aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
...
* mediatek: update pending SoC Ethernet PHY driverDaniel Golle2023-05-23
| | | | | | | Update driver for MediaTek's built-in Gigabit Ethernet PHYs which can be found in the MT7981 and MT7988 SoCs. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* generic: mt7530: backport support for the MT7988 built-in switchDaniel Golle2023-05-23
| | | | | | | | | | | | | | | | Backport commits adding support for the MT7988 built-in switch to the mt7530 driver. This change results in the Kconfig symbol NET_DSA_MT7530 to be extended by NET_DSA_MT7530_MDIO (everything formally covered by NET_DSA_MT7530) and NET_DSA_MT7530_MMIO (a new driver for the MMIO-connected built-in switch of the MT7988 SoC). Select NET_DSA_MT7530_MDIO for all targets previously selecting NET_DSA_MT7530, with the exception of mediatek/filogic which also selects NET_DSA_MT7530_MMIO. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* generic: add support for MediaTek NETSYS v3Daniel Golle2023-05-23
| | | | | | | In order to support Ethernet on the MT7988 SoC add support for NETSYS v3 as well as new paths and USXGMII SerDes to the mtk_eth_soc driver. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mediatek: add mt7988 pinctrl driver supportSam Shih2023-05-23
| | | | | | | This adds provisional pinctrl driver support for the MediaTek MT7988 SoC. Signed-off-by: Sam Shih <sam.shih@mediatek.com> Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mediatek: add mt7988 clock drivers supportSam Shih2023-05-23
| | | | | | | This adds clock drivers for the MediaTek MT7988 SoC Signed-off-by: Sam Shih <sam.shih@mediatek.com> Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mediatek: mt7981: setup all clocks needed for eMMCDaniel Golle2023-05-23
| | | | | | | Setup all necessary clocks to get MMC to work on MT7981, similar to how it is done also on MT7986. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mediatek: mt7981: usb enable 3.0 by defaultChukun Pan2023-05-23
| | | | | | | There is no reason to limit USB to 2.0 mode by default, delete this limit. Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
* kernel: enable (ARM|ARM64)_MODULE_PLTS in generic configTony Ambardar2023-05-23
| | | | | | | | | | | | | | | | | | | This allows loading modules with large memory requirements, recently needed while testing on armvirt/32. Past forum discussions [1] and bug reports [2] also raised this and the ipq806x target already set it in response [3]. Given this increases kernel image size by only ~1KB, is generally useful on multi-platform kernels, and enabled by default on upstream arm32 Linux, add it to the generic config. The setting has similar utility on arm64, is a requirement for KASLR, and already enabled on most OpenWrt aarch64 targets, so pull this into the top-level generic config. [1]: https://forum.openwrt.org/t/vmap-allocation-for-size-442368-failed-use-vmalloc-size-to-increase-size/34545/7 [2]: https://github.com/openwrt/openwrt/issues/8282 [3]: f81e148eb6 ("ipq806x: update 4.19 kernel config"). Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
* Revert "feeds: use git-src-full to allow Git versioning"Petr Štetiar2023-05-23
| | | | | | | | | This partially reverts commit 7fae1e5677e9bb4979c8d4ac99be4de6955b13d0 as it should be no longer necessary to do a full clone since commit 48ed07bc0b94 ("treewide: replace AUTORELEASE with real PKG_RELEASE"). Suggested-by: Thibaut VARÈNE <hacks@slashdirt.org> Signed-off-by: Petr Štetiar <ynezz@true.cz>
* kernel: add disabled symbol CONFIG_CPU_LITTLE_ENDIAN on 6.1Aleksander Jan Bajkowski2023-05-23
| | | | | | | The identical change was previously added to the 5.15 kernel in the commit 9226f1e41948 ("kernel: disable CONFIG_CPU_LITTLE_ENDIAN in generic config"). Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
* kernel: sort generic configurationAleksander Jan Bajkowski2023-05-23
| | | | | | | | | | | | This was done by executing these commands: $ ./scripts/kconfig.pl '+' target/linux/generic/config-5.15 /dev/null > target/linux/generic/config-5.15-new $ mv target/linux/generic/config-5.15-new target/linux/generic/config-5.15 $ ./scripts/kconfig.pl '+' target/linux/generic/config-6.1 /dev/null > target/linux/generic/config-6.1-new $ mv target/linux/generic/config-6.1-new target/linux/generic/config-6.1 Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
* mac80211: backport merged version of A-MSDU mesh patchRobert Marko2023-05-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Kernel 6.1 now has fortify_memcpy_chk() and it is causing the following warning while trying to compile backports: CC [M] /home/robimarko/Building/AX3600/ipq807x-5.15/build_dir/target-aarch64_cortex-a53_musl/linux-ipq807x_generic/backports-6.1.24/net/wireless/util.o In file included from ./include/linux/string.h:253, from /home/robimarko/Building/AX3600/ipq807x-5.15/build_dir/target-aarch64_cortex-a53_musl/linux-ipq807x_generic/backports-6.1.24/backport-include/linux/string.h:3, from ./include/linux/bitmap.h:11, from ./include/linux/cpumask.h:12, from ./include/linux/smp.h:13, from ./arch/arm64/include/asm/arch_timer.h:18, from ./arch/arm64/include/asm/timex.h:8, from ./include/linux/timex.h:67, from ./include/linux/time32.h:13, from ./include/linux/time.h:60, from /home/robimarko/Building/AX3600/ipq807x-5.15/build_dir/target-aarch64_cortex-a53_musl/linux-ipq807x_generic/backports-6.1.24/backport-include/linux/time.h:3, from ./include/linux/skbuff.h:15, from /home/robimarko/Building/AX3600/ipq807x-5.15/build_dir/target-aarch64_cortex-a53_musl/linux-ipq807x_generic/backports-6.1.24/backport-include/linux/skbuff.h:3, from ./include/linux/if_ether.h:19, from /home/robimarko/Building/AX3600/ipq807x-5.15/build_dir/target-aarch64_cortex-a53_musl/linux-ipq807x_generic/backports-6.1.24/backport-include/linux/if_ether.h:3, from ./include/linux/etherdevice.h:20, from /home/robimarko/Building/AX3600/ipq807x-5.15/build_dir/target-aarch64_cortex-a53_musl/linux-ipq807x_generic/backports-6.1.24/backport-include/linux/etherdevice.h:3, from /home/robimarko/Building/AX3600/ipq807x-5.15/build_dir/target-aarch64_cortex-a53_musl/linux-ipq807x_generic/backports-6.1.24/net/wireless/util.c:12: In function 'fortify_memcpy_chk', inlined from 'ieee80211_strip_8023_mesh_hdr' at /home/robimarko/Building/AX3600/ipq807x-5.15/build_dir/target-aarch64_cortex-a53_musl/linux-ipq807x_generic/backports-6.1.24/net/wireless/util.c:590:3: ./include/linux/fortify-string.h:404:25: error: call to '__write_overflow_field' declared with attribute warning: detected write beyond size of field (1st parameter); maybe use struct_group()? [-Werror=attribute-warning] 404 | __write_overflow_field(p_size_field, size); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ cc1: all warnings being treated as errors This issue was fixed in the final version of ("wifi: mac80211: fix receiving A-MSDU frames on mesh interfaces") that was merged upstream but we have a older version that is using: memcpy(&payload.eth.h_dest, mesh_addr, 2 * ETH_ALEN); instead of: memcpy(&payload.eth, mesh_addr, 2 * ETH_ALEN); So, lets just backport the merged version of patch to fix the issue. Signed-off-by: Robert Marko <robimarko@gmail.com>
* mediatek: mt7623: build SD card without all filesystemsDaniel Golle2023-05-22
| | | | | | | | Allow building SD card images without having both initramfs and squashfs present on the card, just like it has already been done for the mt7622 and filogic subtargets. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* ipq806x: enable testing kernel version with 6.1 versionChristian Marangi2023-05-22
| | | | | | Enable testing kernel version with 6.1 kernel version. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq806x: 6.1: refresh config and add missing symbolsChristian Marangi2023-05-22
| | | | | | | | | Refresh config for kernel 6.1 and add missing symbols Then sorted using: $ ./scripts/kconfig.pl '+' target/linux/ipq806x/config-6.1 /dev/null > target/linux/ipq806x/config-6.1-new $ mv target/linux/ipq806x/config-6.1-new target/linux/ipq806x/config-6.1 Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq806x: 6.1: refresh dtsChristian Marangi2023-05-22
| | | | | | | | Refresh dts for kernel 6.1 support. Changes: - nbg6817 drop amba node and reference directly sdcc1. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq806x: 6.1: refresh kernel patchesChristian Marangi2023-05-22
| | | | | | Refresh ipq806x kernel patches with make target/linux/refresh. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq806x: 6.1: manually refresh kernel patchesChristian Marangi2023-05-22
| | | | | | Refresh kernel patches for version 6.1. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq806x: 6.1: replace ZRELADDR HACK patch with new versionChristian Marangi2023-05-22
| | | | | | | | With 6.1 lots have changed and the platform for Makefile.boot got dropped. Replace the patch with a new version that is alligned to the new implementation. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq806x: 6.1: drop upstream patchChristian Marangi2023-05-22
| | | | | | Drop patch that got merged upstream. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq806x: 6.1: copy patches, files and config from 5.15Christian Marangi2023-05-22
| | | | | | Copy patches, files and config from 5.15 kernel version. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* kernel: modules: fs: adapt for kernel 6.1Robert Marko2023-05-22
| | | | | | | | | | Adapt filesystem kmods for building under kernel 6.1: * Depend on kernel not being 5.10 rather than only 5.15 * kmod-fs-9p depends on kmod-fs-netfs from 5.17 as they started using netfs helpers * Set new KConfig options to N Signed-off-by: Robert Marko <robimarko@gmail.com>
* kernel: modules: wwan: adapt for kernel 6.1Robert Marko2023-05-22
| | | | | | | | | Update the WWAN kmods for compilation under kernel 6.1: * Depend on kernel not being 5.10 rather than only 5.15 * Enable CONFIG_WWAN_DEBUGFS as its now optional from 5.17 * Add missing symbols for new WWAN drivers to generic config Signed-off-by: Robert Marko <robimarko@gmail.com>
* kernel: modules: adapt for kernel 6.1Christian Marangi2023-05-22
| | | | | | Adapt kernel modules to support kernel 6.1. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: kernel: add missing symbolPawel Dembicki2023-05-22
| | | | | | | | Add missing symbol while adding layerscape support Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com> [ add commit description ] Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: add missing symbolsRobert Marko2023-05-22
| | | | | | These symbols got exposed once building for ipq807x. Signed-off-by: Robert Marko <robimarko@gmail.com>
* generic: 6.1: refresh config and add missing symbolsChristian Marangi2023-05-22
| | | | | | | | | Refresh generic config for 6.1 and add missing symbols. Then sorted using: $ ./scripts/kconfig.pl '+' target/linux/generic/config-6.1 /dev/null > target/linux/generic/config-6.1-new $ mv target/linux/generic/config-6.1-new target/linux/generic/config-6.1 Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* kernel: add CONFIG_INITRAMFS_PRESERVE_MTIME config to Initramfs functionChristian Marangi2023-05-22
| | | | | | | New kernel version 6.1 introduced new INITRAMFS option. Add them to the Initramfs functions to correctly compile initramfs images. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* kernel: use eth_random_addr instead of random_ether_addrChristian Marangi2023-05-22
| | | | | | | | | | random_ether_addr is just a reference to eth_random_addr, that was later dropped in more recent kernel version. Drop random_ether_addr and use eth_random_addr directly to fix compilation error in 6.1 Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* kernek: use struct_group to wipe ar8216 volatile priv dataChristian Marangi2023-05-22
| | | | | | | | | Instead of reference vlan and do strange subtraction, use the handy struct_group() to create a virtual struct of the same size of the members. This permits to have a more secure memset and fix compilation warning in 6.1 where additional checks are done. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* kernel: refresh swconfig_leds to handle new trigger lockingChristian Marangi2023-05-22
| | | | | | | Refresh swconfig_leds source to handle new trigger locking that is now a spinlock. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* kernel: refresh IFF_NO_IP_ALIGN ifdef for kernel >= 6.1Christian Marangi2023-05-22
| | | | | | | Kernel 6.1 expanded the priv_flags to long bitmap so update and restore it to priv_flags. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: refresh pending patchesChristian Marangi2023-05-22
| | | | | | Refresh pending patches with make target/linux/refresh. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: refresh hack patchesChristian Marangi2023-05-22
| | | | | | Refresh hack patches with make target/linux/refresh. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: refresh backport patchesChristian Marangi2023-05-22
| | | | | | Refresh backport patches with make target/linux/refresh. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: add pending OPP set opp improvement patchChristian Marangi2023-05-22
| | | | | | | Add pending OPP set opp improvement patch to better handle _set_opp function in clock scaling. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: add patch to compile ieee8211 headersChristian Marangi2023-05-22
| | | | | | | With kernel 6.1 ieee2111_ptr is not compiled by default. Add pending patch to restore this to make backports project compatible. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: manually refresh mglru patch with new kernel versionChristian Marangi2023-05-22
| | | | | | | Refresh mglru patch for new kernel version due to very fun backport changing name from folio to pages. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: manually refresh hack patchesChristian Marangi2023-05-22
| | | | | | Refresh hack patches for kernel 6.1. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: drop pending patch backported as fixesChristian Marangi2023-05-22
| | | | | | Drop pending patch backported as fixes in later kernel version. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: manually refresh pending patchesChristian Marangi2023-05-22
| | | | | | | | | | | Refresh pending patches for kernel 6.1. Changes: - Refresh mtd patches with new implementation. - Change 191-rtc-rs5c372-let_the_alarm_to_be_used_as_wakeup_source as uie_unsupported got dropped and we now set the bit directly. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: manually refresh backport patchesChristian Marangi2023-05-22
| | | | | | Refresh backport patches that still needs to be merged for kernel 6.1. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: 6.1: drop backport patchesChristian Marangi2023-05-22
| | | | | | Drop all backport patches that are now included in kernel 6.1. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* generic: copy backport, hack, pending patch and config from 5.15 to 6.1Christian Marangi2023-05-22
| | | | | | Copy backport, hack, pending patch and config from 5.15 to 6.1. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* kernel: add define for kernel 6.1Christian Marangi2023-05-22
| | | | | | Add define for kernel 6.1. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* busybox: update to 1.36.1Nick Hainke2023-05-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Release Notes: http://lists.busybox.net/pipermail/busybox-cvs/2023-May/041510.html Refresh commands, run after busybox is first built once (nothing changed compared to 1.36.0): cd package/utils/busybox/config/ ../convert_menuconfig.pl ../../../../build_dir/target-mipsel_24kc_musl/busybox-default/busybox-1.36.1 cd .. ./convert_defaults.pl ../../../build_dir/target-mipsel_24kc_musl/busybox-default/busybox-1.36.1/.config > Config-defaults.in Manual edits needed afterward: * Config-defaults.in: OpenWrt config symbol IPV6 logic applied to BUSYBOX_DEFAULT_FEATURE_IPV6 * Config-defaults.in: OpenWrt config TARGET_bcm53xx logic applied to BUSYBOX_DEFAULT_TRUNCATE (commit 547f1ec) * Config-defaults.in: OpenWrt logic applied to BUSYBOX_DEFAULT_LOGIN_SESSION_AS_CHILD (commit dc92917) * Config-defaults.in: correct the default ports that get reset BUSYBOX_DEFAULT_FEATURE_HTTPD_PORT_DEFAULT 80 BUSYBOX_DEFAULT_FEATURE_TELNETD_PORT_DEFAULT 23 * config/editors/Config.in: Add USE_GLIBC dependency to BUSYBOX_CONFIG_FEATURE_VI_REGEX_SEARCH (commit f141090) * config/shell/Config.in: change at "Options common to all shells" the conditional symbol SHELL_ASH --> BUSYBOX_CONFIG_SHELL_ASH (discussion in http://lists.openwrt.org/pipermail/openwrt-devel/2021-January/033140.html Apparently our script does not see the hidden option while prepending config options with "BUSYBOX_CONFIG_" which leads to a missed dependency when the options are later evaluated.) * Edit a few Config.in files by adding quotes to sourced items in config/Config.in, config/networking/Config.in and config/util-linux/Config.in (commit 1da014f) Tested-by: Hannu Nyman <hannu.nyman@iki.fi> Signed-off-by: Nick Hainke <vincent@systemli.org>
* libxml2: update to 2.11.4Nick Hainke2023-05-22
| | | | | | | Release Notes: https://gitlab.gnome.org/GNOME/libxml2/-/releases/v2.11.4 Signed-off-by: Nick Hainke <vincent@systemli.org>
* libcap: update to 2.69Nick Hainke2023-05-22
| | | | | | | | Release Notes: https://sites.google.com/site/fullycapable/release-notes-for-libcap#h.iuvg7sbjg8pe Fixes: CVE-2023-2602 CVE-2023-2603 Signed-off-by: Nick Hainke <vincent@systemli.org>
* lldpd: update to 1.0.17Nick Hainke2023-05-22
| | | | | | | Release Notes: https://github.com/lldpd/lldpd/releases/tag/1.0.17 Signed-off-by: Nick Hainke <vincent@systemli.org>
* mediatek: add support for Zyxel EX5601-T0 routerPietro Ameruoso2023-05-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Zyxel EX5601-T0 specifics -------------- The operator specific firmware running on the Zyxel branded EX5601-T0 includes U-Boot modifications affecting the OpenWrt installation. Partition Table | dev | size | erasesize | name | | ---- | -------- | --------- | ------------- | | mtd0 | 20000000 | 00040000 | "spi0.1" | | mtd1 | 00100000 | 00040000 | "BL2" | | mtd2 | 00080000 | 00040000 | "u-boot-env" | | mtd3 | 00200000 | 00040000 | "Factory" | | mtd4 | 001c0000 | 00040000 | "FIP" | | mtd5 | 00040000 | 00040000 | "zloader" | | mtd6 | 04000000 | 00040000 | "ubi" | | mtd7 | 04000000 | 00040000 | "ubi2" | | mtd8 | 15a80000 | 00040000 | "zyubi" | The router boots BL2 which than loads FIP (u-boot). U-boot has hardcoded a command to always launch Zloader "mtd read zloader 0x46000000" and than "bootm". Bootargs are deactivated. Zloader is the zyxel booloader which allow to dual-boot ubi or ubi2, by default access to zloader is blocked. Too zloader checks that the firmware contains a particolar file called zyfwinfo. Additional details regarding Zloader can be found here: https://hack-gpon.github.io/zyxel/ https://forum.openwrt.org/t/adding-openwrt-support-for-zyxel-ex5601-t0/155914 Hardware -------- SOC: MediaTek MT7986a CPU: 4 core cortex-a53 (2000MHz) RAM: 1GB DDR4 FLASH: 512MB SPI-NAND (Micron xxx) WIFI: Wifi6 Mediatek MT7976 802.11ax 5 GHz 4x4 + 2.4GHZ 4x4 ETH: MediaTek MT7531 Switch + SoC 3 x builtin 1G phy (lan1, lan2, lan3) 1 x MaxLinear GPY211B 2.5 N-Base-T phy5 (lan4) 1 x MaxLinear GPY211B 2.5Gbit xor SFP/N-Base-T phy6 (wan) USB: 1 x USB 3.2 Enhanced SuperSpeed port UART: 3V3 115200 8N1 (Pinout: GND KEY RX TX VCC) VOIP: 2 FXS ports for analog phones MAC Address Table ----------------- eth0/lan Factory 0x002a eth1/wan Factory 0x0024 wifi 2.4Ghz Factory 0x0004 wifi 5Ghz Factory 0x0004 + 1 Serial console (UART) --------------------- +-------+-------+-------+-------+-------+ | +3.3V | RX | TX | KEY | GND | +---+---+-------+-------+-------+-------+ | +--- Don't connect Installation ------------ Keep in mind that openwrt can only run on the UBI partition, the openwrt firmware is not able to understand the zloader bootargs. The procedure allows restoring the UBI partition with the Zyxel firmware and retains all the OEM functionalities. 1. Unlock Zloader (this will allow to swap manually between partitions UBI and UBI2): - Attach a usb-ttl adapter to your computer and boot the router. - While the router is booting at some point you will read the following: `Please press Enter to activate this console.` - As soon as you read that press enter, type root and than press enter again (just do it, don't care about the logs scrolling). - Most likely the router is still printing the boot log, leave it boot until it stops. - If everything went ok you should have full root access "root@EX5601-T0:/#". - Type the following command and press enter: "fw_setenv EngDebugFlag 0x1". - Reboot the router. - As soon as you read `Hit any key to stop autoboot:` press Enter. - If everything went ok you should have the following prompt: "ZHAL>". - You have successfully unlocked zloader access, this procedure must be done only once. 2. Check the current active partition: - Boot the router and repeat the steps above to gain root access. - Type the following command to check the current active image: "cat /proc/cmdline". - If `rootubi=ubi` it means that the active partition is `mtd6` - If `rootubi=ubi2` it means that the active partition is `mtd7` - As mentioned earlier we need to flash openwrt into ubi/mtd6 and never overwrite ubi2/mtd7 to be able to fully roll-back. - To activate and boot from mtd7 (ubi2) enter into ZHAL> command prompt and type the following commands: atbt 1 # unlock write atsw # swap boot partition atsr # reboot the router - After rebooting check again with "cat /proc/cmdline" that you are correctly booting from mtd7/ubi2 - If yes proceed with the installation guide. If not probably you don't have a firmware into ubi2 or you did something wrong. 3. Flashing: - Download the sysupgrade file for the router from openwrt, than we need to add the zyfwinfo file into the sysupgrade tar. Zloader only checks for the magic (which is a fixed value 'EXYZ') and the crc of the file itself (256bytes). I created a script to create a valid zyfwinfo file but you can use anything that does exactly the same: https://raw.githubusercontent.com/pameruoso/OpenWRT-Zyxel-EX5601-T0/main/gen_zyfwinfo.sh - Add the zyfwinfo file into the sysupgrade tar. - Enter via telnet or ssh into the router with admin credentials - Enter the following commands to disable the firmware and model checks "zycli fwidcheck off" and "zycli modelcheck off" - Open the router web interface and in the update firmware page select the "restore default settings option" - Select the sysupgrade file and click on upload. - The router will flash and reboot itself into openwrt from UBI 4. Restoring and going back to Zyxel firmware. - Use the ZHAL> command line to manually swap the boot parition to UBI2 with the following: atbt 1 # unlock write atsw # swap boot partition atsr # reboot the router - You will boot again the Zyxel firmware you have into UBI2 and you can flash the zyxel firmware to overwrite the UBI partition and openwrt. Working features ---------------- 3 gbit lan ports Wifi Zyxel partitioning for coexistance with Zloader and dual boot. WAN SFP port (only after exporting pins 57 and 10. gpiobase411) leds reset button serial interface usb port lan ethernet 2.5 gbit port (autosense) wan ethernet 2.5 gbit port (autosense) Not working ---------------- voip (missing drivers or proper zyxel platform software) Swapping the wan ethernet/sfp xor port ---------------- The way to swap the wan port between sfp and ethernet is the following: export the pins 57 and 10. Pin 57 is used to probe if an sfp is present. If pin 57 value is 0 it means that an sfp is present into the cage (cat /sys/class/gpio/gpio468/value). If pin 57 value is 1 it means that no sfp is inserted into the cage. In conclusion by default both 57 an 10 pins are by default 1, which means that the active port is the ethernet one. After inserting an SFP pin 57 will become 0 and you have to manually change the value of pin 10 to 0 too. This is totally scriptable of course. Leds description ------------ All the leds are working out of the box but the leds managed by the 2 maxlinear phy (phy 5 lan, phy6 wan). To activate the phy5 led (rj45 ethernet port led on the back of the router) you have to use mdio-tools. To activate the phy6 led (led on the front of the router for 2.5gbit link) you have to use mdio-tools. Example: Set lan5 led to fast blink on 2500/1000, slow blink on 10/100: mdio mdio-bus mmd 5:30 raw 0x0001 0x33FC Set wan 2.5gbit led to constant on when wan is 2.5gbit: mdio mdio-bus mmd 6:30 raw 0x0001 0x0080 Signed-off-by: Pietro Ameruoso <p.ameruoso@live.it>