From: Michael Jeanson Date: Wed, 10 Feb 2016 16:08:14 +0000 (-0500) Subject: Fix: Define lttng-tracer metadata only once X-Git-Tag: v2.7.2~8 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=353f4684532e95f2f3a8b227bf59df3fb285ce0e;p=lttng-modules.git Fix: Define lttng-tracer metadata only once Fixes sysfs trying to create the lttng-tracer module version node multiple times. Signed-off-by: Michael Jeanson Signed-off-by: Mathieu Desnoyers --- diff --git a/Makefile b/Makefile index 7c878f05..6bf4d287 100644 --- a/Makefile +++ b/Makefile @@ -50,10 +50,6 @@ lttng-tracer-objs := lttng-events.o lttng-abi.o \ lttng-filter-validator.o \ probes/lttng-probe-user.o -obj-m += lttng-statedump.o -lttng-statedump-objs := lttng-statedump-impl.o wrapper/irqdesc.o \ - wrapper/fdtable.o - ifneq ($(CONFIG_HAVE_SYSCALL_TRACEPOINTS),) lttng-tracer-objs += lttng-syscalls.o endif # CONFIG_HAVE_SYSCALL_TRACEPOINTS @@ -70,6 +66,10 @@ lttng-tracer-objs += $(shell \ -o \( $(VERSION) -eq 3 -a $(PATCHLEVEL) -ge 15 -a $(SUBLEVEL) -ge 0 \) ] ; then \ echo "lttng-tracepoint.o" ; fi;) +obj-m += lttng-statedump.o +lttng-statedump-objs := lttng-statedump-impl.o wrapper/irqdesc.o \ + wrapper/fdtable.o + obj-m += probes/ obj-m += lib/ diff --git a/lttng-context-cpu-id.c b/lttng-context-cpu-id.c index 0738d9c7..8243c2f4 100644 --- a/lttng-context-cpu-id.c +++ b/lttng-context-cpu-id.c @@ -84,11 +84,3 @@ int lttng_add_cpu_id_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_cpu_id_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit CPU id Context"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-hostname.c b/lttng-context-hostname.c index 28881d05..0590207d 100644 --- a/lttng-context-hostname.c +++ b/lttng-context-hostname.c @@ -117,11 +117,3 @@ int lttng_add_hostname_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_hostname_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit Perf Support"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-nice.c b/lttng-context-nice.c index 412dd93a..b2e631d8 100644 --- a/lttng-context-nice.c +++ b/lttng-context-nice.c @@ -84,11 +84,3 @@ int lttng_add_nice_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_nice_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit Nice Context"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-perf-counters.c b/lttng-context-perf-counters.c index 0c74234c..467b7180 100644 --- a/lttng-context-perf-counters.c +++ b/lttng-context-perf-counters.c @@ -280,11 +280,3 @@ error_attr: kfree(events); return ret; } - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit Perf Support"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-pid.c b/lttng-context-pid.c index 3211819d..207f88be 100644 --- a/lttng-context-pid.c +++ b/lttng-context-pid.c @@ -84,11 +84,3 @@ int lttng_add_pid_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_pid_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit PID Context"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-ppid.c b/lttng-context-ppid.c index 33ea1a79..f4d7c93d 100644 --- a/lttng-context-ppid.c +++ b/lttng-context-ppid.c @@ -106,11 +106,3 @@ int lttng_add_ppid_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_ppid_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit PPID Context"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-prio.c b/lttng-context-prio.c index d9fb6f31..57b484e9 100644 --- a/lttng-context-prio.c +++ b/lttng-context-prio.c @@ -105,11 +105,3 @@ int lttng_add_prio_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_prio_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit Priority Context"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-procname.c b/lttng-context-procname.c index 5c1cd3a6..d17d47b3 100644 --- a/lttng-context-procname.c +++ b/lttng-context-procname.c @@ -88,11 +88,3 @@ int lttng_add_procname_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_procname_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit Perf Support"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-tid.c b/lttng-context-tid.c index 7b8e04be..7f3d4a11 100644 --- a/lttng-context-tid.c +++ b/lttng-context-tid.c @@ -87,11 +87,3 @@ int lttng_add_tid_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_tid_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit TID Context"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-vpid.c b/lttng-context-vpid.c index 9a8df9a9..dccaaccf 100644 --- a/lttng-context-vpid.c +++ b/lttng-context-vpid.c @@ -99,11 +99,3 @@ int lttng_add_vpid_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_vpid_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit vPID Context"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-vppid.c b/lttng-context-vppid.c index 9f36375d..80b1f9e7 100644 --- a/lttng-context-vppid.c +++ b/lttng-context-vppid.c @@ -128,11 +128,3 @@ int lttng_add_vppid_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_vppid_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit vPPID Context"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION); diff --git a/lttng-context-vtid.c b/lttng-context-vtid.c index a264424f..903e296c 100644 --- a/lttng-context-vtid.c +++ b/lttng-context-vtid.c @@ -99,11 +99,3 @@ int lttng_add_vtid_to_ctx(struct lttng_ctx **ctx) return 0; } EXPORT_SYMBOL_GPL(lttng_add_vtid_to_ctx); - -MODULE_LICENSE("GPL and additional rights"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Linux Trace Toolkit vTID Context"); -MODULE_VERSION(__stringify(LTTNG_MODULES_MAJOR_VERSION) "." - __stringify(LTTNG_MODULES_MINOR_VERSION) "." - __stringify(LTTNG_MODULES_PATCHLEVEL_VERSION) - LTTNG_MODULES_EXTRAVERSION);