android_kernel_xiaomi_sm8350/net/ipv4
Herbert Xu 36cf9acf93 [IPSEC]: Separate inner/outer mode processing on output
With inter-family transforms the inner mode differs from the outer
mode.  Attempting to handle both sides from the same function means
that it needs to handle both IPv4 and IPv6 which creates duplication
and confusion.

This patch separates the two parts on the output path so that each
function deals with one family only.

In particular, the functions xfrm4_extract_output/xfrm6_extract_output
moves the pertinent fields from the IPv4/IPv6 IP headers into a
neutral format stored in skb->cb.  This is then used by the outer mode
output functions to write the outer IP header.  In this way the output
function no longer has to know about the inner address family.

Since the extract functions are only called by tunnel modes (the only
modes that can support inter-family transforms), I've also moved the
xfrm*_tunnel_check_size calls into them.  This allows the correct ICMP
message to be sent as opposed to now where you might call icmp_send
with an IPv6 packet and vice versa.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
2008-01-28 14:53:45 -08:00
..
ipvs [NET]: Convert init_timer into setup_timer 2008-01-28 14:53:35 -08:00
netfilter
af_inet.c [TCP]: Splice receive support. 2008-01-28 14:53:31 -08:00
ah4.c
arp.c IPoIB: improve IPv4/IPv6 to IB mcast mapping functions 2008-01-25 14:15:37 -08:00
cipso_ipv4.c
datagram.c
devinet.c
esp4.c
fib_frontend.c
fib_hash.c [IPV4] FIB_HASH : Avoid unecessary loop in fn_hash_dump_zone() 2008-01-20 20:31:39 -08:00
fib_lookup.h
fib_rules.c
fib_semantics.c
fib_trie.c
icmp.c [ICMP]: ICMP_MIB_OUTMSGS increment duplicated 2008-01-21 03:39:45 -08:00
igmp.c [NET]: Convert init_timer into setup_timer 2008-01-28 14:53:35 -08:00
inet_connection_sock.c [NET]: Convert init_timer into setup_timer 2008-01-28 14:53:35 -08:00
inet_diag.c
inet_fragment.c [NET]: Convert init_timer into setup_timer 2008-01-28 14:53:35 -08:00
inet_hashtables.c
inet_lro.c
inet_timewait_sock.c
inetpeer.c
ip_forward.c
ip_fragment.c
ip_gre.c
ip_input.c
ip_options.c
ip_output.c [INET]: Fix truesize setting in ip_append_data 2008-01-23 03:11:43 -08:00
ip_sockglue.c
ipcomp.c [IPSEC]: Forbid BEET + ipcomp for now 2008-01-28 14:53:43 -08:00
ipconfig.c
ipip.c
ipmr.c [NET]: Convert init_timer into setup_timer 2008-01-28 14:53:35 -08:00
Kconfig
Makefile
netfilter.c
proc.c
protocol.c
raw.c [IPV4]: Add raw drops counter. 2008-01-28 14:53:33 -08:00
route.c [NET]: Eliminate duplicate copies of dst_discard 2008-01-28 14:53:37 -08:00
syncookies.c
sysctl_net_ipv4.c
tcp_bic.c
tcp_cong.c
tcp_cubic.c
tcp_diag.c
tcp_highspeed.c
tcp_htcp.c
tcp_hybla.c
tcp_illinois.c
tcp_input.c
tcp_ipv4.c
tcp_lp.c
tcp_minisocks.c
tcp_output.c
tcp_probe.c
tcp_scalable.c
tcp_timer.c
tcp_vegas.c
tcp_vegas.h
tcp_veno.c
tcp_westwood.c
tcp_yeah.c
tcp.c [TCP]: Make tcp_splice_data_recv() static. 2008-01-28 14:53:32 -08:00
tunnel4.c
udp_impl.h
udp.c
udplite.c
xfrm4_input.c
xfrm4_mode_beet.c [IPSEC]: Separate inner/outer mode processing on output 2008-01-28 14:53:45 -08:00
xfrm4_mode_transport.c
xfrm4_mode_tunnel.c [IPSEC]: Separate inner/outer mode processing on output 2008-01-28 14:53:45 -08:00
xfrm4_output.c [IPSEC]: Separate inner/outer mode processing on output 2008-01-28 14:53:45 -08:00
xfrm4_policy.c [IPSEC]: Merge common code into xfrm_bundle_create 2008-01-28 14:53:43 -08:00
xfrm4_state.c [IPSEC]: Separate inner/outer mode processing on output 2008-01-28 14:53:45 -08:00
xfrm4_tunnel.c