tunnel: Do not set padding bits in tunnel mask.
authorBen Pfaff <blp@nicira.com>
Sun, 2 Mar 2014 01:15:00 +0000 (17:15 -0800)
committerBen Pfaff <blp@nicira.com>
Sun, 2 Mar 2014 01:38:09 +0000 (17:38 -0800)
commit87972a8fcd0f339c7229a014edd4c75fd9c1356c
tree8710b7da62dff58fc3da10a7fb87f5648f2d5c69
parent27a8cbbc8e09e66cf4097c40757e797effbdd20c
tunnel: Do not set padding bits in tunnel mask.

On most architectures other than 32-bit x86, struct flow_tnl ends with 4
padding bytes.  Until now, tnl_xlate_init() set those bytes to nonzero
values in the wildcard mask.  When the wildcard mask passed through Netlink
attributes and back to userspace, the padding bytes of course became zero
again, which caused a wildcard mask mismatch and premature deletion of the
flow in revalidation.  This commit fixes the problem.

Bug #1192516.
Reported-by: Krishna Miriyala <miriyalak@vmware.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Ethan Jackson <ethan@nicira.com>
ofproto/tunnel.c