Fresh pull from upstream
[librecmc/librecmc.git] / target / linux / ramips / dts / DUZUN-DM06.dts
1 /dts-v1/;
2
3 #include "mt7628an.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8         compatible = "duzun,dm06-mt7628an", "mediatek,mt7628an-soc";
9         model = "DuZun DM06";
10
11         memory@0 {
12                 device_type = "memory";
13                 reg = <0x0 0x4000000>;
14         };
15
16         gpio-keys-polled {
17                 compatible = "gpio-keys-polled";
18                 #address-cells = <1>;
19                 #size-cells = <0>;
20                 poll-interval = <100>;
21
22                 reset {
23                         label = "reset";
24                         gpios = <&gpio1 14 1>;
25                         linux,code = <KEY_RESTART>;
26                 };
27
28                 wps {
29                         label = "wps";
30                         gpios = <&gpio1 6 1>;
31                         linux,code = <KEY_WPS_BUTTON>;
32                 };
33         };
34
35         sound {
36                 compatible = "simple-audio-card";
37                 simple-audio-card,name = "Audio-I2S";
38                 simple-audio-card,format = "i2s";
39                 simple-audio-card,bitclock-master = <&dailink0_master>;
40                 simple-audio-card,frame-master = <&dailink0_master>;
41                 simple-audio-card,widgets =
42                         "Headphone", "Headphones";
43                 simple-audio-card,routing =
44                         "Headphones", "HP_L",
45                         "Headphones", "HP_R";
46                 simple-audio-card,mclk-fs = <256>;
47
48                 simple-audio-card,cpu {
49                         sound-dai = <&i2s>;
50                 };
51
52                 dailink0_master: simple-audio-card,codec {
53                         sound-dai = <&codec>;
54                 };
55         };
56 };
57
58 &pinctrl {
59         state_default: pinctrl0 {
60                 gpio {
61                         ralink,group = "wdt", "uart1";
62                         ralink,function = "gpio";
63                 };
64         };
65
66         i2s_pins: i2s {
67                 i2s {
68                         ralink,group = "i2s";
69                         ralink,function = "i2s";
70                 };
71         };
72
73         wm8960_mclk_pins: wm8960_mclk {
74                 wm8960_mclk {
75                         ralink,group = "refclk";
76                         ralink,function = "reclk";
77                 };
78         };
79 };
80
81 &gpio1 {
82         status = "okay";
83 };
84
85 &i2c {
86         status = "okay";
87
88         codec: wm8960@1a {
89                 #sound-dai-cells = <0>;
90                 compatible = "wlf,wm8960";
91                 reg = <0x1a>;
92
93                 wlf,shared-lrclk;
94         };
95 };
96
97 &ethernet {
98         mtd-mac-address = <&factory 0x4>;
99 };
100
101 &esw {
102         mediatek,portmap = <0x3>;
103         mediatek,portdisable = <0x3c>;
104 };
105
106 &i2s {
107         #sound-dai-cells = <0>;
108         status = "okay";
109         pinctrl-names = "default";
110         pinctrl-0 = <&i2s_pins>, <&wm8960_mclk_pins>;
111 };
112
113 &sdhci {
114         status = "okay";
115 };
116
117 &gdma {
118         status = "okay";
119 };
120
121 &spi0 {
122         status = "okay";
123
124         m25p80@0 {
125                 #address-cells = <1>;
126                 #size-cells = <1>;
127                 compatible = "jedec,spi-nor";
128                 reg = <0>;
129                 linux,modalias = "m25p80";
130                 spi-max-frequency = <60000000>;
131                 m25p,chunked-io = <32>;
132                 m25p,fast-read;
133
134                 partition@0 {
135                         label = "u-boot";
136                         reg = <0x0 0x30000>;
137                         read-only;
138                 };
139
140                 partition@30000 {
141                         label = "u-boot-env";
142                         reg = <0x30000 0x10000>;
143                         read-only;
144                 };
145
146                 factory: partition@40000 {
147                         label = "factory";
148                         reg = <0x40000 0x10000>;
149                         read-only;
150                 };
151
152                 partition@50000 {
153                         label = "firmware";
154                         reg = <0x50000 0x7b0000>;
155                 };
156         };
157 };