History

nvme: add vectored-io support for user-passthrough

Add a new NVME_IOCTL_IO64_CMD_VEC ioctl that works like the existing NVME_IOCTL_IO64_CMD ioctl except that it takes and array of iovecs and thus supports vectored I/O. - cmd.addr is base address of user iovec array - cmd.vec_cnt is count of iovec array elements This patch does not include vectored-variant for admin-commands as most of them are light on buffers and likely to have low invocation frequency.

Kanchan Joshi committed 4 years ago

Commit 89377bc1 parent bd83fe62 files · +31 −10Browse files

Showing the changes to include/uapi (1 of 2 files). Show all

Unified · Split

include/uapi/linux/nvme_ioctl.h+5−1
@@ -55,7 +55,10 @@ struct nvme_passthru_cmd64 { · 54 unmodified lines
55 __u64 metadata;55 __u64 metadata;
56 __u64 addr;56 __u64 addr;
57 __u32 metadata_len;57 __u32 metadata_len;
58 __u32 data_len;58 union {
59 __u32 data_len; /* for non-vectored io */
60 __u32 vec_cnt; /* for vectored io */
61 };
59 __u32 cdw10;62 __u32 cdw10;
60 __u32 cdw11;63 __u32 cdw11;
61 __u32 cdw12;64 __u32 cdw12;
@@ -78,5 +81,6 @@ struct nvme_passthru_cmd64 { · 16 unmodified lines
78#define NVME_IOCTL_RESCAN _IO('N', 0x46)81#define NVME_IOCTL_RESCAN _IO('N', 0x46)
79#define NVME_IOCTL_ADMIN64_CMD _IOWR('N', 0x47, struct nvme_passthru_cmd64)82#define NVME_IOCTL_ADMIN64_CMD _IOWR('N', 0x47, struct nvme_passthru_cmd64)
80#define NVME_IOCTL_IO64_CMD _IOWR('N', 0x48, struct nvme_passthru_cmd64)83#define NVME_IOCTL_IO64_CMD _IOWR('N', 0x48, struct nvme_passthru_cmd64)
84#define NVME_IOCTL_IO64_CMD_VEC _IOWR('N', 0x49, struct nvme_passthru_cmd64)
81 85
82#endif /* _UAPI_LINUX_NVME_IOCTL_H */86#endif /* _UAPI_LINUX_NVME_IOCTL_H */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t