History log of /drivers/media/video/davinci/vpif_capture.c
Revision Date Author Comments
d2f7a1a2467c01b569d2a7fbf10e8894a3f0e496 13-Dec-2011 Hans Verkuil <hverkuil@xs4all.nl> [media] vpif_capture.c: v4l2_device_register() is called too late in vpif_probe()

The function v4l2_device_register() is called too late in vpif_probe().
This meant that vpif_obj.v4l2_dev is accessed before it is initialized
which caused a crash.

This used to work in the past, but video_register_device() is now actually
using the v4l2_dev pointer.

Note that vpif_display.c doesn't have this bug, there v4l2_device_register()
is called at the beginning of vpif_probe.

Signed-off-by: Georgios Plakaris <gplakari@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Manjunath Hadli <Manjunath.hadli@ti.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
64dc3c1a906467d90c24913b0b38dd13d9378f4f 25-Jun-2011 Mauro Carvalho Chehab <mchehab@redhat.com> [media] Stop using linux/version.h on the remaining video drivers

Standardize the remaining video drivers to return the API version
for the VIDIOC_QUERYCAP version, instead of a per-driver version.

Those drivers had the version updated more recently or are SoC
drivers. Even so, it doesn't sound a good idea to keep a per-driver
version control, so, let's use the per-subsystem version control
instead.

Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
46656afa8a9a410b7939b248712e4e48921929da 04-Jan-2011 Hans Verkuil <hans.verkuil@cisco.com> [media] davinci: convert vpif_capture to core-assisted locking

Now uses .unlocked_ioctl instead of .ioctl.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Manjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2c0ddd17741383009c53cf557d6526848c8bb917 16-Dec-2010 Mats Randgaard <mats.randgaard@cisco.com> [media] vpif_cap/disp: Cleanup, improved comments

Signed-off-by: Mats Randgaard <mats.randgaard@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Murali Karicheri <mkaricheri@gmail.com>
Acked-by: Vaibhav Hiremath <hvaibhav@ti.com>
Acked-by: Manjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
c027e165d2d901ecab485da5fee72ddce5da0297 16-Dec-2010 Mats Randgaard <mats.randgaard@cisco.com> [media] vpif_cap/disp: Added support for DV timings

Added functions to set and get custom DV timings.

Signed-off-by: Mats Randgaard <mats.randgaard@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Vaibhav Hiremath <hvaibhav@ti.com>
Acked-by: Manjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
40c8bcea6bc594c50abf3d3867bd49c8c039eb21 16-Dec-2010 Mats Randgaard <mats.randgaard@cisco.com> [media] vpif_cap/disp: Add support for DV presets

- Added functions to set/get/query/enum DV presets for vpif_caputre and
vpif_display.
- The format specification table is extended with all the DV formats
supported by TVP7002.

Signed-off-by: Mats Randgaard <mats.randgaard@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Manjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
aa4444063505983c5971bc8fb832385dfba16b41 16-Dec-2010 Mats Randgaard <mats.randgaard@cisco.com> [media] vpif: Consolidate formats from capture and display

- The ch_params tables in vpif_capture.c and vpif_display.c are moved to a common
table in vpif.c. Then it is easier to maintain the table.
- The field "fps" is removed from the struct vpif_channel_config_params because it
is not used.

Signed-off-by: Mats Randgaard <mats.randgaard@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by : Murali Karicheri <mkaricheri@gmail.com>
Acked-by: Manjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
7036d6a73c88428764e4a12f30846279346f4382 16-Dec-2010 Mats Randgaard <mats.randgaard@cisco.com> [media] vpif_cap/disp: Add debug functionality

The following functions are added to the drivers:
- vpif_g_chip_ident
- vpif_dbg_g_register
- vpif_dbg_s_register
- vpif_log_status

Signed-off-by: Mats Randgaard <mats.randgaard@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Vaibhav Hiremath <hvaibhav@ti.com>
Acked-by: Manjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
9a1f8b34aa539000da17a06235e4bec254d0bfb5 24-Sep-2010 Laurent Pinchart <laurent.pinchart@ideasonboard.com> [media] v4l: Remove module_name argument to the v4l2_i2c_new_subdev* functions

