dmaengine.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [-next] dmaengine: stm32-dmamux: Remove unnecessary platform_get_resource() error check
@ 2018-01-17 11:27 weiyongjun (A)
  0 siblings, 0 replies; 3+ messages in thread
From: weiyongjun (A) @ 2018-01-17 11:27 UTC (permalink / raw)
  To: Vinod Koul, Dan Williams, Maxime Coquelin, Alexandre Torgue
  Cc: Wei Yongjun, dmaengine, linux-arm-kernel

devm_ioremap_resource() already checks if the resource is NULL, so
remove the unnecessary platform_get_resource() error check.

Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
 drivers/dma/stm32-dmamux.c | 3 ---
 1 file changed, 3 deletions(-)


--
To unsubscribe from this list: send the line "unsubscribe dmaengine" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

diff --git a/drivers/dma/stm32-dmamux.c b/drivers/dma/stm32-dmamux.c
index d5db0f6..4dbb30c 100644
--- a/drivers/dma/stm32-dmamux.c
+++ b/drivers/dma/stm32-dmamux.c
@@ -253,9 +253,6 @@ static int stm32_dmamux_probe(struct platform_device *pdev)
 	}
 
 	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	if (!res)
-		return -ENODEV;
-
 	iomem = devm_ioremap_resource(&pdev->dev, res);
 	if (IS_ERR(iomem))
 		return PTR_ERR(iomem);

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

* [-next] dmaengine: stm32-dmamux: Remove unnecessary platform_get_resource() error check
@ 2018-01-18 14:42 Pierre Yves MORDRET
  0 siblings, 0 replies; 3+ messages in thread
From: Pierre Yves MORDRET @ 2018-01-18 14:42 UTC (permalink / raw)
  To: Wei Yongjun, Vinod Koul, Dan Williams, Maxime Coquelin,
	Alexandre Torgue
  Cc: dmaengine, linux-arm-kernel

Acked-by: Pierre-Yves MORDRET <pierre-yves.mordret@st.com>

On 01/17/2018 12:27 PM, Wei Yongjun wrote:
> devm_ioremap_resource() already checks if the resource is NULL, so
> remove the unnecessary platform_get_resource() error check.
> 
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
>  drivers/dma/stm32-dmamux.c | 3 ---
>  1 file changed, 3 deletions(-)
> 
> diff --git a/drivers/dma/stm32-dmamux.c b/drivers/dma/stm32-dmamux.c
> index d5db0f6..4dbb30c 100644
> --- a/drivers/dma/stm32-dmamux.c
> +++ b/drivers/dma/stm32-dmamux.c
> @@ -253,9 +253,6 @@ static int stm32_dmamux_probe(struct platform_device *pdev)
>  	}
>  
>  	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	if (!res)
> -		return -ENODEV;
> -
>  	iomem = devm_ioremap_resource(&pdev->dev, res);
>  	if (IS_ERR(iomem))
>  		return PTR_ERR(iomem);
> 
> --
> To unsubscribe from this list: send the line "unsubscribe dmaengine" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
---
To unsubscribe from this list: send the line "unsubscribe dmaengine" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* [-next] dmaengine: stm32-dmamux: Remove unnecessary platform_get_resource() error check
@ 2018-01-19  5:38 Vinod Koul
  0 siblings, 0 replies; 3+ messages in thread
From: Vinod Koul @ 2018-01-19  5:38 UTC (permalink / raw)
  To: Wei Yongjun
  Cc: Dan Williams, Maxime Coquelin, Alexandre Torgue, dmaengine,
	linux-arm-kernel

On Wed, Jan 17, 2018 at 11:27:10AM +0000, Wei Yongjun wrote:
> devm_ioremap_resource() already checks if the resource is NULL, so
> remove the unnecessary platform_get_resource() error check.

Applied, thanks

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

end of thread, other threads:[~2018-01-19  5:38 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-01-19  5:38 [-next] dmaengine: stm32-dmamux: Remove unnecessary platform_get_resource() error check Vinod Koul
  -- strict thread matches above, loose matches on Subject: below --
2018-01-18 14:42 Pierre Yves MORDRET
2018-01-17 11:27 weiyongjun (A)

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).