xref: /openbmc/linux/drivers/media/Kconfig (revision 85f7cd3a)
1# SPDX-License-Identifier: GPL-2.0-only
2#
3# Multimedia device configuration
4#
5
6source "drivers/media/rc/Kconfig"
7
8menuconfig MEDIA_SUPPORT
9	tristate "Multimedia support"
10	depends on HAS_IOMEM
11	help
12	  If you want to use media devices, including Webcams, Video grabber
13	  devices and/or TV devices, V4L2 codecs, etc, enable this option
14	  and other options below.
15
16	  Additional info and docs are available on the web at
17	  <https://linuxtv.org>
18
19if MEDIA_SUPPORT
20
21config MEDIA_SUPPORT_FILTER
22	bool "Filter media drivers"
23	depends on MEDIA_SUPPORT
24	default y if !EMBEDDED && !EXPERT
25	help
26	   Configuring the media subsystem can be complex, as there are
27	   hundreds of drivers and other config options.
28
29	   This menu offers option that will help the Kernel's config
30	   system to hide drivers that are out of the scope of the
31	   user needs, and disabling core support for unused APIs.
32
33	   If not selected, all non-optional media core functionality
34	   needed to support media drivers will be enabled. Also, all
35	   media device drivers should be shown.
36
37config MEDIA_SUBDRV_AUTOSELECT
38	bool "Autoselect ancillary drivers (tuners, sensors, i2c, spi, frontends)"
39	depends on HAS_IOMEM
40	select I2C
41	select I2C_MUX
42	default y if MEDIA_SUPPORT_FILTER
43	help
44	  By default, a media driver auto-selects all possible ancillary
45	  devices such as tuners, sensors, video encoders/decoders and
46	  frontends, that are used by any of the supported devices.
47
48	  This is generally the right thing to do, except when there
49	  are strict constraints with regards to the kernel size,
50	  like on embedded systems.
51
52	  Use this option with care, as deselecting ancillary drivers which
53	  are, in fact, necessary will result in the lack of the needed
54	  functionality for your device (it may not tune or may not have
55	  the needed demodulators).
56
57	  If unsure say Y.
58
59menu "Media device types"
60
61#
62# Multimedia support - automatically enable V4L2 and DVB core
63#
64config MEDIA_CAMERA_SUPPORT
65	bool
66	prompt "Cameras and video grabbers" if MEDIA_SUPPORT_FILTER
67	default y if !MEDIA_SUPPORT_FILTER
68	help
69	  Enable support for webcams and video grabbers.
70
71	  Say Y when you have a webcam or a video capture grabber board.
72
73config MEDIA_ANALOG_TV_SUPPORT
74	bool
75	prompt "Analog TV" if MEDIA_SUPPORT_FILTER
76	default y if !MEDIA_SUPPORT_FILTER
77	help
78	  Enable analog TV support.
79
80	  Say Y when you have a TV board with analog support or with a
81	  hybrid analog/digital TV chipset.
82
83	  Note: There are several DVB cards that are based on chips that
84		support both analog and digital TV. Disabling this option
85		will disable support for them.
86
87config MEDIA_DIGITAL_TV_SUPPORT
88	bool
89	prompt "Digital TV" if MEDIA_SUPPORT_FILTER
90	default y if !MEDIA_SUPPORT_FILTER
91	help
92	  Enable digital TV support.
93
94	  Say Y when you have a board with digital support or a board with
95	  hybrid digital TV and analog TV.
96
97config MEDIA_RADIO_SUPPORT
98	bool
99	prompt "AM/FM radio receivers/transmitters" if MEDIA_SUPPORT_FILTER
100	default y if !MEDIA_SUPPORT_FILTER
101	help
102	  Enable AM/FM radio support.
103
104	  Additional info and docs are available on the web at
105	  <https://linuxtv.org>
106
107	  Say Y when you have a board with radio support.
108
109	  Note: There are several TV cards that are based on chips that
110		support radio reception. Disabling this option will
111		disable support for them.
112
113config MEDIA_SDR_SUPPORT
114	bool
115	prompt "Software defined radio" if MEDIA_SUPPORT_FILTER
116	default y if !MEDIA_SUPPORT_FILTER
117	help
118	  Enable software defined radio support.
119
120	  Say Y when you have a software defined radio device.
121
122config MEDIA_CEC_SUPPORT
123	bool
124	prompt "HDMI CEC support" if MEDIA_SUPPORT_FILTER
125	default y if !MEDIA_SUPPORT_FILTER
126	help
127	  Enable support for HDMI CEC (Consumer Electronics Control),
128	  which is an optional HDMI feature.
129
130	  Say Y when you have an HDMI receiver, transmitter or a USB CEC
131	  adapter that supports HDMI CEC.
132
133config MEDIA_PLATFORM_SUPPORT
134	bool
135	prompt "Platform-specific devices" if MEDIA_SUPPORT_FILTER
136	default y if !MEDIA_SUPPORT_FILTER
137	help
138	  Enable support for complex cameras, codecs, and other hardware
139	  that are integrated at the CPU, GPU or on Image Signalling Processor
140	  and don't use PCI, USB or Firewire buses.
141
142	  This is found on Embedded hardware (SoC), on V4L2 codecs and
143	  on some GPU and newer CPU chipsets.
144
145	  Say Y when you want to be able so see such devices.
146
147config MEDIA_TEST_SUPPORT
148	bool
149	prompt "Test drivers" if MEDIA_SUPPORT_FILTER
150	default y if !MEDIA_SUPPORT_FILTER
151	help
152	  Those drivers should not be used on production Kernels, but
153	  can be useful on debug ones. It enables several dummy drivers
154	  that simulate a real hardware. Very useful to test userspace
155	  applications and to validate if the subsystem core is doesn't
156	  have regressions.
157
158	  Say Y if you want to use some virtual test driver.
159
160	  In case of doubts, say N.
161	  Say Y when you have a software defined radio device.
162endmenu # media device types
163
164
165menu "Media core support"
166	visible if !MEDIA_SUPPORT_FILTER
167
168config VIDEO_DEV
169	tristate "Video4Linux core"
170	default MEDIA_CAMERA_SUPPORT || MEDIA_ANALOG_TV_SUPPORT || MEDIA_RADIO_SUPPORT || MEDIA_SDR_SUPPORT || MEDIA_PLATFORM_SUPPORT || MEDIA_TEST_SUPPORT
171	help
172	  Enables the V4L2 API, used by cameras, analog TV, video grabbers,
173	  radio devices and by some input devices.
174
175config MEDIA_CONTROLLER
176	bool "Media Controller API"
177	default MEDIA_CAMERA_SUPPORT || MEDIA_ANALOG_TV_SUPPORT || MEDIA_DIGITAL_TV_SUPPORT || MEDIA_PLATFORM_SUPPORT
178	help
179	  Enable the media controller API used to query media devices internal
180	  topology and configure it dynamically.
181
182	  This API is mostly used by camera interfaces in embedded platforms.
183
184#
185# DVB Core
186#	Only enables if one of DTV is selected
187#
188
189config DVB_CORE
190	tristate
191	depends on MEDIA_DIGITAL_TV_SUPPORT
192	depends on (I2C || I2C=n)
193	select CRC32
194	help
195	  Enables the DVB API, used by Digital TV devices. Supports several
196	  standards, including DVB, ATSC, ISDB and CMDB.
197
198endmenu # Media core support
199
200#
201# Extra per-media API core functionality
202
203menu "Video4Linux options"
204	visible if VIDEO_DEV
205
206source "drivers/media/v4l2-core/Kconfig"
207endmenu
208
209menu "Media controller options"
210	visible if MEDIA_CONTROLLER
211
212source "drivers/media/mc/Kconfig"
213endmenu
214
215menu "Digital TV options"
216	visible if DVB_CORE
217
218source "drivers/media/dvb-core/Kconfig"
219endmenu
220
221menu "HDMI CEC options"
222	visible if CEC_CORE
223
224source "drivers/media/cec/Kconfig"
225endmenu
226
227menu "Media drivers"
228
229comment "Drivers filtered as selected at 'Filter media drivers'"
230	depends on MEDIA_SUPPORT_FILTER
231
232source "drivers/media/usb/Kconfig"
233source "drivers/media/pci/Kconfig"
234source "drivers/media/radio/Kconfig"
235
236# Common driver options
237source "drivers/media/common/Kconfig"
238
239if MEDIA_PLATFORM_SUPPORT
240source "drivers/media/platform/Kconfig"
241source "drivers/media/test_drivers/Kconfig"
242source "drivers/media/mmc/Kconfig"
243endif
244
245source "drivers/media/firewire/Kconfig"
246
247endmenu
248
249#
250# Ancillary drivers (tuners, i2c, spi, frontends)
251#
252
253config MEDIA_HIDE_ANCILLARY_SUBDRV
254	bool
255	depends on MEDIA_SUBDRV_AUTOSELECT && !COMPILE_TEST && !EXPERT
256	default y
257
258menu "Media ancillary drivers"
259	visible if !MEDIA_HIDE_ANCILLARY_SUBDRV
260
261config MEDIA_ATTACH
262	bool
263	depends on MEDIA_ANALOG_TV_SUPPORT || MEDIA_DIGITAL_TV_SUPPORT || MEDIA_RADIO_SUPPORT
264	depends on MODULES
265	default MODULES
266
267source "drivers/media/i2c/Kconfig"
268source "drivers/media/spi/Kconfig"
269source "drivers/media/tuners/Kconfig"
270source "drivers/media/dvb-frontends/Kconfig"
271
272endmenu
273
274endif # MEDIA_SUPPORT
275