mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-14 08:36:12 -04:00
qcacmn: Add new INI to separate scan policy for rest of world users
Currently host drops an AP from scan list if host country is set to US and AP country is non-US. This implementation violates our standard regulatory scan policy. To address this issue, introduce a new INI to differentiate between our standard regulatory policy with others. Change-Id: Id72f871653e31969c4d1b147cb3c557f90a6c8f6 CRs-Fixed: 3361720
This commit is contained in:
parent
074d285597
commit
c786671eaa
3 changed files with 54 additions and 2 deletions
|
|
@ -1908,6 +1908,30 @@ bool wlan_cm_get_check_6ghz_security(struct wlan_objmgr_psoc *psoc)
|
|||
return mlme_psoc_obj->psoc_cfg.score_config.check_6ghz_security;
|
||||
}
|
||||
|
||||
void wlan_cm_set_standard_6ghz_conn_policy(struct wlan_objmgr_psoc *psoc,
|
||||
bool value)
|
||||
{
|
||||
struct psoc_mlme_obj *mlme_psoc_obj;
|
||||
|
||||
mlme_psoc_obj = wlan_psoc_mlme_get_cmpt_obj(psoc);
|
||||
if (!mlme_psoc_obj)
|
||||
return;
|
||||
|
||||
mlme_debug("6ghz standard connection policy val %x", value);
|
||||
mlme_psoc_obj->psoc_cfg.score_config.standard_6ghz_conn_policy = value;
|
||||
}
|
||||
|
||||
bool wlan_cm_get_standard_6ghz_conn_policy(struct wlan_objmgr_psoc *psoc)
|
||||
{
|
||||
struct psoc_mlme_obj *mlme_psoc_obj;
|
||||
|
||||
mlme_psoc_obj = wlan_psoc_mlme_get_cmpt_obj(psoc);
|
||||
if (!mlme_psoc_obj)
|
||||
return false;
|
||||
|
||||
return mlme_psoc_obj->psoc_cfg.score_config.standard_6ghz_conn_policy;
|
||||
}
|
||||
|
||||
void wlan_cm_set_6ghz_key_mgmt_mask(struct wlan_objmgr_psoc *psoc,
|
||||
uint32_t value)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
/*
|
||||
* Copyright (c) 2017-2020, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2023 Qualcomm Innovation Center, Inc. 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 above
|
||||
|
|
@ -129,6 +130,7 @@ struct per_slot_score {
|
|||
* @check_assoc_disallowed: Should assoc be disallowed if MBO OCE IE indicate so
|
||||
* @vendor_roam_score_algorithm: Preferred ETP vendor roam score algorithm
|
||||
* @check_6ghz_security: check security for 6Ghz candidate
|
||||
* @standard_6ghz_conn_policy: check for 6 GHz standard connection policy
|
||||
* @key_mgmt_mask_6ghz: user configurable mask for 6ghz AKM
|
||||
*/
|
||||
struct scoring_cfg {
|
||||
|
|
@ -143,6 +145,7 @@ struct scoring_cfg {
|
|||
bool check_assoc_disallowed;
|
||||
bool vendor_roam_score_algorithm;
|
||||
uint8_t check_6ghz_security;
|
||||
uint8_t standard_6ghz_conn_policy:1;
|
||||
uint32_t key_mgmt_mask_6ghz;
|
||||
};
|
||||
|
||||
|
|
@ -291,6 +294,18 @@ void wlan_cm_set_6ghz_key_mgmt_mask(struct wlan_objmgr_psoc *psoc,
|
|||
*/
|
||||
uint32_t wlan_cm_get_6ghz_key_mgmt_mask(struct wlan_objmgr_psoc *psoc);
|
||||
|
||||
void wlan_cm_set_standard_6ghz_conn_policy(struct wlan_objmgr_psoc *psoc,
|
||||
bool value);
|
||||
|
||||
/**
|
||||
* wlan_cm_get_standard_6ghz_conn_policy() - Get 6Ghz standard connection
|
||||
* policy
|
||||
* @psoc: pointer to psoc object
|
||||
*
|
||||
* Return: value
|
||||
*/
|
||||
bool wlan_cm_get_standard_6ghz_conn_policy(struct wlan_objmgr_psoc *psoc);
|
||||
|
||||
#else
|
||||
static inline bool
|
||||
wlan_cm_6ghz_allowed_for_akm(struct wlan_objmgr_psoc *psoc,
|
||||
|
|
@ -314,6 +329,18 @@ bool wlan_cm_get_check_6ghz_security(struct wlan_objmgr_psoc *psoc)
|
|||
return false;
|
||||
}
|
||||
|
||||
static inline
|
||||
void wlan_cm_set_standard_6ghz_conn_policy(struct wlan_objmgr_psoc *psoc,
|
||||
uint32_t value)
|
||||
{
|
||||
}
|
||||
|
||||
static inline
|
||||
bool wlan_cm_get_standard_6ghz_conn_policy(struct wlan_objmgr_psoc *psoc)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
static inline
|
||||
void wlan_cm_set_6ghz_key_mgmt_mask(struct wlan_objmgr_psoc *psoc,
|
||||
uint32_t value) {}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
/*
|
||||
* Copyright (c) 2017-2020 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
* Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. 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
|
||||
|
|
@ -1166,7 +1166,8 @@ QDF_STATUS __scm_handle_bcn_probe(struct scan_bcn_probe_event *bcn)
|
|||
* enabled. wlan_cm_get_check_6ghz_security API returns true if
|
||||
* neither Safe mode nor RF test mode are enabled.
|
||||
*/
|
||||
if (!scm_is_bss_allowed_for_country(psoc, scan_entry) &&
|
||||
if (!wlan_cm_get_standard_6ghz_conn_policy(psoc) &&
|
||||
!scm_is_bss_allowed_for_country(psoc, scan_entry) &&
|
||||
wlan_cm_get_check_6ghz_security(psoc)) {
|
||||
scm_info_rl(
|
||||
"Drop frame from "QDF_MAC_ADDR_FMT
|
||||
|
|
|
|||
Loading…
Reference in a new issue