diff options
author | Srinivas Kandagatla <srinivas.kandagatla@st.com> | 2014-03-11 05:32:49 -0400 |
---|---|---|
committer | Srinivas Kandagatla <srinivas.kandagatla@st.com> | 2014-03-11 06:03:10 -0400 |
commit | fc58fcf6da7377eeac217b3b187bb004c9564467 (patch) | |
tree | db3924e30f3b1e38c29b76c557f9e892a379d5c0 | |
parent | 6b7f06cc805bb4755e69cd916b3f565947e0a77a (diff) |
ARM: STi: STiH415: Add soft reset controller support.
This patch adds soft reset controller support for STiH415 and adds new
softreset lines required for other device tree nodes in the header file.
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@st.com>
-rw-r--r-- | Documentation/devicetree/bindings/reset/st,sti-softreset.txt | 46 | ||||
-rw-r--r-- | arch/arm/boot/dts/stih415.dtsi | 5 | ||||
-rw-r--r-- | include/dt-bindings/reset-controller/stih415-resets.h | 7 |
3 files changed, 58 insertions, 0 deletions
diff --git a/Documentation/devicetree/bindings/reset/st,sti-softreset.txt b/Documentation/devicetree/bindings/reset/st,sti-softreset.txt new file mode 100644 index 000000000000..a8d3d3c25ca2 --- /dev/null +++ b/Documentation/devicetree/bindings/reset/st,sti-softreset.txt | |||
@@ -0,0 +1,46 @@ | |||
1 | STMicroelectronics STi family Sysconfig Peripheral SoftReset Controller | ||
2 | ============================================================================= | ||
3 | |||
4 | This binding describes a reset controller device that is used to enable and | ||
5 | disable on-chip peripheral controllers such as USB and SATA, using | ||
6 | "softreset" control bits found in the STi family SoC system configuration | ||
7 | registers. | ||
8 | |||
9 | The actual action taken when softreset is asserted is hardware dependent. | ||
10 | However, when asserted it may not be possible to access the hardware's | ||
11 | registers and after an assert/deassert sequence the hardware's previous state | ||
12 | may no longer be valid. | ||
13 | |||
14 | Please refer to reset.txt in this directory for common reset | ||
15 | controller binding usage. | ||
16 | |||
17 | Required properties: | ||
18 | - compatible: Should be "st,<chip>-softreset" example: | ||
19 | "st,stih415-softreset" or "st,stih416-softreset"; | ||
20 | - #reset-cells: 1, see below | ||
21 | |||
22 | example: | ||
23 | |||
24 | softreset: softreset-controller { | ||
25 | #reset-cells = <1>; | ||
26 | compatible = "st,stih415-softreset"; | ||
27 | }; | ||
28 | |||
29 | |||
30 | Specifying softreset control of devices | ||
31 | ======================================= | ||
32 | |||
33 | Device nodes should specify the reset channel required in their "resets" | ||
34 | property, containing a phandle to the softreset device node and an | ||
35 | index specifying which channel to use, as described in reset.txt | ||
36 | |||
37 | example: | ||
38 | |||
39 | ethernet0{ | ||
40 | resets = <&softreset STIH415_ETH0_SOFTRESET>; | ||
41 | }; | ||
42 | |||
43 | Macro definitions for the supported reset channels can be found in: | ||
44 | |||
45 | include/dt-bindings/reset-controller/stih415-resets.h | ||
46 | include/dt-bindings/reset-controller/stih416-resets.h | ||
diff --git a/arch/arm/boot/dts/stih415.dtsi b/arch/arm/boot/dts/stih415.dtsi index 19e29f4af9d6..d52207c1168e 100644 --- a/arch/arm/boot/dts/stih415.dtsi +++ b/arch/arm/boot/dts/stih415.dtsi | |||
@@ -34,6 +34,11 @@ | |||
34 | compatible = "st,stih415-powerdown"; | 34 | compatible = "st,stih415-powerdown"; |
35 | }; | 35 | }; |
36 | 36 | ||
37 | softreset: softreset-controller { | ||
38 | #reset-cells = <1>; | ||
39 | compatible = "st,stih415-softreset"; | ||
40 | }; | ||
41 | |||
37 | syscfg_sbc: sbc-syscfg@fe600000{ | 42 | syscfg_sbc: sbc-syscfg@fe600000{ |
38 | compatible = "st,stih415-sbc-syscfg", "syscon"; | 43 | compatible = "st,stih415-sbc-syscfg", "syscon"; |
39 | reg = <0xfe600000 0xb4>; | 44 | reg = <0xfe600000 0xb4>; |
diff --git a/include/dt-bindings/reset-controller/stih415-resets.h b/include/dt-bindings/reset-controller/stih415-resets.h index 2d54e68c2d95..c2f8a66913c5 100644 --- a/include/dt-bindings/reset-controller/stih415-resets.h +++ b/include/dt-bindings/reset-controller/stih415-resets.h | |||
@@ -16,4 +16,11 @@ | |||
16 | #define STIH415_SATA1_POWERDOWN 7 | 16 | #define STIH415_SATA1_POWERDOWN 7 |
17 | #define STIH415_PCIE_POWERDOWN 8 | 17 | #define STIH415_PCIE_POWERDOWN 8 |
18 | 18 | ||
19 | #define STIH415_ETH0_SOFTRESET 0 | ||
20 | #define STIH415_ETH1_SOFTRESET 1 | ||
21 | #define STIH415_IRB_SOFTRESET 2 | ||
22 | #define STIH415_USB0_SOFTRESET 3 | ||
23 | #define STIH415_USB1_SOFTRESET 4 | ||
24 | #define STIH415_USB2_SOFTRESET 5 | ||
25 | |||
19 | #endif /* _DT_BINDINGS_RESET_CONTROLLER_STIH415 */ | 26 | #endif /* _DT_BINDINGS_RESET_CONTROLLER_STIH415 */ |