Workaround for suspend/resume SD card problems

AVee openmoko-comunity at avee.org
Tue Aug 26 18:38:19 CEST 2008


On Monday 25 August 2008 17:10, Simon Matthews wrote:
> With my 8G Sandisk SD card, i can reliably fix the problems i have been
> having by turning on the SD clock all the time. To do this type the
> command
> echo 1 > /sys/module/glamo_mci/parameters/sd_idleclk
> then do something that will access the SD card before doing a suspend.
>
> This of course won't do the GPS much good, but i think the real fix
> might be to give the SD card more clock cycles before and after commands
> to give it time to finish executing commands.

Depending on your usage of the SD card you could also workaround the issue 
with a few symlinks. When the card is wrongly mounted just add symlinks to 
the new location of the content of the card in /media/card/. Once you did 
that /media/card will either contain the contents of the card (before 
suspend) or valid symlinks to the content of the card (after suspend) which 
works just as well.

To succesfully use this you should make sure the contents of the root 
directory of your card don't change, and it's no good when you are switching 
cards all the time. But when your card contains just a few directories in the 
root (like mine) it works perfectly. 

AVee

-- 
A man with one watch knows what time it is.
A man with two watches is never quite sure.




More information about the community mailing list