mirror of
https://github.com/torvalds/linux.git
synced 2026-07-27 17:47:41 +02:00
staging: rtl8723bs: remove unnecessary blank lines in rtw_mlme_ext.c
Remove unnecessary blank lines around braces {} to improve readability.
This fixes the following checkpatch.pl checks in rtw_mlme_ext.c:
- CHECK: Blank lines aren't necessary after an open brace '{'
- CHECK: Blank lines aren't necessary before a close brace '}'
Signed-off-by: Jennifer Guo <guojy.bj@gmail.com>
Link: https://patch.msgid.link/20260511182038.6625-2-guojy.bj@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
0007c79071
commit
6602a11fdb
|
|
@ -272,7 +272,6 @@ static void init_channel_list(struct adapter *padapter, struct rt_channel_info *
|
|||
u8 chanset_size,
|
||||
struct p2p_channels *channel_list)
|
||||
{
|
||||
|
||||
static const struct p2p_oper_class_map op_class[] = {
|
||||
{ IEEE80211G, 81, 1, 13, 1, BW20 },
|
||||
{ IEEE80211G, 82, 14, 14, 1, BW20 },
|
||||
|
|
@ -317,7 +316,6 @@ static void init_channel_list(struct adapter *padapter, struct rt_channel_info *
|
|||
}
|
||||
}
|
||||
channel_list->reg_classes = cla;
|
||||
|
||||
}
|
||||
|
||||
static u8 init_channel_set(struct adapter *padapter, u8 ChannelPlan, struct rt_channel_info *channel_set)
|
||||
|
|
@ -534,7 +532,6 @@ unsigned int OnProbeReq(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
}
|
||||
|
||||
return _SUCCESS;
|
||||
|
||||
}
|
||||
|
||||
unsigned int OnProbeRsp(struct adapter *padapter, union recv_frame *precv_frame)
|
||||
|
|
@ -547,7 +544,6 @@ unsigned int OnProbeRsp(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
}
|
||||
|
||||
return _SUCCESS;
|
||||
|
||||
}
|
||||
|
||||
unsigned int OnBeacon(struct adapter *padapter, union recv_frame *precv_frame)
|
||||
|
|
@ -660,7 +656,6 @@ unsigned int OnBeacon(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
_END_ONBEACON_:
|
||||
|
||||
return _SUCCESS;
|
||||
|
||||
}
|
||||
|
||||
unsigned int OnAuth(struct adapter *padapter, union recv_frame *precv_frame)
|
||||
|
|
@ -727,7 +722,6 @@ unsigned int OnAuth(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
|
||||
pstat = rtw_get_stainfo(pstapriv, sa);
|
||||
if (!pstat) {
|
||||
|
||||
/* allocate a new one */
|
||||
pstat = rtw_alloc_stainfo(pstapriv, sa);
|
||||
if (!pstat) {
|
||||
|
|
@ -741,7 +735,6 @@ unsigned int OnAuth(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
/* pstat->flags = 0; */
|
||||
/* pstat->capability = 0; */
|
||||
} else {
|
||||
|
||||
spin_lock_bh(&pstapriv->asoc_list_lock);
|
||||
if (!list_empty(&pstat->asoc_list)) {
|
||||
list_del_init(&pstat->asoc_list);
|
||||
|
|
@ -759,7 +752,6 @@ unsigned int OnAuth(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
|
||||
spin_lock_bh(&pstapriv->auth_list_lock);
|
||||
if (list_empty(&pstat->auth_list)) {
|
||||
|
||||
list_add_tail(&pstat->auth_list, &pstapriv->auth_list);
|
||||
pstapriv->auth_list_cnt++;
|
||||
}
|
||||
|
|
@ -792,7 +784,6 @@ unsigned int OnAuth(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
pstat->state |= WIFI_FW_AUTH_STATE;
|
||||
pstat->authalg = algorithm;
|
||||
} else if (seq == 3) {
|
||||
|
||||
p = rtw_get_ie(pframe + WLAN_HDR_A3_LEN + 4 + _AUTH_IE_OFFSET_, WLAN_EID_CHALLENGE, (int *)&ie_len,
|
||||
len - WLAN_HDR_A3_LEN - _AUTH_IE_OFFSET_ - 4);
|
||||
|
||||
|
|
@ -839,7 +830,6 @@ unsigned int OnAuth(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
issue_auth(padapter, pstat, (unsigned short)status);
|
||||
|
||||
return _FAIL;
|
||||
|
||||
}
|
||||
|
||||
unsigned int OnAuthClient(struct adapter *padapter, union recv_frame *precv_frame)
|
||||
|
|
@ -916,7 +906,6 @@ unsigned int OnAuthClient(struct adapter *padapter, union recv_frame *precv_fram
|
|||
/* pmlmeinfo->state &= ~(WIFI_FW_AUTH_STATE); */
|
||||
|
||||
return _FAIL;
|
||||
|
||||
}
|
||||
|
||||
unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame)
|
||||
|
|
@ -1028,7 +1017,6 @@ unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
p = rtw_get_ie(pframe + WLAN_HDR_A3_LEN + ie_offset, WLAN_EID_EXT_SUPP_RATES, &ie_len,
|
||||
pkt_len - WLAN_HDR_A3_LEN - ie_offset);
|
||||
if (p) {
|
||||
|
||||
if (support_rate_num + ie_len <= sizeof(supportRate)) {
|
||||
memcpy(supportRate + support_rate_num, p + 2, ie_len);
|
||||
support_rate_num += ie_len;
|
||||
|
|
@ -1053,7 +1041,6 @@ unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
pstat->wpa2_pairwise_cipher = 0;
|
||||
memset(pstat->wpa_ie, 0, sizeof(pstat->wpa_ie));
|
||||
if ((psecuritypriv->wpa_psk & BIT(1)) && elems.rsn_ie) {
|
||||
|
||||
int group_cipher = 0, pairwise_cipher = 0;
|
||||
|
||||
wpa_ie = elems.rsn_ie;
|
||||
|
|
@ -1076,7 +1063,6 @@ unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
}
|
||||
|
||||
} else if ((psecuritypriv->wpa_psk & BIT(0)) && elems.wpa_ie) {
|
||||
|
||||
int group_cipher = 0, pairwise_cipher = 0;
|
||||
|
||||
wpa_ie = elems.wpa_ie;
|
||||
|
|
@ -1138,7 +1124,6 @@ unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
status = WLAN_STATUS_INVALID_IE;
|
||||
|
||||
goto OnAssocReqFail;
|
||||
|
||||
}
|
||||
|
||||
if (elems.wps_ie) {
|
||||
|
|
@ -1150,7 +1135,6 @@ unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
|
||||
if (copy_len > 0)
|
||||
memcpy(pstat->wpa_ie, wpa_ie-2, copy_len);
|
||||
|
||||
}
|
||||
|
||||
/* check if there is WMM IE & support WWM-PS */
|
||||
|
|
@ -1206,7 +1190,6 @@ unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
pstat->uapsd_be = BIT(0)|BIT(1);
|
||||
else
|
||||
pstat->uapsd_be = 0;
|
||||
|
||||
}
|
||||
|
||||
break;
|
||||
|
|
@ -1263,7 +1246,6 @@ unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
|
||||
/* if (pstat->aid > NUM_STA) { */
|
||||
if (pstat->aid > pstapriv->max_num_sta) {
|
||||
|
||||
pstat->aid = 0;
|
||||
|
||||
status = WLAN_STATUS_AP_UNABLE_TO_HANDLE_NEW_STA;
|
||||
|
|
@ -1461,7 +1443,6 @@ unsigned int OnDeAuth(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
list_del_init(&psta->asoc_list);
|
||||
pstapriv->asoc_list_cnt--;
|
||||
updated = ap_free_sta(padapter, psta, false, reason);
|
||||
|
||||
}
|
||||
spin_unlock_bh(&pstapriv->asoc_list_lock);
|
||||
|
||||
|
|
@ -1532,7 +1513,6 @@ unsigned int OnDisassoc(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
list_del_init(&psta->asoc_list);
|
||||
pstapriv->asoc_list_cnt--;
|
||||
updated = ap_free_sta(padapter, psta, false, reason);
|
||||
|
||||
}
|
||||
spin_unlock_bh(&pstapriv->asoc_list_lock);
|
||||
|
||||
|
|
@ -1549,7 +1529,6 @@ unsigned int OnDisassoc(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
|
||||
pmlmepriv->link_detect_info.busy_traffic = false;
|
||||
return _SUCCESS;
|
||||
|
||||
}
|
||||
|
||||
unsigned int OnAtim(struct adapter *padapter, union recv_frame *precv_frame)
|
||||
|
|
@ -1857,11 +1836,9 @@ unsigned int OnAction(struct adapter *padapter, union recv_frame *precv_frame)
|
|||
|
||||
if (category == ptable->num)
|
||||
ptable->func(padapter, precv_frame);
|
||||
|
||||
}
|
||||
|
||||
return _SUCCESS;
|
||||
|
||||
}
|
||||
|
||||
unsigned int DoReserved(struct adapter *padapter, union recv_frame *precv_frame)
|
||||
|
|
@ -1896,7 +1873,6 @@ static struct xmit_frame *_alloc_mgtxmitframe(struct xmit_priv *pxmitpriv, bool
|
|||
|
||||
exit:
|
||||
return pmgntframe;
|
||||
|
||||
}
|
||||
|
||||
inline struct xmit_frame *alloc_mgtxmitframe(struct xmit_priv *pxmitpriv)
|
||||
|
|
@ -1949,7 +1925,6 @@ void update_mgntframe_attrib(struct adapter *padapter, struct pkt_attrib *pattri
|
|||
pattrib->retry_ctrl = true;
|
||||
|
||||
pattrib->mbssid = 0;
|
||||
|
||||
}
|
||||
|
||||
void update_mgntframe_attrib_addr(struct adapter *padapter, struct xmit_frame *pmgntframe)
|
||||
|
|
@ -2139,7 +2114,6 @@ void issue_beacon(struct adapter *padapter, int timeout_ms)
|
|||
}
|
||||
|
||||
goto _issue_bcn;
|
||||
|
||||
}
|
||||
|
||||
/* below for ad-hoc mode */
|
||||
|
|
@ -2206,7 +2180,6 @@ void issue_beacon(struct adapter *padapter, int timeout_ms)
|
|||
dump_mgntframe_and_wait(padapter, pmgntframe, timeout_ms);
|
||||
else
|
||||
dump_mgntframe(padapter, pmgntframe);
|
||||
|
||||
}
|
||||
|
||||
void issue_probersp(struct adapter *padapter, unsigned char *da, u8 is_valid_p2p_probereq)
|
||||
|
|
@ -2388,7 +2361,6 @@ void issue_probersp(struct adapter *padapter, unsigned char *da, u8 is_valid_p2p
|
|||
pframe = rtw_set_ie(pframe, WLAN_EID_EXT_SUPP_RATES, (rate_len - 8), (cur_network->supported_rates + 8), &pattrib->pktlen);
|
||||
|
||||
/* todo:HT for adhoc */
|
||||
|
||||
}
|
||||
|
||||
pattrib->last_txcmdsz = pattrib->pktlen;
|
||||
|
|
@ -2641,9 +2613,7 @@ void issue_auth(struct adapter *padapter, struct sta_info *psta, unsigned short
|
|||
pattrib->icv_len = 4;
|
||||
|
||||
pattrib->pktlen += pattrib->icv_len;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
pattrib->last_txcmdsz = pattrib->pktlen;
|
||||
|
|
@ -2737,7 +2707,6 @@ void issue_asocrsp(struct adapter *padapter, unsigned short status, struct sta_i
|
|||
pframe += (ie_len+2);
|
||||
pattrib->pktlen += (ie_len+2);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/* FILL WMM IE */
|
||||
|
|
@ -2758,7 +2727,6 @@ void issue_asocrsp(struct adapter *padapter, unsigned short status, struct sta_i
|
|||
if (!pbuf || ie_len == 0)
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if (pmlmeinfo->assoc_AP_vendor == HT_IOT_PEER_REALTEK)
|
||||
|
|
@ -3576,7 +3544,6 @@ static void issue_action_BSSCoexistPacket(struct adapter *padapter)
|
|||
iedata |= BIT(2);/* 20 MHz BSS Width Request */
|
||||
|
||||
pframe = rtw_set_ie(pframe, WLAN_EID_BSS_COEX_2040, 1, &iedata, &(pattrib->pktlen));
|
||||
|
||||
}
|
||||
|
||||
/* */
|
||||
|
|
@ -3614,7 +3581,6 @@ static void issue_action_BSSCoexistPacket(struct adapter *padapter)
|
|||
if (ICS[0][0] == 0)
|
||||
ICS[0][0] = 1;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
spin_unlock_bh(&(pmlmepriv->scanned_queue.lock));
|
||||
|
|
@ -3641,9 +3607,7 @@ static void issue_action_BSSCoexistPacket(struct adapter *padapter)
|
|||
}
|
||||
|
||||
pframe = rtw_set_ie(pframe, WLAN_EID_BSS_INTOLERANT_CHL_REPORT, k, InfoContent, &(pattrib->pktlen));
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
pattrib->last_txcmdsz = pattrib->pktlen;
|
||||
|
|
@ -3682,13 +3646,11 @@ unsigned int send_delba(struct adapter *padapter, u8 initiator, u8 *addr)
|
|||
issue_action_BA(padapter, addr, WLAN_ACTION_DELBA, (((tid << 1) | initiator)&0x1F));
|
||||
psta->htpriv.agg_enable_bitmap &= ~BIT(tid);
|
||||
psta->htpriv.candidate_tid_bitmap &= ~BIT(tid);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return _SUCCESS;
|
||||
|
||||
}
|
||||
|
||||
unsigned int send_beacon(struct adapter *padapter)
|
||||
|
|
@ -3779,7 +3741,6 @@ void site_survey(struct adapter *padapter)
|
|||
|
||||
set_survey_timer(pmlmeext, channel_scan_time_ms);
|
||||
} else {
|
||||
|
||||
/* channel number is 0 or this channel is not valid. */
|
||||
|
||||
{
|
||||
|
|
@ -4029,7 +3990,6 @@ void start_create_ibss(struct adapter *padapter)
|
|||
}
|
||||
/* update bc/mc sta_info */
|
||||
update_bmc_sta(padapter);
|
||||
|
||||
}
|
||||
|
||||
void start_clnt_join(struct adapter *padapter)
|
||||
|
|
@ -4088,7 +4048,6 @@ void start_clnt_join(struct adapter *padapter)
|
|||
} else {
|
||||
return;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void start_clnt_auth(struct adapter *padapter)
|
||||
|
|
@ -4111,7 +4070,6 @@ void start_clnt_auth(struct adapter *padapter)
|
|||
issue_auth(padapter, NULL, 0);
|
||||
|
||||
set_link_timer(pmlmeext, REAUTH_TO);
|
||||
|
||||
}
|
||||
|
||||
void start_clnt_assoc(struct adapter *padapter)
|
||||
|
|
@ -4245,7 +4203,6 @@ static void process_80211d(struct adapter *padapter, struct wlan_bssid_ex *bssid
|
|||
while ((i < MAX_CHANNEL_NUM) &&
|
||||
(chplan_sta[i].ChannelNum != 0) &&
|
||||
(chplan_sta[i].ChannelNum <= 14)) {
|
||||
|
||||
chplan_new[k].ChannelNum = chplan_sta[i].ChannelNum;
|
||||
chplan_new[k].ScanType = SCAN_PASSIVE;
|
||||
i++;
|
||||
|
|
@ -4614,7 +4571,6 @@ void update_sta_info(struct adapter *padapter, struct sta_info *psta)
|
|||
psta->htpriv.sgi_20m = false;
|
||||
psta->htpriv.sgi_40m = false;
|
||||
psta->qos_option = false;
|
||||
|
||||
}
|
||||
|
||||
psta->htpriv.ch_offset = pmlmeext->cur_ch_offset;
|
||||
|
|
@ -4633,7 +4589,6 @@ void update_sta_info(struct adapter *padapter, struct sta_info *psta)
|
|||
spin_lock_bh(&psta->lock);
|
||||
psta->state = _FW_LINKED;
|
||||
spin_unlock_bh(&psta->lock);
|
||||
|
||||
}
|
||||
|
||||
static void rtw_mlmeext_disconnect(struct adapter *padapter)
|
||||
|
|
@ -4679,7 +4634,6 @@ static void rtw_mlmeext_disconnect(struct adapter *padapter)
|
|||
|
||||
pmlmepriv->link_detect_info.traffic_transition_count = 0;
|
||||
pmlmepriv->link_detect_info.low_power_transition_count = 0;
|
||||
|
||||
}
|
||||
|
||||
void mlmeext_joinbss_event_callback(struct adapter *padapter, int join_res)
|
||||
|
|
@ -4786,7 +4740,6 @@ void mlmeext_sta_add_event_callback(struct adapter *padapter, struct sta_info *p
|
|||
}
|
||||
|
||||
pmlmeinfo->state |= WIFI_FW_ASSOC_SUCCESS;
|
||||
|
||||
}
|
||||
|
||||
join_type = 2;
|
||||
|
|
@ -4828,7 +4781,6 @@ void _linked_info_dump(struct adapter *padapter)
|
|||
struct dvobj_priv *pdvobj = adapter_to_dvobj(padapter);
|
||||
|
||||
if (padapter->bLinkInfoDump) {
|
||||
|
||||
if ((pmlmeinfo->state&0x03) == WIFI_FW_STATION_STATE)
|
||||
rtw_hal_get_def_var(padapter,
|
||||
HAL_DEF_UNDERCORATEDSMOOTHEDPWDB,
|
||||
|
|
@ -5055,7 +5007,6 @@ void addba_timer_hdl(struct timer_list *t)
|
|||
if (phtpriv->ht_option && phtpriv->ampdu_enable) {
|
||||
if (phtpriv->candidate_tid_bitmap)
|
||||
phtpriv->candidate_tid_bitmap = 0x0;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -5164,11 +5115,9 @@ u8 createbss_hdl(struct adapter *padapter, u8 *pbuf)
|
|||
memcpy(pnetwork->ies, ((struct wlan_bssid_ex *)pbuf)->ies, pnetwork->ie_length);
|
||||
|
||||
start_create_ibss(padapter);
|
||||
|
||||
}
|
||||
|
||||
return H2C_SUCCESS;
|
||||
|
||||
}
|
||||
|
||||
u8 join_cmd_hdl(struct adapter *padapter, u8 *pbuf)
|
||||
|
|
@ -5311,7 +5260,6 @@ u8 join_cmd_hdl(struct adapter *padapter, u8 *pbuf)
|
|||
start_clnt_join(padapter);
|
||||
|
||||
return H2C_SUCCESS;
|
||||
|
||||
}
|
||||
|
||||
u8 disconnect_hdl(struct adapter *padapter, unsigned char *pbuf)
|
||||
|
|
@ -5351,7 +5299,6 @@ static int rtw_scan_ch_decision(struct adapter *padapter, struct rtw_ieee80211_c
|
|||
/* acquire channels from in */
|
||||
j = 0;
|
||||
for (i = 0; i < in_num; i++) {
|
||||
|
||||
set_idx = rtw_ch_set_search_ch(pmlmeext->channel_set, in[i].hw_value);
|
||||
if (in[i].hw_value && !(in[i].flags & RTW_IEEE80211_CHAN_DISABLED)
|
||||
&& set_idx >= 0
|
||||
|
|
@ -5377,7 +5324,6 @@ static int rtw_scan_ch_decision(struct adapter *padapter, struct rtw_ieee80211_c
|
|||
/* if out is empty, use channel_set as default */
|
||||
if (j == 0) {
|
||||
for (i = 0; i < pmlmeext->max_chan_nums; i++) {
|
||||
|
||||
if (j >= out_num) {
|
||||
netdev_dbg(padapter->pnetdev,
|
||||
FUNC_ADPT_FMT " out_num:%u not enough\n",
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user