1 /*
2 * Copyright (c) 2014-2016, 2018 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 _OL_FW_H_
20 #define _OL_FW_H_
21
22 #include "qdf_types.h"
23 #include "hif.h"
24 #include "hif_hw_version.h"
25 #include "bmi.h"
26
27 #define AR6320_REV2_VERSION AR6320_REV1_1_VERSION
28 #define AR6320_REV4_VERSION AR6320_REV2_1_VERSION
29 #define SIGN_HEADER_MAGIC 0x454D4F52
30 #define HI_ACS_FLAGS_SDIO_SWAP_MAILBOX_SET (1 << 0)
31 #define HI_ACS_FLAGS_SDIO_REDUCE_TX_COMPL_SET (1 << 1)
32 #define HI_ACS_FLAGS_ALT_DATA_CREDIT_SIZE (1 << 2)
33
34 #define HI_ACS_FLAGS_SDIO_SWAP_MAILBOX_FW_ACK (1 << 16)
35 #define HI_ACS_FLAGS_SDIO_REDUCE_TX_COMPL_FW_ACK (1 << 17)
36
37 #ifdef WLAN_FEATURE_BMI
38 void ol_target_failure(void *instance, QDF_STATUS status);
39
40 void ol_target_ready(struct hif_opaque_softc *scn, void *cfg_ctx);
41 QDF_STATUS ol_extra_initialization(struct ol_context *ol_ctx);
42 #else /* WLAN_FEATURE_BMI */
ol_target_failure(void * instance,QDF_STATUS status)43 static inline void ol_target_failure(void *instance, QDF_STATUS status) {}
44 #endif /* WLAN_FEATURE_BMI */
45 #endif /* _OL_FW_H_ */
46