From f1551cbacce6f38e5d24c307e12b0005939d040c Mon Sep 17 00:00:00 2001 From: Tiger Yu Date: Fri, 26 Oct 2018 13:11:12 +0800 Subject: [PATCH] qcacld-3.0: doing tx desc init earlier in ol_tx_hl_base Doing the tx desc initialization earlier in ol_tx_hl_base to make sure all msdu buffers have been mapped before msdu frame is freed if encouter error. Change-Id: Iefded014b4a179889e67fa7cc0e0c36e8218dd83 CRs-Fixed: 2337167 --- core/dp/txrx/ol_tx_hl.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/core/dp/txrx/ol_tx_hl.c b/core/dp/txrx/ol_tx_hl.c index 18b53dd78688..4c9e0d327425 100644 --- a/core/dp/txrx/ol_tx_hl.c +++ b/core/dp/txrx/ol_tx_hl.c @@ -589,6 +589,17 @@ ol_tx_hl_base( txq = ol_tx_classify(vdev, tx_desc, msdu, &tx_msdu_info); + /* initialize the HW tx descriptor */ + htt_tx_desc_init( + pdev->htt_pdev, tx_desc->htt_tx_desc, + tx_desc->htt_tx_desc_paddr, + ol_tx_desc_id(pdev, tx_desc), + msdu, + &tx_msdu_info.htt, + &tx_msdu_info.tso_info, + &tx_ctrl, + vdev->opmode == wlan_op_mode_ocb); + if ((!txq) || TX_FILTER_CHECK(&tx_msdu_info)) { /* drop this frame, * but try sending subsequent frames @@ -666,16 +677,6 @@ ol_tx_hl_base( &tx_msdu_info)) goto MSDU_LOOP_BOTTOM; - /* initialize the HW tx descriptor */ - htt_tx_desc_init( - pdev->htt_pdev, tx_desc->htt_tx_desc, - tx_desc->htt_tx_desc_paddr, - ol_tx_desc_id(pdev, tx_desc), - msdu, - &tx_msdu_info.htt, - &tx_msdu_info.tso_info, - &tx_ctrl, - vdev->opmode == wlan_op_mode_ocb); /* * If debug display is enabled, show the meta-data * being downloaded to the target via the