]> git.kernelconcepts.de Git - karo-tx-linux.git/blob - Documentation/devicetree/bindings/gpio/qcom,smp2p.txt
dt-binding: gpio: Introduce qcom,smp2p binding documentation
[karo-tx-linux.git] / Documentation / devicetree / bindings / gpio / qcom,smp2p.txt
1 Qualcomm Shared Memory Point 2 Point binding
2
3 The Shared Memory Point to Point (SMP2P) protocol facilitates communication of
4 a single 32-bit value between two processors.  Each value has a single writer
5 (the local side) and a single reader (the remote side).  Values are uniquely
6 identified in the system by the directed edge (local processor ID to remote
7 processor ID) and a string identifier. This documents defines the binding for a
8 driver that implements and exposes this protocol as a set of GPIO and interrupt
9 controllers.
10
11 - compatible:
12         Usage: required
13         Value type: <string>
14         Definition: must be one of:
15                     "qcom,smp2p"
16
17 - interrupts:
18         Usage: required
19         Value type: <prop-encoded-array>
20         Definition: one entry specifying the smp2p notification interrupt
21
22 - qcom,ipc:
23         Usage: required
24         Value type: <prop-encoded-array>
25         Definition: three entries specifying the outgoing ipc bit used for
26                     signaling the remote end of the smp2p edge:
27                     - phandle to a syscon node representing the apcs registers
28                     - u32 representing offset to the register within the syscon
29                     - u32 representing the ipc bit within the register
30
31 - qcom,smem:
32         Usage: required
33         Value type: <u32 array>
34         Definition: two identifiers of the inbound and outbound smem items used
35                     for this edge
36
37 - qcom,local-pid:
38         Usage: required
39         Value type: <u32>
40         Definition: specifies the identfier of the local endpoint of this edge
41
42 - qcom,remote-pid:
43         Usage: required
44         Value type: <u32>
45         Definition: specifies the identfier of the remote endpoint of this edge
46
47 = SUBNODES
48 Each SMP2P pair contain a set of inbound and outbound entries, these are
49 described in subnodes of the smp2p device node. The node names are not
50 important.
51
52 - qcom,entry-name:
53         Usage: required
54         Value type: <string>
55         Definition: specifies the name of this entry, for inbound entries this
56                     will be used to match against the remotely allocated entry
57                     and for outbound entries this name is used for allocating
58                     entries
59
60 - qcom,inbound:
61         Usage: optional
62         Value type: <empty>
63         Definition: marks the entry as inbound; the node should be specified
64                     as a two cell interrupt-controller as defined in 
65                     "../interrupt-controller/interrupts.txt"
66
67 - qcom,outbound:
68         Usage: optional
69         Value type: <empty>
70         Definition: marks the entry as outbound; the node should be specified
71                     as a two cell gpio-controller as defined in "gpio.txt"
72
73
74 = EXAMPLE
75 The following example shows the SMP2P setup with the wireless processor,
76 defined from the 8974 apps processor's point-of-view. It encompasses one
77 inbound and one outbound entry:
78
79 wcnss-smp2p {
80         compatible = "qcom,smp2p";
81         qcom,smem = <431>, <451>;
82
83         interrupts = <0 143 1>;
84
85         qcom,ipc = <&apcs 8 18>;
86
87         qcom,local-pid = <0>;
88         qcom,remote-pid = <4>;
89
90         wcnss_smp2p_out: master-kernel {
91                 qcom,entry-name = "master-kernel";
92                 qcom,outbound;
93
94                 gpio-controller;
95                 #gpio-cells = <2>;
96         };
97
98         wcnss_smp2p_in: slave-kernel {
99                 qcom,entry-name = "slave-kernel";
100                 qcom,inbound;
101
102                 interrupt-controller;
103                 #interrupt-cells = <2>;
104         };
105 };