linux-stable-rt/net/ipv4
Herbert Xu ~{PmVHI~} f291196979 [TCP]: Avoid skb_pull if possible when trimming head
Trimming the head of an skb by calling skb_pull can cause the packet
to become unaligned if the length pulled is odd.  Since the length is
entirely arbitrary for a FIN packet carrying data, this is actually
quite common.

Unaligned data is not the end of the world, but we should avoid it if
it's easily done.  In this case it is trivial.  Since we're discarding
all of the head data it doesn't matter whether we move skb->data forward
or back.

However, it is still possible to have unaligned skb->data in general.
So network drivers should be prepared to handle it instead of crashing.

This patch also adds an unlikely marking on len < headlen since partial
ACKs on head data are extremely rare in the wild.  As the return value
of __pskb_trim_head is no longer ever NULL that has been removed.

Signed-off-by: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-06-05 15:03:37 -07:00
..
ipvs
netfilter [NETFILTER]: PPTP helper: fix sstate/cstate typo 2006-05-28 22:51:05 -07:00
Kconfig
Makefile
af_inet.c [IPV4]: inet_init() -> fs_initcall 2006-04-29 18:33:14 -07:00
ah4.c
arp.c [IPV4]: Possible cleanups. 2006-04-14 15:00:20 -07:00
datagram.c
devinet.c [IPV4]: Possible cleanups. 2006-04-14 15:00:20 -07:00
esp4.c
fib_frontend.c [IPV4]: Possible cleanups. 2006-04-14 15:00:20 -07:00
fib_hash.c
fib_lookup.h
fib_rules.c
fib_semantics.c
fib_trie.c [FIB_TRIE]: Fix leaf freeing. 2006-04-09 22:25:23 -07:00
icmp.c [PATCH] for_each_possible_cpu: network codes 2006-04-11 06:18:31 -07:00
igmp.c
inet_connection_sock.c
inet_diag.c
inet_hashtables.c [IPV4]: Possible cleanups. 2006-04-14 15:00:20 -07:00
inet_timewait_sock.c
inetpeer.c
ip_forward.c
ip_fragment.c [IPV4] ip_fragment: Always compute hash with ipfrag_lock held. 2006-04-09 22:43:55 -07:00
ip_gre.c [INET]: Use port unreachable instead of proto for tunnels 2006-04-09 22:25:29 -07:00
ip_input.c [IPV4]: Remove likely in ip_rcv_finish() 2006-05-06 18:11:39 -07:00
ip_options.c [IPV4]: ip_options_fragment() has no effect on fragmentation 2006-05-09 15:18:50 -07:00
ip_output.c [PATCH] ip_output: account for fraggap when checking to add trailer_len 2006-04-14 16:04:18 -07:00
ip_sockglue.c
ipcomp.c [NET]: Fix "ntohl(ntohs" bugs 2006-05-22 16:53:22 -07:00
ipconfig.c
ipip.c [INET]: Move no-tunnel ICMP error to tunnel4/tunnel6 2006-04-09 22:25:25 -07:00
ipmr.c
multipath.c
multipath_drr.c
multipath_random.c
multipath_rr.c
multipath_wrandom.c
netfilter.c [NETFILTER]: Add address family specific checksum helpers 2006-04-09 22:25:41 -07:00
proc.c [PATCH] for_each_possible_cpu: network codes 2006-04-11 06:18:31 -07:00
protocol.c
raw.c
route.c [IPV4]: ip_route_input panic fix 2006-04-17 17:27:11 -07:00
syncookies.c
sysctl_net_ipv4.c
tcp.c [TCP]: Fix sock_orphan dead lock 2006-05-03 23:31:35 -07:00
tcp_bic.c
tcp_cong.c
tcp_cubic.c
tcp_diag.c
tcp_highspeed.c [TCP] tcp_highspeed: Fix problem observed by Xiaoliang (David) Wei 2006-06-02 17:51:08 -07:00
tcp_htcp.c
tcp_hybla.c
tcp_input.c [TCP]: reno sacked_out count fix 2006-05-16 21:42:11 -07:00
tcp_ipv4.c [IPV4]: Possible cleanups. 2006-04-14 15:00:20 -07:00
tcp_minisocks.c
tcp_output.c [TCP]: Avoid skb_pull if possible when trimming head 2006-06-05 15:03:37 -07:00
tcp_scalable.c
tcp_timer.c
tcp_vegas.c
tcp_westwood.c
tunnel4.c [INET]: Move no-tunnel ICMP error to tunnel4/tunnel6 2006-04-09 22:25:25 -07:00
udp.c
xfrm4_input.c [INET]: Move no-tunnel ICMP error to tunnel4/tunnel6 2006-04-09 22:25:25 -07:00
xfrm4_output.c [IPSEC]: Fix IP ID selection 2006-04-29 18:33:16 -07:00
xfrm4_policy.c [NET]: Fix "ntohl(ntohs" bugs 2006-05-22 16:53:22 -07:00
xfrm4_state.c
xfrm4_tunnel.c