From 0d723c09f03e0b2cb4405c361c927efac373fe0c Mon Sep 17 00:00:00 2001 From: Michael Krufky Date: Thu, 7 Jul 2005 17:58:42 -0700 Subject: [PATCH] v4l: add DVB support for DViCO FusionHDTV3 Gold-T - Correct sync byte for MPEG-2 transport stream packets. - Add lgdt3302 as dependency of cx88-dvb in Kconfig. - Add dvb support in v4l for DViCO FusionHDTV3 Gold-T using lgdt3302 frontend. This adds support for a different board from the previous (Gold-Q) patch. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Johannes Stezenbach Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/media/video/cx88/cx88-cards.c | 3 ++- drivers/media/video/cx88/cx88-dvb.c | 21 +++++++++++++++++++++ drivers/media/video/cx88/cx88-mpeg.c | 8 ++++---- 3 files changed, 27 insertions(+), 5 deletions(-) (limited to 'drivers/media/video/cx88') diff --git a/drivers/media/video/cx88/cx88-cards.c b/drivers/media/video/cx88/cx88-cards.c index eeca2f3..b0b47c3 100644 --- a/drivers/media/video/cx88/cx88-cards.c +++ b/drivers/media/video/cx88/cx88-cards.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-cards.c,v 1.84 2005/07/02 19:42:09 mkrufky Exp $ + * $Id: cx88-cards.c,v 1.85 2005/07/04 19:35:05 mkrufky Exp $ * * device driver for Conexant 2388x based TV cards * card-specific stuff. @@ -723,6 +723,7 @@ struct cx88_board cx88_boards[] = { .vmux = 2, .gpio0 = 0x0f00, }}, + .dvb = 1, }, [CX88_BOARD_ADSTECH_DVB_T_PCI] = { .name = "ADS Tech Instant TV DVB-T PCI", diff --git a/drivers/media/video/cx88/cx88-dvb.c b/drivers/media/video/cx88/cx88-dvb.c index 806afc6..690477a 100644 --- a/drivers/media/video/cx88/cx88-dvb.c +++ b/drivers/media/video/cx88/cx88-dvb.c @@ -220,6 +220,13 @@ static struct lgdt3302_config fusionhdtv_3_gold_q = { .pll_desc = &dvb_pll_microtune_4042, .set_ts_params = lgdt3302_set_ts_param, }; + +static struct lgdt3302_config fusionhdtv_3_gold_t = { + .demod_address = 0x0e, + .pll_address = 0x61, + .pll_desc = &dvb_pll_thomson_dtt7611, + .set_ts_params = lgdt3302_set_ts_param, +}; #endif static int dvb_register(struct cx8802_dev *dev) @@ -282,6 +289,20 @@ static int dvb_register(struct cx8802_dev *dev) &dev->core->i2c_adap); } break; + case CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_T: + dev->ts_gen_cntrl = 0x08; + { + /* Do a hardware reset of chip before using it. */ + struct cx88_core *core = dev->core; + + cx_clear(MO_GP0_IO, 1); + mdelay(100); + cx_set(MO_GP0_IO, 9); /* ANT connector too FIXME */ + mdelay(200); + dev->dvb.frontend = lgdt3302_attach(&fusionhdtv_3_gold_t, + &dev->core->i2c_adap); + } + break; #endif default: printk("%s: The frontend of your DVB/ATSC card isn't supported yet\n", diff --git a/drivers/media/video/cx88/cx88-mpeg.c b/drivers/media/video/cx88/cx88-mpeg.c index c5f4c59..85da6dc 100644 --- a/drivers/media/video/cx88/cx88-mpeg.c +++ b/drivers/media/video/cx88/cx88-mpeg.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-mpeg.c,v 1.28 2005/06/20 03:36:00 mkrufky Exp $ + * $Id: cx88-mpeg.c,v 1.30 2005/07/05 19:44:40 mkrufky Exp $ * * Support for the mpeg transport stream transfers * PCI function #2 of the cx2388x. @@ -73,11 +73,11 @@ static int cx8802_start_dma(struct cx8802_dev *dev, cx_write(TS_GEN_CNTRL, 0x0040 | dev->ts_gen_cntrl); udelay(100); cx_write(MO_PINMUX_IO, 0x00); - if (core->board == CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_Q) { - cx_write(TS_HW_SOP_CNTRL,0x47<<16 | 188<<4 | 0x00); + cx_write(TS_HW_SOP_CNTRL,0x47<<16|188<<4|0x01); + if ((core->board == CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_Q) || + (core->board == CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_T)) { cx_write(TS_SOP_STAT, 0<<16 | 0<<14 | 1<<13 | 0<<12); } else { - cx_write(TS_HW_SOP_CNTRL,47<<16|188<<4|0x00); cx_write(TS_SOP_STAT,0x00); } cx_write(TS_GEN_CNTRL, dev->ts_gen_cntrl); -- cgit v1.1