Commit Graph

6 Commits

Author SHA1 Message Date
Marcel Moolenaar
27e701229c /* -> /*- for license. 2005-08-31 01:47:19 +00:00
Marcel Moolenaar
6686e95fef Implement a remove command. The remove command iterates the GPT
partitions and removes any that matches the pre-conditions. The
options are the same for the add command and are used to select
the partitions to remove.
Currently the remove command without any options deletes all GPT
partitions. This is rather harmful and will need anti-footshooting
measures.
2004-08-07 07:41:37 +00:00
Marcel Moolenaar
f61bdfe072 o Save the partition number (=index) in the internal map. The index
starts at 1. No index is represented by 0.
o  Change the show command to display the partition number at the expense
   of the partition end columm. We already display the start and size.
o  Enhance the add command to accept the -i option. The -i option allows
   the user to specify which partition number the new partition should
   get.
o  Update the manpage accordingly.
2004-08-07 06:10:45 +00:00
Marcel Moolenaar
2a944ecdef o Newer EFI implementations require that a GPT is preceeded by
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)
2002-12-02 01:42:03 +00:00
Marcel Moolenaar
5d5e1c2b12 o Add functionality to add a GPT partition,
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).
2002-10-27 03:23:05 +00:00
Peter Wemm
80643c90e3 Grab a snapshot of Marcel's gpt tool. This is still a work-in-progress
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.
2002-07-20 19:27:43 +00:00