From 66c060fbb2fada1e9a1b1cb9d7327d47874c939d Mon Sep 17 00:00:00 2001 From: John Klug Date: Thu, 8 Jun 2023 11:32:56 -0500 Subject: Fix mlinux-firmware-upgrade to use U-Boot flags to erase user data --- recipes-core/mlinux-scripts/mlinux-scripts/mlinux-firmware-upgrade | 5 ++--- recipes-core/mlinux-scripts/mlinux-scripts_%.bbappend | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/recipes-core/mlinux-scripts/mlinux-scripts/mlinux-firmware-upgrade b/recipes-core/mlinux-scripts/mlinux-scripts/mlinux-firmware-upgrade index 5568357..f39facf 100755 --- a/recipes-core/mlinux-scripts/mlinux-scripts/mlinux-firmware-upgrade +++ b/recipes-core/mlinux-scripts/mlinux-scripts/mlinux-firmware-upgrade @@ -1,6 +1,5 @@ #!/bin/bash -PERSISTENT_DIR="/var/persistent/" -ERASE_PERSISTENT="${PERSISTENT_DIR}/mts_do_erase_persistent" +ERASE_PERSISTENT="u-boot setenv erase_persistent_f 1" dofile=/var/volatile/do_flash_upgrade dofactoryreset=0 id=$(id -u) @@ -122,7 +121,7 @@ if (( $tobeflashed )); then sleep 1 poweroff else - ((KEEP_PERSISTENT)) || touch "$ERASE_PERSISTENT" + ((KEEP_PERSISTENT)) || $ERASE_PERSISTENT logger -s -t firmware_upgrade "Rebooting" sleep 1 reboot diff --git a/recipes-core/mlinux-scripts/mlinux-scripts_%.bbappend b/recipes-core/mlinux-scripts/mlinux-scripts_%.bbappend index f91edbd..2c0aaa5 100644 --- a/recipes-core/mlinux-scripts/mlinux-scripts_%.bbappend +++ b/recipes-core/mlinux-scripts/mlinux-scripts_%.bbappend @@ -1,6 +1,6 @@ FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" -PR .= ".mlinux2" +PR .= ".mlinux3" SRC_URI += " \ file://mlinux-firmware-upgrade \ -- cgit v1.2.3