aboutsummaryrefslogtreecommitdiff
path: root/sys/netinet6/in6_fib.h
diff options
context:
space:
mode:
authorAlexander V. Chernikov <melifaro@FreeBSD.org>2020-10-18 17:15:47 +0000
committerAlexander V. Chernikov <melifaro@FreeBSD.org>2020-10-18 17:15:47 +0000
commit0c325f53f16731f608919a4489f96fbbe28d2344 (patch)
tree47edfa6af78113b91e7dad7f002817c6e110b01f /sys/netinet6/in6_fib.h
parent186bcdaac7c70e59eb04412ad402a6fb57b97d11 (diff)
downloadsrc-0c325f53f16731f608919a4489f96fbbe28d2344.tar.gz
src-0c325f53f16731f608919a4489f96fbbe28d2344.zip
Implement flowid calculation for outbound connections to balance
connections over multiple paths. Multipath routing relies on mbuf flowid data for both transit and outbound traffic. Current code fills mbuf flowid from inp_flowid for connection-oriented sockets. However, inp_flowid is currently not calculated for outbound connections. This change creates simple hashing functions and starts calculating hashes for TCP,UDP/UDP-Lite and raw IP if multipath routes are present in the system. Reviewed by: glebius (previous version),ae Differential Revision: https://reviews.freebsd.org/D26523
Notes
Notes: svn path=/head/; revision=366813
Diffstat (limited to 'sys/netinet6/in6_fib.h')
-rw-r--r--sys/netinet6/in6_fib.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/netinet6/in6_fib.h b/sys/netinet6/in6_fib.h
index a716674bce23..78edb5e5b776 100644
--- a/sys/netinet6/in6_fib.h
+++ b/sys/netinet6/in6_fib.h
@@ -39,4 +39,7 @@ int fib6_check_urpf(uint32_t fibnum, const struct in6_addr *dst6,
uint32_t scopeid, uint32_t flags, const struct ifnet *src_if);
struct nhop_object *fib6_lookup_debugnet(uint32_t fibnum,
const struct in6_addr *dst6, uint32_t scopeid, uint32_t flags);
+uint32_t fib6_calc_software_hash(const struct in6_addr *src,
+ const struct in6_addr *dst, unsigned short src_port, unsigned short dst_port,
+ char proto, uint32_t *phashtype);
#endif