qcacld-3.0: Change WNI_VALID_CHANNEL_LIST_LEN to VALID_CHANNEL_LIST_LEN
All WNI configurations will be cleanup based on new cfg framework, so change Change WNI_VALID_CHANNEL_LIST_LEN to VALID_CHANNEL_LIST_LEN. Change-Id: I805be88ecdcca90cf3a19d1784bf8f8c261b6ca4 CRs-Fixed: 2379748
This commit is contained in:
@@ -47,7 +47,6 @@
|
|||||||
#define CFG_MAX_TX_POWER_5_LEN 128
|
#define CFG_MAX_TX_POWER_5_LEN 128
|
||||||
#define CFG_POWER_USAGE_MAX_LEN 4
|
#define CFG_POWER_USAGE_MAX_LEN 4
|
||||||
|
|
||||||
#define CFG_VALID_CHANNEL_LIST_LEN 100
|
|
||||||
#define CFG_VALID_CHANNEL_LIST_STRING_LEN (CFG_VALID_CHANNEL_LIST_LEN * 4)
|
#define CFG_VALID_CHANNEL_LIST_STRING_LEN (CFG_VALID_CHANNEL_LIST_LEN * 4)
|
||||||
/**
|
/**
|
||||||
* struct mlme_cfg_str - generic structure for all mlme CFG string items
|
* struct mlme_cfg_str - generic structure for all mlme CFG string items
|
||||||
|
@@ -33,7 +33,7 @@ typedef uint8_t qcmacaddr[QCSAP_ADDR_LEN];
|
|||||||
|
|
||||||
struct channel_list_info {
|
struct channel_list_info {
|
||||||
uint8_t num_channels;
|
uint8_t num_channels;
|
||||||
uint8_t channels[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
uint8_t channels[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef __linux__
|
#ifdef __linux__
|
||||||
|
@@ -13457,7 +13457,7 @@ QDF_STATUS wlan_hdd_validate_operation_channel(struct hdd_adapter *adapter,
|
|||||||
int channel)
|
int channel)
|
||||||
{
|
{
|
||||||
uint32_t num_ch = 0;
|
uint32_t num_ch = 0;
|
||||||
u8 valid_ch[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
u8 valid_ch[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
u32 indx = 0;
|
u32 indx = 0;
|
||||||
mac_handle_t mac_handle = hdd_adapter_get_mac_handle(adapter);
|
mac_handle_t mac_handle = hdd_adapter_get_mac_handle(adapter);
|
||||||
uint8_t fValidChannel = false, count = 0;
|
uint8_t fValidChannel = false, count = 0;
|
||||||
@@ -13465,7 +13465,7 @@ QDF_STATUS wlan_hdd_validate_operation_channel(struct hdd_adapter *adapter,
|
|||||||
bool value;
|
bool value;
|
||||||
struct hdd_context *hdd_ctx;
|
struct hdd_context *hdd_ctx;
|
||||||
|
|
||||||
num_ch = WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
num_ch = CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
hdd_ctx = WLAN_HDD_GET_CTX(adapter);
|
hdd_ctx = WLAN_HDD_GET_CTX(adapter);
|
||||||
status = ucfg_mlme_get_sap_allow_all_channels(hdd_ctx->psoc, &value);
|
status = ucfg_mlme_get_sap_allow_all_channels(hdd_ctx->psoc, &value);
|
||||||
if (status != QDF_STATUS_SUCCESS)
|
if (status != QDF_STATUS_SUCCESS)
|
||||||
@@ -18329,8 +18329,8 @@ static int __wlan_hdd_cfg80211_join_ibss(struct wiphy *wiphy,
|
|||||||
mac_handle = hdd_ctx->mac_handle;
|
mac_handle = hdd_ctx->mac_handle;
|
||||||
if (NULL !=
|
if (NULL !=
|
||||||
params->chandef.chan) {
|
params->chandef.chan) {
|
||||||
uint32_t numChans = WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
uint32_t numChans = CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
uint8_t validChan[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
uint8_t validChan[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
int indx;
|
int indx;
|
||||||
|
|
||||||
/* Get channel number */
|
/* Get channel number */
|
||||||
|
@@ -2365,7 +2365,7 @@ __wlan_hdd_cfg80211_extscan_get_valid_channels(struct wiphy *wiphy,
|
|||||||
struct hdd_context *hdd_ctx = wiphy_priv(wiphy);
|
struct hdd_context *hdd_ctx = wiphy_priv(wiphy);
|
||||||
struct net_device *dev = wdev->netdev;
|
struct net_device *dev = wdev->netdev;
|
||||||
struct hdd_adapter *adapter = WLAN_HDD_GET_PRIV_PTR(dev);
|
struct hdd_adapter *adapter = WLAN_HDD_GET_PRIV_PTR(dev);
|
||||||
uint32_t chan_list[WNI_CFG_VALID_CHANNEL_LIST_LEN] = {0};
|
uint32_t chan_list[CFG_VALID_CHANNEL_LIST_LEN] = {0};
|
||||||
uint8_t num_channels = 0, i, buf[256] = {0};
|
uint8_t num_channels = 0, i, buf[256] = {0};
|
||||||
struct nlattr *tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX +
|
struct nlattr *tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX +
|
||||||
1];
|
1];
|
||||||
@@ -2425,9 +2425,9 @@ __wlan_hdd_cfg80211_extscan_get_valid_channels(struct wiphy *wiphy,
|
|||||||
nla_get_u32(tb
|
nla_get_u32(tb
|
||||||
[QCA_WLAN_VENDOR_ATTR_EXTSCAN_GET_VALID_CHANNELS_CONFIG_PARAM_MAX_CHANNELS]);
|
[QCA_WLAN_VENDOR_ATTR_EXTSCAN_GET_VALID_CHANNELS_CONFIG_PARAM_MAX_CHANNELS]);
|
||||||
|
|
||||||
if (maxChannels > WNI_CFG_VALID_CHANNEL_LIST_LEN) {
|
if (maxChannels > CFG_VALID_CHANNEL_LIST_LEN) {
|
||||||
hdd_err("Max channels %d exceeded Valid channel list len %d",
|
hdd_err("Max channels %d exceeded Valid channel list len %d",
|
||||||
maxChannels, WNI_CFG_VALID_CHANNEL_LIST_LEN);
|
maxChannels, CFG_VALID_CHANNEL_LIST_LEN);
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2615,7 +2615,7 @@ static int hdd_extscan_start_fill_bucket_channel_spec(
|
|||||||
uint8_t bkt_index, j, num_channels, total_channels = 0;
|
uint8_t bkt_index, j, num_channels, total_channels = 0;
|
||||||
uint32_t expected_buckets;
|
uint32_t expected_buckets;
|
||||||
uint32_t expected_channels;
|
uint32_t expected_channels;
|
||||||
uint32_t chan_list[WNI_CFG_VALID_CHANNEL_LIST_LEN] = {0};
|
uint32_t chan_list[CFG_VALID_CHANNEL_LIST_LEN] = {0};
|
||||||
uint32_t extscan_active_min_chn_time;
|
uint32_t extscan_active_min_chn_time;
|
||||||
uint32_t min_dwell_time_active_bucket;
|
uint32_t min_dwell_time_active_bucket;
|
||||||
uint32_t max_dwell_time_active_bucket;
|
uint32_t max_dwell_time_active_bucket;
|
||||||
|
@@ -3474,7 +3474,7 @@ int wlan_hdd_set_channel(struct wiphy *wiphy,
|
|||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
num_ch = WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
num_ch = CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
|
|
||||||
if ((QDF_SAP_MODE != adapter->device_mode) &&
|
if ((QDF_SAP_MODE != adapter->device_mode) &&
|
||||||
(QDF_P2P_GO_MODE != adapter->device_mode)) {
|
(QDF_P2P_GO_MODE != adapter->device_mode)) {
|
||||||
|
@@ -1234,7 +1234,7 @@ hdd_parse_channellist(const uint8_t *pValue, uint8_t *pChannelList,
|
|||||||
|
|
||||||
v = kstrtos32(buf, 10, &tempInt);
|
v = kstrtos32(buf, 10, &tempInt);
|
||||||
if ((v < 0) ||
|
if ((v < 0) ||
|
||||||
(tempInt <= 0) || (tempInt > WNI_CFG_VALID_CHANNEL_LIST_LEN))
|
(tempInt <= 0) || (tempInt > CFG_VALID_CHANNEL_LIST_LEN))
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
||||||
*pNumChannels = tempInt;
|
*pNumChannels = tempInt;
|
||||||
@@ -1314,7 +1314,7 @@ static int
|
|||||||
hdd_parse_set_roam_scan_channels_v1(struct hdd_adapter *adapter,
|
hdd_parse_set_roam_scan_channels_v1(struct hdd_adapter *adapter,
|
||||||
const char *command)
|
const char *command)
|
||||||
{
|
{
|
||||||
uint8_t channel_list[WNI_CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
uint8_t channel_list[CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
||||||
uint8_t num_chan = 0;
|
uint8_t num_chan = 0;
|
||||||
QDF_STATUS status;
|
QDF_STATUS status;
|
||||||
struct hdd_context *hdd_ctx = WLAN_HDD_GET_CTX(adapter);
|
struct hdd_context *hdd_ctx = WLAN_HDD_GET_CTX(adapter);
|
||||||
@@ -1331,9 +1331,9 @@ hdd_parse_set_roam_scan_channels_v1(struct hdd_adapter *adapter,
|
|||||||
TRACE_CODE_HDD_SETROAMSCANCHANNELS_IOCTL,
|
TRACE_CODE_HDD_SETROAMSCANCHANNELS_IOCTL,
|
||||||
adapter->session_id, num_chan));
|
adapter->session_id, num_chan));
|
||||||
|
|
||||||
if (num_chan > WNI_CFG_VALID_CHANNEL_LIST_LEN) {
|
if (num_chan > CFG_VALID_CHANNEL_LIST_LEN) {
|
||||||
hdd_err("number of channels (%d) supported exceeded max (%d)",
|
hdd_err("number of channels (%d) supported exceeded max (%d)",
|
||||||
num_chan, WNI_CFG_VALID_CHANNEL_LIST_LEN);
|
num_chan, CFG_VALID_CHANNEL_LIST_LEN);
|
||||||
ret = -EINVAL;
|
ret = -EINVAL;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@@ -1380,7 +1380,7 @@ hdd_parse_set_roam_scan_channels_v2(struct hdd_adapter *adapter,
|
|||||||
const char *command)
|
const char *command)
|
||||||
{
|
{
|
||||||
const uint8_t *value;
|
const uint8_t *value;
|
||||||
uint8_t channel_list[WNI_CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
uint8_t channel_list[CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
||||||
uint8_t channel;
|
uint8_t channel;
|
||||||
uint8_t num_chan;
|
uint8_t num_chan;
|
||||||
int i;
|
int i;
|
||||||
@@ -1393,9 +1393,9 @@ hdd_parse_set_roam_scan_channels_v2(struct hdd_adapter *adapter,
|
|||||||
value = command + 20;
|
value = command + 20;
|
||||||
|
|
||||||
num_chan = *value++;
|
num_chan = *value++;
|
||||||
if (num_chan > WNI_CFG_VALID_CHANNEL_LIST_LEN) {
|
if (num_chan > CFG_VALID_CHANNEL_LIST_LEN) {
|
||||||
hdd_err("number of channels (%d) supported exceeded max (%d)",
|
hdd_err("number of channels (%d) supported exceeded max (%d)",
|
||||||
num_chan, WNI_CFG_VALID_CHANNEL_LIST_LEN);
|
num_chan, CFG_VALID_CHANNEL_LIST_LEN);
|
||||||
ret = -EINVAL;
|
ret = -EINVAL;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@@ -1735,7 +1735,7 @@ static QDF_STATUS hdd_parse_plm_cmd(uint8_t *pValue, tSirPlmReq *pPlmRequest)
|
|||||||
if (content < 0)
|
if (content < 0)
|
||||||
return QDF_STATUS_E_FAILURE;
|
return QDF_STATUS_E_FAILURE;
|
||||||
|
|
||||||
content = QDF_MIN(content, WNI_CFG_VALID_CHANNEL_LIST_LEN);
|
content = QDF_MIN(content, CFG_VALID_CHANNEL_LIST_LEN);
|
||||||
pPlmRequest->plmNumCh = content;
|
pPlmRequest->plmNumCh = content;
|
||||||
hdd_debug("numch: %d", pPlmRequest->plmNumCh);
|
hdd_debug("numch: %d", pPlmRequest->plmNumCh);
|
||||||
|
|
||||||
@@ -3374,7 +3374,7 @@ static int drv_cmd_get_roam_scan_channels(struct hdd_adapter *adapter,
|
|||||||
struct hdd_priv_data *priv_data)
|
struct hdd_priv_data *priv_data)
|
||||||
{
|
{
|
||||||
int ret = 0;
|
int ret = 0;
|
||||||
uint8_t ChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
uint8_t ChannelList[CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
||||||
uint8_t numChannels = 0;
|
uint8_t numChannels = 0;
|
||||||
uint8_t j = 0;
|
uint8_t j = 0;
|
||||||
char extra[128] = { 0 };
|
char extra[128] = { 0 };
|
||||||
@@ -5369,7 +5369,7 @@ static int drv_cmd_set_ccx_roam_scan_channels(struct hdd_adapter *adapter,
|
|||||||
{
|
{
|
||||||
int ret = 0;
|
int ret = 0;
|
||||||
uint8_t *value = command;
|
uint8_t *value = command;
|
||||||
uint8_t ChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
uint8_t ChannelList[CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
||||||
uint8_t numChannels = 0;
|
uint8_t numChannels = 0;
|
||||||
QDF_STATUS status;
|
QDF_STATUS status;
|
||||||
mac_handle_t mac_handle;
|
mac_handle_t mac_handle;
|
||||||
@@ -5379,10 +5379,10 @@ static int drv_cmd_set_ccx_roam_scan_channels(struct hdd_adapter *adapter,
|
|||||||
hdd_err("Failed to parse channel list information");
|
hdd_err("Failed to parse channel list information");
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
if (numChannels > WNI_CFG_VALID_CHANNEL_LIST_LEN) {
|
if (numChannels > CFG_VALID_CHANNEL_LIST_LEN) {
|
||||||
hdd_err("number of channels (%d) supported exceeded max (%d)",
|
hdd_err("number of channels (%d) supported exceeded max (%d)",
|
||||||
numChannels,
|
numChannels,
|
||||||
WNI_CFG_VALID_CHANNEL_LIST_LEN);
|
CFG_VALID_CHANNEL_LIST_LEN);
|
||||||
ret = -EINVAL;
|
ret = -EINVAL;
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
@@ -872,7 +872,7 @@ static int oem_chan_info_req_handler(struct hdd_context *hdd_ctx,
|
|||||||
|
|
||||||
/* message length contains list of channel ids */
|
/* message length contains list of channel ids */
|
||||||
if ((!msg_hdr->length) ||
|
if ((!msg_hdr->length) ||
|
||||||
(WNI_CFG_VALID_CHANNEL_LIST_LEN < msg_hdr->length)) {
|
(CFG_VALID_CHANNEL_LIST_LEN < msg_hdr->length)) {
|
||||||
hdd_err("Invalid length (%d) in channel info request",
|
hdd_err("Invalid length (%d) in channel info request",
|
||||||
msg_hdr->length);
|
msg_hdr->length);
|
||||||
send_oem_err_rsp_nlink_msg(pid, OEM_ERR_INVALID_MESSAGE_LENGTH);
|
send_oem_err_rsp_nlink_msg(pid, OEM_ERR_INVALID_MESSAGE_LENGTH);
|
||||||
|
@@ -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
|
* Permission to use, copy, modify, and/or distribute this software for
|
||||||
* any purpose with or without fee is hereby granted, provided that the
|
* any purpose with or without fee is hereby granted, provided that the
|
||||||
@@ -98,7 +98,7 @@ static int wlan_hdd_validate_and_get_pre_cac_ch(struct hdd_context *hdd_ctx,
|
|||||||
uint32_t i;
|
uint32_t i;
|
||||||
QDF_STATUS status;
|
QDF_STATUS status;
|
||||||
uint32_t weight_len = 0;
|
uint32_t weight_len = 0;
|
||||||
uint32_t len = WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
uint32_t len = CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
uint8_t channel_list[QDF_MAX_NUM_CHAN] = {0};
|
uint8_t channel_list[QDF_MAX_NUM_CHAN] = {0};
|
||||||
uint8_t pcl_weights[QDF_MAX_NUM_CHAN] = {0};
|
uint8_t pcl_weights[QDF_MAX_NUM_CHAN] = {0};
|
||||||
mac_handle_t mac_handle;
|
mac_handle_t mac_handle;
|
||||||
|
@@ -6672,13 +6672,13 @@ static int __iw_get_char_setnone(struct net_device *dev,
|
|||||||
}
|
}
|
||||||
buf = extra;
|
buf = extra;
|
||||||
/*
|
/*
|
||||||
* Maximum channels = WNI_CFG_VALID_CHANNEL_LIST_LEN.
|
* Maximum channels = CFG_VALID_CHANNEL_LIST_LEN.
|
||||||
* Maximum buffer needed = 5 * number of channels.
|
* Maximum buffer needed = 5 * number of channels.
|
||||||
* Check ifsufficient buffer is available and then
|
* Check ifsufficient buffer is available and then
|
||||||
* proceed to fill the buffer.
|
* proceed to fill the buffer.
|
||||||
*/
|
*/
|
||||||
if (WE_MAX_STR_LEN <
|
if (WE_MAX_STR_LEN <
|
||||||
(5 * WNI_CFG_VALID_CHANNEL_LIST_LEN)) {
|
(5 * CFG_VALID_CHANNEL_LIST_LEN)) {
|
||||||
hdd_err("Insufficient Buffer to populate channel list");
|
hdd_err("Insufficient Buffer to populate channel list");
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
@@ -56,6 +56,7 @@ struct mac_context;
|
|||||||
|
|
||||||
/* / Max supported channel list */
|
/* / Max supported channel list */
|
||||||
#define SIR_MAX_SUPPORTED_CHANNEL_LIST 96
|
#define SIR_MAX_SUPPORTED_CHANNEL_LIST 96
|
||||||
|
#define CFG_VALID_CHANNEL_LIST_LEN 100
|
||||||
|
|
||||||
#define SIR_MDIE_ELEMENT_ID 54
|
#define SIR_MDIE_ELEMENT_ID 54
|
||||||
#define SIR_MDIE_SIZE 3 /* MD ID(2 bytes), Capability(1 byte) */
|
#define SIR_MDIE_SIZE 3 /* MD ID(2 bytes), Capability(1 byte) */
|
||||||
@@ -880,7 +881,7 @@ typedef struct sSirPlmReq {
|
|||||||
/* no of channels */
|
/* no of channels */
|
||||||
uint8_t plmNumCh;
|
uint8_t plmNumCh;
|
||||||
/* channel numbers */
|
/* channel numbers */
|
||||||
uint8_t plmChList[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
uint8_t plmChList[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
uint8_t sessionId;
|
uint8_t sessionId;
|
||||||
bool enable;
|
bool enable;
|
||||||
} tSirPlmReq, *tpSirPlmReq;
|
} tSirPlmReq, *tpSirPlmReq;
|
||||||
|
@@ -212,8 +212,8 @@ static void populate_dot11f_tdls_offchannel_params(
|
|||||||
tDot11fIESuppChannels *suppChannels,
|
tDot11fIESuppChannels *suppChannels,
|
||||||
tDot11fIESuppOperatingClasses *suppOperClasses)
|
tDot11fIESuppOperatingClasses *suppOperClasses)
|
||||||
{
|
{
|
||||||
uint32_t numChans = WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
uint32_t numChans = CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
uint8_t validChan[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
uint8_t validChan[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
uint8_t i;
|
uint8_t i;
|
||||||
uint8_t valid_count = 0;
|
uint8_t valid_count = 0;
|
||||||
uint8_t chanOffset;
|
uint8_t chanOffset;
|
||||||
|
@@ -597,7 +597,7 @@ QDF_STATUS lim_send_ht40_obss_scanind(struct mac_context *mac_ctx,
|
|||||||
struct obss_ht40_scanind *ht40_obss_scanind;
|
struct obss_ht40_scanind *ht40_obss_scanind;
|
||||||
uint32_t channelnum;
|
uint32_t channelnum;
|
||||||
struct scheduler_msg msg = {0};
|
struct scheduler_msg msg = {0};
|
||||||
uint8_t chan_list[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
uint8_t chan_list[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
uint8_t channel24gnum, count;
|
uint8_t channel24gnum, count;
|
||||||
|
|
||||||
ht40_obss_scanind = qdf_mem_malloc(sizeof(struct obss_ht40_scanind));
|
ht40_obss_scanind = qdf_mem_malloc(sizeof(struct obss_ht40_scanind));
|
||||||
@@ -628,7 +628,7 @@ QDF_STATUS lim_send_ht40_obss_scanind(struct mac_context *mac_ctx,
|
|||||||
mac_ctx->scan.countryCodeCurrent,
|
mac_ctx->scan.countryCodeCurrent,
|
||||||
session->currentOperChannel,
|
session->currentOperChannel,
|
||||||
session->ch_width);
|
session->ch_width);
|
||||||
channelnum = WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
channelnum = CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
if (wlan_cfg_get_str(mac_ctx, WNI_CFG_VALID_CHANNEL_LIST,
|
if (wlan_cfg_get_str(mac_ctx, WNI_CFG_VALID_CHANNEL_LIST,
|
||||||
chan_list, &channelnum) != QDF_STATUS_SUCCESS) {
|
chan_list, &channelnum) != QDF_STATUS_SUCCESS) {
|
||||||
pe_err("could not retrieve Valid channel list");
|
pe_err("could not retrieve Valid channel list");
|
||||||
|
@@ -4591,8 +4591,8 @@ void lim_add_channel_status_info(struct mac_context *p_mac,
|
|||||||
bool lim_is_channel_valid_for_channel_switch(struct mac_context *mac, uint8_t channel)
|
bool lim_is_channel_valid_for_channel_switch(struct mac_context *mac, uint8_t channel)
|
||||||
{
|
{
|
||||||
uint8_t index;
|
uint8_t index;
|
||||||
uint32_t validChannelListLen = WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
uint32_t validChannelListLen = CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
tSirMacChanNum validChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
tSirMacChanNum validChannelList[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
bool ok = false;
|
bool ok = false;
|
||||||
|
|
||||||
if (policy_mgr_is_chan_ok_for_dnbs(mac->psoc, channel, &ok)) {
|
if (policy_mgr_is_chan_ok_for_dnbs(mac->psoc, channel, &ok)) {
|
||||||
|
@@ -118,7 +118,7 @@ typedef struct sSapAcsChannelInfo {
|
|||||||
*/
|
*/
|
||||||
struct sap_avoid_channels_info {
|
struct sap_avoid_channels_info {
|
||||||
bool present;
|
bool present;
|
||||||
uint8_t channels[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
uint8_t channels[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
};
|
};
|
||||||
#endif /* FEATURE_AP_MCC_CH_AVOIDANCE */
|
#endif /* FEATURE_AP_MCC_CH_AVOIDANCE */
|
||||||
|
|
||||||
|
@@ -281,7 +281,7 @@ typedef struct tagCsrEseCckmIe {
|
|||||||
|
|
||||||
typedef struct sCsrChannel_ {
|
typedef struct sCsrChannel_ {
|
||||||
uint8_t numChannels;
|
uint8_t numChannels;
|
||||||
uint8_t channelList[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
uint8_t channelList[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
} sCsrChannel;
|
} sCsrChannel;
|
||||||
|
|
||||||
typedef struct tagCsrScanResultFilter {
|
typedef struct tagCsrScanResultFilter {
|
||||||
@@ -344,7 +344,7 @@ typedef struct tagCsr11dinfo {
|
|||||||
sCsrChannel Channels;
|
sCsrChannel Channels;
|
||||||
uint8_t countryCode[WNI_CFG_COUNTRY_CODE_LEN + 1];
|
uint8_t countryCode[WNI_CFG_COUNTRY_CODE_LEN + 1];
|
||||||
/* max power channel list */
|
/* max power channel list */
|
||||||
sCsrChnPower ChnPower[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
sCsrChnPower ChnPower[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
} tCsr11dinfo;
|
} tCsr11dinfo;
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
|
@@ -215,7 +215,7 @@ enum csr_diagwlan_status_eventreason {
|
|||||||
|
|
||||||
struct csr_channel {
|
struct csr_channel {
|
||||||
uint8_t numChannels;
|
uint8_t numChannels;
|
||||||
uint8_t channelList[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
uint8_t channelList[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
};
|
};
|
||||||
|
|
||||||
struct scan_profile {
|
struct scan_profile {
|
||||||
@@ -459,7 +459,7 @@ struct csr_scanstruct {
|
|||||||
struct scan_profile scanProfile;
|
struct scan_profile scanProfile;
|
||||||
tSirScanType curScanType;
|
tSirScanType curScanType;
|
||||||
struct csr_channel channels11d;
|
struct csr_channel channels11d;
|
||||||
struct channel_power defaultPowerTable[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
struct channel_power defaultPowerTable[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
uint32_t numChannelsDefault;
|
uint32_t numChannelsDefault;
|
||||||
struct csr_channel base_channels; /* The channel base to work on */
|
struct csr_channel base_channels; /* The channel base to work on */
|
||||||
tDblLinkList channelPowerInfoList24;
|
tDblLinkList channelPowerInfoList24;
|
||||||
@@ -625,7 +625,7 @@ struct csr_roam_session {
|
|||||||
* This may or may not have the up-to-date valid channel list. It is
|
* This may or may not have the up-to-date valid channel list. It is
|
||||||
* used to get WNI_CFG_VALID_CHANNEL_LIST and not alloc memory all time
|
* used to get WNI_CFG_VALID_CHANNEL_LIST and not alloc memory all time
|
||||||
*/
|
*/
|
||||||
tSirMacChanNum validChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
tSirMacChanNum validChannelList[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
int32_t sPendingCommands; /* 0 means CSR is ok to low power */
|
int32_t sPendingCommands; /* 0 means CSR is ok to low power */
|
||||||
#ifdef FEATURE_WLAN_WAPI
|
#ifdef FEATURE_WLAN_WAPI
|
||||||
uint16_t NumBkidCache;
|
uint16_t NumBkidCache;
|
||||||
@@ -733,7 +733,7 @@ struct csr_roamstruct {
|
|||||||
* This may or may not have the up-to-date valid channel list. It is
|
* This may or may not have the up-to-date valid channel list. It is
|
||||||
* used to get WNI_CFG_VALID_CHANNEL_LIST and not alloc mem all time
|
* used to get WNI_CFG_VALID_CHANNEL_LIST and not alloc mem all time
|
||||||
*/
|
*/
|
||||||
tSirMacChanNum validChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
tSirMacChanNum validChannelList[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
uint32_t numValidChannels; /* total number of channels in CFG */
|
uint32_t numValidChannels; /* total number of channels in CFG */
|
||||||
int32_t sPendingCommands;
|
int32_t sPendingCommands;
|
||||||
qdf_mc_timer_t hTimerWaitForKey; /* support timeout for WaitForKey */
|
qdf_mc_timer_t hTimerWaitForKey; /* support timeout for WaitForKey */
|
||||||
|
@@ -1466,7 +1466,7 @@ QDF_STATUS sme_set_plm_request(mac_handle_t mac_handle, tpSirPlmReq pPlmReq)
|
|||||||
QDF_STATUS status;
|
QDF_STATUS status;
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
struct mac_context *mac = MAC_CONTEXT(mac_handle);
|
struct mac_context *mac = MAC_CONTEXT(mac_handle);
|
||||||
uint8_t ch_list[WNI_CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
uint8_t ch_list[CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
||||||
uint8_t count, valid_count = 0;
|
uint8_t count, valid_count = 0;
|
||||||
struct scheduler_msg msg = {0};
|
struct scheduler_msg msg = {0};
|
||||||
struct csr_roam_session *pSession = CSR_GET_SESSION(mac,
|
struct csr_roam_session *pSession = CSR_GET_SESSION(mac,
|
||||||
@@ -1722,7 +1722,7 @@ QDF_STATUS sme_set_ese_roam_scan_channel_list(mac_handle_t mac_handle,
|
|||||||
QDF_STATUS status = QDF_STATUS_SUCCESS;
|
QDF_STATUS status = QDF_STATUS_SUCCESS;
|
||||||
tpCsrNeighborRoamControlInfo pNeighborRoamInfo = NULL;
|
tpCsrNeighborRoamControlInfo pNeighborRoamInfo = NULL;
|
||||||
tpCsrChannelInfo curchnl_list_info = NULL;
|
tpCsrChannelInfo curchnl_list_info = NULL;
|
||||||
uint8_t oldChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN * 2] = { 0 };
|
uint8_t oldChannelList[CFG_VALID_CHANNEL_LIST_LEN * 2] = { 0 };
|
||||||
uint8_t newChannelList[128] = { 0 };
|
uint8_t newChannelList[128] = { 0 };
|
||||||
uint8_t i = 0, j = 0;
|
uint8_t i = 0, j = 0;
|
||||||
|
|
||||||
@@ -7134,8 +7134,8 @@ QDF_STATUS sme_change_roam_scan_channel_list(mac_handle_t mac_handle,
|
|||||||
struct mac_context *mac = MAC_CONTEXT(mac_handle);
|
struct mac_context *mac = MAC_CONTEXT(mac_handle);
|
||||||
QDF_STATUS status = QDF_STATUS_SUCCESS;
|
QDF_STATUS status = QDF_STATUS_SUCCESS;
|
||||||
tpCsrNeighborRoamControlInfo pNeighborRoamInfo = NULL;
|
tpCsrNeighborRoamControlInfo pNeighborRoamInfo = NULL;
|
||||||
uint8_t oldChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN * 2] = { 0 };
|
uint8_t oldChannelList[CFG_VALID_CHANNEL_LIST_LEN * 2] = { 0 };
|
||||||
uint8_t newChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN * 2] = { 0 };
|
uint8_t newChannelList[CFG_VALID_CHANNEL_LIST_LEN * 2] = { 0 };
|
||||||
uint8_t i = 0, j = 0;
|
uint8_t i = 0, j = 0;
|
||||||
tCsrChannelInfo *chan_info;
|
tCsrChannelInfo *chan_info;
|
||||||
|
|
||||||
@@ -8573,7 +8573,7 @@ QDF_STATUS sme_get_reg_info(mac_handle_t mac_handle, uint8_t chanId,
|
|||||||
if (!QDF_IS_STATUS_SUCCESS(status))
|
if (!QDF_IS_STATUS_SUCCESS(status))
|
||||||
return status;
|
return status;
|
||||||
|
|
||||||
for (i = 0; i < WNI_CFG_VALID_CHANNEL_LIST_LEN; i++) {
|
for (i = 0; i < CFG_VALID_CHANNEL_LIST_LEN; i++) {
|
||||||
if (mac->scan.defaultPowerTable[i].chan_num == chanId) {
|
if (mac->scan.defaultPowerTable[i].chan_num == chanId) {
|
||||||
SME_SET_CHANNEL_REG_POWER(*regInfo1,
|
SME_SET_CHANNEL_REG_POWER(*regInfo1,
|
||||||
mac->scan.defaultPowerTable[i].tx_power);
|
mac->scan.defaultPowerTable[i].tx_power);
|
||||||
@@ -9533,10 +9533,10 @@ QDF_STATUS sme_get_valid_channels_by_band(mac_handle_t mac_handle,
|
|||||||
uint8_t *pNumChannels)
|
uint8_t *pNumChannels)
|
||||||
{
|
{
|
||||||
QDF_STATUS status = QDF_STATUS_SUCCESS;
|
QDF_STATUS status = QDF_STATUS_SUCCESS;
|
||||||
uint8_t chanList[WNI_CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
uint8_t chanList[CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
||||||
uint8_t numChannels = 0;
|
uint8_t numChannels = 0;
|
||||||
uint8_t i = 0;
|
uint8_t i = 0;
|
||||||
uint32_t totValidChannels = WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
uint32_t totValidChannels = CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
struct mac_context *mac_ctx = MAC_CONTEXT(mac_handle);
|
struct mac_context *mac_ctx = MAC_CONTEXT(mac_handle);
|
||||||
|
|
||||||
if (!aValidChannels || !pNumChannels) {
|
if (!aValidChannels || !pNumChannels) {
|
||||||
|
@@ -725,7 +725,7 @@ static int8_t csr_find_channel_pwr(struct channel_power *
|
|||||||
uint8_t i;
|
uint8_t i;
|
||||||
/* TODO: if defaultPowerTable is guaranteed to be in ascending */
|
/* TODO: if defaultPowerTable is guaranteed to be in ascending */
|
||||||
/* order of channel numbers, we can employ binary search */
|
/* order of channel numbers, we can employ binary search */
|
||||||
for (i = 0; i < WNI_CFG_VALID_CHANNEL_LIST_LEN; i++) {
|
for (i = 0; i < CFG_VALID_CHANNEL_LIST_LEN; i++) {
|
||||||
if (pdefaultPowerTable[i].chan_num == ChannelNum)
|
if (pdefaultPowerTable[i].chan_num == ChannelNum)
|
||||||
return pdefaultPowerTable[i].tx_power;
|
return pdefaultPowerTable[i].tx_power;
|
||||||
}
|
}
|
||||||
@@ -1768,8 +1768,8 @@ QDF_STATUS csr_create_roam_scan_channel_list(struct mac_context *mac,
|
|||||||
uint8_t inNumChannels = numChannels;
|
uint8_t inNumChannels = numChannels;
|
||||||
uint8_t *inPtr = pChannelList;
|
uint8_t *inPtr = pChannelList;
|
||||||
uint8_t i = 0;
|
uint8_t i = 0;
|
||||||
uint8_t ChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
uint8_t ChannelList[CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
||||||
uint8_t tmpChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
uint8_t tmpChannelList[CFG_VALID_CHANNEL_LIST_LEN] = { 0 };
|
||||||
uint8_t mergedOutputNumOfChannels = 0;
|
uint8_t mergedOutputNumOfChannels = 0;
|
||||||
|
|
||||||
tpCsrChannelInfo currChannelListInfo
|
tpCsrChannelInfo currChannelListInfo
|
||||||
@@ -2859,8 +2859,8 @@ QDF_STATUS csr_get_channel_and_power_list(struct mac_context *mac)
|
|||||||
sme_err("failed to get channels");
|
sme_err("failed to get channels");
|
||||||
status = QDF_STATUS_E_FAILURE;
|
status = QDF_STATUS_E_FAILURE;
|
||||||
} else {
|
} else {
|
||||||
if (num20MHzChannelsFound > WNI_CFG_VALID_CHANNEL_LIST_LEN)
|
if (num20MHzChannelsFound > CFG_VALID_CHANNEL_LIST_LEN)
|
||||||
num20MHzChannelsFound = WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
num20MHzChannelsFound = CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
mac->scan.numChannelsDefault = num20MHzChannelsFound;
|
mac->scan.numChannelsDefault = num20MHzChannelsFound;
|
||||||
/* Move the channel list to the global data */
|
/* Move the channel list to the global data */
|
||||||
/* structure -- this will be used as the scan list */
|
/* structure -- this will be used as the scan list */
|
||||||
@@ -2901,7 +2901,7 @@ static QDF_STATUS csr_init11d_info(struct mac_context *mac, tCsr11dinfo *ps11din
|
|||||||
return status;
|
return status;
|
||||||
|
|
||||||
if (ps11dinfo->Channels.numChannels
|
if (ps11dinfo->Channels.numChannels
|
||||||
&& (WNI_CFG_VALID_CHANNEL_LIST_LEN >=
|
&& (CFG_VALID_CHANNEL_LIST_LEN >=
|
||||||
ps11dinfo->Channels.numChannels)) {
|
ps11dinfo->Channels.numChannels)) {
|
||||||
mac->scan.base_channels.numChannels =
|
mac->scan.base_channels.numChannels =
|
||||||
ps11dinfo->Channels.numChannels;
|
ps11dinfo->Channels.numChannels;
|
||||||
@@ -2928,7 +2928,7 @@ static QDF_STATUS csr_init11d_info(struct mac_context *mac, tCsr11dinfo *ps11din
|
|||||||
/* need to add the max power channel list */
|
/* need to add the max power channel list */
|
||||||
pChanInfo =
|
pChanInfo =
|
||||||
qdf_mem_malloc(sizeof(tSirMacChanInfo) *
|
qdf_mem_malloc(sizeof(tSirMacChanInfo) *
|
||||||
WNI_CFG_VALID_CHANNEL_LIST_LEN);
|
CFG_VALID_CHANNEL_LIST_LEN);
|
||||||
if (pChanInfo != NULL) {
|
if (pChanInfo != NULL) {
|
||||||
pChanInfoStart = pChanInfo;
|
pChanInfoStart = pChanInfo;
|
||||||
for (index = 0; index < ps11dinfo->Channels.numChannels;
|
for (index = 0; index < ps11dinfo->Channels.numChannels;
|
||||||
@@ -2990,7 +2990,7 @@ QDF_STATUS csr_init_channel_power_list(struct mac_context *mac,
|
|||||||
|
|
||||||
pChanInfo =
|
pChanInfo =
|
||||||
qdf_mem_malloc(sizeof(tSirMacChanInfo) *
|
qdf_mem_malloc(sizeof(tSirMacChanInfo) *
|
||||||
WNI_CFG_VALID_CHANNEL_LIST_LEN);
|
CFG_VALID_CHANNEL_LIST_LEN);
|
||||||
if (pChanInfo != NULL) {
|
if (pChanInfo != NULL) {
|
||||||
pChanInfoStart = pChanInfo;
|
pChanInfoStart = pChanInfo;
|
||||||
|
|
||||||
|
@@ -639,7 +639,7 @@ void csr_apply_channel_power_info_to_fw(struct mac_context *mac_ctx,
|
|||||||
|
|
||||||
if (ch_lst->numChannels) {
|
if (ch_lst->numChannels) {
|
||||||
tempNumChannels = CSR_MIN(ch_lst->numChannels,
|
tempNumChannels = CSR_MIN(ch_lst->numChannels,
|
||||||
WNI_CFG_VALID_CHANNEL_LIST_LEN);
|
CFG_VALID_CHANNEL_LIST_LEN);
|
||||||
for (i = 0; i < tempNumChannels; i++) {
|
for (i = 0; i < tempNumChannels; i++) {
|
||||||
tmp_ch_lst.channelList[num_ch] = ch_lst->channelList[i];
|
tmp_ch_lst.channelList[num_ch] = ch_lst->channelList[i];
|
||||||
num_ch++;
|
num_ch++;
|
||||||
@@ -748,8 +748,8 @@ static void csr_get_channel_power_info(struct mac_context *mac,
|
|||||||
static void csr_diag_apply_country_info(struct mac_context *mac_ctx)
|
static void csr_diag_apply_country_info(struct mac_context *mac_ctx)
|
||||||
{
|
{
|
||||||
host_log_802_11d_pkt_type *p11dLog;
|
host_log_802_11d_pkt_type *p11dLog;
|
||||||
struct channel_power chnPwrInfo[WNI_CFG_VALID_CHANNEL_LIST_LEN];
|
struct channel_power chnPwrInfo[CFG_VALID_CHANNEL_LIST_LEN];
|
||||||
uint32_t nChnInfo = WNI_CFG_VALID_CHANNEL_LIST_LEN, nTmp;
|
uint32_t nChnInfo = CFG_VALID_CHANNEL_LIST_LEN, nTmp;
|
||||||
|
|
||||||
WLAN_HOST_DIAG_LOG_ALLOC(p11dLog, host_log_802_11d_pkt_type,
|
WLAN_HOST_DIAG_LOG_ALLOC(p11dLog, host_log_802_11d_pkt_type,
|
||||||
LOG_WLAN_80211D_C);
|
LOG_WLAN_80211D_C);
|
||||||
@@ -769,13 +769,13 @@ static void csr_diag_apply_country_info(struct mac_context *mac_ctx)
|
|||||||
&mac_ctx->scan.channelPowerInfoList24,
|
&mac_ctx->scan.channelPowerInfoList24,
|
||||||
&nChnInfo, chnPwrInfo);
|
&nChnInfo, chnPwrInfo);
|
||||||
nTmp = nChnInfo;
|
nTmp = nChnInfo;
|
||||||
nChnInfo = WNI_CFG_VALID_CHANNEL_LIST_LEN - nTmp;
|
nChnInfo = CFG_VALID_CHANNEL_LIST_LEN - nTmp;
|
||||||
csr_get_channel_power_info(mac_ctx,
|
csr_get_channel_power_info(mac_ctx,
|
||||||
&mac_ctx->scan.channelPowerInfoList5G,
|
&mac_ctx->scan.channelPowerInfoList5G,
|
||||||
&nChnInfo, &chnPwrInfo[nTmp]);
|
&nChnInfo, &chnPwrInfo[nTmp]);
|
||||||
for (nTmp = 0; nTmp < p11dLog->numChannel; nTmp++) {
|
for (nTmp = 0; nTmp < p11dLog->numChannel; nTmp++) {
|
||||||
for (nChnInfo = 0;
|
for (nChnInfo = 0;
|
||||||
nChnInfo < WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
nChnInfo < CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
nChnInfo++) {
|
nChnInfo++) {
|
||||||
if (p11dLog->Channels[nTmp] ==
|
if (p11dLog->Channels[nTmp] ==
|
||||||
chnPwrInfo[nChnInfo].chan_num) {
|
chnPwrInfo[nChnInfo].chan_num) {
|
||||||
@@ -843,12 +843,12 @@ void csr_save_channel_power_for_band(struct mac_context *mac, bool fill_5f)
|
|||||||
|
|
||||||
max_ch_idx =
|
max_ch_idx =
|
||||||
(mac->scan.base_channels.numChannels <
|
(mac->scan.base_channels.numChannels <
|
||||||
WNI_CFG_VALID_CHANNEL_LIST_LEN) ?
|
CFG_VALID_CHANNEL_LIST_LEN) ?
|
||||||
mac->scan.base_channels.numChannels :
|
mac->scan.base_channels.numChannels :
|
||||||
WNI_CFG_VALID_CHANNEL_LIST_LEN;
|
CFG_VALID_CHANNEL_LIST_LEN;
|
||||||
|
|
||||||
chan_info = qdf_mem_malloc(sizeof(tSirMacChanInfo) *
|
chan_info = qdf_mem_malloc(sizeof(tSirMacChanInfo) *
|
||||||
WNI_CFG_VALID_CHANNEL_LIST_LEN);
|
CFG_VALID_CHANNEL_LIST_LEN);
|
||||||
if (NULL == chan_info)
|
if (NULL == chan_info)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@@ -860,7 +860,7 @@ void csr_save_channel_power_for_band(struct mac_context *mac, bool fill_5f)
|
|||||||
if (!tmp_bool)
|
if (!tmp_bool)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (count >= WNI_CFG_VALID_CHANNEL_LIST_LEN) {
|
if (count >= CFG_VALID_CHANNEL_LIST_LEN) {
|
||||||
sme_warn("count: %d exceeded", count);
|
sme_warn("count: %d exceeded", count);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -1533,7 +1533,7 @@ static void csr_save_tx_power_to_cfg(struct mac_context *pMac,
|
|||||||
uint8_t *p_buf = NULL;
|
uint8_t *p_buf = NULL;
|
||||||
|
|
||||||
/* allocate maximum space for all channels */
|
/* allocate maximum space for all channels */
|
||||||
dataLen = WNI_CFG_VALID_CHANNEL_LIST_LEN * sizeof(tSirMacChanInfo);
|
dataLen = CFG_VALID_CHANNEL_LIST_LEN * sizeof(tSirMacChanInfo);
|
||||||
p_buf = qdf_mem_malloc(dataLen);
|
p_buf = qdf_mem_malloc(dataLen);
|
||||||
if (!p_buf)
|
if (!p_buf)
|
||||||
return;
|
return;
|
||||||
|
@@ -524,7 +524,7 @@ QDF_STATUS csr_neighbor_roam_channels_filter_by_current_band(struct mac_context
|
|||||||
if (!pOutputChannelList)
|
if (!pOutputChannelList)
|
||||||
return QDF_STATUS_E_INVAL;
|
return QDF_STATUS_E_INVAL;
|
||||||
|
|
||||||
if (inputNumOfChannels > WNI_CFG_VALID_CHANNEL_LIST_LEN) {
|
if (inputNumOfChannels > CFG_VALID_CHANNEL_LIST_LEN) {
|
||||||
QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR,
|
QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR,
|
||||||
"%s: Wrong Number of Input Channels %d",
|
"%s: Wrong Number of Input Channels %d",
|
||||||
__func__, inputNumOfChannels);
|
__func__, inputNumOfChannels);
|
||||||
@@ -585,13 +585,13 @@ QDF_STATUS csr_neighbor_roam_merge_channel_lists(struct mac_context *mac,
|
|||||||
if (!pOutputChannelList)
|
if (!pOutputChannelList)
|
||||||
return QDF_STATUS_E_INVAL;
|
return QDF_STATUS_E_INVAL;
|
||||||
|
|
||||||
if (inputNumOfChannels > WNI_CFG_VALID_CHANNEL_LIST_LEN) {
|
if (inputNumOfChannels > CFG_VALID_CHANNEL_LIST_LEN) {
|
||||||
QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR,
|
QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR,
|
||||||
"%s: Wrong Number of Input Channels %d",
|
"%s: Wrong Number of Input Channels %d",
|
||||||
__func__, inputNumOfChannels);
|
__func__, inputNumOfChannels);
|
||||||
return QDF_STATUS_E_INVAL;
|
return QDF_STATUS_E_INVAL;
|
||||||
}
|
}
|
||||||
if (outputNumOfChannels >= WNI_CFG_VALID_CHANNEL_LIST_LEN) {
|
if (outputNumOfChannels >= CFG_VALID_CHANNEL_LIST_LEN) {
|
||||||
QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR,
|
QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR,
|
||||||
"%s: Wrong Number of Output Channels %d",
|
"%s: Wrong Number of Output Channels %d",
|
||||||
__func__, outputNumOfChannels);
|
__func__, outputNumOfChannels);
|
||||||
@@ -616,7 +616,7 @@ QDF_STATUS csr_neighbor_roam_merge_channel_lists(struct mac_context *mac,
|
|||||||
numChannels++;
|
numChannels++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (numChannels >= WNI_CFG_VALID_CHANNEL_LIST_LEN) {
|
if (numChannels >= CFG_VALID_CHANNEL_LIST_LEN) {
|
||||||
QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG,
|
QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG,
|
||||||
"%s: Merge Neighbor channel list reached Max limit %d",
|
"%s: Merge Neighbor channel list reached Max limit %d",
|
||||||
__func__, numChannels);
|
__func__, numChannels);
|
||||||
|
@@ -6047,7 +6047,7 @@ bool csr_is_channel_present_in_list(uint8_t *pChannelList,
|
|||||||
|
|
||||||
/* Look for the channel in the list */
|
/* Look for the channel in the list */
|
||||||
for (i = 0; (i < numChannels) &&
|
for (i = 0; (i < numChannels) &&
|
||||||
(i < WNI_CFG_VALID_CHANNEL_LIST_LEN); i++) {
|
(i < CFG_VALID_CHANNEL_LIST_LEN); i++) {
|
||||||
if (pChannelList[i] == channel)
|
if (pChannelList[i] == channel)
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user