Bug 6788

Summary: lttng-modules build fails with kernel 3.10.43
Product: [Build System, Metadata & Runtime] OE-Core Reporter: Rebecca Chang <rebecca.swee.fun.chang>
Component: kernelAssignee: Rebecca Chang <rebecca.swee.fun.chang>
Status: RESOLVED FIXED QA Contact:
Severity: major    
Priority: Medium CC: bruce.ashfield, nitin.a.kamble, rebecca.swee.fun.chang, tom.zanussi
Version: 1.6.1   
Target Milestone: 1.6.2   
Hardware: Other   
OS: x86_64   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Rebecca Chang 2014-10-02 00:55:30 UTC
After updating the kernel SRCREV to version 3.10.55, lttng-modules build failed. By checking lttng-modules git repo, it has been updated to version 2.4.2 while OE-Core still providing version 2.4.0. This build failure only occurs when build core-image-sato-sdk images. Building older kernel version (3.10.40) did not encounter this build issue too.

Test log:
|   CC [M]  /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-types.o
|   CC [M]  /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-sched.o
|   CC [M]  /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-irq.o
|   CC [M]  /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-timer.o
|   CC [M]  /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-kmem.o
|   CC [M]  /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-module.o
|   CC [M]  /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-power.o
|   CC [M]  /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-statedump.o
|   CC [M]  /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-signal.o
|   CC [M]  /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-block.o
| In file included from /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/../instrumentation/events/lttng-module/../../../probes/define_trace.h:148:0,
|                  from /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/../instrumentation/events/lttng-module/block.h:932,
|                  from /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-block.c:41:
| /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/../instrumentation/events/lttng-module/../../../probes/lttng-events.h:151:6: error: conflicting types for 'trace_block_rq_complete'
|  void trace_##_name(_proto);
|       ^
| /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/../instrumentation/events/lttng-module/../../../probes/lttng-events.h:117:2: note: in expansion of macro 'DEFINE_EVENT_MAP'
|   DEFINE_EVENT_MAP(template, name, name, PARAMS(proto), PARAMS(args))
|   ^
| /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/../instrumentation/events/lttng-module/../../../probes/../instrumentation/events/lttng-module/block.h:235:1: note: in expansion of macro 'DEFINE_EVENT'
|  DEFINE_EVENT(block_rq_with_error, block_rq_complete,
|  ^
| In file included from include/linux/module.h:18:0,
|                  from /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-block.c:23:
| include/linux/tracepoint.h:168:21: note: previous definition of 'trace_block_rq_complete' was here
|   static inline void trace_##name(proto)    \
|                      ^
| include/linux/tracepoint.h:265:3: note: in expansion of macro '__DECLARE_TRACE'
|    __DECLARE_TRACE(name, PARAMS(proto), PARAMS(args), 1, \
|    ^
| include/linux/tracepoint.h:395:2: note: in expansion of macro 'DECLARE_TRACE'
|   DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
|   ^
| include/trace/events/block.h:143:1: note: in expansion of macro 'TRACE_EVENT'
|  TRACE_EVENT(block_rq_complete,
|  ^
| make[3]: *** [/home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes/lttng-probe-block.o] Error 1
| make[2]: *** [/home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git/probes] Error 2
| make[1]: *** [_module_/home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/git] Error 2
| make[1]: Leaving directory `/home/ilab/build/valleyisland/tmp/sysroots/valleyisland-64/usr/src/kernel'
| make: *** [default] Error 2
| ERROR: oe_runmake failed
| WARNING: /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/temp/run.do_compile.8063:1 exit 1 from
|   exit 1
| ERROR: Function failed: do_compile (log file is located at /home/ilab/build/valleyisland/tmp/work/valleyisland_64-poky-linux/lttng-modules/2.4.0-r0/temp/log.do_compile.8063)
ERROR: Task 7 (/home/ilab/poky-daisy/meta/recipes-kernel/lttng/lttng-modules_2.4.0.bb, do_compile) failed with exit code '1'
Comment 1 Rebecca Chang 2014-10-02 00:58:56 UTC
I have done some investigation on this. By updating the SRCREV of lttng-modules to version 2.4.2 or later, the lttng-modules will passed build. Also, this required the additional patch (bio-bvec-iter.patch) to be removed as the fix is already available in lttng-modules version 2.4.2.
Comment 2 Nitin Kamble 2014-10-02 14:57:48 UTC
Richard is ok with bumping the lttng-modules to version 2.4.2 in oecore daisy as it is a point version bump of the recipe. But it needs to be validated, to make sure it does not break older versions of the kernel (v3.10.40).
  Also other option is finding and cherry picking the commit from 2.4.2 which fixes the issue. It will being minimal changes to daisy.

Nitin
Comment 3 Rebecca Chang 2014-10-03 00:40:44 UTC
Thanks Nitin. I will take note on the older kernel version build.

Rebecca
Comment 4 Rebecca Chang 2014-10-03 09:05:07 UTC
Fix submitted to OE-core。
http://lists.openembedded.org/pipermail/openembedded-core/2014-October/097694.html
Comment 5 Nitin Kamble 2014-10-09 14:42:11 UTC
Is this issue present in the poky master branch with the latest v3.10 kernel? If yes then a fix is needed for poky master too.
Comment 6 Rebecca Chang 2014-10-14 00:52:40 UTC
Poky master has no problem because master branch is using lttng-modules version 2.5.
Comment 7 Rebecca Chang 2014-10-30 06:54:23 UTC
Issue was fixed and accepted into OE-Core.

OE-Core rev: 29ef1c738050e536d7824bdca6f7a0b8b1528011
poke rev: 2d5bd895656a234a6d6372e1af539e1b5acfd042