diff options
Diffstat (limited to 'linux/drivers/media/video/cx88/cx88-cards.c')
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-cards.c | 47 |
1 files changed, 26 insertions, 21 deletions
diff --git a/linux/drivers/media/video/cx88/cx88-cards.c b/linux/drivers/media/video/cx88/cx88-cards.c index 3ad9c2c40..0f8463a7b 100644 --- a/linux/drivers/media/video/cx88/cx88-cards.c +++ b/linux/drivers/media/video/cx88/cx88-cards.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-cards.c,v 1.51 2004/11/30 17:00:13 kraxel Exp $ + * $Id: cx88-cards.c,v 1.52 2004/12/09 12:51:35 kraxel Exp $ * * device driver for Conexant 2388x based TV cards * card-specific stuff. @@ -32,7 +32,8 @@ #include "cx88.h" #ifdef WITH_DVB -#include "cx22702.h" +# include "dvb-pll.h" +# include "cx22702.h" #endif /* ------------------------------------------------------------------ */ @@ -700,7 +701,6 @@ static int hauppauge_eeprom_dvb(struct cx88_core *core, u8 *ee) { int model; int tuner; - char *tname; /* Make sure we support the board model */ model = ee[0x1f] << 24 | ee[0x1e] << 16 | ee[0x1d] << 8 | ee[0x1c]; @@ -719,21 +719,18 @@ static int hauppauge_eeprom_dvb(struct cx88_core *core, u8 *ee) /* Make sure we support the tuner */ tuner = ee[0x2d]; switch(tuner) { - case 0x4B: - tname = "Thomson DTT 7595"; - core->pll_type = PLLTYPE_DTT7595; - break; - case 0x4C: - tname = "Thomson DTT 7592"; - core->pll_type = PLLTYPE_DTT7592; + case 0x4B: /* ddt 7595 */ + case 0x4C: /* dtt 7592 */ + core->pll_desc = &dvb_pll_thomson_dtt759x; break; default: printk("%s: error: unknown hauppauge tuner 0x%02x\n", core->name, tuner); return -ENODEV; } - printk(KERN_INFO "%s: hauppauge eeprom: model=%d, tuner=%s (%d)\n", - core->name, model, tname, tuner); + printk(KERN_INFO "%s: hauppauge eeprom: model=%d, tuner=%d (%s)\n", + core->name, model, tuner, + core->pll_desc ? core->pll_desc->name : "UNKNOWN"); core->pll_addr = 0x61; core->demod_addr = 0x43; @@ -869,13 +866,6 @@ void cx88_card_setup(struct cx88_core *core) i2c_eeprom(&core->i2c_client,eeprom,sizeof(eeprom)); leadtek_eeprom(core,eeprom); break; - case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1: - /* Tuner reset is hooked to the tuner out of reset */ - cx_set(MO_GP0_IO, 0x00000101); - cx_clear(MO_GP0_IO, 0x00000001); - msleep(1); - cx_set(MO_GP0_IO, 0x00000101); - break; #ifdef WITH_DVB case CX88_BOARD_HAUPPAUGE_DVB_T1: if (0 == core->i2c_rc) @@ -883,11 +873,23 @@ void cx88_card_setup(struct cx88_core *core) hauppauge_eeprom_dvb(core,eeprom); break; case CX88_BOARD_CONEXANT_DVB_T1: - core->pll_type = PLLTYPE_DTT7579; + core->pll_desc = &dvb_pll_thomson_dtt7579; core->pll_addr = 0x60; core->demod_addr = 0x43; break; -#endif + case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1: + /* Tuner reset is hooked to the tuner out of reset */ + cx_set(MO_GP0_IO, 0x00000101); + cx_clear(MO_GP0_IO, 0x00000001); + msleep(1); + cx_set(MO_GP0_IO, 0x00000101); + core->pll_addr = 0x61; + core->pll_desc = &dvb_pll_lg_z201; + break; + case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS: + core->pll_addr = 0x60; + core->pll_desc = &dvb_pll_thomson_dtt7579; + break; case CX88_BOARD_DNTV_LIVE_DVB_T: cx_set(MO_GP0_IO, 0x00000707); cx_set(MO_GP2_IO, 0x00000101); @@ -895,7 +897,10 @@ void cx88_card_setup(struct cx88_core *core) msleep(1); cx_clear(MO_GP0_IO, 0x00000007); cx_set(MO_GP2_IO, 0x00000101); + core->pll_addr = 0x61; + core->pll_desc = &dvb_pll_unknown_1; break; +#endif } if (cx88_boards[core->board].radio.type == CX88_RADIO) core->has_radio = 1; |