Skip to content

Commit

Permalink
qualcommax: ipq807x: Add ability to perform upgrade on current partit…
Browse files Browse the repository at this point in the history
…ion for MX4200/MX5300/MX8500

Dual firmware devices like Linksys MX4200, MX5300 and MX8500 use separate rootfs partition.
This option helps to keep all configuration during upgrade.

Signed-off-by: Paweł Owoc <[email protected]>
  • Loading branch information
testuser7 authored and qosmio committed Nov 14, 2024
1 parent 00877f7 commit f842f09
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions target/linux/qualcommax/ipq807x/base-files/lib/upgrade/platform.sh
Original file line number Diff line number Diff line change
Expand Up @@ -176,13 +176,19 @@ platform_do_upgrade() {
linksys,mx5300|\
linksys,mx8500)
boot_part="$(fw_printenv -n boot_part)"
if [ "$boot_part" -eq "1" ]; then
fw_setenv boot_part 2
CI_KERNPART="alt_kernel"
CI_UBIPART="alt_rootfs"
if [ -n "$UPGRADE_OPT_CURR_PARTITION" ]; then
if [ "$boot_part" -eq "2" ]; then
CI_KERNPART="alt_kernel"
CI_UBIPART="alt_rootfs"
fi
else
fw_setenv boot_part 1
CI_UBIPART="rootfs"
if [ "$boot_part" -eq "1" ]; then
fw_setenv boot_part 2
CI_KERNPART="alt_kernel"
CI_UBIPART="alt_rootfs"
else
fw_setenv boot_part 1
fi
fi
fw_setenv boot_part_ready 3
fw_setenv auto_recovery yes
Expand Down

0 comments on commit f842f09

Please sign in to comment.