28c3e535d266b40ea7ab9e4c24db6756003aeba3
[openwrt/openwrt.git] / target / linux / kirkwood / patches-4.9 / 108-on100.patch
1 --- /dev/null
2 +++ b/arch/arm/boot/dts/kirkwood-on100.dts
3 @@ -0,0 +1,160 @@
4 +/dts-v1/;
5 +
6 +#include "kirkwood.dtsi"
7 +#include "kirkwood-6282.dtsi"
8 +
9 +/ {
10 + model = "Cisco Systems ON100";
11 + compatible = "cisco,on100", "marvell,kirkwood-88f6282", "marvell,kirkwood";
12 +
13 + memory {
14 + device_type = "memory";
15 + reg = <0x00000000 0x20000000>;
16 + };
17 +
18 + aliases {
19 + serial0 = &uart0;
20 + };
21 +
22 + chosen {
23 + bootargs = "console=ttyS0,115200n8 earlyprintk";
24 + stdout-path = "serial0:115200n8";
25 + };
26 +
27 + gpio_keys {
28 + compatible = "gpio-keys";
29 + #address-cells = <1>;
30 + #size-cells = <0>;
31 + pinctrl-0 = <&pmx_btn_reset>;
32 + pinctrl-names = "default";
33 +
34 + button@1 {
35 + label = "Reset Button";
36 + linux,code = <KEY_RESTART>;
37 + gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
38 + };
39 + };
40 +
41 + gpio-leds {
42 + compatible = "gpio-leds";
43 + pinctrl-0 = < &pmx_led_health_r &pmx_led_health_g >;
44 + pinctrl-names = "default";
45 +
46 + health-g {
47 + label = "on100:green:health";
48 + gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
49 + };
50 +
51 + health-r {
52 + label = "on100:red:health";
53 + gpios = <&gpio1 13 GPIO_ACTIVE_LOW>;
54 + };
55 +
56 + health2-g {
57 + label = "on100:green:health2";
58 + gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
59 + };
60 +
61 + health2-r {
62 + label = "on100:red:health2";
63 + gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
64 + };
65 + };
66 +};
67 +
68 +&eth0 {
69 + status = "okay";
70 +
71 + ethernet0-port@0 {
72 + phy-handle = <&ethphy0>;
73 + phy-connection-type = "rgmii-id";
74 + };
75 +};
76 +
77 +&eth1 {
78 + status = "okay";
79 +
80 + ethernet1-port@0 {
81 + phy-handle = <&ethphy1>;
82 + phy-connection-type = "rgmii-id";
83 + };
84 +};
85 +
86 +&mdio {
87 + status = "okay";
88 +
89 + ethphy0: ethernet-phy@0 {
90 + /* Marvell 88E1121R */
91 + compatible = "ethernet-phy-id0141.0cb0",
92 + "ethernet-phy-ieee802.3-c22";
93 + reg = <0>;
94 + };
95 +
96 + ethphy1: ethernet-phy@1 {
97 + /* Marvell 88E1121R */
98 + compatible = "ethernet-phy-id0141.0cb0",
99 + "ethernet-phy-ieee802.3-c22";
100 + reg = <1>;
101 + };
102 +};
103 +
104 +&nand {
105 + status = "okay";
106 +
107 + partition@0 {
108 + label = "u-boot";
109 + reg = <0x00000000 0x000a0000>;
110 + read-only;
111 + };
112 +
113 + partition@a0000 {
114 + label = "u-boot environment";
115 + reg = <0x000a0000 0x00020000>;
116 + read-only;
117 + };
118 +
119 + partition@c0000 {
120 + label = "kernel";
121 + reg = <0x000c0000 0x00540000>;
122 + };
123 +
124 + partition@600000 {
125 + label = "ubi";
126 + reg = <0x00600000 0x1fa00000>;
127 + };
128 +};
129 +
130 +&pinctrl {
131 + pmx_led_health_r: pmx-led-health-r {
132 + marvell,pins = "mpp45";
133 + marvell,function = "gpio";
134 + };
135 +
136 + pmx_led_health_g: pmx-led-health-g {
137 + marvell,pins = "mpp44";
138 + marvell,function = "gpio";
139 + };
140 +
141 + pmx_led_health2_r: pmx-led-health2-r {
142 + marvell,pins = "mpp47";
143 + marvell,function = "gpio";
144 + };
145 +
146 + pmx_led_health2_g: pmx-led-health2-g {
147 + marvell,pins = "mpp46";
148 + marvell,function = "gpio";
149 + };
150 +
151 + pmx_btn_reset: pmx-led-reset {
152 + marvell,pins = "mpp31";
153 + marvell,function = "gpio";
154 + };
155 +};
156 +
157 +&sdio {
158 + status = "okay";
159 +};
160 +
161 +&uart0 {
162 + status = "okay";
163 +};
164 --- a/arch/arm/boot/dts/Makefile
165 +++ b/arch/arm/boot/dts/Makefile
166 @@ -242,6 +242,7 @@ dtb-$(CONFIG_MACH_KIRKWOOD) += \
167 kirkwood-nsa310s.dtb \
168 kirkwood-nsa320.dtb \
169 kirkwood-nsa325.dtb \
170 + kirkwood-on100.dtb \
171 kirkwood-openblocks_a6.dtb \
172 kirkwood-openblocks_a7.dtb \
173 kirkwood-openrd-base.dtb \