[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160311074328.GU11154@localhost>
Date: Fri, 11 Mar 2016 13:13:28 +0530
From: Vinod Koul <vinod.koul@...el.com>
To: "Jon Medhurst (Tixy)" <tixy@...aro.org>
Cc: Robert Baldyga <r.baldyga@...sung.com>,
Lukasz Czerwinski <l.czerwinski@...sung.com>,
Dan Williams <dan.j.williams@...el.com>,
Jaswinder Singh <jassisinghbrar@...il.com>,
dmaengine@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org
Subject: Re: [PATCH] dmaengine: pl330: Fix some race conditions in residue
calculation
On Tue, Mar 08, 2016 at 03:50:41PM +0000, Jon Medhurst (Tixy) wrote:
> > The reside is requested for "a descriptor". For example if you have prepared
> > two descriptors A and B and submitted them, then you can request status and
> > reside for A and you need to calculate that for A only and not take into
> > account status of B
>
> But, in the case of the pl330 driver, A and B may each consist of
> multiple internal/hidden descriptors. So the residue calculation has to
> sum up the residue of all these internal/hidden descriptors as well.
> This is what the current pl330_tx_status() function does, but has bugs.
>
> I've only just managed to clearly understand all the above details
> whilst writing this email, and this confusion obviously means the code
> and any commit messages need to explain things better.
Okay I relooked at the code, the driver is creating descriptor per period,
so yes while calculating that should be taken into account but only for
cyclic case and not for rest, as it will break reside values for for them.
--
~Vinod
Powered by blists - more mailing lists