]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
nvme: expose TLS mode
authorDaniel Wagner <wagi@kernel.org>
Wed, 8 Apr 2026 16:19:56 +0000 (18:19 +0200)
committerKeith Busch <kbusch@kernel.org>
Thu, 16 Apr 2026 22:05:14 +0000 (15:05 -0700)
commit20925812de7bf5e6fdc133c691ef52b33f700fbc
treef08944972da106f5f43a71eb503f13fa1731e920
parentba9d308ccd6732dd97ed8080d834a4a89e758e14
nvme: expose TLS mode

It is not possible to determine the active TLS mode from the
presence or absence of sysfs attributes like tls_key,
tls_configured_key, or dhchap_secret.

With the introduction of the concat mode and optional DH-CHAP
authentication, different configurations can result in identical
sysfs state. This makes user space detection unreliable.

Expose the TLS mode explicitly to allow user space to
unambiguously identify the active configuration and avoid
fragile heuristics in nvme-cli.

Reviewed-by: Chris Leech <cleech@redhat.com>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Daniel Wagner <wagi@kernel.org>
Signed-off-by: Keith Busch <kbusch@kernel.org>
drivers/nvme/host/sysfs.c