PCIe probe failure on AmLogic A311D after 6.18-rc1

Linnaea Lavia linnaea-von-lavia at live.com
Thu Oct 30 22:34:41 PDT 2025


On 10/30/2025 1:15 AM, Bjorn Helgaas wrote:
> On Wed, Oct 29, 2025 at 06:50:46PM +0800, Linnaea Lavia wrote:
>> On 10/29/2025 6:16 AM, Bjorn Helgaas wrote:
> 
>>> diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
>>> index 214ed060ca1b..9cd12924b5cb 100644
>>> --- a/drivers/pci/quirks.c
>>> +++ b/drivers/pci/quirks.c
>>> @@ -2524,6 +2524,7 @@ static void quirk_disable_aspm_l0s_l1(struct pci_dev *dev)
>>>     * disable both L0s and L1 for now to be safe.
>>>     */
>>>    DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ASMEDIA, 0x1080, quirk_disable_aspm_l0s_l1);
>>> +DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_SYNOPSYS, 0xabcd, quirk_disable_aspm_l0s_l1);
>>>    /*
>>>     * Some Pericom PCIe-to-PCI bridges in reverse mode need the PCIe Retrain
>>
>> I have applied the patch on 6.18-rc3 but it's still trying to enable ASPM for some reasons.
> 
> Sorry, my fault, I should have made that fixup run earlier, so the
> patch should be this instead:
> 
> diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
> index 214ed060ca1b..4fc04015ca0c 100644
> --- a/drivers/pci/quirks.c
> +++ b/drivers/pci/quirks.c
> @@ -2524,6 +2524,7 @@ static void quirk_disable_aspm_l0s_l1(struct pci_dev *dev)
>    * disable both L0s and L1 for now to be safe.
>    */
>   DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ASMEDIA, 0x1080, quirk_disable_aspm_l0s_l1);
> +DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_SYNOPSYS, 0xabcd, quirk_disable_aspm_l0s_l1);

L1 still got enabled

