ip6_tunnel: add optional fwmark inherit
authorEric Dumazet <eric.dumazet@gmail.com>
Tue, 20 Sep 2011 18:50:00 +0000 (14:50 -0400)
committerDavid S. Miller <davem@davemloft.net>
Tue, 20 Sep 2011 18:50:00 +0000 (14:50 -0400)
commitd24f22f3df9ac3f3af95e850df0b576d41bd3cfe
treedb5cf4d94fa9b56fafa677dda417fc1f9a919cc7
parent46151ae81758f05086e17fd4e4da129afe100f93
ip6_tunnel: add optional fwmark inherit

Add IP6_TNL_F_USE_ORIG_FWMARK to ip6_tunnel, so that ip6_tnl_xmit2()
makes a route lookup taking into account skb->fwmark and doesnt cache
lookup result.

This permits more flexibility in policies and firewall setups.

To setup such a tunnel, "fwmark inherit" option should be added to "ip
-f inet6 tunnel" command.

Reported-by: Anders Franzen <Anders.Franzen@ericsson.com>
CC: Hans Schillström <hans.schillstrom@ericsson.com>
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/ip6_tunnel.h
net/ipv6/ip6_tunnel.c