4d518bf20673d80ff0493a493525c63ad95842b1
[openwrt/staging/hauke.git] / target / linux / ramips / dts / mt7620a_phicomm_psg1218.dtsi
1 #include "mt7620a.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "phicomm,psg1218", "ralink,mt7620a-soc";
8
9 aliases {
10 led-boot = &led_blue;
11 led-failsafe = &led_blue;
12 led-running = &led_blue;
13 led-upgrade = &led_blue;
14 };
15
16 keys {
17 compatible = "gpio-keys";
18
19 reset {
20 label = "reset";
21 gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
22 linux,code = <KEY_RESTART>;
23 };
24 };
25
26 leds {
27 compatible = "gpio-leds";
28
29 led_blue: blue {
30 label = "blue:status";
31 gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
32 default-state = "on";
33 };
34
35 yellow {
36 label = "yellow:status";
37 gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
38 };
39
40 red {
41 label = "red:status";
42 gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
43 };
44 };
45 };
46
47 &spi0 {
48 status = "okay";
49
50 flash@0 {
51 compatible = "jedec,spi-nor";
52 reg = <0>;
53 spi-max-frequency = <80000000>;
54 m25p,fast-read;
55
56 partitions {
57 compatible = "fixed-partitions";
58 #address-cells = <1>;
59 #size-cells = <1>;
60
61 partition@0 {
62 label = "u-boot";
63 reg = <0x0 0x30000>;
64 read-only;
65 };
66
67 partition@20000 {
68 label = "u-boot-env";
69 reg = <0x30000 0x10000>;
70 read-only;
71 };
72
73 factory: partition@30000 {
74 label = "factory";
75 reg = <0x40000 0x10000>;
76 read-only;
77 };
78
79 partition@40000 {
80 compatible = "denx,uimage";
81 label = "firmware";
82 reg = <0x50000 0x7b0000>;
83 };
84 };
85 };
86 };
87
88 &state_default {
89 gpio {
90 groups = "i2c", "uartf";
91 function = "gpio";
92 };
93 };
94
95 &pcie {
96 status = "okay";
97 };
98
99 &pcie0 {
100 mt76@0,0 {
101 reg = <0x0000 0 0 0 0>;
102 mediatek,mtd-eeprom = <&factory 0x8000>;
103 ieee80211-freq-limit = <5000000 6000000>;
104 };
105 };
106
107 &wmac {
108 ralink,mtd-eeprom = <&factory 0x0>;
109 };