# PCIxx21 Integrated FlashMedia Controller don't work

## nandelbosc

Hi all!

I have SD card reader in by notebook ACER TravelMate 3000, but after many time trying to work, it still don't.

lshw output:

```

           *-storage UNCLAIMED

                description: Mass storage controller

                product: PCIxx21 Integrated FlashMedia Controller

                vendor: Texas Instruments

                physical id: 7.3

                bus info: pci@06:07.3

                version: 00

                width: 32 bits

                clock: 33MHz

                capabilities: storage bus_master cap_list

                resources: iomemory:b0114000-b0115fff irq:11

```

have any ideas? Thank's!

----------

## Gusar

What have you tried to do already? And have you seen this?  You might want to try with a 2.6.18-rc kernel, the sdhci module has been greatly improved compared to 2.6.17.

----------

## Condex

I've followed this setup, and got card reader working (al least with a 32 MB SD Card I used to test):

http://gentoo-wiki.com/HARDWARE_Gentoo_Acer_Ferrari_4005WLMi_Manual#FlashMedia

A few notes:

-After copying modules to /lib/modules/2.6.17-gentoo-r4 directory and doing a modules-update I can't modprobe the modules.

-So I went to the dir and inserted them using insmod, following the order in the site (core, sd, 7xx1), and they run ok, /dev node was created as soon as I insert SD card.

-Autoloading modules doesn't work, so I wrote a little initscript (/etc/init.d/flashmedia) in order to load them @ boot. Here is script code, if you want to use it, you need to copy tifm_core.ko, tifm_sd.ko and tifm_7xx1.ko modules to /lib/modules/<kernel version>/FlashMedia/:

```

#!/sbin/runscript

depend() {

        need localmount

}

load_fm() {

        cd /lib/modules/`uname -r`/FlashMedia/

        insmod tifm_core.ko

        if [ $? -eq 0 ]; then

                einfo "Core Module Inserted"

        else

                ewarn "Core Module Insertion Error"

                return 1

        fi

        insmod tifm_sd.ko

        if [ $? -eq 0 ]; then

                einfo "SD Module Inserted"

        else

                ewarn "SD Module Insertion Error"

                return 1

        fi

        insmod tifm_7xx1.ko

        if [ $? -eq 0 ]; then

                einfo "7xx1 Module Inserted"

        else

                ewarn "7xx1 Module Insertion Error"

                return 1

        fi

        return 0

}

start() {

        ebegin "Configuring FlashMedia Card Reader"

        load_fm

        eend $?

}

unload_fm() {

        rmmod tifm_7xx1

        rmmod tifm_sd

        rmmod tifm_core

        return 0

}

stop() {

        ebegin "Shutting down FlashMedia Card Reader"

        unload_fm

        eend $?

}

restart() {

        ebegin "Restarting FlashMedia Card Reader"

        unload_fm

        load_fm

        eend $?

}

```

Maybe someone with more knowledge than me can write a better script... Or guess why can't I modprobe the modules...

I've also tested the SD card on KDE, it works ok. When I insert the card, KDE daemon asks what to do, as it does with CD's, DVD's...

Hope you find it useful...

Condex-   :Cool: 

----------

## sidious

 *Quote:*   

> -After copying modules to /lib/modules/2.6.17-gentoo-r4 directory and doing a modules-update I can't modprobe the modules.
> 
> -So I went to the dir and inserted them using insmod, following the order in the site (core, sd, 7xx1), and they run ok, /dev node was created as soon as I insert SD card. 

 

same here on my Acer Extensa 3001 WLMi....

I testet it with vanilla-sources 2.6.17.11

```

tar xvjf tifm-06b.tar.bz2

make

cp tifm* /lib/modules/<kernel-version>/

modprobe mmc_core

modprobe mmc_block

insmod /lib/modules/<kernel-version>/tifm_core.ko

insmod /lib/modules/<kernel-version>/tifm_sd.ko

insmod /lib/modules/<kernel-version>/tifm_7xx1.ko

```

... it works! (tested with 128MB SD-Card)  :Very Happy: 

I tried it before with the SDHCI drivers in the 2.6.17 and 2.6.18 kernels, but without succes....

https://forums.gentoo.org/viewtopic-t-477695-highlight-pcixx21.html?sid=2725bc2b78cac45b56aa5c34cfc8d21d

I hope the tifm-driver will be part of the kernel soon....

----------

## sidious

I solved the "modprobe-problem" (using tifm-0.6b.tar.bz2)

1. boot the kernel you want to compile the modules for

2. go to the directory you extracted tifm-0.6 to

3. execute: make && make install

5. modprobe tifm_core, tifm_sd, tifm_7xx1

the modules are installed to /lib/modules/`uname r`/misc (see Makefile)...

not tested if auto-loading (putting them into /etc/modules.autoload.d/kernel-2.6) the modules at boot works, but it should...

----------

## Condex

I've tested the drivers with a 32 MB SD card, and they work ok.

After testing it with a 1 GB SD card, I've got some "corruption" problems. If I try to transfer a large amount of data,say 300 or 400 MB, CPU usage goes to 100%, rendering my computer almost useless. I don't know if it's a drivers problem or a KDE problem (it looks like it transfers all data in background). KDE doesn't allow me to unmount the drive after copying data. A few times, after removing the card I had problems with it (card is plugged in a GP2X console), sometimes I can't delete data (using the GP2X) or access some files.

Read tests (SD Card -> Computer) seem to run ok. It's writing what is problematic.

Condex-   :Cool: 

----------

## okapi

My Flashmedia is working at last with tifm-0.6d on my Toshiba A100 SK9.

Good job!

----------

## msch

tifm-06b works with my Toshiba a100-233, but one-time. when i insert mmc card, i get nodes. but when ejected and inserted once again, there are no nodes /dev/mmc* :/

----------

## Insanity5902

all three modules to get the TI card readers to work are now in the 2.6.19 kernel ... woohoo

----------

