Blackfin arch: As Mike pointed out range goes form m..MAX_BLACKFIN_GPIO -1

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
This commit is contained in:
Michael Hennerich 2007-06-11 16:37:57 +08:00 committed by Bryan Wu
parent 00163e869e
commit e7613aab91
1 changed files with 1 additions and 1 deletions

View File

@ -138,7 +138,7 @@ static unsigned int sic_iwr_irqs[gpio_bank(MAX_BLACKFIN_GPIOS)] = {IRQ_PROG0_INT
inline int check_gpio(unsigned short gpio)
{
if (gpio > MAX_BLACKFIN_GPIOS)
if (gpio >= MAX_BLACKFIN_GPIOS)
return -EINVAL;
return 0;
}