blob: 3f8235dfa73d30eb383a217dd52b8473c31caed0 [file] [log] [blame]
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001/*
Vidyullatha, Kanchanapally528789e2016-05-11 20:38:37 +05302 * Copyright (c) 2012-2016 The Linux Foundation. All rights reserved.
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08003 *
4 * Previously licensed under the ISC license by Qualcomm Atheros, Inc.
5 *
6 *
7 * Permission to use, copy, modify, and/or distribute this software for
8 * any purpose with or without fee is hereby granted, provided that the
9 * above copyright notice and this permission notice appear in all
10 * copies.
11 *
12 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
13 * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
14 * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
15 * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
16 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
17 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
18 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
19 * PERFORMANCE OF THIS SOFTWARE.
20 */
21
22/**
23 * DOC : wlan_hdd_scan.h
24 *
25 * WLAN Host Device Driver scan related implementation
26 *
27 */
28
29#if !defined(WLAN_HDD_SCAN_H)
30#define WLAN_HDD_SCAN_H
31
32#include "wlan_hdd_main.h"
33
34#define MAX_PENDING_LOG 5
35
36/*
37 * enum scan_source - scan request source
38 *
39 * @NL_SCAN: Scan initiated from NL
40 * @VENDOR_SCAN: Scan intiated from vendor command
41*/
42enum scan_source {
43 NL_SCAN,
44 VENDOR_SCAN,
45};
46
47int iw_get_scan(struct net_device *dev, struct iw_request_info *info,
48 union iwreq_data *wrqu, char *extra);
49
50int iw_set_scan(struct net_device *dev, struct iw_request_info *info,
51 union iwreq_data *wrqu, char *extra);
52
Prashanth Bhatta527fd752016-04-28 12:35:23 -070053int hdd_scan_context_init(hdd_context_t *hdd_ctx);
54void hdd_scan_context_destroy(hdd_context_t *hdd_ctx);
55
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080056int wlan_hdd_cfg80211_scan(struct wiphy *wiphy,
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080057 struct cfg80211_scan_request *request);
58
59#ifdef FEATURE_WLAN_SCAN_PNO
60int wlan_hdd_cfg80211_sched_scan_start(struct wiphy *wiphy,
61 struct net_device *dev,
62 struct cfg80211_sched_scan_request
63 *request);
64
65int wlan_hdd_cfg80211_sched_scan_stop(struct wiphy *wiphy,
66 struct net_device *dev);
67#endif /* End of FEATURE_WLAN_SCAN_PNO */
68
69int wlan_hdd_cfg80211_vendor_scan(struct wiphy *wiphy,
70 struct wireless_dev *wdev, const void *data,
71 int data_len);
72
Sandeep Puligillae390be52016-02-08 17:07:05 -080073void hdd_cleanup_scan_queue(hdd_context_t *hdd_ctx);
Vidyullatha, Kanchanapally528789e2016-05-11 20:38:37 +053074
75#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 5, 0)) || \
76 defined(CFG80211_ABORT_SCAN)
77void wlan_hdd_cfg80211_abort_scan(struct wiphy *wiphy,
78 struct wireless_dev *wdev);
79#endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080080#endif /* end #if !defined(WLAN_HDD_SCAN_H) */
81