# dmesg | grep -i -e pci -e iwlwifi -e aspm
[    0.130298] [      T1] PCI: CLS 0 bytes, default 64
[    5.243878] [     T48] dw-pcie fc000000.pcie: error -ENXIO: IRQ index 1 not found
[    5.294697] [     T48] meson-pcie fc000000.pcie: host bridge /soc/pcie at fc000000 ranges:
[    5.298580] [     T48] meson-pcie fc000000.pcie:       IO 0x00fc600000..0x00fc6fffff -> 0x0000000000
[    5.307484] [     T48] meson-pcie fc000000.pcie:      MEM 0x00fc700000..0x00fdffffff -> 0x00fc700000
[    5.324258] [     T48] meson-pcie fc000000.pcie: iATU: unroll T, 4 ob, 4 ib, align 64K, limit 4G
[    5.366020] [     T48] meson-pcie fc000000.pcie: error: wait linkup timeout
[    5.371376] [     T48] meson-pcie fc000000.pcie: PCIe Gen.2 x1 link up
[    5.375932] [     T48] meson-pcie fc000000.pcie: PCI host bridge to bus 0000:00
[    5.381390] [     T48] pci_bus 0000:00: root bus resource [bus 00-ff]
[    5.388280] [     T48] pci_bus 0000:00: root bus resource [io  0x0000-0xfffff]
[    5.395226] [     T48] pci_bus 0000:00: root bus resource [mem 0xfc700000-0xfdffffff]
[    5.402942] [     T48] pci 0000:00:00.0: [16c3:abcd] type 01 class 0x060400 PCIe Root Port
[    5.410068] [     T48] pci 0000:00:00.0: ROM [mem 0x00000000-0x0000ffff pref]
[    5.416900] [     T48] pci 0000:00:00.0: PCI bridge to [bus 01-ff]
[    5.422838] [     T48] pci 0000:00:00.0:   bridge window [io  0x0000-0x0fff]
[    5.429605] [     T48] pci 0000:00:00.0:   bridge window [mem 0x00000000-0x000fffff]
[    5.437147] [     T48] pci 0000:00:00.0:   bridge window [mem 0x00000000-0x000fffff pref]
[    5.445853] [     T48] pci 0000:00:00.0: Disabling ASPM L0s/L1
[    5.451334] [     T48] pci 0000:00:00.0: supports D1
[    5.455104] [     T48] pci 0000:00:00.0: PME# supported from D0 D1 D3hot D3cold
[    5.480231] [     T48] pci 0000:01:00.0: [8086:2725] type 00 class 0x028000 PCIe Endpoint
[    5.490539] [     T48] pci 0000:01:00.0: BAR 0 [mem 0x00000000-0x00003fff 64bit]
[    5.503464] [     T48] pci 0000:01:00.0: Upstream bridge's Max Payload Size set to 128 (was 256, max 256)
[    5.525959] [     T48] pci 0000:01:00.0: Max Payload Size set to 128 (was 128, max 128)
[    5.534845] [     T48] pci 0000:01:00.0: PME# supported from D0 D3hot D3cold
[    5.560448] [     T48] pci 0000:01:00.0: ASPM: default states L1
[    5.603416] [     T48] meson-pcie fc000000.pcie: error: wait linkup timeout
[    5.606141] [     T48] pci 0000:00:00.0: bridge window [mem 0xfc700000-0xfc7fffff]: assigned
[    5.636768] [     T48] pci 0000:00:00.0: ROM [mem 0xfc800000-0xfc80ffff pref]: assigned
[    5.636812] [     T48] pci 0000:01:00.0: BAR 0 [mem 0xfc700000-0xfc703fff 64bit]: assigned
[    5.693932] [     T48] meson-pcie fc000000.pcie: error: wait linkup timeout
[    5.735461] [     T48] meson-pcie fc000000.pcie: error: wait linkup timeout
[    5.778011] [     T48] meson-pcie fc000000.pcie: error: wait linkup timeout
[    5.820548] [     T48] meson-pcie fc000000.pcie: error: wait linkup timeout
[    5.821633] [     T48] pci 0000:01:00.0: BAR 0: error updating (0xfc700004 != 0xffffffff)
[    5.870950] [     T48] meson-pcie fc000000.pcie: error: wait linkup timeout
[    5.913471] [     T48] meson-pcie fc000000.pcie: error: wait linkup timeout
[    5.914547] [     T48] pci 0000:01:00.0: BAR 0: error updating (high 0x00000000 != 0xffffffff)
[    5.964337] [     T48] meson-pcie fc000000.pcie: error: wait linkup timeout
[    5.975124] [     T48] pci 0000:00:00.0: PCI bridge to [bus 01-ff]
[    5.988201] [     T48] pci 0000:00:00.0:   bridge window [mem 0xfc700000-0xfc7fffff]
[    6.004583] [     T48] pci_bus 0000:00: resource 4 [io  0x0000-0xfffff]
[    6.018790] [     T48] pci_bus 0000:00: resource 5 [mem 0xfc700000-0xfdffffff]
[    6.032400] [     T48] pci_bus 0000:01: resource 1 [mem 0xfc700000-0xfc7fffff]
[    6.033164] [     T48] pcieport 0000:00:00.0: PME: Signaling with IRQ 24
[    6.045204] [     T48] pcieport 0000:00:00.0: AER: enabled with IRQ 24

