diff options
Diffstat (limited to 'drivers/media/video/cx88')
-rw-r--r-- | drivers/media/video/cx88/cx88-blackbird.c | 3 | ||||
-rw-r--r-- | drivers/media/video/cx88/cx88-core.c | 56 | ||||
-rw-r--r-- | drivers/media/video/cx88/cx88-dvb.c | 1 | ||||
-rw-r--r-- | drivers/media/video/cx88/cx88-i2c.c | 1 | ||||
-rw-r--r-- | drivers/media/video/cx88/cx88-video.c | 7 | ||||
-rw-r--r-- | drivers/media/video/cx88/cx88.h | 1 |
6 files changed, 9 insertions, 60 deletions
diff --git a/drivers/media/video/cx88/cx88-blackbird.c b/drivers/media/video/cx88/cx88-blackbird.c index 5a7f940565cc..a49062119313 100644 --- a/drivers/media/video/cx88/cx88-blackbird.c +++ b/drivers/media/video/cx88/cx88-blackbird.c | |||
@@ -32,6 +32,7 @@ | |||
32 | #include <linux/firmware.h> | 32 | #include <linux/firmware.h> |
33 | 33 | ||
34 | #include "cx88.h" | 34 | #include "cx88.h" |
35 | #include <media/v4l2-common.h> | ||
35 | 36 | ||
36 | MODULE_DESCRIPTION("driver for cx2388x/cx23416 based mpeg encoder cards"); | 37 | MODULE_DESCRIPTION("driver for cx2388x/cx23416 based mpeg encoder cards"); |
37 | MODULE_AUTHOR("Jelle Foks <jelle@foks.8m.com>, Gerd Knorr <kraxel@bytesex.org> [SuSE Labs]"); | 38 | MODULE_AUTHOR("Jelle Foks <jelle@foks.8m.com>, Gerd Knorr <kraxel@bytesex.org> [SuSE Labs]"); |
@@ -1374,7 +1375,7 @@ static int mpeg_do_ioctl(struct inode *inode, struct file *file, | |||
1374 | struct cx88_core *core = dev->core; | 1375 | struct cx88_core *core = dev->core; |
1375 | 1376 | ||
1376 | if (debug > 1) | 1377 | if (debug > 1) |
1377 | cx88_print_ioctl(core->name,cmd); | 1378 | v4l_print_ioctl(core->name,cmd); |
1378 | 1379 | ||
1379 | switch (cmd) { | 1380 | switch (cmd) { |
1380 | 1381 | ||
diff --git a/drivers/media/video/cx88/cx88-core.c b/drivers/media/video/cx88/cx88-core.c index bb6eb54e19ce..fc814d198694 100644 --- a/drivers/media/video/cx88/cx88-core.c +++ b/drivers/media/video/cx88/cx88-core.c | |||
@@ -34,6 +34,7 @@ | |||
34 | #include <linux/videodev2.h> | 34 | #include <linux/videodev2.h> |
35 | 35 | ||
36 | #include "cx88.h" | 36 | #include "cx88.h" |
37 | #include <media/v4l2-common.h> | ||
37 | 38 | ||
38 | MODULE_DESCRIPTION("v4l2 driver module for cx2388x based TV cards"); | 39 | MODULE_DESCRIPTION("v4l2 driver module for cx2388x based TV cards"); |
39 | MODULE_AUTHOR("Gerd Knorr <kraxel@bytesex.org> [SuSE Labs]"); | 40 | MODULE_AUTHOR("Gerd Knorr <kraxel@bytesex.org> [SuSE Labs]"); |
@@ -76,60 +77,6 @@ static unsigned int cx88_devcount; | |||
76 | static LIST_HEAD(cx88_devlist); | 77 | static LIST_HEAD(cx88_devlist); |
77 | static DECLARE_MUTEX(devlist); | 78 | static DECLARE_MUTEX(devlist); |
78 | 79 | ||
79 | /* ------------------------------------------------------------------ */ | ||
80 | /* debug help functions */ | ||
81 | |||
82 | static const char *v4l1_ioctls[] = { | ||
83 | "0", "CGAP", "GCHAN", "SCHAN", "GTUNER", "STUNER", "GPICT", "SPICT", | ||
84 | "CCAPTURE", "GWIN", "SWIN", "GFBUF", "SFBUF", "KEY", "GFREQ", | ||
85 | "SFREQ", "GAUDIO", "SAUDIO", "SYNC", "MCAPTURE", "GMBUF", "GUNIT", | ||
86 | "GCAPTURE", "SCAPTURE", "SPLAYMODE", "SWRITEMODE", "GPLAYINFO", | ||
87 | "SMICROCODE", "GVBIFMT", "SVBIFMT" }; | ||
88 | #define V4L1_IOCTLS ARRAY_SIZE(v4l1_ioctls) | ||
89 | |||
90 | static const char *v4l2_ioctls[] = { | ||
91 | "QUERYCAP", "1", "ENUM_PIXFMT", "ENUM_FBUFFMT", "G_FMT", "S_FMT", | ||
92 | "G_COMP", "S_COMP", "REQBUFS", "QUERYBUF", "G_FBUF", "S_FBUF", | ||
93 | "G_WIN", "S_WIN", "PREVIEW", "QBUF", "16", "DQBUF", "STREAMON", | ||
94 | "STREAMOFF", "G_PERF", "G_PARM", "S_PARM", "G_STD", "S_STD", | ||
95 | "ENUMSTD", "ENUMINPUT", "G_CTRL", "S_CTRL", "G_TUNER", "S_TUNER", | ||
96 | "G_FREQ", "S_FREQ", "G_AUDIO", "S_AUDIO", "35", "QUERYCTRL", | ||
97 | "QUERYMENU", "G_INPUT", "S_INPUT", "ENUMCVT", "41", "42", "43", | ||
98 | "44", "45", "G_OUTPUT", "S_OUTPUT", "ENUMOUTPUT", "G_AUDOUT", | ||
99 | "S_AUDOUT", "ENUMFX", "G_EFFECT", "S_EFFECT", "G_MODULATOR", | ||
100 | "S_MODULATOR" | ||
101 | }; | ||
102 | #define V4L2_IOCTLS ARRAY_SIZE(v4l2_ioctls) | ||
103 | |||
104 | void cx88_print_ioctl(char *name, unsigned int cmd) | ||
105 | { | ||
106 | char *dir; | ||
107 | |||
108 | switch (_IOC_DIR(cmd)) { | ||
109 | case _IOC_NONE: dir = "--"; break; | ||
110 | case _IOC_READ: dir = "r-"; break; | ||
111 | case _IOC_WRITE: dir = "-w"; break; | ||
112 | case _IOC_READ | _IOC_WRITE: dir = "rw"; break; | ||
113 | default: dir = "??"; break; | ||
114 | } | ||
115 | switch (_IOC_TYPE(cmd)) { | ||
116 | case 'v': | ||
117 | printk(KERN_DEBUG "%s: ioctl 0x%08x (v4l1, %s, VIDIOC%s)\n", | ||
118 | name, cmd, dir, (_IOC_NR(cmd) < V4L1_IOCTLS) ? | ||
119 | v4l1_ioctls[_IOC_NR(cmd)] : "???"); | ||
120 | break; | ||
121 | case 'V': | ||
122 | printk(KERN_DEBUG "%s: ioctl 0x%08x (v4l2, %s, VIDIOC_%s)\n", | ||
123 | name, cmd, dir, (_IOC_NR(cmd) < V4L2_IOCTLS) ? | ||
124 | v4l2_ioctls[_IOC_NR(cmd)] : "???"); | ||
125 | break; | ||
126 | default: | ||
127 | printk(KERN_DEBUG "%s: ioctl 0x%08x (???, %s, #%d)\n", | ||
128 | name, cmd, dir, _IOC_NR(cmd)); | ||
129 | } | ||
130 | } | ||
131 | |||
132 | /* ------------------------------------------------------------------ */ | ||
133 | #define NO_SYNC_LINE (-1U) | 80 | #define NO_SYNC_LINE (-1U) |
134 | 81 | ||
135 | static u32* cx88_risc_field(u32 *rp, struct scatterlist *sglist, | 82 | static u32* cx88_risc_field(u32 *rp, struct scatterlist *sglist, |
@@ -1208,7 +1155,6 @@ void cx88_core_put(struct cx88_core *core, struct pci_dev *pci) | |||
1208 | 1155 | ||
1209 | /* ------------------------------------------------------------------ */ | 1156 | /* ------------------------------------------------------------------ */ |
1210 | 1157 | ||
1211 | EXPORT_SYMBOL(cx88_print_ioctl); | ||
1212 | EXPORT_SYMBOL(cx88_print_irqbits); | 1158 | EXPORT_SYMBOL(cx88_print_irqbits); |
1213 | 1159 | ||
1214 | EXPORT_SYMBOL(cx88_core_irq); | 1160 | EXPORT_SYMBOL(cx88_core_irq); |
diff --git a/drivers/media/video/cx88/cx88-dvb.c b/drivers/media/video/cx88/cx88-dvb.c index 201050478711..c63f20fdff48 100644 --- a/drivers/media/video/cx88/cx88-dvb.c +++ b/drivers/media/video/cx88/cx88-dvb.c | |||
@@ -31,6 +31,7 @@ | |||
31 | 31 | ||
32 | #include "cx88.h" | 32 | #include "cx88.h" |
33 | #include "dvb-pll.h" | 33 | #include "dvb-pll.h" |
34 | #include <media/v4l2-common.h> | ||
34 | 35 | ||
35 | #ifdef HAVE_MT352 | 36 | #ifdef HAVE_MT352 |
36 | # include "mt352.h" | 37 | # include "mt352.h" |
diff --git a/drivers/media/video/cx88/cx88-i2c.c b/drivers/media/video/cx88/cx88-i2c.c index c6492089ee1a..f720901e9638 100644 --- a/drivers/media/video/cx88/cx88-i2c.c +++ b/drivers/media/video/cx88/cx88-i2c.c | |||
@@ -30,6 +30,7 @@ | |||
30 | #include <asm/io.h> | 30 | #include <asm/io.h> |
31 | 31 | ||
32 | #include "cx88.h" | 32 | #include "cx88.h" |
33 | #include <media/v4l2-common.h> | ||
33 | 34 | ||
34 | static unsigned int i2c_debug = 0; | 35 | static unsigned int i2c_debug = 0; |
35 | module_param(i2c_debug, int, 0644); | 36 | module_param(i2c_debug, int, 0644); |
diff --git a/drivers/media/video/cx88/cx88-video.c b/drivers/media/video/cx88/cx88-video.c index b76abb9b8961..9a02515fe18b 100644 --- a/drivers/media/video/cx88/cx88-video.c +++ b/drivers/media/video/cx88/cx88-video.c | |||
@@ -33,6 +33,7 @@ | |||
33 | #include <asm/div64.h> | 33 | #include <asm/div64.h> |
34 | 34 | ||
35 | #include "cx88.h" | 35 | #include "cx88.h" |
36 | #include <media/v4l2-common.h> | ||
36 | 37 | ||
37 | /* Include V4L1 specific functions. Should be removed soon */ | 38 | /* Include V4L1 specific functions. Should be removed soon */ |
38 | #include <linux/videodev.h> | 39 | #include <linux/videodev.h> |
@@ -1118,7 +1119,7 @@ static int video_do_ioctl(struct inode *inode, struct file *file, | |||
1118 | int err; | 1119 | int err; |
1119 | 1120 | ||
1120 | if (video_debug > 1) | 1121 | if (video_debug > 1) |
1121 | cx88_print_ioctl(core->name,cmd); | 1122 | v4l_print_ioctl(core->name,cmd); |
1122 | switch (cmd) { | 1123 | switch (cmd) { |
1123 | 1124 | ||
1124 | /* --- capabilities ------------------------------------------ */ | 1125 | /* --- capabilities ------------------------------------------ */ |
@@ -1254,7 +1255,7 @@ int cx88_do_ioctl(struct inode *inode, struct file *file, int radio, | |||
1254 | 1255 | ||
1255 | dprintk( 1, "CORE IOCTL: 0x%x\n", cmd ); | 1256 | dprintk( 1, "CORE IOCTL: 0x%x\n", cmd ); |
1256 | if (video_debug > 1) | 1257 | if (video_debug > 1) |
1257 | cx88_print_ioctl(core->name,cmd); | 1258 | v4l_print_ioctl(core->name,cmd); |
1258 | 1259 | ||
1259 | switch (cmd) { | 1260 | switch (cmd) { |
1260 | /* ---------- tv norms ---------- */ | 1261 | /* ---------- tv norms ---------- */ |
@@ -1474,7 +1475,7 @@ static int radio_do_ioctl(struct inode *inode, struct file *file, | |||
1474 | struct cx88_core *core = dev->core; | 1475 | struct cx88_core *core = dev->core; |
1475 | 1476 | ||
1476 | if (video_debug > 1) | 1477 | if (video_debug > 1) |
1477 | cx88_print_ioctl(core->name,cmd); | 1478 | v4l_print_ioctl(core->name,cmd); |
1478 | 1479 | ||
1479 | switch (cmd) { | 1480 | switch (cmd) { |
1480 | case VIDIOC_QUERYCAP: | 1481 | case VIDIOC_QUERYCAP: |
diff --git a/drivers/media/video/cx88/cx88.h b/drivers/media/video/cx88/cx88.h index 6d370d1b333f..022ef13c45bc 100644 --- a/drivers/media/video/cx88/cx88.h +++ b/drivers/media/video/cx88/cx88.h | |||
@@ -461,7 +461,6 @@ struct cx8802_dev { | |||
461 | 461 | ||
462 | extern void cx88_print_irqbits(char *name, char *tag, char **strings, | 462 | extern void cx88_print_irqbits(char *name, char *tag, char **strings, |
463 | u32 bits, u32 mask); | 463 | u32 bits, u32 mask); |
464 | extern void cx88_print_ioctl(char *name, unsigned int cmd); | ||
465 | 464 | ||
466 | extern int cx88_core_irq(struct cx88_core *core, u32 status); | 465 | extern int cx88_core_irq(struct cx88_core *core, u32 status); |
467 | extern void cx88_wakeup(struct cx88_core *core, | 466 | extern void cx88_wakeup(struct cx88_core *core, |