Deleted Added
full compact
bktr_card.c (146734) bktr_card.c (152375)
1/*-
2 * 1. Redistributions of source code must retain the
3 * Copyright (c) 1997 Amancio Hasty, 1999 Roger Hardiman
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 18 unchanged lines hidden (view full) ---

27 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
29 * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
30 * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
31 * POSSIBILITY OF SUCH DAMAGE.
32 */
33
34#include <sys/cdefs.h>
1/*-
2 * 1. Redistributions of source code must retain the
3 * Copyright (c) 1997 Amancio Hasty, 1999 Roger Hardiman
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 18 unchanged lines hidden (view full) ---

27 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
29 * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
30 * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
31 * POSSIBILITY OF SUCH DAMAGE.
32 */
33
34#include <sys/cdefs.h>
35__FBSDID("$FreeBSD: head/sys/dev/bktr/bktr_card.c 146734 2005-05-29 04:42:30Z nyan $");
35__FBSDID("$FreeBSD: head/sys/dev/bktr/bktr_card.c 152375 2005-11-13 13:26:37Z netchild $");
36
37/*
38 * This is part of the Driver for Video Capture Cards (Frame grabbers)
39 * and TV Tuner cards using the Brooktree Bt848, Bt848A, Bt849A, Bt878, Bt879
40 * chipset.
41 * Copyright Roger Hardiman and Amancio Hasty.
42 *
43 * bktr_card : This deals with identifying TV cards.

--- 342 unchanged lines hidden (view full) ---

386 0, /* dbx is optional */
387 0,
388 0,
389 PFC8582_WADDR, /* EEProm type */
390 (u_char)(256 / EEPROMBLOCKSIZE), /* 256 bytes */
391 { 0x20000, 0x80000, 0, 0xa8000, 1 }, /* audio MUX values */
392 0xAA0000 }, /* GPIO mask */
393
36
37/*
38 * This is part of the Driver for Video Capture Cards (Frame grabbers)
39 * and TV Tuner cards using the Brooktree Bt848, Bt848A, Bt849A, Bt878, Bt879
40 * chipset.
41 * Copyright Roger Hardiman and Amancio Hasty.
42 *
43 * bktr_card : This deals with identifying TV cards.

--- 342 unchanged lines hidden (view full) ---

386 0, /* dbx is optional */
387 0,
388 0,
389 PFC8582_WADDR, /* EEProm type */
390 (u_char)(256 / EEPROMBLOCKSIZE), /* 256 bytes */
391 { 0x20000, 0x80000, 0, 0xa8000, 1 }, /* audio MUX values */
392 0xAA0000 }, /* GPIO mask */
393
394 { CARD_TERRATVALUE, /* the card id */
395 "TerraTec TValue", /* the 'name' */
396 NULL, /* the tuner */
397 0, /* the tuner i2c address */
398 0, /* dbx is optional */
399 0,
400 0,
401 0, /* EEProm type */
402 0, /* EEProm size */
403 /* Tuner, Extern, Intern, Mute, Enabled */
404 { 0x500, 0x900, 0x300, 0x900, 1 }, /* audio MUX values */
405 0xffff00 }, /* GPIO mask */
406
407 { CARD_PIXELVIEW_PLAYTV_PRO_REV_4C, /* the card id */
408 "PixelView PlayTV Pro REV-4C ", /* the 'name' */
409 NULL, /* the tuner */
410 0, /* the tuner i2c address */
411 0, /* dbx is optional */
412 0,
413 0,
414 0, /* EEProm type */
415 0, /* EEProm size */
416 { 0x01, 0x04, 0x01, 0x03, 1 }, /* audio MUX values */
417 0x00ffffff },
394};
395
396struct bt848_card_sig bt848_card_signature[1]= {
397 /* IMS TURBO TV : card 5 */
398 { 5,9, {00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 02, 00, 00, 00}}
399
400
401};

--- 175 unchanged lines hidden (view full) ---

577 * configuration EEPROM used on Bt878/879 cards. They should match the
578 * number assigned to the company by the PCI Special Interest Group
579 */
580#ifndef __NetBSD__
581#define PCI_VENDOR_HAUPPAUGE 0x0070
582#define PCI_VENDOR_AVERMEDIA 0x1461
583#define PCI_VENDOR_STB 0x10B4
584#define PCI_VENDOR_ASKEY 0x144F
418};
419
420struct bt848_card_sig bt848_card_signature[1]= {
421 /* IMS TURBO TV : card 5 */
422 { 5,9, {00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 02, 00, 00, 00}}
423
424
425};

--- 175 unchanged lines hidden (view full) ---

