[PATCH v2 7/8] [media] vcodec: mediatek: Add Mediatek VP8 Video Encoder Driver

2015-12-11 Thread Tiffany Lin
Add vp8 encoder driver for MT8173 Signed-off-by: Daniel Hsiao Signed-off-by: Tiffany Lin --- drivers/media/platform/mtk-vcodec/Makefile |2 + drivers/media/platform/mtk-vcodec/venc_drv_if.c|3 +

[PATCH v2 8/8] [media] vcodec: mediatek: Add Mediatek H264 Video Encoder Driver

2015-12-11 Thread Tiffany Lin
Add h264 encoder driver for MT8173 Signed-off-by: Daniel Hsiao Signed-off-by: Tiffany Lin --- drivers/media/platform/mtk-vcodec/Makefile |3 +- .../media/platform/mtk-vcodec/h264_enc/Makefile|8 +

[PATCH v2 5/8] arm64: dts: mediatek: Add Video Encoder for MT8173

2015-12-11 Thread Tiffany Lin
Add video encoder node for MT8173 Signed-off-by: Tiffany Lin --- arch/arm64/boot/dts/mediatek/mt8173.dtsi | 47 ++ 1 file changed, 47 insertions(+) diff --git a/arch/arm64/boot/dts/mediatek/mt8173.dtsi

[PATCH v2 6/8] [Media] vcodec: mediatek: Add Mediatek V4L2 Video Encoder Driver

2015-12-11 Thread Tiffany Lin
From: Andrew-CT Chen Add v4l2 layer encoder driver for MT8173 Signed-off-by: Tiffany Lin --- drivers/media/platform/Kconfig | 11 + drivers/media/platform/Makefile|2 +

[PATCH v2 4/8] dt-bindings: Add a binding for Mediatek Video Encoder

2015-12-11 Thread Tiffany Lin
Add a DT binding documentation of Video Encoder for the MT8173 SoC from Mediatek. Signed-off-by: Tiffany Lin --- .../devicetree/bindings/media/mediatek-vcodec.txt | 58 1 file changed, 58 insertions(+) create mode 100644

[PATCH v2 1/8] dt-bindings: Add a binding for Mediatek Video Processor

2015-12-11 Thread Tiffany Lin
From: Andrew-CT Chen Add a DT binding documentation of Video Processor Unit for the MT8173 SoC from Mediatek. Signed-off-by: Andrew-CT Chen Signed-off-by: Tiffany Lin ---

[PATCH v2 0/8] Add MT8173 Video Encoder Driver and VPU Driver

2015-12-11 Thread Tiffany Lin
== Introduction == The purpose of this RFC is to discuss the driver for a hw video codec embedded in the Mediatek's MT8173 SoCs. Mediatek Video Codec is able to handle video encoding of in a range of formats. This RFC also include VPU driver. Mediatek Video Codec driver

[PATCH v2 2/8] arm64: dts: mediatek: Add node for Mediatek Video Processor Unit

2015-12-11 Thread Tiffany Lin
Add VPU drivers for MT8173 Signed-off-by: Andrew-CT Chen Signed-off-by: Tiffany Lin --- arch/arm64/boot/dts/mediatek/mt8173.dtsi | 11 +++ 1 file changed, 11 insertions(+) diff --git a/arch/arm64/boot/dts/mediatek/mt8173.dtsi

[PATCH v2 3/8] [media] VPU: mediatek: support Mediatek VPU

2015-12-11 Thread Tiffany Lin
The VPU driver for hw video codec embedded in Mediatek's MT8173 SOCs. It is able to handle video decoding/encoding of in a range of formats. The driver provides with VPU firmware download, memory management and the communication interface between CPU and VPU. For VPU initialization, it will create

[PATCH 02/10] media-device: better name Kernelspace/Userspace links

2015-12-11 Thread Mauro Carvalho Chehab
The __media_device_enum_links() copies links definitions from Kernelspace to userspace. It has to work with 3 structs that handle with links. Better name them to: link: Kernelspace internal link representation, of the type media_link; klink_desc: struct

[PATCH 05/10] DocBook: Move media-framework.txt contend to media-device.h

2015-12-11 Thread Mauro Carvalho Chehab
Instead of using a text file, let's put it together with the struct documentation for the Media Controller. Signed-off-by: Mauro Carvalho Chehab --- Documentation/DocBook/device-drivers.tmpl | 1 + Documentation/media-framework.txt | 373

[PATCH 08/10] media-entity.c: remove two extra blank lines

2015-12-11 Thread Mauro Carvalho Chehab
No functional changes. Suggested-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab --- drivers/media/media-entity.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/media/media-entity.c

