media: Kconfig: make filtering devices optional

The per-device option selection is a feature that some
developers love, while others hate...

So, let's make both happy by making it optional.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
This commit is contained in:
Mauro Carvalho Chehab 2020-03-24 11:36:10 +01:00
parent c39d57044a
commit c6774ee035
1 changed files with 27 additions and 4 deletions

View File

@ -25,14 +25,32 @@ menuconfig MEDIA_SUPPORT
Additional info and docs are available on the web at
<https://linuxtv.org>
menu "Types of devices to be supported"
if MEDIA_SUPPORT
config MEDIA_SUPPORT_FILTER
bool "Filter devices by their types"
depends on MEDIA_SUPPORT
help
Configuring the media subsystem can be complex, as there are
hundreds of drivers and other config options.
This menu offers option that will help the Kernel's config
system to hide drivers that are out of the scope of the
user needs, and disabling core support for unused APIs.
If not selected, all non-optional media core functionality
needed to support media drivers will be enabled. Also, all
media device drivers should be shown.
menu "Media device types"
visible if MEDIA_SUPPORT_FILTER
#
# Multimedia support - automatically enable V4L2 and DVB core
#
config MEDIA_CAMERA_SUPPORT
bool "Cameras and video grabbers"
default y if !MEDIA_SUPPORT_FILTER
help
Enable support for webcams and video grabbers.
@ -40,6 +58,7 @@ config MEDIA_CAMERA_SUPPORT
config MEDIA_ANALOG_TV_SUPPORT
bool "Analog TV"
default y if !MEDIA_SUPPORT_FILTER
help
Enable analog TV support.
@ -47,6 +66,7 @@ config MEDIA_ANALOG_TV_SUPPORT
config MEDIA_DIGITAL_TV_SUPPORT
bool "Digital TV"
default y if !MEDIA_SUPPORT_FILTER
help
Enable digital TV support.
@ -54,6 +74,7 @@ config MEDIA_DIGITAL_TV_SUPPORT
config MEDIA_RADIO_SUPPORT
bool "AM/FM radio receivers/transmitters"
default y if !MEDIA_SUPPORT_FILTER
help
Enable AM/FM radio support.
@ -64,6 +85,7 @@ config MEDIA_RADIO_SUPPORT
config MEDIA_SDR_SUPPORT
bool "Software defined radio"
default y if !MEDIA_SUPPORT_FILTER
help
Enable software defined radio support.
@ -71,6 +93,7 @@ config MEDIA_SDR_SUPPORT
config MEDIA_CEC_SUPPORT
bool "HDMI CEC"
default y if !MEDIA_SUPPORT_FILTER
help
Enable support for HDMI CEC (Consumer Electronics Control),
which is an optional HDMI feature.
@ -80,6 +103,7 @@ config MEDIA_CEC_SUPPORT
config MEDIA_PLATFORM_SUPPORT
bool "Platform-specific devices"
default y if !MEDIA_SUPPORT_FILTER
help
Enable support for complex cameras, codecs, and other hardware
that are integrated at the CPU, GPU or on Image Signalling Processor
@ -92,6 +116,7 @@ config MEDIA_PLATFORM_SUPPORT
config MEDIA_TEST_SUPPORT
bool "Test drivers"
default y if !MEDIA_SUPPORT_FILTER
help
Those drivers should not be used on production Kernels, but
can be useful on debug ones. It enables several dummy drivers
@ -103,9 +128,7 @@ config MEDIA_TEST_SUPPORT
In case of doubts, say N.
Say Y when you have a software defined radio device.
endmenu # Types of devices to be supported
if MEDIA_SUPPORT
endmenu # media device types
comment "Multimedia core features"