aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ath79/dts/qca9533_mikrotik_routerboard-95x.dtsi
blob: 79c9f44d3280124ef2028bc6e8027e350a38f8d4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT

#include "qca9533_mikrotik_routerboard-16m.dtsi"

/ {
	aliases {
		led-boot = &led_user;
		led-failsafe = &led_user;
		led-running = &led_user;
		led-upgrade = &led_user;
	};

	leds {
		compatible = "gpio-leds";

		led_user: user {
			label = "green:user";
			gpios = <&gpio 4 GPIO_ACTIVE_HIGH>;
		};

		port1 {
			label = "green:port1";
			gpios = <&gpio_ext 0 GPIO_ACTIVE_LOW>;
		};

		port2 {
			label = "green:port2";
			gpios = <&gpio_ext 1 GPIO_ACTIVE_LOW>;
		};

		port3 {
			label = "green:port3";
			gpios = <&gpio_ext 2 GPIO_ACTIVE_LOW>;
		};

		port4 {
			label = "green:port4";
			gpios = <&gpio_ext 3 GPIO_ACTIVE_LOW>;
		};

		port5 {
			label = "green:port5";
			gpios = <&gpio_ext 4 GPIO_ACTIVE_LOW>;
		};

	};

	gpio-export {
		compatible = "gpio-export";

		usb_power {
			gpio-export,name = "usb-power";
			gpio-export,output = <1>;
			gpios = <&gpio_ext 5 GPIO_ACTIVE_LOW>;
		};

		enable_poe_port5 {
			gpio-export,name = "enable-poe:port5";
			gpio-export,output = <0>;
			gpios = <&gpio 14 GPIO_ACTIVE_HIGH>;
		};
	};
};

&spi {
	pinctrl-names = "default";
	pinctrl-0 = <&pin_spi_cs1>;

	gpio_ext: gpio_ext@1 {
		compatible = "fairchild,74hc595";
		reg = <1>;
		gpio-controller;
		#gpio-cells = <2>;
		registers-number = <1>;
		spi-max-frequency = <25000000>;
	};
};


&pinmux {
	pin_spi_cs1: pinmux_spi_cs1 {
		pinctrl-single,bits = <0x8 0x0a000000 0xff000000>;
	};
};

&eth0 {
	status = "okay";

	phy-handle = <&swphy4>;
};

&usb0 {
	status = "okay";
};

&usb_phy {
	status = "okay";
};