X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=libust%2Ftracer.c;h=c9422c8fec5c27668552693e93acde510a0baf2d;hb=bc237fab2306223e429c43ff003ac06c3777be99;hp=6f3c1aeaaf58b37cfc52fd310b49f655a40d7921;hpb=909bc43f70be2b1d3efcefe33121ee1e99d9895b;p=ust.git diff --git a/libust/tracer.c b/libust/tracer.c index 6f3c1ae..c9422c8 100644 --- a/libust/tracer.c +++ b/libust/tracer.c @@ -34,7 +34,8 @@ #include #include -#include +#include + #include "tracercore.h" #include "tracer.h" #include "usterr.h" @@ -68,11 +69,7 @@ int (*ltt_statedump_functor)(struct ust_trace *trace) = ltt_statedump_default; struct module *ltt_statedump_owner; -struct chan_info_struct { - const char *name; - unsigned int def_subbufsize; - unsigned int def_subbufcount; -} chan_infos[] = { +struct chan_info_struct chan_infos[] = { [LTT_CHANNEL_METADATA] = { LTT_METADATA_CHANNEL, LTT_DEFAULT_SUBBUF_SIZE_LOW, @@ -340,7 +337,7 @@ void ltt_release_transport(struct kref *kref) */ void ltt_release_trace(struct kref *kref) { - struct ust_trace *trace = container_of(kref, + struct ust_trace *trace = _ust_container_of(kref, struct ust_trace, kref); ltt_channels_trace_free(trace->channels); free(trace); @@ -389,7 +386,8 @@ int _ltt_trace_setup(const char *trace_name) } strncpy(new_trace->trace_name, trace_name, NAME_MAX); new_trace->channels = ltt_channels_trace_alloc(&new_trace->nr_channels, - 0, 1); + ust_channels_overwrite_by_default, + ust_channels_request_collection_by_default, 1); if (!new_trace->channels) { ERR("Unable to allocate memory for chaninfo %s\n", trace_name); err = -ENOMEM;