Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'pci/controller/dwc-sophgo'

- Disable L0s and L1 on Sophgo 2044 PCIe Root Ports (Inochi Amaoto)

* pci/controller/dwc-sophgo:
PCI: sophgo: Disable L0s and L1 on Sophgo 2044 PCIe Root Ports

+18
+18
drivers/pci/controller/dwc/pcie-sophgo.c
··· 161 161 raw_spin_unlock_irqrestore(&pp->lock, flags); 162 162 } 163 163 164 + static void sophgo_pcie_disable_l0s_l1(struct dw_pcie_rp *pp) 165 + { 166 + struct dw_pcie *pci = to_dw_pcie_from_pp(pp); 167 + u32 offset, val; 168 + 169 + offset = dw_pcie_find_capability(pci, PCI_CAP_ID_EXP); 170 + 171 + dw_pcie_dbi_ro_wr_en(pci); 172 + 173 + val = dw_pcie_readl_dbi(pci, PCI_EXP_LNKCAP + offset); 174 + val &= ~(PCI_EXP_LNKCAP_ASPM_L0S | PCI_EXP_LNKCAP_ASPM_L1); 175 + dw_pcie_writel_dbi(pci, PCI_EXP_LNKCAP + offset, val); 176 + 177 + dw_pcie_dbi_ro_wr_dis(pci); 178 + } 179 + 164 180 static int sophgo_pcie_host_init(struct dw_pcie_rp *pp) 165 181 { 166 182 int irq; ··· 186 170 return irq; 187 171 188 172 irq_set_chained_handler_and_data(irq, sophgo_pcie_intx_handler, pp); 173 + 174 + sophgo_pcie_disable_l0s_l1(pp); 189 175 190 176 sophgo_pcie_msi_enable(pp); 191 177