openmoko-session2: add RDEPENDS openmoko-panel-memory and oe-stylize
[vuplus_openembedded] / packages / initrdscripts / files / 87-kexecboot.sh
1 #!/bin/sh
2 # Allow kexecing to kernel in rootfs
3
4 if [ -n "$BOOT_ROOT" -a -f "$BOOT_ROOT/boot/zImage" ]; then
5     if ! expr "$CMDLINE" : '.*nokexec'; then
6         echo "Kernel found in rootfs:"
7         ls -l "$BOOT_ROOT/boot/zImage"
8         initramfs=""
9         if [ -f "$BOOT_ROOT/boot/initramfs.bin" ]; then
10             echo "Initramfs found in rootfs:"
11             ls -l "$BOOT_ROOT/boot/initramfs.bin"
12             initramfs="--initrd=$BOOT_ROOT/boot/initramfs.bin"
13         fi
14         echo /usr/sbin/kexec -f "$BOOT_ROOT/boot/zImage" $initramfs --command-line="$CMDLINE nokexec"
15         sleep 10
16         /usr/sbin/kexec -f "$BOOT_ROOT/boot/zImage" $initramfs --command-line="$CMDLINE nokexec"
17         sleep 10000
18     fi
19 fi