NetBSD/distrib/utils
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
..
libhack Modify the licences of code written by Theo De Raadt from a 4-clause 2003-12-10 12:06:25 +00:00
more Fix integer/NULL confusion. 2003-10-21 12:02:32 +00:00
script-installer netbsd.org->NetBSD.org 2003-07-26 17:06:22 +00:00
ssh __STDC__ is always defined on NetBSD. 2002-05-26 00:02:06 +00:00
sysinst Move mbr_bootsel from offset 404 to offset 400 in struct mbr_sector to 2004-03-22 07:11:00 +00:00
tls Major readability cleanup; nuke redundancies; MKfoo=no -> NOfoo=. 2001-12-12 00:05:09 +00:00
x_dhclient the new world order is to use DPSRCS to add extra dependencies... 2003-08-02 05:16:56 +00:00
x_dmesg Major readability cleanup; nuke redundancies; MKfoo=no -> NOfoo=. 2001-12-12 00:05:09 +00:00
x_ed Major readability cleanup; nuke redundancies; MKfoo=no -> NOfoo=. 2001-12-12 00:05:09 +00:00
x_gzip ANSIfy, de-__P(), minor KNF. 2003-12-22 02:05:10 +00:00
x_ifconfig Rework how SMALLPROG was being used and how INET6 support was enabled. 2002-10-17 02:05:35 +00:00
x_netstat Major readability cleanup; nuke redundancies; MKfoo=no -> NOfoo=. 2001-12-12 00:05:09 +00:00
x_ping Major readability cleanup; nuke redundancies; MKfoo=no -> NOfoo=. 2001-12-12 00:05:09 +00:00
x_ping6 Major readability cleanup; nuke redundancies; MKfoo=no -> NOfoo=. 2001-12-12 00:05:09 +00:00
x_route Rework how SMALLPROG was being used and how INET6 support was enabled. 2002-10-17 02:05:35 +00:00
x_umount Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 09:27:56 +00:00
zcat Major readability cleanup; nuke redundancies; MKfoo=no -> NOfoo=. 2001-12-12 00:05:09 +00:00
Makefile EOL x_mount. 2003-01-19 12:35:00 +00:00
Makefile.inc No need to special-case sparc64 any longer. 2003-09-19 16:29:21 +00:00
README correct comment 2002-03-25 07:39:50 +00:00

#	$NetBSD: README,v 1.4 2002/03/25 07:39:50 lukem Exp $

From: "Gordon W. Ross" <gwr>
Date: Tue, 3 Oct 95 16:37:39 EDT
Subject: New ramdisk, tiny shell, etc.
[ edited since the original mail ]

As part of my efforts to build a RAM-disk root kernel for the
sun3 port, I've developed some things that others may want:

New RAM-disk: [ see sys/dev/ramdisk.c ]

New "small/tiny" tools, to replace some of the larger
programs that one usually wants on a ramdisk root:

ssh: (small shell)
  * Consumes only about 8K of memory on an m68k!
    (saves about 100K in the ramdisk...)
  * Can run programs, possibly with I/O redirection
  * Just enough to let you run the programs needed
    while partitioning and copying miniroot to swap.

tls: (tiny ls)
  * Consumes only about 4K of memory on an m68k!
    (saves about 10K in the ramdisk...)
  * Long format only, nothing fancy.

Also, in the new "src/distrib/utils" area, I've made build
directories for some programs that build smaller versions,
usually by adding special CFLAGS

init_s:  (built with -DLETS_GET_SMALL)
  * Forces single-user mode
  * Eliminates unnecessary code

libhack:   small implementation of some libc functions
  * Needs only /etc/master.passwd (not pwd.db, spwd.db)
  * Reduces size of an m68k crunched binary by about 64K

x_dd:  built with -DNO_CONV (no conv=* options)

x_ifconfig:  supports inet only

The x_ prefix on the above is to make the names unique so
crunchgen will not confuse them with the real sources.