nl80211: Allow control port to be disabled with a driver param

This is mainly for testing purposes to allow wpa_supplicant and hostapd
functionality to be tested both with and without using the nl80211
control port which is by default used whenever supported by the driver.
control_port=0 driver parameter will prevent that from happening.

Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
Jouni Malinen 2020-01-05 21:18:18 +02:00
parent 781c5a0624
commit c52129bed8

View file

@ -8006,6 +8006,9 @@ static int nl80211_set_param(void *priv, const char *param)
drv->test_use_roc_tx = 1; drv->test_use_roc_tx = 1;
} }
if (os_strstr(param, "control_port=0"))
drv->capa.flags &= ~WPA_DRIVER_FLAGS_CONTROL_PORT;
return 0; return 0;
} }