From: Minas Harutyunyan <Minas.Harutyunyan@synopsys.com>
To: Dejin Zheng <zhengdejin5@gmail.com>,
"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
"rafael@kernel.org" <rafael@kernel.org>,
"mathias.nyman@intel.com" <mathias.nyman@intel.com>,
"bgolaszewski@baylibre.com" <bgolaszewski@baylibre.com>,
"arnd@arndb.de" <arnd@arndb.de>,
"jeffrey.t.kirsher@intel.com" <jeffrey.t.kirsher@intel.com>,
"hdegoede@redhat.com" <hdegoede@redhat.com>,
"treding@nvidia.com" <treding@nvidia.com>,
"tglx@linutronix.de" <tglx@linutronix.de>,
"tomas.winkler@intel.com" <tomas.winkler@intel.com>,
"suzuki.poulose@arm.com" <suzuki.poulose@arm.com>,
"sergei.shtylyov@cogentembedded.com"
<sergei.shtylyov@cogentembedded.com>,
"geert@linux-m68k.org" <geert@linux-m68k.org>,
"linux-usb@vger.kernel.org" <linux-usb@vger.kernel.org>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v3 4/5] usb: dwc2: convert to devm_platform_get_and_ioremap_resource
Date: Wed, 18 Mar 2020 10:40:17 +0000 [thread overview]
Message-ID: <f39917e0-2ee1-076c-c199-3e728ab063d2@synopsys.com> (raw)
In-Reply-To: <20200315140525.21780-5-zhengdejin5@gmail.com>
On 3/15/2020 6:05 PM, Dejin Zheng wrote:
> Use devm_platform_get_and_ioremap_resource() to simplify code, which
> contains platform_get_resource() and devm_ioremap_resource(), it also
> get the resource for use by the following code.
>
> Signed-off-by: Dejin Zheng <zhengdejin5@gmail.com>
Acked-by: Minas Harutyunyan <hminas@synopsys.com>
> ---
> v2 -> v3:
> - call the rename function devm_platform_get_and_ioremap_resource()
>
> v1 -> v2:
> - add this patch for add some real users of this function.
>
> drivers/usb/dwc2/platform.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/usb/dwc2/platform.c b/drivers/usb/dwc2/platform.c
> index 3c6ce09a6db5..8a68e89749d2 100644
> --- a/drivers/usb/dwc2/platform.c
> +++ b/drivers/usb/dwc2/platform.c
> @@ -392,8 +392,7 @@ static int dwc2_driver_probe(struct platform_device *dev)
> return retval;
> }
>
> - res = platform_get_resource(dev, IORESOURCE_MEM, 0);
> - hsotg->regs = devm_ioremap_resource(&dev->dev, res);
> + hsotg->regs = devm_platform_get_and_ioremap_resource(dev, 0, &res);
> if (IS_ERR(hsotg->regs))
> return PTR_ERR(hsotg->regs);
>
>
next prev parent reply other threads:[~2020-03-18 10:40 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-15 14:05 [PATCH v3 0/5] drivers: new helper for ioremapping memory resources Dejin Zheng
2020-03-15 14:05 ` [PATCH v3 1/5] drivers: provide devm_platform_get_and_ioremap_resource() Dejin Zheng
2020-03-17 19:20 ` Greg KH
2020-03-17 19:35 ` Geert Uytterhoeven
2020-03-18 10:10 ` Greg KH
2020-03-20 14:06 ` Dejin Zheng
2020-03-23 12:44 ` Geert Uytterhoeven
2020-03-15 14:05 ` [PATCH v3 2/5] usb: host: xhci-plat: convert to devm_platform_get_and_ioremap_resource Dejin Zheng
2020-03-18 11:33 ` Mathias Nyman
2020-03-23 12:45 ` Geert Uytterhoeven
2020-03-15 14:05 ` [PATCH v3 3/5] usb: host: hisilicon: " Dejin Zheng
2020-03-18 11:35 ` Mathias Nyman
2020-03-23 12:45 ` Geert Uytterhoeven
2020-03-15 14:05 ` [PATCH v3 4/5] usb: dwc2: " Dejin Zheng
2020-03-18 10:40 ` Minas Harutyunyan [this message]
2020-03-23 12:47 ` Geert Uytterhoeven
2020-03-15 14:05 ` [PATCH v3 5/5] driver core: platform: Reimplement devm_platform_ioremap_resource Dejin Zheng
2020-03-23 12:47 ` Geert Uytterhoeven
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=f39917e0-2ee1-076c-c199-3e728ab063d2@synopsys.com \
--to=minas.harutyunyan@synopsys.com \
--cc=arnd@arndb.de \
--cc=bgolaszewski@baylibre.com \
--cc=geert@linux-m68k.org \
--cc=gregkh@linuxfoundation.org \
--cc=hdegoede@redhat.com \
--cc=jeffrey.t.kirsher@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=mathias.nyman@intel.com \
--cc=rafael@kernel.org \
--cc=sergei.shtylyov@cogentembedded.com \
--cc=suzuki.poulose@arm.com \
--cc=tglx@linutronix.de \
--cc=tomas.winkler@intel.com \
--cc=treding@nvidia.com \
--cc=zhengdejin5@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®