diff options
author | Patrick McHardy <kaber@trash.net> | 2009-12-02 00:53:57 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-12-02 00:53:57 +0100 |
commit | b2722b1c3a893ec6021508da15b32282ec79f4da (patch) | |
tree | b3f3fbf1d9b2c80bdc2d1a7a7786498fc2b62d64 /include/net/sctp/structs.h | |
parent | Merge branch 'master' of /home/davem/src/GIT/linux-2.6/ (diff) | |
download | linux-b2722b1c3a893ec6021508da15b32282ec79f4da.tar.xz linux-b2722b1c3a893ec6021508da15b32282ec79f4da.zip |
ip_fragment: also adjust skb->truesize for packets not owned by a socket
When a large packet gets reassembled by ip_defrag(), the head skb
accounts for all the fragments in skb->truesize. If this packet is
refragmented again, skb->truesize is not re-adjusted to reflect only
the head size since its not owned by a socket. If the head fragment
then gets recycled and reused for another received fragment, it might
exceed the defragmentation limits due to its large truesize value.
skb_recycle_check() explicitly checks for linear skbs, so any recycled
skb should reflect its true size in skb->truesize. Change ip_fragment()
to also adjust the truesize value of skbs not owned by a socket.
Reported-and-tested-by: Ben Menchaca <ben@bigfootnetworks.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/sctp/structs.h')
0 files changed, 0 insertions, 0 deletions