Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[tlul,rtl] Correct the calculation of data_intg in tlul_adapter_sram
This is the value that gets supplied as a user field that provides data integrity. If we are responding with an error response, we need to make sure we send integrity bits that correspond. The logic that was previously here detected this condition with (vld_rd_rsp && reqfifo_rdata.error) but that is wrong because it shouldn't depend on vld_rd_rsp. Imagine we send a TL write with a TL error. When we read the response, the d_error flag will be high (because u_reqfifo contains the faulty TL write) and d_data will be error_blanking_data. But the integrity bits will be SecdedInv3932ZeroEcc because vld_rd_rsp is false (we haven't seen a TL read at all!) This is also possible to trigger by using only reads. Suppose we send an TL read with a TL error and then, a few cycles later, read the TL response. When we read the response, the d_error flag will again be high (because u_reqfifo contains the faulty TL read). Again, d_data will (correctly) be error_blanking_data. Again, we should be using error_blanking_integ for error bits but we actually use SecdedInv3932ZeroEcc. Dropping the vld_rd_rsp term will fix the behaviour in both cases. So it remains in sync with the RTL, we also drop a conditional coverage exclusion for rom_ctrl. Tracking down how it was actually possible to see this happen led us to the design change. Signed-off-by: Rupert Swarbrick <[email protected]>
- Loading branch information