deliverable/linux.git
10 years ago[media] drx-j: be sure to use tuner's IF
Mauro Carvalho Chehab [Sun, 26 Jan 2014 18:02:25 +0000 (15:02 -0300)] 
[media] drx-j: be sure to use tuner's IF

Instead of just hardcoding an IF value of 5MHz, use the one
provided by the tuner, with can be different for QAM and
VSB.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of tuner dummy get/set frequency
Mauro Carvalho Chehab [Sun, 26 Jan 2014 17:54:08 +0000 (14:54 -0300)] 
[media] drx-j: get rid of tuner dummy get/set frequency

Those functions will never be used with Linux DVB binding.

Get rid of them.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: remove some ugly bindings from drx39xxj_dummy.c
Mauro Carvalho Chehab [Sun, 26 Jan 2014 17:23:24 +0000 (14:23 -0300)] 
[media] drx-j: remove some ugly bindings from drx39xxj_dummy.c

This file does an ugly binding between drxj and DVB frontend.

Remove most of the functions there. We still need to get rid of
get_frequency and set_frequency, but such patch is a little more
complex, as it should also remove some previous tuner bindings.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: comment or remove unused code
Mauro Carvalho Chehab [Fri, 24 Jan 2014 16:16:16 +0000 (13:16 -0300)] 
[media] drx-j: comment or remove unused code

In order to avoid warnings and to remove dead code, remove
the functions that don't make sense to happen, while commenting
the others that might still be useful some day.

That reduced a lot the text size:

Before:

   text    data     bss     dec     hex filename
  58419    2916       4   61339    ef9b drivers/media/dvb-frontends/drx39xyj/drx39xyj.ko

After:
   text    data     bss     dec     hex filename
  78331    2916       4   81251   13d63 drivers/media/dvb-frontends/drx39xyj/drx39xyj.ko

Without any functional changes.

It could be make sense latter to remove those drivers or to
move them into an analog-specific part of the driver.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of drxj_ctrl()
Mauro Carvalho Chehab [Fri, 24 Jan 2014 16:00:08 +0000 (13:00 -0300)] 
[media] drx-j: get rid of drxj_ctrl()

With this change, we finally got rid of all abstraction
layers on this driver.

This patch also fixes the LNA GPIO settings, as the original
code were using a wrong control name for it.

This patch exposes the several functions that aren't used.
Some of them are related to analog demod that might be
used some day, but others will likely never be needed, as
they don't fit on Linux media APIs.

Latter patches will clean up this mess.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: move drx39xxj into drxj.c
Mauro Carvalho Chehab [Fri, 24 Jan 2014 15:25:04 +0000 (12:25 -0300)] 
[media] drx-j: move drx39xxj into drxj.c

While drxj is already too big, moving the code there will
make easier to get rid of the drxj_ctrl function.

It will also help to detect and remove the unused functions,
helping to remove lots of dead code there.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of the remaining drx generic functions
Mauro Carvalho Chehab [Fri, 24 Jan 2014 15:21:17 +0000 (12:21 -0300)] 
[media] drx-j: get rid of the remaining drx generic functions

Get rid of drx_open and drx_close, as those are just wrapper
functions to drxj_open/drxj_close.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of drx_ctrl
Mauro Carvalho Chehab [Fri, 24 Jan 2014 14:14:17 +0000 (11:14 -0300)] 
[media] drx-j: get rid of drx_ctrl

This function is used only as an abstraction layer to call the
two firmware functions. Remove it.

As a bonus, the drx_ctrl_function is now unused and can be
removed.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Remove duplicated firmware upload code
Mauro Carvalho Chehab [Fri, 24 Jan 2014 10:49:29 +0000 (07:49 -0300)] 
[media] drx-j: Remove duplicated firmware upload code

Remove the duplicated firmware upload code that was commented
inside drxj.c.

This code is not used, and will not work anyway, as it doesn't
download the firmware from userspace.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Avoid any regressions by preserving old behavior
Mauro Carvalho Chehab [Fri, 24 Jan 2014 09:31:03 +0000 (06:31 -0300)] 
[media] drx-j: Avoid any regressions by preserving old behavior

The version is initialized with zero at drx_driver.c. Keep it,
in order to avoid the risk of causing any regression.

While here, remove the drx_driver.h from drxj, as this is not
required there.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of drx_driver.c
Mauro Carvalho Chehab [Fri, 24 Jan 2014 09:25:07 +0000 (06:25 -0300)] 
[media] drx-j: get rid of drx_driver.c

This file contains just the firmware load code, that it is also
somewhat duplicated at drxj.c.

Move the code into there. Latter patches will remove the
duplicated code.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: prepend function names with drx_ at drx_driver.c
Mauro Carvalho Chehab [Fri, 24 Jan 2014 09:15:46 +0000 (06:15 -0300)] 
[media] drx-j: prepend function names with drx_ at drx_driver.c

In order to prepare to get rid of drx_driver.c, prepend all functions
there with drx_.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Some cleanups at drx_driver.c source
Mauro Carvalho Chehab [Wed, 22 Jan 2014 13:21:55 +0000 (10:21 -0300)] 
[media] drx-j: Some cleanups at drx_driver.c source

This is mostly CodingStyle fixes and improvements.

No functional changes.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Allow standard selection
Mauro Carvalho Chehab [Sun, 19 Jan 2014 15:08:36 +0000 (12:08 -0300)] 
[media] drx-j: Allow standard selection

ClearQAM is currently not working. Add support for it too.
Unlikely other ATSC tuners, though, this device will not
auto-detect between ATSC and ClearQAM. So, the delivery
system should be properly set.

Also, this frontend seems to also support DVB-C annex A/C. Add
experimental support for them.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: reset the DVB scan configuration at powerup
Mauro Carvalho Chehab [Sun, 19 Jan 2014 13:31:47 +0000 (10:31 -0300)] 
[media] drx-j: reset the DVB scan configuration at powerup

Without this fixup, the DRX-J will not be properly initialized,
loosing several PIDs.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of its own be??_to_cpu() implementation
Mauro Carvalho Chehab [Sun, 19 Jan 2014 13:06:43 +0000 (10:06 -0300)] 
[media] drx-j: get rid of its own be??_to_cpu() implementation

Instead of handling endiannes with its own internal way, use the
already existing macros.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: remove unused code from drx_driver.c
Mauro Carvalho Chehab [Sun, 19 Jan 2014 12:50:18 +0000 (09:50 -0300)] 
[media] drx-j: remove unused code from drx_driver.c

There are several drx-j code there that are never used, as
they don't even fit into Linux DVB subystem model.

Remove them, in order to simplify the code.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] em28xx: add support for PCTV 80e remote controller
Mauro Carvalho Chehab [Sun, 19 Jan 2014 10:15:11 +0000 (07:15 -0300)] 
[media] em28xx: add support for PCTV 80e remote controller

This stick uses the same RC-5 remote controll found on other
PCTV devices. So, just use the existing keymap.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Split firmware size check from the main routine
Mauro Carvalho Chehab [Sat, 18 Jan 2014 22:11:11 +0000 (19:11 -0300)] 
[media] drx-j: Split firmware size check from the main routine

The firmware upload routine is already complex enough. Split the
first loop that verifies the firmware size into a separate routine,
making the code more readable.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: dynamically load the firmware
Mauro Carvalho Chehab [Sat, 18 Jan 2014 14:13:02 +0000 (11:13 -0300)] 
[media] drx-j: dynamically load the firmware

