Type: improvement
Currently, read event signal is sent on every notification message
received and added in the queue.
With this change, signal read event only when all currently available
notification messages are received.
Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
Change-Id: Ib86d189311ce01f50167e4e97feb99df0292ad96
msg_info->msg = msg;
nlmsg_get (msg);
- /* notify process node if netlink notification processing is active */
- if (nm->nl_status == NL_STATUS_NOTIF_PROC)
- {
- vlib_process_signal_event (vlib_get_main (), nl_route_process_node.index,
- NL_EVENT_READ, 0);
- }
-
return 0;
}
if (err != -NLE_AGAIN)
vlib_process_signal_event (vlib_get_main (), nl_route_process_node.index,
NL_EVENT_ERR, 0);
+ else
+ {
+ /* If netlink notification processing is active, signal process node
+ * there were notifications read
+ */
+ if (nm->nl_status == NL_STATUS_NOTIF_PROC)
+ vlib_process_signal_event (
+ vlib_get_main (), nl_route_process_node.index, NL_EVENT_READ, 0);
+ }
return err;
}