diff mbox series

[1/9] staging/media: add a STAGING_MEDIA_DEPRECATED option

Message ID 20220811091749.3956641-2-hverkuil-cisco@xs4all.nl (mailing list archive)
State New, archived
Headers show
Series Deprecate old non-vb2 drivers | expand

Commit Message

Hans Verkuil Aug. 11, 2022, 9:17 a.m. UTC
Add a kernel config option to build deprecated media drivers
that are scheduled for removal. Move stkwebcam to the deprecated
directory to make it clear that this driver is deprecated.

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
---
 drivers/staging/media/Kconfig                  | 18 ++++++++++++++++--
 drivers/staging/media/Makefile                 |  2 +-
 .../media/{ => deprecated}/stkwebcam/Kconfig   |  0
 .../media/{ => deprecated}/stkwebcam/Makefile  |  0
 .../media/{ => deprecated}/stkwebcam/TODO      |  0
 .../{ => deprecated}/stkwebcam/stk-sensor.c    |  0
 .../{ => deprecated}/stkwebcam/stk-webcam.c    |  0
 .../{ => deprecated}/stkwebcam/stk-webcam.h    |  0
 8 files changed, 17 insertions(+), 3 deletions(-)
 rename drivers/staging/media/{ => deprecated}/stkwebcam/Kconfig (100%)
 rename drivers/staging/media/{ => deprecated}/stkwebcam/Makefile (100%)
 rename drivers/staging/media/{ => deprecated}/stkwebcam/TODO (100%)
 rename drivers/staging/media/{ => deprecated}/stkwebcam/stk-sensor.c (100%)
 rename drivers/staging/media/{ => deprecated}/stkwebcam/stk-webcam.c (100%)
 rename drivers/staging/media/{ => deprecated}/stkwebcam/stk-webcam.h (100%)
diff mbox series

Patch

diff --git a/drivers/staging/media/Kconfig b/drivers/staging/media/Kconfig
index 421ce9dbf44c..3545ba722037 100644
--- a/drivers/staging/media/Kconfig
+++ b/drivers/staging/media/Kconfig
@@ -38,12 +38,26 @@  source "drivers/staging/media/omap4iss/Kconfig"
 
 source "drivers/staging/media/rkvdec/Kconfig"
 
-source "drivers/staging/media/stkwebcam/Kconfig"
-
 source "drivers/staging/media/sunxi/Kconfig"
 
 source "drivers/staging/media/tegra-video/Kconfig"
 
 source "drivers/staging/media/zoran/Kconfig"
 
+menuconfig STAGING_MEDIA_DEPRECATED
+	bool "Media staging drivers (DEPRECATED)"
+	default n
+	help
+	  This option enables deprecated media drivers that are
+	  scheduled for future removal from the kernel.
+
+	  If you wish to work on these drivers to prevent their removal,
+	  then contact the linux-media@vger.kernel.org mailing list.
+
+	  If in doubt, say N here.
+
+if STAGING_MEDIA_DEPRECATED
+source "drivers/staging/media/deprecated/stkwebcam/Kconfig"
+endif
+
 endif
diff --git a/drivers/staging/media/Makefile b/drivers/staging/media/Makefile
index 950e96f10aad..c516764b5393 100644
--- a/drivers/staging/media/Makefile
+++ b/drivers/staging/media/Makefile
@@ -5,7 +5,7 @@  obj-$(CONFIG_VIDEO_MAX96712)	+= max96712/
 obj-$(CONFIG_VIDEO_MESON_VDEC)	+= meson/vdec/
 obj-$(CONFIG_VIDEO_OMAP4)	+= omap4iss/
 obj-$(CONFIG_VIDEO_ROCKCHIP_VDEC)	+= rkvdec/
-obj-$(CONFIG_VIDEO_STKWEBCAM)	+= stkwebcam/
+obj-$(CONFIG_VIDEO_STKWEBCAM)	+= deprecated/stkwebcam/
 obj-$(CONFIG_VIDEO_SUNXI)	+= sunxi/
 obj-$(CONFIG_VIDEO_TEGRA)	+= tegra-video/
 obj-$(CONFIG_VIDEO_HANTRO)	+= hantro/
diff --git a/drivers/staging/media/stkwebcam/Kconfig b/drivers/staging/media/deprecated/stkwebcam/Kconfig
similarity index 100%
rename from drivers/staging/media/stkwebcam/Kconfig
rename to drivers/staging/media/deprecated/stkwebcam/Kconfig
diff --git a/drivers/staging/media/stkwebcam/Makefile b/drivers/staging/media/deprecated/stkwebcam/Makefile
similarity index 100%
rename from drivers/staging/media/stkwebcam/Makefile
rename to drivers/staging/media/deprecated/stkwebcam/Makefile
diff --git a/drivers/staging/media/stkwebcam/TODO b/drivers/staging/media/deprecated/stkwebcam/TODO
similarity index 100%
rename from drivers/staging/media/stkwebcam/TODO
rename to drivers/staging/media/deprecated/stkwebcam/TODO
diff --git a/drivers/staging/media/stkwebcam/stk-sensor.c b/drivers/staging/media/deprecated/stkwebcam/stk-sensor.c
similarity index 100%
rename from drivers/staging/media/stkwebcam/stk-sensor.c
rename to drivers/staging/media/deprecated/stkwebcam/stk-sensor.c
diff --git a/drivers/staging/media/stkwebcam/stk-webcam.c b/drivers/staging/media/deprecated/stkwebcam/stk-webcam.c
similarity index 100%
rename from drivers/staging/media/stkwebcam/stk-webcam.c
rename to drivers/staging/media/deprecated/stkwebcam/stk-webcam.c
diff --git a/drivers/staging/media/stkwebcam/stk-webcam.h b/drivers/staging/media/deprecated/stkwebcam/stk-webcam.h
similarity index 100%
rename from drivers/staging/media/stkwebcam/stk-webcam.h
rename to drivers/staging/media/deprecated/stkwebcam/stk-webcam.h