All of lore.kernel.org
 help / color / mirror / Atom feed
From: maxg@mellanox.com (Max Gurtovoy)
Subject: [PATCH v1 3/3] nvmet: Add port transport state flag
Date: Wed, 16 May 2018 15:40:12 +0300	[thread overview]
Message-ID: <5959e3db-6145-25ba-8d73-bc410e75b7a2@mellanox.com> (raw)
In-Reply-To: <20180417152815.GE25823@lst.de>



On 4/17/2018 6:28 PM, Christoph Hellwig wrote:
> On Sun, Apr 15, 2018@11:54:59AM +0300, Sagi Grimberg wrote:
>>
>>
>>>> +{
>>>> +	struct nvmet_port *port = to_nvmet_port(item);
>>>> +
>>>> +	return sprintf(page, "%s\n",
>>>> +		nvmet_is_port_active(port) ? "up" : "down");
>>>> +}
>>>> +
>>>> +CONFIGFS_ATTR_RO(nvmet_, trstate);
>>>> +
>>>>    /*
>>>>     * Namespace structures & file operation functions below
>>>>     */
>>>> @@ -870,6 +880,7 @@ static struct configfs_attribute *nvmet_port_attrs[] = {
>>>>    	&nvmet_attr_addr_traddr,
>>>>    	&nvmet_attr_addr_trsvcid,
>>>>    	&nvmet_attr_addr_trtype,
>>>> +	&nvmet_attr_trstate,
>>>
>>> Please don't create attributes without a group ever.  Just create a
>>> different group which isn't serialized, e.g. state as the group name
>>> and then transport as the attribute name inside it, or something similar.
>>
>> We already have ns enable which is not within a group. How is that
>> different?
> 
> enable is a magic trigger that we can't handle automatically when
> restoring the state in nvmetcli.  trstate is a read-only field that
> make sense to show with generic code.
> 

Sagi,
are you going to send another version for this one with the above changes ?
If so, a fix should be made also in nvmetcli...

-Max.

  reply	other threads:[~2018-05-16 12:40 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-12  8:06 [PATCH v1 0/3] nvmet-rdma automatic port re-activation Sagi Grimberg
2018-04-12  8:06 ` [PATCH v1 1/3] nvmet-rdma: automatic listening " Sagi Grimberg
2018-04-12 13:08   ` Israel Rukshin
2018-04-12  8:06 ` [PATCH v1 2/3] nvmet: Add fabrics ops to port Sagi Grimberg
2018-04-12  8:06 ` [PATCH v1 3/3] nvmet: Add port transport state flag Sagi Grimberg
2018-04-13 17:14   ` Christoph Hellwig
2018-04-15  8:54     ` Sagi Grimberg
2018-04-17 15:28       ` Christoph Hellwig
2018-05-16 12:40         ` Max Gurtovoy [this message]
2018-04-12  8:06 ` [PATCH 4/3 v1 nvmetcli] nvmetcli: expose nvmet port status and state Sagi Grimberg
2018-04-12 11:25   ` Nitzan Carmi
2018-04-12 12:34     ` Sagi Grimberg
2018-04-13 17:00 ` [PATCH v1 0/3] nvmet-rdma automatic port re-activation Christoph Hellwig
2018-04-15  8:53   ` Sagi Grimberg
2018-04-17 15:43     ` Christoph Hellwig
2018-04-20  2:48     ` Doug Ledford

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=5959e3db-6145-25ba-8d73-bc410e75b7a2@mellanox.com \
    --to=maxg@mellanox.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.