Skip to content

Commit

Permalink
sched: Remove extra static_key*() function indirection
Browse files Browse the repository at this point in the history
I think its a bit simpler without having to follow an extra layer of static
inline fuctions. No functional change just cosmetic.

Signed-off-by: Jason Baron <jbaron@akamai.com>
Signed-off-by: Peter Zijlstra <peterz@infradead.org>
Cc: rostedt@goodmis.org
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: http://lkml.kernel.org/r/2ce52233ce200faad93b6029d90f1411cd926667.1404315388.git.jbaron@akamai.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
  • Loading branch information
Jason Baron authored and Ingo Molnar committed Jul 16, 2014
1 parent 1b09d29 commit 6e76ea8
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions kernel/sched/sched.h
Original file line number Diff line number Diff line change
Expand Up @@ -887,20 +887,10 @@ enum {
#undef SCHED_FEAT

#if defined(CONFIG_SCHED_DEBUG) && defined(HAVE_JUMP_LABEL)
static __always_inline bool static_branch__true(struct static_key *key)
{
return static_key_true(key); /* Not out of line branch. */
}

static __always_inline bool static_branch__false(struct static_key *key)
{
return static_key_false(key); /* Out of line branch. */
}

#define SCHED_FEAT(name, enabled) \
static __always_inline bool static_branch_##name(struct static_key *key) \
{ \
return static_branch__##enabled(key); \
return static_key_##enabled(key); \
}

#include "features.h"
Expand Down

0 comments on commit 6e76ea8

Please sign in to comment.