From 99faf8dfa0ea3e67fa0d800bc72d45d5042db359 Mon Sep 17 00:00:00 2001 From: Jean THOMAS Date: Fri, 7 Aug 2020 18:17:35 +0200 Subject: [PATCH] gram.core.multiplexer: Cleaner code in _Steerer --- gram/core/multiplexer.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gram/core/multiplexer.py b/gram/core/multiplexer.py index 4efdd17..f984b3a 100644 --- a/gram/core/multiplexer.py +++ b/gram/core/multiplexer.py @@ -164,10 +164,10 @@ class _Steerer(Elaboratable): rankbits = log2_int(nranks) if hasattr(phase, "reset"): m.d.comb += phase.reset.eq(0) - m.d.comb += phase.clk_en.eq(Repl(Signal(reset=1), nranks)) + m.d.comb += phase.clk_en.eq(Repl(1, nranks)) if hasattr(phase, "odt"): # FIXME: add dynamic drive for multi-rank (will be needed for high frequencies) - m.d.comb += phase.odt.eq(Repl(Signal(reset=1), nranks)) + m.d.comb += phase.odt.eq(Repl(1, nranks)) if rankbits: rank_decoder = Decoder(nranks) m.submodules += rank_decoder @@ -180,8 +180,7 @@ class _Steerer(Elaboratable): m.d.sync += phase.cs.eq(rank_decoder.o) else: m.d.sync += phase.cs.eq(rank_decoder.o) - m.d.sync += phase.bank.eq(Array(cmd.ba[:-rankbits] - for cmd in commands)[sel]) + m.d.sync += phase.bank.eq(Array(cmd.ba[:-rankbits] for cmd in commands)[sel]) else: m.d.sync += [ phase.cs.eq(1), -- 2.30.2