#include <common.h>
#include <command.h>
+#include <linux/ctype.h>
#include <asm/blackfin.h>
#include <asm/gpio.h>
/* grab the [p]<port> portion */
ulong port_base;
- if (*str_pin == 'p') ++str_pin;
- switch (*str_pin) {
+ if (tolower(*str_pin) == 'p') ++str_pin;
+ switch (tolower(*str_pin)) {
#ifdef GPIO_PA0
case 'a': port_base = GPIO_PA0; break;
#endif
gpio_free(gpio);
- return 0;
+ return value;
}
U_BOOT_CMD(gpio, 3, 0, do_gpio,