qcacmn: WMI registration change to support to WIN modularization

Change WMI initialization sequence to support WMI modularization.
TLV and Non-TLV modules calls WMI module registration based on target type.
WMI attach will call respective attach routines based on registration.

Change-Id: Id56446f491d129758537913d2d5d6633f8dec918
CRs-Fixed: 2179854
This commit is contained in:
Pratik Gandhi
2018-01-30 19:05:41 +05:30
committed by Gerrit - the friendly Code Review server
parent 3f5d65a1ab
commit 073fa004f8
2 changed files with 17 additions and 4 deletions

View File

@@ -1542,6 +1542,17 @@ QDF_STATUS (*send_offload_11k_cmd)(wmi_unified_t wmi_handle,
QDF_STATUS (*send_invoke_neighbor_report_cmd)(wmi_unified_t wmi_handle,
struct wmi_invoke_neighbor_report_params *params);
void (*wmi_pdev_id_conversion_enable)(wmi_unified_t wmi_handle);
void (*wmi_free_allocated_event)(A_UINT32 cmd_event_id,
void **wmi_cmd_struct_ptr);
int (*wmi_check_and_pad_event)(void *os_handle, void *param_struc_ptr,
A_UINT32 param_buf_len,
A_UINT32 wmi_cmd_event_id,
void **wmi_cmd_struct_ptr);
int (*wmi_check_command_params)(void *os_handle, void *param_struc_ptr,
A_UINT32 param_buf_len,
A_UINT32 wmi_cmd_event_id);
};
/* Forward declartion for psoc*/
@@ -1652,15 +1663,16 @@ struct wmi_soc {
};
void wmi_unified_register_module(enum wmi_target_type target_type,
void (*wmi_attach)(wmi_unified_t wmi_handle));
void wmi_tlv_init(void);
void wmi_non_tlv_init(void);
#ifdef WMI_NON_TLV_SUPPORT
/* ONLY_NON_TLV_TARGET:TLV attach dummy function defintion for case when
* driver supports only NON-TLV target (WIN mainline) */
#define wmi_tlv_attach(x) qdf_print("TLV Unavailable\n")
#define wmi_tlv_pdev_id_conversion_enable(wmi_hdl) \
qdf_print("PDEV conversion Not Available")
#else
void wmi_tlv_attach(wmi_unified_t wmi_handle);
void wmi_tlv_pdev_id_conversion_enable(wmi_unified_t wmi_handle);
#endif
void wmi_non_tlv_attach(wmi_unified_t wmi_handle);