GNU Linux-libre 5.10.153-gnu1
[releases.git] / drivers / staging / mt7621-dts / gbpc1.dts
1 /dts-v1/;
2
3 #include "mt7621.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9         compatible = "gnubee,gb-pc1", "mediatek,mt7621-soc";
10         model = "GB-PC1";
11
12         memory@0 {
13                 device_type = "memory";
14                 reg = <0x00000000 0x1c000000>,
15                       <0x20000000 0x04000000>;
16         };
17
18         chosen {
19                 bootargs = "console=ttyS0,57600";
20         };
21
22         palmbus: palmbus@1E000000 {
23                 i2c@900 {
24                         status = "okay";
25                 };
26         };
27
28         gpio-keys {
29                 compatible = "gpio-keys";
30
31                 reset {
32                         label = "reset";
33                         gpios = <&gpio 18 GPIO_ACTIVE_HIGH>;
34                         linux,code = <KEY_RESTART>;
35                 };
36         };
37
38         gpio-leds {
39                 compatible = "gpio-leds";
40
41                 power {
42                         label = "green:power";
43                         gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
44                         linux,default-trigger = "default-on";
45                 };
46
47                 system {
48                         label = "green:system";
49                         gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
50                         linux,default-trigger = "disk-activity";
51                 };
52         };
53 };
54
55 &sdhci {
56         status = "okay";
57 };
58
59 &spi0 {
60         status = "okay";
61
62         m25p80@0 {
63                 #address-cells = <1>;
64                 #size-cells = <1>;
65                 compatible = "jedec,spi-nor";
66                 reg = <0>;
67                 spi-max-frequency = <50000000>;
68                 broken-flash-reset;
69
70                 partition@0 {
71                         label = "u-boot";
72                         reg = <0x0 0x30000>;
73                         read-only;
74                 };
75
76                 partition@30000 {
77                         label = "u-boot-env";
78                         reg = <0x30000 0x10000>;
79                         read-only;
80                 };
81
82                 factory: partition@40000 {
83                         label = "factory";
84                         reg = <0x40000 0x10000>;
85                         read-only;
86                 };
87
88                 partition@50000 {
89                         label = "firmware";
90                         reg = <0x50000 0x1fb0000>;
91                 };
92         };
93 };
94
95 &sysclock {
96                         compatible = "fixed-clock";
97                         /* This is normally 1/4 of cpuclock */
98                         clock-frequency = <225000000>;
99 };
100
101 &cpuclock {
102                         compatible = "fixed-clock";
103                         clock-frequency = <900000000>;
104 };
105
106 &pcie {
107         pinctrl-names = "default";
108         pinctrl-0 = <&pcie_pins>;
109
110         reset-gpios = <&gpio 19 GPIO_ACTIVE_LOW>,
111                         <&gpio 8 GPIO_ACTIVE_LOW>,
112                         <&gpio 7 GPIO_ACTIVE_LOW>;
113         status = "okay";
114 };
115
116 &pinctrl {
117         pinctrl-names = "default";
118         pinctrl-0 = <&state_default>;
119
120         state_default: state-default {
121                 gpio-pinmux {
122                         groups = "rgmii2", "uart3", "wdt";
123                         function = "gpio";
124                 };
125         };
126 };
127
128 &switch0 {
129         ports {
130                 port@0 {
131                         status = "okay";
132                         label = "ethblack";
133                 };
134
135                 port@4 {
136                         status = "okay";
137                         label = "ethblue";
138                 };
139         };
140 };