From: Peter Ujfalusi <peter.ujfalusi@ti.com>
To: Qilong Zhang <zhangqilong3@huawei.com>, <vkoul@kernel.org>,
<dan.j.williams@intel.com>
Cc: <dmaengine@vger.kernel.org>
Subject: Re: [PATCH -next] dmaengine: ti: k3-udma: use devm_platform_ioremap_resource_byname
Date: Thu, 17 Sep 2020 12:41:36 +0300 [thread overview]
Message-ID: <b43833ec-0d2b-8bed-cde4-432a03232432@ti.com> (raw)
In-Reply-To: <20200917074457.52748-1-zhangqilong3@huawei.com>
On 17/09/2020 10.44, Qilong Zhang wrote:
> From: Zhang Qilong <zhangqilong3@huawei.com>
>
> Use the devm_platform_ioremap_resource_byname() helper instead of
> calling platform_get_resource_byname() and devm_ioremap_resource()
> separately.
Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
> Signed-off-by: Zhang Qilong <zhangqilong3@huawei.com>
> ---
> drivers/dma/ti/k3-udma.c | 6 ++----
> 1 file changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/dma/ti/k3-udma.c b/drivers/dma/ti/k3-udma.c
> index de7bfc02a2de..eb29fdc9ffc1 100644
> --- a/drivers/dma/ti/k3-udma.c
> +++ b/drivers/dma/ti/k3-udma.c
> @@ -3157,13 +3157,11 @@ static const struct soc_device_attribute k3_soc_devices[] = {
>
> static int udma_get_mmrs(struct platform_device *pdev, struct udma_dev *ud)
> {
> - struct resource *res;
> int i;
>
> for (i = 0; i < MMR_LAST; i++) {
> - res = platform_get_resource_byname(pdev, IORESOURCE_MEM,
> - mmr_names[i]);
> - ud->mmrs[i] = devm_ioremap_resource(&pdev->dev, res);
> + ud->mmrs[i] = devm_platform_ioremap_resource_byname(pdev,
> + mmr_names[i]);
> if (IS_ERR(ud->mmrs[i]))
> return PTR_ERR(ud->mmrs[i]);
> }
>
- Péter
Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki.
Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki
next prev parent reply other threads:[~2020-09-17 10:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-17 7:44 [PATCH -next] dmaengine: ti: k3-udma: use devm_platform_ioremap_resource_byname Qilong Zhang
2020-09-17 9:41 ` Peter Ujfalusi [this message]
2020-09-17 11:21 ` Vinod Koul
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=b43833ec-0d2b-8bed-cde4-432a03232432@ti.com \
--to=peter.ujfalusi@ti.com \
--cc=dan.j.williams@intel.com \
--cc=dmaengine@vger.kernel.org \
--cc=vkoul@kernel.org \
--cc=zhangqilong3@huawei.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