[PATCH] vivid: fix incorrect capabilities for radio

2018-01-31 Thread Hans Verkuil
The vivid driver has two custom controls that change the behavior of RDS. Depending on the control setting the V4L2_CAP_READWRITE capability is toggled. However, after an earlier commit the capability was no longer set correctly. This is now fixed. Fixes: 9765a32cd8 ("vivid: set device_caps in

Re: [PATCH v6 4/6] media: i2c: Add TDA1997x HDMI receiver driver

2018-01-31 Thread Hans Verkuil
On 02/01/2018 05:47 AM, Tim Harvey wrote: > Hans, > > You forgot to include v4l2-ctl-selection.cpp in your patch. You mean v4l2-ctl-subdev.cpp :-) Anyway, I plan on committing this to v4l2-ctl soon. I'll let you know when that's done. I added support for almost all subdev ioctls to v4l2-ctl.

Re: [PATCH v6 4/6] media: i2c: Add TDA1997x HDMI receiver driver

2018-01-31 Thread Tim Harvey
Tim Harvey - Principal Software Engineer Gateworks Corporation - http://www.gateworks.com/ 3026 S. Higuera St. San Luis Obispo CA 93401 805-781-2000 On Wed, Jan 31, 2018 at 5:22 AM, Hans Verkuil wrote: > On 01/31/18 08:38, Hans Verkuil wrote: >> On 01/31/2018 05:51 AM, Tim

cron job: media_tree daily build: ERRORS

2018-01-31 Thread Hans Verkuil
This message is generated daily by a cron job that builds media_tree for the kernels and architectures in the list below. Results of the daily build of media_tree: date: Thu Feb 1 05:00:30 CET 2018 media-tree git hash:273caa260035c03d89ad63d72d8cd3d9e5c5e3f1 media_build

Re: [PATCH v2 3/4] media: ov2685: add support for OV2685 sensor

