From: Lee Jones <lee.jones@linaro.org>
To: Nathan Chancellor <natechancellor@gmail.com>
Cc: linux-kernel@vger.kernel.org,
Douglas Anderson <dianders@chromium.org>,
Gwendal Grignou <gwendal@chromium.org>,
Stephen Boyd <swboyd@chromium.org>,
Benson Leung <bleung@chromium.org>,
Nick Desaulniers <ndesaulniers@google.com>
Subject: Re: [PATCH] mfd: cros_ec: Avoid unneeded internal declaration warning
Date: Tue, 9 Oct 2018 11:09:34 +0100 [thread overview]
Message-ID: <20181009100934.GK4939@dell> (raw)
In-Reply-To: <20180928011614.GA3681@flashbox>
On Thu, 27 Sep 2018, Nathan Chancellor wrote:
> On Wed, Sep 26, 2018 at 08:33:17PM -0700, Nathan Chancellor wrote:
> > Clang warns:
> >
> > drivers/mfd/cros_ec_dev.c:509:40: warning: variable 'cros_ec_id' is not
> > needed and will not be emitted [-Wunneeded-internal-declaration]
> > static const struct platform_device_id cros_ec_id[] = {
> > ^
> > 1 warning generated.
> >
> > Avoid this warning by adding it to the cros_ec_dev_driver definition
> > under the id_table member like all other platform drivers.
> >
> > Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
> > ---
> >
> > I looked at several drivers with platform_device_id defintions and I
> > didn't really find any where the definition wasn't then added to the
> > platform_driver so I'm not sure if this was just missed in commit
> > afbf8ec7c4f9 ("platform/chrome: cros_ec_dev - Add a platform
> > device ID table") or if it was an intentional omission. I'm not super
> > familiar with the inner workings of platform devices.
> >
> > Should this commit be undesirable, the warning can be silenced with the
> > __used attribute but this seemed like a more proper first commit.
> >
> > drivers/mfd/cros_ec_dev.c | 1 +
> > 1 file changed, 1 insertion(+)
Applied, thanks.
--
Lee Jones [李琼斯]
Linaro Services Technical Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
next prev parent reply other threads:[~2018-10-09 10:09 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-27 3:33 [PATCH] mfd: cros_ec: Avoid unneeded internal declaration warning Nathan Chancellor
2018-09-28 1:16 ` Nathan Chancellor
2018-10-09 10:09 ` Lee Jones [this message]
2018-10-09 16:15 ` Stephen Boyd
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=20181009100934.GK4939@dell \
--to=lee.jones@linaro.org \
--cc=bleung@chromium.org \
--cc=dianders@chromium.org \
--cc=gwendal@chromium.org \
--cc=linux-kernel@vger.kernel.org \
--cc=natechancellor@gmail.com \
--cc=ndesaulniers@google.com \
--cc=swboyd@chromium.org \
/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