dmaengine.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
To: vinod.koul@intel.com
Cc: dmaengine@vger.kernel.org, linux-renesas-soc@vger.kernel.org,
	Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Subject: [PATCH v3 3/4] dmaengine: rcar-dmac: Use devm_platform_ioremap_resource()
Date: Mon,  9 Sep 2019 15:34:51 +0900	[thread overview]
Message-ID: <1568010892-17606-4-git-send-email-yoshihiro.shimoda.uh@renesas.com> (raw)
In-Reply-To: <1568010892-17606-1-git-send-email-yoshihiro.shimoda.uh@renesas.com>

This patch uses devm_platform_ioremap_resource() instead of
using platform_get_resource() and devm_ioremap_resource() together
to simplify.

Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 drivers/dma/sh/rcar-dmac.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/dma/sh/rcar-dmac.c b/drivers/dma/sh/rcar-dmac.c
index 74996a0..542786d 100644
--- a/drivers/dma/sh/rcar-dmac.c
+++ b/drivers/dma/sh/rcar-dmac.c
@@ -1824,7 +1824,6 @@ static int rcar_dmac_probe(struct platform_device *pdev)
 	struct dma_device *engine;
 	struct rcar_dmac *dmac;
 	const struct rcar_dmac_of_data *data;
-	struct resource *mem;
 	unsigned int i;
 	int ret;
 
@@ -1863,8 +1862,7 @@ static int rcar_dmac_probe(struct platform_device *pdev)
 		return -ENOMEM;
 
 	/* Request resources. */
-	mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	dmac->iomem = devm_ioremap_resource(&pdev->dev, mem);
+	dmac->iomem = devm_platform_ioremap_resource(pdev, 0);
 	if (IS_ERR(dmac->iomem))
 		return PTR_ERR(dmac->iomem);
 
-- 
2.7.4


  parent reply	other threads:[~2019-09-09  6:35 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-09  6:34 [PATCH v3 0/4] dmaengine: rcar-dmac: use of_data and add dma-channel-mask support Yoshihiro Shimoda
2019-09-09  6:34 ` [PATCH v3 1/4] dmaengine: rcar-dmac: Fix DMACHCLR handling if iommu is mapped Yoshihiro Shimoda
2019-09-09  6:34 ` [PATCH v3 2/4] dmaengine: rcar-dmac: Use of_data values instead of a macro Yoshihiro Shimoda
2019-09-13  8:48   ` Simon Horman
2019-09-09  6:34 ` Yoshihiro Shimoda [this message]
2019-09-13  8:46   ` [PATCH v3 3/4] dmaengine: rcar-dmac: Use devm_platform_ioremap_resource() Simon Horman
2019-09-09  6:34 ` [PATCH v3 4/4] dmaengine: rcar-dmac: Add dma-channel-mask property support Yoshihiro Shimoda
2019-10-14  6:58 ` [PATCH v3 0/4] dmaengine: rcar-dmac: use of_data and add dma-channel-mask support 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=1568010892-17606-4-git-send-email-yoshihiro.shimoda.uh@renesas.com \
    --to=yoshihiro.shimoda.uh@renesas.com \
    --cc=dmaengine@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=vinod.koul@intel.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;
as well as URLs for NNTP newsgroup(s).