This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/AM5728: PCIe reset issue

Part Number: AM5728


Tool/software: Linux

Hello,

After several months working with prototypes based on AM5728 (Linux) and SATA disk connected via Marvell PCIe/SATA controllers we are not able to solve the problem we have regarding PCIe and disk identification when powering up.

Our system has the following block diagram:

When the system powers up with no errors and all disks are properly identified, the system works smoothly.

Our problem is that under certain circumstances (after a non-expected shut down), the following power up reports SATA errors in one or both PCIe interfaces

 

[    5.881123] ata2: SATA link down (SStatus 1 SControl 300)

[    6.203431] ata2: exception Emask 0x10 SAct 0x0 SErr 0x4040000 action 0xe frozen

[    6.210890] ata2: irq_stat 0x80000040, connection status changed

[    6.216927] ata2: SError: { CommWake DevExch }

[    6.221435] ata2: hard resetting link

[    8.470266] ata2: SATA link down (SStatus 1 SControl 300)

[    8.475805] ata2: EH complete

[    8.702997] ata2: exception Emask 0x10 SAct 0x0 SErr 0x4040000 action 0xe frozen

[    8.710471] ata2: irq_stat 0x80000040, connection status changed

[    8.716505] ata2: SError: { CommWake DevExch }

[    8.721010] ata2: limiting SATA link speed to 1.5 Gbps

[    8.726196] ata2: hard resetting link

[    9.360250] ata6: link is slow to respond, please be patient (ready=0)

[   10.950268] ata2: SATA link down (SStatus 1 SControl 310)

[   10.955781] ata2: EH complete

[   11.202575] ata2: exception Emask 0x10 SAct 0x0 SErr 0x4040000 action 0xe frozen

[   11.210032] ata2: irq_stat 0x80000040, connection status changed

[   11.216082] ata2: SError: { CommWake DevExch }

[   11.220623] ata2: limiting SATA link speed to 1.5 Gbps

[   11.225815] ata2: hard resetting link

[   13.460265] ata2: SATA link down (SStatus 1 SControl 310)

[   13.465718] ata2: EH complete

[   13.630303] ata1: softreset failed (1st FIS failed)

[   13.690758] ata4: softreset failed (1st FIS failed)

[   23.630735] ata1: softreset failed (1st FIS failed)

[   23.691169] ata4: softreset failed (1st FIS failed)

[   58.630299] ata1: softreset failed (1st FIS failed)

[   58.635207] ata1: limiting SATA link speed to 3.0 Gbps

[   58.690576] ata4: softreset failed (1st FIS failed)

[   58.695481] ata4: limiting SATA link speed to 3.0 Gbps

[   63.640577] ata1: softreset failed (1st FIS failed)

[   63.645590] ata1: reset failed, giving up

[   63.700850] ata4: softreset failed (1st FIS failed)

[   63.705756] ata4: reset failed, giving up

 

Sometimes dmesg shows the the PCIe lane does not link up.

[ 1.882257] dra7-pcie 51800000.pcie: phy link never came up

 

Can anyone answer to this very concise question?

-          When powering up the system, why does it matter how it was previously closed? Does CPU PCIe host keep a state machine or is any information stored?

We are really stuck with this issue since our system can power up without working hard disk.

Many thanks,

Jorge 

  • Hi Jorge,

    Jorge Miguel said:
    -          When powering up the system, why does it matter how it was previously closed? Does CPU PCIe host keep a state machine or is any information stored?

    What is the non-expected shut down? Is it power lost or system lockup? When you power up the system after the non-expected shut down, is it a warm reset or power cycle?

    I don't think AM5728 itself keeps any previous state if it loses power, but I cannot speak for anything else, for example, if there is a RTC on your design to keep any information, or Marvell controller does anything.

  • --> What is the non-expected shut down?

    It is a power lost. When I intentionaly disconnect the power wire or I disable the power supply.

    -->  When you power up the system after the non-expected shut down, is it a warm reset or power cycle?

    A power cycle.

    When I just reboot the system by software (warm reset), everything works fine.

    It seems that as long as the previos close is done propertly (by software), the next boot works fine. However when the system is not propertly closed by software, for example when I quit the power, there is a high chance that my disks are not recognized (ata errors) or the PCIe lanes don't link up. 

    There isn´t any RTC on my system.

    Regards,