Showing results for 
Show  only  | Search instead for 
Did you mean: 
Registered: ‎05-12-2020

Hanging bug with HWICAP XHwIcap_CfgInitialize

Using: Vivado/Vitis 2020.2, XC7A50TCSG324-1

AXI HWICAP v3 with MB v11 with bare-metal.

Issue: For a specific configuration of AXI HWICAP, a call to XHwIcap_CfgInitialize will never return and get stuck somewhere inside.

Steps to recreate:

1. AXI HWICAP instance with

 - Use ICAP external to the IP -> unchecked

- Disable Write FIFO -> checked

- Disable Read FIFO -> checked

- ICAPE2 Data Width -> 32

- Include STARTUPE2 Primitive -> unchecked

- Advanced operation -> unchecked

- Synchronous operation

Connected EOS_IN to externally instantiated STARTUPE2 EOS, ICAP_CLK and S_AXI_ACLK tied to 100 MHz source shared with MB instance

2. In Vitis:

static XHwIcap icapHandle;
XHwIcap_config *config = XHwIcap_LookupConfig(XPAR_HWICAP_0_DEVICE_ID);
XHwIcap_CfgInitialize(&icapHandle, config, config->BaseAddress);



Go back to Vivado and have "Disable Read FIFO -> unchecked". No other changes. The CfgInitialize function will now return with XST_SUCCESS and further operations with HWICAP on the embedded hardware will succeed.


This seems to be an error in the implementation for CfgInitialize in xhwicap.c. It does not handle the case where the read FIFO is not included in the HWICAP instance as it seems through the Vitis debugger that it gets stuck attempting to read back all words in the read FIFO in a loop. For some reason the read FIFO occupancy is one and never decrements no matter how many times the code tries to wait for it to clear.

0 Kudos
0 Replies