Re: [PATCH RFC 0/2] pxa_camera transition to v4l2 standalone device
On 03/21/2016 11:42 PM, Robert Jarzmik wrote: > Hans Verkuilwrites: > >>> Input ioctls: >>> test VIDIOC_G/S_TUNER/ENUM_FREQ_BANDS: OK (Not Supported) >>> test VIDIOC_G/S_FREQUENCY: OK (Not Supported) >>> test VIDIOC_S_HW_FREQ_SEEK: OK (Not Supported) >>> test VIDIOC_ENUMAUDIO: OK (Not Supported) >>> fail: v4l2-test-input-output.cpp(418): G_INPUT not supported >>> for a capture device >> >> ENUM/G/S_INPUT is missing and is required for capture devices. > Okay, that one will be easy I think :) It's a mono-sensor mono-videostream IP. > I will add that when for RFC v2. > >>> Format ioctls: >>> test VIDIOC_ENUM_FMT/FRAMESIZES/FRAMEINTERVALS: OK >>> test VIDIOC_G/S_PARM: OK (Not Supported) >>> test VIDIOC_G_FBUF: OK (Not Supported) >>> fail: v4l2-test-formats.cpp(329): pixelformat != >>> V4L2_PIX_FMT_JPEG && colorspace == V4L2_COLORSPACE_JPEG >>> fail: v4l2-test-formats.cpp(432): >>> testColorspace(pix.pixelformat, pix.colorspace, pix.ycbcr_enc, >>> pix.quantization) >> >> The sensor should almost certainly use COLORSPACE_SRGB. Certainly not >> COLORSPACE_JPEG. > Ah even for YUYV format, I didn't know ... The pixel format != colorspace. You can read more about that here, if you are interested: https://hverkuil.home.xs4all.nl/spec/media.html#colorspaces > >>> Buffer ioctls: >>> test VIDIOC_REQBUFS/CREATE_BUFS/QUERYBUF: OK >>> fail: v4l2-test-buffers.cpp(571): q.has_expbuf(node) >> >> You are missing .vidioc_expbuf = vbs_ioctl_expbuf and the vb2 io_mode >> VB2_DMABUF. > Nope, I have : > .vidioc_expbuf = vb2_ioctl_expbuf, > vq->io_modes = VB2_MMAP | VB2_DMABUF; > > So it's something more subtle, and I have a bit of work to understand what. Fix the colorspace issue first, I wonder if it is just fallout from that earlier issue. Regards, Hans > > Cheers. > > -- > Robert > -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH RFC 0/2] pxa_camera transition to v4l2 standalone device
Hans Verkuilwrites: >> Input ioctls: >> test VIDIOC_G/S_TUNER/ENUM_FREQ_BANDS: OK (Not Supported) >> test VIDIOC_G/S_FREQUENCY: OK (Not Supported) >> test VIDIOC_S_HW_FREQ_SEEK: OK (Not Supported) >> test VIDIOC_ENUMAUDIO: OK (Not Supported) >> fail: v4l2-test-input-output.cpp(418): G_INPUT not supported >> for a capture device > > ENUM/G/S_INPUT is missing and is required for capture devices. Okay, that one will be easy I think :) It's a mono-sensor mono-videostream IP. I will add that when for RFC v2. >> Format ioctls: >> test VIDIOC_ENUM_FMT/FRAMESIZES/FRAMEINTERVALS: OK >> test VIDIOC_G/S_PARM: OK (Not Supported) >> test VIDIOC_G_FBUF: OK (Not Supported) >> fail: v4l2-test-formats.cpp(329): pixelformat != >> V4L2_PIX_FMT_JPEG && colorspace == V4L2_COLORSPACE_JPEG >> fail: v4l2-test-formats.cpp(432): >> testColorspace(pix.pixelformat, pix.colorspace, pix.ycbcr_enc, >> pix.quantization) > > The sensor should almost certainly use COLORSPACE_SRGB. Certainly not > COLORSPACE_JPEG. Ah even for YUYV format, I didn't know ... >> Buffer ioctls: >> test VIDIOC_REQBUFS/CREATE_BUFS/QUERYBUF: OK >> fail: v4l2-test-buffers.cpp(571): q.has_expbuf(node) > > You are missing .vidioc_expbuf = vbs_ioctl_expbuf and the vb2 io_mode > VB2_DMABUF. Nope, I have : .vidioc_expbuf = vb2_ioctl_expbuf, vq->io_modes = VB2_MMAP | VB2_DMABUF; So it's something more subtle, and I have a bit of work to understand what. Cheers. -- Robert -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH RFC 0/2] pxa_camera transition to v4l2 standalone device
On 03/21/2016 11:26 PM, Robert Jarzmik wrote: > Hans Verkuilwrites: > >> On 03/19/2016 10:01 PM, Robert Jarzmik wrote: >>> Hi Hans and Guennadi, >>> >>> As Hans is converting sh_mobile_ceu_camera.c, >> >> That's not going as fast as I hoped. This driver is quite complex and >> extracting >> it from soc-camera isn't easy. I also can't spend as much time as I'd like >> on this. >> >>> let's see how close our ports are >>> to see if there are things we could either reuse of change. >>> >>> The port is assuming : >>> - the formation translation is transferred into soc_mediabus, so that it >>> can be >>>reused across all v4l2 devices >> >> At best this will be a temporary helper source. I never liked soc_mediabus, >> I don't >> believe it is the right approach. > As long as you provide a better approach, especially for the dynamic formats > translation, it should be fine. > >> But I have no problem if it is used for now to simplify the soc-camera >> dependency removal. > Ok. > >>> - pxa_camera is ported >>> >>> This sets a ground of discussion for soc_camera adherence removal from >>> pxa_camera. I'd like to have a comment from Hans if this is what he has in >>> mind, >>> and Guennadi if he agrees to transfer the soc xlate stuff to soc_mediabus. >> >> Can you provide the output of 'v4l2-compliance -s' with your new pxa driver? >> I would be curious to see the result of that. > Of course, with [1] added (initial format init and querycap strings), I have > the following results. I have no idea where VIDIOC_EXPBUF failure comes from, > while the colorspace issues are a consequence from the MT9M111 sensor which > provides the couple ("VYUY", V4L2_COLORSPACE_JPEG) format (which I also don't > understand why it is a failure) : > > Driver Info: > Driver name : pxa27x-camera > Card type : PXA_Camera > Bus info : platform:pxa-camera > Driver version: 4.5.0 > Capabilities : 0x8421 > Video Capture > Streaming > Extended Pix Format > Device Capabilities > Device Caps : 0x0421 > Video Capture > Streaming > Extended Pix Format > > Compliance test for device /dev/video0 (not using libv4l2): > > Required ioctls: > test VIDIOC_QUERYCAP: OK > > Allow for multiple opens: > test second video open: OK > test VIDIOC_QUERYCAP: OK > test VIDIOC_G/S_PRIORITY: OK > > Debug ioctls: > test VIDIOC_DBG_G/S_REGISTER: OK > test VIDIOC_LOG_STATUS: OK (Not Supported) > > Input ioctls: > test VIDIOC_G/S_TUNER/ENUM_FREQ_BANDS: OK (Not Supported) > test VIDIOC_G/S_FREQUENCY: OK (Not Supported) > test VIDIOC_S_HW_FREQ_SEEK: OK (Not Supported) > test VIDIOC_ENUMAUDIO: OK (Not Supported) > fail: v4l2-test-input-output.cpp(418): G_INPUT not supported > for a capture device ENUM/G/S_INPUT is missing and is required for capture devices. > test VIDIOC_G/S/ENUMINPUT: FAIL > test VIDIOC_G/S_AUDIO: OK (Not Supported) > Inputs: 0 Audio Inputs: 0 Tuners: 0 > > Output ioctls: > test VIDIOC_G/S_MODULATOR: OK (Not Supported) > test VIDIOC_G/S_FREQUENCY: OK (Not Supported) > test VIDIOC_ENUMAUDOUT: OK (Not Supported) > test VIDIOC_G/S/ENUMOUTPUT: OK (Not Supported) > test VIDIOC_G/S_AUDOUT: OK (Not Supported) > Outputs: 0 Audio Outputs: 0 Modulators: 0 > > Input/Output configuration ioctls: > test VIDIOC_ENUM/G/S/QUERY_STD: OK (Not Supported) > test VIDIOC_ENUM/G/S/QUERY_DV_TIMINGS: OK (Not Supported) > test VIDIOC_DV_TIMINGS_CAP: OK (Not Supported) > test VIDIOC_G/S_EDID: OK (Not Supported) > > Control ioctls: > test VIDIOC_QUERY_EXT_CTRL/QUERYMENU: OK (Not Supported) > test VIDIOC_QUERYCTRL: OK (Not Supported) > test VIDIOC_G/S_CTRL: OK (Not Supported) > test VIDIOC_G/S/TRY_EXT_CTRLS: OK (Not Supported) > test VIDIOC_(UN)SUBSCRIBE_EVENT/DQEVENT: OK (Not Supported) > test VIDIOC_G/S_JPEGCOMP: OK (Not Supported) > Standard Controls: 0 Private Controls: 0 > > Format ioctls: > test VIDIOC_ENUM_FMT/FRAMESIZES/FRAMEINTERVALS: OK > test VIDIOC_G/S_PARM: OK (Not Supported) > test VIDIOC_G_FBUF: OK (Not Supported) > fail: v4l2-test-formats.cpp(329): pixelformat != > V4L2_PIX_FMT_JPEG && colorspace == V4L2_COLORSPACE_JPEG > fail: v4l2-test-formats.cpp(432): > testColorspace(pix.pixelformat, pix.colorspace, pix.ycbcr_enc, > pix.quantization) The sensor should almost certainly use COLORSPACE_SRGB. Certainly not COLORSPACE_JPEG. > test VIDIOC_G_FMT: FAIL > test VIDIOC_TRY_FMT: OK (Not Supported) > test VIDIOC_S_FMT: OK (Not Supported) > test VIDIOC_G_SLICED_VBI_CAP: OK (Not Supported)
Re: [PATCH RFC 0/2] pxa_camera transition to v4l2 standalone device
Hans Verkuilwrites: > On 03/19/2016 10:01 PM, Robert Jarzmik wrote: >> Hi Hans and Guennadi, >> >> As Hans is converting sh_mobile_ceu_camera.c, > > That's not going as fast as I hoped. This driver is quite complex and > extracting > it from soc-camera isn't easy. I also can't spend as much time as I'd like on > this. > >> let's see how close our ports are >> to see if there are things we could either reuse of change. >> >> The port is assuming : >> - the formation translation is transferred into soc_mediabus, so that it >> can be >>reused across all v4l2 devices > > At best this will be a temporary helper source. I never liked soc_mediabus, I > don't > believe it is the right approach. As long as you provide a better approach, especially for the dynamic formats translation, it should be fine. > But I have no problem if it is used for now to simplify the soc-camera > dependency removal. Ok. >> - pxa_camera is ported >> >> This sets a ground of discussion for soc_camera adherence removal from >> pxa_camera. I'd like to have a comment from Hans if this is what he has in >> mind, >> and Guennadi if he agrees to transfer the soc xlate stuff to soc_mediabus. > > Can you provide the output of 'v4l2-compliance -s' with your new pxa driver? > I would be curious to see the result of that. Of course, with [1] added (initial format init and querycap strings), I have the following results. I have no idea where VIDIOC_EXPBUF failure comes from, while the colorspace issues are a consequence from the MT9M111 sensor which provides the couple ("VYUY", V4L2_COLORSPACE_JPEG) format (which I also don't understand why it is a failure) : Driver Info: Driver name : pxa27x-camera Card type : PXA_Camera Bus info : platform:pxa-camera Driver version: 4.5.0 Capabilities : 0x8421 Video Capture Streaming Extended Pix Format Device Capabilities Device Caps : 0x0421 Video Capture Streaming Extended Pix Format Compliance test for device /dev/video0 (not using libv4l2): Required ioctls: test VIDIOC_QUERYCAP: OK Allow for multiple opens: test second video open: OK test VIDIOC_QUERYCAP: OK test VIDIOC_G/S_PRIORITY: OK Debug ioctls: test VIDIOC_DBG_G/S_REGISTER: OK test VIDIOC_LOG_STATUS: OK (Not Supported) Input ioctls: test VIDIOC_G/S_TUNER/ENUM_FREQ_BANDS: OK (Not Supported) test VIDIOC_G/S_FREQUENCY: OK (Not Supported) test VIDIOC_S_HW_FREQ_SEEK: OK (Not Supported) test VIDIOC_ENUMAUDIO: OK (Not Supported) fail: v4l2-test-input-output.cpp(418): G_INPUT not supported for a capture device test VIDIOC_G/S/ENUMINPUT: FAIL test VIDIOC_G/S_AUDIO: OK (Not Supported) Inputs: 0 Audio Inputs: 0 Tuners: 0 Output ioctls: test VIDIOC_G/S_MODULATOR: OK (Not Supported) test VIDIOC_G/S_FREQUENCY: OK (Not Supported) test VIDIOC_ENUMAUDOUT: OK (Not Supported) test VIDIOC_G/S/ENUMOUTPUT: OK (Not Supported) test VIDIOC_G/S_AUDOUT: OK (Not Supported) Outputs: 0 Audio Outputs: 0 Modulators: 0 Input/Output configuration ioctls: test VIDIOC_ENUM/G/S/QUERY_STD: OK (Not Supported) test VIDIOC_ENUM/G/S/QUERY_DV_TIMINGS: OK (Not Supported) test VIDIOC_DV_TIMINGS_CAP: OK (Not Supported) test VIDIOC_G/S_EDID: OK (Not Supported) Control ioctls: test VIDIOC_QUERY_EXT_CTRL/QUERYMENU: OK (Not Supported) test VIDIOC_QUERYCTRL: OK (Not Supported) test VIDIOC_G/S_CTRL: OK (Not Supported) test VIDIOC_G/S/TRY_EXT_CTRLS: OK (Not Supported) test VIDIOC_(UN)SUBSCRIBE_EVENT/DQEVENT: OK (Not Supported) test VIDIOC_G/S_JPEGCOMP: OK (Not Supported) Standard Controls: 0 Private Controls: 0 Format ioctls: test VIDIOC_ENUM_FMT/FRAMESIZES/FRAMEINTERVALS: OK test VIDIOC_G/S_PARM: OK (Not Supported) test VIDIOC_G_FBUF: OK (Not Supported) fail: v4l2-test-formats.cpp(329): pixelformat != V4L2_PIX_FMT_JPEG && colorspace == V4L2_COLORSPACE_JPEG fail: v4l2-test-formats.cpp(432): testColorspace(pix.pixelformat, pix.colorspace, pix.ycbcr_enc, pix.quantization) test VIDIOC_G_FMT: FAIL test VIDIOC_TRY_FMT: OK (Not Supported) test VIDIOC_S_FMT: OK (Not Supported) test VIDIOC_G_SLICED_VBI_CAP: OK (Not Supported) test Cropping: OK (Not Supported) test Composing: OK (Not Supported) test Scaling: OK Codec ioctls: test VIDIOC_(TRY_)ENCODER_CMD: OK (Not Supported) test VIDIOC_G_ENC_INDEX: OK (Not Supported)
Re: [PATCH RFC 0/2] pxa_camera transition to v4l2 standalone device
On 03/19/2016 10:01 PM, Robert Jarzmik wrote: > Hi Hans and Guennadi, > > As Hans is converting sh_mobile_ceu_camera.c, That's not going as fast as I hoped. This driver is quite complex and extracting it from soc-camera isn't easy. I also can't spend as much time as I'd like on this. > let's see how close our ports are > to see if there are things we could either reuse of change. > > The port is assuming : > - the formation translation is transferred into soc_mediabus, so that it can > be >reused across all v4l2 devices At best this will be a temporary helper source. I never liked soc_mediabus, I don't believe it is the right approach. But I have no problem if it is used for now to simplify the soc-camera dependency removal. > - pxa_camera is ported > > This sets a ground of discussion for soc_camera adherence removal from > pxa_camera. I'd like to have a comment from Hans if this is what he has in > mind, > and Guennadi if he agrees to transfer the soc xlate stuff to soc_mediabus. Can you provide the output of 'v4l2-compliance -s' with your new pxa driver? I would be curious to see the result of that. Regards, Hans -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html