CTF2: add to relayd supported trace format
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Tue, 26 Jul 2022 15:56:24 +0000 (11:56 -0400)
committerJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Fri, 19 Aug 2022 16:04:05 +0000 (12:04 -0400)
Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Change-Id: I4bf0ecbc97c64b6d9dbe78c66d2271d67d1902d0

src/bin/lttng-relayd/main.cpp
src/bin/lttng-sessiond/cmd.cpp
src/common/sessiond-comm/relayd.hpp

index d7b65cbac75e258a50890410204a6a74d308895c..5c4792bfae688544dfb843c582b1f1bdffafebeb 100644 (file)
@@ -3346,6 +3346,11 @@ static int relay_get_configuration(
 
                supported_trace_format |= LTTCOMM_RELAYD_CONFIGURATION_TRACE_FORMAT_SUPPORTED_CTF1;
 
+               if (opt_allow_ctf2) {
+                       supported_trace_format |=
+                                       LTTCOMM_RELAYD_CONFIGURATION_TRACE_FORMAT_SUPPORTED_CTF2;
+               }
+
                supported_trace_format = htobe64(supported_trace_format);
 
                lttcomm_relayd_get_configuration_specialized_query_reply s_reply = {};
index f975f31e227981589c32d13dd725bdf115d6e3df..b519f9e70e54ad7ce32e1f1205b4750f800006bf 100644 (file)
@@ -898,6 +898,8 @@ static bool is_trace_format_configuration_supported(
                        mapping = {
                                        {LTTNG_TRACE_FORMAT_DESCRIPTOR_TYPE_CTF_1,
                                                        LTTCOMM_RELAYD_CONFIGURATION_TRACE_FORMAT_SUPPORTED_CTF1},
+                                       {LTTNG_TRACE_FORMAT_DESCRIPTOR_TYPE_CTF_2,
+                                                       LTTCOMM_RELAYD_CONFIGURATION_TRACE_FORMAT_SUPPORTED_CTF2},
                        };
 
        auto it = mapping.find(trace_format.type());
index 5f7bd3dc42aca6705427cb1b209ca1ccdc034298..49d3ed1f7ea34f2fb62a9f555f346e54704c2876 100644 (file)
@@ -348,6 +348,7 @@ enum lttcomm_relayd_configuration_query_flag {
 
 enum lttcomm_relayd_configuration_trace_format_flag {
        LTTCOMM_RELAYD_CONFIGURATION_TRACE_FORMAT_SUPPORTED_CTF1 = (1 << 0),
+       LTTCOMM_RELAYD_CONFIGURATION_TRACE_FORMAT_SUPPORTED_CTF2 = (1 << 1)
 };
 
 struct lttcomm_relayd_get_configuration {
This page took 0.030468 seconds and 5 git commands to generate.