* MEMDISK: enable automatic determination of the disk geometry
for a large floppy disk image if (and only if) it is
formatted with a FAT filesystem.
+ * SYSLINUX: fix the handling of .bss files on FAT12/16.
Changes in 3.73:
* Upgrade gPXE to release version 0.9.5.
;; -----------------------------------------------------------------------
;;
-;; 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
is_bootsector:
%if IS_SYSLINUX || IS_MDSLINUX
; Transfer zero bytes
- mov byte [CopySuper],0
+ push word 0
jmp short load_bootsec
is_bss_sector:
; Transfer the superblock
- mov byte [CopySuper],superblock_len
+SuperSize equ $+1
+ push word superblock_len_fat16
%endif
load_bootsec:
mov edi, 100000h
mov [EntryPoint],eax ; Jump to this address when done
%if IS_SYSLINUX || IS_MDSLINUX
- movzx ecx,byte [CopySuper]
- jcxz .not_bss
+ xchg eax,ecx ; ECX[31:16] <- 0
+ pop cx
; For a BSS boot sector we have to patch.
mov esi,superblock
mov edi,100000h+(superblock-bootsec)
call bcopy
-
-.not_bss:
%endif
xor edx,edx
; from MS-LOSS, and can be especially useful in conjunction with the
; umsdos filesystem.
;
-; 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
;
; This is as far as FAT12/16 and FAT32 are consistent
;
- zb 54 ; FAT12/16 need 26 more bytes,
- ; FAT32 need 54 more bytes
-superblock_len equ $-superblock
+ ; FAT12/16 need 26 more bytes,
+ ; FAT32 need 54 more bytes
+ ;
+superblock_len_fat16 equ $-superblock+26
+superblock_len_fat32 equ $-superblock+54
+ zb 54 ; Maximum needed size
+superblock_max equ $-superblock
SecPerClust equ bxSecPerClust
;
add eax,[DataArea]
mov [RootDir],eax
mov cl,nextcluster_fat28-(nextcluster+2)
+ mov byte [SuperSize],superblock_len_fat32
.setsize:
mov byte [nextcluster+1],cl