[PATCH 03/10] media framework: rename pads init function to media_entity_pads_init()

2015-12-11 Thread Mauro Carvalho Chehab
With the MC next gen rework, what's left for media_entity_init() is to just initialize the PADs. However, certain devices, like a FLASH led/light doesn't have any input or output PAD. So, there's no reason why calling media_entity_init() would be mandatory. Also, despite its name, what this

[PATCH 07/10] media-device.h: Improve documentation and update it

2015-12-11 Thread Mauro Carvalho Chehab
Now that we moved the content of the media-framework.txt into the kerneldoc documentation, move the per-function specific documentation to the corresponding functions and clean it up. It would be good if we had already the markdown kernel-doc patches merged upstream, but, while we doesn't have

[PATCH 10/10] media_entity: get rid of an unused var

2015-12-11 Thread Mauro Carvalho Chehab
> > > + if (rlink != link->reverse) { > > > + r++; > > > > The variable is incremented here but otherwise never used, you can remove > > it. Suggested-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab

[PATCH 04/10] media-entity.h: get rid of revision and group_id fields

2015-12-11 Thread Mauro Carvalho Chehab
Both revision and group_id fields were never used and were always initialized to zero. Remove them. Signed-off-by: Mauro Carvalho Chehab --- Documentation/DocBook/media/v4l/media-ioc-enum-entities.xml | 13 ++--- Documentation/media-framework.txt

[PATCH 09/10] media-entity: get rid of forward __media_entity_remove_link() declaration

2015-12-11 Thread Mauro Carvalho Chehab
Move this function to happen earlier, in order to avoid a uneeded forward declaration. Signed-off-by: Mauro Carvalho Chehab --- drivers/media/media-entity.c | 67 +--- 1 file changed, 32 insertions(+), 35 deletions(-) diff --git

[PATCH 06/10] media-entity.h: convert media_entity_cleanup to inline

2015-12-11 Thread Mauro Carvalho Chehab
This function was used in the past to free the links that were allocated by the media controller core. However, this is not needed anymore. We should likely get rid of the funcion on some function, but, for now, let's just convert into an inlined function and let the compiler to get rid of it.

[PATCH 01/10] media-device: put headers in alphabetic order

2015-12-11 Thread Mauro Carvalho Chehab
It is better to keep the headers in alphabetic order. Suggested-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab --- drivers/media/media-device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH] media: use unsigned for pad index

2015-12-11 Thread Mauro Carvalho Chehab
The pad index is unsigned. Replace the occurences of it where pertinent. Suggested-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab --- drivers/media/platform/omap3isp/ispccdc.c | 2 +-

[PATCH 2/2] media-entity.h: move kernel-doc tags from media-entity.c

2015-12-11 Thread Mauro Carvalho Chehab
Several additional functions are described at media-entity.c. Moving them to the header file, to make the code cleaner and to have all such macros at the same place. Signed-off-by: Mauro Carvalho Chehab --- drivers/media/media-entity.c | 163

Re: [PATCH 03/10] media framework: rename pads init function to media_entity_pads_init()

2015-12-11 Thread Jacek Anaszewski
On 12/11/2015 02:34 PM, Mauro Carvalho Chehab wrote: With the MC next gen rework, what's left for media_entity_init() is to just initialize the PADs. However, certain devices, like a FLASH led/light doesn't have any input or output PAD. So, there's no reason why calling media_entity_init()

[PATCH 00/10] Some cleanups after the Media Controller Next gen

2015-12-11 Thread Mauro Carvalho Chehab
This series address the comments from Laurent to this patch: [PATCH v8.4 24/83] [media] media: convert links from array to list Most of the patches here are trivial. The most relevant one is the patch that updates the media framework documentation, moving it from a pure text file into

Problems with TV card "TeVii S472"

2015-12-11 Thread Hendrik Oenings
Hi all, I've got a DVB-S2 PCI-Express tv card ("Tevii S472", http://tevii.com/P roducts_S472_1.asp) with Debian testing, but I'm not able to get it work. On TeVii's webpage there is a linux driver availible (http://tevii.com/ Support.asp), but if I try to compile the driver, it says that my

[PATCH] [media] go7007: constify go7007_hpi_ops structures

2015-12-11 Thread Julia Lawall
The go7007_hpi_ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall --- drivers/media/pci/saa7134/saa7134-go7007.c |2 +- drivers/media/usb/go7007/go7007-priv.h |2 +-

Re: [PATCH 0/3] adv7604: .g_crop and .cropcap support

