netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] IPv6: Allow 6to4 routes with SIT
@ 2003-07-12  7:55 Mika Liljeberg
  0 siblings, 0 replies; only message in thread
From: Mika Liljeberg @ 2003-07-12  7:55 UTC (permalink / raw)
  To: YOSHIFUJI Hideaki; +Cc: netdev

[-- Attachment #1: Type: text/plain, Size: 337 bytes --]

Ok, I've separated out the SIT fix. A revised anycast fix will follow.

This is against 2.5.75. The patch will allow a host to set up SIT
tunnels using gateway routes to 6to4 addresses. Previously this only
worked with an IPv4-compatible address. Use of the deprecated
IPv4-compatible addresses should not be required.

Thanks,

	MikaL


[-- Attachment #2: 2.5.75-sit.udiff --]
[-- Type: text/x-patch, Size: 553 bytes --]

diff -ur orig/linux-2.5.75/net/ipv6/sit.c linux-2.5.75/net/ipv6/sit.c
--- orig/linux-2.5.75/net/ipv6/sit.c	2003-07-10 23:14:48.000000000 +0300
+++ linux-2.5.75/net/ipv6/sit.c	2003-07-12 10:00:27.000000000 +0300
@@ -472,10 +472,13 @@
 			addr_type = ipv6_addr_type(addr6);
 		}
 
-		if ((addr_type & IPV6_ADDR_COMPATv4) == 0)
-			goto tx_error_icmp;
+		if (addr_type & IPV6_ADDR_COMPATv4)
+			dst = addr6->s6_addr32[3];
+		else
+			dst = try_6to4(addr6);
 
-		dst = addr6->s6_addr32[3];
+		if (!dst)
+			goto tx_error_icmp;
 	}
 
 	{

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-07-12  7:55 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-07-12  7:55 [PATCH] IPv6: Allow 6to4 routes with SIT Mika Liljeberg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).