[PATCH] marker fixup for ltt-probe-*

Kevin Hilman <[email protected]>
Newsgroups gmane.linux.kernel.tracing
Message-ID <[email protected]>
Fix up some markers in ltt-probe-* that were found when trying to load
them as modules and getting -EPERM. Some are #ifdef XYZ in the kernel
code but not in the , and others appear to be typos.

Patch is against today's git tree.

Signed-off-by: Kevin Hilman <[email protected]>

diff --git a/arch/arm/kernel/traps.c b/arch/arm/kernel/traps.c
index 9e43947..2b826ee 100644
--- a/arch/arm/kernel/traps.c
+++ b/arch/arm/kernel/traps.c
@@ -250,7 +250,7 @@ void notify_die(const char *str, struct

                force_sig_info(info->si_signo, info, current);

-               MARK(kernel_trace_exit, MARK_NOARGS);
+               MARK(kernel_trap_exit, MARK_NOARGS);

        } else {
                die(str, regs, err);
diff --git a/ltt/probes/ltt-probe-arm.c b/ltt/probes/ltt-probe-arm.c
index 091f9d5..2511ebc 100644
--- a/ltt/probes/ltt-probe-arm.c
+++ b/ltt/probes/ltt-probe-arm.c
@@ -157,11 +157,13 @@ int __init probe_init(void)
                        probe_kernel_syscall_exit);
        if (!result)
                goto cleanup;
+#if !defined(CONFIG_AEABI) || defined(CONFIG_OABI_COMPAT)
        result = marker_set_probe("ipc_call",
                        IPC_CALL_FORMAT,
                        probe_ipc_call);
        if (!result)
                goto cleanup;
+#endif
        result = marker_set_probe("mm_handle_fault_entry",
                        MM_HANDLE_FAULT_ENTRY_FORMAT,
                        probe_mm_handle_fault_entry);
diff --git a/ltt/probes/ltt-probe-kernel.c b/ltt/probes/ltt-probe-kernel.c
index 311cc68..ce87d36 100644
--- a/ltt/probes/ltt-probe-kernel.c
+++ b/ltt/probes/ltt-probe-kernel.c
@@ -626,6 +626,7 @@ static int __init probe_init(void)
                        probe_kernel_sched_schedule);
        if (!result)
                goto cleanup;
+#ifdef CONFIG_SMP
        result = marker_set_probe("kernel_sched_wait_task",
                        KERNEL_SCHED_WAIT_TASK_FORMAT,
                        probe_kernel_sched_wait_task);
@@ -636,6 +637,7 @@ static int __init probe_init(void)
                        probe_kernel_sched_migrate_task);
        if (!result)
                goto cleanup;
+#endif
        result = marker_set_probe("kernel_process_fork",
                        KERNEL_PROCESS_FORK_FORMAT,
                        probe_kernel_process_fork);
@@ -706,11 +708,12 @@ static int __init probe_init(void)
                        probe_kernel_tasklet_high_exit);
        if (!result)
                goto cleanup;
-       result = marker_set_probe("kernel_timer_update_time",
-                       KERNEL_TIMER_UPDATE_TIME_FORMAT,
-                       probe_kernel_timer_update_time);
-       if (!result)
-               goto cleanup;
+       /* TODO: this is marked as TODO in kernel/timer.c */
+/*     result = marker_set_probe("kernel_timer_update_time", */
+/*                     KERNEL_TIMER_UPDATE_TIME_FORMAT, */
+/*                     probe_kernel_timer_update_time); */
+/*     if (!result) */
+/*             goto cleanup; */
        result = marker_set_probe("kernel_timer_timeout",
                        KERNEL_TIMER_TIMEOUT_FORMAT,
                        probe_kernel_timer_timeout);
diff --git a/ltt/probes/ltt-probe-net.c b/ltt/probes/ltt-probe-net.c
index 8e5dad0..5481cff 100644
--- a/ltt/probes/ltt-probe-net.c
+++ b/ltt/probes/ltt-probe-net.c
@@ -185,11 +185,13 @@ static int __init probe_init(void)
                        probe_net_socket_create);
        if (!result)
                goto cleanup;
+#ifdef __ARCH_WANT_SYS_SOCKETCALL
        result = marker_set_probe("net_socket_call",
                        NET_SOCKET_CALL_FORMAT,
                        probe_net_socket_call);
        if (!result)
                goto cleanup;
+#endif
        result = marker_set_probe("net_dev_xmit",
                        NET_DEV_XMIT_FORMAT,
                        probe_net_dev_xmit);
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.