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

* Re: [PATCH] nvme: consider also host_iface when checking ip options
  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
  1 sibling, 0 replies; 5+ messages in thread
From: Sagi Grimberg @ 2022-07-21 22:22 UTC (permalink / raw)
  To: Daniel Wagner, linux-nvme

Reviewed-by: Sagi Grimberg <sagi@grimberg.me>


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

* Re: [PATCH] nvme: consider also host_iface when checking ip options
  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
  1 sibling, 1 reply; 5+ messages in thread
From: Christoph Hellwig @ 2022-07-22  4:49 UTC (permalink / raw)
  To: Daniel Wagner; +Cc: linux-nvme

Thanks,

applied to nvme-5.20.


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

* Re: [PATCH] nvme: consider also host_iface when checking ip options
  2022-07-22  4:49 ` Christoph Hellwig
@ 2022-07-22  8:58   ` Daniel Wagner
  2022-07-22  9:47     ` Christoph Hellwig
  0 siblings, 1 reply; 5+ messages in thread
From: Daniel Wagner @ 2022-07-22  8:58 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: linux-nvme

On Thu, Jul 21, 2022 at 09:49:40PM -0700, Christoph Hellwig wrote:
> Thanks,
> 
> applied to nvme-5.20.

Argh, forgot to test the non host_iface case. We need to test for a null
host_iface pointer. Do want a follow up on this patch or do you drop it?


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

* Re: [PATCH] nvme: consider also host_iface when checking ip options
  2022-07-22  8:58   ` Daniel Wagner
@ 2022-07-22  9:47     ` Christoph Hellwig
  0 siblings, 0 replies; 5+ messages in thread
From: Christoph Hellwig @ 2022-07-22  9:47 UTC (permalink / raw)
  To: Daniel Wagner; +Cc: Christoph Hellwig, linux-nvme

On Fri, Jul 22, 2022 at 10:58:39AM +0200, Daniel Wagner wrote:
> On Thu, Jul 21, 2022 at 09:49:40PM -0700, Christoph Hellwig wrote:
> > Thanks,
> > 
> > applied to nvme-5.20.
> 
> Argh, forgot to test the non host_iface case. We need to test for a null
> host_iface pointer. Do want a follow up on this patch or do you drop it?

Please send an incremental patch that I can fold in.


^ permalink raw reply	[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