From: Ben Pfaff Date: Mon, 18 Jul 2011 22:13:01 +0000 (-0700) Subject: ofproto-dpif: Implement OFPAT_SET_NW_TOS. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=150a9f153b27a0d4b67388bd60d619dc78fa22ce;p=openvswitch ofproto-dpif: Implement OFPAT_SET_NW_TOS. This field was overlooked in commit b3e9b2eda9a "ofproto: Optimize datapath actions." Found by inspection. --- diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c index 9d2f5ba4..e39f6159 100644 --- a/ofproto/ofproto-dpif.c +++ b/ofproto/ofproto-dpif.c @@ -2807,6 +2807,11 @@ commit_odp_actions(struct action_xlate_ctx *ctx) base->nw_dst = flow->nw_dst; } + if (base->nw_tos != flow->nw_tos) { + nl_msg_put_u8(odp_actions, ODP_ACTION_ATTR_SET_NW_TOS, flow->nw_tos); + base->nw_tos = flow->nw_tos; + } + if (base->vlan_tci != flow->vlan_tci) { if (!(flow->vlan_tci & htons(VLAN_CFI))) { nl_msg_put_flag(odp_actions, ODP_ACTION_ATTR_STRIP_VLAN);