usess = session->ust_session;
+ rcu_read_lock();
+
switch (domain) {
case LTTNG_DOMAIN_KERNEL:
{
ret = LTTNG_OK;
error:
+ rcu_read_unlock();
return ret;
}
DBG("Enabling channel %s for session %s", attr->name, session->name);
+ rcu_read_lock();
+
switch (domain) {
case LTTNG_DOMAIN_KERNEL:
{
}
error:
+ rcu_read_unlock();
return ret;
}
{
int ret;
+ rcu_read_lock();
+
switch (domain) {
case LTTNG_DOMAIN_KERNEL:
{
ret = LTTNG_OK;
error:
+ rcu_read_unlock();
return ret;
}
{
int ret;
+ rcu_read_lock();
+
switch (domain) {
case LTTNG_DOMAIN_KERNEL:
{
ret = LTTNG_OK;
error:
+ rcu_read_unlock();
return ret;
}
assert(event);
assert(channel_name);
+ rcu_read_lock();
+
switch (domain) {
case LTTNG_DOMAIN_KERNEL:
{
ret = LTTNG_OK;
error:
+ rcu_read_unlock();
return ret;
}
assert(session);
assert(channel_name);
+ rcu_read_lock();
+
switch (domain) {
case LTTNG_DOMAIN_KERNEL:
{
ret = LTTNG_OK;
error:
+ rcu_read_unlock();
return ret;
}
}
/*
- * Find the channel in the hashtable.
+ * Find the channel in the hashtable and return channel pointer. RCU read side
+ * lock MUST be acquired before calling this.
*/
struct ltt_ust_channel *trace_ust_find_channel_by_name(struct lttng_ht *ht,
char *name)
struct lttng_ht_node_str *node;
struct lttng_ht_iter iter;
- rcu_read_lock();
lttng_ht_lookup(ht, (void *)name, &iter);
node = lttng_ht_iter_get_node_str(&iter);
if (node == NULL) {
- rcu_read_unlock();
goto error;
}
- rcu_read_unlock();
DBG2("Trace UST channel %s found by name", name);
}
/*
- * Find the event in the hashtable.
+ * Find the event in the hashtable and return event pointer. RCU read side lock
+ * MUST be acquired before calling this.
*/
struct ltt_ust_event *trace_ust_find_event(struct lttng_ht *ht,
char *name, struct lttng_filter_bytecode *filter, int loglevel)