Re: Please help test the new v4l-subdev support in v4l2-compliance

2018-02-06 Thread Tim Harvey
On Mon, Feb 5, 2018 at 11:34 PM, Hans Verkuil wrote: > On 02/06/2018 08:16 AM, Tim Harvey wrote: >> On Sat, Feb 3, 2018 at 7:56 AM, Hans Verkuil wrote: >> >> With regards to the 3 failures: >> >> 1. test VIDIOC_G/S_EDID: FAIL >> This is a valid catch

[PATCH v3 7/8] platform: sh_veu: use 64-bit arithmetic instead of 32-bit

2018-02-06 Thread Gustavo A. R. Silva
Cast left and top to dma_addr_t in order to give the compiler complete information about the proper arithmetic to use. Notice that these variables are being used in contexts that expect expressions of type dma_addr_t (64 bit, unsigned). Such expressions are currently being evaluated using 32-bit

Re: [PATCH] media: cxusb, dib0700: ignore XC2028_I2C_FLUSH

2018-02-06 Thread Enrico Mioso
thank you very very much!! Hoping this patch find it's way into mainline ASAP! :) It will make my life much easier, when dealing with systems with long uptime especially. Enrico On Wed, 24 Jan 2018, Mauro Carvalho Chehab wrote: Date: Wed, 24 Jan 2018 12:05:24 From: Mauro Carvalho Chehab

[PATCH] v4l2-ioctl.c: fix VIDIOC_DV_TIMINGS_CAP: don't clear pad

2018-02-06 Thread Hans Verkuil
The pad field should be passed on to the subdev driver, but it is cleared in v4l2-ioctl.c so the subdev driver always sees a 0 pad. Found with v4l2-compliance. Signed-off-by: Hans Verkuil Reported-by: Tim Harvey --- diff --git

Re: Please help test the new v4l-subdev support in v4l2-compliance

2018-02-06 Thread Hans Verkuil
On 02/06/2018 07:48 PM, Tim Harvey wrote: > On Mon, Feb 5, 2018 at 11:34 PM, Hans Verkuil wrote: >> On 02/06/2018 08:16 AM, Tim Harvey wrote: >>> On Sat, Feb 3, 2018 at 7:56 AM, Hans Verkuil wrote: > >>> >>> With regards to the 3 failures: >>> >>> 1. test

Re: [RFCv2 00/17] Request API, take three

2018-02-06 Thread Hans Verkuil
Hi Alexandre, On 01/31/18 11:24, Alexandre Courbot wrote: > 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 >

[GIT PULL for v4.16-rc1] media updates

2018-02-06 Thread Mauro Carvalho Chehab
Hi Linus, Please pull from: git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media tags/media/v4.16-2 For: - videobuf2 was moved to a media/common dir, as it is now used by the DVB subsystem too; - Digital TV core memory mapped support interface; - New sensor drivers: ov7740; -

Re: [PATCH 5/5] add default control values as module parameters

2018-02-06 Thread Florian Echtler
On 05.02.2018 15:56, Hans Verkuil wrote: > Please add a change log when you make a patch. > I for one would like to know why this has to be supplied as a module option. The idea here was that each individual SUR40 device will likely have slightly different "ideal" settings for the parameters, and

Re: media_device.c question: can this workaround be removed?

2018-02-06 Thread Hans Verkuil
On 02/06/18 11:15, Mauro Carvalho Chehab wrote: > Em Mon, 5 Feb 2018 23:48:38 +0200 > Sakari Ailus escreveu: > >> Hi Mauro and Hans, > >>> Adding pad index to new API is trivial, as your RFC patch pointed. >>> >>> Changing media-ctl to fully use the new ioctl is not

Re: media_device.c question: can this workaround be removed?

2018-02-06 Thread Mauro Carvalho Chehab
Em Mon, 5 Feb 2018 23:48:38 +0200 Sakari Ailus escreveu: > Hi Mauro and Hans, > > Adding pad index to new API is trivial, as your RFC patch pointed. > > > > Changing media-ctl to fully use the new ioctl is not trivial, as it > > was written on a non-portable way, very

Re: [PATCH v2 8/8] platform: vivid-cec: use 64-bit arithmetic instead of 32-bit

2018-02-06 Thread Hans Verkuil
On 02/05/18 22:54, Gustavo A. R. Silva wrote: > Hi Hans, > > Quoting Hans Verkuil : > >> On 02/05/2018 09:36 PM, Gustavo A. R. Silva wrote: >>> Add suffix ULL to constant 10 in order to give the compiler complete >>> information about the proper arithmetic to use. Notice that

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

2018-02-06 Thread Hans Verkuil
On 01/31/18 05:36, Tim Harvey wrote: > Add support for the TDA1997x HDMI receivers. > > Cc: Hans Verkuil > Signed-off-by: Tim Harvey > --- > v7: > - fix interlaced mode > - support no AVI infoframe (ie DVI) (Hans) > - add support for multiple output

Re: [GIT PULL for v4.16-rc1] media updates

2018-02-06 Thread Stephen Rothwell
Hi Linus, On Tue, 6 Feb 2018 09:11:30 -0200 Mauro Carvalho Chehab wrote: > > 1) You may expect a merge conflict due to this patch: > c23e0cb81e40 ("media: annotate ->poll() instances") > > See: https://lkml.org/lkml/2018/1/1/547 Looks like you missed this

[PATCH] keytable: fix EVIOCSCLOCKID related compile failure

2018-02-06 Thread Peter Seiderer
Fixes: keytable.c: In function 'test_event': keytable.c:1351:12: error: 'EVIOCSCLOCKID' undeclared (first use in this function) ioctl(fd, EVIOCSCLOCKID, ); ^ Signed-off-by: Peter Seiderer --- utils/keytable/keytable.c | 4 1 file

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

2018-02-06 Thread Sakari Ailus
Hi Hans and Alexandre, On Wed, Jan 31, 2018 at 09:26:10AM +0100, Hans Verkuil wrote: > 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: ... > >>> +Recycling and

Re: [GIT PULL for v4.16-rc1] media updates

2018-02-06 Thread Linus Torvalds
On Tue, Feb 6, 2018 at 2:16 PM, Stephen Rothwell wrote: >> See: https://lkml.org/lkml/2018/1/1/547 > > Looks like you missed this when doing the merge :-( Gaah. I noticed the actual conflicts, and then didn't actually notice that there had been some other __poll_t

Re: [PATCH v8 0/7] TDA1997x HDMI video reciver

2018-02-06 Thread Tim Harvey
On Tue, Feb 6, 2018 at 1:21 PM, Hans Verkuil wrote: > On 02/06/2018 09:27 PM, Tim Harvey wrote: > > > >> v4l2-compliance test results: >> - with the following kernel patches: >>v4l2-subdev: clear reserved fields >> . v4l2-subdev: without controls return -ENOTTY >> >>

[PATCH v8 1/7] v4l2-dv-timings: add v4l2_hdmi_colorimetry()

2018-02-06 Thread Tim Harvey
From: Hans Verkuil Add the v4l2_hdmi_colorimetry() function so we have a single function that determines the colorspace, YCbCr encoding, quantization range and transfer function from the InfoFrame data. Signed-off-by: Hans Verkuil Signed-off-by: Tim

[PATCH v8 0/7] TDA1997x HDMI video reciver

2018-02-06 Thread Tim Harvey
This is a v4l2 subdev driver supporting the TDA1997x HDMI video receiver. I've tested this on a Gateworks GW54xx/GW551x with an IMX6Q/IMX6DL which uses the TDA19971 with 16bits connected to the IMX6 CSI and single-lane I2S audio providing 2-channel audio. For this configuration I've tested both

[PATCH v8 2/7] media: v4l-ioctl: fix pad for VIDIOC_DV_TIMIGNS_CAP

2018-02-06 Thread Tim Harvey
Signed-off-by: Tim Harvey --- drivers/media/v4l2-core/v4l2-ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c b/drivers/media/v4l2-core/v4l2-ioctl.c index 7961499..5f3670d 100644 ---

Re: [PATCH v8 0/7] TDA1997x HDMI video reciver

2018-02-06 Thread Hans Verkuil
On 02/06/2018 09:27 PM, Tim Harvey wrote: > v4l2-compliance test results: > - with the following kernel patches: >v4l2-subdev: clear reserved fields > . v4l2-subdev: without controls return -ENOTTY > > v4l2-compliance SHA : b2f8f9049056eb6f9e028927dacb2c715a062df8 > Media Driver Info:

Re: [PATCH 5/5] add module parameters for default values

2018-02-06 Thread Hans Verkuil
On 02/06/2018 10:01 PM, Florian Echtler wrote: > To allow setting custom parameters for the sensor directly at startup, the > three primary controls are exposed as module parameters in this patch. > > Signed-off-by: Florian Echtler > --- > drivers/input/touchscreen/sur40.c

Re: Please help test the new v4l-subdev support in v4l2-compliance

2018-02-06 Thread Tim Harvey
On Tue, Feb 6, 2018 at 11:05 AM, Hans Verkuil wrote: > On 02/06/2018 07:48 PM, Tim Harvey wrote: >> On Mon, Feb 5, 2018 at 11:34 PM, Hans Verkuil wrote: >>> On 02/06/2018 08:16 AM, Tim Harvey wrote: On Sat, Feb 3, 2018 at 7:56 AM, Hans Verkuil

[PATCH 5/5] add module parameters for default values

2018-02-06 Thread Florian Echtler
To allow setting custom parameters for the sensor directly at startup, the three primary controls are exposed as module parameters in this patch. Signed-off-by: Florian Echtler --- drivers/input/touchscreen/sur40.c | 16 1 file changed, 16 insertions(+)

[PATCH 3/5] add panel register access functions

2018-02-06 Thread Florian Echtler
These functions provide write access to the internal LCD panel registers which also control the sensor. They can be used to disable the preprocessor, set the illumination brightness, and adjust gain/contrast (which are stored together in one register internally called "vsvideo"). Signed-off-by:

[PATCH 2/5] add control definitions

2018-02-06 Thread Florian Echtler
This patch adds parameter definitions for the four userspace controls that the SUR40 can currently provide. Signed-off-by: Florian Echtler --- drivers/input/touchscreen/sur40.c | 17 + 1 file changed, 17 insertions(+) diff --git

[PATCH 4/5] register control handlers using V4L2 control framework

2018-02-06 Thread Florian Echtler
This patch registers four standard control handlers using the corresponding V4L2 framework. Signed-off-by: Florian Echtler --- drivers/input/touchscreen/sur40.c | 51 +++ 1 file changed, 51 insertions(+) diff --git

Re: [PATCH v8 5/7] media: i2c: Add TDA1997x HDMI receiver driver

2018-02-06 Thread Hans Verkuil
On 02/06/2018 10:03 PM, Tim Harvey wrote: > On Tue, Feb 6, 2018 at 12:38 PM, Hans Verkuil wrote: >> On 02/06/2018 09:27 PM, Tim Harvey wrote: >>> Add support for the TDA1997x HDMI receivers. >>> >>> Cc: Hans Verkuil >>> Signed-off-by: Tim Harvey

Re: [PATCH 1/5] add missing blob structure field for tag id

2018-02-06 Thread Hans Verkuil
On 02/06/2018 10:01 PM, Florian Echtler wrote: > The SUR40 can recognize specific printed patterns directly in hardware; > this information (i.e. the pattern id) is present but currently unused > in the blob structure. > > Signed-off-by: Florian Echtler > --- >

Re: [PATCH v8 5/7] media: i2c: Add TDA1997x HDMI receiver driver

2018-02-06 Thread Tim Harvey
On Tue, Feb 6, 2018 at 12:38 PM, Hans Verkuil wrote: > On 02/06/2018 09:27 PM, Tim Harvey wrote: >> Add support for the TDA1997x HDMI receivers. >> >> Cc: Hans Verkuil >> Signed-off-by: Tim Harvey >> --- > > > >> +static int

Re: [PATCH v8 5/7] media: i2c: Add TDA1997x HDMI receiver driver

