gpio: viperboard: Remove duplicate code to set gpio->gpiob_val
authorAxel Lin <axel.lin@ingics.com>
Tue, 5 Mar 2013 12:21:56 +0000 (20:21 +0800)
committerLinus Walleij <linus.walleij@linaro.org>
Wed, 27 Mar 2013 08:13:06 +0000 (09:13 +0100)
Set it once is enough, and it's done in vprbrd_gpiob_set() which is called by
vprbrd_gpiob_direction_output().

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Tested-by: Lars Poeschel <poeschel@lemonage.de>
Acked-by: Lars Poeschel <poeschel@lemonage.de>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/gpio/gpio-viperboard.c

index 59d7239..095ab14 100644 (file)
@@ -380,10 +380,6 @@ static int vprbrd_gpiob_direction_output(struct gpio_chip *chip,
        struct vprbrd *vb = gpio->vb;
 
        gpio->gpiob_out |= (1 << offset);
-       if (value)
-               gpio->gpiob_val |= (1 << offset);
-       else
-               gpio->gpiob_val &= ~(1 << offset);
 
        mutex_lock(&vb->lock);