浏览代码

qcacld-3.0: Remove vdev stop req from vdev resp queue if vdev stop fail

If during set link state, vdev stop fails, then the params pointer
is not removed from the vdev resp queue and set link state rsp is
called which will free this params pointer.

This leads to double free of the params memory when driver try to
remove the req params from vdev resp queue when cleanup vdev resp
queue is called.

To fix this remove vdev stop req from vdev resp queue if vdev stop
fails.

Change-Id: I1da763d2cc35c12c1b55a3c0057b893e9ef8d48f
CRs-Fixed: 2080189
Abhishek Singh 8 年之前
父节点
当前提交
c15f649aef
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      core/wma/src/wma_data.c

+ 2 - 0
core/wma/src/wma_data.c

@@ -1230,6 +1230,8 @@ void wma_set_linkstate(tp_wma_handle wma, tpLinkStateParams params)
 			WMA_LOGP("%s: %d Failed to send vdev stop",
 				 __func__, __LINE__);
 			params->status = false;
+			wma_remove_vdev_req(wma, vdev_id,
+				WMA_TARGET_REQ_TYPE_VDEV_STOP);
 		} else {
 			WMA_LOGP("%s: %d vdev stop sent vdev %d",
 				 __func__, __LINE__, vdev_id);