diff options
author | Matt Fleming <matt.fleming@intel.com> | 2013-01-10 21:33:32 +0000 |
---|---|---|
committer | Matt Fleming <matt.fleming@intel.com> | 2013-01-14 09:09:41 +0000 |
commit | cb015497a4e433ba81a47b28790b325807185617 (patch) | |
tree | 1521f5db21d49e3715e780aa1d55b1813aa0dfd3 | |
parent | 57733227cd0af41b263ee0042e4a7b5510afbaa5 (diff) | |
download | syslinux-cb015497a4e433ba81a47b28790b325807185617.tar.gz |
isolinux: Update LBA in getlinsec loop
We need to increment the Logical Block Address in eax by the number of
sectors we passed to getlinsec after every invocation, otherwise we'll
start with the same sector everytime.
This bug was discovered when booting an isohybrid image, which failed
to boot after printing the following error,
"Image checksum error, sorry..."
because the isolinux.bin was bigger than 32K, and thus invoked the
getlinsec loop that reads the file in chunks.
Cc: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Matt Fleming <matt.fleming@intel.com>
-rw-r--r-- | core/isolinux.asm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/core/isolinux.asm b/core/isolinux.asm index 7a871f0e..db6d2d42 100644 --- a/core/isolinux.asm +++ b/core/isolinux.asm @@ -426,7 +426,9 @@ MaxLMA equ 384*1024 ; Reasonable limit (384K) .ok: xor bx,bx push bp + push eax call getlinsec + pop eax pop cx mov dx,cx pop bp @@ -434,6 +436,7 @@ MaxLMA equ 384*1024 ; Reasonable limit (384K) shl cx,SECTOR_SHIFT - 4 add bx,cx + add eax,edx sub bp,dx jnz .more |