Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1 | /* |
Himanshu Agarwal | edf30dc | 2017-06-05 15:54:27 +0530 | [diff] [blame] | 2 | * Copyright (c) 2013-2018 The Linux Foundation. All rights reserved. |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3 | * |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4 | * Permission to use, copy, modify, and/or distribute this software for |
| 5 | * any purpose with or without fee is hereby granted, provided that the |
| 6 | * above copyright notice and this permission notice appear in all |
| 7 | * copies. |
| 8 | * |
| 9 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL |
| 10 | * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED |
| 11 | * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE |
| 12 | * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL |
| 13 | * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR |
| 14 | * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER |
| 15 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR |
| 16 | * PERFORMANCE OF THIS SOFTWARE. |
| 17 | */ |
| 18 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 19 | #ifndef HDD_IPA_H__ |
| 20 | #define HDD_IPA_H__ |
| 21 | |
| 22 | /** |
| 23 | * DOC: wlan_hdd_ipa.h |
| 24 | * |
| 25 | * WLAN IPA interface module headers |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 26 | */ |
| 27 | |
Sravan Kumar Kairam | 858073b | 2018-03-13 09:03:32 +0530 | [diff] [blame] | 28 | #include <qdf_nbuf.h> |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 29 | |
| 30 | #ifdef IPA_OFFLOAD |
Houston Hoffman | 43d47fa | 2016-02-24 16:34:30 -0800 | [diff] [blame] | 31 | |
| 32 | /** |
Sravan Kumar Kairam | 858073b | 2018-03-13 09:03:32 +0530 | [diff] [blame] | 33 | * hdd_ipa_send_skb_to_network() - Send skb to kernel |
| 34 | * @skb: network buffer |
| 35 | * @adapter: network adapter |
| 36 | * |
| 37 | * Called when a network buffer is received which should not be routed |
| 38 | * to the IPA module. |
| 39 | * |
| 40 | * Return: None |
Prakash Dhavali | 87b38e3 | 2016-11-14 16:22:53 -0800 | [diff] [blame] | 41 | */ |
Sravan Kumar Kairam | 858073b | 2018-03-13 09:03:32 +0530 | [diff] [blame] | 42 | void hdd_ipa_send_skb_to_network(qdf_nbuf_t skb, qdf_netdev_t dev); |
Prakash Dhavali | 87b38e3 | 2016-11-14 16:22:53 -0800 | [diff] [blame] | 43 | |
| 44 | /** |
Sravan Kumar Kairam | 858073b | 2018-03-13 09:03:32 +0530 | [diff] [blame] | 45 | * hdd_ipa_set_tx_flow_info() - To set TX flow info if IPA is |
| 46 | * enabled |
Houston Hoffman | 43d47fa | 2016-02-24 16:34:30 -0800 | [diff] [blame] | 47 | * |
Sravan Kumar Kairam | 858073b | 2018-03-13 09:03:32 +0530 | [diff] [blame] | 48 | * This routine is called to set TX flow info if IPA is enabled |
| 49 | * |
| 50 | * Return: None |
Houston Hoffman | 43d47fa | 2016-02-24 16:34:30 -0800 | [diff] [blame] | 51 | */ |
Tushnim Bhattacharyya | 9e81b4c | 2017-02-15 17:11:14 -0800 | [diff] [blame] | 52 | void hdd_ipa_set_tx_flow_info(void); |
Yun Park | 4625568 | 2017-10-09 15:56:34 -0700 | [diff] [blame] | 53 | |
jiad | bb47e13 | 2018-03-30 16:28:30 +0800 | [diff] [blame] | 54 | /** |
| 55 | * hdd_ipa_set_mcc_mode() - To set mcc mode if IPA is enabled |
| 56 | * @mcc_mode: mcc mode |
| 57 | * |
| 58 | * This routine is called to set mcc mode if IPA is enabled |
| 59 | * |
| 60 | * Return: None |
| 61 | */ |
| 62 | void hdd_ipa_set_mcc_mode(bool mcc_mode); |
| 63 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 64 | #else |
Sravan Kumar Kairam | 858073b | 2018-03-13 09:03:32 +0530 | [diff] [blame] | 65 | static inline |
| 66 | void hdd_ipa_send_skb_to_network(qdf_nbuf_t skb, qdf_netdev_t dev) |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 67 | { |
Manikandan Mohan | bb8a7ee | 2017-02-09 11:26:53 -0800 | [diff] [blame] | 68 | } |
Tushnim Bhattacharyya | 9e81b4c | 2017-02-15 17:11:14 -0800 | [diff] [blame] | 69 | |
| 70 | static inline void hdd_ipa_set_tx_flow_info(void) |
| 71 | { |
Tushnim Bhattacharyya | 9e81b4c | 2017-02-15 17:11:14 -0800 | [diff] [blame] | 72 | } |
| 73 | |
jiad | bb47e13 | 2018-03-30 16:28:30 +0800 | [diff] [blame] | 74 | static inline void hdd_ipa_set_mcc_mode(bool mcc_mode) |
| 75 | { |
| 76 | } |
| 77 | |
Sravan Kumar Kairam | 858073b | 2018-03-13 09:03:32 +0530 | [diff] [blame] | 78 | #endif |
| 79 | #endif /* HDD_IPA_H__ */ |