From: minwoo.im.dev@gmail.com (Minwoo Im)
Subject: [PATCH 4/4] lnvm: sync-up uapi lightnvm.h header from kernel
Date: Mon, 22 Jul 2019 00:26:49 +0900 [thread overview]
Message-ID: <20190721152649.4894-5-minwoo.im.dev@gmail.com> (raw)
In-Reply-To: <20190721152649.4894-4-minwoo.im.dev@gmail.com>
This patch just syncs-up UAPI header from the kernel. No functional
changes included.
Cc: Keith Busch <kbusch at kernel.org>
Cc: Matias Bjorling <mb at lightnvm.io>
Signed-off-by: Minwoo Im <minwoo.im.dev at gmail.com>
---
linux/lightnvm.h | 52 +++++++++++++++++++++++++++++++++++++++++++++++-
1 file changed, 51 insertions(+), 1 deletion(-)
diff --git a/linux/lightnvm.h b/linux/lightnvm.h
index f678ffb..c937160 100644
--- a/linux/lightnvm.h
+++ b/linux/lightnvm.h
@@ -77,7 +77,7 @@ struct nvm_ioctl_create_simple {
struct nvm_ioctl_create_extended {
__u16 lun_begin;
__u16 lun_end;
- __u16 over_prov;
+ __u16 op;
__u16 rsv;
};
@@ -135,6 +135,44 @@ struct nvm_ioctl_dev_factory {
__u32 flags;
};
+struct nvm_user_vio {
+ __u8 opcode;
+ __u8 flags;
+ __u16 control;
+ __u16 nppas;
+ __u16 rsvd;
+ __u64 metadata;
+ __u64 addr;
+ __u64 ppa_list;
+ __u32 metadata_len;
+ __u32 data_len;
+ __u64 status;
+ __u32 result;
+ __u32 rsvd3[3];
+};
+
+struct nvm_passthru_vio {
+ __u8 opcode;
+ __u8 flags;
+ __u8 rsvd[2];
+ __u32 nsid;
+ __u32 cdw2;
+ __u32 cdw3;
+ __u64 metadata;
+ __u64 addr;
+ __u32 metadata_len;
+ __u32 data_len;
+ __u64 ppa_list;
+ __u16 nppas;
+ __u16 control;
+ __u32 cdw13;
+ __u32 cdw14;
+ __u32 cdw15;
+ __u64 status;
+ __u32 result;
+ __u32 timeout_ms;
+};
+
/* The ioctl type, 'L', 0x20 - 0x2F documented in ioctl-number.txt */
enum {
/* top level cmds */
@@ -150,6 +188,11 @@ enum {
/* Factory reset device */
NVM_DEV_FACTORY_CMD,
+
+ /* Vector user I/O */
+ NVM_DEV_VIO_ADMIN_CMD = 0x41,
+ NVM_DEV_VIO_CMD = 0x42,
+ NVM_DEV_VIO_USER_CMD = 0x43,
};
#define NVM_IOCTL 'L' /* 0x4c */
@@ -167,6 +210,13 @@ enum {
#define NVM_DEV_FACTORY _IOW(NVM_IOCTL, NVM_DEV_FACTORY_CMD, \
struct nvm_ioctl_dev_factory)
+#define NVME_NVM_IOCTL_IO_VIO _IOWR(NVM_IOCTL, NVM_DEV_VIO_USER_CMD, \
+ struct nvm_passthru_vio)
+#define NVME_NVM_IOCTL_ADMIN_VIO _IOWR(NVM_IOCTL, NVM_DEV_VIO_ADMIN_CMD,\
+ struct nvm_passthru_vio)
+#define NVME_NVM_IOCTL_SUBMIT_VIO _IOWR(NVM_IOCTL, NVM_DEV_VIO_CMD,\
+ struct nvm_user_vio)
+
#define NVM_VERSION_MAJOR 1
#define NVM_VERSION_MINOR 0
#define NVM_VERSION_PATCHLEVEL 0
--
2.17.1
next prev parent reply other threads:[~2019-07-21 15:26 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-21 15:26 [PATCH 0/4] lnvm: minor clean-ups Minwoo Im
2019-07-21 15:26 ` [PATCH 1/4] lnvm: remove redundant whitespace in lnvm_init() Minwoo Im
2019-07-21 15:26 ` [PATCH 2/4] lnvm: do not print 0 when the arg is not given Minwoo Im
2019-07-21 15:26 ` [PATCH 3/4] lnvm: cast identity structure to (void *) directly Minwoo Im
2019-07-21 15:26 ` Minwoo Im [this message]
2019-07-21 15:28 ` [PATCH 0/4] lnvm: minor clean-ups Minwoo Im
-- strict thread matches above, loose matches on Subject: below --
2019-07-21 15:32 [PATCH V2 " Minwoo Im
2019-07-21 15:32 ` [PATCH 4/4] lnvm: sync-up uapi lightnvm.h header from kernel Minwoo Im
2019-07-23 5:45 ` Javier González
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=20190721152649.4894-5-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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox