Lines Matching refs:wrole
87 struct rtw_wifi_role_t *wrole, const u16 id) in _phl_wrole_bcmc_id_set() argument
89 macid_ctl->wrole_bmc[wrole->id] = id; in _phl_wrole_bcmc_id_set()
97 struct rtw_wifi_role_t *wrole = phl_sta->wrole; in _phl_alloc_macid() local
103 if (wrole == NULL) { in _phl_alloc_macid()
122 _phl_macid_map_set(&mc->wifi_role_usedmap[wrole->id][0], mid); in _phl_alloc_macid()
127 _phl_wrole_bcmc_id_set(mc, wrole, mid); in _phl_alloc_macid()
156 struct rtw_wifi_role_t *wrole = phl_sta->wrole; in _phl_release_macid() local
178 _phl_macid_map_clr(&macid_ctl->wifi_role_usedmap[wrole->id][0], phl_sta->macid); in _phl_release_macid()
213 rtw_phl_wrole_bcmc_id_get(void *phl, struct rtw_wifi_role_t *wrole) in rtw_phl_wrole_bcmc_id_get() argument
218 return macid_ctl->wrole_bmc[wrole->id]; in rtw_phl_wrole_bcmc_id_get()
317 u16 macid, struct rtw_wifi_role_t *wrole) in rtw_phl_macid_is_wrole_specific() argument
331 if (iface_bmp || i != wrole->id) in rtw_phl_macid_is_wrole_specific()
616 PHL_INFO("\t[STA] WROLE-IDX:%d wlan_mode:0x%02x\n", phl_sta->wrole->id, phl_sta->wmode); in _phl_dump_stainfo()
707 struct phl_info_t *phl_info, struct rtw_wifi_role_t *wrole) in phl_dump_stainfo_per_role() argument
717 wrole->id, in phl_dump_stainfo_per_role()
718 _rtype_str[wrole->type], in phl_dump_stainfo_per_role()
719 wrole->mac_addr[0], wrole->mac_addr[1], wrole->mac_addr[2], in phl_dump_stainfo_per_role()
720 wrole->mac_addr[3], wrole->mac_addr[4], wrole->mac_addr[5]); in phl_dump_stainfo_per_role()
722 _os_spinlock(drv, &wrole->assoc_sta_queue.lock, _bh, NULL); in phl_dump_stainfo_per_role()
724 if (wrole->type == PHL_RTYPE_STATION && wrole->mstate == MLME_LINKED) in phl_dump_stainfo_per_role()
726 else if (wrole->type == PHL_RTYPE_TDLS) in phl_dump_stainfo_per_role()
727 sta_cnt = wrole->assoc_sta_queue.cnt; in phl_dump_stainfo_per_role()
729 sta_cnt = wrole->assoc_sta_queue.cnt - 1; in phl_dump_stainfo_per_role()
732 phl_list_for_loop(sta, struct rtw_phl_stainfo_t, &wrole->assoc_sta_queue.queue, list) { in phl_dump_stainfo_per_role()
736 _os_spinunlock(drv, &wrole->assoc_sta_queue.lock, _bh, NULL); in phl_dump_stainfo_per_role()
780 struct rtw_wifi_role_t *wrole, struct rtw_phl_stainfo_t *sta) in _phl_self_stainfo_chk() argument
785 switch (wrole->type) { in _phl_self_stainfo_chk()
788 _os_mem_cpy(drv, sta->mac_addr, wrole->mac_addr, MAC_ALEN); in _phl_self_stainfo_chk()
796 if (_os_mem_cmp(drv, wrole->mac_addr, sta->mac_addr, MAC_ALEN) == 0) in _phl_self_stainfo_chk()
809 wrole->type); in _phl_self_stainfo_chk()
813 wrole->type); in _phl_self_stainfo_chk()
849 struct rtw_wifi_role_t *wrole = NULL; in __phl_free_stainfo_sw() local
857 wrole = sta->wrole; in __phl_free_stainfo_sw()
860 if (_phl_self_stainfo_chk(phl_info, wrole, sta) == true) { in __phl_free_stainfo_sw()
866 pstatus = phl_stainfo_queue_del(phl_info, &wrole->assoc_sta_queue, sta); in __phl_free_stainfo_sw()
881 if ((wrole->type == PHL_RTYPE_AP) || in __phl_free_stainfo_sw()
882 (wrole->type == PHL_RTYPE_VAP) || in __phl_free_stainfo_sw()
883 (wrole->type == PHL_RTYPE_MESH) || in __phl_free_stainfo_sw()
884 (wrole->type == PHL_RTYPE_P2P_GO)) in __phl_free_stainfo_sw()
885 phl_role_ap_client_notify(phl_info, wrole, MLME_NO_LINK); in __phl_free_stainfo_sw()
925 struct rtw_wifi_role_t *wrole = sta->wrole; in __phl_free_stainfo_hw() local
928 if (_phl_self_stainfo_chk(phl_info, wrole, sta) == true) in __phl_free_stainfo_hw()
961 sta->wrole->hw_band, in _phl_alloc_stainfo_sw()
962 sta->wrole->hw_wmm, in _phl_alloc_stainfo_sw()
963 sta->wrole->hw_port); in _phl_alloc_stainfo_sw()
1001 struct rtw_wifi_role_t *wrole) in phl_alloc_stainfo_sw() argument
1013 if (wrole->type == PHL_RTYPE_STATION && !bmc_sta) { in phl_alloc_stainfo_sw()
1014 phl_sta = rtw_phl_get_stainfo_self(phl_info, wrole); in phl_alloc_stainfo_sw()
1022 phl_sta = rtw_phl_get_stainfo_by_addr(phl_info, wrole, sta_addr); in phl_alloc_stainfo_sw()
1037 phl_sta->wrole = wrole; in phl_alloc_stainfo_sw()
1045 phl_stainfo_enqueue(phl_info, &wrole->assoc_sta_queue, phl_sta); in phl_alloc_stainfo_sw()
1048 if (_phl_self_stainfo_chk(phl_info, wrole, phl_sta) == false) { in phl_alloc_stainfo_sw()
1049 if ((wrole->type == PHL_RTYPE_AP) || in phl_alloc_stainfo_sw()
1050 (wrole->type == PHL_RTYPE_VAP) || in phl_alloc_stainfo_sw()
1051 (wrole->type == PHL_RTYPE_MESH) || in phl_alloc_stainfo_sw()
1052 (wrole->type == PHL_RTYPE_P2P_GO)) { in phl_alloc_stainfo_sw()
1053 phl_role_ap_client_notify(phl_info, wrole, MLME_LINKING); in phl_alloc_stainfo_sw()
1073 struct rtw_wifi_role_t *wrole) in rtw_phl_alloc_stainfo_sw() argument
1075 return phl_alloc_stainfo_sw((struct phl_info_t *)phl, sta_addr, wrole); in rtw_phl_alloc_stainfo_sw()
1113 struct rtw_wifi_role_t *wrole) in __phl_alloc_stainfo() argument
1118 alloc_sta = phl_alloc_stainfo_sw(phl, sta_addr, wrole); in __phl_alloc_stainfo()
1152 struct rtw_wifi_role_t *wrole, in _phl_alloc_stainfo() argument
1162 pstatus = __phl_alloc_stainfo(phl, sta, sta_addr, wrole); in _phl_alloc_stainfo()
1176 struct rtw_wifi_role_t *wrole; member
1195 struct rtw_wifi_role_t *wrole, in _phl_cmd_alloc_stainfo() argument
1206 psts = _phl_alloc_stainfo(phl_info, sta, sta_addr, wrole, alloc, only_hw); in _phl_cmd_alloc_stainfo()
1221 param->wrole = wrole; in _phl_cmd_alloc_stainfo()
1226 wrole->hw_band, in _phl_cmd_alloc_stainfo()
1254 cmd_sta_param->wrole, in phl_cmd_alloc_stainfo_hdl()
1265 struct rtw_wifi_role_t *wrole, in rtw_phl_cmd_alloc_stainfo() argument
1271 return _phl_cmd_alloc_stainfo(phl, sta, sta_addr, wrole, alloc, only_hw, cmd_type, cmd_timeout); in rtw_phl_cmd_alloc_stainfo()
1276 return _phl_alloc_stainfo((struct phl_info_t *)phl, sta, sta_addr, wrole, alloc, only_hw); in rtw_phl_cmd_alloc_stainfo()
1282 struct rtw_wifi_role_t *wrole) in phl_wifi_role_free_stainfo_hw() argument
1290 used_map = &mc->wifi_role_usedmap[wrole->id][0]; in phl_wifi_role_free_stainfo_hw()
1297 __func__, wrole->id, sta->macid); in phl_wifi_role_free_stainfo_hw()
1355 struct rtw_wifi_role_t *wrole) in _phl_set_dfs_tb_ctrl() argument
1358 enum band_type band = wrole->chandef.band; in _phl_set_dfs_tb_ctrl()
1359 u8 channel = wrole->chandef.chan; in _phl_set_dfs_tb_ctrl()
1400 struct rtw_wifi_role_t *wrole = sta->wrole; in phl_update_media_status() local
1413 if (wrole->mstate == MLME_LINKING) { in phl_update_media_status()
1420 if (wrole->type == PHL_RTYPE_STATION || wrole->type == PHL_RTYPE_P2P_GC) in phl_update_media_status()
1421 wrole->mstate = MLME_NO_LINK; in phl_update_media_status()
1430 CLEAR_STATUS_FLAG(wrole->status, WR_STATUS_TSF_SYNC); in phl_update_media_status()
1436 if ((wrole->type == PHL_RTYPE_STATION) || (wrole->type == PHL_RTYPE_P2P_GC) in phl_update_media_status()
1439 || ((wrole->type == PHL_RTYPE_TDLS) && (!sta_addr)) in phl_update_media_status()
1443 wrole->mstate = MLME_LINKED; in phl_update_media_status()
1445 _phl_set_dfs_tb_ctrl(phl_info, wrole); in phl_update_media_status()
1447 wrole->mstate = MLME_NO_LINK; in phl_update_media_status()
1451 else if ((wrole->type == PHL_RTYPE_AP) || in phl_update_media_status()
1452 (wrole->type == PHL_RTYPE_VAP) || in phl_update_media_status()
1453 (wrole->type == PHL_RTYPE_MESH) || in phl_update_media_status()
1454 (wrole->type == PHL_RTYPE_P2P_GO)) { in phl_update_media_status()
1456 phl_role_ap_client_notify(phl_info, wrole, MLME_LINKED); in phl_update_media_status()
1465 if (wrole->type == PHL_RTYPE_STATION in phl_update_media_status()
1468 || ((wrole->type == PHL_RTYPE_TDLS) && (!sta_addr)) in phl_update_media_status()
1471 hstatus = rtw_hal_role_cfg(phl_info->hal, wrole); in phl_update_media_status()
1523 struct rtw_wifi_role_t *wrole = NULL; in rtw_phl_cmd_update_media_status() local
1545 wrole = sta->wrole; in rtw_phl_cmd_update_media_status()
1548 wrole->hw_band, in rtw_phl_cmd_update_media_status()
1685 struct rtw_wifi_role_t *wrole = sta->wrole; in _phl_cmd_change_stainfo() local
1722 wrole->hw_band, in _phl_cmd_change_stainfo()
1890 rtw_phl_get_stainfo_by_addr(void *phl, struct rtw_wifi_role_t *wrole, u8 *addr) in rtw_phl_get_stainfo_by_addr() argument
1897 u16 macid = macid_ctl->wrole_bmc[wrole->id]; in rtw_phl_get_stainfo_by_addr()
1907 &wrole->assoc_sta_queue, addr); in rtw_phl_get_stainfo_by_addr()
1913 rtw_phl_get_stainfo_self(void *phl, struct rtw_wifi_role_t *wrole) in rtw_phl_get_stainfo_self() argument
1919 if ((wrole->type == PHL_RTYPE_STATION) && in rtw_phl_get_stainfo_self()
1920 (wrole->mstate == MLME_LINKED)) in rtw_phl_get_stainfo_self()
1924 &wrole->assoc_sta_queue, wrole->mac_addr); in rtw_phl_get_stainfo_self()
1927 sta = phl_stainfo_queue_get_first(phl_info, &wrole->assoc_sta_queue);
2333 sta->wrole->id); in phl_clean_sta_bcn_info()
2338 struct rtw_wifi_role_t *wrole) in phl_get_sta_bcn_offset_info() argument
2340 struct rtw_phl_stainfo_t *sta = rtw_phl_get_stainfo_self(phl, wrole); in phl_get_sta_bcn_offset_info()
2349 struct rtw_wifi_role_t *wrole = NULL; in phl_bcn_watchdog() local
2354 wrole = rtw_phl_get_wrole_by_ridx(phl->phl_com, ridx); in phl_bcn_watchdog()
2355 if (wrole == NULL) in phl_bcn_watchdog()
2358 if (rtw_phl_role_is_client_category(wrole) && wrole->mstate == MLME_LINKED) { in phl_bcn_watchdog()
2359 b_ofst_i = phl_get_sta_bcn_offset_info(phl, wrole); in phl_bcn_watchdog()
2365 hstatus = rtw_hal_role_cfg_ex(phl->hal, wrole, PCFG_TBTT_SHIFT, &(b_ofst_i->offset)); in phl_bcn_watchdog()
2391 struct rtw_wifi_role_t *wrole, u64 cur_t, u16 *ofst) in phl_calc_offset_from_tbtt() argument
2393 struct rtw_bcn_offset *b_ofst_i = phl_get_sta_bcn_offset_info(phl, wrole); in phl_calc_offset_from_tbtt()
2394 struct rtw_phl_stainfo_t *sta = rtw_phl_get_stainfo_self(phl, wrole); in phl_calc_offset_from_tbtt()
2400 if (phl_role_is_ap_category(wrole)) in phl_calc_offset_from_tbtt()
2401 b_intvl = (u16)wrole->bcn_cmn.bcn_interval; in phl_calc_offset_from_tbtt()
2407 wrole->id, wrole->type); in phl_calc_offset_from_tbtt()
2417 wrole->id, *ofst, (u32)(cur_t >> 32), (u32)cur_t, mod, in phl_calc_offset_from_tbtt()