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#include <dt-bindings/leds/common.h>
9
10/ {
11	compatible = "tplink,hc220-g5-v1", "mediatek,mt7621-soc";
12	model = "TP-Link HC220 G5 v1";
13
14	memory@0 {
15		device_type = "memory";
16		reg = <0x00000000 0x08000000>;
17	};
18
19	chosen {
20		bootargs = "earlycon console=ttyS0,115200";
21	};
22
23	gpio-keys {
24		compatible = "gpio-keys";
25
26		key-reset {
27			label = "reset";
28			gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
29			linux,code = <KEY_RESTART>;
30		};
31
32		key-wps {
33			label = "wps";
34			gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
35			linux,code = <KEY_WPS_BUTTON>;
36		};
37	};
38
39	leds {
40		compatible = "gpio-leds";
41
42		led-fault {
43			color = <LED_COLOR_ID_RED>;
44			function = LED_FUNCTION_FAULT;
45			gpios = <&gpio 13 GPIO_ACTIVE_HIGH>;
46		};
47
48		led-power {
49			color = <LED_COLOR_ID_GREEN>;
50			function = LED_FUNCTION_POWER;
51			gpios = <&gpio 14 GPIO_ACTIVE_HIGH>;
52			linux,default-trigger = "default-on";
53		};
54
55		led-wps {
56			color = <LED_COLOR_ID_BLUE>;
57			function = LED_FUNCTION_WPS;
58			gpios = <&gpio 15 GPIO_ACTIVE_HIGH>;
59		};
60	};
61};
62
63&pcie {
64	status = "okay";
65};
66
67&switch0 {
68	ports {
69		port@0 {
70			status = "okay";
71			label = "lan2";
72		};
73
74		port@1 {
75			status = "okay";
76			label = "lan1";
77		};
78
79		port@2 {
80			status = "okay";
81			label = "wan";
82		};
83	};
84};
85