datapath: Fix tunnel reconfiguration that does not change key data.
authorBen Pfaff <blp@nicira.com>
Mon, 17 Oct 2011 18:32:23 +0000 (11:32 -0700)
committerBen Pfaff <blp@nicira.com>
Tue, 18 Oct 2011 20:31:30 +0000 (13:31 -0700)
commitb1184a78452e7160db81e379783cd18937866382
tree8fb75d7faa568381185d05fe0229953c1911fa0d
parent4879d4c7c9c7632dc7d684b9440ff84b823e588a
datapath: Fix tunnel reconfiguration that does not change key data.

Without this commit, a pair of commands like
    ovs-dpctl add-if br0 gre0,type=gre,remote_ip=192.168.5.2,csum=true
    ovs-dpctl set-if br0 gre0,csum=false
would result in a csum of "true" for gre0, that is, the second command
would silently have no effect.  This could also happen when the key data
(such as remote_ip) changed but the port hash just happened to have the
same value.

This also fixes a small kernel memory leak in this case.

An upcoming commit implements the "ovs-dpctl set-if" command mentioned
above.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
datapath/tunnel.c