[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <D02V8R59Y6I3.13XIQDA5L6QCK@gmail.com>
Date: Mon, 25 Mar 2024 14:30:10 +0100
From: "Thierry Reding" <thierry.reding@...il.com>
To: "Akhil R" <akhilrajeev@...dia.com>, <ldewangan@...dia.com>,
<jonathanh@...dia.com>, <vkoul@...nel.org>, <dmaengine@...r.kernel.org>,
<linux-tegra@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2 RESEND] dmaengine: tegra186: Fix residual calculation
On Fri Mar 15, 2024 at 1:44 PM CET, Akhil R wrote:
> The existing residual calculation returns an incorrect value when
> bytes_xfer == bytes_req. This scenario occurs particularly with drivers
> like UART where DMA is scheduled for maximum number of bytes and is
> terminated when the bytes inflow stops. At higher baud rates, it could
> request the tx_status while there is no bytes left to transfer. This will
> lead to incorrect residual being set. Hence return residual as '0' when
> bytes transferred equals to the bytes requested.
>
> Fixes: ee17028009d4 ("dmaengine: tegra: Add tegra gpcdma driver")
> Signed-off-by: Akhil R <akhilrajeev@...dia.com>
> Reviewed-by: Jon Hunter <jonathanh@...dia.com>
> ---
> v1->v2:
> * corrected typo - s/exisiting/existing/
>
> drivers/dma/tegra186-gpc-dma.c | 3 +++
> 1 file changed, 3 insertions(+)
Acked-by: Thierry Reding <treding@...dia.com>
Download attachment "signature.asc" of type "application/pgp-signature" (834 bytes)
Powered by blists - more mailing lists