From 84909c62c8455a08fb8bb29bd7809ab22c927bf0 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Sun, 9 Mar 2025 16:43:58 +0100 Subject: [PATCH 1/7] unetd: update to Git HEAD (2025-03-09) d8b43985e4d7 ubus: fix token_create policy 7326459bd743 ubus: dump service information on network_get 6c9c8fbd8128 service: add @all as alias for all members, unless defined differently Signed-off-by: Felix Fietkau --- package/network/services/unetd/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package/network/services/unetd/Makefile b/package/network/services/unetd/Makefile index 64b3b63421..96ea12d6fb 100644 --- a/package/network/services/unetd/Makefile +++ b/package/network/services/unetd/Makefile @@ -10,9 +10,9 @@ include $(TOPDIR)/rules.mk PKG_NAME:=unetd PKG_SOURCE_PROTO:=git PKG_SOURCE_URL=$(PROJECT_GIT)/project/unetd.git -PKG_SOURCE_DATE:=2025-02-28 -PKG_SOURCE_VERSION:=edc8fdae463ad7ce9bfb876af0c653ab1da197df -PKG_MIRROR_HASH:=2f0ce439b9e4815b3f20b9aaf4378e3aac114f429bb8bfd06739df118b3da9c8 +PKG_SOURCE_DATE:=2025-03-09 +PKG_SOURCE_VERSION:=6c9c8fbd81285a2cba7dd1c2c1ac2bf25ca99e27 +PKG_MIRROR_HASH:=9dc06c945713a6a289ed0838ebe59e65b4fbb333e02d5159a8e87d29754808a6 PKG_LICENSE:=GPL-2.0 PKG_MAINTAINER:=Felix Fietkau From 8a7863767056ca0dec69a6b383b6e0c0d5fc3af7 Mon Sep 17 00:00:00 2001 From: Roland Reinl Date: Fri, 28 Feb 2025 06:11:01 +0100 Subject: [PATCH 2/7] ramips: Add support for Cudy M1300 v2 The M1300 v2 is similar to the WR1300 series from Cudy. Differences: - Only 1 LAN port - No USB Specifications: - MT7621 - MT7603E (2.4G b/g/n) and MT7613BE (5G ac/n) wifi - 128 MB RAM - 16 MB flash MAC Addresses: - There is one on the label, e.g. xx:xx:xx:xx:xx:1C - LAN (bottom connector) is the same as the label, e.g. xx:xx:xx:xx:xx:1C - WAN (top connector) is label +2, e.g. xx:xx:xx:xx:xx:1E - WLAN (2.4G) is the same as the label, e.g. xx:xx:xx:xx:xx:1C - WLAN (5G) is the same as WAN, e.g. xx:xx:xx:xx:xx:1E UART: - is available via the pin holes on the board - From inner to outer pin: TX, RX, GND, VCC - Do NOT connect VCC - Settings: 3.3V, 115200, 8N1 GPIO: - There are two LEDs: Red (GPIO 3) and White (GPIO 4) - There are two buttons: Reset (GPIO 8) and WPS (GPIO 10) Migration to OpenWrt: - Download the migration image from the Cudy website (it should be available as soon as OpenWrt officially supports the device) - The migration image is also available here until a image is provided by Cudy: https://github.com/RolandoMagico/openwrt-build/releases/tag/M1300_Build_20240222 - File: openwrt-ramips-mt7621-cudy_m1300-v2-squashfs-flash-signed.bin - Connect computer to LAN (bottom connector) and flash the migration image via OEM web interface - In the migration image, LAN and WAN are swapped. Computer must be connected to the other port after flashing - OpenWrt is now accessible via 192.168.1.1 - After flashing an up to date OpenWrt image, LAN and WAN settings are again the same as in the OEM firmware - So use the other connector again Revert back to OEM firmware: - Set up a TFTP server on IP 192.168.1.88 and connect to the LAN port (lower port) - Provide the Cudy firmware as recovery.bin in the TFTP server - Press the reset button while powering on the device - Recovery process is started now - When recovery process is done, OEM firmware is accessible via 192.168.10.1 again General information: - No possibility to load a initramfs image via U-Boot because there is no option to interrupt U-Boot Signed-off-by: Roland Reinl Link: https://github.com/openwrt/openwrt/pull/18139 Signed-off-by: Hauke Mehrtens --- .../linux/ramips/dts/mt7621_cudy_m1300-v2.dts | 201 ++++++++++++++++++ target/linux/ramips/image/mt7621.mk | 13 ++ .../mt7621/base-files/etc/board.d/02_network | 1 + 3 files changed, 215 insertions(+) create mode 100644 target/linux/ramips/dts/mt7621_cudy_m1300-v2.dts diff --git a/target/linux/ramips/dts/mt7621_cudy_m1300-v2.dts b/target/linux/ramips/dts/mt7621_cudy_m1300-v2.dts new file mode 100644 index 0000000000..f988b3375b --- /dev/null +++ b/target/linux/ramips/dts/mt7621_cudy_m1300-v2.dts @@ -0,0 +1,201 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT + +#include "mt7621.dtsi" + +#include +#include +#include + +/ { + compatible = "cudy,m1300-v2", "mediatek,mt7621-soc"; + model = "Cudy M1300 v2"; +}; + +/ { + aliases { + led-boot = &led_status_white; + led-failsafe = &led_status_red; + led-running = &led_status_white; + led-upgrade = &led_status_red; + label-mac-device = &gmac0; + }; + + chosen { + bootargs = "console=ttyS0,115200"; + }; + + keys { + compatible = "gpio-keys"; + + reset { + label = "reset"; + gpios = <&gpio 8 GPIO_ACTIVE_LOW>; + linux,code = ; + }; + + wps { + label = "wps"; + gpios = <&gpio 10 GPIO_ACTIVE_LOW>; + linux,code = ; + }; + }; + + leds { + compatible = "gpio-leds"; + + led_status_red: led-status-red { + color = ; + function = LED_FUNCTION_STATUS; + gpios = <&gpio 3 GPIO_ACTIVE_LOW>; + }; + + led_status_white: led-status-white { + color = ; + function = LED_FUNCTION_STATUS; + gpios = <&gpio 4 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 0x30000>; + read-only; + }; + + partition@30000 { + label = "u-boot-env"; + reg = <0x30000 0x10000>; + read-only; + }; + + partition@40000 { + label = "factory"; + reg = <0x40000 0x10000>; + read-only; + + nvmem-layout { + compatible = "fixed-layout"; + #address-cells = <1>; + #size-cells = <1>; + + eeprom_factory_0: eeprom@0 { + reg = <0x0 0x400>; + }; + + eeprom_factory_8000: eeprom@8000 { + reg = <0x8000 0x4da8>; + }; + }; + }; + + partition@50000 { + compatible = "denx,uimage"; + label = "firmware"; + reg = <0x50000 0xf80000>; + }; + + partition@fd0000 { + label = "debug"; + reg = <0xfd0000 0x10000>; + read-only; + }; + + partition@fe0000 { + label = "backup"; + reg = <0xfe0000 0x10000>; + read-only; + }; + + partition@ff0000 { + label = "bdinfo"; + reg = <0xff0000 0x10000>; + read-only; + + nvmem-layout { + compatible = "fixed-layout"; + #address-cells = <1>; + #size-cells = <1>; + + macaddr_bdinfo_de00: macaddr@de00 { + compatible = "mac-base"; + reg = <0xde00 0x6>; + #nvmem-cell-cells = <1>; + }; + }; + }; + }; + }; +}; + +&pcie { + status = "okay"; +}; + +&pcie0 { + wifi@0,0 { + compatible = "mediatek,mt76"; + reg = <0x0000 0 0 0 0>; + nvmem-cells = <&eeprom_factory_0>, <&macaddr_bdinfo_de00 0>; + nvmem-cell-names = "eeprom", "mac-address"; + ieee80211-freq-limit = <2400000 2500000>; + }; +}; + +&pcie1 { + wifi@0,0 { + compatible = "mediatek,mt76"; + reg = <0x0000 0 0 0 0>; + nvmem-cells = <&eeprom_factory_8000>, <&macaddr_bdinfo_de00 2>; + nvmem-cell-names = "eeprom", "mac-address"; + ieee80211-freq-limit = <5000000 6000000>; + }; +}; + + +&gmac0 { + nvmem-cells = <&macaddr_bdinfo_de00 0>; + nvmem-cell-names = "mac-address"; +}; + +&gmac1 { + status = "okay"; + label = "wan"; + phy-handle = <ðphy4>; + + nvmem-cells = <&macaddr_bdinfo_de00 2>; + nvmem-cell-names = "mac-address"; +}; + +ðphy4 { + /delete-property/ interrupts; +}; + +&switch0 { + ports { + port@3 { + status = "okay"; + label = "lan"; + }; + }; +}; + +&state_default { + gpio { + groups = "wdt", "jtag"; + function = "gpio"; + }; +}; diff --git a/target/linux/ramips/image/mt7621.mk b/target/linux/ramips/image/mt7621.mk index cfcfd0c88a..1f04dbdef6 100755 --- a/target/linux/ramips/image/mt7621.mk +++ b/target/linux/ramips/image/mt7621.mk @@ -699,6 +699,19 @@ define Device/confiabits_mt7621-v1 endef TARGET_DEVICES += confiabits_mt7621-v1 +define Device/cudy_m1300-v2 + $(Device/dsa-migration) + IMAGE_SIZE := 15872k + DEVICE_VENDOR := Cudy + DEVICE_MODEL := M1300 + DEVICE_VARIANT := v2 + DEVICE_PACKAGES := kmod-mt7603 kmod-mt7615e kmod-mt7663-firmware-ap \ + -uboot-envtools + UIMAGE_NAME := R15 + SUPPORTED_DEVICES += R15 +endef +TARGET_DEVICES += cudy_m1300-v2 + define Device/cudy_m1800 $(Device/dsa-migration) DEVICE_VENDOR := Cudy diff --git a/target/linux/ramips/mt7621/base-files/etc/board.d/02_network b/target/linux/ramips/mt7621/base-files/etc/board.d/02_network index 682b75ab5c..dfb139db4e 100644 --- a/target/linux/ramips/mt7621/base-files/etc/board.d/02_network +++ b/target/linux/ramips/mt7621/base-files/etc/board.d/02_network @@ -70,6 +70,7 @@ ramips_setup_interfaces() asiarf,ap7621-001|\ comfast,cf-e390ax|\ comfast,cf-ew72-v2|\ + cudy,m1300-v2|\ cudy,m1800|\ dna,valokuitu-plus-ex400|\ humax,e10|\ From 40f1db9cb11d98ef0b5061b8e210e6351935df8a Mon Sep 17 00:00:00 2001 From: Hauke Mehrtens Date: Sun, 19 Jan 2025 19:49:38 +0100 Subject: [PATCH 3/7] kernel: Add KERNEL_DCB (Data Center Bridging) The kmod-mlxsw-spectrum driver activated CONFIG_DCB indirectly already on all targets which are building this driver. All other DCB capable driver did not activate their DCB support. CONFIG_DCB increases the uncompressed kernel size by about 7.8KB. CONFIG_DCB is only needed some data center Ethernet cards and not used on normal routers. Activate it only on the x86_64 and the armsr_arm64 target which are used on normal servers or in VMs. Link: https://github.com/openwrt/openwrt/pull/17672 Signed-off-by: Hauke Mehrtens --- config/Config-kernel.in | 22 ++++++++++++++++++++++ package/kernel/linux/modules/netdevices.mk | 18 ++++++++++-------- target/linux/generic/config-6.6 | 4 ---- target/linux/loongarch64/config-6.6 | 1 - target/linux/x86/modules.mk | 4 +++- 5 files changed, 35 insertions(+), 14 deletions(-) diff --git a/config/Config-kernel.in b/config/Config-kernel.in index 64c8c63466..31d0e2dba4 100644 --- a/config/Config-kernel.in +++ b/config/Config-kernel.in @@ -1212,6 +1212,28 @@ config KERNEL_NET_L3_MASTER_DEV drivers to support L3 master devices like VRF. Increases the compressed kernel size by ~4kB (as of Linux 6.6). +config KERNEL_DCB + bool "Data Center Bridging support" + default y if TARGET_armsr_armv8 + default y if TARGET_x86_64 + help + This enables support for configuring Data Center Bridging (DCB) + features on DCB capable Ethernet adapters via rtnetlink. Say 'Y' + if you have a DCB capable Ethernet adapter which supports this + interface and you are connected to a DCB capable switch. + + DCB is a collection of Ethernet enhancements which allow DCB capable + NICs and switches to support network traffic with differing + requirements (highly reliable, no drops vs. best effort vs. low + latency) to co-exist on Ethernet. + + DCB features include: + Enhanced Transmission Selection (aka Priority Grouping) - provides a + framework for assigning bandwidth guarantees to traffic classes. + Priority-based Flow Control (PFC) - a MAC control pause frame which + works at the granularity of the 802.1p priority instead of the + link (802.3x). + config KERNEL_XDP_SOCKETS bool "XDP sockets support" help diff --git a/package/kernel/linux/modules/netdevices.mk b/package/kernel/linux/modules/netdevices.mk index d418701555..308958eb68 100644 --- a/package/kernel/linux/modules/netdevices.mk +++ b/package/kernel/linux/modules/netdevices.mk @@ -1148,7 +1148,8 @@ define KernelPackage/ixgbe KCONFIG:=CONFIG_IXGBE \ CONFIG_IXGBE_VXLAN=n \ CONFIG_IXGBE_HWMON=y \ - CONFIG_IXGBE_DCA=n + CONFIG_IXGBE_DCA=n \ + CONFIG_IXGBE_DCB=y FILES:=$(LINUX_DIR)/drivers/net/ethernet/intel/ixgbe/ixgbe.ko AUTOLOAD:=$(call AutoLoad,35,ixgbe) endef @@ -1186,7 +1187,8 @@ define KernelPackage/i40e KCONFIG:=CONFIG_I40E \ CONFIG_I40E_VXLAN=n \ CONFIG_I40E_HWMON=y \ - CONFIG_I40E_DCA=n + CONFIG_I40E_DCA=n \ + CONFIG_I40E_DCB=y FILES:=$(LINUX_DIR)/drivers/net/ethernet/intel/i40e/i40e.ko AUTOLOAD:=$(call AutoProbe,i40e) endef @@ -1600,7 +1602,7 @@ define KernelPackage/bnxt-en CONFIG_BNXT \ CONFIG_BNXT_SRIOV=y \ CONFIG_BNXT_FLOWER_OFFLOAD=y \ - CONFIG_BNXT_DCB=n \ + CONFIG_BNXT_DCB=y \ CONFIG_BNXT_HWMON=y AUTOLOAD:=$(call AutoProbe,bnxt_en) endef @@ -1642,7 +1644,7 @@ define KernelPackage/mlx4-core $(LINUX_DIR)/drivers/net/ethernet/mellanox/mlx4/mlx4_core.ko \ $(LINUX_DIR)/drivers/net/ethernet/mellanox/mlx4/mlx4_en.ko KCONFIG:= CONFIG_MLX4_EN \ - CONFIG_MLX4_EN_DCB=n \ + CONFIG_MLX4_EN_DCB=y \ CONFIG_MLX4_CORE=y \ CONFIG_MLX4_CORE_GEN2=y \ CONFIG_MLX4_DEBUG=n @@ -1662,7 +1664,7 @@ define KernelPackage/mlx5-core FILES:=$(LINUX_DIR)/drivers/net/ethernet/mellanox/mlx5/core/mlx5_core.ko KCONFIG:= CONFIG_MLX5_CORE \ CONFIG_MLX5_CORE_EN=y \ - CONFIG_MLX5_CORE_EN_DCB=n \ + CONFIG_MLX5_CORE_EN_DCB=y \ CONFIG_MLX5_CORE_IPOIB=n \ CONFIG_MLX5_EN_ARFS=n \ CONFIG_MLX5_EN_IPSEC=n \ @@ -1781,8 +1783,7 @@ define KernelPackage/mlxsw-spectrum KCONFIG:= \ CONFIG_MLXSW_SPECTRUM \ CONFIG_MLXSW_SPECTRUM_DCB=y \ - CONFIG_NET_SWITCHDEV=y \ - CONFIG_DCB=y + CONFIG_NET_SWITCHDEV=y AUTOLOAD:=$(call AutoProbe,mlxsw_spectrum) endef @@ -1817,7 +1818,8 @@ define KernelPackage/qlcnic KCONFIG:= \ CONFIG_QLCNIC \ CONFIG_QLCNIC_HWMON=y \ - CONFIG_QLCNIC_SRIOV=y + CONFIG_QLCNIC_SRIOV=y \ + CONFIG_QLCNIC_DCB=y FILES:=$(LINUX_DIR)/drivers/net/ethernet/qlogic/qlcnic/qlcnic.ko AUTOLOAD:=$(call AutoProbe,qlcnic) endef diff --git a/target/linux/generic/config-6.6 b/target/linux/generic/config-6.6 index d3b094eb58..ce2dc48dde 100644 --- a/target/linux/generic/config-6.6 +++ b/target/linux/generic/config-6.6 @@ -179,7 +179,6 @@ CONFIG_ALLOW_DEV_COREDUMP=y # CONFIG_AMD_MEM_ENCRYPT is not set # CONFIG_AMD_PHY is not set # CONFIG_AMD_XGBE is not set -# CONFIG_AMD_XGBE_DCB is not set # CONFIG_AMD_XGBE_HAVE_ECC is not set # CONFIG_AMIGA_PARTITION is not set # CONFIG_AMILO_RFKILL is not set @@ -2531,7 +2530,6 @@ CONFIG_HZ_100=y # CONFIG_I3C is not set # CONFIG_I40E is not set # CONFIG_I40EVF is not set -# CONFIG_I40E_DCB is not set # CONFIG_I6300ESB_WDT is not set # CONFIG_I82092 is not set # CONFIG_I82365 is not set @@ -2883,7 +2881,6 @@ CONFIG_ISDN=y # CONFIG_IWLWIFI is not set # CONFIG_IXGBE is not set # CONFIG_IXGBEVF is not set -# CONFIG_IXGBE_DCB is not set # CONFIG_JAILHOUSE_GUEST is not set # CONFIG_JBD2_DEBUG is not set # CONFIG_JFFS2_CMODE_FAVOURLZO is not set @@ -4823,7 +4820,6 @@ CONFIG_PWRSEQ_SIMPLE=y # CONFIG_QFMT_V1 is not set # CONFIG_QLA3XXX is not set # CONFIG_QLCNIC is not set -# CONFIG_QLCNIC_DCB is not set # CONFIG_QLGE is not set # CONFIG_QNX4FS_FS is not set # CONFIG_QNX6FS_FS is not set diff --git a/target/linux/loongarch64/config-6.6 b/target/linux/loongarch64/config-6.6 index 553c7acbbc..fe0c50c98d 100644 --- a/target/linux/loongarch64/config-6.6 +++ b/target/linux/loongarch64/config-6.6 @@ -169,7 +169,6 @@ CONFIG_CRYPTO_RNG2=y CONFIG_CRYPTO_RSA=y CONFIG_CRYPTO_SHA1=y CONFIG_CRYPTO_SHA256=y -CONFIG_DCB=y CONFIG_DEBUG_BUGVERBOSE=y CONFIG_DEBUG_INFO=y CONFIG_DEBUG_INFO_COMPRESSED_NONE=y diff --git a/target/linux/x86/modules.mk b/target/linux/x86/modules.mk index cdae01bce6..f43824571a 100644 --- a/target/linux/x86/modules.mk +++ b/target/linux/x86/modules.mk @@ -6,7 +6,9 @@ define KernelPackage/amd-xgbe SUBMENU:=$(NETWORK_DEVICES_MENU) TITLE:=AMD Ethernet on SoC support DEPENDS:=@PCI_SUPPORT @TARGET_x86_64 +kmod-lib-crc32c +kmod-ptp +kmod-libphy +kmod-mdio-devres - KCONFIG:=CONFIG_AMD_XGBE + KCONFIG:= \ + CONFIG_AMD_XGBE \ + CONFIG_AMD_XGBE_DCB=y FILES:=$(LINUX_DIR)/drivers/net/ethernet/amd/xgbe/amd-xgbe.ko AUTOLOAD:=$(call AutoLoad,35,amd-xgbe) endef From d136c24f7cc9f7b5ac72259ccf9193683f4ced74 Mon Sep 17 00:00:00 2001 From: Eric ZHANG Date: Sun, 2 Mar 2025 15:54:37 +0800 Subject: [PATCH 4/7] dnsmasq: fix handlers for options `filter_rr` and `cache_rr` According to: - https://github.com/openwrt/luci/blob/master/modules/luci-mod-network/htdocs/luci-static/resources/view/network/dhcp.js#L700 - https://github.com/openwrt/luci/blob/master/modules/luci-mod-network/htdocs/luci-static/resources/view/network/dhcp.js#L402 These two options should be of type `MultiValue` but here there're used as single value. This results in dnsmasq crashes when either of these options are set with multiple values, which leads to an invalid space-separated value. As these options are designed to take multiple values, I think it's better to use list format eg. `list filter_rr 'AAAA'`, instead of `option filter_rr 'AAAA,HTTPS'`. See: https://forum.openwrt.org/t/selecting-more-than-one-filter-arbitrary-rr-or-cache-arbitrary-rr-in-v24-10-0-crashes-dnsmasq/225801 Tested on 24.10.0 Signed-off-by: Eric ZHANG Link: https://github.com/openwrt/openwrt/pull/18149 Signed-off-by: Christian Marangi --- package/network/services/dnsmasq/files/dnsmasq.init | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/package/network/services/dnsmasq/files/dnsmasq.init b/package/network/services/dnsmasq/files/dnsmasq.init index 2e07e13d36..8258bcc3f4 100755 --- a/package/network/services/dnsmasq/files/dnsmasq.init +++ b/package/network/services/dnsmasq/files/dnsmasq.init @@ -226,6 +226,14 @@ append_interface_name() { xappend "--interface-name=$1,$2" } +append_filter_rr() { + xappend "--filter-rr=$1" +} + +append_cache_rr() { + xappend "--cache-rr=$1" +} + filter_dnsmasq() { local cfg="$1" func="$2" match_cfg="$3" found_cfg @@ -1000,8 +1008,8 @@ dnsmasq_start() # deprecate or remove filter-X in favor of filter-rr? append_bool "$cfg" filter_aaaa "--filter-AAAA" append_bool "$cfg" filter_a "--filter-A" - append_parm "$cfg" filter_rr "--filter-rr" - append_parm "$cfg" cache_rr "--cache-rr" + config_list_foreach "$cfg" filter_rr append_filter_rr + config_list_foreach "$cfg" cache_rr append_cache_rr append_parm "$cfg" logfacility "--log-facility" config_get logfacility "$cfg" "logfacility" From 6da7352ebe1150928a249aff47eb28c5c81f26aa Mon Sep 17 00:00:00 2001 From: Bernardus Jansen Date: Sat, 8 Mar 2025 14:57:42 +0100 Subject: [PATCH 5/7] ath79: add support for Fortinet FAP-221-C FCC ID: TVE-121402 Fortinet FAP-221-C is an indoor access point with 1gb ethernet port, dual-band wireless, internal antenna plates, and 802.3at PoE+. Hardware and board design are from Senao. The device appears very similar to the EnGenius EAP1200H, albeit with double the flash and RAM. **Specifications:** - QCA9557 SOC - QCA9882 WLAN PCI card, 5 GHz, 2x2, 26dBm - AR8035-A PHY RGMII GbE with PoE+ IN - 40 MHz clock - 32 MB FLASH FL256SAIFR0 - 2x 128 MB RAM NT5TU64M16HG - UART populated - 4 internal antenna plates - 5 LEDs, 1 button (power, 'warning', eth0, wifi1, wifi2) (reset) Amber LAN LED appears hardwired to ethernet port. Power LED is green only. Other LEDs are amber/green. **MAC addresses:** 1 MAC Address in flash at end of uboot ASCII encoded, no delimiters Labeled as "MAC Address" on case **Serial Access:** Pinout: (arrow) VCC GND RX TX Pins are populated with a header and traces not blocked. Bootloader is set to 9600 baud, 8 data, 1 stop. **Console Access:** Bootloader: Interrupt boot with Ctrl+C Press "k" and enter password "1" OR Hold reset button for 5 sec during power on Interrupt the TFTP transfer with Ctrl+C to print commands available, enter "help" OEM: default username is "admin", password blank telnet is available at default address 192.168.1.2 serial is available with baud 9600 to print commands available, enter "help" or tab-tab (busybox list of commands) **Installation:** Use factory.bin with OEM upgrade procedures OR Use initramfs.bin with uboot TFTP commands. Then perform a sysupgrade with sysupgrade.bin **TFTP Recovery:** Using serial console, load initramfs.bin using TFTP to boot openwrt without touching the flash. **Return to OEM:** The best way to return to OEM firmware is to have a copy of the MTD partitions before flashing Openwrt. Backup copies should be made of partitions "fwconcat0", "loader", and "fwconcat1" which together is the same flash range as OEM's "rootfs" and "uimage" by loading an initramfs.bin and using LuCI to download the mtdblocks. It is also possible to extract from the OEM firmware upgrade image by splitting it up in parts of lengths that correspond to the partitions in openwrt and write them to flash, after gzip decompression. After writing to the firmware partitions, erase the "reserved" partition and reboot. Signed-off-by: Bernardus Jansen Link: https://github.com/openwrt/openwrt/pull/18109 Signed-off-by: Hauke Mehrtens --- .../ath79/dts/qca9557_fortinet_fap-221-c.dts | 231 ++++++++++++++++++ .../generic/base-files/etc/board.d/02_network | 1 + .../base-files/lib/upgrade/platform.sh | 3 +- target/linux/ath79/image/generic.mk | 17 ++ 4 files changed, 251 insertions(+), 1 deletion(-) create mode 100644 target/linux/ath79/dts/qca9557_fortinet_fap-221-c.dts diff --git a/target/linux/ath79/dts/qca9557_fortinet_fap-221-c.dts b/target/linux/ath79/dts/qca9557_fortinet_fap-221-c.dts new file mode 100644 index 0000000000..69b6af2609 --- /dev/null +++ b/target/linux/ath79/dts/qca9557_fortinet_fap-221-c.dts @@ -0,0 +1,231 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT + +#include "qca955x.dtsi" + +#include +#include +#include +#include + +/ { + compatible = "fortinet,fap-221-c", "qca,qca9557"; + model = "Fortinet FAP-221-C"; + + aliases { + led-boot = &led_power; + led-failsafe = &led_power; + led-running = &led_power; + led-upgrade = &led_power; + }; + + chosen { + bootargs = "console=ttyS0,9600"; + }; + + keys { + compatible = "gpio-keys"; + + reset { + label = "reset"; + gpios = <&gpio 17 GPIO_ACTIVE_LOW>; + debounce-interval = <60>; + linux,code = ; + }; + }; + + leds { + compatible = "gpio-leds"; + pinctrl-names = "default"; + pinctrl-0 = <&enable_gpio_2_3 &jtag_disable_pins>; + + led_power: power_green { + function = LED_FUNCTION_POWER; + color = ; + gpios = <&gpio 22 GPIO_ACTIVE_LOW>; + default-state = "on"; + }; + + wifi1_green { + function = LED_FUNCTION_WLAN_2GHZ; + color = ; + gpios = <&gpio 13 GPIO_ACTIVE_LOW>; + linux,default-trigger = "phy1tpt"; + }; + + wifi1_amber { + function = LED_FUNCTION_WLAN_2GHZ; + color = ; + gpios = <&gpio 23 GPIO_ACTIVE_LOW>; + }; + + wifi2_green { + function = LED_FUNCTION_WLAN_5GHZ; + color = ; + gpios = <&gpio 2 GPIO_ACTIVE_LOW>; + linux,default-trigger = "phy0tpt"; + }; + + wifi2_amber { + function = LED_FUNCTION_WLAN_5GHZ; + color = ; + gpios = <&gpio 3 GPIO_ACTIVE_LOW>; + }; + + warning_green { + function = "warning"; + color = ; + gpios = <&gpio 19 GPIO_ACTIVE_LOW>; + }; + + warning_amber { + function = "warning"; + color = ; + gpios = <&gpio 21 GPIO_ACTIVE_LOW>; + }; + + lan_green { + function = LED_FUNCTION_LAN; + color = ; + gpios = <&gpio 12 GPIO_ACTIVE_LOW>; + }; + }; + + virtual_flash { + compatible = "mtd-concat"; + + devices = <&fwconcat0 &fwconcat1 &fwconcat2>; + + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + partition@0 { + compatible = "openwrt,uimage", "denx,uimage"; + openwrt,ih-magic = <0x73714f4b>; + label = "firmware"; + reg = <0x0 0x0>; + }; + }; + }; +}; + +&pinmux { + enable_gpio_2_3: pinmux_enable_gpio_2_3 { + pinctrl-single,bits = <0x00 0x0 0xffff0000>; + }; +}; + +&spi { + status = "okay"; + + flash@0 { + compatible = "jedec,spi-nor"; + reg = <0>; + spi-max-frequency = <40000000>; + + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + uboot: partition@0 { + label = "u-boot"; + reg = <0x000000 0x040000>; + read-only; + + nvmem-layout { + compatible = "fixed-layout"; + #address-cells = <1>; + #size-cells = <1>; + + macaddr_uboot_3ff80: mac-address@3ff80 { + compatible = "mac-base"; + reg = <0x3ff80 0xc>; + #nvmem-cell-cells = <1>; + }; + }; + }; + + fwconcat0: partition@40000 { + label = "fwconcat0"; + reg = <0x0040000 0x1400000>; + }; + + partition@1440000 { + label = "loader"; + reg = <0x1440000 0x0010000>; + }; + + fwconcat1: partition@145000 { + label = "fwconcat1"; + reg = <0x1450000 0x03f0000>; + }; + + fwconcat2: partition@1840000 { + label = "reserved"; + reg = <0x1840000 0x07b0000>; + }; + + art: partition@1ff0000 { + label = "art"; + reg = <0x1ff0000 0x0010000>; + read-only; + }; + }; + }; +}; + +&mdio0 { + status = "okay"; + + phy5: ethernet-phy@5 { + reg = <5>; + }; +}; + +ð0 { + status = "okay"; + nvmem-cells = <&macaddr_uboot_3ff80 0>; + nvmem-cell-names = "mac-address"; + + phy-handle = <&phy5>; + phy-mode = "rgmii-id"; + + pll-data = <0x82000000 0x80000101 0x80001313>; +}; + +&wmac { + status = "okay"; + + nvmem-cells = <&calibration_wmac>, <&macaddr_uboot_3ff80 1>; + nvmem-cell-names = "calibration", "mac-address"; +}; + +&pcie0 { + status = "okay"; + + wifi@0,0,0 { + compatible = "qcom,ath10k"; + reg = <0x0 0 0 0 0>; + nvmem-cells = <&calibration_pcie>, <&macaddr_uboot_3ff80 2>; + nvmem-cell-names = "calibration", "mac-address"; + }; +}; + +&art { + nvmem-layout { + compatible = "fixed-layout"; + #address-cells = <1>; + #size-cells = <1>; + + calibration_wmac: calibration@1000 { + reg = <0x1000 0x440>; + }; + + calibration_pcie: calibration@5000 { + reg = <0x5000 0x844>; + }; + }; +}; + diff --git a/target/linux/ath79/generic/base-files/etc/board.d/02_network b/target/linux/ath79/generic/base-files/etc/board.d/02_network index 9a9267c8c7..c3de8bed7f 100644 --- a/target/linux/ath79/generic/base-files/etc/board.d/02_network +++ b/target/linux/ath79/generic/base-files/etc/board.d/02_network @@ -50,6 +50,7 @@ ath79_setup_interfaces() extreme-networks,ws-ap3805i|\ fortinet,fap-220-b|\ fortinet,fap-221-b|\ + fortinet,fap-221-c|\ glinet,gl-ar300m-lite|\ glinet,gl-usb150|\ hak5,wifi-pineapple-nano|\ diff --git a/target/linux/ath79/generic/base-files/lib/upgrade/platform.sh b/target/linux/ath79/generic/base-files/lib/upgrade/platform.sh index 0e314dd311..77a80868d2 100644 --- a/target/linux/ath79/generic/base-files/lib/upgrade/platform.sh +++ b/target/linux/ath79/generic/base-files/lib/upgrade/platform.sh @@ -68,7 +68,8 @@ platform_do_upgrade() { platform_do_upgrade_failsafe_datachk "$1" ;; fortinet,fap-220-b|\ - fortinet,fap-221-b) + fortinet,fap-221-b|\ + fortinet,fap-221-c) SKIP_HASH="1" ENV_SCRIPT="/dev/null" IMAGE_LIST="tar tzf $1" diff --git a/target/linux/ath79/image/generic.mk b/target/linux/ath79/image/generic.mk index f9547e9567..7f0a7b43de 100644 --- a/target/linux/ath79/image/generic.mk +++ b/target/linux/ath79/image/generic.mk @@ -1669,6 +1669,23 @@ define Device/fortinet_fap-221-b endef TARGET_DEVICES += fortinet_fap-221-b +define Device/fortinet_fap-221-c + $(Device/senao_loader_okli) + SOC := qca9557 + DEVICE_VENDOR := Fortinet + DEVICE_MODEL := FAP-221-C + FACTORY_IMG_NAME := FP221C-9.99-AP-build999-999999-patch99 + DEVICE_PACKAGES := ath10k-firmware-qca988x-ct kmod-ath10k-ct + IMAGE_SIZE := 20480k + LOADER_FLASH_OFFS := 0x040000 + IMAGE/factory.bin := append-kernel | pad-to $$$$(BLOCKSIZE) | \ + append-rootfs | pad-rootfs | \ + check-size | pad-to $$$$(IMAGE_SIZE) | \ + append-loader-okli-uimage $(1) | pad-to 11520k | \ + gzip-filename $$$$(FACTORY_IMG_NAME) +endef +TARGET_DEVICES += fortinet_fap-221-c + define Device/glinet_6408 $(Device/tplink-8mlzma) SOC := ar9331 From 5d266b55ed4c4c4efe2e150b8b2326bb13bb6fb0 Mon Sep 17 00:00:00 2001 From: Coia Prant Date: Mon, 17 Feb 2025 14:22:59 +0800 Subject: [PATCH 6/7] mac80211: rt2x00: load the eeprom data from devicetree embedded data on Ralink SoCs It will allow loading eeprom from eeprom-data embedded in device tree. Ported from mediatek mt76 wireless driver (drivers/net/wireless/mediatek/mt76/eeprom.c) Signed-off-by: Coia Prant Link: https://github.com/openwrt/openwrt/pull/17472 Signed-off-by: Hauke Mehrtens --- ...EEPROM-from-devicetree-embedded-data.patch | 76 +++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 package/kernel/mac80211/patches/rt2x00/603-wifi-rt2x00-Add-support-for-loading-EEPROM-from-devicetree-embedded-data.patch diff --git a/package/kernel/mac80211/patches/rt2x00/603-wifi-rt2x00-Add-support-for-loading-EEPROM-from-devicetree-embedded-data.patch b/package/kernel/mac80211/patches/rt2x00/603-wifi-rt2x00-Add-support-for-loading-EEPROM-from-devicetree-embedded-data.patch new file mode 100644 index 0000000000..0ef946a6cb --- /dev/null +++ b/package/kernel/mac80211/patches/rt2x00/603-wifi-rt2x00-Add-support-for-loading-EEPROM-from-devicetree-embedded-data.patch @@ -0,0 +1,76 @@ +From adf957124a115bdf3e4728e1ea8c70a632648cf0 Mon Sep 17 00:00:00 2001 +From: Coia Prant +Date: Fri, 14 Feb 2025 15:49:55 +0800 +Subject: [PATCH] wifi: rt2x00: Add support for loading EEPROM from devicetree + embedded data + +This patch allows rt2x00 to load eeprom from devicetree embedded data. + +Example: + +/* load eeprom from embedded data 'eeprom-data' */ +&wmac { + ralink,eeprom-data = <0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff>; +}; + +Signed-off-by: Coia Prant +--- + .../net/wireless/ralink/rt2x00/rt2x00eeprom.c | 25 +++++++++++++++++++ + 1 file changed, 25 insertions(+) + +--- a/drivers/net/wireless/ralink/rt2x00/rt2x00eeprom.c ++++ b/drivers/net/wireless/ralink/rt2x00/rt2x00eeprom.c +@@ -33,6 +33,27 @@ static void rt2800lib_eeprom_swap(struct + rt2x00dev->eeprom[i] = swab16(rt2x00dev->eeprom[i]); + } + ++static int rt2800lib_read_eeprom_data(struct rt2x00_dev *rt2x00dev) ++{ ++ struct device_node *np = rt2x00dev->dev->of_node; ++ unsigned int len = rt2x00dev->ops->eeprom_size; ++ const void *data; ++ int size; ++ ++ data = of_get_property(np, "ralink,eeprom-data", &size); ++ if (!data) ++ return -ENOENT; ++ ++ if (size != len) { ++ dev_err(rt2x00dev->dev, "invalid eeprom size, required: 0x%04x\n", len); ++ return -EINVAL; ++ } ++ ++ memcpy(rt2x00dev->eeprom, data, size); ++ ++ return 0; ++} ++ + #if IS_ENABLED(CONFIG_MTD) + static int rt2800lib_read_eeprom_mtd(struct rt2x00_dev *rt2x00dev) + { +@@ -193,6 +214,10 @@ int rt2x00lib_read_eeprom(struct rt2x00_ + { + int ret; + ++ ret = rt2800lib_read_eeprom_data(rt2x00dev); ++ if (!ret) ++ return 0; ++ + #if IS_ENABLED(CONFIG_MTD) + ret = rt2800lib_read_eeprom_mtd(rt2x00dev); + if (!ret) From 6a1bdcf545eec8f9ed5130e7f5794fca6ee54cb3 Mon Sep 17 00:00:00 2001 From: Coia Prant Date: Sat, 4 Jan 2025 02:43:17 +0800 Subject: [PATCH 7/7] ramips: add support for Hongdian H8922 v30 This is an industrial 4G router equipped with OpenWrt 14.07 OEM customized version WARNING: The original firmware device tree is common to multiple boards, and the device tree name is H9350. This submitted device tree is a modified version, which deletes the non-this-device parts and adds GPIO watchdog. Specification: - SoC: MediaTek MT7620A - Flash: 16 MB - RAM: 128 MB - Power: DC 5V-36V 1.5A - Ethernet: 1x WAN, 4x LAN (10/100 Mbps) - Wireless radio: 802.11n 2.4g-only - LED: System/Power (RUN): GPIO/26 active-low Ethernet: 1x WAN, 4x LAN Modem 1: GPIO/66 active-low RF 1 (Modem 1 Signal): GPIO/67 active-low Modem 2: GPIO 71 active-low RF 2 (Modem 2 Signal): GPIO/24 active-low WLAN: GPIO/72 active-low WPS: GPIO/12 active-low - Button: WPS / RESET: GPIO/34 active-low - UART: 1x UART on PCB - 115200 8N1 - GPIO Watchdog: GPIO/62 mode=toggle timeout=1s - PCIe: 2x miniPCIe for modem - SIM Slots: 2x SIM Slots Issue: - No factory partition, eeprom is located at /lib/firmware/mt7620a.eeprom Flash instruction: Using UART: 1. Configure PC with a static IP address and setup an TFTP server. 2. Put rootfs into the tftp directory. 3. Connect the UART line as described on the PCB. 4. Power up the device and press Ctrl+C to break auto boot. 5. Use `system 6` command and follow the instruction to set device and tftp server IP address and input the rootfs file name. U-boot will then load the rootfs and write it into the flash. 6. Use `system 1` command and follow the instruction to set device and tftp server IP address and input the firmware file name. U-boot will then load the firmware once. 7. Login to LuCI and use LuCI upgrade firmware. Original Firmware Dump / More details: https://blog.gov.cooking/archives/research-hongdian-h8922-and-flash.html Signed-off-by: Coia Prant Tested-by: Coia Prant Link: https://github.com/openwrt/openwrt/pull/17472 Signed-off-by: Hauke Mehrtens --- package/boot/uboot-envtools/files/ramips | 1 + .../ramips/dts/mt7620a_hongdian_h8922-v30.dts | 189 ++++++++++++++++++ target/linux/ramips/image/mt7620.mk | 12 ++ .../mt7620/base-files/etc/board.d/02_network | 1 + 4 files changed, 203 insertions(+) create mode 100644 target/linux/ramips/dts/mt7620a_hongdian_h8922-v30.dts diff --git a/package/boot/uboot-envtools/files/ramips b/package/boot/uboot-envtools/files/ramips index ace29907da..c1633e2cac 100644 --- a/package/boot/uboot-envtools/files/ramips +++ b/package/boot/uboot-envtools/files/ramips @@ -19,6 +19,7 @@ alfa-network,r36m-e4g|\ alfa-network,tube-e4g|\ engenius,epg600|\ engenius,esr600h|\ +hongdian,h8922-v30|\ linksys,re7000|\ meig,slt866|\ sitecom,wlr-4100-v1-002|\ diff --git a/target/linux/ramips/dts/mt7620a_hongdian_h8922-v30.dts b/target/linux/ramips/dts/mt7620a_hongdian_h8922-v30.dts new file mode 100644 index 0000000000..d983f5f854 --- /dev/null +++ b/target/linux/ramips/dts/mt7620a_hongdian_h8922-v30.dts @@ -0,0 +1,189 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT + +#include "mt7620a.dtsi" + +#include +#include +#include + +/ { + compatible = "hongdian,h8922-v30", "ralink,mt7620a-soc"; + model = "Hongdian H8922 v30"; + + aliases { + led-boot = &led_sys; + led-failsafe = &led_sys; + led-running = &led_sys; + led-upgrade = &led_sys; + }; + + chosen { + bootargs = "console=ttyS0,115200"; + }; + + leds { + compatible = "gpio-leds"; + + led-wps { + gpios = <&gpio0 12 GPIO_ACTIVE_LOW>; + color = ; + function = LED_FUNCTION_WPS; + }; + + led-rf-2 { + gpios = <&gpio1 0 GPIO_ACTIVE_LOW>; + color = ; + function = "rf"; + function-enumerator = <2>; + }; + + led_sys: led-sys { + gpios = <&gpio1 2 GPIO_ACTIVE_LOW>; + color = ; + function = LED_FUNCTION_POWER; + default-state = "on"; + }; + + led-net-1 { + gpios = <&gpio2 26 GPIO_ACTIVE_LOW>; + color = ; + function = LED_FUNCTION_MOBILE; + function-enumerator = <1>; + }; + + led-rf-1 { + gpios = <&gpio2 27 GPIO_ACTIVE_LOW>; + color = ; + function = "rf"; + function-enumerator = <1>; + }; + + led-net-2 { + gpios = <&gpio2 31 GPIO_ACTIVE_LOW>; + color = ; + function = LED_FUNCTION_MOBILE; + function-enumerator = <2>; + }; + + led-wlan { + gpios = <&gpio3 0 GPIO_ACTIVE_LOW>; + color = ; + function = LED_FUNCTION_WLAN; + linux,default-trigger = "phy0tpt"; + }; + }; + + keys { + compatible = "gpio-keys"; + + reset { + label = "reset"; + gpios = <&gpio1 10 GPIO_ACTIVE_LOW>; + linux,code = ; + }; + }; + + watchdog { + compatible = "linux,wdt-gpio"; + + gpios = <&gpio2 22 GPIO_ACTIVE_HIGH>; + hw_algo = "toggle"; + hw_margin_ms = <600>; + always-running; + }; +}; + +&watchdog { + status = "disabled"; +}; + +&gpio1 { + status = "okay"; +}; + +&gpio2 { + status = "okay"; +}; + +&gpio3 { + status = "okay"; +}; + +&spi0 { + status = "okay"; + + flash@0 { + compatible = "jedec,spi-nor"; + reg = <0>; + spi-max-frequency = <50000000>; + + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + partition@0 { + label = "u-boot"; + reg = <0x0 0x2f000>; + read-only; + }; + + partition@2f000 { + label = "u-boot-env"; + reg = <0x2f000 0x1000>; + read-only; + }; + + partition@30000 { + compatible = "denx,uimage"; + label = "firmware"; + reg = <0x30000 0xffd000>; + }; + }; + }; +}; + +&state_default { + gpio { + groups = "wled", "rgmii1", "rgmii2"; + function = "gpio"; + }; +}; + +ðernet { + pinctrl-names = "default"; + pinctrl-0 = <&ephy_pins>; + + mediatek,portmap = "llllw"; +}; + +&pcie { + status = "okay"; +}; + +&wmac { + ralink,eeprom-data = <0x20760501 0x000c4376 0x2058ffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0x000c4376 0x2077000c 0x43762066 0x220c0000 0xffffb701 0x5577a8aa + 0x8c88ffff 0x0a000000 0x00000000 0x0000ffff 0xffff0a0a 0x0a0a0808 0x08080808 0x08080808 + 0x0e0e0e0e 0x0e0e0e0e 0x0e0e0e0e 0x0e0e80ff 0xffff80ff 0xffff0000 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0x20ffffff 0xffffffff 0xffffffff 0xffff0606 + 0x06060402 0x06060400 0x06060400 0x07070400 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff + 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff>; +}; + +&ehci { + status = "okay"; +}; + +&ohci { + status = "okay"; +}; diff --git a/target/linux/ramips/image/mt7620.mk b/target/linux/ramips/image/mt7620.mk index f12f13d9e9..a21473311e 100644 --- a/target/linux/ramips/image/mt7620.mk +++ b/target/linux/ramips/image/mt7620.mk @@ -604,6 +604,18 @@ define Device/hnet_c108 endef TARGET_DEVICES += hnet_c108 +define Device/hongdian_h8922-v30 + SOC := mt7620a + IMAGE_SIZE := 15808k + DEVICE_VENDOR := Hongdian + DEVICE_MODEL := H8922 + DEVICE_VARIANT := v30 + DEVICE_PACKAGES := kmod-usb2 kmod-usb-ohci kmod-usb-net-qmi-wwan kmod-usb-serial-option uqmi uboot-envtools + IMAGES += rootfs.bin + IMAGE/rootfs.bin := append-rootfs | check-size 10560k +endef +TARGET_DEVICES += hongdian_h8922-v30 + define Device/humax_e2 SOC := mt7620a IMAGE_SIZE := 7744k diff --git a/target/linux/ramips/mt7620/base-files/etc/board.d/02_network b/target/linux/ramips/mt7620/base-files/etc/board.d/02_network index 204a1b0a54..57db30b923 100644 --- a/target/linux/ramips/mt7620/base-files/etc/board.d/02_network +++ b/target/linux/ramips/mt7620/base-files/etc/board.d/02_network @@ -15,6 +15,7 @@ ramips_setup_interfaces() dlink,dwr-921-c1|\ dlink,dwr-922-e2|\ dovado,tiny-ac|\ + hongdian,h8922-v30|\ ohyeah,oy-0001|\ phicomm,psg1208|\ planex,db-wrt01|\