Re: ioremap_uc() followed by set_memory_wc() - burrying MTRR

2015-04-21 Thread Luis R. Rodriguez
On Wed, Apr 15, 2015 at 05:58:14PM -0700, Andy Lutomirski wrote: On Wed, Apr 15, 2015 at 4:59 PM, Andy Walls awa...@md.metrocast.net wrote: On Wed, 2015-04-15 at 16:42 -0700, Andy Lutomirski wrote: On Wed, Apr 15, 2015 at 3:38 PM, Andy Walls awa...@md.metrocast.net wrote: IMO the

[RFCv2 PATCH 12/15] v4l2-device: add v4l2_device_req_queue

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com The v4l2_device_req_queue() function is a helper that can be used as the req_queue callback in simple cases: it will walk over all registered video_devices and call vb2_qbuf_request() for each video device. Signed-off-by: Hans Verkuil

[RFCv2 PATCH 07/15] v4l2-ctrls: implement delete request(s)

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/v4l2-core/v4l2-ctrls.c | 42 include/media/v4l2-ctrls.h | 1 + 2 files changed, 43 insertions(+) diff --git

[RFCv2 PATCH 14/15] v4l2-ctrls: add REQ_KEEP flag

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com Experimental: I am still not certain whether this is desired or not. Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/v4l2-core/v4l2-ctrls.c | 28 drivers/media/v4l2-core/v4l2-ioctl.c | 9 -

[RFCv2 PATCH 11/15] v4l2-device: keep track of registered video_devices

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com In order to efficiently handle V4L2_REQ_CMD_QUEUE we need to know which video_device structs are registered for the given v4l2_device struct. So create a list of vdevs in v4l2_device and add/remove each video_device there as it is

[RFCv2 PATCH 15/15] Documentation: add v4l2-requests.txt

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com Add documentation about requests. Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- Documentation/video4linux/v4l2-requests.txt | 233 1 file changed, 233 insertions(+) create mode 100644

[RFCv2 PATCH 08/15] v4l2-ctrls: add VIDIOC_REQUEST_CMD

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/v4l2-core/v4l2-ctrls.c | 60 -- drivers/media/v4l2-core/v4l2-dev.c| 1 + drivers/media/v4l2-core/v4l2-ioctl.c | 81 ++-

[RFCv2 PATCH 13/15] vivid: add request support for video capture.

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com In order to test the request API in applications we add request support to vivid. The brightness, contrast, saturation and hue controls now can be used in requests. Those were chosen because the test pattern generator supports those controls and will

[RFCv2 PATCH 05/15] v4l2-ctrls: add request support

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/v4l2-core/v4l2-ctrls.c | 228 ++- drivers/media/v4l2-core/v4l2-ioctl.c | 8 ++ include/media/v4l2-ctrls.h | 20 +++ 3 files changed, 228

[RFCv2 PATCH 06/15] v4l2-ctrls: add function to apply a request.

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com Drivers need to be able to select a specific request. Add a new function that can be used to apply a given request. Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/v4l2-core/v4l2-ctrls.c | 112 +--

[RFCv2 PATCH 03/15] videodev2.h: add request field to v4l2_buffer.

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com When queuing buffers allow for passing the request ID that should be associated with this buffer. Split the u32 reserved2 field into two u16 fields, one for request, one with the old reserved2 name. Signed-off-by: Hans Verkuil hans.verk...@cisco.com ---

[RFCv2 PATCH 04/15] vb2: add allow_requests flag

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com The driver has to set allow_requests explicitly in order to allow queuing or preparing buffers for a specific request ID. Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/v4l2-core/videobuf2-core.c | 5 +

[RFCv2 PATCH 01/15] videodev2.h: add max_reqs to struct v4l2_query_ext_ctrl

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com struct v4l2_query_ext_ctrl is extended with a new 'max_reqs' field to store the maximum number of outstanding requests that contain this control. Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/v4l2-core/v4l2-ioctl.c | 5 +++--

