Message ID | 1538101068-160486-1-git-send-email-yuehaibing@huawei.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [-next] gpio: omap: Remove set but not used variable 'dev' | expand |
* YueHaibing <yuehaibing@huawei.com> [180928 02:13]: > Fixes gcc '-Wunused-but-set-variable' warning: > > drivers/gpio/gpio-omap.c: In function 'gpio_omap_cpu_notifier': > drivers/gpio/gpio-omap.c:1327:17: warning: > variable 'dev' set but not used [-Wunused-but-set-variable] > > Signed-off-by: YueHaibing <yuehaibing@huawei.com> Thanks for noticing this: Acked-by: Tony Lindgren <tony@atomide.com>
On Fri, Sep 28, 2018 at 4:08 AM YueHaibing <yuehaibing@huawei.com> wrote: > Fixes gcc '-Wunused-but-set-variable' warning: > > drivers/gpio/gpio-omap.c: In function 'gpio_omap_cpu_notifier': > drivers/gpio/gpio-omap.c:1327:17: warning: > variable 'dev' set but not used [-Wunused-but-set-variable] > > Signed-off-by: YueHaibing <yuehaibing@huawei.com> Patch applied with Tony's ACK. Yours, Linus Walleij
diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c index c0d7ae7..e67d612 100644 --- a/drivers/gpio/gpio-omap.c +++ b/drivers/gpio/gpio-omap.c @@ -1324,11 +1324,9 @@ static int gpio_omap_cpu_notifier(struct notifier_block *nb, unsigned long cmd, void *v) { struct gpio_bank *bank; - struct device *dev; unsigned long flags; bank = container_of(nb, struct gpio_bank, nb); - dev = bank->chip.parent; raw_spin_lock_irqsave(&bank->lock, flags); switch (cmd) {
Fixes gcc '-Wunused-but-set-variable' warning: drivers/gpio/gpio-omap.c: In function 'gpio_omap_cpu_notifier': drivers/gpio/gpio-omap.c:1327:17: warning: variable 'dev' set but not used [-Wunused-but-set-variable] Signed-off-by: YueHaibing <yuehaibing@huawei.com> --- drivers/gpio/gpio-omap.c | 2 -- 1 file changed, 2 deletions(-)