]>
Commit | Line | Data |
---|---|---|
878ddf1f | 1 | /*++\r |
2 | \r | |
3 | Copyright (c) 2006, Intel Corporation \r | |
4 | All rights reserved. This program and the accompanying materials \r | |
5 | are licensed and made available under the terms and conditions of the BSD License \r | |
6 | which accompanies this distribution. The full text of the license may be found at \r | |
7 | http://opensource.org/licenses/bsd-license.php \r | |
8 | \r | |
9 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r | |
10 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r | |
11 | \r | |
12 | Module Name:\r | |
13 | \r | |
14 | Gpt.h\r | |
15 | \r | |
16 | Abstract:\r | |
17 | \r | |
18 | Data Structures required for detecting GPT Partitions\r | |
19 | \r | |
20 | Revision History\r | |
21 | \r | |
22 | --*/\r | |
23 | \r | |
24 | #ifndef _GPT_H_\r | |
25 | #define _GPT_H_\r | |
26 | \r | |
27 | #pragma pack(1)\r | |
28 | \r | |
29 | #define PRIMARY_PART_HEADER_LBA 1\r | |
30 | \r | |
31 | #define EFI_PTAB_HEADER_ID "EFI PART"\r | |
32 | \r | |
33 | //\r | |
34 | // EFI Partition Attributes\r | |
35 | //\r | |
36 | #define EFI_PART_REQUIRED_TO_FUNCTION 0x0000000000000001\r | |
37 | \r | |
38 | //\r | |
39 | // GPT Partition Table Header\r | |
40 | //\r | |
41 | typedef struct {\r | |
42 | EFI_TABLE_HEADER Header;\r | |
43 | EFI_LBA MyLBA;\r | |
44 | EFI_LBA AlternateLBA;\r | |
45 | EFI_LBA FirstUsableLBA;\r | |
46 | EFI_LBA LastUsableLBA;\r | |
47 | EFI_GUID DiskGUID;\r | |
48 | EFI_LBA PartitionEntryLBA;\r | |
49 | UINT32 NumberOfPartitionEntries;\r | |
50 | UINT32 SizeOfPartitionEntry;\r | |
51 | UINT32 PartitionEntryArrayCRC32;\r | |
52 | } EFI_PARTITION_TABLE_HEADER;\r | |
53 | \r | |
54 | //\r | |
55 | // GPT Partition Entry\r | |
56 | //\r | |
57 | typedef struct {\r | |
58 | EFI_GUID PartitionTypeGUID;\r | |
59 | EFI_GUID UniquePartitionGUID;\r | |
60 | EFI_LBA StartingLBA;\r | |
61 | EFI_LBA EndingLBA;\r | |
62 | UINT64 Attributes;\r | |
63 | CHAR16 PartitionName[36];\r | |
64 | } EFI_PARTITION_ENTRY;\r | |
65 | \r | |
66 | //\r | |
67 | // GPT Partition Entry Status\r | |
68 | //\r | |
69 | typedef struct {\r | |
70 | BOOLEAN OutOfRange;\r | |
71 | BOOLEAN Overlap;\r | |
72 | } EFI_PARTITION_ENTRY_STATUS;\r | |
73 | \r | |
74 | #pragma pack()\r | |
75 | \r | |
76 | #endif\r |