From 34852e406dec92007be62fc877a8f4026ac207db Mon Sep 17 00:00:00 2001 From: Howard Mao Date: Mon, 28 Mar 2016 12:22:43 -0700 Subject: [PATCH] fix bug in NastiRouter --- junctions/src/main/scala/nasti.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/junctions/src/main/scala/nasti.scala b/junctions/src/main/scala/nasti.scala index b2e0aa59..75cfb0ec 100644 --- a/junctions/src/main/scala/nasti.scala +++ b/junctions/src/main/scala/nasti.scala @@ -408,8 +408,8 @@ class NastiRouter(nSlaves: Int, routeSel: UInt => UInt)(implicit p: Parameters) aw_ready = aw_ready || (s.aw.ready && aw_route(i)) val chosen = Reg(init = Bool(false)) - when (s.aw.fire()) { chosen := Bool(true) } when (s.w.fire() && s.w.bits.last) { chosen := Bool(false) } + when (s.aw.fire()) { chosen := Bool(true) } s.w.valid := io.master.w.valid && chosen s.w.bits := io.master.w.bits