ARM: 5731/2: Fix U300 generic GPIO, remove ifdefs from MMCI v3
The #ifdefs in the MMCI driver were erroneous and just masking a bug in the U300 generic GPIO implementation. This removes the ifdefs and fixes the U300 generic GPIO instead. Signed-off-by: Linus Walleij <linus.walleij@stericsson.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
This commit is contained in:
committed by
Russell King
parent
aa45ee8fc0
commit
ee17962e24
@ -281,6 +281,16 @@ int gpio_unregister_callback(unsigned gpio)
|
||||
}
|
||||
EXPORT_SYMBOL(gpio_unregister_callback);
|
||||
|
||||
/* Non-zero means valid */
|
||||
int gpio_is_valid(int number)
|
||||
{
|
||||
if (number >= 0 &&
|
||||
number < (U300_GPIO_NUM_PORTS * U300_GPIO_PINS_PER_PORT))
|
||||
return 1;
|
||||
return 0;
|
||||
}
|
||||
EXPORT_SYMBOL(gpio_is_valid);
|
||||
|
||||
int gpio_request(unsigned gpio, const char *label)
|
||||
{
|
||||
if (gpio_pin[gpio].users)
|
||||
|
Reference in New Issue
Block a user