uprobe: Mark uprobe event as registered
authorFrancis Deslauriers <francis.deslauriers@efficios.com>
Thu, 15 Jun 2017 17:40:35 +0000 (13:40 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 27 Aug 2018 21:38:03 +0000 (17:38 -0400)
Signed-off-by: Francis Deslauriers <francis.deslauriers@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
lttng-events.c

index 636a1891be0c188a9619d5a31ee103a4f57e2c86..a3030533d1e62d1c01f4cc8b0db9fed4cffa7425 100644 (file)
@@ -743,6 +743,17 @@ struct lttng_event *_lttng_event_create(struct lttng_channel *chan,
                }
                break;
        case LTTNG_KERNEL_UPROBE:
+               /*
+                * Needs to be explicitly enabled after creation, since
+                * we may want to apply filters.
+                */
+               event->enabled = 0;
+               event->registered = 1;
+               /*
+                * Populate lttng_event structure before event
+                * registration.
+                */
+               smp_wmb();
 
                ret = lttng_uprobes_register(event_param->name,
                                event_param->u.uprobe.path,
@@ -815,6 +826,7 @@ void register_event(struct lttng_event *event)
                        desc->name);
                break;
        case LTTNG_KERNEL_KPROBE:
+       case LTTNG_KERNEL_UPROBE:
        case LTTNG_KERNEL_KRETPROBE:
        case LTTNG_KERNEL_FUNCTION:
        case LTTNG_KERNEL_NOOP:
This page took 0.027201 seconds and 4 git commands to generate.