diff --git a/litedram/common.py b/litedram/common.py index cd8c330..ad95707 100644 --- a/litedram/common.py +++ b/litedram/common.py @@ -165,13 +165,14 @@ def cmd_request_rw_layout(a, ba): class tXXDController(Module): def __init__(self, txxd): self.valid = valid = Signal() - self.ready = ready = Signal() - ready.attr.add("no_retiming") + self.ready = Signal() # # # self.comb += self.ready.eq(1) if txxd is not None: + ready = Signal() + ready.attr.add("no_retiming") count = Signal(max=max(txxd, 2)) self.sync += \ If(valid, @@ -185,3 +186,4 @@ class tXXDController(Module): count.eq(count - 1), If(count == 1, ready.eq(1)) ) + self.comb += self.ready.eq(ready)