]> git.sur5r.net Git - u-boot/blobdiff - drivers/gpio/mxc_gpio.c
nitrogen6x: display: add support for LG-9.7 LVDS display
[u-boot] / drivers / gpio / mxc_gpio.c
index 46c0255adc35e43fc6367f2c54ca03cf95203410..6a572d5454b39e4905da9094edd01f47cf451035 100644 (file)
@@ -127,10 +127,10 @@ int gpio_direction_input(unsigned gpio)
 
 int gpio_direction_output(unsigned gpio, int value)
 {
-       int ret = mxc_gpio_direction(gpio, MXC_GPIO_DIRECTION_OUT);
+       int ret = gpio_set_value(gpio, value);
 
        if (ret < 0)
                return ret;
 
-       return gpio_set_value(gpio, value);
+       return mxc_gpio_direction(gpio, MXC_GPIO_DIRECTION_OUT);
 }