summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/cx18
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2009-07-30 20:10:43 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-07-30 20:10:43 -0300
commit9a373df780905ef4e981bae11edccba07d94e305 (patch)
tree5339c90619daa9375c5ca37023b40eea1a8f932e /linux/drivers/media/video/cx18
parent49baec9371209e4c77da0321f577b9a33be0fe48 (diff)
parent74171fb0a60787bfd13f6a4a98450f0f5ed4d0dc (diff)
downloadmediapointer-dvb-s2-9a373df780905ef4e981bae11edccba07d94e305.tar.gz
mediapointer-dvb-s2-9a373df780905ef4e981bae11edccba07d94e305.tar.bz2
merge: http://kernellabs.com/hg/~mkrufky/cx23885
From: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'linux/drivers/media/video/cx18')
-rw-r--r--linux/drivers/media/video/cx18/cx18-controls.c3
-rw-r--r--linux/drivers/media/video/cx18/cx18-i2c.c2
2 files changed, 4 insertions, 1 deletions
diff --git a/linux/drivers/media/video/cx18/cx18-controls.c b/linux/drivers/media/video/cx18/cx18-controls.c
index 5136df198..93f0dae01 100644
--- a/linux/drivers/media/video/cx18/cx18-controls.c
+++ b/linux/drivers/media/video/cx18/cx18-controls.c
@@ -20,6 +20,7 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
* 02111-1307 USA
*/
+#include <linux/kernel.h>
#include "cx18-driver.h"
#include "cx18-cards.h"
@@ -317,7 +318,7 @@ int cx18_s_ext_ctrls(struct file *file, void *fh, struct v4l2_ext_controls *c)
idx = p.audio_properties & 0x03;
/* The audio clock of the digitizer must match the codec sample
rate otherwise you get some very strange effects. */
- if (idx < sizeof(freqs))
+ if (idx < ARRAY_SIZE(freqs))
cx18_call_all(cx, audio, s_clock_freq, freqs[idx]);
return err;
}
diff --git a/linux/drivers/media/video/cx18/cx18-i2c.c b/linux/drivers/media/video/cx18/cx18-i2c.c
index 3c76a1e27..cee650c58 100644
--- a/linux/drivers/media/video/cx18/cx18-i2c.c
+++ b/linux/drivers/media/video/cx18/cx18-i2c.c
@@ -190,7 +190,9 @@ static int cx18_getsda(void *data)
/* template for i2c-bit-algo */
static struct i2c_adapter cx18_i2c_adap_template = {
.name = "cx18 i2c driver",
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 31)
.id = I2C_HW_B_CX2341X,
+#endif
.algo = NULL, /* set by i2c-algo-bit */
.algo_data = NULL, /* filled from template */
.owner = THIS_MODULE,