lkml.org 
[lkml]   [2015]   [May]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH Not-for-merge 40/40] perf tools: Disable thread refcount due to bug
Date
This makes thread mg sharing test failed due to not decrement
thread->refcnt on thread__put().

Not-signed-off-by: Namhyung Kim <namhyung@kernel.org>
---
tools/perf/util/thread.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/perf/util/thread.c b/tools/perf/util/thread.c
index 702f12dc5a90..dc5ec9a5cca1 100644
--- a/tools/perf/util/thread.c
+++ b/tools/perf/util/thread.c
@@ -163,7 +163,7 @@ struct thread *thread__get(struct thread *thread)

void thread__put(struct thread *thread)
{
- if (thread && atomic_dec_and_test(&thread->refcnt)) {
+ if (thread && atomic_dec_and_test(&thread->refcnt) && 0) {
if (!RB_EMPTY_NODE(&thread->rb_node)) {
struct machine *machine = thread->mg->machine;

--
2.4.0


\
 
 \ /
  Last update: 2015-05-18 03:21    [W:0.317 / U:2.036 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site