[Feature Request] Provide a driver for Ricoh R5C822 xD card reader

Bug #202490 reported by Rlgc79
378
This bug affects 58 people
Affects Status Importance Assigned to Milestone
linux (Debian)
Confirmed
Wishlist
fony
Nominated for Lenny by de100671
linux (Ubuntu)
Fix Released
Wishlist
Maxim Levitsky
Nominated for Karmic by Leonardo Horovitz
Nominated for Lucid by Leonardo Horovitz
Nominated for Maverick by Jerone Young
udev (Ubuntu)
Fix Released
Undecided
Unassigned
Nominated for Karmic by Leonardo Horovitz
Nominated for Lucid by Leonardo Horovitz
Nominated for Maverick by Jerone Young

Bug Description

*** NOTE: this is a *wishlist* item - a request for new functionality. At present, and perhaps forever, xD support on linux is extremely limited. This issue is a request to have xD support added for a specific, and somewhat popular, chipset. Please do not add "me, too" items. We know that it doesn't work. If you want, please add yourself as a subscriber, and click on link to indicate that "This bug effects me, too" In the meantime, there are two xD readers known to work with linux, so if you simply must have xD support, those would be your options.

Now there is an xD driver for this chip.
Supports kernel from 3.6.31.
(http://launchpadlibrarian.net/44373795/ricoh_xd_3.tar.bz2)

The driver is now in Maverick's kernel.
You still need the udev rule to load FTL part of it.

Or just add sm_ftl to /etc/modules.

To install please do ./make && sudo make install && sudo make load

Note that this package installs several kernel modules, similar to compat-wireless
So, make sure that there is no conflict between existing mtd modules and these.

*NOTE* If you use kernel lower that 2.6.34, please be sure to unload the ricoh-mmc driver.
It conflicts with this driver.
This does meant that on this kernel you *can't* use both xD and MMC cards
To be sure that ricoh-mmc is not loaded, you should see the following output:
You can use a modified sdhci driver for mmc cards I attached.
Unfortunately this driver won't help on Mavaric kernel (my fault :-( )

03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)

and NOT:

03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev FF)

------------------------------------------------

On multi-format card readers such as:

> lspci | grep Ricoh
03:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 05)
03:01.1 Generic system peripheral [0805]: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
03:01.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
03:01.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)

SD and MMC cards work, but Xd cards do not. This appears to be due to a lack of driver support for the Xd reader.

There is no need to comment confirming this issue on more laptops. Every laptop with a similar type of reader will be affected.

Revision history for this message
Noel J. Bergman (noeljb) wrote :
Download full text (3.2 KiB)

Same with IBM/Lenovo T61p. SDHC is recognized, xD is not. No messages in any logs or via udevmonitor.

$ lspci | grep Ricoh
15:00.0 CardBus bridge: Ricoh Co Ltd RL5c476 II (rev ba)
15:00.1 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 04)
15:00.2 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 21)
15:00.3 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 11)
15:00.4 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 11)
15:00.5 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 11)

More detail:

15:00.2 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 21)
 Subsystem: Lenovo Unknown device 20c8
 Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
 Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
 Latency: 64
 Interrupt: pin C routed to IRQ 18
 Region 0: Memory at f8101800 (32-bit, non-prefetchable) [size=256]
 Capabilities: [80] Power Management version 2
  Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
  Status: D0 PME-Enable- DSel=0 DScale=2 PME-

15:00.3 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 11)
 Subsystem: Lenovo Unknown device 20c9
 Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
 Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
 Latency: 0
 Interrupt: pin C routed to IRQ 11
 Region 0: Memory at f8101c00 (32-bit, non-prefetchable) [size=256]
 Capabilities: [80] Power Management version 2
  Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
  Status: D0 PME-Enable- DSel=0 DScale=2 PME-

15:00.4 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 11)
 Subsystem: Lenovo Unknown device 20ca
 Control: I/O- Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
 Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
 Interrupt: pin C routed to IRQ 11
 Region 0: Memory at f8102000 (32-bit, non-prefetchable) [size=256]
 Capabilities: [80] Power Management version 2
  Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
  Status: D0 PME-Enable- DSel=0 DScale=2 PME+

15:00.5 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 11)
 Subsystem: Lenovo Unknown device 20cb
 Control: I/O- Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
 Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
 Interrupt: pin C routed to IRQ 11
 Region 0: Memory at f8102400 (32-bit, non-prefetchable) [size=256]
 Capabilities: [80] Power Management version 2
  Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
  Status: D0 PME-Enable- DSel=0 DScale=2 PME+

The problem is also discussed here: http://ubuntuforums.org/showthread.php?t=636704

I'm using Hardy with all current updates:

# uname -a
Linux noel-hardy 2.6.24-16-generic #1 SMP Thu Apr 10 12:47:45 UTC 2008 x86_64 G...

Read more...

Revision history for this message
Zinn (l-zbikowski) wrote :

The same thing - lenovo n100 3000

Revision history for this message
mikele (michael-arnold) wrote :

The same thing - Asus V1S

$ lspci | grep Ricoh
09:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 05)
09:01.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
09:01.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
09:01.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
09:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)

Revision history for this message
mercutio22 (macabro22) wrote :

This
SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter
Won't work out of the box for the Dell XPS m1730 as well.

Revision history for this message
Ian Liu Rodrigues (ian-liu88) wrote :

I have the same bug with Dell Vostro.

03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff) (prog-if ff)
 !!! Unknown header type 7f

Revision history for this message
Court (campbco) wrote :

Ditto for the Dell XPS m1210.

Revision history for this message
DS (ddswanson) wrote :

dv2000t

xD does not work (SD works), also the Palm multimedia Cards do not work for me.

lspci | grep Ricoh
08:09.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller
08:09.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 19)
08:09.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 0a)
08:09.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 05)
08:09.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)

Revision history for this message
P.-A. (pariviere) wrote :

Same for me. SD card doesn't work. No output on dmesg or syslog. Same for udevmonitor

The problem occurs on Ubuntu Hardy uptodate (not tested on Feisty) on a Lenovo T61

15:00.2 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 21)
 Subsystem: Lenovo Unknown device 20c8
 Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
 Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
 Latency: 64
 Interrupt: pin C routed to IRQ 22
 Region 0: Memory at f8101800 (32-bit, non-prefetchable) [size=256]
 Capabilities: [80] Power Management version 2
  Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
  Status: D0 PME-Enable- DSel=0 DScale=2 PME-

15:00.3 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 11)
 Subsystem: Lenovo Unknown device 20c9
 Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
 Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
 Latency: 0
 Interrupt: pin C routed to IRQ 11
 Region 0: Memory at f8101c00 (32-bit, non-prefetchable) [size=256]
 Capabilities: [80] Power Management version 2
  Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
  Status: D0 PME-Enable- DSel=0 DScale=2 PME-

15:00.4 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 11)
 Subsystem: Lenovo Unknown device 20ca
 Control: I/O- Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
 Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
 Interrupt: pin C routed to IRQ 11
 Region 0: Memory at f8102000 (32-bit, non-prefetchable) [size=256]
 Capabilities: [80] Power Management version 2
  Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
  Status: D0 PME-Enable- DSel=0 DScale=2 PME+

15:00.5 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 11)
 Subsystem: Lenovo Unknown device 20cb
 Control: I/O- Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
 Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
 Interrupt: pin C routed to IRQ 11
 Region 0: Memory at f8102400 (32-bit, non-prefetchable) [size=256]
 Capabilities: [80] Power Management version 2
  Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
  Status: D0 PME-Enable- DSel=0 DScale=2 PME+

Revision history for this message
Brad Johnson (itsbradman-gmail) wrote :

Same here Dell Inspiron 1525

02:09.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 05)
02:09.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
02:09.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
02:09.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
02:09.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)

Revision history for this message
Rob Johnson (sk8boy189) wrote :

Same Here Lenovo N100 3000 model: 0768

05:06.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller
05:06.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 19)
05:06.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 0a)
05:06.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 05)
05:06.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)

Revision history for this message
Martin Hammer (martin.hammer) wrote :

SD cards work fine, xD cards do not work on my HP Pavilion dv2699 laptop with a built in Ricoh 5-in-1 card reader.

$ lspci | grep Ricoh
08:09.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 05)
08:09.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
08:09.2 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
08:09.3 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)

Revision history for this message
Daniel Bermudez G. (nergar) wrote :

I can confirm this on a Dell Inspiron 1525

as above: lspci | grep Ricoh

02:09.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 05)
02:09.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
02:09.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
02:09.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
02:09.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)

The hardware works with SD cards but not with Memory Stick

demsg displays nothing.

Revision history for this message
Akdo (menoft) wrote :

I confirm on HP DV6243eu

03:00.0 Network controller: Broadcom Corporation BCM4311 802.11b/g WLAN (rev 01)
07:05.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller
07:05.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 19)
07:05.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 0a)
07:05.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 05)
07:05.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)

only XD card not working.

Revision history for this message
Mario Limonciello (superm1) wrote :

Confirmed on both Ubuntu 8.04 and Ubuntu 8.10 alpha4 on a Studio15n

Changed in dell:
status: New → Confirmed
Revision history for this message
Matt Zimmerman (mdz) wrote :

My hardware is:

15:00.2 SD Host controller [0805]: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter [1180:0822] (rev 21)
15:00.3 System peripheral [0880]: Ricoh Co Ltd R5C843 MMC Host Controller [1180:0843] (rev ff)
15:00.4 System peripheral [0880]: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter [1180:0592] (rev 11)
15:00.5 System peripheral [0880]: Ricoh Co Ltd xD-Picture Card Controller [1180:0852] (rev 11)

running current Intrepid (post-alpha4)

I only have SD and xD cards to test (no MMC). SD works fine, xD is not recognized at all.

