summaryrefslogtreecommitdiff
path: root/cmds-device.c
diff options
context:
space:
mode:
authorMisono, Tomohiro <misono.tomohiro@jp.fujitsu.com>2017-10-20 10:43:05 +0900
committerDavid Sterba <dsterba@suse.com>2017-11-14 15:59:00 +0100
commit2192bd5cfc344e6352ccba044c21195cca7ebe2d (patch)
treee1aecdea270cdf815a89c5ee89c38e00988a902b /cmds-device.c
parent435145613ea3330267d95ac80ae8fb5ae1134373 (diff)
btrfs-progs: doc: add description of missing and example, of device remove
This patch updates help/document of "btrfs device remove" in two points: 1. Add explanation of 'missing' for 'device remove'. This is only written in wikipage currently. (https://btrfs.wiki.kernel.org/index.php/Using_Btrfs_with_Multiple_Devices) 2. Add example of device removal in the man document. This is because that explanation of "remove" says "See the example section below", but there is no example of removal currently. Signed-off-by: Tomohiro Misono <misono.tomohiro@jp.fujitsu.com> Reviewed-by: Satoru Takeuchi <satoru.takeuchi@gmail.com> [ move "" from the macro to help strings ] Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'cmds-device.c')
-rw-r--r--cmds-device.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/cmds-device.c b/cmds-device.c
index 3b6b9855..f4cdb39f 100644
--- a/cmds-device.c
+++ b/cmds-device.c
@@ -224,9 +224,16 @@ static int _cmd_device_remove(int argc, char **argv,
return !!ret;
}
+#define COMMON_USAGE_REMOVE_DELETE \
+ "If 'missing' is specified for <device>, the first device that is", \
+ "described by the filesystem metadata, but not present at the mount", \
+ "time will be removed. (only in degraded mode)"
+
static const char * const cmd_device_remove_usage[] = {
"btrfs device remove <device>|<devid> [<device>|<devid>...] <path>",
"Remove a device from a filesystem",
+ "",
+ COMMON_USAGE_REMOVE_DELETE,
NULL
};
@@ -238,6 +245,8 @@ static int cmd_device_remove(int argc, char **argv)
static const char * const cmd_device_delete_usage[] = {
"btrfs device delete <device>|<devid> [<device>|<devid>...] <path>",
"Remove a device from a filesystem (alias of \"btrfs device remove\")",
+ "",
+ COMMON_USAGE_REMOVE_DELETE,
NULL
};