| 338 | MALLOC_DEFINE(M_IFMADDR, "ether_multi", "link-level multicast address"); |
| 339 | |
| 340 | struct ifnet * |
| 341 | ifnet_byindex(u_short idx) |
| 342 | { |
| 343 | struct ifnet *ifp; |
| 344 | |
| 345 | if (__predict_false(idx > V_if_index)) |
| 346 | return (NULL); |
| 347 | |
| 348 | ifp = *(struct ifnet * const volatile *)(V_ifindex_table + idx); |
| 349 | return (__predict_false(ifp == IFNET_HOLD) ? NULL : ifp); |
| 350 | } |
| 351 | |
| 352 | struct ifnet * |
| 353 | ifnet_byindex_ref(u_short idx) |
no outgoing calls
no test coverage detected