net: systemport: Use devm_ioremap_resource()
authorJingoo Han <jg1.han@samsung.com>
Wed, 14 May 2014 03:15:42 +0000 (12:15 +0900)
committerDavid S. Miller <davem@davemloft.net>
Wed, 14 May 2014 19:42:07 +0000 (15:42 -0400)
Use devm_ioremap_resource() because devm_request_and_ioremap() is
obsoleted by devm_ioremap_resource().

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bcmsysport.c

index 56b74a495181eef7903e7a76c6868d584a9e25d6..f66de1344b6eb4c47923fc5ed8612756006a91f6 100644 (file)
@@ -1514,10 +1514,9 @@ static int bcm_sysport_probe(struct platform_device *pdev)
                goto err;
        }
 
-       priv->base = devm_request_and_ioremap(&pdev->dev, r);
-       if (!priv->base) {
-               dev_err(&pdev->dev, "register remap failed\n");
-               ret = -ENOMEM;
+       priv->base = devm_ioremap_resource(&pdev->dev, r);
+       if (IS_ERR(priv->base)) {
+               ret = PTR_ERR(priv->base);
                goto err;
        }