Difference between revisions of "Didj and Explorer MMC Patch"

From eLinux.org
Jump to: navigation, search
m
Line 1: Line 1:
 
The original source code for the MMC drivers that were released for the LX were not completed but lucky for us there was a patch included that finishes them to a usable state.
 
The original source code for the MMC drivers that were released for the LX were not completed but lucky for us there was a patch included that finishes them to a usable state.
 +
 +
 +
'''Notice: Hot swapping is not supported yet and may lead to data loss in the event that the card is not unmounted before it is removed.'''
 +
  
 
Here are the files you will need
 
Here are the files you will need
Line 7: Line 11:
  
 
to apply these patches just copy them to /drivers/mmc/host/
 
to apply these patches just copy them to /drivers/mmc/host/
and type the fallowing
+
and type the following
  
 
  patch lf1000_mmc.c < mmc_patch_lf1000-sdio.patch
 
  patch lf1000_mmc.c < mmc_patch_lf1000-sdio.patch
Line 21: Line 25:
 
it is best to copy them to /lib/modules/2.6.31-leapfrog/kernel/drivers/mmc/
 
it is best to copy them to /lib/modules/2.6.31-leapfrog/kernel/drivers/mmc/
  
when you want to mount a card simply
+
when you want to mount a card simply type
 
   
 
   
 
  modprobe /lib/modules/2.6.31-leapfrog/kernel/drivers/mmc/host/lf1000_mmc.ko
 
  modprobe /lib/modules/2.6.31-leapfrog/kernel/drivers/mmc/host/lf1000_mmc.ko
 
  modprobe /lib/modules/2.6.31-leapfrog/kernel/drivers/mmc/card/mmc_block.ko
 
  modprobe /lib/modules/2.6.31-leapfrog/kernel/drivers/mmc/card/mmc_block.ko
  
you will then see something like the fallowing
+
you will then see something like the following
 
  mmcblk0: mmc0:0002 00000 3.82 GiB
 
  mmcblk0: mmc0:0002 00000 3.82 GiB
 
  mmcblk0:
 
  mmcblk0:
Line 38: Line 42:
  
 
  umount /dev/mmcblk0p1
 
  umount /dev/mmcblk0p1
 
Notice: Hot swapping is not supported yet and may lead to data loss in the event that the card is not unmounted before it is removed.
 
  
 
much thanks to zucchini for the help
 
much thanks to zucchini for the help

Revision as of 01:28, 27 July 2010

The original source code for the MMC drivers that were released for the LX were not completed but lucky for us there was a patch included that finishes them to a usable state.


Notice: Hot swapping is not supported yet and may lead to data loss in the event that the card is not unmounted before it is removed.


Here are the files you will need (Located on Moogle's server for now) mmc_patch_Kconfig.patch mmc_patch_lf1000-sdio.patch

to apply these patches just copy them to /drivers/mmc/host/ and type the following

patch lf1000_mmc.c < mmc_patch_lf1000-sdio.patch
patch Kconfig < mmc_patch_Kconfig.patch

now when you do a make menuconfig build the MMC drivers as modules then

make -j Number of cpu cores+1  
sudo make modules_install

and your modules will be in /lib/modules/2.6.31-leapfrog on your system ready for you to copy them over

it is best to copy them to /lib/modules/2.6.31-leapfrog/kernel/drivers/mmc/

when you want to mount a card simply type

modprobe /lib/modules/2.6.31-leapfrog/kernel/drivers/mmc/host/lf1000_mmc.ko
modprobe /lib/modules/2.6.31-leapfrog/kernel/drivers/mmc/card/mmc_block.ko

you will then see something like the following

mmcblk0: mmc0:0002 00000 3.82 GiB
mmcblk0:
p1

to mount the card type

mount /dev/mmcblk0p1 /mnt

and you have access to the files on your micro sd card now in the /mnt directory

to unmount the card simply type

umount /dev/mmcblk0p1

much thanks to zucchini for the help