diff options
Diffstat (limited to 'linux/drivers/media/video/bttv-cards.c')
-rw-r--r-- | linux/drivers/media/video/bttv-cards.c | 176 |
1 files changed, 88 insertions, 88 deletions
diff --git a/linux/drivers/media/video/bttv-cards.c b/linux/drivers/media/video/bttv-cards.c index fe7220584..805cc389b 100644 --- a/linux/drivers/media/video/bttv-cards.c +++ b/linux/drivers/media/video/bttv-cards.c @@ -1,5 +1,5 @@ /* - $Id: bttv-cards.c,v 1.28 2004/10/06 13:45:14 kraxel Exp $ + $Id: bttv-cards.c,v 1.29 2004/10/13 10:39:00 kraxel Exp $ bttv-cards.c @@ -143,7 +143,7 @@ __setup("bttv.tuner=", p_tuner); int __init bttv_parse(char *str, int max, int *vals) { int i,number,res = 2; - + for (i = 0; res == 2 && i < max; i++) { res = get_option(&str,&number); if (res) @@ -192,7 +192,7 @@ static struct CARD { { 0x3000121a, BTTV_VOODOOTV_FM, "3Dfx VoodooTV FM/ VoodooTV 200" }, { 0x263710b4, BTTV_VOODOOTV_FM, "3Dfx VoodooTV FM/ VoodooTV 200" }, { 0x3060121a, BTTV_STB2, "3Dfx VoodooTV 100/ STB OEM" }, - + { 0x3000144f, BTTV_MAGICTVIEW063, "(Askey Magic/others) TView99 CPH06x" }, { 0x3002144f, BTTV_MAGICTVIEW061, "(Askey Magic/others) TView99 CPH05x" }, { 0x3005144f, BTTV_MAGICTVIEW061, "(Askey Magic/others) TView99 CPH061/06L (T1/LC)" }, @@ -210,7 +210,7 @@ static struct CARD { { 0x1118153b, BTTV_TERRATVALUE, "Terratec TValue (Temic PAL B/G)" }, { 0x1119153b, BTTV_TERRATVALUE, "Terratec TValue (Philips PAL I)" }, { 0x111a153b, BTTV_TERRATVALUE, "Terratec TValue (Temic PAL I)" }, - + { 0x1123153b, BTTV_TERRATVRADIO, "Terratec TV Radio+" }, { 0x1127153b, BTTV_TERRATV, "Terratec TV+ (V1.05)" }, // clashes with FlyVideo @@ -246,7 +246,7 @@ static struct CARD { { 0xa1550000, BTTV_IVC200, "IVC-200" }, { 0xa1550001, BTTV_IVC200, "IVC-200" }, { 0xa1550002, BTTV_IVC200, "IVC-200" }, - { 0xa1550003, BTTV_IVC200, "IVC-200" }, + { 0xa1550003, BTTV_IVC200, "IVC-200" }, { 0xa1550100, BTTV_IVC200, "IVC-200G" }, { 0xa1550101, BTTV_IVC200, "IVC-200G" }, { 0xa1550102, BTTV_IVC200, "IVC-200G" }, @@ -267,10 +267,10 @@ static struct CARD { { 0xa182ff0d, BTTV_IVC120, "IVC-120G" }, { 0xa182ff0e, BTTV_IVC120, "IVC-120G" }, { 0xa182ff0f, BTTV_IVC120, "IVC-120G" }, - + { 0x41424344, BTTV_GRANDTEC, "GrandTec Multi Capture" }, { 0x01020304, BTTV_XGUARD, "Grandtec Grand X-Guard" }, - + { 0x18501851, BTTV_CHRONOS_VS2, "FlyVideo 98 (LR50)/ Chronos Video Shuttle II" }, { 0xa0501851, BTTV_CHRONOS_VS2, "FlyVideo 98 (LR50)/ Chronos Video Shuttle II" }, { 0x18511851, BTTV_FLYVIDEO98EZ, "FlyVideo 98EZ (LR51)/ CyberMail AV" }, @@ -302,7 +302,7 @@ static struct CARD { // likely broken, vendor id doesn't match the other magic views ... //{ 0xa0fca04f, BTTV_MAGICTVIEW063, "Guillemot Maxi TV Video 3" }, - + // DVB cards (using pci function .1 for mpeg data xfer) { 0x01010071, BTTV_NEBULA_DIGITV, "Nebula Electronics DigiTV" }, { 0x07611461, BTTV_AVDVBT_761, "AverMedia AverTV DVB-T" }, @@ -311,7 +311,7 @@ static struct CARD { { 0xfc00270f, BTTV_TWINHAN_DST, "ChainTech digitop DST-1000 DVB-S" }, { 0x07711461, BTTV_AVDVBT_771, "AVermedia DVB-T 771" }, { 0xdb1018ac, BTTV_DVICO_DVBT_LITE, "DVICO FusionHDTV DVB-T Lite" }, - + { 0, -1, NULL } }; @@ -702,7 +702,7 @@ struct tvcard bttv_tvcards[] = { 10000 : ext. Video audio input 20000 : TV Mono a0000 : TV Mono/2 - 1a0000 : TV Stereo + 1a0000 : TV Stereo 30000 : Radio 40000 : Mute */ @@ -1117,7 +1117,7 @@ struct tvcard bttv_tvcards[] = { .pll = PLL_28, .tuner_type = 5, },{ - /* This is the ultimate cheapo capture card + /* This is the ultimate cheapo capture card * just a BT848A on a small PCB! * Steve Hosgood <steve@equiinet.com> */ .name = "GrandTec 'Grand Video Capture' (Bt848)", @@ -1188,7 +1188,7 @@ struct tvcard bttv_tvcards[] = { .tuner_type = -1, },{ /* Miguel Angel Alvarez <maacruz@navegalia.com> - new Easy TV BT878 version (model CPH061) + new Easy TV BT878 version (model CPH061) special thanks to Informatica Mieres for providing the card */ .name = "Askey CPH061/ BESTBUY Easy TV (bt878)", .video_inputs = 3, @@ -1392,7 +1392,7 @@ struct tvcard bttv_tvcards[] = { },{ .name = "Powercolor MTV878/ MTV878R/ MTV878F", .video_inputs = 3, - .audio_inputs = 2, + .audio_inputs = 2, .tuner = 0, .svhs = 2, .gpiomask = 0x1C800F, // Bit0-2: Audio select, 8-12:remote control 14:remote valid 15:remote reset @@ -1570,7 +1570,7 @@ struct tvcard bttv_tvcards[] = { .no_tda9875 = 1, .no_tda7432 = 1, },{ - + /* ---- card 0x58 ---------------------------------- */ .name = "Osprey 200/250", /* 0x1(A|B)-00C4-C1 */ .video_inputs = 2, @@ -1663,11 +1663,11 @@ struct tvcard bttv_tvcards[] = { .tuner_type = -1, .no_msp34xx = 1, .no_tda9875 = 1, - .no_tda7432 = 1, + .no_tda7432 = 1, .gpiomask = 0x01, .audiomux = { 0, 0, 0, 0, 1 }, .muxsel = { 3, 0, 1, 2}, - .needs_tvaudio = 0, + .needs_tvaudio = 0, .pll = PLL_28, .no_gpioirq = 1, },{ @@ -1679,7 +1679,7 @@ struct tvcard bttv_tvcards[] = { .gpiomask = 2, // TV, Comp1, Composite over SVID con, SVID .muxsel = { 2, 3, 1, 1}, - .audiomux = { 2, 2, 0, 0, 0 }, + .audiomux = { 2, 2, 0, 0, 0 }, .pll = PLL_28, .has_radio = 1, .tuner_type = TUNER_PHILIPS_PAL, @@ -1764,7 +1764,7 @@ struct tvcard bttv_tvcards[] = { /* Notes: - card lacks subsystem ID - stereo variant w/ daughter board with tda9874a @0xb0 - - Audio Routing: + - Audio Routing: always from tda9874 independent of GPIO (?) external line in: unknown - Other chips: em78p156elp @ 0x96 (probably IR remote control) @@ -1848,7 +1848,7 @@ struct tvcard bttv_tvcards[] = { .audio_inputs = 0, .tuner = -1, /* card has no tuner */ .svhs = 3, - .gpiomask = 0x00, + .gpiomask = 0x00, .muxsel = { 2, 3, 1, 0}, .audiomux = { 0, 0, 0, 0, 0, 0 }, /* card has no audio */ .needs_tvaudio = 1, @@ -1921,7 +1921,7 @@ struct tvcard bttv_tvcards[] = { .no_tda9875 = 1, .no_tda7432 = 1, .gpiomask = 0x00, - .muxsel = { 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, + .muxsel = { 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10 }, .muxsel_hook = ivc120_muxsel, .pll = PLL_28, @@ -2206,7 +2206,7 @@ void __devinit bttv_idcard(struct bttv *btv) for (type = -1, i = 0; cards[i].id != 0; i++) if (cards[i].id == btv->cardid) type = i; - + if (type != -1) { /* found it */ printk(KERN_INFO "bttv%d: detected: %s [card=%d], " @@ -2223,12 +2223,12 @@ void __devinit bttv_idcard(struct bttv *btv) printk(KERN_DEBUG "please mail id, board name and " "the correct card= insmod option to kraxel@bytesex.org\n"); } - } + } /* let the user override the autodetected type */ if (card[btv->c.nr] < bttv_num_tvcards) btv->c.type=card[btv->c.nr]; - + /* print which card config we are using */ printk(KERN_INFO "bttv%d: using: %s [card=%d,%s]\n",btv->c.nr, bttv_tvcards[btv->c.type].name, btv->c.type, @@ -2268,7 +2268,7 @@ void __devinit bttv_idcard(struct bttv *btv) void identify_by_eeprom(struct bttv *btv, unsigned char eeprom_data[256]) { int type = -1; - + if (0 == strncmp(eeprom_data,"GET MM20xPCTV",13)) type = BTTV_MODTEC_205; else if (0 == strncmp(eeprom_data+20,"Picolo",7)) @@ -2284,7 +2284,7 @@ void identify_by_eeprom(struct bttv *btv, unsigned char eeprom_data[256]) } static void flyvideo_gpio(struct bttv *btv) -{ +{ int gpio,has_remote,has_radio,is_capture_only,is_lr90,has_tda9820_tda9821; int tuner=-1,ttype; @@ -2298,10 +2298,10 @@ static void flyvideo_gpio(struct bttv *btv) // CP9=GPIO23 .. CP1=GPIO15; when OPEN, the corresponding GPIO reads 1. // GPIO14-12: n.c. // LR90: GP9=GPIO23 .. GP1=GPIO15 (right above the bt878) - + // lowest 3 bytes are remote control codes (no handshake needed) // xxxFFF: No remote control chip soldered - // xxxF00(LR26/LR50), xxxFE0(LR90): Remote control chip (LVA001 or CF45) soldered + // xxxF00(LR26/LR50), xxxFE0(LR90): Remote control chip (LVA001 or CF45) soldered // Note: Some bits are Audio_Mask ! ttype=(gpio&0x0f0000)>>16; @@ -2329,18 +2329,18 @@ static void flyvideo_gpio(struct bttv *btv) is_lr90 = !(gpio & 0x002000); // else LR26/LR50 (LR38/LR51 f. capture only) // gpio & 0x001000 // output bit for audio routing - if(is_capture_only) - tuner=4; // No tuner present + if(is_capture_only) + tuner=4; // No tuner present - printk(KERN_INFO "bttv%d: FlyVideo Radio=%s RemoteControl=%s Tuner=%d gpio=0x%06x\n", - btv->c.nr, has_radio? "yes":"no ", has_remote? "yes":"no ", tuner, gpio); + printk(KERN_INFO "bttv%d: FlyVideo Radio=%s RemoteControl=%s Tuner=%d gpio=0x%06x\n", + btv->c.nr, has_radio? "yes":"no ", has_remote? "yes":"no ", tuner, gpio); printk(KERN_INFO "bttv%d: FlyVideo LR90=%s tda9821/tda9820=%s capture_only=%s\n", - btv->c.nr, is_lr90?"yes":"no ", has_tda9820_tda9821?"yes":"no ", + btv->c.nr, is_lr90?"yes":"no ", has_tda9820_tda9821?"yes":"no ", is_capture_only?"yes":"no "); if(tuner!= -1) // only set if known tuner autodetected, else let insmod option through btv->tuner_type = tuner; - btv->has_radio = has_radio; + btv->has_radio = has_radio; // LR90 Audio Routing is done by 2 hef4052, so Audio_Mask has 4 bits: 0x001c80 // LR26/LR50 only has 1 hef4052, Audio_Mask 0x000c00 @@ -2439,13 +2439,13 @@ static void init_ids_eagle(struct bttv *btv) { gpio_inout(0xffffff,0xFFFF37); gpio_write(0x200020); - + /* flash strobe inverter ?! */ gpio_write(0x200024); - + /* switch sync drive off */ gpio_bits(LM1882_SYNC_DRIVE,LM1882_SYNC_DRIVE); - + /* set BT848 muxel to 2 */ btaor((2)<<5, ~(2<<5), BT848_IFORM); } @@ -2534,7 +2534,7 @@ void bttv_reset_audio(struct bttv *btv) */ if (btv->id != 878) return; - + if (bttv_debug) printk("bttv%d: BT878A ARESET\n",btv->c.nr); btwrite((1<<7), 0x058); @@ -2581,7 +2581,7 @@ void __devinit bttv_init_card2(struct bttv *btv) case BTTV_MIRO: case BTTV_MIROPRO: case BTTV_PINNACLE: - case BTTV_PINNACLEPRO: + case BTTV_PINNACLEPRO: /* miro/pinnacle */ miro_pinnacle_gpio(btv); break; @@ -2705,7 +2705,7 @@ void __devinit bttv_init_card2(struct bttv *btv) /* tuner configuration (from card list / autodetect / insmod option) */ if (UNSET != bttv_tvcards[btv->c.type].tuner_type) - if(UNSET == btv->tuner_type) + if(UNSET == btv->tuner_type) btv->tuner_type = bttv_tvcards[btv->c.type].tuner_type; if (UNSET != tuner[btv->c.nr]) btv->tuner_type = tuner[btv->c.nr]; @@ -2753,7 +2753,7 @@ void __devinit bttv_init_card2(struct bttv *btv) bttv_I2CRead(btv, I2C_TDA9875, "TDA9875") >=0) request_module("tda9875"); - if (!bttv_tvcards[btv->c.type].no_tda7432 && + if (!bttv_tvcards[btv->c.type].no_tda7432 && bttv_I2CRead(btv, I2C_TDA7432, "TDA7432") >=0) request_module("tda7432"); @@ -2777,12 +2777,12 @@ void __devinit bttv_init_card2(struct bttv *btv) /* ----------------------------------------------------------------------- */ /* some hauppauge specific stuff */ -static struct HAUPPAUGE_TUNER +static struct HAUPPAUGE_TUNER { int id; char *name; -} -hauppauge_tuner[] __devinitdata = +} +hauppauge_tuner[] __devinitdata = { { TUNER_ABSENT, "" }, { TUNER_ABSENT, "External" }, @@ -2832,7 +2832,7 @@ hauppauge_tuner[] __devinitdata = { TUNER_ABSENT, "Philips TD1536D_FH_44"}, { TUNER_LG_NTSC_FM, "LG TPI8NSR01F"}, { TUNER_LG_PAL_FM, "LG TPI8PSB01D"}, - { TUNER_LG_PAL, "LG TPI8PSB11D"}, + { TUNER_LG_PAL, "LG TPI8PSB11D"}, { TUNER_LG_PAL_I_FM, "LG TAPC-I001D"}, { TUNER_LG_PAL_I, "LG TAPC-I701D"} }; @@ -2872,12 +2872,12 @@ static void __devinit hauppauge_eeprom(struct bttv *btv) model = eeprom_data[12] << 8 | eeprom_data[11]; tuner = eeprom_data[9]; radio = eeprom_data[blk2-1] & 0x01; - + if (tuner < ARRAY_SIZE(hauppauge_tuner)) btv->tuner_type = hauppauge_tuner[tuner].id; if (radio) btv->has_radio = 1; - + if (bttv_verbose) printk(KERN_INFO "bttv%d: Hauppauge eeprom: model=%d, " "tuner=%s (%d), radio=%s\n", @@ -2914,7 +2914,7 @@ static int terratec_active_radio_upgrade(struct bttv *btv) btv->has_matchbox = 0; } return 0; -} +} /* ----------------------------------------------------------------------- */ @@ -2941,7 +2941,7 @@ static int __devinit pvr_altera_load(struct bttv *btv, u8 *micro, u32 microlen) gpio_inout(0xffffff,BTTV_ALT_DATA|BTTV_ALT_DCLK|BTTV_ALT_NCONFIG); gpio_write(0); udelay(PVR_GPIO_DELAY); - + gpio_write(BTTV_ALT_NCONFIG); udelay(PVR_GPIO_DELAY); @@ -2951,7 +2951,7 @@ static int __devinit pvr_altera_load(struct bttv *btv, u8 *micro, u32 microlen) gpio_bits(BTTV_ALT_DCLK,0); if (bits & 0x01) gpio_bits(BTTV_ALT_DATA,BTTV_ALT_DATA); - else + else gpio_bits(BTTV_ALT_DATA,0); gpio_bits(BTTV_ALT_DCLK,BTTV_ALT_DCLK); bits >>= 1; @@ -2959,7 +2959,7 @@ static int __devinit pvr_altera_load(struct bttv *btv, u8 *micro, u32 microlen) } gpio_bits(BTTV_ALT_DCLK,0); udelay(PVR_GPIO_DELAY); - + /* begin Altera init loop (Not necessary,but doesn't hurt) */ for (i = 0 ; i < 30 ; i++) { gpio_bits(BTTV_ALT_DCLK,0); @@ -2971,7 +2971,7 @@ static int __devinit pvr_altera_load(struct bttv *btv, u8 *micro, u32 microlen) #if !defined(CONFIG_FW_LOADER) && !defined(CONFIG_FW_LOADER_MODULE) /* old 2.4.x way -- via soundcore's mod_firmware_load */ - + static char *firm_altera = "/usr/lib/video4linux/hcwamc.rbf"; MODULE_PARM(firm_altera,"s"); MODULE_PARM_DESC(firm_altera,"WinTV/PVR firmware " @@ -2991,7 +2991,7 @@ int __devinit pvr_boot(struct bttv *btv) btv->c.nr, firm_altera); return -1; } - + printk(KERN_INFO "bttv%d: uploading altera firmware [%s] ...\n", btv->c.nr, firm_altera); result = pvr_altera_load(btv, micro, microlen); @@ -3023,7 +3023,7 @@ int __devinit pvr_boot(struct bttv *btv) btv->c.nr, (rc < 0) ? "failed" : "ok"); release_firmware(fw_entry); return rc; -} +} #endif /* ----------------------------------------------------------------------- */ @@ -3034,7 +3034,7 @@ static void __devinit osprey_eeprom(struct bttv *btv) int i = 0; unsigned char *ee = eeprom_data; unsigned long serial = 0; - + if (btv->c.type == 0) { /* this might be an antique... check for MMAC label in eeprom */ if ((ee[0]=='M') && (ee[1]=='M') && (ee[2]=='A') && (ee[3]=='C')) { @@ -3050,7 +3050,7 @@ static void __devinit osprey_eeprom(struct bttv *btv) } else { unsigned short type; int offset = 4*16; - + for(; offset < 8*16; offset += 16) { unsigned short checksum = 0; /* verify the checksum */ @@ -3061,13 +3061,13 @@ static void __devinit osprey_eeprom(struct bttv *btv) break; } } - + if (offset >= 8*16) return; /* found a valid descriptor */ type = (ee[offset+4]<<8) | (ee[offset+5]); - + switch(type) { /* 848 based */ @@ -3077,7 +3077,7 @@ static void __devinit osprey_eeprom(struct bttv *btv) case 0x0005: btv->c.type = BTTV_OSPREY101_848; break; - + /* 878 based */ case 0x0012: case 0x0013: @@ -3125,10 +3125,10 @@ static void __devinit osprey_eeprom(struct bttv *btv) | (ee[offset+8] << 8) | (ee[offset+9]); } - + printk(KERN_INFO "bttv%d: osprey eeprom: card=%d name=%s serial=%ld\n", btv->c.nr, btv->c.type, bttv_tvcards[btv->c.type].name,serial); -} +} /* ----------------------------------------------------------------------- */ /* AVermedia specific stuff, from bktr_card.c */ @@ -3170,7 +3170,7 @@ static void __devinit avermedia_eeprom(struct bttv *btv) if (tuner_make == 1) if(tuner_format <=9) tuner = tuner_1_table[tuner_format]; - + printk(KERN_INFO "bttv%d: Avermedia eeprom[0x%02x%02x]: tuner=", btv->c.nr,eeprom_data[0x41],eeprom_data[0x42]); if(tuner) { @@ -3260,8 +3260,8 @@ static void __devinit boot_bt832(struct bttv *btv) /* ----------------------------------------------------------------------- */ /* Imagenation L-Model PXC200 Framegrabber */ -/* This is basically the same procedure as - * used by Alessandro Rubini in his pxc200 +/* This is basically the same procedure as + * used by Alessandro Rubini in his pxc200 * driver, but using BTTV functions */ static void __devinit init_PXC200(struct bttv *btv) @@ -3272,13 +3272,13 @@ static void __devinit init_PXC200(struct bttv *btv) unsigned int i; int tmp; u32 val; - + /* Initialise GPIO-connevted stuff */ gpio_inout(0xffffff, (1<<13)); gpio_write(0); udelay(3); gpio_write(1<<13); - /* GPIO inputs are pulled up, so no need to drive + /* GPIO inputs are pulled up, so no need to drive * reset pin any longer */ gpio_bits(0xffffff, 0); if (bttv_gpio) @@ -3293,16 +3293,16 @@ static void __devinit init_PXC200(struct bttv *btv) */ btwrite(BT848_ADC_RESERVED|BT848_ADC_AGC_EN, BT848_ADC); - + /* Initialise MAX517 DAC */ printk(KERN_INFO "Setting DAC reference voltage level ...\n"); bttv_I2CWrite(btv,0x5E,0,0x80,1); - + /* Initialise 12C508 PIC */ - /* The I2CWrite and I2CRead commmands are actually to the + /* The I2CWrite and I2CRead commmands are actually to the * same chips - but the R/W bit is included in the address * argument so the numbers are different */ - + printk(KERN_INFO "Initialising 12C508 PIC chip ...\n"); @@ -3310,7 +3310,7 @@ static void __devinit init_PXC200(struct bttv *btv) val = btread(BT848_GPIO_DMA_CTL); val |= BT848_GPIO_DMA_CTL_GPCLKMODE; btwrite(val, BT848_GPIO_DMA_CTL); - + /* Then, push to 0 the reset pin long enough to reset the * * device same as above for the reset line, but not the same * value sent to the GPIO-connected stuff @@ -3422,7 +3422,7 @@ static int tea5757_read(struct bttv *btv) unsigned long timeout; int value = 0; int i; - + /* better safe than sorry */ gpio_inout(btv->mbox_mask, btv->mbox_clk | btv->mbox_we); @@ -3434,10 +3434,10 @@ static int tea5757_read(struct bttv *btv) if (bttv_gpio) bttv_gpio_tracking(btv,"tea5757 read"); - + bus_low(btv,btv->mbox_we); bus_low(btv,btv->mbox_clk); - + udelay(10); timeout= jiffies + HZ; @@ -3469,7 +3469,7 @@ static int tea5757_write(struct bttv *btv, int value) { int i; int reg = value; - + gpio_inout(btv->mbox_mask, btv->mbox_clk | btv->mbox_we | btv->mbox_data); if (btv->mbox_ior) { @@ -3524,7 +3524,7 @@ void winview_audio(struct bttv *btv, struct video_audio *v, int set) v->flags |= VIDEO_AUDIO_VOLUME; return; } - + /* 32 levels logarithmic */ vol = 32 - ((v->volume>>11)); /* units */ @@ -3551,7 +3551,7 @@ void winview_audio(struct bttv *btv, struct video_audio *v, int set) data |= WINVIEW_PT2254_STROBE; data &= ~WINVIEW_PT2254_DATA; gpio_write(data); - udelay(10); + udelay(10); data &= ~WINVIEW_PT2254_STROBE; gpio_write(data); } @@ -3676,7 +3676,7 @@ static void avermedia_tv_stereo_audio(struct bttv *btv, struct video_audio *v, int set) { int val = 0; - + if (set) { if (v->mode & VIDEO_SOUND_LANG2) /* SAP */ val = 0x01; @@ -3811,7 +3811,7 @@ pvbt878p9b_audio(struct bttv *btv, struct video_audio *v, int set) /* * Dariusz Kowalewski <darekk@automex.pl> - * sound control for FlyVideo 2000S (with tda9874 decoder) + * sound control for FlyVideo 2000S (with tda9874 decoder) * based on pvbt878p9b_audio() - this is not tested, please fix!!! */ static void @@ -3994,13 +3994,13 @@ static void picolo_tetra_muxsel (struct bttv* btv, unsigned int input) * ivc120_muxsel [Added by Alan Garfield <alan@fromorbit.com>] * * The IVC120G security card has 4 i2c controlled TDA8540 matrix - * swichers to provide 16 channels to MUX0. The TDA8540's have - * 4 indepedant outputs and as such the IVC120G also has the - * optional "Monitor Out" bus. This allows the card to be looking + * swichers to provide 16 channels to MUX0. The TDA8540's have + * 4 indepedant outputs and as such the IVC120G also has the + * optional "Monitor Out" bus. This allows the card to be looking * at one input while the monitor is looking at another. * * Since I've couldn't be bothered figuring out how to add an - * independant muxsel for the monitor bus, I've just set it to + * independant muxsel for the monitor bus, I've just set it to * whatever the card is looking at. * * OUT0 of the TDA8540's is connected to MUX0 (0x03) @@ -4025,12 +4025,12 @@ static void picolo_tetra_muxsel (struct bttv* btv, unsigned int input) static void ivc120_muxsel(struct bttv *btv, unsigned int input) { // Simple maths - int key = input % 4; + int key = input % 4; int matrix = input / 4; - + dprintk("bttv%d: ivc120_muxsel: Input - %02d | TDA - %02d | In - %02d\n", btv->c.nr, input, matrix, key); - + // Handles the input selection on the TDA8540's bttv_I2CWrite(btv, I2C_TDA8540_ALT3, 0x00, ((matrix == 3) ? (key | key << 2) : 0x00), 1); @@ -4040,17 +4040,17 @@ static void ivc120_muxsel(struct bttv *btv, unsigned int input) ((matrix == 1) ? (key | key << 2) : 0x00), 1); bttv_I2CWrite(btv, I2C_TDA8540_ALT6, 0x00, ((matrix == 2) ? (key | key << 2) : 0x00), 1); - + // Handles the output enables on the TDA8540's bttv_I2CWrite(btv, I2C_TDA8540_ALT3, 0x02, ((matrix == 3) ? 0x03 : 0x00), 1); // 13 - 16 bttv_I2CWrite(btv, I2C_TDA8540_ALT4, 0x02, ((matrix == 0) ? 0x03 : 0x00), 1); // 1-4 bttv_I2CWrite(btv, I2C_TDA8540_ALT5, 0x02, - ((matrix == 1) ? 0x03 : 0x00), 1); // 5-8 + ((matrix == 1) ? 0x03 : 0x00), 1); // 5-8 bttv_I2CWrite(btv, I2C_TDA8540_ALT6, 0x02, ((matrix == 2) ? 0x03 : 0x00), 1); // 9-12 - + // Selects MUX0 for input on the 878 btaor((0)<<5, ~(3<<5), BT848_IFORM); } |