Thread (23 messages) 23 messages, 6 authors, 2021-05-12

Re: [PATCH 1/1] Add 'Transport Interface' (triface) option. This can be used to specify the IP interface to use for the connection. The driver uses that to set SO_BINDTODEVICE on the socket before connecting.

From: Sagi Grimberg <sagi@grimberg.me>
Date: 2021-05-04 19:57:27

From: Martin Belanger <redacted>
Change log is missing...
quoted hunk ↗ jump to hunk
---
  drivers/nvme/host/core.c    |  5 +++++
  drivers/nvme/host/fabrics.c | 14 +++++++++++++
  drivers/nvme/host/fabrics.h |  6 +++++-
  drivers/nvme/host/tcp.c     | 41 ++++++++++++++++++++++++++++++++++---
  4 files changed, 62 insertions(+), 4 deletions(-)
diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index 288ac47ff5b4..91ae11a1ae26 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -3961,6 +3961,11 @@ static int nvme_class_uevent(struct device *dev, struct kobj_uevent_env *env)
  
  		ret = add_uevent_var(env, "NVME_HOST_TRADDR=%s",
  				opts->host_traddr ?: "none");
+		if (ret)
+			return ret;
+
+		ret = add_uevent_var(env, "NVME_HOST_TRIFACE=%s",
+				opts->host_triface ?: "none");
Given that this was the original intent for host_traddr, why not have
host_traddr resolve the iface from the address and set sockopt
SO_BINDTODEVICE on it?

_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help