iwlwifi: pcie: Enable MSI mode when using MSI interrupts
authorIdo Yariv <ido@wizery.com>
Tue, 14 Jun 2016 14:27:57 +0000 (10:27 -0400)
committerLuca Coelho <luciano.coelho@intel.com>
Wed, 6 Jul 2016 06:39:16 +0000 (09:39 +0300)
On some of the chipsets MSI & INTA interrupts are disabled by default in
the HW registers, and need to be explicitly enabled to be used.

In case MSI-X isn't used, make sure MSI mode is enabled by setting
the relevant HW register.

Signed-off-by: Ido Yariv <idox.yariv@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
drivers/net/wireless/intel/iwlwifi/iwl-prph.h
drivers/net/wireless/intel/iwlwifi/pcie/trans.c

index 6c1d20ded04baf7a34bae96bac8c33f978250d27..459bf736fd5bee48b33de76bfc579c391d6d94e9 100644 (file)
@@ -417,5 +417,6 @@ enum {
 };
 
 #define UREG_CHICK             (0xA05C00)
+#define UREG_CHICK_MSI_ENABLE  BIT(24)
 #define UREG_CHICK_MSIX_ENABLE BIT(25)
 #endif                         /* __iwl_prph_h__ */
index ac623c3e3f240df52f03e0ec51d47923d352f238..f5ace924e76a0ff82293cdf1389c2980d3443063 100644 (file)
@@ -1396,8 +1396,12 @@ static void iwl_pcie_init_msix(struct iwl_trans_pcie *trans_pcie)
 
        max_rx_vector = trans_pcie->allocated_vector - 1;
 
-       if (!trans_pcie->msix_enabled)
+       if (!trans_pcie->msix_enabled) {
+               if (trans->cfg->mq_rx_supported)
+                       iwl_write_prph(trans, UREG_CHICK,
+                                      UREG_CHICK_MSI_ENABLE);
                return;
+       }
 
        iwl_write_prph(trans, UREG_CHICK, UREG_CHICK_MSIX_ENABLE);
 
This page took 0.026137 seconds and 5 git commands to generate.