Altera_Forum
Honored Contributor
10 years agoPCIe Force Gen1 Link
I've built a design around a Stratix V and the Avalon-ST Hard IP Core. The device is designed for Gen3x8 which is working fine.
I now want to connect the design to a laptop via a Gen1x1 ExpressCard Slot. I have a OneStop Systems express card cable adapter (OSS-ECA-x4 and OSS-PCIe-HIB2-EC-x4). On one laptop, the device correctly enumerates at Gen1x1 and works as expected. However on a second laptop, the core fails to properly enumerate - sometimes doesn't select the correct number of lanes and so fails to appear at all. Other times it does enumerate, but only very late on after windows has started up. Looking at the configuration registers, on most attempts to boot there are fatal errors detected (read the configuration space and it indicates errors). Only very occasionally does it successfully enumerate. I compiled a gen1x1 variant of the core, which does enumerate correctly, but (a) it means I have to have two versions of the firmware to keep up to date which I would rather not do, and (b) I will have to do a lot of debugging of my application layer again to make sure it works with the slower clock frequency (there are clock crossing considerations) and narrower bus (64bit rather than 256bit), so really would rather get the Gen3x8 properly enumerating on Gen1x1. As far as I can tell the laptop that is misbehaving being quite modern supports Rev2.0 of ExpressCard which basically says that it is allowed to run the PCIe lane at Gen2. Sure enough the north bridge chipset of it also supports Gen2. The old laptop which is working however predates Rev2.0 of ExpressCard, so is limited to Gen1. I have a sneaking suspicion that the Stratix V is trying to jump up to Gen2 and failing. As there are redrivers in the cable that only support Gen1 any attempt to run faster will simply result in garbled signals - in fact looking on a oscilloscope at the traces they do seem to double in speed. So the question is, is there a way to force the Stratix V Avalon-ST Hard IP core to not go above Gen1 using something like a dip switch setting? - i.e. I don't want it to be a synthesis parameter, I want to be able to flick a switch at have it be limited to Gen1.