diff options
| -rw-r--r-- | core/wma/src/wma_mgmt.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/core/wma/src/wma_mgmt.c b/core/wma/src/wma_mgmt.c index 3a92298b1973..e6d40b2cc2c6 100644 --- a/core/wma/src/wma_mgmt.c +++ b/core/wma/src/wma_mgmt.c @@ -3192,12 +3192,6 @@ static int wma_mgmt_rx_process(void *handle, uint8_t *data, return -EINVAL; } - rx_pkt = qdf_mem_malloc(sizeof(*rx_pkt)); - if (!rx_pkt) { - WMA_LOGE("Failed to allocate rx packet"); - return -ENOMEM; - } - if (cds_is_load_or_unload_in_progress()) { WMA_LOGW(FL("Load/Unload in progress")); return -EINVAL; @@ -3208,6 +3202,12 @@ static int wma_mgmt_rx_process(void *handle, uint8_t *data, return -EINVAL; } + rx_pkt = qdf_mem_malloc(sizeof(*rx_pkt)); + if (!rx_pkt) { + WMA_LOGE("Failed to allocate rx packet"); + return -ENOMEM; + } + qdf_mem_zero(rx_pkt, sizeof(*rx_pkt)); /* |
