xref: /linux/arch/mips/boot/dts/ralink/mt7621-gnubee-gb-pc2.dts (revision 156010ed9c2ac1e9df6c11b1f688cf8a6e0152e6)
1// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2/dts-v1/;
3
4#include "mt7621.dtsi"
5
6#include <dt-bindings/gpio/gpio.h>
7#include <dt-bindings/input/input.h>
8
9/ {
10	compatible = "gnubee,gb-pc2", "mediatek,mt7621-soc";
11	model = "GB-PC2";
12
13	memory@0 {
14		device_type = "memory";
15		reg = <0x00000000 0x1c000000>,
16		      <0x20000000 0x04000000>;
17	};
18
19	chosen {
20		bootargs = "console=ttyS0,57600";
21	};
22
23	gpio-keys {
24		compatible = "gpio-keys";
25
26		key-reset {
27			label = "reset";
28			gpios = <&gpio 18 GPIO_ACTIVE_HIGH>;
29			linux,code = <KEY_RESTART>;
30		};
31	};
32
33	gpio-leds {
34		compatible = "gpio-leds";
35
36		ethblack-green {
37			label = "green:ethblack";
38			gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
39		};
40
41		ethblue-green {
42			label = "green:ethblue";
43			gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
44		};
45
46		ethyellow-green {
47			label = "green:ethyellow";
48			gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
49		};
50
51		ethyellow-orange {
52			label = "orange:ethyellow";
53			gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
54		};
55
56		power {
57			label = "green:power";
58			gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
59			linux,default-trigger = "default-on";
60		};
61
62		system {
63			label = "green:system";
64			gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
65			linux,default-trigger = "disk-activity";
66		};
67	};
68};
69
70&mmc {
71	status = "okay";
72};
73
74&spi0 {
75	status = "okay";
76
77	flash@0 {
78		#address-cells = <1>;
79		#size-cells = <1>;
80		compatible = "jedec,spi-nor";
81		reg = <0>;
82		spi-max-frequency = <50000000>;
83		broken-flash-reset;
84
85		partition@0 {
86			label = "u-boot";
87			reg = <0x0 0x30000>;
88			read-only;
89		};
90
91		partition@30000 {
92			label = "u-boot-env";
93			reg = <0x30000 0x10000>;
94			read-only;
95		};
96
97		factory: partition@40000 {
98			label = "factory";
99			reg = <0x40000 0x10000>;
100			read-only;
101		};
102
103		partition@50000 {
104			label = "firmware";
105			reg = <0x50000 0x1fb0000>;
106		};
107	};
108};
109
110&pcie {
111	status = "okay";
112};
113
114&gmac1 {
115	status = "okay";
116	phy-mode = "rgmii-rxid";
117	phy-handle = <&ethphy5>;
118};
119
120&mdio {
121	ethphy5: ethernet-phy@5 {
122		reg = <5>;
123	};
124};
125
126&switch0 {
127	ports {
128		port@0 {
129			status = "okay";
130			label = "ethblack";
131		};
132
133		port@4 {
134			status = "okay";
135			label = "ethblue";
136		};
137	};
138};
139