AnsweredAssumed Answered

i.MX 6DualLite resume problem with PCIe (ERR005723?)

Question asked by Kai Ruhnau on Aug 24, 2015
Latest reply on Aug 25, 2015 by igorpadykov



Im currently running Kernel 3.14.28-1.0.0-ga (from the freescale git repository) with a few patches and have issues with resume that look a lot like what ERR005723 related documents describe. Without any additional output, I can see the hang after the "CPU1 is up" output during resume. Once I "disabled" PCI in my device tree, resume works fine.


In my hardware design, one Cyclone V Altera FPGA is connected to a "Keith & Koep Trizeps VII".


In the git repository (334af1b0) and in the code I can see that the "not official" fix using the PHY-power-down in GPR1 is part of the kernel. However, the system hangs when it tries to get the FPGA out of the D3 power state and before my driver is called (in pci_raw_set_power_state from drivers/pci/pci.h). This whole hang is made complicated by the fact that when I start adding printk and similar outputs, the behavior changes until with enough output (using the serial console, so it's slow) the system resumes successfully.


Here is a couple of things I tried:

  • "dev_warn"-output before "error = device_resume_noirq..." in dpm_resume_noirq in drivers/base/power/main.c: Resume takes 1.4 seconds, but succeeds reliably (?)
  • "printk("x");" at the same position: Resume hangs reliably
  • some printks in pci_power_up in drivers/pci/pci.c, depending on the size of the output and moon phase
    • "fpga 0000:01:00.0: Refused to change power state, currently in D3"
    • "imx6q-pcie 1ffc000.pcie: transition to gen2 is stuck, reset PHY!"
    • resume hangs

The second one is a bit strange, as the FPGA currently only supports gen1.


I'm trying to get a hold of this and would like to avoid adding some random printks and the delays it brings just because "it fixes stuff" (or not: System will not resume from suspend to memory with PCIE enabled). Any help would be greatly appreciated.