#include <linux/elf.h>
#include "qmi.h"
#include "core.h"
#include "debug.h"
#include <linux/of.h>
#include <linux/firmware.h>
#define SLEEP_CLOCK_SELECT_INTERNAL_BIT …
#define HOST_CSTATE_BIT …
#define PLATFORM_CAP_PCIE_GLOBAL_RESET …
#define ATH12K_QMI_MAX_CHUNK_SIZE …
static const struct qmi_elem_info wlfw_host_mlo_chip_info_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_host_cap_req_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_host_cap_resp_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_phy_cap_req_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_phy_cap_resp_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_ind_register_req_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_ind_register_resp_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_mem_cfg_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_mem_seg_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_request_mem_ind_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_mem_seg_resp_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_respond_mem_req_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_respond_mem_resp_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_cap_req_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_rf_chip_info_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_rf_board_info_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_soc_info_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_dev_mem_info_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_fw_version_info_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_cap_resp_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_bdf_download_req_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_bdf_download_resp_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_m3_info_req_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_m3_info_resp_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_ce_tgt_pipe_cfg_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_ce_svc_pipe_cfg_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_shadow_reg_cfg_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_shadow_reg_v3_cfg_s_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_wlan_mode_req_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_wlan_mode_resp_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_wlan_cfg_req_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_wlan_cfg_resp_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_mem_ready_ind_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_fw_ready_ind_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_wlan_ini_req_msg_v01_ei[] = …;
static const struct qmi_elem_info qmi_wlanfw_wlan_ini_resp_msg_v01_ei[] = …;
static void ath12k_host_cap_parse_mlo(struct ath12k_base *ab,
struct qmi_wlanfw_host_cap_req_msg_v01 *req)
{ … }
static int ath12k_qmi_host_cap_send(struct ath12k_base *ab)
{ … }
static void ath12k_qmi_phy_cap_send(struct ath12k_base *ab)
{ … }
static int ath12k_qmi_fw_ind_register_send(struct ath12k_base *ab)
{ … }
static int ath12k_qmi_respond_fw_mem_request(struct ath12k_base *ab)
{ … }
static void ath12k_qmi_free_target_mem_chunk(struct ath12k_base *ab)
{ … }
static int ath12k_qmi_alloc_target_mem_chunk(struct ath12k_base *ab)
{ … }
static int ath12k_qmi_request_target_cap(struct ath12k_base *ab)
{ … }
static int ath12k_qmi_load_file_target_mem(struct ath12k_base *ab,
const u8 *data, u32 len, u8 type)
{ … }
static int ath12k_qmi_load_bdf_qmi(struct ath12k_base *ab,
enum ath12k_qmi_bdf_type type)
{ … }
static void ath12k_qmi_m3_free(struct ath12k_base *ab)
{ … }
static int ath12k_qmi_m3_load(struct ath12k_base *ab)
{ … }
static int ath12k_qmi_wlanfw_m3_info_send(struct ath12k_base *ab)
{ … }
static int ath12k_qmi_wlanfw_mode_send(struct ath12k_base *ab,
u32 mode)
{ … }
static int ath12k_qmi_wlanfw_wlan_cfg_send(struct ath12k_base *ab)
{ … }
static int ath12k_qmi_wlanfw_wlan_ini_send(struct ath12k_base *ab)
{ … }
void ath12k_qmi_firmware_stop(struct ath12k_base *ab)
{ … }
int ath12k_qmi_firmware_start(struct ath12k_base *ab,
u32 mode)
{ … }
static int
ath12k_qmi_driver_event_post(struct ath12k_qmi *qmi,
enum ath12k_qmi_event_type type,
void *data)
{ … }
static int ath12k_qmi_event_server_arrive(struct ath12k_qmi *qmi)
{ … }
static int ath12k_qmi_event_mem_request(struct ath12k_qmi *qmi)
{ … }
static int ath12k_qmi_event_load_bdf(struct ath12k_qmi *qmi)
{ … }
static void ath12k_qmi_msg_mem_request_cb(struct qmi_handle *qmi_hdl,
struct sockaddr_qrtr *sq,
struct qmi_txn *txn,
const void *data)
{ … }
static void ath12k_qmi_msg_mem_ready_cb(struct qmi_handle *qmi_hdl,
struct sockaddr_qrtr *sq,
struct qmi_txn *txn,
const void *decoded)
{ … }
static void ath12k_qmi_msg_fw_ready_cb(struct qmi_handle *qmi_hdl,
struct sockaddr_qrtr *sq,
struct qmi_txn *txn,
const void *decoded)
{ … }
static const struct qmi_msg_handler ath12k_qmi_msg_handlers[] = …;
static int ath12k_qmi_ops_new_server(struct qmi_handle *qmi_hdl,
struct qmi_service *service)
{ … }
static void ath12k_qmi_ops_del_server(struct qmi_handle *qmi_hdl,
struct qmi_service *service)
{ … }
static const struct qmi_ops ath12k_qmi_ops = …;
static void ath12k_qmi_driver_event_work(struct work_struct *work)
{ … }
int ath12k_qmi_init_service(struct ath12k_base *ab)
{ … }
void ath12k_qmi_deinit_service(struct ath12k_base *ab)
{ … }
void ath12k_qmi_free_resource(struct ath12k_base *ab)
{ … }