]> git.baikalelectronics.ru Git - kernel.git/commit
iwlwifi: pcie: actually release queue memory in TVQM
authorJohannes Berg <johannes.berg@intel.com>
Fri, 17 Apr 2020 07:08:09 +0000 (10:08 +0300)
committerKalle Valo <kvalo@codeaurora.org>
Tue, 21 Apr 2020 12:39:00 +0000 (15:39 +0300)
commitd0ec642a96d6d5481f292dadcdba07d2010b06ec
treee771347a101bf4b9a8fedd561c35e80f5c3c7e13
parent661d624b92e70817ff695e69573efe772b641eec
iwlwifi: pcie: actually release queue memory in TVQM

The iwl_trans_pcie_dyn_txq_free() function only releases the frames
that may be left on the queue by calling iwl_pcie_gen2_txq_unmap(),
but doesn't actually free the DMA ring or byte-count tables for the
queue. This leads to pretty large memory leaks (at least before my
queue size improvements), in particular in monitor/sniffer mode on
channel hopping since this happens on every channel change.

This was also now more evident after the move to a DMA pool for the
byte count tables, showing messages such as

  BUG iwlwifi:bc (...): Objects remaining in iwlwifi:bc on __kmem_cache_shutdown()

This fixes https://bugzilla.kernel.org/show_bug.cgi?id=206811.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Fixes: e4adfd3d6877 ("iwlwifi: pcie: introduce a000 TX queues management")
Cc: stable@vger.kernel.org # v4.14+
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/iwlwifi.20200417100405.f5f4c4193ec1.Id5feebc9b4318041913a9c89fc1378bb5454292c@changeid
drivers/net/wireless/intel/iwlwifi/pcie/tx-gen2.c