summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cmd_device.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/cmd_device.c b/cmd_device.c
index f9e975ab..b18bdd8c 100644
--- a/cmd_device.c
+++ b/cmd_device.c
@@ -331,6 +331,7 @@ static void device_set_state_usage(void)
"\n"
"Options:\n"
" -f, --force Force, if data redundancy will be degraded\n"
+ " --force-if-data-lost Force, if data will be lost\n"
" -o, --offline Set state of an offline device\n"
" -h, --help display this help and exit\n"
"Report bugs to <linux-bcache@vger.kernel.org>");
@@ -341,6 +342,7 @@ int cmd_device_set_state(int argc, char *argv[])
{
static const struct option longopts[] = {
{ "force", 0, NULL, 'f' },
+ { "force-if-data-lost", 0, NULL, 'F' },
{ "offline", 0, NULL, 'o' },
{ "help", 0, NULL, 'h' },
{ NULL }
@@ -355,6 +357,10 @@ int cmd_device_set_state(int argc, char *argv[])
case 'f':
flags |= BCH_FORCE_IF_DEGRADED;
break;
+ case 'F':
+ flags |= BCH_FORCE_IF_DEGRADED;
+ flags |= BCH_FORCE_IF_LOST;
+ break;
case 'o':
offline = true;
break;