From: Jingoo Han Date: Wed, 14 May 2014 03:17:14 +0000 (+0900) Subject: mfd: ipaq-micro: Use devm_ioremap_resource() X-Git-Tag: firefly_0821_release~176^2~3820^2~6^2~19 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=63c348cb2b9c41fad259e6471692927f95e61d27;p=firefly-linux-kernel-4.4.55.git mfd: ipaq-micro: Use devm_ioremap_resource() Use devm_ioremap_resource() because devm_request_and_ioremap() is obsoleted by devm_ioremap_resource(). Signed-off-by: Jingoo Han Acked-by: Linus Walleij Signed-off-by: Lee Jones --- diff --git a/drivers/mfd/ipaq-micro.c b/drivers/mfd/ipaq-micro.c index 1763d6db346e..5d08daf3bd2b 100644 --- a/drivers/mfd/ipaq-micro.c +++ b/drivers/mfd/ipaq-micro.c @@ -403,17 +403,17 @@ static int micro_probe(struct platform_device *pdev) if (!res) return -EINVAL; - micro->base = devm_request_and_ioremap(&pdev->dev, res); - if (!micro->base) - return -ENOMEM; + micro->base = devm_ioremap_resource(&pdev->dev, res); + if (IS_ERR(micro->base)) + return PTR_ERR(micro->base); res = platform_get_resource(pdev, IORESOURCE_MEM, 1); if (!res) return -EINVAL; - micro->sdlc = devm_request_and_ioremap(&pdev->dev, res); - if (!micro->sdlc) - return -ENOMEM; + micro->sdlc = devm_ioremap_resource(&pdev->dev, res); + if (IS_ERR(micro->sdlc)) + return PTR_ERR(micro->sdlc); micro_reset_comm(micro);