[PATCH] staging: atomisp: use k{v}zalloc instead of k{v}alloc and memset

2017-03-13 Thread Daeseok Youn
If the atomisp_kernel_zalloc() has "true" as a second parameter, it tries to allocate zeroing memory from kmalloc(vmalloc) and memset. But using kzalloc is rather than kmalloc followed by memset with 0. (vzalloc is for same reason with kzalloc) And also atomisp_kernel_malloc() can be used with

Re: [PATCH v4 14/36] [media] v4l2-mc: add a function to inherit controls from a pipeline

2017-03-13 Thread Russell King - ARM Linux
On Mon, Mar 13, 2017 at 11:44:50AM +0100, Hans Verkuil wrote: > On 03/12/2017 06:56 PM, Steve Longerbeam wrote: > > In summary, I do like the media framework, it's a good abstraction of > > hardware pipelines. It does require a lot of system level knowledge to > > configure, but as I said that is

Conditional sys/sysmacros.h inclusion

2017-03-13 Thread Ingo Feinerer
Hi, please find attached a diff that makes the inclusion of the sys/sysmacros.h header file conditional. I noticed it on OpenBSD which has no sys/sysmacros.h, so compilation fails there. Best regards, Ingo diff --git a/configure.ac b/configure.ac index f3269728a..ae58da377 100644 ---

Re: [PATCH v4 14/36] [media] v4l2-mc: add a function to inherit controls from a pipeline

2017-03-13 Thread Sakari Ailus
Hi Mauro, On Sat, Mar 11, 2017 at 08:25:49AM -0300, Mauro Carvalho Chehab wrote: > Em Sat, 11 Mar 2017 00:37:14 +0200 > Sakari Ailus escreveu: > > > Hi Mauro (and others), > > > > On Fri, Mar 10, 2017 at 12:53:42PM -0300, Mauro Carvalho Chehab wrote: > > > Em Fri, 10 Mar

Re: [PATCH v5 15/39] [media] v4l2: add a frame interval error event

2017-03-13 Thread Hans Verkuil
On 03/13/2017 11:45 AM, Russell King - ARM Linux wrote: > On Mon, Mar 13, 2017 at 11:02:34AM +0100, Hans Verkuil wrote: >> On 03/11/2017 07:14 PM, Steve Longerbeam wrote: >>> The event must be user visible, otherwise the user has no indication >>> the error, and can't correct it by stream restart.

Re: [RFC PATCH 00/12] Ion cleanup in preparation for moving out of staging

2017-03-13 Thread Mark Brown
On Mon, Mar 13, 2017 at 10:54:33AM +, Brian Starkey wrote: > On Sun, Mar 12, 2017 at 02:34:14PM +0100, Benjamin Gaignard wrote: > > Another point is how can we put secure rules (like selinux policy) on > > heaps since all the allocations > > go to the same device (/dev/ion) ? For example,

[PATCH 4/6] [media] cx231xx-audio: fix init error path

2017-03-13 Thread Johan Hovold
Make sure to release the snd_card also on a late allocation error. Fixes: e0d3bafd0258 ("V4L/DVB (10954): Add cx231xx USB driver") Cc: stable # 2.6.30 Cc: Sri Deevi Signed-off-by: Johan Hovold ---

Re: [PATCH v4 29/36] media: imx: mipi-csi2: enable setting and getting of frame rates

2017-03-13 Thread Sakari Ailus
Hi Philipp, On Tue, Feb 21, 2017 at 09:50:23AM +0100, Philipp Zabel wrote: ... > > > Then there's the issue where, if you have this setup: > > > > > > camera --> csi2 receiver --> csi --> capture > > > > > > and the "csi" subdev can skip frames, you need to know (a) at the CSI > > > sink pad

[PATCH 6/6] [media] gspca: konica: add missing endpoint sanity check

2017-03-13 Thread Johan Hovold
Make sure to check the number of endpoints to avoid accessing memory beyond the endpoint array should a device lack the expected endpoints. Note that, as far as I can tell, the gspca framework has already made sure there is at least one endpoint in the current alternate setting so there should be

[PATCH 2/6] [media] usbvision: fix NULL-deref at probe

2017-03-13 Thread Johan Hovold
Make sure to check the number of endpoints to avoid dereferencing a NULL-pointer or accessing memory beyond the endpoint array should a malicious device lack the expected endpoints. Fixes: 2a9f8b5d25be ("V4L/DVB (5206): Usbvision: set alternate interface modification") Cc: stable

[PATCH 3/6] [media] cx231xx-cards: fix NULL-deref at probe

2017-03-13 Thread Johan Hovold
Make sure to check the number of endpoints to avoid dereferencing a NULL-pointer or accessing memory beyond the endpoint array should a malicious device lack the expected endpoints. Fixes: e0d3bafd0258 ("V4L/DVB (10954): Add cx231xx USB driver") Cc: stable # 2.6.30

[PATCH 1/6] [media] dib0700: fix NULL-deref at probe

2017-03-13 Thread Johan Hovold
Make sure to check the number of endpoints to avoid dereferencing a NULL-pointer should a malicious device lack endpoints. Fixes: c4018fa2e4c0 ("[media] dib0700: fix RC support on Hauppauge Nova-TD") Cc: stable # 3.16 Cc: Mauro Carvalho Chehab

