From: Jingoo Han Date: Wed, 14 May 2014 03:15:42 +0000 (+0900) Subject: net: systemport: Use devm_ioremap_resource() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=126e612223c885a8718839d97c67473503bea58a;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git net: systemport: 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: Florian Fainelli Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethernet/broadcom/bcmsysport.c b/drivers/net/ethernet/broadcom/bcmsysport.c index 56b74a495181..f66de1344b6e 100644 --- a/drivers/net/ethernet/broadcom/bcmsysport.c +++ b/drivers/net/ethernet/broadcom/bcmsysport.c @@ -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; }