Merge branches 'fixes', 'misc' and 'spectre' into for-next
[sfrench/cifs-2.6.git] / Documentation / devicetree / bindings / interrupt-controller / qcom,pdc.txt
1 PDC interrupt controller
2
3 Qualcomm Technologies Inc. SoCs based on the RPM Hardened architecture have a
4 Power Domain Controller (PDC) that is on always-on domain. In addition to
5 providing power control for the power domains, the hardware also has an
6 interrupt controller that can be used to help detect edge low interrupts as
7 well detect interrupts when the GIC is non-operational.
8
9 GIC is parent interrupt controller at the highest level. Platform interrupt
10 controller PDC is next in hierarchy, followed by others. Drivers requiring
11 wakeup capabilities of their device interrupts routed through the PDC, must
12 specify PDC as their interrupt controller and request the PDC port associated
13 with the GIC interrupt. See example below.
14
15 Properties:
16
17 - compatible:
18         Usage: required
19         Value type: <string>
20         Definition: Should contain "qcom,<soc>-pdc"
21                     - "qcom,sdm845-pdc": For SDM845
22
23 - reg:
24         Usage: required
25         Value type: <prop-encoded-array>
26         Definition: Specifies the base physical address for PDC hardware.
27
28 - interrupt-cells:
29         Usage: required
30         Value type: <u32>
31         Definition: Specifies the number of cells needed to encode an interrupt
32                     source.
33                     Must be 2.
34                     The first element of the tuple is the PDC pin for the
35                     interrupt.
36                     The second element is the trigger type.
37
38 - interrupt-controller:
39         Usage: required
40         Value type: <bool>
41         Definition: Identifies the node as an interrupt controller.
42
43 - qcom,pdc-ranges:
44         Usage: required
45         Value type: <u32 array>
46         Definition: Specifies the PDC pin offset and the number of PDC ports.
47                     The tuples indicates the valid mapping of valid PDC ports
48                     and their hwirq mapping.
49                     The first element of the tuple is the starting PDC port.
50                     The second element is the GIC hwirq number for the PDC port.
51                     The third element is the number of interrupts in sequence.
52
53 Example:
54
55         pdc: interrupt-controller@b220000 {
56                 compatible = "qcom,sdm845-pdc";
57                 reg = <0xb220000 0x30000>;
58                 qcom,pdc-ranges = <0 512 94>, <94 641 15>, <115 662 7>;
59                 #interrupt-cells = <2>;
60                 interrupt-parent = <&intc>;
61                 interrupt-controller;
62         };
63
64 DT binding of a device that wants to use the GIC SPI 514 as a wakeup
65 interrupt, must do -
66
67         wake-device {
68                 interrupts-extended = <&pdc 2 IRQ_TYPE_LEVEL_HIGH>;
69         };
70
71 In this case interrupt 514 would be mapped to port 2 on the PDC as defined by
72 the qcom,pdc-ranges property.