[ 13.598137] sdhci: Secure Digital Host Controller Interface driver
[ 13.598140] sdhci: Copyright(c) Pierre Ossman
[ 13.598181] sdhci: SDHCI controller found at 0000:15:00.2 [1180:0822] (rev 21)
[ 13.598213] ACPI: PCI Interrupt 0000:15:00.2[C] -> GSI 18 (level, low) -> IRQ 18
[ 13.599293] mmc0: Will use DMA mode even though HW doesn't fully claim to support it.
[ 13.599293] PCI: Setting latency timer of device 0000:15:00.2 to 64
[ 13.599373] mmc0: SDHCI at 0xf8301800 irq 18 DMA
[ 13.645778] ricoh-mmc: Ricoh MMC Controller disabling driver
[ 13.645778] ricoh-mmc: Copyright(c) Philip Langdale
[ 13.645778] ricoh-mmc: Ricoh MMC controller found at 0000:15:00.3 [1180:0843] (rev 11)
[ 13.645778] ricoh-mmc: Controller is now disabled.

Revision history for this message
graingert (tagrain) wrote :

I get this problem also; HP dv2700 ubuntu hardy amd64

graingert@graingert-laptop:~$ lspci | grep Ricoh
08:09.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 05)
08:09.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
08:09.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
08:09.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
08:09.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)

graingert (tagrain)
Changed in linux:
status: New → Confirmed
Revision history for this message
marco.pallotta (marco-pallotta) wrote :

I can confirm that also in acer aspire 5920, and with Hardy Heron x86-64, xD card is not recognised.
This is my lspci
0a:09.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
0a:09.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
0a:09.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
0a:09.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)

description: updated
Revision history for this message
Leann Ogasawara (leannogasawara) wrote :

The Ubuntu Kernel Team is planning to move to the 2.6.27 kernel for the upcoming Intrepid Ibex 8.10 release. As a result, the kernel team would appreciate it if you could please test this newer 2.6.27 Ubuntu kernel. There are one of two ways you should be able to test:

1) If you are comfortable installing packages on your own, the linux-image-2.6.27-* package is currently available for you to install and test.

--or--

2) The upcoming Alpha5 for Intrepid Ibex 8.10 will contain this newer 2.6.27 Ubuntu kernel. Alpha5 is set to be released Thursday Sept 4. Please watch http://www.ubuntu.com/testing for Alpha5 to be announced. You should then be able to test via a LiveCD.

Please let us know immediately if this newer 2.6.27 kernel resolves the bug reported here or if the issue remains. More importantly, please open a new bug report for each new bug/regression introduced by the 2.6.27 kernel and tag the bug report with 'linux-2.6.27'. Also, please specifically note if the issue does or does not appear in the 2.6.26 kernel. Thanks again, we really appreicate your help and feedback.

Revision history for this message
Matt Zimmerman (mdz) wrote :

This fails to work in precisely the same fashion under 2.6.27-2.3.

Revision history for this message
Matt Zimmerman (mdz) wrote :

It looks like each card type uses a different controller (separate PCI device), and there simply isn't a driver in the kernel for the xD controller. See also http://linux.derkeiler.com/Mailing-Lists/Kernel/2006-03/msg08781.html

Changed in linux:
importance: Undecided → Wishlist
importance: Undecided → Wishlist
Revision history for this message
levmatta (levmatta) wrote : Re: No driver for Ricoh R5C822 Xd card reader

My ...
02:09.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
02:09.2 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
02:09.3 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)
Is also not working on Intrepid 64bit - I have a Dell 1525.
Thanks

Revision history for this message
Alex Maguran (amaguran) wrote :

At least SD card not detected.

HP 8510p

02:06.0 CardBus bridge: Ricoh Co Ltd RL5c476 II (rev b9)
02:06.1 CardBus bridge: Ricoh Co Ltd RL5c476 II (rev b9)
02:06.2 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 03)
02:06.3 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 20)
02:06.4 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 10)

Revision history for this message
Matt Zimmerman (mdz) wrote : Re: [Bug 202490] Re: No driver for Ricoh R5C822 Xd card reader

On Wed, Oct 01, 2008 at 06:22:27AM -0000, Alex Maguran wrote:
> At least SD card not detected.

Not the same problem.

--
 - mdz

Revision history for this message
Alex Maguran (amaguran) wrote : Re: No driver for Ricoh R5C822 Xd card reader

> No the same problem

I thought I have the same problem as #276484, which is marked as duplicate of this one. Sorry, if this is not the case.

Revision history for this message
Dan The Man (onemanbanddan) wrote :

Now, I'm very new to this, but I've just done the 8.10 upgrade, and my lspci | grep ricoh output is identical to those listed above. Dell Vostro 1700.
Everything I've seen on the web in the last hour leads me to believe that it's impossible to read xd cards with a built in reader using gnu/linux.
(not very) Interestingly, I just put ubuntu on this machine this morning dual boot, and when I fired up xp pro, it told me 'Found new hardware: xd picture card reader'. It had always worked flawlessly before in xp on this box. I guess I'm just going to have to stick with windows, because microsoft, quite clearly, make far superior operating systems than this geek oriented linux nonsense.

Revision history for this message
stiv2k (stiv2k) wrote :

I can confirm the same problem with the same Ricoh chipset on:

HP Pavilion dv1657cl
HP Pavilion dv9009nr

Revision history for this message
Zaar Hai (haizaar) wrote :

Same here on Dell XPS m1330 Ubuntu 8.04

03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)

Changed in dell:
importance: Undecided → Wishlist
Revision history for this message
Yossi Gil (yossi-gil) wrote :

Same problem. Thinkpad T61 (which is not exactly the same as the T61).
SD card is read. But not an XD card..

Take note that the problem occurs in Windows as well, and an update from Lenovo is required.

See

http://www-307.ibm.com/pc/support/site.wss/MIGR-68053.html

Recent versions add more and more support for the XD card. Here is the summary from the Lenovo site:

Version 3.54.02

    * (New) Support for Dutch and Brazilian Portuguese installer program.
    * (Fix) Blue Screen on Death happens with System Enable/Disable with IO test on Windows Logo Kit (WLK) 1.1.

Version 3.52.02

    * (New) Added some SSID.
    * (New) Updated xD Icon design.
    * (Fix) The Memorystick and xD devcies don't work when the system memory exceeds 4GB.
    * (Fix) Kingston MMC plus 1GB might not work properly.
    * (Fix) SanDisk RS-MMC 1GB might not work properly.

Version 3.51.01

    * (New) Added some SSID/SVID for MS and xD x86 drivers.
    * (New) Summarized Windows Vista x86/x64 drivers.
    * (New) Supported uninstall feature on "Programs and features".
    * (New) Changed user interface of program installer.
    * (New) Added WHQL signature files for all drivers.
    * (New) Updated to support resource rebalancing for Windows Vista.
    * (Fix) It becomes impossible to access the xD-Picture card without rebooting the computer if once failing to recognize the card.
    * (Fix) Kingston RS-MMC 512MB isn't recognized on Windows Vista x64.
    * (Fix) Flash Media Card may not be recognized after booting the computer with a CardBus Card.

Revision history for this message
Pablo Estigarribia (pablodav) wrote :

I made many many test after upgrade to Interpid, I have no problems to work with SSD card on Interpid!!

Seems to be ok with kernel 2.6.27

Revision history for this message
Pablo Estigarribia (pablodav) wrote :

Sorry I wrote SSD card, but is MMC....

Revision history for this message
TomasHnyk (sup) wrote :

Pablo: do you have the same reader? Please post output of lspci.

Revision history for this message
Pablo Estigarribia (pablodav) wrote :

This is my lspci:

00:00.0 Host bridge: Intel Corporation Mobile PM965/GM965/GL960 Memory Controller Hub (rev 03)
00:02.0 VGA compatible controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 03)
00:02.1 Display controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 03)
00:1a.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #4 (rev 03)
00:1a.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #5 (rev 03)
00:1a.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #2 (rev 03)
00:1b.0 Audio device: Intel Corporation 82801H (ICH8 Family) HD Audio Controller (rev 03)
00:1c.0 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 1 (rev 03)
00:1c.1 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 2 (rev 03)
00:1c.2 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 3 (rev 03)
00:1d.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #1 (rev 03)
00:1d.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #2 (rev 03)
00:1d.2 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #3 (rev 03)
00:1d.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #1 (rev 03)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev f3)
00:1f.0 ISA bridge: Intel Corporation 82801HEM (ICH8M) LPC Interface Controller (rev 03)
00:1f.1 IDE interface: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) IDE Controller (rev 03)
00:1f.2 SATA controller: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) SATA AHCI Controller (rev 03)
01:04.0 FLASH memory: ENE Technology Inc ENE PCI Memory Stick Card Reader Controller
01:04.1 SD Host controller: ENE Technology Inc ENE PCI SmartMedia / xD Card Reader Controller
01:04.2 FLASH memory: ENE Technology Inc Memory Stick Card Reader Controller
01:04.3 FLASH memory: ENE Technology Inc ENE PCI Secure Digital / MMC Card Reader Controller
02:00.0 Network controller: Intel Corporation PRO/Wireless 3945ABG [Golan] Network Connection (rev 02)
03:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 01)

Revision history for this message
Mike (michael-calcano) wrote :

You don't have the same hardware, this bug affects the Ricoh reader.

Revision history for this message
Adrian Moya (adrianmoya) wrote : Re: [Bug 202490] Re: No driver for Ricoh R5C822 Xd card reader

I've been unable to read MemoryStick Cards with this reader on ubuntu
intrepid.

Revision history for this message
Chris Malley (mallux) wrote : Re: No driver for Ricoh R5C822 Xd card reader

Also on Acer Aspire 5720-602G16Mi (on special offer from Tesco direct so probably v. common):

# lspci -vv
...
07:00.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff) (prog-if ff)
 !!! Unknown header type 7f

