]> git.baikalelectronics.ru Git - kernel.git/commit
openvswitch: Use exact lookup for flow_get and flow_del.
authorAlex Wang <alexw@nicira.com>
Tue, 1 Jul 2014 03:30:29 +0000 (20:30 -0700)
committerPravin B Shelar <pshelar@nicira.com>
Tue, 1 Jul 2014 03:47:15 +0000 (20:47 -0700)
commit5135938a69a34414620e3f29eba9010837585a2d
tree0a36962df76d37c1f44bfb683991848b7e23ed07
parent51584ec7ff043a16371bff1a2924d172ad646ebc
openvswitch: Use exact lookup for flow_get and flow_del.

Due to the race condition in userspace, there is chance that two
overlapping megaflows could be installed in datapath.  And this
causes userspace unable to delete the less inclusive megaflow flow
even after it timeout, since the flow_del logic will stop at the
first match of masked flow.

This commit fixes the bug by making the kernel flow_del and flow_get
logic check all masks in that case.

Introduced by 07f23f89e (openvswitch: Mega flow implementation).

Signed-off-by: Alex Wang <alexw@nicira.com>
Acked-by: Andy Zhou <azhou@nicira.com>
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
net/openvswitch/datapath.c
net/openvswitch/flow_table.c
net/openvswitch/flow_table.h