ramips: mt7620: tidy up ethernet node in DTS files
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7620a_yukai_bocco.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 = "yukai,bocco", "ralink,mt7620a-soc";
10 model = "YUKAI Engineering BOCCO";
11
12 keys {
13 compatible = "gpio-keys";
14
15 reset {
16 label = "reset";
17 gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
18 linux,code = <KEY_RESTART>;
19 };
20 };
21
22 gpio_export {
23 compatible = "gpio-export";
24 #size-cells = <0>;
25
26 s1 {
27 gpio-export,name = "rec";
28 gpios = <&gpio1 8 GPIO_ACTIVE_HIGH>;
29 };
30 s2 {
31 gpio-export,name = "play";
32 gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
33 };
34 };
35
36 sound {
37 compatible = "simple-audio-card";
38 simple-audio-card,name = "Audio-I2S";
39 simple-audio-card,format = "i2s";
40 simple-audio-card,bitclock-master = <&dailink0_master>;
41 simple-audio-card,frame-master = <&dailink0_master>;
42 simple-audio-card,widgets =
43 "Headphone", "Headphones";
44 simple-audio-card,routing =
45 "Headphones", "HP_L",
46 "Headphones", "HP_R";
47 simple-audio-card,mclk-fs = <256>;
48
49 simple-audio-card,cpu {
50 sound-dai = <&i2s>;
51 };
52
53 dailink0_master: simple-audio-card,codec {
54 sound-dai = <&codec>;
55 };
56 };
57 };
58
59 &gpio0 {
60 status = "okay";
61 };
62
63 &gpio1 {
64 status = "okay";
65 };
66
67 &gpio2 {
68 status = "okay";
69 };
70
71 &gpio3 {
72 status = "okay";
73 };
74
75 &i2c {
76 status = "okay";
77
78 codec: wm8960@1a {
79 #sound-dai-cells = <0>;
80 compatible = "wlf,wm8960";
81 reg = <0x1a>;
82
83 wlf,shared-lrclk;
84 };
85 };
86
87 &i2s {
88 #sound-dai-cells = <0>;
89 status = "okay";
90 pinctrl-names = "default";
91 pinctrl-0 = <&pcm_i2s_pins>;
92 };
93
94 &spi0 {
95 status = "okay";
96
97 flash@0 {
98 compatible = "jedec,spi-nor";
99 reg = <0>;
100 spi-max-frequency = <10000000>;
101
102 partitions {
103 compatible = "fixed-partitions";
104 #address-cells = <1>;
105 #size-cells = <1>;
106
107 partition@0 {
108 label = "u-boot";
109 reg = <0x0 0x30000>;
110 read-only;
111 };
112
113 partition@30000 {
114 label = "u-boot-env";
115 reg = <0x30000 0x10000>;
116 read-only;
117 };
118
119 factory: partition@40000 {
120 label = "factory";
121 reg = <0x40000 0x10000>;
122 read-only;
123 };
124
125 partition@50000 {
126 compatible = "denx,uimage";
127 label = "firmware";
128 reg = <0x50000 0x7b0000>;
129 };
130 };
131 };
132 };
133
134 &pcm {
135 status = "okay";
136 };
137
138 &gdma {
139 status = "okay";
140 };
141
142 &state_default {
143 gpio {
144 groups = "spi refclk", "rgmii1";
145 function = "gpio";
146 };
147 };
148
149 &ethernet {
150 pinctrl-names = "default";
151 pinctrl-0 = <&ephy_pins>;
152
153 mtd-mac-address = <&factory 0x4>;
154
155 mediatek,portmap = "llllw";
156 };
157
158 &gsw {
159 ralink,port4 = "ephy";
160 };
161
162 &wmac {
163 ralink,mtd-eeprom = <&factory 0x0>;
164 };