* [PATCHv2] nvme-tcp: only evaluate 'tls' option if TLS is selected
@ 2023-11-14 13:18 Hannes Reinecke
2023-11-14 14:03 ` Keith Busch
0 siblings, 1 reply; 2+ messages in thread
From: Hannes Reinecke @ 2023-11-14 13:18 UTC (permalink / raw)
To: Christoph Hellwig
Cc: Sagi Grimberg, Keith Busch, Jens Axboe, linux-nvme,
Hannes Reinecke, kernel test robot
We only need to evaluate the 'tls' connect option if TLS is
enabled; otherwise we might be getting a link error.
Fixes: 706add13676d ("nvme: keyring: fix conditional compilation")
Reported-by: kernel test robot <yujie.liu@intel.com>
Closes: https://lore.kernel.org/r/202311140426.0eHrTXBr-lkp@intel.com/
Signed-off-by: Hannes Reinecke <hare@suse.de>
---
drivers/nvme/host/tcp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/nvme/host/tcp.c b/drivers/nvme/host/tcp.c
index 89661a9cf850..6ed794815517 100644
--- a/drivers/nvme/host/tcp.c
+++ b/drivers/nvme/host/tcp.c
@@ -1916,7 +1916,7 @@ static int nvme_tcp_alloc_admin_queue(struct nvme_ctrl *ctrl)
int ret;
key_serial_t pskid = 0;
- if (ctrl->opts->tls) {
+ if (IS_ENABLED(CONFIG_NVME_TCP_TLS) && ctrl->opts->tls) {
if (ctrl->opts->tls_key)
pskid = key_serial(ctrl->opts->tls_key);
else
--
2.35.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-11-14 14:03 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-14 13:18 [PATCHv2] nvme-tcp: only evaluate 'tls' option if TLS is selected Hannes Reinecke
2023-11-14 14:03 ` Keith Busch
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox