From: Ben Pfaff Date: Fri, 26 Dec 2008 18:28:17 +0000 (-0800) Subject: Fix learning-switch STP breakage from "out_port" in flow stats request. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5d69c233557908e25f25acaa8d21da10de1a2868;p=openvswitch Fix learning-switch STP breakage from "out_port" in flow stats request. ofp_flow_stats_request recently added a new member, "out_port", to select only flows that output to a particular port. Unfortunately this code in learning-switch.c was not updated to set that member to OFPP_NONE, with the result that it would only get flows that output to port 0. This bug was found when looking at this code for another reason and thus is no guarantee that the STP code in learning-switch actually works. --- diff --git a/lib/learning-switch.c b/lib/learning-switch.c index 76636a7b..e89b2573 100644 --- a/lib/learning-switch.c +++ b/lib/learning-switch.c @@ -210,6 +210,7 @@ lswitch_run(struct lswitch *sw, struct rconn *rconn) ofsr = (struct ofp_flow_stats_request *) osr->body; ofsr->match.wildcards = htonl(OFPFW_ALL); ofsr->table_id = 0xff; + ofsr->out_port = htons(OFPP_NONE); error = rconn_send(rconn, b, NULL); if (error) {