ifnet: garbage collect unused function ifaddr_byindex().
Last use was removed in 5adea417d4.
This commit is contained in:
@@ -412,20 +412,6 @@ ifnet_byindexgen(uint16_t idx, uint16_t gen)
|
|||||||
return (NULL);
|
return (NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
struct ifaddr *
|
|
||||||
ifaddr_byindex(u_short idx)
|
|
||||||
{
|
|
||||||
struct ifnet *ifp;
|
|
||||||
struct ifaddr *ifa = NULL;
|
|
||||||
|
|
||||||
NET_EPOCH_ASSERT();
|
|
||||||
|
|
||||||
ifp = ifnet_byindex(idx);
|
|
||||||
if (ifp != NULL && (ifa = ifp->if_addr) != NULL)
|
|
||||||
ifa_ref(ifa);
|
|
||||||
return (ifa);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Network interface utility routines.
|
* Network interface utility routines.
|
||||||
*
|
*
|
||||||
|
|||||||
+1
-8
@@ -373,7 +373,7 @@ struct ifnet {
|
|||||||
* addresses which store the link-level address and the name
|
* addresses which store the link-level address and the name
|
||||||
* of the interface.
|
* of the interface.
|
||||||
* However, access to the AF_LINK address through this
|
* However, access to the AF_LINK address through this
|
||||||
* field is deprecated. Use if_addr or ifaddr_byindex() instead.
|
* field is deprecated. Use if_addr instead.
|
||||||
*/
|
*/
|
||||||
struct ifaddrhead if_addrhead; /* linked list of addresses per if */
|
struct ifaddrhead if_addrhead; /* linked list of addresses per if */
|
||||||
struct ifmultihead if_multiaddrs; /* multicast addresses configured */
|
struct ifmultihead if_multiaddrs; /* multicast addresses configured */
|
||||||
@@ -651,13 +651,6 @@ struct ifnet *ifnet_byindex_ref(u_int);
|
|||||||
*/
|
*/
|
||||||
struct ifnet *ifnet_byindexgen(uint16_t idx, uint16_t gen);
|
struct ifnet *ifnet_byindexgen(uint16_t idx, uint16_t gen);
|
||||||
|
|
||||||
/*
|
|
||||||
* Given the index, ifaddr_byindex() returns the one and only
|
|
||||||
* link-level ifaddr for the interface. You are not supposed to use
|
|
||||||
* it to traverse the list of addresses associated to the interface.
|
|
||||||
*/
|
|
||||||
struct ifaddr *ifaddr_byindex(u_short idx);
|
|
||||||
|
|
||||||
VNET_DECLARE(struct ifnethead, ifnet);
|
VNET_DECLARE(struct ifnethead, ifnet);
|
||||||
VNET_DECLARE(struct ifgrouphead, ifg_head);
|
VNET_DECLARE(struct ifgrouphead, ifg_head);
|
||||||
VNET_DECLARE(struct ifnet *, loif); /* first loopback interface */
|
VNET_DECLARE(struct ifnet *, loif); /* first loopback interface */
|
||||||
|
|||||||
Reference in New Issue
Block a user