From: Anthony Iliopoulos <ailiop@suse.com>
To: util-linux@vger.kernel.org
Cc: ailiop@suse.com
Subject: [PATCH] lsblk: add dax (direct access) capability column
Date: Tue, 5 May 2020 16:31:44 +0200 [thread overview]
Message-ID: <20200505143145.9852-1-ailiop@suse.com> (raw)
Signed-off-by: Anthony Iliopoulos <ailiop@suse.com>
---
misc-utils/lsblk.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/misc-utils/lsblk.c b/misc-utils/lsblk.c
index 72ac7b483..51b9f6ad7 100644
--- a/misc-utils/lsblk.c
+++ b/misc-utils/lsblk.c
@@ -117,6 +117,7 @@ enum {
COL_REV,
COL_VENDOR,
COL_ZONED,
+ COL_DAX
};
/* basic table settings */
@@ -208,6 +209,7 @@ static struct colinfo infos[] = {
[COL_REV] = { "REV", 4, SCOLS_FL_RIGHT, N_("device revision") },
[COL_VENDOR] = { "VENDOR", 0.1, SCOLS_FL_TRUNC, N_("device vendor") },
[COL_ZONED] = { "ZONED", 0.3, 0, N_("zone model") },
+ [COL_DAX] = { "DAX", 1, SCOLS_FL_RIGHT, N_("dax-capable device"), COLTYPE_BOOL },
};
struct lsblk *lsblk; /* global handler */
@@ -1031,6 +1033,9 @@ static char *device_get_data(
case COL_ZONED:
ul_path_read_string(dev->sysfs, &str, "queue/zoned");
break;
+ case COL_DAX:
+ ul_path_read_string(dev->sysfs, &str, "queue/dax");
+ break;
};
return str;
--
2.26.2
next reply other threads:[~2020-05-05 14:32 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-05 14:31 Anthony Iliopoulos [this message]
2020-05-06 13:15 ` [PATCH] lsblk: add dax (direct access) capability column Karel Zak
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=20200505143145.9852-1-ailiop@suse.com \
--to=ailiop@suse.com \
--cc=util-linux@vger.kernel.org \
/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).