iwlwifi: pcie: properly set LTR workarounds on 22000 devices
authorJohannes Berg <johannes.berg@intel.com>
Fri, 26 Mar 2021 10:57:18 +0000 (12:57 +0200)
committerKalle Valo <kvalo@codeaurora.org>
Tue, 6 Apr 2021 10:25:53 +0000 (13:25 +0300)
commit25628bc08d4526d3673ca7d039eb636aa9006076
tree6d89d846a4a31a659d6cd6ee685e5759dc4afd58
parent07cc40fec9a85e669ea12e161a438d2cbd76f1ed
iwlwifi: pcie: properly set LTR workarounds on 22000 devices

As the context info gen3 code is only called for >=AX210 devices
(from iwl_trans_pcie_gen2_start_fw()) the code there to set LTR
on 22000 devices cannot actually do anything (22000 < AX210).

Fix this by moving the LTR code to iwl_trans_pcie_gen2_start_fw()
where it can handle both devices. This then requires that we kick
the firmware only after that rather than doing it from the context
info code.

Note that this again had a dead branch in gen3 code, which I've
removed here.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Fixes: ed0022da8bd9 ("iwlwifi: pcie: set LTR on more devices")
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/iwlwifi.20210326125611.675486178ed1.Ib61463aba6920645059e366dcdca4c4c77f0ff58@changeid
drivers/net/wireless/intel/iwlwifi/pcie/ctxt-info-gen3.c
drivers/net/wireless/intel/iwlwifi/pcie/ctxt-info.c
drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c