From 0c2c6606eb66cb5222ab7a2a4f8329fd5dfdef70 Mon Sep 17 00:00:00 2001 From: Mathieu Desnoyers Date: Tue, 22 Feb 2022 11:56:29 -0500 Subject: [PATCH] Fix: circular dependency on symbol lttng_id_tracker_lookup Adding lttng_id_tracker_lookup feature into kprobes, uprobes and kretprobes introduces a circular dependency between lttng-tracer.ko and the respective probe modules. There is no real reason for having the kprobes/uprobes/kretprobes modules separate from the tracer core, so combine those. Signed-off-by: Mathieu Desnoyers Change-Id: Iea80c8054054b341e1836c8675c04e00424608fc --- src/Kbuild | 12 ++++++++++++ src/{probes => }/lttng-kprobes.c | 0 src/{probes => }/lttng-kretprobes.c | 0 src/{probes => }/lttng-uprobes.c | 0 src/probes/Kbuild | 12 ------------ 5 files changed, 12 insertions(+), 12 deletions(-) rename src/{probes => }/lttng-kprobes.c (100%) rename src/{probes => }/lttng-kretprobes.c (100%) rename src/{probes => }/lttng-uprobes.c (100%) diff --git a/src/Kbuild b/src/Kbuild index a341fd9b..3fa1807d 100644 --- a/src/Kbuild +++ b/src/Kbuild @@ -140,6 +140,18 @@ ifneq ($(CONFIG_TIME_NS),) lttng-tracer-objs += lttng-context-time-ns.o endif +ifneq ($(CONFIG_KPROBES),) + lttng-tracer-objs += lttng-kprobes.o +endif + +ifneq ($(CONFIG_UPROBES),) + lttng-tracer-objs += lttng-uprobes.o +endif + +ifneq ($(CONFIG_KRETPROBES),) + lttng-tracer-objs += lttng-kretprobes.o +endif + obj-$(CONFIG_LTTNG) += lttng-statedump.o lttng-statedump-objs := lttng-statedump-impl.o diff --git a/src/probes/lttng-kprobes.c b/src/lttng-kprobes.c similarity index 100% rename from src/probes/lttng-kprobes.c rename to src/lttng-kprobes.c diff --git a/src/probes/lttng-kretprobes.c b/src/lttng-kretprobes.c similarity index 100% rename from src/probes/lttng-kretprobes.c rename to src/lttng-kretprobes.c diff --git a/src/probes/lttng-uprobes.c b/src/lttng-uprobes.c similarity index 100% rename from src/probes/lttng-uprobes.c rename to src/lttng-uprobes.c diff --git a/src/probes/Kbuild b/src/probes/Kbuild index c4273e01..f9677678 100644 --- a/src/probes/Kbuild +++ b/src/probes/Kbuild @@ -236,18 +236,6 @@ else endif endif # CONFIG_KALLSYMS_ALL -ifneq ($(CONFIG_KPROBES),) - obj-$(CONFIG_LTTNG) += lttng-kprobes.o -endif # CONFIG_KPROBES - -ifneq ($(CONFIG_UPROBES),) - obj-$(CONFIG_LTTNG) += lttng-uprobes.o -endif # CONFIG_UPROBES - -ifneq ($(CONFIG_KRETPROBES),) - obj-$(CONFIG_LTTNG) += lttng-kretprobes.o -endif # CONFIG_KRETPROBES - ifneq ($(CONFIG_PREEMPTIRQ_EVENTS),) obj-$(CONFIG_LTTNG) += lttng-probe-preemptirq.o endif # CONFIG_PREEMPTIRQ_EVENTS -- 2.34.1