Thread (62 messages) flat view 62 messages, 5 authors, 2023-08-21

Re: [PATCH v12 12/26] nvme-tcp: Only enable offload with TLS if the driver supports it

From: Sagi Grimberg <sagi@grimberg.me>
Date: 2023-08-09 08:05:14
Also in: linux-nvme


On 7/12/23 19:14, Aurelien Aptel wrote:
quoted hunk ↗ jump to hunk
Check if ULP offload driver supports ULP-over-TLS before enabling the
offload with tls.

Signed-off-by: Aurelien Aptel <redacted>
Signed-off-by: Shai Malin <redacted>
Reviewed-by: Max Gurtovoy <mgurtovoy@nvidia.com>
---
  drivers/nvme/host/tcp.c | 4 ++++
  1 file changed, 4 insertions(+)
diff --git a/drivers/nvme/host/tcp.c b/drivers/nvme/host/tcp.c
index e560bdf3a023..afb3dedcbc0c 100644
--- a/drivers/nvme/host/tcp.c
+++ b/drivers/nvme/host/tcp.c
@@ -367,6 +367,10 @@ static inline bool is_netdev_ulp_offload_active(struct net_device *netdev,
  	if (!nvme_tcp_ddp_query_limits(netdev, queue))
  		return false;
  
+	/* If we are using TLS and netdev doesn't support it, do not offload */
+	if (queue->ctrl->ctrl.opts->tls && !queue->ddp_limits.tls)
+		return false;
Same for this, fold to the first patch.

Other than that I had a question on one of my other responses.
I don't think that tls_device supports 1.3, so what does tls
here mean? That any device that enables this supports _all_
tls versions?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help