xref: /OK3568_Linux_fs/kernel/Documentation/admin-guide/media/bt8xx.rst (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun.. SPDX-License-Identifier: GPL-2.0
2*4882a593Smuzhiyun
3*4882a593Smuzhiyun==================================
4*4882a593SmuzhiyunHow to get the bt8xx cards working
5*4882a593Smuzhiyun==================================
6*4882a593Smuzhiyun
7*4882a593SmuzhiyunAuthors:
8*4882a593Smuzhiyun	 Richard Walker,
9*4882a593Smuzhiyun	 Jamie Honan,
10*4882a593Smuzhiyun	 Michael Hunold,
11*4882a593Smuzhiyun	 Manu Abraham,
12*4882a593Smuzhiyun	 Uwe Bugla,
13*4882a593Smuzhiyun	 Michael Krufky
14*4882a593Smuzhiyun
15*4882a593SmuzhiyunGeneral information
16*4882a593Smuzhiyun-------------------
17*4882a593Smuzhiyun
18*4882a593SmuzhiyunThis class of cards has a bt878a as the PCI interface, and require the bttv driver
19*4882a593Smuzhiyunfor accessing the i2c bus and the gpio pins of the bt8xx chipset.
20*4882a593Smuzhiyun
21*4882a593SmuzhiyunPlease see :doc:`bttv-cardlist` for a complete list of Cards based on the
22*4882a593SmuzhiyunConexant Bt8xx PCI bridge supported by the Linux Kernel.
23*4882a593Smuzhiyun
24*4882a593SmuzhiyunIn order to be able to compile the kernel, some config options should be
25*4882a593Smuzhiyunenabled::
26*4882a593Smuzhiyun
27*4882a593Smuzhiyun    ./scripts/config -e PCI
28*4882a593Smuzhiyun    ./scripts/config -e INPUT
29*4882a593Smuzhiyun    ./scripts/config -m I2C
30*4882a593Smuzhiyun    ./scripts/config -m MEDIA_SUPPORT
31*4882a593Smuzhiyun    ./scripts/config -e MEDIA_PCI_SUPPORT
32*4882a593Smuzhiyun    ./scripts/config -e MEDIA_ANALOG_TV_SUPPORT
33*4882a593Smuzhiyun    ./scripts/config -e MEDIA_DIGITAL_TV_SUPPORT
34*4882a593Smuzhiyun    ./scripts/config -e MEDIA_RADIO_SUPPORT
35*4882a593Smuzhiyun    ./scripts/config -e RC_CORE
36*4882a593Smuzhiyun    ./scripts/config -m VIDEO_BT848
37*4882a593Smuzhiyun    ./scripts/config -m DVB_BT8XX
38*4882a593Smuzhiyun
39*4882a593SmuzhiyunIf you want to automatically support all possible variants of the Bt8xx
40*4882a593Smuzhiyuncards, you should also do::
41*4882a593Smuzhiyun
42*4882a593Smuzhiyun    ./scripts/config -e MEDIA_SUBDRV_AUTOSELECT
43*4882a593Smuzhiyun
44*4882a593Smuzhiyun.. note::
45*4882a593Smuzhiyun
46*4882a593Smuzhiyun   Please use the following options with care as deselection of drivers which
47*4882a593Smuzhiyun   are in fact necessary may result in DVB devices that cannot be tuned due
48*4882a593Smuzhiyun   to lack of driver support.
49*4882a593Smuzhiyun
50*4882a593SmuzhiyunIf your goal is to just support an specific board, you may, instead,
51*4882a593Smuzhiyundisable MEDIA_SUBDRV_AUTOSELECT and manually select the frontend drivers
52*4882a593Smuzhiyunrequired by your board. With that, you can save some RAM.
53*4882a593Smuzhiyun
54*4882a593SmuzhiyunYou can do that by calling make xconfig/qconfig/menuconfig and look at
55*4882a593Smuzhiyunthe options on those menu options (only enabled if
56*4882a593Smuzhiyun``Autoselect ancillary drivers`` is disabled:
57*4882a593Smuzhiyun
58*4882a593Smuzhiyun#) ``Device drivers`` => ``Multimedia support`` => ``Customize TV tuners``
59*4882a593Smuzhiyun#) ``Device drivers`` => ``Multimedia support`` => ``Customize DVB frontends``
60*4882a593Smuzhiyun
61*4882a593SmuzhiyunThen, on each of the above menu, please select your card-specific
62*4882a593Smuzhiyunfrontend and tuner modules.
63*4882a593Smuzhiyun
64*4882a593Smuzhiyun
65*4882a593SmuzhiyunLoading Modules
66*4882a593Smuzhiyun---------------
67*4882a593Smuzhiyun
68*4882a593SmuzhiyunRegular case: If the bttv driver detects a bt8xx-based DVB card, all
69*4882a593Smuzhiyunfrontend and backend modules will be loaded automatically.
70*4882a593Smuzhiyun
71*4882a593SmuzhiyunExceptions are:
72*4882a593Smuzhiyun
73*4882a593Smuzhiyun- Old TV cards without EEPROMs, sharing a common PCI subsystem ID;
74*4882a593Smuzhiyun- Old TwinHan DST cards or clones with or without CA slot and not
75*4882a593Smuzhiyun  containing an Eeprom.
76*4882a593Smuzhiyun
77*4882a593SmuzhiyunIn the following cases overriding the PCI type detection for bttv and
78*4882a593Smuzhiyunfor dvb-bt8xx drivers by passing modprobe parameters may be necessary.
79*4882a593Smuzhiyun
80*4882a593SmuzhiyunRunning TwinHan and Clones
81*4882a593Smuzhiyun~~~~~~~~~~~~~~~~~~~~~~~~~~
82*4882a593Smuzhiyun
83*4882a593SmuzhiyunAs shown at :doc:`bttv-cardlist`, TwinHan and
84*4882a593Smuzhiyunclones use ``card=113`` modprobe parameter. So, in order to properly
85*4882a593Smuzhiyundetect it for devices without EEPROM, you should use::
86*4882a593Smuzhiyun
87*4882a593Smuzhiyun	$ modprobe bttv card=113
88*4882a593Smuzhiyun	$ modprobe dst
89*4882a593Smuzhiyun
90*4882a593SmuzhiyunUseful parameters for verbosity level and debugging the dst module::
91*4882a593Smuzhiyun
92*4882a593Smuzhiyun	verbose=0:		messages are disabled
93*4882a593Smuzhiyun		1:		only error messages are displayed
94*4882a593Smuzhiyun		2:		notifications are displayed
95*4882a593Smuzhiyun		3:		other useful messages are displayed
96*4882a593Smuzhiyun		4:		debug setting
97*4882a593Smuzhiyun	dst_addons=0:		card is a free to air (FTA) card only
98*4882a593Smuzhiyun		0x20:	card has a conditional access slot for scrambled channels
99*4882a593Smuzhiyun	dst_algo=0:		(default) Software tuning algorithm
100*4882a593Smuzhiyun	         1:		Hardware tuning algorithm
101*4882a593Smuzhiyun
102*4882a593Smuzhiyun
103*4882a593SmuzhiyunThe autodetected values are determined by the cards' "response string".
104*4882a593Smuzhiyun
105*4882a593SmuzhiyunIn your logs see f. ex.: dst_get_device_id: Recognize [DSTMCI].
106*4882a593Smuzhiyun
107*4882a593SmuzhiyunFor bug reports please send in a complete log with verbose=4 activated.
108*4882a593SmuzhiyunPlease also see :doc:`ci`.
109*4882a593Smuzhiyun
110*4882a593SmuzhiyunRunning multiple cards
111*4882a593Smuzhiyun~~~~~~~~~~~~~~~~~~~~~~
112*4882a593Smuzhiyun
113*4882a593SmuzhiyunSee :doc:`bttv-cardlist` for a complete list of
114*4882a593SmuzhiyunCard ID. Some examples:
115*4882a593Smuzhiyun
116*4882a593Smuzhiyun	===========================	===
117*4882a593Smuzhiyun	Brand name			ID
118*4882a593Smuzhiyun	===========================	===
119*4882a593Smuzhiyun	Pinnacle PCTV Sat		 94
120*4882a593Smuzhiyun	Nebula Electronics Digi TV	104
121*4882a593Smuzhiyun	pcHDTV HD-2000 TV		112
122*4882a593Smuzhiyun	Twinhan DST and clones		113
123*4882a593Smuzhiyun	Avermedia AverTV DVB-T 77:	123
124*4882a593Smuzhiyun	Avermedia AverTV DVB-T 761	124
125*4882a593Smuzhiyun	DViCO FusionHDTV DVB-T Lite	128
126*4882a593Smuzhiyun	DViCO FusionHDTV 5 Lite		135
127*4882a593Smuzhiyun	===========================	===
128*4882a593Smuzhiyun
129*4882a593Smuzhiyun.. note::
130*4882a593Smuzhiyun
131*4882a593Smuzhiyun   When you have multiple cards, the order of the card ID should
132*4882a593Smuzhiyun   match the order where they're detected by the system. Please notice
133*4882a593Smuzhiyun   that removing/inserting other PCI cards may change the detection
134*4882a593Smuzhiyun   order.
135*4882a593Smuzhiyun
136*4882a593SmuzhiyunExample::
137*4882a593Smuzhiyun
138*4882a593Smuzhiyun	$ modprobe bttv card=113 card=135
139*4882a593Smuzhiyun
140*4882a593SmuzhiyunIn case of further problems please subscribe and send questions to
141*4882a593Smuzhiyunthe mailing list: linux-media@vger.kernel.org.
142*4882a593Smuzhiyun
143*4882a593SmuzhiyunProbing the cards with broken PCI subsystem ID
144*4882a593Smuzhiyun~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
145*4882a593Smuzhiyun
146*4882a593SmuzhiyunThere are some TwinHan cards whose EEPROM has become corrupted for some
147*4882a593Smuzhiyunreason. The cards do not have a correct PCI subsystem ID.
148*4882a593SmuzhiyunStill, it is possible to force probing the cards with::
149*4882a593Smuzhiyun
150*4882a593Smuzhiyun	$ echo 109e 0878 $subvendor $subdevice > \
151*4882a593Smuzhiyun		/sys/bus/pci/drivers/bt878/new_id
152*4882a593Smuzhiyun
153*4882a593SmuzhiyunThe two numbers there are::
154*4882a593Smuzhiyun
155*4882a593Smuzhiyun	109e: PCI_VENDOR_ID_BROOKTREE
156*4882a593Smuzhiyun	0878: PCI_DEVICE_ID_BROOKTREE_878
157