Skip to content

Commit

Permalink
locking/lockdep: Remove useless conditional macro
Browse files Browse the repository at this point in the history
Since #defined(CONFIG_PROVE_LOCKING) is used in the scope of #ifdef
CONFIG_PROVE_LOCKING, it can be removed.

Signed-off-by: Yuyang Du <duyuyang@gmail.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: bvanassche@acm.org
Cc: frederic@kernel.org
Cc: ming.lei@redhat.com
Cc: will.deacon@arm.com
Link: https://lkml.kernel.org/r/20190506081939.74287-5-duyuyang@gmail.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
  • Loading branch information
Yuyang Du authored and Ingo Molnar committed Jun 3, 2019
1 parent c52478f commit e7a38f6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions kernel/locking/lockdep.c
Original file line number Diff line number Diff line change
Expand Up @@ -1674,7 +1674,7 @@ check_redundant(struct lock_list *root, struct lock_class *target,
return result;
}

#if defined(CONFIG_TRACE_IRQFLAGS) && defined(CONFIG_PROVE_LOCKING)
#ifdef CONFIG_TRACE_IRQFLAGS

static inline int usage_accumulate(struct lock_list *entry, void *mask)
{
Expand Down Expand Up @@ -2152,7 +2152,7 @@ static inline void inc_chains(void)
nr_process_chains++;
}

#endif
#endif /* CONFIG_TRACE_IRQFLAGS */

static void
print_deadlock_scenario(struct held_lock *nxt, struct held_lock *prv)
Expand Down Expand Up @@ -2829,7 +2829,7 @@ static inline int validate_chain(struct task_struct *curr,
{
return 1;
}
#endif
#endif /* CONFIG_PROVE_LOCKING */

/*
* We are building curr_chain_key incrementally, so double-check
Expand Down

0 comments on commit e7a38f6

Please sign in to comment.