2 * Copyright (C) 2011 EfficiOS Inc.
3 * Copyright (C) 2016 Jérémie Galarneau <jeremie.galarneau@efficios.com>
5 * SPDX-License-Identifier: GPL-2.0-only
11 #include "channel.hpp"
14 #include "lttng-sessiond.hpp"
15 #include "lttng-ust-ctl.hpp"
16 #include "lttng-ust-error.hpp"
17 #include "trace-kernel.hpp"
18 #include "trace-ust.hpp"
19 #include "ust-app.hpp"
22 #include <common/bytecode/bytecode.hpp>
23 #include <common/compat/errno.hpp>
24 #include <common/context.hpp>
25 #include <common/error.hpp>
26 #include <common/filter.hpp>
27 #include <common/sessiond-comm/sessiond-comm.hpp>
28 #include <common/urcu.hpp>
30 #include <lttng/condition/condition.h>
31 #include <lttng/condition/event-rule-matches.h>
32 #include <lttng/event-rule/event-rule-internal.hpp>
33 #include <lttng/event-rule/event-rule.h>
34 #include <lttng/lttng.h>
37 #include <urcu/list.h>
40 * Add unique UST event based on the event name, filter bytecode and loglevel.
42 static void add_unique_ust_event(struct lttng_ht
*ht
, struct ltt_ust_event
*event
)
44 struct cds_lfht_node
*node_ptr
;
45 struct ltt_ust_ht_key key
;
51 key
.name
= event
->attr
.name
;
52 key
.filter
= (struct lttng_bytecode
*) event
->filter
;
53 key
.loglevel_type
= (lttng_ust_abi_loglevel_type
) event
->attr
.loglevel_type
;
54 key
.loglevel_value
= event
->attr
.loglevel
;
55 key
.exclusion
= event
->exclusion
;
57 node_ptr
= cds_lfht_add_unique(ht
->ht
,
58 ht
->hash_fct(event
->node
.key
, lttng_ht_seed
),
59 trace_ust_ht_match_event
,
62 LTTNG_ASSERT(node_ptr
== &event
->node
.node
);
66 * Disable kernel tracepoint events for a channel from the kernel session of
67 * a specified event_name and event type.
68 * On type LTTNG_EVENT_ALL all events with event_name are disabled.
69 * If event_name is NULL all events of the specified type are disabled.
71 int event_kernel_disable_event(struct ltt_kernel_channel
*kchan
,
72 const char *event_name
,
73 enum lttng_event_type type
)
75 int ret
, error
= 0, found
= 0;
76 struct ltt_kernel_event
*kevent
;
80 /* For each event in the kernel session */
81 cds_list_for_each_entry (kevent
, &kchan
->events_list
.head
, list
) {
82 if (type
!= LTTNG_EVENT_ALL
&& kevent
->type
!= type
)
84 if (event_name
!= nullptr && strcmp(event_name
, kevent
->event
->name
) != 0) {
88 ret
= kernel_disable_event(kevent
);
94 DBG("Disable kernel event: found %d events with name: %s and type: %d",
96 event_name
? event_name
: "NULL",
99 if (event_name
!= nullptr && !found
) {
100 ret
= LTTNG_ERR_NO_EVENT
;
102 ret
= error
? LTTNG_ERR_KERN_DISABLE_FAIL
: LTTNG_OK
;
109 * Enable kernel tracepoint event for a channel from the kernel session.
110 * We own filter_expression and filter.
112 int event_kernel_enable_event(struct ltt_kernel_channel
*kchan
,
113 struct lttng_event
*event
,
114 char *filter_expression
,
115 struct lttng_bytecode
*filter
)
118 struct ltt_kernel_event
*kevent
;
123 kevent
= trace_kernel_find_event(event
->name
, kchan
, event
->type
, filter
);
124 if (kevent
== nullptr) {
125 ret
= kernel_create_event(event
, kchan
, filter_expression
, filter
);
126 /* We have passed ownership */
127 filter_expression
= nullptr;
132 } else if (!kevent
->enabled
) {
133 ret
= kernel_enable_event(kevent
);
135 ret
= LTTNG_ERR_KERN_ENABLE_FAIL
;
139 /* At this point, the event is considered enabled */
140 ret
= LTTNG_ERR_KERN_EVENT_EXIST
;
146 free(filter_expression
);
152 * ============================
153 * UST : The Ultimate Frontier!
154 * ============================
158 * Enable UST tracepoint event for a channel from a UST session.
159 * We own filter_expression, filter, and exclusion.
161 int event_ust_enable_tracepoint(struct ltt_ust_session
*usess
,
162 struct ltt_ust_channel
*uchan
,
163 struct lttng_event
*event
,
164 char *filter_expression
,
165 struct lttng_bytecode
*filter
,
166 struct lttng_event_exclusion
*exclusion
,
169 int ret
= LTTNG_OK
, to_create
= 0;
170 struct ltt_ust_event
*uevent
;
176 lttng::urcu::read_lock_guard read_lock
;
178 uevent
= trace_ust_find_event(uchan
->events
,
181 (enum lttng_ust_abi_loglevel_type
) event
->loglevel_type
,
185 ret
= trace_ust_create_event(
186 event
, filter_expression
, filter
, exclusion
, internal_event
, &uevent
);
187 /* We have passed ownership */
188 filter_expression
= nullptr;
191 if (ret
!= LTTNG_OK
) {
195 /* Valid to set it after the goto error since uevent is still NULL */
199 if (uevent
->enabled
) {
200 /* It's already enabled so everything is OK */
201 LTTNG_ASSERT(!to_create
);
202 ret
= LTTNG_ERR_UST_EVENT_ENABLED
;
206 uevent
->enabled
= true;
208 /* Add ltt ust event to channel */
209 add_unique_ust_event(uchan
->events
, uevent
);
212 if (!usess
->active
) {
217 /* Create event on all UST registered apps for session */
218 ret
= ust_app_create_event_glb(usess
, uchan
, uevent
);
220 /* Enable event on all UST registered apps for session */
221 ret
= ust_app_enable_event_glb(usess
, uchan
, uevent
);
225 if (ret
== -LTTNG_UST_ERR_EXIST
) {
226 ret
= LTTNG_ERR_UST_EVENT_EXIST
;
228 ret
= LTTNG_ERR_UST_ENABLE_FAIL
;
233 DBG("Event UST %s %s in channel %s",
235 to_create
? "created" : "enabled",
241 free(filter_expression
);
248 * Disable UST tracepoint of a channel from a UST session.
250 int event_ust_disable_tracepoint(struct ltt_ust_session
*usess
,
251 struct ltt_ust_channel
*uchan
,
252 const char *event_name
)
255 struct ltt_ust_event
*uevent
;
256 struct lttng_ht_node_str
*node
;
257 struct lttng_ht_iter iter
;
262 LTTNG_ASSERT(event_name
);
266 lttng::urcu::read_lock_guard read_lock
;
269 * We use a custom lookup since we need the iterator for the next_duplicate
270 * call in the do while loop below.
272 cds_lfht_lookup(ht
->ht
,
273 ht
->hash_fct((void *) event_name
, lttng_ht_seed
),
274 trace_ust_ht_match_event_by_name
,
277 node
= lttng_ht_iter_get_node_str(&iter
);
278 if (node
== nullptr) {
279 DBG2("Trace UST event NOT found by name %s", event_name
);
280 ret
= LTTNG_ERR_UST_EVENT_NOT_FOUND
;
285 uevent
= lttng::utils::container_of(node
, <t_ust_event::node
);
286 LTTNG_ASSERT(uevent
);
288 if (!uevent
->enabled
) {
289 /* It's already disabled so everything is OK */
292 uevent
->enabled
= false;
293 DBG2("Event UST %s disabled in channel %s", uevent
->attr
.name
, uchan
->name
);
295 if (!usess
->active
) {
298 ret
= ust_app_disable_event_glb(usess
, uchan
, uevent
);
299 if (ret
< 0 && ret
!= -LTTNG_UST_ERR_EXIST
) {
300 ret
= LTTNG_ERR_UST_DISABLE_FAIL
;
304 /* Get next duplicate event by name. */
305 cds_lfht_next_duplicate(
306 ht
->ht
, trace_ust_ht_match_event_by_name
, event_name
, &iter
.iter
);
307 node
= lttng_ht_iter_get_node_str(&iter
);
317 * Disable all UST tracepoints for a channel from a UST session.
319 int event_ust_disable_all_tracepoints(struct ltt_ust_session
*usess
, struct ltt_ust_channel
*uchan
)
321 int ret
, i
, size
, error
= 0;
322 struct lttng_ht_iter iter
;
323 struct ltt_ust_event
*uevent
= nullptr;
324 struct lttng_event
*events
= nullptr;
329 /* Disabling existing events */
331 lttng::urcu::read_lock_guard read_lock
;
333 cds_lfht_for_each_entry (uchan
->events
->ht
, &iter
.iter
, uevent
, node
.node
) {
334 if (uevent
->enabled
) {
335 ret
= event_ust_disable_tracepoint(usess
, uchan
, uevent
->attr
.name
);
337 error
= LTTNG_ERR_UST_DISABLE_FAIL
;
344 /* Get all UST available events */
345 size
= ust_app_list_events(&events
);
347 ret
= LTTNG_ERR_UST_LIST_FAIL
;
351 for (i
= 0; i
< size
; i
++) {
352 ret
= event_ust_disable_tracepoint(usess
, uchan
, events
[i
].name
);
354 /* Continue to disable the rest... */
355 error
= LTTNG_ERR_UST_DISABLE_FAIL
;
360 ret
= error
? error
: LTTNG_OK
;
366 static void agent_enable_all(struct agent
*agt
)
368 struct agent_event
*aevent
;
369 struct lttng_ht_iter iter
;
372 /* Flag every event as enabled. */
373 lttng::urcu::read_lock_guard read_lock
;
375 cds_lfht_for_each_entry (agt
->events
->ht
, &iter
.iter
, aevent
, node
.node
) {
376 aevent
->enabled_count
++;
382 * Enable all agent event for a given UST session.
384 * Return LTTNG_OK on success or else a LTTNG_ERR* code.
386 int event_agent_enable_all(struct ltt_ust_session
*usess
,
388 struct lttng_event
*event
,
389 struct lttng_bytecode
*filter
,
390 char *filter_expression
)
396 DBG("Event agent enabling ALL events for session %" PRIu64
, usess
->id
);
398 /* Enable event on agent application through TCP socket. */
399 ret
= event_agent_enable(usess
, agt
, event
, filter
, filter_expression
);
400 if (ret
!= LTTNG_OK
) {
404 agent_enable_all(agt
);
413 * Check if this event's filter requires the activation of application contexts
414 * and enable them in the agent.
415 * TODO: bytecode iterator does not support non-legacy application
416 * contexts yet. Not an issue for now, since they are not generated by
417 * the lttng-ctl library.
419 static int add_filter_app_ctx(struct lttng_bytecode
*bytecode
,
420 const char *filter_expression
,
424 char *provider_name
= nullptr, *ctx_name
= nullptr;
425 struct bytecode_symbol_iterator
*it
= bytecode_symbol_iterator_create(bytecode
);
428 ret
= LTTNG_ERR_NOMEM
;
433 struct lttng_event_context ctx
;
434 const char *symbol_name
= bytecode_symbol_iterator_get_name(it
);
436 if (parse_application_context(symbol_name
, &provider_name
, &ctx_name
)) {
437 /* Not an application context. */
441 ctx
.ctx
= LTTNG_EVENT_CONTEXT_APP_CONTEXT
;
442 ctx
.u
.app_ctx
.provider_name
= provider_name
;
443 ctx
.u
.app_ctx
.ctx_name
= ctx_name
;
445 /* Recognized an application context. */
446 DBG("Enabling event with filter expression \"%s\" requires enabling the %s:%s application context.",
451 ret
= agent_add_context(&ctx
, agt
);
452 if (ret
!= LTTNG_OK
) {
453 ERR("Failed to add application context %s:%s.", provider_name
, ctx_name
);
457 ret
= agent_enable_context(&ctx
, agt
->domain
);
458 if (ret
!= LTTNG_OK
) {
459 ERR("Failed to enable application context %s:%s.", provider_name
, ctx_name
);
465 provider_name
= ctx_name
= nullptr;
466 } while (bytecode_symbol_iterator_next(it
) == 0);
470 bytecode_symbol_iterator_destroy(it
);
474 static int agent_enable(struct agent
*agt
,
475 struct lttng_event
*event
,
476 struct lttng_bytecode
*filter
,
477 char *filter_expression
)
479 int ret
, created
= 0;
480 struct agent_event
*aevent
;
485 lttng::urcu::read_lock_guard read_lock
;
486 aevent
= agent_find_event(
487 event
->name
, event
->loglevel_type
, event
->loglevel
, filter_expression
, agt
);
489 aevent
= agent_create_event(event
->name
,
490 event
->loglevel_type
,
495 ret
= LTTNG_ERR_NOMEM
;
499 filter_expression
= nullptr;
501 LTTNG_ASSERT(!AGENT_EVENT_IS_ENABLED(aevent
));
504 if (created
&& aevent
->filter
) {
505 ret
= add_filter_app_ctx(aevent
->filter
, aevent
->filter_expression
, agt
);
506 if (ret
!= LTTNG_OK
) {
511 /* Already enabled? */
512 if (AGENT_EVENT_IS_ENABLED(aevent
)) {
517 ret
= agent_enable_event(aevent
, agt
->domain
);
518 if (ret
!= LTTNG_OK
) {
522 /* If the event was created prior to the enable, add it to the domain. */
524 agent_add_event(aevent
, agt
);
532 agent_destroy_event(aevent
);
536 free(filter_expression
);
541 * Enable a single agent event for a given UST session.
543 * Return LTTNG_OK on success or else a LTTNG_ERR* code.
545 int event_agent_enable(struct ltt_ust_session
*usess
,
547 struct lttng_event
*event
,
548 struct lttng_bytecode
*filter
,
549 char *filter_expression
)
555 DBG("Enabling agent event: event pattern = '%s', session id = %" PRIu64
556 ", loglevel type = %d, loglevel = %d, filter expression = '%s'",
559 event
->loglevel_type
,
561 filter_expression
? filter_expression
: "(none)");
563 return agent_enable(agt
, event
, filter
, filter_expression
);
567 * Enable a single agent event for a trigger.
569 * Return LTTNG_OK on success or else a LTTNG_ERR* code.
571 int trigger_agent_enable(const struct lttng_trigger
*trigger
, struct agent
*agt
)
574 enum lttng_condition_status c_status
;
575 enum lttng_trigger_status t_status
;
576 enum lttng_domain_type d_type
;
577 const struct lttng_condition
*condition
;
578 const struct lttng_event_rule
*rule
;
579 const char *filter_expression
;
580 char *filter_expression_copy
= nullptr;
581 const struct lttng_bytecode
*filter_bytecode
;
582 struct lttng_bytecode
*filter_bytecode_copy
= nullptr;
583 struct lttng_event
*event
= nullptr;
584 uid_t trigger_owner_uid
= 0;
585 const char *trigger_name
;
587 LTTNG_ASSERT(trigger
);
590 t_status
= lttng_trigger_get_name(trigger
, &trigger_name
);
591 if (t_status
!= LTTNG_TRIGGER_STATUS_OK
) {
592 trigger_name
= "(anonymous)";
595 t_status
= lttng_trigger_get_owner_uid(trigger
, &trigger_owner_uid
);
596 LTTNG_ASSERT(t_status
== LTTNG_TRIGGER_STATUS_OK
);
598 condition
= lttng_trigger_get_const_condition(trigger
);
600 LTTNG_ASSERT(lttng_condition_get_type(condition
) ==
601 LTTNG_CONDITION_TYPE_EVENT_RULE_MATCHES
);
603 c_status
= lttng_condition_event_rule_matches_get_rule(condition
, &rule
);
604 LTTNG_ASSERT(c_status
== LTTNG_CONDITION_STATUS_OK
);
606 switch (lttng_event_rule_get_type(rule
)) {
607 case LTTNG_EVENT_RULE_TYPE_JUL_LOGGING
:
608 case LTTNG_EVENT_RULE_TYPE_LOG4J_LOGGING
:
609 case LTTNG_EVENT_RULE_TYPE_PYTHON_LOGGING
:
616 d_type
= lttng_event_rule_get_domain_type(rule
);
617 LTTNG_ASSERT(d_type
== agt
->domain
);
619 event
= lttng_event_rule_generate_lttng_event(rule
);
621 ret
= LTTNG_ERR_NOMEM
;
625 /* Get the internal filter expression and bytecode. */
626 filter_expression
= lttng_event_rule_get_filter(rule
);
627 if (filter_expression
) {
628 filter_expression_copy
= strdup(filter_expression
);
629 if (!filter_expression_copy
) {
630 ret
= LTTNG_ERR_NOMEM
;
634 /* Get the filter bytecode */
635 filter_bytecode
= lttng_event_rule_get_filter_bytecode(rule
);
636 if (filter_bytecode
) {
637 filter_bytecode_copy
= lttng_bytecode_copy(filter_bytecode
);
638 if (!filter_bytecode_copy
) {
639 ret
= LTTNG_ERR_NOMEM
;
645 DBG("Enabling agent event from trigger: trigger name = '%s', trigger owner uid = %d, token = %" PRIu64
,
648 lttng_trigger_get_tracer_token(trigger
));
650 ret
= agent_enable(agt
, event
, filter_bytecode_copy
, filter_expression_copy
);
651 /* Ownership was passed even in case of error. */
652 filter_expression_copy
= nullptr;
653 filter_bytecode_copy
= nullptr;
656 free(filter_expression_copy
);
657 free(filter_bytecode_copy
);
663 * Return the default event name associated with the provided UST domain. Return
666 const char *event_get_default_agent_ust_name(enum lttng_domain_type domain
)
668 const char *default_event_name
= nullptr;
671 case LTTNG_DOMAIN_LOG4J
:
672 default_event_name
= DEFAULT_LOG4J_EVENT_NAME
;
674 case LTTNG_DOMAIN_JUL
:
675 default_event_name
= DEFAULT_JUL_EVENT_NAME
;
677 case LTTNG_DOMAIN_PYTHON
:
678 default_event_name
= DEFAULT_PYTHON_EVENT_NAME
;
684 return default_event_name
;
687 static int trigger_agent_disable_one(const struct lttng_trigger
*trigger
,
689 struct agent_event
*aevent
)
695 LTTNG_ASSERT(trigger
);
696 LTTNG_ASSERT(aevent
);
699 * Actual ust event un-registration happens on the trigger
700 * un-registration at that point.
703 DBG("Event agent disabling %s (loglevel type %d, loglevel value %d) for trigger %" PRIu64
,
705 aevent
->loglevel_type
,
706 aevent
->loglevel_value
,
707 lttng_trigger_get_tracer_token(trigger
));
709 /* Already disabled? */
710 if (!AGENT_EVENT_IS_ENABLED(aevent
)) {
714 ret
= agent_disable_event(aevent
, agt
->domain
);
715 if (ret
!= LTTNG_OK
) {
727 * Disable a given agent event for a given UST session.
729 * Must be called with the RCU read lock held.
730 * Return LTTNG_OK on success or else a LTTNG_ERR* code.
732 static int event_agent_disable_one(struct ltt_ust_session
*usess
,
734 struct agent_event
*aevent
)
737 struct ltt_ust_event
*uevent
= nullptr;
738 struct ltt_ust_channel
*uchan
= nullptr;
739 const char *ust_event_name
, *ust_channel_name
;
743 LTTNG_ASSERT(aevent
);
745 DBG("Event agent disabling %s (loglevel type %d, loglevel value %d) for session %" PRIu64
,
747 aevent
->loglevel_type
,
748 aevent
->loglevel_value
,
751 /* Already disabled? */
752 if (!AGENT_EVENT_IS_ENABLED(aevent
)) {
756 if (agt
->domain
== LTTNG_DOMAIN_JUL
) {
757 ust_channel_name
= DEFAULT_JUL_CHANNEL_NAME
;
758 } else if (agt
->domain
== LTTNG_DOMAIN_LOG4J
) {
759 ust_channel_name
= DEFAULT_LOG4J_CHANNEL_NAME
;
760 } else if (agt
->domain
== LTTNG_DOMAIN_PYTHON
) {
761 ust_channel_name
= DEFAULT_PYTHON_CHANNEL_NAME
;
763 ret
= LTTNG_ERR_INVALID
;
768 * Disable it on the UST side. First get the channel reference then find
769 * the event and finally disable it.
771 uchan
= trace_ust_find_channel_by_name(usess
->domain_global
.channels
,
772 (char *) ust_channel_name
);
774 ret
= LTTNG_ERR_UST_CHAN_NOT_FOUND
;
778 ust_event_name
= event_get_default_agent_ust_name(agt
->domain
);
779 if (!ust_event_name
) {
780 ret
= LTTNG_ERR_FATAL
;
785 * Agent UST event has its loglevel type forced to
786 * LTTNG_UST_LOGLEVEL_ALL. The actual loglevel type/value filtering
787 * happens thanks to an UST filter. The following -1 is actually
788 * ignored since the type is LTTNG_UST_LOGLEVEL_ALL.
790 uevent
= trace_ust_find_event(uchan
->events
,
791 (char *) ust_event_name
,
793 LTTNG_UST_ABI_LOGLEVEL_ALL
,
796 /* If the agent event exists, it must be available on the UST side. */
797 LTTNG_ASSERT(uevent
);
800 ret
= ust_app_disable_event_glb(usess
, uchan
, uevent
);
801 if (ret
< 0 && ret
!= -LTTNG_UST_ERR_EXIST
) {
802 ret
= LTTNG_ERR_UST_DISABLE_FAIL
;
808 * Flag event that it's disabled so the shadow copy on the ust app side
809 * will disable it if an application shows up.
811 uevent
->enabled
= false;
813 ret
= agent_disable_event(aevent
, agt
->domain
);
814 if (ret
!= LTTNG_OK
) {
826 * Disable agent event matching a given trigger.
828 * Return LTTNG_OK on success or else a LTTNG_ERR* code.
830 int trigger_agent_disable(const struct lttng_trigger
*trigger
, struct agent
*agt
)
833 struct agent_event
*aevent
;
835 LTTNG_ASSERT(trigger
);
838 DBG("Event agent disabling for trigger %" PRIu64
, lttng_trigger_get_tracer_token(trigger
));
840 lttng::urcu::read_lock_guard read_lock
;
841 aevent
= agent_find_event_by_trigger(trigger
, agt
);
843 if (aevent
== nullptr) {
844 DBG2("Event agent NOT found by trigger %" PRIu64
,
845 lttng_trigger_get_tracer_token(trigger
));
846 ret
= LTTNG_ERR_UST_EVENT_NOT_FOUND
;
850 ret
= trigger_agent_disable_one(trigger
, agt
, aevent
);
852 if (ret
!= LTTNG_OK
) {
861 * Disable all agent events matching a given name for a given UST session.
863 * Return LTTNG_OK on success or else a LTTNG_ERR* code.
865 int event_agent_disable(struct ltt_ust_session
*usess
, struct agent
*agt
, const char *event_name
)
868 struct agent_event
*aevent
;
869 struct lttng_ht_iter iter
;
870 struct lttng_ht_node_str
*node
;
874 LTTNG_ASSERT(event_name
);
876 DBG("Event agent disabling %s (all loglevels) for session %" PRIu64
, event_name
, usess
->id
);
878 lttng::urcu::read_lock_guard read_lock
;
879 agent_find_events_by_name(event_name
, agt
, &iter
);
880 node
= lttng_ht_iter_get_node_str(&iter
);
882 if (node
== nullptr) {
883 DBG2("Event agent NOT found by name %s", event_name
);
884 ret
= LTTNG_ERR_UST_EVENT_NOT_FOUND
;
889 aevent
= lttng::utils::container_of(node
, &agent_event::node
);
890 ret
= event_agent_disable_one(usess
, agt
, aevent
);
892 if (ret
!= LTTNG_OK
) {
896 /* Get next duplicate agent event by name. */
897 agent_event_next_duplicate(event_name
, agt
, &iter
);
898 node
= lttng_ht_iter_get_node_str(&iter
);
904 * Disable all agent event for a given UST session.
906 * Return LTTNG_OK on success or else a LTTNG_ERR* code.
908 int event_agent_disable_all(struct ltt_ust_session
*usess
, struct agent
*agt
)
911 struct agent_event
*aevent
;
912 struct lttng_ht_iter iter
;
918 * Disable event on agent application. Continue to disable all other events
919 * if the * event is not found.
921 ret
= event_agent_disable(usess
, agt
, "*");
922 if (ret
!= LTTNG_OK
&& ret
!= LTTNG_ERR_UST_EVENT_NOT_FOUND
) {
926 /* Disable every event. */
928 lttng::urcu::read_lock_guard read_lock
;
930 cds_lfht_for_each_entry (agt
->events
->ht
, &iter
.iter
, aevent
, node
.node
) {
931 if (!AGENT_EVENT_IS_ENABLED(aevent
)) {
935 ret
= event_agent_disable(usess
, agt
, aevent
->name
);
936 if (ret
!= LTTNG_OK
) {