blob: c90ce90914003d27f37c6799304d6d05cd16d228 [file] [log] [blame]
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001/*
Srinivas Girigowda8711c742017-03-24 23:35:10 -07002 * Copyright (c) 2014-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#if !defined(WLAN_HDD_SOFTAP_TX_RX_H)
29#define WLAN_HDD_SOFTAP_TX_RX_H
30
31/**
32 * DOC: wlan_hdd_softap_tx_rx.h
33 *
34 *Linux HDD SOFTAP Tx/RX APIs
35 */
36
37#include <wlan_hdd_hostapd.h>
Manjunathappa Prakash3454fd62016-04-01 08:52:06 -070038#include <cdp_txrx_peer_ops.h>
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080039
40int hdd_softap_hard_start_xmit(struct sk_buff *skb,
41 struct net_device *dev);
42void hdd_softap_tx_timeout(struct net_device *dev);
Jeff Johnson18dd7e12017-08-29 14:22:28 -070043QDF_STATUS hdd_softap_init_tx_rx(struct hdd_adapter *pAdapter);
44QDF_STATUS hdd_softap_deinit_tx_rx(struct hdd_adapter *pAdapter);
45QDF_STATUS hdd_softap_init_tx_rx_sta(struct hdd_adapter *pAdapter,
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080046 uint8_t STAId,
Anurag Chouhan6d760662016-02-20 16:05:43 +053047 struct qdf_mac_addr *pmacAddrSTA);
Jeff Johnson18dd7e12017-08-29 14:22:28 -070048QDF_STATUS hdd_softap_deinit_tx_rx_sta(struct hdd_adapter *pAdapter,
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080049 uint8_t STAId);
Dhanashri Atre182b0272016-02-17 15:35:07 -080050
51QDF_STATUS hdd_softap_rx_packet_cbk(void *context, qdf_nbuf_t rxBufChain);
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080052#ifdef IPA_OFFLOAD
Anurag Chouhanfb54ab02016-02-18 18:00:46 +053053QDF_STATUS hdd_softap_rx_mul_packet_cbk(void *cds_context,
Nirav Shahcbc6d722016-03-01 16:24:53 +053054 qdf_nbuf_t rx_buf_list, uint8_t staId);
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080055#endif /* IPA_OFFLOAD */
56
Jeff Johnson18dd7e12017-08-29 14:22:28 -070057QDF_STATUS hdd_softap_deregister_sta(struct hdd_adapter *pAdapter,
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080058 uint8_t staId);
Jeff Johnson18dd7e12017-08-29 14:22:28 -070059QDF_STATUS hdd_softap_register_sta(struct hdd_adapter *pAdapter,
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080060 bool fAuthRequired,
61 bool fPrivacyBit,
62 uint8_t staId,
63 uint8_t ucastSig,
64 uint8_t bcastSig,
Anurag Chouhan6d760662016-02-20 16:05:43 +053065 struct qdf_mac_addr *pPeerMacAddress,
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080066 bool fWmmEnabled);
Jeff Johnson18dd7e12017-08-29 14:22:28 -070067QDF_STATUS hdd_softap_register_bc_sta(struct hdd_adapter *pAdapter,
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080068 bool fPrivacyBit);
Jeff Johnson18dd7e12017-08-29 14:22:28 -070069QDF_STATUS hdd_softap_deregister_bc_sta(struct hdd_adapter *pAdapter);
70QDF_STATUS hdd_softap_stop_bss(struct hdd_adapter *pHostapdAdapter);
71QDF_STATUS hdd_softap_change_sta_state(struct hdd_adapter *pAdapter,
Anurag Chouhan6d760662016-02-20 16:05:43 +053072 struct qdf_mac_addr *pDestMacAddress,
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080073 enum ol_txrx_peer_state state);
Jeff Johnson18dd7e12017-08-29 14:22:28 -070074QDF_STATUS hdd_softap_get_sta_id(struct hdd_adapter *pAdapter,
Anurag Chouhan6d760662016-02-20 16:05:43 +053075 struct qdf_mac_addr *pMacAddress,
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080076 uint8_t *staId);
77
78#ifdef QCA_LL_LEGACY_TX_FLOW_CONTROL
79void hdd_softap_tx_resume_timer_expired_handler(void *adapter_context);
80void hdd_softap_tx_resume_cb(void *adapter_context, bool tx_resume);
81#else
82static inline
83void hdd_softap_tx_resume_timer_expired_handler(void *adapter_context)
84{
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080085}
86static inline
87void hdd_softap_tx_resume_cb(void *adapter_context, bool tx_resume)
88{
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080089}
90#endif /* QCA_LL_LEGACY_TX_FLOW_CONTROL */
91
92#endif /* end #if !defined(WLAN_HDD_SOFTAP_TX_RX_H) */