Re: [RFC v4 07/18] vb2: dma-contig: Remove redundant sgt_base field

2017-05-10 Thread Tomasz Figa
Hi Sakari, Some comments inline. On Mon, May 8, 2017 at 11:03 PM, Sakari Ailus wrote: > The struct vb2_dc_buf contains two struct sg_table fields: sgt_base and > dma_sgt. The former is used by DMA-BUF buffers whereas the latter is used > by USERPTR. > > Unify the

[RFC v4 07/18] vb2: dma-contig: Remove redundant sgt_base field

2017-05-08 Thread Sakari Ailus
The struct vb2_dc_buf contains two struct sg_table fields: sgt_base and dma_sgt. The former is used by DMA-BUF buffers whereas the latter is used by USERPTR. Unify the two, leaving dma_sgt. MMAP buffers do not need cache flushing since they have been allocated using dma_alloc_coherent().