diff options
author | H. Peter Anvin <hpa@zytor.com> | 2008-02-25 15:11:28 -0800 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2008-02-25 15:11:28 -0800 |
commit | 241be5df8baa2089a635a2a373e5a219d184015d (patch) | |
tree | bb67d7c80df1ba6b566c656fdb2e526cba8b1e2c /mbr | |
parent | 4098fb7f5b886f4875a6cb8f2edfb4f77890d256 (diff) | |
download | syslinux-241be5df8baa2089a635a2a373e5a219d184015d.tar.gz |
gptmbr: since %bx is advanced, we can test -2(%bx) == (bootsec+510)
With %bx advanced to the end of the boot sector, we can use -2(%bx)
instead of (bootsec+510), thus saving one byte.
Diffstat (limited to 'mbr')
-rw-r--r-- | mbr/gptmbr.S | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mbr/gptmbr.S b/mbr/gptmbr.S index 49414e48..cca7b479 100644 --- a/mbr/gptmbr.S +++ b/mbr/gptmbr.S @@ -195,7 +195,7 @@ boot: movl (48+16)(%si),%edx movw $bootsec,%bx call read_sector - cmpw $0xaa55, (bootsec+510) + cmpw $0xaa55, -2(%bx) jne missing_os /* Not a valid boot sector */ movw $driveno, %sp /* driveno == bootsec-6 */ popw %dx /* dl -> drive number */ |