[RFCv2 PATCH 02/15] videodev2.h: add request to v4l2_ext_controls

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com The ctrl_class is fairly pointless when used with drivers that use the control framework: you can just fill in 0 and it will just work fine. There are still some old unconverted drivers that do not support 0 and instead want the control class there. The

[RFCv2 PATCH 00/15] Request API

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com This patch series adds support for the request API (formerly called the configuration store API: http://www.spinics.net/lists/linux-media/msg81024.html). This second version takes into account all the feedback I received from various people and from the

[RFCv2 PATCH 10/15] vb2: add helper function to queue request-specific buffer.

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com The vb2_qbuf_request() function will queue any buffers for the given request that are in state PREPARED. Useful when drivers have to implement the req_queue callback. Signed-off-by: Hans Verkuil hans.verk...@cisco.com ---

[RFCv2 PATCH 09/15] v4l2: add initial V4L2_REQ_CMD_QUEUE support

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com Add the V4L2_REQ_CMD_QUEUE command and the req_queue callback to struct v4l2_device. Call it if set from v4l2-ioctl.c and v4l2-subdev.c. Make sure in v4l2-ioctl.c to unlock any current lock first (and relock afterwards). That way req_queue is called with

Re: [patch] [media] v4l: xilinx: harmless buffer overflow

2015-04-21 Thread Laurent Pinchart
Hi Dan, Thank you for the patch. On Tuesday 21 April 2015 12:31:10 Dan Carpenter wrote: My static checker warns that the name of the port can be 15 characters when you consider the NUL terminator and that's one more than the 14 characters in name[]. Maybe it's an off-by-one? It's unlikely

[patch] [media] v4l: xilinx: harmless buffer overflow

2015-04-21 Thread Dan Carpenter
My static checker warns that the name of the port can be 15 characters when you consider the NUL terminator and that's one more than the 14 characters in name[]. Maybe it's an off-by-one? It's unlikely that we hit the limit and even if we do the overflow will only affect one of the two bytes of

Re: [PATCH 2/2] gspca: sn9c2028: Add gain and autogain controls Genius Videocam Live v2

2015-04-21 Thread Vasily Khoruzhick
Hi Hans, On Tue, Apr 21, 2015 at 5:32 PM, Hans de Goede hdego...@redhat.com wrote: diff --git a/drivers/media/usb/gspca/sn9c2028.h b/drivers/media/usb/gspca/sn9c2028.h index 8fd1d3e..6f20c0f 100644 --- a/drivers/media/usb/gspca/sn9c2028.h +++ b/drivers/media/usb/gspca/sn9c2028.h @@ -21,8

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

2015-04-21 Thread Mauro Carvalho Chehab
Hi Linus, Please pull from: git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media tags/media/v4.1-2 For: - A new frontend driver for new ATSC devices: lgdt3306a - A new sensor driver: ov2659 - a new platform driver: xilinx - The m88ts2022 tuner driver was merged at ts2020

Re: [PATCH 1/2] gspca: sn9c2028: Add support for Genius Videocam Live v2

2015-04-21 Thread Vasily Khoruzhick
Hi Hans, On Tue, Apr 21, 2015 at 5:21 PM, Hans de Goede hdego...@redhat.com wrote: @@ -128,7 +129,7 @@ static int sn9c2028_long_command(struct gspca_dev *gspca_dev, u8 *command) status = -1; for (i = 0; i 256 status 2; i++) status =

[PATCHv3 3/4] vim2m: drop format description

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com The format description is now filled in by the core, so we can drop this in this virtual m2m driver. Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/platform/vim2m.c | 4 1 file changed, 4 deletions(-) diff --git

[PATCHv3 2/4] v4l2-pci-skeleton: drop format description

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com The format description is now filled in by the core, so we can drop this in this skeleton driver. Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- Documentation/video4linux/v4l2-pci-skeleton.c | 2 -- 1 file changed, 2 deletions(-) diff --git

[PATCHv3 1/4] v4l2-ioctl: fill in the description for VIDIOC_ENUM_FMT

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com The descriptions used in drivers for the formats returned with ENUM_FMT are all over the place. So instead allow the core to fill them in if the driver didn't. This allows drivers to drop the description and flags. Based on an earlier patch from Philipp

[PATCHv3 4/4] vivid: drop format description

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com The format description is now filled in by the core, so we can drop this in this virtual driver. Signed-off-by: Hans Verkuil hans.verk...@cisco.com --- drivers/media/platform/vivid/vivid-core.h | 1 - drivers/media/platform/vivid/vivid-vid-cap.c

[PATCHv3 0/4] Fill in the description for VIDIOC_ENUM_FMT

2015-04-21 Thread Hans Verkuil
From: Hans Verkuil hans.verk...@cisco.com This patch series is identical to https://patchwork.linuxtv.org/patch/29080/ but it removes the description from the skeleton driver and the virtual drivers. Since those are basically reference drivers it makes sense to update those first. I'll make a

[GIT PULL FOR v4.2] Replace most duplicate video ops by pad ops

2015-04-21 Thread Hans Verkuil
These patches replace most duplicate video ops by their pad ops counterparts. The only remaining duplicate ops deal with cropping and selection, and I want to be able to test that first. I have difficulty doing that, but I am expecting hardware in the near future that should enable me to do this

[GIT PULL FOR v4.2] Fill in the description for VIDIOC_ENUM_FMT

2015-04-21 Thread Hans Verkuil
Ensure standard format descriptions by filling it in in the v4l2 core. Currently these descriptions are all over the place and every driver dreams up its own description. That's not good. Regards, Hans The following changes since commit e183201b9e917daf2530b637b2f34f1d5afb934d:

Re: [PATCH 1/2] gspca: sn9c2028: Add support for Genius Videocam Live v2

2015-04-21 Thread Hans de Goede
Hi Vasily, Thanks for the patches. On 19-04-15 20:52, Vasily Khoruzhick wrote: Signed-off-by: Vasily Khoruzhick anars...@gmail.com --- drivers/media/usb/gspca/sn9c2028.c | 120 - 1 file changed, 119 insertions(+), 1 deletion(-) diff --git

Re: [PATCH 2/2] gspca: sn9c2028: Add gain and autogain controls Genius Videocam Live v2

2015-04-21 Thread Hans de Goede
Hi, On 19-04-15 20:52, Vasily Khoruzhick wrote: Autogain algorithm is very simple, if average luminance is low - increase gain, if it's high - decrease gain. Gain granularity is low enough for this algo to stabilize quickly. Signed-off-by: Vasily Khoruzhick anars...@gmail.com ---

Re: OMAP3 ISP previewer Y10 to UYVY conversion

2015-04-21 Thread Chris Whittenburg
On Fri, Apr 17, 2015 at 4:39 AM, Laurent Pinchart laurent.pinch...@ideasonboard.com wrote: Hi Chris, On Thursday 16 April 2015 13:05:30 Chris Whittenburg wrote: On Tue, Apr 7, 2015 at 10:51 AM, Laurent Pinchart wrote: Black level compensation is applied by the CCDC before writing raw frames

Re: [PATCH v2 1/5] media/v4l2-ctrls: volatiles should not generate CH_VALUE

2015-04-21 Thread Ricardo Ribalda Delgado
Hello Laurent On Tue, Apr 21, 2015 at 7:44 PM, Laurent Pinchart laurent.pinch...@ideasonboard.com wrote: Hi Ricardo, Thank you for the patch, and sorry for the late review (so late that the patch has already been merged). No worries. On Friday 20 March 2015 14:30:46 Ricardo Ribalda

Re: ioremap_uc() followed by set_memory_wc() - burrying MTRR

2015-04-21 Thread Andy Lutomirski
On Tue, Apr 21, 2015 at 3:08 PM, Luis R. Rodriguez mcg...@suse.com wrote: On Tue, Apr 21, 2015 at 3:02 PM, Luis R. Rodriguez mcg...@suse.com wrote: Andy, can we live without MTRR support on this driver for future kernels? This would only leave ipath as the only offending driver. Sorry to be

Re: ioremap_uc() followed by set_memory_wc() - burrying MTRR

2015-04-21 Thread Luis R. Rodriguez
On Tue, Apr 21, 2015 at 3:02 PM, Luis R. Rodriguez mcg...@suse.com wrote: Andy, can we live without MTRR support on this driver for future kernels? This would only leave ipath as the only offending driver. Sorry to be clear, can we live with removal of write-combining on this driver? Luis --

Re: ioremap_uc() followed by set_memory_wc() - burrying MTRR

2015-04-21 Thread Luis R. Rodriguez
On Wed, Apr 15, 2015 at 01:42:47PM -0700, Andy Lutomirski wrote: On Mon, Apr 13, 2015 at 10:49 AM, Luis R. Rodriguez mcg...@suse.com wrote: c) ivtv: the driver does not have the PCI space mapped out separately, and in fact it actually does not do the math for the framebuffer, instead it

