Bug 3206

Summary: all BSP images are failing to boot
Product: [Build System, Metadata & Runtime] BSPs Reporter: Nitin Kamble <nitin.a.kamble>
Component: bsps-meta-intelAssignee: Nitin Kamble <nitin.a.kamble>
Status: VERIFIED FIXED QA Contact:
Severity: critical    
Priority: High CC: corneliux.stoicescu, sgw, tom.zanussi
Version: unspecified   
Target Milestone: 1.3 M5   
Hardware: All   
OS: Multiple   
Whiteboard: Understand the issue now, working on fix
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: ---

Description Nitin Kamble 2012-10-02 15:50:41 UTC
All the BSP images are failing with these error messages:

Bug in initramfs /init detected. Dropping to a shell. Good luck!

sh: cannot set terminal process group (-1): Inappropriate ioctl for device
sh: no job control in this shell




I have found the reason: this commit in the master:

commit ffb6928f5783e5202d9849c3a185e29be1d41c63
Author: Damien Lespiau <damien.lespiau@intel.com>
Date:   Thu Sep 27 15:20:50 2012 +0100

    initrd: Spawn an emergency shell when something goes wrong
    
    set -e allows to exit if a command fails. We install a trap and execute
    emergency_shell() when either the init script exits or when ctrl-c is
    typed (say if we are stuck somewhere and we want to debug it).
    
    (From OE-Core rev: ae5e2bd994e3f60d3803ab56e6ed34d08fbc56f0)
    
    Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
    Signed-off-by: Ross Burton <ross.burton@intel.com>
    Signed-off-by: Saul Wold <sgw@linux.intel.com>
    Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>

diff --git a/meta/recipes-core/initrdscripts/files/init-live.sh b/meta/recipes-core/initrdscripts/files/init-live.sh
index 3fba7dc..fb7af31 100644
--- a/meta/recipes-core/initrdscripts/files/init-live.sh
+++ b/meta/recipes-core/initrdscripts/files/init-live.sh
@@ -2,6 +2,17 @@
 
 PATH=/sbin:/bin:/usr/sbin:/usr/bin
 
+emergency_shell()
+{
+    echo "Bug in initramfs /init detected. Dropping to a shell. Good luck!"
+    echo
+    sh
+}
+trap "emergency_shell" 0 2
+
+# exit immediately if a command fails
+set -e
+
 ROOT_MOUNT="/rootfs/"
 ROOT_IMAGE="rootfs.img"
 MOUNT="/bin/mount"





And now I and Tom are working on to fix this issue.
Comment 1 Saul Wold 2012-10-02 20:25:46 UTC
I thought this was resolved by RP's reverting the orignal patch?
Comment 2 Tom Zanussi 2012-10-02 20:28:19 UTC
I was able to get a good emenlow boot by reverting the patch, so yes, that should mean this can be closed.
Comment 3 Stoicescu Cornel 2012-10-08 08:58:17 UTC
Verified in: 86c9aa8081f107420cd3763d0566d779daddc2b1

The folowing BSPs are confirmed to boot: n450, jasperforest, crownbay, emelow, FRI2, crownbay.