diff options
author | Petr Štetiar <ynezz@true.cz> | 2019-05-13 16:42:41 +0200 |
---|---|---|
committer | Petr Štetiar <ynezz@true.cz> | 2019-05-20 21:19:48 +0200 |
commit | 2f1a11d0089c9d4b675b0e1e8806e1e8e3be5a02 (patch) | |
tree | bfa8a83542d1a674b1f0ecb285716df9551f4467 /target | |
parent | 049748e87e329313635cc7f7cc858a6c44eaf4f1 (diff) | |
download | upstream-2f1a11d0089c9d4b675b0e1e8806e1e8e3be5a02.tar.gz upstream-2f1a11d0089c9d4b675b0e1e8806e1e8e3be5a02.tar.bz2 upstream-2f1a11d0089c9d4b675b0e1e8806e1e8e3be5a02.zip |
imx6: apalis: fix config survival after sysupgrade -n
This patch fixes `sysupgrade -n` when flashed with rootfs of the same
size as currently running, so the rootfs_data wouldn't get destroyed and
thus survive reboot. So let's fix it by always cleaning up the content
of the rootfs_data during sysupgrade.
Signed-off-by: Petr Štetiar <ynezz@true.cz>
Diffstat (limited to 'target')
-rwxr-xr-x | target/linux/imx6/base-files/lib/upgrade/platform.sh | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/target/linux/imx6/base-files/lib/upgrade/platform.sh b/target/linux/imx6/base-files/lib/upgrade/platform.sh index 2d76b6b4af..c3be9d5424 100755 --- a/target/linux/imx6/base-files/lib/upgrade/platform.sh +++ b/target/linux/imx6/base-files/lib/upgrade/platform.sh @@ -72,3 +72,16 @@ platform_copy_config() { ;; esac } + +platform_pre_upgrade() { + local board=$(board_name) + + case "$board" in + apalis*) + [ "$SAVE_CONFIG" -eq 0 ] && { + jffs2reset -y + umount /overlay + } + ;; + esac +} |