brintos

brintos / linux-shallow public Read only

0
0
Text · 1.5 KiB · fce7eaf Raw
34 lines · plain
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later2 3.. _media-controller-intro:4 5Introduction6============7 8Media devices increasingly handle multiple related functions. Many USB9cameras include microphones, video capture hardware can also output10video, or SoC camera interfaces also perform memory-to-memory operations11similar to video codecs.12 13Independent functions, even when implemented in the same hardware, can14be modelled as separate devices. A USB camera with a microphone will be15presented to userspace applications as V4L2 and ALSA capture devices.16The devices' relationships (when using a webcam, end-users shouldn't17have to manually select the associated USB microphone), while not made18available directly to applications by the drivers, can usually be19retrieved from sysfs.20 21With more and more advanced SoC devices being introduced, the current22approach will not scale. Device topologies are getting increasingly23complex and can't always be represented by a tree structure. Hardware24blocks are shared between different functions, creating dependencies25between seemingly unrelated devices.26 27Kernel abstraction APIs such as V4L2 and ALSA provide means for28applications to access hardware parameters. As newer hardware expose an29increasingly high number of those parameters, drivers need to guess what30applications really require based on limited information, thereby31implementing policies that belong to userspace.32 33The media controller API aims at solving those problems.34