| 2071 | } |
| 2072 | |
| 2073 | static void |
| 2074 | _ieee80211_free_node(struct ieee80211_node *ni) |
| 2075 | { |
| 2076 | struct ieee80211_node_table *nt = ni->ni_table; |
| 2077 | |
| 2078 | /* |
| 2079 | * NB: careful about referencing the vap as it may be |
| 2080 | * gone if the last reference was held by a driver. |
| 2081 | * We know the com will always be present so it's safe |
| 2082 | * to use ni_ic below to reclaim resources. |
| 2083 | */ |
| 2084 | #if 0 |
| 2085 | IEEE80211_DPRINTF(vap, IEEE80211_MSG_NODE, |
| 2086 | "%s %p<%s> in %s table\n", __func__, ni, |
| 2087 | ether_sprintf(ni->ni_macaddr), |
| 2088 | nt != NULL ? nt->nt_name : "<gone>"); |
| 2089 | #endif |
| 2090 | if (ni->ni_associd != 0) { |
| 2091 | struct ieee80211vap *vap = ni->ni_vap; |
| 2092 | if (vap->iv_aid_bitmap != NULL) |
| 2093 | IEEE80211_AID_CLR(vap, ni->ni_associd); |
| 2094 | } |
| 2095 | if (nt != NULL) |
| 2096 | ieee80211_del_node_nt(nt, ni); |
| 2097 | ni->ni_ic->ic_node_free(ni); |
| 2098 | } |
| 2099 | |
| 2100 | /* |
| 2101 | * Clear any entry in the unicast key mapping table. |
no test coverage detected