Linux-NVME Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/3] nvme: make SMART / Health Status AENs reach hwmon alarms
@ 2026-11-24 12:00 Guixin Liu
  2026-11-24 12:00 ` [PATCH v4 1/3] nvme: define an event bit enum for nvme_ctrl::events Guixin Liu
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Guixin Liu @ 2026-11-24 12:00 UTC (permalink / raw)
  To: Keith Busch, Jens Axboe, Christoph Hellwig, Sagi Grimberg,
	Nilay Shroff, Daniel Wagner, Hannes Reinecke
  Cc: linux-nvme

The NVMe hwmon support exposes the temperature alarm as a plain sysfs
attribute, so monitoring tools have to poll temp1_alarm to learn about
a critical temperature condition. The device does send a SMART / Health
Status asynchronous event when a critical warning is raised, but the
host never enables it in the Asynchronous Event Configuration, and the
completion path silently drops the event.

The temperature warning is subscribed unconditionally when hwmon is
present (it has no OAES capability bit), a work item embedded in
nvme_ctrl re-reads the SMART log to clear the latched event -- the
same shape as the namespace scan reading the changed namespace list --
and the alarm is announced with hwmon_notify_event(), which also feeds
the registered thermal zone.

Testing: verified end to end against QEMU's nvme emulation: injecting
smart_critical_warning over QMP delivers the AEN, poll(2) on
temp1_alarm wakes immediately with EPOLLERR|EPOLLPRI and reads alarm=1;
clearing the warning produces no event and no spurious wake;
re-injecting the bit wakes again; enabling the spare-block warning
through an admin passthrough delivers the AEN without waking the
temperature alarm; a controller modeled to reject the critical warning
subscription with Invalid Field in Command falls back to the
notice-only mask, which a Get Features of the Asynchronous Event
Configuration confirms; a temperature event whose warning recovers
before the deferred log is read still wakes the poll with alarm=0.

Changes since v3:

 - split the preparation into its own patches: an event bit enum for
   nvme_ctrl::events, whose only bit was indexed with an AER subtype
   value so far, and the SMART / Health Status asynchronous event
   subtype values
 - notify temp1_alarm when the event information indicates the
   temperature threshold, not only when the re-read log still has the
   temperature critical warning set, so that a transient excursion
   that recovered before the log is read is still reported (Nilay
   Shroff)

Link: https://lore.kernel.org/all/20261123112342.2761131-1-kanie@linux.alibaba.com/

Guixin Liu (3):
  nvme: define an event bit enum for nvme_ctrl::events
  nvme: define the SMART / Health Status async event subtypes
  nvme-hwmon: notify hwmon alarms on the SMART / Health Status AEN

 drivers/nvme/host/core.c  | 32 +++++++++++++++++++++++++++----
 drivers/nvme/host/hwmon.c | 37 +++++++++++++++++++++++++++++++++++++
 drivers/nvme/host/nvme.h  | 25 +++++++++++++++++++++++++
 include/linux/nvme.h      |  6 ++++++
 4 files changed, 96 insertions(+), 4 deletions(-)

--
2.43.7


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH v4 1/3] nvme: define an event bit enum for nvme_ctrl::events
  2026-11-24 12:00 [PATCH v4 0/3] nvme: make SMART / Health Status AENs reach hwmon alarms Guixin Liu
@ 2026-11-24 12:00 ` Guixin Liu
  2026-11-24 15:24   ` Nilay Shroff
  2026-11-25  5:17   ` Christoph Hellwig
  2026-11-24 12:00 ` [PATCH v4 2/3] nvme: define the SMART / Health Status async event subtypes Guixin Liu
  2026-11-24 12:00 ` [PATCH v4 3/3] nvme-hwmon: notify hwmon alarms on the SMART / Health Status AEN Guixin Liu
  2 siblings, 2 replies; 12+ messages in thread
From: Guixin Liu @ 2026-11-24 12:00 UTC (permalink / raw)
  To: Keith Busch, Jens Axboe, Christoph Hellwig, Sagi Grimberg,
	Nilay Shroff, Daniel Wagner, Hannes Reinecke
  Cc: linux-nvme

The only bit used in nvme_ctrl::events is indexed with
NVME_AER_NOTICE_NS_CHANGED, an AER subtype value that doubles as the
bit number.  The AER subtypes are numbered per event type and are not
a bit namespace -- the notice and SMART values overlap -- so borrowing
them as indices gets ambiguous as soon as more bits are needed.  Give
the events field its own numbering.

