Skip to content

Commit e62e3f6

Browse files
committed
rcu: Remove deprecated rcu_lockdep_assert()
The old rcu_lockdep_assert() was retained to ease handling of incoming patches, but any use will result in deprecated warnings. However, its replacement, RCU_LOCKDEP_WARN(), is now upstream. It is therefore time to remove rcu_lockdep_assert(), which this commit does. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Reviewed-by: Josh Triplett <josh@joshtriplett.org>
1 parent 8db70b1 commit e62e3f6

File tree

1 file changed

+0
-21
lines changed

1 file changed

+0
-21
lines changed

include/linux/rcupdate.h

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -537,28 +537,8 @@ static inline int rcu_read_lock_sched_held(void)
537537

538538
#endif /* #else #ifdef CONFIG_DEBUG_LOCK_ALLOC */
539539

540-
/* Deprecate rcu_lockdep_assert(): Use RCU_LOCKDEP_WARN() instead. */
541-
static inline void __attribute((deprecated)) deprecate_rcu_lockdep_assert(void)
542-
{
543-
}
544-
545540
#ifdef CONFIG_PROVE_RCU
546541

547-
/**
548-
* rcu_lockdep_assert - emit lockdep splat if specified condition not met
549-
* @c: condition to check
550-
* @s: informative message
551-
*/
552-
#define rcu_lockdep_assert(c, s) \
553-
do { \
554-
static bool __section(.data.unlikely) __warned; \
555-
deprecate_rcu_lockdep_assert(); \
556-
if (debug_lockdep_rcu_enabled() && !__warned && !(c)) { \
557-
__warned = true; \
558-
lockdep_rcu_suspicious(__FILE__, __LINE__, s); \
559-
} \
560-
} while (0)
561-
562542
/**
563543
* RCU_LOCKDEP_WARN - emit lockdep splat if specified condition is met
564544
* @c: condition to check
@@ -596,7 +576,6 @@ static inline void rcu_preempt_sleep_check(void)
596576

597577
#else /* #ifdef CONFIG_PROVE_RCU */
598578

599-
#define rcu_lockdep_assert(c, s) deprecate_rcu_lockdep_assert()
600579
#define RCU_LOCKDEP_WARN(c, s) do { } while (0)
601580
#define rcu_sleep_check() do { } while (0)
602581

0 commit comments

Comments
 (0)