• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * hdf_mac80211_sta_event.h
3  *
4  * sta event driver
5  *
6  * Copyright (c) 2020-2021 Huawei Device Co., Ltd.
7  *
8  * This software is licensed under the terms of the GNU General Public
9  * License version 2, as published by the Free Software Foundation, and
10  * may be copied, distributed, and modified under those terms.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  */
18 
19 #ifndef WAL_MAC80211_STA_EVENT_H_
20 #define WAL_MAC80211_STA_EVENT_H_
21 
22 #define HDF_ETHER_ADDR_LEN (6)
23 #include <net/cfg80211.h>
24 
25 typedef struct _HdfConnetResult {
26 //    uint8_t   bssid[ETH_ADDR_LEN];  /**< MAC address of the AP associated with the station */
27     uint8_t   bssid[HDF_ETHER_ADDR_LEN];  /**< MAC address of the AP associated with the station */
28     uint16_t  statusCode;           /**< 16-bit status code defined in the IEEE protocol */
29     uint8_t  *rspIe;                /**< Association response IE */
30     uint8_t  *reqIe;                /**< Association request IE */
31     uint32_t  reqIeLen;             /**< Length of the association request IE */
32     uint32_t  rspIeLen;             /**< Length of the association response IE */
33     uint16_t  connectStatus;        /**< Connection status */
34     uint16_t  freq;                 /**< Frequency of the AP */
35 } HdfConnetResult;
36 
37 typedef enum {
38     HDF_WIFI_SCAN_SUCCESS,
39     HDF_WIFI_SCAN_FAILED,
40     HDF_WIFI_SCAN_REFUSED,
41     HDF_WIFI_SCAN_TIMEOUT
42 } HdfWifiScanStatus;
43 
44 int32_t HdfScanEventCallback(struct net_device *ndev, HdfWifiScanStatus _status);
45 int32_t HdfConnectResultEventCallback(struct net_device *ndev, struct ConnetResult *conn);
46 void HdfInformBssFrameEventCallback(struct net_device *ndev, struct ieee80211_channel *channel,
47     struct ScannedBssInfo *bss);
48 int32_t HdfDisconnectedEventCallback(struct net_device *ndev, uint16_t reason, uint8_t *ie, uint32_t len);
49 
50 #endif
51