initrd: Spawn an emergency shell when something goes wrong
authorDamien Lespiau <damien.lespiau@intel.com>
Thu, 27 Sep 2012 14:20:50 +0000 (15:20 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 28 Sep 2012 10:07:40 +0000 (11:07 +0100)
commit2ca8bba5991934e797643fca2b997aa25a20e882
tree9a10d14adbd54bdeaba1f13eea9366b9c56bbd07
parent4d583c956b3699c97ea4747b1cab87b7fc94532a
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>
meta/recipes-core/initrdscripts/files/init-live.sh