Fix: access migrate_disable field directly
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Wed, 19 Sep 2018 21:48:49 +0000 (17:48 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Wed, 26 Sep 2018 16:34:24 +0000 (12:34 -0400)
commitb656f50743f54bbe0719523a71e3b2cee7c68b7e
tree37476edc1cd8781a549008cb08b5dd93b7fd66d0
parentfbbb0005efb47a518b8cecbaad5556c4f526074f
Fix: access migrate_disable field directly

For stable real time kernel > 4.9, the __migrate_disabled utility symbol
is not always exported. This can result in linking problem at build time
and runtime, preventing the loading of the tracer.

The problem was reported to the RT community. [1] [2]

A solution is to access the field directly instead of using the
utility wrapper.

It is important to note that the field is now available for other
configurations than CONFIG_PREEMPT_RT_FULL. For now, we choose to
expose the migratable context only for configurations where
CONFIG_PREEMPT_RT_FULL is set.

Based on the configuration dependency of the kernels, selecting
CONFIG_PREEMPT_RT_FULL ensures the presence of the migrate_disable
field.

Initial bug report [3].

[1] https://marc.info/?l=linux-rt-users&m=153730414126984&w=2
[2] https://marc.info/?l=linux-rt-users&m=153729444223779&w=2
[3] https://lists.lttng.org/pipermail/lttng-dev/2018-September/028216.html

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
lttng-context-migratable.c
This page took 0.024867 seconds and 4 git commands to generate.