From: Mateusz Moscicki Date: Mon, 25 Jul 2022 12:50:27 +0000 (+0200) Subject: Mount hal partition as read-only X-Git-Tag: submit/tizen/20220725.143901~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d10a98ab38d7afbdeba979a31e938dbefdb2c68b;p=platform%2Fcore%2Fsystem%2Finitrd-fota.git Mount hal partition as read-only We don't want the data on this partition to change so that it can be upgraded with DELTA_IMAGE upgrade. Change-Id: I87487d345e48f0545361924ecc69788ade462649 --- diff --git a/scripts/fota-init.sh b/scripts/fota-init.sh index e49de49..61cf618 100755 --- a/scripts/fota-init.sh +++ b/scripts/fota-init.sh @@ -241,14 +241,14 @@ mount_partitions() { return 1 fi fi - if [ "${P_SUFFIX}" == "" ]; then - if [ ! "z${PART_HAL}" = "z" ]; then + if [ ! "z${PART_HAL}" = "z" ]; then + if [ "${P_SUFFIX}" == "" ]; then if ! mount_checkpoint_partition hal "${PART_HAL}" "${FAKE_ROOT}/${HAL_MNT}"; then return 1 fi + else + "$MOUNT" -o ro "${PART_HAL}" "${FAKE_ROOT}/${HAL_MNT}" fi - else - "$MOUNT" "${PART_HAL}" "${FAKE_ROOT}/${HAL_MNT}" fi "$MOUNT" -t proc none "${FAKE_ROOT}/proc"