Skip to content

Commit dbc6cdc

Browse files
nxf58150nashif
authored andcommitted
modules: hostap: Supports link mode of legacy STA.
Link mode shows unknown when legacy (A or bg only) device connects to APUT. Set the link mode to WIFI_2 when the host freq over 4000 and set link mode to WIFI_3 when the host freq over 2000. Signed-off-by: Hui Bai <[email protected]>
1 parent 86feca3 commit dbc6cdc

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

modules/hostap/src/supp_events.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -271,6 +271,11 @@ static enum wifi_link_mode get_sta_link_mode(struct wpa_supplicant *wpa_s, struc
271271
return WIFI_2;
272272
} else if (wpa_s->assoc_freq > 2000) {
273273
return WIFI_3;
274+
#else
275+
} else if (iface->freq > 4000) {
276+
return WIFI_2;
277+
} else if (iface->freq > 2000) {
278+
return WIFI_3;
274279
#endif
275280
} else {
276281
return WIFI_LINK_MODE_UNKNOWN;

0 commit comments

Comments
 (0)