tunnel: Recreate tunnel port only when the netdev status change.
authorAlex Wang <alexw@nicira.com>
Fri, 5 Dec 2014 22:02:53 +0000 (14:02 -0800)
committerAlex Wang <alexw@nicira.com>
Sun, 14 Dec 2014 00:36:18 +0000 (16:36 -0800)
commitd91b1e0e53c09826b63e7c06ca5df0749ebd40fa
treea363ddc5b8de9a34a124ffe13db98a1d7d961f25
parente8b2f7930717118634053e90495ac3b82bf141bd
tunnel: Recreate tunnel port only when the netdev status change.

On current master, the 'struct tnl_port' in tunnel module will be
recreated whenever the global connectivity sequence number changes
(e.g. when adding unrelated flow).  This is unnecessary and could
cause drop of tunnel packet if a lookup happens between the removal
and recreate.

This commit fixes the above issue by only checking the netdev's own
sequence number.

Found by code inspection.

Signed-off-by: Alex Wang <alexw@nicira.com>
Acked-by: Joe Stringer <joestringer@nicira.com>
ofproto/tunnel.c