diff options
author | Arvind Yadav <arvind.yadav.cs@gmail.com> | 2017-08-01 12:13:05 +0530 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2017-08-14 15:03:38 +0200 |
commit | d829b37ae3bfdb7252e63bd098ad75a96adabe97 (patch) | |
tree | b3dba784d3b6df23de2d1c6e891ac3638aea0229 /drivers/gpio | |
parent | 01062ad31b531f2a3bcbfd9f6267e4e0c1103010 (diff) | |
download | linux-stable-d829b37ae3bfdb7252e63bd098ad75a96adabe97.tar.gz linux-stable-d829b37ae3bfdb7252e63bd098ad75a96adabe97.tar.bz2 linux-stable-d829b37ae3bfdb7252e63bd098ad75a96adabe97.zip |
gpio: mb86s7x: Handle return value of clk_prepare_enable.
clk_prepare_enable() can fail here and we must check its return value.
Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio')
-rw-r--r-- | drivers/gpio/gpio-mb86s7x.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpio/gpio-mb86s7x.c b/drivers/gpio/gpio-mb86s7x.c index ffb73f688ae1..94d772677ed6 100644 --- a/drivers/gpio/gpio-mb86s7x.c +++ b/drivers/gpio/gpio-mb86s7x.c @@ -168,7 +168,9 @@ static int mb86s70_gpio_probe(struct platform_device *pdev) if (IS_ERR(gchip->clk)) return PTR_ERR(gchip->clk); - clk_prepare_enable(gchip->clk); + ret = clk_prepare_enable(gchip->clk); + if (ret) + return ret; spin_lock_init(&gchip->lock); |