summaryrefslogtreecommitdiff
path: root/fw/esp32/components/eos/msgq.c
diff options
context:
space:
mode:
Diffstat (limited to 'fw/esp32/components/eos/msgq.c')
-rw-r--r--fw/esp32/components/eos/msgq.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/fw/esp32/components/eos/msgq.c b/fw/esp32/components/eos/msgq.c
index c704399..c200f7c 100644
--- a/fw/esp32/components/eos/msgq.c
+++ b/fw/esp32/components/eos/msgq.c
@@ -12,30 +12,27 @@ void eos_msgq_init(EOSMsgQ *msgq, EOSMsgItem *array, uint8_t size) {
msgq->array = array;
}
-int eos_msgq_push(EOSMsgQ *msgq, unsigned char type, unsigned char *buffer, uint16_t len, uint8_t flags) {
+int eos_msgq_push(EOSMsgQ *msgq, unsigned char type, unsigned char *buffer, uint16_t len) {
if ((uint8_t)(msgq->idx_w - msgq->idx_r) == msgq->size) return EOS_ERR_FULL;
uint8_t idx = IDX_MASK(msgq->idx_w, msgq->size);
msgq->array[idx].type = type;
msgq->array[idx].buffer = buffer;
msgq->array[idx].len = len;
- msgq->array[idx].flags = flags;
msgq->idx_w++;
return EOS_OK;
}
-void eos_msgq_pop(EOSMsgQ *msgq, unsigned char *type, unsigned char **buffer, uint16_t *len, uint8_t *flags) {
+void eos_msgq_pop(EOSMsgQ *msgq, unsigned char *type, unsigned char **buffer, uint16_t *len) {
if (msgq->idx_r == msgq->idx_w) {
*type = 0;
*buffer = NULL;
*len = 0;
- if (flags) *flags = 0;
} else {
uint8_t idx = IDX_MASK(msgq->idx_r, msgq->size);
*type = msgq->array[idx].type;
*buffer = msgq->array[idx].buffer;
*len = msgq->array[idx].len;
- if (flags) *flags = msgq->array[idx].flags;
msgq->idx_r++;
}
}