Move protoypes for the non-standard include/semaphore.h file to the non-standard include/nuttx/semaphore.h with the other non-standard semaphore interfaces.
This commit is contained in:
parent
00cc8598c7
commit
d5b4d848d3
|
@ -138,6 +138,49 @@ int sem_tickwait(FAR sem_t *sem, systime_t start, uint32_t delay);
|
|||
|
||||
int sem_reset(FAR sem_t *sem, int16_t count);
|
||||
|
||||
/****************************************************************************
|
||||
* Function: sem_getprotocol
|
||||
*
|
||||
* Description:
|
||||
* Return the value of the semaphore protocol attribute.
|
||||
*
|
||||
* Parameters:
|
||||
* sem - A pointer to the semaphore whose attributes are to be
|
||||
* queried.
|
||||
* protocol - The user provided location in which to store the protocol
|
||||
* value.
|
||||
*
|
||||
* Return Value:
|
||||
* 0 if successful. Otherwise, -1 is returned and the errno value is set
|
||||
* appropriately.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PRIORITY_INHERITANCE
|
||||
int sem_getprotocol(FAR sem_t *sem, FAR int *protocol);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
* Function: sem_setprotocol
|
||||
*
|
||||
* Description:
|
||||
* Set semaphore protocol attribute.
|
||||
*
|
||||
* Parameters:
|
||||
* sem - A pointer to the semaphore whose attributes are to be
|
||||
* modified
|
||||
* protocol - The new protocol to use
|
||||
*
|
||||
* Return Value:
|
||||
* 0 if successful. Otherwise, -1 is returned and the errno value is set
|
||||
* appropriately.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PRIORITY_INHERITANCE
|
||||
int sem_setprotocol(FAR sem_t *sem, int protocol);
|
||||
#endif
|
||||
|
||||
#undef EXTERN
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
|
|
@ -153,13 +153,6 @@ int sem_close(FAR sem_t *sem);
|
|||
int sem_unlink(FAR const char *name);
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_PRIORITY_INHERITANCE
|
||||
/* Non-standard interfaces to manage priority inheritance */
|
||||
|
||||
int sem_getprotocol(FAR sem_t *sem, FAR int *protocol);
|
||||
int sem_setprotocol(FAR sem_t *sem, int protocol);
|
||||
#endif
|
||||
|
||||
#undef EXTERN
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
|
|
@ -39,9 +39,10 @@
|
|||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
#include <semaphore.h>
|
||||
#include <assert.h>
|
||||
|
||||
#include <nuttx/semaphore.h>
|
||||
|
||||
#ifdef CONFIG_PRIORITY_INHERITANCE
|
||||
|
||||
/****************************************************************************
|
||||
|
|
|
@ -44,6 +44,8 @@
|
|||
#include <errno.h>
|
||||
#include <debug.h>
|
||||
|
||||
#include <nuttx/semaphore.h>
|
||||
|
||||
#include "pthread/pthread.h"
|
||||
|
||||
/****************************************************************************
|
||||
|
|
|
@ -39,10 +39,11 @@
|
|||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
#include <semaphore.h>
|
||||
#include <assert.h>
|
||||
#include <errno.h>
|
||||
|
||||
#include <nuttx/semaphore.h>
|
||||
|
||||
#include "semaphore/semaphore.h"
|
||||
|
||||
#ifdef CONFIG_PRIORITY_INHERITANCE
|
||||
|
|
|
@ -118,7 +118,7 @@
|
|||
"sem_destroy","semaphore.h","","int","FAR sem_t*"
|
||||
"sem_open","semaphore.h","defined(CONFIG_FS_NAMED_SEMAPHORES)","FAR sem_t*","FAR const char*","int","..."
|
||||
"sem_post","semaphore.h","","int","FAR sem_t*"
|
||||
"sem_setprotocol","semaphore.h","defined(CONFIG_PRIORITY_INHERITANCE)","int","FAR sem_t*","int"
|
||||
"sem_setprotocol","nuttx/semaphore.h","defined(CONFIG_PRIORITY_INHERITANCE)","int","FAR sem_t*","int"
|
||||
"sem_timedwait","semaphore.h","","int","FAR sem_t*","FAR const struct timespec *"
|
||||
"sem_trywait","semaphore.h","","int","FAR sem_t*"
|
||||
"sem_unlink","semaphore.h","defined(CONFIG_FS_NAMED_SEMAPHORES)","int","FAR const char*"
|
||||
|
|
Can't render this file because it has a wrong number of fields in line 2.
|
Loading…
Reference in New Issue