Instead of hardcoding the firmware files together with the driver,
use request_firmware() way, loading it from userspace.

The firmware files are placed at:
http://linuxtv.org/downloads/firmware/#8

And they'll be latter submitted to linux-firmware git tree.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Be sure that all allocated data are properly initialized
Mauro Carvalho Chehab [Sat, 18 Jan 2014 14:12:46 +0000 (11:12 -0300)] 
[media] drx-j: Be sure that all allocated data are properly initialized

The state struct is allocated without cleaning the memory.
This causes random bugs.

Clean it, and move the memcpy functions just below each kalloc,
to be clearer that all those data are properly filled.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Fix release and error path on drx39xxj.c
Mauro Carvalho Chehab [Sat, 18 Jan 2014 10:38:30 +0000 (07:38 -0300)] 
[media] drx-j: Fix release and error path on drx39xxj.c

There are memory leaks on both DVB release and
dvb attach error path. Fix them.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: remove the useless microcode_size
Mauro Carvalho Chehab [Fri, 17 Jan 2014 19:02:09 +0000 (16:02 -0300)] 
[media] drx-j: remove the useless microcode_size

This var is not used. Remove it from the code, as we'll now be
converting the driver to load the firmware from an external
file.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: make checkpatch.pl happy
Mauro Carvalho Chehab [Fri, 17 Jan 2014 14:51:52 +0000 (11:51 -0300)] 
[media] drx-j: make checkpatch.pl happy

Fix the remaining checkpatch.pl compliants at drxj.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: remove drxj_options.h
Mauro Carvalho Chehab [Fri, 17 Jan 2014 16:50:08 +0000 (13:50 -0300)] 
[media] drx-j: remove drxj_options.h

This file is empty (actually, all commented there). So, remove it.

We should latter remove those macros too, or convert them into
a struct to allow dynamically enable the options during device
probing time.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: remove typedefs at drx_driver.c
Mauro Carvalho Chehab [Fri, 17 Jan 2014 15:51:14 +0000 (12:51 -0300)] 
[media] drx-j: remove typedefs at drx_driver.c

Get rid of another typedef defined on this driver.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of some ugly macros
Mauro Carvalho Chehab [Fri, 17 Jan 2014 15:20:41 +0000 (12:20 -0300)] 
[media] drx-j: get rid of some ugly macros

There are several get/set macros that are bogus: they just
call another macro and do either:
x = FOO(d)
or
FOO(d) = x

As checkpatch complains about that, and replacing all of them
are as easy as running a small coccinelle script, get rid
of all of them.

Script used:

@@
expression d, x;
@@
-DRX_SET_MIRRORFREQSPECT(d, x);
+DRX_ATTR_MIRRORFREQSPECT(d) = x;

@@
expression d, x;
@@
-DRX_GET_MIRRORFREQSPECT(d, x);
+x = DRX_ATTR_MIRRORFREQSPECT(d);

@@
expression d, x;
@@
-DRX_SET_CURRENTPOWERMODE(d, x);
+DRX_ATTR_CURRENTPOWERMODE(d) = x;

@@
expression d, x;
@@
-DRX_GET_CURRENTPOWERMODE(d, x);
+x = DRX_ATTR_CURRENTPOWERMODE(d);

@@
expression d, x;
@@
-DRX_SET_MICROCODE(d, x);
+DRX_ATTR_MICROCODE(d) = x;

@@
expression d, x;
@@
-DRX_GET_MICROCODE(d, x);
+x = DRX_ATTR_MICROCODE(d);

@@
expression d, x;
@@
-DRX_SET_MICROCODESIZE(d, x);
+DRX_ATTR_MICROCODESIZE(d) = x;

@@
expression d, x;
@@
-DRX_GET_MICROCODESIZE(d, x);
+x = DRX_ATTR_MICROCODESIZE(d);

@@
expression d, x;
@@
-DRX_SET_VERIFYMICROCODE(d, x);
+DRX_ATTR_VERIFYMICROCODE(d) = x;

@@
expression d, x;
@@
-DRX_GET_VERIFYMICROCODE(d, x);
+x = DRX_ATTR_VERIFYMICROCODE(d);

@@
expression d, x;
@@
-DRX_SET_MCVERTYPE(d, x);
+DRX_ATTR_MCRECORD(d).aux_type = x;

@@
expression d, x;
@@
-DRX_GET_MCVERTYPE(d, x);
+x = DRX_ATTR_MCRECORD(d).aux_type;

@@
expression d, x;
@@
-DRX_SET_MCDEV(d, x);
+DRX_ATTR_MCRECORD(d).mc_dev_type = x;

@@
expression d, x;
@@
-DRX_GET_MCDEV(d, x);
+x = DRX_ATTR_MCRECORD(d).mc_dev_type;

@@
expression d, x;
@@
-DRX_SET_MCVERSION(d, x);
+DRX_ATTR_MCRECORD(d).mc_version = x;

@@
expression d, x;
@@
-DRX_GET_MCVERSION(d, x);
+x = DRX_ATTR_MCRECORD(d).mc_version;

@@
expression d, x;
@@
-DRX_SET_MCPATCH(d, x);
+DRX_ATTR_MCRECORD(d).mc_base_version = x;

@@
expression d, x;
@@
-DRX_GET_MCPATCH(d, x);
+x = DRX_ATTR_MCRECORD(d).mc_base_version;

@@
expression d, x;
@@
-DRX_SET_I2CADDR(d, x);
+DRX_ATTR_I2CADDR(d) = x;

@@
expression d, x;
@@
-DRX_GET_I2CADDR(d, x);
+x = DRX_ATTR_I2CADDR(d);

@@
expression d, x;
@@
-DRX_SET_I2CDEVID(d, x);
+DRX_ATTR_I2CDEVID(d) = x;

@@
expression d, x;
@@
-DRX_GET_I2CDEVID(d, x);
+x = DRX_ATTR_I2CDEVID(d);

@@
expression d, x;
@@
-DRX_SET_USEBOOTLOADER(d, x);
+DRX_ATTR_USEBOOTLOADER(d) = x;

@@
expression d, x;
@@
-DRX_GET_USEBOOTLOADER(d, x);
+x = DRX_ATTR_USEBOOTLOADER(d);

@@
expression d, x;
@@
-DRX_SET_CURRENTSTANDARD(d, x);
+DRX_ATTR_CURRENTSTANDARD(d) = x;

@@
expression d, x;
@@
-DRX_GET_CURRENTSTANDARD(d, x);
+x = DRX_ATTR_CURRENTSTANDARD(d);

@@
expression d, x;
@@
-DRX_SET_PREVSTANDARD(d, x);
+DRX_ATTR_PREVSTANDARD(d) = x;

@@
expression d, x;
@@
-DRX_GET_PREVSTANDARD(d, x);
+x = DRX_ATTR_PREVSTANDARD(d);

@@
expression d, x;
@@
-DRX_SET_CACHESTANDARD(d, x);
+DRX_ATTR_CACHESTANDARD(d) = x;

@@
expression d, x;
@@
-DRX_GET_CACHESTANDARD(d, x);
+x = DRX_ATTR_CACHESTANDARD(d);

@@
expression d, x;
@@
-DRX_SET_CURRENTCHANNEL(d, x);
+DRX_ATTR_CURRENTCHANNEL(d) = x;

@@
expression d, x;
@@
-DRX_GET_CURRENTCHANNEL(d, x);
+x = DRX_ATTR_CURRENTCHANNEL(d);

@@
expression d, x;
@@
-DRX_SET_ISOPENED(d, x);
+DRX_ATTR_ISOPENED(d) = x;

@@
expression d, x;
@@
-DRX_GET_ISOPENED(d, x);
+x = DRX_ATTR_ISOPENED(d);

@@
expression d, x;
@@
-DRX_SET_TUNER(d, x);
+DRX_ATTR_TUNER(d) = x;

@@
expression d, x;
@@
-DRX_GET_TUNER(d, x);
+x = DRX_ATTR_TUNER(d);

@@
expression d, x;
@@
-DRX_SET_CAPABILITIES(d, x);
+DRX_ATTR_CAPABILITIES(d) = x;

@@
expression d, x;
@@
-DRX_GET_CAPABILITIES(d, x);
+x = DRX_ATTR_CAPABILITIES(d);

@@
expression d, x;
@@
-DRX_SET_PRODUCTID(d, x);
+DRX_ATTR_PRODUCTID(d) = x;

@@
expression d, x;
@@
-DRX_GET_PRODUCTID(d, x);
+x = DRX_ATTR_PRODUCTID(d);

@@
expression d, x;
@@
-DRX_SET_MFX(d, x);
+DRX_ATTR_PRODUCTID(d) = x;

@@
expression d, x;
@@
-DRX_GET_MFX(d, x);
+x = DRX_ATTR_PRODUCTID(d);

@@
expression d, x;
@@
-DRX_SET_INTERMEDIATEFREQ(d, x);
+DRX_ATTR_INTERMEDIATEFREQ(d) = x;

@@
expression d, x;
@@
-DRX_GET_INTERMEDIATEFREQ(d, x);
+x = DRX_ATTR_INTERMEDIATEFREQ(d);

@@
expression d, x;
@@
-DRX_SET_SYSCLOCKFREQ(d, x);
+DRX_ATTR_SYSCLOCKFREQ(d) = x;

@@
expression d, x;
@@
-DRX_GET_SYSCLOCKFREQ(d, x);
+x = DRX_ATTR_SYSCLOCKFREQ(d);

@@
expression d, x;
@@
-DRX_SET_TUNERRFAGCPOL(d, x);
+DRX_ATTR_TUNERRFAGCPOL(d) = x;

@@
expression d, x;
@@
-DRX_GET_TUNERRFAGCPOL(d, x);
+x = DRX_ATTR_TUNERRFAGCPOL(d);

@@
expression d, x;
@@
-DRX_SET_TUNERIFAGCPOL(d, x);
+DRX_ATTR_TUNERIFAGCPOL(d) = x;

@@
expression d, x;
@@
-DRX_GET_TUNERIFAGCPOL(d, x);
+x = DRX_ATTR_TUNERIFAGCPOL(d);

@@
expression d, x;
@@
-DRX_SET_TUNERSLOWMODE(d, x);
+DRX_ATTR_TUNERSLOWMODE(d) = x;

@@
expression d, x;
@@
-DRX_GET_TUNERSLOWMODE(d, x);
+x = DRX_ATTR_TUNERSLOWMODE(d);

@@
expression d, x;
@@
-DRX_SET_TUNERPORTNR(d, x);
+DRX_ATTR_TUNERSPORTNR(d) = x;

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Replace printk's by pr_foo()
Mauro Carvalho Chehab [Fri, 17 Jan 2014 14:36:17 +0000 (11:36 -0300)] 
[media] drx-j: Replace printk's by pr_foo()

Instead of using printk's, use the pr_foo() macros.

That fixes some checkpatch warnings and provide a better error,
warning and debug support.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Use the Linux error codes
Mauro Carvalho Chehab [Fri, 17 Jan 2014 13:18:16 +0000 (10:18 -0300)] 
[media] drx-j: Use the Linux error codes

Instead of defining its own set of error codes, use the linux
native ones.

Please note that this patch made a "stupid" error code mapping, just
replacing the codes with the closest one. In special, -EIO is being
used on several places. I'm pretty sure this could be better assigned,
but a change like that would require lots o time and efforts, without
much benefit.

So lets do adjstments at the error codes latter, when we have more
time.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: CodingStyle fixups on drxj.c
Mauro Carvalho Chehab [Fri, 17 Jan 2014 10:12:28 +0000 (07:12 -0300)] 
[media] drx-j: CodingStyle fixups on drxj.c

Fix almost all checkpatch.pl warnings/errors on drxj.c, except for:
- 80 cols whitespacing;
- too many leading tabs;
- a false positive at DRXJ_16TO8() macro.
- static char array declaration should probably be static const char
  as adding "const" would cause warnings.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Remove typedefs in drxj.c
Mauro Carvalho Chehab [Fri, 17 Jan 2014 10:00:31 +0000 (07:00 -0300)] 
[media] drx-j: Remove typedefs in drxj.c

Remove three typedefs from drxj.c, using the following script:

use File::Find;
use strict;

my $dir = shift or die "need a dir";
my $type = shift or die "need type";
my $var = shift or die "need var";

sub handle_file {
my $file = shift;

my $out;

open IN, $file or die "can't open $file";
$out .= $_ while (<IN>);
close IN;

$out =~ s/\btypedef\s+($type)\s+\{([\d\D]+?)\s*\}\s+\b($var)[^\;]+\;/$type $var \{\2\};/;

        # This replaces the typedef declaration for a simple struct declaration - style 1

        # This replaces the typedef declaration for a simple struct declaration - style 2

# Replace struct occurrences

$out =~ s,\b($var)_t\s+,$type \1 ,g;
$out =~ s,\bp_*($var)_t\s+,$type \1 *,g;
$out =~ s,\b($var)_t\b,$type \1,g;
$out =~ s,\bp_*($var)_t\b,$type \1 *,g;

open OUT, ">$file" or die "can't open $file";
print OUT $out;
close OUT;
}

sub parse_dir {
my $file = $File::Find::name;

return if (!($file =~ /.[ch]$/));

handle_file $file;
}

find({wanted => \&parse_dir, no_chdir => 1}, $dir);

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: More CamelCase fixups
Mauro Carvalho Chehab [Fri, 17 Jan 2014 09:47:04 +0000 (06:47 -0300)] 
[media] drx-j: More CamelCase fixups

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Simplify logic expressions
Mauro Carvalho Chehab [Fri, 17 Jan 2014 09:40:47 +0000 (06:40 -0300)] 
[media] drx-j: Simplify logic expressions

Don't need to test boolean x == true or x == false.

That makes the code more compact.

patch generated with make coccicheck and manually reviewed.

While here, remove uneeded ';'.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: don't use parenthesis on return
Mauro Carvalho Chehab [Fri, 17 Jan 2014 09:28:28 +0000 (06:28 -0300)] 
[media] drx-j: don't use parenthesis on return

CodingStyle fix: don't use parenthesis on return, as it is not
a function.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: replace the ugly CHK_ERROR() macro
Mauro Carvalho Chehab [Thu, 16 Jan 2014 22:41:13 +0000 (19:41 -0300)] 
[media] drx-j: replace the ugly CHK_ERROR() macro

Using return and goto inside macros is ugly and makes harder to
understand the code and the labels. Remove those macros, and add
a proper error debug message, when something bad happens.

This was generated using the following coccinelle script:

@@
@@
-DUMMY_READ();
+do {
+ u16 dummy;
+ RR16(demod->my_i2c_dev_addr, SCU_RAM_VERSION_HI__A, &dummy);
+} while (0);

@@
expression dev, addr, val;
@@
-WR16(dev, addr, val)
+CHK_ERROR(DRXJ_DAP.write_reg16func(dev, addr, val, 0))

@@
expression dev, addr, val;
@@
-RR16(dev, addr, val)
+CHK_ERROR(DRXJ_DAP.read_reg16func(dev, addr, val, 0))

@@
expression dev, addr, val;
@@
-WR32(dev, addr, val)
+CHK_ERROR(DRXJ_DAP.write_reg32func(dev, addr, val, 0))

@@
expression dev, addr, val;
@@
-RR32(dev, addr, val)
+CHK_ERROR(DRXJ_DAP.read_reg32func(dev, addr, val, 0))

@@
expression dev, addr, val, block;
@@
-WRB(dev, addr, val, block)
+CHK_ERROR(DRXJ_DAP.write_block_func(dev, addr, val, block, 0))

@@
expression dev, addr, val, block;
@@
-RRB(dev, addr, val, block)
+CHK_ERROR(DRXJ_DAP.read_block_func(dev, addr, val, block, 0))

@@
expression dev, addr, val;
@@
-BCWR16(dev, addr, val)
+CHK_ERROR(DRXJ_DAP.write_reg16func(dev, addr, val, DRXDAP_FASI_BROADCAST))

@@
expression dev, addr, val;
@@
-ARR32(dev, addr, val)
+CHK_ERROR(drxj_dap_atomic_read_reg32(dev, addr, val, 0))

@@
expression dev, addr, val;
@@
-SARR16(dev, addr, val)
+CHK_ERROR(drxj_dap_scu_atomic_read_reg16(dev, addr, val, 0))

@@
expression x;
@@
-CHK_ERROR(x);
+rc = x;
+if (rc != DRX_STS_OK) {
+ pr_err("error %d\n", rc);
+ goto rw_error;
+}

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Don't use buffer if an error occurs
Mauro Carvalho Chehab [Thu, 16 Jan 2014 19:34:03 +0000 (16:34 -0300)] 
[media] drx-j: Don't use buffer if an error occurs

drivers/media/dvb-frontends/drx39xyj/drxj.c: In function â€˜drxj_dap_scu_atomic_read_reg16’:
drivers/media/dvb-frontends/drx39xyj/drxj.c:4170:9: warning: â€˜*((void *)&buf+1)’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  word = (u16) (buf[0] + (buf[1] << 8));
         ^
drivers/media/dvb-frontends/drx39xyj/drxj.c:4170:9: warning: â€˜buf’ may be used uninitialized in this function [-Wmaybe-uninitialized]
drivers/media/dvb-frontends/drx39xyj/drxj.c: In function â€˜drxj_dap_atomic_read_reg32.isra.59’:
drivers/media/dvb-frontends/drx39xyj/drxj.c:2186:7: warning: â€˜*((void *)&buf+3)’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  word = (u32) buf[3];
       ^
drivers/media/dvb-frontends/drx39xyj/drxj.c:2188:10: warning: â€˜*((void *)&buf+2)’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  word |= (u32) buf[2];
          ^
drivers/media/dvb-frontends/drx39xyj/drxj.c:2190:10: warning: â€˜*((void *)&buf+1)’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  word |= (u32) buf[1];
          ^
drivers/media/dvb-frontends/drx39xyj/drxj.c:2192:10: warning: â€˜buf’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  word |= (u32) buf[0];
          ^

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: a few more CodingStyle fixups
Mauro Carvalho Chehab [Thu, 16 Jan 2014 18:56:51 +0000 (15:56 -0300)] 
[media] drx-j: a few more CodingStyle fixups

Some whitespace cleanups.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Get rid of typedefs on drxh.h
Mauro Carvalho Chehab [Thu, 16 Jan 2014 18:33:14 +0000 (15:33 -0300)] 
[media] drx-j: Get rid of typedefs on drxh.h

This were fixed with the help of this small perl script:

#!/usr/bin/perl
my $dir = shift or die "need a dir";
my $type = shift or die "need type";
my $var = shift or die "need var";
sub handle_file {
my $file = shift;
my $out;
open IN, $file or die "can't open $file";
$out .= $_ while (<IN>);
close IN;
$out =~ s/\btypedef\s+($type)\s+\{([\d\D]+?)\s*\}\s+\b($var)[^\;]+\;/$type $var \{\2\};/;
$out =~ s,\b($var)_t\s+,$type \1 ,g;
$out =~ s,\bp_*($var)_t\s+,$type \1 *,g;
$out =~ s,\b($var)_t\b,$type \1,g;
$out =~ s,\bp_*($var)_t\b,$type \1 *,g;
open OUT, ">$file" or die "can't open $file";
print OUT $out;
close OUT;
}
sub parse_dir {
my $file = $File::Find::name;
return if (!($file =~ /.[ch]$/));
handle_file $file;
}
find({wanted => \&parse_dir, no_chdir => 1}, $dir);

Some manual work were needed.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of typedefs in drx_driver.h
Mauro Carvalho Chehab [Thu, 16 Jan 2014 15:51:36 +0000 (12:51 -0300)] 
[media] drx-j: get rid of typedefs in drx_driver.h

Most of the changes were done with scripts like:
for i in drivers/media/dvb-frontends/drx39xyj/*.[ch]; do perl -ne '$var = "drx_sig_quality"; s,\b($var)_t\s+,struct \1 ,g; s,\bp_*($var)_t\s+,struct \1 *,g; s,\b($var)_t\b,struct \1,g; s,\bp_*($var)_t\b,struct \1 *,g; print $_' <$i >a && mv a $i; done

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Get rid of drx39xyj/bsp_tuner.h
Mauro Carvalho Chehab [Thu, 16 Jan 2014 15:17:27 +0000 (12:17 -0300)] 
[media] drx-j: Get rid of drx39xyj/bsp_tuner.h

This file is not used anywhere. Drop it.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: make a few functions static
Mauro Carvalho Chehab [Thu, 16 Jan 2014 15:20:38 +0000 (12:20 -0300)] 
[media] drx-j: make a few functions static

drivers/media/dvb-frontends/drx39xyj/drx_driver.c:181:7: warning: no previous prototype for 'get_scan_context' [-Wmissing-prototypes]
 void *get_scan_context(pdrx_demod_instance_t demod, void *scan_context)

drivers/media/dvb-frontends/drx39xyj/drx_driver.c: At top level:
drivers/media/dvb-frontends/drx39xyj/drx_driver.c:842:5: warning: no previous prototype for 'ctrl_dump_registers' [-Wmissing-prototypes]
 int ctrl_dump_registers(pdrx_demod_instance_t demod,

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Some minor CodingStyle fixes at headers
Mauro Carvalho Chehab [Thu, 16 Jan 2014 15:05:15 +0000 (12:05 -0300)] 
[media] drx-j: Some minor CodingStyle fixes at headers

No functional changes.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Remove a bunch of unused but assigned vars
Mauro Carvalho Chehab [Thu, 16 Jan 2014 14:49:13 +0000 (11:49 -0300)] 
[media] drx-j: Remove a bunch of unused but assigned vars

None of those vars are used on those functions. Just remove them.

After this patch, there's just one of such warnings:

drivers/media/dvb-frontends/drx39xyj/drxj.c: In function 'ctrl_get_qam_sig_quality':
drivers/media/dvb-frontends/drx39xyj/drxj.c:7872:6: warning: variable 'ber_cnt' set but not used [-Wunused-but-set-variable]
  u32 ber_cnt = 0; /* BER count */

