xref: /wlan-driver/qcacld-3.0/components/pmo/dispatcher/inc/wlan_pmo_apf_cfg.h (revision 5113495b16420b49004c444715d2daae2066e7dc)
1 /*
2  * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved.
3  *
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 
19 #ifndef WLAN_PMO_APF_CFG_H__
20 #define WLAN_PMO_APF_CFG_H__
21 
22 /*
23  * <ini>
24  * gBpfFilterEnable - APF feature support configuration
25  * @Min: 0
26  * @Max: 1
27  * @Default: 1
28  *
29  * When set to 1 APF feature will be enabled.
30  *
31  * Supported Feature: Android packet filter
32  *
33  * Usage: External
34  *
35  * </ini>
36  */
37 #define CFG_PMO_APF_ENABLE CFG_INI_BOOL("gBpfFilterEnable", \
38 					1, \
39 					"Enable APF Support")
40 
41 /*
42  * <ini>
43  * gActiveUcBpfMode - Control UC active APF mode
44  * @Min: 0 (disabled)
45  * @Max: 2 (adaptive)
46  * @Default: 0 (disabled)
47  *
48  * This config item controls UC APF in active mode. There are 3 modes:
49  *	0) disabled - APF is disabled in active mode
50  *	1) enabled - APF is enabled for all packets in active mode
51  *	2) adaptive - APF is enabled for packets up to some throughput threshold
52  *
53  * Related: gActiveMcBcBpfMode
54  *
55  * Supported Feature: Active Mode APF
56  *
57  * Usage: Internal/External
58  * </ini>
59  */
60 #define CFG_ACTIVE_UC_APF_MODE CFG_INI_UINT( \
61 	"gActiveUcBpfMode", \
62 	ACTIVE_APF_DISABLED, \
63 	(ACTIVE_APF_MODE_COUNT - 1), \
64 	ACTIVE_APF_DISABLED, \
65 	CFG_VALUE_OR_DEFAULT, \
66 	"Control UC active APF mode")
67 
68 /*
69  * <ini>
70  * gActiveMcBcBpfMode - Control MC/BC active APF mode
71  * @Min: 0 (disabled)
72  * @Max: 1 (enabled)
73  * @Default: 0 (disabled)
74  *
75  * This config item controls MC/BC APF in active mode. There are 3 modes:
76  *	0) disabled - APF is disabled in active mode
77  *	1) enabled - APF is enabled for all packets in active mode
78  *	2) adaptive - APF is enabled for packets up to some throughput threshold
79  *
80  * Related: gActiveUcBpfMode
81  *
82  * Supported Feature: Active Mode APF
83  *
84  * Usage: Internal/External
85  * </ini>
86  */
87 #define CFG_ACTIVE_MC_BC_APF_MODE CFG_INI_UINT( \
88 	"gActiveMcBcBpfMode", \
89 	ACTIVE_APF_DISABLED, \
90 	ACTIVE_APF_ENABLED, \
91 	ACTIVE_APF_DISABLED, \
92 	CFG_VALUE_OR_DEFAULT, \
93 	"Control MC/BC active APF mode")
94 
95 #define CFG_PMO_APF_ALL \
96 	CFG(CFG_PMO_APF_ENABLE) \
97 	CFG(CFG_ACTIVE_UC_APF_MODE) \
98 	CFG(CFG_ACTIVE_MC_BC_APF_MODE)
99 
100 #endif /* WLAN_PMO_APF_CFG_H__ */
101