[OpenWrt-Devel] [PATCH 2/2] base-files: fix sysupgrade for Netgear WNDR4300

Michal Cieslakiewicz michal.cieslakiewicz at wp.pl
Fri Oct 11 05:18:45 EDT 2019


This patch provides correct flashing via sysupgrade for Netgear
WNDR4300 router with NAND flash memory. Without this fix
upgrade process is not aware of UBI layer and corrupts volume
data putting router in Firmware Recovery mode.

Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz at wp.pl>
---
 target/linux/ath79/base-files/lib/upgrade/platform.sh | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/target/linux/ath79/base-files/lib/upgrade/platform.sh b/target/linux/ath79/base-files/lib/upgrade/platform.sh
index f4fca06384..fb1bf607f8 100644
--- a/target/linux/ath79/base-files/lib/upgrade/platform.sh
+++ b/target/linux/ath79/base-files/lib/upgrade/platform.sh
@@ -2,6 +2,8 @@
 # Copyright (C) 2011 OpenWrt.org
 #
 
+. /lib/upgrade/nand.sh
+
 PART_NAME=firmware
 REQUIRE_IMAGE_METADATA=1
 
@@ -51,6 +53,9 @@ platform_do_upgrade() {
 	ubnt,routerstation-pro)
 		redboot_fis_do_upgrade "$1" kernel
 		;;
+	netgear,wndr4300)
+		nand_do_upgrade "$1"
+		;;
 	*)
 		default_do_upgrade "$1"
 		;;
-- 
2.23.0


_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel



More information about the openwrt-devel mailing list