Skip to content

Commit

Permalink
More fixes to amba components
Browse files Browse the repository at this point in the history
  • Loading branch information
jerryz123 committed Aug 20, 2023
1 parent 9aaac40 commit 13fe404
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/main/scala/amba/ahb/Xbar.scala
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class AHBFanout()(implicit p: Parameters) extends LazyModule {

when (in.hready) { d_sel := a_sel }
(a_sel zip io_out) foreach { case (sel, out) =>
out :<>= in
out.squeezeAll :<>= in.squeezeAll
out.hsel := in.hsel && sel
out.hmaster.map { _ := 0.U }
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/scala/amba/apb/Xbar.scala
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class APBFanout()(implicit p: Parameters) extends LazyModule {

val sel = VecInit(route_addrs.map(seq => seq.map(_.contains(in.paddr)).reduce(_ || _)))
(sel zip io_out) foreach { case (sel, out) =>
out :<>= in
out.squeezeAll :<>= in.squeezeAll
out.psel := sel && in.psel
out.penable := sel && in.penable
}
Expand Down
8 changes: 4 additions & 4 deletions src/main/scala/amba/axi4/RegisterRouter.scala
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ case class AXI4RegisterNode(address: AddressSet, concurrency: Int = 0, beatBytes
aw.ready := in.ready && !ar.valid && w .valid
w .ready := in.ready && !ar.valid && aw.valid

ar_extra :<= ar.bits.echo
aw_extra :<= aw.bits.echo
ar_extra.waiveAll :<= ar.bits.echo
aw_extra.waiveAll :<= aw.bits.echo
ar_extra(AXI4RRId) := ar.bits.id
aw_extra(AXI4RRId) := aw.bits.id
val addr = Mux(ar.valid, ar.bits.addr, aw.bits.addr)
Expand All @@ -75,11 +75,11 @@ case class AXI4RegisterNode(address: AddressSet, concurrency: Int = 0, beatBytes
r.bits.data := out.bits.data
r.bits.last := true.B
r.bits.resp := AXI4Parameters.RESP_OKAY
r.bits.echo :<= out.bits.extra
r.bits.echo :<= out.bits.extra.waiveAll

b.bits.id := out.bits.extra(AXI4RRId)
b.bits.resp := AXI4Parameters.RESP_OKAY
b.bits.echo :<= out.bits.extra
b.bits.echo :<= out.bits.extra.waiveAll
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/main/scala/amba/axi4/Xbar.scala
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ class AXI4Xbar(
// Transform output bundles
val out = Wire(Vec(io_out.size, new AXI4Bundle(wide_bundle)))
for (i <- 0 until out.size) {
io_out(i) :<>= out(i)
io_out(i).squeezeAll :<>= out(i).squeezeAll

if (io_in.size > 1) {
// Block AW if we cannot record the W source
Expand Down

0 comments on commit 13fe404

Please sign in to comment.