Skip to content

Commit

Permalink
core/_Storage: fix size of length/offset signals.
Browse files Browse the repository at this point in the history
  • Loading branch information
enjoy-digital committed Sep 2, 2020
1 parent 02b543e commit bd10138
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions litescope/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,12 +162,10 @@ def __init__(self, data_width, depth):
self.specials += MultiReg(self.enable.storage, enable, "scope")
self.sync.scope += enable_d.eq(enable)

length = Signal(max=depth)
offset = Signal(max=depth)
self.specials += [
MultiReg(self.length.storage, length, "scope"),
MultiReg(self.offset.storage, offset, "scope")
]
length = Signal().like(self.length.storage)
offset = Signal().like(self.offset.storage)
self.specials += MultiReg(self.length.storage, length, "scope")
self.specials += MultiReg(self.offset.storage, offset, "scope")

# Status re-synchronization
done = Signal()
Expand Down

0 comments on commit bd10138

Please sign in to comment.