From: "Folker Schwesinger" <dev@folker-schwesinger.de>
To: "Suraj Gupta" <suraj.gupta2@amd.com>, <vkoul@kernel.org>,
<radhey.shyam.pandey@amd.com>, <michal.simek@amd.com>
Cc: <dmaengine@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>,
<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 1/3] dmaengine: xilinx_dma: Fix channel idle state management in interrupt handler
Date: Thu, 18 Sep 2025 07:32:04 +0000 [thread overview]
Message-ID: <DCVR1UNIOUUU.2VF0ODU86VKI2@folker-schwesinger.de> (raw)
In-Reply-To: <20250917133609.231316-2-suraj.gupta2@amd.com>
On Wed Sep 17, 2025 at 3:36 PM CEST, Suraj Gupta wrote:
> Only mark the channel as idle and start new transfers when the active list
> is actually empty, ensuring proper channel state management and avoiding
> spurious transfer attempts.
>
> Signed-off-by: Suraj Gupta <suraj.gupta2@amd.com>
> Fixes: c0bba3a99f07 ("dmaengine: vdma: Add Support for Xilinx AXI Direct Memory Access Engine")
Tested-by: Folker Schwesinger <dev@folker-schwesinger.de>
> ---
> drivers/dma/xilinx/xilinx_dma.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/dma/xilinx/xilinx_dma.c b/drivers/dma/xilinx/xilinx_dma.c
> index a34d8f0ceed8..9f416eae33d0 100644
> --- a/drivers/dma/xilinx/xilinx_dma.c
> +++ b/drivers/dma/xilinx/xilinx_dma.c
> @@ -1914,8 +1914,10 @@ static irqreturn_t xilinx_dma_irq_handler(int irq, void *data)
> XILINX_DMA_DMASR_DLY_CNT_IRQ)) {
> spin_lock(&chan->lock);
> xilinx_dma_complete_descriptor(chan);
> - chan->idle = true;
> - chan->start_transfer(chan);
> + if (list_empty(&chan->active_list)) {
> + chan->idle = true;
> + chan->start_transfer(chan);
> + }
> spin_unlock(&chan->lock);
> }
>
next prev parent reply other threads:[~2025-09-18 7:46 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-17 13:36 [PATCH 0/3] dmaengine: xilinx_dma: Fixes and optimizations for channel management Suraj Gupta
2025-09-17 13:36 ` [PATCH 1/3] dmaengine: xilinx_dma: Fix channel idle state management in interrupt handler Suraj Gupta
2025-09-18 7:32 ` Folker Schwesinger [this message]
2025-09-18 7:36 ` Folker Schwesinger
2025-09-29 5:36 ` Pandey, Radhey Shyam
2025-09-17 13:36 ` [PATCH 2/3] dmaengine: xilinx_dma: Enable transfer chaining by removing idle restriction Suraj Gupta
2025-09-18 7:33 ` Folker Schwesinger
2025-09-29 5:44 ` Pandey, Radhey Shyam
2025-09-17 13:36 ` [PATCH 3/3] dmaengine: xilinx_dma: Optimize control register write and channel start logic in xilinx_dma_start_transfer Suraj Gupta
2025-09-18 7:34 ` Folker Schwesinger
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=DCVR1UNIOUUU.2VF0ODU86VKI2@folker-schwesinger.de \
--to=dev@folker-schwesinger.de \
--cc=dmaengine@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.simek@amd.com \
--cc=radhey.shyam.pandey@amd.com \
--cc=suraj.gupta2@amd.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox