staging: r8188eu: Remove conditionals CONFIG_88EU_{AP_MODE,P2P}
PATCH v2 1/1 staging: r8188eu: Remove conditionals CONFIG_88EU_{AP_MODE,P2P}
These rwo conditional compile symbols are explicitely defined. As a result, their included code is always compiled. They could be converted to Kconfig symbols; however, my experience with this driver in a GitHub repo is that many users of the device have it built into a SOC or SBC that they wish to use as an access point. As a result, CONFIG_88EU_APMODE would need to be selected. Thuse it should be built in.
There have also been many users the wish to establish peer-to-peer networks with this device. For this reason, I am also proposing that CONFIG_88EU_P2P be automatically included.
---
v2 - removed AP symbol from Kconfig following GregKH suggestion
--- drivers/staging/r8188eu/Kconfig | 10 -- drivers/staging/r8188eu/core/rtw_ap.c | 8 - drivers/staging/r8188eu/core/rtw_cmd.c | 13 -- drivers/staging/r8188eu/core/rtw_debug.c | 3 - drivers/staging/r8188eu/core/rtw_ieee80211.c | 5 - drivers/staging/r8188eu/core/rtw_ioctl_set.c | 5 - drivers/staging/r8188eu/core/rtw_mlme.c | 20 +-- drivers/staging/r8188eu/core/rtw_mlme_ext.c | 156 ++---------------- drivers/staging/r8188eu/core/rtw_p2p.c | 16 -- drivers/staging/r8188eu/core/rtw_pwrctrl.c | 19 --- drivers/staging/r8188eu/core/rtw_recv.c | 9 - drivers/staging/r8188eu/core/rtw_sta_mgt.c | 17 -- drivers/staging/r8188eu/core/rtw_wlan_util.c | 2 - drivers/staging/r8188eu/core/rtw_xmit.c | 6 - drivers/staging/r8188eu/hal/hal_intf.c | 2 - drivers/staging/r8188eu/hal/rtl8188e_cmd.c | 3 - drivers/staging/r8188eu/hal/usb_halinit.c | 2 - drivers/staging/r8188eu/include/drv_types.h | 8 - drivers/staging/r8188eu/include/ieee80211.h | 12 -- .../staging/r8188eu/include/ioctl_cfg80211.h | 2 - .../staging/r8188eu/include/rtl8188e_cmd.h | 2 - .../staging/r8188eu/include/rtl8188e_hal.h | 2 - drivers/staging/r8188eu/include/rtw_ap.h | 5 - drivers/staging/r8188eu/include/rtw_cmd.h | 4 - drivers/staging/r8188eu/include/rtw_debug.h | 4 - drivers/staging/r8188eu/include/rtw_mlme.h | 5 - .../staging/r8188eu/include/rtw_mlme_ext.h | 4 - .../staging/r8188eu/include/rtw_security.h | 2 - drivers/staging/r8188eu/include/rtw_xmit.h | 2 - drivers/staging/r8188eu/include/sta_info.h | 7 - drivers/staging/r8188eu/os_dep/ioctl_linux.c | 38 ----- drivers/staging/r8188eu/os_dep/mlme_linux.c | 4 - drivers/staging/r8188eu/os_dep/os_intfs.c | 13 -- drivers/staging/r8188eu/os_dep/usb_intf.c | 4 - .../staging/r8188eu/os_dep/usb_ops_linux.c | 2 - 35 files changed, 12 insertions(+), 404 deletions(-)
drivers/staging/r8188eu/Kconfig +0 -10
@@ -14,13 +14,3 @@ config R8188EU sources for version v4.1.4_6773.20130222, and contains modifications for newer kernel features. If built as a module, it will be called r8188eu. -if R8188EU - -config 88EU_AP_MODE - bool "Realtek RTL8188EU AP mode" - help - This option enables Access Point mode. Unless you know that your system - will never be used as an AP, or the target system has limited memory, - "Y" should be selected. - -endif
drivers/staging/r8188eu/core/rtw_ap.c +0 -8
@@ -8,8 +8,6 @@#include "../include/wifi.h" #include "../include/ieee80211.h" -#ifdef CONFIG_88EU_AP_MODE -void init_mlme_ap_info (struct adapter *padapter) {struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
@@ -603,9 +601,7 @@ static void start_bss_network(struct adapter *padapter, u8 *pbuf)struct mlme_ext_info *pmlmeinfo = &pmlmeext->mlmext_info;struct wlan_bssid_ex *pnetwork_mlmeext = &pmlmeinfo->network;struct HT_info_element *pht_info =NULL ; -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &padapter->wdinfo; -#endif /* CONFIG_88EU_P2P */ bcn_interval = (u16 )pnetwork->Configuration.BeaconPeriod; cur_channel = pnetwork->Configuration.DSConfig;
@@ -706,10 +702,8 @@ static void start_bss_network(struct adapter *padapter, u8 *pbuf)/* let pnetwork_mlmeext == pnetwork_mlme. */ memcpy (pnetwork_mlmeext, pnetwork, pnetwork->Length); -#ifdef CONFIG_88EU_P2P memcpy (pwdinfo->p2p_group_ssid, pnetwork->Ssid.Ssid, pnetwork->Ssid.SsidLength); pwdinfo->p2p_group_ssid_len = pnetwork->Ssid.SsidLength; -#endif /* CONFIG_88EU_P2P */ if (pmlmeext->bstart_bss) {update_beacon (padapter, _TIM_IE_,NULL , false);
@@ -1846,5 +1840,3 @@ void stop_ap_mode(struct adapter *padapter)rtw_free_mlme_priv_ie_data (pmlmepriv); } - -#endif /* CONFIG_88EU_AP_MODE */
drivers/staging/r8188eu/core/rtw_cmd.c +0 -13
@@ -1486,10 +1486,8 @@ static void dynamic_chk_wk_hdl(struct adapter *padapter, u8 *pbuf, int sz) padapter = (struct adapter *)pbuf; pmlmepriv = &padapter->mlmepriv; -#ifdef CONFIG_88EU_AP_MODE if (check_fwstate (pmlmepriv,WIFI_AP_STATE ))expire_timeout_chk (padapter); -#endif rtw_hal_sreset_xmit_status_check (padapter);
@@ -1674,7 +1672,6 @@ static void power_saving_wk_hdl(struct adapter *padapter, u8 *pbuf, int sz)rtw_ps_processor (padapter); } -#ifdef CONFIG_88EU_P2P u8 p2p_protocol_wk_cmd (struct adapter *padapter,int intCmdType) {struct cmd_obj *ph2c;
@@ -1711,7 +1708,6 @@ u8 p2p_protocol_wk_cmd(struct adapter *padapter, int intCmdType)return res; } -#endif /* CONFIG_88EU_P2P */ u8 rtw_ps_cmd (struct adapter *padapter) {
@@ -1745,8 +1741,6 @@ u8 rtw_ps_cmd(struct adapter *padapter)return res; } -#ifdef CONFIG_88EU_AP_MODE -static void rtw_chk_hi_queue_hdl (struct adapter *padapter) {int cnt =0 ;
@@ -1817,7 +1811,6 @@ u8 rtw_chk_hi_queue_cmd(struct adapter *padapter) exit:return res; } -#endif u8 rtw_c2h_wk_cmd (struct adapter *padapter,u8 *c2h_evt) {
@@ -1894,10 +1887,8 @@ static void c2h_wk_callback(struct work_struct *work)continue ; } -#ifdef CONFIG_88EU_P2P /* Enqueue into cmd_thread for others */ rtw_c2h_wk_cmd (adapter, (u8 *)c2h_evt); -#endif } evtpriv->c2h_wk_alive = false;
@@ -1928,7 +1919,6 @@ u8 rtw_drvextra_cmd_hdl(struct adapter *padapter, unsigned char *pbuf)case ANT_SELECT_WK_CID :antenna_select_wk_hdl (padapter, pdrvextra_cmd->type_size);break ; -#ifdef CONFIG_88EU_P2P case P2P_PS_WK_CID :p2p_ps_wk_hdl (padapter, pdrvextra_cmd->type_size);break ;
@@ -1937,12 +1927,9 @@ u8 rtw_drvextra_cmd_hdl(struct adapter *padapter, unsigned char *pbuf)/* I used the type_size as the type command */ p2p_protocol_wk_hdl (padapter, pdrvextra_cmd->type_size);break ; -#endif -#ifdef CONFIG_88EU_AP_MODE case CHECK_HIQ_WK_CID :rtw_chk_hi_queue_hdl (padapter);break ; -#endif /* CONFIG_88EU_AP_MODE */ case C2H_WK_CID :c2h_evt_hdl (padapter, (struct c2h_evt_hdr *)pdrvextra_cmd->pbuf,NULL );break ;
drivers/staging/r8188eu/core/rtw_debug.c +0 -3
@@ -795,8 +795,6 @@ int proc_set_rssi_disp(struct file *file, const char __user *buffer,return count; } -#ifdef CONFIG_88EU_AP_MODE -int proc_get_all_sta_info (char *page,char **start,off_t offset,int count,int *eof,void *data)
@@ -851,7 +849,6 @@ int proc_get_all_sta_info(char *page, char **start, *eof =1 ;return len; } -#endif int proc_get_best_channel(char *page, char **start, off_t offset, int count,
drivers/staging/r8188eu/core/rtw_ieee80211.c +0 -5
@@ -1051,9 +1051,7 @@ void dump_ies(u8 *buf, u32 buf_len) len = *(pos +1 );DBG_88E ("%s ID:%u, LEN:%u\n" , __func__, id, len); -#ifdef CONFIG_88EU_P2P dump_p2p_ie (pos, len); -#endif dump_wps_ie (pos, len); pos += (2 + len);
@@ -1081,7 +1079,6 @@ void dump_wps_ie(u8 *ie, u32 ie_len) } } -#ifdef CONFIG_88EU_P2P void dump_p2p_ie (u8 *ie,u32 ie_len) {u8 *pos = (u8 *)ie;
@@ -1283,8 +1280,6 @@ void rtw_wlan_bssid_ex_remove_p2p_attr(struct wlan_bssid_ex *bss_ex, u8 attr_id) } } -#endif /* CONFIG_88EU_P2P */ -/* Baron adds to avoid FreeBSD warning */ int ieee80211_is_empty_essid (const char *essid,int essid_len) {
drivers/staging/r8188eu/core/rtw_ioctl_set.c +0 -5
@@ -312,9 +312,7 @@ u8 rtw_set_802_11_infrastructure_mode(struct adapter *padapter,/* change to other mode from Ndis802_11APMode */ cur_network->join_res =-1 ; -#ifdef CONFIG_88EU_AP_MODE stop_ap_mode (padapter); -#endif } if ((check_fwstate(pmlmepriv, _FW_LINKED)) ||
@@ -343,9 +341,6 @@ u8 rtw_set_802_11_infrastructure_mode(struct adapter *padapter,break ;case Ndis802_11APMode:set_fwstate (pmlmepriv,WIFI_AP_STATE ); -#ifdef CONFIG_88EU_AP_MODE -start_ap_mode (padapter); -#endif break ;case Ndis802_11AutoUnknown:case Ndis802_11InfrastructureMax:
drivers/staging/r8188eu/core/rtw_mlme.c +2 -18
@@ -88,7 +88,6 @@ static void rtw_mfree_mlme_priv_lock(struct mlme_priv *pmlmepriv) { } -#if defined(CONFIG_88EU_AP_MODE )static void rtw_free_mlme_ie_data (u8 **ppie,u32 *plen) {kfree (*ppie);
@@ -111,11 +110,6 @@ void rtw_free_mlme_priv_ie_data(struct mlme_priv *pmlmepriv)rtw_free_mlme_ie_data (&pmlmepriv->p2p_go_probe_resp_ie, &pmlmepriv->p2p_go_probe_resp_ie_len);rtw_free_mlme_ie_data (&pmlmepriv->p2p_assoc_req_ie, &pmlmepriv->p2p_assoc_req_ie_len); } -#else -void rtw_free_mlme_priv_ie_data (struct mlme_priv *pmlmepriv) -{ -} -#endif void _rtw_free_mlme_priv (struct mlme_priv *pmlmepriv) {
@@ -611,9 +605,7 @@ static void rtw_add_network(struct adapter *adapter, struct wlan_bssid_ex *pnetwork) { -#if defined(CONFIG_88EU_P2P )rtw_wlan_bssid_ex_remove_p2p_attr (pnetwork,P2P_ATTR_GROUP_INFO ); -#endif update_current_network (adapter, pnetwork);rtw_update_scanned_network (adapter, pnetwork);
@@ -1200,24 +1192,20 @@ void rtw_joinbss_event_callback(struct adapter *adapter, u8 *pbuf)static u8 search_max_mac_id (struct adapter *padapter) {u8 mac_id; -#if defined(CONFIG_88EU_AP_MODE )u8 aid;struct mlme_priv *pmlmepriv = &padapter->mlmepriv;struct sta_priv *pstapriv = &padapter->stapriv; -#endif struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;struct mlme_ext_info *pmlmeinfo = &pmlmeext->mlmext_info; -#if defined(CONFIG_88EU_AP_MODE )if (check_fwstate (pmlmepriv,WIFI_AP_STATE )) {for (aid = (pstapriv->max_num_sta); aid >0 ; aid--) {if (pstapriv->sta_aid[aid -1 ])break ; } mac_id = aid +1 ; - } else -#endif - {/* adhoc id = 31~2 */ + }else { +/* adhoc id = 31~2 */ for (mac_id = (NUM_STA -1 ); mac_id >=IBSS_START_MAC_ID ; mac_id--) {if (pmlmeinfo->FW_sta_info[mac_id].status ==1 )break ;
@@ -1255,14 +1243,12 @@ void rtw_stassoc_event_callback(struct adapter *adapter, u8 *pbuf)if (!rtw_access_ctrl (adapter, pstassoc->macaddr))return ; -#if defined(CONFIG_88EU_AP_MODE )if (check_fwstate (pmlmepriv,WIFI_AP_STATE )) { psta =rtw_get_stainfo (&adapter->stapriv, pstassoc->macaddr);if (psta)rtw_indicate_sta_assoc_event (adapter, psta);return ; } -#endif /* for AD-HOC mode */ psta =rtw_get_stainfo (&adapter->stapriv, pstassoc->macaddr);if (psta)
@@ -1486,10 +1472,8 @@ void rtw_dynamic_check_timer_handlder(struct adapter *adapter)rtw_dynamic_chk_wk_cmd (adapter);if (pregistrypriv->wifi_spec ==1 ) { -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &adapter->wdinfo;if (rtw_p2p_chk_state (pwdinfo,P2P_STATE_NONE )) -#endif {/* auto site survey */ rtw_auto_scan_handler (adapter);
drivers/staging/r8188eu/core/rtw_mlme_ext.c +10 -146
678 lines not on this page · raw message
drivers/staging/r8188eu/core/rtw_p2p.c +0 -16
@@ -7,8 +7,6 @@#include "../include/rtw_p2p.h" #include "../include/wifi.h" -#ifdef CONFIG_88EU_P2P -static int rtw_p2p_is_channel_list_ok (u8 desired_ch,u8 *ch_list,u8 ch_cnt) {int found =0 , i =0 ;
@@ -1832,7 +1830,6 @@ void rtw_init_wifidirect_timers(struct adapter *padapter)void rtw_init_wifidirect_addrs (struct adapter *padapter,u8 *dev_addr,u8 *iface_addr) { -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &padapter->wdinfo;/*init device&interface address */
@@ -1840,7 +1837,6 @@ void rtw_init_wifidirect_addrs(struct adapter *padapter, u8 *dev_addr, u8 *ifacememcpy (pwdinfo->device_addr, dev_addr,ETH_ALEN );if (iface_addr)memcpy (pwdinfo->interface_addr, iface_addr,ETH_ALEN ); -#endif }void init_wifidirect_info (struct adapter *padapter,enum P2P_ROLE role)
@@ -1983,15 +1979,3 @@ int rtw_p2p_enable(struct adapter *padapter, enum P2P_ROLE role) exit:return ret; } - -#else -u8 p2p_ps_wk_cmd (struct adapter *padapter,u8 p2p_ps_state,u8 enqueue) -{ -return _FAIL; -} - -void process_p2p_ps_ie (struct adapter *padapter,u8 *IEs,u32 IELength) -{ -} - -#endif /* CONFIG_88EU_P2P */
drivers/staging/r8188eu/core/rtw_pwrctrl.c +0 -19
@@ -99,10 +99,7 @@ static bool rtw_pwr_unassociated_idle(struct adapter *adapter) {struct adapter *buddy = adapter->pbuddy_adapter;struct mlme_priv *pmlmepriv = &adapter->mlmepriv; -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &adapter->wdinfo; -#endif -bool ret = false;if (adapter->pwrctrlpriv.ips_deny_time >= jiffies)
@@ -113,29 +110,19 @@ static bool rtw_pwr_unassociated_idle(struct adapter *adapter)check_fwstate (pmlmepriv,WIFI_UNDER_WPS ) ||check_fwstate (pmlmepriv,WIFI_AP_STATE ) ||check_fwstate (pmlmepriv,WIFI_ADHOC_MASTER_STATE |WIFI_ADHOC_STATE ) || -#if defined(CONFIG_88EU_P2P ) !rtw_p2p_chk_state(pwdinfo, P2P_STATE_NONE)) -#else - 0) -#endif goto exit;/* consider buddy, if exist */ if (buddy) {struct mlme_priv *b_pmlmepriv = &buddy->mlmepriv; -#ifdef CONFIG_88EU_P2P struct wifidirect_info *b_pwdinfo = &buddy->wdinfo; -#endif if (check_fwstate (b_pmlmepriv,WIFI_ASOC_STATE |WIFI_SITE_MONITOR ) ||check_fwstate (b_pmlmepriv,WIFI_UNDER_LINKING |WIFI_UNDER_WPS ) ||check_fwstate (b_pmlmepriv,WIFI_AP_STATE ) ||check_fwstate (b_pmlmepriv,WIFI_ADHOC_MASTER_STATE |WIFI_ADHOC_STATE ) || -#if defined(CONFIG_88EU_P2P) !rtw_p2p_chk_state (b_pwdinfo,P2P_STATE_NONE )) -#else - 0) -#endif goto exit; } ret = true;
@@ -274,9 +261,7 @@ static u8 PS_RDY_CHECK(struct adapter *padapter)void rtw_set_ps_mode (struct adapter *padapter,u8 ps_mode,u8 smart_ps,u8 bcn_ant_mode) {struct pwrctrl_priv *pwrpriv = &padapter->pwrctrlpriv; -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &padapter->wdinfo; -#endif /* CONFIG_88EU_P2P */ if (ps_mode > PM_Card_Disable)return ;
@@ -292,7 +277,6 @@ void rtw_set_ps_mode(struct adapter *padapter, u8 ps_mode, u8 smart_ps, u8 bcn_a/* if (pwrpriv->pwr_mode == PS_MODE_ACTIVE) */ if (ps_mode ==PS_MODE_ACTIVE ) { -#ifdef CONFIG_88EU_P2P if (pwdinfo->opp_ps ==0 ) {DBG_88E ("rtw_set_ps_mode: Leave 802.11 power save\n" ); pwrpriv->pwr_mode = ps_mode;
@@ -301,7 +285,6 @@ void rtw_set_ps_mode(struct adapter *padapter, u8 ps_mode, u8 smart_ps, u8 bcn_a pwrpriv->bFwCurrentInPSMode = false; } }else { -#endif /* CONFIG_88EU_P2P */ if (PS_RDY_CHECK (padapter)) {DBG_88E ("%s: Enter 802.11 power save\n" , __func__); pwrpriv->bFwCurrentInPSMode = true;
@@ -310,11 +293,9 @@ void rtw_set_ps_mode(struct adapter *padapter, u8 ps_mode, u8 smart_ps, u8 bcn_a pwrpriv->bcn_ant_mode = bcn_ant_mode;rtw_hal_set_hwreg (padapter,HW_VAR_H2C_FW_PWRMODE , (u8 *)(&ps_mode)); -#ifdef CONFIG_88EU_P2P /* Set CTWindow after LPS */ if (pwdinfo->opp_ps ==1 )p2p_ps_wk_cmd (padapter,P2P_PS_ENABLE ,0 ); -#endif /* CONFIG_88EU_P2P */ rtw_set_rpwm (padapter,PS_STATE_S2 ); }
drivers/staging/r8188eu/core/rtw_recv.c +0 -9
@@ -523,7 +523,6 @@ static int recv_decache(struct recv_frame *precv_frame, u8 bretry, struct stainfvoid process_pwrbit_data (struct adapter *padapter,struct recv_frame *precv_frame);void process_pwrbit_data (struct adapter *padapter,struct recv_frame *precv_frame) { -#ifdef CONFIG_88EU_AP_MODE unsigned char pwrbit;u8 *ptr = precv_frame->rx_data;struct rx_pkt_attrib *pattrib = &precv_frame->attrib;
@@ -543,13 +542,10 @@ void process_pwrbit_data(struct adapter *padapter, struct recv_frame *precv_framwakeup_sta_to_xmit (padapter, psta); } } - -#endif }static void process_wmmps_data (struct adapter *padapter,struct recv_frame *precv_frame) { -#ifdef CONFIG_88EU_AP_MODE struct rx_pkt_attrib *pattrib = &precv_frame->attrib;struct sta_priv *pstapriv = &padapter->stapriv;struct sta_info *psta =NULL ;
@@ -598,8 +594,6 @@ static void process_wmmps_data(struct adapter *padapter, struct recv_frame *prec } } } - -#endif }static void count_rx_stats (struct adapter *padapter,struct recv_frame *prframe,struct sta_info *sta)
@@ -883,7 +877,6 @@ static int sta2ap_data_frame(struct adapter *adapter,static int validate_recv_ctrl_frame (struct adapter *padapter,struct recv_frame *precv_frame) { -#ifdef CONFIG_88EU_AP_MODE struct rx_pkt_attrib *pattrib = &precv_frame->attrib;struct sta_priv *pstapriv = &padapter->stapriv;u8 *pframe = precv_frame->rx_data;
@@ -996,8 +989,6 @@ static int validate_recv_ctrl_frame(struct adapter *padapter, } } -#endif -return _FAIL; }
drivers/staging/r8188eu/core/rtw_sta_mgt.c +0 -17
@@ -24,8 +24,6 @@ static void _rtw_init_stainfo(struct sta_info *psta)_rtw_init_sta_xmit_priv (&psta->sta_xmitpriv);_rtw_init_sta_recv_priv (&psta->sta_recvpriv); -#ifdef CONFIG_88EU_AP_MODE -INIT_LIST_HEAD (&psta->asoc_list);INIT_LIST_HEAD (&psta->auth_list);
@@ -38,21 +36,16 @@ static void _rtw_init_stainfo(struct sta_info *psta) psta->bpairwise_key_installed = false; -#ifdef CONFIG_88EU_AP_MODE psta->nonerp_set =0 ; psta->no_short_slot_time_set =0 ; psta->no_short_preamble_set =0 ; psta->no_ht_gf_set =0 ; psta->no_ht_set =0 ; psta->ht_20mhz_set =0 ; -#endif psta->under_exist_checking =0 ; psta->keep_alive_trycnt =0 ; - -#endif /* CONFIG_88EU_AP_MODE */ - }u32 _rtw_init_sta_priv (struct sta_priv *pstapriv)
@@ -88,8 +81,6 @@ u32 _rtw_init_sta_priv(struct sta_priv *pstapriv) psta++; } -#ifdef CONFIG_88EU_AP_MODE - pstapriv->sta_dz_bitmap =0 ; pstapriv->tim_bitmap =0 ;
@@ -104,7 +95,6 @@ u32 _rtw_init_sta_priv(struct sta_priv *pstapriv) pstapriv->assoc_to =3 ; pstapriv->expire_to =3 ;/* 3*2 = 6 sec */ pstapriv->max_num_sta =NUM_STA ; -#endif return _SUCCESS; }
@@ -322,8 +312,6 @@ u32 rtw_free_stainfo(struct adapter *padapter, struct sta_info *psta)if (!(psta->state &WIFI_AP_STATE ))rtw_hal_set_odm_var (padapter,HAL_ODM_STA_INFO , psta, false); -#ifdef CONFIG_88EU_AP_MODE -spin_lock_bh (&pstapriv->auth_list_lock);if (!list_empty (&psta->auth_list)) {list_del_init (&psta->auth_list);
@@ -353,8 +341,6 @@ u32 rtw_free_stainfo(struct adapter *padapter, struct sta_info *psta) psta->under_exist_checking =0 ; -#endif /* CONFIG_88EU_AP_MODE */ -spin_lock_bh (&pfree_sta_queue->lock);list_add_tail (&psta->list,get_list_head (pfree_sta_queue));spin_unlock_bh (&pfree_sta_queue->lock);
@@ -470,7 +456,6 @@ struct sta_info *rtw_get_bcmc_stainfo(struct adapter *padapter)u8 rtw_access_ctrl (struct adapter *padapter,u8 *mac_addr) {u8 res = true; -#ifdef CONFIG_88EU_AP_MODE struct list_head *plist, *phead;struct rtw_wlan_acl_node *paclnode;u8 match = false;
@@ -501,7 +486,5 @@ u8 rtw_access_ctrl(struct adapter *padapter, u8 *mac_addr)else res = true; -#endif -return res; }
drivers/staging/r8188eu/core/rtw_wlan_util.c +0 -2
@@ -1233,7 +1233,6 @@ void set_sta_rate(struct adapter *padapter, struct sta_info *psta)void update_tx_basic_rate (struct adapter *padapter,u8 wirelessmode) {unsigned char supported_rates[NDIS_802_11_LENGTH_RATES_EX ]; -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &padapter->wdinfo;/* Added by Albert 2011/03/22 */
@@ -1241,7 +1240,6 @@ void update_tx_basic_rate(struct adapter *padapter, u8 wirelessmode)/* So, the Tx packet shouldn't use the CCK rate */ if (!rtw_p2p_chk_state (pwdinfo,P2P_STATE_NONE ))return ; -#endif /* CONFIG_88EU_P2P */ memset (supported_rates,0 ,NDIS_802_11_LENGTH_RATES_EX );if ((wirelessmode &WIRELESS_11B ) && (wirelessmode ==WIRELESS_11B ))
drivers/staging/r8188eu/core/rtw_xmit.c +0 -6
@@ -1773,14 +1773,12 @@ s32 rtw_xmit(struct adapter *padapter, struct sk_buff **ppkt)do_queue_select (padapter, &pxmitframe->attrib); -#ifdef CONFIG_88EU_AP_MODE spin_lock_bh (&pxmitpriv->lock);if (xmitframe_enqueue_for_sleeping_sta (padapter, pxmitframe)) {spin_unlock_bh (&pxmitpriv->lock);return 1 ; }spin_unlock_bh (&pxmitpriv->lock); -#endif if (!rtw_hal_xmit (padapter, pxmitframe))return 1 ;
@@ -1788,8 +1786,6 @@ s32 rtw_xmit(struct adapter *padapter, struct sk_buff **ppkt)return 0 ; } -#if defined(CONFIG_88EU_AP_MODE ) -int xmitframe_enqueue_for_sleeping_sta (struct adapter *padapter,struct xmit_frame *pxmitframe) {int ret = false;
@@ -2156,8 +2152,6 @@ void xmit_delivery_enabled_frames(struct adapter *padapter, struct sta_info *pstspin_unlock_bh (&psta->sleep_q.lock); } -#endif -void rtw_sctx_init (struct submit_ctx *sctx,int timeout_ms) { sctx->timeout_ms = timeout_ms;
drivers/staging/r8188eu/hal/hal_intf.c +0 -2
@@ -186,14 +186,12 @@ void rtw_hal_update_ra_mask(struct adapter *adapt, u32 mac_id, u8 rssi_level)struct mlme_priv *pmlmepriv = &adapt->mlmepriv;if (check_fwstate (pmlmepriv,WIFI_AP_STATE )) { -#ifdef CONFIG_88EU_AP_MODE struct sta_info *psta =NULL ;struct sta_priv *pstapriv = &adapt->stapriv;if ((mac_id -1 ) >0 ) psta = pstapriv->sta_aid[(mac_id -1 ) -1 ];if (psta)add_RATid (adapt, psta,0 );/* todo: based on rssi_level*/ -#endif }else {if (adapt->HalFunc.UpdateRAMaskHandler) adapt->HalFunc.UpdateRAMaskHandler(adapt, mac_id,
drivers/staging/r8188eu/hal/rtl8188e_cmd.c +0 -3
@@ -667,7 +667,6 @@ void rtl8188e_set_FwJoinBssReport_cmd(struct adapter *adapt, u8 mstatus)void rtl8188e_set_p2p_ps_offload_cmd (struct adapter *adapt,u8 p2p_ps_state) { -#ifdef CONFIG_88EU_P2P struct hal_data_8188e *haldata =GET_HAL_DATA (adapt);struct wifidirect_info *pwdinfo = &adapt->wdinfo;struct P2P_PS_Offload_t *p2p_ps_offload = &haldata->p2p_ps_offload;
@@ -732,6 +731,4 @@ void rtl8188e_set_p2p_ps_offload_cmd(struct adapter *adapt, u8 p2p_ps_state) }FillH2CCmd_88E (adapt,H2C_PS_P2P_OFFLOAD ,1 , (u8 *)p2p_ps_offload); -#endif - }
drivers/staging/r8188eu/hal/usb_halinit.c +0 -2
@@ -1776,14 +1776,12 @@ static void SetHwReg8188EU(struct adapter *Adapter, u8 variable, u8 *val)rtl8188e_set_FwJoinBssReport_cmd (Adapter, mstatus); }break ; -#ifdef CONFIG_88EU_P2P case HW_VAR_H2C_FW_P2P_PS_OFFLOAD : {u8 p2p_ps_state = (*(u8 *)val);rtl8188e_set_p2p_ps_offload_cmd (Adapter, p2p_ps_state); }break ; -#endif case HW_VAR_INITIAL_GAIN : {struct rtw_dig *pDigTable = &podmpriv->DM_DigTable;
drivers/staging/r8188eu/include/drv_types.h +0 -8
@@ -11,8 +11,6 @@#define __DRV_TYPES_H__#define DRV_NAME "r8188eu" -#define CONFIG_88EU_AP_MODE 1 -#define CONFIG_88EU_P2P 1#include "osdep_service.h" #include "wlan_bssdef.h"
@@ -231,11 +229,7 @@ struct adapter {struct eeprom_priv eeprompriv;struct led_priv ledpriv;struct mp_priv mppriv; - -#ifdef CONFIG_88EU_AP_MODE struct hostapd_priv *phostapdpriv; -#endif -struct wifidirect_info wdinfo;void *HalData;
@@ -286,11 +280,9 @@ struct adapter {/* The driver will show up the desired channel number * when this flag is 1. */ u8 bNotifyChannelChange; -#ifdef CONFIG_88EU_P2P /* The driver will show the current P2P status when the * upper application reads it. */ u8 bShowGetP2PState; -#endif struct adapter *pbuddy_adapter;struct mutex *hw_init_mutex;
drivers/staging/r8188eu/include/ieee80211.h +0 -12
@@ -15,8 +15,6 @@#define ETH_TYPE_LEN 2#define PAYLOAD_TYPE_LEN 1 -#ifdef CONFIG_88EU_AP_MODE -#define RTL_IOCTL_HOSTAPD (SIOCIWFIRSTPRIV + 28)/* STA flags */
@@ -36,8 +34,6 @@#define WLAN_STA_MAYBE_WPS BIT(13)#define WLAN_STA_NONERP BIT(31) -#endif -#define IEEE_CMD_SET_WPA_PARAM 1#define IEEE_CMD_SET_WPA_IE 2#define IEEE_CMD_SET_ENCRYPTION 3
@@ -172,7 +168,6 @@ struct ieee_param {u16 key_len;u8 key[0 ]; } crypt; -#ifdef CONFIG_88EU_AP_MODEstruct {u16 aid;u16 capability;
@@ -184,12 +179,9 @@ struct ieee_param {u8 reserved[2 ];/* for set max_num_sta */ u8 buf[0 ]; } bcn_ie; -#endif - } u; }; -#ifdef CONFIG_88EU_AP_MODE struct ieee_param_ex {u32 cmd;u8 sta_addr[ETH_ALEN ];
@@ -211,7 +203,6 @@ struct sta_data {u64 tx_bytes;u64 tx_drops; }; -#endif #define IEEE80211_DATA_LEN 2304/* Maximum size for the MA-UNITDATA primitive, 802.11 standard section
@@ -1158,7 +1149,6 @@ u8 *rtw_get_wps_attr_content(u8 *wps_ie, uint wps_ielen, u16 target_attr_id,void dump_ies (u8 *buf,u32 buf_len);void dump_wps_ie (u8 *ie,u32 ie_len); -#ifdef CONFIG_88EU_P2P void dump_p2p_ie (u8 *ie,u32 ie_len);u8 *rtw_get_p2p_ie (u8 *in_ie,int in_len,u8 *p2p_ie,uint *p2p_ielen); u8 *rtw_get_p2p_attr(u8 *p2p_ie, uint p2p_ielen, u8 target_attr_id,
@@ -1169,8 +1159,6 @@ u32 rtw_set_p2p_attr_content(u8 *pbuf, u8 attr_id, u16 attr_len, u8 *pdata_attr);void rtw_wlan_bssid_ex_remove_p2p_attr (struct wlan_bssid_ex *bss_ex,u8 attr_id); -#endif -uint rtw_get_rateset_len (u8 *rateset);struct registry_priv ;
drivers/staging/r8188eu/include/ioctl_cfg80211.h +0 -2
@@ -61,13 +61,11 @@ void rtw_cfg80211_indicate_disconnect(struct adapter *padapter);void rtw_cfg80211_indicate_scan_done (struct rtw_wdev_priv *pwdev_priv,bool aborted); -#ifdef CONFIG_88EU_AP_MODE void rtw_cfg80211_indicate_sta_assoc (struct adapter *padapter,u8 *pmgmt_frame,uint frame_len);void rtw_cfg80211_indicate_sta_disassoc (struct adapter *padapter,unsigned char *da,unsigned short reason); -#endif /* CONFIG_88EU_AP_MODE */ void rtw_cfg80211_issue_p2p_provision_request (struct adapter *padapter,const u8 *buf,size_t len);
drivers/staging/r8188eu/include/rtl8188e_cmd.h +0 -2
@@ -96,9 +96,7 @@ u8 rtl8188e_set_raid_cmd(struct adapter *padapter, u32 mask);void rtl8188e_Add_RateATid (struct adapter *padapter,u32 bitmap,u8 arg,u8 rssi_level); -#ifdef CONFIG_88EU_P2P void rtl8188e_set_p2p_ps_offload_cmd (struct adapter *adapt,u8 p2p_ps_state); -#endif /* CONFIG_88EU_P2P */ void CheckFwRsvdPageContent (struct adapter *adapt);void rtl8188e_set_FwMediaStatus_cmd (struct adapter *adapt,__le16 mstatus_rpt);
drivers/staging/r8188eu/include/rtl8188e_hal.h +0 -2
@@ -364,9 +364,7 @@ struct hal_data_8188e {u16 EfuseUsedBytes; -#ifdef CONFIG_88EU_P2P struct P2P_PS_Offload_t p2p_ps_offload; -#endif /* Auto FSM to Turn On, include clock, isolation, power control * for MAC only */
drivers/staging/r8188eu/include/rtw_ap.h +0 -5
@@ -7,8 +7,6 @@#include "osdep_service.h" #include "drv_types.h" -#ifdef CONFIG_88EU_AP_MODE -/* external function */ void rtw_indicate_sta_assoc_event (struct adapter *padapter,struct sta_info *psta);
@@ -28,7 +26,6 @@ void rtw_set_macaddr_acl(struct adapter *padapter, int mode);int rtw_acl_add_sta (struct adapter *padapter,u8 *addr);int rtw_acl_remove_sta (struct adapter *padapter,u8 *addr); -#ifdef CONFIG_88EU_AP_MODE void associated_clients_update (struct adapter *padapter,u8 updated);void bss_cap_update_on_sta_join (struct adapter *padapter,struct sta_info *psta);u8 bss_cap_update_on_sta_leave (struct adapter *padapter,struct sta_info *psta);
@@ -40,8 +37,6 @@ int rtw_sta_flush(struct adapter *padapter);int rtw_ap_inform_ch_switch (struct adapter *padapter,u8 new_ch,u8 ch_offset);void start_ap_mode (struct adapter *padapter);void stop_ap_mode (struct adapter *padapter); -#endif -#endif /* end of CONFIG_88EU_AP_MODE */ void update_bmc_sta (struct adapter *padapter);#endif
drivers/staging/r8188eu/include/rtw_cmd.h +0 -4
@@ -91,9 +91,7 @@ u32 rtw_init_evt_priv(struct evt_priv *pevtpriv);void rtw_free_evt_priv (struct evt_priv *pevtpriv);void rtw_cmd_clr_isr (struct cmd_priv *pcmdpriv);void rtw_evt_notify_isr (struct evt_priv *pevtpriv); -#ifdef CONFIG_88EU_P2P u8 p2p_protocol_wk_cmd (struct adapter *padapter,int intCmdType); -#endif /* CONFIG_88EU_P2P */ enum rtw_drvextra_cmd_id {NONE_WK_CID ,
@@ -785,9 +783,7 @@ u8 rtw_rpt_timer_cfg_cmd(struct adapter*padapter, u16 minRptTime);u8 rtw_antenna_select_cmd (struct adapter *padapter,u8 antenna,u8 enqueue);u8 rtw_ps_cmd (struct adapter *padapter); -#ifdef CONFIG_88EU_AP_MODE u8 rtw_chk_hi_queue_cmd (struct adapter *padapter); -#endif u8 rtw_set_ch_cmd (struct adapter *padapter,u8 ch,u8 bw,u8 ch_offset,u8 enqueue);u8 rtw_set_chplan_cmd (struct adapter *padapter,u8 chplan,u8 enqueue);
drivers/staging/r8188eu/include/rtw_debug.h +0 -4
@@ -156,14 +156,10 @@ int proc_get_rf_reg_dump4(char *page, char **start, off_t offset, int count, int *eof, void *data); -#ifdef CONFIG_88EU_AP_MODE -int proc_get_all_sta_info (char *page,char **start,off_t offset,int count,int *eof,void *data); -#endif -int proc_get_best_channel (char *page,char **start,off_t offset,int count,int *eof,void *data);
drivers/staging/r8188eu/include/rtw_mlme.h +0 -5
@@ -379,7 +379,6 @@ struct mlme_priv {u8 *assoc_rsp;u32 assoc_rsp_len; -#if defined (CONFIG_88EU_AP_MODE )/* Number of associated Non-ERP stations (i.e., stations using 802.11b * in 802.11g BSS) */ int num_sta_non_erp;
@@ -428,18 +427,14 @@ struct mlme_priv {u32 p2p_assoc_req_ie_len;spinlock_t bcn_update_lock;u8 update_bcn; -#endif /* if defined (CONFIG_88EU_AP_MODE) */ }; -#ifdef CONFIG_88EU_AP_MODE -struct hostapd_priv {struct adapter *padapter; };int hostapd_mode_init (struct adapter *padapter);void hostapd_mode_unload (struct adapter *padapter); -#endif extern unsigned char WPA_TKIP_CIPHER [4 ];extern unsigned char RSN_TKIP_CIPHER [4 ];
drivers/staging/r8188eu/include/rtw_mlme_ext.h +0 -4
@@ -416,9 +416,7 @@ struct mlme_ext_priv {u64 TSFValue; -#ifdef CONFIG_88EU_AP_MODE unsigned char bstart_bss; -#endif u8 update_channel_plan_by_ap_done;/* recv_decache check for Action_public frame */ u8 action_public_dialog_token;
@@ -538,7 +536,6 @@ s32 dump_mgntframe_and_wait(struct adapter *padapter,s32 dump_mgntframe_and_wait_ack (struct adapter *padapter,struct xmit_frame *pmgntframe); -#ifdef CONFIG_88EU_P2P void issue_probersp_p2p (struct adapter *padapter,unsigned char *da);void issue_p2p_provision_request (struct adapter *padapter,u8 *pssid,u8 ussidlen,u8 *pdev_raddr);
@@ -549,7 +546,6 @@ int issue_probereq_p2p_ex(struct adapter *adapter, u8 *da, int try_cnt,void issue_p2p_invitation_response (struct adapter *padapter,u8 *raddr,u8 dialogToken,u8 success);void issue_p2p_invitation_request (struct adapter *padapter,u8 * raddr); -#endif /* CONFIG_88EU_P2P */ void issue_beacon (struct adapter *padapter,int timeout_ms);void issue_probersp (struct adapter *padapter,unsigned char *da,u8 is_valid_p2p_probereq);
drivers/staging/r8188eu/include/rtw_security.h +0 -2
@@ -111,7 +111,6 @@ struct security_priv {struct arc4_ctx xmit_arc4_ctx;struct arc4_ctx recv_arc4_ctx; -#ifdef CONFIG_88EU_AP_MODE /* extend security capabilities for AP_MODE */ unsigned int dot8021xalg;/* 0:disable, 1:psk, 2:802.1x */ unsigned int wpa_psk;/* 0:disable, bit(0): WPA, bit(1):WPA2 */
@@ -119,7 +118,6 @@ struct security_priv {unsigned int wpa2_group_cipher;unsigned int wpa_pairwise_cipher;unsigned int wpa2_pairwise_cipher; -#endif u8 wps_ie[MAX_WPS_IE_LEN ];/* added in assoc req */ int wps_ie_len;u8 binstallGrpkey;
drivers/staging/r8188eu/include/rtw_xmit.h +0 -2
@@ -349,12 +349,10 @@ void rtw_alloc_hwxmits(struct adapter *padapter);void rtw_free_hwxmits (struct adapter *padapter);s32 rtw_xmit (struct adapter *padapter,struct sk_buff **pkt); -#if defined(CONFIG_88EU_AP_MODE )int xmitframe_enqueue_for_sleeping_sta (struct adapter *padapter,struct xmit_frame *pxmitframe);void stop_sta_xmit (struct adapter *padapter,struct sta_info *psta);void wakeup_sta_to_xmit (struct adapter *padapter,struct sta_info *psta);void xmit_delivery_enabled_frames (struct adapter *padapter,struct sta_info *psta); -#endif u8 qos_acm (u8 acm_mask,u8 priority);u32 rtw_get_ff_hwaddr (struct xmit_frame *pxmitframe);
drivers/staging/r8188eu/include/sta_info.h +0 -7
@@ -124,7 +124,6 @@ struct sta_info {/* sta_info: (AP & STA) CAP/INFO */ struct list_head asoc_list; -#ifdef CONFIG_88EU_AP_MODE struct list_head auth_list;unsigned int expire_to;
@@ -164,9 +163,7 @@ struct sta_info {u8 has_legacy_ac;unsigned int sleepq_ac_len; -#endif /* CONFIG_88EU_AP_MODE */ -#ifdef CONFIG_88EU_P2P /* p2p priv data */ u8 is_p2p_device;u8 p2p_status_code;
@@ -180,7 +177,6 @@ struct sta_info {u8 secdev_types_list[32 ];/* 32/8 == 4; */ u16 dev_name_len;u8 dev_name[32 ]; -#endif /* CONFIG_88EU_P2P */ u8 under_exist_checking;u8 keep_alive_trycnt;
@@ -306,7 +302,6 @@ struct sta_priv {spinlock_t asoc_list_lock;struct list_head asoc_list; -#ifdef CONFIG_88EU_AP_MODE struct list_head auth_list;spinlock_t auth_list_lock;u8 asoc_list_cnt;
@@ -330,8 +325,6 @@ struct sta_priv {u16 max_num_sta;struct wlan_acl_pool acl_list; -#endif - };static inline u32 wifi_mac_hash (u8 *mac)
drivers/staging/r8188eu/os_dep/ioctl_linux.c +0 -38
@@ -137,7 +137,6 @@ static char *translate_scan(struct adapter *padapter,u8 bw_40MHz =0 , short_GI =0 ;u16 mcs_rate =0 ;u8 ss, sq; -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &padapter->wdinfo;if (!rtw_p2p_chk_state (pwdinfo,P2P_STATE_NONE )) {
@@ -165,7 +164,6 @@ static char *translate_scan(struct adapter *padapter,if (!blnGotP2PIE)return start; } -#endif /* CONFIG_88EU_P2P */ /* AP MAC address */ iwe.cmd =SIOCGIWAP ;
@@ -424,9 +422,7 @@ static int wpa_set_encryption(struct net_device *dev, struct ieee_param *param,struct adapter *padapter = (struct adapter *)rtw_netdev_priv (dev);struct mlme_priv *pmlmepriv = &padapter->mlmepriv;struct security_priv *psecuritypriv = &padapter->securitypriv; -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &padapter->wdinfo; -#endif /* CONFIG_88EU_P2P */ param->u.crypt.err =0 ; param->u.crypt.alg[IEEE_CRYPT_ALG_NAME_LEN -1 ] ='\0' ;
@@ -539,10 +535,8 @@ static int wpa_set_encryption(struct net_device *dev, struct ieee_param *param, padapter->securitypriv.dot118021XGrpKeyid = param->u.crypt.idx;rtw_set_key (padapter, &padapter->securitypriv, param->u.crypt.idx,1 ); -#ifdef CONFIG_88EU_P2P if (rtw_p2p_chk_state (pwdinfo,P2P_STATE_PROVISIONING_ING ))rtw_p2p_set_state (pwdinfo,P2P_STATE_PROVISIONING_DONE ); -#endif /* CONFIG_88EU_P2P */ } } pbcmc_sta =rtw_get_bcmc_stainfo (padapter);
@@ -572,9 +566,7 @@ static int rtw_set_wpa_ie(struct adapter *padapter, char *pie, unsigned short ieu8 *buf =NULL ;int group_cipher =0 , pairwise_cipher =0 ;int ret =0 ; -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &padapter->wdinfo; -#endif /* CONFIG_88EU_P2P */ if (ielen >MAX_WPA_IE_LEN || !pie) {_clr_fwstate_ (&padapter->mlmepriv,WIFI_UNDER_WPS );
@@ -677,10 +669,8 @@ static int rtw_set_wpa_ie(struct adapter *padapter, char *pie, unsigned short iememcpy (padapter->securitypriv.wps_ie, &buf[cnt], padapter->securitypriv.wps_ie_len);set_fwstate (&padapter->mlmepriv,WIFI_UNDER_WPS ); -#ifdef CONFIG_88EU_P2P if (rtw_p2p_chk_state (pwdinfo,P2P_STATE_GONEGO_OK ))rtw_p2p_set_state (pwdinfo,P2P_STATE_PROVISIONING_ING ); -#endif /* CONFIG_88EU_P2P */ cnt += buf[cnt +1 ] +2 ;break ; }else {
@@ -1149,9 +1139,7 @@ static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a,struct adapter *padapter = (struct adapter *)rtw_netdev_priv (dev);struct mlme_priv *pmlmepriv = &padapter->mlmepriv;struct ndis_802_11_ssid ssid[RTW_SSID_SCAN_AMOUNT ]; -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &padapter->wdinfo; -#endif /* CONFIG_88EU_P2P */ if (padapter->registrypriv.mp_mode ==1 ) {if (check_fwstate (pmlmepriv,WIFI_MP_STATE )) {
@@ -1197,14 +1185,12 @@ static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a,/* the pmlmepriv->scan_interval is always equal to 3. */ /* So, the wpa_supplicant won't find out the WPS SoftAP. */ -#ifdef CONFIG_88EU_P2P if (pwdinfo->p2p_state !=P2P_STATE_NONE ) {rtw_p2p_set_pre_state (pwdinfo,rtw_p2p_state (pwdinfo));rtw_p2p_set_state (pwdinfo,P2P_STATE_FIND_PHASE_SEARCH );rtw_p2p_findphase_ex_set (pwdinfo,P2P_FINDPHASE_EX_FULL );rtw_free_network_queue (padapter, true); } -#endif /* CONFIG_88EU_P2P */ memset (ssid,0 ,sizeof (struct ndis_802_11_ssid ) *RTW_SSID_SCAN_AMOUNT );
@@ -1300,16 +1286,13 @@ static int rtw_wx_get_scan(struct net_device *dev, struct iw_request_info *a,u32 cnt =0 ;u32 wait_for_surveydone;int wait_status; -#ifdef CONFIG_88EU_P2P struct wifidirect_info *pwdinfo = &padapter->wdinfo; -#endif /* CONFIG_88EU_P2P */ if (padapter->pwrctrlpriv.brfoffbyhw && padapter->bDriverStopped) { ret = -EINVAL ; goto exit; } -#ifdef CONFIG_88EU_P2P if (!rtw_p2p_chk_state (pwdinfo,P2P_STATE_NONE )) {/* P2P is enabled */ wait_for_surveydone =200 ;
@@ -1317,11 +1300,6 @@ static int rtw_wx_get_scan(struct net_device *dev, struct iw_request_info *a,/* P2P is disabled */ wait_for_surveydone =100 ; } -#else - { - wait_for_surveydone =100 ; - } -#endif /* CONFIG_88EU_P2P */ wait_status = _FW_UNDER_SURVEY | _FW_UNDER_LINKING;
@@ -2557,7 +2535,6 @@ static int rtw_wps_start(struct net_device *dev,return ret; } -#ifdef CONFIG_88EU_P2P static int rtw_wext_p2p_enable (struct net_device *dev,struct iw_request_info *info,union iwreq_data *wrqu,char *extra)
@@ -3662,15 +3639,12 @@ static int rtw_p2p_got_wpsinfo(struct net_device *dev,return ret; } -#endif /* CONFIG_88EU_P2P */ -static int rtw_p2p_set (struct net_device *dev,struct iw_request_info *info,union iwreq_data *wrqu,char *extra) {int ret =0 ; -#ifdef CONFIG_88EU_P2P DBG_88E ("[%s] extra = %s\n" , __func__, extra);if (!memcmp (extra,"enable =" ,7 )) {rtw_wext_p2p_enable (dev, info, wrqu, &extra[7 ]);
@@ -3717,7 +3691,6 @@ static int rtw_p2p_set(struct net_device *dev, wrqu->data.length -=11 ;rtw_p2p_set_persistent (dev, info, wrqu, &extra[11 ]); } -#endif /* CONFIG_88EU_P2P */ return ret; }
@@ -3728,7 +3701,6 @@ static int rtw_p2p_get(struct net_device *dev, {int ret =0 ; -#ifdef CONFIG_88EU_P2P struct adapter *padapter = (struct adapter *)rtw_netdev_priv (dev);if (padapter->bShowGetP2PState)
@@ -3752,7 +3724,6 @@ static int rtw_p2p_get(struct net_device *dev, }else if (!memcmp (wrqu->data.pointer,"op_ch" ,5 )) {rtw_p2p_get_op_ch (dev, info, wrqu, extra); } -#endif /* CONFIG_88EU_P2P */ return ret; }
@@ -3762,7 +3733,6 @@ static int rtw_p2p_get2(struct net_device *dev, {int ret =0 ; -#ifdef CONFIG_88EU_P2P DBG_88E ("[%s] extra = %s\n" , __func__, (char *)wrqu->data.pointer);if (!memcmp (extra,"wpsCM =" ,6 )) { wrqu->data.length -=6 ;
@@ -3781,8 +3751,6 @@ static int rtw_p2p_get2(struct net_device *dev,rtw_p2p_get_invitation_procedure (dev, info, wrqu, &extra[8 ]); } -#endif /* CONFIG_88EU_P2P */ -return ret; }
@@ -4247,9 +4215,7 @@ static int rtw_dbg_port(struct net_device *dev,struct list_head *plist, *phead;struct recv_reorder_ctrl *preorder_ctrl; -#ifdef CONFIG_88EU_AP_MODE DBG_88E ("sta_dz_bitmap = 0x%x, tim_bitmap = 0x%x\n" , pstapriv->sta_dz_bitmap, pstapriv->tim_bitmap); -#endif spin_lock_bh (&pstapriv->sta_hash_lock);for (i =0 ; i <NUM_STA ; i++) {
@@ -4270,14 +4236,12 @@ static int rtw_dbg_port(struct net_device *dev,DBG_88E ("ampdu_enable = %d\n" , psta->htpriv.ampdu_enable);DBG_88E ("agg_enable_bitmap =%x, candidate_tid_bitmap =%x\n" , psta->htpriv.agg_enable_bitmap, psta->htpriv.candidate_tid_bitmap); -#ifdef CONFIG_88EU_AP_MODE DBG_88E ("capability = 0x%x\n" , psta->capability);DBG_88E ("flags = 0x%x\n" , psta->flags);DBG_88E ("wpa_psk = 0x%x\n" , psta->wpa_psk);DBG_88E ("wpa2_group_cipher = 0x%x\n" , psta->wpa2_group_cipher);DBG_88E ("wpa2_pairwise_cipher = 0x%x\n" , psta->wpa2_pairwise_cipher);DBG_88E ("qos_info = 0x%x\n" , psta->qos_info); -#endif DBG_88E ("dot118021XPrivacy = 0x%x\n" , psta->dot118021XPrivacy);for (j =0 ; j <16 ; j++) {
@@ -4358,10 +4322,8 @@ static int rtw_dbg_port(struct net_device *dev, padapter->bNotifyChannelChange = extra_arg;break ;case 0x24 : -#ifdef CONFIG_88EU_P2P DBG_88E ("turn %s the bShowGetP2PState Variable\n" , (extra_arg ==1 ) ?"on" :"off" ); padapter->bShowGetP2PState = extra_arg; -#endif /* CONFIG_88EU_P2P */ break ;case 0xaa :if (extra_arg >0x13 )
drivers/staging/r8188eu/os_dep/mlme_linux.c +0 -4
@@ -165,8 +165,6 @@ void init_mlme_ext_timer(struct adapter *padapter)timer_setup (&pmlmeext->link_timer, _link_timer_hdl,0 ); } -#ifdef CONFIG_88EU_AP_MODE -void rtw_indicate_sta_assoc_event (struct adapter *padapter,struct sta_info *psta) {union iwreq_data wrqu;
@@ -212,5 +210,3 @@ void rtw_indicate_sta_disassoc_event(struct adapter *padapter, struct sta_info *wireless_send_event (padapter->pnetdev,IWEVEXPIRED , &wrqu,NULL ); } - -#endif
drivers/staging/r8188eu/os_dep/os_intfs.c +0 -13
@@ -362,15 +362,12 @@ void rtw_proc_init_one(struct net_device *dev) } } -#ifdef CONFIG_88EU_AP_MODE - entry =create_proc_read_entry ("all_sta_info" ,S_IFREG |S_IRUGO , dir_dev, proc_get_all_sta_info, dev);if (!entry) {pr_info ("Unable to create_proc_read_entry!\n" );return ; } -#endif entry =create_proc_read_entry ("best_channel" ,S_IFREG |S_IRUGO , dir_dev, proc_get_best_channel, dev);
@@ -467,9 +464,7 @@ void rtw_proc_remove_one(struct net_device *dev)remove_proc_entry ("rf_reg_dump3" , dir_dev);remove_proc_entry ("rf_reg_dump4" , dir_dev); } -#ifdef CONFIG_88EU_AP_MODE remove_proc_entry ("all_sta_info" , dir_dev); -#endif remove_proc_entry ("best_channel" , dir_dev);remove_proc_entry ("rx_signal" , dir_dev);
@@ -789,9 +784,7 @@ static u8 rtw_init_default_value(struct adapter *padapter) padapter->bWritePortCancel = false; padapter->bRxRSSIDisplay =0 ; padapter->bNotifyChannelChange =0 ; -#ifdef CONFIG_88EU_P2P padapter->bShowGetP2PState =1 ; -#endif return _SUCCESS; }
@@ -846,11 +839,9 @@ u8 rtw_init_drv_sw(struct adapter *padapter) goto exit; } -#ifdef CONFIG_88EU_P2P rtw_init_wifidirect_timers (padapter);init_wifidirect_info (padapter,P2P_ROLE_DISABLE );reset_global_wifidirect_info (padapter); -#endif /* CONFIG_88EU_P2P */ if (init_mlme_ext_priv (padapter) == _FAIL) { ret8 = _FAIL;
@@ -920,7 +911,6 @@ u8 rtw_free_drv_sw(struct adapter *padapter)/* we can call rtw_p2p_enable here, but: */ /* 1. rtw_p2p_enable may have IO operation */ /* 2. rtw_p2p_enable is bundled with wext interface */ -#ifdef CONFIG_88EU_P2P {struct wifidirect_info *pwdinfo = &padapter->wdinfo;if (!rtw_p2p_chk_state (pwdinfo,P2P_STATE_NONE )) {
@@ -930,7 +920,6 @@ u8 rtw_free_drv_sw(struct adapter *padapter)rtw_p2p_set_state (pwdinfo,P2P_STATE_NONE ); } } -#endif free_mlme_ext_priv (&padapter->mlmeextpriv);
@@ -1185,9 +1174,7 @@ int netdev_close(struct net_device *pnetdev)nat25_db_cleanup (padapter); -#ifdef CONFIG_88EU_P2P rtw_p2p_enable (padapter,P2P_ROLE_DISABLE ); -#endif /* CONFIG_88EU_P2P */ kfree (dvobj->firmware.szFwBuffer); dvobj->firmware.szFwBuffer =NULL ;
drivers/staging/r8188eu/os_dep/usb_intf.c +0 -4
@@ -630,10 +630,8 @@ static struct adapter *rtw_usb_if1_init(struct dvobj_priv *dvobj,/* alloc dev name after read efuse. */ rtw_init_netdev_name (pnetdev, padapter->registrypriv.ifname);rtw_macaddr_cfg (padapter->eeprompriv.mac_addr); -#ifdef CONFIG_88EU_P2P rtw_init_wifidirect_addrs (padapter, padapter->eeprompriv.mac_addr, padapter->eeprompriv.mac_addr); -#endif memcpy (pnetdev->dev_addr, padapter->eeprompriv.mac_addr,ETH_ALEN );DBG_88E ("MAC Address from pnetdev->dev_addr = %pM\n" , pnetdev->dev_addr);
@@ -677,9 +675,7 @@ static void rtw_usb_if1_deinit(struct adapter *if1)if (check_fwstate (pmlmepriv, _FW_LINKED))rtw_disassoc_cmd (if1,0 , false); -#ifdef CONFIG_88EU_AP_MODE free_mlme_ap_info (if1); -#endif if (if1->DriverState !=DRIVER_DISAPPEAR ) {if (pnetdev) {
drivers/staging/r8188eu/os_dep/usb_ops_linux.c +0 -2
@@ -79,9 +79,7 @@ static void usb_write_port_complete(struct urb *purb, struct pt_regs *regs) pxmitpriv->bkq_cnt--;break ;case HIGH_QUEUE_INX : -#ifdef CONFIG_88EU_AP_MODE rtw_chk_hi_queue_cmd (padapter); -#endif break ;default :break ;
Signature · 1 line
2.33.0