Add assertion for rogue external ack strobes. Clarify recommended external ack tieoff. #57

This commit is contained in:
Alex Mykyta
2023-08-01 20:30:16 -07:00
parent 45eb47cdb1
commit 8a6f525ee2
2 changed files with 10 additions and 0 deletions

View File

@@ -71,6 +71,9 @@ hwif_in..rd_ack
Single-cycle strobe indicating a read transfer has completed.
Qualifies all other read response signals.
If the transfer is always completed in the same cycle, it is acceptable to
tie this signal to ``hwif_out..req && !hwif_out..req_is_wr``.
hwif_in..rd_data
Read response data.
@@ -79,6 +82,9 @@ Write Response
hwif_in..wr_ack
Single-cycle strobe indicating a write transfer has completed.
If the transfer is always completed in the same cycle, it is acceptable to
tie this signal to ``hwif_out..req && hwif_out..req_is_wr``.
External Blocks

View File

@@ -56,6 +56,10 @@ module {{ds.module_name}} (
end else begin
if(external_req & ~external_wr_ack & ~external_rd_ack) external_pending <= '1;
else if(external_wr_ack | external_rd_ack) external_pending <= '0;
assert(external_wr_ack -> (external_pending | external_req))
else $error("An external wr_ack strobe was asserted when no external request was active");
assert(external_rd_ack -> (external_pending | external_req))
else $error("An external rd_ack strobe was asserted when no external request was active");
end
end
{%- endif %}