diff options
author | Jing Xiangfeng <jingxiangfeng@huawei.com> | 2020-07-24 11:54:30 +0800 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2020-08-17 14:25:23 +0300 |
commit | a58cfdba2039ff2d5758840e97a23a2dedecf1e8 (patch) | |
tree | 8066f4a580777c22128275b42d38067d5f8c7ca7 | |
parent | 9123e3a74ec7b934a4a099e98af6a61c2f80bbf5 (diff) | |
download | linux-stable-a58cfdba2039ff2d5758840e97a23a2dedecf1e8.tar.gz linux-stable-a58cfdba2039ff2d5758840e97a23a2dedecf1e8.tar.bz2 linux-stable-a58cfdba2039ff2d5758840e97a23a2dedecf1e8.zip |
ARM: OMAP2+: Fix an IS_ERR() vs NULL check in _get_pwrdm()
The of_clk_get() function returns error pointers, it never returns NULL.
Fixes: 4ea3711aece4 ("ARM: OMAP2+: omap-iommu.c conversion to ti-sysc")
Signed-off-by: Jing Xiangfeng <jingxiangfeng@huawei.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
-rw-r--r-- | arch/arm/mach-omap2/omap-iommu.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/mach-omap2/omap-iommu.c b/arch/arm/mach-omap2/omap-iommu.c index 54aff33e55e6..bfa5e1b8dba7 100644 --- a/arch/arm/mach-omap2/omap-iommu.c +++ b/arch/arm/mach-omap2/omap-iommu.c @@ -74,7 +74,7 @@ static struct powerdomain *_get_pwrdm(struct device *dev) return pwrdm; clk = of_clk_get(dev->of_node->parent, 0); - if (!clk) { + if (IS_ERR(clk)) { dev_err(dev, "no fck found\n"); return NULL; } |