(Intrepid 32-bit)

Revision history for this message
toneman77 (toni-eleftheriadis) wrote :

I dont know when this happened, but 2 minutes ago I put my card in the reader (Dell Vostro 1400) and it was instantly recognized.

$ uname -a
Linux tonesdell 2.6.27-7-generic #1 SMP Tue Nov 4 19:33:20 UTC 2008 i686 GNU/Linux

$ lspci |grep -i ricoh
03:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 05)
03:01.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
03:01.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
03:01.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)

thumbs up! Works for me now.

Revision history for this message
TomasHnyk (sup) wrote :

toneman77: what kind of card was that?

Revision history for this message
toneman77 (toni-eleftheriadis) wrote :

According to the text on my digital camera it's a SD HC card (Kingston 4GB premium pro)
It is/was the only card that was ever plugged into the card reader. Worked without problems in hardy, stopped working in intrepid.
I was only putting it in the card reader because I forgot that it didn't work in intrepid.

Revision history for this message
Andrea Piccinelli (frasten) wrote :

toneman77: it isn't the same bug: your card is a SD, but here we're talking about XDs.

Revision history for this message
toneman77 (toni-eleftheriadis) wrote :

Argh, my fault. sorry

Revision history for this message
Ozzyprv (ozzyprv) wrote :

same here, HP Pavillion dv9005ca, running Ibex.
lspci |grep -i ricoh
07:05.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller
07:05.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 19)
07:05.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 0a)
07:05.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 05)
07:05.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)

Revision history for this message
Ozzyprv (ozzyprv) wrote :

Sorry, I forgot to mention that I was trying a 4 GB MS (Pro)

Revision history for this message
ak (akameswaran-gmail) wrote :

Just updated to Intrepid 8.10 SD works, Sony 1GB MS (Pro) does not.

I have the same ricoh controller(s) from lspci.

Revision history for this message
Andy (acreech2330) wrote :

I am having the same problem. I have the ricoh controller. My SD card works, however my xD card does not work.

here is the output of lspci:

acreech@acreech-laptop:~$ lspci
00:00.0 RAM memory: nVidia Corporation MCP67 Memory Controller (rev a2)
00:01.0 ISA bridge: nVidia Corporation MCP67 ISA Bridge (rev a2)
00:01.1 SMBus: nVidia Corporation MCP67 SMBus (rev a2)
00:01.2 RAM memory: nVidia Corporation MCP67 Memory Controller (rev a2)
00:01.3 Co-processor: nVidia Corporation MCP67 Co-processor (rev a2)
00:02.0 USB Controller: nVidia Corporation MCP67 OHCI USB 1.1 Controller (rev a2)
00:02.1 USB Controller: nVidia Corporation MCP67 EHCI USB 2.0 Controller (rev a2)
00:04.0 USB Controller: nVidia Corporation MCP67 OHCI USB 1.1 Controller (rev a2)
00:04.1 USB Controller: nVidia Corporation MCP67 EHCI USB 2.0 Controller (rev a2)
00:06.0 IDE interface: nVidia Corporation MCP67 IDE Controller (rev a1)
00:07.0 Audio device: nVidia Corporation MCP67 High Definition Audio (rev a1)
00:08.0 PCI bridge: nVidia Corporation MCP67 PCI Bridge (rev a2)
00:09.0 IDE interface: nVidia Corporation MCP67 AHCI Controller (rev a2)
00:0a.0 Ethernet controller: nVidia Corporation MCP67 Ethernet (rev a2)
00:0c.0 PCI bridge: nVidia Corporation MCP67 PCI Express Bridge (rev a2)
00:0d.0 PCI bridge: nVidia Corporation MCP67 PCI Express Bridge (rev a2)
00:12.0 VGA compatible controller: nVidia Corporation GeForce 7000M (rev a2) (rev a2)
00:18.0 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] HyperTransport Technology Configuration
00:18.1 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Address Map
00:18.2 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] DRAM Controller
00:18.3 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Miscellaneous Control
01:04.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 05)
01:04.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
01:04.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
01:04.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
01:04.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)
05:00.0 Ethernet controller: Atheros Communications Inc. AR242x 802.11abg Wireless PCI Express Adapter (rev 01)

Matt Zimmerman (mdz)
description: updated
Revision history for this message
Jacobmg (jacobmg) wrote :

I have the same issue
 :09:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff) (prog-if ff)
 !!! Unknown header type 7f
I am concerned about my notebooks temperature running 8.10.

 I dual book this mobile machine with Vista x64 and KDE Ubuntu 8.10 64 bit. During my kubuntu sessions, my laptop runs very hot right where the Ricoh's peripheral interface is. At times my notebook has crashed, no movement whatsoever, only thing to alleviate is a hard shutdown. My fans are clean, my CPU is dynamically scaled, and during Vista sessions=normal operations.

 Would this "bug" cause my temperature issues or am I barking up the wrong tree?

Kind Regards
Jacob Griffin

Revision history for this message
Jacobmg (jacobmg) wrote :

P.S.

Asus F300sa-A1
Intel T7500 core2 duo @ 2.2Ghz
Ocz DDR2-667 x 4GB
Hitachi 160GB @5400
ATI Mobility Radeon HD2600

Revision history for this message
marcel (marcelunilsson) wrote :

xd doesent work on Lenovo N500 either... sd works fine here to.

Revision history for this message
Florian Heinle (tiax) wrote :

just adding the note to the bottom: there is no driver for any XD controller in the kernel. No need to confirm the bug on any further machines. Please keep this report free of noise so people can stay subscribed to actual progress

Revision history for this message
Michael Marley (mamarley) wrote :

Any chance of getting a fix for this?

Revision history for this message
Noel J. Bergman (noeljb) wrote :

> Any chance of getting a fix for this?

Support for the chip does not seem likely to come from Canonica, and I can think of a lot of other things I would prefer that they invest their time and money onl. xD media is not very popular. Were it not for a loaner of an Olympus camera at PADI Total Sub last year, I'd personally never know that this issue existed.

