aboutsummaryrefslogtreecommitdiffstats
path: root/src/svm/message_queue.h
AgeCommit message (Collapse)AuthorFilesLines
2021-03-30svm: cleanup mq private data on fifo segment cleanupFlorin Coras1-0/+5
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I65373f2cd5a33381da1e51ed7ab7a8b1358cef29
2021-03-25svm: add producer wait functionFlorin Coras1-2/+10
Type: refactor Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I9488ad7e045c908b60b5821d9c48583f6d513c2f
2021-02-05session svm: non blocking mqFlorin Coras1-15/+63
Avoid synchronizing producers and the consumer. Instead, only use mutex or spinlock (if eventfds are configured) to synchronize producers. Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ie2aafbdc2e07fced5d5e46ee2df6b30a186faa2f
2021-01-25svm: add custom q implementation for mqFlorin Coras1-60/+47
Add separate queue implementation for the message queue as it's custom tailored for fifo segments as opposed to binary api. Also move eventfds to the private data structures. Type: refactor Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I6df0c824ecd94c7904516373f92a9fffc6b04736
2020-12-29svm: allow mq attachments at random offsetsFlorin Coras1-6/+22
Type: feature Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ic373cd2c11272da539eb4b0db27227f36f2f9688
2020-12-23svm: remove fifo segment heapFlorin Coras1-0/+2
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I518e096fe13847759806ff62009e73fd8f7451b7
2020-12-03svm: fix mutex consistency on trylockFlorin Coras1-1/+4
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I1370943935b460a1a1a22847fed2c97b1272a5e1
2020-11-30svm: make svm queue mutex robustFlorin Coras1-1/+4
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I256774c25b3c4105139a4728724a1a0c775e740f
2019-12-11session: Add mq debug cliNathan Skrzypczak1-0/+6
Type: feature This add a `show app message queue` cli command that shows mq size per app & thread. Change-Id: I5c6ce024b149fb7a47d899bc514c5a4887429982 Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2019-04-08host stack: update stale copyrightFlorin Coras1-1/+1
Change-Id: I33cd6e44d126c73c1f4c16b2041ea607b4d7f39f Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-03-12svm mq: add unit testFlorin Coras1-3/+0
Change-Id: I2f1fa15a99163b9c105707484503dc9502265c52 Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-08-10vcl: support for eventfd mq signalingFlorin Coras1-9/+49
- support eventfd based mq signaling. Based on configuration, vcl epoll/select can use either condvars or epoll on mq eventfds. - add vcl support for memfd segments - vpp explicitly registers cut-through segments with apps/vcl - if using eventfd, make ldp allow one call to libc_epoll_create. Needed for the message queue epfd - update svm_queue_t to allow blocking calls with eventfd signaling. Change-Id: I064151ac370bbe29bb16c968bf4e3659c8286bea Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-07-27vcl: use events for epoll/select/read/writeFlorin Coras1-6/+32
Have vcl poll and wait on the event message queues as opposed to constantly polling the session fifos. This also adds event signaling to cut through sessions. On the downside, because we can't wait on multiple condvars, i.e., when we have multiple message queues because of cut-through registrations, we do timed waits. Change-Id: I29ade95dba449659fe46008bb1af502276a7c5fd Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-07-18svm: make message queue more compactFlorin Coras1-2/+2
Change-Id: Id45957163c2b95a2300a8ac9104fc92b9cc928ed Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-07-17session: send ctrl msg over mqFlorin Coras1-1/+1
Change-Id: I242056bc46ddb671064665916b2687860292dcb2 Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-07-17session: use msg queue for eventsFlorin Coras1-4/+153
Change-Id: I3c58367eec2243fe19b75be78a175c5261863e9e Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-07-06svm: add unidirectional message queueFlorin Coras1-0/+154
Meant for single reader/writer message exchanges. Supports multiple message rings. Change-Id: I925de9a6ae19226c5c39a63caff76424ed123a13 Signed-off-by: Florin Coras <fcoras@cisco.com>