Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
7-in-1 Card Reader recognized in kernel but not media
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
sonix
Tux's lil' helper
Tux's lil' helper


Joined: 12 Feb 2003
Posts: 102

PostPosted: Sat Oct 22, 2005 5:05 pm    Post subject: 7-in-1 Card Reader recognized in kernel but not media Reply with quote

http://www.geeks.com/imageshare/5/300x300/5069-6272-unit.jpg

So I have that Hewlett Packard 7-in-1 Card Reader. I looked up a couple posts here of others who have multiple card reader and followed with what they did (enabling LUP, usb-storage in kernel).

So I dmesg when i stick a card in and no update to dmesg. but a blue LED lights up next to the card.

here's whats in dmesg though.

dmesg wrote:
Initializing USB Mass Storage driver...
usb 2-1: new low speed USB device using ohci_hcd and address 2
usbcore: registered new driver usb-storage
USB Mass Storage support registered.
usb 3-1: new full speed USB device using ohci_hcd and address 2
scsi2 : SCSI emulation for USB Mass Storage devices
usb-storage: device found at 2
usb-storage: waiting for device to settle before scanning
input: USB HID v1.10 Mouse [Logitech USB Receiver] on usb-0000:00:02.0-1
usbcore: registered new driver usbhid
drivers/usb/input/hid-core.c: v2.01:USB HID core driver
Advanced Linux Sound Architecture Driver Version 1.0.9rc2 (Thu Mar 24 10:33:39 2005 UTC).
ACPI: PCI Interrupt Link [APCJ] enabled at IRQ 21
ACPI: PCI Interrupt 0000:00:06.0[A] -> Link [APCJ] -> GSI 21 (level, high) -> IRQ 21
PCI: Setting latency timer of device 0000:00:06.0 to 64
intel8x0_measure_ac97_clock: measured 50704 usecs
intel8x0: clocking to 48000
ALSA device list:
#0: NVidia nForce2 with ALC650F at 0xec081000, irq 21
oprofile: using NMI interrupt.
NET: Registered protocol family 2
...
ACPI wakeup devices:
HUB0 HUB1 USB0 USB1 USB2 F139 MMAC MMCI UAR1
ACPI: (supports S0 S1 S4 S5)
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem) readonly.
Freeing unused kernel memory: 224k freed
kjournald starting. Commit interval 5 seconds
Adding 1004020k swap on /dev/hda1. Priority:-1 extents:1
EXT3 FS on sda2, internal journal
Vendor: Generic Model: USB SD Reader Rev: 1.00
Type: Direct-Access ANSI SCSI revision: 00
Attached scsi removable disk sdb at scsi2, channel 0, id 0, lun 0
Attached scsi generic sg1 at scsi2, channel 0, id 0, lun 0, type 0
Vendor: Generic Model: USB CF Reader Rev: 1.01
Type: Direct-Access ANSI SCSI revision: 00
Attached scsi removable disk sdc at scsi2, channel 0, id 0, lun 1
Attached scsi generic sg2 at scsi2, channel 0, id 0, lun 1, type 0
Vendor: Generic Model: USB SM Reader Rev: 1.02
Type: Direct-Access ANSI SCSI revision: 00
Attached scsi removable disk sdd at scsi2, channel 0, id 0, lun 2
Attached scsi generic sg3 at scsi2, channel 0, id 0, lun 2, type 0
Vendor: Generic Model: USB MS Reader Rev: 1.03
Type: Direct-Access ANSI SCSI revision: 00
Attached scsi removable disk sde at scsi2, channel 0, id 0, lun 3
Attached scsi generic sg4 at scsi2, channel 0, id 0, lun 3, type 0
usb-storage: device scan complete


so why is it not reading my card when i plug it in?
Back to top
View user's profile Send private message
Headrush
Watchman
Watchman


Joined: 06 Nov 2003
Posts: 5597
Location: Bizarro World

PostPosted: Sat Oct 22, 2005 5:13 pm    Post subject: Reply with quote

I have two of these type devices and it is far from 100%
1 supports the 7 or so types it can handle perfectly, but doesn't automate mounts using udev/dbus/pmount .
The other works for all types except SD, (dmesg shows nothing), but mounts all the other types perfectly.

So I don't think its just kernel support, I think so devices might be a little "flakier" than others.
Back to top
View user's profile Send private message
sonix
Tux's lil' helper
Tux's lil' helper


Joined: 12 Feb 2003
Posts: 102

PostPosted: Sat Oct 22, 2005 5:21 pm    Post subject: Reply with quote

