Use generic driver event notification for AP mode assoc/disassoc
[libeap.git] / src / ap / hostapd.h
index f3cbad2..7c6b0b7 100644 (file)
@@ -29,7 +29,7 @@ struct ieee80211_ht_capabilities;
 struct full_dynamic_vlan;
 
 struct hostapd_probereq_cb {
-       void (*cb)(void *ctx, const u8 *sa, const u8 *ie, size_t ie_len);
+       int (*cb)(void *ctx, const u8 *sa, const u8 *ie, size_t ie_len);
        void *ctx;
 };
 
@@ -40,6 +40,12 @@ struct hostapd_rate_data {
        int flags; /* HOSTAPD_RATE_ flags */
 };
 
+struct hostapd_frame_info {
+       u32 channel;
+       u32 datarate;
+       u32 ssi_signal;
+};
+
 
 struct hostapd_driver_ops {
        int (*set_ap_wps_ie)(struct hostapd_data *hapd,
@@ -249,9 +255,14 @@ void hostapd_new_assoc_sta(struct hostapd_data *hapd, struct sta_info *sta,
 
 /* utils.c */
 int hostapd_register_probereq_cb(struct hostapd_data *hapd,
-                                void (*cb)(void *ctx, const u8 *sa,
-                                           const u8 *ie, size_t ie_len),
+                                int (*cb)(void *ctx, const u8 *sa,
+                                          const u8 *ie, size_t ie_len),
                                 void *ctx);
 void hostapd_prune_associations(struct hostapd_data *hapd, const u8 *addr);
 
+/* drv_callbacks.c (TODO: move to somewhere else?) */
+int hostapd_notif_assoc(struct hostapd_data *hapd, const u8 *addr,
+                       const u8 *ie, size_t ielen);
+void hostapd_notif_disassoc(struct hostapd_data *hapd, const u8 *addr);
+
 #endif /* HOSTAPD_H */