ramips: fix dtc warnings
[openwrt/openwrt.git] / target / linux / ramips / dts / K2G.dts
1 /dts-v1/;
2
3 #include "mt7620a.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "phicomm,k2g", "ralink,mt7620a-soc";
10 model = "Phicomm K2G";
11
12 aliases {
13 led-status = &led_blue;
14 serial0 = &uartlite;
15 };
16
17 gpio-leds {
18 compatible = "gpio-leds";
19
20 led_blue: blue {
21 label = "k2g:blue:status";
22 gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
23 };
24
25 yellow {
26 label = "k2g:yellow:status";
27 gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
28 };
29
30 red {
31 label = "k2g:red:status";
32 gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
33 };
34 };
35
36 gpio-keys-polled {
37 compatible = "gpio-keys-polled";
38 poll-interval = <20>;
39
40 reset {
41 label = "reset";
42 gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
43 linux,code = <KEY_RESTART>;
44 };
45 };
46 };
47
48 &spi0 {
49 status = "okay";
50
51 m25p80@0 {
52 compatible = "jedec,spi-nor";
53 reg = <0>;
54 spi-max-frequency = <24000000>;
55
56 partitions {
57 compatible = "fixed-partitions";
58 #address-cells = <1>;
59 #size-cells = <1>;
60
61 u-boot@0 {
62 reg = <0x0 0x30000>;
63 read-only;
64 };
65
66 u-boot-env@30000 {
67 reg = <0x30000 0x10000>;
68 read-only;
69 };
70
71 factory: factory@40000 {
72 reg = <0x40000 0x10000>;
73 read-only;
74 };
75
76 permanent_config@50000 {
77 reg = <0x50000 0x50000>;
78 read-only;
79 };
80
81 firmware@a0000 {
82 reg = <0xa0000 0x760000>;
83 };
84 };
85 };
86 };
87
88 &pinctrl {
89 state_default: pinctrl0 {
90 gpio {
91 ralink,group = "i2c", "uartf";
92 ralink,function = "gpio";
93 };
94 };
95 };
96
97 &ethernet {
98 pinctrl-names = "default";
99 pinctrl-0 = <&rgmii2_pins &mdio_pins>;
100 mtd-mac-address = <&factory 0x28>;
101 mediatek,portmap = "llllw";
102
103 port@5 {
104 status = "okay";
105 phy-handle = <&phy5>;
106 phy-mode = "rgmii";
107 };
108
109 mdio-bus {
110 status = "okay";
111
112 phy5: ethernet-phy@5 {
113 reg = <5>;
114 phy-mode = "rgmii";
115 };
116 };
117 };
118
119 &pcie {
120 status = "okay";
121 };
122
123 &pcie0 {
124 mt76@0,0 {
125 reg = <0x0000 0 0 0 0>;
126 mediatek,mtd-eeprom = <&factory 0x8000>;
127 ieee80211-freq-limit = <5000000 6000000>;
128 };
129 };
130
131 &wmac {
132 ralink,mtd-eeprom = <&factory 0>;
133 pinctrl-names = "default";
134 pinctrl-0 = <&pa_pins>;
135 };