Re: [PATCH v2 01/12] iio: buffer-dma: Get rid of outgoing queue

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Jonathan,

Le dim., févr. 13 2022 at 18:57:40 +0000, Jonathan Cameron <jic23@xxxxxxxxxx> a écrit :
On Mon,  7 Feb 2022 12:59:22 +0000
Paul Cercueil <paul@xxxxxxxxxxxxxxx> wrote:

 The buffer-dma code was using two queues, incoming and outgoing, to
 manage the state of the blocks in use.

 While this totally works, it adds some complexity to the code,
especially since the code only manages 2 blocks. It is much easier to just check each block's state manually, and keep a counter for the next
 block to dequeue.

Since the new DMABUF based API wouldn't use the outgoing queue anyway,
 getting rid of it now makes the upcoming changes simpler.

With this change, the IIO_BLOCK_STATE_DEQUEUED is now useless, and can
 be removed.

v2: - Only remove the outgoing queue, and keep the incoming queue, as we want the buffer to start streaming data as soon as it is enabled. - Remove IIO_BLOCK_STATE_DEQUEUED, since it is now functionally the
       same as IIO_BLOCK_STATE_DONE.

 Signed-off-by: Paul Cercueil <paul@xxxxxxxxxxxxxxx>
 ---

Trivial process thing but change log should be here, not above as we don't
want it to end up in the main git log.

I'm kinda used to do this now, it's the policy for sending patches to the DRM tree. I like it because "git notes" disappear after rebases and it's a pain. At least like this I don't lose the changelog.

But okay, I'll change it for v3, if there's a v3.

Cheers,
-Paul

drivers/iio/buffer/industrialio-buffer-dma.c | 44 ++++++++++----------
  include/linux/iio/buffer-dma.h               |  7 ++--
  2 files changed, 26 insertions(+), 25 deletions(-)






[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux