]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
USB: ehci-tegra: remove redundant gpio_set_value
authorStephen Warren <swarren@nvidia.com>
Mon, 30 Apr 2012 23:24:10 +0000 (17:24 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 7 May 2012 15:53:24 +0000 (08:53 -0700)
commit 04c235c92ce8474e9f2b358bd97f013a500385f2 upstream.

The immediately preceding gpio_direction_output() already set the value,
so there's no need to repeat it. This also prevents gpio_set_value() from
WARNing when the GPIO is sleepable (e.g. is on an I2C expander); the set
direction API is always sleepable, but plain set_value isn't.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/host/ehci-tegra.c

index dbc7fe8ca9e7d692dc750d58e49e3bbcc13b6140..de36b8c66626600d7e5455d107e6226de03079fa 100644 (file)
@@ -601,7 +601,6 @@ static int setup_vbus_gpio(struct platform_device *pdev)
                dev_err(&pdev->dev, "can't enable vbus\n");
                return err;
        }
-       gpio_set_value(gpio, 1);
 
        return err;
 }