]> www.infradead.org Git - users/sagi/nvme-cli.git/commitdiff
nvme-cli: generate spec-compliant UUID NQNs
authorDaniel Verkamp <daniel.verkamp@intel.com>
Wed, 30 Aug 2017 22:25:16 +0000 (15:25 -0700)
committerKeith Busch <keith.busch@intel.com>
Thu, 31 Aug 2017 17:05:22 +0000 (13:05 -0400)
The gen-hostnqn command previously generated UUID NQNs in a format that
does not match the NVMe specification.

Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Keith Busch <keith.busch@intel.com>
Documentation/nvme-gen-hostnqn.txt
nvme.c

index 6d5346face5cd06951f1aa8d6f733f2d5a0bb06a..9efefb5a451177113c8459f0810b1ca59b4a1c09 100644 (file)
@@ -13,7 +13,7 @@ SYNOPSIS
 DESCRIPTION
 -----------
 Generate a random host NQN in the form:
-nqn.2014-08.org.nvmexpress:NVMf:uuid:1b4e28ba-2fa1-11d2-883f-0016d3cca427
+nqn.2014-08.org.nvmexpress:uuid:1b4e28ba-2fa1-11d2-883f-0016d3cca427
 and prints it to stdout.
 
 OPTIONS
diff --git a/nvme.c b/nvme.c
index 676e8bfa1f4d21e45d9976dbe3ac34f21506b444..f1d6d65cbe6a5a2d8ef1d0b6cd414db9d050375e 100644 (file)
--- a/nvme.c
+++ b/nvme.c
@@ -3217,7 +3217,7 @@ static int gen_hostnqn_cmd(int argc, char **argv, struct command *command, struc
 
        uuid_generate_random(uuid);
        uuid_unparse_lower(uuid, uuid_str);
-       printf("nqn.2014-08.org.nvmexpress:NVMf:uuid:%s\n", uuid_str);
+       printf("nqn.2014-08.org.nvmexpress:uuid:%s\n", uuid_str);
        return 0;
 }
 #else