summaryrefslogtreecommitdiffstats
path: root/drivers/gpio/gpio-tb10x.c
diff options
context:
space:
mode:
authorAxel Lin <axel.lin@ingics.com>2013-10-31 11:23:46 +0800
committerLinus Walleij <linus.walleij@linaro.org>2013-11-25 09:02:29 +0100
commit2e86230fcb918172751b4aadeb5782409e769988 (patch)
tree3391b2a07ee6f44bad8a679da22184a88bd0fbfc /drivers/gpio/gpio-tb10x.c
parent6ce4eac1f600b34f2f7f58f9cd8f0503d79e42ae (diff)
downloadlinux-2e86230fcb918172751b4aadeb5782409e769988.tar.gz
linux-2e86230fcb918172751b4aadeb5782409e769988.tar.bz2
linux-2e86230fcb918172751b4aadeb5782409e769988.zip
gpio: tb10x: Set output value before setting direction to output
Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Christian Ruppert <christian.ruppert@abilis.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio/gpio-tb10x.c')
-rw-r--r--drivers/gpio/gpio-tb10x.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpio/gpio-tb10x.c b/drivers/gpio/gpio-tb10x.c
index 0502b9a041a5..da071ddbad99 100644
--- a/drivers/gpio/gpio-tb10x.c
+++ b/drivers/gpio/gpio-tb10x.c
@@ -132,6 +132,7 @@ static int tb10x_gpio_direction_out(struct gpio_chip *chip,
int mask = BIT(offset);
int val = TB10X_GPIO_DIR_OUT << offset;
+ tb10x_gpio_set(chip, offset, value);
tb10x_set_bits(tb10x_gpio, OFFSET_TO_REG_DDR, mask, val);
return 0;