wifi: iwlwifi: pcie: avoid a warning in case prepare card failed
authorAvraham Stern <avraham.stern@intel.com>
Tue, 22 Aug 2023 07:33:15 +0000 (10:33 +0300)
committerJohannes Berg <johannes.berg@intel.com>
Tue, 22 Aug 2023 11:19:52 +0000 (13:19 +0200)
commit057381ddac0593c6e4ca8f58732830d8542b9c4e
tree0236fb793f2d0c29b1c9572cc318960de919fd6d
parentd166a5c9775f8cc0b20e3331e238844a3fe57fa1
wifi: iwlwifi: pcie: avoid a warning in case prepare card failed

In case CSME holds the NIC and SAP connection is already established,
iwl_pcie_prepare_card_hw() during iwl_pci_probe() will fail
(which is fine since CSME will release the nic later when asked with
a SAP message). In this case tring to grab nic access to read the
crf ids will fail with a warning.
Avoid the warning by only trying to read the crf ids in case prepare
card succeeded.

Signed-off-by: Avraham Stern <avraham.stern@intel.com>
Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
Link: https://lore.kernel.org/r/20230822103048.9b026fa7b97e.I12bea7e6eef54eeeaf916b68d71583e92ff310fd@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/intel/iwlwifi/pcie/drv.c