From 6fe27a7103698bf347c583f3c4199e87006da6f9 Mon Sep 17 00:00:00 2001 From: Ilya Maximets Date: Mon, 10 Dec 2018 20:05:22 +0300 Subject: ovs-thread: Drop xpthread_meutex_{un}lock finctions. There are no users of these functions. This change fixes clang build on FreeBSD: lib/ovs-thread.c:158:1: error: \ mutex 'mutex' is still held at the end of function \ [-Werror,-Wthread-safety-analysis] XPTHREAD_FUNC1(pthread_mutex_lock, pthread_mutex_t *); ^ lib/ovs-thread.c:138:5: note: expanded from macro 'XPTHREAD_FUNC1' } ^ Fixes: 4dff0893c376 ("ovs-atomic-pthreads: Use global shared locks for atomic_flag also.") Signed-off-by: Ilya Maximets Signed-off-by: Ben Pfaff --- lib/ovs-thread.c | 2 -- lib/ovs-thread.h | 5 ----- 2 files changed, 7 deletions(-) (limited to 'lib') diff --git a/lib/ovs-thread.c b/lib/ovs-thread.c index c72bc543b..b5f7424b7 100644 --- a/lib/ovs-thread.c +++ b/lib/ovs-thread.c @@ -155,8 +155,6 @@ UNLOCK_FUNCTION(rwlock, destroy, NULL); } \ } -XPTHREAD_FUNC1(pthread_mutex_lock, pthread_mutex_t *); -XPTHREAD_FUNC1(pthread_mutex_unlock, pthread_mutex_t *); XPTHREAD_FUNC1(pthread_mutexattr_init, pthread_mutexattr_t *); XPTHREAD_FUNC1(pthread_mutexattr_destroy, pthread_mutexattr_t *); XPTHREAD_FUNC2(pthread_mutexattr_settype, pthread_mutexattr_t *, int); diff --git a/lib/ovs-thread.h b/lib/ovs-thread.h index 0f9663324..1050fc29a 100644 --- a/lib/ovs-thread.h +++ b/lib/ovs-thread.h @@ -33,11 +33,6 @@ struct ovs_barrier { struct seq *seq; }; -/* Wrappers for pthread_mutex_*() that abort the process on any error. - * This is still needed when ovs-atomic-pthreads.h is used. */ -void xpthread_mutex_lock(pthread_mutex_t *mutex); -void xpthread_mutex_unlock(pthread_mutex_t *mutex); - /* Wrappers for pthread_mutexattr_*() that abort the process on any error. */ void xpthread_mutexattr_init(pthread_mutexattr_t *); void xpthread_mutexattr_destroy(pthread_mutexattr_t *); -- cgit v1.2.1