2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-31 06:15:47 +00:00

datapath: Set the correct bits for OFPAT_SET_NW_TOS action.

The DSCP bits are the high bits, not the low bits.

Reported-by: Jean Tourrilhes <jt@hpl.hp.com>
This commit is contained in:
Ben Pfaff
2010-02-11 15:19:26 -08:00
committed by Justin Pettit
parent 2d38e234f4
commit f119330116
4 changed files with 11 additions and 6 deletions

View File

@@ -151,7 +151,7 @@ flow_extract(struct ofpbuf *packet, uint16_t in_port, flow_t *flow)
if (nh) {
flow->nw_src = nh->ip_src;
flow->nw_dst = nh->ip_dst;
flow->nw_tos = nh->ip_tos & 0xfc;
flow->nw_tos = nh->ip_tos & IP_DSCP_MASK;
flow->nw_proto = nh->ip_proto;
packet->l4 = b.data;
if (!IP_IS_FRAGMENT(nh->ip_frag_off)) {