X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=liblttng-ust%2Flttng-events.c;h=9b2d3c649ac1b695e8d1136af11e12797b5053bc;hb=bd9bb3c77252c984f8b6a7cbfb1d6ebbd069159c;hp=855f8d8739d1ff0ecb07d6779957c4f11153f9db;hpb=735bef4705cc42f25d26f25be09ba98f1efb8511;p=deliverable%2Flttng-ust.git diff --git a/liblttng-ust/lttng-events.c b/liblttng-ust/lttng-events.c index 855f8d87..9b2d3c64 100644 --- a/liblttng-ust/lttng-events.c +++ b/liblttng-ust/lttng-events.c @@ -600,8 +600,6 @@ int lttng_event_create(const struct lttng_event_desc *desc, goto sessiond_register_error; } - /* Populate lttng_event structure before tracepoint registration. */ - cmm_smp_wmb(); cds_list_add(&event->node, &chan->session->events_head); cds_hlist_add_head(&event->hlist, head); return 0; @@ -746,7 +744,8 @@ void lttng_create_event_if_missing(struct lttng_enabler *enabler) */ cds_list_for_each_entry(probe_desc, probe_list, head) { for (i = 0; i < probe_desc->nr_events; i++) { - int found = 0, ret; + int ret; + bool found = false; struct cds_hlist_head *head; struct cds_hlist_node *node; const char *event_name; @@ -766,8 +765,10 @@ void lttng_create_event_if_missing(struct lttng_enabler *enabler) head = &session->events_ht.table[hash & (LTTNG_UST_EVENT_HT_SIZE - 1)]; cds_hlist_for_each_entry(event, node, head, hlist) { if (event->desc == desc - && event->chan == enabler->chan) - found = 1; + && event->chan == enabler->chan) { + found = true; + break; + } } if (found) continue; @@ -1126,6 +1127,18 @@ int lttng_attach_context(struct lttng_ust_context *context_param, return lttng_add_user_ns_to_ctx(ctx); case LTTNG_UST_CONTEXT_UTS_NS: return lttng_add_uts_ns_to_ctx(ctx); + case LTTNG_UST_CONTEXT_VUID: + return lttng_add_vuid_to_ctx(ctx); + case LTTNG_UST_CONTEXT_VEUID: + return lttng_add_veuid_to_ctx(ctx); + case LTTNG_UST_CONTEXT_VSUID: + return lttng_add_vsuid_to_ctx(ctx); + case LTTNG_UST_CONTEXT_VGID: + return lttng_add_vgid_to_ctx(ctx); + case LTTNG_UST_CONTEXT_VEGID: + return lttng_add_vegid_to_ctx(ctx); + case LTTNG_UST_CONTEXT_VSGID: + return lttng_add_vsgid_to_ctx(ctx); default: return -EINVAL; }