soc/interconnect/stream/SyncFIFO: expose fifo level
This commit is contained in:
parent
7ed2576ce1
commit
2f52d364af
|
@ -113,6 +113,7 @@ class SyncFIFO(_FIFOWrapper):
|
||||||
self,
|
self,
|
||||||
fifo.SyncFIFOBuffered if buffered else fifo.SyncFIFO,
|
fifo.SyncFIFOBuffered if buffered else fifo.SyncFIFO,
|
||||||
layout, depth)
|
layout, depth)
|
||||||
|
self.level = self.fifo.level
|
||||||
|
|
||||||
|
|
||||||
class AsyncFIFO(_FIFOWrapper):
|
class AsyncFIFO(_FIFOWrapper):
|
||||||
|
|
|
@ -379,6 +379,6 @@ class Buffer(Module):
|
||||||
# compute almost full
|
# compute almost full
|
||||||
if almost_full is not None:
|
if almost_full is not None:
|
||||||
self.almost_full = Signal()
|
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
|
# XXX
|
||||||
|
|
Loading…
Reference in New Issue