Hardware - Support > Other

Compaq CQ57 Internal SD card reader not recognized by gparted, parted, or fdisk

(1/1)

rokytnji:

--- Code: [email protected]:~$ lspci -knn
<snip>
02:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS5209 PCI Express Card Reader [10ec:5209] (rev 01)
Subsystem: Hewlett-Packard Company Device [103c:3577]
<snip>

--- End code ---


--- Code: ---$ inxi -zv7
System:    Host: biker1 Kernel: 3.15.0-linuxlite i686 (32 bit gcc: 4.6.3)
           Desktop: Xfce 4.11.6 (Gtk 2.24.23) info: xfce4-panel dm: lightdm
           Distro: Ubuntu 14.04 trusty
Machine:   System: Hewlett-Packard (portable) product: Presario CQ57 Notebook PC v: 068C110003204910000620100
           Mobo: Hewlett-Packard model: 3577 v: 24.48
           Bios: Hewlett-Packard v: F.42 date: 11/07/2011
           Chassis: type: 10
CPU:       Dual core AMD C-50 (-MCP-) cache: 1024 KB
           flags: (lm nx pae sse sse2 sse3 sse4a ssse3 svm) bmips: 3991
           Clock Speeds: 1: 1000 MHz 2: 800 MHz
Memory:    Using dmidecode: you must be root to run dmidecode
Graphics:  Card: Advanced Micro Devices [AMD/ATI] Wrestler [Radeon HD 6250]
           bus-ID: 00:01.0 chip-ID: 1002:9804
           Display Server: X.Org 1.15.1 drivers: ati,radeon (unloaded: fbdev,vesa)
           Resolution: [email protected]
           GLX Renderer: Gallium 0.4 on AMD PALM
           GLX Version: 3.0 Mesa 10.1.3 Direct Rendering: Yes
Audio:     Card Advanced Micro Devices [AMD/ATI] SBx00 Azalia (Intel HDA)
           driver: snd_hda_intel bus-ID: 00:14.2 chip-ID: 1002:4383
           Sound: Advanced Linux Sound Architecture v: k3.15.0-linuxlite
Network:   Card-1: Realtek RTL8101E/RTL8102E PCI Express Fast Ethernet controller
           driver: r8169 v: 2.3LK-NAPI port: 2000
           bus-ID: 06:00.0 chip-ID: 10ec:8136
           IF: em1 state: down mac: <filter>
           Card-2: Ralink RT5390 Wireless 802.11n 1T/1R PCIe
           driver: rt2800pci v: 2.3.0 bus-ID: 07:00.0 chip-ID: 1814:5390
           IF: wlan1 state: up mac: <filter>
           WAN IP: <filter> IF: em1 ip: N/A ip-v6: N/A
           IF: wlan1 ip: <filter> ip-v6: <filter>
Drives:    HDD Total Size: 121.3GB (19.2% used)
           ID-1: /dev/sda model: APPLE_SSD_SM128 size: 121.3GB serial: DFKU604844ED440
           Optical: /dev/sr0 model: hp DVDRAM GT31L
           rev: MR52 dev-links: cdrom
           Features: speed: 24x multisession: yes
           audio: yes dvd: yes rw: cd-r,cd-rw,dvd-r,dvd-ram state: running
Partition: ID-1: / size: 8.6G used: 4.7G (58%) fs: ext4 dev: /dev/sda1
           label: / uuid: 24580b54-b3d7-418a-96f2-6bbbf1ccccff
           ID-2: /home size: 103G used: 18G (18%) fs: ext3 dev: /dev/sda2
           label: /home uuid: 65f560b2-63b4-41e0-9d4e-4597d237493b
RAID:      System: supported: N/A
           No RAID devices: /proc/mdstat, md_mod kernel module present
           Unused Devices: none
Unmounted: No unmounted partitions detected
Sensors:   System Temperatures: cpu: 61.0C mobo: N/A gpu: 61.0
           Fan Speeds (in rpm): cpu: N/A
Info:      Processes: 159 Uptime: 2:55 Memory: 523.8/3646.9MB
           Init: Upstart v: 1.12.1 runlevel: 2 default: 2 Gcc sys: 4.8.2
           Client: Shell (bash 4.3.111 running in x-terminal-emul) inxi: 2.2.1
--- End code ---


--- Code: ---$ sudo modprobe rts_pstor
[sudo] password for harry:
modprobe: FATAL: Module rts_pstor not found.

