All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
To: Linux Media Mailing List <linux-media@vger.kernel.org>
Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Subject: [PATCH v4 22/33] media: Kconfig: make filtering devices optional
Date: Tue, 31 Mar 2020 13:11:58 +0200	[thread overview]
Message-ID: <53a0d97793a50891c7a1d67681c927cf45d0d947.1585651678.git.mchehab+huawei@kernel.org> (raw)
In-Reply-To: <cover.1585651678.git.mchehab+huawei@kernel.org>

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>
---
 drivers/media/Kconfig | 31 +++++++++++++++++++++++++++----
 1 file changed, 27 insertions(+), 4 deletions(-)

diff --git a/drivers/media/Kconfig b/drivers/media/Kconfig
index a57f898fa35e..8b070fb703f9 100644
--- a/drivers/media/Kconfig
+++ b/drivers/media/Kconfig
@@ -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"
 
-- 
2.25.1


  parent reply	other threads:[~2020-03-31 11:12 UTC|newest]

Thread overview: 63+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-31 11:11 [PATCH v4 00/33] Media Kconfig menu reorg and improvements Mauro Carvalho Chehab
2020-03-31 11:11 ` Mauro Carvalho Chehab
2020-03-31 11:11 ` Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 01/33] media: dvb-usb: auto-select CYPRESS_FIRMWARE Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 02/33] media: Kconfig: add an option to filter in/out platform drivers Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 03/33] media: Kconfig: not all V4L2 platform drivers are for camera Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 04/33] media: pci: move VIDEO_PCI_SKELETON to a different Kconfig Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 05/33] media: Kconfig: update the MEDIA_SUPPORT help message Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 06/33] media: split test drivers from platform directory Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 07/33] media: Kconfig: move comment to siano include Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 08/33] media: Kconfig: move drivers-specific TTPCI_EEPROM Kconfig var Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 09/33] media: Kconfig: mode firewire comment to firewire/Kconfig Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 10/33] media: ddbridge: copy the dvb_dummy_fe driver to ddbridge Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 11/33] media: ddbridge-dummy_fe: do some vars and function renames Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 12/33] media: ddbridge: use the ddbridge's own dummy fe driver Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 13/33] media: Kconfig: mark other drivers as test drivers Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 14/33] media: Kconfig: simplify some dependencies Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 15/33] media: Kconfig: better support hybrid TV devices Mauro Carvalho Chehab
2020-04-01  3:20   ` kbuild test robot
2020-04-01  3:20     ` kbuild test robot
2020-03-31 11:11 ` [PATCH v4 16/33] media: Kconfig: fix selection for test drivers Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 17/33] media: add SPDX headers on Kconfig and Makefile files Mauro Carvalho Chehab
2020-03-31 11:11   ` Mauro Carvalho Chehab
2020-03-31 11:11   ` Mauro Carvalho Chehab
2020-03-31 11:11   ` Mauro Carvalho Chehab
2020-03-31 12:06   ` Laurent Pinchart
2020-03-31 12:06     ` Laurent Pinchart
2020-03-31 12:06     ` Laurent Pinchart
2020-03-31 12:22     ` Greg Kroah-Hartman
2020-03-31 12:22       ` Greg Kroah-Hartman
2020-03-31 12:22       ` Greg Kroah-Hartman
2020-03-31 12:39       ` Laurent Pinchart
2020-03-31 12:39         ` Laurent Pinchart
2020-03-31 12:39         ` Laurent Pinchart
2020-03-31 12:47         ` Greg Kroah-Hartman
2020-03-31 12:47           ` Greg Kroah-Hartman
2020-03-31 12:47           ` Greg Kroah-Hartman
2020-03-31 12:52           ` Laurent Pinchart
2020-03-31 12:52             ` Laurent Pinchart
2020-03-31 12:52             ` Laurent Pinchart
2020-03-31 15:49     ` SPDX headers - Was: " Mauro Carvalho Chehab
2020-03-31 15:49       ` Mauro Carvalho Chehab
2020-03-31 15:49       ` Mauro Carvalho Chehab
2020-03-31 15:49       ` Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 18/33] media: dvb-core: Kconfig: default to use dynamic minors Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 19/33] media: Kconfig files: use select for V4L2 subdevs and MC Mauro Carvalho Chehab
2020-03-31 11:11   ` Mauro Carvalho Chehab
2020-03-31 11:11   ` Mauro Carvalho Chehab
2020-03-31 11:11   ` Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 20/33] media: Kconfig: reorganize the drivers menu options Mauro Carvalho Chehab
2020-03-31 11:11 ` [PATCH v4 21/33] media: Kconfig: use a sub-menu to select supported devices Mauro Carvalho Chehab
2020-03-31 11:11 ` Mauro Carvalho Chehab [this message]
2020-03-31 11:11 ` [PATCH v4 23/33] media: Kconfig: warn if drivers are filtered Mauro Carvalho Chehab
2020-03-31 11:12 ` [PATCH v4 24/33] media: Kconfig: move CEC-specific options to cec/Kconfig Mauro Carvalho Chehab
2020-03-31 11:12 ` [PATCH v4 25/33] media: Kconfig: move DVB-specific options to dvb-core/Kconfig Mauro Carvalho Chehab
2020-03-31 11:12 ` [PATCH v4 26/33] media: Kconfig: move V4L2 subdev API to v4l2-core/Kconfig Mauro Carvalho Chehab
2020-03-31 11:12 ` [PATCH v4 27/33] media: Kconfig: move media controller core select to main Kconfig Mauro Carvalho Chehab
2020-03-31 11:12 ` [PATCH v4 28/33] media: Kconfig: place all options under a sub-menu Mauro Carvalho Chehab
2020-03-31 11:12 ` [PATCH v4 29/33] media: Kconfig: move the position of sub-driver autoselection Mauro Carvalho Chehab
2020-03-31 11:12 ` [PATCH v4 30/33] media: Kconfig: on !EMBEDDED && !EXPERT, enable driver filtering Mauro Carvalho Chehab
2020-03-31 11:12 ` [PATCH v4 31/33] media: Kconfig: Better organize the per-API options Mauro Carvalho Chehab
2020-03-31 11:12 ` [PATCH v4 32/33] media: i2c/Kconfig: reorganize items there Mauro Carvalho Chehab
2020-03-31 11:12 ` [PATCH v4 33/33] media: Kconfig: don't use visible for device type select Mauro Carvalho Chehab

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=53a0d97793a50891c7a1d67681c927cf45d0d947.1585651678.git.mchehab+huawei@kernel.org \
    --to=mchehab+huawei@kernel.org \
    --cc=linux-media@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.