apm821xx: unify My Book Live Single + Duo images
[openwrt/staging/rmilecki.git] / target / linux / apm821xx / dts / wd-mybooklive.dts
1 /*
2 * Copyright 2008 DENX Software Engineering, Stefan Roese <sr@denx.de>
3 * (c) Copyright 2010 Western Digital Technologies, Inc. All Rights Reserved.
4 *
5 * This file is licensed under the terms of the GNU General Public
6 * License version 2. This program is licensed "as is" without
7 * any warranty of any kind, whether express or implied.
8 */
9
10 /dts-v1/;
11
12 #include "apm82181.dtsi"
13
14 / {
15 compatible = "wd,mybooklive", "amcc,apollo3g";
16 model = "MyBook Live";
17
18 aliases {
19 serial0 = &UART0;
20 led-boot = &status;
21 led-failsafe = &status;
22 led-running = &status;
23 led-upgrade = &status;
24 };
25 };
26
27 &POB0 {
28 ebc {
29 nor_flash@0,0 {
30 status = "okay";
31 compatible = "amd,s29gl512n", "jedec-probe", "cfi-flash", "mtd-rom";
32 bank-width = <1>;
33 reg = <0x00000000 0x00000000 0x00080000>;
34 #address-cells = <1>;
35 #size-cells = <1>;
36
37 partition@0 {
38 /* Part of bootrom - Don't use it without a jump */
39 label = "free";
40 reg = <0x00000000 0x0001e000>;
41 };
42
43 partition@1 {
44 label = "env";
45 reg = <0x0001e000 0x00002000>;
46 };
47
48 partition@2 {
49 label = "uboot";
50 reg = <0x00020000 0x00050000>;
51 };
52 };
53 };
54
55 GPIO1: gpio1@e0000000 {
56 compatible = "wd,mbl-gpio", "ti,74273";
57 reg-names = "dat";
58 reg = <0xe0000000 0x1>;
59 #gpio-cells = <2>;
60 gpio-controller;
61
62 enable-phy {
63 /* toggle to reset EMAC PHY */
64 gpio-hog;
65 line-name = "enable EMAC PHY";
66 gpios = <0 GPIO_ACTIVE_LOW>;
67 output-low;
68 };
69
70 enable-button {
71 /* Defined in u-boot as: NOT_NOR
72 * "enables features other than NOR
73 * specifically, the buffer at CS2"
74 * (button).
75 *
76 * Note: This option is disabled as
77 * it prevents the system from being
78 * rebooted successfully.
79 */
80
81 gpio-hog;
82 line-name = "Enable Reset Button, disable NOR";
83 gpios = <1 GPIO_ACTIVE_HIGH>;
84 output-low;
85 };
86
87 enable-usb {
88 gpio-hog;
89 line-name = "Power USB Core";
90 gpios = <2 GPIO_ACTIVE_LOW>;
91 output-low;
92 };
93
94 enable-port1 {
95 gpio-hog;
96 line-name = "Power Drive Port 1";
97 gpios = <3 GPIO_ACTIVE_LOW>;
98 output-low;
99 };
100
101 enable-port0 {
102 gpio-hog;
103 line-name = "Power Drive Port 0";
104 gpios = <7 GPIO_ACTIVE_LOW>;
105 output-low;
106 };
107 };
108
109 GPIO2: gpio2@e0100000 {
110 compatible = "wd,mbl-gpio", "ti,74244";
111 reg-names = "dat";
112 reg = <0xe0100000 0x1>;
113 #gpio-cells = <2>;
114 gpio-controller;
115 no-output;
116 };
117
118 gpio-leds {
119 compatible = "gpio-leds";
120
121 failsafe: power-red {
122 label = "mbl:red:power";
123 gpios = <&GPIO1 4 GPIO_ACTIVE_HIGH>;
124 linux,default-trigger = "panic";
125 };
126
127 status: power-green {
128 label = "mbl:green:power";
129 gpios = <&GPIO1 5 GPIO_ACTIVE_HIGH>;
130 };
131
132 power-blue {
133 label = "mbl:blue:power";
134 gpios = <&GPIO1 6 GPIO_ACTIVE_HIGH>;
135 };
136 };
137
138 gpio_keys_polled {
139 compatible = "gpio-keys-polled";
140 #address-cells = <1>;
141 #size-cells = <0>;
142 poll-interval = <60>; /* 3 * 20 = 60ms */
143 autorepeat;
144
145 reset-button {
146 label = "Reset button";
147 linux,code = <KEY_RESTART>;
148 gpios = <&GPIO2 2 GPIO_ACTIVE_LOW>;
149 };
150 };
151 };
152
153 &EMAC0 {
154 status = "okay";
155
156 phy-map = <0x2>;
157 phy-address = <0x1>;
158 phy-handle = <&phy>;
159
160 mdio {
161 #address-cells = <1>;
162 #size-cells = <0>;
163
164 phy: phy@1 {
165 compatible = "ethernet-phy-ieee802.3-c22";
166 reg = <1>;
167 };
168 };
169 };
170
171 &CRYPTO {
172 status = "okay";
173 };
174
175 &PKA {
176 status = "okay";
177 };
178
179 &TRNG {
180 status = "okay";
181 };
182
183 &SATA0 {
184 status = "okay";
185 };
186
187 &SATA1 {
188 status = "okay";
189 };
190
191 &UART0 {
192 status = "okay";
193 };
194
195 &USBOTG0 {
196 status = "okay";
197 dr_mode = "host";
198 };