# [Solved] USB SD Card Reader not working

## cazdli

Hey guys, I'm having an issue getting my laptop's built in USB SD Card Reader to work.  I bought it a few days ago and I can read its contents just fine when I'm on a liveCD, but on my actual Gentoo instalaltion, it hasn't really worked out for me. 

On my kernel config, I have:

```

CONFIG_USB_STORAGE=y

CONFIG_USB_STORAGE_REALTEK=y

CONFIG_SCSI_MULTI_LUN=y

```

When I run lsusb, my output is

```

Bus 001 Device 003: ID 0bda:0129 Realtek Semiconductor Corp. RTS5129 Card Reader Controller

```

Any ideas on how to get it working?Last edited by cazdli on Tue Aug 13, 2013 9:26 pm; edited 1 time in total

----------

## eccerr0r

When you plug it in, what does your dmesg log say?

Are you sure you're running the right kernel?

----------

## cazdli

dmesg doesn't say anything relevant to the SD Card, it just mentions rtl8723au, which is my wireless card. 

Yea, I'm pretty sure I'm running the right kernel, just double checked now and the modules I listed in the OP are on Y.

----------

## Jaglover

Run 

```
uname -a
```

to see what kernel is running. Pay attention to date and time.

----------

## cazdli

```

3.10.1-gentoo #1 SMP Sat Jul 20 00:56:49 EDT 2013 x86_64 Intel(R) Core(TM) i7-3517U CPU @ 1.90GHz GenuineIntel GNU/Linux

```

Yep, running the correct one.

----------

## eccerr0r

Does it make a difference if you plug into USB with SD card inserted?

Set CONFIG_USB_ANNOUNCE_NEW_DEVICES=y so you can see dmesg events dealing with usb?

Do you have other USB devices and are they working?

Have all three XHCI, EHCI, and UHCI built in or modularized? (should be OK if it shows up in usb...)

CONFIG_BLK_DEV_SD=y ? (should be ok if you're using libata...)

----------

## cazdli

It doesn't really make a difference if I plug in an USB with the SD Card inserted, it reads just fine.

I do have CONFIG_USB_ANNOUNCE_NEW_DEVICES=y and it does work whenever I plug in my USB flashdrive or my mouse through the USB slot, but nothing when the SD card is inserted.

My mouse, flash drive, and USB headset are working just fine too.

CONFIG_BLK_DEV_SD is set to y

I actually didn't have all three XHCI, EHCI, UHCI built in/modularized (rather, I had some of them built-in or modularized, but not every single one of them), but I did so after reading your post. Still no change.

----------

## eccerr0r

 *cazdli wrote:*   

> but nothing when the SD card is inserted.
> 
> 

 

Ok if it works when the sd card is already inserted and then the USB is plugged in, but not when the media is inserted after USB is plugged in, it's a udisks issue - need to tell udisks/hal to poll the usb device... which is something I'm not sure how to do as it keeps changing...

----------

## cazdli

Oh no, the USB devices work just fine even when the SD card isn't inserted. The only issue I have is with the SD Card, everything else works with or without the SD Card inserted.

After reading your post, I decided to check out udisks anyway, I gave the udisks man a read and ran udisks --debug to list information on the devices, but nothing about my SD Card showed up.

I also ran udisks --monitor and tried ejecting/inserting the SD Card to see if there's any activity and it doesn't show anything either.

So I was thinking it was probably a kernel issue, but apparently that wasn't the case. I don't know what to do anymore.   :Crying or Very sad: 

----------

## cjubon

Hi, you also need to enable MMC/SC Card Support in your kernel config (Device drivers >> MMC/SD/SDIO Card Support >> Select what your machine needs).

Cheers, cjubon

----------

## eccerr0r

Though it may be worth a try, USB sd card readers abstract the sd interface away and thus does not tend to need that driver.

My built-in SD card readers on my HP laptops do require this interface however, but my Asus eeePC with its built-in USB SD card reader does not - it's just another plain USB mass storage device with removable storage.

----------

## cazdli

 *Quote:*   

> 
> 
> Hi, you also need to enable MMC/SC Card Support in your kernel config (Device drivers >> MMC/SD/SDIO Card Support >> Select what your machine needs).
> 
> Cheers, cjubon
> ...

 

I have that set to M on my kernel configuration, no dice.

 *Quote:*   

> 
> 
> Though it may be worth a try, USB sd card readers abstract the sd interface away and thus does not tend to need that driver.
> 
> My built-in SD card readers on my HP laptops do require this interface however, but my Asus eeePC with its built-in USB SD card reader does not - it's just another plain USB mass storage device with removable storage.
> ...

 

So you're telling me to disable MMC/SD/SDIO card support from the kernel?

Currently, this is my .config

http://pastebin.com/jwrSw7zY

----------

## cazdli

Solved. Even though lsusb tells me it's rts5129 The lenovo yoga uses the rts5139 driver that's under device drivers > staging.

Only had to enable this driver in order to get it to work perfectly.

----------

## chemonz

 *cazdli wrote:*   

> Solved. Even though lsusb tells me it's rts5129 The lenovo yoga uses the rts5139 driver that's under device drivers > staging.
> 
> Only had to enable this driver in order to get it to work perfectly.

 

what is the kernel version you are using? I do not have my support in version 3.9.8.

----------

