PCI: rockchip: Fix wrong transmitted FTS count
authorShawn Lin <shawn.lin@rock-chips.com>
Tue, 4 Oct 2016 17:20:22 +0000 (12:20 -0500)
committerBjorn Helgaas <bhelgaas@google.com>
Tue, 4 Oct 2016 17:20:22 +0000 (12:20 -0500)
commitca1989084054e64da25662e1f974f77312083eb3
tree51d762fb3a580ab10cc70b8deb9e0ab9c2756ebc
parent58c6990c5ee772c2551193f053e51a52b9984b49
PCI: rockchip: Fix wrong transmitted FTS count

If the expected number of FTS aren't received by RC when exiting from L0s,
the LTSSM will fall into recover state, which means it will need to send TS
for retraining which makes the latency of exiting from L0s a little longer
than expected.  This issue is caused by an incorrect reset value of FTS
count on PLC1 register (offset 0x4).  The expected value for Gen1/2 should
be more than 240 and we may leave a little margin here.  Fix this before
starting Gen1 training which will make TS1 contain the correct FTS count.

Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
drivers/pci/host/pcie-rockchip.c