public inbox for linux-nvme@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH] nvme: consider also host_iface when checking ip options
@ 2022-07-21 17:44 Daniel Wagner
  2022-07-21 22:22 ` Sagi Grimberg
  2022-07-22  4:49 ` Christoph Hellwig
  0 siblings, 2 replies; 5+ messages in thread
From: Daniel Wagner @ 2022-07-21 17:44 UTC (permalink / raw)
  To: linux-nvme; +Cc: Daniel Wagner

It's perfectly fine to use the same traddr and trsvcid more than once
as long we use different host interface. This is used in setups where
the host has more than one interface but the target exposes only one
traddr/trsvcid combination.

Signed-off-by: Daniel Wagner <dwagner@suse.de>
---
 drivers/nvme/host/fabrics.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/nvme/host/fabrics.c b/drivers/nvme/host/fabrics.c
index 604ab0e5a2ad..10ef2e249d88 100644
--- a/drivers/nvme/host/fabrics.c
+++ b/drivers/nvme/host/fabrics.c
@@ -944,7 +944,8 @@ bool nvmf_ip_options_match(struct nvme_ctrl *ctrl,
 {
 	if (!nvmf_ctlr_matches_baseopts(ctrl, opts) ||
 	    strcmp(opts->traddr, ctrl->opts->traddr) ||
-	    strcmp(opts->trsvcid, ctrl->opts->trsvcid))
+	    strcmp(opts->trsvcid, ctrl->opts->trsvcid) ||
+	    strcmp(opts->host_iface, ctrl->opts->host_iface))
 		return false;
 
 	/*
-- 
2.37.1



^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-07-22  9:47 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-21 17:44 [PATCH] nvme: consider also host_iface when checking ip options Daniel Wagner
2022-07-21 22:22 ` Sagi Grimberg
2022-07-22  4:49 ` Christoph Hellwig
2022-07-22  8:58   ` Daniel Wagner
2022-07-22  9:47     ` Christoph Hellwig

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox