summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2007-11-16 17:28:21 -0200
committerMauro Carvalho Chehab <mchehab@infradead.org>2007-11-16 17:28:21 -0200
commite33f3357a8412f6941641fd3c40da7305987b03d (patch)
tree6e1d0b603c069d9030945bf87f446042f8e72dde /linux/drivers/media/video
parent7261c59f9f24fea44aac4651b3f587be55ad2d80 (diff)
downloadmediapointer-dvb-s2-e33f3357a8412f6941641fd3c40da7305987b03d.tar.gz
mediapointer-dvb-s2-e33f3357a8412f6941641fd3c40da7305987b03d.tar.bz2
Fix driver for i386 architectures
From: Mauro Carvalho Chehab <mchehab@infradead.org> Also, fixed backporting up to 2.6.20 Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'linux/drivers/media/video')
-rw-r--r--linux/drivers/media/video/tuner-xc2028-types.h14
-rw-r--r--linux/drivers/media/video/tuner-xc2028.c13
2 files changed, 16 insertions, 11 deletions
diff --git a/linux/drivers/media/video/tuner-xc2028-types.h b/linux/drivers/media/video/tuner-xc2028-types.h
index 388884491..a9e2e0562 100644
--- a/linux/drivers/media/video/tuner-xc2028-types.h
+++ b/linux/drivers/media/video/tuner-xc2028-types.h
@@ -82,13 +82,13 @@
/* Audio types */
-#define V4L2_STD_A2_A (1L<<32)
-#define V4L2_STD_A2_B (1L<<33)
-#define V4L2_STD_NICAM_A (1L<<34)
-#define V4L2_STD_NICAM_B (1L<<35)
-#define V4L2_STD_AM (1L<<36)
-#define V4L2_STD_BTSC (1L<<37)
-#define V4L2_STD_EIAJ (1L<<38)
+#define V4L2_STD_A2_A (1LL<<32)
+#define V4L2_STD_A2_B (1LL<<33)
+#define V4L2_STD_NICAM_A (1LL<<34)
+#define V4L2_STD_NICAM_B (1LL<<35)
+#define V4L2_STD_AM (1LL<<36)
+#define V4L2_STD_BTSC (1LL<<37)
+#define V4L2_STD_EIAJ (1LL<<38)
#define V4L2_STD_A2 (V4L2_STD_A2_A | V4L2_STD_A2_B)
#define V4L2_STD_NICAM (V4L2_STD_NICAM_A | V4L2_STD_NICAM_B)
diff --git a/linux/drivers/media/video/tuner-xc2028.c b/linux/drivers/media/video/tuner-xc2028.c
index 9736a07cf..d8d960e7b 100644
--- a/linux/drivers/media/video/tuner-xc2028.c
+++ b/linux/drivers/media/video/tuner-xc2028.c
@@ -30,6 +30,10 @@
#include <linux/dvb/frontend.h>
#include "dvb_frontend.h"
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 22)
+#define strcasecmp(a, b) strnicmp(a, b, sizeof(a))
+#endif
+
#define PREFIX "xc2028"
static int debug;
@@ -205,7 +209,7 @@ void dump_firm_type(unsigned int type)
printk("SCODE ");
}
-static v4l2_std_id parse_audio_std_option(void)
+static v4l2_std_id parse_audio_std_option(void)
{
if (strcasecmp(audio_std, "A2"))
return V4L2_STD_A2;
@@ -329,9 +333,10 @@ static int load_all_firmwares(struct dvb_frontend *fe)
if ((!size) || (size + p > endp)) {
tuner_err("Firmware type ");
dump_firm_type(type);
- printk("(%x), id %lx is corrupted "
- "(size=%ld, expected %d)\n",
- type, (unsigned long)id, endp - p, size);
+ printk("(%x), id %llx is corrupted "
+ "(size=%d, expected %d)\n",
+ type, id,
+ (unsigned)(endp - p), size);
goto corrupt;
}