All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bumyong Lee <bumyong.lee@samsung.com>
To: vkoul@kernel.org, p.zabel@pengutronix.de
Cc: dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org,
	Bumyong Lee <bumyong.lee@samsung.com>
Subject: [PATCH] dmaengine: pl330: issue_pending waits until WFP state
Date: Tue, 19 Dec 2023 14:50:26 +0900	[thread overview]
Message-ID: <20231219055026.118695-1-bumyong.lee@samsung.com> (raw)
In-Reply-To: CGME20231219055052epcas2p4bb1d8210f650ab18370711db2194e8e3@epcas2p4.samsung.com

According to DMA-330 errata notice[1] 71930, DMAKILL
cannot clear internal signal, named pipeline_req_active.
it makes that pl330 would wait forever in WFP state
although dma already send dma request if pl330 gets
dma request before entering WFP state.

The errata suggests that polling until entering WFP state
as workaround and then peripherals allows to issue dma request.

[1]: https://developer.arm.com/documentation/genc008428/latest
Signed-off-by: Bumyong Lee <bumyong.lee@samsung.com>
---
 drivers/dma/pl330.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
index 3cf0b38387ae..c29744bfdf2c 100644
--- a/drivers/dma/pl330.c
+++ b/drivers/dma/pl330.c
@@ -1053,6 +1053,9 @@ static bool _trigger(struct pl330_thread *thrd)
 
 	thrd->req_running = idx;
 
+	if (desc->rqtype == DMA_MEM_TO_DEV || desc->rqtype == DMA_DEV_TO_MEM)
+		UNTIL(thrd, PL330_STATE_WFP);
+
 	return true;
 }
 
-- 
2.43.0


       reply	other threads:[~2023-12-19  5:50 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20231219055052epcas2p4bb1d8210f650ab18370711db2194e8e3@epcas2p4.samsung.com>
2023-12-19  5:50 ` Bumyong Lee [this message]
2023-12-21 16:30   ` [PATCH] dmaengine: pl330: issue_pending waits until WFP state Vinod Koul
2023-12-24 15:40     ` Chen-Yu Tsai
2023-12-27  2:09       ` bumyong.lee
2024-01-08 16:51         ` Chen-Yu Tsai
2024-01-09  1:18           ` bumyong.lee

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=20231219055026.118695-1-bumyong.lee@samsung.com \
    --to=bumyong.lee@samsung.com \
    --cc=dmaengine@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=p.zabel@pengutronix.de \
    --cc=vkoul@kernel.org \
    /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.