Lines Matching refs:ifindex
45 * @ifindex: the network interface
52 static inline u32 sel_netif_hashfn(const struct net *ns, int ifindex)
54 return (((uintptr_t)ns + ifindex) & (SEL_NETIF_HASH_SIZE - 1));
60 * @ifindex: the network interface
63 * Search the network interface table and return the record matching @ifindex.
68 int ifindex)
70 u32 idx = sel_netif_hashfn(ns, ifindex);
75 netif->nsec.ifindex == ifindex)
97 idx = sel_netif_hashfn(netif->nsec.ns, netif->nsec.ifindex);
122 * @ifindex: the network interface
132 static int sel_netif_sid_slow(struct net *ns, int ifindex, u32 *sid)
142 dev = dev_get_by_index(ns, ifindex);
145 __func__, ifindex);
150 netif = sel_netif_find(ns, ifindex);
162 new->nsec.ifindex = ifindex;
173 __func__, ifindex);
180 * @ifindex: the network interface
191 int sel_netif_sid(struct net *ns, int ifindex, u32 *sid)
196 netif = sel_netif_find(ns, ifindex);
204 return sel_netif_sid_slow(ns, ifindex, sid);
210 * @ifindex: the network interface
213 * This function removes the entry matching @ifindex from the network interface
217 static void sel_netif_kill(const struct net *ns, int ifindex)
223 netif = sel_netif_find(ns, ifindex);
255 sel_netif_kill(dev_net(dev), dev->ifindex);