ap_list.h 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. /*
  2. * hostapd / AP table
  3. * Copyright (c) 2002-2003, Jouni Malinen <j@w1.fi>
  4. * Copyright (c) 2003-2004, Instant802 Networks, Inc.
  5. * Copyright (c) 2006, Devicescape Software, Inc.
  6. *
  7. * This software may be distributed under the terms of the BSD license.
  8. * See README for more details.
  9. */
  10. #ifndef AP_LIST_H
  11. #define AP_LIST_H
  12. struct ap_info {
  13. /* Note: next/prev pointers are updated whenever a new beacon is
  14. * received because these are used to find the least recently used
  15. * entries. */
  16. struct ap_info *next; /* next entry in AP list */
  17. struct ap_info *prev; /* previous entry in AP list */
  18. struct ap_info *hnext; /* next entry in hash table list */
  19. u8 addr[6];
  20. u8 supported_rates[WLAN_SUPP_RATES_MAX];
  21. int erp; /* ERP Info or -1 if ERP info element not present */
  22. int channel;
  23. int ht_support;
  24. struct os_reltime last_beacon;
  25. };
  26. struct ieee802_11_elems;
  27. struct hostapd_frame_info;
  28. void ap_list_process_beacon(struct hostapd_iface *iface,
  29. const struct ieee80211_mgmt *mgmt,
  30. struct ieee802_11_elems *elems,
  31. struct hostapd_frame_info *fi);
  32. #ifdef NEED_AP_MLME
  33. int ap_list_init(struct hostapd_iface *iface);
  34. void ap_list_deinit(struct hostapd_iface *iface);
  35. void ap_list_timer(struct hostapd_iface *iface);
  36. #else /* NEED_AP_MLME */
  37. static inline int ap_list_init(struct hostapd_iface *iface)
  38. {
  39. return 0;
  40. }
  41. static inline void ap_list_deinit(struct hostapd_iface *iface)
  42. {
  43. }
  44. static inline void ap_list_timer(struct hostapd_iface *iface)
  45. {
  46. }
  47. #endif /* NEED_AP_MLME */
  48. #endif /* AP_LIST_H */