wifi: iwlwifi: fw: fix memory leak in debugfs
authorJohannes Berg <johannes.berg@intel.com>
Tue, 18 Apr 2023 09:28:05 +0000 (12:28 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 11 May 2023 14:03:25 +0000 (23:03 +0900)
commit37f64bc8e001f216566d17ef9fd5608c762ebcd4
treef30771306a9cb5b139e49b2521f3c27a93ece373
parent80c5ba0078e20d926d11d0778f9a43902664ebf0
wifi: iwlwifi: fw: fix memory leak in debugfs

[ Upstream commit 3d90d2f4a018fe8cfd65068bc6350b6222be4852 ]

Fix a memory leak that occurs when reading the fw_info
file all the way, since we return NULL indicating no
more data, but don't free the status tracking object.

Fixes: 36dfe9ac6e8b ("iwlwifi: dump api version in yaml format")
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
Link: https://lore.kernel.org/r/20230418122405.239e501b3b8d.I4268f87809ef91209cbcd748eee0863195e70fa2@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/wireless/intel/iwlwifi/fw/debugfs.c