| 1 |
// SPDX-License-Identifier: GPL-2.0 |
| 2 |
|
| 3 |
/ { |
| 4 |
testcase-data { |
| 5 |
interrupts { |
| 6 |
#address-cells = <1>; |
| 7 |
#size-cells = <1>; |
| 8 |
|
| 9 |
test_intc0: intc0 { |
| 10 |
interrupt-controller; |
| 11 |
#interrupt-cells = <1>; |
| 12 |
}; |
| 13 |
|
| 14 |
test_intc1: intc1 { |
| 15 |
interrupt-controller; |
| 16 |
#interrupt-cells = <3>; |
| 17 |
}; |
| 18 |
|
| 19 |
test_intc2: intc2 { |
| 20 |
interrupt-controller; |
| 21 |
#interrupt-cells = <2>; |
| 22 |
}; |
| 23 |
|
| 24 |
test_intmap0: intmap0 { |
| 25 |
#interrupt-cells = <1>; |
| 26 |
#address-cells = <0>; |
| 27 |
interrupt-map = <1 &test_intc0 9>, |
| 28 |
<2 &test_intc1 10 11 12>, |
| 29 |
<3 &test_intc2 13 14>, |
| 30 |
<4 &test_intc2 15 16>; |
| 31 |
}; |
| 32 |
|
| 33 |
test_intmap1: intmap1 { |
| 34 |
#interrupt-cells = <2>; |
| 35 |
/* |
| 36 |
* #address-cells is required |
| 37 |
* |
| 38 |
* The property is not provided in this node to |
| 39 |
* test that the code will properly handle |
| 40 |
* this case for legacy .dts files. |
| 41 |
* |
| 42 |
* Not having #address-cells will result in a |
| 43 |
* warning from dtc starting with |
| 44 |
* version v1.6.1-19-g0a3a9d3449c8 |
| 45 |
* The warning is suppressed by adding |
| 46 |
* -Wno-interrupt_map to the Makefile for all |
| 47 |
* .dts files this include this .dtsi |
| 48 |
#address-cells = <1>; |
| 49 |
*/ |
| 50 |
interrupt-map = <0x5000 1 2 &test_intc0 15>; |
| 51 |
}; |
| 52 |
|
| 53 |
intmap2 { |
| 54 |
#interrupt-cells = <2>; |
| 55 |
#address-cells = <0>; |
| 56 |
interrupt-map = <1 11 &test_intc0 100>, |
| 57 |
<2 22 &test_intc1 200 201 202>, |
| 58 |
<3 33 &test_intc2 300 301>, |
| 59 |
<4 44 &test_intc2 400 401>; |
| 60 |
}; |
| 61 |
|
| 62 |
test_intc_intmap0: intc-intmap0 { |
| 63 |
#interrupt-cells = <1>; |
| 64 |
#address-cells = <1>; |
| 65 |
interrupt-controller; |
| 66 |
interrupt-map = <0x6000 1 &test_intc_intmap0 0x7000 2>; |
| 67 |
}; |
| 68 |
|
| 69 |
interrupts0 { |
| 70 |
interrupt-parent = <&test_intc0>; |
| 71 |
interrupts = <1>, <2>, <3>, <4>; |
| 72 |
}; |
| 73 |
|
| 74 |
interrupts1 { |
| 75 |
interrupt-parent = <&test_intmap0>; |
| 76 |
interrupts = <1>, <2>, <3>, <4>; |
| 77 |
}; |
| 78 |
|
| 79 |
interrupts2 { |
| 80 |
reg = <0x6000 0x100>; |
| 81 |
interrupt-parent = <&test_intc_intmap0>; |
| 82 |
interrupts = <1>; |
| 83 |
}; |
| 84 |
|
| 85 |
interrupts-extended0 { |
| 86 |
reg = <0x5000 0x100>; |
| 87 |
/* |
| 88 |
* Do not remove &test_intmap1 from this |
| 89 |
* property - see comment in node intmap1 |
| 90 |
*/ |
| 91 |
interrupts-extended = <&test_intc0 1>, |
| 92 |
<&test_intc1 2 3 4>, |
| 93 |
<&test_intc2 5 6>, |
| 94 |
<&test_intmap0 1>, |
| 95 |
<&test_intmap0 2>, |
| 96 |
<&test_intmap0 3>, |
| 97 |
<&test_intmap1 1 2>; |
| 98 |
}; |
| 99 |
}; |
| 100 |
|
| 101 |
testcase-device1 { |
| 102 |
compatible = "testcase-device"; |
| 103 |
interrupt-parent = <&test_intc0>; |
| 104 |
interrupts = <1>; |
| 105 |
}; |
| 106 |
|
| 107 |
/* |
| 108 |
* testcase data that intentionally results in an error is |
| 109 |
* located in testcases.dts instead of in this file so that the |
| 110 |
* static overlay apply tests will not include the error. |
| 111 |
*/ |
| 112 |
}; |
| 113 |
}; |