All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next v2] dmaengine: ti: k3-udma: use devm_platform_ioremap_resource_byname
@ 2020-09-21  9:37 Qilong Zhang
  2020-10-05  4:43 ` Vinod Koul
  0 siblings, 1 reply; 2+ messages in thread
From: Qilong Zhang @ 2020-09-21  9:37 UTC (permalink / raw)
  To: vkoul, dan.j.williams, peter.ujfalusi; +Cc: dmaengine

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.

Signed-off-by: Zhang Qilong <zhangqilong3@huawei.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
---
 drivers/dma/ti/k3-udma.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/dma/ti/k3-udma.c b/drivers/dma/ti/k3-udma.c
index de7bfc02a2de..bb4bdd90a745 100644
--- a/drivers/dma/ti/k3-udma.c
+++ b/drivers/dma/ti/k3-udma.c
@@ -3157,13 +3157,10 @@ 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]);
 	}
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH -next v2] dmaengine: ti: k3-udma: use devm_platform_ioremap_resource_byname
  2020-09-21  9:37 [PATCH -next v2] dmaengine: ti: k3-udma: use devm_platform_ioremap_resource_byname Qilong Zhang
@ 2020-10-05  4:43 ` Vinod Koul
  0 siblings, 0 replies; 2+ messages in thread
From: Vinod Koul @ 2020-10-05  4:43 UTC (permalink / raw)
  To: Qilong Zhang; +Cc: dan.j.williams, peter.ujfalusi, dmaengine

On 21-09-20, 17:37, 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.

Applied, thanks

-- 
~Vinod

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-10-05  4:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-21  9:37 [PATCH -next v2] dmaengine: ti: k3-udma: use devm_platform_ioremap_resource_byname Qilong Zhang
2020-10-05  4:43 ` Vinod Koul

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.