[ovs-git] Open vSwitch: revalidator: Prevent handling the same flow twice. (master)

dev at openvswitch.org dev at openvswitch.org
Thu Apr 24 01:03:04 UTC 2014

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Open vSwitch".

The branch, master has been updated
       via  73a3c4757e596ff156d40f41496a0264373e5bc4 (commit)
      from  c12cea0e269986bb0ab75a702da760db745b8143 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 73a3c4757e596ff156d40f41496a0264373e5bc4
Diffs: http://openvswitch.org/cgi-bin/gitweb.cgi?p=openvswitch;a=commitdiff;h=73a3c4757e596ff156d40f41496a0264373e5bc4
Author: Joe Stringer <joestringer at nicira.com>
revalidator: Prevent handling the same flow twice.
When the datapath flow table is modified while a flow dump operation is
in progress, it is possible for the same flow to be dumped twice. In
such cases, revalidators may perform redundant work, or attempt to
delete the same flow twice.

This was causing intermittent testsuite failures for test #670 -
"ofproto-dpif, active-backup bonding" where a flow (that had not
previously been dumped) was dumped, revalidated and deleted twice.

The logs show errors such as:
"failed to flow_get (No such file or directory) skb_priority(0),..."
"failed to flow_del (No such file or directory) skb_priority(0),..."

This patch adds a 'flow_exists' field to 'struct udpif_key' to track
whether the flow is (in progress) to be deleted. After doing a ukey
lookup, we check whether ukey->mark or ukey->flow indicates that the
flow has already been handled. If it has already been handled, we skip
handling the flow again.

We also defer ukey cleanup for flows that fail revalidation, so that the
ukey will still exist if the same flow is dumped twice. This allows the
above logic to work in this case.

Signed-off-by: Joe Stringer <joestringer at nicira.com>
Acked-by: Alex Wang <alexw at nicira.com>


Summary of changes:
 ofproto/ofproto-dpif-upcall.c |   21 ++++++++++++++++++++-
 1 file changed, 20 insertions(+), 1 deletion(-)

Open vSwitch

More information about the git mailing list