[PATCH 5/6] [media] cx231xx-audio: fix NULL-deref at probe

2017-03-13 Thread Johan Hovold
Make sure to check the number of endpoints to avoid dereferencing a NULL-pointer or accessing memory beyond the endpoint array should a malicious device lack the expected endpoints. Fixes: e0d3bafd0258 ("V4L/DVB (10954): Add cx231xx USB driver") Cc: stable # 2.6.30

Re: [PATCH] staging: atomisp: use k{v}zalloc instead of k{v}alloc and memset

2017-03-13 Thread Dan Carpenter
On Mon, Mar 13, 2017 at 07:54:21PM +0900, Daeseok Youn wrote: > If the atomisp_kernel_zalloc() has "true" as a second parameter, it > tries to allocate zeroing memory from kmalloc(vmalloc) and memset. > But using kzalloc is rather than kmalloc followed by memset with 0. > (vzalloc is for same

Re: [PATCH v4 14/36] [media] v4l2-mc: add a function to inherit controls from a pipeline

2017-03-13 Thread Hans Verkuil
On 03/13/2017 11:58 AM, Russell King - ARM Linux wrote: > On Mon, Mar 13, 2017 at 11:44:50AM +0100, Hans Verkuil wrote: >> On 03/12/2017 06:56 PM, Steve Longerbeam wrote: >>> In summary, I do like the media framework, it's a good abstraction of >>> hardware pipelines. It does require a lot of

Re: [PATCH v5 15/39] [media] v4l2: add a frame interval error event

2017-03-13 Thread Russell King - ARM Linux
On Mon, Mar 13, 2017 at 11:02:34AM +0100, Hans Verkuil wrote: > On 03/11/2017 07:14 PM, Steve Longerbeam wrote: > > The event must be user visible, otherwise the user has no indication > > the error, and can't correct it by stream restart. > > In that case the driver can detect this and call

Re: [PATCHv5 07/16] atmel-isi: remove dependency of the soc-camera framework

2017-03-13 Thread Nicolas Ferre
Le 13/03/2017 à 12:43, Hans Verkuil a écrit : > On 03/12/2017 05:44 PM, Guennadi Liakhovetski wrote: >> Hi Hans, >> >> Thanks for the patch. Why hasn't this patch been CCed to Josh Wu? Is he >> still at Atmel? Adding to CC to check. > > To the best of my knowledge Josh no longer works for

Re: [PATCH v4 14/36] [media] v4l2-mc: add a function to inherit controls from a pipeline

2017-03-13 Thread Hans Verkuil
On 03/12/2017 06:56 PM, Steve Longerbeam wrote: > > > On 03/11/2017 11:37 PM, Russell King - ARM Linux wrote: >> On Sat, Mar 11, 2017 at 07:31:18PM -0800, Steve Longerbeam wrote: >>> >>> >>> On 03/11/2017 10:59 AM, Russell King - ARM Linux wrote: On Sat, Mar 11, 2017 at 10:54:55AM -0800,

Re: [PATCH v4 14/36] [media] v4l2-mc: add a function to inherit controls from a pipeline

2017-03-13 Thread Russell King - ARM Linux
On Mon, Mar 13, 2017 at 08:42:15AM -0300, Mauro Carvalho Chehab wrote: > I don't have myself any hardware with i.MX6. Yet, I believe that > a low cost board like SolidRun Hummingboard - with comes with a > CSI interface compatible with RPi camera modules - will likely > attract users who need to

[PATCH 0/6] [media] fix missing endpoint sanity checks

2017-03-13 Thread Johan Hovold
This series fixes a number of NULL-pointer dereferences (and related issues) due to missing endpoint sanity checks that can be triggered by a malicious USB device. Johan Johan Hovold (6): [media] dib0700: fix NULL-deref at probe [media] usbvision: fix NULL-deref at probe [media]

[PATCH 2/2] vb2: convert vb2_vmarea_handler refcount from atomic_t to refcount_t

2017-03-13 Thread Sakari Ailus
From: Elena Reshetova Use refcount_t to manage the refcount to the memory type specific buffer videobuf2 buffer implementations. refcount_t is better suitable for the purpose than atomic_t. Signed-off-by: Elena Reshetova Signed-off-by: Hans

[PATCH 1/2] cx88: convert struct cx88_core.refcount from atomic_t to refcount_t

2017-03-13 Thread Sakari Ailus
From: Elena Reshetova refcount_t is better suitable for counting references than atomic_t. Signed-off-by: Elena Reshetova Signed-off-by: Hans Liljestrand Signed-off-by: Kees Cook Signed-off-by:

[PATCH 0/2] V4L2 driver refcount_t conversion

2017-03-13 Thread Sakari Ailus
Hi folks, These two patches convert a few V4L2 driver from using atomic_t for refcounts to the newly added refcount_t. The previous version of the patches were posted by Elena to the list and the review comments given to those patches have been addressed. In particular, - One of the patches was

Re: [RFC PATCH 00/12] Ion cleanup in preparation for moving out of staging

2017-03-13 Thread Brian Starkey
On Sun, Mar 12, 2017 at 02:34:14PM +0100, Benjamin Gaignard wrote: 2017-03-09 18:38 GMT+01:00 Laura Abbott : On 03/09/2017 02:00 AM, Benjamin Gaignard wrote: 2017-03-06 17:04 GMT+01:00 Daniel Vetter : On Mon, Mar 06, 2017 at 11:58:05AM +0100, Mark Brown

[PATCH] staging: atomisp: potential underflow in atomisp_get_metadata_by_type()

2017-03-13 Thread Dan Carpenter
md_type is an enum. On my tests, GCC treats it as unsigned but according to the C standard it's an implementation dependant thing so we should check for negatives. Fixes: a49d25364dfb ("staging/atomisp: Add support for the Intel IPU v2") Signed-off-by: Dan Carpenter

[bug report] staging/atomisp: Add support for the Intel IPU v2

2017-03-13 Thread Dan Carpenter
Hello Alan Cox, The patch a49d25364dfb: "staging/atomisp: Add support for the Intel IPU v2" from Feb 17, 2017, leads to the following static checker warning: drivers/staging/media/atomisp/platform/intel-mid/atomisp_gmin_platform.c:676 gmin_get_config_var() warn: impossible

Re: [PATCHv5 07/16] atmel-isi: remove dependency of the soc-camera framework

2017-03-13 Thread Hans Verkuil
On 03/12/2017 05:44 PM, Guennadi Liakhovetski wrote: > Hi Hans, > > Thanks for the patch. Why hasn't this patch been CCed to Josh Wu? Is he > still at Atmel? Adding to CC to check. To the best of my knowledge Josh no longer works for Atmel/Microchip, and Songjun took over. > > A general

Re: [PATCH v4 14/36] [media] v4l2-mc: add a function to inherit controls from a pipeline

2017-03-13 Thread Mauro Carvalho Chehab
Em Mon, 13 Mar 2017 10:58:42 + Russell King - ARM Linux escreveu: > On Mon, Mar 13, 2017 at 11:44:50AM +0100, Hans Verkuil wrote: > > On 03/12/2017 06:56 PM, Steve Longerbeam wrote: > > > In summary, I do like the media framework, it's a good abstraction of > > >

Re: [PATCH v3 4/6] drm: bridge: dw-hdmi: Switch to V4L bus format and encodings

2017-03-13 Thread Jose Abreu
Hi Neil, On 09-03-2017 14:27, Jose Abreu wrote: > Hi Neil, > > > On 08-03-2017 12:12, Neil Armstrong wrote: >> Hi Jose, >> >> It seems here that we only have the RGB444<->YUV444 8bit tables, from the >> Amlogic >> source I have the following for 10bit, 12bit and 16bit for itu601 : >> >> static

Re: [PATCH v4 29/36] media: imx: mipi-csi2: enable setting and getting of frame rates

2017-03-13 Thread Russell King - ARM Linux
On Mon, Mar 13, 2017 at 03:16:48PM +0200, Sakari Ailus wrote: > The vast majority of existing drivers do not implement them nor the user > space expects having to set them. Making that mandatory would break existing > user space. > > In addition, that does not belong to link validation either:

Re: [PATCH] staging: atomisp: use k{v}zalloc instead of k{v}alloc and memset

2017-03-13 Thread DaeSeok Youn
2017-03-13 23:07 GMT+09:00 DaeSeok Youn : > 2017-03-13 20:51 GMT+09:00 Dan Carpenter : >> On Mon, Mar 13, 2017 at 07:54:21PM +0900, Daeseok Youn wrote: >>> If the atomisp_kernel_zalloc() has "true" as a second parameter, it >>> tries to allocate

Re: [PATCH] staging: atomisp: use k{v}zalloc instead of k{v}alloc and memset

2017-03-13 Thread DaeSeok Youn
2017-03-13 20:51 GMT+09:00 Dan Carpenter : > On Mon, Mar 13, 2017 at 07:54:21PM +0900, Daeseok Youn wrote: >> If the atomisp_kernel_zalloc() has "true" as a second parameter, it >> tries to allocate zeroing memory from kmalloc(vmalloc) and memset. >> But using kzalloc is

[PATCH v7 6/9] media: venus: venc: add video encoder files

2017-03-13 Thread Stanimir Varbanov
This adds encoder part of the driver plus encoder controls. Signed-off-by: Stanimir Varbanov --- drivers/media/platform/qcom/venus/venc.c | 1231 drivers/media/platform/qcom/venus/venc.h | 23 +

[PATCH v7 7/9] media: venus: hfi: add Host Firmware Interface (HFI)

2017-03-13 Thread Stanimir Varbanov
This is the implementation of HFI. It is charged with the responsibility to comunicate with the firmware through an interface commands and messages. - hfi.c has interface functions used by the core, decoder and encoder parts to comunicate with the firmware. For example there are functions for

[PATCH v7 8/9] media: venus: hfi: add Venus HFI files

2017-03-13 Thread Stanimir Varbanov
Here is the implementation of Venus video accelerator low-level functionality. It contanins code which setup the registers and startup uthe processor, allocate and manipulates with the shared memory used for sending commands and receiving messages. Signed-off-by: Stanimir Varbanov

[PATCH v7 4/9] media: venus: adding core part and helper functions

2017-03-13 Thread Stanimir Varbanov
* core.c has implemented the platform dirver methods, file operations and v4l2 registration. * helpers.c has implemented common helper functions for: - buffer management - vb2_ops and functions for format propagation, - functions for allocating and freeing buffers for internal

[PATCH v7 9/9] media: venus: enable building of Venus video driver

2017-03-13 Thread Stanimir Varbanov
This adds Venus driver Makefile and changes v4l2 platform Makefile/Kconfig in order to enable building of the driver. Signed-off-by: Stanimir Varbanov --- drivers/media/platform/Kconfig | 14 ++ drivers/media/platform/Makefile|

[PATCH v7 5/9] media: venus: vdec: add video decoder files

2017-03-13 Thread Stanimir Varbanov
This consists of video decoder implementation plus decoder controls. Signed-off-by: Stanimir Varbanov --- drivers/media/platform/qcom/venus/vdec.c | 1091 drivers/media/platform/qcom/venus/vdec.h | 23 +

[PATCH v7 0/9] Qualcomm video decoder/encoder driver

2017-03-13 Thread Stanimir Varbanov
Hi all, Here is seventh version of the patch-set - no functional changes in v4l2 APIs. The changes since v6 are. * changes in DT binding document - moved memory-region DT property in video-codec node - see 2/9. * improved recovery mechanism. * fixed various issues found during

[PATCH v7 1/9] media: v4l2-mem2mem: extend m2m APIs for more accurate buffer management

2017-03-13 Thread Stanimir Varbanov
this add functions for: - remove buffers from src/dst queue by index - remove exact buffer from src/dst queue also extends m2m API to iterate over a list of src/dst buffers in safely and non-safely manner. Signed-off-by: Stanimir Varbanov ---

Re: [PATCH v5 15/39] [media] v4l2: add a frame interval error event

2017-03-13 Thread Steve Longerbeam
On 03/13/2017 03:53 AM, Hans Verkuil wrote: On 03/13/2017 11:45 AM, Russell King - ARM Linux wrote: On Mon, Mar 13, 2017 at 11:02:34AM +0100, Hans Verkuil wrote: On 03/11/2017 07:14 PM, Steve Longerbeam wrote: The event must be user visible, otherwise the user has no indication the error,

[PATCH v7 3/9] MAINTAINERS: Add Qualcomm Venus video accelerator driver

2017-03-13 Thread Stanimir Varbanov
Add an entry for Venus video encoder/decoder accelerator driver. Signed-off-by: Stanimir Varbanov --- MAINTAINERS | 8 1 file changed, 8 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 83a42ef1d1a7..cce2537d4d00 100644 --- a/MAINTAINERS +++

[PATCH v7 2/9] doc: DT: venus: binding document for Qualcomm video driver

2017-03-13 Thread Stanimir Varbanov
Add binding document for Venus video encoder/decoder driver Cc: Rob Herring Cc: devicet...@vger.kernel.org Acked-by: Rob Herring Signed-off-by: Stanimir Varbanov --- .../devicetree/bindings/media/qcom,venus.txt | 107

Re: [PATCH v5 15/39] [media] v4l2: add a frame interval error event

2017-03-13 Thread Hans Verkuil
On 03/13/2017 06:06 PM, Steve Longerbeam wrote: > > > On 03/13/2017 03:53 AM, Hans Verkuil wrote: >> On 03/13/2017 11:45 AM, Russell King - ARM Linux wrote: >>> On Mon, Mar 13, 2017 at 11:02:34AM +0100, Hans Verkuil wrote: On 03/11/2017 07:14 PM, Steve Longerbeam wrote: > The event must

Re: [PATCH v5 00/39] i.MX Media Driver

2017-03-13 Thread Russell King - ARM Linux
On Sun, Mar 12, 2017 at 09:26:41PM -0700, Steve Longerbeam wrote: > On 03/12/2017 01:22 PM, Russell King - ARM Linux wrote: > >What I had was this patch for your v3. I never got to testing your > >v4 because of the LP-11 problem. > > > >In v5, you've changed to propagate the ipu_cpmem_set_image()

Re: [PATCH] v4l: soc-camera: Remove videobuf1 support

2017-03-13 Thread Hans Verkuil
On 03/12/2017 01:06 PM, Guennadi Liakhovetski wrote: Hi Laurent, Thanks for the patch. I just checked in the current media/master, there are still 2 users of vb1: sh_mobile_ceu_camera.c and atmel-isi.c. I understand, that they are about to be removed either completely or out of soc-camera,

Re: [PATCH v5 00/39] i.MX Media Driver

2017-03-13 Thread Russell King - ARM Linux
On Mon, Mar 13, 2017 at 08:16:25AM +, Russell King - ARM Linux wrote: > On Sun, Mar 12, 2017 at 09:26:41PM -0700, Steve Longerbeam wrote: > > On 03/12/2017 01:22 PM, Russell King - ARM Linux wrote: > > >What I had was this patch for your v3. I never got to testing your > > >v4 because of the

Re: [PATCH v5 21/39] UAPI: Add media UAPI Kbuild file

2017-03-13 Thread Hans Verkuil
On 03/11/2017 07:20 PM, Steve Longerbeam wrote: > > > On 03/11/2017 05:49 AM, Sakari Ailus wrote: >> Hi Steve, >> >> On Thu, Mar 09, 2017 at 08:53:01PM -0800, Steve Longerbeam wrote: >>> Add an empty UAPI Kbuild file for media UAPI headers. >>> >>> Signed-off-by: Steve Longerbeam

Re: [PATCH v2 12/23] MAINTAINERS: Add file patterns for media device tree bindings

2017-03-13 Thread Mauro Carvalho Chehab
Em Mon, 13 Mar 2017 08:43:52 +0100 Geert Uytterhoeven escreveu: > Hi Mauro, > > On Mon, Mar 13, 2017 at 2:02 AM, Mauro Carvalho Chehab > wrote: > > Em Sun, 12 Mar 2017 14:16:56 +0100 > > Geert Uytterhoeven escreveu: > > >

Re: [PATCH v5 15/39] [media] v4l2: add a frame interval error event

2017-03-13 Thread Hans Verkuil
On 03/11/2017 07:14 PM, Steve Longerbeam wrote: > > > On 03/11/2017 03:39 AM, Hans Verkuil wrote: >> On 10/03/17 19:37, Steve Longerbeam wrote: >>> Hi Hans, >>> >>> On 03/10/2017 04:03 AM, Hans Verkuil wrote: On 10/03/17 05:52, Steve Longerbeam wrote: > Add a new FRAME_INTERVAL_ERROR

Re: [PATCH] [media] vcodev: mediatek: add missing include in JPEG decoder driver

2017-03-13 Thread Hans Verkuil
On 03/12/2017 09:13 PM, Jérémy Lefaure wrote: > The driver uses kzalloc and kfree functions. So it should include > linux/slab.h. This header file is implicitly included by v4l2-common.h > if CONFIG_SPI is enabled. But when it is disabled, slab.h is not > included. In this case, the driver does

Re: [PATCH v2 12/23] MAINTAINERS: Add file patterns for media device tree bindings

2017-03-13 Thread Geert Uytterhoeven
Hi Mauro, On Mon, Mar 13, 2017 at 2:02 AM, Mauro Carvalho Chehab wrote: > Em Sun, 12 Mar 2017 14:16:56 +0100 > Geert Uytterhoeven escreveu: > >> Submitters of device tree binding documentation may forget to CC >> the subsystem maintainer if this is

Re: [PATCH] [media] atmel-isc: fix off-by-one comparison and out of bounds read issue

2017-03-13 Thread Hans Verkuil
On 03/13/2017 06:53 AM, Wu, Songjun wrote: > > > On 3/9/2017 18:57, Hans Verkuil wrote: >> Hi Songjun, >> >> On 08/03/17 03:25, Wu, Songjun wrote: >>> Hi Colin, >>> >>> Thank you for your comment. >>> It is a bug, will be fixed in the next patch. >> >> Do you mean that you will provide a new

Re: [PATCH] v4l: soc-camera: Remove videobuf1 support

2017-03-13 Thread Guennadi Liakhovetski
On Mon, 13 Mar 2017, Hans Verkuil wrote: > On 03/12/2017 01:06 PM, Guennadi Liakhovetski wrote: > > Hi Laurent, > > > > Thanks for the patch. I just checked in the current media/master, there > > are still 2 users of vb1: sh_mobile_ceu_camera.c and atmel-isi.c. I > > understand, that they are

Re: [PATCH] [media] atmel-isc: fix off-by-one comparison and out of bounds read issue

2017-03-13 Thread Wu, Songjun
On 3/13/2017 17:25, Hans Verkuil wrote: On 03/13/2017 06:53 AM, Wu, Songjun wrote: On 3/9/2017 18:57, Hans Verkuil wrote: Hi Songjun, On 08/03/17 03:25, Wu, Songjun wrote: Hi Colin, Thank you for your comment. It is a bug, will be fixed in the next patch. Do you mean that you will

Re: [PATCH] [media] atmel-isc: fix off-by-one comparison and out of bounds read issue

2017-03-13 Thread Hans Verkuil
On 03/13/2017 10:32 AM, Wu, Songjun wrote: > > > On 3/13/2017 17:25, Hans Verkuil wrote: >> On 03/13/2017 06:53 AM, Wu, Songjun wrote: >>> >>> >>> On 3/9/2017 18:57, Hans Verkuil wrote: Hi Songjun, On 08/03/17 03:25, Wu, Songjun wrote: > Hi Colin, > > Thank you for

Re: [PATCH] docs-rst: Don't use explicit Makefile rules to build SVG and DOT files

2017-03-13 Thread Jonathan Corbet
On Thu, 9 Mar 2017 15:14:52 -0300 Mauro Carvalho Chehab wrote: > Now that we have an extension to handle images, use it. Applied, finally - thanks. jon

Re: [PATCH v5 00/39] i.MX Media Driver

2017-03-13 Thread Steve Longerbeam
er, I meant I will integrate this patch. And verify/fix possible breakage for non-bayer passthrough. Steve On 03/13/2017 02:30 AM, Russell King - ARM Linux wrote: On Mon, Mar 13, 2017 at 08:16:25AM +, Russell King - ARM Linux wrote: On Sun, Mar 12, 2017 at 09:26:41PM -0700, Steve

Re: [PATCH v5 00/39] i.MX Media Driver

2017-03-13 Thread Steve Longerbeam
On 03/13/2017 01:16 AM, Russell King - ARM Linux wrote: On Sun, Mar 12, 2017 at 09:26:41PM -0700, Steve Longerbeam wrote: On 03/12/2017 01:22 PM, Russell King - ARM Linux wrote: What I had was this patch for your v3. I never got to testing your v4 because of the LP-11 problem. In v5,

Re: [PATCH v4 29/36] media: imx: mipi-csi2: enable setting and getting of frame rates

2017-03-13 Thread Steve Longerbeam
On 03/13/2017 06:55 AM, Philipp Zabel wrote: On Mon, 2017-03-13 at 13:27 +, Russell King - ARM Linux wrote: On Mon, Mar 13, 2017 at 03:16:48PM +0200, Sakari Ailus wrote: The vast majority of existing drivers do not implement them nor the user space expects having to set them. Making that

[PATCH] staging: atomisp: fix missing break in switch statement

2017-03-13 Thread Colin King
From: Colin Ian King I believe there is a missing break in the switch statement for case V4L2_CID_FOCUS_STATUS as the current fall-through looks suspect to me. Detected by CoverityScan, CID#1416580 ("Missing break in switch") Signed-off-by: Colin Ian King

Re: [PATCH] staging: atomisp: potential underflow in atomisp_get_metadata_by_type()

2017-03-13 Thread Alan Cox
On Mon, 2017-03-13 at 15:34 +0300, Dan Carpenter wrote: > md_type is an enum.  On my tests, GCC treats it as unsigned but > according to the C standard it's an implementation dependant thing so > we > should check for negatives. Can do but the kernel assumes GNU C everywhere else. Acked-by: Alan

Re: [PATCH] staging: atomisp: use k{v}zalloc instead of k{v}alloc and memset

2017-03-13 Thread Alan Cox
On Mon, 2017-03-13 at 19:54 +0900, Daeseok Youn wrote: > If the atomisp_kernel_zalloc() has "true" as a second parameter, it > tries to allocate zeroing memory from kmalloc(vmalloc) and memset. > But using kzalloc is rather than kmalloc followed by memset with 0. > (vzalloc is for same reason with

[PATCH] staging/atomisp: remove redundant null check on frame

2017-03-13 Thread Colin King
From: Colin Ian King There is no need to perform a null check on frame as there is an earlier null check check and return hence making the null check redundant. Remove it. Detected by CoverityScan, CID#1416563 ("Logically Dead Code") Signed-off-by: Colin Ian King

Re: [RFC PATCH 10/13] mm: Introduce first class virtual address spaces

2017-03-13 Thread Till Smejkal
Hi Vineet, On Mon, 13 Mar 2017, Vineet Gupta wrote: > I've not looked at the patches closely (or read the references paper fully > yet), > but at first glance it seems on ARC architecture, we can can potentially > use/leverage this mechanism to implement the shared TLB entries. Before anyone >

Re: [RFC PATCH 10/13] mm: Introduce first class virtual address spaces

2017-03-13 Thread Vineet Gupta
+CC Ingo, tglx Hi Till, On 03/13/2017 03:14 PM, Till Smejkal wrote: > Introduce a different type of address spaces which are first class citizens > in the OS. That means that the kernel now handles two types of AS, those > which are closely coupled with a process and those which aren't. While

Re: [PATCH] staging: atomisp: use k{v}zalloc instead of k{v}alloc and memset

2017-03-13 Thread DaeSeok Youn
2017-03-14 2:54 GMT+09:00 Alan Cox : > > On Mon, 2017-03-13 at 19:54 +0900, Daeseok Youn wrote: > > If the atomisp_kernel_zalloc() has "true" as a second parameter, it > > tries to allocate zeroing memory from kmalloc(vmalloc) and memset. > > But using kzalloc is rather than

Re: [PATCH v4 14/36] [media] v4l2-mc: add a function to inherit controls from a pipeline

2017-03-13 Thread Mauro Carvalho Chehab
Hi Sakari, I started preparing a long argument about it, but gave up in favor of a simpler one. Em Mon, 13 Mar 2017 14:46:22 +0200 Sakari Ailus escreveu: > Drivers are written to support hardware, not particular use case. No, it is just the reverse: drivers and hardware

cron job: media_tree daily build: ERRORS

2017-03-13 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: Tue Mar 14 05:00:31 CET 2017 media-tree git hash:700ea5e0e0dd70420a04e703ff264cc133834cba media_build

[RFC 07/10] [media] v4l: add support to BUF_QUEUED event

2017-03-13 Thread Gustavo Padovan
From: Gustavo Padovan Implement the needed pieces to let userspace subscribe for V4L2_EVENT_BUF_QUEUED events. Videobuf2 will queue the event for the DQEVENT ioctl. Signed-off-by: Gustavo Padovan ---

[RFC 09/10] [media] vb2: add infrastructure to support out-fences

2017-03-13 Thread Gustavo Padovan
From: Gustavo Padovan Add vb2_setup_out_fence() and the needed members to struct vb2_buffer. Signed-off-by: Gustavo Padovan --- drivers/media/v4l2-core/videobuf2-core.c | 31 +++

[RFC 02/10] [media] vb2: split out queueing from vb_core_qbuf()

2017-03-13 Thread Gustavo Padovan
From: Gustavo Padovan In order to support explicit synchronization we need to divide vb2_core_qbuf() in two parts one, to be executed before the fence signals and another one after that, to do the actual queueing of the buffer. Signed-off-by: Gustavo Padovan

[RFC 10/10] [media] vb2: add out-fence support to QBUF

2017-03-13 Thread Gustavo Padovan
From: Gustavo Padovan If V4L2_BUF_FLAG_OUT_FENCE flag is present on the QBUF call we create an out_fence for the buffer and return it to userspace on the fence_fd field. The fence is signaled on buffer_done(), when the job on the buffer is finished. TODO: clean

[RFC 03/10] [media] vb2: add in-fence support to QBUF

2017-03-13 Thread Gustavo Padovan
From: Gustavo Padovan Receive in-fence from userspace and support for waiting on them before queueing the buffer for the driver. Signed-off-by: Gustavo Padovan --- drivers/media/Kconfig| 1 +

[RFC 04/10] [media] uvc: enable subscriptions to other events

2017-03-13 Thread Gustavo Padovan
From: Gustavo Padovan Call v4l2_ctrl_subscribe_event to subscribe to more events supported by v4l. Signed-off-by: Gustavo Padovan --- drivers/media/usb/uvc/uvc_v4l2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

[RFC 01/10] [media] vb2: add explicit fence user API

2017-03-13 Thread Gustavo Padovan
From: Gustavo Padovan Turn the reserved2 field into fence_fd that we will use to send an in-fence to the kernel return an out-fence from the kernel to userspace. Two new flags were added, V4L2_BUF_FLAG_IN_FENCE and V4L2_BUF_FLAG_OUT_FENCE. They should be used when

Re: [PATCH RESEND 1/1] media: platform: Renesas IMR driver

2017-03-13 Thread Sergei Shtylyov
Hello! On 02/22/2017 10:05 PM, Sergei Shtylyov wrote: From: Konstantin Kozhevnikov The image renderer light extended 4 (IMR-LX4) or the distortion correction engine is a drawing processor with a simple instruction system capable of referencing data

[RFC 00/10] V4L2 explicit synchronization support

2017-03-13 Thread Gustavo Padovan
From: Gustavo Padovan Hi, This RFC adds support for Explicit Synchronization of shared buffers in V4L2. It uses the Sync File Framework[1] as vector to communicate the fences between kernel and userspace. I'm sending this to start the discussion on the best

[RFC 05/10] [media] vivid: assign the specific device to the vb2_queue->dev

2017-03-13 Thread Gustavo Padovan
From: Gustavo Padovan Instead of assign the global v4l2 device assigned the specific device, this was causing trouble when using using V4L2 events with vivid devices. The queue device should be the same one we opened in userspace. Signed-off-by: Gustavo Padovan

[RFC 06/10] [media] v4l: add V4L2_EVENT_BUF_QUEUED event

2017-03-13 Thread Gustavo Padovan
From: Gustavo Padovan Add a new event the userspace can subscribe to receive notifications about when a buffer was enqueued onto the driver. The event provides the index of the enqueued buffer. Signed-off-by: Gustavo Padovan ---

Re: [PATCH] [media] v4l2-dv-timings: Introduce v4l2_calc_fps()

2017-03-13 Thread Jose Abreu
Hi Hans, On 09-03-2017 15:40, Hans Verkuil wrote: > On 09/03/17 16:15, Jose Abreu wrote: >> Hi Hans, >> >> >> Thanks for the review! >> >> >> On 09-03-2017 12:29, Hans Verkuil wrote: >>> On 07/03/17 17:48, Jose Abreu wrote: HDMI Receivers receive video modes which, according to CEA

[RFC 08/10] [media] vb2: add videobuf2 dma-buf fence helpers

2017-03-13 Thread Gustavo Padovan
From: Javier Martinez Canillas Add a videobuf2-fence.h header file that contains different helpers for DMA buffer sharing explicit fence support in videobuf2. Signed-off-by: Javier Martinez Canillas Signed-off-by: Gustavo Padovan

Re: [PATCH v4 29/36] media: imx: mipi-csi2: enable setting and getting of frame rates

2017-03-13 Thread Sakari Ailus
Hi Steve, On Mon, Mar 13, 2017 at 11:06:22AM -0700, Steve Longerbeam wrote: > > > On 03/13/2017 06:55 AM, Philipp Zabel wrote: > >On Mon, 2017-03-13 at 13:27 +, Russell King - ARM Linux wrote: > >>On Mon, Mar 13, 2017 at 03:16:48PM +0200, Sakari Ailus wrote: > >>>The vast majority of

Re: [RFC PATCH 00/12] Ion cleanup in preparation for moving out of staging

2017-03-13 Thread Laura Abbott
On 03/12/2017 12:05 PM, Daniel Vetter wrote: > On Sun, Mar 12, 2017 at 2:34 PM, Benjamin Gaignard > wrote: >> 2017-03-09 18:38 GMT+01:00 Laura Abbott : >>> On 03/09/2017 02:00 AM, Benjamin Gaignard wrote: 2017-03-06 17:04 GMT+01:00 Daniel

Re: [PATCH v4 29/36] media: imx: mipi-csi2: enable setting and getting of frame rates

2017-03-13 Thread Russell King - ARM Linux
On Mon, Mar 13, 2017 at 10:56:46PM +0200, Sakari Ailus wrote: > Hi Russell, > > On Mon, Mar 13, 2017 at 01:27:02PM +, Russell King - ARM Linux wrote: > > On Mon, Mar 13, 2017 at 03:16:48PM +0200, Sakari Ailus wrote: > > > The vast majority of existing drivers do not implement them nor the

Re: [PATCH v4 29/36] media: imx: mipi-csi2: enable setting and getting of frame rates

2017-03-13 Thread Philipp Zabel
On Mon, 2017-03-13 at 13:27 +, Russell King - ARM Linux wrote: > On Mon, Mar 13, 2017 at 03:16:48PM +0200, Sakari Ailus wrote: > > The vast majority of existing drivers do not implement them nor the user > > space expects having to set them. Making that mandatory would break existing > > user

Re: [PATCH 12/13] [media] tuners/tda18212: add flag for retrying tuner init on failure

2017-03-13 Thread Antti Palosaari
On 03/07/2017 08:57 PM, Daniel Scheller wrote: From: Daniel Scheller Taken from tda18212dd, first read after cold reset sometimes fails on some cards, trying twice shall do the trick. This is the case with the STV0367 demods soldered on the CineCTv6 bridge boards and older

Re: [PATCH v4 29/36] media: imx: mipi-csi2: enable setting and getting of frame rates

2017-03-13 Thread Sakari Ailus
Hi Russell, On Mon, Mar 13, 2017 at 01:27:02PM +, Russell King - ARM Linux wrote: > On Mon, Mar 13, 2017 at 03:16:48PM +0200, Sakari Ailus wrote: > > The vast majority of existing drivers do not implement them nor the user > > space expects having to set them. Making that mandatory would

[PATCH] media: platform: rcar_imr: add IMR-LSX3 support

2017-03-13 Thread Sergei Shtylyov
Add support for the image renderer light SRAM extended 3 (IMR-LSX3) found only in the R-Car V2H (R8A7792) SoC. It differs from IMR-LX4 in that it supports only planar video formats but can use the video capture data for the textures. Signed-off-by: Sergei Shtylyov

Re: [RFC PATCH 00/12] Ion cleanup in preparation for moving out of staging

2017-03-13 Thread Laura Abbott
On 03/13/2017 03:54 AM, Brian Starkey wrote: > On Sun, Mar 12, 2017 at 02:34:14PM +0100, Benjamin Gaignard wrote: >> 2017-03-09 18:38 GMT+01:00 Laura Abbott : >>> On 03/09/2017 02:00 AM, Benjamin Gaignard wrote: 2017-03-06 17:04 GMT+01:00 Daniel Vetter :

Re: [RFC PATCH 00/12] Ion cleanup in preparation for moving out of staging

2017-03-13 Thread Rob Clark
On Mon, Mar 13, 2017 at 5:09 PM, Laura Abbott wrote: >> Hm, we might want to expose all the heaps as individual >> /dev/ion_$heapname nodes? Should we do this from the start, since >> we're massively revamping the uapi anyway (imo not needed, current >> state seems to work

Re: [PATCH v4 29/36] media: imx: mipi-csi2: enable setting and getting of frame rates

2017-03-13 Thread Russell King - ARM Linux
On Mon, Mar 13, 2017 at 11:03:50PM +0200, Sakari Ailus wrote: > Hi Steve, > > On Mon, Mar 13, 2017 at 11:06:22AM -0700, Steve Longerbeam wrote: > > I'm kinda in the middle on this topic. I agree with Sakari that > > frame rate can fluctuate, but that should only be temporary. If > > the frame

[no subject]

2017-03-13 Thread Martin Herrman
unsubscribe linux-media

Re: [RFC PATCH 00/12] Ion cleanup in preparation for moving out of staging

2017-03-13 Thread Laura Abbott
On 03/13/2017 06:21 AM, Mark Brown wrote: > On Mon, Mar 13, 2017 at 10:54:33AM +, Brian Starkey wrote: >> On Sun, Mar 12, 2017 at 02:34:14PM +0100, Benjamin Gaignard wrote: > >>> Another point is how can we put secure rules (like selinux policy) on >>> heaps since all the allocations >>> go

Re: [PATCH v5 15/39] [media] v4l2: add a frame interval error event

2017-03-13 Thread Steve Longerbeam
On 03/13/2017 10:10 AM, Hans Verkuil wrote: On 03/13/2017 06:06 PM, Steve Longerbeam wrote: On 03/13/2017 03:53 AM, Hans Verkuil wrote: On 03/13/2017 11:45 AM, Russell King - ARM Linux wrote: On Mon, Mar 13, 2017 at 11:02:34AM +0100, Hans Verkuil wrote: On 03/11/2017 07:14 PM, Steve

Re: [RFC PATCH 00/12] Ion cleanup in preparation for moving out of staging

2017-03-13 Thread Laura Abbott
On 03/13/2017 02:29 PM, Rob Clark wrote: > On Mon, Mar 13, 2017 at 5:09 PM, Laura Abbott wrote: >>> Hm, we might want to expose all the heaps as individual >>> /dev/ion_$heapname nodes? Should we do this from the start, since >>> we're massively revamping the uapi anyway (imo