only allow unprivileged passthrough for commands without effects v4
Christoph Hellwig
hch at lst.de
Thu Dec 22 23:18:08 PST 2022
Hi all,
this series first fixes a few minor issues in the CES log support in the
host and target drivers and then uses the log to deny unprivileged
passthrough of commands that have effects, where the only practically
relevant effect is the modification of contents of the data stored in the
namespace.
Changes since v3:
- clear NVME_CMD_EFFECTS_CSE_MASK for I/O commands
Changes since v2:
- drop various cleanups and aim for a minimum viable fix for 6.2
- fix the NVME_CMD_EFFECTS_CSE_MASK definition
- don't allow unprivilged passthrough without a Commands Supported and
Effects log
Changes since v1:
- make sure ctrl->effects an nshead->effects is always available
- initializse known effects at init time
- remove the use_workqueue field in nvmet_req
- fix up a commit message
Diffstat:
drivers/nvme/host/core.c | 32 ++++++++++++++++++++++++++------
drivers/nvme/host/ioctl.c | 28 ++++++++++++++++++++++++----
drivers/nvme/target/admin-cmd.c | 37 +++++++++++++++++++++----------------
drivers/nvme/target/passthru.c | 11 +++++------
include/linux/nvme.h | 4 +++-
5 files changed, 79 insertions(+), 33 deletions(-)
More information about the Linux-nvme
mailing list