Skip to content

Commit

Permalink
gpio: ath79: Fix the logic to clear offset bit of AR71XX_GPIO_REG_OE …
Browse files Browse the repository at this point in the history
…register

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Alban Bedel <albeu@free.fr>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
  • Loading branch information
Axel Lin authored and Linus Walleij committed Dec 11, 2015
1 parent 527e931 commit 3a57e74
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/gpio/gpio-ath79.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ static int ar934x_gpio_direction_output(struct gpio_chip *chip, unsigned offset,
__raw_writel(BIT(offset), ctrl->base + AR71XX_GPIO_REG_CLEAR);

__raw_writel(
__raw_readl(ctrl->base + AR71XX_GPIO_REG_OE) & BIT(offset),
__raw_readl(ctrl->base + AR71XX_GPIO_REG_OE) & ~BIT(offset),
ctrl->base + AR71XX_GPIO_REG_OE);

spin_unlock_irqrestore(&ctrl->lock, flags);
Expand Down

0 comments on commit 3a57e74

Please sign in to comment.