changeset 774:e05fd965c1ba

synch: remove unused held type sanity check function Its consumers no longer need it. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
author Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
date Sun, 11 Aug 2019 12:00:12 -0400
parents 3e2779bb68a0
children a43e4fe3eb2c
files synch.c
diffstat 1 files changed, 0 insertions(+), 17 deletions(-) [+]
line wrap: on
line diff
--- a/synch.c	Sun Aug 11 11:59:45 2019 -0400
+++ b/synch.c	Sun Aug 11 12:00:12 2019 -0400
@@ -114,23 +114,6 @@
 	held_stack_count--;
 }
 
-/*
- * Sanity check that the two synch types are equal.  In several places, we
- * want to make sure that the held structure's type matches that it truly
- * should be.  Since this is such an unlikely to fail check, we don't even
- * try to make nice user friendly error messages.
- *
- * The only way this check could fail is if a lock got acquired, then
- * re-initialized as a different type of a lock, and then destroyed.  E.g.,
- * if the code acquires a mutex (struct lock), and then tries to destroy the
- * same structure as a (struct rwlock).
- */
-static inline void sanity_check_held_synch_type(struct held_lock *held,
-						enum synch_type exp)
-{
-	VERIFY3U(held->type, ==, exp);
-}
-
 #define LOCK_DEP_GRAPH()	VERIFY0(pthread_mutex_lock(&lockdep_lock))
 #define UNLOCK_DEP_GRAPH()	VERIFY0(pthread_mutex_unlock(&lockdep_lock))