Commit 9cfc93b2 authored by Christophe JAILLET's avatar Christophe JAILLET Committed by Olof Johansson

ARM: zx: Fix error handling

'devm_ioremap_resource()' returns an error pointer in case of error, not
NULL. So test it with IS_ERR.
Signed-off-by: default avatarChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
parent ce340961
......@@ -169,7 +169,7 @@ static int zx296702_pd_probe(struct platform_device *pdev)
}
pcubase = devm_ioremap_resource(&pdev->dev, res);
if (!pcubase) {
if (IS_ERR(pcubase)) {
dev_err(&pdev->dev, "ioremap fail.\n");
return -EIO;
}
......
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