--- End code ---

For now. I use a usb to sd card adapter to use sd cards on this laptop. As lspci -knn shows. The card reader is unassigned by Linux-Lite kernel and no driver is loaded.

Gparted, parted -l, and fdisk -l will not show the card in my internal card reader.
Ubuntu says that this bug should be fixed in upstream kernels but I guess
something was missed somewhere, somehow?

md5sum checks were done before install.

Searching gives me,

http://www.omgubuntu.co.uk/2011/02/card-reader-not-working-hp-mini-ubuntu

and

http://www.realtek.com.tw/downloads/downloadsView.aspx?Langid=1&PNid=15&PFid=25&Level=4&Conn=3&DownTypeID=3&GetDown=false

So this is where I am presently at on this problem


--- Code: [email protected]:~$ cd Downloads
[email protected]:~/Downloads$ ls
rts_pstor  rts_pstor.tar.bz2
[email protected]:~/Downloads$ cd rts_pstor
[email protected]:~/Downloads/rts_pstor$ ls
debug.h         ms.c         rtsx_chip.c  rtsx_transport.c  timestamp.in
define.debug    ms.h         rtsx_chip.h  rtsx_transport.h  trace.h
define.release  README.txt   rtsx.h       sd.c              xd.c
general.c       rtsx.c       rtsx_scsi.c  sd.h              xd.h
general.h       rtsx_card.c  rtsx_scsi.h  spi.c
Makefile        rtsx_card.h  rtsx_sys.h   spi.h
[email protected]:~/Downloads/rts_pstor$ make
sed "s/RTSX_MK_TIME/`date +%y.%m.%d.%H.%M`/" timestamp.in > timestamp.h
cp -f ./define.release ./define.h
make -C /lib/modules/3.15.0-linuxlite/build/ SUBDIRS=/home/harry/Downloads/rts_pstor modules
make[1]: Entering directory `/usr/src/linux-headers-3.15.0-linuxlite'
  CC [M]  /home/harry/Downloads/rts_pstor/rtsx.o
/home/harry/Downloads/rts_pstor/rtsx.c:275:2: error: unknown field ‘proc_info’ specified in initializer
  .proc_info =   proc_info,
  ^
/home/harry/Downloads/rts_pstor/rtsx.c:275:2: warning: initialization from incompatible pointer type [enabled by default]
/home/harry/Downloads/rts_pstor/rtsx.c:275:2: warning: (near initialization for ‘rtsx_host_template.proc_dir’) [enabled by default]
/home/harry/Downloads/rts_pstor/rtsx.c:916:22: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘rtsx_probe’
 static int __devinit rtsx_probe(struct pci_dev *pci, const struct pci_device_id *pci_id)
                      ^
/home/harry/Downloads/rts_pstor/rtsx.c:1080:23: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘rtsx_remove’
 static void __devexit rtsx_remove(struct pci_dev *pci)
                       ^
/home/harry/Downloads/rts_pstor/rtsx.c:1106:11: error: ‘rtsx_probe’ undeclared here (not in a function)
  .probe = rtsx_probe,
           ^
/home/harry/Downloads/rts_pstor/rtsx.c:1107:2: error: implicit declaration of function ‘__devexit_p’ [-Werror=implicit-function-declaration]
  .remove = __devexit_p(rtsx_remove),
  ^
/home/harry/Downloads/rts_pstor/rtsx.c:1107:24: error: ‘rtsx_remove’ undeclared here (not in a function)
  .remove = __devexit_p(rtsx_remove),
                        ^
/home/harry/Downloads/rts_pstor/rtsx.c:485:12: warning: ‘rtsx_control_thread’ defined but not used [-Wunused-function]
 static int rtsx_control_thread(void * __dev)
            ^
/home/harry/Downloads/rts_pstor/rtsx.c:596:12: warning: ‘rtsx_polling_thread’ defined but not used [-Wunused-function]
 static int rtsx_polling_thread(void * __dev)
            ^
/home/harry/Downloads/rts_pstor/rtsx.c:745:13: warning: ‘quiesce_and_remove_host’ defined but not used [-Wunused-function]
 static void quiesce_and_remove_host(struct rtsx_dev *dev)
             ^
/home/harry/Downloads/rts_pstor/rtsx.c:780:13: warning: ‘release_everything’ defined but not used [-Wunused-function]
 static void release_everything(struct rtsx_dev *dev)
             ^
/home/harry/Downloads/rts_pstor/rtsx.c:790:12: warning: ‘rtsx_scan_thread’ defined but not used [-Wunused-function]
 static int rtsx_scan_thread(void * __dev)
            ^
/home/harry/Downloads/rts_pstor/rtsx.c:816:13: warning: ‘rtsx_init_options’ defined but not used [-Wunused-function]
 static void rtsx_init_options(struct rtsx_chip *chip)
             ^
cc1: some warnings being treated as errors
make[2]: *** [/home/harry/Downloads/rts_pstor/rtsx.o] Error 1
make[1]: *** [_module_/home/harry/Downloads/rts_pstor] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.15.0-linuxlite'
make: *** [default] Error 2
[email protected]:~/Downloads/rts_pstor$

--- End code ---


I am not liking the make errors so I am not proceeding any further with this problem till I hear some feedback on this.

Edit: Just to show I picked the right download I grabbed the


--- Quote ---PCIE RTS5209 card reader driver for Linux   V1.10   2012/7/12
--- End quote ---

on that realtek page.

Happy Trails, Rok

2nd Edit: Tried using a fix posted below

http://dainaccio.wordpress.com/2013/07/14/realtek-sd-reader-mounting-problems-under-linux-mintubuntu/#more-836

And changed the lines on


--- Quote --- to remove __devinit keywords from rtsx.c file.
Open the file with a text editor and modify lines 916, 1080 and 1107:


--- End quote ---

To


--- Quote ---/* Driver for Realtek PCI-Express card reader
 *
 * Copyright(c) 2009 Realtek Semiconductor Corp. All rights reserved. 
 *
 * This program is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License as published by the
 * Free Software Foundation; either version 2, or (at your option) any
 * later version.
 *
 * This program is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License along
 * with this program; if not, see <http:
 *
 * Author:
 *   wwang ([email protected])
 *   No. 450, Shenhu Road, Suzhou Industry Park, Suzhou, China
<snip>
Line 916: static int  rtsx_probe(struct pci_dev *pci, const struct pci_device_id *pci_id)
<snip>
Line 1080:  static void  rtsx_remove(struct pci_dev *pci)
<snip>
Line 1107:  .remove = rtsx_remove,
--- End quote ---

But make still throws errors. At least I am trying.


--- Code: [email protected]:~/Downloads/rts_pstor$ make
sed "s/RTSX_MK_TIME/`date +%y.%m.%d.%H.%M`/" timestamp.in > timestamp.h
cp -f ./define.release ./define.h
make -C /lib/modules/3.15.0-linuxlite/build/ SUBDIRS=/home/harry/Downloads/rts_pstor modules
make[1]: Entering directory `/usr/src/linux-headers-3.15.0-linuxlite'
  CC [M]  /home/harry/Downloads/rts_pstor/rtsx.o
