Commit eed5d29d authored by Tushar Behera's avatar Tushar Behera Committed by David S. Miller

net: emaclite: Convert to use devm_ioremap_resource

Commit 75096579 ("lib: devres: Introduce devm_ioremap_resource()")
introduced devm_ioremap_resource() and deprecated the use of
devm_request_and_ioremap().
Signed-off-by: default avatarTushar Behera <tushar.behera@linaro.org>
CC: netdev@vger.kernel.org
CC: "David S. Miller" <davem@davemloft.net>
CC: Michal Simek <michal.simek@xilinx.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 941e173a
...@@ -1159,9 +1159,11 @@ static int xemaclite_of_probe(struct platform_device *ofdev) ...@@ -1159,9 +1159,11 @@ static int xemaclite_of_probe(struct platform_device *ofdev)
ndev->irq = res->start; ndev->irq = res->start;
res = platform_get_resource(ofdev, IORESOURCE_MEM, 0); res = platform_get_resource(ofdev, IORESOURCE_MEM, 0);
lp->base_addr = devm_request_and_ioremap(&ofdev->dev, res); lp->base_addr = devm_ioremap_resource(&ofdev->dev, res);
if (!lp->base_addr) if (IS_ERR(lp->base_addr)) {
rc = PTR_ERR(lp->base_addr);
goto error; goto error;
}
ndev->mem_start = res->start; ndev->mem_start = res->start;
ndev->mem_end = res->end; ndev->mem_end = res->end;
......
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