The argument isn't used anymore by the functions, remove it.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
dfffec67951494a02244b43b0b2cdc9cded841b2 24-Sep-2010 Laurent Pinchart <laurent.pinchart@ideasonboard.com> [media] vpif_capture: Don't use module names to load I2C modules

With the v4l2_i2c_new_subdev* functions now supporting loading modules
based on modaliases, don't use the module names hardcoded in platform
data by passing a NULL module name to those functions.

The only platform using the VPIF capture device (DM646x EVM) hardcodes
the module names to invalid values (tvp514x-0 and tvp514x-1). As this is
already broken, there's no risk of breaking it more.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
e3cfd447d01cf723ccda0ad6bfa2e85b73d3d747 30-Sep-2010 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB: videobuf: add ext_lock argument to the queue init functions (part 2)

Missed a few init functions on non-Intel platforms the first time :-(

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
11382f3d8a2d54d1db0aa6a768cd94214536c1b2 07-Sep-2010 Mats Randgaard <mats.randgaard@tandberg.com> V4L/DVB: vpif_cap: don't ignore return code of videobuf_poll_stream()

Signed-off-by: Mats Randgaard <mats.randgaard@tandberg.com>
Signed-off-by: Hans Verkuil <hans.verkuil@tandberg.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
1f8766b4e3f06c2206e7ff48da72d2886672759a 30-Aug-2010 Mats Randgaard <mats.randgaard@tandberg.com> V4L/DVB: vpif_cap/disp: Replaced kmalloc with kzalloc

Signed-off-by: Mats Randgaard <mats.randgaard@tandberg.com>
Signed-off-by: Hans Verkuil <hans.verkuil@tandberg.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
ffa1b391c61b9f9a2b5d14859bfdd9259fc6c4da 30-Aug-2010 Mats Randgaard <mats.randgaard@tandberg.com> V4L/DVB: vpif_cap/disp: Removed section mismatch warning

Signed-off-by: Mats Randgaard <mats.randgaard@tandberg.com>
Signed-off-by: Hans Verkuil <hans.verkuil@tandberg.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
473d80247332b818caf6d25ed3eaaa10d3dfcfb7 05-Aug-2010 Julia Lawall <julia@diku.dk> V4L/DVB: drivers/media/video: Adjust confusing if indentation

In cx23885/cx23885-video.c, cx88/cx88-video.c, davinci/vpif_capture.c, and
davinci/vpif_display.c, group the aligned code into a single if branch.

In saa7134/saa7134-video.c, outdent the code following the if.

The semantic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@r disable braces4@
position p1,p2;
statement S1,S2;
@@

(
if (...) { ... }
|
if (...) S1@p1 S2@p2
)

@script:python@
p1 << r.p1;
p2 << r.p2;
@@

if (p1[0].column == p2[0].column):
cocci.print_main("branch",p1)
cocci.print_secs("after",p2)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
ffb4877ba013f94322083f77cbb05b35c2a218aa 01-May-2010 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB: v4l2-common: simplify prio utility functions

v4l2_prio_init/open/close returned an int when in fact they would
always return 0. Make these void functions.

v4l2_prio_close and v4l2_prio_check pass an enum v4l2_priority as a
pointer for no good reason. Replace with a normal enum v4l2_priority
argument.

These changes will simplify the work of moving priority handling into
the v4l core.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
5a0e3ad6af8660be21ca98a971cd00f331318c05 24-Mar-2010 Tejun Heo <tj@kernel.org> include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h

percpu.h is included by sched.h and module.h and thus ends up being
included when building most .c files. percpu.h includes slab.h which
in turn includes gfp.h making everything defined by the two files
universally available and complicating inclusion dependencies.

percpu.h -> slab.h dependency is about to be removed. Prepare for
this change by updating users of gfp and slab facilities include those
headers directly instead of assuming availability. As this conversion
needs to touch large number of source files, the following script is
used as the basis of conversion.

http://userweb.kernel.org/~tj/misc/slabh-sweep.py

The script does the followings.

* Scan files for gfp and slab usages and update includes such that
only the necessary includes are there. ie. if only gfp is used,
gfp.h, if slab is used, slab.h.

* When the script inserts a new include, it looks at the include
blocks and try to put the new include such that its order conforms
to its surrounding. It's put in the include block which contains
core kernel includes, in the same order that the rest are ordered -
alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
doesn't seem to be any matching order.

* If the script can't find a place to put a new include (mostly
because the file doesn't have fitting include block), it prints out
an error message indicating which .h file needs to be added to the
file.

The conversion was done in the following steps.

1. The initial automatic conversion of all .c files updated slightly
over 4000 files, deleting around 700 includes and adding ~480 gfp.h
and ~3000 slab.h inclusions. The script emitted errors for ~400
files.

2. Each error was manually checked. Some didn't need the inclusion,
some needed manual addition while adding it to implementation .h or
embedding .c file was more appropriate for others. This step added
inclusions to around 150 files.

3. The script was run again and the output was compared to the edits
from #2 to make sure no file was left behind.

4. Several build tests were done and a couple of problems were fixed.
e.g. lib/decompress_*.c used malloc/free() wrappers around slab
APIs requiring slab.h to be added manually.

5. The script was run on all .h files but without automatically
editing them as sprinkling gfp.h and slab.h inclusions around .h
files could easily lead to inclusion dependency hell. Most gfp.h
inclusion directives were ignored as stuff from gfp.h was usually
wildly available and often used in preprocessor macros. Each
slab.h inclusion directive was examined and added manually as
necessary.

6. percpu.h was updated not to include slab.h.

7. Build test were done on the following configurations and failures
were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my
distributed build env didn't work with gcov compiles) and a few
more options had to be turned off depending on archs to make things
build (like ipr on powerpc/64 which failed due to missing writeq).

* x86 and x86_64 UP and SMP allmodconfig and a custom test config.
* powerpc and powerpc64 SMP allmodconfig
* sparc and sparc64 SMP allmodconfig
* ia64 SMP allmodconfig
* s390 SMP allmodconfig
* alpha SMP allmodconfig
* um on x86_64 SMP allmodconfig

8. percpu.h modifications were reverted so that it could be applied as
a separate patch and serve as bisection point.

Given the fact that I had only a couple of failures from tests on step
6, I'm fairly confident about the coverage of this conversion patch.
If there is a breakage, it's likely to be something in one of the arch
headers which should be easily discoverable easily on most builds of
the specific arch.

Signed-off-by: Tejun Heo <tj@kernel.org>
Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
471452104b8520337ae2fb48c4e61cd4896e025d 15-Dec-2009 Alexey Dobriyan <adobriyan@gmail.com> const: constify remaining dev_pm_ops

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
6ffefff5a9e76c2e9cb5081e219a7a6a4a5eee9f 16-Sep-2009 Muralidharan Karicheri <m-karicheri2@ti.com> V4L/DVB (12906c): V4L : vpif capture driver for DM6467

This is the vpif capture bridge driver for DM6467. This video
supports two video channels each having a tvp5147 device at
the input. This allows simultaneous capture of NTSC/PAL video
in each of this channel. Both MMAP and USERPTR io mechanism
are supported. Currently buffer allocation happens at REQBUF
ioctl request. Since USERPTR IO is supported, this is not an
issue since user applications can allocate buffers and pass
the user space address to the driver. Following are TODOs :-
1) Adding support for allocation of buffers at init
2) VBI/HBI data service

This has incorporated comments received against version v0
of the patch series.

Resending to merge V4l linux-next
create mode 100644 drivers/media/video/davinci/vpif_capture.c
create mode 100644 drivers/media/video/davinci/vpif_capture.h

Reviewed-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Muralidharan Karicheri <m-karicheri2@ti.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>