# lspci -vv
00:00.0 PCI bridge: Synopsys, Inc. DWC_usb3 / PCIe bridge (rev 01) (prog-if 00 [Normal decode])
         Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR+ FastB2B- DisINTx+
         Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
         Latency: 0
         Interrupt: pin A routed to IRQ 24
         Bus: primary=00, secondary=01, subordinate=ff, sec-latency=0
         I/O behind bridge: [disabled] [16-bit]
         Memory behind bridge: fc700000-fc7fffff [size=1M] [32-bit]
         Prefetchable memory behind bridge: [disabled] [32-bit]
         Secondary status: 66MHz- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort+ <SERR- <PERR-
         Expansion ROM at fc800000 [virtual] [disabled] [size=64K]
         BridgeCtl: Parity- SERR+ NoISA- VGA- VGA16- MAbort- >Reset- FastB2B-
                 PriDiscTmr- SecDiscTmr- DiscTmrStat- DiscTmrSERREn-
         Capabilities: [40] Power Management version 3
                 Flags: PMEClk- DSI- D1+ D2- AuxCurrent=375mA PME(D0+,D1+,D2-,D3hot+,D3cold+)
                 Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=0 PME-
         Capabilities: [50] MSI: Enable+ Count=1/1 Maskable- 64bit+
                 Address: 000000000935f000  Data: 0000
         Capabilities: [70] Express (v2) Root Port (Slot-), IntMsgNum 0
                 DevCap: MaxPayload 256 bytes, PhantFunc 0
                         ExtTag- RBE+ TEE-IO-
                 DevCtl: CorrErr+ NonFatalErr+ FatalErr+ UnsupReq+
                         RlxdOrd+ ExtTag- PhantFunc- AuxPwr- NoSnoop-
                         MaxPayload 128 bytes, MaxReadReq 256 bytes
                 DevSta: CorrErr- NonFatalErr- FatalErr- UnsupReq- AuxPwr+ TransPend-
                 LnkCap: Port #0, Speed 5GT/s, Width x1, ASPM L0s L1, Exit Latency L0s <1us, L1 <2us
                         ClockPM- Surprise- LLActRep+ BwNot+ ASPMOptComp+
                 LnkCtl: ASPM L1 Enabled; RCB 64 bytes, LnkDisable- CommClk+
                         ExtSynch- ClockPM- AutWidDis- BWInt+ AutBWInt+
                 LnkSta: Speed 5GT/s, Width x1
                         TrErr- Train- SlotClk+ DLActive+ BWMgmt- ABWMgmt-
                 RootCap: CRSVisible+
                 RootCtl: ErrCorrectable- ErrNon-Fatal- ErrFatal- PMEIntEna+ CRSVisible+
                 RootSta: PME ReqID 0000, PMEStatus- PMEPending-
                 DevCap2: Completion Timeout: Range ABCD, TimeoutDis+ NROPrPrP+ LTR-
                          10BitTagComp- 10BitTagReq- OBFF Not Supported, ExtFmt- EETLPPrefix-
                          EmergencyPowerReduction Not Supported, EmergencyPowerReductionInit-
                          FRS- LN System CLS Not Supported, TPHComp- ExtTPHComp- ARIFwd-
                          AtomicOpsCap: Routing- 32bit- 64bit- 128bitCAS-
                 DevCtl2: Completion Timeout: 50us to 50ms, TimeoutDis- ARIFwd-
                          AtomicOpsCtl: ReqEn- EgressBlck-
                          IDOReq- IDOCompl- LTR- EmergencyPowerReductionReq-
                          10BitTagReq- OBFF Disabled, EETLPPrefixBlk-
                 LnkCap2: Supported Link Speeds: 2.5-5GT/s, Crosslink- Retimer- 2Retimers- DRS-
                 LnkCtl2: Target Link Speed: 5GT/s, EnterCompliance- SpeedDis-
                          Transmit Margin: Normal Operating Range, EnterModifiedCompliance- ComplianceSOS-
                          Compliance Preset/De-emphasis: -6dB de-emphasis, 0dB preshoot
                 LnkSta2: Current De-emphasis Level: -6dB, EqualizationComplete- EqualizationPhase1-
                          EqualizationPhase2- EqualizationPhase3- LinkEqualizationRequest-
                          Retimer- 2Retimers- CrosslinkRes: unsupported
         Capabilities: [100 v2] Advanced Error Reporting
                 UESta:  DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF- MalfTLP-
                         ECRC- UnsupReq- ACSViol- UncorrIntErr- BlockedTLP- AtomicOpBlocked- TLPBlockedErr-
                         PoisonTLPBlocked- DMWrReqBlocked- IDECheck- MisIDETLP- PCRC_CHECK- TLPXlatBlocked-
                 UEMsk:  DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF- MalfTLP-
                         ECRC- UnsupReq- ACSViol- UncorrIntErr+ BlockedTLP- AtomicOpBlocked- TLPBlockedErr-
                         PoisonTLPBlocked- DMWrReqBlocked- IDECheck- MisIDETLP- PCRC_CHECK- TLPXlatBlocked-
                 UESvrt: DLP+ SDES+ TLP- FCP+ CmpltTO- CmpltAbrt- UnxCmplt- RxOF+ MalfTLP+
                         ECRC- UnsupReq- ACSViol- UncorrIntErr+ BlockedTLP- AtomicOpBlocked- TLPBlockedErr-
                         PoisonTLPBlocked- DMWrReqBlocked- IDECheck- MisIDETLP- PCRC_CHECK- TLPXlatBlocked-
                 CESta:  RxErr- BadTLP- BadDLLP- Rollover- Timeout- AdvNonFatalErr- CorrIntErr- HeaderOF-
                 CEMsk:  RxErr- BadTLP- BadDLLP- Rollover- Timeout- AdvNonFatalErr+ CorrIntErr+ HeaderOF+
                 AERCap: First Error Pointer: 00, ECRCGenCap+ ECRCGenEn- ECRCChkCap+ ECRCChkEn-
                         MultHdrRecCap- MultHdrRecEn- TLPPfxPres- HdrLogCap-
                 HeaderLog: 00000000 00000000 00000000 00000000
                 RootCmd: CERptEn+ NFERptEn+ FERptEn+
                 RootSta: CERcvd- MultCERcvd- UERcvd- MultUERcvd-
                          FirstFatal- NonFatalMsg- FatalMsg- IntMsgNum 0
                 ErrorSrc: ERR_COR: 0000 ERR_FATAL/NONFATAL: 0000
         Capabilities: [148 v1] L1 PM Substates
                 L1SubCap: PCI-PM_L1.2+ PCI-PM_L1.1+ ASPM_L1.2- ASPM_L1.1+ L1_PM_Substates+
                           PortCommonModeRestoreTime=55us PortTPowerOnTime=12us
                 L1SubCtl1: PCI-PM_L1.2- PCI-PM_L1.1- ASPM_L1.2- ASPM_L1.1-
                            T_CommonMode=55us
                 L1SubCtl2: T_PwrOn=18us
         Kernel driver in use: pcieport
         Kernel modules: shpchp

