gluon/patches/lede/0014-procd-clean-up-trailing-whitespace-in-nand.sh.patch
Matthias Schiffer 52d28c1140
Backport staged sysupgrade patches
The staged sysupgrade allows to properly unmount the rootfs before writing
the new partitions. This will fix upgrades losing configuration when
parition sizes change on x86 and similar image types.
2017-05-30 07:31:37 +02:00

29 lines
1.0 KiB
Diff

From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Wed, 3 May 2017 08:27:40 +0200
Subject: procd: clean up trailing whitespace in nand.sh
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
diff --git a/package/system/procd/files/nand.sh b/package/system/procd/files/nand.sh
index ebaaf2aa16009cc1431dbb79ba9f689c8b636069..8a164ee08537014936a8608f5a60fe0e27dcabd6 100644
--- a/package/system/procd/files/nand.sh
+++ b/package/system/procd/files/nand.sh
@@ -194,7 +194,7 @@ nand_upgrade_prepare_ubi() {
nand_do_upgrade_success() {
local conf_tar="/tmp/sysupgrade.tgz"
-
+
sync
[ -f "$conf_tar" ] && nand_restore_config "$conf_tar"
echo "sysupgrade successful"
@@ -231,7 +231,7 @@ nand_upgrade_ubifs() {
local rootfs_length=`(cat $1 | wc -c) 2> /dev/null`
nand_upgrade_prepare_ubi "$rootfs_length" "ubifs" "0" "0"
-
+
local ubidev="$( nand_find_ubi "$CI_UBIPART" )"
local root_ubivol="$(nand_find_volume $ubidev rootfs)"
ubiupdatevol /dev/$root_ubivol -s $rootfs_length $1