aboutsummaryrefslogtreecommitdiffstats
path: root/net/netfilter/xt_DSCP.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/netfilter/xt_DSCP.c')
-rw-r--r--net/netfilter/xt_DSCP.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/netfilter/xt_DSCP.c b/net/netfilter/xt_DSCP.c
index 0a229191e55b..ae8271652efa 100644
--- a/net/netfilter/xt_DSCP.c
+++ b/net/netfilter/xt_DSCP.c
@@ -99,7 +99,7 @@ tos_tg6(struct sk_buff *skb, const struct xt_action_param *par)
u_int8_t orig, nv;
orig = ipv6_get_dsfield(iph);
- nv = (orig & info->tos_mask) ^ info->tos_value;
+ nv = (orig & ~info->tos_mask) ^ info->tos_value;
if (orig != nv) {
if (!skb_make_writable(skb, sizeof(struct iphdr)))