1c9ccf3a3SEmmanuel Vadot// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2c9ccf3a3SEmmanuel Vadot/dts-v1/;
3c9ccf3a3SEmmanuel Vadot
4c9ccf3a3SEmmanuel Vadot#include "mt7621.dtsi"
5c9ccf3a3SEmmanuel Vadot
6c9ccf3a3SEmmanuel Vadot#include <dt-bindings/gpio/gpio.h>
7c9ccf3a3SEmmanuel Vadot#include <dt-bindings/input/input.h>
8c9ccf3a3SEmmanuel Vadot
9c9ccf3a3SEmmanuel Vadot/ {
10c9ccf3a3SEmmanuel Vadot	compatible = "gnubee,gb-pc1", "mediatek,mt7621-soc";
11*84943d6fSEmmanuel Vadot	model = "GnuBee GB-PC1";
12c9ccf3a3SEmmanuel Vadot
13c9ccf3a3SEmmanuel Vadot	memory@0 {
14c9ccf3a3SEmmanuel Vadot		device_type = "memory";
15c9ccf3a3SEmmanuel Vadot		reg = <0x00000000 0x1c000000>,
16c9ccf3a3SEmmanuel Vadot		      <0x20000000 0x04000000>;
17c9ccf3a3SEmmanuel Vadot	};
18c9ccf3a3SEmmanuel Vadot
19c9ccf3a3SEmmanuel Vadot	chosen {
20c9ccf3a3SEmmanuel Vadot		bootargs = "console=ttyS0,57600";
21c9ccf3a3SEmmanuel Vadot	};
22c9ccf3a3SEmmanuel Vadot
23c9ccf3a3SEmmanuel Vadot	gpio-keys {
24c9ccf3a3SEmmanuel Vadot		compatible = "gpio-keys";
25c9ccf3a3SEmmanuel Vadot
26b97ee269SEmmanuel Vadot		key-reset {
27c9ccf3a3SEmmanuel Vadot			label = "reset";
28c9ccf3a3SEmmanuel Vadot			gpios = <&gpio 18 GPIO_ACTIVE_HIGH>;
29c9ccf3a3SEmmanuel Vadot			linux,code = <KEY_RESTART>;
30c9ccf3a3SEmmanuel Vadot		};
31c9ccf3a3SEmmanuel Vadot	};
32c9ccf3a3SEmmanuel Vadot
33c9ccf3a3SEmmanuel Vadot	gpio-leds {
34c9ccf3a3SEmmanuel Vadot		compatible = "gpio-leds";
35c9ccf3a3SEmmanuel Vadot
36cb7aa33aSEmmanuel Vadot		led-power {
37c9ccf3a3SEmmanuel Vadot			label = "green:power";
38c9ccf3a3SEmmanuel Vadot			gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
39c9ccf3a3SEmmanuel Vadot			linux,default-trigger = "default-on";
40c9ccf3a3SEmmanuel Vadot		};
41c9ccf3a3SEmmanuel Vadot
42cb7aa33aSEmmanuel Vadot		led-system {
43c9ccf3a3SEmmanuel Vadot			label = "green:system";
44c9ccf3a3SEmmanuel Vadot			gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
45c9ccf3a3SEmmanuel Vadot			linux,default-trigger = "disk-activity";
46c9ccf3a3SEmmanuel Vadot		};
47c9ccf3a3SEmmanuel Vadot	};
48c9ccf3a3SEmmanuel Vadot};
49c9ccf3a3SEmmanuel Vadot
507ef62cebSEmmanuel Vadot&mmc {
51c9ccf3a3SEmmanuel Vadot	status = "okay";
52c9ccf3a3SEmmanuel Vadot};
53c9ccf3a3SEmmanuel Vadot
54c9ccf3a3SEmmanuel Vadot&spi0 {
55c9ccf3a3SEmmanuel Vadot	status = "okay";
56c9ccf3a3SEmmanuel Vadot
57d5b0e70fSEmmanuel Vadot	flash@0 {
58c9ccf3a3SEmmanuel Vadot		#address-cells = <1>;
59c9ccf3a3SEmmanuel Vadot		#size-cells = <1>;
60c9ccf3a3SEmmanuel Vadot		compatible = "jedec,spi-nor";
61c9ccf3a3SEmmanuel Vadot		reg = <0>;
62c9ccf3a3SEmmanuel Vadot		spi-max-frequency = <50000000>;
63c9ccf3a3SEmmanuel Vadot		broken-flash-reset;
64c9ccf3a3SEmmanuel Vadot
65c9ccf3a3SEmmanuel Vadot		partition@0 {
66c9ccf3a3SEmmanuel Vadot			label = "u-boot";
67c9ccf3a3SEmmanuel Vadot			reg = <0x0 0x30000>;
68c9ccf3a3SEmmanuel Vadot			read-only;
69c9ccf3a3SEmmanuel Vadot		};
70c9ccf3a3SEmmanuel Vadot
71c9ccf3a3SEmmanuel Vadot		partition@30000 {
72c9ccf3a3SEmmanuel Vadot			label = "u-boot-env";
73c9ccf3a3SEmmanuel Vadot			reg = <0x30000 0x10000>;
74c9ccf3a3SEmmanuel Vadot			read-only;
75c9ccf3a3SEmmanuel Vadot		};
76c9ccf3a3SEmmanuel Vadot
77c9ccf3a3SEmmanuel Vadot		factory: partition@40000 {
78c9ccf3a3SEmmanuel Vadot			label = "factory";
79c9ccf3a3SEmmanuel Vadot			reg = <0x40000 0x10000>;
80c9ccf3a3SEmmanuel Vadot			read-only;
81c9ccf3a3SEmmanuel Vadot		};
82c9ccf3a3SEmmanuel Vadot
83c9ccf3a3SEmmanuel Vadot		partition@50000 {
84c9ccf3a3SEmmanuel Vadot			label = "firmware";
85c9ccf3a3SEmmanuel Vadot			reg = <0x50000 0x1fb0000>;
86c9ccf3a3SEmmanuel Vadot		};
87c9ccf3a3SEmmanuel Vadot	};
88c9ccf3a3SEmmanuel Vadot};
89c9ccf3a3SEmmanuel Vadot
90c9ccf3a3SEmmanuel Vadot&pcie {
91c9ccf3a3SEmmanuel Vadot	status = "okay";
92c9ccf3a3SEmmanuel Vadot};
93c9ccf3a3SEmmanuel Vadot
94c9ccf3a3SEmmanuel Vadot&switch0 {
95c9ccf3a3SEmmanuel Vadot	ports {
96c9ccf3a3SEmmanuel Vadot		port@0 {
97c9ccf3a3SEmmanuel Vadot			status = "okay";
98c9ccf3a3SEmmanuel Vadot			label = "ethblack";
99c9ccf3a3SEmmanuel Vadot		};
100cb7aa33aSEmmanuel Vadot
101cb7aa33aSEmmanuel Vadot		port@4 {
102cb7aa33aSEmmanuel Vadot			status = "okay";
103cb7aa33aSEmmanuel Vadot			label = "ethblue";
104cb7aa33aSEmmanuel Vadot		};
105c9ccf3a3SEmmanuel Vadot	};
106c9ccf3a3SEmmanuel Vadot};
107