a56f1ca1ed
When using variadic macros there's no need for IF_MD2/IF_MV2 to deal with function parameters. IF_MD/IF_MV are enough. Throw in IF_MD_DRV/ID_MV_VOL that return the parameter if MD/MV, or 0 if not. Change-Id: I7605e6039f3be19cb47110c84dcb3c5516f2c3eb |
||
---|---|---|
.. | ||
ata-sim.c | ||
autoconf.h | ||
main.c | ||
Makefile | ||
README | ||
test.sh | ||
test16.sh |
This code is for testing the Rockbox fat code on a dummy drive image file. Dummy image ----------- Here's how to create a 1 gig dummy drive image in linux: # dd if=/dev/hda of=disk.img bs=1M count=1024 You can then format disk.img as a FAT32 partition: # mkdosfs -F 32 disk.img To mount the image, your linux kernel must include the loopback device: # mount -o loop disk.img /mnt/image Now copy some test data to the disk, umount it and start testing. The test script mounts the disk image in order to initialize it will a number of dummy files. Since users are no longer allowed to mount loopback devices, you can either run the test script as root (not recommended) or add a line to your fstab file: /path/to/disk.img /mnt/dummy vfat loop,users,noauto 0 0 Test code --------- The files in this dir build the 'fat' program. It will read 'disk.img' and treat is as a real disk, thanks to the ata-sim.c module. Modify the main.c source code to make it perform the tests you want.