1059b1c5bSMauro Carvalho Chehab.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later 254f38fcaSMauro Carvalho Chehab 354f38fcaSMauro Carvalho Chehab.. _media-controller-model: 454f38fcaSMauro Carvalho Chehab 554f38fcaSMauro Carvalho ChehabMedia device model 654f38fcaSMauro Carvalho Chehab================== 754f38fcaSMauro Carvalho Chehab 854f38fcaSMauro Carvalho ChehabDiscovering a device internal topology, and configuring it at runtime, 954f38fcaSMauro Carvalho Chehabis one of the goals of the media controller API. To achieve this, 1054f38fcaSMauro Carvalho Chehabhardware devices and Linux Kernel interfaces are modelled as graph 1154f38fcaSMauro Carvalho Chehabobjects on an oriented graph. The object types that constitute the graph 1254f38fcaSMauro Carvalho Chehabare: 1354f38fcaSMauro Carvalho Chehab 1454f38fcaSMauro Carvalho Chehab- An **entity** is a basic media hardware or software building block. 1554f38fcaSMauro Carvalho Chehab It can correspond to a large variety of logical blocks such as 1654f38fcaSMauro Carvalho Chehab physical hardware devices (CMOS sensor for instance), logical 1754f38fcaSMauro Carvalho Chehab hardware devices (a building block in a System-on-Chip image 1854f38fcaSMauro Carvalho Chehab processing pipeline), DMA channels or physical connectors. 1954f38fcaSMauro Carvalho Chehab 2054f38fcaSMauro Carvalho Chehab- An **interface** is a graph representation of a Linux Kernel 2154f38fcaSMauro Carvalho Chehab userspace API interface, like a device node or a sysfs file that 2254f38fcaSMauro Carvalho Chehab controls one or more entities in the graph. 2354f38fcaSMauro Carvalho Chehab 2454f38fcaSMauro Carvalho Chehab- A **pad** is a data connection endpoint through which an entity can 2554f38fcaSMauro Carvalho Chehab interact with other entities. Data (not restricted to video) produced 2654f38fcaSMauro Carvalho Chehab by an entity flows from the entity's output to one or more entity 2754f38fcaSMauro Carvalho Chehab inputs. Pads should not be confused with physical pins at chip 2854f38fcaSMauro Carvalho Chehab boundaries. 2954f38fcaSMauro Carvalho Chehab 3054f38fcaSMauro Carvalho Chehab- A **data link** is a point-to-point oriented connection between two 3154f38fcaSMauro Carvalho Chehab pads, either on the same entity or on different entities. Data flows 3254f38fcaSMauro Carvalho Chehab from a source pad to a sink pad. 3354f38fcaSMauro Carvalho Chehab 3454f38fcaSMauro Carvalho Chehab- An **interface link** is a point-to-point bidirectional control 3554f38fcaSMauro Carvalho Chehab connection between a Linux Kernel interface and an entity. 36*4e4dab4bSDaniel Scally 37*4e4dab4bSDaniel Scally- An **ancillary link** is a point-to-point connection denoting that two 38*4e4dab4bSDaniel Scally entities form a single logical unit. For example this could represent the 39*4e4dab4bSDaniel Scally fact that a particular camera sensor and lens controller form a single 40*4e4dab4bSDaniel Scally physical module, meaning this lens controller drives the lens for this 41*4e4dab4bSDaniel Scally camera sensor.