2018-01-31 Thread Sakari Ailus
Hi Shunqian, On Fri, Jan 12, 2018 at 10:30:57AM +0800, Shunqian Zheng wrote: > Hi Sakari, > > > On 2018年01月03日 19:43, Sakari Ailus wrote: > > > +static int ov2685_s_stream(struct v4l2_subdev *sd, int on) > > > +{ > > > + struct ov2685 *ov2685 = to_ov2685(sd); > > > + struct i2c_client *client =

Re: [PATCH] media: ov5640: various typo & style fixes

2018-01-31 Thread Sakari Ailus
Hi Hugues, On Wed, Jan 31, 2018 at 03:41:07PM +, Hugues FRUCHET wrote: > Comment added about module_param() > > On 01/31/2018 03:29 PM, Hugues Fruchet wrote: > > Y're welcome, changes you pointed out are detected by checkpatch > > (--strict), see below: > > > > On 01/31/2018 03:23 PM,

[PATCH] media: cx25821: prevent out-of-bounds read on array card

2018-01-31 Thread Colin King
From: Colin Ian King Currently an out of range dev->nr is detected by just reporting the issue and later on an out-of-bounds read on array card occurs because of this. Fix this by checking the upper range of dev->nr with the size of array card (removes the hard coded

Re: [RFC PATCH 0/8] [media] Request API, take three

2018-01-31 Thread Hans Verkuil
On 01/31/2018 10:46 AM, Tomasz Figa wrote: > On Wed, Jan 31, 2018 at 5:47 PM, Hans Verkuil wrote: >> On 01/31/2018 09:10 AM, Tomasz Figa wrote: >>> Hi Hans, >>> >>> Sorry for joining the party late. >>> >>> On Wed, Jan 31, 2018 at 4:50 PM, Hans Verkuil

Re: [PATCH] media: ov5640: various typo & style fixes

2018-01-31 Thread Hugues FRUCHET
Comment added about module_param() On 01/31/2018 03:29 PM, Hugues Fruchet wrote: > Y're welcome, changes you pointed out are detected by checkpatch > (--strict), see below: > > On 01/31/2018 03:23 PM, Sakari Ailus wrote: >> Hi Hugues, >> >> Thanks for the patch. It's nice to see cleanups, too!

Re: [linux-sunxi] Re: [PATCH v6 2/2] media: V3s: Add support for Allwinner CSI.

2018-01-31 Thread Liviu Dudau
On Wed, Jan 31, 2018 at 08:42:12AM +0100, Maxime Ripard wrote: > Hi Liviu, Hi Maxime, > > On Wed, Jan 31, 2018 at 03:08:08AM +, Liviu Dudau wrote: > > On Fri, Jan 26, 2018 at 11:00:41AM +0800, Yong wrote: > > > Hi Maxime, > > > > > > On Fri, 26 Jan 2018 09:46:58 +0800 > > > Yong

Re: [PATCH] media: ov5640: various typo & style fixes

2018-01-31 Thread Hugues FRUCHET
Y're welcome, changes you pointed out are detected by checkpatch (--strict), see below: On 01/31/2018 03:23 PM, Sakari Ailus wrote: > Hi Hugues, > > Thanks for the patch. It's nice to see cleanups, too! :-) > > A few comments below. Apart those this seems good to me. > > On Wed, Jan 31, 2018

Re: [PATCH] media: ov5640: various typo & style fixes

2018-01-31 Thread Sakari Ailus
Hi Hugues, Thanks for the patch. It's nice to see cleanups, too! :-) A few comments below. Apart those this seems good to me. On Wed, Jan 31, 2018 at 12:22:09PM +0100, Hugues Fruchet wrote: > Various typo & style fixes either detected by code > review or checkpatch. > > Signed-off-by: Hugues

Re: [PATCH v6 4/6] media: i2c: Add TDA1997x HDMI receiver driver

2018-01-31 Thread Hans Verkuil
On 01/31/18 08:38, Hans Verkuil wrote: > On 01/31/2018 05:51 AM, Tim Harvey wrote: >> On Mon, Jan 29, 2018 at 4:00 AM, Hans Verkuil wrote: >>> On 01/25/2018 05:15 PM, Tim Harvey wrote: >> > > Hmm. This receiver supports multiple output formats, but you advertise

Re: [PATCH v8 07/11] media: i2c: ov772x: Support frame interval handling

2018-01-31 Thread jacopo mondi
Hi Laurent, thanks for review Resuming here the brief conversation on #v4l with you and Hans... On Wed, Jan 31, 2018 at 12:34:59PM +0200, Laurent Pinchart wrote: > Hi Jacopo, > > Thank you for the patch. > > On Tuesday, 30 January 2018 11:58:18 EET Jacopo Mondi wrote: > > Add support to

[PATCH v2] media: ov5640: add error trace in case of i2c read failure

2018-01-31 Thread Hugues Fruchet
Add an error trace in ov5640_read_reg() in case of i2c_transfer() failure. Uniformize error traces using dev_err instead v4l2_err. Signed-off-by: Hugues Fruchet --- version 2: - Uniformize error traces using dev_err instead v4l2_err as per Sakari's review comment.

Re: [PATCH] media: ov5640: add error trace in case of i2c read failure

2018-01-31 Thread Hugues FRUCHET
Hi Sakari, I've made it symetric to ov5640_write_reg() which also uses v4l2_err, I will change both so we are gone with all v4l2_err. BR, Hugues. On 01/31/2018 12:57 PM, Sakari Ailus wrote: > On Wed, Jan 31, 2018 at 12:19:24PM +0100, Hugues Fruchet wrote: >> Add an error trace in

Re: [RFC PATCH 3/8] media: videobuf2: add support for requests

2018-01-31 Thread Sakari Ailus
Hi Alexandre, On Fri, Jan 26, 2018 at 03:02:11PM +0900, Alexandre Courbot wrote: > Make vb2 aware of requests. Drivers can specify whether a given queue > can accept requests or not. Queues that accept requests will block on a > buffer that is part of a request until that request is submitted. >

Re: [PATCH] media: ov5640: add error trace in case of i2c read failure

2018-01-31 Thread Sakari Ailus
On Wed, Jan 31, 2018 at 12:19:24PM +0100, Hugues Fruchet wrote: > Add an error trace in ov5640_read_reg() in case of i2c_transfer() > failure. > > Signed-off-by: Hugues Fruchet > --- > drivers/media/i2c/ov5640.c | 5 - > 1 file changed, 4 insertions(+), 1 deletion(-)

[PATCH] media: ov5640: various typo & style fixes

2018-01-31 Thread Hugues Fruchet
Various typo & style fixes either detected by code review or checkpatch. Signed-off-by: Hugues Fruchet --- drivers/media/i2c/ov5640.c | 52 +++--- 1 file changed, 26 insertions(+), 26 deletions(-) diff --git

[PATCH] media: ov5640: add error trace in case of i2c read failure

2018-01-31 Thread Hugues Fruchet
Add an error trace in ov5640_read_reg() in case of i2c_transfer() failure. Signed-off-by: Hugues Fruchet --- drivers/media/i2c/ov5640.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/media/i2c/ov5640.c b/drivers/media/i2c/ov5640.c index

Re: [PATCH v8 07/11] media: i2c: ov772x: Support frame interval handling

2018-01-31 Thread Laurent Pinchart
Hi Jacopo, Thank you for the patch. On Tuesday, 30 January 2018 11:58:18 EET Jacopo Mondi wrote: > Add support to ov772x driver for frame intervals handling and enumeration. > Tested with 10MHz and 24MHz input clock at VGA and QVGA resolutions for > 10, 15 and 30 frame per second rates. > >

[RFCv2 02/17] videodev2.h: Add request_fd field to v4l2_buffer

2018-01-31 Thread Alexandre Courbot
From: Hans Verkuil When queuing buffers allow for passing the request that should be associated with this buffer. Signed-off-by: Hans Verkuil [acour...@chromium.org: make request ID 32-bit] Signed-off-by: Alexandre Courbot

[RFCv2 04/17] media: vb2: add support for requests in QBUF ioctl

2018-01-31 Thread Alexandre Courbot
Support the request argument of the QBUF ioctl. Signed-off-by: Alexandre Courbot --- drivers/media/v4l2-core/v4l2-ioctl.c | 83 +++- 1 file changed, 82 insertions(+), 1 deletion(-) diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c

[RFCv2 01/17] media: add request API core and UAPI

2018-01-31 Thread Alexandre Courbot
The request API provides a way to group buffers and device parameters into units of work to be queued and executed. This patch introduces the UAPI and core framework. This patch is based on the previous work by Laurent Pinchart. The core has changed considerably, but the UAPI is mostly untouched.

[RFCv2 08/17] v4l2-ctrls: add core request API

2018-01-31 Thread Alexandre Courbot
From: Hans Verkuil Add the four core request functions: v4l2_ctrl_request_init() initializes a new (empty) request. v4l2_ctrl_request_clone() resets a request based on another request (or clears it if that request is NULL). v4l2_ctrl_request_get(): increase refcount

[RFCv2 12/17] v4l2: add request API support

2018-01-31 Thread Alexandre Courbot
Add a v4l2 request entity data structure that takes care of storing the request-related state of a V4L2 device ; in this case, its controls. Signed-off-by: Alexandre Courbot --- drivers/media/v4l2-core/Makefile | 2 +- drivers/media/v4l2-core/v4l2-request.c | 54

[RFCv2 13/17] videodev2.h: add request_fd field to v4l2_ext_controls

2018-01-31 Thread Alexandre Courbot
Allow to specify a request to be used with the S_EXT_CTRLS and G_EXT_CTRLS operations. Signed-off-by: Alexandre Courbot --- include/uapi/linux/videodev2.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/uapi/linux/videodev2.h

[RFCv2 10/17] v4l2-ctrls: support g/s_ext_ctrls for requests

2018-01-31 Thread Alexandre Courbot
From: Hans Verkuil The v4l2_g/s_ext_ctrls functions now support control handlers that represent requests. Signed-off-by: Hans Verkuil Signed-off-by: Alexandre Courbot --- drivers/media/v4l2-core/v4l2-ctrls.c | 37

[RFCv2 14/17] v4l2-ctrls: support requests in EXT_CTRLS ioctls

2018-01-31 Thread Alexandre Courbot
Read and use the request_fd field of struct v4l2_ext_controls to apply VIDIOC_G_EXT_CTRLS or VIDIOC_S_EXT_CTRLS to a request when asked by userspace. Signed-off-by: Alexandre Courbot --- drivers/media/v4l2-core/v4l2-ioctl.c | 36 1

[RFCv2 17/17] media: vim2m: add request support

2018-01-31 Thread Alexandre Courbot
Set the necessary ops for supporting requests in vim2m. Signed-off-by: Alexandre Courbot --- drivers/media/platform/vim2m.c | 55 ++ 1 file changed, 55 insertions(+) diff --git a/drivers/media/platform/vim2m.c

[RFCv2 16/17] media: vim2m: add media device

2018-01-31 Thread Alexandre Courbot
Request API requires a media node. Add one to the vim2m driver so we can use requests with it. Signed-off-by: Alexandre Courbot --- drivers/media/platform/vim2m.c | 24 1 file changed, 24 insertions(+) diff --git a/drivers/media/platform/vim2m.c

[RFCv2 15/17] v4l2: document the request API interface

2018-01-31 Thread Alexandre Courbot
Document how the request API can be used along with the existing V4L2 interface. Signed-off-by: Alexandre Courbot --- Documentation/media/uapi/v4l/buffer.rst| 10 +- Documentation/media/uapi/v4l/common.rst| 1 +

[RFCv2 07/17] v4l2-ctrls: prepare internal structs for request API

2018-01-31 Thread Alexandre Courbot
From: Hans Verkuil Add a refcount and is_request bool to struct v4l2_ctrl_handler: this is used to refcount a handler that represents a request. Add a p_req field to struct v4l2_ctrl_ref that will store the request value. Signed-off-by: Hans Verkuil

[RFCv2 11/17] v4l2-ctrls: add v4l2_ctrl_request_setup

2018-01-31 Thread Alexandre Courbot
From: Hans Verkuil Add a helper function that can set controls from a request. Signed-off-by: Hans Verkuil Signed-off-by: Alexandre Courbot --- drivers/media/v4l2-core/v4l2-ctrls.c | 71

[RFCv2 03/17] media: videobuf2: add support for requests

2018-01-31 Thread Alexandre Courbot
Make vb2 aware of requests. Drivers can specify whether a given queue can accept requests or not. Queues that accept requests will block on a buffer that is part of a request until that request is submitted. Signed-off-by: Alexandre Courbot ---

[RFCv2 06/17] v4l2-ctrls: v4l2_ctrl_add_handler: add from_other_dev

2018-01-31 Thread Alexandre Courbot
From: Hans Verkuil Add a 'bool from_other_dev' argument: set to true if the two handlers refer to different devices (e.g. it is true when inheriting controls from a subdev into a main v4l2 bridge driver). This will be used later when implementing support for the request

[RFCv2 09/17] v4l2-ctrls: use ref in helper instead of ctrl

2018-01-31 Thread Alexandre Courbot
From: Hans Verkuil The next patch needs the reference to a control instead of the control itself, so change struct v4l2_ctrl_helper accordingly. Signed-off-by: Hans Verkuil Signed-off-by: Alexandre Courbot ---

[RFCv2 05/17] media: Document the media request API

2018-01-31 Thread Alexandre Courbot
From: Laurent Pinchart The media request API is made of a new ioctl to implement request management. Document it. Signed-off-by: Laurent Pinchart [acour...@chromium.org: adapt for newest API] Signed-off-by:

[RFCv2 00/17] Request API, take three

2018-01-31 Thread Alexandre Courbot
This is a quickly-put together revision that includes and uses Hans' work to use v4l2_ctrl_handler as the request state holder for V4L2 devices. Although minor fixes have also been applied, there are still a few comments from the previous revision that are left unaddressed. I wanted to give Hans

Re: [RFC PATCH 0/8] [media] Request API, take three

2018-01-31 Thread Tomasz Figa
On Wed, Jan 31, 2018 at 5:47 PM, Hans Verkuil wrote: > On 01/31/2018 09:10 AM, Tomasz Figa wrote: >> Hi Hans, >> >> Sorry for joining the party late. >> >> On Wed, Jan 31, 2018 at 4:50 PM, Hans Verkuil wrote: >>> On 01/30/2018 07:31 AM, Alexandre Courbot

Re: [PATCH v6 2/2] media: V3s: Add support for Allwinner CSI.

2018-01-31 Thread Arnd Bergmann
On Wed, Jan 31, 2018 at 8:29 AM, Maxime Ripard wrote: > Hi Thierry, > > On Tue, Jan 30, 2018 at 11:01:50AM +0100, Thierry Reding wrote: >> On Tue, Jan 30, 2018 at 10:59:16AM +0100, Thierry Reding wrote: >> > On Tue, Jan 30, 2018 at 10:24:48AM +0100, Arnd Bergmann

[PATCH v3] media: ov5640: add JPEG support

2018-01-31 Thread Hugues Fruchet
Add YUV422 encoded JPEG support. Signed-off-by: Hugues Fruchet --- version 2: - Revisit code as per Sakari suggestions: - fix lock scheme - fix switch back to non-JPEG output while sensor powered See

Re: [RFC PATCH 0/8] [media] Request API, take three

2018-01-31 Thread Hans Verkuil
On 01/31/2018 09:10 AM, Tomasz Figa wrote: > Hi Hans, > > Sorry for joining the party late. > > On Wed, Jan 31, 2018 at 4:50 PM, Hans Verkuil wrote: >> On 01/30/2018 07:31 AM, Alexandre Courbot wrote: >>> Hi Hans, >>> >>> On Mon, Jan 29, 2018 at 8:21 PM, Hans Verkuil

Re: [RFC PATCH 6/8] v4l2: document the request API interface

2018-01-31 Thread Hans Verkuil
On 01/30/2018 07:31 AM, Alexandre Courbot wrote: > On Tue, Jan 30, 2018 at 1:03 AM, Hans Verkuil wrote: >> On 01/26/2018 07:02 AM, Alexandre Courbot wrote: >>> Document how the request API can be used along with the existing V4L2 >>> interface. >>> >>> Signed-off-by: Alexandre

Re: [RFC PATCH 0/8] [media] Request API, take three

2018-01-31 Thread Tomasz Figa
Hi Hans, Sorry for joining the party late. On Wed, Jan 31, 2018 at 4:50 PM, Hans Verkuil wrote: > On 01/30/2018 07:31 AM, Alexandre Courbot wrote: >> Hi Hans, >> >> On Mon, Jan 29, 2018 at 8:21 PM, Hans Verkuil wrote: >>> On 01/26/2018 07:02 AM,

Re: [PATCH v8 04/11] ARM: dts: r7s72100: Add Capture Engine Unit (CEU)

2018-01-31 Thread Sergei Shtylyov
Hello! On 1/30/2018 12:58 PM, Jacopo Mondi wrote: Add Capture Engine Unit (CEU) node to device tree. Signed-off-by: Jacopo Mondi Reviewed-by: Geert Uytterhoeven Reviewed-by: Laurent Pinchart Acked-by: