[PATCH] media:adv7180: Use dev_pm_ops

2013-04-13 Thread Lars-Peter Clausen
Use dev_pm_ops instead of the deprecated legacy suspend/resume callbacks. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 19 --- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/drivers/media/i2c/adv7180.c b/drivers/media/i2c

[PATCH] [media] tvp514x: Fix init seqeunce

2013-06-15 Thread Lars-Peter Clausen
client-driver-id_table will always point to the first entry in the device id table. So all devices will use the same init sequence. Use the id table entry that gets passed to the driver's probe() function to get the right init sequence. Signed-off-by: Lars-Peter Clausen l...@metafoo.de

Re: [Device-drivers-devel] [RFCv1 PATCH 0/7] Add adv7604/ad9389b drivers

2012-07-06 Thread Lars-Peter Clausen
On 07/05/2012 04:26 PM, Hans Verkuil wrote: Hi all, This RFC patch series builds on an earlier RFC patch series (posted only to linux-media) that adds support for DVI/HDMI/DP connectors to the V4L2 API. This earlier patch series is here:

Re: [PATCH] drivers/media/video/mx2_emmaprp.c: use devm_kzalloc and devm_clk_get

2012-08-06 Thread Lars-Peter Clausen
On 08/06/2012 04:26 PM, Dan Carpenter wrote: On Mon, Aug 06, 2012 at 05:23:23PM +0300, Dan Carpenter wrote: On Sat, Aug 04, 2012 at 08:23:27PM +0200, Julia Lawall wrote: @@ -922,12 +920,7 @@ static int emmaprp_probe(struct platform_device *pdev) platform_set_drvdata(pdev, pcdev); -

Re: [RFC 01/10] drm: ADV7511 i2c HDMI encoder driver

