Skip to contentSkip to conversation

Trivial ipv6 fix.

PATCH In review Ralph Loader 3 participants 3 messages Aug 2, 2004 – Aug 3, 2004

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Trivial ipv6 fix.

Hi,

ipv6_addr_hash doesn't do what it's comment says. The comment was probably what was intended, not that it'll make much difference in practice.

Cheers,
Ralph.

net/addrconf.h renamed from net/addrconf.h.orig +2 -2
@@ -178,8 +178,8 @@
 	 * This will include the IEEE address token on links that support it.
 	 */
 
-	word = addr->s6_addr[2] ^ addr->s6_addr32[3];
-	word  ^= (word>>16);
+	word = addr->s6_addr32[2] ^ addr->s6_addr32[3];
+	word ^= (word >> 16);
 	word ^= (word >> 8);
 
 	return ((word ^ (word >> 4)) & 0x0f);
#1 lore raw

In article <[email protected]> (at Mon, 02 Aug 2004 20:12:08 +1200), Ralph Loader <[email protected]> says:

Quoted 3 lines

ipv6_addr_hash doesn't do what it's comment says. The comment was probably what was intended, not that it'll make much difference in practice.

Oops, David, please apply this.

Quoted 1 line

===== include/net/addrconf.h 1.17 vs edited =====

include/net/addrconf.h +2 -2
@@ -178,8 +178,8 @@
 	 * This will include the IEEE address token on links that support it.
 	 */
 
-	word = addr->s6_addr[2] ^ addr->s6_addr32[3];
-	word  ^= (word>>16);
+	word = addr->s6_addr32[2] ^ addr->s6_addr32[3];
+	word ^= (word >> 16);
 	word ^= (word >> 8);
 
 	return ((word ^ (word >> 4)) & 0x0f);
Signature · 2 lines
Hideaki YOSHIFUJI @ USAGI Project <[email protected]>
GPG FP: 9022 65EB 1ECF 3AD1 0BDF  80D8 4807 F894 E062 0EEA
#2 lore raw
Quoted 7 lines · On Mon, 02 Aug 2004 06:59:40 -0700 (PDT) YOSHIFUJI Hideaki / $B5HF#1QL@(B…

In article <[email protected]> (at Mon, 02 Aug 2004 20:12:08 +1200), Ralph Loader <[email protected]> says:

Quoted 3 lines

ipv6_addr_hash doesn't do what it's comment says. The comment was probably what was intended, not that it'll make much difference in practice.

Oops, David, please apply this.

Done, thanks guys.