From: David Laight <David.Laight@ACULAB.COM>
To: 'Miles Chen' <miles.chen@mediatek.com>,
Lakshmi Sowjanya D <lakshmi.sowjanya.d@intel.com>,
Linus Walleij <linus.walleij@linaro.org>,
Matthias Brugger <matthias.bgg@gmail.com>,
Kiran Kumar S <kiran.kumar1.s@intel.com>
Cc: "linux-gpio@vger.kernel.org" <linux-gpio@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
"linux-mediatek@lists.infradead.org"
<linux-mediatek@lists.infradead.org>
Subject: RE: [PATCH] pinctrl: fix a discarded-qualifiers build error
Date: Tue, 25 Jan 2022 22:17:38 +0000 [thread overview]
Message-ID: <693a71e17b364afd987f2d2178b7e5cb@AcuMS.aculab.com> (raw)
In-Reply-To: <20220125175457.23728-1-miles.chen@mediatek.com>
From: Miles Chen
> Sent: 25 January 2022 17:55
>
> Fix COMPILER=gcc ARCH=arm64 DEFCONFIG=allyesconfig build:
>
> log:
> drivers/pinctrl/pinctrl-thunderbay.c:815:29: error: assignment discards
> 'const' qualifier from pointer target type [-Werror=discarded-qualifiers]
>
> Fixes: 12422af8194d ("pinctrl: Add Intel Thunder Bay pinctrl driver")
> Signed-off-by: Miles Chen <miles.chen@mediatek.com>
> ---
> drivers/pinctrl/pinctrl-thunderbay.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/pinctrl/pinctrl-thunderbay.c b/drivers/pinctrl/pinctrl-thunderbay.c
> index b5b47f4dd774..4e6d718c03fc 100644
> --- a/drivers/pinctrl/pinctrl-thunderbay.c
> +++ b/drivers/pinctrl/pinctrl-thunderbay.c
> @@ -812,7 +812,7 @@ static int thunderbay_add_functions(struct thunderbay_pinctrl *tpc, struct funct
> }
> }
>
> - grp = func->group_names;
> + grp = (const char **)func->group_names;
You should change the type of 'grp' not add a cast.
The compiler can warn about casts removing 'const' as well.
David
-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK
Registration No: 1397386 (Wales)
next prev parent reply other threads:[~2022-01-25 22:17 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-25 17:54 Miles Chen
2022-01-25 22:17 ` David Laight [this message]
2022-01-26 5:11 ` Miles Chen
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=693a71e17b364afd987f2d2178b7e5cb@AcuMS.aculab.com \
--to=david.laight@aculab.com \
--cc=kiran.kumar1.s@intel.com \
--cc=lakshmi.sowjanya.d@intel.com \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=matthias.bgg@gmail.com \
--cc=miles.chen@mediatek.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
Powered by JetHome