X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Fust-metadata.cpp;h=3a2eb5ca2446b5042884d5917c468df281cb3bf5;hb=f149493493fbd8a3efa4748832c03278c96c38ca;hp=566799efd08b2016e7ce24edeeadb3cd70937d04;hpb=bacc39bbfbccc984d2b558b41cf8ab42a8592d09;p=lttng-tools.git diff --git a/src/bin/lttng-sessiond/ust-metadata.cpp b/src/bin/lttng-sessiond/ust-metadata.cpp index 566799efd..3a2eb5ca2 100644 --- a/src/bin/lttng-sessiond/ust-metadata.cpp +++ b/src/bin/lttng-sessiond/ust-metadata.cpp @@ -23,10 +23,14 @@ #define NR_CLOCK_OFFSET_SAMPLES 10 +namespace { struct offset_sample { - int64_t offset; /* correlation offset */ - uint64_t measure_delta; /* lower is better */ + /* correlation offset */ + int64_t offset; + /* lower is better */ + uint64_t measure_delta; }; +} /* namespace */ static int _lttng_field_statedump(struct ust_registry_session *session, @@ -906,12 +910,16 @@ end: /* * Should be called with session registry mutex held. + * + * RCU read lock must be held by the caller. */ int ust_metadata_channel_statedump(struct ust_registry_session *session, struct ust_registry_channel *chan) { int ret; + ASSERT_RCU_READ_LOCKED(); + /* Don't dump metadata events */ if (chan->chan_id == -1U) return 0;