a PMBR. Make sure the create command creates a PMBR as well
(if not already present).
o When parsing the MBR, explicitly check for a PMBR and create
a PMBR map node if one is found.
o When parsing the MBR, recurse to handle extended partitions.
This allows us to flatten nested MBRs when migrating to a
GPT.
o Have the migrate command bail out if it encounters a partition
it doesn't know how to migrate. This avoids data loss.
o Change the output of the show command so that the UUIDs of the
GPT partitions fit on the same line.
o Show when partitions are extended partitions and add the PMBR
type.
Approved by: re (blanket)
UUIDs can then be limited to those cases when an alias doesn't exist.
This greatly increases the likelyhood that a sysadmin finishes the
partitioning without intermittent mental breakdowns. Current aliases
are "efi", "swap" and "ufs".
While here, staticize global variables and expand the usage message.
Approved by: re (blanket)
<sys/gpt.h>. This avoids having to include both <sys/uuid.h> and
<uuid.h>, which is considered by your friendly committer to be
aestheticly displeasing (= ballyhoo barf barf :-)
o Use DCE compliant UUID functions and provide local
implementations if they don't exist,
o Move dumping of the map to show.c and print the
partition type,
o Some cleanups and rearrangements.
The default GPT partition type is UFS. When no starting block
or size are specified, the tool will create a partition in the
first free space it find (or that fits, depending on the size).
code is directly copied from migrate.c. The intend is to express
migrate in terms of create and add. The functionality to add
partitions is not yet there.
result of an incomplete migration. An incomplete migration is
one where the MBR is not turned into a PMBR after creating the
GPT. This early in the game it's more convenient to allow the
inconsistency, because that avoids that we have to destroy the
MBR partitioning for now.
but is useful to have handy. EFI GPT partitions are used instead of the
fdisk+disklabel combination. They are pure 64 bit LBA, are fully
extensible, support up to 16383 partitons per disk, etc.