Fix: use channel per domain default values
authorDavid Goulet <dgoulet@efficios.com>
Fri, 12 Apr 2013 14:21:51 +0000 (10:21 -0400)
committerDavid Goulet <dgoulet@efficios.com>
Fri, 12 Apr 2013 14:21:51 +0000 (10:21 -0400)
This is related to bug497 but does not fix it. Using the command line and the
lttng_channel_set_default_attr() API call, the default read and switch timer
were not correct for UST and Kernel domain since we now use specific default
values for each of them.

Reported-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
src/lib/lttng-ctl/lttng-ctl.c

index 107e70b6fa85d897553cb912feefed4d3dc6e491..55c0ea19d3a40bfeff226c5037383fc363687713 100644 (file)
@@ -1389,8 +1389,8 @@ void lttng_channel_set_default_attr(struct lttng_domain *domain,
        switch (domain->type) {
        case LTTNG_DOMAIN_KERNEL:
                attr->overwrite = DEFAULT_CHANNEL_OVERWRITE;
-               attr->switch_timer_interval = DEFAULT_CHANNEL_SWITCH_TIMER;
-               attr->read_timer_interval = DEFAULT_CHANNEL_READ_TIMER;
+               attr->switch_timer_interval = DEFAULT_KERNEL_CHANNEL_SWITCH_TIMER;
+               attr->read_timer_interval = DEFAULT_KERNEL_CHANNEL_READ_TIMER;
 
                attr->subbuf_size = default_get_kernel_channel_subbuf_size();
                attr->num_subbuf = DEFAULT_KERNEL_CHANNEL_SUBBUF_NUM;
@@ -1399,14 +1399,9 @@ void lttng_channel_set_default_attr(struct lttng_domain *domain,
                attr->tracefile_count = DEFAULT_KERNEL_CHANNEL_TRACEFILE_COUNT;
                break;
        case LTTNG_DOMAIN_UST:
-#if 0
-       case LTTNG_DOMAIN_UST_EXEC_NAME:
-       case LTTNG_DOMAIN_UST_PID:
-       case LTTNG_DOMAIN_UST_PID_FOLLOW_CHILDREN:
-#endif
                attr->overwrite = DEFAULT_CHANNEL_OVERWRITE;
-               attr->switch_timer_interval = DEFAULT_CHANNEL_SWITCH_TIMER;
-               attr->read_timer_interval = DEFAULT_CHANNEL_READ_TIMER;
+               attr->switch_timer_interval = DEFAULT_UST_CHANNEL_SWITCH_TIMER;
+               attr->read_timer_interval = DEFAULT_UST_CHANNEL_READ_TIMER;
 
                attr->subbuf_size = default_get_ust_channel_subbuf_size();
                attr->num_subbuf = DEFAULT_UST_CHANNEL_SUBBUF_NUM;
This page took 0.030195 seconds and 4 git commands to generate.