diff options
author | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-04-16 18:20:36 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-04-16 18:20:36 -0400 |
commit | 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 (patch) | |
tree | 0bba044c4ce775e45a88a51686b5d9f90697ea9d /include/mtd/inftl-user.h |
Linux-2.6.12-rc2v2.6.12-rc2
Initial git repository build. I'm not bothering with the full history,
even though we have it. We can create a separate "historical" git
archive of that later if we want to, and in the meantime it's about
3.2GB when imported into git - space that would just make the early
git days unnecessarily complicated, when we don't have a lot of good
infrastructure for it.
Let it rip!
Diffstat (limited to 'include/mtd/inftl-user.h')
-rw-r--r-- | include/mtd/inftl-user.h | 91 |
1 files changed, 91 insertions, 0 deletions
diff --git a/include/mtd/inftl-user.h b/include/mtd/inftl-user.h new file mode 100644 index 000000000000..bda4f2c8f728 --- /dev/null +++ b/include/mtd/inftl-user.h | |||
@@ -0,0 +1,91 @@ | |||
1 | /* | ||
2 | * $Id: inftl-user.h,v 1.1 2004/05/05 15:17:00 dwmw2 Exp $ | ||
3 | * | ||
4 | * Parts of INFTL headers shared with userspace | ||
5 | * | ||
6 | */ | ||
7 | |||
8 | #ifndef __MTD_INFTL_USER_H__ | ||
9 | #define __MTD_INFTL_USER_H__ | ||
10 | |||
11 | #define OSAK_VERSION 0x5120 | ||
12 | #define PERCENTUSED 98 | ||
13 | |||
14 | #define SECTORSIZE 512 | ||
15 | |||
16 | /* Block Control Information */ | ||
17 | |||
18 | struct inftl_bci { | ||
19 | uint8_t ECCsig[6]; | ||
20 | uint8_t Status; | ||
21 | uint8_t Status1; | ||
22 | } __attribute__((packed)); | ||
23 | |||
24 | struct inftl_unithead1 { | ||
25 | uint16_t virtualUnitNo; | ||
26 | uint16_t prevUnitNo; | ||
27 | uint8_t ANAC; | ||
28 | uint8_t NACs; | ||
29 | uint8_t parityPerField; | ||
30 | uint8_t discarded; | ||
31 | } __attribute__((packed)); | ||
32 | |||
33 | struct inftl_unithead2 { | ||
34 | uint8_t parityPerField; | ||
35 | uint8_t ANAC; | ||
36 | uint16_t prevUnitNo; | ||
37 | uint16_t virtualUnitNo; | ||
38 | uint8_t NACs; | ||
39 | uint8_t discarded; | ||
40 | } __attribute__((packed)); | ||
41 | |||
42 | struct inftl_unittail { | ||
43 | uint8_t Reserved[4]; | ||
44 | uint16_t EraseMark; | ||
45 | uint16_t EraseMark1; | ||
46 | } __attribute__((packed)); | ||
47 | |||
48 | union inftl_uci { | ||
49 | struct inftl_unithead1 a; | ||
50 | struct inftl_unithead2 b; | ||
51 | struct inftl_unittail c; | ||
52 | }; | ||
53 | |||
54 | struct inftl_oob { | ||
55 | struct inftl_bci b; | ||
56 | union inftl_uci u; | ||
57 | }; | ||
58 | |||
59 | |||
60 | /* INFTL Media Header */ | ||
61 | |||
62 | struct INFTLPartition { | ||
63 | __u32 virtualUnits; | ||
64 | __u32 firstUnit; | ||
65 | __u32 lastUnit; | ||
66 | __u32 flags; | ||
67 | __u32 spareUnits; | ||
68 | __u32 Reserved0; | ||
69 | __u32 Reserved1; | ||
70 | } __attribute__((packed)); | ||
71 | |||
72 | struct INFTLMediaHeader { | ||
73 | char bootRecordID[8]; | ||
74 | __u32 NoOfBootImageBlocks; | ||
75 | __u32 NoOfBinaryPartitions; | ||
76 | __u32 NoOfBDTLPartitions; | ||
77 | __u32 BlockMultiplierBits; | ||
78 | __u32 FormatFlags; | ||
79 | __u32 OsakVersion; | ||
80 | __u32 PercentUsed; | ||
81 | struct INFTLPartition Partitions[4]; | ||
82 | } __attribute__((packed)); | ||
83 | |||
84 | /* Partition flag types */ | ||
85 | #define INFTL_BINARY 0x20000000 | ||
86 | #define INFTL_BDTL 0x40000000 | ||
87 | #define INFTL_LAST 0x80000000 | ||
88 | |||
89 | #endif /* __MTD_INFTL_USER_H__ */ | ||
90 | |||
91 | |||