diff options
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/jhash.c | 15 | ||||
| -rw-r--r-- | lib/jhash.h | 2 |
2 files changed, 0 insertions, 17 deletions
diff --git a/lib/jhash.c b/lib/jhash.c index d0aff57d87..0d561ef3a4 100644 --- a/lib/jhash.c +++ b/lib/jhash.c @@ -185,18 +185,3 @@ uint32_t jhash_1word(uint32_t a, uint32_t initval) { return jhash_3words(a, 0, 0, initval); } - -/* ipv6 hash function */ -uint32_t __ipv6_addr_jhash(const struct in6_addr *a, const uint32_t initval) -{ - uint32_t v = 0; - uint32_t y[4] = {0}; - - /* Since s6_addr32 is not available is few os like FreeBSD, NetBDS, - * OMIBDS & OpenBDS. So recreating in uint32_t format. - */ - memcpy(y, a->s6_addr, sizeof(struct in6_addr)); - v = y[0] ^ y[1]; - - return jhash_3words(v, y[2], y[3], initval); -} diff --git a/lib/jhash.h b/lib/jhash.h index 1b6f879369..977421495c 100644 --- a/lib/jhash.h +++ b/lib/jhash.h @@ -45,8 +45,6 @@ extern uint32_t jhash_3words(uint32_t a, uint32_t b, uint32_t c, uint32_t initval); extern uint32_t jhash_2words(uint32_t a, uint32_t b, uint32_t initval); extern uint32_t jhash_1word(uint32_t a, uint32_t initval); -extern uint32_t __ipv6_addr_jhash(const struct in6_addr *a, - const uint32_t initval); #ifdef __cplusplus } |
