summaryrefslogtreecommitdiffstats
path: root/sbin
diff options
context:
space:
mode:
authormelifaro <melifaro@FreeBSD.org>2015-12-08 10:50:03 +0000
committermelifaro <melifaro@FreeBSD.org>2015-12-08 10:50:03 +0000
commitca13483a3ceb41301eee9d9d194676056a9b304a (patch)
tree6ca921174b94c73570e52b7776a5a84068f7a02f /sbin
parent857f62b52e4aba63ee7b8c0eeaba0da2e8ae21e5 (diff)
downloadFreeBSD-src-ca13483a3ceb41301eee9d9d194676056a9b304a.zip
FreeBSD-src-ca13483a3ceb41301eee9d9d194676056a9b304a.tar.gz
Merge helper fib* functions used for basic lookups.
Vast majority of rtalloc(9) users require only basic info from route table (e.g. "does the rtentry interface match with the interface I have?". "what is the MTU?", "Give me the IPv4 source address to use", etc..). Instead of hand-rolling lookups, checking if rtentry is up, valid, dealing with IPv6 mtu, finding "address" ifp (almost never done right), provide easy-to-use API hiding all the complexity and returning the needed info into small on-stack structure. This change also helps hiding route subsystem internals (locking, direct rtentry accesses). Additionaly, using this API improves lookup performance since rtentry is not locked. (This is safe, since all the rtentry changes happens under both radix WLOCK and rtentry WLOCK). Sponsored by: Yandex LLC
Diffstat (limited to 'sbin')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud