mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-14 16:46:15 -04:00
qcacld-3.0: Fix crash on WMA path
During a recent merge, a frame type was being set to a similar looking value (ol_tx_spec_no_free instead of ol_tx_frm_no_free) and this is causing crashes on tx-completion. Also capitalize the constants. This is a stability CR. Change-Id: Ic86dafc5baa80ae634c5267794f3add0e06d076f Acked-by: Orhan K AKYILDIZ <oka@qca.qualcomm.com> CRs-fixed: 1010581
This commit is contained in:
parent
d3ccca2545
commit
6dc1a9658a
4 changed files with 16 additions and 16 deletions
|
|
@ -384,10 +384,10 @@ ol_tx_prepare_ll_fast(struct ol_txrx_pdev_t *pdev,
|
|||
tx_desc->netbuf = msdu;
|
||||
if (msdu_info->tso_info.is_tso) {
|
||||
tx_desc->tso_desc = msdu_info->tso_info.curr_seg;
|
||||
tx_desc->pkt_type = ol_tx_frm_tso;
|
||||
tx_desc->pkt_type = OL_TX_FRM_TSO;
|
||||
TXRX_STATS_MSDU_INCR(pdev, tx.tso.tso_pkts, msdu);
|
||||
} else {
|
||||
tx_desc->pkt_type = ol_tx_frm_std;
|
||||
tx_desc->pkt_type = OL_TX_FRM_STD;
|
||||
}
|
||||
|
||||
htt_tx_desc = tx_desc->htt_tx_desc;
|
||||
|
|
@ -1049,9 +1049,9 @@ ol_tx_non_std_ll(ol_txrx_vdev_handle vdev,
|
|||
|
||||
if (tx_spec != OL_TX_SPEC_STD) {
|
||||
if (tx_spec & OL_TX_SPEC_NO_FREE) {
|
||||
tx_desc->pkt_type = OL_TX_SPEC_NO_FREE;
|
||||
tx_desc->pkt_type = OL_TX_FRM_NO_FREE;
|
||||
} else if (tx_spec & OL_TX_SPEC_TSO) {
|
||||
tx_desc->pkt_type = OL_TX_SPEC_TSO;
|
||||
tx_desc->pkt_type = OL_TX_FRM_TSO;
|
||||
} else if (tx_spec & OL_TX_SPEC_NWIFI_NO_ENCRYPT) {
|
||||
uint8_t sub_type =
|
||||
ol_txrx_tx_raw_subtype(tx_spec);
|
||||
|
|
|
|||
|
|
@ -230,7 +230,7 @@ void ol_tx_desc_free(struct ol_txrx_pdev_t *pdev, struct ol_tx_desc_t *tx_desc)
|
|||
{
|
||||
qdf_spin_lock_bh(&pdev->tx_mutex);
|
||||
|
||||
if (tx_desc->pkt_type == ol_tx_frm_tso) {
|
||||
if (tx_desc->pkt_type == OL_TX_FRM_TSO) {
|
||||
if (qdf_unlikely(tx_desc->tso_desc == NULL)) {
|
||||
qdf_print("%s %d TSO desc is NULL!\n",
|
||||
__func__, __LINE__);
|
||||
|
|
@ -259,7 +259,7 @@ void ol_tx_desc_free(struct ol_txrx_pdev_t *pdev, struct ol_tx_desc_t *tx_desc)
|
|||
struct ol_tx_flow_pool_t *pool = tx_desc->pool;
|
||||
|
||||
#if defined(FEATURE_TSO)
|
||||
if (tx_desc->pkt_type == ol_tx_frm_tso) {
|
||||
if (tx_desc->pkt_type == OL_TX_FRM_TSO) {
|
||||
if (qdf_unlikely(tx_desc->tso_desc == NULL))
|
||||
qdf_print("%s %d TSO desc is NULL!\n",
|
||||
__func__, __LINE__);
|
||||
|
|
@ -359,10 +359,10 @@ struct ol_tx_desc_t *ol_tx_desc_ll(struct ol_txrx_pdev_t *pdev,
|
|||
|
||||
if (msdu_info->tso_info.is_tso) {
|
||||
tx_desc->tso_desc = msdu_info->tso_info.curr_seg;
|
||||
tx_desc->pkt_type = ol_tx_frm_tso;
|
||||
tx_desc->pkt_type = OL_TX_FRM_TSO;
|
||||
TXRX_STATS_MSDU_INCR(pdev, tx.tso.tso_pkts, netbuf);
|
||||
} else {
|
||||
tx_desc->pkt_type = ol_tx_frm_std;
|
||||
tx_desc->pkt_type = OL_TX_FRM_STD;
|
||||
}
|
||||
|
||||
/* initialize the HW tx descriptor */
|
||||
|
|
@ -472,7 +472,7 @@ void ol_tx_desc_frame_free_nonstd(struct ol_txrx_pdev_t *pdev,
|
|||
#endif
|
||||
trace_str = (had_error) ? "OT:C:F:" : "OT:C:S:";
|
||||
qdf_nbuf_trace_update(tx_desc->netbuf, trace_str);
|
||||
if (tx_desc->pkt_type == ol_tx_frm_no_free) {
|
||||
if (tx_desc->pkt_type == OL_TX_FRM_NO_FREE) {
|
||||
/* free the tx desc but don't unmap or free the frame */
|
||||
if (pdev->tx_data_callback.func) {
|
||||
qdf_nbuf_set_next(tx_desc->netbuf, NULL);
|
||||
|
|
|
|||
|
|
@ -311,7 +311,7 @@ ol_tx_download_done_hl_free(void *txrx_pdev,
|
|||
|
||||
ol_tx_download_done_base(pdev, status, msdu, msdu_id);
|
||||
|
||||
if ((tx_desc->pkt_type != ol_tx_frm_no_free) &&
|
||||
if ((tx_desc->pkt_type != OL_TX_FRM_NO_FREE) &&
|
||||
(tx_desc->pkt_type < OL_TXRX_MGMT_TYPE_BASE)) {
|
||||
qdf_atomic_add(1, &pdev->tx_queue.rsrc_cnt);
|
||||
ol_tx_desc_frame_free_nonstd(pdev, tx_desc, status != A_OK);
|
||||
|
|
@ -406,7 +406,7 @@ ol_tx_delay_compute(struct ol_txrx_pdev_t *pdev,
|
|||
_netbuf, _lcl_freelist, \
|
||||
_tx_desc_last, _status) \
|
||||
do { \
|
||||
if (qdf_likely((_tx_desc)->pkt_type == ol_tx_frm_std)) { \
|
||||
if (qdf_likely((_tx_desc)->pkt_type == OL_TX_FRM_STD)) { \
|
||||
ol_tx_msdu_complete_single((_pdev), (_tx_desc),\
|
||||
(_netbuf), (_lcl_freelist), \
|
||||
(_tx_desc_last)); \
|
||||
|
|
@ -428,7 +428,7 @@ ol_tx_delay_compute(struct ol_txrx_pdev_t *pdev,
|
|||
_netbuf, _lcl_freelist, \
|
||||
_tx_desc_last, _status) \
|
||||
do { \
|
||||
if (qdf_likely((_tx_desc)->pkt_type == ol_tx_frm_std)) { \
|
||||
if (qdf_likely((_tx_desc)->pkt_type == OL_TX_FRM_STD)) { \
|
||||
ol_tx_msdu_complete_batch((_pdev), (_tx_desc), \
|
||||
(_tx_descs), (_status)); \
|
||||
} else { \
|
||||
|
|
|
|||
|
|
@ -117,10 +117,10 @@ struct privacy_exemption {
|
|||
};
|
||||
|
||||
enum ol_tx_frm_type {
|
||||
ol_tx_frm_std = 0, /* regular frame - no added header fragments */
|
||||
ol_tx_frm_tso, /* TSO segment, with a modified IP header added */
|
||||
ol_tx_frm_audio, /* audio frames, with a custom LLC/SNAP hdr added */
|
||||
ol_tx_frm_no_free, /* frame requires special tx completion callback */
|
||||
OL_TX_FRM_STD = 0, /* regular frame - no added header fragments */
|
||||
OL_TX_FRM_TSO, /* TSO segment, with a modified IP header added */
|
||||
OL_TX_FRM_AUDIO, /* audio frames, with a custom LLC/SNAP hdr added */
|
||||
OL_TX_FRM_NO_FREE, /* frame requires special tx completion callback */
|
||||
};
|
||||
|
||||
struct ol_tx_desc_t {
|
||||
|
|
|
|||
Loading…
Reference in a new issue