Recommendation: with all due apologies to my friends at Olympus, do not buy gear that uses xD media (or Memory Stick). Instead, go for SD/SDHC and/or Compact Flash. If you happen to have one of the two brands of cameras that use xD, or otherwise simply *must* have support for xD media, purchase a reader from Olympus or Fuji since the xD reader sold by them appears to be supported (q.v., http://alauda.sourceforge.net).

See also: http://en.wikipedia.org/wiki/XD-Picture_Card

Revision history for this message
Noel J. Bergman (noeljb) wrote :

> with all due apologies to my friends at Olympus, do not buy gear that uses xD media
> (or Memory Stick). Instead, go for SD/SDHC and/or Compact Flash.

By "uses", I mean "requires". And, to be clear, newer cameras from Olympus generally accept xD plus micro-SD and/or CF, so I'm not telling you to avoid the manufacturer, just xD only products.

Revision history for this message
Michael Marley (mamarley) wrote :

I was just wondering because sometimes other people must do presentations on my laptop, and sometimes they give me MS and xD cards, and I cannot read them.

Revision history for this message
Noel J. Bergman (noeljb) wrote :

Michael, if you simply must have support for xD then apparently you'll have to carry one of the two supported USB readers. Likewise for Sony Memory Stick, I see from looking around that there seem to be some supported readers, but our Ricoh reader is not one of them. If Sony Memory Stick support is an issue for you, please open a separate bug.

Revision history for this message
Armands (armandjohn) wrote :

Noel, Sony Memory Stick support is my issue (I don't use xD), and I DID open a separate bug; that bug was deemed a duplicate of this one and assimilated into it. How would you recommend I pursue this?

Revision history for this message
Noel J. Bergman (noeljb) wrote :

I would have left that as a separate bug, since although the underlying cause is the same (lack of a driver), I suspect that there would have to be two quite different and separate changes to support xD and Sony Memory Stick.

Revision history for this message
Armands (armandjohn) wrote :

I agree with your logic, Noel, but since I wasn't the one who merged the bugs, any suggestions on how I should proceed?

Revision history for this message
Noel J. Bergman (noeljb) wrote :

As I see it, THIS bug report should be about the need for an xD driver for the RICOH reader. Another bug should cover the Sony MemoryStick driver for this chipset.

Accordingly, it looks to me that Bug 238208, Bug 225274, and Bug 216937 should be separated, and perhaps made duplicates of one of them (e.g., 216937). I don't know, and the posters did not provide the information, whether or not those reports even use the same RICOH chipset.

I am separating out Bug 238208, and posted requests to the others to find out which chipset they use.

Noel J. Bergman (noeljb)
description: updated
Changed in dell:
status: Confirmed → Triaged
Revision history for this message
Motin (motin) wrote :

How hard is it to get hacking on a driver for this chipset?

As was the case for the Texas Instruments devices: "TI refused to publish a complete datasheet for any of the FlashMedia devices rendering them useless anywhere except M$ Windows"

Still, the tifmxx driver was and is being developed.

So, can this possibly be done for the Ricoh chipset? Maybe it's even possible to re-use code from the tifmxx driver (MS specifications, code structure etc)?

Project page TI driver:
http://developer.berlios.de/projects/tifmxx

Maybe someone can create a new project in launchpad for this driver, set up the basic driver files etc and at least get a dummy driver up that detects that a MS or xD card has been inserted into the bay - so that we at least can inform the uninformed user that "Sorry, but there are currently no available drivers for MemoryStick or xD cards for your built-in card reader"

What about that?

Revision history for this message
Jason (jpassow) wrote :

To say that the card is not popular enough to develop a driver and say there is no need to confirm the bug, seems like an oxymoron to me. If it is not a popular format then there should not be enough confirmations of this bug to interfere. So I propose that the format is more popular than Noel thinks (especially among amateur photo enthusiasts). And I second the notion that it would be beneficial to have a driver. For Linux to become main stream, you need to support as much integrated hardware as is possible. It seems a ridiculous suggestion that developing drivers for non-integrated devices is more worthwhile than developing a driver for an integrated device.

Revision history for this message
Martin Hammer (martin.hammer) wrote :

Agree with both points made by Jason. A cursory glance through the comments above shows a variety of hardware from big-name vendors (Acer, Asus, Dell, HP, Lenovo) - these guys clearly deemed the xD format sufficiently popular in merit inclusion of the card reader in their laptops. Failure to support built-in hardware out-of-the-box (or at all, as in this case) is a major obstacle to wider adoption of GNU/Linux.

Revision history for this message
Noel J. Bergman (noeljb) wrote :

The reason why "there is no need to confirm the bug" is because we know that the driver does not exist, and the fact that mass manufactured hardware exists means that there are people who have it. Remember: I have the same hardware, and the same missing driver. But are there enough to justify a major effort to reverse engineer an Open Source driver for closed, proprietary and IP constrained hardware? IMO, realistically unlikely, but should someone have an itch to scratch, please feel free.

This is the problem of closed hardware. The xD specification is controlled by Olympus, and (perhaps the good news is that) even they are moving to support SD in their newer cameras. I'll commit to talking with contacts at Olympus when I see them in May and see what, if anything, they have to say.

Revision history for this message
Noel J. Bergman (noeljb) wrote :

Oh, and Jason, we can count the size of the subscriber list (and presumably those who are effected by the bug") to get a count of "me, too" parties. :-)

Martin, they all use the same Ricoh chip for a whole range of things, including SD, MMC. MS, xD and Firewire, so that is not necessarily an endorsement of xD. Nor is the presence of the Ricoh-provided driver on MS-Windows an indicator of widespread support. If Ricoh really wants their chip supported, they can provide code and/or detailed specs.

Revision history for this message
van_zwier (levinga) wrote :

I agree, with Jason. If there is not enough support for the bug, then why can I, in almost every shop, buy a laptop with a device that supports XD?

I have a camera with an XD-card, a laptop with a device for XD, witch i'm going to use for at least 2 or 3 years, and yes i would really like to use it with my linux-ubuntu software, instead of buying an other device to workaround the problem.

Revision history for this message
Jason (jpassow) wrote :

The subscriber list would only include those that have subscribed (obviously). I wish to put forth that there are MANY more (including me until today) that have not subscribed but maybe bookmarked the page or have not yet found the page. If I had the know how I would code it if I could. If there is a any way that I can help including testing, or trying to talk to a manufacturer, or anything please let me know.

Revision history for this message
Missamilou (missamilou) wrote :

Well... Unfortunately, I can't afford to buy a new camera, so it looks like i either need to revert to Windows (I dread the thought) or buy a USB reader. I guess this problem is why Dell are now issuing their laptops with the Ricoh 3-in-1 reader for SD, MMS etc. NOT XD cards. I imagine that they found they had the same problems when creating Dell-buntu but instead of complaining to Ricoh and getting a bit of help srapped the idea of the 5-in-1 or perhaps Ricoh found the problem first and created the 3-in-1 instead. Who knows. Either way... looks like all us XD owners are "Without a Paddle" LOL :-S

Revision history for this message
Robb Munson (r.munson) wrote :

Just a reminder to all:

*** NOTE: this is a *wishlist* item - a request for new functionality. This issue is a request to have MemoryStick support added for a specific, and somewhat popular, chipset. Please do not add "me, too" items. We know that it doesn't work. If you want, please add yourself as a subscriber, and click on link to indicate that "This bug effects me, too"

Revision history for this message
Robb Munson (r.munson) wrote :

I am aware it says this above our wishlist item, but I wanted to make sure everyone had ample opportunities to read the text.

Revision history for this message
L Duperval (lduperval) wrote :

I would like to point out that a few weeks ago, I was given an HP dv6xxx loaner while my laptop was being repaired. That laptop had managed to read xD and Sony Duo cards to my great surprise, actually. I thought it was because I had installed Jaunty on the loaner, whereas I was running Intrepid on my laptop.

When I received the laptop, I installed Jaunty on it but it did not recognized the xD nor the ProDuo cards.

The reason I mention this is because it's possible to read xD cards with Ubuntu. The thing is, I don't know what card reader was on the loaner. :(

Revision history for this message
Ryan C. Underwood (nemesis-icequake) wrote : Re: [Bug 202490] Re: [Feature Request] Provide a driver for Ricoh R5C822 xD card reader

It was most likely a reader that is attached using USB internally. Such
readers work fine. It is system-bus-connected readers like the Ricoh
that are not supported yet.

--
Ryan C. Underwood, <email address hidden>

fony (four-baladewa)
Changed in linux (Debian):
assignee: nobody → fony (four-baladewa)
status: Confirmed → New
Revision history for this message
Reloweb (reloweb) wrote :

This bug affects me too. I have Ubuntu 9.10 on Dell Studio 1557

Santiago M. Mola (smola)
Changed in linux (Debian):
status: New → Confirmed
Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

I had written a driver for this device.

Please look at linux-mtd maling list for patches

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Here is the pathset against 2.6.33-rc3
It won't apply to older kernels.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Apart from fixes, this pathset contains two drivers
One is the lowlevel driver, and second is high level generic driver (FTL) on top of it.

I have plans for memstick driver too.

Revision history for this message
Michael Marley (mamarley) wrote :

You are a hero, Maxim Levitsky! Are you trying to get this included upstream? You should.

Revision history for this message
Michael Marley (mamarley) wrote :

It is failing to compile. I get:

drivers/built-in.o: In function `sm_remove_dev':
sm_ftl.c:(.text+0xc8ddc): undefined reference to `del_mtd_blktrans_dev'
drivers/built-in.o: In function `sm_add_mtd':
sm_ftl.c:(.text+0xc9da8): undefined reference to `add_mtd_blktrans_dev'
drivers/built-in.o: In function `sm_module_init':
sm_ftl.c:(.init.text+0x69eb): undefined reference to `register_mtd_blktrans'
drivers/built-in.o: In function `sm_module_exit':
sm_ftl.c:(.exit.text+0x7e6): undefined reference to `deregister_mtd_blktrans'

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Very strange.

What kernel you patch?
could you send me .config

Could you try to compile both drivers as a module?

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Did patch apply cleanly?

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

I know what happened, this is small bug in Kconfig.
For now, just select also the 'NAND SSFDC (SmartMedia) read only translation layer'.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Or apply this patch:

Revision history for this message
Michael Marley (mamarley) wrote :

Ok, I applied the patch and now it is working fine. Thanks!

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@Michael Marley

Could you tell me how well my driver is working?
What sizes are xD cards you use.

Also I want again to tell to everybody, that this is experimental driver, Please don't use it with valuable data.
Best first to back the data up with some usb card reader.

Memstick driver is in very early stages of development. I might be able to publish first version after a month.

I did contact upstream. In fact I talked with them even before I began writting it.
Unfortunelly mtd subsystem has very few maintainers, and they are friendly but very busy.

If everything goes well, this driver might be in 2.6.34.

Revision history for this message
Michael Marley (mamarley) wrote :

I don't actually have any xD cards on hand right now, but I will check when I get a chance.

Revision history for this message
komputes (komputes) wrote :

This issue is also mentioned in Bug #247819

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

New, slightly updated version.

Changed in linux (Ubuntu):
assignee: nobody → Maxim Levitsky (maximlevitsky)
Changed in dell:
assignee: nobody → Maxim Levitsky (maximlevitsky)
Revision history for this message
Alan Cárdenas (alancv86) wrote :

Hello, how do i install that driver? thanks.

Revision history for this message
Noel J. Bergman (noeljb) wrote :

Maxim, I have an xD card, so if you can support Lucid with this (I won't ask you to go back to Karmic), I'll be happy to test.

And, yes, I suppose I can try it against the mainline kernel from http://kernel.ubuntu.com/~kernel-ppa/mainline/?C=M;O=D.

Have you considered providing a PPA for testing?

Revision history for this message
fony (four-baladewa) wrote :

i'm wanna have debian for sharing with my friends in my campus

tags: added: patch
Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

This driver was just merged to linux-mtd tree, and soon will be merged upstream, and will appear in 2.6.34

I will backport it to 2.6.32 too soon.

As for creating ppa, I guess I won't have time for that, I soon will be very busy.

The memstick driver I am creating passed first milestone of 'reading full dump of the card'
It is still a userspace application that I mostly use to poke at registers to understand their meaning.

Also, if you own jmicron xD reader, there is a driver for it written by Alex Dubov. It isn't usable in its current form, because I implemented everything very differently (to fit existing infrastructure), but it can be used as a reference for a driver.
When I finish my semester, I will write the memstick, and xD driver for the jmicron controller.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

I of course mean memstick driver for ricoh device, Alex did write a memstick driver for jmicron device and it is merged upstream.

Revision history for this message
Chase Douglas (chasedouglas) wrote :

@Maxim Levitsky:

Just so you are aware, we generally prefer changes to come into Ubuntu through the linux-2.6-stable kernel tree. If you are aiming to get the driver into Lucid, I suggest creating a series of patches against the current linux-2.6.32.y branch of the -stable tree. If your modifications do not change existing code (i.e. they only add code to the kernel), then there's a greater chance it will be accepted into the -stable tree. If it is accepted into the -stable tree it will get pulled into the Lucid kernel automatically. See the Documentation/stable_kernel_rules.txt file in the kernel tree for more details about the -stable tree process.

If your driver is not accepted into the -stable tree, we may still be able to include it in the Lucid kernel, but the first step is to try to get it into the -stable tree.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@Chase Douglas this isn't going to be accepted to -stable tree.

I do a lot of changes to existing subsystem (mtd) to fix bugs and make it work with xD readers.

Revision history for this message
Khairul Aizat Kamarudzzaman (fenris) wrote :

any good result in lucid ? still waiting for the driver ... MMC still not working in my Thinkpad T61 using Lucid ..

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@Khairul Aizat Kamarudzzaman

You don't need my driver for mmc cards.

You need to load ricoh-mmc module to enable mmc cards via standard SDHCI controller.

If you need to read xD card, then you need my driver.

Folks, anybody tested my driver?

About upstream inclusion, my driver didn't make in 2.6.34, but will be for sure in 2.6.35

Revision history for this message
Noel J. Bergman (noeljb) wrote :

@Maxim,

"Folks, anybody tested my driver?" A month ago you indicated that "I will backport it to 2.6.32 too soon." Did you? If so, where?

Revision history for this message
Khairul Aizat Kamarudzzaman (fenris) wrote :

@maxim .. recompile kernel ?

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@Noel J. Bergman. Fair enough. I should have done that aready.

@Khairul Aizat Kamarudzzaman: I guess so.

The git tree that contains all my patches and will be merged in next kernel is at

http://git.infradead.org/mtd-2.6.git

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Here is ported version to 2.6.32.
Tested on ubuntu lucid kernel.

This package includes my driver and minimal mtd subsystem.

Just download it, do

make
sudo make install
sudo make load

I also included in that package a nice icon for xD cards, and udev rule to make them work better with devicekit
Dont be afraid if the card isn't auto-mounted, because that is bug in devicekit. It unfortunately hardcodes which devices to mount automatically.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Now I ported & tested the driver on 2.6.31 (9.10 kernel)

This package should work on all kernels from 2.6.31

Note that before you load that driver, you need to unload 'ricoh-mmc' driver, because it conflicts with this driver.
Proper fix included in 2.6.34, and to apply the fix to older kernel, you must patch the kernel.
(The fix removes that module, and moves its code to the kernel itself)

Revision history for this message
jerzy (jpiter) wrote :

I tried to add your driver to kernel 2.6.31.21 and after sudo make load I got following message:
root@laptop:/home/compilacja/xd# sudo make load
modprobe r852
FATAL: Error inserting r852 (/lib/modules/2.6.31-21-generic/extra/nand/r852.ko): Unknown symbol in module, or unknown parameter (see dmesg)
make: *** [load] Błąd 1

dmesg:
[ 989.082087] sm_common: disagrees about version of symbol nand_scan_ident
[ 989.082091] sm_common: Unknown symbol nand_scan_ident

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Is this stock ubuntu kernel?

If not, please make sure that mtd subsystem isn't compiled in the kernel.

Revision history for this message
jerzy (jpiter) wrote :

This kernel was installed from ubuntu 9.10 repository, during upgrade system.

Revision history for this message
jerzy (jpiter) wrote :

I noticed following error during compilation, maybe it's responsible for above:

 /home/compilacja/xd/mtdcore.c:274: warning: initialization from incompatible pointer type
  CC [M] /home/compilacja/xd/mtdsuper.o
  CC [M] /home/compilacja/xd/mtdbdi.o
  CC [M] /home/compilacja/xd/mtdpart.o
  LD [M] /home/compilacja/xd/mtd.o
  CC [M] /home/compilacja/xd/mtd_blkdevs.o
/home/compilacja/xd/mtd_blkdevs.c: In function ‘add_mtd_blktrans_dev’:
/home/compilacja/xd/mtd_blkdevs.c:335: warning: assignment discards qualifiers from pointer target type
  CC [M] /home/compilacja/xd/mtdblock.o
  CC [M] /home/compilacja/xd/ssfdc.o
  CC [M] /home/compilacja/xd/sm_ftl.o
/home/compilacja/xd/sm_ftl.c: In function ‘sm_erase_block’:
/home/compilacja/xd/sm_ftl.c:487: warning: passing argument 2 of ‘kfifo_put’ discards qualifiers from pointer target type
include/linux/kfifo.h:79: note: expected ‘unsigned char *’ but argument is of type ‘const unsigned char *’
/home/compilacja/xd/sm_ftl.c: In function ‘sm_init_zone’:
/home/compilacja/xd/sm_ftl.c:898: warning: passing argument 2 of ‘kfifo_put’ discards qualifiers from pointer target type
include/linux/kfifo.h:79: note: expected ‘unsigned char *’ but argument is of type ‘const unsigned char *’
  Building modules, stage 2.

Revision history for this message
Tony Espy (awe) wrote :

Changing status to WontFix in the Dell project.

Changed in dell:
status: Triaged → Won't Fix
Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@jerzy, these error messages are nothing to worry about, just missing casts between const and non-const variables. It only happens on 2.6.32

I think I know what was going on.

Please run 'depmod -a', and then try to load the module again.
I would suggest you to read some HOWTOs on how to load and compile kernel modules.

Basicly what the lines:

[ 989.082087] sm_common: disagrees about version of symbol nand_scan_ident
[ 989.082091] sm_common: Unknown symbol nand_scan_ident

mean is that module sm_common (which r852 depends on) can find function nand_scan_ident which I know is defined in nand.ko

So you can try to load module 'nand' manually.

Revision history for this message
jerzy (jpiter) wrote :

Well, I tried 'depmod -a, and i load manually 'nand' module situation without change.
I'll try to use your driver on ubuntu lucid when it'll be stable.

greetings

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@jerzy

Lucid won't help you here, you seem to be unable to load my driver (actually a set of modules, three mine, rest from mtd subsystem), and it seems not to work.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Please give output of

modinfo nand

Revision history for this message
jerzy (jpiter) wrote :

jerzy@laptop: ~jerzy@laptop:~$ modinfo nand
filename: /lib/modules/2.6.31-21-generic/kernel/drivers/mtd/nand/nand.ko
description: Generic NAND flash driver code
author: Steven J. Hill <email address hidden>, Thomas Gleixner <email address hidden>
license: GPL
srcversion: AC46E9FAAC09EEFF7E2EF35
depends: nand_ecc,mtd,nand_ids
vermagic: 2.6.31-21-generic SMP mod_unload modversions 586

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@jerzy

Then modprobe still tries to use ubuntu's mtd drivers.

Do you have '/lib/modules/2.6.31-21-generic/extra' with drivers inside?
If so, you might remove, or move it to some other place the
'/lib/modules/2.6.31-21-generic/kernel/drivers/mtd'

And then run 'depmod -a' (with sudo of course)

Then look what 'modinfo nand' shows. If it sees it in '/lib/modules/2.6.31-21-generic/extra...' then try to load my driver again, if that fails, reboot your system and try again (this is easiest way to unload already loaded modules)

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

I mean again that you need to remove/move the
'/lib/modules/2.6.31-21-generic/kernel/drivers/mtd'

Revision history for this message
jerzy (jpiter) wrote :

I did what you said, your version of nand is loaded:
jerzy@laptop:~$ modinfo nand
filename: /lib/modules/2.6.31-21-generic/extra/nand/nand.ko
description: Generic NAND flash driver code
author: Steven J. Hill <email address hidden>, Thomas Gleixner <email address hidden>
license: GPL
srcversion: 361572BB0B1AECACD855D92
depends: nand_ecc,mtd,nand_ids
vermagic: 2.6.31-21-generic SMP mod_unload modversions 586

but the error during loading driver is the same

jerzy@laptop:~$ sudo modprobe r852
FATAL: Error inserting r852 (/lib/modules/2.6.31-21-generic/extra/nand/r852.ko): Unknown symbol in module, or unknown parameter (see dmesg)

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@jerzy, can you join some irc channel?

Revision history for this message
jerzy (jpiter) wrote :

@Maxim
I could on Monday, just tell what channel and what time

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@jerzy

I can't be online at Monday due to studies.

I am on freenode and oftc.
Best for this is #mtd on oftc.net

There is some conflict in loading the modules.

Revision history for this message
Noel J. Bergman (noeljb) wrote :

@Maxim,

> Here is ported version to 2.6.32

My apologies for not getting to it sooner. I actually hadn't seen the e-mail notice when you posted the code. I've built and tested your driver on Lucid, and it seems to work fine. :-) I'll try to get my hands on an Olympus camera, and make sure that it is happy with media processed by them.

Revision history for this message
Wojciech Aniszewski (pentahedron) wrote : Re: [Bug 202490] Re: [Feature Request] Provide a driver for Ricoh R5C822 xD card reader

Hi Maxim,
I tested the driver in 2.6.31-21, seems to work, i.e. dmesg is giving
reasonable output when I plug an XD card in. But I cannot mount it :)
I seem to not know which device it is. Do you mind hinting me what
should I put into /etc/fstab?

Thanks for all your work.
wojtek

2010/4/12, Noel J. Bergman <email address hidden>:
> @Maxim,
>
>> Here is ported version to 2.6.32
>
> My apologies for not getting to it sooner. I actually hadn't seen the
> e-mail notice when you posted the code. I've built and tested your
> driver on Lucid, and it seems to work fine. :-) I'll try to get my
> hands on an Olympus camera, and make sure that it is happy with media
> processed by them.
>
> --
> [Feature Request] Provide a driver for Ricoh R5C822 xD card reader
> https://bugs.launchpad.net/bugs/202490
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in The Dell Project: Won't Fix
> Status in “linux” package in Ubuntu: Confirmed
> Status in “linux” package in Debian: Confirmed
>
> Bug description:
> *** NOTE: this is a *wishlist* item - a request for new functionality. At
> present, and perhaps forever, xD support on linux is extremely limited.
> This issue is a request to have xD support added for a specific, and
> somewhat popular, chipset. Please do not add "me, too" items. We know that
> it doesn't work. If you want, please add yourself as a subscriber, and
> click on link to indicate that "This bug effects me, too" In the meantime,
> there are two xD readers known to work with linux, so if you simply must
> have xD support, those would be your options.
>
> ------------------------------------------------
>
> On multi-format card readers such as:
>
>> lspci | grep Ricoh
> 03:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev
> 05)
> 03:01.1 Generic system peripheral [0805]: Ricoh Co Ltd R5C822
> SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
> 03:01.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
> 03:01.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter
> (rev 12)
> 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)
>
> SD and MMC cards work, but Xd cards do not. This appears to be due to a
> lack of driver support for the Xd reader.
>
> There is no need to comment confirming this issue on more laptops. Every
> laptop with a similar type of reader will be affected.
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/dell/+bug/202490/+subscribe
>

