Skip to contentSkip to conversation

VIDEO_V4L1 shouldn't be user-visible

PATCH NAK Adrian Bunk 3 participants 6 messages Jun 29, 2006 – Jun 30, 2006 Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 VIDEO_V4L1 shouldn't be user-visible

VIDEO_V4L1 is an implementation detail that shouldn't be user-visible.

This patch changes VIDEO_V4L1 to be no longer user-visible and being delect'ed by all drivers requiring it.

---

 drivers/media/Kconfig                |    9 ---
 drivers/media/dvb/ttpci/Kconfig      |   15 +++--
 drivers/media/radio/Kconfig          |   46 +++++++++++------
 drivers/media/video/Kconfig          |   71 +++++++++++++++++----------
 drivers/media/video/em28xx/Kconfig   |    3 -
 drivers/media/video/et61x251/Kconfig |    3 -
 drivers/media/video/pwc/Kconfig      |    3 -
 drivers/media/video/sn9c102/Kconfig  |    3 -
 drivers/media/video/usbvideo/Kconfig |    9 ++-
 drivers/media/video/zc0301/Kconfig   |    3 -
 10 files changed, 104 insertions(+), 61 deletions(-)
drivers/media/Kconfig renamed from drivers/media/Kconfig.old +1 -8
@@ -25,15 +25,8 @@
 	  module will be called videodev.
 
 config VIDEO_V4L1
-	bool "Enable Video For Linux API 1 (DEPRECATED)"
-	depends on VIDEO_DEV
+	bool
 	select VIDEO_V4L1_COMPAT
-	default y
-	---help---
-	  Enables a compatibility API used by most V4L2 devices to allow
-	  its usage with legacy applications that supports only V4L1 api.
-
-	  If you are unsure as to whether this is required, answer Y.
 
 config VIDEO_V4L1_COMPAT
 	bool "Enable Video For Linux API 1 compatible Layer"
drivers/media/dvb/ttpci/Kconfig renamed from drivers/media/dvb/ttpci/Kconfig.old +10 -5
@@ -1,6 +1,6 @@
 config DVB_AV7110
 	tristate "AV7110 cards"
-	depends on DVB_CORE && PCI && I2C && VIDEO_V4L1
+	depends on DVB_CORE && PCI && I2C && VIDEO_DEV
 	select FW_LOADER
 	select VIDEO_SAA7146_VV
 	select DVB_VES1820
@@ -11,6 +11,7 @@
 	select DVB_STV0297
 	select DVB_L64781
 	select DVB_LNBP21
+	select VIDEO_V4L1
 	help
 	  Support for SAA7146 and AV7110 based DVB cards as produced
 	  by Fujitsu-Siemens, Technotrend, Hauppauge and others.
@@ -59,7 +60,7 @@
 
 config DVB_BUDGET
 	tristate "Budget cards"
-	depends on DVB_CORE && PCI && I2C && VIDEO_V4L1
+	depends on DVB_CORE && PCI && I2C && VIDEO_DEV
 	select VIDEO_SAA7146
 	select DVB_STV0299
 	select DVB_VES1X93
@@ -69,6 +70,7 @@
 	select DVB_TDA10021
 	select DVB_S5H1420
 	select DVB_LNBP21
+	select VIDEO_V4L1
 	help
 	  Support for simple SAA7146 based DVB cards
 	  (so called Budget- or Nova-PCI cards) without onboard
@@ -81,12 +83,13 @@
 
 config DVB_BUDGET_CI
 	tristate "Budget cards with onboard CI connector"
-	depends on DVB_CORE && PCI && I2C && VIDEO_V4L1
+	depends on DVB_CORE && PCI && I2C && VIDEO_DEV
 	select VIDEO_SAA7146
 	select DVB_STV0297
 	select DVB_STV0299
 	select DVB_TDA1004X
 	select DVB_LNBP21
+	select VIDEO_V4L1
 	help
 	  Support for simple SAA7146 based DVB cards
 	  (so called Budget- or Nova-PCI cards) without onboard
@@ -102,12 +105,13 @@
 
 config DVB_BUDGET_AV
 	tristate "Budget cards with analog video inputs"
-	depends on DVB_CORE && PCI && I2C && VIDEO_V4L1
+	depends on DVB_CORE && PCI && I2C && VIDEO_DEV
 	select VIDEO_SAA7146_VV
 	select DVB_STV0299
 	select DVB_TDA1004X
 	select DVB_TDA10021
 	select FW_LOADER
+	select VIDEO_V4L1
 	help
 	  Support for simple SAA7146 based DVB cards
 	  (so called Budget- or Nova-PCI cards) without onboard
@@ -120,11 +124,12 @@
 
 config DVB_BUDGET_PATCH
 	tristate "AV7110 cards with Budget Patch"
-	depends on DVB_CORE && DVB_BUDGET && VIDEO_V4L1
+	depends on DVB_CORE && DVB_BUDGET && VIDEO_DEV
 	select DVB_AV7110
 	select DVB_STV0299
 	select DVB_VES1X93
 	select DVB_TDA8083
