* [PATCH] PKT_SCHED: dsmark should ignore ECN bits
@ 2004-12-27 19:38 Thomas Graf
2004-12-28 5:54 ` David S. Miller
0 siblings, 1 reply; 2+ messages in thread
From: Thomas Graf @ 2004-12-27 19:38 UTC (permalink / raw)
To: David S. Miller; +Cc: netdev
Taking ECN bits into account doesn't make sense. The two bits were
still unused at the time the code was written so this brings back the
old behaviour.
Signed-off-by: Thomas Graf <tgraf@suug.ch>
--- linux-2.6.10-bk1.orig/net/sched/sch_dsmark.c 2004-12-27 14:32:33.000000000 +0100
+++ linux-2.6.10-bk1/net/sched/sch_dsmark.c 2004-12-27 20:30:40.000000000 +0100
@@ -14,6 +14,7 @@
#include <linux/rtnetlink.h>
#include <net/pkt_sched.h>
#include <net/dsfield.h>
+#include <net/inet_ecn.h>
#include <asm/byteorder.h>
@@ -198,10 +199,12 @@
/* FIXME: Safe with non-linear skbs? --RR */
switch (skb->protocol) {
case __constant_htons(ETH_P_IP):
- skb->tc_index = ipv4_get_dsfield(skb->nh.iph);
+ skb->tc_index = ipv4_get_dsfield(skb->nh.iph)
+ & ~INET_ECN_MASK;
break;
case __constant_htons(ETH_P_IPV6):
- skb->tc_index = ipv6_get_dsfield(skb->nh.ipv6h);
+ skb->tc_index = ipv6_get_dsfield(skb->nh.ipv6h)
+ & ~INET_ECN_MASK;
break;
default:
skb->tc_index = 0;
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] PKT_SCHED: dsmark should ignore ECN bits
2004-12-27 19:38 [PATCH] PKT_SCHED: dsmark should ignore ECN bits Thomas Graf
@ 2004-12-28 5:54 ` David S. Miller
0 siblings, 0 replies; 2+ messages in thread
From: David S. Miller @ 2004-12-28 5:54 UTC (permalink / raw)
To: Thomas Graf; +Cc: netdev
On Mon, 27 Dec 2004 20:38:22 +0100
Thomas Graf <tgraf@suug.ch> wrote:
> Taking ECN bits into account doesn't make sense. The two bits were
> still unused at the time the code was written so this brings back the
> old behaviour.
>
> Signed-off-by: Thomas Graf <tgraf@suug.ch>
Looks good, I put this into my 2.4 tree as well.
Thanks.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2004-12-28 5:54 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-12-27 19:38 [PATCH] PKT_SCHED: dsmark should ignore ECN bits Thomas Graf
2004-12-28 5:54 ` David S. Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).