Re: [PATCHv4 04/11] videobuf2: add queue memory consistency parameter

From: Sergey Senozhatsky
Date: Mon Mar 23 2020 - 22:39:15 EST


On (20/03/20 14:46), Dafna Hirschfeld wrote:
[..]
> > +static void set_queue_consistency(struct vb2_queue *q, bool consistent_mem)
> > +{
> > + if (!vb2_queue_allows_cache_hints(q))
> > + return;
> > +
> > + if (consistent_mem)
> > + q->dma_attrs &= ~DMA_ATTR_NON_CONSISTENT;
> > + else
> > + q->dma_attrs |= DMA_ATTR_NON_CONSISTENT;
> > +}
> > +
> > int vb2_core_reqbufs(struct vb2_queue *q, enum vb2_memory memory,
> > - unsigned int *count)
> > + bool consistent_mem, unsigned int *count)
> You extended the vb2_core_reqbufs accepting a new boolean that
> is decided according to the setting of the V4L2_FLAG_MEMORY_NON_CONSISTENT
> but in the future some other flags might be added, and so I think it
> is better to replace the boolean with a u32 consisting of all the flags.

Don't have any objections. Can change the `bool' to `u32'.

-ss