From: Sean Wang <sean.wang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
To: Dan Carpenter <dan.carpenter-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
Cc: linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Subject: Re: [bug report] pinctrl: mediatek: add pinctrl driver for MT7622 SoC
Date: Tue, 9 Jan 2018 22:13:46 +0800 [thread overview]
Message-ID: <1515507226.31546.12.camel@mtkswgap22> (raw)
In-Reply-To: <20180109095552.33amqzg5i2qrunhl@mwanda>
On Tue, 2018-01-09 at 12:55 +0300, Dan Carpenter wrote:
> Hello Sean Wang,
>
> The patch d6ed93551320: "pinctrl: mediatek: add pinctrl driver for
> MT7622 SoC" from Dec 12, 2017, leads to the following static checker
> warning:
>
> drivers/pinctrl/mediatek/pinctrl-mt7622.c:1419 mtk_gpio_get()
> error: uninitialized symbol 'value'.
>
> drivers/pinctrl/mediatek/pinctrl-mt7622.c
> 1412 static int mtk_gpio_get(struct gpio_chip *chip, unsigned int gpio)
> 1413 {
> 1414 struct mtk_pinctrl *hw = dev_get_drvdata(chip->parent);
> 1415 int value;
> 1416
> 1417 mtk_hw_get_value(hw, gpio, PINCTRL_PIN_REG_DI, &value);
> ^^^^^^^^^^^^^^^^
> No error handling.
>
Nice catch, Will fix it soon.
Sean
> 1418
> 1419 return !!value;
> 1420 }
>
> regards,
> dan carpenter
>
prev parent reply other threads:[~2018-01-09 14:13 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-09 9:55 [bug report] pinctrl: mediatek: add pinctrl driver for MT7622 SoC Dan Carpenter
2018-01-09 14:13 ` Sean Wang [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=1515507226.31546.12.camel@mtkswgap22 \
--to=sean.wang-nus5lvnupcjwk0htik3j/w@public.gmane.org \
--cc=dan.carpenter-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org \
--cc=linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.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