diff --git a/src/ap/ap_drv_ops.c b/src/ap/ap_drv_ops.c index f15765945..d1642d7df 100644 --- a/src/ap/ap_drv_ops.c +++ b/src/ap/ap_drv_ops.c @@ -988,3 +988,11 @@ int hostapd_drv_update_dh_ie(struct hostapd_data *hapd, const u8 *peer, return hapd->driver->update_dh_ie(hapd->drv_priv, peer, reason_code, ie, ielen); } + + +int hostapd_drv_dpp_listen(struct hostapd_data *hapd, bool enable) +{ + if (!hapd->driver || !hapd->driver->dpp_listen || !hapd->drv_priv) + return 0; + return hapd->driver->dpp_listen(hapd->drv_priv, enable); +} diff --git a/src/ap/ap_drv_ops.h b/src/ap/ap_drv_ops.h index 0257c3a65..582ab61d8 100644 --- a/src/ap/ap_drv_ops.h +++ b/src/ap/ap_drv_ops.h @@ -134,6 +134,7 @@ int hostapd_start_dfs_cac(struct hostapd_iface *iface, int hostapd_drv_do_acs(struct hostapd_data *hapd); int hostapd_drv_update_dh_ie(struct hostapd_data *hapd, const u8 *peer, u16 reason_code, const u8 *ie, size_t ielen); +int hostapd_drv_dpp_listen(struct hostapd_data *hapd, bool enable); #include "drivers/driver.h" diff --git a/src/ap/dpp_hostapd.c b/src/ap/dpp_hostapd.c index c048d1db5..e106df513 100644 --- a/src/ap/dpp_hostapd.c +++ b/src/ap/dpp_hostapd.c @@ -697,12 +697,14 @@ int hostapd_dpp_listen(struct hostapd_data *hapd, const char *cmd) return -1; } + hostapd_drv_dpp_listen(hapd, true); return 0; } void hostapd_dpp_listen_stop(struct hostapd_data *hapd) { + hostapd_drv_dpp_listen(hapd, false); /* TODO: Stop listen operation on non-operating channel */ }