Signed-off-by: Guixin Liu <kanie@linux.alibaba.com>
---
 drivers/nvme/host/core.c | 6 +++---
 drivers/nvme/host/nvme.h | 7 +++++++
 2 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index cd0df9b038063..9da2061a0c0d5 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -4692,7 +4692,7 @@ static void nvme_scan_work(struct work_struct *work)
 		return;
 	}
 
-	if (test_and_clear_bit(NVME_AER_NOTICE_NS_CHANGED, &ctrl->events)) {
+	if (test_and_clear_bit(NVME_EVENT_NS_CHANGED, &ctrl->events)) {
 		dev_info(ctrl->device, "rescanning namespaces.\n");
 		nvme_clear_changed_ns_log(ctrl);
 	}
@@ -4713,7 +4713,7 @@ static void nvme_scan_work(struct work_struct *work)
 	mutex_unlock(&ctrl->scan_lock);
 
 	/* Requeue if we have missed AENs */
-	if (test_bit(NVME_AER_NOTICE_NS_CHANGED, &ctrl->events))
+	if (test_bit(NVME_EVENT_NS_CHANGED, &ctrl->events))
 		nvme_queue_scan(ctrl);
 #ifdef CONFIG_NVME_MULTIPATH
 	else if (ctrl->ana_log_buf)
@@ -4947,7 +4947,7 @@ static bool nvme_handle_aen_notice(struct nvme_ctrl *ctrl, u32 result)
 
 	switch (aer_notice_type) {
 	case NVME_AER_NOTICE_NS_CHANGED:
-		set_bit(NVME_AER_NOTICE_NS_CHANGED, &ctrl->events);
+		set_bit(NVME_EVENT_NS_CHANGED, &ctrl->events);
 		nvme_queue_scan(ctrl);
 		break;
 	case NVME_AER_NOTICE_FW_ACT_STARTING:
diff --git a/drivers/nvme/host/nvme.h b/drivers/nvme/host/nvme.h
index 2543e52d6358a..8948f4ecc7567 100644
--- a/drivers/nvme/host/nvme.h
+++ b/drivers/nvme/host/nvme.h
@@ -356,6 +356,13 @@ enum nvme_ctrl_flags {
 	NVME_CTRL_FROZEN		= 6,
 };
 
+/* Event bits in nvme_ctrl::events.  The numbering is independent of the
+ * AER type and subtype values in include/linux/nvme.h.
+ */
+enum nvme_events {
+	NVME_EVENT_NS_CHANGED,
+};
+
 struct nvme_ctrl {
 	bool comp_seen;
 	bool identified;
-- 
2.43.7



^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH v4 2/3] nvme: define the SMART / Health Status async event subtypes
  2026-11-24 12:00 [PATCH v4 0/3] nvme: make SMART / Health Status AENs reach hwmon alarms Guixin Liu
  2026-11-24 12:00 ` [PATCH v4 1/3] nvme: define an event bit enum for nvme_ctrl::events Guixin Liu
@ 2026-11-24 12:00 ` Guixin Liu
  2026-11-24 15:24   ` Nilay Shroff
  2026-11-25  5:18   ` Christoph Hellwig
  2026-11-24 12:00 ` [PATCH v4 3/3] nvme-hwmon: notify hwmon alarms on the SMART / Health Status AEN Guixin Liu
  2 siblings, 2 replies; 12+ messages in thread
From: Guixin Liu @ 2026-11-24 12:00 UTC (permalink / raw)
  To: Keith Busch, Jens Axboe, Christoph Hellwig, Sagi Grimberg,
	Nilay Shroff, Daniel Wagner, Hannes Reinecke
  Cc: linux-nvme

Add the asynchronous event information values of the SMART / Health
Status event type (NVMe 2.x, Figure 154) alongside the notice
subtypes, and the events bit for the temperature warning.

Signed-off-by: Guixin Liu <kanie@linux.alibaba.com>
---
 drivers/nvme/host/nvme.h | 1 +
 include/linux/nvme.h     | 6 ++++++
 2 files changed, 7 insertions(+)

diff --git a/drivers/nvme/host/nvme.h b/drivers/nvme/host/nvme.h
index 8948f4ecc7567..cd9d08cf9cde9 100644
--- a/drivers/nvme/host/nvme.h
+++ b/drivers/nvme/host/nvme.h
@@ -361,6 +361,7 @@ enum nvme_ctrl_flags {
  */
 enum nvme_events {
 	NVME_EVENT_NS_CHANGED,
+	NVME_EVENT_SMART_TEMP,
 };
 
 struct nvme_ctrl {
diff --git a/include/linux/nvme.h b/include/linux/nvme.h
index 6248711784b37..66fcd5a160684 100644
--- a/include/linux/nvme.h
+++ b/include/linux/nvme.h
@@ -859,6 +859,12 @@ enum {
 	NVME_AER_ERROR_PERSIST_INT_ERR	= 0x03,
 };
 
+enum {
+	NVME_AER_SMART_RELIABILITY	= 0x00,
+	NVME_AER_SMART_TEMP_THRESH	= 0x01,
+	NVME_AER_SMART_SPARE_THRESH	= 0x02,
+};
+
 enum {
 	NVME_AER_NOTICE_NS_CHANGED	= 0x00,
 	NVME_AER_NOTICE_FW_ACT_STARTING = 0x01,
-- 
2.43.7



^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH v4 3/3] nvme-hwmon: notify hwmon alarms on the SMART / Health Status AEN
  2026-11-24 12:00 [PATCH v4 0/3] nvme: make SMART / Health Status AENs reach hwmon alarms Guixin Liu
  2026-11-24 12:00 ` [PATCH v4 1/3] nvme: define an event bit enum for nvme_ctrl::events Guixin Liu
  2026-11-24 12:00 ` [PATCH v4 2/3] nvme: define the SMART / Health Status async event subtypes Guixin Liu
@ 2026-11-24 12:00 ` Guixin Liu
  2026-11-24 15:25   ` Nilay Shroff
  2026-11-25  5:18   ` Christoph Hellwig
  2 siblings, 2 replies; 12+ messages in thread
From: Guixin Liu @ 2026-11-24 12:00 UTC (permalink / raw)
  To: Keith Busch, Jens Axboe, Christoph Hellwig, Sagi Grimberg,
	Nilay Shroff, Daniel Wagner, Hannes Reinecke
  Cc: linux-nvme

The NVMe hwmon support exposes the temperature alarm as a plain sysfs
attribute, so monitoring tools have to poll temp1_alarm to learn about
a critical temperature condition. The device does send a SMART / Health
Status asynchronous event when a critical warning is raised, but the
host never enables it in the Asynchronous Event Configuration, and the
completion path silently drops the event.

The temperature warning is configured through the SMART / Health
Critical Warnings field of the Asynchronous Event Configuration, which
mirrors the critical_warning byte of the SMART log and has no OAES
capability bit, so the subscription does not go through ctrl->oaes.
A rejection with Invalid Field in Command falls back to the
notice-only mask, so the notice events are not lost with it.

On the event, a work item embedded in nvme_ctrl re-reads the SMART log
to clear the latched event and notifies temp1_alarm through
hwmon_notify_event(), which also feeds the registered thermal zone.
The notification fires when the event information indicates the
temperature threshold, or when the re-read log has the temperature
critical warning set, so that a transient excursion that recovered
before the log is read is still reported.
The work is only queued while the controller is live and is drained
before its data is freed.  The nvme-pci transport completes
asynchronous events from interrupt context, so the completion path
only queues the work.

Signed-off-by: Guixin Liu <kanie@linux.alibaba.com>
---
 drivers/nvme/host/core.c  | 26 +++++++++++++++++++++++++-
 drivers/nvme/host/hwmon.c | 37 +++++++++++++++++++++++++++++++++++++
 drivers/nvme/host/nvme.h  | 17 +++++++++++++++++
 3 files changed, 79 insertions(+), 1 deletion(-)

diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index 9da2061a0c0d5..602c336e557d9 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -1792,11 +1792,29 @@ static void nvme_enable_aen(struct nvme_ctrl *ctrl)
 	u32 result, supported_aens = ctrl->oaes & NVME_AEN_SUPPORTED;
 	int status;
 
+	if (nvme_hwmon_present(ctrl) && ctrl->ops->submit_async_event)
+		supported_aens |= NVME_SMART_CRIT_TEMPERATURE;
+
 	if (!supported_aens)
 		return;
 
 	status = nvme_set_features(ctrl, NVME_FEAT_ASYNC_EVENT, supported_aens,
 			NULL, 0, &result);
+	/*
+	 * The SHCW bits have no capability field, so a controller
+	 * reports the lack of support as Invalid Field in Command.
+	 * Retry with the notice-only mask, so the notice events are
+	 * not lost with the subscription; other errors do not
+	 * indicate an unsupported mask.
+	 */
+	if ((status & NVME_SCT_SC_MASK) == NVME_SC_INVALID_FIELD &&
+	    (supported_aens & NVME_SMART_CRIT_TEMPERATURE)) {
+		supported_aens &= ~NVME_SMART_CRIT_TEMPERATURE;
+		if (!supported_aens)
+			return;
+		status = nvme_set_features(ctrl, NVME_FEAT_ASYNC_EVENT,
+				supported_aens, NULL, 0, &result);
+	}
 	if (status)
 		dev_warn(ctrl->device, "Failed to configure AEN (cfg %x)\n",
 			 supported_aens);
@@ -5009,8 +5027,14 @@ void nvme_complete_async_event(struct nvme_ctrl *ctrl, __le16 status,
 			nvme_handle_aer_persistent_error(ctrl);
 			return;
 		}
-		fallthrough;
+		ctrl->aen_result = result;
+		break;
 	case NVME_AER_SMART:
+		ctrl->aen_result = result;
+		if (nvme_hwmon_present(ctrl) &&
+		    nvme_ctrl_state(ctrl) == NVME_CTRL_LIVE)
+			nvme_hwmon_smart_event(ctrl, aer_subtype);
+		break;
 	case NVME_AER_CSS:
 	case NVME_AER_VS:
 		ctrl->aen_result = result;
diff --git a/drivers/nvme/host/hwmon.c b/drivers/nvme/host/hwmon.c
index 406203d8b9adb..8375a3fac8ba4 100644
--- a/drivers/nvme/host/hwmon.c
+++ b/drivers/nvme/host/hwmon.c
@@ -223,6 +223,41 @@ static const struct hwmon_chip_info nvme_hwmon_chip_info = {
 	.info	= nvme_hwmon_info,
 };
 
+static void nvme_hwmon_smart_notify(struct work_struct *work)
+{
+	struct nvme_ctrl *ctrl =
+		container_of(work, struct nvme_ctrl, smart_work);
+	struct nvme_hwmon_data *data;
+	struct device *hwmon;
+	bool warn;
+
+	warn = test_and_clear_bit(NVME_EVENT_SMART_TEMP, &ctrl->events);
+
+	if (nvme_ctrl_state(ctrl) != NVME_CTRL_LIVE)
+		return;
+
+	hwmon = ctrl->hwmon_device;
+	if (!hwmon)
+		return;
+	data = dev_get_drvdata(hwmon);
+
+	mutex_lock(&data->read_lock);
+	if (!nvme_hwmon_get_smart_log(data))
+		warn = warn || (data->log->critical_warning &
+				NVME_SMART_CRIT_TEMPERATURE);
+	mutex_unlock(&data->read_lock);
+
+	if (warn)
+		hwmon_notify_event(hwmon, hwmon_temp, hwmon_temp_alarm, 0);
+}
+
+void nvme_hwmon_smart_event(struct nvme_ctrl *ctrl, u32 subtype)
+{
+	if (subtype == NVME_AER_SMART_TEMP_THRESH)
+		set_bit(NVME_EVENT_SMART_TEMP, &ctrl->events);
+	queue_work(nvme_wq, &ctrl->smart_work);
+}
+
 int nvme_hwmon_init(struct nvme_ctrl *ctrl)
 {
 	struct device *dev = ctrl->device;
@@ -242,6 +277,7 @@ int nvme_hwmon_init(struct nvme_ctrl *ctrl)
 
 	data->ctrl = ctrl;
 	mutex_init(&data->read_lock);
+	INIT_WORK(&ctrl->smart_work, nvme_hwmon_smart_notify);
 
 	err = nvme_hwmon_get_smart_log(data);
 	if (err) {
@@ -273,6 +309,7 @@ void nvme_hwmon_exit(struct nvme_ctrl *ctrl)
 		struct nvme_hwmon_data *data =
 			dev_get_drvdata(ctrl->hwmon_device);
 
+		cancel_work_sync(&ctrl->smart_work);
 		hwmon_device_unregister(ctrl->hwmon_device);
 		ctrl->hwmon_device = NULL;
 		kfree(data->log);
diff --git a/drivers/nvme/host/nvme.h b/drivers/nvme/host/nvme.h
index cd9d08cf9cde9..2d3d9b1e92237 100644
--- a/drivers/nvme/host/nvme.h
+++ b/drivers/nvme/host/nvme.h
@@ -387,6 +387,7 @@ struct nvme_ctrl {
 	struct device *device;	/* char device */
 #ifdef CONFIG_NVME_HWMON
 	struct device *hwmon_device;
+	struct work_struct smart_work;
 #endif
 	struct cdev cdev;
 	struct work_struct reset_work;
@@ -1284,6 +1285,12 @@ static inline struct nvme_ns *nvme_get_ns_from_dev(struct device *dev)
 #ifdef CONFIG_NVME_HWMON
 int nvme_hwmon_init(struct nvme_ctrl *ctrl);
 void nvme_hwmon_exit(struct nvme_ctrl *ctrl);
+void nvme_hwmon_smart_event(struct nvme_ctrl *ctrl, u32 subtype);
+
+static inline bool nvme_hwmon_present(struct nvme_ctrl *ctrl)
+{
+	return ctrl->hwmon_device != NULL;
+}
 #else
 static inline int nvme_hwmon_init(struct nvme_ctrl *ctrl)
 {
@@ -1293,6 +1300,16 @@ static inline int nvme_hwmon_init(struct nvme_ctrl *ctrl)
 static inline void nvme_hwmon_exit(struct nvme_ctrl *ctrl)
 {
 }
+
+static inline void nvme_hwmon_smart_event(struct nvme_ctrl *ctrl,
+		u32 subtype)
+{
+}
+
+static inline bool nvme_hwmon_present(struct nvme_ctrl *ctrl)
+{
+	return false;
+}
 #endif
 
 static inline void nvme_start_request(struct request *rq)
-- 
2.43.7



^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 1/3] nvme: define an event bit enum for nvme_ctrl::events
  2026-11-24 12:00 ` [PATCH v4 1/3] nvme: define an event bit enum for nvme_ctrl::events Guixin Liu
@ 2026-11-24 15:24   ` Nilay Shroff
  2026-11-25  5:17   ` Christoph Hellwig
  1 sibling, 0 replies; 12+ messages in thread
From: Nilay Shroff @ 2026-11-24 15:24 UTC (permalink / raw)
  To: Guixin Liu, Keith Busch, Jens Axboe, Christoph Hellwig,
	Sagi Grimberg, Daniel Wagner, Hannes Reinecke
  Cc: linux-nvme

On 11/24/26 5:30 PM, Guixin Liu wrote:
> The only bit used in nvme_ctrl::events is indexed with
> NVME_AER_NOTICE_NS_CHANGED, an AER subtype value that doubles as the
> bit number.  The AER subtypes are numbered per event type and are not
> a bit namespace -- the notice and SMART values overlap -- so borrowing
> them as indices gets ambiguous as soon as more bits are needed.  Give
> the events field its own numbering.
> 
> Signed-off-by: Guixin Liu<kanie@linux.alibaba.com>

Looks good to me:

Reviewed-by: Nilay Shroff <nilay@linux.ibm.com>


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 2/3] nvme: define the SMART / Health Status async event subtypes
  2026-11-24 12:00 ` [PATCH v4 2/3] nvme: define the SMART / Health Status async event subtypes Guixin Liu
@ 2026-11-24 15:24   ` Nilay Shroff
  2026-11-25  5:18   ` Christoph Hellwig
  1 sibling, 0 replies; 12+ messages in thread
From: Nilay Shroff @ 2026-11-24 15:24 UTC (permalink / raw)
  To: Guixin Liu, Keith Busch, Jens Axboe, Christoph Hellwig,
	Sagi Grimberg, Daniel Wagner, Hannes Reinecke
  Cc: linux-nvme

On 11/24/26 5:30 PM, Guixin Liu wrote:
> Add the asynchronous event information values of the SMART / Health
> Status event type (NVMe 2.x, Figure 154) alongside the notice
> subtypes, and the events bit for the temperature warning.
> 
> Signed-off-by: Guixin Liu<kanie@linux.alibaba.com>

Looks good to me:

Reviewed-by: Nilay Shroff <nilay@linux.ibm.com>


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 3/3] nvme-hwmon: notify hwmon alarms on the SMART / Health Status AEN
  2026-11-24 12:00 ` [PATCH v4 3/3] nvme-hwmon: notify hwmon alarms on the SMART / Health Status AEN Guixin Liu
@ 2026-11-24 15:25   ` Nilay Shroff
  2026-11-25  5:18   ` Christoph Hellwig
  1 sibling, 0 replies; 12+ messages in thread
From: Nilay Shroff @ 2026-11-24 15:25 UTC (permalink / raw)
  To: Guixin Liu, Keith Busch, Jens Axboe, Christoph Hellwig,
	Sagi Grimberg, Daniel Wagner, Hannes Reinecke
  Cc: linux-nvme

On 11/24/26 5:30 PM, Guixin Liu wrote:
> The NVMe hwmon support exposes the temperature alarm as a plain sysfs
> attribute, so monitoring tools have to poll temp1_alarm to learn about
> a critical temperature condition. The device does send a SMART / Health
> Status asynchronous event when a critical warning is raised, but the
> host never enables it in the Asynchronous Event Configuration, and the
> completion path silently drops the event.
> 
> The temperature warning is configured through the SMART / Health
> Critical Warnings field of the Asynchronous Event Configuration, which
> mirrors the critical_warning byte of the SMART log and has no OAES
> capability bit, so the subscription does not go through ctrl->oaes.
> A rejection with Invalid Field in Command falls back to the
> notice-only mask, so the notice events are not lost with it.
> 
> On the event, a work item embedded in nvme_ctrl re-reads the SMART log
> to clear the latched event and notifies temp1_alarm through
> hwmon_notify_event(), which also feeds the registered thermal zone.
> The notification fires when the event information indicates the
> temperature threshold, or when the re-read log has the temperature
> critical warning set, so that a transient excursion that recovered
> before the log is read is still reported.
> The work is only queued while the controller is live and is drained
> before its data is freed.  The nvme-pci transport completes
> asynchronous events from interrupt context, so the completion path
> only queues the work.
> 
> Signed-off-by: Guixin Liu<kanie@linux.alibaba.com>

Looks good to me:

Reviewed-by: Nilay Shroff <nilay@linux.ibm.com>


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 1/3] nvme: define an event bit enum for nvme_ctrl::events
  2026-11-24 12:00 ` [PATCH v4 1/3] nvme: define an event bit enum for nvme_ctrl::events Guixin Liu
  2026-11-24 15:24   ` Nilay Shroff
@ 2026-11-25  5:17   ` Christoph Hellwig
  2026-11-25  5:45     ` Guixin Liu
  1 sibling, 1 reply; 12+ messages in thread
From: Christoph Hellwig @ 2026-11-25  5:17 UTC (permalink / raw)
  To: Guixin Liu
  Cc: Keith Busch, Jens Axboe, Christoph Hellwig, Sagi Grimberg,
	Nilay Shroff, Daniel Wagner, Hannes Reinecke, linux-nvme

On Tue, Nov 24, 2026 at 08:00:30PM +0800, Guixin Liu wrote:
> +/* Event bits in nvme_ctrl::events.  The numbering is independent of the
> + * AER type and subtype values in include/linux/nvme.h.
> + */

Please use the normal kernel comment style.

Otherwise looks good.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 2/3] nvme: define the SMART / Health Status async event subtypes
  2026-11-24 12:00 ` [PATCH v4 2/3] nvme: define the SMART / Health Status async event subtypes Guixin Liu
  2026-11-24 15:24   ` Nilay Shroff
@ 2026-11-25  5:18   ` Christoph Hellwig
  2026-11-25  5:46     ` Guixin Liu
  1 sibling, 1 reply; 12+ messages in thread
From: Christoph Hellwig @ 2026-11-25  5:18 UTC (permalink / raw)
  To: Guixin Liu
  Cc: Keith Busch, Jens Axboe, Sagi Grimberg, Nilay Shroff,
	Daniel Wagner, Hannes Reinecke, linux-nvme

On Tue, Nov 24, 2026 at 08:00:31PM +0800, Guixin Liu wrote:
> Add the asynchronous event information values of the SMART / Health
> Status event type (NVMe 2.x, Figure 154) alongside the notice
> subtypes, and the events bit for the temperature warning.

Pleaee split the command set addition in nvme.h from the changes to the
host implementation.  The latter can go directly into the next patch.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 3/3] nvme-hwmon: notify hwmon alarms on the SMART / Health Status AEN
  2026-11-24 12:00 ` [PATCH v4 3/3] nvme-hwmon: notify hwmon alarms on the SMART / Health Status AEN Guixin Liu
  2026-11-24 15:25   ` Nilay Shroff
@ 2026-11-25  5:18   ` Christoph Hellwig
  1 sibling, 0 replies; 12+ messages in thread
From: Christoph Hellwig @ 2026-11-25  5:18 UTC (permalink / raw)
  To: Guixin Liu
  Cc: Keith Busch, Jens Axboe, Christoph Hellwig, Sagi Grimberg,
	Nilay Shroff, Daniel Wagner, Hannes Reinecke, linux-nvme

Looks good:

Reviewed-by: Christoph Hellwig <hch@lst.de>



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 1/3] nvme: define an event bit enum for nvme_ctrl::events
  2026-11-25  5:17   ` Christoph Hellwig
@ 2026-11-25  5:45     ` Guixin Liu
  0 siblings, 0 replies; 12+ messages in thread
From: Guixin Liu @ 2026-11-25  5:45 UTC (permalink / raw)
  To: Christoph Hellwig
  Cc: Keith Busch, Jens Axboe, Sagi Grimberg, Nilay Shroff,
	Daniel Wagner, Hannes Reinecke, linux-nvme



在 2026/11/25 13:17, Christoph Hellwig 写道:
> On Tue, Nov 24, 2026 at 08:00:30PM +0800, Guixin Liu wrote:
>> +/* Event bits in nvme_ctrl::events.  The numbering is independent of the
>> + * AER type and subtype values in include/linux/nvme.h.
>> + */
> Please use the normal kernel comment style.
>
> Otherwise looks good.
Sorry, changed in v5.

Best Regards,
Guixin Liu



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 2/3] nvme: define the SMART / Health Status async event subtypes
  2026-11-25  5:18   ` Christoph Hellwig
@ 2026-11-25  5:46     ` Guixin Liu
  0 siblings, 0 replies; 12+ messages in thread
From: Guixin Liu @ 2026-11-25  5:46 UTC (permalink / raw)
  To: Christoph Hellwig
  Cc: Keith Busch, Jens Axboe, Sagi Grimberg, Nilay Shroff,
	Daniel Wagner, Hannes Reinecke, linux-nvme



在 2026/11/25 13:18, Christoph Hellwig 写道:
> On Tue, Nov 24, 2026 at 08:00:31PM +0800, Guixin Liu wrote:
>> Add the asynchronous event information values of the SMART / Health
>> Status event type (NVMe 2.x, Figure 154) alongside the notice
>> subtypes, and the events bit for the temperature warning.
> Pleaee split the command set addition in nvme.h from the changes to the
> host implementation.  The latter can go directly into the next patch.
OK, changed in v5.

Best Regards,
Guixin Liu



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2026-11-25  5:46 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-24 12:00 [PATCH v4 0/3] nvme: make SMART / Health Status AENs reach hwmon alarms Guixin Liu
2026-11-24 12:00 ` [PATCH v4 1/3] nvme: define an event bit enum for nvme_ctrl::events Guixin Liu
2026-11-24 15:24   ` Nilay Shroff
2026-11-25  5:17   ` Christoph Hellwig
2026-11-25  5:45     ` Guixin Liu
2026-11-24 12:00 ` [PATCH v4 2/3] nvme: define the SMART / Health Status async event subtypes Guixin Liu
2026-11-24 15:24   ` Nilay Shroff
2026-11-25  5:18   ` Christoph Hellwig
2026-11-25  5:46     ` Guixin Liu
2026-11-24 12:00 ` [PATCH v4 3/3] nvme-hwmon: notify hwmon alarms on the SMART / Health Status AEN Guixin Liu
2026-11-24 15:25   ` Nilay Shroff
2026-11-25  5:18   ` Christoph Hellwig

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox