use right offset in dcache wb address
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 29 Jan 2022 14:32:23 +0000 (14:32 +0000)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 29 Jan 2022 14:32:23 +0000 (14:32 +0000)
happened to be the same value but best to be safe, eh?

src/soc/experiment/dcache.py

index b7c059aa77051089ff47966805900ec9f4193023..2689a319c274bd5d056e1facb61f2bb844e9a9e5 100644 (file)
@@ -1463,7 +1463,7 @@ class DCache(Elaboratable):
         with m.Switch(r1.state):
 
             with m.Case(State.IDLE):
-                sync += r1.wb.adr.eq(req.real_addr[ROW_LINE_BITS:])
+                sync += r1.wb.adr.eq(req.real_addr[ROW_OFF_BITS:])
                 sync += r1.wb.sel.eq(req.byte_sel)
                 sync += r1.wb.dat.eq(req.data)
                 sync += r1.dcbz.eq(req.dcbz)