Remove CONFIG_PTHREAD_RWLOCK. Rwlock interfaces built unconditionally.
This commit is contained in:
parent
7bb26d2615
commit
b631dc886f
@ -337,7 +337,6 @@ typedef struct pthread_barrier_s pthread_barrier_t;
|
|||||||
typedef bool pthread_once_t;
|
typedef bool pthread_once_t;
|
||||||
#define __PTHREAD_ONCE_T_DEFINED 1
|
#define __PTHREAD_ONCE_T_DEFINED 1
|
||||||
|
|
||||||
#ifdef CONFIG_PTHREAD_RWLOCK
|
|
||||||
struct pthread_rwlock_s
|
struct pthread_rwlock_s
|
||||||
{
|
{
|
||||||
pthread_mutex_t lock;
|
pthread_mutex_t lock;
|
||||||
@ -357,7 +356,6 @@ typedef int pthread_rwlockattr_t;
|
|||||||
#define PTHREAD_MUTEX_INITIALIZER {NULL, SEM_INITIALIZER(1), -1, \
|
#define PTHREAD_MUTEX_INITIALIZER {NULL, SEM_INITIALIZER(1), -1, \
|
||||||
__PTHREAD_MUTEX_DEFAULT_FLAGS, \
|
__PTHREAD_MUTEX_DEFAULT_FLAGS, \
|
||||||
PTHREAD_MUTEX_DEFAULT, 0}
|
PTHREAD_MUTEX_DEFAULT, 0}
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_PTHREAD_CLEANUP
|
#ifdef CONFIG_PTHREAD_CLEANUP
|
||||||
/* This type describes the pthread cleanup callback (non-standard) */
|
/* This type describes the pthread cleanup callback (non-standard) */
|
||||||
@ -572,7 +570,6 @@ int pthread_once(FAR pthread_once_t *once_control,
|
|||||||
|
|
||||||
/* Pthread rwlock */
|
/* Pthread rwlock */
|
||||||
|
|
||||||
#ifdef CONFIG_PTHREAD_RWLOCK
|
|
||||||
int pthread_rwlock_destroy(FAR pthread_rwlock_t *rw_lock);
|
int pthread_rwlock_destroy(FAR pthread_rwlock_t *rw_lock);
|
||||||
int pthread_rwlock_init(FAR pthread_rwlock_t *rw_lock,
|
int pthread_rwlock_init(FAR pthread_rwlock_t *rw_lock,
|
||||||
FAR const pthread_rwlockattr_t *attr);
|
FAR const pthread_rwlockattr_t *attr);
|
||||||
@ -585,7 +582,6 @@ int pthread_rwlock_timedwrlock(FAR pthread_rwlock_t *lock,
|
|||||||
FAR const struct timespec *abstime);
|
FAR const struct timespec *abstime);
|
||||||
int pthread_rwlock_trywrlock(FAR pthread_rwlock_t *lock);
|
int pthread_rwlock_trywrlock(FAR pthread_rwlock_t *lock);
|
||||||
int pthread_rwlock_unlock(FAR pthread_rwlock_t *lock);
|
int pthread_rwlock_unlock(FAR pthread_rwlock_t *lock);
|
||||||
#endif /* CONFIG_PTHREAD_RWLOCK */
|
|
||||||
|
|
||||||
/* Pthread signal management APIs */
|
/* Pthread signal management APIs */
|
||||||
|
|
||||||
|
@ -52,10 +52,7 @@ CSRCS += pthread_mutexattr_settype.c pthread_mutexattr_gettype.c
|
|||||||
CSRCS += pthread_mutexattr_setrobust.c pthread_mutexattr_getrobust.c
|
CSRCS += pthread_mutexattr_setrobust.c pthread_mutexattr_getrobust.c
|
||||||
CSRCS += pthread_setcancelstate.c pthread_setcanceltype.c
|
CSRCS += pthread_setcancelstate.c pthread_setcanceltype.c
|
||||||
CSRCS += pthread_testcancel.c
|
CSRCS += pthread_testcancel.c
|
||||||
|
|
||||||
ifeq ($(CONFIG_PTHREAD_RWLOCK),y)
|
|
||||||
CSRCS += pthread_rwlock.c pthread_rwlock_rdlock.c pthread_rwlock_wrlock.c
|
CSRCS += pthread_rwlock.c pthread_rwlock_rdlock.c pthread_rwlock_wrlock.c
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(CONFIG_SMP),y)
|
ifeq ($(CONFIG_SMP),y)
|
||||||
CSRCS += pthread_attr_getaffinity.c pthread_attr_setaffinity.c
|
CSRCS += pthread_attr_getaffinity.c pthread_attr_setaffinity.c
|
||||||
|
@ -573,12 +573,6 @@ config PTHREAD_MUTEX_DEFAULT_UNSAFE
|
|||||||
|
|
||||||
endchoice # Default NORMAL mutex robustness
|
endchoice # Default NORMAL mutex robustness
|
||||||
|
|
||||||
config PTHREAD_RWLOCK
|
|
||||||
bool "Enable pthread rwlock API"
|
|
||||||
default n
|
|
||||||
---help---
|
|
||||||
Add supports for the rwlock interfaces
|
|
||||||
|
|
||||||
config NPTHREAD_KEYS
|
config NPTHREAD_KEYS
|
||||||
int "Maximum number of pthread keys"
|
int "Maximum number of pthread keys"
|
||||||
default 4
|
default 4
|
||||||
|
Loading…
Reference in New Issue
Block a user