Lines Matching defs:tt_global_entry
71 batadv_tt_global_del_orig_list(struct batadv_tt_global_entry *tt_global_entry);
193 * Return: a pointer to the corresponding tt_global_entry struct if the client
201 struct batadv_tt_global_entry *tt_global_entry = NULL;
206 tt_global_entry = container_of(tt_common_entry,
209 return tt_global_entry;
245 * batadv_tt_global_entry_release() - release tt_global_entry from lists and
251 struct batadv_tt_global_entry *tt_global_entry;
253 tt_global_entry = container_of(ref, struct batadv_tt_global_entry,
256 batadv_tt_global_del_orig_list(tt_global_entry);
258 kfree_rcu(tt_global_entry, common.rcu);
273 struct batadv_tt_global_entry *tt_global_entry;
276 tt_global_entry = batadv_tt_global_hash_find(bat_priv, addr, vid);
277 if (!tt_global_entry)
280 count = atomic_read(&tt_global_entry->orig_list_count);
281 batadv_tt_global_entry_put(tt_global_entry);
1430 * find out if an orig_node is already in the list of a tt_global_entry.
1554 struct batadv_tt_global_entry *tt_global_entry;
1565 tt_global_entry = batadv_tt_global_hash_find(bat_priv, tt_addr, vid);
1576 if (!tt_global_entry) {
1577 tt_global_entry = kmem_cache_zalloc(batadv_tg_cache,
1579 if (!tt_global_entry)
1582 common = &tt_global_entry->common;
1589 tt_global_entry->roam_at = 0;
1595 tt_global_entry->roam_at = jiffies;
1599 INIT_HLIST_HEAD(&tt_global_entry->orig_list);
1600 atomic_set(&tt_global_entry->orig_list_count, 0);
1601 spin_lock_init(&tt_global_entry->list_lock);
1611 batadv_tt_global_entry_put(tt_global_entry);
1615 common = &tt_global_entry->common;
1629 if (batadv_tt_global_entry_has_orig(tt_global_entry,
1632 batadv_tt_global_del_orig_list(tt_global_entry);
1643 batadv_tt_global_del_orig_list(tt_global_entry);
1662 batadv_tt_global_del_orig_list(tt_global_entry);
1664 tt_global_entry->roam_at = 0;
1669 batadv_tt_global_orig_entry_add(tt_global_entry, orig_node, ttvn,
1689 tt_global_entry->common.flags |= local_flags & BATADV_TT_CLIENT_WIFI;
1695 tt_global_entry->common.flags &= ~BATADV_TT_CLIENT_ROAM;
1698 batadv_tt_global_entry_put(tt_global_entry);
1706 * @tt_global_entry: global translation table entry to be analyzed
1713 struct batadv_tt_global_entry *tt_global_entry)
1720 head = &tt_global_entry->orig_list;
1951 * @tt_global_entry: the global entry to remove the orig_entry from
1954 * Remove an orig_entry from its list in the given tt_global_entry and
1957 * Caller must hold tt_global_entry->list_lock and ensure orig_entry->list is
1961 _batadv_tt_global_del_orig_entry(struct batadv_tt_global_entry *tt_global_entry,
1964 lockdep_assert_held(&tt_global_entry->list_lock);
1967 tt_global_entry->common.vid);
1968 atomic_dec(&tt_global_entry->orig_list_count);
1969 /* requires holding tt_global_entry->list_lock and orig_entry->list
1976 /* deletes the orig list of a tt_global_entry */
1978 batadv_tt_global_del_orig_list(struct batadv_tt_global_entry *tt_global_entry)
1984 spin_lock_bh(&tt_global_entry->list_lock);
1985 head = &tt_global_entry->orig_list;
1987 _batadv_tt_global_del_orig_entry(tt_global_entry, orig_entry);
1988 spin_unlock_bh(&tt_global_entry->list_lock);
1994 * @tt_global_entry: the global entry to remove the orig_node from
2003 struct batadv_tt_global_entry *tt_global_entry,
2012 spin_lock_bh(&tt_global_entry->list_lock);
2013 head = &tt_global_entry->orig_list;
2016 vid = tt_global_entry->common.vid;
2020 tt_global_entry->common.addr,
2022 _batadv_tt_global_del_orig_entry(tt_global_entry,
2026 spin_unlock_bh(&tt_global_entry->list_lock);
2035 struct batadv_tt_global_entry *tt_global_entry,
2048 head = &tt_global_entry->orig_list;
2059 tt_global_entry->common.flags |= BATADV_TT_CLIENT_ROAM;
2060 tt_global_entry->roam_at = jiffies;
2065 batadv_tt_global_del_orig_node(bat_priv, tt_global_entry,
2085 struct batadv_tt_global_entry *tt_global_entry;
2088 tt_global_entry = batadv_tt_global_hash_find(bat_priv, addr, vid);
2089 if (!tt_global_entry)
2093 batadv_tt_global_del_orig_node(bat_priv, tt_global_entry,
2096 if (hlist_empty(&tt_global_entry->orig_list))
2097 batadv_tt_global_free(bat_priv, tt_global_entry,
2117 tt_global_entry->common.addr,
2121 batadv_tt_global_del_orig_list(tt_global_entry);
2122 batadv_tt_global_free(bat_priv, tt_global_entry, message);
2125 batadv_tt_global_del_roaming(bat_priv, tt_global_entry,
2130 batadv_tt_global_entry_put(tt_global_entry);
2292 struct batadv_tt_global_entry *tt_global_entry)
2295 tt_global_entry->common.flags & BATADV_TT_CLIENT_WIFI)
2300 tt_global_entry->common.flags & BATADV_TT_CLIENT_ISOLA)
2326 struct batadv_tt_global_entry *tt_global_entry = NULL;
2337 tt_global_entry = batadv_tt_global_hash_find(bat_priv, addr, vid);
2338 if (!tt_global_entry)
2345 _batadv_is_ap_isolated(tt_local_entry, tt_global_entry))
2349 best_entry = batadv_transtable_best_orig(bat_priv, tt_global_entry);
2358 batadv_tt_global_entry_put(tt_global_entry);
2674 const struct batadv_tt_global_entry *tt_global_entry;
2681 tt_global_entry = container_of(tt_common_entry,
2685 return batadv_tt_global_entry_has_orig(tt_global_entry, orig_node,
3684 struct batadv_tt_global_entry *tt_global_entry;
3699 tt_global_entry = batadv_tt_global_hash_find(bat_priv, src, vid);
3700 if (!tt_global_entry)
3703 if (_batadv_is_ap_isolated(tt_local_entry, tt_global_entry))
3706 batadv_tt_global_entry_put(tt_global_entry);
3812 struct batadv_tt_global_entry *tt_global_entry;
3815 tt_global_entry = batadv_tt_global_hash_find(bat_priv, addr, vid);
3816 if (!tt_global_entry)
3819 ret = tt_global_entry->common.flags & BATADV_TT_CLIENT_ROAM;
3820 batadv_tt_global_entry_put(tt_global_entry);