mirror of
https://github.com/apache/nuttx.git
synced 2026-06-06 00:14:22 +08:00
Squashed commit of the following:
Change all calls to mq_send() and mq_timedsend() in the OS to calls to nxmq_send() and nxmq_timedsend(), making appropriate changes for differences in return values.
sched/mqueue: Add internal function nxmq_send() and nxmq_timedsend() that are equivalent to mq_send() and mq_timedsend() except that they do not create cancellation points and do to not modify the errno variable.
This commit is contained in:
+6
-5
@@ -53,8 +53,9 @@
|
||||
#include <debug.h>
|
||||
|
||||
#include <nuttx/kmalloc.h>
|
||||
#include <nuttx/fs/fs.h>
|
||||
#include <nuttx/mqueue.h>
|
||||
#include <nuttx/arch.h>
|
||||
#include <nuttx/fs/fs.h>
|
||||
#include <nuttx/audio/audio.h>
|
||||
#include <mqueue.h>
|
||||
|
||||
@@ -716,8 +717,8 @@ static inline void audio_dequeuebuffer(FAR struct audio_upperhalf_s *upper,
|
||||
msg.session = session;
|
||||
#endif
|
||||
apb->flags |= AUDIO_APB_DEQUEUED;
|
||||
mq_send(upper->usermq, (FAR const char *)&msg, sizeof(msg),
|
||||
CONFIG_AUDIO_BUFFER_DEQUEUE_PRIO);
|
||||
(void)nxmq_send(upper->usermq, (FAR const char *)&msg, sizeof(msg),
|
||||
CONFIG_AUDIO_BUFFER_DEQUEUE_PRIO);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -754,8 +755,8 @@ static inline void audio_complete(FAR struct audio_upperhalf_s *upper,
|
||||
#ifdef CONFIG_AUDIO_MULTI_SESSION
|
||||
msg.session = session;
|
||||
#endif
|
||||
mq_send(upper->usermq, (FAR const char *)&msg, sizeof(msg),
|
||||
CONFIG_AUDIO_BUFFER_DEQUEUE_PRIO);
|
||||
(void)nxmq_send(upper->usermq, (FAR const char *)&msg, sizeof(msg),
|
||||
CONFIG_AUDIO_BUFFER_DEQUEUE_PRIO);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user