liblockdep defines various macros that may expand to an expression with no effect, while the in-kernel definition does have an effect. This results in warnings from gcc when -Wunused-value is enabled, and is is enabled by -Wall. Fix this by introducing trivial functions, as function return values are generally allowed to be ignored. Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Signed-off-by: Sasha Levin <sasha.levin@oracle.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: a.p.zijlstra@chello.nl Link: http://lkml.kernel.org/r/20170525130005.5947-6-alexander.levin@verizon.com Signed-off-by: Ingo Molnar <mingo@kernel.org>
13 lines
228 B
C
13 lines
228 B
C
#ifndef _LIBLOCKDEP_DEBUG_LOCKS_H_
|
|
#define _LIBLOCKDEP_DEBUG_LOCKS_H_
|
|
|
|
#include <stddef.h>
|
|
#include <linux/compiler.h>
|
|
|
|
#define DEBUG_LOCKS_WARN_ON(x) WARN_ON(x)
|
|
|
|
extern bool debug_locks;
|
|
extern bool debug_locks_silent;
|
|
|
|
#endif
|