[oe-commits] [openembedded-core] 32/51: sysvinit-inittab_2.88dsf.bb: Allow aliasing with SERIAL_CONSOLES_CHECK

git at git.openembedded.org git at git.openembedded.org
Wed Aug 10 09:47:57 UTC 2016


rpurdie pushed a commit to branch master
in repository openembedded-core.

commit 91d9f3271c12fb755ab332637b17650d5fe75ce2
Author: California Sullivan <california.l.sullivan at intel.com>
AuthorDate: Wed Aug 3 19:36:36 2016 -0700

    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 at intel.com>
    Signed-off-by: Ross Burton <ross.burton at intel.com>
---
 meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb | 7 +++++--
 1 file 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 bdc3416..f136ad8 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

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list