diff mbox series

nl80211: fix small room for AKM suites log splat

Message ID 20200511081651.22849-1-ynezz@true.cz
State Accepted
Headers show
Series nl80211: fix small room for AKM suites log splat | expand

Commit Message

Petr Štetiar May 11, 2020, 8:16 a.m. UTC
Commit dd74ddd0dff6 ("nl80211: Handle AKM suite selectors for AP
configuration") added warning log message "nl80211: Not enough room for
all AKM suites (num_suites=X > NL80211_MAX_NR_AKM_SUITES)" which in some
cases fills logs every 3 seconds, so fix this by increasing the log
message level to debug.

Reported-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
Ref: https://patchwork.ozlabs.org/project/openwrt/patch/20200504130757.12736-1-ynezz@true.cz/#2429246
Fixes: dd74ddd0dff6 ("nl80211: Handle AKM suite selectors for AP configuration")
Signed-off-by: Petr Štetiar <ynezz@true.cz>
---
 src/drivers/driver_nl80211.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Stefan Lippers-Hollmann May 12, 2020, 3:33 a.m. UTC | #1
Hi

On 2020-05-11, Petr Štetiar wrote:
> Commit dd74ddd0dff6 ("nl80211: Handle AKM suite selectors for AP
> configuration") added warning log message "nl80211: Not enough room for
> all AKM suites (num_suites=X > NL80211_MAX_NR_AKM_SUITES)" which in some
> cases fills logs every 3 seconds, so fix this by increasing the log
> message level to debug.
> 
> Reported-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
> Ref: https://patchwork.ozlabs.org/project/openwrt/patch/20200504130757.12736-1-ynezz@true.cz/#2429246
[...]

Tested-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>

As already quickly indicated on IRC, hostapd has been functional 
despite this regular warning, it merely made the system log ring buffer 
overflow with 'meaningless' (at least unfixable) warnings.

I've now successfully tested this patch on ipq40xx/ map-ac2200 
(ipq4019+qca9886, ath10k), using r13213-146e18af56 as a base (upgrading
locally to kernel v5.4.40, no code changes necessary to build on ath79, 
ath79-tiny, ipq40xx, ipq806x, lantiq; runtime tested on ipq40xx only so 
far) and Hauke's mac80211 v5.7-rc3 patchset. I don't really notice any
CPU load increase either (which might have been possible due to spinning
into the error case on a regular base, despite not actually printing out
the warning anymore), so this patch seems to work.

Regards, thanks
	Stefan Lippers-Hollmann
Jouni Malinen May 16, 2020, 4:18 p.m. UTC | #2
On Mon, May 11, 2020 at 10:16:51AM +0200, Petr Štetiar wrote:
> Commit dd74ddd0dff6 ("nl80211: Handle AKM suite selectors for AP
> configuration") added warning log message "nl80211: Not enough room for
> all AKM suites (num_suites=X > NL80211_MAX_NR_AKM_SUITES)" which in some
> cases fills logs every 3 seconds, so fix this by increasing the log
> message level to debug.

Thanks, applied.
diff mbox series

Patch

diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c
index d48f8cb7653d..3c4c41dcad87 100644
--- a/src/drivers/driver_nl80211.c
+++ b/src/drivers/driver_nl80211.c
@@ -4323,7 +4323,7 @@  static int wpa_driver_nl80211_set_ap(void *priv,
 	num_suites = wpa_key_mgmt_to_suites(params->key_mgmt_suites,
 					    suites, ARRAY_SIZE(suites));
 	if (num_suites > NL80211_MAX_NR_AKM_SUITES)
-		wpa_printf(MSG_WARNING,
+		wpa_printf(MSG_DEBUG,
 			   "nl80211: Not enough room for all AKM suites (num_suites=%d > NL80211_MAX_NR_AKM_SUITES)",
 			   num_suites);
 	else if (num_suites &&