Altera_Forum
Honored Contributor
14 years agoModifying QSys PCIe reference design to have dual port OCM
Hi everyone,
I am trying to modify the QSys PCIe reference design (AN431) for a Cyclone IV Starter Kit equivalent. The reference design works on my board after I modified the pin mappings and PLL settings. I get transfer rates of 195MB/s (FPGA->computer) and 120MB/s (computer->FPGA). These speeds are obtained using the Windows program that came with the reference design. Here's my understanding of the system: http://img12.imageshack.us/img12/176/an431.png I am trying to transfer data over PCIe with DMA. To do so, I am moving data into the OCM (on chip memory) and transfering the contents of the OCM via DMA. To do this, the OCM was modified to be a dual port memory. The second port was exported from the Qsys design. Data is constantly being written to the exported port. In essence, I created this system: http://img202.imageshack.us/img202/2865/an431modified.png The problem is DMA transfer now is intermittent and fails on occasion. The smaller the transfer size, the higher the likelihood of success. When it succeeds, the transfer takes place at the full speed that it did prior to modification. So, my question is, why is it failing and what can I do to fix this? My first hypothesis is that perhaps its a read during write that is causing the failure. However, this does not seem plausible because there is no feedback from the OCM which can cause the Avalon bus to stall. The signals coming out of each slave port of the OCM are:
address
chipselect
clken
readdata
write
writedata
byteenable
I don't see any signals which could cause the system to wait. I wouldn't even know which signals to probe if I were to use SignalTap. Does anyone have any suggestions?