1- Graphs
1+ .. SPDX-License-Identifier: GPL-2.0
22
3+ ======
4+ Graphs
5+ ======
36
47_DSD
5- ----
8+ ====
69
710_DSD (Device Specific Data) [7] is a predefined ACPI device
811configuration object that can be used to convey information on
@@ -30,17 +33,17 @@ hierarchical data extension array on each depth.
3033
3134
3235Ports and endpoints
33- -------------------
36+ ===================
3437
3538The port and endpoint concepts are very similar to those in Devicetree
3639[3]. A port represents an interface in a device, and an endpoint
3740represents a connection to that interface.
3841
3942All port nodes are located under the device's "_DSD" node in the hierarchical
4043data extension tree. The data extension related to each port node must begin
41- with "port" and must be followed by the "@" character and the number of the port
42- as its key. The target object it refers to should be called "PRTX", where "X" is
43- the number of the port. An example of such a package would be:
44+ with "port" and must be followed by the "@" character and the number of the
45+ port as its key. The target object it refers to should be called "PRTX", where
46+ "X" is the number of the port. An example of such a package would be: :
4447
4548 Package() { "port@4", PRT4 }
4649
@@ -49,7 +52,7 @@ data extension key of the endpoint nodes must begin with
4952"endpoint" and must be followed by the "@" character and the number of the
5053endpoint. The object it refers to should be called "EPXY", where "X" is the
5154number of the port and "Y" is the number of the endpoint. An example of such a
52- package would be:
55+ package would be::
5356
5457 Package() { "endpoint@0", EP40 }
5558
@@ -62,113 +65,113 @@ of that port shall be zero. Similarly, if a port may only have a single
6265endpoint, the number of that endpoint shall be zero.
6366
6467The endpoint reference uses property extension with "remote-endpoint" property
65- name followed by a reference in the same package. Such references consist of the
68+ name followed by a reference in the same package. Such references consist of
6669the remote device reference, the first package entry of the port data extension
6770reference under the device and finally the first package entry of the endpoint
68- data extension reference under the port. Individual references thus appear as:
71+ data extension reference under the port. Individual references thus appear as::
6972
7073 Package() { device, "port@X", "endpoint@Y" }
7174
72- In the above example, "X" is the number of the port and "Y" is the number of the
73- endpoint.
75+ In the above example, "X" is the number of the port and "Y" is the number of
76+ the endpoint.
7477
7578The references to endpoints must be always done both ways, to the
7679remote endpoint and back from the referred remote endpoint node.
7780
78- A simple example of this is show below:
81+ A simple example of this is show below::
7982
8083 Scope (\_SB.PCI0.I2C2)
8184 {
82- Device (CAM0)
83- {
84- Name (_DSD, Package () {
85- ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
86- Package () {
87- Package () { "compatible", Package () { "nokia,smia" } },
88- },
89- ToUUID("dbb8e3e6-5886-4ba6-8795-1319f52a966b"),
90- Package () {
91- Package () { "port@0", PRT0 },
92- }
93- })
94- Name (PRT0, Package() {
95- ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
96- Package () {
97- Package () { "reg", 0 },
98- },
99- ToUUID("dbb8e3e6-5886-4ba6-8795-1319f52a966b"),
100- Package () {
101- Package () { "endpoint@0", EP00 },
102- }
103- })
104- Name (EP00, Package() {
105- ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
106- Package () {
107- Package () { "reg", 0 },
108- Package () { "remote-endpoint", Package() { \_SB.PCI0.ISP, "port@4", "endpoint@0" } },
109- }
110- })
111- }
85+ Device (CAM0)
86+ {
87+ Name (_DSD, Package () {
88+ ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
89+ Package () {
90+ Package () { "compatible", Package () { "nokia,smia" } },
91+ },
92+ ToUUID("dbb8e3e6-5886-4ba6-8795-1319f52a966b"),
93+ Package () {
94+ Package () { "port@0", PRT0 },
95+ }
96+ })
97+ Name (PRT0, Package() {
98+ ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
99+ Package () {
100+ Package () { "reg", 0 },
101+ },
102+ ToUUID("dbb8e3e6-5886-4ba6-8795-1319f52a966b"),
103+ Package () {
104+ Package () { "endpoint@0", EP00 },
105+ }
106+ })
107+ Name (EP00, Package() {
108+ ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
109+ Package () {
110+ Package () { "reg", 0 },
111+ Package () { "remote-endpoint", Package() { \_SB.PCI0.ISP, "port@4", "endpoint@0" } },
112+ }
113+ })
114+ }
112115 }
113116
114117 Scope (\_SB.PCI0)
115118 {
116- Device (ISP)
117- {
118- Name (_DSD, Package () {
119- ToUUID("dbb8e3e6-5886-4ba6-8795-1319f52a966b"),
120- Package () {
121- Package () { "port@4", PRT4 },
122- }
123- })
124-
125- Name (PRT4, Package() {
126- ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
127- Package () {
128- Package () { "reg", 4 }, /* CSI-2 port number */
129- },
130- ToUUID("dbb8e3e6-5886-4ba6-8795-1319f52a966b"),
131- Package () {
132- Package () { "endpoint@0", EP40 },
133- }
134- })
135-
136- Name (EP40, Package() {
137- ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
138- Package () {
139- Package () { "reg", 0 },
140- Package () { "remote-endpoint", Package () { \_SB.PCI0.I2C2.CAM0, "port@0", "endpoint@0" } },
141- }
142- })
143- }
119+ Device (ISP)
120+ {
121+ Name (_DSD, Package () {
122+ ToUUID("dbb8e3e6-5886-4ba6-8795-1319f52a966b"),
123+ Package () {
124+ Package () { "port@4", PRT4 },
125+ }
126+ })
127+
128+ Name (PRT4, Package() {
129+ ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
130+ Package () {
131+ Package () { "reg", 4 }, /* CSI-2 port number */
132+ },
133+ ToUUID("dbb8e3e6-5886-4ba6-8795-1319f52a966b"),
134+ Package () {
135+ Package () { "endpoint@0", EP40 },
136+ }
137+ })
138+
139+ Name (EP40, Package() {
140+ ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
141+ Package () {
142+ Package () { "reg", 0 },
143+ Package () { "remote-endpoint", Package () { \_SB.PCI0.I2C2.CAM0, "port@0", "endpoint@0" } },
144+ }
145+ })
146+ }
144147 }
145148
146149Here, the port 0 of the "CAM0" device is connected to the port 4 of
147150the "ISP" device and vice versa.
148151
149152
150153References
151- ----------
154+ ==========
152155
153156[1] _DSD (Device Specific Data) Implementation Guide.
154- <URL: http://www.uefi.org/sites/default/files/resources/_DSD-implementation-guide-toplevel-1_1.htm> ,
157+ http://www.uefi.org/sites/default/files/resources/_DSD-implementation-guide-toplevel-1_1.htm,
155158 referenced 2016-10-03.
156159
157- [2] Devicetree. <URL: http://www.devicetree.org> , referenced 2016-10-03.
160+ [2] Devicetree. http://www.devicetree.org, referenced 2016-10-03.
158161
159162[3] Documentation/devicetree/bindings/graph.txt
160163
161164[4] Device Properties UUID For _DSD.
162- <URL: http://www.uefi.org/sites/default/files/resources/_DSD-device-properties-UUID.pdf> ,
165+ http://www.uefi.org/sites/default/files/resources/_DSD-device-properties-UUID.pdf,
163166 referenced 2016-10-04.
164167
165168[5] Hierarchical Data Extension UUID For _DSD.
166- <URL: http://www.uefi.org/sites/default/files/resources/_DSD-hierarchical-data-extension-UUID-v1.1.pdf> ,
169+ http://www.uefi.org/sites/default/files/resources/_DSD-hierarchical-data-extension-UUID-v1.1.pdf,
167170 referenced 2016-10-04.
168171
169172[6] Advanced Configuration and Power Interface Specification.
170- <URL: http://www.uefi.org/sites/default/files/resources/ACPI_6_1.pdf> ,
173+ http://www.uefi.org/sites/default/files/resources/ACPI_6_1.pdf,
171174 referenced 2016-10-04.
172175
173176[7] _DSD Device Properties Usage Rules.
174- Documentation/acpi/ DSD-properties-rules.txt
177+ :doc: ` ../ DSD-properties-rules`
0 commit comments