|
@@ -1418,10 +1418,16 @@ struct iwl_trans *iwl_trans_pcie_alloc(struct pci_dev *pdev,
|
|
|
spin_lock_init(&trans_pcie->reg_lock);
|
|
|
init_waitqueue_head(&trans_pcie->ucode_write_waitq);
|
|
|
|
|
|
- /* W/A - seems to solve weird behavior. We need to remove this if we
|
|
|
- * don't want to stay in L1 all the time. This wastes a lot of power */
|
|
|
- pci_disable_link_state(pdev, PCIE_LINK_STATE_L0S | PCIE_LINK_STATE_L1 |
|
|
|
- PCIE_LINK_STATE_CLKPM);
|
|
|
+ if (!cfg->base_params->pcie_l1_allowed) {
|
|
|
+ /*
|
|
|
+ * W/A - seems to solve weird behavior. We need to remove this
|
|
|
+ * if we don't want to stay in L1 all the time. This wastes a
|
|
|
+ * lot of power.
|
|
|
+ */
|
|
|
+ pci_disable_link_state(pdev, PCIE_LINK_STATE_L0S |
|
|
|
+ PCIE_LINK_STATE_L1 |
|
|
|
+ PCIE_LINK_STATE_CLKPM);
|
|
|
+ }
|
|
|
|
|
|
if (pci_enable_device(pdev)) {
|
|
|
err = -ENODEV;
|