From: Jason Gunthorpe <jgg@nvidia.com>
To: Tom Talpey <tom@talpey.com>
Cc: Leon Romanovsky <leon@kernel.org>,
"linux-rdma@vger.kernel.org" <linux-rdma@vger.kernel.org>,
Bernard Metzler <bmt@zurich.ibm.com>
Subject: Re: [PATCH] RDMA/siw: Add missing Kconfig selections
Date: Thu, 1 Sep 2022 09:51:24 -0300 [thread overview]
Message-ID: <YxCqzJtLdX85Agg+@nvidia.com> (raw)
In-Reply-To: <6dee3f9e-f896-c31d-557c-f7a76574b41c@talpey.com>
On Thu, Sep 01, 2022 at 08:50:12AM -0400, Tom Talpey wrote:
> On 9/1/2022 8:32 AM, Leon Romanovsky wrote:
> > On Thu, Sep 01, 2022 at 09:25:39AM -0300, Jason Gunthorpe wrote:
> > > On Wed, Aug 31, 2022 at 12:30:48PM -0400, Tom Talpey wrote:
> > > > The SoftiWARP Kconfig is missing "select" for CRYPTO and CRYPTO_CRC32C.
> > > >
> > > > In addition, it improperly "depends on" LIBCRC32C, this should be a
> > > > "select", similar to net/sctp and others. As a dependency, SIW fails
> > > > to appear in generic configurations.
> > > >
> > > > Signed-off-by: Tom Talpey <tom@talpey.com>
> > > > ---
> > > > drivers/infiniband/sw/siw/Kconfig | 5 ++++-
> > > > 1 file changed, 4 insertions(+), 1 deletion(-)
> > > >
> > > > diff --git a/drivers/infiniband/sw/siw/Kconfig
> > > > b/drivers/infiniband/sw/siw/Kconfig
> > > > index 1b5105cbabae..81b70a3eeb87 100644
> > > > --- a/drivers/infiniband/sw/siw/Kconfig
> > > > +++ b/drivers/infiniband/sw/siw/Kconfig
> > > > @@ -1,7 +1,10 @@
> > > > config RDMA_SIW
> > > > tristate "Software RDMA over TCP/IP (iWARP) driver"
> > > > - depends on INET && INFINIBAND && LIBCRC32C
> > > > + depends on INET && INFINIBAND
> > > > depends on INFINIBAND_VIRT_DMA
> > > > + select LIBCRC32C
> > > > + select CRYPTO
> > > > + select CRYPTO_CRC32C
> > >
> > > This is against the kconfig instructions Documentation/kbuild/kconfig-language.rst:
> > >
> > > Note:
> > > select should be used with care. select will force
> > > a symbol to a value without visiting the dependencies.
> > > By abusing select you are able to select a symbol FOO even
> > > if FOO depends on BAR that is not set.
> > > In general use select only for non-visible symbols
> > > (no prompts anywhere) and for symbols with no dependencies.
> > > That will limit the usefulness but on the other hand avoid
> > > the illegal configurations all over.
> > >
> > > None of them meet that criteria even though other places do abuse
> > > select like this as well.
> > >
> > > It looked fine to me the way it was, you are supposed to have to
> > > select libcrc32c manually to make siw appear, and it already brings in
> > > the other symbols.
> >
> > He took his snippet from RXE.
>
> RXE, net/sctp and many others, actually. It seems backwards for a
> subsystem to depend on a library, shouldn't libraries be there for
> selecting? If that's invalid, there are a LOT of subsystems to fix.
kconfig is a mess unfortunately, and the crypto stuff is kind of
weirdly done to be both a library and a user selectable pluggable..
Jason
next prev parent reply other threads:[~2022-09-01 12:51 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-31 16:30 [PATCH] RDMA/siw: Add missing Kconfig selections Tom Talpey
2022-09-01 6:47 ` Bernard Metzler
2022-09-01 7:13 ` Leon Romanovsky
2022-09-01 12:25 ` Jason Gunthorpe
2022-09-01 12:32 ` Leon Romanovsky
2022-09-01 12:50 ` Tom Talpey
2022-09-01 12:51 ` Jason Gunthorpe [this message]
2022-09-01 13:14 ` Tom Talpey
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=YxCqzJtLdX85Agg+@nvidia.com \
--to=jgg@nvidia.com \
--cc=bmt@zurich.ibm.com \
--cc=leon@kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=tom@talpey.com \
/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