--
Pentahedron - A polyhedron having five faces. Because there are two
pentahedral graphs, there are two convex pentahedra, namely the square
pyramid and the triangular prism. The triangular prism is the unique
convex pentahedra having unit edge lengths.

(Eric W. Weisstein. "Pentahedron." From MathWorld--A Wolfram Web
Resource. http://mathworld.wolfram.com/Pentahedron.html)

Revision history for this message
Jerone Young (jerone) wrote :

@Wojciech
             This sounds a lot like the udev with hdparm. Try removing file /lib/udev/rules.d/85-hdparm (place it somewhere else). Reboot and see if it works?

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@Wojciech Aniszewski

my driver consists of two parts, r852, the lowlevel driver,
and sm_ftl the high level driver that provides xD compatable FTL.

The udev rule I gave should load the sm_ftl after a card is detected by r852. If its isn't loaded "lsmod | grep sm_ftl"
try to load sm_ftl manually (modprobe sm_ftl).

The device that you can mount is /dev/smblka

Best regards,
     Maxim Levitsky

Revision history for this message
Wojciech Aniszewski (pentahedron) wrote :

@Maxim.
Both r852 and sml_ftl are present (i see them in lsmod).
Nevertheless, /dev/smblka you mentioned does not exist.

@Jerone.
I did that, no effect.

Regards

2010/4/14, Maxim Levitsky <email address hidden>:
> @Wojciech Aniszewski
>
> my driver consists of two parts, r852, the lowlevel driver,
> and sm_ftl the high level driver that provides xD compatable FTL.
>
> The udev rule I gave should load the sm_ftl after a card is detected by
> r852. If its isn't loaded "lsmod | grep sm_ftl"
> try to load sm_ftl manually (modprobe sm_ftl).
>
> The device that you can mount is /dev/smblka
>
> Best regards,
> Maxim Levitsky
>
> --
> [Feature Request] Provide a driver for Ricoh R5C822 xD card reader
> https://bugs.launchpad.net/bugs/202490
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in The Dell Project: Won't Fix
> Status in “linux” package in Ubuntu: Confirmed
> Status in “linux” package in Debian: Confirmed
>
> Bug description:
> *** NOTE: this is a *wishlist* item - a request for new functionality. At
> present, and perhaps forever, xD support on linux is extremely limited.
> This issue is a request to have xD support added for a specific, and
> somewhat popular, chipset. Please do not add "me, too" items. We know that
> it doesn't work. If you want, please add yourself as a subscriber, and
> click on link to indicate that "This bug effects me, too" In the meantime,
> there are two xD readers known to work with linux, so if you simply must
> have xD support, those would be your options.
>
> ------------------------------------------------
>
> On multi-format card readers such as:
>
>> lspci | grep Ricoh
> 03:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev
> 05)
> 03:01.1 Generic system peripheral [0805]: Ricoh Co Ltd R5C822
> SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
> 03:01.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
> 03:01.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter
> (rev 12)
> 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)
>
> SD and MMC cards work, but Xd cards do not. This appears to be due to a
> lack of driver support for the Xd reader.
>
> There is no need to comment confirming this issue on more laptops. Every
> laptop with a similar type of reader will be affected.
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/dell/+bug/202490/+subscribe
>