/home/harry/Downloads/rts_pstor/rtsx.c:275:2: error: unknown field ‘proc_info’ specified in initializer
  .proc_info =   proc_info,
  ^
/home/harry/Downloads/rts_pstor/rtsx.c:275:2: warning: initialization from incompatible pointer type [enabled by default]
/home/harry/Downloads/rts_pstor/rtsx.c:275:2: warning: (near initialization for ‘rtsx_host_template.proc_dir’) [enabled by default]
make[2]: *** [/home/harry/Downloads/rts_pstor/rtsx.o] Error 1
make[1]: *** [_module_/home/harry/Downloads/rts_pstor] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.15.0-linuxlite'
make: *** [default] Error 2
[email protected]:~/Downloads/rts_pstor$

--- End code ---

This comment


--- Quote [email protected] I got the same error. To fix it, I deleted the line .proc_name = .proc_name on line 274 of rtsx.c. After that, unload the dependencies and reload rts_pstor.
--- End quote ---

Did not help either.  So presently. I deleted the extracted folder I made changes to and re-extracted the .bz2 again to start from scratch.

rokytnji:
Solved by installing a different kernel image and header. The 3.13 kernel that comes with Linux-Lite 2.0 also enables the internal card reader. So I will use 3.13 as a backup and just run the liqourox kernel till somebody comes up with a fix for the 3.15 or any later kernels
Linux-lite puts out. I have not tested this on My Dell XT2 install yet with it's internal sd card reader.


--- Code: [email protected]:~$ uname -a
Linux biker1 3.14.3-dreamlinux-liquorix #1 ZEN SMP PREEMPT Wed May 14 17:21:07 CEST 2014 i686 athlon i686 GNU/Linux
[email protected]:~$ free
             total       used       free     shared    buffers     cached
