From 3f23fcd943026eb324992f99a5beaecdb4f4a5ce Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Thu, 16 Nov 2017 08:15:37 +0100 Subject: LOCKING(9): Remove dead code (KDTRACE_HOOKS) --- rtemsbsd/rtems/rtems-kernel-sx.c | 19 ------------------- 1 file changed, 19 deletions(-) (limited to 'rtemsbsd/rtems/rtems-kernel-sx.c') diff --git a/rtemsbsd/rtems/rtems-kernel-sx.c b/rtemsbsd/rtems/rtems-kernel-sx.c index 57087eef..1092afe8 100644 --- a/rtemsbsd/rtems/rtems-kernel-sx.c +++ b/rtemsbsd/rtems/rtems-kernel-sx.c @@ -49,9 +49,6 @@ static void assert_sx(const struct lock_object *lock, int what); static void lock_sx(struct lock_object *lock, uintptr_t how); -#ifdef KDTRACE_HOOKS -static int owner_sx(const struct lock_object *lock, struct thread **owner); -#endif static uintptr_t unlock_sx(struct lock_object *lock); struct lock_class lock_class_sx = { @@ -63,9 +60,6 @@ struct lock_class lock_class_sx = { #endif .lc_lock = lock_sx, .lc_unlock = unlock_sx, -#ifdef KDTRACE_HOOKS - .lc_owner = owner_sx, -#endif }; #define sx_xholder(sx) rtems_bsd_mutex_owner(&(sx)->mutex) @@ -94,19 +88,6 @@ unlock_sx(struct lock_object *lock) return (0); } -#ifdef KDTRACE_HOOKS -int -owner_sx(struct lock_object *lock, struct thread **owner) -{ - struct sx *sx = (struct sx *)lock; - uintptr_t x = sx->sx_lock; - - *owner = (struct thread *)SX_OWNER(x); - return ((x & SX_LOCK_SHARED) != 0 ? (SX_SHARERS(x) != 0) : - (*owner != NULL)); -} -#endif - void sx_sysinit(void *arg) { -- cgit v1.2.3