diff options
| author | Jens Rehsack <rehsack@gmail.com> | 2015-11-12 17:13:15 +0100 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-11-24 15:50:27 +0000 |
| commit | a9cc27e6916e5affe8b0cc431c3e89abd7681643 (patch) | |
| tree | 92ddfd51a1820ae00fe197cf703e3e8092d3778f | |
| parent | fecb07755ca6aec978cac19d5cb17fdc888b0057 (diff) | |
| download | poky-a9cc27e6916e5affe8b0cc431c3e89abd7681643.tar.gz | |
kernel: fix race condition between compile_kernelmodules and shared_workdir
Fixes https://bugzilla.yoctoproject.org/show_bug.cgi?id=8127 which causes
[ 1225.089323] 8189es: Unknown symbol cfg80211_scan_done (err -22)
[ 1225.095916] 8189es: no symbol version for cfg80211_remain_on_channel_expired
when loading external compiled 8189es module.
(From OE-Core rev: afcea61e8eb39234d336c706fdfd4680dea7c060)
Signed-off-by: Jens Rehsack <sno@netbsd.org>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/classes/kernel.bbclass | 8 | ||||
| -rw-r--r-- | meta/classes/module-base.bbclass | 2 |
2 files changed, 9 insertions, 1 deletions
diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass index 5e8b6cf343..b75a462180 100644 --- a/meta/classes/kernel.bbclass +++ b/meta/classes/kernel.bbclass | |||
| @@ -217,6 +217,14 @@ do_compile_kernelmodules() { | |||
| 217 | unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE | 217 | unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE |
| 218 | if (grep -q -i -e '^CONFIG_MODULES=y$' ${B}/.config); then | 218 | if (grep -q -i -e '^CONFIG_MODULES=y$' ${B}/.config); then |
| 219 | oe_runmake -C ${B} ${PARALLEL_MAKE} modules CC="${KERNEL_CC}" LD="${KERNEL_LD}" ${KERNEL_EXTRA_ARGS} | 219 | oe_runmake -C ${B} ${PARALLEL_MAKE} modules CC="${KERNEL_CC}" LD="${KERNEL_LD}" ${KERNEL_EXTRA_ARGS} |
| 220 | |||
| 221 | # Module.symvers gets updated during the | ||
| 222 | # building of the kernel modules. We need to | ||
| 223 | # update this in the shared workdir since some | ||
| 224 | # external kernel modules has a dependency on | ||
| 225 | # other kernel modules and will look at this | ||
| 226 | # file to do symbol lookups | ||
| 227 | cp Module.symvers ${STAGING_KERNEL_BUILDDIR}/ | ||
| 220 | else | 228 | else |
| 221 | bbnote "no modules to compile" | 229 | bbnote "no modules to compile" |
| 222 | fi | 230 | fi |
diff --git a/meta/classes/module-base.bbclass b/meta/classes/module-base.bbclass index 8be26c4f5e..cf4b02ee02 100644 --- a/meta/classes/module-base.bbclass +++ b/meta/classes/module-base.bbclass | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | inherit kernel-arch | 1 | inherit kernel-arch |
| 2 | 2 | ||
| 3 | # This is instead of DEPENDS = "virtual/kernel" | 3 | # This is instead of DEPENDS = "virtual/kernel" |
| 4 | do_configure[depends] += "virtual/kernel:do_shared_workdir" | 4 | do_configure[depends] += "virtual/kernel:do_compile_kernelmodules" |
| 5 | 5 | ||
| 6 | export OS = "${TARGET_OS}" | 6 | export OS = "${TARGET_OS}" |
| 7 | export CROSS_COMPILE = "${TARGET_PREFIX}" | 7 | export CROSS_COMPILE = "${TARGET_PREFIX}" |
