soc/interconnect/stream/SyncFIFO: expose fifo level

This commit is contained in:
Florent Kermarrec 2015-11-16 16:11:31 +01:00
parent 7ed2576ce1
commit 2f52d364af
2 changed files with 2 additions and 1 deletions

View File

@ -113,6 +113,7 @@ class SyncFIFO(_FIFOWrapper):
self,
fifo.SyncFIFOBuffered if buffered else fifo.SyncFIFO,
layout, depth)
self.level = self.fifo.level
class AsyncFIFO(_FIFOWrapper):

View File

@ -379,6 +379,6 @@ class Buffer(Module):
# compute almost full
if almost_full is not None:
self.almost_full = Signal()
self.comb += self.almost_full.eq(data_fifo.fifo.level > almost_full)
self.comb += self.almost_full.eq(data_fifo.level > almost_full)
# XXX