Headrush wrote:
I have two of these type devices and it is far from 100%
I think so devices might be a little "flakier" than others.


got any tips i should try out or anything i should double check?
Back to top
View user's profile Send private message
servo888
Apprentice
Apprentice


Joined: 22 Feb 2004
Posts: 293

PostPosted: Sat Oct 22, 2005 5:21 pm    Post subject: Reply with quote

Make sure you enable 'probe all luns' in the kernel config (under scsi), and there are new MMC / SD options available in the kernel (towards the bottom of device drivers iirc), enable that as well.
_________________
www.garberdesign.com
"You need a Windows PC to listen to this music." -listen.com
Back to top
View user's profile Send private message
sonix
Tux's lil' helper
Tux's lil' helper


Joined: 12 Feb 2003
Posts: 102

PostPosted: Sat Oct 22, 2005 5:50 pm    Post subject: Reply with quote

servo888 wrote:
Make sure you enable 'probe all luns' in the kernel config (under scsi), and there are new MMC / SD options available in the kernel (towards the bottom of device drivers iirc), enable that as well.


yup. all enabled.

Quote:
#
# MMC/SD Card support
#
CONFIG_MMC=y
# CONFIG_MMC_DEBUG is not set
CONFIG_MMC_BLOCK=y
CONFIG_MMC_WBSD=m

# Some SCSI devices (e.g. CD jukebox) support multiple LUNs
#
CONFIG_SCSI_MULTI_LUN=y
# CONFIG_SCSI_CONSTANTS is not set
# CONFIG_SCSI_LOGGING is not set
Back to top
View user's profile Send private message
Headrush
Watchman
Watchman


Joined: 06 Nov 2003
Posts: 5597
Location: Bizarro World

PostPosted: Sat Oct 22, 2005 10:34 pm    Post subject: Reply with quote

Headrush wrote:
I have two of these type devices and it is far from 100%
1 supports the 7 or so types it can handle perfectly, but doesn't automate mounts using udev/dbus/pmount .
The other works for all types except SD, (dmesg shows nothing), but mounts all the other types perfectly.

I was sure probe all logical units was enabled, but I doubled checked and sure enough it wasn't. :oops:

Headrush wrote:
So I don't think its just kernel support, I think so devices might be a little "flakier" than others.

Didn't realize the kernel now had specific MMC driver support now.

Both device seem to work now. I compiled the MMC modules this time, both none are loaded and the devices work now. :?
Back to top
View user's profile Send private message
lindegur
Apprentice
Apprentice


Joined: 14 Aug 2004
Posts: 270
Location: Swiss mountains

PostPosted: Thu Dec 29, 2005 9:55 am    Post subject: Reply with quote

Make sure that you have disabled then USB block driver (BLK_DEV_UB) in the kernel since it causes a conflict.
Explore /dev/ for nodes (are you using udev?)
udevinfo -a -p $(udevinfo -q path -n /dev/sda)
is the magic command to see what is behind the different /dev nodes. If it would work you would see for each slot a device. e.g /dev/sda, /dev/sdb, ...
If you have /dev/uda then the above USB block driver (BLK_DEV_UB) is on.
Back to top
View user's profile Send private message
sonix
Tux's lil' helper
Tux's lil' helper


Joined: 12 Feb 2003
Posts: 102

PostPosted: Thu Dec 29, 2005 8:21 pm    Post subject: Reply with quote

lindegur wrote:
Make sure that you have disabled then USB block driver (BLK_DEV_UB) in the kernel since it causes a conflict.
Explore /dev/ for nodes (are you using udev?)
udevinfo -a -p $(udevinfo -q path -n /dev/sda)
is the magic command to see what is behind the different /dev nodes. If it would work you would see for each slot a device. e.g /dev/sda, /dev/sdb, ...
If you have /dev/uda then the above USB block driver (BLK_DEV_UB) is on.


could you repeat that? i dont quite understand what the command is.

udevinfo -a -p $(udevinfo -q path -n /dev/sda)
all in one line like that?

