All of lore.kernel.org
 help / color / mirror / Atom feed
* [NETFILTER 1/3]: Fix ECN target TCP marking
@ 2005-08-20  1:39 Patrick McHardy
  0 siblings, 0 replies; only message in thread
From: Patrick McHardy @ 2005-08-20  1:39 UTC (permalink / raw)
  To: David S. Miller; +Cc: Netfilter Development Mailinglist

[-- Attachment #1: Type: text/plain, Size: 258 bytes --]

Hi Dave,

these patches fix HW checksum handling in the ECN and TCPMSS target.
The second and third patch don't apply to both net-2.6 and net-2.6.14
because of the nfcache removal and renaming of skb_ip_make_writable,
I've attached one patch for each tree.


[-- Attachment #2: 01.diff --]
[-- Type: text/x-patch, Size: 1240 bytes --]

[NETFILTER]: Fix ECN target TCP marking

An incorrect check made it bail out before doing anything.

Signed-off-by: Patrick McHardy <kaber@trash.net>

---
commit a811712706846bff6ad796394ce4aa3abcc657b0
tree 58734ec94ba7a8d54accc29c5d986b242a2b5180
parent 97023145be4225d4b39c73264da10377982205ab
author Patrick McHardy <kaber@trash.net> Fri, 19 Aug 2005 08:51:18 +0200
committer Patrick McHardy <kaber@trash.net> Fri, 19 Aug 2005 08:51:18 +0200

 net/ipv4/netfilter/ipt_ECN.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/net/ipv4/netfilter/ipt_ECN.c b/net/ipv4/netfilter/ipt_ECN.c
--- a/net/ipv4/netfilter/ipt_ECN.c
+++ b/net/ipv4/netfilter/ipt_ECN.c
@@ -60,10 +60,10 @@ set_ect_tcp(struct sk_buff **pskb, const
 	if (!tcph)
 		return 0;
 
-	if (!(einfo->operation & IPT_ECN_OP_SET_ECE
-	      || tcph->ece == einfo->proto.tcp.ece)
-	    && (!(einfo->operation & IPT_ECN_OP_SET_CWR
-		  || tcph->cwr == einfo->proto.tcp.cwr)))
+	if ((!(einfo->operation & IPT_ECN_OP_SET_ECE) ||
+	     tcph->ece == einfo->proto.tcp.ece) &&
+	    ((!(einfo->operation & IPT_ECN_OP_SET_CWR) ||
+	     tcph->cwr == einfo->proto.tcp.cwr)))
 		return 1;
 
 	if (!skb_make_writable(pskb, (*pskb)->nh.iph->ihl*4+sizeof(*tcph)))

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2005-08-20  1:39 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-08-20  1:39 [NETFILTER 1/3]: Fix ECN target TCP marking Patrick McHardy

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.