2015-12-11 Thread Hans Verkuil
Hi Ulrich, On 12/11/2015 05:04 PM, Ulrich Hecht wrote: > Hi! > > The rcar_vin driver relies on these methods. The third patch makes sure > that they return up-to-date data if the input signal has changed since > initialization. > > CU > Uli > > > Ulrich Hecht (3): > media: adv7604:

[PATCH 1/3] media: adv7604: implement g_crop

2015-12-11 Thread Ulrich Hecht
The rcar_vin driver relies on this. Signed-off-by: Ulrich Hecht --- drivers/media/i2c/adv7604.c | 12 1 file changed, 12 insertions(+) diff --git a/drivers/media/i2c/adv7604.c b/drivers/media/i2c/adv7604.c index 129009f..d30e7cc 100644 ---

[PATCH] adv7604: add direct interrupt handling

2015-12-11 Thread Ulrich Hecht
When probed from device tree, the i2c client driver can handle the interrupt on its own. Signed-off-by: Ulrich Hecht --- drivers/media/i2c/adv7604.c | 24 ++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git

[PATCH 0/3] adv7604: .g_crop and .cropcap support

2015-12-11 Thread Ulrich Hecht
Hi! The rcar_vin driver relies on these methods. The third patch makes sure that they return up-to-date data if the input signal has changed since initialization. CU Uli Ulrich Hecht (3): media: adv7604: implement g_crop media: adv7604: implement cropcap media: adv7604: update timings

[PATCH 2/3] media: adv7604: implement cropcap

2015-12-11 Thread Ulrich Hecht
Used by the rcar_vin driver. Signed-off-by: Ulrich Hecht --- drivers/media/i2c/adv7604.c | 17 + 1 file changed, 17 insertions(+) diff --git a/drivers/media/i2c/adv7604.c b/drivers/media/i2c/adv7604.c index d30e7cc..1bfa9f3 100644 ---

[PATCH 3/3] media: adv7604: update timings on change of input signal

2015-12-11 Thread Ulrich Hecht
Without this, g_crop will always return the boot-time state. Signed-off-by: Ulrich Hecht --- drivers/media/i2c/adv7604.c | 9 + 1 file changed, 9 insertions(+) diff --git a/drivers/media/i2c/adv7604.c b/drivers/media/i2c/adv7604.c index 1bfa9f3..d7d0bb7

Re: [PATCH v5 1/3] [media] media-device: check before unregister if mdev was registered

2015-12-11 Thread Shuah Khan
On 12/11/2015 03:57 PM, Javier Martinez Canillas wrote: > Most media functions that unregister, check if the corresponding register > function succeed before. So these functions can safely be called even if a > registration was never made or the component as already been unregistered. > > Add the

Re: [Patch v5 1/2] media: v4l: ti-vpe: Add CAL v4l2 camera capture driver

2015-12-11 Thread Benoit Parrot
Mauro Carvalho Chehab wrote on Thu [2015-Dec-03 11:19:22 -0200]: > Em Wed, 18 Nov 2015 14:47:11 -0600 > Benoit Parrot escreveu: > > > The Camera Adaptation Layer (CAL) is a block which consists of a dual > > port CSI2/MIPI camera capture engine. > >

[PATCH v5 0/3] [media] Fix race between graph enumeration and entities registration

