From: H. Peter Anvin Date: Tue, 26 Nov 2013 17:58:17 +0000 (-0800) Subject: isolinux: Clear upper half of EDX before using X-Git-Tag: syslinux-6.03~86^2~2^2~7 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=88d17d136c21b8afb7d27e091cbb1f757ded80df;p=platform%2Fupstream%2Fsyslinux.git isolinux: Clear upper half of EDX before using In checkin: cb015497a4e4 isolinux: Update LBA in getlinsec loop ... we use EDX as a sector count, but the sector count is actually in DX, and the upper half of EDX is uninitialized. If the BIOS enters with a nonzero value in the upper half of EDX, this breaks horribly. At least one set of BIOSes has been identified where if the LBA > 64K then the upper half of EDX will be nonzero. Reported-by: Carl Duff Reported-by: Philip Müller Tested-by: Gerardo Exequiel Pozzi Signed-off-by: H. Peter Anvin --- diff --git a/core/isolinux.asm b/core/isolinux.asm index db6d2d4..dd0fa89 100644 --- a/core/isolinux.asm +++ b/core/isolinux.asm @@ -430,7 +430,7 @@ MaxLMA equ 384*1024 ; Reasonable limit (384K) call getlinsec pop eax pop cx - mov dx,cx + movzx edx,cx pop bp pop bx