diff options
author | Florin Coras <fcoras@cisco.com> | 2020-09-01 15:25:50 -0700 |
---|---|---|
committer | Dave Barach <openvpp@barachs.net> | 2020-09-02 14:28:19 +0000 |
commit | 8ccea00339a550902f76a5ec24c1dda5a5975eaf (patch) | |
tree | cc0c7d4270dfc2bbcf1b05c0dde11060d4d6718c | |
parent | 2e84d665542cba52461a5abcac4e05b050ffe4ff (diff) |
session: fix non-blocking msg enqueue to vpp mq
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I7228a01d38e61cc00358419b2512ca0da4f76ff5
-rw-r--r-- | src/vnet/session/application_interface.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/vnet/session/application_interface.h b/src/vnet/session/application_interface.h index cddc031ec0d..d7869312d49 100644 --- a/src/vnet/session/application_interface.h +++ b/src/vnet/session/application_interface.h @@ -581,7 +581,8 @@ app_send_io_evt_to_vpp (svm_msg_q_t * mq, u32 session_index, u8 evt_type, { if (svm_msg_q_try_lock (mq)) return -1; - if (PREDICT_FALSE (svm_msg_q_ring_is_full (mq, SESSION_MQ_IO_EVT_RING))) + if (PREDICT_FALSE (svm_msg_q_ring_is_full (mq, SESSION_MQ_IO_EVT_RING) + || svm_msg_q_is_full (mq))) { svm_msg_q_unlock (mq); return -2; |