2015-12-11 Thread Javier Martinez Canillas
Hello, This series fixes the issue of media device nodes being registered before all the media entities and pads links are created so if user-space tries to enumerate the graph too early, it may get a partial graph enumeration since everything may not been registered yet. The solution (suggested

[PATCH v5 2/3] [media] media-device: split media initialization and registration

2015-12-11 Thread Javier Martinez Canillas
The media device node is registered and so made visible to user-space before entities are registered and links created which means that the media graph obtained by user-space could be only partially enumerated if that happens too early before all the graph has been created. To avoid this race

[PATCH v5 1/3] [media] media-device: check before unregister if mdev was registered

2015-12-11 Thread Javier Martinez Canillas
Most media functions that unregister, check if the corresponding register function succeed before. So these functions can safely be called even if a registration was never made or the component as already been unregistered. Add the same check to media_device_unregister() function for consistency.

[PATCH] v4l-utils: mc_nextgen_test fix compile warnings

2015-12-11 Thread Shuah Khan
Fix the following compile warnings: CC mc_nextgen_test-mc_nextgen_test.o mc_nextgen_test.c: In function ‘media_get_ifname’: mc_nextgen_test.c:410:3: warning: ignoring return value of ‘asprintf’, declared with attribute warn_unused_result [-Wunused-result] asprintf(, "%s", devname);

[PATCH v5 3/3] [media] media-device: set topology version 0 at media registration

2015-12-11 Thread Javier Martinez Canillas
The G_TOPOLOGY ioctl is used to get a graph topology and since in the future a graph can be dynamically updated, there is a way to know the topology version so userspace can be aware that the graph has changed. The version 0 is reserved to indicate that the graph is static (i.e no graphs updates

cron job: media_tree daily build: ERRORS

2015-12-11 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: Sat Dec 12 04:00:19 CET 2015 git branch: test git hash: 991ce92f8de24cde063d531246602b6e14d3fef2 gcc

[PATCH 07/10] [media] v4l: vsp1: use else if instead of continue when creating links

2015-12-11 Thread Javier Martinez Canillas
The for loop in the vsp1_create_entities() function that create the links, checks the entity type and call the proper link creation function but then it uses continue to force the next iteration of the loop to take place and skipping code in between that creates links for different entities types.

[PATCH 06/10] [media] v4l: vsp1: remove pads prefix from *_create_pads_links()

2015-12-11 Thread Javier Martinez Canillas
The functions that create entities links are called *_create_pads_links() but the "pads" prefix is redundant since the driver doesn't handle any other kind of link so it can be removed. Suggested-by: Laurent Pinchart Signed-off-by: Javier Martinez Canillas

[PATCH 09/10] [media] uvcvideo: register entity subdev on init

2015-12-11 Thread Javier Martinez Canillas
The uvc_mc_register_entities() function iterated over the entities three times to initialize the entities, register the subdev for the ones whose type was UVC_TT_STREAMING and to create the entities links. But this can be simplied by merging the init and registration logic in a single loop.

[PATCH 05/10] [media] staging: omap4iss: remove pads prefix from *_create_pads_links()

2015-12-11 Thread Javier Martinez Canillas
The functions that create ISS internal and external entities links are called *_create_pads_links() but the "pads" prefix is redundant since the driver doesn't handle any other kind of link so it can be removed. Suggested-by: Laurent Pinchart Signed-off-by:

[PATCH 08/10] [media] uvcvideo: remove pads prefix from uvc_mc_create_pads_links()

2015-12-11 Thread Javier Martinez Canillas
The function uvc_mc_create_pads_links() creates entities links but the "pads" prefix is redundant since the driver doesn't handle any other kind of link, so it can be removed. Suggested-by: Laurent Pinchart Signed-off-by: Javier Martinez Canillas

[PATCH 10/10] [media] media-entity: remove unneded enclosing parenthesis

2015-12-11 Thread Javier Martinez Canillas
Commit 86ee417578a2 ("[media] media: convert links from array to list") had many changes that were automated using coccinelle but the semantic patch was not smart enough to rely on operators precedence and avoid using unnecessary enclosing parenthesis. This patch removes them since are not

Re: [PATCH 3/3] media: adv7604: update timings on change of input signal

2015-12-11 Thread Sergei Shtylyov
Hello. On 12/11/2015 07:04 PM, Ulrich Hecht wrote: Without this, g_crop will always return the boot-time state. Signed-off-by: Ulrich Hecht --- drivers/media/i2c/adv7604.c | 9 + 1 file changed, 9 insertions(+) diff --git

[PATCH 04/10] [media] omap3isp: consistently use v4l2_dev var in complete notifier

2015-12-11 Thread Javier Martinez Canillas
The isp_subdev_notifier_complete() complete callback defines a struct v4l2_device *v4l2_dev to avoid needing two level of indirections to access the V4L2 subdevs but the var is not always used when possible as when calling v4l2_device_register_subdev_nodes(). So change that to consistently use

[PATCH 01/10] [media] omap3isp: remove per ISP module link creation functions

2015-12-11 Thread Javier Martinez Canillas
The entities to video nodes links were created on separate functions for each ISP module but since the only thing that these functions do is to call media_create_pad_link(), there's no need for that indirection level and all link creation logic can be just inlined in the caller function. Also,

[PATCH 03/10] [media] omap3isp: rename single labels to just error

2015-12-11 Thread Javier Martinez Canillas
Commit bc36b30fe06b ("[media] omap3isp: separate links creation from entities init") moved the link creation logic from the entities init functions and so removed the error_link labels from the error paths. But after that, some functions have a single error label so it makes more sense to rename

[PATCH 00/10] [media] Some cleanup and fixes for MC next gen patches

2015-12-11 Thread Javier Martinez Canillas
Hello, This series contains some cleanup and fixes for the MC next gen patches [0]. These addresses all the issues pointed out by Laurent and Sakari in patches authored by me: d125aeaa74da [media] media: don't try to empty links list in media_entity_cleanup() 46b30ba56a89 [media] uvcvideo:

[PATCH 02/10] [media] omap3isp: remove pads prefix from isp_create_pads_links()

2015-12-11 Thread Javier Martinez Canillas
The function that creates the links between ISP internal and external entities is called isp_create_pads_links() but the "pads" prefix is redundant since the driver doesn't handle any other kind of link so it can just be removed. While being there, fix the function's kernel-doc since is not using

Re: [PATCH v2 1/8] dt-bindings: Add a binding for Mediatek Video Processor

2015-12-11 Thread Rob Herring
On Fri, Dec 11, 2015 at 05:55:36PM +0800, Tiffany Lin wrote: > From: Andrew-CT Chen > > Add a DT binding documentation of Video Processor Unit for the > MT8173 SoC from Mediatek. > > Signed-off-by: Andrew-CT Chen > Signed-off-by:

Re: [PATCH v2 4/8] dt-bindings: Add a binding for Mediatek Video Encoder

2015-12-11 Thread Rob Herring
On Fri, Dec 11, 2015 at 05:55:39PM +0800, Tiffany Lin wrote: > Add a DT binding documentation of Video Encoder for the > MT8173 SoC from Mediatek. > > Signed-off-by: Tiffany Lin A question and minor issue below, otherwise: Acked-by: Rob Herring >

[PATCH 1/2] media_entity: rename media_obj functions to *_create *_destroy

2015-12-11 Thread Mauro Carvalho Chehab
Those media_obj_* functions are actually creating/destroying media graph objects. So, rename them to better represent what they're actually doing. No functional changes. This was created via this small shell script: for i in $(git grep -l media_gobj_init); do sed

[PATCH 2/2] media-device: Use u64 ints for pointers

2015-12-11 Thread Mauro Carvalho Chehab
By using u64 integers and pointers, we can get rid of compat32 logic. So, let's do it! Suggested-by: Arnd Bergmann Suggested-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab --- This patch is the result of the

[PATCH 1/2] media-device.h: Let clearer that entity function must be initialized

2015-12-11 Thread Mauro Carvalho Chehab
Improve the documentation to let it clear that the entity function must be initialized. Suggested-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab --- include/media/media-device.h | 4 include/uapi/linux/media.h | 2 +-

[PATCH 2/2] [media] media: move MEDIA_LNK_FL_INTERFACE_LINK logic to link creation

2015-12-11 Thread Mauro Carvalho Chehab
Instead of flagging an interface link as MEDIA_LNK_FL_INTERFACE_LINK only when returning to userspace, do it at link creation time. That would allow using such flag internally, and cleans up a little bit the code for G_TOPOLOGY ioctl. Suggested-by: Hans Verkuil

[PATCH 1/2] [media] media-device.h: remove extra blank lines

2015-12-11 Thread Mauro Carvalho Chehab
No functional changes. Suggested-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab --- include/media/media-device.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/media/media-device.h

Re: [PATCH v2 00/32] VSP: Add R-Car Gen3 support

2015-12-11 Thread Khiem Nguyen
Hi Laurent, On 12/6/2015 5:54 AM, Laurent Pinchart wrote: Hi Geert, On Saturday 05 December 2015 11:57:49 Geert Uytterhoeven wrote: On Sat, Dec 5, 2015 at 3:12 AM, Laurent Pinchart wrote: This patch set adds support for the Renesas R-Car Gen3 SoC family to the VSP1 driver. The large number

Re: v4l2 kernel module debugging methods

2015-12-11 Thread Fabien DESSENNE
Hi Ran, On 12/10/2015 10:46 PM, Ran Shalit wrote: > On Sun, Dec 6, 2015 at 2:23 AM, Nicolas Dufresne > wrote: >> Le dimanche 06 décembre 2015 à 00:00 +0200, Ran Shalit a écrit : >>> Hello, >>> >>> I would like to ask a general question regarding methods to debug a

[PATCH] [media] media.h: let be clear that tuners need to use connectors

2015-12-11 Thread Mauro Carvalho Chehab
The V4L2 core won't be adding connectors to the tuners and other entities that need them. Let it be clear. Suggested-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab --- include/uapi/linux/media.h | 7 ++- 1 file changed,

Re: Media Controller patches

2015-12-11 Thread Mauro Carvalho Chehab
Em Thu, 10 Dec 2015 18:34:11 -0200 Mauro Carvalho Chehab escreveu: > Hi, > > I've been working during this week to address the issues pointed during > the Media Controller really long review process. We should avoid taking > so long to review patches in the future, as