]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
gpio: sifive: fix static checker warning
authorYash Shah <yash.shah@sifive.com>
Tue, 28 Jan 2020 05:24:21 +0000 (10:54 +0530)
committerLinus Walleij <linus.walleij@linaro.org>
Mon, 10 Feb 2020 12:54:17 +0000 (13:54 +0100)
commita924eae75106258c0797706a0578c5af499c9ff5
tree348316e129f90221570ae8562c7d8f6896545def
parent2d5a2f913b658a7ae984773a63318ed4daadf4af
gpio: sifive: fix static checker warning

Typcasting "irq_state" leads to the below static checker warning:
The fix is to declare "irq_state" as unsigned long instead of u32.

drivers/gpio/gpio-sifive.c:97 sifive_gpio_irq_enable()
warn: passing casted pointer '&chip->irq_state' to
'assign_bit()' 32 vs 64.

Fixes: 96868dce644d ("gpio/sifive: Add GPIO driver for SiFive SoCs")
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Yash Shah <yash.shah@sifive.com>
Link: https://lore.kernel.org/r/1580189061-14091-1-git-send-email-yash.shah@sifive.com
Reviewed-by: Marc Zyngier <maz@kernel.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/gpio/gpio-sifive.c