search for: guestfs_mkfs_opts_label_bitmask

Displaying 2 results from an estimated 2 matches for "guestfs_mkfs_opts_label_bitmask".

2015 Jan 13
0
[PATCH] format, make-fs: specify the label on mkfs
...opts (g, filesystem, dev, -1) == -1) - exit (EXIT_FAILURE); + struct guestfs_mkfs_opts_argv optargs = { .bitmask = 0 }; if (label) { - if (guestfs_set_label (g, dev, label) == -1) - exit (EXIT_FAILURE); + optargs.label = label; + optargs.bitmask |= GUESTFS_MKFS_OPTS_LABEL_BITMASK; } + + if (guestfs_mkfs_opts_argv (g, filesystem, dev, &optargs) == -1) + exit (EXIT_FAILURE); } if (free_dev) diff --git a/make-fs/make-fs.c b/make-fs/make-fs.c index 841c202..14729ad 100644 --- a/make-fs/make-fs.c +++ b/make-fs/make-fs.c @@ -755,9 +755,15 @@ do_...
2015 Jan 13
3
[PATCH] mkfs: add 'label' optional argument
Add the 'label' optional argument to the mkfs action, so it is possible to set a filesystem label direct when creating it. There may be filesystems not supporting changing the label of existing filesystems but only setting it at creation time, so this new optarg will help. Implement it for the most common filesystems (ext*, fat, ntfs, btrfs, xfs), giving an error for all the others, just