--
Pentahedron - A polyhedron having five faces. Because there are two
pentahedral graphs, there are two convex pentahedra, namely the square
pyramid and the triangular prism. The triangular prism is the unique
convex pentahedra having unit edge lengths.

(Eric W. Weisstein. "Pentahedron." From MathWorld--A Wolfram Web
Resource. http://mathworld.wolfram.com/Pentahedron.html)

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@Wojciech Aniszewski

Thank you very much for testing.
First of all, try to remove and add the card.
I have seen that nand core very rarely doesn't detect it.

Then try to load the drivers with debug=1 (both r582 and sm_ftl support it)
And then see what you get in the logs.

What xD card you use?
(Is it type M or not, and what size is it)

If you could join irc 5 hours from that post, (I am MaximLevitsky on freenode and oftc), we could do some debugging.

The above is of course true for anybody that wants to test my driver.

description: updated
Revision history for this message
Wojciech Aniszewski (pentahedron) wrote :
Download full text (6.1 KiB)

Sorry, I couldn't join the channel back then.
I'll be happy to try later, will look for you.
When I put the card out and in:
----(code 1)
$dmesg
[...]
[73418.876071] r852: card removed
[74172.784059] r852: detected xD writeable card in slot
[74173.088094] NAND device: Manufacturer ID: 0x98, Chip ID: 0xd5
(Toshiba SmartMedia 4MiB 3,3V ROM)
----
As far as writings on it say, its FujiFilm XD H 2GB card.

With debug=1, only difference seems to be that r852 prints
---(code 2)
[80148.517617] r852 0000:03:01.4: PCI INT B disabled
[80165.105581] r852 0000:03:01.4: PCI INT B -> GSI 18 (level, low) -> IRQ 18
---
after being modprobed. After that comes the same data as in (code 1).

best reagards
wojtek

2010/4/15, Maxim Levitsky <email address hidden>:
> ** Description changed:
>
> *** NOTE: this is a *wishlist* item - a request for new functionality.
> At present, and perhaps forever, xD support on linux is extremely
> limited. This issue is a request to have xD support added for a
> specific, and somewhat popular, chipset. Please do not add "me, too"
> items. We know that it doesn't work. If you want, please add yourself
> as a subscriber, and click on link to indicate that "This bug effects
> me, too" In the meantime, there are two xD readers known to work with
> linux, so if you simply must have xD support, those would be your
> options.
> +
> + Now there is an xD driver for this chip.
> + Supports kernel from 3.6.32.
> + (http://launchpadlibrarian.net/42999924/ricoh_xd-2.tar.bz2)
> +
> + To install please do ./make && sudo make install && sudo make load
> +
> + Note that this package installs several kernel modules, similar to
> compat-wireless
> + So, make sure that there is no conflict between existing mtd modules and
> these.
> +
> + *NOTE* If you use kernel lower that 2.6.34, please be sure to unload the
> ricoh-mmc driver.
> + It conflicts with this driver.
> + This does meant that on this kernel you *can't* use both xD and MMC cards
> + To be sure that ricoh-mmc is not loaded, you should see the following
> output:
> +
> + 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev
> + 12)
> +
> + and NOT:
> +
> + 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev
> + FF)
> +
>
> ------------------------------------------------
>
> On multi-format card readers such as:
>
> > lspci | grep Ricoh
> 03:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller
> (rev 05)
> 03:01.1 Generic system peripheral [0805]: Ricoh Co Ltd R5C822
> SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
> 03:01.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev
> 12)
> 03:01.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host
> Adapter (rev 12)
> 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev
> 12)
>
> SD and MMC cards work, but Xd cards do not. This appears to be due to a
> lack of driver support for the Xd reader.
>
> There is no need to comment confirming this issue on more laptops.
> Every laptop with a similar type of reader will be affected.
>
> --
> [Feature Request] Provide a driver for Ricoh R5C822 xD card reader
> https...

Read more...

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@Wojciech Aniszewski

Thanks for testing.
Well you found first bug.

My driver thinks that your card is 4 MB SmartMedia card (this was predecessor of xD),
But it shares same ID with your card.

For now, find file sm_common.c

and delete line

 {"SmartMedia 4MiB 3,3V ROM", 0xd5, 512, 4, 0x2000, NAND_ROM},

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

An update for that fixes the above bug (should :-) )

description: updated
description: updated
Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Can I kindly ask you to test latest version?

Revision history for this message
Wojciech Aniszewski (pentahedron) wrote :
Download full text (3.4 KiB)

Hello Maxim.
Yes, it works like a charm within Gnome and using 2.6.31-21.
Two days ago I tried it without nautilus and gvfs (I use Ion3 on daily
basis), I got some errors but now I see that gnome manages just fine.
Anyway, thanks very much, it's up and running !

2010/4/19, Maxim Levitsky <email address hidden>:
> Can I kindly ask you to test latest version?
>
> --
> [Feature Request] Provide a driver for Ricoh R5C822 xD card reader
> https://bugs.launchpad.net/bugs/202490
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in The Dell Project: Won't Fix
> Status in “linux” package in Ubuntu: Confirmed
> Status in “linux” package in Debian: Confirmed
>
> Bug description:
> *** NOTE: this is a *wishlist* item - a request for new functionality. At
> present, and perhaps forever, xD support on linux is extremely limited.
> This issue is a request to have xD support added for a specific, and
> somewhat popular, chipset. Please do not add "me, too" items. We know that
> it doesn't work. If you want, please add yourself as a subscriber, and
> click on link to indicate that "This bug effects me, too" In the meantime,
> there are two xD readers known to work with linux, so if you simply must
> have xD support, those would be your options.
>
> Now there is an xD driver for this chip.
> Supports kernel from 3.6.31.
> (http://launchpadlibrarian.net/44373795/ricoh_xd_3.tar.bz2)
>
> To install please do ./make && sudo make install && sudo make load
>
> Note that this package installs several kernel modules, similar to
> compat-wireless
> So, make sure that there is no conflict between existing mtd modules and
> these.
>
> *NOTE* If you use kernel lower that 2.6.34, please be sure to unload the
> ricoh-mmc driver.
> It conflicts with this driver.
> This does meant that on this kernel you *can't* use both xD and MMC cards
> To be sure that ricoh-mmc is not loaded, you should see the following
> output:
>
> 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)
>
> and NOT:
>
> 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev FF)
>
> ------------------------------------------------
>
> On multi-format card readers such as:
>
>> lspci | grep Ricoh
> 03:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev
> 05)
> 03:01.1 Generic system peripheral [0805]: Ricoh Co Ltd R5C822
> SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
> 03:01.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 12)
> 03:01.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter
> (rev 12)
> 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)
>
> SD and MMC cards work, but Xd cards do not. This appears to be due to a
> lack of driver support for the Xd reader.
>
> There is no need to comment confirming this issue on more laptops. Every
> laptop with a similar type of reader will be affected.
>
>
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/dell/+bug/202490/+subscribe
>

