[DISCUSSION] NVMe firmware_rev not updated after firmware commit when AEN is not supported
wangzhiqiang (Q)
wangzhiqiang95 at h-partners.com
Mon Oct 20 02:20:40 PDT 2025
Hi all
I encountered an issue while working with the NVMe driver on kernel v6.6.
When I use ioctl with NVME_IOCTL_ADMIN_CMD to passthrough Firmware Image Download(CA=3) and Firmware Commit commands
to upgrade the firmware image on an NVMe drive, if the drive does not support the Asynchronous Event Notice (AEN)
for Firmware Activation Notices, the kernel does not receive the NVME_AER_NOTICE_FW_ACT_STARTING event. As a result,
ctrl->subsys->firmware_rev in the kernel is not updated, and the corresponding /sys/class/nvme/nvme0/firmware_rev still
shows the outdated firmware revision.
According to the NVMe specification, a Commit Action (CA) = 3 indicates that the firmware image should be activated
without performing a controller reset (even though a reset would normally cause the controller to be re-identified).
However, since most vendor drives currently either do not support Firmware Activation Notices or have not enabled it,
leads to an inconsistency between the actual firmware version on the device and the value exposed by the kernel.
Would it make sense to add a userspace interface that allows applications to query the latest firmware revision in real time?
For example, this could be implemented via an ioctl or by providing a mechanism to refresh or read the updated value through sysfs.
Best regards
wangzhiqiang
jingsixiang
More information about the Linux-nvme
mailing list