aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--target/linux/realtek/dts-5.10/rtl8380_engenius_ews2910p.dts173
-rw-r--r--target/linux/realtek/image/rtl838x.mk13
2 files changed, 186 insertions, 0 deletions
diff --git a/target/linux/realtek/dts-5.10/rtl8380_engenius_ews2910p.dts b/target/linux/realtek/dts-5.10/rtl8380_engenius_ews2910p.dts
new file mode 100644
index 0000000000..feb57fecff
--- /dev/null
+++ b/target/linux/realtek/dts-5.10/rtl8380_engenius_ews2910p.dts
@@ -0,0 +1,173 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+
+#include "rtl838x.dtsi"
+
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
+
+/ {
+ compatible = "engenius,ews2910p", "realtek,rtl838x-soc";
+ model = "EnGenius EWS2910P";
+
+ aliases {
+ led-boot = &led_power;
+ led-failsafe = &led_fault;
+ led-running = &led_power;
+ led-upgrade = &led_power;
+ };
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x10000000>;
+ };
+
+ keys {
+ compatible = "gpio-keys";
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ led_mode {
+ label = "led-mode";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ };
+ };
+
+ gpio1: rtl8231-gpio {
+ compatible = "realtek,rtl8231-gpio";
+ #gpio-cells = <2>;
+ gpio-controller;
+ indirect-access-bus-id = <0>;
+ };
+
+ gpio-restart {
+ compatible = "gpio-restart";
+ gpios = <&gpio1 0 GPIO_ACTIVE_LOW>;
+ };
+
+ leds {
+ compatible = "gpio-leds";
+
+ led_power: led-0 {
+ label = "green:power";
+ gpios = <&gpio1 3 GPIO_ACTIVE_LOW>;
+ };
+
+ led_lan_mode: led-1 {
+ label = "green:lan-mode";
+ gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
+ };
+
+ led_fault: led-2 {
+ label = "amber:fault";
+ gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
+ };
+
+ led_poe_max: led-3 {
+ label = "amber:poe-max";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ flash@0 {
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partitions {
+ compatible = "fixed-partitions";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x80000>;
+ read-only;
+ };
+ partition@80000 {
+ label = "u-boot-env";
+ reg = <0x80000 0x10000>;
+ read-only;
+ };
+ partition@90000 {
+ label = "u-boot-env2";
+ reg = <0x90000 0x10000>;
+ };
+ partition@a0000 {
+ label = "jffs2-cfg";
+ reg = <0xa0000 0xd60000>;
+ };
+ partition@e00000 {
+ label = "jffs2-log";
+ reg = <0xe00000 0x200000>;
+ };
+ partition@1000000 {
+ compatible = "openwrt,uimage";
+ label = "firmware";
+ reg = <0x1000000 0x800000>;
+ openwrt,ih-magic = <0x03802910>;
+ };
+ partition@1800000 {
+ label = "firmware2";
+ reg = <0x1800000 0x800000>;
+ };
+ };
+ };
+};
+
+&ethernet0 {
+ mdio: mdio-bus {
+ compatible = "realtek,rtl838x-mdio";
+ regmap = <&ethernet0>;
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ INTERNAL_PHY(8)
+ INTERNAL_PHY(9)
+ INTERNAL_PHY(10)
+ INTERNAL_PHY(11)
+ INTERNAL_PHY(12)
+ INTERNAL_PHY(13)
+ INTERNAL_PHY(14)
+ INTERNAL_PHY(15)
+ };
+};
+
+&switch0 {
+ ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ SWITCH_PORT(8, 1, internal)
+ SWITCH_PORT(9, 2, internal)
+ SWITCH_PORT(10, 3, internal)
+ SWITCH_PORT(11, 4, internal)
+ SWITCH_PORT(12, 5, internal)
+ SWITCH_PORT(13, 6, internal)
+ SWITCH_PORT(14, 7, internal)
+ SWITCH_PORT(15, 8, internal)
+
+ port@28 {
+ ethernet = <&ethernet0>;
+ reg = <28>;
+ phy-mode = "internal";
+
+ fixed-link {
+ speed = <1000>;
+ full-duplex;
+ };
+ };
+ };
+};
+
+&uart1 {
+ status = "okay";
+};
diff --git a/target/linux/realtek/image/rtl838x.mk b/target/linux/realtek/image/rtl838x.mk
index df145cfb69..f38e4977d2 100644
--- a/target/linux/realtek/image/rtl838x.mk
+++ b/target/linux/realtek/image/rtl838x.mk
@@ -42,6 +42,19 @@ define Device/d-link_dgs-1210-28
endef
TARGET_DEVICES += d-link_dgs-1210-28
+# The "IMG-" uImage name allows flashing the iniramfs from the vendor Web UI.
+# Avoided for sysupgrade, as the vendor FW would do an incomplete flash.
+define Device/engenius_ews2910p
+ SOC := rtl8380
+ IMAGE_SIZE := 8192k
+ DEVICE_VENDOR := EnGenius
+ DEVICE_MODEL := EWP2910P
+ UIMAGE_MAGIC := 0x03802910
+ KERNEL_INITRAMFS := kernel-bin | append-dtb | gzip | \
+ uImage gzip -n 'IMG-0.00.00-c0.0.00'
+endef
+TARGET_DEVICES += engenius_ews2910p
+
define Device/inaba_aml2-17gp
SOC := rtl8382
IMAGE_SIZE := 13504k