aboutsummaryrefslogtreecommitdiffstats
path: root/mbr/gptmbr.S
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2008-09-08 17:30:55 -0700
committerH. Peter Anvin <hpa@zytor.com>2008-09-08 17:30:55 -0700
commit6879e4565b2ed27de10e7a22bba568503012ef1a (patch)
tree886652e829918739e2d293d2b11d16acf3579760 /mbr/gptmbr.S
parent6d5d88b94bccafc2e8f28dff016172103f3814ed (diff)
downloadsyslinux.git-6879e4565b2ed27de10e7a22bba568503012ef1a.tar.gz
syslinux.git-6879e4565b2ed27de10e7a22bba568503012ef1a.tar.xz
syslinux.git-6879e4565b2ed27de10e7a22bba568503012ef1a.zip
mbr, gptmbr, isohdpfx: don't lose the carry flag
Using addw to restore the stack pointer clobbers CF. Use leaw instead, even though this relies on the BIOS not clobbering %si. Worst case we can add a mov %sp, %si or similar. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'mbr/gptmbr.S')
-rw-r--r--mbr/gptmbr.S2
1 files changed, 1 insertions, 1 deletions
diff --git a/mbr/gptmbr.S b/mbr/gptmbr.S
index 77408b75..385afe74 100644
--- a/mbr/gptmbr.S
+++ b/mbr/gptmbr.S
@@ -257,7 +257,7 @@ read_sector_cbios:
read_common:
movb (%bp), %dl /* driveno */
int $0x13
- addw $16, %sp /* Drop DAPA */
+ leaw 16(%si), %sp /* Drop DAPA */
popal
jc disk_error
addb $2, %bh /* bx += 512: point to the next buffer */