提交 28a26945 编写于 作者: V Varka Bhadram 提交者: Felipe Balbi

usb: phy: rcar-usb: remove duplicate check on resource

Sanity check on resource happening with devm_ioremap_resource().
Signed-off-by: NVarka Bhadram <varkab@cdac.in>
Signed-off-by: NFelipe Balbi <balbi@ti.com>
上级 687f16b8
...@@ -195,11 +195,9 @@ static int rcar_usb_phy_probe(struct platform_device *pdev) ...@@ -195,11 +195,9 @@ static int rcar_usb_phy_probe(struct platform_device *pdev)
return PTR_ERR(reg0); return PTR_ERR(reg0);
res1 = platform_get_resource(pdev, IORESOURCE_MEM, 1); res1 = platform_get_resource(pdev, IORESOURCE_MEM, 1);
if (res1) { reg1 = devm_ioremap_resource(dev, res1);
reg1 = devm_ioremap_resource(dev, res1); if (IS_ERR(reg1))
if (IS_ERR(reg1)) return PTR_ERR(reg1);
return PTR_ERR(reg1);
}
priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL); priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL);
if (!priv) if (!priv)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册