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