]> git.ipfire.org Git - thirdparty/hostap.git/commit
dbus: Do not bring down primary interface when removing created AP interface
authorJintao Lin <jintaolin@chromium.org>
Tue, 6 Dec 2022 17:41:58 +0000 (17:41 +0000)
committerJouni Malinen <j@w1.fi>
Sun, 18 Dec 2022 09:04:18 +0000 (11:04 +0200)
commit4bd1efe07354db6f3f588281219320dc671cde9d
tree05c7b91ee6383aaf03094b91292e95bdfcb8631f
parent3b4a5e58b74d5d3c69655d1bb102afb0c8f4a4aa
dbus: Do not bring down primary interface when removing created AP interface

If the CreateInterface command was used to create a virtual AP
interface, deleting this interface using the RemoveInterface command was
also bringing down the primary interface.

wpa_supplicant never uses hostapd style multi-BSS setup with
type=WPA_IF_AP_BSS and setup_ap=1 to if_add() when creating an AP
interface in wpa_driver_nl80211_if_add(), so it should not go through
the multi-BSS tear down procedure in wpa_driver_nl80211_if_remove(). The
virtual AP resources init and deinit are well handled in
wpa_driver_nl80211_init() and wpa_driver_nl80211_deinit().

Collapse the interface type to WPA_IF_STATION for the D-Bus interface to
skip the multi-BSS cleanup procedure. This is inline with the control
interface design. Add comments before the code to avoid confusion.

Signed-off-by: Jintao Lin <jintaolin@chromium.org>
wpa_supplicant/ctrl_iface.c
wpa_supplicant/dbus/dbus_new_handlers.c
wpa_supplicant/wpa_supplicant_i.h