Fixed HTRANS not changing after accepting HREADY. This exposed a bug in uncore.

This commit is contained in:
Ross Thompson 2022-09-29 11:24:15 -05:00
parent 638e506d0b
commit 146ff6ff6a
3 changed files with 2 additions and 4 deletions

View File

@ -140,7 +140,6 @@ module buscachefsm #(parameter integer WordCountThreshold,
// AHB bus interface
assign HTRANS = (CurrState == ADR_PHASE & HREADY & (|BusRW | |CacheBusRW)) |
(CurrState == DATA_PHASE & ~HREADY) | // *** this is wrong.
(CacheAccess & FinalWordCount & |CacheBusRW & HREADY) ? AHB_NONSEQ : // if we have a pipelined request
(CacheAccess & |WordCount) ? (`BURST_EN ? AHB_SEQ : AHB_NONSEQ) : AHB_IDLE;

View File

@ -76,8 +76,7 @@ module busfsm
assign BusCommitted = CurrState != ADR_PHASE;
assign HTRANS = (CurrState == ADR_PHASE & HREADY & |BusRW) |
(CurrState == DATA_PHASE & ~HREADY) ? AHB_NONSEQ : AHB_IDLE;
assign HTRANS = (CurrState == ADR_PHASE & HREADY & |BusRW) ? AHB_NONSEQ : AHB_IDLE;
assign HWRITE = BusRW[0];
assign CaptureEn = CurrState == DATA_PHASE;

View File

@ -203,6 +203,6 @@ module uncore (
// However on reset None must be seleted.
flopenr #(10) hseldelayreg(HCLK, ~HRESETn, HREADY, HSELRegions[10:1], {HSELDTIMD, HSELIROMD, HSELEXTD, HSELBootRomD, HSELRamD, HSELCLINTD, HSELGPIOD, HSELUARTD, HSELPLICD, HSELSDCD});
flopenl #(1) hseldelayreg2(HCLK, ~HRESETn, HREADY, HSELRegions[0], 1'b1, HSELNoneD);
flopr #(1) hselbridgedelayreg(HCLK, ~HRESETn, HSELBRIDGE, HSELBRIDGED);
flopenr #(1) hselbridgedelayreg(HCLK, ~HRESETn, HREADY, HSELBRIDGE, HSELBRIDGED);
endmodule