All of lore.kernel.org
 help / color / mirror / Atom feed
From: minwoo.im.dev@gmail.com (Minwoo Im)
Subject: [PATCH] nvme-cli: add new HMB identify fields of TP 4002
Date: Tue, 28 Nov 2017 20:56:47 +0900	[thread overview]
Message-ID: <1511870207-17033-1-git-send-email-minwoo.im.dev@gmail.com> (raw)

Add new HMB identify fields (hmminds, hmmaxd) to struct nvme_id_ctrl.
Those fields were added in TP 4002 which is "HMB Enhancements".

Signed-off-by: Minwoo Im <minwoo.im.dev at gmail.com>
---
 linux/nvme.h | 4 +++-
 nvme-print.c | 2 ++
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/linux/nvme.h b/linux/nvme.h
index 2d5be8f..2f30616 100644
--- a/linux/nvme.h
+++ b/linux/nvme.h
@@ -217,7 +217,9 @@ struct nvme_id_ctrl {
 	__le16			mntmt;
 	__le16			mxtmt;
 	__le32			sanicap;
-	__u8			rsvd332[180];
+	__le32			hmminds;
+	__le16			hmmaxd;
+	__u8			rsvd332[174];
 	__u8			sqes;
 	__u8			cqes;
 	__le16			maxcmd;
diff --git a/nvme-print.c b/nvme-print.c
index db11dd7..1808405 100644
--- a/nvme-print.c
+++ b/nvme-print.c
@@ -860,6 +860,8 @@ void __show_nvme_id_ctrl(struct nvme_id_ctrl *ctrl, unsigned int mode, void (*ve
 	printf("sanicap : %#x\n", le32_to_cpu(ctrl->sanicap));
 	if (human)
 		show_nvme_id_ctrl_sanicap(ctrl->sanicap);
+	printf("hmminds : %d\n", le32_to_cpu(ctrl->hmminds));
+	printf("hmmaxd  : %d\n", le16_to_cpu(ctrl->hmmaxd));
 	printf("sqes    : %#x\n", ctrl->sqes);
 	if (human)
 		show_nvme_id_ctrl_sqes(ctrl->sqes);
-- 
2.7.4

             reply	other threads:[~2017-11-28 11:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-28 11:56 Minwoo Im [this message]
2017-11-28 12:37 ` [PATCH] nvme-cli: add new HMB identify fields of TP 4002 Christoph Hellwig
2017-11-28 12:58   ` Minwoo Im
2017-11-28 13:04     ` Christoph Hellwig
2017-11-28 14:21       ` Minwoo Im

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=1511870207-17033-1-git-send-email-minwoo.im.dev@gmail.com \
    --to=minwoo.im.dev@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.