This will prevent error message that pop up when the serial port is not present --- This seems quite hacky to me, but we have an issue where if we remove a serial port from the device tree the serial port won't work.
It seems link it's still in /dev/ttySN but it's not configured properly. I looked for udev rules and items in /proc and /sys to try to use but I did not see anything... Is there a better approach than this? .../sysvinit/sysvinit-inittab_2.88dsf.bb | 19 ++++++++++++++++++- 1 files changed, 18 insertions(+), 1 deletions(-) diff --git a/meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb b/meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb index 3a716d7..3031442 100644 --- a/meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb +++ b/meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb @@ -2,7 +2,7 @@ DESCRIPTION = "Inittab for sysvinit" LICENSE = "GPLv2" LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe" -PR = "r6" +PR = "r7" SRC_URI = "file://COPYING \ file://inittab" @@ -56,6 +56,23 @@ EOF fi } +pkg_postinst_${PN} () { +# run this on the target +if [ "x$D" == "x" ]; then + tmp="${SERIAL_CONSOLES}" + for i in $tmp + do + j=`echo ${i} | sed s/^.*\;//g` + if [ -z "`dmesg | grep ${j}`" ]; then + sed -i /^.*${j}$/d /etc/inittab + fi + done + kill -HUP 1 +fi + +exit 1 +} + # USE_VT and SERIAL_CONSOLE are generally defined by the MACHINE .conf. # Set PACKAGE_ARCH appropriately. PACKAGE_ARCH = "${MACHINE_ARCH}" -- 1.7.6.1 _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core