We'll keep it, as BER count will be useful when converting the
frontend to report statistics via DVBv5 API

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: remove the unused tuner_i2c_write_read() function
Mauro Carvalho Chehab [Thu, 16 Jan 2014 14:32:04 +0000 (11:32 -0300)] 
[media] drx-j: remove the unused tuner_i2c_write_read() function

This function is not static. Also, it is not used anywhere.
So, drop it.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: do more CodingStyle fixes
Mauro Carvalho Chehab [Thu, 16 Jan 2014 14:28:52 +0000 (11:28 -0300)] 
[media] drx-j: do more CodingStyle fixes

This time, use checkpatch --strict --fix.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Don't use CamelCase
Mauro Carvalho Chehab [Thu, 16 Jan 2014 14:24:57 +0000 (11:24 -0300)] 
[media] drx-j: Don't use CamelCase

There's no reason at all to use CamelCase here. Convert all of
them to normal case.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Use checkpatch --fix to solve several issues
Mauro Carvalho Chehab [Thu, 16 Jan 2014 14:08:15 +0000 (11:08 -0300)] 
[media] drx-j: Use checkpatch --fix to solve several issues

Instead of manually fixing the issues, use the --fix experimental
checkpatch. That solves a bunch of checkpatch issues.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: fix whitespacing on pointer parmameters
Mauro Carvalho Chehab [Thu, 16 Jan 2014 13:43:00 +0000 (10:43 -0300)] 
[media] drx-j: fix whitespacing on pointer parmameters

Patch generated with this script:

