79_move_config 358 B

123456789101112131415161718
  1. #!/bin/sh
  2. # Copyright (C) 2015 OpenWrt.org
  3. BOOTPART=/dev/mmcblk0p1
  4. move_config() {
  5. if [ -b $BOOTPART ]; then
  6. insmod nls_cp437
  7. insmod nls_iso8859-1
  8. insmod fat
  9. insmod vfat
  10. mkdir -p /boot
  11. mount -t vfat -o rw,noatime $BOOTPART /boot
  12. [ -f /boot/sysupgrade.tgz ] && mv -f /boot/sysupgrade.tgz /
  13. fi
  14. }
  15. boot_hook_add preinit_mount_root move_config