From: Mathieu Desnoyers Date: Fri, 2 Sep 2016 19:20:41 +0000 (-0400) Subject: Fix: remove unlock in getcpu X-Git-Tag: v2.7.5~7 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=5ee2bb7bd214eb38f795103daaf504d5230f931b;p=lttng-ust.git Fix: remove unlock in getcpu Causes unbalanced RCU read-side lock if nesting safety net is triggered. Signed-off-by: Mathieu Desnoyers --- diff --git a/libringbuffer/frontend_api.h b/libringbuffer/frontend_api.h index 56dbef2a..8c0b7686 100644 --- a/libringbuffer/frontend_api.h +++ b/libringbuffer/frontend_api.h @@ -61,7 +61,6 @@ int lib_ring_buffer_get_cpu(const struct lttng_ust_lib_ring_buffer_config *confi if (caa_unlikely(nesting > 4)) { WARN_ON_ONCE(1); URCU_TLS(lib_ring_buffer_nesting)--; - rcu_read_unlock(); return -EPERM; } else return cpu;