Mem:       3736904     825844    2911060       9084      29568     351124
-/+ buffers/cache:     445152    3291752
Swap:            0          0          0
[email protected]:~$ dpkg --list | grep linux-image
ii  linux-image-3.13.0-24-generic              3.13.0-24.47                           i386         Linux kernel image for version 3.13.0 on 32 bit x86 SMP
ii  linux-image-3.14.3-dreamlinux-liquorix     1                                      i386         Linux kernel binary image for version 3.14.3-dreamlinux-liquorix
ii  linux-image-extra-3.13.0-24-generic        3.13.0-24.47                           i386         Linux kernel extra modules for version 3.13.0 on 32 bit x86 SMP
--- End code ---


--- Code: [email protected]:~$ dpkg --list | grep linux-headers
ii  linux-headers-3.13.0-24                    3.13.0-24.47                           all          Header files related to Linux kernel version 3.13.0
ii  linux-headers-3.13.0-24-generic            3.13.0-24.47                           i386         Linux kernel headers for version 3.13.0 on 32 bit x86 SMP
ii  linux-headers-3.14.3-dreamlinux-liquorix   1                                      i386         Header files related to Linux kernel, specifically,

--- End code ---


--- Code: [email protected]:~$ sudo update-grub
[sudo] password for harry:
Generating grub configuration file ...
Warning: Setting GRUB_TIMEOUT to a non-zero value when GRUB_HIDDEN_TIMEOUT is set is no longer supported.
Found linux image: /boot/vmlinuz-3.14.3-dreamlinux-liquorix
Found initrd image: /boot/initrd.img-3.14.3-dreamlinux-liquorix
Found linux image: /boot/vmlinuz-3.13.0-24-generic
Found initrd image: /boot/initrd.img-3.13.0-24-generic
Found memtest86+ image: /boot/memtest86+.elf
Found memtest86+ image: /boot/memtest86+.bin
done
[email protected]:~$ i

--- End code ---

I have not really tested the liqourix dreamlinux kernel. I know it works good on my AntiX 13.2 Debian Stable install on my antique IBM T23 Laptop. If anyone else is reading this. I guess just go with the 3.13 that ships with this distro. I just don't feel like not having a backup kernel in case something goes wrong later in a upgrade. SD card now automounts just fine.


--- Code: [email protected]:~$ sudo parted -l
[sudo] password for harry:
Model: ATA APPLE SSD SM128 (scsi)
Disk /dev/sda: 121GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number  Start   End     Size    File system  Name  Flags
 1      1049kB  9438MB  9437MB  ext4
 2      9438MB  121GB   112GB   ext3


Model: SD SD08G (sd/mmc)
Disk /dev/mmcblk0: 7948MB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number  Start   End     Size    Type     File system  Flags
 1      32.3kB  7946MB  7946MB  primary  fat32

--- End code ---

I am not marking this as solved yet because maybe someone will want me to test another i686 kernel on this 4 gig ram
Compaq CQ57 Laptop. I prefer not to keep the Liqourix kernel on here as that was only done as a test.

Edit/Update: Removed dreamlinux kernel. I did not trust that it might be compatible so I am just running one kernel


--- Code: [email protected]:~$ sudo update-grub
[sudo] password for harry:
Generating grub configuration file ...
Warning: Setting GRUB_TIMEOUT to a non-zero value when GRUB_HIDDEN_TIMEOUT is set is no longer supported.
Found linux image: /boot/vmlinuz-3.13.0-24-generic
Found initrd image: /boot/initrd.img-3.13.0-24-generic
Found memtest86+ image: /boot/memtest86+.elf
Found memtest86+ image: /boot/memtest86+.bin
done
[email protected]:~$ sudo parted -l
Model: ATA APPLE SSD SM128 (scsi)
Disk /dev/sda: 121GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number  Start   End     Size    File system  Name  Flags
 1      1049kB  9438MB  9437MB  ext4
 2      9438MB  121GB   112GB   ext3


Model: SD SU16G (sd/mmc)
Disk /dev/mmcblk0: 15.9GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number  Start   End     Size    Type     File system  Flags
 1      1049kB  15.9GB  15.9GB  primary  fat32        boot

--- End code ---

Oh Well. At least the internal card reader works now.

Navigation

[0] Message Index

Go to full version