for i in drivers/media/dvb-frontends/drx39xyj/*.[ch]; do perl -ne 's,(enum|struct|void|int|u32|u64|u16|u8|s8|s16|s32|s64)\s+(\S+)\s+\*[ ]+,\1 \2 *,g; print $_' <$i >a && mv a $i; done

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of most of the typedefs
Mauro Carvalho Chehab [Tue, 20 Mar 2012 04:18:02 +0000 (01:18 -0300)] 
[media] drx-j: get rid of most of the typedefs

There are lots of typedefs there. Let's get rid of them.

Most of the work here is due to this small script:

if [ "$3" == "" ]; then
echo "usage: $0 type DRXName drx_name"
fi
t=$1; f=$2; g=$3
for i in *.[ch]; do
sed s,"p${f}_t","$t $g *",g <$i >a && mv a $i && \
sed s,"${f}_t","$t $g",g <$i >a && mv a $i
done

Just kept there the function typedefs, as those are still useful.

Yet, all those tuner_ops can likely be just removed on a latter
cleanup patch.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of the bsp*.h headers
Mauro Carvalho Chehab [Tue, 20 Mar 2012 04:13:25 +0000 (01:13 -0300)] 
[media] drx-j: get rid of the bsp*.h headers

Move them into drx_driver.h

That makes easier to cleanup further what's there at the
headers.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of the other typedefs at bsp_types.h
Mauro Carvalho Chehab [Tue, 20 Mar 2012 03:59:03 +0000 (00:59 -0300)] 
[media] drx-j: get rid of the other typedefs at bsp_types.h

Most of the work were done by those small scripts:

for i in *; do sed s,pDRXFrequency_t,"s32 *",g <$i >a && mv a $i; done
for i in *; do sed s,DRXFrequency_t,"s32",g <$i >a && mv a $i; done
for i in *; do sed s,pDRXSymbolrate_t,"u32 *",g <$i >a && mv a $i; done
for i in *; do sed s,DRXSymbolrate_t,"u32",g <$i >a && mv a $i; done
for i in *; do sed s,FALSE,false,g <$i >a && mv a $i; done
for i in *; do sed s,TRUE,true,g <$i >a && mv a $i; done
for i in *; do sed s,Bool_t,bool,g <$i >a && mv a $i; done
for i in *; do sed s,pbool,"bool *",g <$i >a && mv a $i; done

The only remaining things there are the return values.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of the integer typedefs
Mauro Carvalho Chehab [Tue, 20 Mar 2012 03:49:45 +0000 (00:49 -0300)] 
[media] drx-j: get rid of the integer typedefs

Patch created using this small script:

for j in 8 16 32; do for i in *; do sed s,pu${j}_t,"u$j *",g <$i >a && mv a $i; done; done
for j in 8 16 32; do for i in *; do sed s,ps${j}_t,"s$j *",g <$i >a && mv a $i; done; done
for j in 8 16 32; do for i in *; do sed s,s${j}_t,"s$j",g <$i >a && mv a $i; done; done
for j in 8 16 32; do for i in *; do sed s,u${j}_t,"u$j",g <$i >a && mv a $i; done; done

and fixing the bsp_types.h header.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: remove the "const" annotate on HICommand()
Mauro Carvalho Chehab [Tue, 20 Mar 2012 03:38:10 +0000 (00:38 -0300)] 
[media] drx-j: remove the "const" annotate on HICommand()

After removing the typedef, it is now clear that HICommand() were
abusing of a var that was expecting to be constant:

drivers/media/dvb-frontends/drx39xyj/drxj.c: In function â€˜HICommand’:
drivers/media/dvb-frontends/drx39xyj/drxj.c:2272:3: warning: passing argument 1 of â€˜drxDapDRXJFunct_g.writeReg16Func’ discards â€˜const’ qualifier from pointer target type [enabled by default]
drivers/media/dvb-frontends/drx39xyj/drxj.c:2272:3: note: expected â€˜struct i2c_device_addr *’ but argument is of type â€˜const struct i2c_device_addr *’
drivers/media/dvb-frontends/drx39xyj/drxj.c:2273:3: warning: passing argument 1 of â€˜drxDapDRXJFunct_g.writeReg16Func’ discards â€˜const’ qualifier from pointer target type [enabled by default]
drivers/media/dvb-frontends/drx39xyj/drxj.c:2273:3: note: expected â€˜struct i2c_device_addr *’ but argument is of type â€˜const struct i2c_device_addr *’
drivers/media/dvb-frontends/drx39xyj/drxj.c:2274:3: warning: passing argument 1 of â€˜drxDapDRXJFunct_g.writeReg16Func’ discards â€˜const’ qualifier from pointer target type [enabled by default]
drivers/media/dvb-frontends/drx39xyj/drxj.c:2274:3: note: expected â€˜struct i2c_device_addr *’ but argument is of type â€˜const struct i2c_device_addr *’
drivers/media/dvb-frontends/drx39xyj/drxj.c:2275:3: warning: passing argument 1 of â€˜drxDapDRXJFunct_g.writeReg16Func’ discards â€˜const’ qualifier from pointer target type [enabled by default]
drivers/media/dvb-frontends/drx39xyj/drxj.c:2275:3: note: expected â€˜struct i2c_device_addr *’ but argument is of type â€˜const struct i2c_device_addr *’
drivers/media/dvb-frontends/drx39xyj/drxj.c:2278:3: warning: passing argument 1 of â€˜drxDapDRXJFunct_g.writeReg16Func’ discards â€˜const’ qualifier from pointer target type [enabled by default]
drivers/media/dvb-frontends/drx39xyj/drxj.c:2278:3: note: expected â€˜struct i2c_device_addr *’ but argument is of type â€˜const struct i2c_device_addr *’
drivers/media/dvb-frontends/drx39xyj/drxj.c:2279:3: warning: passing argument 1 of â€˜drxDapDRXJFunct_g.writeReg16Func’ discards â€˜const’ qualifier from pointer target type [enabled by default]
drivers/media/dvb-frontends/drx39xyj/drxj.c:2279:3: note: expected â€˜struct i2c_device_addr *’ but argument is of type â€˜const struct i2c_device_addr *’
drivers/media/dvb-frontends/drx39xyj/drxj.c:2291:2: warning: passing argument 1 of â€˜drxDapDRXJFunct_g.writeReg16Func’ discards â€˜const’ qualifier from pointer target type [enabled by default]
drivers/media/dvb-frontends/drx39xyj/drxj.c:2291:2: note: expected â€˜struct i2c_device_addr *’ but argument is of type â€˜const struct i2c_device_addr *’
drivers/media/dvb-frontends/drx39xyj/drxj.c:2311:4: warning: passing argument 1 of â€˜drxDapDRXJFunct_g.readReg16Func’ discards â€˜const’ qualifier from pointer target type [enabled by default]
drivers/media/dvb-frontends/drx39xyj/drxj.c:2311:4: note: expected â€˜struct i2c_device_addr *’ but argument is of type â€˜const struct i2c_device_addr *’
drivers/media/dvb-frontends/drx39xyj/drxj.c:2315:3: warning: passing argument 1 of â€˜drxDapDRXJFunct_g.readReg16Func’ discards â€˜const’ qualifier from pointer target type [enabled by default]
drivers/media/dvb-frontends/drx39xyj/drxj.c:2315:3: note: expected â€˜struct i2c_device_addr *’ but argument is of type â€˜const struct i2c_device_addr *’

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: get rid of the typedefs on bsp_i2c.h
Mauro Carvalho Chehab [Tue, 20 Mar 2012 03:33:46 +0000 (00:33 -0300)] 
[media] drx-j: get rid of the typedefs on bsp_i2c.h

Most of the hard work here were done by this small script:

for i in *; do sed s,pI2CDeviceAddr_t,"struct i2c_device_addr *",g <$i >a && mv a $i; done
for i in *; do sed s,I2CDeviceAddr_t,"struct i2c_device_addr",g <$i >a && mv a $i; done

Only bsp_i2c.h were added by hand.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Fix CodingStyle
Mauro Carvalho Chehab [Tue, 20 Mar 2012 03:16:54 +0000 (00:16 -0300)] 
[media] drx-j: Fix CodingStyle

Make checkpatch.pl happy.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: Fix compilation and un-comment it
Mauro Carvalho Chehab [Tue, 20 Mar 2012 03:09:53 +0000 (00:09 -0300)] 
[media] drx-j: Fix compilation and un-comment it

There were some DVB internal API changes, since this driver were
written. Change it to work with the new API.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: CodingStyle fixes
Mauro Carvalho Chehab [Tue, 20 Mar 2012 03:00:42 +0000 (00:00 -0300)] 
[media] drx-j: CodingStyle fixes

Do the automatic CodingStyle fixes found at Lindent.

No functional changes.

Acked-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: put under 3-clause BSD license
Devin Heitmueller [Sun, 4 Jul 2010 21:42:11 +0000 (18:42 -0300)] 
[media] drx-j: put under 3-clause BSD license

Relicense the drx-j driver under a standard 3-clause BSD license, which makes
it GPL compatible.

This was done explicitly with permission from Trident Microsystems.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] drx-j: add a driver for Trident drx-j frontend
Devin Heitmueller [Tue, 14 Aug 2012 00:18:02 +0000 (21:18 -0300)] 
[media] drx-j: add a driver for Trident drx-j frontend

Add support for the Trident DRX-J driver, including a card profile for the
PCTV 80e which uses the chip.

Thanks to Trident for allowing the release of this code under a BSD license,
and of course Hauppauge/PCTV for pushing for its release to the community.

[pdickeybeta@gmail.com: modified to fix compilation errors and also to move
 the driver files from the drx39xy subdirectory to the frontends directory]

[m.chehab@samsung.com: fix merge conflicts, commented drx-j compilation and
 added EM28XX_R06_I2C_CLK setup also to the board setup]

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] DocBook: document DVB DMX_[ADD|REMOVE]_PID
Mauro Carvalho Chehab [Tue, 18 Feb 2014 23:35:51 +0000 (20:35 -0300)] 
[media] DocBook: document DVB DMX_[ADD|REMOVE]_PID

Those ioctls were added back in 2009, at changeset 1cb662a3144
but were never documented. Fortunately, the original commit is
good enough to serve as the basis for documenting it. Also, the
support for it is done by dmxdev implementation.

So, add a proper documentation for it, based on the description
of the original changeset.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] dvb_frontend: better handle lna set errors
Mauro Carvalho Chehab [Sun, 16 Feb 2014 09:36:17 +0000 (06:36 -0300)] 
[media] dvb_frontend: better handle lna set errors

If an attempt to set LNA fails, restore the cache to LNA_AUTO,
in order to make it to reflect the current LNA status.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] em28xx: Display the used DVB alternate
Mauro Carvalho Chehab [Sat, 25 Jan 2014 02:17:00 +0000 (23:17 -0300)] 
[media] em28xx: Display the used DVB alternate

That helps to understand what's going there.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] em28xx_dvb: only call the software filter if data
Mauro Carvalho Chehab [Sun, 2 Mar 2014 11:20:54 +0000 (08:20 -0300)] 
[media] em28xx_dvb: only call the software filter if data

Several URBs will be simply not filled. Don't call the DVB
core software filter for those empty URBs.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] em28xx: implement em28xx_usb_driver suspend, resume, reset_resume hooks
Shuah Khan [Sat, 22 Feb 2014 00:50:18 +0000 (21:50 -0300)] 
[media] em28xx: implement em28xx_usb_driver suspend, resume, reset_resume hooks

Implement em28xx_usb_driver suspend, resume, and reset_resume hooks.
These hooks will invoke em28xx core em28xx_suspend_extension() and
em28xx_resume_extension() to suspend and resume registered extensions.

Approach:
Add power management support to em28xx usb driver. This driver works in
conjunction with extensions for each of the functions on the USB device
for video/audio/dvb/remote functionality that is present on media USB
devices it supports. During suspend and resume each of these extensions
will have to do their part in suspending the components they control.

Adding suspend and resume hooks to the existing struct em28xx_ops will
enable the extensions the ability to implement suspend and resume hooks
to be called from em28xx driver. The overall approach is as follows:

-- add suspend and resume hooks to em28xx_ops
-- add suspend and resume routines to em28xx-core to invoke suspend
   and resume hooks for all registered extensions.
-- change em28xx dvb, audio, input, and video extensions to implement
   em28xx_ops: suspend and resume hooks. These hooks do what is necessary
   to suspend and resume the devices they control.

Signed-off-by: Shuah Khan <shuah.kh@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] em28xx-video: implement em28xx_ops: suspend/resume hooks
Shuah Khan [Sat, 22 Feb 2014 00:50:17 +0000 (21:50 -0300)] 
[media] em28xx-video: implement em28xx_ops: suspend/resume hooks

Implement em28xx_ops: suspend/resume hooks. em28xx usb driver will
invoke em28xx_ops: suspend and resume hooks for all its extensions
from its suspend() and resume() interfaces.

Signed-off-by: Shuah Khan <shuah.kh@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] em28xx-input: implement em28xx_ops: suspend/resume hooks
Shuah Khan [Sat, 22 Feb 2014 00:50:16 +0000 (21:50 -0300)] 
[media] em28xx-input: implement em28xx_ops: suspend/resume hooks

Implement em28xx_ops: suspend/resume hooks. em28xx usb driver will
invoke em28xx_ops: suspend and resume hooks for all its extensions
from its suspend() and resume() interfaces.

[m.chehab@samsung.com: Fix a breakage caused by calling a non-existing
 function call: schedule_delayed_work_sync(), and test if IR was defined
 at suspend/resume]

Signed-off-by: Shuah Khan <shuah.kh@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] em28xx-dvb: implement em28xx_ops: suspend/resume hooks
Shuah Khan [Sat, 22 Feb 2014 00:50:15 +0000 (21:50 -0300)] 
[media] em28xx-dvb: implement em28xx_ops: suspend/resume hooks

Implement em28xx_ops: suspend/resume hooks. em28xx usb driver will
invoke em28xx_ops: suspend and resume hooks for all its extensions
from its suspend() and resume() interfaces.

Signed-off-by: Shuah Khan <shuah.kh@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] em28xx-audio: implement em28xx_ops: suspend/resume hooks
Shuah Khan [Sat, 22 Feb 2014 00:50:14 +0000 (21:50 -0300)] 
[media] em28xx-audio: implement em28xx_ops: suspend/resume hooks

Implement em28xx_ops: suspend/resume hooks. em28xx usb driver will
invoke em28xx_ops: suspend and resume hooks for all its extensions
from its suspend() and resume() interfaces.

Signed-off-by: Shuah Khan <shuah.kh@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] em28xx: add suspend/resume to em28xx_ops
Shuah Khan [Sat, 22 Feb 2014 00:50:13 +0000 (21:50 -0300)] 
[media] em28xx: add suspend/resume to em28xx_ops

em28xx usb driver will have to suspend and resume its extensions. Adding
suspend and resume to em28xx_ops gives extensions the ability to install
suspend and resume that can be invoked from em28xx_usb driver suspend()
and resume() interfaces.

Approach:
Add power management support to em28xx usb driver. This driver works in
conjunction with extensions for each of the functions on the USB device
for video/audio/dvb/remote functionality that is present on media USB
devices it supports. During suspend and resume each of these extensions
will have to do their part in suspending the components they control.

Adding suspend and resume hooks to the existing struct em28xx_ops will
enable the extensions the ability to implement suspend and resume hooks
to be called from em28xx driver. The overall approach is as follows:

-- add suspend and resume hooks to em28xx_ops
-- add suspend and resume routines to em28xx-core to invoke suspend
   and resume hooks for all registered extensions.
-- change em28xx dvb, audio, input, and video extensions to implement
   em28xx_ops: suspend and resume hooks. These hooks do what is necessary
   to suspend and resume the devices they control.

Signed-off-by: Shuah Khan <shuah.kh@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] au0828: rework GPIO management for HVR-950q
Devin Heitmueller [Mon, 19 Aug 2013 21:25:16 +0000 (18:25 -0300)] 
[media] au0828: rework GPIO management for HVR-950q

Restructure the way we bring the various GPIOs out of reset.  In particular:

1.  we only need to setup the GPIOs as outputs once
2.  there's no point in writing 0x40 to register 0x00 since that's the EEPROM
    write protect and already it's configured as an input
3.  Separate out the act of enabling the power supply and bringing the tuner
    and demod out of reset.  If you don't then the chip may not be properly
    enabled (as the power supply is still ramping up when the chip comes
    out of reset).  This can result in probing failures.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] ds3000: fix reading array out of bound in ds3000_read_snr
Heinrich Schuchardt [Fri, 28 Feb 2014 02:04:08 +0000 (23:04 -0300)] 
[media] ds3000: fix reading array out of bound in ds3000_read_snr

An attempt was made to read dvbs2_snr_tab[80],
though dvbs2_snr_tab has only 80 elements.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] stb6100: fix buffer length check in stb6100_write_reg_range()
Alexander Shiyan [Wed, 26 Feb 2014 02:41:14 +0000 (23:41 -0300)] 
[media] stb6100: fix buffer length check in stb6100_write_reg_range()

We are checking sizeof() the wrong variable!

Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] stv0900: remove an unneeded check
Dan Carpenter [Wed, 26 Feb 2014 02:26:41 +0000 (23:26 -0300)] 
[media] stv0900: remove an unneeded check

No need to check lock twice here.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] m88rs2000: prevent frontend crash on continuous transponder scans
Malcolm Priestley [Wed, 26 Feb 2014 02:11:34 +0000 (23:11 -0300)] 
[media] m88rs2000: prevent frontend crash on continuous transponder scans

Add m88rs2000_get_tune_settings, min delay of 2000 ms on symbol
rate more than 3000000 and delay of 3000ms less than this.

Adding min delay prevents crashing the frontend on continuous
transponder scans. Other dvb_frontend_tune_settings remain as default.

This makes very little time difference to good channel scans, but slows down
the set frontend where lock can never be achieved i.e. DVB-S2.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: stable@vger.kernel.org
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] m88rs2000: add caps FE_CAN_INVERSION_AUTO
Malcolm Priestley [Wed, 26 Feb 2014 02:05:39 +0000 (23:05 -0300)] 
[media] m88rs2000: add caps FE_CAN_INVERSION_AUTO

The m88rs2000 frontend is always auto inversion.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: stable@vger.kernel.org
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] s5p-mfc: Add Horizontal and Vertical MV Search Range
Amit Grover [Tue, 4 Feb 2014 09:59:59 +0000 (06:59 -0300)] 
[media] s5p-mfc: Add Horizontal and Vertical MV Search Range

This patch adds Controls to set Horizontal and Vertical search range
for Motion Estimation block for Samsung MFC video Encoders.

Signed-off-by: Swami Nathan <swaminath.p@samsung.com>
Signed-off-by: Amit Grover <amit.grover@samsung.com>
Signed-off-by: Kamil Debski <k.debski@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] v4l2: Add settings for Horizontal and Vertical MV Search Range
Amit Grover [Tue, 4 Feb 2014 09:59:58 +0000 (06:59 -0300)] 
[media] v4l2: Add settings for Horizontal and Vertical MV Search Range

Adding V4L2 controls for horizontal and vertical search range in pixels
for motion estimation module in video encoder.

Signed-off-by: Swami Nathan <swaminath.p@samsung.com>
Signed-off-by: Amit Grover <amit.grover@samsung.com>
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Kamil Debski <k.debski@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] rtl28xxu: add chipset version comments into device list
Jan Vcelak [Wed, 26 Feb 2014 18:33:40 +0000 (15:33 -0300)] 
[media] rtl28xxu: add chipset version comments into device list

Signed-off-by: Jan Vcelak <jv@fcelda.cz>
Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] rtl28xxu: add USB ID for Genius TVGo DVB-T03
Jan Vcelak [Wed, 26 Feb 2014 18:33:39 +0000 (15:33 -0300)] 
[media] rtl28xxu: add USB ID for Genius TVGo DVB-T03

0458:707f KYE Systems Corp. (Mouse Systems) TVGo DVB-T03 [RTL2832]

The USB dongle uses RTL2832U demodulator and FC0012 tuner.

Signed-off-by: Jan Vcelak <jv@fcelda.cz>
Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] gspca_topro: Add a couple of missing length check in the packet parsing code
Hans de Goede [Sun, 23 Feb 2014 22:01:58 +0000 (19:01 -0300)] 
[media] gspca_topro: Add a couple of missing length check in the packet parsing code

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] gspca_stv06xx: remove an unneeded check
Dan Carpenter [Tue, 18 Feb 2014 15:00:45 +0000 (12:00 -0300)] 
[media] gspca_stv06xx: remove an unneeded check

"err" is zero here so we don't need to check again.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] media: gspca: sn9c20x: add ID for Genius Look 1320 V2
Wolfram Sang [Sat, 1 Feb 2014 18:26:00 +0000 (15:26 -0300)] 
[media] media: gspca: sn9c20x: add ID for Genius Look 1320 V2

Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Cc: stable@vger.kernel.org
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] gspca_kinect: fix messages about kinect_read() return value
Antonio Ospite [Mon, 30 Dec 2013 16:41:46 +0000 (13:41 -0300)] 
[media] gspca_kinect: fix messages about kinect_read() return value

Messages relative to kinect_read() are printing "res" which contains the
return value of a previous kinect_write().

Print the correct value in the messages.

Cc: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Antonio Ospite <ospite@studenti.unina.it>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] gspca_kinect: fix kinect_read() error path
Antonio Ospite [Mon, 30 Dec 2013 16:41:45 +0000 (13:41 -0300)] 
[media] gspca_kinect: fix kinect_read() error path

The error checking code relative to the invocations of kinect_read()
does not return the actual return code of the function just called, it
returns "res" which still contains the value of the last invocation of
a previous kinect_write().

Return the proper value, and while at it also report with -EREMOTEIO the
case of a partial transfer.

Reported-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Antonio Ospite <ospite@studenti.unina.it>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] s2255drv: upgrade to videobuf2
sensoray-dev [Wed, 12 Feb 2014 20:25:45 +0000 (17:25 -0300)] 
[media] s2255drv: upgrade to videobuf2

Upgrade to videobuf2 libraries.
No errors reported with "v4l2-compliance -s".

Signed-off-by: Dean Anderson <linux-dev@sensoray.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] omap_vout: avoid sleep_on race
Arnd Bergmann [Thu, 2 Jan 2014 12:07:29 +0000 (09:07 -0300)] 
[media] omap_vout: avoid sleep_on race

sleep_on and its variants are broken and going away soon. This changes
the omap vout driver to use wait_event_interruptible_timeout instead,
which fixes potential race where the dma is complete before we
schedule.

[hans.verkuil@cisco.com: replaced interruptible_sleep_on_timeout by
wait_event_interruptible_timeout in the commit msg, obvious typo]

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Cc: Mauro Carvalho Chehab <m.chehab@samsung.com>
Cc: linux-media@vger.kernel.org
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] radio-cadet: avoid interruptible_sleep_on race
Hans Verkuil [Mon, 10 Feb 2014 10:21:36 +0000 (07:21 -0300)] 
[media] radio-cadet: avoid interruptible_sleep_on race

interruptible_sleep_on is racy and going away. This replaces
one use in the radio-cadet driver with a wait_event_interruptible
call. Special care was taken that accesses to the rdsin and rdsout
indices are always done with dev->lock held.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] ths8200: Format adjustment
Martin Bugge [Fri, 7 Feb 2014 08:11:05 +0000 (05:11 -0300)] 
[media] ths8200: Format adjustment

Closer inspection on exact transmitted format showed that
we needed to add 1 on vertical sync.

Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Martin Bugge <marbugge@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] ths8200: Corrected sync polarities setting
Martin Bugge [Fri, 7 Feb 2014 08:11:04 +0000 (05:11 -0300)] 
[media] ths8200: Corrected sync polarities setting

HS_IN/VS_IN was always set to positive.

Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Martin Bugge <marbugge@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] ths8200: Zero blanking level for RGB
Martin Bugge [Fri, 7 Feb 2014 08:11:03 +0000 (05:11 -0300)] 
[media] ths8200: Zero blanking level for RGB

Currently only RGB444 input data is supported so set to zero.

Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Martin Bugge <marbugge@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] s2255drv: cleanup of s2255_fh
Dean Anderson [Wed, 5 Feb 2014 20:38:42 +0000 (17:38 -0300)] 
[media] s2255drv: cleanup of s2255_fh

Removal of unnecessary parameters from s2255_fh.

Signed-off-by: Dean Anderson <linux-dev@sensoray.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] s2255drv: fix for return code not checked
Dean Anderson [Wed, 5 Feb 2014 18:58:20 +0000 (15:58 -0300)] 
[media] s2255drv: fix for return code not checked

Start acquisition return code was not being checked.  Return error
if start acquisition fails.

Signed-off-by: Dean Anderson <linux-dev@sensoray.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] s2255drv: dynamic memory allocation efficiency fix
Dean Anderson [Wed, 5 Feb 2014 18:43:51 +0000 (15:43 -0300)] 
[media] s2255drv: dynamic memory allocation efficiency fix

Driver was allocating a kernel buffer each time it was sending a command.
It is better to allocate this buffer once at startup.

Signed-off-by: Dean Anderson <linux-dev@sensoray.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] s2255drv: remove redundant parameter
Dean Anderson [Wed, 5 Feb 2014 18:18:55 +0000 (15:18 -0300)] 
[media] s2255drv: remove redundant parameter

Removing duplicate fmt from buffer structure.

Signed-off-by: Dean Anderson <linux-dev@sensoray.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] s2255drv: buffer setup fix
Dean Anderson [Wed, 5 Feb 2014 17:58:06 +0000 (14:58 -0300)] 
[media] s2255drv: buffer setup fix

Buffer setup should check if minimum number of buffers is used.

Signed-off-by: Dean Anderson <linux-dev@sensoray.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] s2255drv: refactoring s2255_channel to s2255_vc
Dean Anderson [Tue, 4 Feb 2014 21:16:24 +0000 (18:16 -0300)] 
[media] s2255drv: refactoring s2255_channel to s2255_vc

Renaming s2255_channel and all instances of channel to vc (video channel).

Signed-off-by: Dean Anderson <linux-dev@sensoray.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] s2255drv: removal of s2255_dmaqueue structure
Dean Anderson [Tue, 4 Feb 2014 20:18:03 +0000 (17:18 -0300)] 
[media] s2255drv: removal of s2255_dmaqueue structure

Removal of unused and unnecessary s2255dma_queue structure.

Signed-off-by: Dean Anderson <linux-dev@sensoray.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] davinci: vpfe: remove deprecated IRQF_DISABLED
Michael Opdenacker [Mon, 9 Dec 2013 10:16:22 +0000 (07:16 -0300)] 
[media] davinci: vpfe: remove deprecated IRQF_DISABLED

This patch proposes to remove the use of the IRQF_DISABLED flag

It's a NOOP since 2.6.35 and it will be removed one day.

Signed-off-by: Michael Opdenacker <michael.opdenacker@free-electrons.com>
Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] staging: davinci_vpfe: fix error check
Levente Kurusa [Sat, 15 Feb 2014 10:17:11 +0000 (07:17 -0300)] 
[media] staging: davinci_vpfe: fix error check

The check would check the pointer, which is never less than 0.
According to the error message, the correct check would be
to check the return value of ipipe_mode. Check that instead.

Reported-by: David Binderman <dcb314@hotmail.com>
Signed-off-by: Levente Kurusa <levex@linux.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
10 years ago[media] uvcvideo: Enable VIDIOC_CREATE_BUFS
Philipp Zabel [Wed, 29 Jan 2014 16:13:52 +0000 (13:13 -0300)] 
[media] uvcvideo: Enable VIDIOC_CREATE_BUFS

This patch enables the ioctl to create additional buffers on the
videobuf2 capture queue.

[laurent.pinchart@ideasonboard.com: Acquire privileges instead of just
checking them in VIDIOC_CREATE_BUFS implementation]

Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Tested-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
This page took 0.048091 seconds and 5 git commands to generate.