* [PATCH] gpio: davinci: Use signed type for 'irq' variable
@ 2014-02-15 13:12 Alexander Shiyan
2014-02-24 13:51 ` Linus Walleij
0 siblings, 1 reply; 2+ messages in thread
From: Alexander Shiyan @ 2014-02-15 13:12 UTC (permalink / raw)
To: linux-gpio; +Cc: Linus Walleij, Alexandre Courbot, Alexander Shiyan
Variable 'irq' is declared as unsigned and then used to store
negative return values from irq_alloc_descs() such as -EINVAL.
This patch fix this by declaring the variable as a signed.
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
---
drivers/gpio/gpio-davinci.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/gpio/gpio-davinci.c b/drivers/gpio/gpio-davinci.c
index 7629b4f..29321ee 100644
--- a/drivers/gpio/gpio-davinci.c
+++ b/drivers/gpio/gpio-davinci.c
@@ -423,7 +423,8 @@ static const struct irq_domain_ops davinci_gpio_irq_ops = {
static int davinci_gpio_irq_setup(struct platform_device *pdev)
{
- unsigned gpio, irq, bank;
+ unsigned gpio, bank;
+ int irq;
struct clk *clk;
u32 binten = 0;
unsigned ngpio, bank_irq;
--
1.8.3.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-02-24 13:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-15 13:12 [PATCH] gpio: davinci: Use signed type for 'irq' variable Alexander Shiyan
2014-02-24 13:51 ` Linus Walleij
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).