dmesg wrote:
EXT3 FS on sda2, internal journal
Vendor: Generic Model: USB SD Reader Rev: 1.00
Type: Direct-Access ANSI SCSI revision: 00
Attached scsi removable disk sdb at scsi2, channel 0, id 0, lun 0
Attached scsi generic sg1 at scsi2, channel 0, id 0, lun 0, type 0
Vendor: Generic Model: USB CF Reader Rev: 1.01
Type: Direct-Access ANSI SCSI revision: 00
Attached scsi removable disk sdc at scsi2, channel 0, id 0, lun 1
Attached scsi generic sg2 at scsi2, channel 0, id 0, lun 1, type 0
Vendor: Generic Model: USB SM Reader Rev: 1.02
Type: Direct-Access ANSI SCSI revision: 00
Attached scsi removable disk sdd at scsi2, channel 0, id 0, lun 2
Attached scsi generic sg3 at scsi2, channel 0, id 0, lun 2, type 0
Vendor: Generic Model: USB MS Reader Rev: 1.03
Type: Direct-Access ANSI SCSI revision: 00
Attached scsi removable disk sde at scsi2, channel 0, id 0, lun 3
Attached scsi generic sg4 at scsi2, channel 0, id 0, lun 3, type 0
usb-storage: device scan complete
Back to top
View user's profile Send private message
lindegur
Apprentice
Apprentice


Joined: 14 Aug 2004
Posts: 270
Location: Swiss mountains

PostPosted: Sat Dec 31, 2005 2:15 pm    Post subject: Reply with quote

udevinfo -a -p $(udevinfo -q path -n /dev/mmcsd)
is as I said the magic command that I was looking for long time.
udevinfo -q path -n /dev/mmcsd
tells you where under /sys the kernel has put the data about my multimedia card / secure disk slot of my multi card reader.
/block/sdc
Knowing where the kernel has put the data under /sys you could do a
udevinfo -a -p /block/sdc
And I would get the information about all of it. Special interest would be:
It is USB2 full speed! DRIVER=="ehci_hcd"
Sits in my SYSFS{product}=="USB2.0 Card Reader"
Here one of the key options in the kernel configuration DRIVER=="usb-storage"
Here is the name of the slot in the multi readerSYSFS{model}=="IC1210 MMC/SD"

Instead of the two commands the magic command just puts the result of the first command as parameter for the second command.
:lol:

The problem of the multi slot card readers is to find out what /dev/sd* is mapped to what slot? The sample above tells how to find it out. To scare you, the mapping is not static, if you plug in other memory sticks it could produce an other mapping (as windows does).

Way out are udev rules. Edit /etc/udev/rules.d/10-local.rules
#Apacer Card Reader
BUS="scsi", KERNEL="sd*", SYSFS{model}=="IC1210 CF", NAME="cflash%n"
BUS="scsi", KERNEL="sd*", SYSFS{model}=="IC1210 MS", NAME="mstick%n"
BUS="scsi", KERNEL="sd*", SYSFS{model}=="IC1210 MMC/SD", NAME="mmcsd%n"
BUS="scsi", KERNEL="sd*", SYSFS{model}=="IC1210 SM", NAME="smedia%n"
#any further usb memory stick
BUS="usb", DRIVER=="usb-storage", KERNEL="sd*", NAME="usbstk%n"

and you have it fixed. This is also where my /dev/mmcsd comes from.
All usb memory sticks plugged in can be accessed under /dev/usbstk and not one time sda then sde and so on. :lol:
it took me a long time until my computer behaves like this, but it is not that complicated when you know how. :roll:
Back to top
View user's profile Send private message
sonix
Tux's lil' helper
Tux's lil' helper


Joined: 12 Feb 2003
Posts: 102

PostPosted: Sat Dec 31, 2005 8:51 pm    Post subject: Reply with quote

should i create that file or could i add this to /etc/udev/rules.d/50-udev.rules ?

Quote:
stalin ~ # udevinfo -a -p $(udevinfo -q path -n /dev/sde)

udevinfo starts with the device the node belongs to and then walks up the
device chain, to print for every device found, all possibly useful attributes
in the udev key format.
Only attributes within one device section may be used together in one rule,
to match the device for which the node will be created.

device '/sys/block/sde' has major:minor 8:64
looking at class device '/sys/block/sde':
SUBSYSTEM=="block"
SYSFS{dev}=="8:64"
SYSFS{range}=="16"
SYSFS{removable}=="1"
SYSFS{size}=="0"
SYSFS{stat}==" 0 0 0 0 0 0 0
0 0 0 0"

follow the "device"-link to the physical device:
looking at the device chain at '/sys/devices/pci0000:00/0000:00:02.1/usb3/3-1/
3-1:1.0/host2/target2:0:0/2:0:0:3':
BUS=="scsi"
ID=="2:0:0:3"
DRIVER=="sd"
SYSFS{device_blocked}=="0"
SYSFS{iocounterbits}=="32"
SYSFS{iodone_cnt}=="0x4"
SYSFS{ioerr_cnt}=="0x3"
SYSFS{iorequest_cnt}=="0x4"
SYSFS{max_sectors}=="240"
SYSFS{model}=="USB MS Reader "
SYSFS{queue_depth}=="1"
SYSFS{queue_type}=="none"
SYSFS{rev}=="1.03"
SYSFS{scsi_level}=="3"
SYSFS{state}=="running"
SYSFS{timeout}=="30"
SYSFS{type}=="0"
SYSFS{vendor}=="Generic "

