diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2013-11-07 10:50:19 +0300 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2013-11-25 09:03:12 +0100 |
commit | d535922691fc026479fcc03e78ac3d931a54e75a (patch) | |
tree | 046a205f2867e2b1c50c87284c08f572ec7f6104 /drivers/gpio/gpio-mvebu.c | |
parent | 53e7cac35db5941f42221314c33693e71ffa496b (diff) | |
download | linux-d535922691fc026479fcc03e78ac3d931a54e75a.tar.gz linux-d535922691fc026479fcc03e78ac3d931a54e75a.tar.bz2 linux-d535922691fc026479fcc03e78ac3d931a54e75a.zip |
gpio: mvebu: make mvchip->irqbase signed for error handling
There is a bug in mvebu_gpio_probe() where we do:
mvchip->irqbase = irq_alloc_descs(-1, 0, ngpios, -1);
if (mvchip->irqbase < 0) {
The problem is that mvchip->irqbase is unsigned so the error handling
doesn't work. I have changed it to be a regular int.
Cc: stable@vger.kernel.org
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio/gpio-mvebu.c')
-rw-r--r-- | drivers/gpio/gpio-mvebu.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpio/gpio-mvebu.c b/drivers/gpio/gpio-mvebu.c index 3c3321f94053..db3129043e63 100644 --- a/drivers/gpio/gpio-mvebu.c +++ b/drivers/gpio/gpio-mvebu.c @@ -79,7 +79,7 @@ struct mvebu_gpio_chip { spinlock_t lock; void __iomem *membase; void __iomem *percpu_membase; - unsigned int irqbase; + int irqbase; struct irq_domain *domain; int soc_variant; }; |