Loading components/mlme/dispatcher/inc/cfg_mlme_rates.h +3 −3 Original line number Diff line number Diff line Loading @@ -268,9 +268,9 @@ * b14-27 => NSS2, MCS 0-13 and so on for other NSS. * Note that the bit representation is continuous. * * For VHT targets, 10 bits correspond to one NSS setting. * b0-9 => NSS1, MCS 0-9 * b10-19 => NSS2, MCS 0-9 and so on for other NSS. * For VHT targets, 12 bits correspond to one NSS setting. * b0-11 => NSS1, MCS 0-11 * b12-23 => NSS2, MCS 0-11 and so on for other NSS. * * For HT targets, 8 bits correspond to one NSS setting. * b0-7 => NSS1, MCS 0-7 Loading core/hdd/src/wlan_hdd_hostapd_wext.c +37 −58 Original line number Diff line number Diff line Loading @@ -1918,16 +1918,13 @@ static int iw_get_channel_list(struct net_device *dev, { uint32_t num_channels = 0; uint8_t i = 0; uint8_t band_start_channel = MIN_24GHZ_CHANNEL; uint8_t band_end_channel = MAX_5GHZ_CHANNEL; struct hdd_adapter *hostapd_adapter = (netdev_priv(dev)); struct channel_list_info *channel_list = (struct channel_list_info *)extra; bool enable_dfs_scan = true; enum band_info cur_band = BAND_ALL; struct regulatory_channel *cur_chan_list = NULL; struct hdd_context *hdd_ctx; int ret; bool is_dfs_mode_enabled = false; QDF_STATUS status; hdd_enter_dev(dev); Loading @@ -1940,59 +1937,44 @@ static int iw_get_channel_list(struct net_device *dev, if (0 != ret) return ret; if (QDF_STATUS_SUCCESS != ucfg_reg_get_band(hdd_ctx->pdev, &cur_band)) { hdd_err_rl("not able get the current frequency band"); return -EIO; } cur_chan_list = qdf_mem_malloc(sizeof(*cur_chan_list) * NUM_CHANNELS); if (!cur_chan_list) return -ENOMEM; if (BAND_2G == cur_band) { band_start_channel = MIN_24GHZ_CHANNEL; band_end_channel = MAX_24GHZ_CHANNEL; } else if (BAND_5G == cur_band) { band_start_channel = MIN_5GHZ_CHANNEL; band_end_channel = MAX_5GHZ_CHANNEL; } if (cur_band != BAND_2G) band_end_channel = MAX_5GHZ_CHANNEL; ucfg_scan_cfg_get_dfs_chan_scan_allowed(hdd_ctx->psoc, &enable_dfs_scan); if (hostapd_adapter->device_mode == QDF_STA_MODE && enable_dfs_scan) { is_dfs_mode_enabled = true; } else if (hostapd_adapter->device_mode == QDF_SAP_MODE) { if (QDF_STATUS_SUCCESS != ucfg_mlme_get_dfs_master_capability( hdd_ctx->psoc, &is_dfs_mode_enabled)) { hdd_err_rl("Fail to get dfs master mode capability"); return -EINVAL; } status = ucfg_reg_get_current_chan_list(hdd_ctx->pdev, cur_chan_list); if (status != QDF_STATUS_SUCCESS) { hdd_err_rl("Failed to get the current channel list"); qdf_mem_free(cur_chan_list); return -EIO; } hdd_debug_rl("curBand = %d, StartChannel = %hu, EndChannel = %hu, is_dfs_mode_enabled = %d", cur_band, band_start_channel, band_end_channel, is_dfs_mode_enabled); for (i = 0; i < NUM_CHANNELS; i++) { /* * current channel list includes all channels. do not report * disabled channels */ if (cur_chan_list[i].chan_flags & REGULATORY_CHAN_DISABLED) continue; for (i = band_start_channel; i <= band_end_channel; i++) { if ((CHANNEL_STATE_ENABLE == wlan_reg_get_channel_state_for_freq( hdd_ctx->pdev, WLAN_REG_CH_TO_FREQ(i))) || (is_dfs_mode_enabled && CHANNEL_STATE_DFS == wlan_reg_get_channel_state_for_freq( hdd_ctx->pdev, WLAN_REG_CH_TO_FREQ(i)))) { /* * do not include 6 GHz channels since they are ambiguous with * 2.4 GHz and 5 GHz channels. 6 GHz-aware applications should * not be using this interface, but instead should be using the * frequency-based interface */ if (wlan_reg_is_6ghz_chan_freq(cur_chan_list[i].center_freq)) continue; channel_list->channels[num_channels] = WLAN_REG_CH_NUM(i); cur_chan_list[i].chan_num; num_channels++; } } qdf_mem_free(cur_chan_list); hdd_debug_rl("number of channels %d", num_channels); channel_list->num_channels = num_channels; wrqu->data.length = num_channels + 1; hdd_exit(); return 0; } Loading @@ -2007,9 +1989,8 @@ int iw_get_channel_list_with_cc(struct net_device *dev, uint8_t ubuf[CFG_COUNTRY_CODE_LEN] = {0}; uint8_t ubuf_len = CFG_COUNTRY_CODE_LEN; struct channel_list_info channel_list; struct mac_context *mac = MAC_CONTEXT(mac_handle); hdd_enter_dev(dev); memset(&channel_list, 0, sizeof(channel_list)); if (0 != iw_get_channel_list(dev, info, wrqu, (char *)&channel_list)) { Loading @@ -2028,15 +2009,13 @@ int iw_get_channel_list_with_cc(struct net_device *dev, return -EINVAL; } len = scnprintf(buf, WE_MAX_STR_LEN, "%u ", channel_list.num_channels); if (QDF_STATUS_SUCCESS == sme_get_country_code(mac_handle, ubuf, &ubuf_len)) { ucfg_reg_get_cc_and_src(mac->psoc, ubuf); /* Printing Country code in getChannelList */ for (i = 0; i < (ubuf_len - 1); i++) len += scnprintf(buf + len, WE_MAX_STR_LEN - len, "%c", ubuf[i]); } for (i = 0; i < channel_list.num_channels; i++) len += scnprintf(buf + len, WE_MAX_STR_LEN - len, " %u", channel_list.channels[i]); wrqu->data.length = strlen(extra) + 1; hdd_exit(); Loading core/hdd/src/wlan_hdd_main.c +39 −4 Original line number Diff line number Diff line Loading @@ -15490,6 +15490,36 @@ void hdd_init_start_completion(void) INIT_COMPLETION(wlan_start_comp); } #if defined CFG80211_USER_HINT_CELL_BASE_SELF_MANAGED || \ (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 18, 0)) static void hdd_inform_wifi_on(void) { int ret; struct hdd_context *hdd_ctx = cds_get_context(QDF_MODULE_ID_HDD); struct osif_psoc_sync *psoc_sync; hdd_nofl_debug("inform regdomain for wifi on"); ret = wlan_hdd_validate_context(hdd_ctx); if (ret) return; if (!wlan_hdd_validate_modules_state(hdd_ctx)) return; if (!hdd_ctx->wiphy) return; ret = osif_psoc_sync_op_start(wiphy_dev(hdd_ctx->wiphy), &psoc_sync); if (ret) return; if (hdd_ctx->wiphy->registered) hdd_send_wiphy_regd_sync_event(hdd_ctx); osif_psoc_sync_op_stop(psoc_sync); } #else static void hdd_inform_wifi_on(void) { } #endif static ssize_t wlan_hdd_state_ctrl_param_write(struct file *filp, const char __user *user_buf, size_t count, Loading @@ -15501,6 +15531,7 @@ static ssize_t wlan_hdd_state_ctrl_param_write(struct file *filp, int ret; unsigned long rc; struct hdd_context *hdd_ctx = cds_get_context(QDF_MODULE_ID_HDD); bool turning_on = false; if (copy_from_user(buf, user_buf, 3)) { pr_err("Failed to read buffer\n"); Loading @@ -15508,13 +15539,15 @@ static ssize_t wlan_hdd_state_ctrl_param_write(struct file *filp, } if (strncmp(buf, wlan_off_str, strlen(wlan_off_str)) == 0) { pr_debug("Wifi turning off from UI\n"); hdd_info("Wifi turning off from UI\n"); hdd_inform_wifi_off(); goto exit; } if (strncmp(buf, wlan_on_str, strlen(wlan_on_str)) == 0) pr_info("Wifi Turning On from UI\n"); if (strncmp(buf, wlan_on_str, strlen(wlan_on_str)) == 0) { hdd_info("Wifi Turning On from UI\n"); turning_on = true; } if (strncmp(buf, wlan_on_str, strlen(wlan_on_str)) != 0) { pr_err("Invalid value received from framework"); Loading @@ -15537,8 +15570,10 @@ static ssize_t wlan_hdd_state_ctrl_param_write(struct file *filp, */ if (hdd_ctx) hdd_psoc_idle_timer_stop(hdd_ctx); exit: if (turning_on) hdd_inform_wifi_on(); return count; } Loading core/mac/inc/qwlan_version.h +2 −2 Original line number Diff line number Diff line Loading @@ -32,9 +32,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 022 #define QWLAN_VERSION_EXTRA "D" #define QWLAN_VERSION_EXTRA "J" #define QWLAN_VERSION_BUILD 11 #define QWLAN_VERSIONSTR "5.2.022.11D" #define QWLAN_VERSIONSTR "5.2.022.11J" #endif /* QWLAN_VERSION_H */ core/wma/src/wma_main.c +2 −1 Original line number Diff line number Diff line Loading @@ -6778,7 +6778,8 @@ int wma_rx_service_ready_ext_event(void *handle, uint8_t *event, * indicate 3 vdevs and firmware shall add 1 vdev for NAN. So decrement * the num_vdevs by 1. */ if (ucfg_nan_is_vdev_creation_allowed(wma_handle->psoc)) { if (ucfg_nan_is_vdev_creation_allowed(wma_handle->psoc) || QDF_GLOBAL_FTM_MODE == cds_get_conparam()) { wlan_res_cfg->nan_separate_iface_support = true; } else { wlan_res_cfg->num_vdevs--; Loading Loading
components/mlme/dispatcher/inc/cfg_mlme_rates.h +3 −3 Original line number Diff line number Diff line Loading @@ -268,9 +268,9 @@ * b14-27 => NSS2, MCS 0-13 and so on for other NSS. * Note that the bit representation is continuous. * * For VHT targets, 10 bits correspond to one NSS setting. * b0-9 => NSS1, MCS 0-9 * b10-19 => NSS2, MCS 0-9 and so on for other NSS. * For VHT targets, 12 bits correspond to one NSS setting. * b0-11 => NSS1, MCS 0-11 * b12-23 => NSS2, MCS 0-11 and so on for other NSS. * * For HT targets, 8 bits correspond to one NSS setting. * b0-7 => NSS1, MCS 0-7 Loading
core/hdd/src/wlan_hdd_hostapd_wext.c +37 −58 Original line number Diff line number Diff line Loading @@ -1918,16 +1918,13 @@ static int iw_get_channel_list(struct net_device *dev, { uint32_t num_channels = 0; uint8_t i = 0; uint8_t band_start_channel = MIN_24GHZ_CHANNEL; uint8_t band_end_channel = MAX_5GHZ_CHANNEL; struct hdd_adapter *hostapd_adapter = (netdev_priv(dev)); struct channel_list_info *channel_list = (struct channel_list_info *)extra; bool enable_dfs_scan = true; enum band_info cur_band = BAND_ALL; struct regulatory_channel *cur_chan_list = NULL; struct hdd_context *hdd_ctx; int ret; bool is_dfs_mode_enabled = false; QDF_STATUS status; hdd_enter_dev(dev); Loading @@ -1940,59 +1937,44 @@ static int iw_get_channel_list(struct net_device *dev, if (0 != ret) return ret; if (QDF_STATUS_SUCCESS != ucfg_reg_get_band(hdd_ctx->pdev, &cur_band)) { hdd_err_rl("not able get the current frequency band"); return -EIO; } cur_chan_list = qdf_mem_malloc(sizeof(*cur_chan_list) * NUM_CHANNELS); if (!cur_chan_list) return -ENOMEM; if (BAND_2G == cur_band) { band_start_channel = MIN_24GHZ_CHANNEL; band_end_channel = MAX_24GHZ_CHANNEL; } else if (BAND_5G == cur_band) { band_start_channel = MIN_5GHZ_CHANNEL; band_end_channel = MAX_5GHZ_CHANNEL; } if (cur_band != BAND_2G) band_end_channel = MAX_5GHZ_CHANNEL; ucfg_scan_cfg_get_dfs_chan_scan_allowed(hdd_ctx->psoc, &enable_dfs_scan); if (hostapd_adapter->device_mode == QDF_STA_MODE && enable_dfs_scan) { is_dfs_mode_enabled = true; } else if (hostapd_adapter->device_mode == QDF_SAP_MODE) { if (QDF_STATUS_SUCCESS != ucfg_mlme_get_dfs_master_capability( hdd_ctx->psoc, &is_dfs_mode_enabled)) { hdd_err_rl("Fail to get dfs master mode capability"); return -EINVAL; } status = ucfg_reg_get_current_chan_list(hdd_ctx->pdev, cur_chan_list); if (status != QDF_STATUS_SUCCESS) { hdd_err_rl("Failed to get the current channel list"); qdf_mem_free(cur_chan_list); return -EIO; } hdd_debug_rl("curBand = %d, StartChannel = %hu, EndChannel = %hu, is_dfs_mode_enabled = %d", cur_band, band_start_channel, band_end_channel, is_dfs_mode_enabled); for (i = 0; i < NUM_CHANNELS; i++) { /* * current channel list includes all channels. do not report * disabled channels */ if (cur_chan_list[i].chan_flags & REGULATORY_CHAN_DISABLED) continue; for (i = band_start_channel; i <= band_end_channel; i++) { if ((CHANNEL_STATE_ENABLE == wlan_reg_get_channel_state_for_freq( hdd_ctx->pdev, WLAN_REG_CH_TO_FREQ(i))) || (is_dfs_mode_enabled && CHANNEL_STATE_DFS == wlan_reg_get_channel_state_for_freq( hdd_ctx->pdev, WLAN_REG_CH_TO_FREQ(i)))) { /* * do not include 6 GHz channels since they are ambiguous with * 2.4 GHz and 5 GHz channels. 6 GHz-aware applications should * not be using this interface, but instead should be using the * frequency-based interface */ if (wlan_reg_is_6ghz_chan_freq(cur_chan_list[i].center_freq)) continue; channel_list->channels[num_channels] = WLAN_REG_CH_NUM(i); cur_chan_list[i].chan_num; num_channels++; } } qdf_mem_free(cur_chan_list); hdd_debug_rl("number of channels %d", num_channels); channel_list->num_channels = num_channels; wrqu->data.length = num_channels + 1; hdd_exit(); return 0; } Loading @@ -2007,9 +1989,8 @@ int iw_get_channel_list_with_cc(struct net_device *dev, uint8_t ubuf[CFG_COUNTRY_CODE_LEN] = {0}; uint8_t ubuf_len = CFG_COUNTRY_CODE_LEN; struct channel_list_info channel_list; struct mac_context *mac = MAC_CONTEXT(mac_handle); hdd_enter_dev(dev); memset(&channel_list, 0, sizeof(channel_list)); if (0 != iw_get_channel_list(dev, info, wrqu, (char *)&channel_list)) { Loading @@ -2028,15 +2009,13 @@ int iw_get_channel_list_with_cc(struct net_device *dev, return -EINVAL; } len = scnprintf(buf, WE_MAX_STR_LEN, "%u ", channel_list.num_channels); if (QDF_STATUS_SUCCESS == sme_get_country_code(mac_handle, ubuf, &ubuf_len)) { ucfg_reg_get_cc_and_src(mac->psoc, ubuf); /* Printing Country code in getChannelList */ for (i = 0; i < (ubuf_len - 1); i++) len += scnprintf(buf + len, WE_MAX_STR_LEN - len, "%c", ubuf[i]); } for (i = 0; i < channel_list.num_channels; i++) len += scnprintf(buf + len, WE_MAX_STR_LEN - len, " %u", channel_list.channels[i]); wrqu->data.length = strlen(extra) + 1; hdd_exit(); Loading
core/hdd/src/wlan_hdd_main.c +39 −4 Original line number Diff line number Diff line Loading @@ -15490,6 +15490,36 @@ void hdd_init_start_completion(void) INIT_COMPLETION(wlan_start_comp); } #if defined CFG80211_USER_HINT_CELL_BASE_SELF_MANAGED || \ (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 18, 0)) static void hdd_inform_wifi_on(void) { int ret; struct hdd_context *hdd_ctx = cds_get_context(QDF_MODULE_ID_HDD); struct osif_psoc_sync *psoc_sync; hdd_nofl_debug("inform regdomain for wifi on"); ret = wlan_hdd_validate_context(hdd_ctx); if (ret) return; if (!wlan_hdd_validate_modules_state(hdd_ctx)) return; if (!hdd_ctx->wiphy) return; ret = osif_psoc_sync_op_start(wiphy_dev(hdd_ctx->wiphy), &psoc_sync); if (ret) return; if (hdd_ctx->wiphy->registered) hdd_send_wiphy_regd_sync_event(hdd_ctx); osif_psoc_sync_op_stop(psoc_sync); } #else static void hdd_inform_wifi_on(void) { } #endif static ssize_t wlan_hdd_state_ctrl_param_write(struct file *filp, const char __user *user_buf, size_t count, Loading @@ -15501,6 +15531,7 @@ static ssize_t wlan_hdd_state_ctrl_param_write(struct file *filp, int ret; unsigned long rc; struct hdd_context *hdd_ctx = cds_get_context(QDF_MODULE_ID_HDD); bool turning_on = false; if (copy_from_user(buf, user_buf, 3)) { pr_err("Failed to read buffer\n"); Loading @@ -15508,13 +15539,15 @@ static ssize_t wlan_hdd_state_ctrl_param_write(struct file *filp, } if (strncmp(buf, wlan_off_str, strlen(wlan_off_str)) == 0) { pr_debug("Wifi turning off from UI\n"); hdd_info("Wifi turning off from UI\n"); hdd_inform_wifi_off(); goto exit; } if (strncmp(buf, wlan_on_str, strlen(wlan_on_str)) == 0) pr_info("Wifi Turning On from UI\n"); if (strncmp(buf, wlan_on_str, strlen(wlan_on_str)) == 0) { hdd_info("Wifi Turning On from UI\n"); turning_on = true; } if (strncmp(buf, wlan_on_str, strlen(wlan_on_str)) != 0) { pr_err("Invalid value received from framework"); Loading @@ -15537,8 +15570,10 @@ static ssize_t wlan_hdd_state_ctrl_param_write(struct file *filp, */ if (hdd_ctx) hdd_psoc_idle_timer_stop(hdd_ctx); exit: if (turning_on) hdd_inform_wifi_on(); return count; } Loading
core/mac/inc/qwlan_version.h +2 −2 Original line number Diff line number Diff line Loading @@ -32,9 +32,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 022 #define QWLAN_VERSION_EXTRA "D" #define QWLAN_VERSION_EXTRA "J" #define QWLAN_VERSION_BUILD 11 #define QWLAN_VERSIONSTR "5.2.022.11D" #define QWLAN_VERSIONSTR "5.2.022.11J" #endif /* QWLAN_VERSION_H */
core/wma/src/wma_main.c +2 −1 Original line number Diff line number Diff line Loading @@ -6778,7 +6778,8 @@ int wma_rx_service_ready_ext_event(void *handle, uint8_t *event, * indicate 3 vdevs and firmware shall add 1 vdev for NAN. So decrement * the num_vdevs by 1. */ if (ucfg_nan_is_vdev_creation_allowed(wma_handle->psoc)) { if (ucfg_nan_is_vdev_creation_allowed(wma_handle->psoc) || QDF_GLOBAL_FTM_MODE == cds_get_conparam()) { wlan_res_cfg->nan_separate_iface_support = true; } else { wlan_res_cfg->num_vdevs--; Loading