aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/jump_label.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2011-11-11 08:19:37 +0100
committerIngo Molnar <mingo@elte.hu>2011-11-11 08:19:37 +0100
commitefc96737bd82b508794d2b28061a12af4a3f7766 (patch)
treee9fe4982967b74c0d25a35a2d7f7c62d8be98a47 /kernel/jump_label.c
parentx86, perf: Add a build-time sanity test to the x86 decoder (diff)
parenttracing/latency: Fix header output for latency tracers (diff)
downloadlinux-dev-efc96737bd82b508794d2b28061a12af4a3f7766.tar.xz
linux-dev-efc96737bd82b508794d2b28061a12af4a3f7766.zip
Merge branch 'tip/perf/core' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace into perf/core
Diffstat (limited to 'kernel/jump_label.c')
-rw-r--r--kernel/jump_label.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/jump_label.c b/kernel/jump_label.c
index bbdfe2a462a0..66ff7109f697 100644
--- a/kernel/jump_label.c
+++ b/kernel/jump_label.c
@@ -66,8 +66,9 @@ void jump_label_inc(struct jump_label_key *key)
return;
jump_label_lock();
- if (atomic_add_return(1, &key->enabled) == 1)
+ if (atomic_read(&key->enabled) == 0)
jump_label_update(key, JUMP_LABEL_ENABLE);
+ atomic_inc(&key->enabled);
jump_label_unlock();
}