1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
3 #include "rtl838x.dtsi"
5 #include <dt-bindings/input/input.h>
6 #include <dt-bindings/gpio/gpio.h>
9 compatible = "d-link,dgs-1210-10p", "realtek,rtl838x-soc";
10 model = "D-Link DGS-1210-10P";
13 led-boot = &led_power;
14 led-failsafe = &led_power;
15 led-running = &led_power;
16 led-upgrade = &led_power;
20 bootargs = "console=ttyS0,115200";
24 device_type = "memory";
25 reg = <0x0 0x8000000>;
29 compatible = "gpio-leds";
32 // GPIO 24 seems to provide power to the leds
33 label = "green:power";
34 gpios = <&gpio0 47 GPIO_ACTIVE_LOW>;
39 compatible = "gpio-keys-polled";
44 gpios = <&gpio0 94 GPIO_ACTIVE_LOW>;
45 linux,code = <KEY_RESTART>;
52 indirect-access-bus-id = <0>;
58 compatible = "jedec,spi-nor";
60 spi-max-frequency = <10000000>;
63 compatible = "fixed-partitions";
69 reg = <0x00000000 0x80000>;
74 reg = <0x00080000 0x40000>;
78 label = "u-boot-env2";
79 reg = <0x000c0000 0x40000>;
83 compatible = "denx,uimage";
84 reg = <0x00100000 0xd80000>;
88 reg = <0x00e80000 0x180000>;
92 reg = <0x01000000 0x40000>;
96 reg = <0x01040000 0xc00000>;
100 reg = <0x01c40000 0x3c0000>;
108 compatible = "realtek,rtl838x-mdio";
109 regmap = <ðernet0>;
110 #address-cells = <1>;
128 #address-cells = <1>;
131 SWITCH_PORT(8, 1, internal)
132 SWITCH_PORT(9, 2, internal)
133 SWITCH_PORT(10, 3, internal)
134 SWITCH_PORT(11, 4, internal)
135 SWITCH_PORT(12, 5, internal)
136 SWITCH_PORT(13, 6, internal)
137 SWITCH_PORT(14, 7, internal)
138 SWITCH_PORT(15, 8, internal)
139 SWITCH_SFP_PORT(24, 9, rgmii-id)
140 SWITCH_SFP_PORT(26, 10, rgmii-id)
143 ethernet = <ðernet0>;
145 phy-mode = "internal";