From 167c998efc5ba755bafc1aca1bf68d9e694e4c10 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Sat, 8 May 2021 11:30:32 +0200 Subject: [PATCH] ath79: various fixes * free up additional 1MB rootfs space * make the target use bridge-vlan * use the single eth port as wan Signed-off-by: John Crispin --- target/linux/ath79/dts/ar9344_tplink_cpe.dtsi | 20 ++++++++----------- .../generic/base-files/etc/board.d/02_network | 3 ++- tools/firmware-utils/src/tplink-safeloader.c | 4 ++-- 3 files changed, 12 insertions(+), 15 deletions(-) diff --git a/target/linux/ath79/dts/ar9344_tplink_cpe.dtsi b/target/linux/ath79/dts/ar9344_tplink_cpe.dtsi index d4b7de440a..c5ab963174 100644 --- a/target/linux/ath79/dts/ar9344_tplink_cpe.dtsi +++ b/target/linux/ath79/dts/ar9344_tplink_cpe.dtsi @@ -59,20 +59,16 @@ partition@40000 { label = "firmware"; reg = <0x040000 0x780000>; + }; - compatible = "fixed-partitions"; - #address-cells = <1>; - #size-cells = <1>; - - partition@0 { - label = "kernel"; - reg = <0x000000 0x300000>; - }; + partition@040000 { + label = "kernel"; + reg = <0x040000 0x210000>; + }; - partition@300000 { - label = "rootfs"; - reg = <0x300000 0x480000>; - }; + partition@340000 { + label = "rootfs"; + reg = <0x250000 0x560000>; }; partition@7c0000 { 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 1e522b91c6..b8bc38348e 100755 --- a/target/linux/ath79/generic/base-files/etc/board.d/02_network +++ b/target/linux/ath79/generic/base-files/etc/board.d/02_network @@ -94,7 +94,7 @@ ath79_setup_interfaces() ubnt,unifi|\ wd,mynet-wifi-rangeextender|\ winchannel,wb2000) - ucidef_set_interface_lan "eth0" + ucidef_set_interface_wan "eth0" ;; airtight,c-75) ucidef_add_switch "switch0" \ @@ -669,6 +669,7 @@ ath79_setup_macs() board_config_update board=$(board_name) +ucidef_set_bridge_device bridge ath79_setup_interfaces $board ath79_setup_macs $board board_config_flush diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c index ac71b3305e..2bc4a3cb82 100644 --- a/tools/firmware-utils/src/tplink-safeloader.c +++ b/tools/firmware-utils/src/tplink-safeloader.c @@ -443,8 +443,8 @@ static struct device_info boards[] = { {"default-mac", 0x30000, 0x00020}, {"product-info", 0x31100, 0x00100}, {"signature", 0x32000, 0x00400}, - {"os-image", 0x40000, 0x300000}, - {"file-system", 0x340000, 0x470000}, + {"os-image", 0x40000, 0x210000}, + {"file-system", 0x250000, 0x560000}, {"soft-version", 0x7b0000, 0x00100}, {"support-list", 0x7b1000, 0x00400}, {"user-config", 0x7c0000, 0x10000}, -- 2.25.1