Commit c4922c7b authored by Dalton Durst's avatar Dalton Durst

Merge branch 'flag-file' into 'master'

Check a flag file to decide whether to boot into recovery

See merge request !4
parents b81994a8 d4422364
......@@ -24,6 +24,7 @@ $SCRIPT/ ${TMPDOWN}/linux-image-*-pine64_*.deb ${HERE}/initrd.i
$SCRIPT/ ${TMP}/system
$SCRIPT/ ${TMP}/system
$SCRIPT/ uboot ${TMP}/partitions/
$SCRIPT/ uboot ${TMP}/partitions/
cp ${TMPDOWN}/u-boot-sunxi-with-spl-pinephone.bin ${TMP}/partitions/loader.img
cp recovery-pinephone.img ${TMP}/partitions/recovery.img
set -xe
truncate --size 500K persist.img
mkfs.ext2 persist.img
mv persist.img $OUT
echo "done"
cache /cache ext4 defaults
boot_a /boot ext4 defaults
persist /persist ext4 defaults
# White
gpio set 114; gpio set 115; gpio set 116
setenv bootargs console=tty0 console=${console} systempart=/dev/mmcblk0p9
setenv bootargs console=${console} systempart=/dev/mmcblk${devnum}p9 devnum=${devnum}
setenv kernel_addr_z 0x44080000
echo "[UBPORTS] Bootargs are" ${bootargs}
echo "[UBPORTS] Beginning load"
if test "${volume_key}" = "up"; then
if test "${volume_key}" = "up" -o -e ${devtype} ${devnum}:3 reboot-recovery; then
# recovery-a partition
setenv partnum 6
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment