diff options
author | Jonas Gorski <jonas.gorski@gmail.com> | 2016-09-26 12:02:40 +0200 |
---|---|---|
committer | Jonas Gorski <jonas.gorski@gmail.com> | 2016-09-26 13:04:53 +0200 |
commit | 6859098d97aaa4e60a795f5887911958ca134ed0 (patch) | |
tree | 408a95b82c94b1679023a9e6d2d8275b356b50aa /target/linux/mvebu/base-files/lib/preinit | |
parent | c359d7e81bd0f73bd3931abf5d87589a97cc37df (diff) | |
download | upstream-6859098d97aaa4e60a795f5887911958ca134ed0.tar.gz upstream-6859098d97aaa4e60a795f5887911958ca134ed0.tar.bz2 upstream-6859098d97aaa4e60a795f5887911958ca134ed0.zip |
mvebu: add sysupgrade support for clearfog
Add and enable sysupgrade support for clearfog boards, based on how the
brcm2708 target does it.
Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
Acked-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'target/linux/mvebu/base-files/lib/preinit')
-rw-r--r-- | target/linux/mvebu/base-files/lib/preinit/79_move_config | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/target/linux/mvebu/base-files/lib/preinit/79_move_config b/target/linux/mvebu/base-files/lib/preinit/79_move_config new file mode 100644 index 0000000000..b0ee62a809 --- /dev/null +++ b/target/linux/mvebu/base-files/lib/preinit/79_move_config @@ -0,0 +1,18 @@ +#!/bin/sh +# Copyright (C) 2015 OpenWrt.org + +BOOTPART=/dev/mmcblk0p1 + +move_config() { + if [ -b $BOOTPART ]; then + insmod nls_cp437 + insmod nls_iso8859-1 + insmod fat + insmod vfat + mkdir -p /boot + mount -t vfat -o rw,noatime $BOOTPART /boot + [ -f /boot/sysupgrade.tgz ] && mv -f /boot/sysupgrade.tgz / + fi +} + +boot_hook_add preinit_mount_root move_config |