datapath: Accept any in_port mask but override to be exact match
authorAndy Zhou <azhou@nicira.com>
Thu, 1 Aug 2013 17:49:45 +0000 (10:49 -0700)
committerJesse Gross <jesse@nicira.com>
Thu, 1 Aug 2013 20:01:12 +0000 (13:01 -0700)
commit214a1331e23ca2153dc7149f7f53e6513d5a7354
tree86d3ac361a6e81729be043ae075d7cd5578a56d9
parent8b2e4432d04439ad863824ed050541ba894ccc49
datapath: Accept any in_port mask but override to be exact match

Pre mega flow, netlink allows the in_port key attribute
to be missing. Missing in_port is interpreted as DP_MAX_PORTS.

For backward compatibility, mega flow implementation will always allow
the mask of in_port to be specified, as if the in_port key attribute
is always specified.

To prevent accidental match of the DP_MAX_PORTS, which value is opaque to
the user space, we will always force the mask to be exact match,
regardless of the value supplied by the netline message. Missing
in_port mask continue to mean wildcarded match, same as other masks.

Signed-off-by: Andy Zhou <azhou@nicira.com>
Signed-off-by: Jesse Gross <jesse@nicira.com>
datapath/flow.c