Commit fdc355a0 authored by Tiezhu Yang's avatar Tiezhu Yang Committed by Vinod Koul

phy: rockchip: Fix return value of inno_dsidphy_probe()

When call function devm_platform_ioremap_resource(), we should use IS_ERR()
to check the return value and return PTR_ERR() if failed.

Fixes: b7535a3b ("phy/rockchip: Add support for Innosilicon MIPI/LVDS/TTL PHY")
Signed-off-by: default avatarTiezhu Yang <yangtiezhu@loongson.cn>
Reviewed-by: default avatarHeiko Stuebner <heiko@sntech.de>
Link: https://lore.kernel.org/r/1590412138-13903-1-git-send-email-yangtiezhu@loongson.cnSigned-off-by: default avatarVinod Koul <vkoul@kernel.org>
parent 5a72122d
...@@ -607,8 +607,8 @@ static int inno_dsidphy_probe(struct platform_device *pdev) ...@@ -607,8 +607,8 @@ static int inno_dsidphy_probe(struct platform_device *pdev)
platform_set_drvdata(pdev, inno); platform_set_drvdata(pdev, inno);
inno->phy_base = devm_platform_ioremap_resource(pdev, 0); inno->phy_base = devm_platform_ioremap_resource(pdev, 0);
if (!inno->phy_base) if (IS_ERR(inno->phy_base))
return -ENOMEM; return PTR_ERR(inno->phy_base);
inno->ref_clk = devm_clk_get(dev, "ref"); inno->ref_clk = devm_clk_get(dev, "ref");
if (IS_ERR(inno->ref_clk)) { if (IS_ERR(inno->ref_clk)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment