summaryrefslogtreecommitdiff
path: root/rbutil/ipodpatcher/ipodio.h
diff options
context:
space:
mode:
authorDave Chapman <dave@dchapman.com>2007-06-16 22:32:57 +0000
committerDave Chapman <dave@dchapman.com>2007-06-16 22:32:57 +0000
commit56780e3e417cb1b9d1d453592d58c988c8029c16 (patch)
tree78cf5d5ebb36348932bc7f425a107d838b656fe9 /rbutil/ipodpatcher/ipodio.h
parent9e0dfa1a533206200d2fcc87113417d8676e8fd7 (diff)
downloadrockbox-56780e3e417cb1b9d1d453592d58c988c8029c16.tar.gz
rockbox-56780e3e417cb1b9d1d453592d58c988c8029c16.zip
Initial integration of a --format option, based on fat32format.exe. The main limitation is that it only works on disks with 512-byte sectors - it needs adapting to the 2048-byte sector ipods. It has only been tested on Linux and Mac OS X, with a 60GB ipod Color, but appears to work.... When this feature has been more widely tested, the intention is to add code to convert the information in an Apple Partition Map (which can currently be read by ipodpatcher) to a DOS partition table, and hence allow conversion of Macpods to Winpods.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13643 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'rbutil/ipodpatcher/ipodio.h')
-rw-r--r--rbutil/ipodpatcher/ipodio.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/rbutil/ipodpatcher/ipodio.h b/rbutil/ipodpatcher/ipodio.h
index f2aba267d8..dadb5f8ad4 100644
--- a/rbutil/ipodpatcher/ipodio.h
+++ b/rbutil/ipodpatcher/ipodio.h
@@ -62,6 +62,8 @@ struct ipod_t {
62 HANDLE dh; 62 HANDLE dh;
63 char diskname[4096]; 63 char diskname[4096];
64 int sector_size; 64 int sector_size;
65 int sectors_per_track;
66 int num_heads;
65 struct ipod_directory_t ipod_directory[MAX_IMAGES]; 67 struct ipod_directory_t ipod_directory[MAX_IMAGES];
66 int nimages; 68 int nimages;
67 off_t diroffset; 69 off_t diroffset;
@@ -88,4 +90,7 @@ int ipod_read(struct ipod_t* ipod, unsigned char* buf, int nbytes);
88int ipod_write(struct ipod_t* ipod, unsigned char* buf, int nbytes); 90int ipod_write(struct ipod_t* ipod, unsigned char* buf, int nbytes);
89int ipod_alloc_buffer(unsigned char** sectorbuf, int bufsize); 91int ipod_alloc_buffer(unsigned char** sectorbuf, int bufsize);
90 92
93/* In fat32format.c */
94int format_partition(struct ipod_t* ipod, int partition);
95
91#endif 96#endif