Hi Michael, On Monday 11 February 2013 16:14:00 Michael Grzeschik wrote: > On Mon, Feb 11, 2013 at 04:02:23PM +0100, Laurent Pinchart wrote: > > On Friday 08 February 2013 23:38:59 Bhupesh SHARMA wrote: > > > > [snip] > > > > > > Beside my two comments on patch 3 i have tested it with the contig > > > > allocator instead of vmalloc [¹]. With that changes applied i can give > > > > my Tested-By if desired. > > > > > > @ Michael, sure I can apply your comments and also Laurent's and then > > > probably you can add your Tested-By. @ Laurent, would that be fine? > > > > What are your use cases that require vb2 dma-contig instead of vb2 vmalloc > > ? > > We are currently working with USERPTR buffers which are, in the first > instance, dma-alloc buffers which come from an camera and are shared by > gstreamer. The UVC-Camera needs the physical address in the end. For that > the videobuf2-dam-contig.c has following hack. > > diff --git a/drivers/media/video/videobuf2-dma-contig.c > b/drivers/media/video/videobuf2-dma-contig.c index cac8114..c828b46 100644 > --- a/drivers/media/video/videobuf2-dma-contig.c > +++ b/drivers/media/video/videobuf2-dma-contig.c > @@ -133,6 +133,7 @@ static void *vb2_dma_contig_get_userptr(void *alloc_ctx, > unsigned long vaddr, return ERR_PTR(ret); > } > > + buf->vaddr = phys_to_virt(dma_addr); > buf->size = size; > buf->dma_addr = dma_addr; > buf->vma = vma; Can't vb2-vmalloc import USERPTR buffers that have been allocated by vb2-dma- contig ? BTW, why don't you import dma-buf buffers directly instead of using USERPTR ? -- Regards, Laurent Pinchart -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html