blob: b9b07961aa50951685cdae079a7c75132430909c [file] [log] [blame]
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001/*
Jeff Johnson46106882017-01-12 10:39:26 -08002 * Copyright (c) 2012-2017 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 * This file was originally distributed by Qualcomm Atheros, Inc.
24 * under proprietary terms before Copyright ownership was assigned
25 * to the Linux Foundation.
26 */
27
28#ifndef __WEXT_IW_H__
29#define __WEXT_IW_H__
30
31#include <linux/version.h>
32#include <linux/module.h>
33#include <linux/netdevice.h>
34#include <linux/wireless.h>
35#include <net/iw_handler.h>
36#include <linux/timer.h>
Anurag Chouhance0dc992016-02-16 18:18:03 +053037#include "qdf_event.h"
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080038
Krishna Kumaar Natarajan9e5339d2016-12-05 14:12:13 -080039struct sap_Config;
40
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080041/*
42 * order of parameters in addTs private ioctl
43 */
44#define HDD_WLAN_WMM_PARAM_HANDLE 0
45#define HDD_WLAN_WMM_PARAM_TID 1
46#define HDD_WLAN_WMM_PARAM_DIRECTION 2
47#define HDD_WLAN_WMM_PARAM_APSD 3
48#define HDD_WLAN_WMM_PARAM_USER_PRIORITY 4
49#define HDD_WLAN_WMM_PARAM_NOMINAL_MSDU_SIZE 5
50#define HDD_WLAN_WMM_PARAM_MAXIMUM_MSDU_SIZE 6
51#define HDD_WLAN_WMM_PARAM_MINIMUM_DATA_RATE 7
52#define HDD_WLAN_WMM_PARAM_MEAN_DATA_RATE 8
53#define HDD_WLAN_WMM_PARAM_PEAK_DATA_RATE 9
54#define HDD_WLAN_WMM_PARAM_MAX_BURST_SIZE 10
55#define HDD_WLAN_WMM_PARAM_MINIMUM_PHY_RATE 11
56#define HDD_WLAN_WMM_PARAM_SURPLUS_BANDWIDTH_ALLOWANCE 12
57#define HDD_WLAN_WMM_PARAM_SERVICE_INTERVAL 13
58#define HDD_WLAN_WMM_PARAM_SUSPENSION_INTERVAL 14
59#define HDD_WLAN_WMM_PARAM_BURST_SIZE_DEFN 15
60#define HDD_WLAN_WMM_PARAM_ACK_POLICY 16
61#define HDD_WLAN_WMM_PARAM_INACTIVITY_INTERVAL 17
62#define HDD_WLAN_WMM_PARAM_MAX_SERVICE_INTERVAL 18
63#define HDD_WLAN_WMM_PARAM_COUNT 19
64
65#define MHZ 6
66
67#define WE_MAX_STR_LEN IW_PRIV_SIZE_MASK
68#define WLAN_HDD_UI_BAND_AUTO 0
69#define WLAN_HDD_UI_BAND_5_GHZ 1
70#define WLAN_HDD_UI_BAND_2_4_GHZ 2
71/* SETBAND x */
72/* 012345678 */
73#define WLAN_HDD_UI_SET_BAND_VALUE_OFFSET 8
74
75typedef enum {
76 HDD_WLAN_WMM_DIRECTION_UPSTREAM = 0,
77 HDD_WLAN_WMM_DIRECTION_DOWNSTREAM = 1,
78 HDD_WLAN_WMM_DIRECTION_BIDIRECTIONAL = 2,
79} hdd_wlan_wmm_direction_e;
80
81typedef enum {
82 HDD_WLAN_WMM_POWER_SAVE_LEGACY = 0,
83 HDD_WLAN_WMM_POWER_SAVE_UAPSD = 1,
84} hdd_wlan_wmm_power_save_e;
85
86typedef enum {
87 /* TSPEC/re-assoc done, async */
88 HDD_WLAN_WMM_STATUS_SETUP_SUCCESS = 0,
89 /* no need to setup TSPEC since ACM=0 and no UAPSD desired, sync + async */
90 HDD_WLAN_WMM_STATUS_SETUP_SUCCESS_NO_ACM_NO_UAPSD = 1,
91 /* no need to setup TSPEC since ACM=0 and UAPSD already exists, sync + async */
92 HDD_WLAN_WMM_STATUS_SETUP_SUCCESS_NO_ACM_UAPSD_EXISTING = 2,
93 /* TSPEC result pending, sync */
94 HDD_WLAN_WMM_STATUS_SETUP_PENDING = 3,
95 /* TSPEC/re-assoc failed, sync + async */
96 HDD_WLAN_WMM_STATUS_SETUP_FAILED = 4,
97 /* Request rejected due to invalid params, sync + async */
98 HDD_WLAN_WMM_STATUS_SETUP_FAILED_BAD_PARAM = 5,
99 /* TSPEC request rejected since AP!=QAP, sync */
100 HDD_WLAN_WMM_STATUS_SETUP_FAILED_NO_WMM = 6,
101
102 /* TSPEC modification/re-assoc successful, async */
103 HDD_WLAN_WMM_STATUS_MODIFY_SUCCESS = 7,
104 /* TSPEC modification a no-op since ACM=0 and no change in UAPSD, sync + async */
105 HDD_WLAN_WMM_STATUS_MODIFY_SUCCESS_NO_ACM_NO_UAPSD = 8,
106 /* TSPEC modification a no-op since ACM=0 and requested U-APSD already exists, sync + async */
107 HDD_WLAN_WMM_STATUS_MODIFY_SUCCESS_NO_ACM_UAPSD_EXISTING = 9,
108 /* TSPEC result pending, sync */
109 HDD_WLAN_WMM_STATUS_MODIFY_PENDING = 10,
110 /* TSPEC modification failed, prev TSPEC in effect, sync + async */
111 HDD_WLAN_WMM_STATUS_MODIFY_FAILED = 11,
112 /* TSPEC modification request rejected due to invalid params, sync + async */
113 HDD_WLAN_WMM_STATUS_MODIFY_FAILED_BAD_PARAM = 12,
114
115 /* TSPEC release successful, sync and also async */
116 HDD_WLAN_WMM_STATUS_RELEASE_SUCCESS = 13,
117 /* TSPEC release pending, sync */
118 HDD_WLAN_WMM_STATUS_RELEASE_PENDING = 14,
119 /* TSPEC release failed, sync + async */
120 HDD_WLAN_WMM_STATUS_RELEASE_FAILED = 15,
121 /* TSPEC release rejected due to invalid params, sync */
122 HDD_WLAN_WMM_STATUS_RELEASE_FAILED_BAD_PARAM = 16,
123 /* TSPEC modified due to the mux'ing of requests on ACs, async */
124
125 HDD_WLAN_WMM_STATUS_MODIFIED = 17,
126 /* TSPEC revoked by AP, async */
127 HDD_WLAN_WMM_STATUS_LOST = 18,
128 /* some internal failure like memory allocation failure, etc, sync */
129 HDD_WLAN_WMM_STATUS_INTERNAL_FAILURE = 19,
130
131 /* U-APSD failed during setup but OTA setup (whether TSPEC exchnage or */
132 /* re-assoc) was done so app should release this QoS, async */
133 HDD_WLAN_WMM_STATUS_SETUP_UAPSD_SET_FAILED = 20,
134 /* U-APSD failed during modify, but OTA setup (whether TSPEC exchnage or */
135 /* re-assoc) was done so app should release this QoS, async */
136 HDD_WLAN_WMM_STATUS_MODIFY_UAPSD_SET_FAILED = 21
137} hdd_wlan_wmm_status_e;
138
139/** TS Info Ack Policy */
140typedef enum {
141 HDD_WLAN_WMM_TS_INFO_ACK_POLICY_NORMAL_ACK = 0,
142 HDD_WLAN_WMM_TS_INFO_ACK_POLICY_HT_IMMEDIATE_BLOCK_ACK = 1,
143} hdd_wlan_wmm_ts_info_ack_policy_e;
144
145/** Maximum Length of WPA/RSN IE */
146#define MAX_WPA_RSN_IE_LEN 40
147
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800148/** Enable 11d */
149#define ENABLE_11D 1
150
151/** Disable 11d */
152#define DISABLE_11D 0
153
154/*
Jeff Johnson46106882017-01-12 10:39:26 -0800155 * refer wpa.h in wpa supplicant code for REASON_MICHAEL_MIC_FAILURE.
156 * supplicant sets REASON_MICHAEL_MIC_FAILURE as the reason code when
157 * it sends the MLME deauth IOCTL for TKIP counter measures
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800158 */
159#define HDD_REASON_MICHAEL_MIC_FAILURE 14
160
161/*
162 * These are for TLV fields in WPS IE
163 */
164#define HDD_WPS_UUID_LEN 16
165#define HDD_WPS_ELEM_VERSION 0x104a
166#define HDD_WPS_ELEM_REQUEST_TYPE 0x103a
167#define HDD_WPS_ELEM_CONFIG_METHODS 0x1008
168#define HDD_WPS_ELEM_UUID_E 0x1047
169#define HDD_WPS_ELEM_PRIMARY_DEVICE_TYPE 0x1054
170#define HDD_WPS_ELEM_RF_BANDS 0x103c
171#define HDD_WPS_ELEM_ASSOCIATION_STATE 0x1002
172#define HDD_WPS_ELEM_CONFIGURATION_ERROR 0x1009
173#define HDD_WPS_ELEM_DEVICE_PASSWORD_ID 0x1012
174
175#define HDD_WPA_ELEM_VENDOR_EXTENSION 0x1049
176
177#define HDD_WPS_MANUFACTURER_LEN 64
178#define HDD_WPS_MODEL_NAME_LEN 32
179#define HDD_WPS_MODEL_NUM_LEN 32
180#define HDD_WPS_SERIAL_NUM_LEN 32
181#define HDD_WPS_DEVICE_OUI_LEN 4
182#define HDD_WPS_DEVICE_NAME_LEN 32
183
184#define HDD_WPS_ELEM_WPS_STATE 0x1044
185#define HDD_WPS_ELEM_APSETUPLOCK 0x1057
186#define HDD_WPS_ELEM_SELECTEDREGISTRA 0x1041
187#define HDD_WPS_ELEM_RSP_TYPE 0x103B
188#define HDD_WPS_ELEM_MANUFACTURER 0x1021
189#define HDD_WPS_ELEM_MODEL_NAME 0x1023
190#define HDD_WPS_ELEM_MODEL_NUM 0x1024
191#define HDD_WPS_ELEM_SERIAL_NUM 0x1042
192#define HDD_WPS_ELEM_DEVICE_NAME 0x1011
193#define HDD_WPS_ELEM_REGISTRA_CONF_METHODS 0x1053
194
195#define HDD_RTSCTS_EN_MASK 0xF
196#define HDD_RTSCTS_ENABLE 1
197#define HDD_CTS_ENABLE 2
198
199#define WPS_OUI_TYPE "\x00\x50\xf2\x04"
200#define WPS_OUI_TYPE_SIZE 4
201
202#define SS_OUI_TYPE "\x00\x16\x32"
203#define SS_OUI_TYPE_SIZE 3
204
205#define P2P_OUI_TYPE "\x50\x6f\x9a\x09"
206#define P2P_OUI_TYPE_SIZE 4
207
208#define HS20_OUI_TYPE "\x50\x6f\x9a\x10"
209#define HS20_OUI_TYPE_SIZE 4
210
211#define OSEN_OUI_TYPE "\x50\x6f\x9a\x12"
212#define OSEN_OUI_TYPE_SIZE 4
213
214#ifdef WLAN_FEATURE_WFD
215#define WFD_OUI_TYPE "\x50\x6f\x9a\x0a"
216#define WFD_OUI_TYPE_SIZE 4
217#endif
218
Selvaraj, Sridhara7fc7632016-09-04 13:13:38 +0530219#define MBO_OUI_TYPE "\x50\x6f\x9a\x16"
220#define MBO_OUI_TYPE_SIZE 4
221
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800222typedef enum {
223 eWEXT_WPS_OFF = 0,
224 eWEXT_WPS_ON = 1,
225} hdd_wps_mode_e;
226
227/*
228 * This structure contains the interface level (granularity)
229 * configuration information in support of wireless extensions.
230 */
231typedef struct hdd_wext_state_s {
232 /** The CSR "desired" Profile */
233 tCsrRoamProfile roamProfile;
234
235 /** BSSID to which connect request is received */
Anurag Chouhan6d760662016-02-20 16:05:43 +0530236 struct qdf_mac_addr req_bssId;
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800237
238 /** The association status code */
239 uint32_t statusCode;
240
241 /** wpa version WPA/WPA2/None*/
242 int32_t wpaVersion;
243
244 /**WPA or RSN IE*/
245 uint8_t WPARSNIE[MAX_WPA_RSN_IE_LEN];
246
247 /**gen IE */
248 tSirAddie genIE;
249
250 /**Additional IE for assoc */
251 tSirAddie assocAddIE;
252
253 /**auth key mgmt */
254 int32_t authKeyMgmt;
255
Anurag Chouhanf04e84f2016-03-03 10:12:12 +0530256 /* qdf event */
257 qdf_event_t hdd_qdf_event;
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800258
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800259 /**Counter measure state, Started/Stopped*/
260 bool mTKIPCounterMeasures;
261
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800262#ifdef FEATURE_WLAN_ESE
263 /* ESE state variables */
264 bool isESEConnection;
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800265#endif
266} hdd_wext_state_t;
267
268typedef struct ccp_freq_chan_map_s {
269 /* List of frequencies */
270 uint32_t freq;
271 uint32_t chan;
272} hdd_freq_chan_map_t;
273
274/* Packet Types. */
275#define WLAN_KEEP_ALIVE_UNSOLICIT_ARP_RSP 2
276#define WLAN_KEEP_ALIVE_NULL_PKT 1
277
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800278#define wlan_hdd_get_wps_ie_ptr(ie, ie_len) \
279 wlan_hdd_get_vendor_oui_ie_ptr(WPS_OUI_TYPE, WPS_OUI_TYPE_SIZE, ie, ie_len)
280
281#define wlan_hdd_get_p2p_ie_ptr(ie, ie_len) \
282 wlan_hdd_get_vendor_oui_ie_ptr(P2P_OUI_TYPE, P2P_OUI_TYPE_SIZE, ie, ie_len)
283
284#ifdef WLAN_FEATURE_WFD
285#define wlan_hdd_get_wfd_ie_ptr(ie, ie_len) \
286 wlan_hdd_get_vendor_oui_ie_ptr(WFD_OUI_TYPE, WFD_OUI_TYPE_SIZE, ie, ie_len)
287#endif
288
Selvaraj, Sridhar4ea106e2016-08-05 20:34:46 +0530289#define wlan_hdd_get_mbo_ie_ptr(ie, ie_len) \
290 wlan_hdd_get_vendor_oui_ie_ptr(MBO_OUI_TYPE, MBO_OUI_TYPE_SIZE, ie, ie_len)
Anurag Chouhanbf5e0e22016-09-12 12:54:09 +0530291/*
292 * Defines for fw_test command
293 */
294#define HDD_FWTEST_PARAMS 3
295#define HDD_FWTEST_SU_PARAM_ID 53
296#define HDD_FWTEST_MU_PARAM_ID 2
297#define HDD_FWTEST_SU_DEFAULT_VALUE 100
298#define HDD_FWTEST_MU_DEFAULT_VALUE 40
299#define HDD_FWTEST_MAX_VALUE 500
300
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800301extern int hdd_unregister_wext(struct net_device *dev);
302extern int hdd_register_wext(struct net_device *dev);
303extern int hdd_wlan_get_freq(uint32_t chan, uint32_t *freq);
Mohit Khanna3e2115b2016-10-11 13:18:29 -0700304extern void hdd_display_stats_help(void);
Arun Khandavallia96c2c02016-05-17 19:15:34 +0530305extern void hdd_wlan_get_version(hdd_context_t *hdd_ctx,
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800306 union iwreq_data *wrqu, char *extra);
307
308extern void hdd_wlan_get_stats(hdd_adapter_t *pAdapter, uint16_t *length,
309 char *buffer, uint16_t buf_len);
Govind Singha471e5e2015-10-12 17:11:14 +0530310extern void hdd_wlan_list_fw_profile(uint16_t *length,
311 char *buffer, uint16_t buf_len);
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800312
Jeff Johnson5b907622017-02-07 10:00:37 -0800313int iw_get_rts_threshold(struct net_device *dev,
314 struct iw_request_info *info,
315 union iwreq_data *wrqu, char *extra);
316
317int iw_get_frag_threshold(struct net_device *dev,
318 struct iw_request_info *info,
319 union iwreq_data *wrqu, char *extra);
320
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800321extern int iw_set_essid(struct net_device *dev,
322 struct iw_request_info *info,
323 union iwreq_data *wrqu, char *extra);
324
325extern int iw_get_essid(struct net_device *dev,
326 struct iw_request_info *info,
327 struct iw_point *dwrq, char *extra);
328
329extern int iw_set_ap_address(struct net_device *dev,
330 struct iw_request_info *info,
331 union iwreq_data *wrqu, char *extra);
332
333extern int iw_get_ap_address(struct net_device *dev,
334 struct iw_request_info *info,
335 union iwreq_data *wrqu, char *extra);
336
337extern int iw_set_auth(struct net_device *dev, struct iw_request_info *info,
338 union iwreq_data *wrqu, char *extra);
339
340extern int iw_get_auth(struct net_device *dev, struct iw_request_info *info,
341 union iwreq_data *wrqu, char *extra);
342
343extern int iw_set_var_ints_getnone(struct net_device *dev,
344 struct iw_request_info *info,
345 union iwreq_data *wrqu, char *extra);
346
347extern int iw_set_three_ints_getnone(struct net_device *dev,
348 struct iw_request_info *info,
349 union iwreq_data *wrqu, char *extra);
350
351extern int hdd_priv_get_data(struct iw_point *p_priv_data,
352 union iwreq_data *wrqu);
353
354extern void *mem_alloc_copy_from_user_helper(const void *wrqu_data, size_t len);
355
Jeff Johnsone50427c2017-01-26 10:54:49 -0800356/**
357 * wlan_hdd_get_linkspeed_for_peermac() - Get link speed for a peer
358 * @adapter: adapter upon which the peer is active
359 * @mac_address: MAC address of the peer
360 * @linkspeed: pointer to memory where returned link speed is to be placed
361 *
362 * This function will send a query to SME for the linkspeed of the
363 * given peer, and then wait for the callback to be invoked.
364 *
365 * Return: 0 if linkspeed data is available, negative errno otherwise
366 */
367int wlan_hdd_get_linkspeed_for_peermac(hdd_adapter_t *adapter,
368 struct qdf_mac_addr *mac_address,
369 uint32_t *linkspeed);
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800370void hdd_clear_roam_profile_ie(hdd_adapter_t *pAdapter);
371
372uint8_t *wlan_hdd_get_vendor_oui_ie_ptr(uint8_t *oui, uint8_t oui_size,
373 uint8_t *ie, int ie_len);
374
Anurag Chouhanfb54ab02016-02-18 18:00:46 +0530375QDF_STATUS wlan_hdd_get_class_astats(hdd_adapter_t *pAdapter);
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800376
Anurag Chouhanfb54ab02016-02-18 18:00:46 +0530377QDF_STATUS wlan_hdd_get_station_stats(hdd_adapter_t *pAdapter);
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800378
Anurag Chouhanfb54ab02016-02-18 18:00:46 +0530379QDF_STATUS wlan_hdd_get_rssi(hdd_adapter_t *pAdapter, int8_t *rssi_value);
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800380
Anurag Chouhanfb54ab02016-02-18 18:00:46 +0530381QDF_STATUS wlan_hdd_get_snr(hdd_adapter_t *pAdapter, int8_t *snr);
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800382
Manjeet Singhe80d6d82016-09-02 19:04:41 +0530383int hdd_get_ldpc(hdd_adapter_t *adapter, int *value);
384int hdd_set_ldpc(hdd_adapter_t *adapter, int value);
385int hdd_get_tx_stbc(hdd_adapter_t *adapter, int *value);
386int hdd_set_tx_stbc(hdd_adapter_t *adapter, int value);
387int hdd_get_rx_stbc(hdd_adapter_t *adapter, int *value);
388int hdd_set_rx_stbc(hdd_adapter_t *adapter, int value);
389
Krishna Kumaar Natarajan9e5339d2016-12-05 14:12:13 -0800390/**
391 * hdd_assemble_rate_code() - assemble rate code to be sent to FW
392 * @preamble: rate preamble
393 * @nss: number of streams
394 * @rate: rate index
395 *
396 * Rate code assembling is different for targets which are 11ax capable.
397 * Check for the target support and assemble the rate code accordingly.
398 *
399 * Return: assembled rate code
400 */
401int hdd_assemble_rate_code(uint8_t preamble, uint8_t nss, uint8_t rate);
402
403/**
404 * hdd_set_11ax_rate() - set 11ax rate
405 * @adapter: adapter being modified
406 * @value: new 11ax rate code
407 * @sap_config: pointer to SAP config to check HW mode
408 * this will be NULL for call from STA persona
409 *
410 * Return: 0 on success, negative errno on failure
411 */
412int hdd_set_11ax_rate(hdd_adapter_t *adapter, int value,
413 struct sap_Config *sap_config);
414
Krishna Kumaar Natarajanf1581df2017-02-21 13:42:08 -0800415/**
416 * hdd_set_peer_rate() - set peer rate
417 * @adapter: adapter being modified
418 * @value: rate code with AID
419 *
420 * Return: 0 on success, negative errno on failure
421 */
422int hdd_set_peer_rate(hdd_adapter_t *adapter, int value);
423
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800424void wlan_hdd_change_country_code_callback(void *pAdapter);
425
426int hdd_set_band(struct net_device *dev, u8 ui_band);
427int hdd_set_band_helper(struct net_device *dev, const char *command);
428int wlan_hdd_update_phymode(struct net_device *net, tHalHandle hal,
429 int new_phymode, hdd_context_t *phddctx);
430
431int wlan_hdd_get_temperature(hdd_adapter_t *pAdapter, int *temperature);
432int wlan_hdd_get_link_speed(hdd_adapter_t *sta_adapter, uint32_t *link_speed);
Jeff Johnson441e1f72017-02-07 08:50:49 -0800433
434struct iw_request_info;
435/**
436 * hdd_check_standard_wext_control() - Check to see if standard
437 * wireless extensions ioctls are allowed
438 * @hdd_ctx: Global HDD context
439 * @info: Wireless extensions ioctl information passed by the kernel
440 *
441 * This function will examine the "standard_wext_control" configuration
442 * item to determine whether or not standard wireless extensions ioctls
443 * are allowed.
444 *
445 * Return: 0 if the ioctl is allowed to be processed, -ENOTSUPP if the
446 * ioctls have been disabled. Note that in addition to returning
447 * status, this function will log a message if the ioctls are disabled
448 * or deprecated.
449 */
450int hdd_check_standard_wext_control(struct hdd_context_s *hdd_ctx,
451 struct iw_request_info *info);
452
453/**
454 * hdd_check_private_wext_control() - Check to see if private
455 * wireless extensions ioctls are allowed
456 * @hdd_ctx: Global HDD context
457 * @info: Wireless extensions ioctl information passed by the kernel
458 *
459 * This function will examine the "private_wext_control" configuration
460 * item to determine whether or not private wireless extensions ioctls
461 * are allowed.
462 *
463 * Return: 0 if the ioctl is allowed to be processed, -ENOTSUPP if the
464 * ioctls have been disabled. Note that in addition to returning
465 * status, this function will log a message if the ioctls are disabled
466 * or deprecated.
467 */
468int hdd_check_private_wext_control(struct hdd_context_s *hdd_ctx,
469 struct iw_request_info *info);
470
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800471#endif /* __WEXT_IW_H__ */