aboutsummaryrefslogtreecommitdiffstats
path: root/core/isolinux.asm
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2009-03-16 09:24:02 -0700
committerH. Peter Anvin <hpa@zytor.com>2009-03-16 09:24:02 -0700
commitbf366cd045b9abaf52f7f1c83d603e8e34cbe9ce (patch)
treed65246c467366dca08a46615e4982afb10d49467 /core/isolinux.asm
parent1cb786fc4c9a11179b73d6f5005a2bd990a51b92 (diff)
downloadsyslinux-bf366cd045b9abaf52f7f1c83d603e8e34cbe9ce.tar.gz
isolinux: split MaxTransfer for HD and CD modes
The MaxTransfer for CD modes has to be smaller than for HD modes to avoid 64K overrun (even though in theory it's permitted, we don't trust it.) Thus have separate variables for HD and CD modes.
Diffstat (limited to 'core/isolinux.asm')
-rw-r--r--core/isolinux.asm12
1 files changed, 7 insertions, 5 deletions
diff --git a/core/isolinux.asm b/core/isolinux.asm
index 8ec74e5a..51d3bcd3 100644
--- a/core/isolinux.asm
+++ b/core/isolinux.asm
@@ -8,7 +8,7 @@
; available. It is based on the SYSLINUX boot loader for MS-DOS
; floppies.
;
-; Copyright 1994-2008 H. Peter Anvin - All Rights Reserved
+; Copyright 1994-2009 H. Peter Anvin - All Rights Reserved
;
; This program is free software; you can redistribute it and/or modify
; it under the terms of the GNU General Public License as published by
@@ -932,9 +932,9 @@ getlinsec_cdrom:
mov [si+8],eax
.loop:
push bp ; Sectors left
- cmp bp,[MaxTransfer]
+ cmp bp,[MaxTransferCD]
jbe .bp_ok
- mov bp,[MaxTransfer]
+ mov bp,[MaxTransferCD]
.bp_ok:
mov [si+2],bp
push si
@@ -979,7 +979,7 @@ xint13: mov byte [RetryCount],retry_count
shr ah,1 ; Otherwise, try to reduce
adc ah,0 ; the max transfer size, but not to 0
.setsize:
- mov [MaxTransfer],ah
+ mov [MaxTransferCD],ah
mov [dapa+2],ah
.again:
pop ax
@@ -1072,7 +1072,9 @@ bios_cbios: dw getlinsec_cbios, bios_cbios_str
bios_ebios: dw getlinsec_ebios, bios_ebios_str
%endif
-MaxTransfer dw 32 ; Max sectors per transfer
+; Maximum transfer size
+MaxTransfer dw 127 ; Hard disk modes
+MaxTransferCD dw 32 ; CD mode
rl_checkpt equ $ ; Must be <= 800h