From: jay.e.sternberg@intel.com (Jay Sternberg)
Subject: [PATCH v3 5/8] nvmet: Add defines for discovery change async events
Date: Mon, 12 Nov 2018 13:56:37 -0800 [thread overview]
Message-ID: <1542059800-35938-6-git-send-email-jay.e.sternberg@intel.com> (raw)
In-Reply-To: <1542059800-35938-1-git-send-email-jay.e.sternberg@intel.com>
Add AEN/AER values as defined by the specification
Signed-off-by: Jay Sternberg <jay.e.sternberg at intel.com>
Reviewed-by: Sagi Grimberg <sagi at grimberg.me>
Reviewed-by: Christoph Hellwig <hch at lst.de>
---
v2 - unchanged
v3 - use 1 << instead of BIT() per request from Christoph
drivers/nvme/target/nvmet.h | 2 ++
include/linux/nvme.h | 3 +++
2 files changed, 5 insertions(+)
diff --git a/drivers/nvme/target/nvmet.h b/drivers/nvme/target/nvmet.h
index e9a81f6..5c583c4 100644
--- a/drivers/nvme/target/nvmet.h
+++ b/drivers/nvme/target/nvmet.h
@@ -36,6 +36,8 @@
*/
#define NVMET_AEN_CFG_OPTIONAL \
(NVME_AEN_CFG_NS_ATTR | NVME_AEN_CFG_ANA_CHANGE)
+#define NVMET_DISC_AEN_CFG_OPTIONAL \
+ (NVME_AEN_CFG_DISC_CHANGE)
/*
* Plus mandatory SMART AENs (we'll never send them, but allow enabling them):
diff --git a/include/linux/nvme.h b/include/linux/nvme.h
index 5690882..809c31c 100644
--- a/include/linux/nvme.h
+++ b/include/linux/nvme.h
@@ -481,18 +481,21 @@ enum {
NVME_AER_NOTICE_NS_CHANGED = 0x00,
NVME_AER_NOTICE_FW_ACT_STARTING = 0x01,
NVME_AER_NOTICE_ANA = 0x03,
+ NVME_AER_NOTICE_DISC_CHANGED = 0xf0,
};
enum {
NVME_AEN_BIT_NS_ATTR = 8,
NVME_AEN_BIT_FW_ACT = 9,
NVME_AEN_BIT_ANA_CHANGE = 11,
+ NVME_AEN_BIT_DISC_CHANGE = 31,
};
enum {
NVME_AEN_CFG_NS_ATTR = 1 << NVME_AEN_BIT_NS_ATTR,
NVME_AEN_CFG_FW_ACT = 1 << NVME_AEN_BIT_FW_ACT,
NVME_AEN_CFG_ANA_CHANGE = 1 << NVME_AEN_BIT_ANA_CHANGE,
+ NVME_AEN_CFG_DISC_CHANGE = 1 << NVME_AEN_BIT_DISC_CHANGE,
};
struct nvme_lba_range_type {
--
1.8.3.1
next prev parent reply other threads:[~2018-11-12 21:56 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-12 21:56 [PATCH v3 0/8] nvmet: Enable AENs support for Discovery controllers Jay Sternberg
2018-11-12 21:56 ` [PATCH v3 1/8] nvmet: Provide aen bit functions for multiple controller types Jay Sternberg
2018-11-12 21:56 ` [PATCH v3 2/8] nvmet: Change aen mask functions to use bit numbers Jay Sternberg
2018-11-12 21:56 ` [PATCH v3 3/8] nvmet: Allow Keep Alive for Discovery controller Jay Sternberg
2018-11-12 21:56 ` [PATCH v3 4/8] nvmet: Make kato and AEN processing for use by other controllers Jay Sternberg
2018-11-12 21:56 ` Jay Sternberg [this message]
2018-11-12 21:56 ` [PATCH v3 6/8] nvmet: Add support to Discovery controllers for commands Jay Sternberg
2018-11-12 21:56 ` [PATCH v3 7/8] nvmet: allow host connect even if no allowed subsystems are exported Jay Sternberg
2018-11-12 21:56 ` [PATCH v3 8/8] nvmet: Enable Discovery Controller AENs Jay Sternberg
2018-11-14 15:45 ` [PATCH v3 0/8] nvmet: Enable AENs support for Discovery controllers Christoph Hellwig
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1542059800-35938-6-git-send-email-jay.e.sternberg@intel.com \
--to=jay.e.sternberg@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).