[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <DB8PR04MB71626E57AECABAA95C60E7F88B790@DB8PR04MB7162.eurprd04.prod.outlook.com>
Date: Wed, 22 Jul 2020 08:46:12 +0000
From: Peter Chen <peter.chen@....com>
To: Chunfeng Yun <chunfeng.yun@...iatek.com>,
Felipe Balbi <balbi@...nel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>
CC: Matthias Brugger <matthias.bgg@...il.com>,
"linux-usb@...r.kernel.org" <linux-usb@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>,
"linux-mediatek@...ts.infradead.org"
<linux-mediatek@...ts.infradead.org>
Subject: RE: [PATCH 3/7] usb: cdns3: convert to
devm_platform_ioremap_resource_byname
> Use devm_platform_ioremap_resource_byname() to simplify code
>
> Cc: Peter Chen <peter.chen@....com>
> Signed-off-by: Chunfeng Yun <chunfeng.yun@...iatek.com>
> ---
> drivers/usb/cdns3/core.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/usb/cdns3/core.c b/drivers/usb/cdns3/core.c index
> 19bbb5b..24faf60 100644
> --- a/drivers/usb/cdns3/core.c
> +++ b/drivers/usb/cdns3/core.c
> @@ -436,8 +436,7 @@ static int cdns3_probe(struct platform_device *pdev)
> if (cdns->dev_irq < 0)
> dev_err(dev, "couldn't get peripheral irq\n");
>
> - res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "dev");
> - regs = devm_ioremap_resource(dev, res);
> + regs = devm_platform_ioremap_resource_byname(pdev, "dev");
> if (IS_ERR(regs))
> return PTR_ERR(regs);
> cdns->dev_regs = regs;
> --
Reviewed-by: Peter Chen <peter.chen@....com>
Peter
Powered by blists - more mailing lists