diff options
author | Arnd Bergmann <arnd@arndb.de> | 2012-11-05 12:43:11 -0500 |
---|---|---|
committer | Arnd Bergmann <arnd@arndb.de> | 2012-11-05 12:43:11 -0500 |
commit | dbe30538771b7c9811e397c7ce50db546209b4f6 (patch) | |
tree | a820c2b4faddc6109e449a21b551b4a18339c287 /Documentation | |
parent | 8f0d8163b50e01f398b14bcd4dc039ac5ab18d64 (diff) | |
parent | 433683a66401adb0150792e725cc4f631c94de46 (diff) |
Merge branch 'vexpress-clk-soc' of git://git.linaro.org/people/pawelmoll/linux into next/soc2
From Pawel Moll <pawel.moll@arm.com>:
This reworks the generic support for versatile express, in part
as preparation for the arm64 version of it that can now share
more of the code.
The series is based on top of the clk tree from Mike Turquette.
* 'vexpress-clk-soc' of git://git.linaro.org/people/pawelmoll/linux:
ARM: vexpress: Remove motherboard dependencies in the DTS files
ARM: vexpress: Start using new Versatile Express infrastructure
ARM: vexpress: Add config bus components and clocks to DTs
mfd: Versatile Express system registers driver
mfd: Versatile Express config infrastructure
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/devicetree/bindings/arm/vexpress-sysreg.txt | 50 | ||||
-rw-r--r-- | Documentation/devicetree/bindings/arm/vexpress.txt | 98 |
2 files changed, 138 insertions, 10 deletions
diff --git a/Documentation/devicetree/bindings/arm/vexpress-sysreg.txt b/Documentation/devicetree/bindings/arm/vexpress-sysreg.txt new file mode 100644 index 000000000000..9cf3f25544c7 --- /dev/null +++ b/Documentation/devicetree/bindings/arm/vexpress-sysreg.txt | |||
@@ -0,0 +1,50 @@ | |||
1 | ARM Versatile Express system registers | ||
2 | -------------------------------------- | ||
3 | |||
4 | This is a system control registers block, providing multiple low level | ||
5 | platform functions like board detection and identification, software | ||
6 | interrupt generation, MMC and NOR Flash control etc. | ||
7 | |||
8 | Required node properties: | ||
9 | - compatible value : = "arm,vexpress,sysreg"; | ||
10 | - reg : physical base address and the size of the registers window | ||
11 | - gpio-controller : specifies that the node is a GPIO controller | ||
12 | - #gpio-cells : size of the GPIO specifier, should be 2: | ||
13 | - first cell is the pseudo-GPIO line number: | ||
14 | 0 - MMC CARDIN | ||
15 | 1 - MMC WPROT | ||
16 | 2 - NOR FLASH WPn | ||
17 | - second cell can take standard GPIO flags (currently ignored). | ||
18 | |||
19 | Example: | ||
20 | v2m_sysreg: sysreg@10000000 { | ||
21 | compatible = "arm,vexpress-sysreg"; | ||
22 | reg = <0x10000000 0x1000>; | ||
23 | gpio-controller; | ||
24 | #gpio-cells = <2>; | ||
25 | }; | ||
26 | |||
27 | This block also can also act a bridge to the platform's configuration | ||
28 | bus via "system control" interface, addressing devices with site number, | ||
29 | position in the board stack, config controller, function and device | ||
30 | numbers - see motherboard's TRM for more details. | ||
31 | |||
32 | The node describing a config device must refer to the sysreg node via | ||
33 | "arm,vexpress,config-bridge" phandle (can be also defined in the node's | ||
34 | parent) and relies on the board topology properties - see main vexpress | ||
35 | node documentation for more details. It must must also define the | ||
36 | following property: | ||
37 | - arm,vexpress-sysreg,func : must contain two cells: | ||
38 | - first cell defines function number (eg. 1 for clock generator, | ||
39 | 2 for voltage regulators etc.) | ||
40 | - device number (eg. osc 0, osc 1 etc.) | ||
41 | |||
42 | Example: | ||
43 | mcc { | ||
44 | arm,vexpress,config-bridge = <&v2m_sysreg>; | ||
45 | |||
46 | osc@0 { | ||
47 | compatible = "arm,vexpress-osc"; | ||
48 | arm,vexpress-sysreg,func = <1 0>; | ||
49 | }; | ||
50 | }; | ||
diff --git a/Documentation/devicetree/bindings/arm/vexpress.txt b/Documentation/devicetree/bindings/arm/vexpress.txt index ec8b50cbb2e8..ae49161e478a 100644 --- a/Documentation/devicetree/bindings/arm/vexpress.txt +++ b/Documentation/devicetree/bindings/arm/vexpress.txt | |||
@@ -11,6 +11,10 @@ the motherboard file using a /include/ directive. As the motherboard | |||
11 | can be initialized in one of two different configurations ("memory | 11 | can be initialized in one of two different configurations ("memory |
12 | maps"), care must be taken to include the correct one. | 12 | maps"), care must be taken to include the correct one. |
13 | 13 | ||
14 | |||
15 | Root node | ||
16 | --------- | ||
17 | |||
14 | Required properties in the root node: | 18 | Required properties in the root node: |
15 | - compatible value: | 19 | - compatible value: |
16 | compatible = "arm,vexpress,<model>", "arm,vexpress"; | 20 | compatible = "arm,vexpress,<model>", "arm,vexpress"; |
@@ -45,6 +49,10 @@ Optional properties in the root node: | |||
45 | - Coretile Express A9x4 (V2P-CA9) HBI-0225: | 49 | - Coretile Express A9x4 (V2P-CA9) HBI-0225: |
46 | arm,hbi = <0x225>; | 50 | arm,hbi = <0x225>; |
47 | 51 | ||
52 | |||
53 | CPU nodes | ||
54 | --------- | ||
55 | |||
48 | Top-level standard "cpus" node is required. It must contain a node | 56 | Top-level standard "cpus" node is required. It must contain a node |
49 | with device_type = "cpu" property for every available core, eg.: | 57 | with device_type = "cpu" property for every available core, eg.: |
50 | 58 | ||
@@ -59,6 +67,52 @@ with device_type = "cpu" property for every available core, eg.: | |||
59 | }; | 67 | }; |
60 | }; | 68 | }; |
61 | 69 | ||
70 | |||
71 | Configuration infrastructure | ||
72 | ---------------------------- | ||
73 | |||
74 | The platform has an elaborated configuration system, consisting of | ||
75 | microcontrollers residing on the mother- and daughterboards known | ||
76 | as Motherboard/Daughterboard Configuration Controller (MCC and DCC). | ||
77 | The controllers are responsible for the platform initialization | ||
78 | (reset generation, flash programming, FPGA bitfiles loading etc.) | ||
79 | but also control clock generators, voltage regulators, gather | ||
80 | environmental data like temperature, power consumption etc. Even | ||
81 | the video output switch (FPGA) is controlled that way. | ||
82 | |||
83 | Nodes describing devices controlled by this infrastructure should | ||
84 | point at the bridge device node: | ||
85 | - bridge phandle: | ||
86 | arm,vexpress,config-bridge = <phandle>; | ||
87 | This property can be also defined in a parent node (eg. for a DCC) | ||
88 | and is effective for all children. | ||
89 | |||
90 | |||
91 | Platform topology | ||
92 | ----------------- | ||
93 | |||
94 | As Versatile Express can be configured in number of physically | ||
95 | different setups, the device tree should describe platform topology. | ||
96 | Root node and main motherboard node must define the following | ||
97 | property, describing physical location of the children nodes: | ||
98 | - site number: | ||
99 | arm,vexpress,site = <number>; | ||
100 | where 0 means motherboard, 1 or 2 are daugtherboard sites, | ||
101 | 0xf means "master" site (site containing main CPU tile) | ||
102 | - when daughterboards are stacked on one site, their position | ||
103 | in the stack be be described with: | ||
104 | arm,vexpress,position = <number>; | ||
105 | - when describing tiles consisting more than one DCC, its number | ||
106 | can be described with: | ||
107 | arm,vexpress,dcc = <number>; | ||
108 | |||
109 | Any of the numbers above defaults to zero if not defined in | ||
110 | the node or any of its parent. | ||
111 | |||
112 | |||
113 | Motherboard | ||
114 | ----------- | ||
115 | |||
62 | The motherboard description file provides a single "motherboard" node | 116 | The motherboard description file provides a single "motherboard" node |
63 | using 2 address cells corresponding to the Static Memory Bus used | 117 | using 2 address cells corresponding to the Static Memory Bus used |
64 | between the motherboard and the tile. The first cell defines the Chip | 118 | between the motherboard and the tile. The first cell defines the Chip |
@@ -87,22 +141,30 @@ can be used to obtain required phandle in the tile's "aliases" node: | |||
87 | - SP804 timers: | 141 | - SP804 timers: |
88 | v2m_timer01 and v2m_timer23 | 142 | v2m_timer01 and v2m_timer23 |
89 | 143 | ||
90 | Current Linux implementation requires a "arm,v2m_timer" alias | 144 | The tile description should define a "smb" node, describing the |
91 | pointing at one of the motherboard's SP804 timers, if it is to be | 145 | Static Memory Bus between the tile and motherboard. It must define |
92 | used as the system timer. This alias should be defined in the | 146 | the following properties: |
93 | motherboard files. | 147 | - "simple-bus" compatible value (to ensure creation of the children) |
148 | compatible = "simple-bus"; | ||
149 | - mapping of the SMB CS/offset addresses into main address space: | ||
150 | #address-cells = <2>; | ||
151 | #size-cells = <1>; | ||
152 | ranges = <...>; | ||
153 | - interrupts mapping: | ||
154 | #interrupt-cells = <1>; | ||
155 | interrupt-map-mask = <0 0 63>; | ||
156 | interrupt-map = <...>; | ||
94 | 157 | ||
95 | The tile description must define "ranges", "interrupt-map-mask" and | ||
96 | "interrupt-map" properties to translate the motherboard's address | ||
97 | and interrupt space into one used by the tile's processor. | ||
98 | 158 | ||
99 | Abbreviated example: | 159 | Example of a VE tile description (simplified) |
160 | --------------------------------------------- | ||
100 | 161 | ||
101 | /dts-v1/; | 162 | /dts-v1/; |
102 | 163 | ||
103 | / { | 164 | / { |
104 | model = "V2P-CA5s"; | 165 | model = "V2P-CA5s"; |
105 | arm,hbi = <0x225>; | 166 | arm,hbi = <0x225>; |
167 | arm,vexpress,site = <0xf>; | ||
106 | compatible = "arm,vexpress-v2p-ca5s", "arm,vexpress"; | 168 | compatible = "arm,vexpress-v2p-ca5s", "arm,vexpress"; |
107 | interrupt-parent = <&gic>; | 169 | interrupt-parent = <&gic>; |
108 | #address-cells = <1>; | 170 | #address-cells = <1>; |
@@ -134,13 +196,29 @@ Abbreviated example: | |||
134 | <0x2c000100 0x100>; | 196 | <0x2c000100 0x100>; |
135 | }; | 197 | }; |
136 | 198 | ||
137 | motherboard { | 199 | dcc { |
200 | compatible = "simple-bus"; | ||
201 | arm,vexpress,config-bridge = <&v2m_sysreg>; | ||
202 | |||
203 | osc@0 { | ||
204 | compatible = "arm,vexpress-osc"; | ||
205 | }; | ||
206 | }; | ||
207 | |||
208 | smb { | ||
209 | compatible = "simple-bus"; | ||
210 | |||
211 | #address-cells = <2>; | ||
212 | #size-cells = <1>; | ||
138 | /* CS0 is visible at 0x08000000 */ | 213 | /* CS0 is visible at 0x08000000 */ |
139 | ranges = <0 0 0x08000000 0x04000000>; | 214 | ranges = <0 0 0x08000000 0x04000000>; |
215 | |||
216 | #interrupt-cells = <1>; | ||
140 | interrupt-map-mask = <0 0 63>; | 217 | interrupt-map-mask = <0 0 63>; |
141 | /* Active high IRQ 0 is connected to GIC's SPI0 */ | 218 | /* Active high IRQ 0 is connected to GIC's SPI0 */ |
142 | interrupt-map = <0 0 0 &gic 0 0 4>; | 219 | interrupt-map = <0 0 0 &gic 0 0 4>; |
220 | |||
221 | /include/ "vexpress-v2m-rs1.dtsi" | ||
143 | }; | 222 | }; |
144 | }; | 223 | }; |
145 | 224 | ||
146 | /include/ "vexpress-v2m-rs1.dtsi" | ||