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