projects
/
litex.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b96eb33
)
genlib/roundrobin.py: fix n==1 case
author
Robert Jordens
<jordens@gmail.com>
Thu, 25 Jul 2013 21:55:05 +0000
(15:55 -0600)
committer
Sebastien Bourdeauducq
<sebastien@milkymist.org>
Thu, 25 Jul 2013 22:41:08 +0000
(
00:41
+0200)
migen/genlib/roundrobin.py
patch
|
blob
|
history
diff --git
a/migen/genlib/roundrobin.py
b/migen/genlib/roundrobin.py
index 15bec5c7f3bce3dd30082277901b51a575494031..cf42e9436523765ca1296d6ccf8d54a61dd43d65 100644
(file)
--- a/
migen/genlib/roundrobin.py
+++ b/
migen/genlib/roundrobin.py
@@
-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=
n
)
+ self.grant = Signal(max=
max(1, n)
)
self.switch_policy = switch_policy
if self.switch_policy == SP_CE:
self.ce = Signal()