Message ID | 20220803192327.3726094-1-bruce.ashfield@gmail.com |
---|---|
State | New |
Headers | show |
Series | compaction: make tracepoints condtional on CONFIG_COMPACTION | expand |
On 2022-08-03 15 h 23, Bruce Ashfield via lttng-dev wrote: > Hi all, > > This was found during the update of the yocto project reference > kernel to 5.19. Out of all the supported architectures, only > mips failed during the build of lttng-modules. > > Specifically, it seems like the lack of CONFIG_COMPACTION being > enabled in the kernel was the significant issue. Only one of the > tracepoints blew up, but I can't see how any of them would be > valid in this scenario, or why it would be limited to mips. > > While I don't think this is the right fix, this is what got me > up and passing sanity testing, so I wanted to send the change > and see what the actual, correct fix would be :) > > Cheers, > > Bruce Hi Bruce, Thanks for reporting this issue, I propose a simpler fix [1] of just disabling the build of the compaction probe module when CONFIG_COMPACTION is disabled in the kernel configuration. Can you confirm this patch fixes the issue on your side? Thanks, Michael [1] https://review.lttng.org/c/lttng-modules/+/8660
On Wed, Aug 10, 2022 at 11:20 AM Michael Jeanson <mjeanson at efficios.com> wrote: > > On 2022-08-03 15 h 23, Bruce Ashfield via lttng-dev wrote: > > Hi all, > > > > This was found during the update of the yocto project reference > > kernel to 5.19. Out of all the supported architectures, only > > mips failed during the build of lttng-modules. > > > > Specifically, it seems like the lack of CONFIG_COMPACTION being > > enabled in the kernel was the significant issue. Only one of the > > tracepoints blew up, but I can't see how any of them would be > > valid in this scenario, or why it would be limited to mips. > > > > While I don't think this is the right fix, this is what got me > > up and passing sanity testing, so I wanted to send the change > > and see what the actual, correct fix would be :) > > > > Cheers, > > > > Bruce > > Hi Bruce, > > Thanks for reporting this issue, I propose a simpler fix [1] of just > disabling the build of the compaction probe module when > CONFIG_COMPACTION is disabled in the kernel configuration. > > Can you confirm this patch fixes the issue on your side? confirmed, it fixes the issue on my side. Bruce > > Thanks, > > Michael > > [1] https://review.lttng.org/c/lttng-modules/+/8660
----- On Aug 10, 2022, at 1:48 PM, Bruce Ashfield via lttng-dev lttng-dev at lists.lttng.org wrote: > On Wed, Aug 10, 2022 at 11:20 AM Michael Jeanson <mjeanson at efficios.com> wrote: >> >> On 2022-08-03 15 h 23, Bruce Ashfield via lttng-dev wrote: >> > Hi all, >> > >> > This was found during the update of the yocto project reference >> > kernel to 5.19. Out of all the supported architectures, only >> > mips failed during the build of lttng-modules. >> > >> > Specifically, it seems like the lack of CONFIG_COMPACTION being >> > enabled in the kernel was the significant issue. Only one of the >> > tracepoints blew up, but I can't see how any of them would be >> > valid in this scenario, or why it would be limited to mips. >> > >> > While I don't think this is the right fix, this is what got me >> > up and passing sanity testing, so I wanted to send the change >> > and see what the actual, correct fix would be :) >> > >> > Cheers, >> > >> > Bruce >> >> Hi Bruce, >> >> Thanks for reporting this issue, I propose a simpler fix [1] of just >> disabling the build of the compaction probe module when >> CONFIG_COMPACTION is disabled in the kernel configuration. >> >> Can you confirm this patch fixes the issue on your side? > > confirmed, it fixes the issue on my side. Merged into lttng-modules master, stable-2.13, stable-2.12, thanks! Mathieu > > Bruce > >> >> Thanks, >> >> Michael >> >> [1] https://review.lttng.org/c/lttng-modules/+/8660 > > > > -- > - Thou shalt not follow the NULL pointer, for chaos and madness await > thee at its end > - "Use the force Harry" - Gandalf, Star Trek II > _______________________________________________ > lttng-dev mailing list > lttng-dev at lists.lttng.org > https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
diff --git a/include/instrumentation/events/compaction.h b/include/instrumentation/events/compaction.h index ecae39a..155804a 100644 --- a/include/instrumentation/events/compaction.h +++ b/include/instrumentation/events/compaction.h @@ -9,6 +9,8 @@ #include <linux/types.h> #include <lttng/kernel-version.h> +#ifdef CONFIG_COMPACTION + #if LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,0,0) LTTNG_TRACEPOINT_EVENT_CLASS(compaction_isolate_template, @@ -97,6 +99,7 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(compaction_isolate_template, #endif /* #else #if LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,0,0) */ + #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,18,0)) LTTNG_TRACEPOINT_EVENT_MAP(mm_compaction_migratepages, @@ -182,6 +185,8 @@ LTTNG_TRACEPOINT_EVENT_MAP(mm_compaction_migratepages, ) #endif /* #else #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(3,16,0)) */ +#endif /* CONFIG_COMPACTION */ + #endif /* LTTNG_TRACE_COMPACTION_H */ /* This part must be outside protection */