summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2013-08-21[media] introduce gspca-stk1135: Syntek STK1135 driverOndrej Zary
Hello, this is a new gspca driver for Syntek STK1135 webcams. The code is completely new, but register values are based on Syntekdriver (stk11xx) by Nicolas VIVIEN (http://syntekdriver.sourceforge.net). Only one webcam type is supported now - vendor 0x174f, device 0x6a31. It's Asus F5RL laptop flippable webcam with MT9M112. The camera works better than in Windows - initializes much faster and provides more resolutions (the sensor can do almost any resolution - just add it to the stk1135_modes[] - could this feature be somehow used by applications to avoid SW scaling?). Autoflip works too - when the camera is flipped around, the image is flipped automatically. Signed-off-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-21[media] gspca-ov534: don't call sd_start() from sd_init()Antonio Ospite
sd_start() operates on device controls but after the conversion to the v4l2 control framework in commits 62bba5d and 1bd7d6a controls are initialized in sd_init_controls() which is called _after_ sd_init(): The change fixes a NULL pointer dereference for Hercules Blog Webcam; the problem is observable since 3.6: gspca_main: v2.14.0 registered gspca_main: ov534-2.14.0 probing 06f8:3002 BUG: unable to handle kernel NULL pointer dereference at 0000000000000050 IP: [<ffffffffa03c1b01>] v4l2_ctrl_g_ctrl+0x11/0x60 [videodev] PGD 0 Oops: 0000 [#1] SMP Modules linked in: gspca_ov534(+) gspca_main videodev rfcomm bnep ppdev bluetooth binfmt_misc snd_hda_codec_hdmi snd_hda_codec_realtek stir4200 irda crc_ccitt usblp snd_hda_intel snd_hda_codec snd_hwdep snd_pcm hid_generic snd_page_alloc snd_seq_midi snd_seq_midi_event usbhid snd_rawmidi snd_seq snd_seq_device snd_timer hid i915 snd psmouse drm_kms_helper serio_raw mei_me drm mei soundcore video i2c_algo_bit lpc_ich mac_hid coretemp lp parport firewire_ohci firewire_core crc_itu_t ahci libahci alx mdio r8169 mii [last unloaded: parport_pc] CPU: 3 PID: 4352 Comm: modprobe Not tainted 3.11.0-031100rc2-generic #201307211535 Hardware name: Gigabyte Technology Co., Ltd. To be filled by O.E.M./Z77-DS3H, BIOS F9 09/19/2012 task: ffff8801c20f9770 ti: ffff8801ceaa0000 task.ti: ffff8801ceaa0000 RIP: 0010:[<ffffffffa03c1b01>] [<ffffffffa03c1b01>] v4l2_ctrl_g_ctrl+0x11/0x60 [videodev] RSP: 0018:ffff8801ceaa1af8 EFLAGS: 00010292 RAX: 0000000000000001 RBX: 0000000000000000 RCX: 000000000001988b RDX: 000000000001988a RSI: ffffffffa032745a RDI: 0000000000000000 RBP: ffff8801ceaa1b28 R08: 0000000000017380 R09: ffffea0008419d80 R10: ffffffff81538f5a R11: 0000000000000002 R12: ffffffffa03273dc R13: ffffffffa03273dc R14: 0000000000000000 R15: ffffffffa03270a0 FS: 00007f72d564a740(0000) GS:ffff88021f380000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000050 CR3: 00000001bd1f0000 CR4: 00000000001407e0 Stack: ffff8801ceaa1b28 ffffffffa0325cff ffff8801000001f4 ffff8801ceb44000 ffffffffa03273dc ffff8801ceb44000 ffff8801ceaa1b58 ffffffffa032688e ffff8801ceb44000 ffffffffa03274f0 ffffffffa03274f0 ffff8801ceb44380 Call Trace: [<ffffffffa0325cff>] ? sccb_w_array+0x3f/0x80 [gspca_ov534] [<ffffffffa032688e>] sd_start+0xce/0x2b0 [gspca_ov534] [<ffffffffa0326bf9>] sd_init+0x189/0x1e8 [gspca_ov534] [<ffffffffa02a0c95>] gspca_dev_probe2+0x285/0x410 [gspca_main] [<ffffffffa02a0e58>] gspca_dev_probe+0x38/0x60 [gspca_main] [<ffffffffa0325081>] sd_probe+0x21/0x30 [gspca_ov534] [<ffffffff8153c960>] usb_probe_interface+0x1c0/0x2f0 [<ffffffff8148758c>] really_probe+0x6c/0x330 [<ffffffff814879d7>] driver_probe_device+0x47/0xa0 [<ffffffff81487adb>] __driver_attach+0xab/0xb0 [<ffffffff81487a30>] ? driver_probe_device+0xa0/0xa0 [<ffffffff814857be>] bus_for_each_dev+0x5e/0x90 [<ffffffff8148714e>] driver_attach+0x1e/0x20 [<ffffffff81486bdc>] bus_add_driver+0x10c/0x290 [<ffffffff8148805d>] driver_register+0x7d/0x160 [<ffffffff8153b590>] usb_register_driver+0xa0/0x160 [<ffffffffa0067000>] ? 0xffffffffa0066fff [<ffffffffa006701e>] sd_driver_init+0x1e/0x1000 [gspca_ov534] [<ffffffff8100212a>] do_one_initcall+0xfa/0x1b0 [<ffffffff810578c3>] ? set_memory_nx+0x43/0x50 [<ffffffff81712e8d>] do_init_module+0x80/0x1d1 [<ffffffff810d2079>] load_module+0x4c9/0x5f0 [<ffffffff810cf7b0>] ? add_kallsyms+0x210/0x210 [<ffffffff810d2254>] SyS_init_module+0xb4/0x100 [<ffffffff817333ef>] tracesys+0xe1/0xe6 Code: a0 09 00 00 48 c7 c7 30 c3 3c a0 e8 7a 38 ca e0 eb cf 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 55 48 89 e5 53 48 89 fb 48 83 ec 28 <8b> 47 50 83 e8 05 83 f8 02 77 09 80 b8 20 8c 3c a0 00 74 1d 48 RIP [<ffffffffa03c1b01>] v4l2_ctrl_g_ctrl+0x11/0x60 [videodev] RSP <ffff8801ceaa1af8> CR2: 0000000000000050 ---[ end trace 6786f15abfd2ac90 ]--- Original bug report from: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1173723/ Signed-off-by: Antonio Ospite <ospite@studenti.unina.it> Tested-by: Yaroslav Zakharuk <slavikz@gmail.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-21[media] gspca: fix dev_open() error pathAlexey Khoroshilov
If v4l2_fh_open() fails in dev_open(), gspca_dev->module left locked. The patch adds module_put(gspca_dev->module) on this path. Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-21[media] radio-si470x-usb: Remove software version checkHans de Goede
We've an user reporting a device with a software version of 0, which works fine. Once we lower the version check to accept version 0 it becomes a nop, so remove it completely. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: few improvements for RF tunerAntti Palosaari
* Fix AM_MODE. Now it could work at least in theory, cannot test. * Use greatest common divisor algo to divide PLL fractional parts. * Fix IF frequency mode. * + some very minor "style" issues Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: change stream format 384Antti Palosaari
After feeding different signal levels using RF generator and looking GNU Radio FFT sink I made decision to change bit shift 3 to bit shift 2 as there was very (too) huge visible leap in FFT sink GUI. Now it looks more natural. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: implement stream format 504Antti Palosaari
That stream format carries 504 x I+Q samples per 1024 USB frame. Sample resolution is 8-bit signed. Default it when sampling rate is 9Msps or over. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: a lot of small cleanupsAntti Palosaari
Add comments, remove useless code and so. House cleaning party. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: changes for tuner PLL freq limitsAntti Palosaari
I made some tuner freq limit tests against RF signal generator. Adjust some PLL limits according to these test results. Here are the results, taken from two different devices. Ranges are measured RF limits + calculated VCO limits. Mirics MSi3101 SDR Dongle: VHF_MODE 52 - 132 1664 - 4224 B3_MODE 103 - 263 1648 - 4208 B45_MODE 413 - 960 1652 - 3840 Hauppauge WinTV 133559 LF: VHF_MODE 49 - 130 1568 - 4160 B3_MODE 98 - 259 1568 - 4144 B45_MODE 391 - 960 1564 - 3840 Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: add stream format 336 I+Q pairs per frameAntti Palosaari
That one seem to have 12-bit resolution. Use it for streams that has sampling rate 6 <= rate (Msps) < 8, between 6 and 8Msps. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: fix overflow in freq settingAntti Palosaari
Higher frequencies were not possible to set correctly as that value overflows. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: init bits 23:20 on PLL registerAntti Palosaari
It is not sure what is meaning of that number, but it is better to try do as Windows driver. It seems to have small effect for signal when looking FM FFT. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: add support for stream format "252" I+Q per frameAntti Palosaari
That one seems to have 14-bit ADC resolution, wow! It is now used when sampling rate is below 6 Msps. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: improve tuner synth calc step sizeAntti Palosaari
Allow stepless synthesizer configuration. With that change we lose precision a little bit, as it is now between +-500Hz from the target. It could be better but on that case calculation algorithm goes more complex and atm there is more important things to do. Two approach to improve which comes to my mind are: 1) select and use biggest suitable step 2) use greatest common divisor algo to find divisor for thresh & frac when possible to avoid rounding errors, which is root of cause of current +-500Hz inaccuracy. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: correct ADC sampling rate calc a little bitAntti Palosaari
No need to compare numbers, we could just store that fractional value MSB directly. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: add debug dump for unknown stream dataAntti Palosaari
Dump all unknown 'garbage' data - maybe we will discover someday if there is something rational... Also fix comment in USB frame description. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: add 2040:d300 Hauppauge WinTV 133559 LFAntti Palosaari
It is based Mirics MSi3101 reference design and will just work without any changes. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: fix stream re-start haltAntti Palosaari
Restarting stream fails quite often. Small delay is between urb killing and stream stop command - likely to give harware some time to process killed urbs. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: enhance sampling resultsAntti Palosaari
It looks like there is some extra data carried to enhance sampling results. When you tune to some some weak/empty channel those bits are always zeroes. When you tune to some channel where is very strong signals those bits are all zeroes. Examining those 32-bits reveals shortly there is 16 pieces of 2-bit numbers. Number seen are 0, 1 and 3 - for some reason 2 is not used. I used that number to shift bits given amount to left, "increasing" sampling resolution by 3-bits. It may be wrong, but after some testing it still provides better signal. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: add sampling mode controlAntti Palosaari
Whilst Quadrature Sampling is most common sampling technique used in radio technology there is others too. Add control user could select sampling mode. We currently support only quadrature sampling. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: fix sampling rate calculationAntti Palosaari
These calculations seem to give 100% correct results. Calculation formulas could be still a little bit wrong as I have no knowledge what kind of dividers, multipliers and VCO limits there really is. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] msi3101: sample is correct term for sampleAntti Palosaari
Just fix wrong term name. No functional changes. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-20[media] Mirics MSi3101 SDR Dongle driverAntti Palosaari
It is first Kernel software defined radio receiver driver. That device is sold as a digital television solution. MSi3101 is reference design which consists of two chips: 1) MSi2500 USB ADC 2) MSi001 RF-tuner Driver is put to staging as API is not ready. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18v4l2-common: warning fix (W=1): add a missed function prototypeMauro Carvalho Chehab
changeset d1e9b7c12 added a new ancilliary function to API, but forgot to add it to the corresponding header file. drivers/media/v4l2-core/v4l2-ctrls.c:568:18: warning: no previous prototype for 'v4l2_ctrl_get_int_menu' [-Wmissing-prototypes] const s64 const *v4l2_ctrl_get_int_menu(u32 id, u32 *len) Cc: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18sh_mobile_ceu_camera: Fix a compilation warningMauro Carvalho Chehab
drivers/media/platform/soc_camera/sh_mobile_ceu_camera.c: In function 'sh_mobile_ceu_clock_start': drivers/media/platform/soc_camera/sh_mobile_ceu_camera.c:613:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable] Cc: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] exynos-gsc: fix s2r functionalityPrathyush K
When gsc is in runtime suspended state, there is no need to call m2m_suspend during suspend and similarly, there is no need to call m2m_resume during resume if already in runtime suspended state. This patch adds the necessary conditions to achieve this. Signed-off-by: Prathyush K <prathyush.k@samsung.com> Signed-off-by: Arun Mankuzhi <arun.m@samsung.com> Signed-off-by: Arun Kumar K <arun.kk@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] exynos4-is: Staticize local symbolSachin Kamat
__fimc_is_hw_update_param is used only in this file. Make it static. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] exynos4-is: Fix potential NULL pointer dereferenceSachin Kamat
dev->of_node could be NULL. Hence check for the same and return before dereferencing it in the subsequent error message. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] V4L: s5c73m3: Add format propagation for TRY formatsAndrzej Hajda
Resolution set on ISP pad of S5C73M3-OIF subdev should be propagated to source pad for TRY and ACTIVE formats. The patch adds missing propagation for TRY format. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] v4l2-async: Use proper list head for iteration over registered subdevsSylwester Nawrocki
This fixes regression introduced in commit b426b3a660c85faf6e1ca1c92c6d [media] V4L: Merge struct v4l2_async_subdev_list with struct v4l2_subdev Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] V4L2: mt9m111: switch to asynchronous subdevice probingGuennadi Liakhovetski
Convert the mt9m111 driver to asynchronous subdevice probing. Synchronous probing is also still possible. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] V4L2: mt9t031: don't Oops if asynchronous probing is attemptedGuennadi Liakhovetski
The mt9t031 driver hasn't yet been updated to support asynchronous subdevice probing. If such a probing is attempted, the driver is allowed to fail, but it shouldn't Oops. This patch fixes such a potential NULL pointer dereference. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] V4L2: mx3_camera: add support for asynchronous subdevice registrationGuennadi Liakhovetski
The soc-camera core does all the work on supporting asynchronous subdevice probing, host drivers only have to pass a subdevice list to soc-camera. Typically this list is provided by the platform. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] V4L2: mx3_camera: print V4L2_MBUS_FMT_* codes in hexadecimal formatGuennadi Liakhovetski
V4L2_MBUS_FMT_* codes are defined in v4l2-mediabus.h as hexadecimal constants. Print them in the same form for easier recognition. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] V4L2: mx3_camera: convert to managed resource allocationGuennadi Liakhovetski
Use devm_* resource allocators to simplify the driver's probe and clean up paths. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] V4L2: soc-camera: fix requesting regulators in synchronous caseGuennadi Liakhovetski
With synchronous subdevice probing regulators should be requested by the soc-camera core in soc_camera_pdrv_probe(). Subdevice drivers, supporting asynchronous probing, call soc_camera_power_init() to request regulators. Erroneously, the same regulator array is used in the latter case as in the former, which leads to a failure. This patch fixes it by preventing the second regulator request from being executed. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] soc_camera: fix compiler warningHans Verkuil
media_build/v4l/soc_camera.c: In function 'soc_camera_host_register': media_build/v4l/soc_camera.c:1513:10: warning: 'sasd' may be used uninitialized in this function [-Wmaybe-uninitialized] snprintf(clk_name, sizeof(clk_name), "%d-%04x", ^ media_build/v4l/soc_camera.c:1464:34: note: 'sasd' was declared here struct soc_camera_async_subdev *sasd; ^ By changing the type of 'i' to unsigned and changing a condition we finally convince the compiler that sasd is really initialized. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] V4L2: soc_camera: Renesas R-Car VIN driverVladimir Barinov
Add Renesas R-Car VIN (Video In) V4L2 driver. Based on the patch by Phil Edworthy <phil.edworthy@renesas.com>. [Sergei: removed deprecated IRQF_DISABLED flag, reordered/renamed 'enum chip_id' values, reordered rcar_vin_id_table[] entries, removed senseless parens from to_buf_list() macro, used ALIGN() macro in rcar_vin_setup(), added {} to the *if* statement and used 'bool' values instead of 0/1 where necessary, removed unused macros, done some reformatting and clarified some comments.] Signed-off-by: Vladimir Barinov <vladimir.barinov@cogentembedded.com> Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] v4l: async: Make it safe to unregister unregistered notifierLaurent Pinchart
Calling v4l2_async_notifier_unregister() on a notifier that hasn't been registered leads to a crash. To simplify drivers, make it safe to unregister a notifier that has not been registered. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Tested-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] v4l: Fix colorspace conversion error in sample codeLaurent Pinchart
The sample code erroneously scales the y1, pb and pr variables from the [0.0 .. 1.0] and [-0.5 .. 0.5] ranges to [0 .. 255] and [-128 .. 127]. Fix it. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] v4l: of: Drop acquired reference to node when getting next endpointLaurent Pinchart
The of_get_child_by_name() function takes a reference to the node it returns. Make sure to drop it when looking for the ports node in v4l2_of_get_next_endpoint(). Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] v4l: of: Use of_get_child_by_name()Laurent Pinchart
Replace a manual loop through child nodes with a call to of_get_child_by_name(). Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] videobuf2-core: Verify planes lengths for output buffersLaurent Pinchart
For output buffers application provide to the kernel the number of bytes they stored in each plane of the buffer. Verify that the value is smaller than or equal to the plane length. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Pawel Osciak <pawel@osciak.com> Acked-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] saa7115: make multi-line comments compliant with CodingStyleMauro Carvalho Chehab
changeset 2ccf12a did a crappy job when added multi-line comment lines, violating CodingStyle. Change the comments added there to fulfill CodingStyle, and document the platform_data using Documentation/kernel-doc-nano-HOWTO.txt. Cc: Jon Arne Jørgensen <jonarne@jonarne.no> Cc: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] saa7115: Implement i2c_board_info.platform_dataJon Arne Jørgensen
This patch implements i2c_board_info.platform_data, and some options to override the default initialization table for the GM7113C and SAA7113 chips. Signed-off-by: Jon Arne Jørgensen <jonarne@jonarne.no> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] saa7115: Do not load saa7115_init_misc for gm7113cJon Arne Jørgensen
Most of the registers changed in saa7115_init_misc table are out of range for the gm7113c chip. The only register that's within range, don't need to be changed here. Signed-off-by: Jon Arne Jørgensen <jonarne@jonarne.no> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] saa7115: Fix saa711x_set_v4lstd for gm7113cJon Arne Jørgensen
saa711x_set_v4lstd would toggle several bits that should not be touched when changing std. This patch fixes this. Signed-off-by: Jon Arne Jørgensen <jonarne@jonarne.no> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] ths8200/ad9389b: use new dv_timings helpersHans Verkuil
Simplify the code by using the new dv_timings helpers. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] v4l2: use new V4L2_DV_BT_BLANKING/FRAME definesHans Verkuil
Use the new blanking and frame size defines. This also fixed a bug in these drivers: they assumed that the height for interlaced formats was the field height, however height is the frame height. So the height for a field is actually bt->height / 2. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-08-18[media] v4l2: use new V4L2_DV_BT_BLANKING/FRAME definesHans Verkuil
Use the new defines to calculate the full blanking and frame sizes. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Scott Jiang <scott.jiang.linux@gmail.com> Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>