aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/x86/base-files/lib
diff options
context:
space:
mode:
authorDaniel Golle <daniel@makrotopia.org>2017-05-05 05:56:10 +0200
committerDaniel Golle <daniel@makrotopia.org>2017-05-05 07:12:47 +0200
commit63571cb56c7ff2692b5c9aa78133c3f4996e2ac5 (patch)
tree933985a444fb951ca2c866d05767ea38a281df19 /target/linux/x86/base-files/lib
parent7296767639b511ab96ca2847ffad84dd4c37452d (diff)
downloadupstream-63571cb56c7ff2692b5c9aa78133c3f4996e2ac5.tar.gz
upstream-63571cb56c7ff2692b5c9aa78133c3f4996e2ac5.tar.bz2
upstream-63571cb56c7ff2692b5c9aa78133c3f4996e2ac5.zip
x86: keep /boot mounted for kexec
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Diffstat (limited to 'target/linux/x86/base-files/lib')
-rw-r--r--target/linux/x86/base-files/lib/preinit/79_move_config11
1 files changed, 7 insertions, 4 deletions
diff --git a/target/linux/x86/base-files/lib/preinit/79_move_config b/target/linux/x86/base-files/lib/preinit/79_move_config
index 143ca5147b..7b34d9e5da 100644
--- a/target/linux/x86/base-files/lib/preinit/79_move_config
+++ b/target/linux/x86/base-files/lib/preinit/79_move_config
@@ -7,11 +7,14 @@ move_config() {
. /lib/upgrade/common.sh
if export_bootdevice && export_partdevice partdev 1; then
- if mount -t ext4 -o rw,noatime "/dev/$partdev" /mnt; then
- if [ -f /mnt/sysupgrade.tgz ]; then
- mv -f /mnt/sysupgrade.tgz /
+ mkdir -p /boot
+ if mount -t ext4 -o ro,noatime "/dev/$partdev" /boot; then
+ if [ -f /boot/sysupgrade.tgz ]; then
+ mount /boot -o remount,rw,noatime
+ mv -f /boot/sysupgrade.tgz /
+ mount /boot -o remount,ro,noatime
fi
- umount /mnt
+ mount --bind /boot/boot /boot
fi
fi
}