xref: /openbmc/linux/drivers/staging/media/imx/TODO (revision 160b8e75)
1
2- The Frame Interval Monitor could be exported to v4l2-core for
3  general use.
4
5- The CSI subdevice parses its nearest upstream neighbor's device-tree
6  bus config in order to setup the CSI. Laurent Pinchart argues that
7  instead the CSI subdev should call its neighbor's g_mbus_config op
8  (which should be propagated if necessary) to get this info. However
9  Hans Verkuil is planning to remove the g_mbus_config op. For now this
10  driver uses the parsed DT bus config method until this issue is
11  resolved.
12
13- This media driver supports inheriting V4L2 controls to the
14  video capture devices, from the subdevices in the capture device's
15  pipeline. The controls for each capture device are updated in the
16  link_notify callback when the pipeline is modified. It should be
17  decided whether this feature is useful enough to make it generally
18  available by exporting to v4l2-core.
19
20- The OF graph is walked at probe time to form the list of fwnodes to
21  be passed to v4l2_async_notifier_register(), starting from the IPU
22  CSI ports. And after all async subdevices have been bound,
23  v4l2_fwnode_parse_link() is used to form the media links between
24  the entities discovered by walking the OF graph.
25
26  While this approach allows support for arbitrary OF graphs, there
27  are some assumptions for this to work:
28
29  1. All port parent nodes reachable in the graph from the IPU CSI
30     ports bind to V4L2 async subdevice drivers.
31
32     If a device has mixed-use ports such as video plus audio, the
33     endpoints from the audio ports are followed to devices that must
34     bind to V4L2 subdevice drivers, and not for example, to an ALSA
35     driver or a non-V4L2 media driver. If the device were bound to
36     such a driver, imx-media would never get an async completion
37     notification because the device fwnode was added to the async
38     list, but the driver does not interface with the V4L2 async
39     framework.
40
41  2. Every port reachable in the graph is treated as a media pad,
42     owned by the V4L2 subdevice that is bound to the port's parent.
43
44     This presents problems for devices that don't make this port = pad
45     assumption. Examples are SMIAPP compatible cameras which define only
46     a single output port node, but which define multiple pads owned
47     by multiple subdevices (pixel-array, binner, scaler). Or video
48     decoders (entity function MEDIA_ENT_F_ATV_DECODER), which also define
49     only a single output port node, but define multiple pads for video,
50     VBI, and audio out.
51
52     A workaround at present is to set the port reg properties to
53     correspond to the media pad index that the port represents. A
54     possible long-term solution is to implement a subdev API that
55     maps a port id to a media pad index.
56
57  3. Every endpoint of a port reachable in the graph is treated as
58     a media link, between V4L2 subdevices that are bound to the
59     port parents of the local and remote endpoints.
60
61     Which means a port must not contain mixed-use endpoints, they
62     must all refer to media links between V4L2 subdevices.
63