diff options
Diffstat (limited to 'drivers/clk/mvebu')
-rw-r--r-- | drivers/clk/mvebu/common.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/clk/mvebu/common.c b/drivers/clk/mvebu/common.c index f3be5f2974..0e7f65c488 100644 --- a/drivers/clk/mvebu/common.c +++ b/drivers/clk/mvebu/common.c @@ -15,6 +15,7 @@ #include <init.h> #include <of.h> #include <linux/clk.h> +#include <linux/err.h> #include <linux/clkdev.h> #include "common.h" @@ -166,8 +167,8 @@ int mvebu_clk_gating_probe(struct device_d *dev) desc = (const struct clk_gating_soc_desc *)match->data; base = dev_request_mem_region(dev, 0); - if (!base) - return -EINVAL; + if (IS_ERR(base)) + return PTR_ERR(base); clk = of_clk_get(np, 0); if (IS_ERR(clk)) |