1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-25 11:37:56 +00:00
freebsd/sbin
John Baldwin f352a0d45f First cut at support for booting a GPT labeled disk via the BIOS bootstrap
on i386 and amd64 machines.  The overall process is that /boot/pmbr lives
in the PMBR (similar to /boot/mbr for MBR disks) and is responsible for
locating and loading /boot/gptboot.  /boot/gptboot is similar to /boot/boot
except that it groks GPT rather than MBR + bsdlabel.  Unlike /boot/boot,
/boot/gptboot lives in its own dedicated GPT partition with a new
"FreeBSD boot" type.  This partition does not have a fixed size in that
/boot/pmbr will load the entire partition into the lower 640k.  However,
it is limited in that it can only be 545k.  That's still a lot better than
the current 7.5k limit for boot2 on MBR.  gptboot mostly acts just like
boot2 in that it reads /boot.config and loads up /boot/loader.  Some more
details:
- Include uuid_equal() and uuid_is_nil() in libstand.
- Add a new 'boot' command to gpt(8) which makes a GPT disk bootable using
  /boot/pmbr and /boot/gptboot.  Note that the disk must have some free
  space for the boot partition.
  - This required exposing the backend of the 'add' function as a
    gpt_add_part() function to the rest of gpt(8).  'boot' uses this to
    create a boot partition if needed.
- Don't cripple cgbase() in the UFS boot code for /boot/gptboot so that
  it can handle a filesystem > 1.5 TB.
- /boot/gptboot has a simple loader (gptldr) that doesn't do any I/O
  unlike boot1 since /boot/pmbr loads all of gptboot up front.  The
  C portion of gptboot (gptboot.c) has been repocopied from boot2.c.
  The primary changes are to parse the GPT to find a root filesystem
  and to use 64-bit disk addresses.  Currently gptboot assumes that the
  first UFS partition on the disk is the / filesystem, but this algorithm
  will likely be improved in the future.
- Teach the biosdisk driver in /boot/loader to understand GPT tables.
  GPT partitions are identified as 'disk0pX:' (e.g. disk0p2:) which is
  similar to the /dev names the kernel uses (e.g. /dev/ad0p2).
- Add a new "freebsd-boot" alias to g_part() for the new boot UUID.

MFC after:	1 month
Discussed with:	marcel (some things might still change, but am committing
			what I have so far)
