At this moment layerscape images are ext4 only. It causes problem with save changes durring sysupgrade and make "firstboot" and failsafe mode useless. This patch changes sd-card images to squashfs + f2fs combined images. To make place, for saving config, kernel space ar now ext4 partition with fit kernel. This method of image generation is similar to rest of OpenWrt sd-card targets. Reviewed-by: Yangbo Lu <yangbo.lu@nxp.com> Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com> [reword README, reword DEVICE_COMPAT_MESSAGE, keep original indent] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
26 lines
540 B
Text
26 lines
540 B
Text
. /lib/functions.sh
|
|
. /lib/upgrade/common.sh
|
|
|
|
BOOTPART=/dev/mmcblk0p1
|
|
|
|
move_config() {
|
|
local board=$(board_name)
|
|
|
|
case "$board" in
|
|
fsl,ls1012a-frwy-sdboot | \
|
|
fsl,ls1021a-iot-sdboot | \
|
|
fsl,ls1021a-twr-sdboot | \
|
|
fsl,ls1043a-rdb-sdboot | \
|
|
fsl,ls1046a-rdb-sdboot | \
|
|
fsl,ls1088a-rdb-sdboot)
|
|
if [ -b $BOOTPART ]; then
|
|
mkdir -p /boot
|
|
mount -t ext4 -o rw,noatime $BOOTPART /boot 2>&1
|
|
[ -f "/boot/$BACKUP_FILE" ] && mv -f "/boot/$BACKUP_FILE" /
|
|
umount /boot
|
|
fi
|
|
;;
|
|
esac
|
|
}
|
|
|
|
boot_hook_add preinit_mount_root move_config
|