This sends out the AP and Enrollee notifications for all tracked
devices and generates a new SSDP search to find more APs.
int wps_attr_text(struct wpabuf *data, char *buf, char *end);
struct wps_er * wps_er_init(struct wps_context *wps, const char *ifname);
int wps_attr_text(struct wpabuf *data, char *buf, char *end);
struct wps_er * wps_er_init(struct wps_context *wps, const char *ifname);
+void wps_er_refresh(struct wps_er *er);
void wps_er_deinit(struct wps_er *er);
void wps_er_set_sel_reg(struct wps_er *er, int sel_reg, u16 dev_passwd_id,
u16 sel_reg_config_methods);
void wps_er_deinit(struct wps_er *er);
void wps_er_set_sel_reg(struct wps_er *er, int sel_reg, u16 dev_passwd_id,
u16 sel_reg_config_methods);
+void wps_er_refresh(struct wps_er *er)
+{
+ struct wps_er_ap *ap;
+ struct wps_er_sta *sta;
+
+ for (ap = er->ap; ap; ap = ap->next) {
+ wps_er_ap_event(er->wps, ap, WPS_EV_ER_AP_ADD);
+ for (sta = ap->sta; sta; sta = sta->next)
+ wps_er_sta_event(er->wps, sta, WPS_EV_ER_ENROLLEE_ADD);
+ }
+
+ wps_er_send_ssdp_msearch(er);
+}
+
+
void wps_er_deinit(struct wps_er *er)
{
if (er == NULL)
void wps_er_deinit(struct wps_er *er)
{
if (er == NULL)
{
#ifdef CONFIG_WPS_ER
if (wpa_s->wps_er) {
{
#ifdef CONFIG_WPS_ER
if (wpa_s->wps_er) {
- /* TODO: re-send ctrl_iface events for current data? */
+ wps_er_refresh(wpa_s->wps_er);
return 0;
}
wpa_s->wps_er = wps_er_init(wpa_s->wps, wpa_s->ifname);
return 0;
}
wpa_s->wps_er = wps_er_init(wpa_s->wps, wpa_s->ifname);