Skip to content
This repository has been archived by the owner on Nov 14, 2024. It is now read-only.

[nrf fromlist] wpa_supplicant: Add an option to disable SNR capping #166

Merged
merged 1 commit into from
Apr 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions wpa_supplicant/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -1886,6 +1886,10 @@ ifdef CONFIG_NO_TKIP
CFLAGS += -DCONFIG_NO_TKIP
endif

ifdef CONFIG_NW_SEL_RELIABILITY
CFLAGS += -DCONFIG_NW_SEL_RELIABILITY
endif

dynamic_eap_methods: $(EAPDYN)

_OBJS_VAR := OBJS_priv
Expand Down
11 changes: 11 additions & 0 deletions wpa_supplicant/defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -633,3 +633,14 @@ CONFIG_DPP2=y
# design is still subject to change. As such, this should not yet be enabled in
# production use.
#CONFIG_PASN=y

# When selecting a network, prefer networks with a better signal strength
# without any cap a.k.a "Great SNR".
#
# If this is enabled then higher SNR is preferred without any cap over higher band
# (higher throughput) to achieve better reliability.
#
# If this is disabled then for networks with capped SNR, the preference is given
# to the network with higher band (5GHz or 6GHz) and then to the network with
# higher SNR.
#CONFIG_NW_SEL_RELIABILITY=y
10 changes: 10 additions & 0 deletions wpa_supplicant/scan.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,15 @@
#define DEFAULT_NOISE_FLOOR_5GHZ (-92)
#define DEFAULT_NOISE_FLOOR_6GHZ (-92)

#ifdef CONFIG_NW_SEL_RELIABILITY
/*
* This basically disables capping the SNR when choosing the best BSS. This
* means that the BSS with the highest SNR will be chosen, independent of the
* band. This is useful for scenarios where reliability is more important than
* throughput.
*/
#define GREAT_SNR 999
#else
/*
* Channels with a great SNR can operate at full rate. What is a great SNR?
* This doc https://supportforums.cisco.com/docs/DOC-12954 says, "the general
Expand All @@ -29,6 +38,7 @@
* somewhat conservative value here.
*/
#define GREAT_SNR 25
#endif /* CONFIG_NW_SEL_RELIABILITY */

#define IS_2P4GHZ(n) (n >= 2412 && n <= 2484)
#define IS_5GHZ(n) (n > 4000 && n < 5895)
Expand Down
Loading