couldn't open device directory



Quote:
# udevinfo -a -p /block/sdc

udevinfo starts with the device the node belongs to and then walks up the
device chain, to print for every device found, all possibly useful attributes
in the udev key format.
Only attributes within one device section may be used together in one rule,
to match the device for which the node will be created.

device '/sys/block/sdc' has major:minor 8:32
looking at class device '/sys/block/sdc':
SUBSYSTEM=="block"
SYSFS{dev}=="8:32"
SYSFS{range}=="16"
SYSFS{removable}=="1"
SYSFS{size}=="0"
SYSFS{stat}==" 0 0 0 0 0 0 0
0 0 0 0"

follow the "device"-link to the physical device:
looking at the device chain at '/sys/devices/pci0000:00/0000:00:02.1/usb3/3-1/
3-1:1.0/host2/target2:0:0/2:0:0:1':
BUS=="scsi"
ID=="2:0:0:1"
DRIVER=="sd"
SYSFS{device_blocked}=="0"
SYSFS{iocounterbits}=="32"
SYSFS{iodone_cnt}=="0x4"
SYSFS{ioerr_cnt}=="0x3"
SYSFS{iorequest_cnt}=="0x4"
SYSFS{max_sectors}=="240"
SYSFS{model}=="USB CF Reader "
SYSFS{queue_depth}=="1"
SYSFS{queue_type}=="none"
SYSFS{rev}=="1.01"
SYSFS{scsi_level}=="3"
SYSFS{state}=="running"
SYSFS{timeout}=="30"
SYSFS{type}=="0"
SYSFS{vendor}=="Generic "

couldn't open device directory
Back to top
View user's profile Send private message
lindegur
Apprentice
Apprentice


Joined: 14 Aug 2004
Posts: 270
Location: Swiss mountains

PostPosted: Sun Jan 01, 2006 1:32 am    Post subject: Reply with quote

By the way happy new year, at least here its 2006

Dont't edit /etc/udev/rules.d/50-udev.rules since it will go lost after some udev update. Create the /etc/udev/rules.d/10-local.rules it will have priority and if no rules match then udev looks in /etc/udev/rules.d/50-udev.rules

If I look at your responsel I would say that you should be able to do mount /dev/sde for your MS (memory stick) and sdc CF (compact flash). I recommend to do first a simple mount and then adapt the udev rules. Can you do a mount?

What I don't like is couldn't open device directory I get much more output from the udevinfo -a -p $(udevinfo -q path -n /dev/sde) as a block with DRIVER=="usb-storage"
and an other with SYSFS{product}=="USB2.0 Card Reader" and an other SYSFS{product}=="EHCI Host Controller" so much data that I dont want to copy all of it here. I think something is wrong there, maybe with the kernel? udevinfo goes up to /sys/devices/pci0000:00' in my case and prints out all in this directory tree. However in your case it stops. Can you check manually with konqueror what is there? (I have to admit that I'm still a newbe if it comes to those detail but I like to learn).

Some thing simple to begin:
Can you mount other usb devices as a simple usb memory stick plugged in directly to one of the computers usb connectors?
In the console type su then password and do a mount /dev/sde1 /mnt/somedirectory . Remember do it as root and the 1 means first partition on the memory stick in this case.
Back to top
View user's profile Send private message
andersbk
n00b
n00b


Joined: 16 Aug 2003
Posts: 35

PostPosted: Wed Feb 22, 2006 7:17 pm    Post subject: Reply with quote

EDIT: Resolved to my liking. Follow link below, to other thread, for my solution.

Bumping this tread.

I am close to getting the multi reader on my Dell 2405fpw working. For whatever reason, it (udev) will not create symlinks based on my rules unless I "hotplug" the reader/monitor with a CF already inserted. If I insert/remove a CF any other time, nothing happens, nothing changes. Ideas?

For more details about my setup, see:
https://forums.gentoo.org/viewtopic-p-3131673.html#3131673

TIA.
Back to top
View user's profile Send private message
lindegur
Apprentice
Apprentice


Joined: 14 Aug 2004
Posts: 270
Location: Swiss mountains

PostPosted: Mon Jul 24, 2006 8:04 am    Post subject: Reply with quote

Maybe this helps:
https://forums.gentoo.org/viewtopic-t-474862-highlight-.html
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum