netdev
[Top] [All Lists]

[IPV4] Clear DF bit in ip_fragment fast path

To: "David S. Miller" <davem@xxxxxxxxxxxxx>, netdev@xxxxxxxxxxx
Subject: [IPV4] Clear DF bit in ip_fragment fast path
From: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 21 Mar 2005 22:16:37 +1100
In-reply-to: <20050321105622.GA23809@xxxxxxxxxxxxxxxxxxx>
References: <20050321105622.GA23809@xxxxxxxxxxxxxxxxxxx>
Sender: netdev-bounce@xxxxxxxxxxx
User-agent: Mutt/1.5.6+20040907i
Hi Dave:

It is possible for ip_fragment() to send out head fragments with
both DF and MF set for packets with local_df set to true.  This is
because the fast path tries to only modify the MF bit of the head
fragment.

Since the offset is always zero for the head fragment, and we know
that DF should be cleared in case of local_df, we can change |= to
a straight assignment.

Signed-off-by: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>

Cheers,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

Attachment: p
Description: Text document

<Prev in Thread] Current Thread [Next in Thread>