; the Free Software Foundation, Inc., 675 Mass Ave, Cambridge MA 02139,
; USA; either version 2 of the License, or (at your option) any later
; version; incorporated herein by reference.
-;
+;
; ****************************************************************************
;
; THIS FILE IS A MODIFIED VERSION OF ISOLINUX.ASM
call crlf
%endif
- mov bx, 0x8000 ; bx = load address
+; use high segment, as some bios can fail, when offset is too big
+ mov bx, 0x0F80 ; FREELDR_BASE / 16 ; es = load segment
+ mov es, bx
+ xor ebx, ebx ; bx = load offset
mov si, di ; restore file pointer
mov cx, 0xFFFF ; load the whole file
call getfssec ; get the whole file
mov dl, [DriveNo] ; dl = boot drive
mov dh, 0 ; dh = boot partition
- push 0 ; push segment (0x0000)
- mov eax, [0x8000 + 0xA8] ; load the RVA of the EntryPoint into eax
- add eax, 0x8000 ; RVA -> VA
- push ax ; push offset
- retf ; Transfer control to ROSLDR
-
+ ; Transfer execution to the bootloader
+ ;ljmp16 0, FREELDR_BASE
+ db 0xEA
+ dw 0xF800
+ dw 0
;
; searchdir:
isolinux_banner db CR, LF, 'Loading IsoBoot...', CR, LF, 0
-copyright_str db ' Copyright (C) 1994-2002 H. Peter Anvin', CR, LF, 0
+copyright_str db ' (C) 1994-2002 H. Peter Anvin', CR, LF, 0
presskey_msg db 'Press any key to boot from CD', 0
dot_msg db '.',0
startldr_msg: db 'Starting SETUPLDR.SYS', 0
%endif
-nosecsize_msg: db 'Failed to get sector size, assuming 0800', CR, LF, 0
+; nosecsize_msg: db 'Failed to get sector size, assuming 0800', CR, LF, 0
spec_err_msg: db 'Loading spec packet failed, trying to wing it...', CR, LF, 0
maybe_msg: db 'Found something at drive = ', 0
alright_msg: db 'Looks like it might be right, continuing...', CR, LF, 0