# O2Micro 4-in-1 MemoryCardBus Controller and its Card Reader

## casso

Hi,

I'm sure this question gets posted a lot on a lot of forums. It's quite simple really.

I have a O2 Micro 0Z711M1/MC1 4-in-1 Memory CardBus Controller. It has support for using PCMCIA cards, and also has a built-in card reader, suitable for MMC, SD and Memory Stick Duo. It does a few other cards as well, and has a few other nice features.

I don't have any use for the PCMCIA side of things at present. What I do have a use for is the card reader. All I want to be able to do is to use the card reader under Linux to copy confidential information onto an SD card. SD cards are much easier to hide than a thumb drive would be, but if I just can't use it, well then too bad.

My logic tells me to load both yenta_socket for the PCMCIA side of things, then to load the mmc_core and mmc_block modules to cover the MMC/SD part. Suprise, suprise, this does not resolve my issue.

Windows doesn't have any trouble finding the inserted SD card and says that it is a PCMCIA/IDE device for memory. So maybe this might help to explain a few things.

If there is any other information I can give, then please ask. It just has me stumped.

----------

## forgotten1

These are two threads in the forums, the first may not be relevant, but the second probably is:

SD card under Gentoo Linux

SD Card Reader not detected

The obvious things to check for are:

1.  PCMCIA support configured in the kernel

2.  MMC support configured in the kernel

As the second post identifies, do you also have SCSI support built in, or as a module?

When you boot with any of the install CDs with an MMC card inserted, does it get recognized?

There is an 02micro driver at www.musclecard.com, but I believe it's only for reading smartcards, additionally, there is a bug listed for it on bugzilla, but there is as yet no maintainer identified.

----------

## Boesmann

 *forgotten1 wrote:*   

> There is an 02micro driver at www.musclecard.com

 

This site appears to be dead....

I have the same problem and did quite a lot of research   :Rolling Eyes: 

The company 02 claims, that there will be a Linux driver soon, but they keep claiming that since 2000 or so, so I am not too confident about this...

Some people seem to have got it working somehow..I think with the help of pcmcia-utils. I read a post about it in the Gentoo-forums the other day, but I seem to have lost the link   :Embarassed:  .

Good Luck, if I find the solution again I will tell you!

EDIT:

Weird...the site IS actually working..it seems like my browser had died.

Anyway, I got the drivers and I got the ebuild; strange thing is, the drivers will only work with kernel >=2.6 and the ebuild is dependent on pcmcia-cs while I was told that pcmcia-cs IS NOT compatible with kernels >=2.6   :Confused: 

I will try it anyway tonight...will tell you on monday if it worked (no internet at home).

----------

## casso

Thanks for the feedback.

1. I do have SCSI support enabled in the kernel, MMC_core, MMC_block and yetna_socket. These were all built as modules and loaded.

2. The LiveCD does not recognise the SD Card upon insertion. I did add pcmcia to the loading process and checked the ouptut of dmesg, but saw nothing change.

3. I know very little about pcmcia-cs or pcmcia-utils in general. I did NOT enable any of these through init scripts on the liveCD. I don't really know enough to know what I should be doing there anyway.

I would like to get some information on using some of these tools mentioned above so I have more of an idea about what I am doing. It would also help if I get a PCMCIA card of some sort in the future, but I will also look around the forums for help on that if/when the time comes.

After reading the posts given above, most users opted for an external card reader. My system is a laptop that has a built-in card reader that is very convinent if it works. If I can't use it under linux, I would rather use USB because my only use for reading the card does not relate to photos. It is an SD card, not an MMC card that I am using. I can easily purchase an MMC card instead, but I don't want to if I don't have to.

I may have to try the probe all LUNs option, but I would assume that the LiveCDs have this option enabled.

From Boesmann:

 *Quote:*   

> I will try it anyway tonight...will tell you on monday if it worked (no internet at home).

 

I will look forward to this reply.

Michael Cassaniti

----------

## Boesmann

So, I tried to compile the O2-drivers from www.musclecard.com (which were produced in cooperation with the company, at least it seems so), but unfortunately they are disfunct crap.

Tried with several ebuilds and 'by hand', but the results were the same. Compilation dies with a bunch of error messages.

Seems like the driver tries to use some kernel-pcmcia-functions that do not exist (...but this was not the only error).

They claim to have tested the driver with kernel 2.6.13 but I won't downgrade my kernel just to try...

Luckily I own an external USB-12-in-one-CardReader and it works just fine. I tried SD, MMC and MemoryStickPro so far and they all work perfectly.

Regarding my internal reader I will just wait...maybe someone will write a real driver somewhen (...unfortunately I'm not good at programming).

Sorry that I don't have better news...

----------

## casso

Not to worry, I will be waiting as well I gather.

I am not that good at programming. I should be better at C since I am an undergraduate computer engineer on my way to designing embedded systems.

I am under the impression that if the yenta-socket module was modified to include support for this portion of a PCMCIA chip, then any PCMCIA card reader of a similar design could be used with Linux, providing they all followed some sort of standard, that I doubt would happen. Hence a kernel module built against the current sources would be the way to go, but not many of us are that keen on programming to get out there and write it, or able to get the specifications easily to implement this effectively.

I guess I will conclude the same as everyone else. Under linux, at least at the present time, a driver to use the card reader in an O2Micro, specifically the 0Z711M1 is not available. An external card reader is necessary, or the use of Windows   :Rolling Eyes:  are the alternatives for this.

I haven't given up though. If anyone can find something useful, or thinks that pressuring the developers of the hardware may create a suitable driver for linux, then let me know.

----------

## Boesmann

I found some additional information on this site:

http://archives.neohapsis.com/archives/dev/muscle/2006-q2/0251.html

Apparently it works for kernels <=2.6.15.

----------

## casso

Thanks, will test.

Can't say that this one is solved yet. If a new modified driver for >=2.6.16 is released, then I can say that we are done.

Thanks again,

Michael Cassaniti

----------

## Boesmann

According to this thread

https://forums.gentoo.org/viewtopic-t-321878.html

the next kernel-version 2.6.17 will have full support for every card-reader. CAn't tell if it's true, though...let's just hope!

----------

## bandreabis

I tryed to use vanilla2.6.17 but without any luck. TexasInstruments card reader didn't work.  :Sad: 

Andrea

----------

## sonaatti

I have the same card-reader and spent a couple of weeks on it without any luck, it compiled cleanly but just didn't work, it should create a device /dev/ozxlr (something like this) but doesn't.

The O2-driver from the muscle page works with 0Z711M3 but not 0Z711M1, all we can do is hope.

** update **

Cant find any support in 2.6.17.

----------

## forgotten1

There's positive movement in the bug

There's reportedly been success with kernels >= 2.6.16, but a patch has to be applied. I haven't had the time yet to test.  When I get around to it, I'll report the results.

----------

