All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Ujfalusi <peter.ujfalusi@ti.com>
To: <qiwuchen55@gmail.com>, <vkoul@kernel.org>,
	<dan.j.williams@intel.com>, <allison@lohutok.net>,
	<kstewart@linuxfoundation.org>
Cc: <tglx@linutronix.de>, <wenwen@cs.uga.edu>,
	<dmaengine@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
	chenqiwu <chenqiwu@xiaomi.com>
Subject: Re: [PATCH] dma: ti: dma-crossbar: convert to devm_platform_ioremap_resource()
Date: Tue, 28 Jan 2020 09:53:42 +0200	[thread overview]
Message-ID: <2d85b488-6cc1-f062-c926-b17d1165bde1@ti.com> (raw)
In-Reply-To: <1580189746-2864-1-git-send-email-qiwuchen55@gmail.com>



On 28/01/2020 7.35, qiwuchen55@gmail.com wrote:
> From: chenqiwu <chenqiwu@xiaomi.com>
> 
> Use a new API devm_platform_ioremap_resource() to simplify code.

Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>

> Signed-off-by: chenqiwu <chenqiwu@xiaomi.com>
> ---
>  drivers/dma/ti/dma-crossbar.c | 8 ++------
>  1 file changed, 2 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/dma/ti/dma-crossbar.c b/drivers/dma/ti/dma-crossbar.c
> index f255056..4ba8fa5 100644
> --- a/drivers/dma/ti/dma-crossbar.c
> +++ b/drivers/dma/ti/dma-crossbar.c
> @@ -133,7 +133,6 @@ static int ti_am335x_xbar_probe(struct platform_device *pdev)
>  	const struct of_device_id *match;
>  	struct device_node *dma_node;
>  	struct ti_am335x_xbar_data *xbar;
> -	struct resource *res;
>  	void __iomem *iomem;
>  	int i, ret;
>  
> @@ -173,8 +172,7 @@ static int ti_am335x_xbar_probe(struct platform_device *pdev)
>  		xbar->xbar_events = TI_AM335X_XBAR_LINES;
>  	}
>  
> -	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	iomem = devm_ioremap_resource(&pdev->dev, res);
> +	iomem = devm_platform_ioremap_resource(pdev, 0);
>  	if (IS_ERR(iomem))
>  		return PTR_ERR(iomem);
>  
> @@ -323,7 +321,6 @@ static int ti_dra7_xbar_probe(struct platform_device *pdev)
>  	struct device_node *dma_node;
>  	struct ti_dra7_xbar_data *xbar;
>  	struct property *prop;
> -	struct resource *res;
>  	u32 safe_val;
>  	int sz;
>  	void __iomem *iomem;
> @@ -403,8 +400,7 @@ static int ti_dra7_xbar_probe(struct platform_device *pdev)
>  		kfree(rsv_events);
>  	}
>  
> -	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	iomem = devm_ioremap_resource(&pdev->dev, res);
> +	iomem = devm_platform_ioremap_resource(pdev, 0);
>  	if (IS_ERR(iomem))
>  		return PTR_ERR(iomem);
>  
> 

- Péter

Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki.
Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki

  reply	other threads:[~2020-01-28  7:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-28  5:35 [PATCH] dma: ti: dma-crossbar: convert to devm_platform_ioremap_resource() qiwuchen55
2020-01-28  7:53 ` Peter Ujfalusi [this message]
2020-02-13 15:19 ` 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=2d85b488-6cc1-f062-c926-b17d1165bde1@ti.com \
    --to=peter.ujfalusi@ti.com \
    --cc=allison@lohutok.net \
    --cc=chenqiwu@xiaomi.com \
    --cc=dan.j.williams@intel.com \
    --cc=dmaengine@vger.kernel.org \
    --cc=kstewart@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=qiwuchen55@gmail.com \
    --cc=tglx@linutronix.de \
    --cc=vkoul@kernel.org \
    --cc=wenwen@cs.uga.edu \
    /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 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.