From: jthumshirn@suse.de (Johannes Thumshirn)
Subject: [PATCH nvmetcli] nvmetcli: remove status method for the UIPortNode
Date: Thu, 30 Nov 2017 11:27:23 +0100 [thread overview]
Message-ID: <20171130102723.6488-1-jthumshirn@suse.de> (raw)
nvmetcli defines a status method for the UIPortNode class but there is
no corresponding 'enable' file in configfs so typing in status will
always result in nvmetcli printing disbaled if one types 'status' in
the port node:
/> cd ports/1/
/ports/1> status
Status for /ports/1: disabled
/ports/1>
There are two possible ways for fixing this issue, provide a configfs
file to enable/disable the port node in the kernel or delete the
method in nvmetcli. Having a configfs file in the kernel is pointless,
as ports get enabled when symlinked to a namespace so zap the pointless status
method in user-space.
Signed-off-by: Johannes Thumshirn <jthumshirn at suse.de>
Reported-by: Hannes Reinecke <hare at suse.de>
---
nvmetcli | 5 -----
1 file changed, 5 deletions(-)
diff --git a/nvmetcli b/nvmetcli
index 5378365eb91f..4fbc12ec430f 100755
--- a/nvmetcli
+++ b/nvmetcli
@@ -356,11 +356,6 @@ class UIPortNode(UINode):
UIPortSubsystemsNode(self)
UIReferralsNode(self)
- def status(self):
- if self.cfnode.get_enable():
- return "enabled"
- return "disabled"
-
class UIPortSubsystemsNode(UINode):
def __init__(self, parent):
--
2.13.6
next reply other threads:[~2017-11-30 10:27 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-30 10:27 Johannes Thumshirn [this message]
2017-11-30 14:27 ` [PATCH nvmetcli] nvmetcli: remove status method for the UIPortNode Christoph Hellwig
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20171130102723.6488-1-jthumshirn@suse.de \
--to=jthumshirn@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox