Commit Graph

161 Commits

Author SHA1 Message Date
wiz
24be734e2d Nm needs no argument; also, correct wrong Nm usage. 2004-03-20 18:49:33 +00:00
snj
17ed0d0099 Bump date for last. Use Sq for single quotes. Drop trailing space.
New sentence, new line.  Sort xrefs.  Fix a spelling error.
2004-03-19 22:21:36 +00:00
dyoung
6c02382b7e Add flag -F, options -t disktab and -T disktype to fdisk. Flag -F
indicates that the target of the fdisk operation is a file, not a
disk. With -t and -T, the user tells fdisk the geometry for the
file If the default geometry that fdisk will "fake up" for a file
are not satisfactory, the user may tell the geometry to fdisk using
-t disktab -T disktype.
2004-03-19 18:19:17 +00:00
jmmv
b635f565e7 Homogenize usage messages: make the 'usage' word all lowercase, as this seems
to be the most common practice in our tree.
2004-01-05 23:23:32 +00:00
lukem
2a42af8c7a Add "DISK" to -S output. 2003-11-21 21:47:42 +00:00
lukem
7a699e2bed unconditionally #define DEFAULT_BOOTDIR. should fix non-x86 builds 2003-10-11 04:50:49 +00:00
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
lukem
f41de51799 be consistent about "MS-DOS" 2003-10-06 12:02:52 +00:00
itojun
731ae88ecd realloc pedant 2003-09-19 08:35:15 +00:00
dsl
1ce757782d Define and use PRIdaddr for printing disk block numbers.
Should fix bin/22638 for compilation on amd64.
2003-08-29 16:31:30 +00:00
dsl
26461e4412 Put cylinder number 1023 into the mbr for sectors beyond the CHS limit
(rather than encoding the highest CHS addressable sector).
2003-08-10 10:20:08 +00:00
dsl
ae60f83e33 Remove old i386 mbr stuff (move to arch/i386/stand/mbr a while ago)
mbr.8 moved to src/share/man/man8/man8.i386
2003-07-16 11:11:49 +00:00
dsl
02af72a142 Fix code that detects bios geometry from mbr table. 2003-07-14 09:32:12 +00:00
dsl
93e88fd2eb Only look at each pair of CHS values once when trying to guess geometry. 2003-07-07 11:45:00 +00:00
joda
e5986b088f add missing . before Fl 2003-06-03 12:35:54 +00:00
itojun
00868410fd asprintf is easier 2003-05-17 23:14:42 +00:00
dsl
b081987b73 delete a diagnostic printf that was accidentally left in 2003-05-14 11:24:05 +00:00
wiz
c94730c38a MBR, not mbr. 2003-05-06 07:56:03 +00:00
dsl
5e53f766f8 Change a couple of .Em to .Ar 2003-05-01 13:36:25 +00:00
wiz
0682f1a427 Replace some raw roff with mdoc. 2003-05-01 13:01:17 +00:00
wiz
0d14e41651 Improve formatting for [/bootmenu], requested by dsl; add some commas. 2003-05-01 12:55:52 +00:00
dsl
315515ebe4 a mbr -> an mbr 2003-05-01 10:43:58 +00:00
wiz
c662d486a9 mdoc fix, use \*[Lt]/\*[Gt], sort SEE ALSO, some other nits. 2003-05-01 10:43:14 +00:00
wiz
b3d7fe267b Drop trailing space. 2003-05-01 09:50:12 +00:00
bjh21
b2fbd85bee Remove some unused variabled from get_params_to_use() in the !i386 && !amd64
case.
2003-05-01 09:23:30 +00:00
dsl
93174a8c33 Update to match new mbr code 2003-05-01 08:40:17 +00:00
dsl
c5bd7c9dfd i386/amd64 mbr is now built in sys/arch/i386/stand/mbr 2003-04-30 19:50:42 +00:00
dsl
8defedc8ba Don't descend into mbr_bootsel.
i386/and64 mbr code is built in arch i386/stand/mbr
2003-04-30 19:49:01 +00:00
dsl
fa01152676 Rototilled fdisk that supports:
- editing of the extended partition list
- user friendly default start/size for new partitions
- partition start/size input in sectors, cylinders or MB
- bootsel menu names configured with paritition bounds
- partition update loop asks used which partition to change
  (instead of asking about each partition in turn).
- detection (and erroring) of overlapped partitions.
- automatic installation of correct mbr_xxx code (after prompting user)
2003-04-30 19:47:10 +00:00
dsl
6ac09f276d Move some definitions from fdisk.c to disklabel_mbr.h so they don't have
to be duplicated elsewhere (eg in mbr.S).
Modify fdisk.c so that it builds with the new disklabel.h
2003-04-30 10:29:51 +00:00
fvdl
043f21d9ea x86_64 -> amd64 2003-04-26 19:14:17 +00:00
fvdl
0945a6df17 x86_64 -> amd64 2003-04-26 19:02:50 +00:00
fvdl
96757427c6 Fix range check for the default boot option case. 2003-04-01 19:39:13 +00:00
wiz
990562bfef .Nm does not need a dummy argument ("") before punctuation or
for correct formatting of the SYNOPSIS any longer.
2003-02-25 10:34:36 +00:00
wiz
82ece76c41 Drop trailing space (in last). 2003-02-09 21:56:19 +00:00
perry
d259c39de5 Slightly clarify/improve the documentation for the -B (boot selector)
option
2003-02-09 20:46:29 +00:00
jmmv
dd4a382f46 Print missing newline in two bootselector-related messages. Approved by wiz. 2003-01-10 23:37:34 +00:00
fvdl
f77d71f782 Enable bootselector code for x86_64.
XXX the ifdef-ed parts should be split off into a seperate file.
2002-11-30 13:47:19 +00:00
fvdl
2ee89df87b Avoid format warning for off_t printf. 2002-11-24 21:49:15 +00:00
fvdl
304258c96f Compile mbr and mbr_bootsel on x86_64 2002-11-23 23:45:51 +00:00
jdarrow
7e912cff61 Make the -l flage more useful, by actually printing the systype number
alongside the sysid string (instead of just the array index of the
struct part_type they are found in).

Now fdisk -l shows the familiar 169 for NetBSD, 165 for FreeBSD or
386BSD or old NetBSD, and other possibly-familiar (131 for Linux native,
015 for Ext. Partition - LBA) values in with their correct numbers.
2002-10-08 07:38:47 +00:00
wiz
2fb4b1db52 New sentence, new line. By Robert Elz with minimal fixes. 2002-10-01 13:40:23 +00:00
dbj
bfd495ea39 add partition type 0xaf for Apple HFS. 2002-09-27 23:19:56 +00:00
lukem
0d1ba7e8a0 minor makefile delint 2002-09-18 06:38:50 +00:00
enami
eb0197ee71 Fix unbalanced paren. 2002-09-09 03:01:26 +00:00
soren
26bc587db9 Clean up printf->err conversions. 2002-08-08 13:19:18 +00:00
ross
08c3bcd192 shut up assembler warnings 2002-08-04 20:29:44 +00:00
ross
626a25bc13 deal with assembler warnings 2002-08-04 20:27:22 +00:00
manu
3f13baf349 Added fdisk on hpcarm 2002-07-26 17:22:51 +00:00
wiz
1322c69689 Nit. 2002-07-09 22:51:13 +00:00