+	select VIDEO_V4L1
 	help
 	  Support for Budget Patch (full TS) modification on
 	  SAA7146+AV7110 based cards (DVB-S cards). This
drivers/media/radio/Kconfig renamed from drivers/media/radio/Kconfig.old +30 -16

139 lines not on this page · raw message

drivers/media/video/Kconfig renamed from drivers/media/video/Kconfig.old +47 -24

214 lines not on this page · raw message

drivers/media/video/em28xx/Kconfig renamed from drivers/media/video/em28xx/Kconfig.old +2 -1
@@ -1,6 +1,7 @@
 config VIDEO_EM28XX
 	tristate "Empia EM2800/2820/2840 USB video capture support"
-	depends on VIDEO_V4L1 && USB && I2C
+	depends on USB && I2C
+	select VIDEO_V4L1
 	select VIDEO_BUF
 	select VIDEO_TUNER
 	select VIDEO_TVEEPROM
drivers/media/video/et61x251/Kconfig renamed from drivers/media/video/et61x251/Kconfig.old +2 -1
@@ -1,6 +1,7 @@
 config USB_ET61X251
 	tristate "USB ET61X[12]51 PC Camera Controller support"
-	depends on USB && VIDEO_V4L1
+	depends on USB
+	select VIDEO_V4L1
 	---help---
 	  Say Y here if you want support for cameras based on Etoms ET61X151
 	  or ET61X251 PC Camera Controllers.
drivers/media/video/pwc/Kconfig renamed from drivers/media/video/pwc/Kconfig.old +2 -1
@@ -1,6 +1,7 @@
 config USB_PWC
 	tristate "USB Philips Cameras"
-	depends on USB && VIDEO_V4L1
+	depends on USB
+	select VIDEO_V4L1
 	---help---
 	  Say Y or M here if you want to use one of these Philips & OEM
 	  webcams:
drivers/media/video/sn9c102/Kconfig renamed from drivers/media/video/sn9c102/Kconfig.old +2 -1
@@ -1,6 +1,7 @@
 config USB_SN9C102
 	tristate "USB SN9C10x PC Camera Controller support"
-	depends on USB && VIDEO_V4L1
+	depends on USB 
+	select VIDEO_V4L1
 	---help---
 	  Say Y here if you want support for cameras based on SONiX SN9C101,
 	  SN9C102 or SN9C103 PC Camera Controllers.
drivers/media/video/usbvideo/Kconfig renamed from drivers/media/video/usbvideo/Kconfig.old +6 -3
@@ -3,7 +3,8 @@
 
 config USB_VICAM
 	tristate "USB 3com HomeConnect (aka vicam) support (EXPERIMENTAL)"
-	depends on USB && VIDEO_V4L1 && EXPERIMENTAL
+	depends on USB && EXPERIMENTAL
+	select VIDEO_V4L1
 	select VIDEO_USBVIDEO
 	---help---
 	  Say Y here if you have 3com homeconnect camera (vicam).
@@ -13,7 +14,8 @@
 
 config USB_IBMCAM
 	tristate "USB IBM (Xirlink) C-it Camera support"
-	depends on USB && VIDEO_V4L1
+	depends on USB
+	select VIDEO_V4L1
 	select VIDEO_USBVIDEO
 	---help---
 	  Say Y here if you want to connect a IBM "C-It" camera, also known as
@@ -28,7 +30,8 @@
 
 config USB_KONICAWC
 	tristate "USB Konica Webcam support"
-	depends on USB && VIDEO_V4L1
+	depends on USB
+	select VIDEO_V4L1
 	select VIDEO_USBVIDEO
 	---help---
 	  Say Y here if you want support for webcams based on a Konica
drivers/media/video/zc0301/Kconfig renamed from drivers/media/video/zc0301/Kconfig.old +2 -1
@@ -1,6 +1,7 @@
 config USB_ZC0301
 	tristate "USB ZC0301[P] Image Processor and Control Chip support"
-	depends on USB && VIDEO_V4L1
+	depends on USB
+	select VIDEO_V4L1
 	---help---
 	  Say Y here if you want support for cameras based on the ZC0301 or
 	  ZC0301P Image Processors and Control Chips.
#1 lore raw

Adrian,

Em Qui, 2006-06-29 às 21:21 +0200, Adrian Bunk escreveu:

Quoted 1 line

VIDEO_V4L1 is an implementation detail that shouldn't be user-visible.

Nack.

V4L1 is an obsolete api, just like OSS, marked at feature-removal-schedule.txt to be removed on July (probably, we might need to postpone this, but this is another question).

This API have serious trouble on handling video and audio standards used on analog world and should be discontinued in favor of V4L2 API. Like ALSA have, V4L2 drivers also have a compatibility driver that changes calls from legacy userspace applications into newer V4L2 calls (of course losing several features, working fine only for a few video standards that were supported by V4L1).

Cheers,
Mauro.

#2 lore raw
Quoted 1 line · Mauro Carvalho Chehab

Adrian,

Hi Mauro,

Quoted 9 lines

