In theory it is possible that ovn-controller tried to install flows by calling ofctrl_put() while ofctrl is at a state other than S_UPDATE_FLOWS thus not able to install. So, when entering S_UPDATE_FLOWS, we should immediately wakeup the main loop so that any pending flows can be installed without being delayed.
Signed-off-by: Han Zhou <[email protected]> --- controller/ofctrl.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/controller/ofctrl.c b/controller/ofctrl.c index eb66d0348..9f9cd56ef 100644 --- a/controller/ofctrl.c +++ b/controller/ofctrl.c @@ -669,6 +669,10 @@ run_S_CLEAR_FLOWS(void) } state = S_UPDATE_FLOWS; + + /* Give a chance for the main loop to call ofctrl_put() in case there were + * pending flows waiting ofctrl state change to S_UPDATE_FLOWS. */ + poll_immediate_wake(); } static void -- 2.30.2 _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