--
Pentahedron - A polyhedron having five faces. Because there are two
pentahedral graphs, there are two convex pentahedra, namely...

Read more...

Revision history for this message
jerzy (jpiter) wrote :

I managed to start your driver under Lucid, I replaced original "nand_ecc.ko", "nand_ids.ko", "nand.ko", "mtd_blkdevs.ko"
"mtdblock.ko", "mtd.ko", "ssfdc.ko" with compiled from your package. Of course I'd done back up original files. After reboting system everything works perfectly. I don't see any conficts, SD card works fine too. For the time the only inconveniance is the fact that the XD icon you mentioned above doesn't show in my gnome bar (tool mounting disks). After inserting XD card I only see blank button. By the way I use 2 GB XD H card so I removed the line: "{"SmartMedia 4MiB 3,3V ROM", 0xd5, 512, 4, 0x2000, NAND_ROM}" from sm_common.c before compiling.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@jerzy. you probably use different icon style that default?

I also use lucid.
If you didn't do make install, you should copy udev rule I provided to /lib/udev/rules.d
It should then make udisk ask for 'gnome-dev-media-xd',which I provide.

I put the icon in '/usr/share/icons/Humanity/devices/16', '/usr/share/icons/Humanity/devices/32' and '/usr/share/icons/Humanity/devices/48'

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Maybe you can even put it in ~/.icons

But don't forget to remove -16 -32 or -48 suffix from the icon

Revision history for this message
jerzy (jpiter) wrote :

I did make install during installation. I checked icons directory /usr/share/... File with picture is present, I checked also udev rules wich also exist in /lib/udev/rules.d. It helped to copy icon to ~/.icons directory.

Revision history for this message
jerzy (jpiter) wrote :

I use 24 bit color depth, and can't use 32 because I have graphics card Intel X3100 (GM965) and default ubuntu driver doesn't support such depth. Probably that is why I hadn't seen the icon.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@jerzy

24 and 32 bit depths are exactly the same
The icons I created are SVG, and the suffix is its recommended size, not bit depth.
(SVG is supposed to be scalable, but in practicable, its not....)

I think you just use non default icon theme.
But anyway this is really minor issue.
Thanks for testing

Revision history for this message
Noel J. Bergman (noeljb) wrote :

> I'll try to get my hands on an Olympus camera, and make sure that it is happy with media processed by them.

Worked perfectly. I spent the past week diving with Olympus loaner cameras, and the driver worked fine with the older models that still used xD media.

Thanks for the effort, Maxim! I know that xD is a dead format, but there are still people using it, who will appreciate all of the work you've done!

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Now the driver is committed upstream to what will became 2.6.35
Since ubuntu 10.10 is will be based on this kernel, I guess soon I could close this bug

Revision history for this message
Jerone Young (jerone) wrote :

@Maxim
             Best to wait to close. What you wan to ensure is once the 2.6.35 kernel is pulled in for 10.10 that the kernel config option to enable the driver is enabled.

Revision history for this message
Misosofos (misosofos) wrote :

It doesn't work :(

Changed in linux (Ubuntu):
assignee: Maxim Levitsky (maximlevitsky) → Misosofos (misosofos)
Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@Misosofos could you explain why?

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

we figured out what problem was, and I want to repeat to *anyone* here listening:

If you have kernel below 2.6.34, you need to:

Unload and blacklist ricoh_mmc module.
To do so:

sudo modprobe -r ricoh_mmc

and then add
blacklist ricoh_mmc to
/etc/modprobe.d/blacklist.conf

This will make it impossible to use MMC cards, update the kernel if you want to use both.

(You can load that module manually to temporally regain ability to read MMC cards)

Changed in linux (Ubuntu):
assignee: Misosofos (misosofos) → Maxim Levitsky (maximlevitsky)
Revision history for this message
Ayrton Santana (ayrton) wrote :

ayrton ~ $ -> lspci | grep JMicron
04:00.0 System peripheral: JMicron Technology Corp. SD/MMC Host Controller
04:00.2 SD Host controller: JMicron Technology Corp. Standard SD Host Controller
04:00.3 System peripheral: JMicron Technology Corp. MS Host Controller
04:00.4 System peripheral: JMicron Technology Corp. xD Host Controller

List that my reader supports xD Cards however it doesn't.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote : Re: [Bug 202490] Re: [Feature Request] Provide a driver for Ricoh R5C822 xD card reader

On Sun, 2010-05-23 at 18:27 +0000, Ayrton Araujo wrote:
> ayrton ~ $ -> lspci | grep JMicron
> 04:00.0 System peripheral: JMicron Technology Corp. SD/MMC Host Controller
> 04:00.2 SD Host controller: JMicron Technology Corp. Standard SD Host Controller
> 04:00.3 System peripheral: JMicron Technology Corp. MS Host Controller
> 04:00.4 System peripheral: JMicron Technology Corp. xD Host Controller
>
> List that my reader supports xD Cards however it doesn't.
>

I have that reader too, and Alex Dubov wrote an xD driver for it.
It isn't compatable with modern kernels.

In future I rewrite his driver and make this xD reader work.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Due to unexpected turn of events (sometimes it pays to ask a question) I was told that mmc controller that ricoh-mmc disables in fact is almost standard sdhci controller.

Therefore I patched the sdhci kernel driver and now it binds to both sdhci and mmc devices and therefore allows you to use sd,sdhi,mmc and xD cards at same time.

The driver modified to compile under 10.4 kernel is attached.

