Skip to content

Commit

Permalink
staging: rtl8723au: core: Remove unneeded #ifdefs
Browse files Browse the repository at this point in the history
In rtw_mlme_ext.c, nested #ifdef blocks form the following
structure inside the file:

 #ifdef CONFIG_8723AU_AP_MODE           (line 1323)
 [...]
 #ifdef CONFIG_8723AU_AP_MODE           (line 1720)
 [...]
 #endif
 (2 more ifdef blocks with CONFIG_8723AU_AP_MODE follow)
 [...]
 #endif /* CONFIG_8723AU_AP_MODE */     (line 1763)

The inner #ifdefs are unnecessary as they depend on the
same condition as the outer #ifdef and can thus be removed.

Signed-off-by: Andreas Ruprecht <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
  • Loading branch information
rupran authored and gregkh committed Jun 18, 2015
1 parent a9b693c commit 07a55cd
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions drivers/staging/rtl8723au/core/rtw_mlme_ext.c
Original file line number Diff line number Diff line change
Expand Up @@ -1717,7 +1717,6 @@ OnAssocReq23a(struct rtw_adapter *padapter, struct recv_frame *precv_frame)
/* now the station is qualified to join our BSS... */
if (pstat && pstat->state & WIFI_FW_ASSOC_SUCCESS &&
status == WLAN_STATUS_SUCCESS) {
#ifdef CONFIG_8723AU_AP_MODE
/* 1 bss_cap_update & sta_info_update23a */
bss_cap_update_on_sta_join23a(padapter, pstat);
sta_info_update23a(padapter, pstat);
Expand All @@ -1736,29 +1735,24 @@ OnAssocReq23a(struct rtw_adapter *padapter, struct recv_frame *precv_frame)

/* 3-(1) report sta add event */
report_add_sta_event23a(padapter, pstat->hwaddr, pstat->aid);
#endif
}

return _SUCCESS;

asoc_class2_error:

#ifdef CONFIG_8723AU_AP_MODE
issue_deauth23a(padapter, mgmt->sa, status);
#endif
return _FAIL;

OnAssocReq23aFail:

#ifdef CONFIG_8723AU_AP_MODE
pstat->aid = 0;
if (ieee80211_is_assoc_req(mgmt->frame_control))
issue_assocrsp(padapter, status, pstat,
IEEE80211_STYPE_ASSOC_RESP);
else
issue_assocrsp(padapter, status, pstat,
IEEE80211_STYPE_REASSOC_RESP);
#endif

#endif /* CONFIG_8723AU_AP_MODE */

Expand Down

0 comments on commit 07a55cd

Please sign in to comment.