Thread (6 messages) 6 messages, 3 authors, 2021-02-01

Re: [PATCH] gpio: gpiolib: remove shadowed variable

From: Bartosz Golaszewski <hidden>
Date: 2021-02-01 12:26:01
Also in: linux-renesas-soc

On Mon, Feb 1, 2021 at 10:04 AM Geert Uytterhoeven [off-list ref] wrote:
Hi Bartosz,

On Mon, Feb 1, 2021 at 9:59 AM Bartosz Golaszewski
[off-list ref] wrote:
quoted
On Wed, Jan 27, 2021 at 11:39 AM Wolfram Sang
[off-list ref] wrote:
quoted
On Tue, Jan 05, 2021 at 12:14:34PM +0100, Geert Uytterhoeven wrote:
quoted
On Tue, Jan 5, 2021 at 12:00 PM Wolfram Sang
[off-list ref] wrote:
quoted
After refactoring, we had two variables for the same thing. Remove the
second declaration, one is enough here. Found by cppcheck.

drivers/gpio/gpiolib.c:2551:17: warning: Local variable 'ret' shadows outer variable [shadowVariable]

Fixes: d377f56f34f5 ("gpio: gpiolib: Normalize return code variable name")
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Ccing Linus & Bartosz
For some reason this is not on patchwork and I also don't have it in
my inbox, can you resend, please?
https://lore.kernel.org/linux-gpio/20210105105914.13172-1-wsa+renesas@sang-engineering.com/ (local)

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
Thanks, now applied. Please make sure to Cc Linus and I next time.

Bartosz
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help