Home | History | Annotate | Download | only in wpa_supplicant_8_lib
      1 #ifndef __DEVICE_GOOGLE_GCE_WPA_SUPPLICANT_8_H__
      2 #define __DEVICE_GOOGLE_GCE_WPA_SUPPLICANT_8_H__
      3 
      4 #include <stddef.h>
      5 #include <stdio.h>
      6 #include <stdlib.h>
      7 #include <string.h>
      8 #include "common.h"
      9 #include "wpa_supplicant_i.h"
     10 
     11 #define LOG_TAG "GceWpaSupplicant8Driver"
     12 
     13 #include "log/log.h"
     14 
     15 /*
     16 #define GCE_WPA_SUPPLICANT_DEBUG 0
     17 */
     18 
     19 #if GCE_WPA_SUPPLICANT_DEBUG
     20 #  define D(...) ALOGD(__VA_ARGS__)
     21 #else
     22 #  define D(...) ((void)0)
     23 #endif
     24 
     25 
     26 typedef struct android_wifi_priv_cmd {
     27   char* buf;
     28   int used_len;
     29   int total_len;
     30 } android_wifi_priv_cmd;
     31 
     32 /*
     33 #if GCE_PLATFORM_SDK_BEFORE(K)
     34 
     35 #include "driver.h"
     36 #include "linux_ioctl.h"
     37 
     38 struct i802_bss {
     39   struct wpa_driver_nl80211_data* drv;
     40   struct i802_bss* next;
     41   int ifindex;
     42   char ifname[IFNAMSIZ + 1];
     43   char brname[IFNAMSIZ];
     44 
     45   unsigned int beacon_set:1;
     46   unsigned int added_if_into_bridge:1;
     47   unsigned int added_bridge:1;
     48   unsigned int in_deinit:1;
     49 
     50   u8 addr[ETH_ALEN];
     51 
     52   int freq;
     53 
     54   void* ctx;
     55   struct nl_handle* nl_preq;
     56   struct nl_handle* nl_mgmt;
     57   struct nl_cb* nl_cb;
     58 
     59   struct nl80211_wiphy_data *wiphy_data;
     60   struct dl_list wiphy_list;
     61 };
     62 
     63 struct nl80211_global {
     64   struct dl_list interfaces;
     65   int if_add_ifindex;
     66   struct netlink_data *netlink;
     67   struct nl_cb* nl_cb;
     68   struct nl_handle* nl;
     69   int nl80211_id;
     70   int ioctl_sock;  // socket for ioctl() use
     71 
     72   struct nl_handle* nl_event;
     73 };
     74 
     75 struct wpa_driver_nl80211_data {
     76   struct nl80211_global* global;
     77   struct dl_list list;
     78   struct dl_list wiphy_list;
     79   char phyname[32];
     80   void* ctx;
     81   int ifindex;
     82   int if_removed;
     83   int if_disabled;
     84   int ignore_if_down_event;
     85   struct rfkill_data* rfkill;
     86   struct wpa_driver_capa capa;
     87   u8* extended_capa;
     88   u8* extended_capa_mask;
     89   unsigned int extended_capa_len;
     90   int has_capability;
     91   // More internal data follows.
     92 };
     93 
     94 #endif  // GCE_PLATFORM_SDK_AFTER(J)
     95 */
     96 
     97 #endif  // __DEVICE_GOOGLE_GCE_WPA_SUPPLICANT_8_H__
     98