[PATCH] IPv6: Fix Prefix Length of Link-local Addresses

STALE8755d

4 messages, 2 authors, 2002-10-08 · open the first message on its own page

[PATCH] IPv6: Fix Prefix Length of Link-local Addresses

From: YOSHIFUJI Hideaki / 吉藤英明 <hidden>
Date: 2002-10-07 15:00:29

Hi,

Prefix length for link-local address should be 64, not 10.
This patch fixes prefix length of link-local address.

Following patch is against 2.4.19.

Thanks in advance.

-------------------------------------------------------------------
Patch-Name: Fix Prefix Length of Link-local Addresses
Patch-Id: FIX_2_4_19_LINKLOCAL_PREFIXLEN-20020928
Patch-Author: YOSHIFUJI Hideaki / USAGI Project [off-list ref]
Credit: YOSHIFUJI Hideaki / USAGI Project [off-list ref]
-------------------------------------------------------------------
Index: net/ipv6/addrconf.c
===================================================================
RCS file: /cvsroot/usagi/usagi-backport/linux24/net/ipv6/addrconf.c,v
retrieving revision 1.1.1.1
retrieving revision 1.1.1.1.20.1
diff -u -r1.1.1.1 -r1.1.1.1.20.1
--- net/ipv6/addrconf.c	2002/08/20 09:47:02	1.1.1.1
+++ net/ipv6/addrconf.c	2002/09/27 17:17:06	1.1.1.1.20.1
@@ -783,7 +783,7 @@
 	struct in6_addr addr;
 
 	ipv6_addr_set(&addr,  __constant_htonl(0xFE800000), 0, 0, 0);
-	addrconf_prefix_route(&addr, 10, dev, 0, RTF_ADDRCONF);
+	addrconf_prefix_route(&addr, 64, dev, 0, RTF_ADDRCONF);
 }
 
 static struct inet6_dev *addrconf_add_dev(struct net_device *dev)
@@ -1158,7 +1158,7 @@
 					flag |= IFA_HOST;
 				}
 				if (idev->dev->flags&IFF_POINTOPOINT)
-					plen = 10;
+					plen = 64;
 				else
 					plen = 96;
 
@@ -1208,7 +1208,7 @@
 {
 	struct inet6_ifaddr * ifp;
 
-	ifp = ipv6_add_addr(idev, addr, 10, IFA_LINK, IFA_F_PERMANENT);
+	ifp = ipv6_add_addr(idev, addr, 64, IFA_LINK, IFA_F_PERMANENT);
 	if (ifp) {
 		addrconf_dad_start(ifp);
 		in6_ifa_put(ifp);

Re: [PATCH] IPv6: Fix Prefix Length of Link-local Addresses

From: David S. Miller <hidden>
Date: 2002-10-07 18:57:03

   From: YOSHIFUJI Hideaki / 吉藤英明 [off-list ref]
   Date: Tue, 08 Oct 2002 00:05:59 +0900 (JST)

   Prefix length for link-local address should be 64, not 10.
   This patch fixes prefix length of link-local address.
   
   Following patch is against 2.4.19.

Patch is applied, thank you.

BTW, we start to run into conflicts now and most of USAGI patches now
I need to apply some parts by hand.  Here is one example, with this
patch:
   
   @@ -783,7 +783,7 @@
    	struct in6_addr addr;
    
    	ipv6_addr_set(&addr,  __constant_htonl(0xFE800000), 0, 0, 0);
   -	addrconf_prefix_route(&addr, 10, dev, 0, RTF_ADDRCONF);
   +	addrconf_prefix_route(&addr, 64, dev, 0, RTF_ADDRCONF);
    }
    
    static struct inet6_dev *addrconf_add_dev(struct net_device *dev)

Note in this hunk the __constant_htonl() which was transformed
to plain htonl() by already accepted USAGI patch.

It is not such a big deal now, but it may soon become larger as
bigger USAGI patches are applied.  We will need to synchronize
at some point.

Re: [PATCH] IPv6: Fix Prefix Length of Link-local Addresses

From: YOSHIFUJI Hideaki / 吉藤英明 <hidden>
Date: 2002-10-08 00:31:54

In article [off-list ref] (at Mon, 07 Oct 2002 11:55:30 -0700 (PDT)), "David S. Miller" [off-list ref] says:
BTW, we start to run into conflicts now and most of USAGI patches now
I need to apply some parts by hand.  Here is one example, with this
patch:
:
It is not such a big deal now, but it may soon become larger as
bigger USAGI patches are applied.  We will need to synchronize
at some point.
Agreed.

So,... What kind of patches do you prefer, now?

 - on top of plain kernel (2.4.19, 2.4.20, 2.4.21-preXX, or whatever)
 - plain kernel + on top of our whole patch?
 - ???

-- 
Hideaki YOSHIFUJI @ USAGI Project [off-list ref]
GPG FP: 9022 65EB 1ECF 3AD1 0BDF  80D8 4807 F894 E062 0EEA

Re: [PATCH] IPv6: Fix Prefix Length of Link-local Addresses

From: David S. Miller <hidden>
Date: 2002-10-08 19:43:21

   From: YOSHIFUJI Hideaki / 吉藤英明 [off-list ref]
   Date: Tue, 08 Oct 2002 09:37:21 +0900 (JST)

   So,... What kind of patches do you prefer, now?
   
    - on top of plain kernel (2.4.19, 2.4.20, 2.4.21-preXX, or whatever)
    - plain kernel + on top of our whole patch?
    - ???

If you send patches against 2.4.20-pre9, it would be fine.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help