Thread (10 messages) flat view 10 messages, 4 authors, 2006-07-07

Re: [PATCH]NET: Add ECN support for TSO

From: "Michael Chan" <mchan@broadcom.com>
Date: 2006-06-28 04:53:35

On Wed, 2006-06-28 at 14:42 +1000, Herbert Xu wrote:
On Tue, Jun 27, 2006 at 09:37:01PM -0700, Michael Chan wrote:
quoted
@@ -56,6 +55,9 @@ static inline void TCP_ECN_send(struct s
 			if (tp->ecn_flags&TCP_ECN_QUEUE_CWR) {
 				tp->ecn_flags &= ~TCP_ECN_QUEUE_CWR;
 				skb->h.th->cwr = 1;
+				if (skb_shinfo(skb)->gso_type & SKB_GSO_TCPV4)
+					skb_shinfo(skb)->gso_type |=
+						SKB_GSO_TCPV4_ECN;
As a byte-pincher I must suggest that you turn this check into something
like 

				if (skb_shinfo(skb)->gso_type)

or even

				if (skb_shinfo(skb)->gso_size)
Assuming that we'll later have GSO_TCPV6, isn't it better to check for
TCPV4 explicitly now?  Or just change it later when necessary.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help