vswitchd: Only re-learn from flows that output to OFPP_NORMAL.
authorBen Pfaff <blp@nicira.com>
Fri, 6 Aug 2010 18:46:24 +0000 (11:46 -0700)
committerBen Pfaff <blp@nicira.com>
Fri, 6 Aug 2010 19:59:48 +0000 (12:59 -0700)
commit26d79bf2686b08a49c881d5bb54501d7584f5111
tree6d1e0843e6c6325a360bab9e29927fcb56966791
parentd12f7113b047455d410cb54862f339717d4c932f
vswitchd: Only re-learn from flows that output to OFPP_NORMAL.

Commit e96a4d8035 "bridge: Feed flow stats into learning table." started
feeding flow statistics back into the learning table, but it did not
distinguish between flows with and flows without an action that outputs to
OFPP_NORMAL.  Flows without such an action are not put into the learning
table initially, because bridge_normal_ofhook_cb() is not called for them,
but since that commit they have been put into the learning table when their
flows are reassessed.

This is inconsistent--flows without OFPP_NORMAL should either be learned
from all the time or never, not sometimes.  I can see valid arguments both
ways, but since it was always my intention not to learn from such flows,
this commit disables learning from them.

Problem found by code inspection.  I don't know of any observed bug that
this fixes.
ofproto/ofproto.c
ofproto/ofproto.h
vswitchd/bridge.c