nvme: blank out authentication fabrics options if not configured
authorHannes Reinecke <hare@suse.de>
Thu, 16 Nov 2023 12:14:35 +0000 (13:14 +0100)
committerKeith Busch <kbusch@kernel.org>
Mon, 20 Nov 2023 17:25:32 +0000 (09:25 -0800)
commitc7ca9757bda35ff9ce27ab42f2cb8b84d983e6ad
tree8229a2fdc92236202feeb0808b8a109de5d37a88
parentcd9aed606088d36a7ffff3e808db4e76b1854285
nvme: blank out authentication fabrics options if not configured

If the config option NVME_HOST_AUTH is not selected we should not
accept the corresponding fabrics options. This allows userspace
to detect if NVMe authentication has been enabled for the kernel.

Cc: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Fixes: f50fff73d620 ("nvme: implement In-Band authentication")
Signed-off-by: Hannes Reinecke <hare@suse.de>
Tested-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Reviewed-by: Daniel Wagner <dwagner@suse.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Keith Busch <kbusch@kernel.org>
drivers/nvme/host/fabrics.c