2013-09-04 Thread Lars-Peter Clausen
[...] + +/** + * enum adv7511_input_color_depth - Selects the input format color depth + * @ADV7511_INPUT_COLOR_DEPTH_8BIT: Input format color depth is 8 bits per channel + * @ADV7511_INPUT_COLOR_DEPTH_10BIT: Input format color dpeth is 10 bits per channel + *

[PATCH 4/8] drm: encoder_slave: Don't use i2c_client-driver

2013-09-29 Thread Lars-Peter Clausen
'to_i2c_driver(client-dev.driver)'. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/gpu/drm/drm_encoder_slave.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/drm_encoder_slave.c b/drivers/gpu/drm/drm_encoder_slave.c index 0cfb60f..d18b88b

[PATCH 6/8] ALSA: ppc: keywest: Don't use i2c_client-driver

2013-09-29 Thread Lars-Peter Clausen
The 'driver' field of the i2c_client struct is redundant and is going to be removed. Use 'to_i2c_driver(client-dev.driver)' instead to get direct access to the i2c_driver struct. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- sound/ppc/keywest.c | 4 ++-- 1 file changed, 2 insertions

[PATCH 7/8] ASoC: imx-wm8962: Don't use i2c_client-driver

2013-09-29 Thread Lars-Peter Clausen
The 'driver' field of the i2c_client struct is redundant and is going to be removed. Check i2c_client-dev.driver instead to see if a driver is bound to the device. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- sound/soc/fsl/imx-wm8962.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion

[PATCH 5/8] drm: nouveau: Don't use i2c_client-driver

2013-09-29 Thread Lars-Peter Clausen
The 'driver' field of the i2c_client struct is redundant and is going to be removed. Use 'to_i2c_driver(client-dev.driver)' instead to get direct access to the i2c_driver struct. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Cc: Martin Peres martin.pe...@labri.fr --- drivers/gpu/drm/nouveau

[PATCH 2/8] [media] exynos4-is: Don't use i2c_client-driver

2013-09-29 Thread Lars-Peter Clausen
The 'driver' field of the i2c_client struct is redundant and is going to be removed. The results of the expressions 'client-driver.driver-field' and 'client-dev.driver-field' are identical, so replace all occurrences of the former with the later. Signed-off-by: Lars-Peter Clausen l...@metafoo.de

[PATCH 8/8] i2c: Remove redundant 'driver' field from the i2c_client struct

2013-09-29 Thread Lars-Peter Clausen
struct. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/i2c/i2c-core.c | 21 - drivers/i2c/i2c-smbus.c | 10 ++ include/linux/i2c.h | 2 -- 3 files changed, 18 insertions(+), 15 deletions(-) diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c

[PATCH 0/8] i2c: Remove redundant driver field from the i2c_client struct

2013-09-29 Thread Lars-Peter Clausen
. - Lars Lars-Peter Clausen (8): [media] s5c73m3: Don't use i2c_client-driver [media] exynos4-is: Don't use i2c_client-driver [media] core: Don't use i2c_client-driver drm: encoder_slave: Don't use i2c_client-driver drm: nouveau: Don't use i2c_client-driver ALSA: ppc: keywest: Don't use

[PATCH 1/8] [media] s5c73m3: Don't use i2c_client-driver

2013-09-29 Thread Lars-Peter Clausen
The 'driver' field of the i2c_client struct is redundant and is going to be removed. The results of the expressions 'client-driver.driver-field' and 'client-dev.driver-field' are identical, so replace all occurrences of the former with the later. Signed-off-by: Lars-Peter Clausen l...@metafoo.de

[PATCH 3/8] [media] core: Don't use i2c_client-driver

2013-09-29 Thread Lars-Peter Clausen
The 'driver' field of the i2c_client struct is redundant and is going to be removed. The results of the expressions 'client-driver.driver-field' and 'client-dev.driver-field' are identical, so replace all occurrences of the former with the later. Signed-off-by: Lars-Peter Clausen l...@metafoo.de

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-26 Thread Lars-Peter Clausen
On 11/26/2013 10:28 PM, Valentine wrote: On 11/20/2013 07:53 PM, Valentine wrote: On 11/20/2013 07:42 PM, Hans Verkuil wrote: Hi Valentine, Hi Hans, Did you ever look at this adv7611 driver: https://github.com/Xilinx/linux-xlnx/commit/610b9d5de22ae7c0047c65a07e4afa42af2daa12 No, I

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-26 Thread Lars-Peter Clausen
On 11/26/2013 10:57 PM, Valentine wrote: [...] [...] I'd also appreciate your thoughts about the issues I've described, which have been replaced by [...] here. Those seem to be mostly issues that also apply to the adv7604 and should be fixed anyway. Hans knows the code much better than me

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-26 Thread Lars-Peter Clausen
On 11/26/2013 11:00 PM, Laurent Pinchart wrote: Hi Lars, On Tuesday 26 November 2013 22:43:32 Lars-Peter Clausen wrote: On 11/26/2013 10:28 PM, Valentine wrote: On 11/20/2013 07:53 PM, Valentine wrote: On 11/20/2013 07:42 PM, Hans Verkuil wrote: Hi Valentine, Hi Hans, Did you ever look

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-26 Thread Lars-Peter Clausen
On 11/26/2013 11:03 PM, Laurent Pinchart wrote: On Tuesday 26 November 2013 23:03:19 Lars-Peter Clausen wrote: On 11/26/2013 11:00 PM, Laurent Pinchart wrote: On Tuesday 26 November 2013 22:43:32 Lars-Peter Clausen wrote: On 11/26/2013 10:28 PM, Valentine wrote: On 11/20/2013 07:53 PM

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-27 Thread Lars-Peter Clausen
[...] I had to implement the IRQ handler since the soc_camera model does not use interrupt_service_routine subdevice callback and R-Car VIN knows nothing about adv7612 interrupt routed to a GPIO pin. So I had to schedule a workqueue and call adv7604_isr from there in case an interrupt

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-27 Thread Lars-Peter Clausen
On 11/27/2013 01:32 PM, Valentine wrote: On 11/27/2013 04:14 PM, Hans Verkuil wrote: Hi Laurent, On 11/27/13 12:39, Laurent Pinchart wrote: Hi Hans, On Wednesday 27 November 2013 09:21:22 Hans Verkuil wrote: On 11/26/2013 10:28 PM, Valentine wrote: On 11/20/2013 07:53 PM, Valentine wrote:

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-27 Thread Lars-Peter Clausen
On 11/27/2013 01:14 PM, Hans Verkuil wrote: [...] For our systems the adv7604 interrupts is not always hooked up to a gpio irq, instead a register has to be read to figure out which device actually produced the irq. Where is that register located ? Shouldn't it be modeled as an interrupt

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-27 Thread Lars-Peter Clausen
[...] The driver enables multiple interrupts on the chip, however, the adv7604_isr callback doesn't seem to handle them correctly. According to the docs: If an interrupt event occurs, and then a second interrupt event occurs before the system controller has cleared or masked the first

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-29 Thread Lars-Peter Clausen
On 11/29/2013 11:37 AM, Linus Walleij wrote: On Wed, Nov 27, 2013 at 5:40 PM, Laurent Pinchart laurent.pinch...@ideasonboard.com wrote: (CC'ing Linus Walleij, Wolfram Sang and LAKML) On Wednesday 27 November 2013 16:32:01 Valentine wrote: On 11/27/2013 04:14 PM, Hans Verkuil wrote: Yes, of

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-29 Thread Lars-Peter Clausen
On 11/29/2013 02:42 PM, Linus Walleij wrote: On Fri, Nov 29, 2013 at 11:45 AM, Lars-Peter Clausen l...@metafoo.de wrote: On 11/29/2013 11:37 AM, Linus Walleij wrote: (...) Specifically you should be able to request an IRQ from the irq_chip portions of the driver without first requesting

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-29 Thread Lars-Peter Clausen
On 11/29/2013 08:52 PM, Linus Walleij wrote: On Fri, Nov 29, 2013 at 2:48 PM, Lars-Peter Clausen l...@metafoo.de wrote: On 11/29/2013 02:42 PM, Linus Walleij wrote: On Fri, Nov 29, 2013 at 11:45 AM, Lars-Peter Clausen l...@metafoo.de wrote: As far as I understand it this already works more

Re: [PATCH V2] media: i2c: Add ADV761X support

2013-11-29 Thread Lars-Peter Clausen
On 11/26/2013 11:06 PM, Lars-Peter Clausen wrote: On 11/26/2013 11:03 PM, Laurent Pinchart wrote: On Tuesday 26 November 2013 23:03:19 Lars-Peter Clausen wrote: On 11/26/2013 11:00 PM, Laurent Pinchart wrote: On Tuesday 26 November 2013 22:43:32 Lars-Peter Clausen wrote: On 11/26/2013 10:28

Re: [PATCH] [media] tvp514x: Fix init seqeunce

2013-06-21 Thread Lars-Peter Clausen
On 06/21/2013 02:27 PM, Prabhakar Lad wrote: Hi Lars-Peter, On Sun, Jun 16, 2013 at 3:41 PM, Prabhakar Lad prabhakar.cse...@gmail.com wrote: Hi Lars-Peter, Thanks for the patch. On Sat, Jun 15, 2013 at 8:04 PM, Lars-Peter Clausen l...@metafoo.de wrote: client-driver-id_table will always

[PATCH v2] [media] tvp514x: Fix init seqeunce

2013-06-23 Thread Lars-Peter Clausen
client-driver-id_table will always point to the first entry in the device id table. So all devices will use the same init sequence. Use the id table entry that gets passed to the driver's probe() function to get the right init sequence. Signed-off-by: Lars-Peter Clausen l...@metafoo.de

Re: [PATCH 43/47] adv7604: Control hot-plug detect through a GPIO

2014-02-06 Thread Lars-Peter Clausen
On 02/05/2014 05:42 PM, Laurent Pinchart wrote: Replace the ADV7604-specific hotplug notifier with a GPIO to control the HPD pin directly instead of going through the bridge driver. Signed-off-by: Laurent Pinchart laurent.pinch...@ideasonboard.com This should probably use the new GPIO

Re: [PATCH 45/47] adv7604: Add DT support

2014-02-11 Thread Lars-Peter Clausen
On 02/11/2014 01:14 PM, Hans Verkuil wrote: On 02/11/14 13:08, Laurent Pinchart wrote: Hi Hans, On Tuesday 11 February 2014 10:23:03 Hans Verkuil wrote: On 02/05/14 17:42, Laurent Pinchart wrote: Parse the device tree node to populate platform data. Cc: devicet...@vger.kernel.org

Re: [PATCH 43/47] adv7604: Control hot-plug detect through a GPIO

2014-02-13 Thread Lars-Peter Clausen
On 02/13/2014 10:47 AM, Hans Verkuil wrote: On 02/11/14 13:03, Laurent Pinchart wrote: Hi Hans, On Tuesday 11 February 2014 11:09:31 Hans Verkuil wrote: On 02/05/14 17:42, Laurent Pinchart wrote: Replace the ADV7604-specific hotplug notifier with a GPIO to control the HPD pin directly

[PATCH 1/7] [media] adv7180: Fix remove order

2014-03-07 Thread Lars-Peter Clausen
The mutex is used in the subdev callbacks, so unregister the subdev before the mutex is destroyed. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/media/i2c/adv7180.c b/drivers/media

[PATCH 4/7] [media] adv7180: Remove duplicated probe error message

2014-03-07 Thread Lars-Peter Clausen
The device driver core already prints out a very similar message when a driver fails to probe. No need to print one in the driver itself. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/media/i2c/adv7180

[PATCH 6/7] [media] adv7180: Add support for async device registration

2014-03-07 Thread Lars-Peter Clausen
Add support for async device registration to the adv7180 driver. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/drivers/media/i2c/adv7180.c b/drivers/media/i2c/adv7180.c index c750aae..623cec5

[PATCH 2/7] [media] adv7180: Free control handler on remove()

2014-03-07 Thread Lars-Peter Clausen
Make sure to free the control handler when the device is removed. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/media/i2c/adv7180.c b/drivers/media/i2c/adv7180.c index 1a3622a..2359fd8 100644

[PATCH 5/7] [media] adv7180: Use threaded IRQ instead of IRQ + workqueue

2014-03-07 Thread Lars-Peter Clausen
The proper way to handle IRQs that need to be able to sleep in their IRQ handler is to use a threaded IRQ. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 33 + 1 file changed, 5 insertions(+), 28 deletions(-) diff --git

[PATCH 3/7] [media] adv7180: Remove unnecessary v4l2_device_unregister_subdev() from probe error path

2014-03-07 Thread Lars-Peter Clausen
The device can't possibly be registered at this point, so no need to to call v4l2_device_unregister_subdev(). Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/media/i2c/adv7180.c b/drivers/media/i2c

[PATCH 7/7] [media] adv7180: Add support for power down

2014-03-07 Thread Lars-Peter Clausen
The adv7180 has a low power mode in which the analog and the digital processing section are shut down. Implement the s_power callback to let bridge drivers put the part into low power mode when not needed. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 52

Re: [PATCH 7/7] [media] adv7180: Add support for power down

2014-03-10 Thread Lars-Peter Clausen
On 03/10/2014 03:37 PM, Hans Verkuil wrote: [...] + +static int adv7180_s_power(struct v4l2_subdev *sd, int on) +{ + struct adv7180_state *state = to_state(sd); + struct i2c_client *client = v4l2_get_subdevdata(sd); + int ret; + + ret =

Re: [PATCH 7/7] [media] adv7180: Add support for power down

2014-03-10 Thread Lars-Peter Clausen
On 03/10/2014 04:28 PM, Hans Verkuil wrote: On 03/10/2014 04:24 PM, Lars-Peter Clausen wrote: On 03/10/2014 03:37 PM, Hans Verkuil wrote: [...] + +static int adv7180_s_power(struct v4l2_subdev *sd, int on) +{ + struct adv7180_state *state = to_state(sd); + struct i2c_client *client

[PATCH v2] [media] adv7180: Add support for power down

2014-03-10 Thread Lars-Peter Clausen
The adv7180 has a low power mode in which the analog and the digital processing section are shut down. Implement the s_power callback to let bridge drivers put the part into low power mode when not needed. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- Changes since v1: * Set powered

Re: [PATCH] [media] adv7180: free an interrupt on failure paths in init_device()

2014-03-21 Thread Lars-Peter Clausen
On 03/14/2014 10:04 PM, Alexey Khoroshilov wrote: There is request_irq() in init_device(), but the interrupt is not removed on failure paths. The patch adds proper error handling. Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Alexey Khoroshilov

Re: [PATCH 2/2] gpio: gpiolib: set gpiochip_remove retval to void

2014-05-30 Thread Lars-Peter Clausen
On 05/30/2014 07:33 PM, David Daney wrote: On 05/30/2014 04:39 AM, Geert Uytterhoeven wrote: On Fri, May 30, 2014 at 1:30 PM, abdoulaye berthe berthe...@gmail.com wrote: --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c @@ -1263,10 +1263,9 @@ static void gpiochip_irqchip_remove(struct

Re: [GIT PULL for 3.16-rc1] updates and DT support for adv7604

2014-06-06 Thread Lars-Peter Clausen
On 06/06/2014 05:49 PM, Ben Dooks wrote: On 05/06/14 13:55, Mauro Carvalho Chehab wrote: Linus, Please pull from: git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media topic/adv76xx For adv7604 driver updates, including DT support. Can we use the adv7611 for the adv7612 with

[PATCH] [media] adv7604: Update recommended writes for the adv7611

2014-06-17 Thread Lars-Peter Clausen
enhance performance in some cases. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7604.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/media/i2c/adv7604.c b/drivers/media/i2c/adv7604.c index 1778d32..d4fa213 100644 --- a/drivers/media/i2c

Re: [PATCH] Add support for definition of register maps in DT in ADV7604

2014-08-27 Thread Lars-Peter Clausen
On 08/27/2014 03:03 PM, Hans Verkuil wrote: On 08/27/14 14:53, jean-michel.hautb...@vodalys.com wrote: From: Jean-Michel Hautbois jean-michel.hautb...@vodalys.com This patch adds support for DT parsing of register maps adresses. This allows multiple adv76xx devices on the same bus.

Re: [PATCH v2 1/2] Allow DT parsing of secondary devices

2014-08-29 Thread Lars-Peter Clausen
On 08/29/2014 05:15 PM, Jean-Michel Hautbois wrote: This is based on reg and reg-names in DT. Example: reg = 0x10 0x20 0x30; reg-names = main, io, test; This function will create dummy devices io and test with addresses 0x20 and 0x30 respectively. Signed-off-by: Jean-Michel Hautbois

Re: [PATCH v2 1/2] Allow DT parsing of secondary devices

2014-08-29 Thread Lars-Peter Clausen
On 08/29/2014 05:15 PM, Jean-Michel Hautbois wrote: This is based on reg and reg-names in DT. Example: reg = 0x10 0x20 0x30; reg-names = main, io, test; This function will create dummy devices io and test with addresses 0x20 and 0x30 respectively. Signed-off-by: Jean-Michel Hautbois

Re: [alsa-devel] [PATCH v2 5/6] sound/usb: pcm changes to use media token api

2014-10-16 Thread Lars-Peter Clausen
On 10/14/2014 04:58 PM, Shuah Khan wrote: [...] switch (cmd) { case SNDRV_PCM_TRIGGER_START: + err = media_get_audio_tkn(subs-dev-dev); + if (err == -EBUSY) { + dev_info(subs-dev-dev, %s device is busy\n, +

Re: [RFC] adp1653: Add device tree bindings for LED controller

2014-11-16 Thread Lars-Peter Clausen
On 11/16/2014 08:59 AM, Pavel Machek wrote: [...] + adp1653: adp1653@30 { + compatible = ad,adp1653; The Analog Devices vendor prefix is adi. -- To unsubscribe from this list: send the line unsubscribe linux-media in the body of a message to majord...@vger.kernel.org More

Re: [PATCH 1/2] [media] adv7180: Simplify PM hooks

2014-12-16 Thread Lars-Peter Clausen
On 12/16/2014 05:49 PM, Fabio Estevam wrote: The macro SIMPLE_DEV_PM_OPS already takes care of the CONFIG_PM_SLEEP=n case. I guess that's kind of debatable. The purpose of ifdef-ing stuff out is to decrease the driver size if PM support is disabled. With this change you are adding a rather

Re: [RFC PATCH 0/3] Introduce IIO interface for fingerprint sensors

2014-12-18 Thread Lars-Peter Clausen
Adding V4L folks to Cc for more input. On 12/08/2014 03:10 PM, Baluta, Teodora wrote: Hello, On Vi, 2014-12-05 at 02:15 +, Jonathan Cameron wrote: On 04/12/14 13:00, Teodora Baluta wrote: This patchset adds support for fingerprint sensors through the IIO interface. This way userspace

Re: [PATCH 1/2] regmap: pass map name to lockdep

2014-12-18 Thread Lars-Peter Clausen
On 12/18/2014 10:05 PM, Antti Palosaari wrote: lockdep complains recursive locking and deadlock when two different regmap instances are called in a nested order. That happen easily for example when both I2C client and muxed/repeater I2C adapter are using regmap. As a solution, pass regmap name

Re: [PATCH 1/2] regmap: pass map name to lockdep

2014-12-19 Thread Lars-Peter Clausen
On 12/19/2014 11:58 AM, Antti Palosaari wrote: On 12/18/2014 11:34 PM, Lars-Peter Clausen wrote: On 12/18/2014 10:05 PM, Antti Palosaari wrote: lockdep complains recursive locking and deadlock when two different regmap instances are called in a nested order. That happen easily for example when

Re: [PATCH 6/8] WmT: adv7604 driver compatibility

2015-02-03 Thread Lars-Peter Clausen
On 02/03/2015 04:24 PM, Hans Verkuil wrote: On 02/03/15 16:22, Laurent Pinchart wrote: Hi Hans, On Monday 02 February 2015 11:09:27 Hans Verkuil wrote: On 02/02/2015 11:01 AM, Laurent Pinchart wrote: On Sunday 01 February 2015 12:26:11 Guennadi Liakhovetski wrote: On a second thought: On

Re: [PATCH 21/66] rtl2830: implement own I2C locking

2015-02-02 Thread Lars-Peter Clausen
On 02/02/2015 09:33 PM, Wolfram Sang wrote: Ok, this may eventually work ok for now, but a further change at the I2C core could easily break it. So, we need to double check about such patch with the I2C maintainer. Jean, Are you ok with such patch? If so, please ack. Jean handed over I2C

Re: [PATCH v2 03/15] [media] adv7180: Use inline function instead of macro

2015-02-02 Thread Lars-Peter Clausen
On 02/02/2015 02:36 PM, Mauro Carvalho Chehab wrote: Em Fri, 23 Jan 2015 16:52:22 +0100 Lars-Peter Clausen l...@metafoo.de escreveu: Use a inline function instead of a macro for the container_of helper for getting the driver's state struct from a control. A inline function has the advantage

Re: [PATCH] media: i2c: ADV7604: Migrate to regmap

2015-02-03 Thread Lars-Peter Clausen
On 02/01/2015 11:08 AM, Jean-Michel Hautbois wrote: Looks mostly good, some things in addition to what Hans already said. [...] - -static s32 adv_smbus_write_byte_data(struct adv7604_state *state, -enum adv7604_page page, u8 command, -

Re: [PATCH 2/2] [media] adv7180: Remove the unneeded 'err' label

2015-01-16 Thread Lars-Peter Clausen
On 12/16/2014 05:49 PM, Fabio Estevam wrote: There is no need to jump to the 'err' label as we can simply return the error code directly and make the code shorter. Signed-off-by: Fabio Estevam fabio.este...@freescale.com Acked-by: Lars-Peter Clausen l...@metafoo.de -- To unsubscribe from

[PATCH 04/16] [media] adv7180: Cleanup register define naming

2015-01-13 Thread Lars-Peter Clausen
Consistently prefix register defines with ADV7180_REG. Also remove the ADI from register names, the ADV7180 prefix should provide enough of a namespace separation. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 105

[PATCH 16/16] [media] Add MAINTAINERS entry for the adv7180

2015-01-13 Thread Lars-Peter Clausen
Add myself as the maintainer for the adv7180 video subdev driver. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 4318f34..22bb77e 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -659,6

[PATCH 00/16] [media] adv7180: Add support for different chip

2015-01-13 Thread Lars-Peter Clausen
. The first half of this series contains fixes and cleanups while the second half adds new features and support for new chips. - Lars Lars-Peter Clausen (16): [media] adv7180: Do not request the IRQ again during resume [media] adv7180: Pass correct flags to request_threaded_irq() [media

[PATCH 03/16] [media] adv7180: Use inline function instead of macro

2015-01-13 Thread Lars-Peter Clausen
Use a inline function instead of a macro for the container_of helper for getting the driver's state struct from a control. A inline function has the advantage that it is more typesafe and nicer in general. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 13

[PATCH 09/16] [media] adv7180: Prepare for multi-chip support

2015-01-13 Thread Lars-Peter Clausen
format is configured slightly differs between some devices. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 187 ++-- 1 file changed, 130 insertions(+), 57 deletions(-) diff --git a/drivers/media/i2c/adv7180.c b/drivers

[PATCH 08/16] [media] adv7180: Consolidate video mode setting

2015-01-13 Thread Lars-Peter Clausen
We have basically the same code to set the video standard in init_device() and adv7180_s_std(). Factor this out into a common helper function. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 67 ++--- 1 file changed, 32

[PATCH 01/16] [media] adv7180: Do not request the IRQ again during resume

2015-01-13 Thread Lars-Peter Clausen
requested once. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/drivers/media/i2c/adv7180.c b/drivers/media/i2c/adv7180.c index bffe6eb..172e4a2 100644 --- a/drivers/media/i2c/adv7180.c

[PATCH 12/16] [media] adv7180: Add support for the adv7280-m/adv7281-m/adv7281-ma/adv7282-m

2015-01-13 Thread Lars-Peter Clausen
need to register a dummy device for it. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 170 +++- 1 file changed, 154 insertions(+), 16 deletions(-) diff --git a/drivers/media/i2c/adv7180.c b/drivers/media/i2c/adv7180.c

[PATCH 13/16] [media] adv7180: Add I2P support

2015-01-13 Thread Lars-Peter Clausen
for the format. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 156 +--- 1 file changed, 148 insertions(+), 8 deletions(-) diff --git a/drivers/media/i2c/adv7180.c b/drivers/media/i2c/adv7180.c index 868a677..4d789c7 100644

[PATCH 15/16] [media] adv7180: Add free run mode controls

2015-01-13 Thread Lars-Peter Clausen
* Free Running Color: Allows to select the color of the pattern Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 125 ++-- 1 file changed, 122 insertions(+), 3 deletions(-) diff --git a/drivers/media/i2c/adv7180.c b/drivers

[PATCH 10/16] [media] adv7180: Add support for the ad7182

2015-01-13 Thread Lars-Peter Clausen
This patch adds support for the adv7182 to the adv7180 driver. The adv7182 is similar to the adv7180, the main difference from the driver's point of view is how the video input and how the input format are selected. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180

[PATCH 14/16] [media] adv7180: Add fast switch support

2015-01-13 Thread Lars-Peter Clausen
to either enable or disable fast switch mode. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 29 + 1 file changed, 29 insertions(+) diff --git a/drivers/media/i2c/adv7180.c b/drivers/media/i2c/adv7180.c index 4d789c7..82c8296 100644

[PATCH 11/16] [media] adv7180: Add support for the adv7280/adv7281/adv7282

2015-01-13 Thread Lars-Peter Clausen
This patch adds support for the adv7280/adv7281/adv7282 devices to the adv7180 driver. They are very similar to the adv7182, the main difference from the drivers point of view are some different tuning constants for improved video performance. Signed-off-by: Lars-Peter Clausen l...@metafoo.de

[PATCH 06/16] [media] adv7180: Reset the device before initialization

2015-01-13 Thread Lars-Peter Clausen
Reset the device when initializing it so it is in a good known state and the assumed register settings matches the actual register settings. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 14 +- 1 file changed, 9 insertions(+), 5 deletions

[PATCH 05/16] [media] adv7180: Do implicit register paging

2015-01-13 Thread Lars-Peter Clausen
means that a register access is not a single atomic i2c_smbus_write_byte_data() or i2c_smbus_read_byte_data() call and we need to make sure that concurrent register access does not race against each other. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7180.c | 206

[PATCH 07/16] [media] adv7180: Add media controller support

2015-01-13 Thread Lars-Peter Clausen
the V4L2_SUBDEV_FL_HAS_DEVNODE flag for the subdevice so it is possible to create a subdevice device node. Since the driver now depends on VIDEO_V4L2_SUBDEV_API all drivers which select the driver need to depend on that symbol as well. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media

[PATCH 02/16] [media] adv7180: Pass correct flags to request_threaded_irq()

2015-01-13 Thread Lars-Peter Clausen
Most IRQ controllers support different types of interrupts. The adv7180 generates falling edge interrupts, so make sure to pass IRQF_TRIGGER_FALLING to request_threaded_irq() so the IRQ controller is configured for the correct mode. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers

Re: [PATCH 16/16] [media] Add MAINTAINERS entry for the adv7180

2015-01-13 Thread Lars-Peter Clausen
On 01/13/2015 01:55 PM, Mats Randgaard (matrandg) wrote: On 01/13/2015 01:01 PM, Lars-Peter Clausen wrote: Add myself as the maintainer for the adv7180 video subdev driver. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions

Re: [PATCH 00/16] [media] adv7180: Add support for different chip

2015-01-13 Thread Lars-Peter Clausen
On 01/13/2015 02:04 PM, Hans Verkuil wrote: Hi Lars, On 01/13/15 13:01, Lars-Peter Clausen wrote: The adv7180 is part of a larger family of chips which all implement different features from a feature superset. This patch series step by step extends the current adv7180 with features from

Re: [PATCH] media: i2c: adv7180: unregister the subdev in remove callback

2015-02-26 Thread Lars-Peter Clausen
On 02/26/2015 07:19 PM, Lad Prabhakar wrote: From: Lad, Prabhakar prabhakar.cse...@gmail.com this patch makes sure we unregister the subdev by calling v4l2_device_unregister_subdev() on remove callback. This was just removed a while ago, see commit 632f2b0db9da ([media] adv7180: Remove

[PATCH v2 09/15] [media] adv7180: Prepare for multi-chip support

2015-01-23 Thread Lars-Peter Clausen
format is configured slightly differs between some devices. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/i2c/adv7180.c | 187 ++-- 1 file changed, 130 insertions(+), 57 deletions(-) diff

[PATCH v2 06/15] [media] adv7180: Reset the device before initialization

2015-01-23 Thread Lars-Peter Clausen
Reset the device when initializing it so it is in a good known state and the assumed register settings matche the actual register settings. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/i2c/adv7180.c | 14 +- 1 file

[PATCH v2 08/15] [media] adv7180: Consolidate video mode setting

2015-01-23 Thread Lars-Peter Clausen
We have basically the same code to set the video standard in init_device() and adv7180_s_std(). Factor this out into a common helper function. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/i2c/adv7180.c | 67

[PATCH v2 11/15] [media] adv7180: Add support for the adv7280/adv7281/adv7282

2015-01-23 Thread Lars-Peter Clausen
This patch adds support for the adv7280/adv7281/adv7282 devices to the adv7180 driver. They are very similar to the adv7182, the main difference from the drivers point of view are some different tuning constants for improved video performance. Signed-off-by: Lars-Peter Clausen l...@metafoo.de

[PATCH v2 13/15] [media] adv7180: Add I2P support

2015-01-23 Thread Lars-Peter Clausen
for the format. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/i2c/adv7180.c | 156 +--- 1 file changed, 148 insertions(+), 8 deletions(-) diff --git a/drivers/media/i2c/adv7180.c b/drivers

[PATCH v2 02/15] [media] adv7180: Pass correct flags to request_threaded_irq()

2015-01-23 Thread Lars-Peter Clausen
Most IRQ controllers support different types of interrupts. The adv7180 generates falling edge interrupts, so make sure to pass IRQF_TRIGGER_FALLING to request_threaded_irq() so the IRQ controller is configured for the correct mode. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans

[PATCH v2 07/15] [media] adv7180: Add media controller support

2015-01-23 Thread Lars-Peter Clausen
the V4L2_SUBDEV_FL_HAS_DEVNODE flag for the subdevice so it is possible to create a subdevice device node. Since the driver now depends on VIDEO_V4L2_SUBDEV_API all drivers which select the driver need to depend on that symbol as well. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans

[PATCH v2 05/15] [media] adv7180: Do implicit register paging

2015-01-23 Thread Lars-Peter Clausen
means that a register access is not a single atomic i2c_smbus_write_byte_data() or i2c_smbus_read_byte_data() call and we need to make sure that concurrent register access does not race against each other. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil hans.verk

[PATCH v2 10/15] [media] adv7180: Add support for the adv7182

2015-01-23 Thread Lars-Peter Clausen
This patch adds support for the adv7182 to the adv7180 driver. The adv7182 is similar to the adv7180, the main difference from the driver's point of view is how the video input and how the input format are selected. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil

[PATCH v2 00/15] [media] adv7180: Add support for more chip variants

2015-01-23 Thread Lars-Peter Clausen
. The first half of this series contains fixes and cleanups while the second half adds new features and support for new chips Lars-Peter Clausen (15): [media] adv7180: Do not request the IRQ again during resume [media] adv7180: Pass correct flags to request_threaded_irq() [media] adv7180

[PATCH v2 04/15] [media] adv7180: Cleanup register define naming

2015-01-23 Thread Lars-Peter Clausen
Consistently prefix register defines with ADV7180_REG. Also remove the ADI from register names, the ADV7180 prefix should provide enough of a namespace separation. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/i2c/adv7180.c

[PATCH v2 15/15] [media] Add MAINTAINERS entry for the adv7180

2015-01-23 Thread Lars-Peter Clausen
Add myself as the maintainer for the adv7180 video subdev driver. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil hans.verk...@cisco.com --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 4318f34..22bb77e 100644

[PATCH v2 12/15] [media] adv7180: Add support for the adv7280-m/adv7281-m/adv7281-ma/adv7282-m

2015-01-23 Thread Lars-Peter Clausen
need to register a dummy device for it. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/i2c/adv7180.c | 170 +++- 1 file changed, 154 insertions(+), 16 deletions(-) diff --git a/drivers

[PATCH v2 14/15] [media] adv7180: Add fast switch support

2015-01-23 Thread Lars-Peter Clausen
to either enable or disable fast switch mode. Signed-off-by: Lars-Peter Clausen l...@metafoo.de -- Changes since v1: * Reserve private control range and use it for the fast switch control * Changed control name from Fast switch to Fast Switch --- drivers/media/i2c/adv7180.c| 29

[PATCH v2 01/15] [media] adv7180: Do not request the IRQ again during resume

2015-01-23 Thread Lars-Peter Clausen
requested once. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/i2c/adv7180.c | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/drivers/media/i2c/adv7180.c b/drivers/media/i2c/adv7180.c index bffe6eb

[PATCH v2 03/15] [media] adv7180: Use inline function instead of macro

2015-01-23 Thread Lars-Peter Clausen
Use a inline function instead of a macro for the container_of helper for getting the driver's state struct from a control. A inline function has the advantage that it is more typesafe and nicer in general. Signed-off-by: Lars-Peter Clausen l...@metafoo.de Acked-by: Hans Verkuil hans.verk

Re: [PATCH 4/5] [media] adv7604: Deliver resolution change events to userspace

2015-06-25 Thread Lars-Peter Clausen
On 06/25/2015 12:21 PM, Sakari Ailus wrote: Hi Lars-Peter, On Wed, Jun 24, 2015 at 06:50:30PM +0200, Lars-Peter Clausen wrote: Use the new v4l2_subdev_notify_event() helper function to deliver the resolution change event to userspace via the v4l2 subdev event queue as well as to the bridge

Re: [PATCH 3/5] [media] Add helper function for subdev event notifications

2015-06-25 Thread Lars-Peter Clausen
On 06/25/2015 11:47 AM, Sakari Ailus wrote: Hi Lars-Peter, On Wed, Jun 24, 2015 at 06:50:29PM +0200, Lars-Peter Clausen wrote: Add a new helper function called v4l2_subdev_notify_event() which will deliver the specified event to both the v4l2 subdev event queue as well as to the notify

[PATCH 3/5] [media] Add helper function for subdev event notifications

2015-06-24 Thread Lars-Peter Clausen
drivers. Combining both into the same function avoids boilerplate code in subdev drivers. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/v4l2-core/v4l2-subdev.c | 18 ++ include/media/v4l2-subdev.h | 4 2 files changed, 22 insertions(+) diff --git

[PATCH 4/5] [media] adv7604: Deliver resolution change events to userspace

2015-06-24 Thread Lars-Peter Clausen
and often necessary for video pipelines where there is no direct 1-to-1 relationship between the subdevice converter and the video capture device and hence it does not make sense to directly forward the event to the video capture device node. Signed-off-by: Lars-Peter Clausen l...@metafoo.de

[PATCH 2/5] [media] adv7842: Add support for control event notifications

2015-06-24 Thread Lars-Peter Clausen
Allow userspace applications to subscribe to control change events. This can e.g. be used to monitor the 5V detect control to be notified when a source is connected or disconnected. Signed-off-by: Lars-Peter Clausen l...@metafoo.de --- drivers/media/i2c/adv7842.c | 5 - 1 file changed, 4

  1   2   >