Init control word to zero, cdrom-handler reads this and will crash if it is non-zero...
[AROS.git] / rom / partition / partitiongpt.h
blobd11e5b60b0bf957dbffe5d77128fd320894b54d7
1 #include <libraries/uuid.h>
3 /* Type ID for legacy MBR */
4 #define MBRT_GPT 0xEE
6 /* GPT partition table header */
7 struct GPTHeader
9 char Signature[8]; /* ID signature */
10 ULONG Revision; /* Revision number */
11 ULONG HeaderSize; /* Size of this structure */
12 ULONG HeaderCRC32; /* CRC32 of the header */
13 ULONG Reserved;
14 UQUAD CurrentBlock; /* Number of block where this structure is placed */
15 UQUAD BackupBlock; /* Number of block where backup partition table is placed */
16 UQUAD DataStart; /* Number of the first usable block for data */
17 UQUAD DataEnd; /* Number of the last usable block for data */
18 uuid_t DiskID; /* Disk unique ID */
19 UQUAD StartBlock; /* Number if the first partition entry block */
20 ULONG NumEntries; /* Number of partitions in the table */
21 ULONG EntrySize; /* Size of one entry */
22 ULONG PartCRC32; /* CRC32 of the partition entries array */
23 /* The rest is reserved */
26 #define GPT_SIGNATURE "EFI PART"
27 #define GPT_MIN_HEADER_SIZE 92
28 #define GPT_MAX_HEADER_SIZE 512
30 struct GPTPartition
32 uuid_t TypeID; /* Partition type ID */
33 uuid_t PartitionID; /* Partition unique ID */
34 UQUAD StartBlock; /* Number of the first block */
35 UQUAD EndBlock; /* Number of the last block */
36 ULONG Flags0; /* Flags */
37 ULONG Flags1;
38 UBYTE Name[72]; /* Name in UTF16-LE encoding */
41 /* Flags0 and Flags1, according to Microsoft(R) */
42 #define GPT_PF0_SYSTEM (1 << 0)
43 #define GPT_PF1_READONLY (1 << 29)
44 #define GPT_PF1_HIDDEN (1 << 30)
45 #define GPT_PF1_NOMOUNT (1 << 31)
47 /* AROS-specific flags */
48 #define GPT_PF1_AROS_BOOTABLE (1 << 28)
49 #define GPT_PF1_AROS_BOOTPRI 0x000000FF /* Mask for boot priority */