From 8bac5dc18a139e13338956e83d8dc4948824a82f Mon Sep 17 00:00:00 2001 From: Furong Xu Date: Thu, 22 Dec 2022 10:40:26 +0800 Subject: mediatek: add new layout for Xiaomi Redmi Router AX6000 for OpenWrt U-Boot This new layout is only bootable with OpenWrt U-Boot. It reuses the two crash partions and expands the ubi partion to the end of whole flash. Do not use this layout with stock U-Boot! Signed-off-by: Furong Xu --- target/linux/mediatek/filogic/base-files/etc/board.d/01_leds | 3 ++- target/linux/mediatek/filogic/base-files/etc/board.d/02_network | 6 ++++-- target/linux/mediatek/filogic/base-files/lib/upgrade/platform.sh | 4 ++++ 3 files changed, 10 insertions(+), 3 deletions(-) (limited to 'target/linux/mediatek/filogic') diff --git a/target/linux/mediatek/filogic/base-files/etc/board.d/01_leds b/target/linux/mediatek/filogic/base-files/etc/board.d/01_leds index 8cfed15544..d85b12fb66 100644 --- a/target/linux/mediatek/filogic/base-files/etc/board.d/01_leds +++ b/target/linux/mediatek/filogic/base-files/etc/board.d/01_leds @@ -7,7 +7,8 @@ board_config_update case $board in xiaomi,redmi-router-ax6000|\ -xiaomi,redmi-router-ax6000-stock) +xiaomi,redmi-router-ax6000-stock|\ +xiaomi,redmi-router-ax6000-ubootmod) ucidef_set_led_netdev "wan" "wan" "rgb:network" "wan" ;; esac diff --git a/target/linux/mediatek/filogic/base-files/etc/board.d/02_network b/target/linux/mediatek/filogic/base-files/etc/board.d/02_network index 1c98dcc7cb..608161f0ad 100644 --- a/target/linux/mediatek/filogic/base-files/etc/board.d/02_network +++ b/target/linux/mediatek/filogic/base-files/etc/board.d/02_network @@ -17,7 +17,8 @@ mediatek_setup_interfaces() ucidef_set_interface_macaddr "wan" "$(macaddr_add $(cat /sys/class/net/eth0/address) 1)" ;; xiaomi,redmi-router-ax6000|\ - xiaomi,redmi-router-ax6000-stock) + xiaomi,redmi-router-ax6000-stock|\ + xiaomi,redmi-router-ax6000-ubootmod) ucidef_set_interfaces_lan_wan "lan2 lan3 lan4" wan ;; *) @@ -35,7 +36,8 @@ mediatek_setup_macs() case $board in xiaomi,redmi-router-ax6000|\ - xiaomi,redmi-router-ax6000-stock) + xiaomi,redmi-router-ax6000-stock|\ + xiaomi,redmi-router-ax6000-ubootmod) wan_mac=$(mtd_get_mac_ascii Bdata ethaddr_wan) label_mac=$wan_mac ;; diff --git a/target/linux/mediatek/filogic/base-files/lib/upgrade/platform.sh b/target/linux/mediatek/filogic/base-files/lib/upgrade/platform.sh index 29c7a1475e..c2808bc736 100755 --- a/target/linux/mediatek/filogic/base-files/lib/upgrade/platform.sh +++ b/target/linux/mediatek/filogic/base-files/lib/upgrade/platform.sh @@ -64,6 +64,10 @@ platform_do_upgrade() { CI_ROOT_UBIPART=ubi nand_do_upgrade "$1" ;; + xiaomi,redmi-router-ax6000-ubootmod) + CI_KERNPART="fit" + nand_do_upgrade "$1" + ;; *) nand_do_upgrade "$1" ;; -- cgit v1.2.3