[PATCH] nvme-core: update NS Attr Changed AEN handling for ANA group

Hannes Reinecke hare at suse.de
Wed Dec 9 02:26:16 EST 2020


On 12/9/20 1:20 AM, Keith Busch wrote:
> On Wed, Dec 09, 2020 at 12:07:08AM +0000, Knight, Frederick wrote:
>> If you want to make that a transition, then bring a TPAR to change it.
>>
>> When ANA Groups are created, they already have a state.  There is NO transition; there is NO AEN.
> 
> The requirement doesn't even mention the word "transition", so it's a
> moot point. The requirement says "upon entry". Whether that entry occurs
> because of a transition to it or because it sprung into existence
> already having entered that state is not a disticition made in the spec.
> If you want that disticition to be written in spec, then feel free to
> bring an ECN to clarify it.
> 
What are you discussing here?
The original situation was that a namespace was created within an 
existing subsystem and existing ANA groups and namespaces, where the new 
namespace was _not_ part of any of the existing ANA groups.
And you already had agreed that a namespace _creation_ (which this most 
definitely is) should not send ANA AENs.

So where is the 'transition' here? Is this due to the fact the ANA group 
creation and namespace creation might be two distinct events?

Clearly, the ANA group has to be created at one point.
And namespace creation might be happening at a different time, true; but 
they might also be a single event.
If it's a single event then I think we've already agreed that ANA change 
AENs will be suppressed.

I don't think it'll be possible to create an ANA group _after_ creating 
a namespace, as the definition for the ANAGRPID field in the 'namespace 
identify' data structure says:

   This field indicates the ANA Group Identifier of the ANA group
  (refer to section 8.20.2) of which the namespace is a member.
  Each namespace that is attached to a controller that supports
  Asymmetric Namespace Access Reporting (refer to the CMIC field)
  shall report a valid ANAGRPID.

Which would require us to create the ANA group prior to the namespace.
But then we cannot report the empty ANA group as per definition of the 
ANA log page:

  Number of ANA Group Descriptors: This field indicates the number
  of ANA Group Descriptors available in the log page. The log page
  shall contain one ANA Group Descriptor for each ANA Group that
  contains Namespaces that are attached to the controller.

So even if you are right and we would have to expect an ANA AEN, the log 
page would have no way of reporting it. And we would end up in exactly 
the same situation as we are now, namely having to re-read the ANA log 
page after namespace creation.

Cheers,

Hannes
-- 
Dr. Hannes Reinecke                Kernel Storage Architect
hare at suse.de                              +49 911 74053 688
SUSE Software Solutions GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), Geschäftsführer: Felix Imendörffer



More information about the Linux-nvme mailing list