X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Flttng-context-callstack-legacy-impl.h;h=edd13cf5d30445278cec1b49f522e54734e6ba92;hb=b1199bd39f4b617b99518b72ceeea644b164b901;hp=b74b966a21b7c3e74663fdff6b60b827aff7ce67;hpb=51ef453614a6db2b778595b16d93283d25db974a;p=lttng-modules.git diff --git a/src/lttng-context-callstack-legacy-impl.h b/src/lttng-context-callstack-legacy-impl.h index b74b966a..edd13cf5 100644 --- a/src/lttng-context-callstack-legacy-impl.h +++ b/src/lttng-context-callstack-legacy-impl.h @@ -107,7 +107,7 @@ struct stack_trace *stack_trace_context(struct lttng_kernel_ctx_field *field, * Do not gather the userspace callstack context when the event was * triggered by the userspace callstack context saving mechanism. */ - cs_user_nesting = per_cpu(callstack_user_nesting, ctx->cpu); + cs_user_nesting = per_cpu(callstack_user_nesting, ctx->priv.reserve_cpu); if (fdata->mode == CALLSTACK_USER && cs_user_nesting >= 1) return NULL; @@ -119,8 +119,8 @@ struct stack_trace *stack_trace_context(struct lttng_kernel_ctx_field *field, * max nesting is checked in lib_ring_buffer_get_cpu(). * Check it again as a safety net. */ - cs = per_cpu_ptr(fdata->cs_percpu, ctx->cpu); - buffer_nesting = per_cpu(lib_ring_buffer_nesting, ctx->cpu) - 1; + cs = per_cpu_ptr(fdata->cs_percpu, ctx->priv.reserve_cpu); + buffer_nesting = per_cpu(lib_ring_buffer_nesting, ctx->priv.reserve_cpu) - 1; if (buffer_nesting >= RING_BUFFER_MAX_NESTING) return NULL; @@ -163,13 +163,13 @@ size_t lttng_callstack_sequence_get_size(size_t offset, struct lttng_kernel_ctx_ trace->nr_entries = 0; if (fdata->mode == CALLSTACK_USER) - ++per_cpu(callstack_user_nesting, ctx->cpu); + ++per_cpu(callstack_user_nesting, ctx->priv.reserve_cpu); /* do the real work and reserve space */ cs_types[fdata->mode].save_func(trace); if (fdata->mode == CALLSTACK_USER) - per_cpu(callstack_user_nesting, ctx->cpu)--; + per_cpu(callstack_user_nesting, ctx->priv.reserve_cpu)--; /* * Remove final ULONG_MAX delimiter. If we cannot find it, add