xref: /wlan-dirver/qca-wifi-host-cmn/hif/src/ipcie/hif_io32_ipci.h (revision 44e048386b4452f77a38c2b7485d114f29dfeff3)
1 /*
2  * Copyright (c) 2020 The Linux Foundation. All rights reserved.
3  *
4  * Permission to use, copy, modify, and/or distribute this software for any
5  * purpose with or without fee is hereby granted, provided that the above
6  * copyright notice and this permission notice appear in all copies.
7 
8  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15  */
16 
17 #ifndef __HIF_IO32_IPCI_H__
18 #define __HIF_IO32_IPCI_H__
19 
20 #ifdef HIF_IPCI
21 
22 #include "hif_main.h"
23 #include "regtable.h"
24 #include "ce_reg.h"
25 #include "qdf_atomic.h"
26 #include "if_ipci.h"
27 /*
28  * For maximum performance and no power management, set this to 1.
29  * For power management at the cost of performance, set this to 0.
30  */
31 #ifndef CONFIG_ATH_IPCIE_MAX_PERF
32 #define CONFIG_ATH_IPCIE_MAX_PERF 0
33 #endif
34 
35 /*
36  * PCIE_ACCESS_LOG_NUM specifies the number of
37  * read/write records to store
38  */
39 #ifdef CONFIG_ATH_IPCIE_ACCESS_DEBUG
40 #define IPCIE_ACCESS_LOG_NUM 500
41 #endif
42 
43 /* 64-bit MSI support */
44 #define CONFIG_IPCIE_64BIT_MSI 0
45 
46 /* AXI gating when L1, L2 to reduce power consumption */
47 #define CONFIG_IPCIE_ENABLE_AXI_CLK_GATE 0
48 
49 irqreturn_t hif_fw_interrupt_handler(int irq, void *arg);
50 #endif /* HIF_IPCI */
51 #endif /* __HIF_IO32_IPCI_H__ */
52