summaryrefslogtreecommitdiff
path: root/drivers/media/video/cx88/cx88-mpeg.c
diff options
context:
space:
mode:
authorSteven Toth <stoth@hauppauge.com>2006-09-25 12:43:45 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2006-10-03 15:13:54 -0300
commit3a5ba52a1a1981c51af8f3559c16feaa238b2fec (patch)
treee2881b38f57f7cdbb0811d8d8782cbe1458ba768 /drivers/media/video/cx88/cx88-mpeg.c
parent3057906df5c9be9c99a181eccac3bc40cf07ad9f (diff)
V4L/DVB (4667): Changed cx88_board .dvb and .register to an enum.
Some basic cleanup in preperation for a future patch where the cx88-mpeg functions have to deal with the port being used by multiple frontends in (mpeg2 hw encoder and dvb demod). Signed-off-by: Steven Toth <stoth@hauppauge.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/cx88/cx88-mpeg.c')
-rw-r--r--drivers/media/video/cx88/cx88-mpeg.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/drivers/media/video/cx88/cx88-mpeg.c b/drivers/media/video/cx88/cx88-mpeg.c
index 138a4f692501..957f37c7857a 100644
--- a/drivers/media/video/cx88/cx88-mpeg.c
+++ b/drivers/media/video/cx88/cx88-mpeg.c
@@ -65,8 +65,17 @@ static int cx8802_start_dma(struct cx8802_dev *dev,
/* FIXME: this needs a review.
* also: move to cx88-blackbird + cx88-dvb source files? */
+ if (cx88_boards[core->board].mpeg == (CX88_BOARD_DVB | CX88_BOARD_BLACKBIRD) ) {
+ /* Report a warning until the mini driver patch is applied,
+ * else the following conditions will set the dma registers incorrectly.
+ * This will be removed in the next major patch and changes to the conditions
+ * will be made.
+ */
+ printk(KERN_INFO "%s() board->(CX88_BOARD_DVB | CX88_BOARD_BLACKBIRD) is invalid\n", __FUNCTION__);
+ return -EINVAL;
+ }
- if (cx88_boards[core->board].dvb) {
+ if (cx88_boards[core->board].mpeg & CX88_BOARD_DVB) {
/* negedge driven & software reset */
cx_write(TS_GEN_CNTRL, 0x0040 | dev->ts_gen_cntrl);
udelay(100);
@@ -92,7 +101,7 @@ static int cx8802_start_dma(struct cx8802_dev *dev,
udelay(100);
}
- if (cx88_boards[core->board].blackbird) {
+ if (cx88_boards[core->board].mpeg & CX88_BOARD_BLACKBIRD) {
cx_write(MO_PINMUX_IO, 0x88); /* enable MPEG parallel IO */
cx_write(TS_GEN_CNTRL, 0x46); /* punctured clock TS & posedge driven & software reset */