Lines Matching defs:header
25 * 1 1 primary partition header
32 * 466 1 secondary partition header
69 * header CRC32 value to 0, and calculate header CRC32 value. Both primary and
74 GptHeader *header, *header2;
77 header = (GptHeader *)gpt->primary_header;
82 header->entries_crc32 =
84 header->number_of_entries * header->size_of_entry);
85 header->header_crc32 = 0;
86 header->header_crc32 = Crc32((uint8_t *)header, header->size);
114 * All fields are zero except 4 pointers linking to header and entries.
140 * file. Before calling this function, primary/secondary header/entries must
147 GptHeader *header, *header2;
161 header = (GptHeader *)gpt->primary_header;
163 Memcpy(header->signature, GPT_HEADER_SIGNATURE,
165 header->revision = GPT_HEADER_REVISION;
166 header->size = sizeof(GptHeader);
167 header->reserved_zero = 0;
168 header->my_lba = 1;
169 header->alternate_lba = DEFAULT_DRIVE_SECTORS - 1;
170 header->first_usable_lba = 34;
171 header->last_usable_lba = DEFAULT_DRIVE_SECTORS - 1 - 32 - 1; /* 433 */
172 header->entries_lba = 2;
174 header->number_of_entries = 128;
175 header->size_of_entry = 128; /* bytes */
196 Memcpy(header2, header, sizeof(GptHeader));
268 /* Test if header CRC in two copies are calculated. */
277 /* CRC covers first byte of header */
282 /* CRC covers last byte of header */
287 /* CRC only covers header */
295 /* Test if header-same comparison works. */
372 * in header is not that, we expect the header is invalid.
447 /* Modify a field that the header verification doesn't care about */
600 * We support a padding between primary GPT header and its entries. So
606 * header, which is now lying after its entry array.
699 * entry.StartingLBA >= header.FirstUsableLBA
700 * entry.EndingLBA <= header.LastUsableLBA
709 /* error case: entry.StartingLBA < header.FirstUsableLBA */
715 /* error case: entry.EndingLBA > header.LastUsableLBA */
929 * header will have the wrong entries CRC, so we should fall back
930 * to the secondary header.
942 /* Modify both header and entries */
1020 /* Test unloaded header
1434 // But off device, it is okay to accept this GPT header.
1454 // Repeat for secondary header.