diff options
author | H. Peter Anvin <hpa@zytor.com> | 2010-06-26 17:49:01 -0700 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2010-06-26 17:49:01 -0700 |
commit | a2a9c336a366f0f254b0aaca1d6bec740efaa430 (patch) | |
tree | 7ec05c36598c7b4b37c49772ec7e0c9f0c992c90 /mbr | |
parent | f6f72bd64722876fa6684d293dc659cf5c141a39 (diff) | |
download | syslinux-a2a9c336a366f0f254b0aaca1d6bec740efaa430.tar.gz |
gptmbr: skip partitions with all-zero PartitionTypeGUID
PartitionTypeGUID being zero means an empty slot, and so we should not
count that partition type.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'mbr')
-rw-r--r-- | mbr/gptmbr.S | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/mbr/gptmbr.S b/mbr/gptmbr.S index d25d27c8..8ed4cf48 100644 --- a/mbr/gptmbr.S +++ b/mbr/gptmbr.S @@ -152,6 +152,12 @@ get_ptab: popw %ax /* SizeOfPartitionEntry */ find_part: + /* If the PartitionTypeGUID is all zero, it's an empty slot */ + movl (%di),%edx + orl 4(%di),%edx + orl 8(%di),%edx + orl 12(%di),%edx + jz not_this testb $0x04,48(%di) jz not_this andw %si,%si |