mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-02 12:20:51 +00:00
Add ZFS support.
MFC after: 1 week PR: bin/119976 Submitted by: Simun Mikecin numisemis of yahoo.com
This commit is contained in:
parent
23490135ae
commit
d27c29a34e
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=176010
@ -130,7 +130,7 @@ option allows the user to specify the partition type.
|
||||
The type is given as an UUID, but
|
||||
.Nm
|
||||
accepts
|
||||
.Cm boot , efi , swap , ufs , hfs , linux
|
||||
.Cm boot , efi , swap , ufs , zfs, hfs , linux
|
||||
and
|
||||
.Cm windows
|
||||
as aliases for the most commonly used partition types.
|
||||
|
@ -118,6 +118,13 @@ migrate_disklabel(int fd, off_t start, struct gpt_ent *ent)
|
||||
ent->ent_name, 36);
|
||||
break;
|
||||
}
|
||||
case FS_ZFS: {
|
||||
uuid_t zfs = GPT_ENT_TYPE_FREEBSD_ZFS;
|
||||
le_uuid_enc(&ent->ent_type, &zfs);
|
||||
utf8_to_utf16("FreeBSD ZFS partition",
|
||||
ent->ent_name, 36);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
warnx("%s: warning: unknown FreeBSD partition (%d)",
|
||||
device_name, dl->d_partitions[i].p_fstype);
|
||||
|
@ -64,6 +64,7 @@ friendly(uuid_t *t)
|
||||
static uuid_t swap = GPT_ENT_TYPE_FREEBSD_SWAP;
|
||||
static uuid_t ufs = GPT_ENT_TYPE_FREEBSD_UFS;
|
||||
static uuid_t vinum = GPT_ENT_TYPE_FREEBSD_VINUM;
|
||||
static uuid_t zfs = GPT_ENT_TYPE_FREEBSD_ZFS;
|
||||
static char buf[80];
|
||||
char *s;
|
||||
|
||||
@ -80,6 +81,8 @@ friendly(uuid_t *t)
|
||||
return ("FreeBSD UFS/UFS2");
|
||||
if (uuid_equal(t, &vinum, NULL))
|
||||
return ("FreeBSD vinum");
|
||||
if (uuid_equal(t, &zfs, NULL))
|
||||
return ("FreeBSD ZFS");
|
||||
|
||||
if (uuid_equal(t, &freebsd, NULL))
|
||||
return ("FreeBSD legacy");
|
||||
|
Loading…
Reference in New Issue
Block a user