MCPcopy Create free account
hub / github.com/F-Stack/f-stack / in6_pcbgroup_getbucket

Function in6_pcbgroup_getbucket

freebsd/netinet6/in6_pcbgroup.c:57–66  ·  view source on GitHub ↗

* Given a hash of whatever the covered tuple might be, return a pcbgroup * index. Where RSS is supported, try to align bucket selection with RSS CPU * affinity strategy. */

Source from the content-addressed store, hash-verified

55 * affinity strategy.
56 */
57static __inline u_int
58in6_pcbgroup_getbucket(struct inpcbinfo *pcbinfo, uint32_t hash)
59{
60
61#ifdef RSS
62 return (rss_getbucket(hash));
63#else
64 return (hash % pcbinfo->ipi_npcbgroups);
65#endif
66}
67
68/*
69 * Map a (hashtype, hash) tuple into a connection group, or NULL if the hash

Callers 2

in6_pcbgroup_byhashFunction · 0.85
in6_pcbgroup_bytupleFunction · 0.85

Calls 1

rss_getbucketFunction · 0.85

Tested by

no test coverage detected