diff options
author | Dave Airlie <airlied@redhat.com> | 2011-01-05 08:31:08 +1000 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2011-01-05 08:31:08 +1000 |
commit | 4f125010d2d02c481a0fdf5aee23a9f937bc5de1 (patch) | |
tree | dcdcd2ba1d0bb980b57ced9a1b2b5b17c84c8f57 /drivers/gpio/gpiolib.c | |
parent | 204663c48711ddceee09df46269cd34d49d1f7be (diff) | |
parent | 989d873fc5b6a96695b97738dea8d9f02a60f8ab (diff) | |
download | op-kernel-dev-4f125010d2d02c481a0fdf5aee23a9f937bc5de1.zip op-kernel-dev-4f125010d2d02c481a0fdf5aee23a9f937bc5de1.tar.gz |
Merge branch 'master' of /home/airlied/kernel/linux-2.6 into drm-core-next
Diffstat (limited to 'drivers/gpio/gpiolib.c')
-rw-r--r-- | drivers/gpio/gpiolib.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index 21da9c1..649550e 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c @@ -1281,6 +1281,9 @@ int gpio_request_one(unsigned gpio, unsigned long flags, const char *label) err = gpio_direction_output(gpio, (flags & GPIOF_INIT_HIGH) ? 1 : 0); + if (err) + gpio_free(gpio); + return err; } EXPORT_SYMBOL_GPL(gpio_request_one); |