]> www.infradead.org Git - users/sagi/nvme-cli.git/commitdiff
ocp: use NVME_ARGS macro definition by eol-plp-failure-mode command
authorTokunori Ikegami <ikegami.t@gmail.com>
Sun, 7 Jul 2024 13:55:14 +0000 (22:55 +0900)
committerDaniel Wagner <wagi@monom.org>
Tue, 9 Jul 2024 10:21:18 +0000 (12:21 +0200)
The verbose, output-format and timeout options enabled by the macro.

Signed-off-by: Tokunori Ikegami <ikegami.t@gmail.com>
plugins/ocp/ocp-nvme.c

index e9ebc4012425db81fa770a497a2bceff2acfcec0..88ac212e49282480caa808fa6bac41b9bbb54c1a 100644 (file)
@@ -775,14 +775,12 @@ static int eol_plp_failure_mode(int argc, char **argv, struct command *cmd,
                .sel = 0,
        };
 
-       OPT_ARGS(opts) = {
-               OPT_BYTE("mode", 'm', &cfg.mode, mode),
-               OPT_FLAG("save", 's', &cfg.save, save),
-               OPT_BYTE("sel", 'S', &cfg.sel, sel),
-               OPT_FLAG("no-uuid", 'n', NULL,
-                        "Skip UUID index search (UUID index not required for OCP 1.0)"),
-               OPT_END()
-       };
+       NVME_ARGS(opts,
+                 OPT_BYTE("mode", 'm', &cfg.mode, mode),
+                 OPT_FLAG("save", 's', &cfg.save, save),
+                 OPT_BYTE("sel", 'S', &cfg.sel, sel),
+                 OPT_FLAG("no-uuid", 'n', NULL,
+                          "Skip UUID index search (UUID index not required for OCP 1.0)"));
 
        err = parse_and_open(&dev, argc, argv, desc, opts);
        if (err)