diff --git a/wmi/inc/wmi_unified_api.h b/wmi/inc/wmi_unified_api.h index 6f54d0cc2f..af74c11241 100644 --- a/wmi/inc/wmi_unified_api.h +++ b/wmi/inc/wmi_unified_api.h @@ -123,16 +123,17 @@ typedef qdf_nbuf_t wmi_buf_t; struct wmi_soc; struct policy_mgr_dual_mac_config; /** - * struct wmi_ops - service callbacks to upper layer - * @service_ready_cbk: service ready callback - * @service_ready_ext_cbk: service ready ext callback - * @ready_cbk: ready calback + * struct wmi_rx_ops - handle to wmi rx ops + * @scn_handle: handle to scn + * @ev: event buffer + * @rx_ctx: rx execution context * @wma_process_fw_event_handler_cbk: generic event handler callback */ struct wmi_rx_ops { - int (*wma_process_fw_event_handler_cbk)(void *ctx, - void *ev, uint8_t rx_ctx); + int (*wma_process_fw_event_handler_cbk)(ol_scn_t scn_handle, + void *ev, + uint8_t rx_ctx); }; /** @@ -1581,8 +1582,19 @@ QDF_STATUS wmi_extract_smartlog_ev #endif /* OL_ATH_SMART_LOGGING */ +/** + * wmi_process_fw_event_worker_thread_ctx() - process in worker thread context + * @wmi_handle: handle to wmi + * @evt_buf: pointer to event buffer + * + * Event process by below function will be in worker thread context. + * Use this method for events which are not critical and not + * handled in protocol stack. + * + * Return: none + */ void wmi_process_fw_event_worker_thread_ctx(struct wmi_unified *wmi_handle, - HTC_PACKET * htc_packet); + void *evt_buf); /** * wmi_extract_ctl_failsafe_check_ev_param() - extract ctl failsafe diff --git a/wmi/src/wmi_unified.c b/wmi/src/wmi_unified.c index 58011552c2..e057bd4337 100644 --- a/wmi/src/wmi_unified.c +++ b/wmi/src/wmi_unified.c @@ -2001,34 +2001,15 @@ static void wmi_process_fw_event_default_ctx(struct wmi_unified *wmi_handle, wmi_buf_t evt_buf; evt_buf = (wmi_buf_t) htc_packet->pPktContext; -#ifndef CONFIG_MCL wmi_handle->rx_ops.wma_process_fw_event_handler_cbk (wmi_handle->scn_handle, evt_buf, exec_ctx); -#else - wmi_handle->rx_ops.wma_process_fw_event_handler_cbk(wmi_handle, - htc_packet, exec_ctx); -#endif return; } -/** - * wmi_process_fw_event_worker_thread_ctx() - process in worker thread context - * @wmi_handle: handle to wmi - * @htc_packet: pointer to htc packet - * - * Event process by below function will be in worker thread context. - * Use this method for events which are not critical and not - * handled in protocol stack. - * - * Return: none - */ void wmi_process_fw_event_worker_thread_ctx(struct wmi_unified *wmi_handle, - HTC_PACKET *htc_packet) + void *evt_buf) { - wmi_buf_t evt_buf; - - evt_buf = (wmi_buf_t) htc_packet->pPktContext; qdf_spin_lock_bh(&wmi_handle->eventq_lock); qdf_nbuf_queue_add(&wmi_handle->event_queue, evt_buf); @@ -2154,7 +2135,7 @@ static void wmi_control_rx(void *ctx, HTC_PACKET *htc_packet) if (exec_ctx == WMI_RX_WORK_CTX) { wmi_process_fw_event_worker_thread_ctx - (wmi_handle, htc_packet); + (wmi_handle, evt_buf); } else if (exec_ctx > WMI_RX_WORK_CTX) { wmi_process_fw_event_default_ctx (wmi_handle, htc_packet, exec_ctx);