summaryrefslogtreecommitdiff
path: root/meta/recipes-core
diff options
context:
space:
mode:
authorCalifornia Sullivan <california.l.sullivan@intel.com>2016-08-03 19:36:36 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-08-10 10:45:32 +0100
commit91d9f3271c12fb755ab332637b17650d5fe75ce2 (patch)
tree93d700c4b0f4e162e33ebe3c61dcbe3232fea2d7 /meta/recipes-core
parentf9faa8df85317d12743134a44576b4882a9fb22a (diff)
downloadopenembedded-core-91d9f3271c12fb755ab332637b17650d5fe75ce2.tar.gz
openembedded-core-91d9f3271c12fb755ab332637b17650d5fe75ce2.tar.bz2
openembedded-core-91d9f3271c12fb755ab332637b17650d5fe75ce2.zip
sysvinit-inittab_2.88dsf.bb: Allow aliasing with SERIAL_CONSOLES_CHECK
With some hardware the name of the device node and the name in /proc/console differ. This causes SERIAL_CONSOLES_CHECK to not enable working consoles in these cases. This patch changes SERIAL_CONSOLES_CHECK to have an optional alias for the checked consoles. The new format is: <device>:<alias to check(optional)> Fixes [YOCTO #9440]. Signed-off-by: California Sullivan <california.l.sullivan@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/recipes-core')
-rw-r--r--meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb7
1 files changed, 5 insertions, 2 deletions
diff --git a/meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb b/meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb
index bdc3416aa9..f136ad821b 100644
--- a/meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb
+++ b/meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb
@@ -58,9 +58,12 @@ if [ "x$D" = "x" ] && [ -e /proc/consoles ]; then
tmp="${SERIAL_CONSOLES_CHECK}"
for i in $tmp
do
- j=`echo ${i} | sed s/^.*\;//g`
+ j=`echo ${i} | sed -e s/^.*\;//g -e s/\:.*//g`
+ k=`echo ${i} | sed s/^.*\://g`
if [ -z "`grep ${j} /proc/consoles`" ]; then
- sed -i /^.*${j}$/d /etc/inittab
+ if [ -z "${k}" ] || [ -z "`grep ${k} /proc/consoles`" ] || [ ! -e /dev/${j} ]; then
+ sed -i /^.*${j}$/d /etc/inittab
+ fi
fi
done
kill -HUP 1