From 5175f81cb1dba5745c724dd6b6062a14aca8e1a3 Mon Sep 17 00:00:00 2001 From: Larry Finger Date: Sun, 21 Jul 2013 20:37:56 -0500 Subject: [PATCH] rtl8188eu: Remove CONFIG_DBG_P2P Signed-off-by: Larry Finger --- core/rtw_mlme_ext.c | 3 -- core/rtw_p2p.c | 73 --------------------------------------------- include/rtw_p2p.h | 12 -------- 3 files changed, 88 deletions(-) diff --git a/core/rtw_mlme_ext.c b/core/rtw_mlme_ext.c index 7165979..fa31d56 100644 --- a/core/rtw_mlme_ext.c +++ b/core/rtw_mlme_ext.c @@ -7398,9 +7398,6 @@ void site_survey(_adapter *padapter) /* This will let the following flow to run the scanning end. */ rtw_p2p_findphase_ex_set(pwdinfo, P2P_FINDPHASE_EX_MAX); } - #ifdef CONFIG_DBG_P2P - DBG_88E( "[%s] find phase exchange cnt = %d\n", __func__, pwdinfo->find_phase_state_exchange_cnt ); - #endif } if (rtw_p2p_findphase_ex_is_needed(pwdinfo)) diff --git a/core/rtw_p2p.c b/core/rtw_p2p.c index b300c08..c169305 100644 --- a/core/rtw_p2p.c +++ b/core/rtw_p2p.c @@ -2264,79 +2264,6 @@ void init_wifidirect_info( _adapter* padapter, enum P2P_ROLE role) pwdinfo->p2p_info.scan_op_ch_only = 0; } -#ifdef CONFIG_DBG_P2P -char * p2p_role_str[] = { - "P2P_ROLE_DISABLE", - "P2P_ROLE_DEVICE", - "P2P_ROLE_CLIENT", - "P2P_ROLE_GO" -}; - -char * p2p_state_str[] = { - "P2P_STATE_NONE", - "P2P_STATE_IDLE", - "P2P_STATE_LISTEN", - "P2P_STATE_SCAN", - "P2P_STATE_FIND_PHASE_LISTEN", - "P2P_STATE_FIND_PHASE_SEARCH", - "P2P_STATE_TX_PROVISION_DIS_REQ", - "P2P_STATE_RX_PROVISION_DIS_RSP", - "P2P_STATE_RX_PROVISION_DIS_REQ", - "P2P_STATE_GONEGO_ING", - "P2P_STATE_GONEGO_OK", - "P2P_STATE_GONEGO_FAIL", - "P2P_STATE_RECV_INVITE_REQ_MATCH", - "P2P_STATE_PROVISIONING_ING", - "P2P_STATE_PROVISIONING_DONE", - "P2P_STATE_RECV_INVITE_REQ_DISMATCH", - "P2P_STATE_RECV_INVITE_REQ_GO" -}; - -void dbg_rtw_p2p_set_state(struct wifidirect_info *wdinfo, enum P2P_STATE state, const char *caller, int line) -{ - if (!_rtw_p2p_chk_state(wdinfo, state)) { - enum P2P_STATE old_state = _rtw_p2p_state(wdinfo); - _rtw_p2p_set_state(wdinfo, state); - DBG_88E("[CONFIG_DBG_P2P]%s:%d set_state from %s to %s\n", caller, line - , p2p_state_str[old_state], p2p_state_str[_rtw_p2p_state(wdinfo)] - ); - } else { - DBG_88E("[CONFIG_DBG_P2P]%s:%d set_state to same state %s\n", caller, line - , p2p_state_str[_rtw_p2p_state(wdinfo)] - ); - } -} -void dbg_rtw_p2p_set_pre_state(struct wifidirect_info *wdinfo, enum P2P_STATE state, const char *caller, int line) -{ - if (_rtw_p2p_pre_state(wdinfo) != state) { - enum P2P_STATE old_state = _rtw_p2p_pre_state(wdinfo); - _rtw_p2p_set_pre_state(wdinfo, state); - DBG_88E("[CONFIG_DBG_P2P]%s:%d set_pre_state from %s to %s\n", caller, line - , p2p_state_str[old_state], p2p_state_str[_rtw_p2p_pre_state(wdinfo)] - ); - } else { - DBG_88E("[CONFIG_DBG_P2P]%s:%d set_pre_state to same state %s\n", caller, line - , p2p_state_str[_rtw_p2p_pre_state(wdinfo)] - ); - } -} - -void dbg_rtw_p2p_set_role(struct wifidirect_info *wdinfo, enum P2P_ROLE role, const char *caller, int line) -{ - if (wdinfo->role != role) { - enum P2P_ROLE old_role = wdinfo->role; - _rtw_p2p_set_role(wdinfo, role); - DBG_88E("[CONFIG_DBG_P2P]%s:%d set_role from %s to %s\n", caller, line - , p2p_role_str[old_role], p2p_role_str[wdinfo->role] - ); - } else { - DBG_88E("[CONFIG_DBG_P2P]%s:%d set_role to same role %s\n", caller, line - , p2p_role_str[wdinfo->role] - ); - } -} -#endif /* CONFIG_DBG_P2P */ - int rtw_p2p_enable(_adapter *padapter, enum P2P_ROLE role) { int ret = _SUCCESS; diff --git a/include/rtw_p2p.h b/include/rtw_p2p.h index 83117c2..b512957 100644 --- a/include/rtw_p2p.h +++ b/include/rtw_p2p.h @@ -93,21 +93,9 @@ static inline bool _rtw_p2p_chk_role(struct wifidirect_info *wdinfo, enum P2P_RO return wdinfo->role == role; } -#ifdef CONFIG_DBG_P2P -void dbg_rtw_p2p_set_state(struct wifidirect_info *wdinfo, enum P2P_STATE state, const char *caller, int line); -void dbg_rtw_p2p_set_pre_state(struct wifidirect_info *wdinfo, enum P2P_STATE state, const char *caller, int line); -//void dbg_rtw_p2p_restore_state(struct wifidirect_info *wdinfo, const char *caller, int line); -void dbg_rtw_p2p_set_role(struct wifidirect_info *wdinfo, enum P2P_ROLE role, const char *caller, int line); -#define rtw_p2p_set_state(wdinfo, state) dbg_rtw_p2p_set_state(wdinfo, state, __func__, __LINE__) -#define rtw_p2p_set_pre_state(wdinfo, state) dbg_rtw_p2p_set_pre_state(wdinfo, state, __func__, __LINE__) -#define rtw_p2p_set_role(wdinfo, role) dbg_rtw_p2p_set_role(wdinfo, role, __func__, __LINE__) -//#define rtw_p2p_restore_state(wdinfo) dbg_rtw_p2p_restore_state(wdinfo, __func__, __LINE__) -#else //CONFIG_DBG_P2P #define rtw_p2p_set_state(wdinfo, state) _rtw_p2p_set_state(wdinfo, state) #define rtw_p2p_set_pre_state(wdinfo, state) _rtw_p2p_set_pre_state(wdinfo, state) #define rtw_p2p_set_role(wdinfo, role) _rtw_p2p_set_role(wdinfo, role) -//#define rtw_p2p_restore_state(wdinfo) _rtw_p2p_restore_state(wdinfo) -#endif //CONFIG_DBG_P2P #define rtw_p2p_state(wdinfo) _rtw_p2p_state(wdinfo) #define rtw_p2p_pre_state(wdinfo) _rtw_p2p_pre_state(wdinfo)