@@ -413,6 +413,7 @@ def add_bss(apdev, ifname, confname, phy=None, ignore_error=False):
hapd = Hostapd(ifname, hostname=hostname, port=port)
if not hapd.ping():
raise Exception("Could not ping hostapd")
+ return hapd
def add_iface(apdev, confname, ifname=None):
if ifname == None:
@@ -431,6 +432,7 @@ def add_iface(apdev, confname, ifname=None):
hapd = Hostapd(ifname, hostname=hostname, port=port)
if not hapd.ping():
raise Exception("Could not ping hostapd")
+ return hapd
def remove_bss(apdev, ifname=None):
if ifname == None:
return hapd from add_bss() and add_iface() while we can next use it. Signed-off-by: Janusz Dziedzic <janusz.dziedzic@tieto.com> --- tests/hwsim/hostapd.py | 2 ++ 1 file changed, 2 insertions(+)