]> git.ipfire.org Git - thirdparty/linux.git/commit
nvme: Allow reauth from sysfs
authorAlistair Francis <alistair.francis@wdc.com>
Tue, 2 Dec 2025 05:17:55 +0000 (15:17 +1000)
committerKeith Busch <kbusch@kernel.org>
Fri, 27 Mar 2026 14:35:03 +0000 (07:35 -0700)
commited6a9f7dabf84a9f2bed418e66eda6f8239b7f60
tree5ee600db3b4822214b15a634e0b235564f93a9c5
parent56d25f1a6e312e36ee07c605c4102e0848245381
nvme: Allow reauth from sysfs

Allow userspace to trigger a reauth (REPLACETLSPSK) from sysfs.
This can be done by writing  a zero to the sysfs file.

echo 0 > /sys/devices/virtual/nvme-fabrics/ctl/nvme0/tls_configured_key

In order to use the new keys for the admin queue we call controller
reset. This isn't ideal, but I can't find a simpler way to reset the
admin queue TLS connection.

Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Wilfred Mallawa <wilfred.mallawa@wdc.com>
Signed-off-by: Keith Busch <kbusch@kernel.org>
Documentation/ABI/testing/sysfs-nvme [new file with mode: 0644]
drivers/nvme/host/sysfs.c