NetBSD/sys/arch/i386/stand
lukem 455da8e60b Move mbr_bootsel from offset 404 to offset 400 in struct mbr_sector to
leave 4 bytes for the Windows NT Drive Serial Number (DSN) at 440-443
(as mbr_sector.mbr_dsn).

Ensure that all the MBR & PBR code reserves space for mbr_sector.mbr_dsn.

Leave the bootsel magic number at 444-445 as mbr_sector.mbr_bootsel_magic
(instead of mbr_sector.mbr_bootsel.mbrbs_magic), but use 0xb5e1 (MBR_BS_MAGIC)
instead of 0xaa55 (MBR_MAGIC) to indicate that this change has occurred.

Rework MBR_BS_NEWMBR to mean "mbr_bootsel has moved to 400".

Modify fdisk(8) to automatically relocate the mbr_bootsel from 404 to 400
if mbr_bootsel_magic is the old value (0xaa55), and unset MBR_BS_NEWMBR
to flag that new mbr_bootsel code must be used if updating the MBR.


These changes fixes a problem where Windows 2000 or Windows XP would corrupt
the last 3 bytes + NUL of MBR partition 3's bootsel name if the bootsel name
was 5 characters long, replacing bytes 6-9 with the DSN.
Also, by explicitly reserving the space for the DSN we prevent problems in the
future if non bootsel MBR or PBR code had other information at bytes 440-443.
2004-03-22 07:11:00 +00:00
..
boot Translate ascii keycode to help those with azerty keyboard type straight. 2004-03-13 22:41:37 +00:00
bootxx Move mbr_bootsel from offset 404 to offset 400 in struct mbr_sector to 2004-03-22 07:11:00 +00:00
dosboot Fix signed/unsigned warnings. 2003-08-31 22:40:13 +00:00
genprom This is a host program. Don't use errx. 2003-05-08 13:42:17 +00:00
lib Translate ascii keycode to help those with azerty keyboard type straight. 2004-03-13 22:41:37 +00:00
libsa Fix signed/unsigned warnings. 2003-08-31 22:40:13 +00:00
mbr Move mbr_bootsel from offset 404 to offset 400 in struct mbr_sector to 2004-03-22 07:11:00 +00:00
misc avoid calling toupper with posibly -ve value. fixes PR 21171 2003-04-14 11:33:40 +00:00
netboot Add bsd.obj.mk so these directories get their own obj directory (for the 2003-10-13 06:56:47 +00:00
pxeboot Uhm - the last change broke everything but very simple setups. 2003-11-12 18:44:08 +00:00
pxeboot_com0 * Rename the pxeboot binary from "pxeboot" to "pxeboot_ia32", since 2002-02-20 03:00:27 +00:00
Makefile No longer build biosboot*.sym and installboot. 2003-07-26 08:45:12 +00:00
Makefile.booters stand/lib/crt/rom is no more, no need for it in .PATH 2003-11-07 23:44:56 +00:00
Makefile.inc Cleanup of i386 bootloader building: 2002-02-17 20:03:05 +00:00