Project

General

Profile

Actions

Feature #14467

closed

Update nvmeadm 'get-features event' for NVMe 1.4

Added by Andy Fiddaman 6 months ago. Updated 6 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
driver - device drivers
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Bite-size
Tags:
Gerrit CR:

Description

Although nvmeadm identify knows about the Optional Asynchronous Event Support (OAES) bits up to the 1.4 standard, nvmeadm get-feature event does not know about the corresponding bits in the Asynchronous Event Configuration (AEC) feature word.

# nvmeadm -v identify nvme0
nvme0: Identify Controller
...
    Optional Asynchronous Events Supported
      Namespace Attribute Notices:          supported
      Firmware Activation Notices:          unsupported
      Asynchronous Namespace Access Change Notices: unsupported
      Predictable Latency Event Aggregation: unsupported
      LBA Status Information Notices:       unsupported
      Endurance Group Event Aggregate Log Page Change Notices: unsupported
# nvmeadm get-features nvme0 event
nvme0: Get Features
  Asynchronous Event Configuration
    Available Space below threshold:        disabled
    Temperature above threshold:            disabled
    Device Reliability compromised:         disabled
    Media read-only:                        disabled

There is also a new asynchronous event type introduced in NVMe 1.2 for notices, which could be supported. Currently an AEN is logged as an unknown event:

Jan 31 17:18:01 bhyvetest nvme: [ID 806610 kern.warning] WARNING: nvme0: unknown async event received, type = 2, info = 0, logpage = 4

Related issues

Related to illumos gate - Feature #13530: Update nvmeadm identify to 1.4ClosedRobert Mustacchi

Actions
Actions #1

Updated by Andy Fiddaman 6 months ago

Actions #2

Updated by Electric Monk 6 months ago

  • Gerrit CR set to 1997
Actions #3

Updated by Andy Fiddaman 6 months ago

I've tested this change mostly in a bhyve VM with the latest bhyve sync pieces that support namespace change AENs. I've also tested on some real hardware, although only NVME 1.0 pieces so the new fields show up as disabled/unsupported.

root@bhyvetest:~# nvmeadm list
nvme0: model: bhyve-NVMe, serial: NVME-4-0, FW rev: 1.0, NVMe v1.3
  nvme0/589cfc2045c20001 (c1t589CFC2045C20001d0): Size = 15360 MB, Capacity = 15360 MB, Used = 15360 MB

root@bhyvetest:~# nvmeadm -v identify nvme0
nvme0: Identify Controller
  Controller Capabilities and Features
    Model:                                  bhyve-NVMe
    Serial:                                 NVME-4-0
    Firmware Revision:                      1.0
...
    Optional Asynchronous Events Supported
      Namespace Attribute Notices:          supported
      Firmware Activation Notices:          unsupported
      Asynchronous Namespace Access Change Notices: unsupported
      Predictable Latency Event Aggregation: unsupported
      LBA Status Information Notices:       unsupported
      Endurance Group Event Aggregate Log Page Change Notices: unsupported

root@bhyvetest:~# nvmeadm get-features nvme0 event
nvme0: Get Features
  Asynchronous Event Configuration
    Available Space below threshold:        enabled
    Temperature above threshold:            enabled
    Device Reliability compromised:         enabled
    Media read-only:                        enabled
    Namespace attribute notices:            enabled
    Firmware activation notices:            enabled
    Telemetry log notices:                  disabled
    ANA change notices:                     disabled
    Predictable latency event aggr. LCNs:   disabled
    LBA status information notices:         disabled
    Endurance group event aggregate LCNs:   disabled

and when causing the bhyve NVMe device to send a namespace change AEN:

Feb  6 23:22:40 bhyvetest nvme: [ID 122171 kern.notice] NOTICE: nvme0: namespace attribute change event, logpage = 4
Feb  6 23:22:40 bhyvetest nvme: [ID 388270 kern.info] NOTICE: nvme0: namespace 1 (589cfc2045c20001) has changed.
Actions #4

Updated by Electric Monk 6 months ago

  • Status changed from In Progress to Closed
  • % Done changed from 0 to 100

git commit 04be5853f332657b12766ebc8691a5d1ffd48958

commit  04be5853f332657b12766ebc8691a5d1ffd48958
Author: Andy Fiddaman <omnios@citrus-it.co.uk>
Date:   2022-02-09T10:16:28.000Z

    14467 Update nvmeadm 'get-features event' for NVMe 1.4
    Reviewed by: Hans Rosenfeld <rosenfeld@grumpf.hope-2000.org>
    Reviewed by: Toomas Soome <tsoome@me.com>
    Approved by: Dan McDonald <danmcd@joyent.com>

Actions

Also available in: Atom PDF