compare_gpts(9)
πΈ NAME πΈ
okay so this is compare_gpts(9) from the Kernel API Manual, and its whole mission is to search the disk for valid GPT headers and PTEs. thatβs the assignment, bestie π
β¨
β¨ SYNOPSIS β¨
void compare_gpts (gpt_header *pgpt , gpt_header *agpt , u64 lastlba );
π ARGUMENTS π
pgptβ the primary GPT header. main character energy πagptβ the alternate GPT header. the backup bestie π«Άlastlbaβ the last LBA number. literally exactly that, no cap π
π DESCRIPTION π
Returns nothing. like, actually nothing β void is giving minimalist icon behavior πβ¨
It sanity checks the pgpt and agpt fields and prints warnings on discrepancies. so if those two start disagreeing, this function is gonna call it out π£π
π₯ SEE ALSO π₯
the kernel file is ./block/partitions/efi.c, and hereβs the whole squad:
efi_crc32(9)last_lba(9)is_pmbr_valid(9)read_lba(9)alloc_read_gpt_entries(9)alloc_read_gpt_header(9)is_gpt_valid(9)is_pte_valid(9)find_valid_gpt(9)utf16_le_to_7bit(9)efi_partition(9)
π thatβs a wrap! source: ./block/partitions β’ date: October 2026 β’ this was compare_gpts(9) β byeee bestie, go check those GPT fields π«Άβ¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms