mirror of
https://github.com/enjoy-digital/litex.git
synced 2025-01-04 09:52:26 -05:00
fhdl/structure: disable we_granularity when larger than width
This commit is contained in:
parent
d2c61e6a90
commit
27d87c9412
1 changed files with 2 additions and 0 deletions
|
@ -335,6 +335,8 @@ class Memory(HUID):
|
|||
def get_port(self, write_capable=False, async_read=False,
|
||||
has_re=False, we_granularity=0, mode=WRITE_FIRST,
|
||||
clock_domain="sys"):
|
||||
if we_granularity >= self.width:
|
||||
we_granularity = 0
|
||||
adr = Signal(BV(bits_for(self.depth-1)))
|
||||
dat_r = Signal(BV(self.width))
|
||||
if write_capable:
|
||||
|
|
Loading…
Reference in a new issue