PCIE example issues
I am using the PCIE Example as described in UG-20234. As i want to connect another application behind the hard-IP EP, i am modifying the testbench and APPS to allow transfers >4 bytes, which is how the example is written. The idea is: i verify in simulation, before mapping it onto the FPGA, debugging on a mapped design is way more time consuming then in simulation.
It is configured for 64 bit/250 Mhz / Atlanta interface between HardIP and APPS.
I managed to send 8 bytes to APPS, which sends those 8 bytes to memory, and returns them again. I then add 1 to each byte, to be sure i do not mix up with the sent information. The comparator at testbench detects the differences, and goes on playing (in the example it stops when send != receive. ) I adapted the header for the CmplD TLP from
| 77 RX | MWr | 0004 | 60000001_0000000F_00000001_00010000 |
| 77 RX | MRd (00) | 0004 | 20000001_0000000F_00000001_00010000 |
| 77 TX | CplD (00) | 0004 | 4A000001_01080004_00000000 |
| 77 RX | MWr | 0004 | 60000001_0000000F_00000001_00010000 |
| 77 RX | MRd (00) | 0004 | 20000001_0000000F_00000001_00010000 |
| 77 TX | CplD (00) | 0004 | 4A000001_01080004_00000000 |
(for 8 byte) to
| 77 RX | MWr | 0008 | 60000002_000000FF_00000001_00010000 |
| 77 RX | MRd (00) | 0008 | 20000002_000000FF_00000001_00010000 |
| 77 TX | CplD (00) | 0008 | 4A000002_01080008_00000000 |
The Header for 8 byte has the following TLP fields, which are to my knowledge correct:
For MWr:
DW0 60000002: length = 2, Fmt = 2’b11”, Type = 5’b00000 => strange: Fmt should be 2’b10 for MWr!!!??? (this is made by INTEL IP)
DW1 000000FF: 1stBE = F, Last_BE = F, Tag = 0, ReqID = 0 (Made by Intel IP)
DW2 00000001: why is DW1[0] = R=1, this should be 0 !!!!???? Address = 0 (Made by Intel IP) In reality it is 0000_0000 !!! (bug)
DW3 00010000 = ???? (should be data???!!!). But the data arrives correctly in the memory (Made by Intel IP) In reality it is data[31:0]
DW4: (not depicted in this table) data[63:32] works correctly
For Mrd:
DW0 20000002: Length = 2, Type = 5’b0000, Fmt = 2’b01 => strange: Fmt should be 2’b00 for Mrd (Made by Intel IP)
DW1 000000FF: : 1stBE = F, Last_BE = F, Tag = 0, ReqID = 0 (Made by Intel IP)
DW2: 00000000: why is DW1[0] = R=1, this should be 0 !!!!???? Address = 0 (Made by Intel IP)
For CplD
DW0 4A000002: Length = 2, Type = 5’b01010 (correct), Fmt = 2’b10 (correct) (Made by me)
DW1 000000FF: : 1stBE = F, Last_BE = F, Tag = 0, ReqID = 0 (Made by me)
DW2: 00000001: why is DW1[0] = R=1, this should be 0 !!!!???? Address = 0 (Made by Intel IP), in reality it is 0000_0000
DW3 data[31:0]
DW4 data[63:32]
For some reason this does not work:
The DUT PCIE hard IP does not produce nice continuous tx0..tx3 signals: they are interrupted with ‘x’ s.
In the testbench, the signal is routed via rx0..rx3 to altpcietb_bfm_rpvar_64b_x8_pipen1b. The output of rpvar: rx_data0 0000000000000000 rx_desc0 044a000002010800080000000078561011 rx_be f4 rx_dv 0 rx_dfr 0 rx_ack 0 rx_abort 0 rx_retry 0 rx_mask 0 rx_ws 0 Where the last 8 bytes are correct = data[31:0] sent!
My questions:
Why does this not work? Options:
- the header for MRd is not correct, but this is generated by INTEL testbench?
- The header for ClpD is not correct (this is generated by my modifications)?
- The HardIP in DUT has a configuration that only allows 4 bytes?
- The rpvar mimic can only handle 4 bytes?
- The rpvar needs a modification of parameters?
- And how do I make it working?
Thanks in advance! Pieter
Hi Pieter,
And yes, indeed, if you run the software test as in figure 12, then the application accepts traffic loadup to MAX.PAYLOAD. BUT NOT THE TESTBENCH / APPS in simulation!
Yes. As in my previous reply, the testbench provides simple method to do basic testing and this does not cover all the traffic profile stimuli. If user wants to simulate with what is not covered in the testbench, user has to modify the testbench based on their requirements.
So, i think i am on the edge of improving the testbench and APPS to payload = max.payload. My question: if i would share this code with you, would INTEL be willing to compensate me for this effort ? (i think INTEL does not deliver what it says it does as described in the manual)
I apologize for the miscommunication if there is any. The reason I asked if you are willing to share the modification earlier is because there are some hobbyists share information, what they have created or method to solve problems in this public forum. Please do not share if the content is confidential or non-public accessible.
Thanks for your understanding. Do let me know if you have any questions or concerns.
Best regards,
KhaiY