diff options
author | Ben Pfaff <blp@nicira.com> | 2011-07-18 15:17:57 -0700 |
---|---|---|
committer | Ben Pfaff <blp@nicira.com> | 2011-07-28 11:22:00 -0700 |
commit | 4927c517cc2373b4957e75328d6d347ba844d23d (patch) | |
tree | 06ac4d1bafdf2268b316bbd53d74783e57871bcd | |
parent | 6cd1fd9128bb9719fad0a0f210308069f71fafd6 (diff) |
ofproto-dpif: Ignore ECN bits in OFPAT_SET_NW_TOS actions.
OpenFlow 1.0 doesn't say that the ECN bits in OFPAT_SET_NW_TOS actions must
be zero, but Open vSwitch ODP implementations do require that, so mask off
those bits before storing the nw_tos into the flow.
-rw-r--r-- | ofproto/ofproto.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ofproto/ofproto.c b/ofproto/ofproto.c index 737b86b5..8720ae7e 100644 --- a/ofproto/ofproto.c +++ b/ofproto/ofproto.c @@ -2394,8 +2394,8 @@ do_xlate_actions(const union ofp_action *in, size_t n_in, case OFPAT_SET_NW_TOS: nl_msg_put_u8(ctx->odp_actions, ODP_ACTION_ATTR_SET_NW_TOS, - ia->nw_tos.nw_tos); - ctx->flow.nw_tos = ia->nw_tos.nw_tos; + ia->nw_tos.nw_tos & IP_DSCP_MASK); + ctx->flow.nw_tos = ia->nw_tos.nw_tos & IP_DSCP_MASK; break; case OFPAT_SET_TP_SRC: |