]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
The two functions ifnet_byindex() and ifnet_byindex_locked() are exactly the
authorhselasky <hselasky@FreeBSD.org>
Tue, 15 Oct 2019 12:08:09 +0000 (12:08 +0000)
committerhselasky <hselasky@FreeBSD.org>
Tue, 15 Oct 2019 12:08:09 +0000 (12:08 +0000)
commitd234ae58eee2f08094c50f8d917c827d51c5f65c
tree75048b21a5ff4cc0e03112feede02212869333ee
parent9eb258b5cf99f9b4f29c1dd7b920449456ebaf81
The two functions ifnet_byindex() and ifnet_byindex_locked() are exactly the
same after the network stack was epochified. Merge the two into one function
and cleanup all uses of ifnet_byindex_locked().

While at it:
- Add branch prediction macros.
- Make sure the ifnet pointer is only deferred once,
  also when code optimisation is disabled.

Sponsored by: Mellanox Technologies
sys/net/if.c
sys/net/if_var.h
sys/net/route.c