diff options
author | Miaoqing Pan <miaoqing@codeaurora.org> | 2019-10-09 11:18:09 +0300 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2019-10-14 11:34:31 +0300 |
commit | 486a8849843455298d49e694cca9968336ce2327 (patch) | |
tree | 3a7ee06b1b0601bdea15834c01da68214661dc99 /drivers/net/wireless/ath/ath10k/debug.c | |
parent | c5329b2d5b8b4e41be14d31ee8505b4f5607bf9b (diff) | |
download | linux-486a8849843455298d49e694cca9968336ce2327.tar.xz |
ath10k: fix memory leak for tpc_stats_final
The memory of ar->debug.tpc_stats_final is reallocated every debugfs
reading, it should be freed in ath10k_debug_destroy() for the last
allocation.
Tested HW: QCA9984
Tested FW: 10.4-3.9.0.2-00035
Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/ath/ath10k/debug.c')
-rw-r--r-- | drivers/net/wireless/ath/ath10k/debug.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath10k/debug.c b/drivers/net/wireless/ath/ath10k/debug.c index 40baf25ac99f..04c50a26a4f4 100644 --- a/drivers/net/wireless/ath/ath10k/debug.c +++ b/drivers/net/wireless/ath/ath10k/debug.c @@ -2532,6 +2532,7 @@ void ath10k_debug_destroy(struct ath10k *ar) ath10k_debug_fw_stats_reset(ar); kfree(ar->debug.tpc_stats); + kfree(ar->debug.tpc_stats_final); } int ath10k_debug_register(struct ath10k *ar) |