]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit - net/ipv6/sit.c
[IPV6] sit: Rebinding of SIT tunnels to other interfaces
authorMichal Schmidt <mschmidt@redhat.com>
Thu, 13 Dec 2007 17:47:00 +0000 (09:47 -0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 28 Jan 2008 22:57:56 +0000 (14:57 -0800)
commit8a4a50f98bc13670bee94c40b94bc169e1263cd9
treeb262f239b7f91afc65b60032e64e15dba65e54ed
parentee34c1eb35923cc98b1c47488a615bf51a2a2afb
[IPV6] sit: Rebinding of SIT tunnels to other interfaces

This is similar to the change already done for IPIP tunnels.

Once created, a SIT tunnel can't be bound to another device.
To reproduce:

# create a tunnel:
ip tunnel add tunneltest0 mode sit remote 10.0.0.1 dev eth0
# try to change the bounding device from eth0 to eth1:
ip tunnel change tunneltest0 dev eth1
# show the result:
ip tunnel show tunneltest0

tunneltest0: ipv6/ip  remote 10.0.0.1  local any  dev eth0  ttl inherit

Notice the bound device has not changed from eth0 to eth1.

This patch fixes it. When changing the binding, it also recalculates the
MTU according to the new bound device's MTU.

Signed-off-by: Michal Schmidt <mschmidt@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/sit.c