diff mbox series

[2/3] scan: replace -ENETUNREACH with -ENOTSUP for rate estimation return

Message ID 20240415151130.40389-2-prestwoj@gmail.com (mailing list archive)
State New
Headers show
Series [1/3] band: return -ENOTSUP when RSSI is too low for rate estimation | expand

Checks

Context Check Description
tedd_an/pre-ci_am success Success
prestwoj/iwd-ci-gitlint success GitLint

Commit Message

James Prestwood April 15, 2024, 3:11 p.m. UTC
The rate estimation functions now just return 0 or -ENOTSUP for
success or if no estimation could be made due to missing IEs. Only
in the case of other errors (such as malformed IEs) should a
warning be printed.
---
 src/scan.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/src/scan.c b/src/scan.c
index f48ffdef..a22cc27a 100644
--- a/src/scan.c
+++ b/src/scan.c
@@ -1608,7 +1608,7 @@  static struct scan_bss *scan_parse_attr_bss(struct l_genl_attr *attr,
 
 		ret = wiphy_estimate_data_rate(wiphy, ies, ies_len, bss,
 						&bss->data_rate);
-		if (ret < 0 && ret != -ENETUNREACH)
+		if (ret < 0 && ret != -ENOTSUP)
 			l_warn("wiphy_estimate_data_rate() failed");
 	}