dmaengine Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] DMA: PL330: Remove unreachable code
       [not found] <CGME20201013122030epcas5p2e576d5a2ebfaf9df8078e6ee70f3765c@epcas5p2.samsung.com>
@ 2020-10-13 11:47 ` Surendran K
  2020-10-14  4:39   ` Vinod Koul
  0 siblings, 1 reply; 3+ messages in thread
From: Surendran K @ 2020-10-13 11:47 UTC (permalink / raw)
  To: dmaengine, linux-kernel
  Cc: vkoul, shaik.ameer, alim.akhtar, pankaj.dubey, Surendran K

_setup_req(..) never returns negative value.
Hence the condition ret < 0 is never met

Signed-off-by: Surendran K <surendran.k@samsung.com>
---
 drivers/dma/pl330.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
index e9f0101d92fa..8355586c9788 100644
--- a/drivers/dma/pl330.c
+++ b/drivers/dma/pl330.c
@@ -1527,8 +1527,6 @@ static int pl330_submit_req(struct pl330_thread *thrd,
 
 	/* First dry run to check if req is acceptable */
 	ret = _setup_req(pl330, 1, thrd, idx, &xs);
-	if (ret < 0)
-		goto xfer_exit;
 
 	if (ret > pl330->mcbufsz / 2) {
 		dev_info(pl330->ddma.dev, "%s:%d Try increasing mcbufsz (%i/%i)\n",
-- 
2.17.1


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

* Re: [PATCH] DMA: PL330: Remove unreachable code
  2020-10-13 11:47 ` [PATCH] DMA: PL330: Remove unreachable code Surendran K
@ 2020-10-14  4:39   ` Vinod Koul
  2020-10-16 10:30     ` Surendran K
  0 siblings, 1 reply; 3+ messages in thread
From: Vinod Koul @ 2020-10-14  4:39 UTC (permalink / raw)
  To: Surendran K
  Cc: dmaengine, linux-kernel, shaik.ameer, alim.akhtar, pankaj.dubey

On 13-10-20, 17:17, Surendran K wrote:
> _setup_req(..) never returns negative value.
> Hence the condition ret < 0 is never met

The subsystem is "dmaengine", git log would tell you the tags to use


> 
> Signed-off-by: Surendran K <surendran.k@samsung.com>
> ---
>  drivers/dma/pl330.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
> index e9f0101d92fa..8355586c9788 100644
> --- a/drivers/dma/pl330.c
> +++ b/drivers/dma/pl330.c
> @@ -1527,8 +1527,6 @@ static int pl330_submit_req(struct pl330_thread *thrd,
>  
>  	/* First dry run to check if req is acceptable */
>  	ret = _setup_req(pl330, 1, thrd, idx, &xs);
> -	if (ret < 0)
> -		goto xfer_exit;
>  
>  	if (ret > pl330->mcbufsz / 2) {
>  		dev_info(pl330->ddma.dev, "%s:%d Try increasing mcbufsz (%i/%i)\n",
> -- 
> 2.17.1

-- 
~Vinod

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

* RE: [PATCH] DMA: PL330: Remove unreachable code
  2020-10-14  4:39   ` Vinod Koul
@ 2020-10-16 10:30     ` Surendran K
  0 siblings, 0 replies; 3+ messages in thread
From: Surendran K @ 2020-10-16 10:30 UTC (permalink / raw)
  To: 'Vinod Koul'
  Cc: dmaengine, linux-kernel, shaik.ameer, alim.akhtar, pankaj.dubey

Hi Vinod,
Thanks for pointing it out, I missed it. Will send V2 with correction.

Regards,
Surendran.

-----Original Message-----
From: Vinod Koul [mailto:vkoul@kernel.org] 
Sent: Tuesday, October 13, 2020 9:40 PM
To: Surendran K <surendran.k@samsung.com>
Cc: dmaengine@vger.kernel.org; linux-kernel@vger.kernel.org;
shaik.ameer@samsung.com; alim.akhtar@samsung.com; pankaj.dubey@samsung.com
Subject: Re: [PATCH] DMA: PL330: Remove unreachable code

On 13-10-20, 17:17, Surendran K wrote:
> _setup_req(..) never returns negative value.
> Hence the condition ret < 0 is never met

The subsystem is "dmaengine", git log would tell you the tags to use


> 
> Signed-off-by: Surendran K <surendran.k@samsung.com>
> ---
>  drivers/dma/pl330.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c index 
> e9f0101d92fa..8355586c9788 100644
> --- a/drivers/dma/pl330.c
> +++ b/drivers/dma/pl330.c
> @@ -1527,8 +1527,6 @@ static int pl330_submit_req(struct pl330_thread 
> *thrd,
>  
>  	/* First dry run to check if req is acceptable */
>  	ret = _setup_req(pl330, 1, thrd, idx, &xs);
> -	if (ret < 0)
> -		goto xfer_exit;
>  
>  	if (ret > pl330->mcbufsz / 2) {
>  		dev_info(pl330->ddma.dev, "%s:%d Try increasing mcbufsz
(%i/%i)\n",
> --
> 2.17.1

--
~Vinod


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

end of thread, back to index

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CGME20201013122030epcas5p2e576d5a2ebfaf9df8078e6ee70f3765c@epcas5p2.samsung.com>
2020-10-13 11:47 ` [PATCH] DMA: PL330: Remove unreachable code Surendran K
2020-10-14  4:39   ` Vinod Koul
2020-10-16 10:30     ` Surendran K

dmaengine Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/dmaengine/0 dmaengine/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dmaengine dmaengine/ https://lore.kernel.org/dmaengine \
		dmaengine@vger.kernel.org
	public-inbox-index dmaengine

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.dmaengine


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git