mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-13 08:07:32 -04:00
qcacld-3.0: Disconnect after roam fails in NUD fail case
Extend ini value to disconnect from current AP if roam failure happens after the NUD failure. Change-Id: Id764c97b5c1748b1d513d85d4063868a1c77141b CRs-Fixed: 2622087
This commit is contained in:
parent
8f5b9fbe84
commit
29aa34ddea
10 changed files with 34 additions and 18 deletions
|
|
@ -1251,7 +1251,7 @@
|
|||
* <ini>
|
||||
* gEnableNUDTracking - Will enable or disable NUD tracking within driver
|
||||
* @Min: 0
|
||||
* @Max: 2
|
||||
* @Max: 3
|
||||
* @Default: 2
|
||||
*
|
||||
* This ini is used to specify the behaviour of the driver for NUD tracking.
|
||||
|
|
@ -1261,7 +1261,7 @@
|
|||
* the connected BSSID.
|
||||
* 2: Driver will track the NUD failures and if honoured will roam away from
|
||||
* the connected BSSID to a new BSSID to retain the data connectivity.
|
||||
*
|
||||
* 3: Driver will try to roam to a new AP but if roam fails, disconnect.
|
||||
* Related: None
|
||||
*
|
||||
* Supported Feature: STA
|
||||
|
|
@ -1270,15 +1270,11 @@
|
|||
*
|
||||
* <ini>
|
||||
*/
|
||||
#define CFG_DP_ROAM_AFTER_NUD_FAIL 2
|
||||
#define CFG_DP_DISCONNECT_AFTER_NUD_FAIL 1
|
||||
#define CFG_DP_DISABLE_NUD_TRACKING 0
|
||||
|
||||
#define CFG_DP_ENABLE_NUD_TRACKING \
|
||||
CFG_INI_UINT("gEnableNUDTracking", \
|
||||
CFG_DP_DISABLE_NUD_TRACKING, \
|
||||
CFG_DP_ROAM_AFTER_NUD_FAIL, \
|
||||
CFG_DP_ROAM_AFTER_NUD_FAIL, \
|
||||
0, \
|
||||
3, \
|
||||
2, \
|
||||
CFG_VALUE_OR_DEFAULT, "Driver NUD tracking behaviour")
|
||||
|
||||
#define CFG_DP_ENABLE_NUD_TRACKING_ALL \
|
||||
|
|
|
|||
|
|
@ -204,9 +204,7 @@ struct hdd_config {
|
|||
bool enable_dp_trace;
|
||||
uint8_t dp_trace_config[DP_TRACE_CONFIG_STRING_LENGTH];
|
||||
#endif
|
||||
#ifdef WLAN_NUD_TRACKING
|
||||
uint8_t enable_nud_tracking;
|
||||
#endif
|
||||
uint32_t operating_chan_freq;
|
||||
uint8_t num_vdevs;
|
||||
uint8_t enable_concurrent_sta[CFG_CONCURRENT_IFACE_MAX_LEN];
|
||||
|
|
|
|||
|
|
@ -853,7 +853,7 @@ QDF_STATUS hdd_set_sme_config(struct hdd_context *hdd_ctx)
|
|||
*/
|
||||
sme_config->csr_config.phyMode =
|
||||
hdd_cfg_xlate_to_csr_phy_mode(config->dot11Mode);
|
||||
|
||||
sme_update_nud_config(mac_handle, config->enable_nud_tracking);
|
||||
if (config->dot11Mode == eHDD_DOT11_MODE_abg ||
|
||||
config->dot11Mode == eHDD_DOT11_MODE_11b ||
|
||||
config->dot11Mode == eHDD_DOT11_MODE_11g ||
|
||||
|
|
@ -884,7 +884,6 @@ QDF_STATUS hdd_set_sme_config(struct hdd_context *hdd_ctx)
|
|||
&enable_dfs_scan);
|
||||
sme_config->csr_config.fEnableDFSChnlScan = enable_dfs_scan;
|
||||
sme_config->csr_config.Csr11dinfo.Channels.numChannels = 0;
|
||||
|
||||
hdd_set_power_save_offload_config(hdd_ctx);
|
||||
|
||||
#ifdef FEATURE_WLAN_ESE
|
||||
|
|
|
|||
|
|
@ -290,7 +290,8 @@ hdd_handle_nud_fail_non_sta(struct hdd_adapter *adapter)
|
|||
static bool
|
||||
hdd_is_roam_after_nud_enabled(struct hdd_config *config)
|
||||
{
|
||||
if (config->enable_nud_tracking == CFG_DP_ROAM_AFTER_NUD_FAIL)
|
||||
if (config->enable_nud_tracking == ROAM_AFTER_NUD_FAIL ||
|
||||
config->enable_nud_tracking == DISCONNECT_AFTER_ROAM_FAIL)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2012-2019 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2012-2020 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
|
||||
|
|
@ -761,6 +761,7 @@ struct mac_context {
|
|||
struct wlan_mlme_chain_cfg fw_chain_cfg;
|
||||
struct wlan_mlme_cfg *mlme_cfg;
|
||||
tAniSirLim lim;
|
||||
uint8_t nud_fail_behaviour;
|
||||
struct sch_context sch;
|
||||
tAniSirSys sys;
|
||||
|
||||
|
|
|
|||
|
|
@ -4429,6 +4429,11 @@ struct sir_sme_ext_cng_chan_req {
|
|||
uint8_t vdev_id;
|
||||
};
|
||||
|
||||
#define IGNORE_NUD_FAIL 0
|
||||
#define DISCONNECT_AFTER_NUD_FAIL 1
|
||||
#define ROAM_AFTER_NUD_FAIL 2
|
||||
#define DISCONNECT_AFTER_ROAM_FAIL 3
|
||||
|
||||
/**
|
||||
* struct sir_sme_ext_change_chan_ind.
|
||||
* @session_id: session id
|
||||
|
|
|
|||
|
|
@ -901,6 +901,7 @@ struct csr_neighbor_report_offload_params {
|
|||
struct csr_config_params {
|
||||
/* keep this uint32_t. This gets converted to ePhyChannelBondState */
|
||||
uint32_t channelBondingMode24GHz;
|
||||
uint8_t nud_fail_behaviour;
|
||||
uint32_t channelBondingMode5GHz;
|
||||
eCsrPhyMode phyMode;
|
||||
uint32_t HeartbeatThresh50;
|
||||
|
|
|
|||
|
|
@ -412,6 +412,13 @@ void sme_cleanup_session(mac_handle_t mac_handle, uint8_t vdev_id);
|
|||
void sme_set_curr_device_mode(mac_handle_t mac_handle,
|
||||
enum QDF_OPMODE curr_device_mode);
|
||||
|
||||
/**
|
||||
* sme_update_nud_config() - update nud config
|
||||
* @mac_handle: The handle returned by mac_open.
|
||||
* @nud_fail_behavior: Vlaue of nud fail behaviour
|
||||
*/
|
||||
void sme_update_nud_config(mac_handle_t mac_handle, uint8_t nud_fail_behavior);
|
||||
|
||||
QDF_STATUS sme_update_roam_params(mac_handle_t mac_handle,
|
||||
uint8_t session_id,
|
||||
struct roam_ext_params *roam_params_src,
|
||||
|
|
|
|||
|
|
@ -841,6 +841,13 @@ void sme_update_fine_time_measurement_capab(mac_handle_t mac_handle,
|
|||
}
|
||||
}
|
||||
|
||||
void sme_update_nud_config(mac_handle_t mac_handle, uint8_t nud_fail_behavior)
|
||||
{
|
||||
struct mac_context *mac = MAC_CONTEXT(mac_handle);
|
||||
|
||||
mac->nud_fail_behaviour = nud_fail_behavior;
|
||||
}
|
||||
|
||||
/**
|
||||
* sme_update_neighbor_report_config() - Update CSR config for 11k params
|
||||
* @mac_handle: Pointer to MAC context
|
||||
|
|
|
|||
|
|
@ -21167,9 +21167,10 @@ static QDF_STATUS csr_process_roam_sync_callback(struct mac_context *mac_ctx,
|
|||
eCSR_ROAM_NAPI_OFF, eCSR_ROAM_RESULT_SUCCESS);
|
||||
goto end;
|
||||
case SIR_ROAMING_INVOKE_FAIL:
|
||||
sme_debug("Roaming triggered failed source %d",
|
||||
vdev_roam_params->source);
|
||||
if (vdev_roam_params->source == USERSPACE_INITIATED) {
|
||||
sme_debug("Roaming triggered failed source %d nud behaviour %d",
|
||||
vdev_roam_params->source, mac_ctx->nud_fail_behaviour);
|
||||
if (vdev_roam_params->source == USERSPACE_INITIATED ||
|
||||
mac_ctx->nud_fail_behaviour == DISCONNECT_AFTER_NUD_FAIL) {
|
||||
/* Userspace roam req fail, disconnect with AP */
|
||||
csr_roam_disconnect(mac_ctx, session_id,
|
||||
eCSR_DISCONNECT_REASON_DEAUTH,
|
||||
|
|
|
|||
Loading…
Reference in a new issue