* [PATCH] nvmet: unify aer type enum
@ 2024-01-18 12:51 Guixin Liu
2024-01-22 9:15 ` Sagi Grimberg
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Guixin Liu @ 2024-01-18 12:51 UTC (permalink / raw)
To: sagi, kbusch, axboe, hch, kch; +Cc: linux-nvme
The host and target use two definition of aer type, unify
them into a single one.
Signed-off-by: Guixin Liu <kanie@linux.alibaba.com>
---
drivers/nvme/target/core.c | 4 ++--
drivers/nvme/target/discovery.c | 2 +-
include/linux/nvme.h | 6 ------
3 files changed, 3 insertions(+), 9 deletions(-)
diff --git a/drivers/nvme/target/core.c b/drivers/nvme/target/core.c
index 5bacffc59848..564ab051fb0c 100644
--- a/drivers/nvme/target/core.c
+++ b/drivers/nvme/target/core.c
@@ -248,7 +248,7 @@ void nvmet_ns_changed(struct nvmet_subsys *subsys, u32 nsid)
nvmet_add_to_changed_ns_log(ctrl, cpu_to_le32(nsid));
if (nvmet_aen_bit_disabled(ctrl, NVME_AEN_BIT_NS_ATTR))
continue;
- nvmet_add_async_event(ctrl, NVME_AER_TYPE_NOTICE,
+ nvmet_add_async_event(ctrl, NVME_AER_NOTICE,
NVME_AER_NOTICE_NS_CHANGED,
NVME_LOG_CHANGED_NS);
}
@@ -265,7 +265,7 @@ void nvmet_send_ana_event(struct nvmet_subsys *subsys,
continue;
if (nvmet_aen_bit_disabled(ctrl, NVME_AEN_BIT_ANA_CHANGE))
continue;
- nvmet_add_async_event(ctrl, NVME_AER_TYPE_NOTICE,
+ nvmet_add_async_event(ctrl, NVME_AER_NOTICE,
NVME_AER_NOTICE_ANA, NVME_LOG_ANA);
}
mutex_unlock(&subsys->lock);
diff --git a/drivers/nvme/target/discovery.c b/drivers/nvme/target/discovery.c
index 668d257fa986..68e82ccc0e4e 100644
--- a/drivers/nvme/target/discovery.c
+++ b/drivers/nvme/target/discovery.c
@@ -21,7 +21,7 @@ static void __nvmet_disc_changed(struct nvmet_port *port,
if (nvmet_aen_bit_disabled(ctrl, NVME_AEN_BIT_DISC_CHANGE))
return;
- nvmet_add_async_event(ctrl, NVME_AER_TYPE_NOTICE,
+ nvmet_add_async_event(ctrl, NVME_AER_NOTICE,
NVME_AER_NOTICE_DISC_CHANGED, NVME_LOG_DISC);
}
diff --git a/include/linux/nvme.h b/include/linux/nvme.h
index 67a8c9fd1956..f957cfb7052f 100644
--- a/include/linux/nvme.h
+++ b/include/linux/nvme.h
@@ -865,12 +865,6 @@ struct nvme_reservation_status_ext {
struct nvme_registered_ctrl_ext regctl_eds[];
};
-enum nvme_async_event_type {
- NVME_AER_TYPE_ERROR = 0,
- NVME_AER_TYPE_SMART = 1,
- NVME_AER_TYPE_NOTICE = 2,
-};
-
/* I/O commands */
enum nvme_opcode {
--
2.43.0
^ permalink raw reply related [flat|nested] 5+ messages in thread* Re: [PATCH] nvmet: unify aer type enum
2024-01-18 12:51 [PATCH] nvmet: unify aer type enum Guixin Liu
@ 2024-01-22 9:15 ` Sagi Grimberg
2024-01-22 9:22 ` Sagi Grimberg
2024-01-23 9:05 ` Christoph Hellwig
2024-01-23 16:39 ` Keith Busch
2 siblings, 1 reply; 5+ messages in thread
From: Sagi Grimberg @ 2024-01-22 9:15 UTC (permalink / raw)
To: Guixin Liu, kbusch, axboe, hch, kch; +Cc: linux-nvme
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] nvmet: unify aer type enum
2024-01-18 12:51 [PATCH] nvmet: unify aer type enum Guixin Liu
2024-01-22 9:15 ` Sagi Grimberg
@ 2024-01-23 9:05 ` Christoph Hellwig
2024-01-23 16:39 ` Keith Busch
2 siblings, 0 replies; 5+ messages in thread
From: Christoph Hellwig @ 2024-01-23 9:05 UTC (permalink / raw)
To: Guixin Liu; +Cc: sagi, kbusch, axboe, hch, kch, linux-nvme
Looks good:
Reviewed-by: Christoph Hellwig <hch@lst.de>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] nvmet: unify aer type enum
2024-01-18 12:51 [PATCH] nvmet: unify aer type enum Guixin Liu
2024-01-22 9:15 ` Sagi Grimberg
2024-01-23 9:05 ` Christoph Hellwig
@ 2024-01-23 16:39 ` Keith Busch
2 siblings, 0 replies; 5+ messages in thread
From: Keith Busch @ 2024-01-23 16:39 UTC (permalink / raw)
To: Guixin Liu; +Cc: sagi, axboe, hch, kch, linux-nvme
Applied to nvme-6.8, thanks.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2024-01-23 16:39 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-18 12:51 [PATCH] nvmet: unify aer type enum Guixin Liu
2024-01-22 9:15 ` Sagi Grimberg
2024-01-22 9:22 ` Sagi Grimberg
2024-01-23 9:05 ` Christoph Hellwig
2024-01-23 16:39 ` Keith Busch
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox