mirror of
https://github.com/enjoy-digital/litex.git
synced 2025-01-04 09:52:26 -05:00
genlib/roundrobin: fix n==1 case (correctly)
This commit is contained in:
parent
b8ff2f2792
commit
6e1195415e
1 changed files with 1 additions and 1 deletions
|
@ -5,7 +5,7 @@ from migen.fhdl.std import *
|
|||
class RoundRobin(Module):
|
||||
def __init__(self, n, switch_policy=SP_WITHDRAW):
|
||||
self.request = Signal(n)
|
||||
self.grant = Signal(max=max(1, n))
|
||||
self.grant = Signal(max=max(2, n))
|
||||
self.switch_policy = switch_policy
|
||||
if self.switch_policy == SP_CE:
|
||||
self.ce = Signal()
|
||||
|
|
Loading…
Reference in a new issue