This is the bug/patch tracker for Rockbox. Click here for more information.
Quick links: Bugs · Patches · Rockbox frontpage
FS#9545 - Storage cleanup and multi-driver support
Attached to Project:
Rockbox
Opened by Frank Gevaerts (fg) - Wednesday, 12 November 2008, 22:42 GMT+2
Last edited by Frank Gevaerts (fg) - Saturday, 18 July 2009, 00:47 GMT+2
Opened by Frank Gevaerts (fg) - Wednesday, 12 November 2008, 22:42 GMT+2
Last edited by Frank Gevaerts (fg) - Saturday, 18 July 2009, 00:47 GMT+2
|
DetailsThis patch add HAVE_MULTIDRIVE as opposed to HAVE_MULTIVOLUME. It also mostly implements multi-driver support.
This has not been tested yet. Still to do: - update usb_storage.c properly - finish multi-driver iplementation (maybe just #define NUM_DRIVES storage_num_drives(), not clear yet - handle NUM_VOLUMES and NUM_DRIVES properly (allocate NUM_VOLUMES*NUM_DRIVES filesystems, and loop accordingly?) - test Longer-term multi-driver open issues: - storage_*() that don't take a drive argument currently get "broadcasted" to all drivers. It's not clear if that is the right thing to do in all cases - The current implementation doesn't allow flexibility in deciding which is the primary drive. |
Closed by Frank Gevaerts (fg)
Saturday, 18 July 2009, 00:47 GMT+2
Reason for closing: Accepted
Additional comments about closing: Committed as r21933
Saturday, 18 July 2009, 00:47 GMT+2
Reason for closing: Accepted
Additional comments about closing: Committed as r21933
- some small fixes
- still totally untested
This will be split in separate MULTIVOLUME vs MULTIDRIVE and multidriver patches before commit
NUM_VOLUMES in the HAVE_MULTIDRIVE case is still not finalised
- Some small fixes
- Tested on ipod mini in ATA+RAMDISK configuration. The ramdisk is accessible over USB, but not in the file browser. This could be an issue with it not being formatted on first boot.
With my Code Police hat on, I don't think storage.c should be "compacted" so much though, even if has many repeated lines. Whitespace is reader friendly.
Actually I want to split the patch to separate the multivolume confusion from the multi-driver work.
Confirmed working on Onda VX747.
- add storage.c which was missing from v5
- fix HAVE_HOTSWAP typo
- fix warnings in storage.c
- add missing stubs to TCC NAND driver
Tested working on Cowon D2 with SD and NAND drivers (see
FS#10415).btw. this only compiled on my D2 build because I had added sd.c elsewhere in SOURCES while hacking around previously... doh!
If we make *num_drives accept a parameter (e.g. int sd_num_drives(int first_drive)), and storage_init() passes num_drives to all drivers, it should work I think
FS#10415).EDIT: Fixed hunk that shouldn't have been present...