ofproto-dpif: Translation of indirect and all groups
authorSimon Horman <horms@verge.net.au>
Wed, 30 Oct 2013 09:17:14 +0000 (18:17 +0900)
committerBen Pfaff <blp@nicira.com>
Sat, 2 Nov 2013 19:01:14 +0000 (12:01 -0700)
commitf4fb341b51080a1959ac184434674ca86c74c2ee
treec7c40840cb457ec29dce515f55119eaae0c863af
parentbd3240ba0cec7c89d44dd78e9b3dd566ae223140
ofproto-dpif: Translation of indirect and all groups

Allow translation of indirect and all groups.  Also allow insertion of
indirect and all groups by changing the maximum permitted number in the
groups table from 0 to OFPG_MAX.

Implementation note:

After translating the actions for each bucket ctx->flow is reset to its
state prior to translation of the buckets actions. This is equivalent to
cloning the bucket before applying actions. This is my interpretation of the
OpenFlow 1.3.2 specification section 5.6.1 Group Types, which includes the
following text. I believe there is room for other interpretations.

* On all groups: "The packet is effectively cloned for each bucket; one
  packet is processed for each bucket of the group."
* On indirect groups: "This group type is effectively identical to an
  all group with one bucket."

Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Ben Pfaff <blp@nicira.com>
ofproto/ofproto-dpif-xlate.c
ofproto/ofproto-dpif.c
ofproto/ofproto-dpif.h
ofproto/ofproto.c
tests/ofproto-dpif.at
tests/ofproto.at