From: Doug Ledford <dledford@redhat.com>
To: Arnd Bergmann <arnd@arndb.de>, Sean Hefty <sean.hefty@intel.com>,
Hal Rosenstock <hal.rosenstock@gmail.com>
Cc: Christoph Hellwig <hch@infradead.org>,
Matan Barak <matanb@mellanox.com>,
Yishai Hadas <yishaih@mellanox.com>,
Leon Romanovsky <leon@kernel.org>,
linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/2] [v2] IB/uverbs: clean up INIT_UDATA_BUF_OR_NULL usage
Date: Wed, 27 Sep 2017 09:09:42 -0400 [thread overview]
Message-ID: <1506517782.82712.7.camel@redhat.com> (raw)
In-Reply-To: <20170906213521.1845893-1-arnd@arndb.de>
On Wed, 2017-09-06 at 23:34 +0200, Arnd Bergmann wrote:
> We get a harmless warning about the fact that we use the result of a
> multiplication as a condition:
>
> drivers/infiniband/core/uverbs_main.c: In function 'ib_uverbs_write':
> drivers/infiniband/core/uverbs_main.c:787:40: error: '*' in boolean
> context, suggest '&&' instead [-Werror=int-in-bool-context]
> drivers/infiniband/core/uverbs_main.c:787:117: error: '*' in boolean
> context, suggest '&&' instead [-Werror=int-in-bool-context]
> drivers/infiniband/core/uverbs_main.c:790:50: error: '*' in boolean
> context, suggest '&&' instead [-Werror=int-in-bool-context]
> drivers/infiniband/core/uverbs_main.c:790:151: error: '*' in boolean
> context, suggest '&&' instead [-Werror=int-in-bool-context]
>
> This avoids the problem by using an inline function in place of
> the macro.
>
> Fixes: a96e4e2ffe43 ("IB/uverbs: New macro to set pointers to NULL if
> length is 0 in INIT_UDATA()")
> Suggested-by: Christoph Hellwig <hch@infradead.org>
> Link: https://patchwork.kernel.org/patch/9940777/
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Thanks, applied.
--
Doug Ledford <dledford@redhat.com>
GPG KeyID: B826A3330E572FDD
Key fingerprint = AE6B 1BDA 122B 23B4 265B 1274 B826 A333 0E57 2FDD
prev parent reply other threads:[~2017-09-27 13:09 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-06 21:34 [PATCH 1/2] [v2] IB/uverbs: clean up INIT_UDATA_BUF_OR_NULL usage Arnd Bergmann
2017-09-06 21:34 ` [PATCH 2/2] IB/uverbs: clean up INIT_UDATA() macro usage Arnd Bergmann
[not found] ` <20170906213521.1845893-2-arnd-r2nGTMty4D4@public.gmane.org>
2017-09-11 14:27 ` Leon Romanovsky
2017-09-11 14:27 ` Leon Romanovsky
2017-09-27 13:10 ` Doug Ledford
2017-09-27 13:10 ` Doug Ledford
2017-09-27 13:09 ` Doug Ledford [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=1506517782.82712.7.camel@redhat.com \
--to=dledford@redhat.com \
--cc=arnd@arndb.de \
--cc=hal.rosenstock@gmail.com \
--cc=hch@infradead.org \
--cc=leon@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=matanb@mellanox.com \
--cc=sean.hefty@intel.com \
--cc=yishaih@mellanox.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.