From: Christoph Hellwig <hch@lst.de>
To: Hannes Reinecke <hare@kernel.org>
Cc: Christoph Hellwig <hch@lst.de>, Sagi Grimberg <sagi@grimberg.me>,
Keith Busch <kbusch@kernel.org>,
linux-nvme@lists.infradead.org
Subject: Re: [PATCH] nvmet: make 'tsas' attribute idempotent for RDMA
Date: Fri, 14 Jun 2024 18:49:29 +0200 [thread overview]
Message-ID: <20240614164929.GC20338@lst.de> (raw)
In-Reply-To: <20240614104445.105041-1-hare@kernel.org>
> + if (port->disc_addr.trtype == NVMF_TRTYPE_RDMA) {
> + for (i = 0; i < ARRAY_SIZE(nvmet_addr_tsas_rdma); i++) {
> + u8 qptype;
> +
> + if (sysfs_streq(page, nvmet_addr_tsas_rdma[i].name)) {
> + qptype = nvmet_addr_tsas_rdma[i].type;
> + if (qptype == port->disc_addr.tsas.rdma.qptype)
> + return count;
> + }
> + }
> + }
> if (port->disc_addr.trtype != NVMF_TRTYPE_TCP)
> return -EINVAL;
Sounds like this should switch on the transport types and have helpers
for each.
prev parent reply other threads:[~2024-06-14 16:49 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-06-14 10:44 [PATCH] nvmet: make 'tsas' attribute idempotent for RDMA Hannes Reinecke
2024-06-14 16:49 ` Christoph Hellwig [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240614164929.GC20338@lst.de \
--to=hch@lst.de \
--cc=hare@kernel.org \
--cc=kbusch@kernel.org \
--cc=linux-nvme@lists.infradead.org \
--cc=sagi@grimberg.me \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).