2007-10-24 21:33:00 +00:00
..
adjkerntz If not compiled for debugging, redirect standard input/output/error 2006-10-23 10:48:19 +00:00
atacontrol Expand the data structure returned by the ATA RAID status ioctl to include 2007-08-13 18:46:31 +00:00
atm Disconnect netatm from the build as it is not MPSAFE and relies on 2007-07-14 21:49:24 +00:00
badsect
bsdlabel - Fix markup. 2006-12-29 16:28:38 +00:00
camcontrol Add SCSI READ CAPACITY support to camcontrol. The new 'readcap' subcommand 2007-09-08 20:24:12 +00:00
ccdconfig Fix markup and some typos. 2006-04-14 09:20:25 +00:00
clri
comcontrol
conscontrol
devd Fix the description of "media-type". 2006-10-24 20:20:41 +00:00
devfs - I forgot to bump a date. 2006-11-05 20:12:32 +00:00
dhclient - Remove references to unexisting man pages 2007-09-20 10:46:25 +00:00
dmesg Avoid moving onto a new line while testing if there is a syslog priority 2006-02-27 19:13:47 +00:00
dump (bread): For a read that is contained entirely within a block, never copy 2007-04-05 20:31:23 +00:00
dumpfs Replace incomprehensive description of -m by much clearer text from OpenBSD, 2007-05-12 22:35:22 +00:00
dumpon Whitespace and style nits. 2006-10-31 22:36:49 +00:00
fdisk Add Apple HFS+ (0xAF) MBR partition type identificator. 2007-05-06 18:48:30 +00:00
fdisk_pc98 Another merging from sbin/fdisk/fdisk.8. 2007-05-10 12:33:00 +00:00
ffsinfo Default output to stdout as the man page suggests. 2007-02-14 23:22:33 +00:00
fsck
fsck_ffs Convert fsck_ffs to nmount(). This seems to solve 2007-09-19 01:24:19 +00:00
fsck_msdosfs
fsdb Update after function renames. 2006-10-31 22:07:29 +00:00
fsirand
gbde Remove temporary files when there are no longer needed. 2007-04-06 11:16:11 +00:00
geom Fix a last-minute, but more importantly, an untested change that 2007-10-21 19:38:21 +00:00
ggate Tweak the handling of "WITHOUT_LIBPTHREAD". Also remove the accidental 2007-10-09 23:31:11 +00:00
gpt First cut at support for booting a GPT labeled disk via the BIOS bootstrap 2007-10-24 21:33:00 +00:00
growfs Teach about new fields (cg_unrefs and fs_unrefs) and new FS_GJOURNAL flag. 2006-10-31 22:02:24 +00:00
gvinum Revise markup. 2006-09-30 11:02:17 +00:00
idmapd .PATH isn't necessary here. 2006-10-15 13:51:49 +00:00
ifconfig Fix the module name matching to the drivers present in the kernel. Previously 2007-10-04 09:45:41 +00:00
init I understood the MLINK part incorrectly, it should be the other way around 2007-06-01 21:48:07 +00:00
ipf Exclude inet_addr.c from the build. 2007-06-11 19:38:38 +00:00
ipfw Change IPTOS_CE to IPTOS_ECN_CE. 2007-10-19 18:24:19 +00:00
iscontrol First round of cleanups. 2007-07-24 18:08:16 +00:00
kldconfig
kldload Mark up lkm with .Nm, since lkm is name of an api. 2007-02-13 17:06:15 +00:00
kldstat Add the full module path name to the kld_file_stat structure 2007-10-22 04:12:57 +00:00
kldunload Mark up lkm with .Nm, since lkm is name of an api. 2007-02-13 17:06:15 +00:00
ldconfig Remove unused reference to objformat.h 2007-01-25 22:38:58 +00:00
mca Markup nit. 2006-09-30 11:12:36 +00:00
md5 Fix an 11 year old mistake: Let the hash functions take a void* instead 2006-01-17 15:35:57 +00:00
mdconfig Add an example which shows how mdconfig(8) can be used 2007-05-18 13:57:17 +00:00
mdmfs -n is used by newfs to tell "do not generate a .snap directory" instead of 2007-05-14 19:23:13 +00:00
mknod In the previous changeset a cast of myminor to u_int were 2007-06-14 03:16:16 +00:00
mksnap_ffs
mount Remove stale reference to mount_std. 2007-10-19 05:29:18 +00:00
mount_autofs
mount_cd9660 Fixing multi-session disc mount by passing the correct "ssector" option 2005-12-19 05:52:37 +00:00
mount_ext2fs Convert mount_ext2fs to a simple program which passes "-o option" to nmount(). 2007-01-28 00:51:01 +00:00
mount_hpfs
mount_msdosfs Pass "errmsg" to nmount(), so that if nmount() fails, we can get 2007-01-29 01:49:08 +00:00
mount_nfs Add "fg" option as antonym to "bg"; add "hard" option as antonym to "soft". 2007-03-05 14:47:54 +00:00
mount_ntfs
mount_nullfs Add a missing .Pp call. 2006-04-19 19:21:42 +00:00
mount_reiserfs
mount_std Reduce the number of errors under WARNS=6 2006-09-13 04:50:44 +00:00
mount_udf style.Makefile(5): Remove -Wall from CFLAGS. 2006-07-17 20:53:25 +00:00
mount_unionfs Added whiteout behavior option. ``-o whiteout=always'' is default mode 2007-10-14 13:55:38 +00:00
natd Summer of Code 2005: improve libalias - part 1 of 2 2006-09-26 23:26:53 +00:00
newfs Document -J in usage. 2007-03-02 20:07:59 +00:00
newfs_msdos The newfs_msdos utility does not store the boot signature in the 2007-05-31 20:06:46 +00:00
nfsiod
nos-tun
pfctl Link pf 4.1 to the build: 2007-07-03 12:46:08 +00:00
pflogd
ping Commit IPv6 support for FAST_IPSEC to the tree. 2007-07-01 12:08:08 +00:00
ping6 Remove the -DFAST_IPSEC from Makefiles again. 2007-07-05 08:56:46 +00:00
quotacheck Fix "quotacheck -a" from core dumping on 64 bit systems by correctly 2007-09-16 02:59:32 +00:00
rcorder do_file() is called recursively from several places and cannot 2006-05-20 05:47:18 +00:00
reboot - Sweep the boot(8) man page after addition of boot.config(5). 2007-08-18 07:58:36 +00:00
recoverdisk Improve reporting in recoverdisk a good deal. 2007-04-23 12:17:27 +00:00
restore Move macros describing extended attributes in UFS from 2007-03-06 08:13:21 +00:00
route Obey MK_INET6_SUPPORT. 2006-07-27 13:26:29 +00:00
routed Sync up with rhyolite routed 2.31 which fixes the handling of varargs. 2006-11-05 14:49:47 +00:00
rtsol Add eye candy while I'm here: a blank line between 2006-07-27 18:28:14 +00:00
savecore Check fdopen return value. 2007-05-28 09:48:25 +00:00
sconfig Add FBSDID, rename local variable time to not conflict with time() 2006-09-12 17:54:35 +00:00
setkey Commit IPv6 support for FAST_IPSEC to the tree. 2007-07-01 12:08:08 +00:00
shutdown
slattach
spppcontrol
startslip
sunlabel
swapon
sysctl Backout sensors framework. 2007-10-15 20:00:24 +00:00
tunefs o s/filesystem/file system/g. 2007-09-23 16:06:37 +00:00
umount
Makefile Introduce Danny Braniss' iSCSI initiator, version 2.0.99. Please read the 2007-07-24 15:35:02 +00:00
Makefile.inc Reimplementation of world/kernel build options. For details, see: 2006-03-17 18:54:44 +00:00