diff --git a/core/mac/inc/ani_global.h b/core/mac/inc/ani_global.h index 318f47b7ce16..855180afa1c2 100644 --- a/core/mac/inc/ani_global.h +++ b/core/mac/inc/ani_global.h @@ -295,11 +295,6 @@ typedef struct sLimTimers { TX_TIMER gLimPeriodicJoinProbeReqTimer; TX_TIMER gLimDisassocAckTimer; TX_TIMER gLimDeauthAckTimer; - /* This timer is used to convert active channel to - * passive channel when there is no beacon - * for a period of time on a particular DFS channel - */ - TX_TIMER gLimActiveToPassiveChannelTimer; TX_TIMER g_lim_periodic_auth_retry_timer; /* SAE authentication related timer */ @@ -684,7 +679,6 @@ typedef struct sAniSirLim { uint8_t reAssocRetryAttempt; tLimDisassocDeauthCnfReq limDisassocDeauthCnfReq; uint8_t deferredMsgCnt; - tSirDFSChannelList dfschannelList; uint8_t deauthMsgCnt; uint8_t disassocMsgCnt; uint8_t gLimIbssStaLimit; diff --git a/core/mac/inc/sir_api.h b/core/mac/inc/sir_api.h index e672f25790f8..727c099ad33a 100644 --- a/core/mac/inc/sir_api.h +++ b/core/mac/inc/sir_api.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -62,10 +62,6 @@ struct mac_context; #define SIR_MAX_ELEMENT_ID 255 -/* Max number of channels are 165, but to access 165th element of array, - *array of 166 is required. - */ -#define SIR_MAX_24G_5G_CHANNEL_RANGE 166 #define SIR_BCN_REPORT_MAX_BSS_DESC 4 #define SIR_NUM_11B_RATES 4 /* 1,2,5.5,11 */ @@ -747,11 +743,6 @@ typedef struct sSirChannelList { uint8_t channelNumber[SIR_ESE_MAX_MEAS_IE_REQS]; } tSirChannelList, *tpSirChannelList; -typedef struct sSirDFSChannelList { - uint32_t timeStamp[SIR_MAX_24G_5G_CHANNEL_RANGE]; - -} tSirDFSChannelList, *tpSirDFSChannelList; - /* / Two Background Scan mode */ typedef enum eSirBackgroundScanMode { eSIR_ROAMING_SCAN = 2, diff --git a/core/mac/inc/wni_api.h b/core/mac/inc/wni_api.h index 10b929392131..bad296d5a90e 100644 --- a/core/mac/inc/wni_api.h +++ b/core/mac/inc/wni_api.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -84,7 +84,6 @@ enum eWniMsgTypes { eWNI_SME_UPPER_LAYER_ASSOC_CNF, eWNI_SME_SESSION_UPDATE_PARAM, eWNI_SME_CHNG_MCC_BEACON_INTERVAL, - eWNI_SME_CLEAR_DFS_CHANNEL_LIST, eWNI_SME_GET_SNR_REQ, eWNI_SME_RRM_MSG_TYPE_BEGIN, diff --git a/core/mac/inc/wni_cfg.h b/core/mac/inc/wni_cfg.h index 80e26c66ca42..58a4f90e6112 100644 --- a/core/mac/inc/wni_cfg.h +++ b/core/mac/inc/wni_cfg.h @@ -31,7 +31,6 @@ enum { WNI_CFG_CURRENT_TX_POWER_LEVEL, WNI_CFG_COUNTRY_CODE, WNI_CFG_LOCAL_POWER_CONSTRAINT, - WNI_CFG_SCAN_CONTROL_LIST, WNI_CFG_ENABLE_MCC_ADAPTIVE_SCHED, WNI_CFG_PS_WOW_DATA_INACTIVITY_TIMEOUT, WNI_CFG_OBSS_DETECTION_OFFLOAD, @@ -47,7 +46,6 @@ enum { #define WNI_CFG_STA_ID_LEN 6 #define WNI_CFG_VALID_CHANNEL_LIST_LEN 100 #define WNI_CFG_COUNTRY_CODE_LEN 3 -#define WNI_CFG_SCAN_CONTROL_LIST_LEN 128 #define WNI_CFG_PROBE_RSP_ADDNIE_DATA1_LEN 255 #define WNI_CFG_ASSOC_RSP_ADDNIE_DATA_LEN 255 #define WNI_CFG_PROBE_RSP_BCN_ADDNIE_DATA_LEN 255 diff --git a/core/mac/src/cfg/cfg_param_name.c b/core/mac/src/cfg/cfg_param_name.c index 688754bd1a91..a4ac0d01de4c 100644 --- a/core/mac/src/cfg/cfg_param_name.c +++ b/core/mac/src/cfg/cfg_param_name.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -46,7 +46,6 @@ const char *cfg_get_string(uint16_t cfg_id) CASE_RETURN_STRING(WNI_CFG_CURRENT_TX_POWER_LEVEL); CASE_RETURN_STRING(WNI_CFG_COUNTRY_CODE); CASE_RETURN_STRING(WNI_CFG_LOCAL_POWER_CONSTRAINT); - CASE_RETURN_STRING(WNI_CFG_SCAN_CONTROL_LIST); CASE_RETURN_STRING(WNI_CFG_ENABLE_MCC_ADAPTIVE_SCHED); CASE_RETURN_STRING(WNI_CFG_PS_WOW_DATA_INACTIVITY_TIMEOUT); CASE_RETURN_STRING(WNI_CFG_OBSS_DETECTION_OFFLOAD); diff --git a/core/mac/src/cfg/cfg_proc_msg.c b/core/mac/src/cfg/cfg_proc_msg.c index 83eb959d2f56..4f6c45b8bc9e 100644 --- a/core/mac/src/cfg/cfg_proc_msg.c +++ b/core/mac/src/cfg/cfg_proc_msg.c @@ -58,10 +58,6 @@ cgstatic cfg_static[CFG_PARAM_MAX_NUM] = { WNI_CFG_LOCAL_POWER_CONSTRAINT_STAMIN, WNI_CFG_LOCAL_POWER_CONSTRAINT_STAMAX, WNI_CFG_LOCAL_POWER_CONSTRAINT_STADEF}, - {WNI_CFG_SCAN_CONTROL_LIST, - CFG_CTL_VALID | CFG_CTL_RE | CFG_CTL_WE | CFG_CTL_RESTART | - CFG_CTL_NTF_LIM, - 0, 0, 0}, {WNI_CFG_ENABLE_MCC_ADAPTIVE_SCHED, CFG_CTL_VALID | CFG_CTL_RE | CFG_CTL_WE | CFG_CTL_INT, WNI_CFG_ENABLE_MCC_ADAPTIVE_SCHED_STAMIN, @@ -103,18 +99,6 @@ cfgstatic_string cfg_static_string[CFG_MAX_STATIC_STRING] = { WNI_CFG_COUNTRY_CODE_LEN, 0, {0} }, - {WNI_CFG_SCAN_CONTROL_LIST, - WNI_CFG_SCAN_CONTROL_LIST_LEN, - 114, - {0x1, 0x1, 0x2, 0x1, 0x3, 0x1, 0x4, 0x1, 0x5, 0x1, 0x6, 0x1, 0x7, 0x1, - 0x8, 0x1, 0x9, 0x1, 0xa, 0x1, 0xb, 0x1, 0xc, 0x1, 0xd, 0x1, 0xe, 0x1, - 0x22, 0x1, 0x24, 0x1, 0x26, 0x1, 0x28, 0x1, 0x2a, 0x1, 0x2c, 0x1, 0x2e, - 0x1, 0x30, 0x1, 0x32, 0x1, 0x34, 0x0, 0x36, 0x0, 0x38, 0x0, 0x3a, 0x0, - 0x3c, 0x0, 0x3e, 0x0, 0x40, 0x0, 0x64, 0x0, 0x68, 0x0, 0x6c, 0x0, 0x70, - 0x0, 0x74, 0x0, 0x78, 0x0, 0x7c, 0x0, 0x80, 0x0, 0x84, 0x0, 0x88, 0x0, - 0x8c, 0x0, 0x90, 0x0, 0x95, 0x1, 0x97, 0x1, 0x99, 0x1, 0x9b, 0x1, 0x9d, - 0x1, 0x9f, 0x1, 0xa1, 0x1, 0xa5, 0x1, 0xf0, 0x1, 0xf2, 0x1, 0xf4, 0x1, - 0xf6, 0x1, 0xf8, 0x1, 0xfa, 0x1, 0xfc, 0x1} }, }; /*--------------------------------------------------------------------*/ diff --git a/core/mac/src/include/sir_params.h b/core/mac/src/include/sir_params.h index 103eb3bef35f..84818a43b672 100644 --- a/core/mac/src/include/sir_params.h +++ b/core/mac/src/include/sir_params.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -765,8 +765,6 @@ struct sir_cfg_action_frm_tb_ppdu { #define SIR_LIM_PERIODIC_JOIN_PROBE_REQ_TIMEOUT \ (SIR_LIM_TIMEOUT_MSG_START + 0x28) -#define SIR_LIM_CONVERT_ACTIVE_CHANNEL_TO_PASSIVE \ - (SIR_LIM_TIMEOUT_MSG_START + 0x2C) #define SIR_LIM_AUTH_RETRY_TIMEOUT (SIR_LIM_TIMEOUT_MSG_START + 0x2D) #define SIR_LIM_AUTH_SAE_TIMEOUT (SIR_LIM_TIMEOUT_MSG_START + 0x2E) diff --git a/core/mac/src/pe/lim/lim_api.c b/core/mac/src/pe/lim/lim_api.c index e1a0d295fce9..227bd5dfa4f3 100644 --- a/core/mac/src/pe/lim/lim_api.c +++ b/core/mac/src/pe/lim/lim_api.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -75,11 +75,6 @@ #include "cfg_ucfg_api.h" #include "wlan_mlme_public_struct.h" -static void __lim_init_scan_vars(struct mac_context *mac) -{ - qdf_mem_set(&mac->lim.dfschannelList, sizeof(tSirDFSChannelList), 0); -} - static void __lim_init_bss_vars(struct mac_context *mac) { qdf_mem_set((void *)mac->lim.gpSession, @@ -422,7 +417,6 @@ QDF_STATUS lim_initialize(struct mac_context *mac) __lim_init_states(mac); __lim_init_stats_vars(mac); __lim_init_bss_vars(mac); - __lim_init_scan_vars(mac); __lim_init_ht_vars(mac); /* Initializations for maintaining peers in IBSS */ diff --git a/core/mac/src/pe/lim/lim_link_monitoring_algo.c b/core/mac/src/pe/lim/lim_link_monitoring_algo.c index caaa5d59ca68..b245e4a4a8ad 100644 --- a/core/mac/src/pe/lim/lim_link_monitoring_algo.c +++ b/core/mac/src/pe/lim/lim_link_monitoring_algo.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -526,13 +526,7 @@ void lim_handle_heart_beat_failure(struct mac_context *mac_ctx, session->dot11mode, NULL, NULL); } } else { - pe_debug("HB missed from AP on DFS chanel moving to passive"); - if (curr_chan < SIR_MAX_24G_5G_CHANNEL_RANGE) { - lim_covert_channel_scan_type(mac_ctx, curr_chan, - false); - mac_ctx->lim.dfschannelList. - timeStamp[curr_chan] = 0; - } + pe_debug("HB missed from AP on DFS channel"); /* * Connected on DFS channel so should not send the * probe request tear down the link directly diff --git a/core/mac/src/pe/lim/lim_process_beacon_frame.c b/core/mac/src/pe/lim/lim_process_beacon_frame.c index a724806d9768..e1093536cdc3 100644 --- a/core/mac/src/pe/lim/lim_process_beacon_frame.c +++ b/core/mac/src/pe/lim/lim_process_beacon_frame.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -110,18 +110,7 @@ lim_process_beacon_frame(struct mac_context *mac_ctx, uint8_t *rx_pkt_info, MTRACE(mac_trace(mac_ctx, TRACE_CODE_RX_MGMT_TSF, 0, bcn_ptr->timeStamp[1])); - if ((mac_ctx->lim.gLimMlmState == - eLIM_MLM_WT_PROBE_RESP_STATE) || - (mac_ctx->lim.gLimMlmState == - eLIM_MLM_PASSIVE_SCAN_STATE)) { - /* - * Calling dfsChannelList which will convert DFS channel - * to active channel for x secs if this channel is DFS - */ - lim_set_dfs_channel_list(mac_ctx, - bcn_ptr->channelNumber, - &mac_ctx->lim.dfschannelList); - } else if (session->limMlmState == + if (session->limMlmState == eLIM_MLM_WT_JOIN_BEACON_STATE) { if (session->beacon != NULL) { qdf_mem_free(session->beacon); diff --git a/core/mac/src/pe/lim/lim_process_message_queue.c b/core/mac/src/pe/lim/lim_process_message_queue.c index 968733b68567..4147f0fb7897 100644 --- a/core/mac/src/pe/lim/lim_process_message_queue.c +++ b/core/mac/src/pe/lim/lim_process_message_queue.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -1642,7 +1642,6 @@ static void lim_process_messages(struct mac_context *mac_ctx, case eWNI_SME_FT_PRE_AUTH_REQ: case eWNI_SME_FT_AGGR_QOS_REQ: case eWNI_SME_REGISTER_MGMT_FRAME_REQ: - case eWNI_SME_CLEAR_DFS_CHANNEL_LIST: case eWNI_SME_GET_STATISTICS_REQ: #ifdef FEATURE_WLAN_ESE case eWNI_SME_GET_TSM_STATS_REQ: @@ -1767,7 +1766,6 @@ static void lim_process_messages(struct mac_context *mac_ctx, case SIR_LIM_FT_PREAUTH_RSP_TIMEOUT: case SIR_LIM_DISASSOC_ACK_TIMEOUT: case SIR_LIM_DEAUTH_ACK_TIMEOUT: - case SIR_LIM_CONVERT_ACTIVE_CHANNEL_TO_PASSIVE: case SIR_LIM_AUTH_RETRY_TIMEOUT: case SIR_LIM_AUTH_SAE_TIMEOUT: /* These timeout messages are handled by MLM sub module */ diff --git a/core/mac/src/pe/lim/lim_process_mlm_req_messages.c b/core/mac/src/pe/lim/lim_process_mlm_req_messages.c index 43eec84b6f0b..181f3b96702b 100644 --- a/core/mac/src/pe/lim/lim_process_mlm_req_messages.c +++ b/core/mac/src/pe/lim/lim_process_mlm_req_messages.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -148,9 +148,6 @@ void lim_process_mlm_req_messages(struct mac_context *mac_ctx, case SIR_LIM_FT_PREAUTH_RSP_TIMEOUT: lim_process_ft_preauth_rsp_timeout(mac_ctx); break; - case SIR_LIM_CONVERT_ACTIVE_CHANNEL_TO_PASSIVE: - lim_convert_active_channel_to_passive_channel(mac_ctx); - break; case SIR_LIM_DISASSOC_ACK_TIMEOUT: lim_process_disassoc_ack_timeout(mac_ctx); break; @@ -169,115 +166,6 @@ void lim_process_mlm_req_messages(struct mac_context *mac_ctx, } /* switch (msg->type) */ } -/** - * lim_covert_channel_scan_type() - switch between ACTIVE and PASSIVE scan type - * @mac_ctx: global MAC context - * @chan_num: channel number to change the scan type - * @passive_to_active: flag to indicate if switch allowed - * - * This function is called to get the list, - * change the channel type and set again. - * NOTE: If a channel is ACTIVE, this function will make it as PASSIVE - * If a channel is PASSIVE, this function will make it as ACTIVE - * - * Return: None - */ - -void lim_covert_channel_scan_type(struct mac_context *mac_ctx, uint8_t chan_num, - bool passive_to_active) -{ - - uint32_t i; - uint8_t chan_pair[WNI_CFG_SCAN_CONTROL_LIST_LEN]; - uint32_t len = WNI_CFG_SCAN_CONTROL_LIST_LEN; - QDF_STATUS status; - - status = wlan_cfg_get_str(mac_ctx, WNI_CFG_SCAN_CONTROL_LIST, - chan_pair, &len); - if (QDF_STATUS_SUCCESS != status) { - pe_err("Unable to get scan control list"); - return; - } - if (len > WNI_CFG_SCAN_CONTROL_LIST_LEN) { - pe_err("Invalid scan control list length: %d", len); - return; - } - for (i = 0; (i + 1) < len; i += 2) { - if (chan_pair[i] != chan_num) /* skip this channel */ - continue; - if ((eSIR_PASSIVE_SCAN == chan_pair[i + 1]) && - true == passive_to_active) { - pe_debug("Channel %d changed from Passive to Active", - chan_num); - chan_pair[i + 1] = eSIR_ACTIVE_SCAN; - break; - } - if ((eSIR_ACTIVE_SCAN == chan_pair[i + 1]) && - false == passive_to_active) { - pe_debug("Channel %d changed from Active to Passive", - chan_num); - chan_pair[i + 1] = eSIR_PASSIVE_SCAN; - break; - } - } - - cfg_set_str_notify(mac_ctx, WNI_CFG_SCAN_CONTROL_LIST, - (uint8_t *) chan_pair, len, false); - return; -} - -/** - * lim_set_dfs_channel_list() - convert dfs channel list to active channel list - * @mac_ctx: global MAC context. - * @chan_num: channel number - * @dfs_ch_list: list of DFS channels - * - * This function is called to convert DFS channel list to active channel list - * when any beacon is present on that channel. This function store time for - * passive channels which help to know that for how much time channel has been - * passive. - * - * NOTE: If a channel is ACTIVE, it won't store any time - * If a channel is PAssive, it will store time as timestamp - * - * Return: None - */ -void lim_set_dfs_channel_list(struct mac_context *mac_ctx, uint8_t chan_num, - tSirDFSChannelList *dfs_ch_list) -{ - bool pass_to_active = true; - - if (!((1 <= chan_num) && (165 >= chan_num))) { - pe_err("Invalid Channel: %d", chan_num); - return; - } - - if (lim_isconnected_on_dfs_channel(mac_ctx, chan_num)) { - if (dfs_ch_list->timeStamp[chan_num] == 0) { - /* - * Received first beacon; - * Convert DFS channel to Active channel. - */ - pe_debug("Received first beacon on DFS channel: %d", - chan_num); - lim_covert_channel_scan_type(mac_ctx, chan_num, - pass_to_active); - } - dfs_ch_list->timeStamp[chan_num] = - qdf_mc_timer_get_system_time(); - } else { - return; - } - - if (!tx_timer_running - (&mac_ctx->lim.limTimers.gLimActiveToPassiveChannelTimer)) { - tx_timer_activate( - &mac_ctx->lim.limTimers.gLimActiveToPassiveChannelTimer); - } - - return; -} - /** * mlm_add_sta() - MLM add sta * @mac_ctx: global MAC context diff --git a/core/mac/src/pe/lim/lim_process_sme_req_messages.c b/core/mac/src/pe/lim/lim_process_sme_req_messages.c index 62031d101f3d..1b7a652e4663 100644 --- a/core/mac/src/pe/lim/lim_process_sme_req_messages.c +++ b/core/mac/src/pe/lim/lim_process_sme_req_messages.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -1118,29 +1118,6 @@ void lim_get_random_bssid(struct mac_context *mac, uint8_t *data) qdf_mem_copy(data, (uint8_t *) random, sizeof(tSirMacAddr)); } -/** - * __lim_process_clear_dfs_channel_list() - * - ***FUNCTION: - ***Clear DFS channel list when country is changed/acquired. - .*This message is sent from SME. - * - ***LOGIC: - * - ***ASSUMPTIONS: - * - ***NOTE: - * - * @param mac Pointer to Global MAC structure - * @param *pMsgBuf A pointer to the SME message buffer - * @return None - */ -static void __lim_process_clear_dfs_channel_list(struct mac_context *mac, - struct scheduler_msg *pMsg) -{ - qdf_mem_set(&mac->lim.dfschannelList, sizeof(tSirDFSChannelList), 0); -} - #ifdef WLAN_FEATURE_SAE /** @@ -4949,9 +4926,6 @@ bool lim_process_sme_req_messages(struct mac_context *mac, bufConsumed = __lim_process_sme_start_bss_req(mac, pMsg); break; - case eWNI_SME_CLEAR_DFS_CHANNEL_LIST: - __lim_process_clear_dfs_channel_list(mac, pMsg); - break; case eWNI_SME_JOIN_REQ: __lim_process_sme_join_req(mac, pMsgBuf); break; diff --git a/core/mac/src/pe/lim/lim_timer_utils.c b/core/mac/src/pe/lim/lim_timer_utils.c index 941be6de785a..f4ad23be9ba6 100644 --- a/core/mac/src/pe/lim/lim_timer_utils.c +++ b/core/mac/src/pe/lim/lim_timer_utils.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -52,11 +52,6 @@ */ #define LIM_AUTH_SAE_TIMER_MS 5000 - -/* This timer is a periodic timer which expires at every 1 sec to - convert ACTIVE DFS channel to DFS channels */ -#define ACTIVE_TO_PASSIVE_CONVERISON_TIMEOUT 1000 - static bool lim_create_non_ap_timers(struct mac_context *mac) { uint32_t cfgValue; @@ -261,17 +256,6 @@ uint32_t lim_create_timers(struct mac_context *mac) goto err_timer; } - cfgValue = ACTIVE_TO_PASSIVE_CONVERISON_TIMEOUT; - cfgValue = SYS_MS_TO_TICKS(cfgValue); - if (tx_timer_create(mac, - &mac->lim.limTimers.gLimActiveToPassiveChannelTimer, - "ACTIVE TO PASSIVE CHANNEL", lim_timer_handler, - SIR_LIM_CONVERT_ACTIVE_CHANNEL_TO_PASSIVE, cfgValue, 0, - TX_NO_ACTIVATE) != TX_SUCCESS) { - pe_warn("could not create timer for passive channel to active channel"); - goto err_timer; - } - return TX_SUCCESS; err_timer: @@ -290,7 +274,6 @@ err_timer: tx_timer_delete(&mac->lim.limTimers.gLimPeriodicJoinProbeReqTimer); tx_timer_delete(&mac->lim.limTimers.g_lim_periodic_auth_retry_timer); tx_timer_delete(&mac->lim.limTimers.gLimChannelSwitchTimer); - tx_timer_delete(&mac->lim.limTimers.gLimActiveToPassiveChannelTimer); tx_timer_delete(&mac->lim.limTimers.sae_auth_timer); if (NULL != mac->lim.gLimPreAuthTimerTable.pTable) { @@ -684,31 +667,6 @@ void lim_deactivate_and_change_timer(struct mac_context *mac, uint32_t timerId) case eLIM_LEARN_DURATION_TIMER: break; - case eLIM_CONVERT_ACTIVE_CHANNEL_TO_PASSIVE: - if (tx_timer_deactivate - (&mac->lim.limTimers.gLimActiveToPassiveChannelTimer) != - TX_SUCCESS) { - /** - ** Could not deactivate Active to passive channel timer. - ** Log error. - **/ - pe_err("Unable to Deactivate Active to passive channel timer"); - return; - } - val = ACTIVE_TO_PASSIVE_CONVERISON_TIMEOUT; - val = SYS_MS_TO_TICKS(val); - if (tx_timer_change - (&mac->lim.limTimers.gLimActiveToPassiveChannelTimer, val, - 0) != TX_SUCCESS) { - /** - * Could not change timer to check scan type for passive channel. - * timer. Log error. - */ - pe_err("Unable to change timer"); - return; - } - break; - case eLIM_DISASSOC_ACK_TIMER: if (tx_timer_deactivate (&mac->lim.limTimers.gLimDisassocAckTimer) != TX_SUCCESS) { diff --git a/core/mac/src/pe/lim/lim_timer_utils.h b/core/mac/src/pe/lim/lim_timer_utils.h index 41437f7ac414..2de3393c7fdf 100644 --- a/core/mac/src/pe/lim/lim_timer_utils.h +++ b/core/mac/src/pe/lim/lim_timer_utils.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2014, 2016-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2014, 2016-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -55,7 +55,6 @@ enum { eLIM_DEAUTH_ACK_TIMER, eLIM_PERIODIC_JOIN_PROBE_REQ_TIMER, eLIM_INSERT_SINGLESHOT_NOA_TIMER, - eLIM_CONVERT_ACTIVE_CHANNEL_TO_PASSIVE, eLIM_AUTH_RETRY_TIMER, eLIM_AUTH_SAE_TIMER }; diff --git a/core/mac/src/pe/lim/lim_trace.c b/core/mac/src/pe/lim/lim_trace.c index 4eed14e5bb6b..c0f16c2cdef9 100644 --- a/core/mac/src/pe/lim/lim_trace.c +++ b/core/mac/src/pe/lim/lim_trace.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2013-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -65,7 +65,6 @@ static uint8_t *__lim_trace_get_timer_string(uint16_t timerId) CASE_RETURN_STRING(eLIM_DISASSOC_ACK_TIMER); CASE_RETURN_STRING(eLIM_DEAUTH_ACK_TIMER); CASE_RETURN_STRING(eLIM_PERIODIC_JOIN_PROBE_REQ_TIMER); - CASE_RETURN_STRING(eLIM_CONVERT_ACTIVE_CHANNEL_TO_PASSIVE); CASE_RETURN_STRING(eLIM_AUTH_RETRY_TIMER); default: return "UNKNOWN"; diff --git a/core/mac/src/pe/lim/lim_types.h b/core/mac/src/pe/lim/lim_types.h index ea3ad9f39539..d080ecb6cdca 100644 --- a/core/mac/src/pe/lim/lim_types.h +++ b/core/mac/src/pe/lim/lim_types.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -755,10 +755,6 @@ void lim_process_mlm_set_bss_key_rsp(struct mac_context *mac, /* Function to process WMA_SWITCH_CHANNEL_RSP message */ void lim_process_switch_channel_rsp(struct mac_context *mac, void *); -void lim_covert_channel_scan_type(struct mac_context *mac, uint8_t channelNum, - bool passiveToActive); -void lim_set_dfs_channel_list(struct mac_context *mac, uint8_t channelNum, - tSirDFSChannelList *dfsChannelList); QDF_STATUS lim_sta_send_down_link(join_params *param); #ifdef WLAN_FEATURE_11W diff --git a/core/mac/src/pe/lim/lim_utils.c b/core/mac/src/pe/lim/lim_utils.c index 7fc3c4516db9..c7383a84dcc6 100644 --- a/core/mac/src/pe/lim/lim_utils.c +++ b/core/mac/src/pe/lim/lim_utils.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -69,11 +69,6 @@ #define ASCII_SPACE_CHARACTER 0x20 -/* A DFS channel can be ACTIVE for max 9000 msec, from the last - received Beacon/Prpbe Resp. */ -#define MAX_TIME_TO_BE_ACTIVE_CHANNEL 9000 - - /** ------------------------------------------------------------- \fn lim_delete_dialogue_token_list \brief deletes the complete lim dialogue token linked list. @@ -602,9 +597,6 @@ void lim_deactivate_timers(struct mac_context *mac_ctx) } tx_timer_deactivate(&lim_timer->gLimDeauthAckTimer); - tx_timer_deactivate(&lim_timer-> - gLimActiveToPassiveChannelTimer); - tx_timer_deactivate(&lim_timer->sae_auth_timer); } @@ -674,9 +666,6 @@ void lim_cleanup_mlm(struct mac_context *mac_ctx) tx_timer_delete(&lim_timer->gLimDeauthAckTimer); - tx_timer_delete(&lim_timer-> - gLimActiveToPassiveChannelTimer); - tx_timer_delete(&lim_timer->sae_auth_timer); mac_ctx->lim.gLimTimersCreated = 0; @@ -2020,10 +2009,6 @@ static void __lim_process_channel_switch_timeout(struct pe_session *pe_session) return; } } - lim_covert_channel_scan_type(mac, pe_session->currentOperChannel, - false); - mac->lim.dfschannelList.timeStamp[pe_session->currentOperChannel] = - 0; switch (pe_session->gLimChannelSwitch.state) { case eLIM_CHANNEL_SWITCH_PRIMARY_ONLY: pe_warn("CHANNEL_SWITCH_PRIMARY_ONLY"); @@ -7858,45 +7843,6 @@ enum rateid lim_get_min_session_txrate(struct pe_session *session) return rid; } -void lim_convert_active_channel_to_passive_channel(struct mac_context *mac_ctx) -{ - uint64_t current_time; - uint64_t last_time = 0; - uint64_t time_diff; - uint8_t i; - - current_time = (uint64_t)qdf_mc_timer_get_system_time(); - for (i = 1; i < SIR_MAX_24G_5G_CHANNEL_RANGE; i++) { - if ((mac_ctx->lim.dfschannelList.timeStamp[i]) != 0) { - last_time = mac_ctx->lim.dfschannelList.timeStamp[i]; - if (current_time >= last_time) { - time_diff = (current_time - last_time); - } else { - time_diff = - (0xFFFFFFFF - last_time) + current_time; - } - - if (time_diff >= MAX_TIME_TO_BE_ACTIVE_CHANNEL) { - lim_covert_channel_scan_type(mac_ctx, i, false); - mac_ctx->lim.dfschannelList.timeStamp[i] = 0; - } - } - } - /* - * last_time is zero if there is no DFS active channels in the list. - * If this is non zero then we have active DFS channels so restart - * the timer. - */ - if (last_time != 0) { - if (tx_timer_activate - (&mac_ctx->lim.limTimers.gLimActiveToPassiveChannelTimer) - != TX_SUCCESS) { - pe_err("Active to Passive Channel timer not activated"); - } - } - return; -} - void lim_send_sme_mgmt_frame_ind(struct mac_context *mac_ctx, uint8_t frame_type, uint8_t *frame, uint32_t frame_len, uint16_t session_id, uint32_t rx_channel, diff --git a/core/mac/src/pe/lim/lim_utils.h b/core/mac/src/pe/lim/lim_utils.h index c5668bf86650..b36a278ce854 100644 --- a/core/mac/src/pe/lim/lim_utils.h +++ b/core/mac/src/pe/lim/lim_utils.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -184,17 +184,6 @@ void lim_send_sme_mgmt_frame_ind(struct mac_context *mac_ctx, uint8_t frame_type uint16_t session_id, uint32_t rx_channel, struct pe_session *psession_entry, int8_t rx_rssi); -/* - * lim_convert_active_channel_to_passive_channel() - Timer callback function - * @mac_ctx : Pointer to Global MAC structure - * - * It check active DFS channels and convert them to passive channels - * if there was no beacon/proberesp for MAX_TIME_TO_BE_ACTIVE_CHANNEL time - * - * Return: None -*/ -void lim_convert_active_channel_to_passive_channel(struct mac_context *mac_ctx); - /* * lim_deactivate_timers() - Function to deactivate lim timers * @mac_ctx: Pointer to global mac structure diff --git a/core/mac/src/sys/legacy/src/utils/src/mac_trace.c b/core/mac/src/sys/legacy/src/utils/src/mac_trace.c index 0b95d78298af..823a0c23bf0e 100644 --- a/core/mac/src/sys/legacy/src/utils/src/mac_trace.c +++ b/core/mac/src/sys/legacy/src/utils/src/mac_trace.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2013-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -260,7 +260,6 @@ uint8_t *mac_trace_get_sme_msg_string(uint16_t sme_msg) CASE_RETURN_STRING(eWNI_SME_UPPER_LAYER_ASSOC_CNF); CASE_RETURN_STRING(eWNI_SME_SESSION_UPDATE_PARAM); CASE_RETURN_STRING(eWNI_SME_CHNG_MCC_BEACON_INTERVAL); - CASE_RETURN_STRING(eWNI_SME_CLEAR_DFS_CHANNEL_LIST); CASE_RETURN_STRING(eWNI_SME_GET_SNR_REQ); CASE_RETURN_STRING(eWNI_SME_LINK_STATUS_IND); CASE_RETURN_STRING(eWNI_SME_RRM_MSG_TYPE_BEGIN); @@ -685,7 +684,6 @@ uint8_t *mac_trace_get_lim_msg_string(uint16_t lim_msg) CASE_RETURN_STRING(SIR_LIM_CHANNEL_SWITCH_TIMEOUT); CASE_RETURN_STRING(SIR_LIM_WPS_OVERLAP_TIMEOUT); CASE_RETURN_STRING(SIR_LIM_FT_PREAUTH_RSP_TIMEOUT); - CASE_RETURN_STRING(SIR_LIM_CONVERT_ACTIVE_CHANNEL_TO_PASSIVE); CASE_RETURN_STRING(SIR_LIM_BEACON_GEN_IND); CASE_RETURN_STRING(SIR_LIM_DISASSOC_ACK_TIMEOUT); CASE_RETURN_STRING(SIR_LIM_DEAUTH_ACK_TIMEOUT); diff --git a/core/sme/src/csr/csr_api_scan.c b/core/sme/src/csr/csr_api_scan.c index f274bdf7f2b9..ce6de903dcb6 100644 --- a/core/sme/src/csr/csr_api_scan.c +++ b/core/sme/src/csr/csr_api_scan.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -619,20 +619,6 @@ QDF_STATUS csr_save_to_channel_power2_g_5_g(struct mac_context *mac, return QDF_STATUS_SUCCESS; } -static void csr_clear_dfs_channel_list(struct mac_context *mac) -{ - tSirMbMsg *pMsg; - uint16_t msgLen; - - msgLen = (uint16_t) (sizeof(tSirMbMsg)); - pMsg = qdf_mem_malloc(msgLen); - if (NULL != pMsg) { - pMsg->type = eWNI_SME_CLEAR_DFS_CHANNEL_LIST; - pMsg->msgLen = msgLen; - umac_send_mb_message_to_mac(pMsg); - } -} - void csr_apply_power2_current(struct mac_context *mac) { sme_debug("Updating Cfg with power settings"); @@ -663,14 +649,6 @@ void csr_apply_channel_power_info_to_fw(struct mac_context *mac_ctx, csr_apply_power2_current(mac_ctx); csr_set_cfg_valid_channel_list(mac_ctx, tmp_ch_lst.channelList, tmp_ch_lst.numChannels); - /* - * extend scan capability, build a scan list based on the - * channel list : channel# + active/passive scan - */ - csr_set_cfg_scan_control_list(mac_ctx, countryCode, - &tmp_ch_lst); - /* Send msg to Lim to clear DFS channel list */ - csr_clear_dfs_channel_list(mac_ctx); } else { sme_err("11D channel list is empty"); } @@ -1695,51 +1673,6 @@ QDF_STATUS csr_get_country_code(struct mac_context *mac, uint8_t *pBuf, return QDF_STATUS_E_INVAL; } -void csr_set_cfg_scan_control_list(struct mac_context *mac, - uint8_t *countryCode, - struct csr_channel *pChannelList) -{ - uint8_t i, j; - bool found = false; - uint8_t *pControlList = NULL; - uint32_t len = WNI_CFG_SCAN_CONTROL_LIST_LEN; - - pControlList = qdf_mem_malloc(WNI_CFG_SCAN_CONTROL_LIST_LEN); - if (pControlList != NULL) { - if (QDF_IS_STATUS_SUCCESS(wlan_cfg_get_str(mac, - WNI_CFG_SCAN_CONTROL_LIST, - pControlList, &len))) { - for (i = 0; i < pChannelList->numChannels; i++) { - for (j = 0; j < len; j += 2) { - if (pControlList[j] == - pChannelList->channelList[i]) { - found = true; - break; - } - } - - if (found) { - /* insert a pair(channel#, flag) */ - pControlList[j + 1] = - csr_get_scan_type(mac, - pControlList[j]); - found = false; /* reset the flag */ - } - - } - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - "%s: dump scan control list", __func__); - QDF_TRACE_HEX_DUMP(QDF_MODULE_ID_SME, - QDF_TRACE_LEVEL_DEBUG, pControlList, - len); - - cfg_set_str(mac, WNI_CFG_SCAN_CONTROL_LIST, - pControlList, len); - } /* Successfully getting scan control list */ - qdf_mem_free(pControlList); - } /* AllocateMemory */ -} - QDF_STATUS csr_scan_abort_mac_scan(struct mac_context *mac_ctx, uint32_t vdev_id, uint32_t scan_id) diff --git a/core/sme/src/csr/csr_inside_api.h b/core/sme/src/csr/csr_inside_api.h index 273b79a9084a..a7d0178697e6 100644 --- a/core/sme/src/csr/csr_inside_api.h +++ b/core/sme/src/csr/csr_inside_api.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -253,8 +253,6 @@ bool csr_learn_11dcountry_information(struct mac_context *mac, tSirBssDescription *pSirBssDesc, tDot11fBeaconIEs *pIes, bool fForce); void csr_apply_country_information(struct mac_context *mac); -void csr_set_cfg_scan_control_list(struct mac_context *mac, uint8_t *countryCode, - struct csr_channel *pChannelList); void csr_free_scan_result_entry(struct mac_context *mac, struct tag_csrscan_result *pResult);