Skip to contentSkip to conversation

Improve generic DT binding documentation for media devices

PATCH New Sakari Ailus 3 participants 4 messages Sep 29, 2017 – Oct 6, 2017 1 message not in the archive

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

v3 cover Improve generic DT binding documentation for media devices

Hi folks,

This set improves the DT binding documentation for media devices where device specific documentation is lacking and also documents that explicit documentation of all properties supported by the device is required.

- Port and endpoint numbering
- lane numbering for the data-lanes property

since v2:

- Refer to Documentation/devicetree/bindings/graph.txt

- State that port and endpoint nodes need to be documented, but do not say that the numbering (unit-address and reg-property) is mandatory. This is in line with Device tree spec as well as graph.txt .

Sakari Ailus (2):
dt: bindings: media: Document practices for DT bindings, ports,
endpoints
dt: bindings: media: Document data lane numbering without lane
reordering

 .../devicetree/bindings/media/video-interfaces.txt         | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)
Signature · 1 line
2.7.4

A message that is not in the archive (sent off-list or not yet received): 1506673421-6085-1-git-send-email-sakari.ailus-VuQAYsv1563Yd54FQh9/[email protected]

#2 lore raw

PATCH v3 1/2 dt: bindings: media: Document practices for DT bindings, ports, endpoints

Port and endpoint numbering has been omitted in DT binding documentation for a large number of devices. Also common properties the device uses have been missed in binding documentation. Make it explicit that these things need to be documented.

---
 Documentation/devicetree/bindings/media/video-interfaces.txt | 9 +++++++++
 1 file changed, 9 insertions(+)
Documentation/devicetree/bindings/media/video-interfaces.txt +9 -0
index 852041a..bc8f18fb 100644
@@ -55,6 +55,15 @@ divided into two separate ITU-R BT.656 8-bit busses.  In such case bus-width
 and data-shift properties can be used to assign physical data lines to each
 endpoint node (logical bus).
 
+Documenting bindings for devices
+--------------------------------
+
+All required and optional bindings the device supports shall be explicitly
+documented in device DT binding documentation. This also includes port and
+endpoint nodes for the device, including unit-addresses and reg properties where
+relevant.
+
+Please also see Documentation/devicetree/bindings/graph.txt .
 
 Required properties
 -------------------
Signature · 6 lines
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
maintainer Acked-by on v3 1/2
#3 lore raw

Re: [PATCH v3 1/2] dt: bindings: media: Document practices for DT bindings, ports, endpoints

Quoted 9 lines · Sakari Ailus

Port and endpoint numbering has been omitted in DT binding documentation for a large number of devices. Also common properties the device uses have been missed in binding documentation. Make it explicit that these things need to be documented.

---
 Documentation/devicetree/bindings/media/video-interfaces.txt | 9 +++++++++
 1 file changed, 9 insertions(+)
#4 lore raw

PATCH v3 2/2 dt: bindings: media: Document data lane numbering without lane reordering

In reply to Sakari Ailus

Most devices do not support lane reordering and in many cases the documentation of the data-lanes property is incomplete for such devices. Document that in case the lane reordering isn't supported, monotonically incremented values from 0 or 1 shall be used.

---
 Documentation/devicetree/bindings/media/video-interfaces.txt | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
Documentation/devicetree/bindings/media/video-interfaces.txt +4 -1
index bc8f18fb..bd64749 100644
@@ -108,7 +108,10 @@ Optional endpoint properties
   determines the logical lane number, while the value of an entry indicates
   physical lane, e.g. for 2-lane MIPI CSI-2 bus we could have
   "data-lanes = <1 2>;", assuming the clock lane is on hardware lane 0.
-  This property is valid for serial busses only (e.g. MIPI CSI-2).
+  If the hardware does not support lane reordering, monotonically
+  incremented values shall be used from 0 or 1 onwards, depending on
+  whether or not there is also a clock lane. This property is valid for
+  serial busses only (e.g. MIPI CSI-2).
 - clock-lanes: an array of physical clock lane indexes. Position of an entry
   determines the logical lane number, while the value of an entry indicates
   physical lane, e.g. for a MIPI CSI-2 bus we could have "clock-lanes = <0>;",
Signature · 1 line
2.7.4