diff options
Diffstat (limited to 'drivers/gpio')
-rw-r--r-- | drivers/gpio/langwell_gpio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpio/langwell_gpio.c b/drivers/gpio/langwell_gpio.c index 4baf3d7d0f8e..6c0ebbdc659e 100644 --- a/drivers/gpio/langwell_gpio.c +++ b/drivers/gpio/langwell_gpio.c | |||
@@ -123,7 +123,7 @@ static int lnw_irq_type(unsigned irq, unsigned type) | |||
123 | void __iomem *grer = (void __iomem *)(&lnw->reg_base->GRER[reg]); | 123 | void __iomem *grer = (void __iomem *)(&lnw->reg_base->GRER[reg]); |
124 | void __iomem *gfer = (void __iomem *)(&lnw->reg_base->GFER[reg]); | 124 | void __iomem *gfer = (void __iomem *)(&lnw->reg_base->GFER[reg]); |
125 | 125 | ||
126 | if (gpio < 0 || gpio > lnw->chip.ngpio) | 126 | if (gpio >= lnw->chip.ngpio) |
127 | return -EINVAL; | 127 | return -EINVAL; |
128 | spin_lock_irqsave(&lnw->lock, flags); | 128 | spin_lock_irqsave(&lnw->lock, flags); |
129 | if (type & IRQ_TYPE_EDGE_RISING) | 129 | if (type & IRQ_TYPE_EDGE_RISING) |