01:00.0 Network controller: Intel Corporation Wi-Fi 6E(802.11ax) AX210/AX1675* 2x2 [Typhoon Peak] (rev 1a)
         Subsystem: Intel Corporation Wi-Fi 6 AX210 160MHz
         !!! Unknown header type 7f
         Region 0: Memory at fc700000 (64-bit, non-prefetchable) [size=16K]
         Kernel modules: iwlwifi

Something else I tried was to boot with pcie_aspm.policy=performance so the link and device can be initialized, then

# echo default > /sys/module/pcie_aspm/parameters/policy

# while true; do cat /sys/kernel/debug/dwc_pcie_fc000000.pcie/ltssm_status; done | uniq
L1_IDLE (0x14)
RCVRY_LOCK (0x0d)
L1_IDLE (0x14)
RCVRY_IDLE (0x10)
L1_IDLE (0x14)
RCVRY_LOCK (0x0d)
L1_IDLE (0x14)
RCVRY_LOCK (0x0d)
L1_IDLE (0x14)
L0 (0x11)
L1_IDLE (0x14)
RCVRY_LOCK (0x0d)
L1_IDLE (0x14)
L0 (0x11)
L1_IDLE (0x14)
RCVRY_LOCK (0x0d)
L1_IDLE (0x14)
RCVRY_LOCK (0x0d)
L1_IDLE (0x14)
L0 (0x11)
L1_IDLE (0x14)
L0 (0x11)
L1_IDLE (0x14)
L0 (0x11)
L1_IDLE (0x14)
L0 (0x11)
L1_IDLE (0x14)
L123_SEND_EIDLE (0x13)
L1_IDLE (0x14)

The card works just fine. I'm thinking the ASPM issue is probably from the glue driver reporting the link to be down when it's really just in low power state.



More information about the linux-amlogic mailing list