realtek: netgear-gigabit: Enable RTL8231
[openwrt/staging/jow.git] / target / linux / realtek / dts-5.10 / rtl8380_netgear_gigabit.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later
2
3 #include "rtl838x.dtsi"
4
5 #include <dt-bindings/input/input.h>
6 #include <dt-bindings/gpio/gpio.h>
7
8 / {
9 compatible = "realtek,rtl838x-soc";
10
11 memory@0 {
12 device_type = "memory";
13 reg = <0x0 0x8000000>;
14 };
15
16 keys {
17 compatible = "gpio-keys";
18
19 mode {
20 label = "reset";
21 gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
22 linux,code = <KEY_RESTART>;
23 };
24 };
25
26 gpio-restart {
27 compatible = "gpio-restart";
28 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
29 open-source;
30 };
31 };
32
33 &gpio1 {
34 status = "okay";
35
36 indirect-access-bus-id = <31>;
37 };
38
39 &ethernet0 {
40 mdio: mdio-bus {
41 compatible = "realtek,rtl838x-mdio";
42 regmap = <&ethernet0>;
43 #address-cells = <1>;
44 #size-cells = <0>;
45
46 INTERNAL_PHY(8)
47 INTERNAL_PHY(9)
48 INTERNAL_PHY(10)
49 INTERNAL_PHY(11)
50 INTERNAL_PHY(12)
51 INTERNAL_PHY(13)
52 INTERNAL_PHY(14)
53 INTERNAL_PHY(15)
54 };
55 };
56
57 &switch0 {
58 ports {
59 #address-cells = <1>;
60 #size-cells = <0>;
61
62 SWITCH_PORT(8, 1, internal)
63 SWITCH_PORT(9, 2, internal)
64 SWITCH_PORT(10, 3, internal)
65 SWITCH_PORT(11, 4, internal)
66 SWITCH_PORT(12, 5, internal)
67 SWITCH_PORT(13, 6, internal)
68 SWITCH_PORT(14, 7, internal)
69 SWITCH_PORT(15, 8, internal)
70
71 port@28 {
72 ethernet = <&ethernet0>;
73 reg = <28>;
74 phy-mode = "internal";
75 fixed-link {
76 speed = <1000>;
77 full-duplex;
78 };
79 };
80 };
81 };