]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
remove gpio functions provided by gpiolib.c
authorLothar Waßmann <LW@KARO-electronics.de>
Fri, 17 Aug 2012 13:37:27 +0000 (15:37 +0200)
committerLothar Waßmann <LW@KARO-electronics.de>
Fri, 17 Aug 2012 13:37:27 +0000 (15:37 +0200)
board/karo/tx51/tx51.c

index 8eb2cbdb9afb1c7c54543f0455e995b4f34cd270..15dc9997b523614700b80bb87780a75c43975841 100644 (file)
 
 DECLARE_GLOBAL_DATA_PTR;
 
-enum gpio_flags {
-       GPIOF_INPUT,
-       GPIOF_OUTPUT_INIT_LOW,
-       GPIOF_OUTPUT_INIT_HIGH,
-};
-
-struct gpio {
-       unsigned int gpio;
-       enum gpio_flags flags;
-       const char *label;
-};
-
-static int gpio_request_array(const struct gpio *gp, int count)
-{
-       int ret;
-       int i;
-
-       for (i = 0; i < count; i++) {
-               ret = gpio_request(gp[i].gpio, gp[i].label);
-               if (ret)
-                       goto error;
-
-               if (gp[i].flags == GPIOF_INPUT)
-                       gpio_direction_input(gp[i].gpio);
-               else if (gp[i].flags == GPIOF_OUTPUT_INIT_LOW)
-                       gpio_direction_output(gp[i].gpio, 0);
-               else if (gp[i].flags == GPIOF_OUTPUT_INIT_HIGH)
-                       gpio_direction_output(gp[i].gpio, 1);
-       }
-       return 0;
-
-error:
-       while (--i >= 0)
-               gpio_free(gp[i].gpio);
-
-       return ret;
-}
-
 #define IOMUX_SION             IOMUX_PAD(0, 0, IOMUX_CONFIG_SION, 0, 0, 0)
 
 static iomux_v3_cfg_t tx51_pads[] = {