aboutsummaryrefslogtreecommitdiff
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
parent1ec454baf1245df4fdb5dae728da3363630ce6de (diff)
parent7e9a49ef542610609144d1afcd516dc3fafac4d6 (diff)
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 bbdfe2a462a..66ff7109f69 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();
}