NetBSD/distrib/utils
lukem 1c33b4e6a4 Overhaul MBR handling (part 1):
<sys/bootblock.h>:
    *	Added definitions for the Master Boot Record (MBR) used by
	a variety of systems (primarily i386), including the format
	of the BIOS Parameter Block (BPB).
	This information was cribbed from a variety of sources
	including <sys/disklabel_mbr.h> which this is a superset of.

	As part of this, some data structure elements and #defines
	were renamed to be more "namespace friendly" and consistent
	with other bootblocks and MBR documentation.
	Update all uses of the old names to the new names.

<sys/disklabel_mbr.h>:
    *	Deprecated in favor of <sys/bootblock.h> (the latter is more
	"host tool" friendly).

amd64 & i386:
    *	Renamed /usr/mdec/bootxx_dosfs to /usr/mdec/bootxx_msdos, to
	be consistent with the naming convention of the msdosfs tools.

    *	Removed /usr/mdec/bootxx_ufs, as it's equivalent to bootxx_ffsv1
	and it's confusing to have two functionally equivalent bootblocks,
	especially given that "ufs" has multiple meanings (it could be
	a synonym for "ffs", or the group of ffs/lfs/ext2fs file systems).

    *	Rework pbr.S (the first sector of bootxx_*):
	    +	Ensure that BPB (bytes 11..89) and the partition table
		(bytes 446..509) do not contain code.
	    +	Add support for booting from FAT partitions if BOOT_FROM_FAT
		is defined.  (Only set for bootxx_msdos).
	    +	Remove "dummy" partition 3; if people want to installboot(8)
		these to the start of the disk they can use fdisk(8) to
		create a real MBR partition table...
	    +	Compile with TERSE_ERROR so it fits because of the above.
		Whilst this is less user friendly, I feel it's important
		to have a valid partition table and BPB in the MBR/PBR.

    *	Renamed /usr/mdec/biosboot to /usr/mdec/boot, to be consistent
	with other platforms.

    *	Enable SUPPORT_DOSFS in /usr/mdec/boot (stage2), so that
    	we can boot off FAT partitions.

    *	Crank version of /usr/mdec/boot to 3.1, and fix some of the other
	entries in the version file.

installboot(8) (i386):
    *	Read the existing MBR of the filesystem and retain the BIOS
    	Parameter Block (BPB) in bytes 11..89 and the MBR partition
	table in bytes 446..509.  (Previously installboot(8) would
	trash those two sections of the MBR.)

mbrlabel(8):
    *	Use sys/lib/libkern/xlat_mbr_fstype.c instead of homegrown code
	to map the MBR partition type to the NetBSD disklabel type.


Test built "make release" for i386, and new bootblocks verified to work
(even off FAT!).
2003-10-08 04:25:43 +00:00
..
libhack Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 09:27:56 +00:00
more avoid gcc3 cpp lossage. 2003-08-10 08:26:38 +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 Overhaul MBR handling (part 1): 2003-10-08 04:25:43 +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 use bounded string op 2003-08-06 13:56:58 +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.