dpif: Index flows using unique identifiers.
authorJoe Stringer <joestringer@nicira.com>
Wed, 24 Sep 2014 04:26:35 +0000 (16:26 +1200)
committerJoe Stringer <joestringer@nicira.com>
Tue, 2 Dec 2014 22:10:23 +0000 (14:10 -0800)
commit70e5ed6f39f02e1b378908f045d4ba2ab2000513
tree909628e8d7e984762ae48bf27ae92c7f71de6112
parentd9aa7218a27b6c2aa8fde2663ded63ae17a0e112
dpif: Index flows using unique identifiers.

This patch modifies the dpif interface to allow flows to be manipulated
using a 128-bit identifier. This allows revalidator threads to perform
datapath operations faster, as they do not need to serialise the entire
flow key for operations like flow_get and flow_delete. In conjunction
with a future patch to simplify the dump interface, this provides a
significant performance benefit for revalidation.

When handlers assemble flow_put operations, they specify a unique
identifier (UFID) for each flow as it is passed down to the datapath to
be stored with the flow. The UFID is currently provided to handlers
by the dpif during upcall processing.

When revalidators assemble flow_get or flow_del operations, they may
specify the UFID for the flow along with the key. The dpif will decide
whether to send only the UFID to the datapath, or both the UFID and flow
key. The former is preferred for newer datapaths that support UFID,
while the latter is used for backwards compatibility.

Signed-off-by: Joe Stringer <joestringer@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
12 files changed:
lib/dpctl.c
lib/dpif-netdev.c
lib/dpif-netlink.c
lib/dpif.c
lib/dpif.h
lib/odp-util.c
lib/odp-util.h
ofproto/ofproto-dpif-upcall.c
ofproto/ofproto-dpif.c
tests/dpif-netdev.at
tests/ofproto-dpif.at
tests/ofproto-macros.at