Skip to content

Commit

Permalink
gpio: tb10x: Set output value before setting direction to output
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Axel Lin authored and Linus Walleij committed Nov 25, 2013
1 parent 6ce4eac commit 2e86230
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/gpio/gpio-tb10x.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 2e86230

Please sign in to comment.