fs: Disable priority inheritance on all semaphores used for signaling
This commit is contained in:
parent
2d057c28c8
commit
dbbe46a2bc
@ -47,9 +47,9 @@
|
||||
#include <errno.h>
|
||||
|
||||
#include <nuttx/clock.h>
|
||||
#include <nuttx/semaphore.h>
|
||||
#include <nuttx/fs/fs.h>
|
||||
#include <nuttx/net/net.h>
|
||||
#include <nuttx/semaphore.h>
|
||||
|
||||
#include <arch/irq.h>
|
||||
|
||||
@ -365,7 +365,13 @@ int poll(FAR struct pollfd *fds, nfds_t nfds, int timeout)
|
||||
int errcode;
|
||||
int ret;
|
||||
|
||||
/* This semaphore is used for signaling and, hence, should not have
|
||||
* priority inheritance enabled.
|
||||
*/
|
||||
|
||||
sem_init(&sem, 0, 0);
|
||||
sem_setprotocol(&sem, SEM_PRIO_NONE);
|
||||
|
||||
ret = poll_setup(fds, nfds, &sem);
|
||||
if (ret >= 0)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user