1 .. SPDX-License-Identifier: GFDL-1.1-no-invari 1 .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later 2 2 3 .. _media-controller-intro: 3 .. _media-controller-intro: 4 4 5 Introduction 5 Introduction 6 ============ 6 ============ 7 7 8 Media devices increasingly handle multiple rel 8 Media devices increasingly handle multiple related functions. Many USB 9 cameras include microphones, video capture har 9 cameras include microphones, video capture hardware can also output 10 video, or SoC camera interfaces also perform m 10 video, or SoC camera interfaces also perform memory-to-memory operations 11 similar to video codecs. 11 similar to video codecs. 12 12 13 Independent functions, even when implemented i 13 Independent functions, even when implemented in the same hardware, can 14 be modelled as separate devices. A USB camera 14 be modelled as separate devices. A USB camera with a microphone will be 15 presented to userspace applications as V4L2 an 15 presented to userspace applications as V4L2 and ALSA capture devices. 16 The devices' relationships (when using a webca 16 The devices' relationships (when using a webcam, end-users shouldn't 17 have to manually select the associated USB mic 17 have to manually select the associated USB microphone), while not made 18 available directly to applications by the driv 18 available directly to applications by the drivers, can usually be 19 retrieved from sysfs. 19 retrieved from sysfs. 20 20 21 With more and more advanced SoC devices being 21 With more and more advanced SoC devices being introduced, the current 22 approach will not scale. Device topologies are 22 approach will not scale. Device topologies are getting increasingly 23 complex and can't always be represented by a t 23 complex and can't always be represented by a tree structure. Hardware 24 blocks are shared between different functions, 24 blocks are shared between different functions, creating dependencies 25 between seemingly unrelated devices. 25 between seemingly unrelated devices. 26 26 27 Kernel abstraction APIs such as V4L2 and ALSA 27 Kernel abstraction APIs such as V4L2 and ALSA provide means for 28 applications to access hardware parameters. As 28 applications to access hardware parameters. As newer hardware expose an 29 increasingly high number of those parameters, 29 increasingly high number of those parameters, drivers need to guess what 30 applications really require based on limited i 30 applications really require based on limited information, thereby 31 implementing policies that belong to userspace 31 implementing policies that belong to userspace. 32 32 33 The media controller API aims at solving those 33 The media controller API aims at solving those problems.
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.