Re: atomisp current issues

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

 



Em Wed, 3 Nov 2021 16:54:24 +0000
Mauro Carvalho Chehab <mchehab+huawei@xxxxxxxxxx> escreveu:

> Em Wed, 3 Nov 2021 15:41:05 +0100
> Hans Verkuil <hverkuil-cisco@xxxxxxxxx> escreveu:
> 
> > On 03/11/2021 14:54, Mauro Carvalho Chehab wrote:  
> > > Hi,
> > > 
> > > From what I've seen so far, those are the main issues with regards to V4L2 API,
> > > in order to allow a generic V4L2 application to work with it.
> > > 
> > > MMAP support
> > > ============
> > > 
> > > Despite having some MMAP code on it, the current implementation is broken. 
> > > Fixing it is not trivial, as it would require fixing the HMM support on it, 
> > > which does several tricks.
> > > 
> > > The best would be to replace it by something simpler. If this is similar
> > > enough to IPU3, perhaps one idea would be to replace the HMM code on it by 
> > > videodev2 + IPU3 HMM code.
> > > 
> > > As this is not trivial, I'm postponing such task. If someone has enough
> > > time, it would be great to have this fixed.
> > > 
> > > From my side, I opted to add support for USERPTR on camorama:
> > > 
> > > 	https://github.com/alessio/camorama
> > > 
> > > As this is something I wanted to do anyway, and it allowed me to cleanup
> > > several things in camorama's code.
> > > 
> > > Support for USERPTR is not autodetected. So, this should be selected    
> > 
> > You can autodetect this: the capabilities field returned by VIDIOC_REQBUFS
> > or VIDIOC_CREATE_BUFS will indicate support for this. This works with any
> > vb2-based driver.
> > 
> > Just thought I should mention this...  
> 
> Yeah, surely the app could try it, but:
> 
> 1. As libv4l doesn't support USERPTR, such detection should happen
>    early inside camorama code;

I ended adding auto-detection support for USERPTR inside camorama,
for completeness.

The "-U" command line option remains, so one could use it to force USERPTR
mode.

As the way I implemented it is that camorama checks if REQBUFS doesn't
return any error, it means that it will automatically fallback to USERPTR
with atomisp driver (while MMAP support is not fixed there).

So, once I fix the issues with S_FMT/G_FMT, camorama will likely work
out of the box with it.

Regards,
Mauro





[Index of Archives]     [Linux Driver Development]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux