Lines Matching refs:hard_iface
487 const struct batadv_hard_iface *hard_iface, in batadv_neigh_node_get() argument
497 if (tmp_neigh_node->if_incoming != hard_iface) in batadv_neigh_node_get()
519 batadv_hardif_neigh_create(struct batadv_hard_iface *hard_iface, in batadv_hardif_neigh_create() argument
522 struct batadv_priv *bat_priv = netdev_priv(hard_iface->soft_iface); in batadv_hardif_neigh_create()
525 spin_lock_bh(&hard_iface->neigh_list_lock); in batadv_hardif_neigh_create()
528 hardif_neigh = batadv_hardif_neigh_get(hard_iface, neigh_addr); in batadv_hardif_neigh_create()
536 kref_get(&hard_iface->refcount); in batadv_hardif_neigh_create()
539 hardif_neigh->if_incoming = hard_iface; in batadv_hardif_neigh_create()
547 hlist_add_head_rcu(&hardif_neigh->list, &hard_iface->neigh_list); in batadv_hardif_neigh_create()
550 spin_unlock_bh(&hard_iface->neigh_list_lock); in batadv_hardif_neigh_create()
563 batadv_hardif_neigh_get_or_create(struct batadv_hard_iface *hard_iface, in batadv_hardif_neigh_get_or_create() argument
569 hardif_neigh = batadv_hardif_neigh_get(hard_iface, neigh_addr); in batadv_hardif_neigh_get_or_create()
573 return batadv_hardif_neigh_create(hard_iface, neigh_addr); in batadv_hardif_neigh_get_or_create()
586 batadv_hardif_neigh_get(const struct batadv_hard_iface *hard_iface, in batadv_hardif_neigh_get() argument
593 &hard_iface->neigh_list, list) { in batadv_hardif_neigh_get()
620 struct batadv_hard_iface *hard_iface, in batadv_neigh_node_create() argument
628 neigh_node = batadv_neigh_node_get(orig_node, hard_iface, neigh_addr); in batadv_neigh_node_create()
632 hardif_neigh = batadv_hardif_neigh_get_or_create(hard_iface, in batadv_neigh_node_create()
645 kref_get(&hard_iface->refcount); in batadv_neigh_node_create()
647 neigh_node->if_incoming = hard_iface; in batadv_neigh_node_create()
663 neigh_addr, orig_node->orig, hard_iface->net_dev->name); in batadv_neigh_node_create()
683 struct batadv_hard_iface *hard_iface, in batadv_neigh_node_get_or_create() argument
689 neigh_node = batadv_neigh_node_get(orig_node, hard_iface, neigh_addr); in batadv_neigh_node_get_or_create()
693 return batadv_neigh_node_create(orig_node, hard_iface, neigh_addr); in batadv_neigh_node_get_or_create()
744 struct net_device *hard_iface = NULL; in batadv_hardif_neigh_dump() local
772 hard_iface = dev_get_by_index(net, hard_ifindex); in batadv_hardif_neigh_dump()
773 if (hard_iface) in batadv_hardif_neigh_dump()
774 hardif = batadv_hardif_get_by_netdev(hard_iface); in batadv_hardif_neigh_dump()
799 if (hard_iface) in batadv_hardif_neigh_dump()
800 dev_put(hard_iface); in batadv_hardif_neigh_dump()
1235 struct batadv_hard_iface *hard_iface; in batadv_purge_orig_node() local
1262 list_for_each_entry_rcu(hard_iface, &batadv_hardif_list, list) { in batadv_purge_orig_node()
1263 if (hard_iface->if_status != BATADV_IF_ACTIVE) in batadv_purge_orig_node()
1266 if (hard_iface->soft_iface != bat_priv->soft_iface) in batadv_purge_orig_node()
1269 if (!kref_get_unless_zero(&hard_iface->refcount)) in batadv_purge_orig_node()
1274 hard_iface); in batadv_purge_orig_node()
1275 batadv_update_route(bat_priv, orig_node, hard_iface, in batadv_purge_orig_node()
1280 batadv_hardif_put(hard_iface); in batadv_purge_orig_node()
1384 struct batadv_hard_iface *hard_iface; in batadv_orig_hardif_seq_print_text() local
1387 hard_iface = batadv_hardif_get_by_netdev(net_dev); in batadv_orig_hardif_seq_print_text()
1389 if (!hard_iface || !hard_iface->soft_iface) { in batadv_orig_hardif_seq_print_text()
1394 bat_priv = netdev_priv(hard_iface->soft_iface); in batadv_orig_hardif_seq_print_text()
1401 if (hard_iface->if_status != BATADV_IF_ACTIVE) { in batadv_orig_hardif_seq_print_text()
1407 BATADV_SOURCE_VERSION, hard_iface->net_dev->name, in batadv_orig_hardif_seq_print_text()
1408 hard_iface->net_dev->dev_addr, in batadv_orig_hardif_seq_print_text()
1409 hard_iface->soft_iface->name, bat_priv->algo_ops->name); in batadv_orig_hardif_seq_print_text()
1411 bat_priv->algo_ops->orig.print(bat_priv, seq, hard_iface); in batadv_orig_hardif_seq_print_text()
1414 if (hard_iface) in batadv_orig_hardif_seq_print_text()
1415 batadv_hardif_put(hard_iface); in batadv_orig_hardif_seq_print_text()
1432 struct net_device *hard_iface = NULL; in batadv_orig_dump() local
1460 hard_iface = dev_get_by_index(net, hard_ifindex); in batadv_orig_dump()
1461 if (hard_iface) in batadv_orig_dump()
1462 hardif = batadv_hardif_get_by_netdev(hard_iface); in batadv_orig_dump()
1487 if (hard_iface) in batadv_orig_dump()
1488 dev_put(hard_iface); in batadv_orig_dump()
1497 int batadv_orig_hash_add_if(struct batadv_hard_iface *hard_iface, in batadv_orig_hash_add_if() argument
1500 struct batadv_priv *bat_priv = netdev_priv(hard_iface->soft_iface); in batadv_orig_hash_add_if()
1532 int batadv_orig_hash_del_if(struct batadv_hard_iface *hard_iface, in batadv_orig_hash_del_if() argument
1535 struct batadv_priv *bat_priv = netdev_priv(hard_iface->soft_iface); in batadv_orig_hash_del_if()
1555 hard_iface->if_num); in batadv_orig_hash_del_if()
1568 if (hard_iface == hard_iface_tmp) in batadv_orig_hash_del_if()
1571 if (hard_iface->soft_iface != hard_iface_tmp->soft_iface) in batadv_orig_hash_del_if()
1574 if (hard_iface_tmp->if_num > hard_iface->if_num) in batadv_orig_hash_del_if()
1579 hard_iface->if_num = -1; in batadv_orig_hash_del_if()