2018-02-06 Thread Hans Verkuil
On 02/06/2018 09:27 PM, Tim Harvey wrote: > Add support for the TDA1997x HDMI receivers. > > Cc: Hans Verkuil > Signed-off-by: Tim Harvey > --- > +static int tda1997x_get_dv_timings_cap(struct v4l2_subdev *sd, > +

[PATCH v8 5/7] media: i2c: Add TDA1997x HDMI receiver driver

2018-02-06 Thread Tim Harvey
Add support for the TDA1997x HDMI receivers. Cc: Hans Verkuil Signed-off-by: Tim Harvey --- v8: - fix available formats for tda19971 bt656 bus width >12 - support full range of input modes based on timings_cap - fix set_format (compliance) - fixed

[PATCH v8 6/7] ARM: dts: imx: Add TDA19971 HDMI Receiver to GW54xx

2018-02-06 Thread Tim Harvey
The GW54xx has a front-panel microHDMI connector routed to a TDA19971 which is connected the the IPU CSI when using IMX6Q. Signed-off-by: Tim Harvey --- v5: - remove leading 0 from unit address - add newline between property list and child node v4: no changes v3: no

[PATCH v8 3/7] MAINTAINERS: add entry for NXP TDA1997x driver

2018-02-06 Thread Tim Harvey
Signed-off-by: Tim Harvey --- MAINTAINERS | 8 1 file changed, 8 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 845fc25..439b500 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -13262,6 +13262,14 @@ T: git git://linuxtv.org/mkrufky/tuners.git S:

[PATCH v8 7/7] ARM: dts: imx: Add TDA19971 HDMI Receiver to GW551x

2018-02-06 Thread Tim Harvey
Signed-off-by: Tim Harvey --- v5: - add missing audmux config --- arch/arm/boot/dts/imx6qdl-gw551x.dtsi | 138 ++ 1 file changed, 138 insertions(+) diff --git a/arch/arm/boot/dts/imx6qdl-gw551x.dtsi

[PATCH v8 4/7] media: dt-bindings: Add bindings for TDA1997X

2018-02-06 Thread Tim Harvey
Acked-by: Rob Herring Acked-by: Sakari Ailus Signed-off-by: Tim Harvey --- v6: - replace copyright with SPDX tag - added Rob's ack v5: - added Sakari's ack v4: - move include/dt-bindings/media/tda1997x.h to bindings patch -

[PATCH v2] [RFC] add video controls for SUR40 driver

2018-02-06 Thread Florian Echtler
As discussed previously, here's a second iteration of my patch to add control functions for the SUR40 driver, now using the V4L2 control framework.

[PATCH 1/5] add missing blob structure field for tag id

2018-02-06 Thread Florian Echtler
The SUR40 can recognize specific printed patterns directly in hardware; this information (i.e. the pattern id) is present but currently unused in the blob structure. Signed-off-by: Florian Echtler --- drivers/input/touchscreen/sur40.c | 5 - 1 file changed, 4

Re: [PATCH 4/5] register control handlers using V4L2 control framework

2018-02-06 Thread Hans Verkuil
On 02/06/2018 10:01 PM, Florian Echtler wrote: > This patch registers four standard control handlers using the corresponding > V4L2 framework. > > Signed-off-by: Florian Echtler > --- > drivers/input/touchscreen/sur40.c | 51 > +++ > 1

[PATCH v3 8/8] platform: vivid-cec: use 64-bit arithmetic instead of 32-bit

2018-02-06 Thread Gustavo A. R. Silva
Add suffix ULL to constant 10 in order to give the compiler complete information about the proper arithmetic to use. Notice that this constant is used in a context that expects an expression of type u64 (64 bits, unsigned). The expression len * 10 * CEC_TIM_DATA_BIT_TOTAL is currently being

Re: [PATCH v2 8/8] platform: vivid-cec: use 64-bit arithmetic instead of 32-bit

2018-02-06 Thread Gustavo A. R. Silva
Quoting Hans Verkuil : On 02/05/18 22:54, Gustavo A. R. Silva wrote: Hi Hans, Quoting Hans Verkuil : On 02/05/2018 09:36 PM, Gustavo A. R. Silva wrote: Add suffix ULL to constant 10 in order to give the compiler complete information about the proper

[PATCH v3 0/8] use 64-bit arithmetic instead of 32-bit

2018-02-06 Thread Gustavo A. R. Silva
Add suffix LL and ULL to various constants in order to give the compiler complete information about the proper arithmetic to use. Such constants are used in contexts that expect expressions of type u64 (64 bits, unsigned) and s64 (64 bits, signed). The mentioned expressions are currently being

[PATCH v3 1/8] rtl2832: use 64-bit arithmetic instead of 32-bit in rtl2832_set_frontend

2018-02-06 Thread Gustavo A. R. Silva
Add suffix ULL to constant 7 in order to give the compiler complete information about the proper arithmetic to use. Notice that this constant is used in a context that expects an expression of type u64 (64 bits, unsigned). The expression dev->pdata->clk * 7 is currently being evaluated using

[PATCH v3 3/8] i2c: max2175: use 64-bit arithmetic instead of 32-bit

2018-02-06 Thread Gustavo A. R. Silva
Add suffix LL to constant 2 in order to give the compiler complete information about the proper arithmetic to use. Notice that this constant is used in a context that expects an expression of type s64 (64 bits, signed). The expression 2 * (clock_rate - abs_nco_freq) is currently being evaluated

[PATCH v3 2/8] dvb-frontends: ves1820: use 64-bit arithmetic instead of 32-bit

2018-02-06 Thread Gustavo A. R. Silva
Add suffix ULL to constant 10 in order to give the compiler complete information about the proper arithmetic to use. Notice that this constant is used in a context that expects an expression of type u64 (64 bits, unsigned). The expression fpxin = state->config->xin * 10 is currently being

[PATCH v3 4/8] i2c: ov9650: use 64-bit arithmetic instead of 32-bit

2018-02-06 Thread Gustavo A. R. Silva
Add suffix ULL to constants 1 and 100 in order to give the compiler complete information about the proper arithmetic to use. Notice that these constants are used in contexts that expect expressions of type u64 (64 bits, unsigned). The following expressions: (u64)(fi->interval.numerator *

[PATCH v3 6/8] rockchip/rga: use 64-bit arithmetic instead of 32-bit

2018-02-06 Thread Gustavo A. R. Silva
Cast p to dma_addr_t in order to avoid a potential integer overflow. This variable is being used in a context that expects an expression of type dma_addr_t (u64). The expression p << PAGE_SHIFT is currently being evaluated using 32-bit arithmetic. Addresses-Coverity-ID: 1458347 ("Unintentional

[PATCH v3 5/8] pci: cx88-input: use 64-bit arithmetic instead of 32-bit

2018-02-06 Thread Gustavo A. R. Silva
Add suffix LL to constant 100 in order to give the compiler complete information about the proper arithmetic to use. Notice that this constant is used in a context that expects an expression of type ktime_t (64 bits, signed). The expression ir->polling * 100 is currently being evaluated

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

2018-02-06 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 ---

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

2018-02-06 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.

[RFCv3 00/17] Request API, take three

2018-02-06 Thread Alexandre Courbot
As discussed yesterday, here is a rebase on the media master branch. A few minor fixes for typos have also slept in, but otherwise this is equivalent to v2. I expect to have the buffer queueing behavior fixed in the next version. Alexandre Courbot (9): media: add request API core and UAPI

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

2018-02-06 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

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

2018-02-06 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 ---

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

2018-02-06 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 +

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

2018-02-06 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

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

2018-02-06 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

Re: [PATCH v8 1/7] v4l2-dv-timings: add v4l2_hdmi_colorimetry()

2018-02-06 Thread Randy Dunlap
On 02/06/2018 12:27 PM, Tim Harvey wrote: > From: Hans Verkuil > > Add the v4l2_hdmi_colorimetry() function so we have a single function > that determines the colorspace, YCbCr encoding, quantization range and > transfer function from the InfoFrame data. > > Signed-off-by:

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

2018-02-06 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

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

2018-02-06 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

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

2018-02-06 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

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

2018-02-06 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

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

2018-02-06 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

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

2018-02-06 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

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

2018-02-06 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

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

2018-02-06 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

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

2018-02-06 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:

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

2018-02-06 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

cron job: media_tree daily build: ERRORS

2018-02-06 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: Wed Feb 7 05:00:18 CET 2018 media-tree git hash:273caa260035c03d89ad63d72d8cd3d9e5c5e3f1 media_build

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Geert Uytterhoeven
Hi Wolfram, On Mon, Feb 5, 2018 at 9:09 PM, Wolfram Sang wrote: > In one Renesas driver, I found a typo which turned an intended bit shift > ('<<') > into a comparison ('<'). Because this is a subtle issue, I looked tree wide > for > similar patterns. This

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Wolfram Sang
> I found two more using "git grep 'define.*0x[0-9a-f]* < '": I added '[0-9]\+' at the end of the regex to reduce the number of false positives... > drivers/net/can/m_can/m_can.c:#define RXFC_FWM_MASK (0x7f < > RXFC_FWM_SHIFT) > drivers/usb/gadget/udc/goku_udc.h:#define INT_EPnNAK(n) >

[PATCH v2] media: vb2: Fix videobuf2 to map correct area

2018-02-06 Thread Masami Hiramatsu
Fixes vb2_vmalloc_get_userptr() to ioremap correct area. Since the current code does ioremap the page address, if the offset > 0, it does not do ioremap the last page and results in kernel panic. This fixes to pass the size + offset to ioremap so that ioremap can map correct area. Also, this uses

Re: [PATCH v2] media: vb2: Fix videobuf2 to map correct area

2018-02-06 Thread Marek Szyprowski
Hi Masami, On 2018-02-06 09:02, Masami Hiramatsu wrote: Fixes vb2_vmalloc_get_userptr() to ioremap correct area. Since the current code does ioremap the page address, if the offset > 0, it does not do ioremap the last page and results in kernel panic. This fixes to pass the size + offset to

Re: [PATCH v5 03/16] media: rkisp1: Add user space ABI definitions

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > From: Jeffy Chen > > Add the header for userspace > > Signed-off-by: Jeffy Chen > Signed-off-by: Jacob Chen > --- > include/uapi/linux/rkisp1-config.h | 757 >

Re: [PATCH v5 04/16] media: rkisp1: add Rockchip MIPI Synopsys DPHY driver

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > From: Jacob Chen > > This commit adds a subdev driver for Rockchip MIPI Synopsys DPHY driver > > Signed-off-by: Jacob Chen > Signed-off-by: Shunqian Zheng >

Re: [PATCH v5 04/16] media: rkisp1: add Rockchip MIPI Synopsys DPHY driver

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > From: Jacob Chen > > This commit adds a subdev driver for Rockchip MIPI Synopsys DPHY driver > > Signed-off-by: Jacob Chen > Signed-off-by: Shunqian Zheng >

Re: [PATCH] media: ov5640: fix virtual_channel parameter permissions

2018-02-06 Thread Hugues FRUCHET
Hi Jacopo, Thanks for review, v2 sent ! BR, Hugues. On 02/01/2018 05:56 PM, jacopo mondi wrote: > Hi Hugues, > > On Thu, Feb 01, 2018 at 02:17:34PM +0100, Hugues Fruchet wrote: >> Fix module_param(virtual_channel) permissions. >> This problem was detected by checkpatch: >> $

Re: [PATCH v5 05/16] media: rkisp1: add Rockchip ISP1 subdev driver

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > From: Jacob Chen > > Add the subdev driver for rockchip isp1. > > Signed-off-by: Jacob Chen > Signed-off-by: Shunqian Zheng > Signed-off-by: Yichong Zhong

Re: [PATCH v5 06/16] media: rkisp1: add ISP1 statistics driver

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > From: Jacob Chen > > Add the capture video driver for rockchip isp1 statistics block. > > Signed-off-by: Jacob Chen > Signed-off-by: Shunqian Zheng > Signed-off-by:

Re: [PATCH v5 07/16] media: rkisp1: add ISP1 params driver

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > From: Jacob Chen > > Add the output video driver that accept params from userspace. > > Signed-off-by: Jacob Chen > Signed-off-by: Shunqian Zheng > Signed-off-by: Yichong

Re: [PATCH v5 01/16] media: videodev2.h, v4l2-ioctl: add rkisp1 meta buffer format

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > Add the Rockchip ISP1 specific processing parameter format > V4L2_META_FMT_RK_ISP1_PARAMS and metadata format > V4L2_META_FMT_RK_ISP1_STAT_3A for 3A. > > Signed-off-by: Shunqian Zheng > Signed-off-by: Jacob Chen

Re: [PATCH v5 02/16] media: doc: add document for rkisp1 meta buffer format

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > From: Jacob Chen > > This commit add docuemnt for rkisp1 meta buffer format > > Signed-off-by: Jacob Chen > --- > Documentation/media/uapi/v4l/meta-formats.rst | 2 ++ >

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Dan Carpenter
On Mon, Feb 05, 2018 at 09:09:57PM +0100, Wolfram Sang wrote: > In one Renesas driver, I found a typo which turned an intended bit shift > ('<<') > into a comparison ('<'). Because this is a subtle issue, I looked tree wide > for > similar patterns. This small patch series is the outcome. > >

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Julia Lawall
On Tue, 6 Feb 2018, Dan Carpenter wrote: > On Mon, Feb 05, 2018 at 09:09:57PM +0100, Wolfram Sang wrote: > > In one Renesas driver, I found a typo which turned an intended bit shift > > ('<<') > > into a comparison ('<'). Because this is a subtle issue, I looked tree wide > > for > > similar

[PATCH v2] media: ov5640: fix virtual_channel parameter permissions

2018-02-06 Thread Hugues Fruchet
Fix module_param(virtual_channel) permissions. This problem was detected by checkpatch: $ scripts/checkpatch.pl -f drivers/media/i2c/ov5640.c ERROR: Use 4 digit octal (0777) not decimal permissions #131: FILE: drivers/media/i2c/ov5640.c:131: +module_param(virtual_channel, int, 0); Also add an

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Dan Carpenter
On Tue, Feb 06, 2018 at 02:15:51PM +0100, Julia Lawall wrote: > > > On Tue, 6 Feb 2018, Dan Carpenter wrote: > > > On Mon, Feb 05, 2018 at 09:09:57PM +0100, Wolfram Sang wrote: > > > In one Renesas driver, I found a typo which turned an intended bit shift > > > ('<<') > > > into a comparison

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Julia Lawall
On Tue, 6 Feb 2018, Dan Carpenter wrote: > On Tue, Feb 06, 2018 at 02:15:51PM +0100, Julia Lawall wrote: > > > > > > On Tue, 6 Feb 2018, Dan Carpenter wrote: > > > > > On Mon, Feb 05, 2018 at 09:09:57PM +0100, Wolfram Sang wrote: > > > > In one Renesas driver, I found a typo which turned an

Re: [PATCH v5 08/16] media: rkisp1: add capture device driver

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > From: Jacob Chen > > This is the capture device interface driver that provides the v4l2 > user interface. Frames can be received from ISP1. > > Signed-off-by: Jacob Chen > Signed-off-by: Shunqian

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Wolfram Sang
Hi Julia, > and got the results below. I can make a version for the kernel shortly. It should probably take care of right-shifting, too? Thanks, Wolfram signature.asc Description: PGP signature

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Julia Lawall
On Tue, 6 Feb 2018, Wolfram Sang wrote: > Hi Julia, > > > and got the results below. I can make a version for the kernel shortly. > > It should probably take care of right-shifting, too? I did that too but got no results. Perhaps right shifting constants is pretty uncommon. I can put that

Re: [PATCH v5 09/16] media: rkisp1: add rockchip isp1 core driver

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > From: Jacob Chen > > Add the core driver for rockchip isp1. > > Signed-off-by: Jacob Chen > Signed-off-by: Shunqian Zheng > Signed-off-by: Yichong Zhong

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Wolfram Sang
> I did that too but got no results. Perhaps right shifting constants is > pretty uncommon. I can put that in the complete rule though. Please do. Even if rare, we would want this bug pointed out, right? :) signature.asc Description: PGP signature

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Dan Carpenter
That found 4 that I think Wolfram's grep missed. arch/um/drivers/vector_user.h |2 -- drivers/gpu/drm/mxsfb/mxsfb_regs.h|2 -- drivers/video/fbdev/mxsfb.c |2 -- include/drm/drm_scdc_helper.h |3 --- But it didn't find the two bugs

Re: [PATCH 0/4] tree-wide: fix comparison to bitshift when dealing with a mask

2018-02-06 Thread Julia Lawall
On Tue, 6 Feb 2018, Dan Carpenter wrote: > That found 4 that I think Wolfram's grep missed. > > arch/um/drivers/vector_user.h |2 -- > drivers/gpu/drm/mxsfb/mxsfb_regs.h|2 -- > drivers/video/fbdev/mxsfb.c |2 -- > include/drm/drm_scdc_helper.h

Re: [PATCH v5 00/16] Rockchip ISP1 Driver

2018-02-06 Thread Hans Verkuil
Hi Shunqian Zheng, Thank you for this patch series. My apologies for the late reply, it arrived in the middle of my Christmas vacation and completely forgot about it afterwards. I finished my review. Besides small stuff I have basically two things that need resolving: proof that the param/stats

Re: [PATCH v5 02/16] media: doc: add document for rkisp1 meta buffer format

2018-02-06 Thread Hans Verkuil
On 12/29/17 08:52, Shunqian Zheng wrote: > From: Jacob Chen > > This commit add docuemnt for rkisp1 meta buffer format > > Signed-off-by: Jacob Chen > --- > Documentation/media/uapi/v4l/meta-formats.rst | 2 ++ >