Petr Vanek wrote:
> I have spent a while googling this up and have no wiki skills but
> someone might find this useful:
> to make FR act as a memory stick, here is what my script does:
> #!/bin/sh                                                                     
> /etc/init.d/networking stop
> rmmod g_ether
> modprobe g_file_storage file=/dev/mmcblk0p1
> --
> Petr Vaněk
very cool, but before I test it out (potentially breaking my usb 
networking in the process), I have a couple of questions:

1. will this persist over a reboot, or will it revert back to being an 
ethernet gadget when I reboot?

2. is the following sufficient to switch it back?

rmmod g_file_storage
modprobe g_ether
ifup usb0

(assuming I replaced '/etc/init.d/networking stop' with 'ifdown usb0' as 
recommended by Daniel)

3. can somebody point me to a resource for the g_file_storage module 
where I can learn more about it? I did a couple of quick googles but 
didn't see anything promising. specifically I'd like to know more about 
the file parameter - I assume that in this scenario our "usb stick" is 
using partition/device information from /dev/mmcblk0p1, and will be 
partitioned in the same way as the SD card? what If I wanted to have my 
home directory accessible in "usb stick" mode?


Openmoko community mailing list

Reply via email to