From: Florent Kermarrec Date: Mon, 9 Mar 2015 11:45:46 +0000 (+0100) Subject: liteeth: fix cnt_inc in IDLE state (we should wait sop to inc counter) X-Git-Tag: 24jan2021_ls180~2501 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=360c849f21f4b976762a059ac34178e2a0affe77;p=litex.git liteeth: fix cnt_inc in IDLE state (we should wait sop to inc counter) --- diff --git a/misoclib/com/liteeth/mac/frontend/sram.py b/misoclib/com/liteeth/mac/frontend/sram.py index 7df9c584..cb6a4d72 100644 --- a/misoclib/com/liteeth/mac/frontend/sram.py +++ b/misoclib/com/liteeth/mac/frontend/sram.py @@ -69,10 +69,10 @@ class LiteEthMACSRAMWriter(Module, AutoCSR): self.submodules += fsm fsm.act("IDLE", - inc_cnt.eq(sink.stb), If(sink.stb & sink.sop, - ongoing.eq(1), If(fifo.sink.ack, + ongoing.eq(1), + inc_cnt.eq(1), NextState("WRITE") ) )