[oe-commits] Bruce Ashfield : kernel-yocto: fix kernel configuration audit for custom yocto kernels

git at git.openembedded.org git at git.openembedded.org
Fri Sep 14 08:57:07 UTC 2012


Module: openembedded-core.git
Branch: master
Commit: 4d1b7dae063ee4c35c426306d0e22f11ce112c72
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=4d1b7dae063ee4c35c426306d0e22f11ce112c72

Author: Bruce Ashfield <bruce.ashfield at windriver.com>
Date:   Thu Sep 13 08:59:08 2012 -0400

kernel-yocto: fix kernel configuration audit for custom yocto kernels

It was reported that the kernel configuration checks for custom yocto
kernels had the following output:

  NOTE: validating kernel configuration
  grep: /meta-series: No such file or directory
  grep: /meta-series: No such file or directory
  WARNING: Can't find any BSP hardware or required configuration fragments.
  WARNING: Looked at //cfg///hdw_frags.txt and //cfg///required_frags.txt in directory: //cfg//
  NOTE: Tasks Summary: Attempted 375 tasks of which 367 didn't need to be rerun and all succeeded.

which is not inspire confidence in the output of the process.

Completely inhibiting the check is one option to remove the messages,
but that removes the ability see output, which can help move users to
a better or more fully configured linux-yocto based kernel.

To fix this, we have to ensure that the path to the meta-series is
always valid, and that the tools can deal with not all files existing
in the audit directory.

Since custom yocto kernels do not set KMETA (they don't have a meta branch),
we ensure that a default of 'meta' is passed to the audit ('meta' is always
valid), and that kconf_check itself can deal with an incomplete set of
input audit files.

The net result is output like this (using a defconfig with invalid options
for the kernel being built):

  NOTE: validating kernel configuration
  This BSP sets 19 invalid/obsolete kernel options.
  These config options are not offered anywhere within this kernel.
  The full list can be found in your kernel src dir at:
  meta/cfg/standard/qemux86/invalid.cfg

  There were 1 instances of config fragment errors.
  The full list can be found in your kernel src dir at:
  meta/cfg/standard/qemux86/fragment_errors.txt

  The full list can be found in your kernel src dir at:
  meta/cfg/standard/qemux86/missing_required.cfg

Signed-off-by: Bruce Ashfield <bruce.ashfield at windriver.com>
Signed-off-by: Saul Wold <sgw at linux.intel.com>

---

 meta/classes/kernel-yocto.bbclass                  |    7 ++++++-
 .../kern-tools/kern-tools-native_git.bb            |    2 +-
 2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/meta/classes/kernel-yocto.bbclass b/meta/classes/kernel-yocto.bbclass
index 724e5cd..f78d63b 100644
--- a/meta/classes/kernel-yocto.bbclass
+++ b/meta/classes/kernel-yocto.bbclass
@@ -212,8 +212,13 @@ python do_kernel_configcheck() {
 
     bb.plain("NOTE: validating kernel configuration")
 
+    # if KMETA isn't set globally by a recipe using this routine, we need to
+    # set the default to 'meta'. Otherwise, kconf_check is not passed a valid
+    # meta-series for processing
+    kmeta = d.getVar( "KMETA", True ) or "meta"
+
     pathprefix = "export PATH=%s:%s; " % (d.getVar('PATH', True), "${S}/scripts/util/")
-    cmd = d.expand("cd ${S}; kconf_check -config- ${KMETA}/meta-series ${S} ${B}")
+    cmd = d.expand("cd ${S}; kconf_check -config- %s/meta-series ${S} ${B}" % kmeta)
     ret, result = commands.getstatusoutput("%s%s" % (pathprefix, cmd))
 
     bb.plain( "%s" % result )
diff --git a/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb b/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
index e8926ee..1381fd1 100644
--- a/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
+++ b/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
@@ -4,7 +4,7 @@ LIC_FILES_CHKSUM = "file://git/tools/kgit;beginline=5;endline=9;md5=d8d1d729a70c
 
 DEPENDS = "git-native guilt-native"
 
-SRCREV = "0c7b625280eb9ff62d40b53308e7238ddd164f38"
+SRCREV = "a04138a02644eada0d012196e5ac3db4f516114d"
 PR = "r12"
 PV = "0.1+git${SRCPV}"
 





More information about the Openembedded-commits mailing list