lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20191009074641.taocxbrs2vodvsgm@M43218.corp.atmel.com>
Date:   Wed, 9 Oct 2019 09:46:42 +0200
From:   Ludovic Desroches <ludovic.desroches@...rochip.com>
To:     Markus Elfring <Markus.Elfring@....de>
CC:     <dmaengine@...r.kernel.org>,
        <linux-arm-kernel@...ts.infradead.org>,
        "Dan Williams" <dan.j.williams@...el.com>,
        Vinod Koul <vkoul@...nel.org>,
        LKML <linux-kernel@...r.kernel.org>,
        <kernel-janitors@...r.kernel.org>,
        "Nicolas Ferre" <nicolas.ferre@...el.com>
Subject: Re: [PATCH] dmaengine: at_xdmac: Use
 devm_platform_ioremap_resource() in at_xdmac_probe()

On Sun, Sep 22, 2019 at 10:48:20AM +0200, Markus Elfring wrote:
> 
> From: Markus Elfring <elfring@...rs.sourceforge.net>
> Date: Sun, 22 Sep 2019 10:37:31 +0200
> 
> Simplify this function implementation by using a known wrapper function.
> 
> This issue was detected by using the Coccinelle software.
> 
> Signed-off-by: Markus Elfring <elfring@...rs.sourceforge.net>
Acked-by: Ludovic Desroches <ludovic.desroches@...rochip.com> 

Thanks

> ---
>  drivers/dma/at_xdmac.c | 7 +------
>  1 file changed, 1 insertion(+), 6 deletions(-)
> 
> diff --git a/drivers/dma/at_xdmac.c b/drivers/dma/at_xdmac.c
> index b58ac720d9a1..f71c9f77d405 100644
> --- a/drivers/dma/at_xdmac.c
> +++ b/drivers/dma/at_xdmac.c
> @@ -1957,21 +1957,16 @@ static int atmel_xdmac_resume(struct device *dev)
> 
>  static int at_xdmac_probe(struct platform_device *pdev)
>  {
> -	struct resource	*res;
>  	struct at_xdmac	*atxdmac;
>  	int		irq, size, nr_channels, i, ret;
>  	void __iomem	*base;
>  	u32		reg;
> 
> -	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	if (!res)
> -		return -EINVAL;
> -
>  	irq = platform_get_irq(pdev, 0);
>  	if (irq < 0)
>  		return irq;
> 
> -	base = devm_ioremap_resource(&pdev->dev, res);
> +	base = devm_platform_ioremap_resource(pdev, 0);
>  	if (IS_ERR(base))
>  		return PTR_ERR(base);
> 
> --
> 2.23.0
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