To use first unload the ricoh-mmc (if you didn't already)

$ sudo modprobe -r ricoh_mmc

To make this permanent blacklist it (if you didn't already)
to do so:

$ echo ricoh_mmc | sudo tee /etc/modprobe.d/blacklist_ricoh_mmc.conf

Now compile & install:

$ make
$ sudo make install

Unload current driver:
$ modprobe -r sdhci_pci
$ modprobe -r sdhci

assure that new driver is seen
to do so ensure that you see the 'extra':

$ modinfo sdhci-pci | grep filename
filename: /lib/modules/2.6.32-18-generic/extra/sdhci-pci.ko

Now load patched driver: (on next boot it will be loaded automaticly)
$ modprobe -r sdhci_pci
$ modprobe -r sdhci

note that due to bug (you probably seen it) don't try to suspend the system while sd/sdhc/mmc card is in slot
This just hands the system
I know the cause, but fix is far from trivial.
(Its not my fault)

Revision history for this message
alx5000 (alx5000) wrote : Re: [Bug 202490] Re: [Feature Request] Provide a driver for Ricoh R5C822 xD card reader
Download full text (4.2 KiB)

Maxim, thank you for all your work and your attention to this thread and the
people waiting for this feature.

On Thu, Jun 3, 2010 at 6:13 PM, Maxim Levitsky <email address hidden>wrote:

> Due to unexpected turn of events (sometimes it pays to ask a question) I
> was told that mmc controller that ricoh-mmc disables in fact is almost
> standard sdhci controller.
>
> Therefore I patched the sdhci kernel driver and now it binds to both
> sdhci and mmc devices and therefore allows you to use sd,sdhi,mmc and xD
> cards at same time.
>
> The driver modified to compile under 10.4 kernel is attached.
>
> To use first unload the ricoh-mmc (if you didn't already)
>
> $ sudo modprobe -r ricoh_mmc
>
> To make this permanent blacklist it (if you didn't already)
> to do so:
>
> $ echo ricoh_mmc | sudo tee /etc/modprobe.d/blacklist_ricoh_mmc.conf
>
> Now compile & install:
>
> $ make
> $ sudo make install
>
> Unload current driver:
> $ modprobe -r sdhci_pci
> $ modprobe -r sdhci
>
>
> assure that new driver is seen
> to do so ensure that you see the 'extra':
>
> $ modinfo sdhci-pci | grep filename
> filename: /lib/modules/2.6.32-18-generic/extra/sdhci-pci.ko
>
>
> Now load patched driver: (on next boot it will be loaded automaticly)
> $ modprobe -r sdhci_pci
> $ modprobe -r sdhci
>
>
> note that due to bug (you probably seen it) don't try to suspend the system
> while sd/sdhc/mmc card is in slot
> This just hands the system
> I know the cause, but fix is far from trivial.
> (Its not my fault)
>
>
> ** Attachment added: "mmc-sd-sdhci.tar.gz"
> http://launchpadlibrarian.net/49613807/mmc-sd-sdhci.tar.gz
>
> --
> [Feature Request] Provide a driver for Ricoh R5C822 xD card reader
> https://bugs.launchpad.net/bugs/202490
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in The Dell Project: Won't Fix
> Status in “linux” package in Ubuntu: Confirmed
> Status in “linux” package in Debian: Confirmed
>
> Bug description:
> *** NOTE: this is a *wishlist* item - a request for new functionality. At
> present, and perhaps forever, xD support on linux is extremely limited.
> This issue is a request to have xD support added for a specific, and
> somewhat popular, chipset. Please do not add "me, too" items. We know that
> it doesn't work. If you want, please add yourself as a subscriber, and
> click on link to indicate that "This bug effects me, too" In the meantime,
> there are two xD readers known to work with linux, so if you simply must
> have xD support, those would be your options.
>
> Now there is an xD driver for this chip.
> Supports kernel from 3.6.31.
> (http://launchpadlibrarian.net/44373795/ricoh_xd_3.tar.bz2)
>
> To install please do ./make && sudo make install && sudo make load
>
> Note that this package installs several kernel modules, similar to
> compat-wireless
> So, make sure that there is no conflict between existing mtd modules and
> these.
>
> *NOTE* If you use kernel lower that 2.6.34, please be sure to unload the
> ricoh-mmc driver.
> It conflicts with this driver.
> This does meant that on this kernel you *can't* use both xD and MMC cards
> To be sure that ricoh-mmc is not loa...

Read more...

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

This is updated backport of mmc subsystem.

Not only this version binds and works correctly with mmc cards without need of mmc disabler, but it also contains a fix for hangs on suspend/resume. Now you can suspend and resume the system with the card normally.

Changed in linux (Ubuntu):
status: Confirmed → Fix Committed
description: updated
Revision history for this message
Misosofos (misosofos) wrote :

What if we installed previous version? Can we just run this script, or we
need to whitelist the mmc kernel module?

Thank you.

On Sat, Jun 12, 2010 at 12:55 AM, Maxim Levitsky <email address hidden>wrote:

> ** Description changed:
>
> *** NOTE: this is a *wishlist* item - a request for new functionality.
> At present, and perhaps forever, xD support on linux is extremely
> limited. This issue is a request to have xD support added for a
> specific, and somewhat popular, chipset. Please do not add "me, too"
> items. We know that it doesn't work. If you want, please add yourself
> as a subscriber, and click on link to indicate that "This bug effects
> me, too" In the meantime, there are two xD readers known to work with
> linux, so if you simply must have xD support, those would be your
> options.
>
> Now there is an xD driver for this chip.
> Supports kernel from 3.6.31.
> (http://launchpadlibrarian.net/44373795/ricoh_xd_3.tar.bz2)
>
> + The driver is now in Maverick's kernel.
> + You still need the udev rule to load FTL part of it.
> +
> + Or just add sm_ftl to /etc/modules.
> +
> To install please do ./make && sudo make install && sudo make load
>
> Note that this package installs several kernel modules, similar to
> compat-wireless
> So, make sure that there is no conflict between existing mtd modules and
> these.
>
> *NOTE* If you use kernel lower that 2.6.34, please be sure to unload the
> ricoh-mmc driver.
> It conflicts with this driver.
> This does meant that on this kernel you *can't* use both xD and MMC cards
> To be sure that ricoh-mmc is not loaded, you should see the following
> output:
> + You can use a modified sdhci driver for mmc cards I attached.
> + Unfortunately this driver won't help on Mavaric kernel (my fault :-( )
>
> 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev
> 12)
>
> and NOT:
>
> 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev
> FF)
>
> ------------------------------------------------
>
> On multi-format card readers such as:
>
> > lspci | grep Ricoh
> 03:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller
> (rev 05)
> 03:01.1 Generic system peripheral [0805]: Ricoh Co Ltd R5C822
> SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
> 03:01.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev
> 12)
> 03:01.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host
> Adapter (rev 12)
> 03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev
> 12)
>
> SD and MMC cards work, but Xd cards do not. This appears to be due to a
> lack of driver support for the Xd reader.
>
> There is no need to comment confirming this issue on more laptops.
> Every laptop with a similar type of reader will be affected.
>
> --
> [Feature Request] Provide a driver for Ricoh R5C822 xD card reader
> https://bugs.launchpad.net/bugs/202490
> You received this bug notification because you are a direct subscriber
> of the bug.
>

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@Misosofus, I didn't understand what you mean.

The modified sdhci driver I just published allows you to use mmc cards without ricoh_mmc.
It just uses it the same way windows does

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package linux - 2.6.35-3.4

---------------
linux (2.6.35-3.4) maverick; urgency=low

  [ Andy Whitcroft ]

  * debian -- ensure the version number is clean

  [ Henrik Rydberg ]

  * [Upstream] Introduce MT event slots (rev 5)
  * [Upstream] Document the MT event slot protocol (rev5)
  * [Upstream] (evdev) Use multi-reader buffer to save space (rev4)
  * [Upstream] (evdev) Convert to dynamic event buffer (rev4)
  * [Upstream] (evdev) Use driver hint to compute the evdev buffer size
    (rev2)

  [ Leann Ogasawara ]

  * Revert "SAUCE: Add MODULE_ALIAS for Dell WMI module"
  * Revert "SAUCE: hostap: send events on data interface as well as master
    interface"
  * Revert "Fix webcam having USB ID 0ac8:303b"
  * Revert "SAUCE: toshiba_acpi -- pull in current -dev version of driver"
  * rebase to v2.6.35-rc3

  [ Maxim Levitsky ]

  * [Config] Enable new Smartmedia/xD translation layer
    - LP: #202490

  [ Upstream Kernel Changes ]

  * net: fix deliver_no_wcard regression on loopback device

  [ Upstream changes ]

  * rebased to v2.6.35-rc3
 -- Leann Ogasawara <email address hidden> Thu, 10 Jun 2010 16:15:22 -0700

Changed in linux (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

Just note that 'Fix isn't yet fully released'

That is driver won't load automatically, so you need the udev rule that I have in my package.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

This patch adds the udev rule to load my driver automatically.
It was posted on linux-hotplug@vger, but no reaction yet.

It is still not enough for out of box experience.
Another rule for udisk in needed.

Revision history for this message
Misosofos (misosofos) wrote :

I tried to patch with patch -p0 < filename

In which folder is necessary to put the patch file?

On Wed, Jun 23, 2010 at 6:31 PM, Maxim Levitsky <email address hidden>wrote:

> This patch adds the udev rule to load my driver automatically.
> It was posted on linux-hotplug@vger, but no reaction yet.
>
>
> It is still not enough for out of box experience.
> Another rule for udisk in needed.
>
> ** Attachment added: "[PATCH]_Add_autodetection_for_xD_cards"
>
> http://launchpadlibrarian.net/50808643/%5BPATCH%5D_Add_autodetection_for_xD_cards
>
> --
> [Feature Request] Provide a driver for Ricoh R5C822 xD card reader
> https://bugs.launchpad.net/bugs/202490
> You received this bug notification because you are a direct subscriber
> of the bug.
>

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

You don't need it.
As you probably already know my driver consists on 2 parts, a lowlevel driver r852, and it is loaded automatically,
and high-level sm_ftl which implements wear leveling according to xD standard.

The problem is that sm_ftl isn't loaded automatically.
(In the package I provided, there is an udev rule that loads the ftl automatically)

This patch does the same but in generic and clean way.
It is intended to patch udev sources.

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

This udev patch is now included in udev-158.
I hope maveric will use it.

The only thing that isn't 'working' yet, (and you probably noticed it) is that xD card isn't automounted.

This is partially thanks to this piece of hardcoded code (devicekit and its friends are full of this junk):

                      if (g_strcmp0 (connection_interface, "usb") == 0 ||
                          g_strcmp0 (connection_interface, "firewire") == 0 ||
                          g_strcmp0 (connection_interface, "sdio") == 0 ||
                          gdu_device_is_optical_disc (drive_device))
                        {
                          volume->should_automount = TRUE;
                        }

in package 'gvfs', gvfs/monitor/ggduvolume.c

Revision history for this message
Roman Krylov (volyrkr) wrote :

Tested my xd ricoh reader with 2.6.35 mainline - had to modprobe ssfdc it manually since I did not find udev rule in the package for it. Found a rule for sm_ftl only. It works now, thank you so much!

Revision history for this message
Maxim Levitsky (maximlevitsky) wrote :

@Roman Krylov, note that you can use sm_ftl too.
ssfdc is read only driver. Very safe though.

sm_ftl is read/write driver. It works ok here. It is of course (as anything that is RW) a bit less safe.

Changed in udev (Ubuntu):
status: New → Fix Released
Revision history for this message
jerzy (jpiter) wrote :

maxim, could you tell when your driver is going to be included in main stream linux kernel?

Revision history for this message
Sukochev Roman (Leolik) (leolik) wrote :

> On Sun, 2010-05-23 at 18:27 +0000, Ayrton Araujo wrote:
>> ayrton ~ $ -> lspci | grep JMicron
>> 04:00.0 System peripheral: JMicron Technology Corp. SD/MMC Host Controller
>> 04:00.2 SD Host controller: JMicron Technology Corp. Standard SD Host Controller
>> 04:00.3 System peripheral: JMicron Technology Corp. MS Host Controller
>> 04:00.4 System peripheral: JMicron Technology Corp. xD Host Controller
>>
>> List that my reader supports xD Cards however it doesn't.
>>
>
> I have that reader too, and Alex Dubov wrote an xD driver for it.
> It isn't compatable with modern kernels.
>
> In future I rewrite his driver and make this xD reader work.
>

Hello Maxim, when you can rewrite driver for JMicron reader? Thanks.

Revision history for this message
Ubuntu QA Website (ubuntuqa) wrote :

This bug has been reported on the Ubuntu laptop testing tracker.

A list of all reports related to this bug can be found here:
http://laptop.qa.ubuntu.com/qatracker/reports/bugs/202490

tags: added: laptop-testing
Changed in somerville:
assignee: nobody → Maxim Levitsky (maximlevitsky)
importance: Undecided → Wishlist
status: New → Won't Fix
no longer affects: dell
Revision history for this message
Timothy R. Chavez (timrchavez) wrote :

The bug task for the somerville project has been removed by an automated script. This bug has been cloned on that project and is available here: https://bugs.launchpad.net/bugs/1305865

no longer affects: somerville
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.