aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xusr/captivatemtd_initramfs_files/init8
-rwxr-xr-xusr/fascinatemtd_initramfs_files/init9
-rwxr-xr-xusr/galaxysbmtd_initramfs_files/init8
-rwxr-xr-xusr/galaxysmtd_initramfs_files/init8
-rwxr-xr-xusr/vibrantmtd_initramfs_files/init8
5 files changed, 26 insertions, 15 deletions
diff --git a/usr/captivatemtd_initramfs_files/init b/usr/captivatemtd_initramfs_files/init
index feb03f6..5d0a655 100755
--- a/usr/captivatemtd_initramfs_files/init
+++ b/usr/captivatemtd_initramfs_files/init
@@ -17,9 +17,11 @@ load_offset=$boot_offset
load_len=$boot_len
busybox mount -t yaffs2 /dev/block/mtdblock2 /system
+busybox mount -t yaffs2 /dev/block/mtdblock3 /cache
-if busybox grep -q bootmode=2 /proc/cmdline ; then
+if busybox test -e /cache/.startrecovery || busybox grep -q bootmode=2 /proc/cmdline ; then
# recovery boot
+ busybox rm -fr /cache/.startrecovery
load_offset=$recovery_offset
load_len=$recovery_len
@@ -27,6 +29,7 @@ if busybox grep -q bootmode=2 /proc/cmdline ; then
busybox echo 0 > /sys/class/power_supply/battery/charging_mode_booting
elif ! busybox test -e /system/build.prop ; then
# emergency boot
+ busybox umount /cache
erase_image cache
busybox mount -t yaffs2 /dev/block/mtdblock3 /cache
busybox mkdir /cache/recovery
@@ -39,8 +42,6 @@ elif ! busybox test -e /system/build.prop ; then
busybox echo "install_zip(\"`echo $UPDATE`\");" > /cache/recovery/extendedcommand
fi
- busybox umount /cache
-
load_offset=$recovery_offset
load_len=$recovery_len
@@ -48,6 +49,7 @@ elif ! busybox test -e /system/build.prop ; then
busybox echo 0 > /sys/class/power_supply/battery/charging_mode_booting
fi
+busybox umount /cache
busybox umount /system
busybox umount /sdcard
busybox rmdir /sdcard
diff --git a/usr/fascinatemtd_initramfs_files/init b/usr/fascinatemtd_initramfs_files/init
index 4d35c3e..ae94eab 100755
--- a/usr/fascinatemtd_initramfs_files/init
+++ b/usr/fascinatemtd_initramfs_files/init
@@ -17,9 +17,12 @@ load_offset=$boot_offset
load_len=$boot_len
busybox mount -t yaffs2 /dev/block/mtdblock2 /system
+busybox mount -t yaffs2 /dev/block/mtdblock3 /cache
-if busybox grep -q bootmode=2 /proc/cmdline ; then
+if busybox test -e /cache/.startrecovery || \
+ busybox grep -q bootmode=2 /proc/cmdline ; then
# recovery boot
+ busybox rm -fr /cache/.startrecovery
load_offset=$recovery_offset
load_len=$recovery_len
@@ -28,6 +31,7 @@ if busybox grep -q bootmode=2 /proc/cmdline ; then
busybox echo 0 > /sys/class/power_supply/battery/charging_mode_booting
elif ! busybox test -e /system/build.prop ; then
# emergency boot
+ busybox umount /cache
erase_image cache
busybox mount -t yaffs2 /dev/block/mtdblock3 /cache
busybox mkdir /cache/recovery
@@ -40,8 +44,6 @@ elif ! busybox test -e /system/build.prop ; then
busybox echo "install_zip(\"`echo $UPDATE`\");" > /cache/recovery/extendedcommand
fi
- busybox umount /cache
-
load_offset=$recovery_offset
load_len=$recovery_len
@@ -49,6 +51,7 @@ elif ! busybox test -e /system/build.prop ; then
busybox echo 0 > /sys/class/power_supply/battery/charging_mode_booting
fi
+busybox umount /cache
busybox umount /system
busybox umount /sdcard
busybox rmdir /sdcard
diff --git a/usr/galaxysbmtd_initramfs_files/init b/usr/galaxysbmtd_initramfs_files/init
index feb03f6..5d0a655 100755
--- a/usr/galaxysbmtd_initramfs_files/init
+++ b/usr/galaxysbmtd_initramfs_files/init
@@ -17,9 +17,11 @@ load_offset=$boot_offset
load_len=$boot_len
busybox mount -t yaffs2 /dev/block/mtdblock2 /system
+busybox mount -t yaffs2 /dev/block/mtdblock3 /cache
-if busybox grep -q bootmode=2 /proc/cmdline ; then
+if busybox test -e /cache/.startrecovery || busybox grep -q bootmode=2 /proc/cmdline ; then
# recovery boot
+ busybox rm -fr /cache/.startrecovery
load_offset=$recovery_offset
load_len=$recovery_len
@@ -27,6 +29,7 @@ if busybox grep -q bootmode=2 /proc/cmdline ; then
busybox echo 0 > /sys/class/power_supply/battery/charging_mode_booting
elif ! busybox test -e /system/build.prop ; then
# emergency boot
+ busybox umount /cache
erase_image cache
busybox mount -t yaffs2 /dev/block/mtdblock3 /cache
busybox mkdir /cache/recovery
@@ -39,8 +42,6 @@ elif ! busybox test -e /system/build.prop ; then
busybox echo "install_zip(\"`echo $UPDATE`\");" > /cache/recovery/extendedcommand
fi
- busybox umount /cache
-
load_offset=$recovery_offset
load_len=$recovery_len
@@ -48,6 +49,7 @@ elif ! busybox test -e /system/build.prop ; then
busybox echo 0 > /sys/class/power_supply/battery/charging_mode_booting
fi
+busybox umount /cache
busybox umount /system
busybox umount /sdcard
busybox rmdir /sdcard
diff --git a/usr/galaxysmtd_initramfs_files/init b/usr/galaxysmtd_initramfs_files/init
index feb03f6..5d0a655 100755
--- a/usr/galaxysmtd_initramfs_files/init
+++ b/usr/galaxysmtd_initramfs_files/init
@@ -17,9 +17,11 @@ load_offset=$boot_offset
load_len=$boot_len
busybox mount -t yaffs2 /dev/block/mtdblock2 /system
+busybox mount -t yaffs2 /dev/block/mtdblock3 /cache
-if busybox grep -q bootmode=2 /proc/cmdline ; then
+if busybox test -e /cache/.startrecovery || busybox grep -q bootmode=2 /proc/cmdline ; then
# recovery boot
+ busybox rm -fr /cache/.startrecovery
load_offset=$recovery_offset
load_len=$recovery_len
@@ -27,6 +29,7 @@ if busybox grep -q bootmode=2 /proc/cmdline ; then
busybox echo 0 > /sys/class/power_supply/battery/charging_mode_booting
elif ! busybox test -e /system/build.prop ; then
# emergency boot
+ busybox umount /cache
erase_image cache
busybox mount -t yaffs2 /dev/block/mtdblock3 /cache
busybox mkdir /cache/recovery
@@ -39,8 +42,6 @@ elif ! busybox test -e /system/build.prop ; then
busybox echo "install_zip(\"`echo $UPDATE`\");" > /cache/recovery/extendedcommand
fi
- busybox umount /cache
-
load_offset=$recovery_offset
load_len=$recovery_len
@@ -48,6 +49,7 @@ elif ! busybox test -e /system/build.prop ; then
busybox echo 0 > /sys/class/power_supply/battery/charging_mode_booting
fi
+busybox umount /cache
busybox umount /system
busybox umount /sdcard
busybox rmdir /sdcard
diff --git a/usr/vibrantmtd_initramfs_files/init b/usr/vibrantmtd_initramfs_files/init
index feb03f6..5d0a655 100755
--- a/usr/vibrantmtd_initramfs_files/init
+++ b/usr/vibrantmtd_initramfs_files/init
@@ -17,9 +17,11 @@ load_offset=$boot_offset
load_len=$boot_len
busybox mount -t yaffs2 /dev/block/mtdblock2 /system
+busybox mount -t yaffs2 /dev/block/mtdblock3 /cache
-if busybox grep -q bootmode=2 /proc/cmdline ; then
+if busybox test -e /cache/.startrecovery || busybox grep -q bootmode=2 /proc/cmdline ; then
# recovery boot
+ busybox rm -fr /cache/.startrecovery
load_offset=$recovery_offset
load_len=$recovery_len
@@ -27,6 +29,7 @@ if busybox grep -q bootmode=2 /proc/cmdline ; then
busybox echo 0 > /sys/class/power_supply/battery/charging_mode_booting
elif ! busybox test -e /system/build.prop ; then
# emergency boot
+ busybox umount /cache
erase_image cache
busybox mount -t yaffs2 /dev/block/mtdblock3 /cache
busybox mkdir /cache/recovery
@@ -39,8 +42,6 @@ elif ! busybox test -e /system/build.prop ; then
busybox echo "install_zip(\"`echo $UPDATE`\");" > /cache/recovery/extendedcommand
fi
- busybox umount /cache
-
load_offset=$recovery_offset
load_len=$recovery_len
@@ -48,6 +49,7 @@ elif ! busybox test -e /system/build.prop ; then
busybox echo 0 > /sys/class/power_supply/battery/charging_mode_booting
fi
+busybox umount /cache
busybox umount /system
busybox umount /sdcard
busybox rmdir /sdcard