/* there is only one AP station with id= IWL_AP_ID NOTE: mutex must be held before calling this function  */
int iwl_rxon_add_station(struct iwl_priv *priv, const u8 *addr, bool is_ap)
/* there is only one AP station with id= IWL_AP_ID NOTE: mutex must be held before calling this function  */
int iwl_rxon_add_station(struct iwl_priv *priv, const u8 *addr, bool is_ap)
{
	struct ieee80211_sta *sta;
	struct ieee80211_sta_ht_cap ht_config;
	struct ieee80211_sta_ht_cap *cur_ht_config = NULL;
	u8 sta_id;
	if (priv->current_ht_config.is_ht) {
		rcu_read_lock();
		sta = ieee80211_find_sta(priv->vif, addr);
		if (sta) {
			memcpy(&ht_config, &sta->ht_cap, sizeof(ht_config));
			cur_ht_config = &ht_config;
		}
		rcu_read_unlock();
	}
	sta_id = iwl_add_station(priv, addr, is_ap, CMD_SYNC, cur_ht_config);
	iwl_sta_init_lq(priv, addr, is_ap);
	return sta_id;
}