[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAGVrzcZDCJq5vWurOyN-2um9LZp5Hg8UA_XFisqHMh5PjGxDkg@mail.gmail.com>
Date: Mon, 24 Feb 2014 09:29:06 -0800
From: Florian Fainelli <f.fainelli@...il.com>
To: Fabio Estevam <festevam@...il.com>
Cc: David Miller <davem@...emloft.net>,
netdev <netdev@...r.kernel.org>,
Fabio Estevam <fabio.estevam@...escale.com>
Subject: Re: [PATCH v2] net: bcmgenet: Use devm_ioremap_resource()
2014-02-23 19:47 GMT-08:00 Fabio Estevam <festevam@...il.com>:
> From: Fabio Estevam <fabio.estevam@...escale.com>
>
> According to Documentation/driver-model/devres.txt, devm_request_and_ioremap()
> is deprecated, so use devm_ioremap_resource() instead.
Acked-by: Florian Fainelli <f.fainelli@...il.com>
>
> Signed-off-by: Fabio Estevam <fabio.estevam@...escale.com>
> ---
> Changes since v1:
> - Fix subject
>
> drivers/net/ethernet/broadcom/genet/bcmgenet.c | 7 +++----
> 1 file changed, 3 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/net/ethernet/broadcom/genet/bcmgenet.c b/drivers/net/ethernet/broadcom/genet/bcmgenet.c
> index 0ebc297..844e081 100644
> --- a/drivers/net/ethernet/broadcom/genet/bcmgenet.c
> +++ b/drivers/net/ethernet/broadcom/genet/bcmgenet.c
> @@ -2481,10 +2481,9 @@ static int bcmgenet_probe(struct platform_device *pdev)
> }
>
> r = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> - priv->base = devm_request_and_ioremap(&pdev->dev, r);
> - if (!priv->base) {
> - dev_err(&pdev->dev, "can't ioremap\n");
> - err = -EINVAL;
> + priv->base = devm_ioremap_resource(&pdev->dev, r);
> + if (IS_ERR(priv->base)) {
> + err = PTR_ERR(priv->base);
> goto err;
> }
>
> --
> 1.8.1.2
>
--
Florian
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists