MCPcopy Create free account
hub / github.com/F-Stack/f-stack / meta_header_emit

Function meta_header_emit

dpdk/lib/eal/common/eal_common_trace_ctf.c:114–135  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

112}
113
114static int
115meta_header_emit(char **meta, int *offset)
116{
117 struct trace *trace = trace_obj_get();
118 char uustr[RTE_UUID_STRLEN];
119 char *str = NULL;
120 int rc;
121
122 rte_uuid_unparse(trace->uuid, uustr, RTE_UUID_STRLEN);
123 rc = metadata_printf(&str,
124 "trace {\n"
125 " major = 1;\n"
126 " minor = 8;\n"
127 " uuid = \"%s\";\n"
128 " byte_order = %s;\n"
129 " packet.header := struct {\n"
130 " uint32_t magic;\n"
131 " uint8_t uuid[16];\n"
132 " };\n"
133 "};\n\n", uustr, is_be() ? "be" : "le");
134 return meta_copy(meta, offset, str, rc);
135}
136
137static int
138meta_env_emit(char **meta, int *offset)

Callers 1

trace_metadata_createFunction · 0.85

Calls 5

trace_obj_getFunction · 0.85
rte_uuid_unparseFunction · 0.85
metadata_printfFunction · 0.85
meta_copyFunction · 0.85
is_beFunction · 0.70

Tested by

no test coverage detected