Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
  • 2 commits
  • 2 files changed
  • 0 commit comments
  • 1 contributor
Showing with 16 additions and 10 deletions.
  1. +6 −2 migen/actorlib/dma_asmi.py
  2. +10 −8 migen/flow/network.py
View
8 migen/actorlib/dma_asmi.py
@@ -89,7 +89,8 @@ def __init__(self, port):
port.adr.eq(self.address_data.payload.a),
port.we.eq(1),
port.stb.eq(self.address_data.stb),
- self.address_data.ack.eq(port.ack)
+ self.address_data.ack.eq(port.ack),
+ port.dat_wm.eq(0)
]
self.sync += [
port.dat_w.eq(0),
@@ -112,7 +113,10 @@ def __init__(self, port, n):
drive_data = Signal()
data_reg = Signal(port.hub.dw)
- self.comb += If(drive_data, port.dat_w.eq(data_reg))
+ self.comb += [
+ If(drive_data, port.dat_w.eq(data_reg)),
+ port.dat_wm.eq(0)
+ ]
self.sync += [
If(port.stb & port.ack & (port.tag_issue == (port.base + n)),
View
18 migen/flow/network.py
@@ -151,24 +151,26 @@ def _infer_plumbing_layout(self):
if not ap:
break
for a in ap:
- if a.actor_class in plumbing.layout_sink:
- edges = self.in_edges(a, data=True)
- assert(len(edges) == 1)
- other, me, data = edges[0]
+ in_edges = self.in_edges(a, data=True)
+ out_edges = self.out_edges(a, data=True)
+ if a.actor_class in plumbing.layout_sink and len(in_edges) == 1:
+ other, me, data = in_edges[0]
if isinstance(other, AbstractActor):
continue
other_ep = data["source"]
if other_ep is None:
other_ep = get_single_ep(other, Source)[1]
- elif a.actor_class in plumbing.layout_source:
- edges = self.out_edges(a, data=True)
- assert(len(edges) == 1)
- me, other, data = edges[0]
+ else:
+ other_ep = getattr(other, other_ep)
+ elif a.actor_class in plumbing.layout_source and len(out_edges) == 1:
+ me, other, data = out_edges[0]
if isinstance(other, AbstractActor):
continue
other_ep = data["sink"]
if other_ep is None:
other_ep = get_single_ep(other, Sink)[1]
+ else:
+ other_ep = getattr(other, other_ep)
else:
raise AssertionError
layout = other_ep.payload.layout

No commit comments for this range

Something went wrong with that request. Please try again.