08-06-2020 08:13 AM
here below you can see a AXI_S_DATI_0, which is an AXI slave (generated with "Tools/Create and package new IP"...), connected to the M_AXI_GP0 port of the zynq via smart connect.
In my test (helloworld run in Vitis), PS writes (250 MHz) in burst mode to AXI_S_DATI_0 1024 32-bit words, which are then transferred (40 MHz) to an external DDR via memory mapped.
Between the AXI slave and the external DDR I have put a FIFO generetor. Now, when FIFO is almost full (wr_data_count >= FULL - 16), a wr_PL_busy signal becomes high.
This wr_PL_busy goes to the AXI slave. Inside the AXI slave, specifically in the file AXI_S_DATI_v1_0_S00_AXI.vhd generated by Vivado, I modified the axi_wready generation like this:
I attached below the Helloworld.c I used: with burst size = 4, no problem, with burst size = 16 the DMA transfer stops and I can't read back data.
I tried to debug with ILA (see below): As you can see, in the last transfer the busy goes high three times and wready, consequently, goes low: at the end, the bvalid goes normally high (BRESP is always = "00"). All the 16 data of the last transfer goes to the FIFO regularly and all seems OK, but after this transfer, as I said before, the DMA transfer ends in advance (and ILA can't complete its 1024 samples).
Please, take a look to the Helloworld: I just took it somewhere and modified it here or there and now I'm not completely sure of its correctness...
Thanks a lot to everyone who wants to help me!
08-06-2020 11:17 AM
A couple quick notes:
08-07-2020 06:00 AM
thank you for your precious notes!
In particular, I hope your second link, the one about formal methods, could be useful for me.
I've never used these methods before now, and would ask you some additional suggestion.
I wrote these lines:
if (int_wready && s00_axi_aresetn)
out of the process where I use int_wready, at the beginning of the file, just after signal declarations and I get this error, synthetizing my AXI slave:
[Synth 8-36] 'assert' is not declared
Do you think I need specific libraries (something like OVL)? In this case, how should I get and include them?
Thanks a lot!
08-07-2020 07:09 AM
08-10-2020 03:28 AM
thanks to your tip, now I can syntetize my AXI slave. But, my design still doesn't work. Debugging with ILA It seems that the condition about PL busy, now, is ignored...
Probably I'm still missing something... I add here below the new process:
Can you help me to correct it? Thanks a lot!
08-10-2020 04:47 AM
08-10-2020 09:35 AM
After some different attempts, I've tried to include my condition about PL busy in the Vivado process to generate axi_wready, the one inside AXI_S_D_2_v1_0_S00_AXI.v, instead of working in the top file of the AXI slave. Now my initial issue seems to have disappeared. I hope also some other addidional tests work...
Thank you so much,
08-10-2020 11:32 AM
So I took a look at your *_S00_AXI.v slave logic file. Here's what I discovered:
Sadly, I discussed these bugs on my blog over a year ago. They've been known for a while. Xilinx has since released Vivado 2019.1 and even Vivado 2020.1. Neither version has fixed these bugs. Your design is at risk of a hard lockup if you use this base design.
If you need some better logic to start from, try this AXI (full) slave demonstrator. It's been verified bug free.
08-10-2020 11:51 AM
Almost forgot another bug--the core doesn't gate its WLAST check against WVALID.
There's also the issue where the core doesn't permit concurrent reads and writes, but only if they both show up on the same cycle. As before, the blog article above has more information on all of these.