[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20240815085725.2740390-3-quic_mdalam@quicinc.com>
Date: Thu, 15 Aug 2024 14:27:11 +0530
From: Md Sadre Alam <quic_mdalam@...cinc.com>
To: vkoul@...nel.org, robh@...nel.org, krzk+dt@...nel.org, conor+dt@...nel.org,
andersson@...nel.org, konradybcio@...nel.org, thara.gopinath@...il.com,
herbert@...dor.apana.org.au, davem@...emloft.net,
gustavoars@...nel.org, u.kleine-koenig@...gutronix.de, kees@...nel.org,
agross@...nel.org, linux-arm-msm@...r.kernel.org,
dmaengine@...r.kernel.org, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-crypto@...r.kernel.org
Cc: quic_srichara@...cinc.com, quic_varada@...cinc.com,
quic_mdalam@...cinc.com, quic_utiwari@...cinc.com
Subject: [PATCH v2 02/16] dmaengine: qcom: bam_dma: add bam_pipe_lock dt property
bam having locking and unlocking mechanism of bam pipes.
Upon encountering a descriptor with Lock bit set, the
BAM will lock all other pipes not related to the current
pipe group, and keep handling the current pipe only until
it sees the Un-Lock set , then it will release all locked
pipes. The actual locking is done on the new descriptor
fetching for publishing, i.e. locked pipe will not fetch
new descriptors even if it got event/events adding more
descriptors for this pipe.
Adding the bam_pipe_lock flag in bam driver to handle
Lock and Un-Lock bit set on command descriptor.
Signed-off-by: Md Sadre Alam <quic_mdalam@...cinc.com>
---
Change in [v2]
* Added bam_pipe_lock dt property
Change in [v1]
* This patch was not included in [v1]
drivers/dma/qcom/bam_dma.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/dma/qcom/bam_dma.c b/drivers/dma/qcom/bam_dma.c
index 5e7d332731e0..1ac7e250bdaa 100644
--- a/drivers/dma/qcom/bam_dma.c
+++ b/drivers/dma/qcom/bam_dma.c
@@ -389,6 +389,7 @@ struct bam_device {
u32 ee;
bool controlled_remotely;
bool powered_remotely;
+ bool bam_pipe_lock;
u32 active_channels;
const struct reg_offset_data *layout;
@@ -1272,6 +1273,9 @@ static int bam_dma_probe(struct platform_device *pdev)
bdev->powered_remotely = of_property_read_bool(pdev->dev.of_node,
"qcom,powered-remotely");
+ bdev->bam_pipe_lock = of_property_read_bool(pdev->dev.of_node,
+ "qcom,bam_pipe_lock");
+
if (bdev->controlled_remotely || bdev->powered_remotely)
bdev->bamclk = devm_clk_get_optional(bdev->dev, "bam_clk");
else
--
2.34.1
Powered by blists - more mailing lists