601 * configuration EEPROM used on Bt878/879 cards. They should match the
602 * number assigned to the company by the PCI Special Interest Group
603 */
604#ifndef __NetBSD__
605#define PCI_VENDOR_HAUPPAUGE 0x0070
606#define PCI_VENDOR_AVERMEDIA 0x1461
607#define PCI_VENDOR_STB 0x10B4
608#define PCI_VENDOR_ASKEY 0x144F
609#define PCI_VENDOR_TERRATEC 0x153B
585#endif
586/* Following not confirmed with http://members.hyperlink.net.au/~chart,
587 so not added to NetBSD's pcidevs */
588#define PCI_VENDOR_LEADTEK_ALT 0x6606
589#define PCI_VENDOR_LEADTEK_ALT_2 0x6607
590#define PCI_VENDOR_LEADTEK_ALT_3 0x107d
591#define PCI_VENDOR_FLYVIDEO 0x1851
592#define PCI_VENDOR_FLYVIDEO_2 0x1852
593#define PCI_VENDOR_IODATA 0x10fc
594#define PCI_VENDOR_PINNACLE_ALT 0xBD11 /* They got their own ID backwards? */
595#define PCI_VENDOR_PINNACLE_NEW 0x11BD
596
597#define MODEL_IODATA_GV_BCTV3_PCI 0x4020
610#endif
611/* Following not confirmed with http://members.hyperlink.net.au/~chart,
612 so not added to NetBSD's pcidevs */
613#define PCI_VENDOR_LEADTEK_ALT 0x6606
614#define PCI_VENDOR_LEADTEK_ALT_2 0x6607
615#define PCI_VENDOR_LEADTEK_ALT_3 0x107d
616#define PCI_VENDOR_FLYVIDEO 0x1851
617#define PCI_VENDOR_FLYVIDEO_2 0x1852
618#define PCI_VENDOR_IODATA 0x10fc
619#define PCI_VENDOR_PINNACLE_ALT 0xBD11 /* They got their own ID backwards? */
620#define PCI_VENDOR_PINNACLE_NEW 0x11BD
621
622#define MODEL_IODATA_GV_BCTV3_PCI 0x4020
623#define MODEL_TERRATVALUE_1117 0x1117
624#define MODEL_TERRATVALUE_1118 0x1118
625#define MODEL_TERRATVALUE_1119 0x1119
626#define MODEL_TERRATVALUE_111A 0x111a
627#define MODEL_TERRATVALUE_1134 0x1134
598
599void
600probeCard( bktr_ptr_t bktr, int verbose, int unit )
601{
602 int card, i,j, card_found;
603 int status;
604 u_char probe_signature[128], *probe_temp;
605 int any_i2c_devices;

--- 128 unchanged lines hidden (view full) ---

734 if (subsystem_vendor_id == PCI_VENDOR_IODATA &&
735 subsystem_id == MODEL_IODATA_GV_BCTV3_PCI) {
736 bktr->card = cards[ (card = CARD_IO_BCTV3) ];
737 bktr->card.eepromAddr = eeprom_i2c_address;
738 bktr->card.eepromSize = (u_char)(256 / EEPROMBLOCKSIZE);
739 goto checkTuner;
740 }
741
628
629void
630probeCard( bktr_ptr_t bktr, int verbose, int unit )
631{
632 int card, i,j, card_found;
633 int status;
634 u_char probe_signature[128], *probe_temp;
635 int any_i2c_devices;

--- 128 unchanged lines hidden (view full) ---

764 if (subsystem_vendor_id == PCI_VENDOR_IODATA &&
765 subsystem_id == MODEL_IODATA_GV_BCTV3_PCI) {
766 bktr->card = cards[ (card = CARD_IO_BCTV3) ];
767 bktr->card.eepromAddr = eeprom_i2c_address;
768 bktr->card.eepromSize = (u_char)(256 / EEPROMBLOCKSIZE);
769 goto checkTuner;
770 }
771
772 if (subsystem_vendor_id == PCI_VENDOR_TERRATEC) {
773 switch (subsystem_id) {
774 case MODEL_TERRATVALUE_1117:
775 case MODEL_TERRATVALUE_1118:
776 case MODEL_TERRATVALUE_1119:
777 case MODEL_TERRATVALUE_111A:
778 case MODEL_TERRATVALUE_1134:
779 bktr->card = cards[ (card = CARD_TERRATVALUE) ];
780 bktr->card.eepromAddr = eeprom_i2c_address;
781 bktr->card.eepromSize = (u_char)(256 / EEPROMBLOCKSIZE);
782 goto checkTuner;
783 }
784 }
785
742 /* Vendor is unknown. We will use the standard probe code */
743 /* which may not give best results */
744 printf("%s: Warning - card vendor 0x%04x (model 0x%04x) unknown.\n",
745 bktr_name(bktr), subsystem_vendor_id, subsystem_id);
746 }
747 else
748 {
749 printf("%s: Card has no configuration EEPROM. Cannot determine card make.\n",

--- 410 unchanged lines hidden (view full) ---

1160 goto checkDBX;
1161 break;
1162
1163 case CARD_IO_BCTV3:
1164 select_tuner( bktr, ALPS_TSCH5 ); /* ALPS_TSCH6, in fact. */
1165 goto checkDBX;
1166 break;
1167
786 /* Vendor is unknown. We will use the standard probe code */
787 /* which may not give best results */
788 printf("%s: Warning - card vendor 0x%04x (model 0x%04x) unknown.\n",
789 bktr_name(bktr), subsystem_vendor_id, subsystem_id);
790 }
791 else
792 {
793 printf("%s: Card has no configuration EEPROM. Cannot determine card make.\n",

--- 410 unchanged lines hidden (view full) ---

1204 goto checkDBX;
1205 break;
1206
1207 case CARD_IO_BCTV3:
1208 select_tuner( bktr, ALPS_TSCH5 ); /* ALPS_TSCH6, in fact. */
1209 goto checkDBX;
1210 break;
1211
1212 case CARD_TERRATVALUE:
1213 select_tuner( bktr, PHILIPS_PAL); /* Phlips PAL tuner */
1214 goto checkDBX;
1215 break;
1216
1168 } /* end switch(card) */
1169
1170
1171 /* At this point, a goto checkDBX has not occured */
1172 /* We have not been able to select a Tuner */
1173 /* Some cards make use of the tuner address to */
1174 /* identify the make/model of tuner */
1175

--- 170 unchanged lines hidden ---
1217 } /* end switch(card) */
1218
1219
1220 /* At this point, a goto checkDBX has not occured */
1221 /* We have not been able to select a Tuner */
1222 /* Some cards make use of the tuner address to */
1223 /* identify the make/model of tuner */
1224

--- 170 unchanged lines hidden ---