Em Qui, 2006-06-29 às 21:21 +0200, Adrian Bunk escreveu:

Quoted 1 line

VIDEO_V4L1 is an implementation detail that shouldn't be user-visible.

Nack.

V4L1 is an obsolete api, just like OSS, marked at feature-removal-schedule.txt to be removed on July (probably, we might need to postpone this, but this is another question).

Quoted 6 lines

This API have serious trouble on handling video and audio standards used on analog world and should be discontinued in favor of V4L2 API. Like ALSA have, V4L2 drivers also have a compatibility driver that changes calls from legacy userspace applications into newer V4L2 calls (of course losing several features, working fine only for a few video standards that were supported by V4L1).

I might not understand the issue well enough for getting your point.

My point is:

For users (= people compiling their own kernel), the obsolete in-kernel API is an implementation detail.

When configuring the kernel, the important thing for users is to find the driver for their hardware, not which internal APIs the driver is using.

The userspace visible part VIDEO_V4L1_COMPAT is something different, and it shouldn't be hidden.

Quoted 2 lines

Cheers,
Mauro.

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed
#3 lore raw

Hi, Adrian,
Em Qui, 2006-06-29 às 23:08 +0200, Adrian Bunk escreveu:

Quoted 8 lines · Mauro Carvalho Chehab

I might not understand the issue well enough for getting your point.

My point is:

For users (= people compiling their own kernel), the obsolete in-kernel API is an implementation detail.

It is not the in-kernel API, but the userspace API.

V4L1 api cannot handle several needs from userspace.

For example, V4L1 API, there are just 3 video standards: PAL (you can read here EU PAL), NTSC (you can read here US NTSC) and SECAM ( you can read here France). So, api works fine only on two continents. All the rest of the globe cannot use a V4L1 for a TV device. On V4L2 API, you can select all known video standards (like for example NTSC/M Korea - with have some particular issues with audio channels that require some adjustments at audio decoders).

Quoted 3 lines

When configuring the kernel, the important thing for users is to find the driver for their hardware, not which internal APIs the driver is using.

The user still can still select the proper hardware support, being warned that the device is obsolete, and a proper legacy application should be used instead.

I did the comparative between OSS/ALSA and V4L1/V4L2 because the similarities. Both OSS and V4L1 are obsoleted APIs that need to be removed from kernel, due to implementation issues. OSS is marked as depreciated at Kconfig menus. User can include an OSS driver and use it, but should know that those stuff is obsolete. The same should apply to video/radio users.

Also, on V4L side, the V4L1 api is stopping V4L development. V4L API 2 is already at kernel since the beginning of kernel 2.6 series, and fixes several flaws at the old api (V4L1 API were designed on 2.1 series). Still now, most applications still implement only V4L1, and people do submit newer v4l1 drivers to us.

We do really go ahead, making V4L2 API the standard.

Quoted 2 lines

The userspace visible part VIDEO_V4L1_COMPAT is something different, and it shouldn't be hidden.

Allowing unselecting V4L1 and V4L1_COMPAT is also very useful for testing the compliance of applications, helping application developers as well.

Cheers,
Mauro.

#4 lore raw
Quoted 7 lines · Mauro Carvalho Chehab

Also, on V4L side, the V4L1 api is stopping V4L development. V4L API 2 is already at kernel since the beginning of kernel 2.6 series, and fixes several flaws at the old api (V4L1 API were designed on 2.1 series). Still now, most applications still implement only V4L1, and people do submit newer v4l1 drivers to us.

We do really go ahead, making V4L2 API the standard.

I don't think anyone would complain about dropping V4L1 if the people pushing V4L2 were to port the 25 or so drivers that depend on V4L1 to the V4L2 API. As long as those V4L1 dependent drivers are around people are going to want to keep using V4L1. You may want to consider building some in-kernel compatibility APIs into V4L2 to make porting those drivers easier.

Signature · 2 lines
Jon Smirl
[email protected]
#5 lore raw

Em Qui, 2006-06-29 às 20:59 -0400, Jon Smirl escreveu:

Quoted 7 lines · Mauro Carvalho Chehab
Quoted 6 lines

Also, on V4L side, the V4L1 api is stopping V4L development. V4L API 2 is already at kernel since the beginning of kernel 2.6 series, and fixes several flaws at the old api (V4L1 API were designed on 2.1 series). Still now, most applications still implement only V4L1, and people do submit newer v4l1 drivers to us.

Quoted 5 lines
Quoted 1 line

We do really go ahead, making V4L2 API the standard.

I don't think anyone would complain about dropping V4L1 if the people pushing V4L2 were to port the 25 or so drivers that depend on V4L1 to the V4L2 API.

We are working on it. The issue will be someone to test all those drivers for the obsolete hardwares.

Quoted 4 lines

As long as those V4L1 dependent drivers are around
people are going to want to keep using V4L1. You may want to consider building some in-kernel compatibility APIs into V4L2 to make porting those drivers easier.

Most of changes are just trivial. Just one will requre more work, since it is related to newer mmap methods on V4L2.

Quoted 1 line

Cheers,
Mauro.