Skip to contentSkip to conversation

nvmetcli: fixup ana groupid setting for namespaces

PATCH Applied Hannes Reinecke 2 participants 2 messages Feb 5, 2021 – Jul 13, 2021 NVMe

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 nvmetcli: fixup ana groupid setting for namespaces

The ANA group of a namespace is displayed, but can't be set. So add a new attribute group 'ana' to the namespace such that it can be set via 'set ana grpid'.

---
 nvmet/nvme.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
nvmet/nvme.py +1 -1
index 83fd75b..d170204 100644
@@ -567,7 +567,7 @@ class Namespace(CFSNode):
             if nsid < 1 or nsid > self.MAX_NSID:
                 raise CFSError("NSID must be 1 to %d" % self.MAX_NSID)
 
-        self.attr_groups = ['device']
+        self.attr_groups = ['device', 'ana']
         self._subsystem = subsystem
         self._nsid = nsid
         self._path = "%s/namespaces/%d" % (self.subsystem.path, self.nsid)
Signature · 7 lines
2.29.2


_______________________________________________
Linux-nvme mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-nvme