From 92ee8cac8dc01e3efd8d6b0b0ac7db2b6b3579b0 Mon Sep 17 00:00:00 2001 From: hqu Date: Fri, 17 Nov 2017 17:12:09 +0800 Subject: [PATCH] qcacld-3.0: Add SKB to internal tracking table in ipa i2w path When define MEMORY_DEBUG macro for debugging memory issue, even in normal case it still will report double free for ipa i2w SKB. Fix is to add ipa i2w SKB to internal tracking table. Change-Id: I27b0afc79e8c39c99a73ec9a65a348ebf85960b6 CRs-Fixed: 2145344 --- core/dp/txrx/ol_tx.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/core/dp/txrx/ol_tx.c b/core/dp/txrx/ol_tx.c index 0e2939baf605..78f08eef1e4c 100644 --- a/core/dp/txrx/ol_tx.c +++ b/core/dp/txrx/ol_tx.c @@ -292,6 +292,8 @@ qdf_nbuf_t ol_tx_send_ipa_data_frame(struct cdp_vdev *vdev, qdf_nbuf_t skb) qdf_nbuf_t ret; if (qdf_unlikely(!pdev)) { + qdf_net_buf_debug_acquire_skb(skb, __FILE__, __LINE__); + ol_txrx_err("%s: pdev is NULL", __func__); return skb; } @@ -303,6 +305,13 @@ qdf_nbuf_t ol_tx_send_ipa_data_frame(struct cdp_vdev *vdev, qdf_nbuf_t skb) /* Terminate the (single-element) list of tx frames */ qdf_nbuf_set_next(skb, NULL); + + /* + * Add SKB to internal tracking table before further processing + * in WLAN driver. + */ + qdf_net_buf_debug_acquire_skb(skb, __FILE__, __LINE__); + ret = OL_TX_SEND((struct ol_txrx_vdev_t *)vdev, skb); if (ret) { ol_txrx_dbg("%s: Failed to tx", __func__);