diff options
author | Shawn Lin <shawn.lin@rock-chips.com> | 2016-02-15 04:33:57 +0100 |
---|---|---|
committer | Heiko Stuebner <heiko@sntech.de> | 2016-04-12 03:28:08 +0200 |
commit | 4506697d9f8537a8d33e9e002f8efceb32d10757 (patch) | |
tree | dd6cda03f1a2913b4b4dbd4fd400f946c39c845a /drivers | |
parent | soc: rockchip: power-domain: Modify power domain driver for rk3399 (diff) | |
download | linux-4506697d9f8537a8d33e9e002f8efceb32d10757.tar.xz linux-4506697d9f8537a8d33e9e002f8efceb32d10757.zip |
soc: rockchip: power-domain: check the existing of regmap
Check return value of syscon_node_to_regmap for
rockchip_pm_domain_probe. If err value is returned, probe
procedure should abort.
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/soc/rockchip/pm_domains.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/soc/rockchip/pm_domains.c b/drivers/soc/rockchip/pm_domains.c index 2116131528f7..ac729fe42cc9 100644 --- a/drivers/soc/rockchip/pm_domains.c +++ b/drivers/soc/rockchip/pm_domains.c @@ -475,6 +475,10 @@ static int rockchip_pm_domain_probe(struct platform_device *pdev) } pmu->regmap = syscon_node_to_regmap(parent->of_node); + if (IS_ERR(pmu->regmap)) { + dev_err(dev, "no regmap available\n"); + return PTR_ERR(pmu->regmap); + } /* * Configure power up and down transition delays for CORE |