qcacld-3.0: Fix memory leak in dfs module
Fix memory leak in dfs module by removing check for the board id. During dfs_attach dfs_hw_bd_id was zero, so memory was allocated for pulses_ext_seg but in wma registration process correct board was updated. In dfs_detach while freeing the memory we check for the board id and we leaked the memory for pulses_ext_seg. Change-Id: Ica9719cc4cd67e895fad850c59c753d39473f46d CRs-Fixed: 974299
This commit is contained in:

committed by
Vishwajith Upendra

parent
f1d6deee43
commit
0379b59f95
@@ -489,8 +489,7 @@ void dfs_detach(struct ieee80211com *ic)
|
||||
dfs->pulses = NULL;
|
||||
}
|
||||
|
||||
if (dfs->pulses_ext_seg != NULL &&
|
||||
ic->dfs_hw_bd_id != DFS_HWBD_QCA6174) {
|
||||
if (dfs->pulses_ext_seg != NULL) {
|
||||
OS_FREE(dfs->pulses_ext_seg);
|
||||
dfs->pulses_ext_seg = NULL;
|
||||
}
|
||||
@@ -520,8 +519,7 @@ void dfs_detach(struct ieee80211com *ic)
|
||||
OS_FREE(dfs->dfs_b5radars);
|
||||
dfs->dfs_b5radars = NULL;
|
||||
}
|
||||
if (dfs->dfs_b5radars_ext_seg != NULL &&
|
||||
ic->dfs_hw_bd_id != DFS_HWBD_QCA6174) {
|
||||
if (dfs->dfs_b5radars_ext_seg != NULL) {
|
||||
OS_FREE(dfs->dfs_b5radars_ext_seg);
|
||||
dfs->dfs_b5radars_ext_seg = NULL;
|
||||
}
|
||||
|
Reference in New Issue
Block a user