cron job: media_tree daily build: ERRORS

2015-04-21 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 Apr 22 04:00:22 CEST 2015 git branch: test git hash: e183201b9e917daf2530b637b2f34f1d5afb934d gcc

Re: ioremap_uc() followed by set_memory_wc() - burrying MTRR

2015-04-21 Thread Jason Gunthorpe
On Wed, Apr 22, 2015 at 01:39:07AM +0200, Luis R. Rodriguez wrote: Mike, do you think the time is right to just remove the iPath driver? With PAT now being default the driver effectively won't work with write-combining on modern kernels. Even if systems are old they likely had PAT support,

Re: ioremap_uc() followed by set_memory_wc() - burrying MTRR

2015-04-21 Thread Jason Gunthorpe
On Wed, Apr 22, 2015 at 12:46:01AM +0200, Luis R. Rodriguez wrote: are talking about annotating the qib driver as known to be broken without PAT and since the ipath driver needs considerable work to be ported to use PAT (the This only seems to be true for one of the chips that driver

Re: ioremap_uc() followed by set_memory_wc() - burrying MTRR

2015-04-21 Thread Luis R. Rodriguez
On Tue, Apr 21, 2015 at 04:57:32PM -0600, Jason Gunthorpe wrote: On Wed, Apr 22, 2015 at 12:46:01AM +0200, Luis R. Rodriguez wrote: are talking about annotating the qib driver as known to be broken without PAT and since the ipath driver needs considerable work to be ported to use PAT

Re: ioremap_uc() followed by set_memory_wc() - burrying MTRR

2015-04-21 Thread Luis R. Rodriguez
On Tue, Apr 21, 2015 at 06:51:26PM -0400, Andy Walls wrote: Sorry for the top post; mobile work email account. Luis, You do the changes to remove MTTR and point me to your dev repo and branch. Also point me to the new functions/primitives I'll need. There is nothing new actually needed

Re: ioremap_uc() followed by set_memory_wc() - burrying MTRR

2015-04-21 Thread Luis R. Rodriguez
On Wed, Apr 15, 2015 at 09:07:37PM -0400, Andy Walls wrote: On Thu, 2015-04-16 at 01:58 +0200, Luis R. Rodriguez wrote: Hey Andy, thanks for your review, adding Hyong-Youb Kim for review of the full range ioremap_wc() idea below. On Wed, Apr 15, 2015 at 06:38:51PM -0400, Andy Walls

Re: OMAP3 ISP previewer Y10 to UYVY conversion

2015-04-21 Thread Laurent Pinchart
Hi Chris, On Tuesday 21 April 2015 11:04:14 Chris Whittenburg wrote: On Fri, Apr 17, 2015 at 4:39 AM, Laurent Pinchart wrote: On Thursday 16 April 2015 13:05:30 Chris Whittenburg wrote: On Tue, Apr 7, 2015 at 10:51 AM, Laurent Pinchart wrote: Black level compensation is applied by the CCDC