* [PATCH] gpio: regmap: fix type clash
@ 2020-07-25 23:23 Michael Walle
2020-07-26 22:28 ` Linus Walleij
0 siblings, 1 reply; 2+ messages in thread
From: Michael Walle @ 2020-07-25 23:23 UTC (permalink / raw)
To: linux-kernel, linux-gpio
Cc: Linus Walleij, Bartosz Golaszewski, Michael Walle, kernel test robot
GPIO_REGMAP_ADDR_ZERO() cast to unsigned long but the actual config
parameters are unsigned int. We use unsigned int here because that is
the type which is used by the underlying regmap.
Fixes: ebe363197e52 ("gpio: add a reusable generic gpio_chip using regmap")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Michael Walle <michael@walle.cc>
---
include/linux/gpio/regmap.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/gpio/regmap.h b/include/linux/gpio/regmap.h
index 4c1e6b34e824..ad76f3d0a6ba 100644
--- a/include/linux/gpio/regmap.h
+++ b/include/linux/gpio/regmap.h
@@ -8,7 +8,7 @@ struct gpio_regmap;
struct irq_domain;
struct regmap;
-#define GPIO_REGMAP_ADDR_ZERO ((unsigned long)(-1))
+#define GPIO_REGMAP_ADDR_ZERO ((unsigned int)(-1))
#define GPIO_REGMAP_ADDR(addr) ((addr) ? : GPIO_REGMAP_ADDR_ZERO)
/**
--
2.20.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] gpio: regmap: fix type clash
2020-07-25 23:23 [PATCH] gpio: regmap: fix type clash Michael Walle
@ 2020-07-26 22:28 ` Linus Walleij
0 siblings, 0 replies; 2+ messages in thread
From: Linus Walleij @ 2020-07-26 22:28 UTC (permalink / raw)
To: Michael Walle
Cc: linux-kernel, open list:GPIO SUBSYSTEM, Bartosz Golaszewski,
kernel test robot
On Sun, Jul 26, 2020 at 1:23 AM Michael Walle <michael@walle.cc> wrote:
> GPIO_REGMAP_ADDR_ZERO() cast to unsigned long but the actual config
> parameters are unsigned int. We use unsigned int here because that is
> the type which is used by the underlying regmap.
>
> Fixes: ebe363197e52 ("gpio: add a reusable generic gpio_chip using regmap")
> Reported-by: kernel test robot <lkp@intel.com>
> Signed-off-by: Michael Walle <michael@walle.cc>
Patch applied, thanks!
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-07-26 22:28 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-25 23:23 [PATCH] gpio: regmap: fix type clash Michael Walle
2020-07-26 22:28 ` Linus Walleij
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.