diff options
author | Naveen Rawat <naveenrawat@codeaurora.org> | 2017-09-20 15:54:44 -0700 |
---|---|---|
committer | snandini <snandini@codeaurora.org> | 2017-09-22 06:13:00 -0700 |
commit | 0df4041620469f86dfd57b81b6796f53ebdc3778 (patch) | |
tree | 6dc5b3b012a03b68f985852d56ec68a1f4213e0a /core/wma/src/wma_mgmt.c | |
parent | f81cb683bd78b9aa81492a19f53fc3a1236b7cea (diff) | |
download | qcacld-0df4041620469f86dfd57b81b6796f53ebdc3778.tar.gz |
qcacld-3.0: Improve tx status logging for mgmt packets
Change status logging in mgmt tx completion to string format.
Change-Id: I84c99e3c928a8a5c17048f20e1d9b3e990b911ad
CRs-Fixed: 2113615
Diffstat (limited to 'core/wma/src/wma_mgmt.c')
-rw-r--r-- | core/wma/src/wma_mgmt.c | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/core/wma/src/wma_mgmt.c b/core/wma/src/wma_mgmt.c index ecf9065951..de462c4253 100644 --- a/core/wma/src/wma_mgmt.c +++ b/core/wma/src/wma_mgmt.c @@ -2673,6 +2673,25 @@ void wma_beacon_miss_handler(tp_wma_handle wma, uint32_t vdev_id, int32_t rssi) } /** + * wma_get_status_str() - get string of tx status from firmware + * @status: tx status + * + * Return: converted string of tx status + */ +static const char *wma_get_status_str(uint32_t status) +{ + switch (status) { + default: + return "unknown"; + CASE_RETURN_STRING(WMI_MGMT_TX_COMP_TYPE_COMPLETE_OK); + CASE_RETURN_STRING(WMI_MGMT_TX_COMP_TYPE_DISCARD); + CASE_RETURN_STRING(WMI_MGMT_TX_COMP_TYPE_INSPECT); + CASE_RETURN_STRING(WMI_MGMT_TX_COMP_TYPE_COMPLETE_NO_ACK); + CASE_RETURN_STRING(WMI_MGMT_TX_COMP_TYPE_MAX); + } +} + +/** * wma_process_mgmt_tx_completion() - process mgmt completion * @wma_handle: wma handle * @desc_id: descriptor id @@ -2692,7 +2711,8 @@ static int wma_process_mgmt_tx_completion(tp_wma_handle wma_handle, return -EINVAL; } - WMA_LOGD("%s: status: %d wmi_desc_id: %d", __func__, status, desc_id); + WMA_LOGD("%s: status: %s wmi_desc_id: %d", __func__, + wma_get_status_str(status), desc_id); wmi_desc = (struct wmi_desc_t *) (&wma_handle->wmi_desc_pool.array[desc_id]); |