Preparations for work on MDSLINUX, if it ever happens
authorhpa <hpa>
Fri, 11 Apr 2003 05:44:56 +0000 (05:44 +0000)
committerhpa <hpa>
Fri, 11 Apr 2003 05:44:56 +0000 (05:44 +0000)
bootsect.inc
comboot.inc
ldlinux.asm
macros.inc
runkernel.inc
ui.inc

index ccf5331..afa6568 100644 (file)
@@ -25,7 +25,7 @@
 ; Load a boot sector
 ;
 is_bootsector:
-%if IS_SYSLINUX
+%if IS_SYSLINUX || IS_MDSLINUX
                ; Transfer zero bytes
                xor cx,cx
                jmp short load_bootsec
@@ -42,14 +42,14 @@ load_bootsec:
                call load_high
                call crlf
 
-%if IS_SYSLINUX
+%if IS_SYSLINUX || IS_MDSLINUX
                pop cx
 %endif
 
                sub edi,100000h
                push edi                ; Save length
 
-%if IS_SYSLINUX
+%if IS_SYSLINUX || IS_MDSLINUX
                jcxz .not_bss
 
                ; For a BSS boot sector we have to patch.
@@ -66,7 +66,7 @@ load_bootsec:
                call vgaclearmode
                xor edx,edx
                xor eax,eax
-%if IS_SYSLINUX
+%if IS_SYSLINUX || IS_MDSLINUX
                mov dl,[bsDriveNumber]
 
                mov si,PartInfo
@@ -106,7 +106,9 @@ load_bootsec:
 
                jmp bcopy_over_self
 
-%if IS_SYSLINUX = 0
+%if IS_SYSLINUX || IS_MDSLINUX
+               ; Nothing
+%else
 is_bss_sector:
                mov si,err_bssimage
                call cwritestr
index 2388ad1..5e1d8e9 100644 (file)
@@ -449,7 +449,7 @@ comapi_pxecall      equ comapi_err                  ; Not available
 ;
 comapi_derinfo:
                mov P_AL,my_id
-%if IS_SYSLINUX
+%if IS_SYSLINUX || IS_MDSLINUX
                mov al,[bsDriveNumber]
                mov P_DL,al
                mov P_ES,cs
@@ -499,7 +499,7 @@ comapi_cleanup:
                test dl,3
                setnz [KeepPXE]
                call unload_pxe
-%elif IS_SYSLINUX
+%elif IS_SYSLINUX || IS_MDSLINUX
                ; Restore original FDC table
                mov eax,[OrigFDCTabPtr]
                mov [fdctab],eax
index dd1f10e..cb146b9 100644 (file)
@@ -26,7 +26,9 @@
 ; 
 ; ****************************************************************************
 
+%ifndef IS_MDSLINUX
 %define IS_SYSLINUX 1
+%endif
 %include "macros.inc"
 %include "config.inc"
 %include "kernel.inc"
@@ -647,7 +649,13 @@ magic_len  equ $-bs_magic
 
 ldlinux_sys:
 
-syslinux_banner        db 0Dh, 0Ah, 'SYSLINUX ', version_str, ' ', date, ' ', 0
+syslinux_banner        db 0Dh, 0Ah
+%if IS_MDSLINUX
+               db 'MDSLINUX '
+%else
+               db 'SYSLINUX '
+%endif
+               db version_str, ' ', date, ' ', 0
                db 0Dh, 0Ah, 1Ah        ; EOF if we "type" this in DOS
 
 ldlinux_magic  db 'LDLINUX SYS'
@@ -1381,6 +1389,9 @@ crlf_msg  db CR, LF
 null_msg       db 0
 crff_msg       db CR, FF, 0
 syslinux_cfg   db 'SYSLINUXCFG'
+%if IS_MDSLINUX
+manifest       db 'MANIFEST   '
+%endif
 ;
 ; Command line options we'd like to take a look at
 ;
index f1cb66d..f12ff3f 100644 (file)
@@ -27,6 +27,9 @@
 %ifndef IS_SYSLINUX
 %define IS_SYSLINUX 0
 %endif
+%ifndef IS_MDSLINUX
+%define IS_MDSLINUX 0
+%endif
 %ifndef IS_PXELINUX
 %define IS_PXELINUX 0
 %endif
index c536967..1b23cdc 100644 (file)
@@ -451,7 +451,7 @@ root_not_floppy:
 ; Copy the disk table to high memory, then re-initialize the floppy
 ; controller
 ;
-%if IS_SYSLINUX
+%if IS_SYSLINUX || IS_MDSLINUX
                lgs si,[cs:fdctab]
                mov di,linux_fdctab
                mov cx,6                        ; 12 bytes
diff --git a/ui.inc b/ui.inc
index c8d309d..5711439 100644 (file)
--- a/ui.inc
+++ b/ui.inc
@@ -240,7 +240,7 @@ not_vk:             pop ds
 ; Find the kernel on disk
 ;
 get_kernel:     mov byte [KernelName+FILENAME_MAX],0   ; Zero-terminate filename/extension
-%if IS_SYSLINUX                ; SYSLINUX has to deal with DOS mangled names...
+%if IS_SYSLINUX || IS_MDSLINUX         ; SYSLINUX has to deal with DOS mangled names...
                mov eax,[KernelName+8]          ; Save initial extension
                mov [exten_table_end],eax       ; Last case == initial ext.
 %else
@@ -259,7 +259,7 @@ get_kernel:     mov byte [KernelName+FILENAME_MAX],0        ; Zero-terminate filename/e
                pop bx
                 jnz kernel_good
                mov eax,[bx]                    ; Try a different extension
-%if IS_SYSLINUX
+%if IS_SYSLINUX || IS_MDSLINUX
                mov [KernelName+8],eax
 %else
                mov si,[KernelExtPtr]
@@ -318,7 +318,7 @@ vk_found:   popa
 %endif
                xor bx,bx                       ; Try only one version
 
-%if IS_SYSLINUX
+%if IS_SYSLINUX || IS_MDSLINUX
                jmp get_kernel
 %else
                ; Is this a "localboot" pseudo-kernel?
@@ -360,7 +360,7 @@ kernel_good:
                mov [KernelCNameLen],di
                popa
                
-%if IS_SYSLINUX
+%if IS_SYSLINUX || IS_MDSLINUX
                mov ecx,[KernelName+7]
                mov cl,'.'
 %else
@@ -397,7 +397,7 @@ kernel_good:
                je is_bss_sector
                cmp ecx,'.bin'
                je is_bootsector
-%if IS_SYSLINUX
+%if IS_SYSLINUX || IS_MDSLINUX
                cmp ecx,'.bs '
                je is_bootsector
                cmp ecx,'.0  '