From e564fff139768e6a232d118ec7155ecf080f1bc4 Mon Sep 17 00:00:00 2001 From: Brendan Sweeney Date: Mon, 25 Jun 2018 13:47:52 -0700 Subject: Correcting documentation errors in Arbiter.scala (#839) Documentation for example had parameters in wrong order, and was missing @param. Additionally, it was lacking a module wrapper. This has been corrected.--- src/main/scala/chisel3/util/Arbiter.scala | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/main/scala/chisel3/util/Arbiter.scala b/src/main/scala/chisel3/util/Arbiter.scala index 623dd619..0da4bbc5 100644 --- a/src/main/scala/chisel3/util/Arbiter.scala +++ b/src/main/scala/chisel3/util/Arbiter.scala @@ -91,8 +91,10 @@ class LockingArbiter[T <: Data](gen: T, n: Int, count: Int, needsLock: Option[T /** Hardware module that is used to sequence n producers into 1 consumer. * Producers are chosen in round robin order. * + * @param gen data type + * @param n number of inputs * @example {{{ - * val arb = new RRArbiter(2, UInt()) + * val arb = Module(new RRArbiter(UInt(), 2)) * arb.io.in(0) <> producer0.io.out * arb.io.in(1) <> producer1.io.out * consumer.io.in <> arb.io.out @@ -104,8 +106,11 @@ class RRArbiter[T <: Data](gen:T, n: Int) extends LockingRRArbiter[T](gen, n, 1) /** Hardware module that is used to sequence n producers into 1 consumer. * Priority is given to lower producer. * + * @param gen data type + * @param n number of inputs + * * @example {{{ - * val arb = Module(new Arbiter(2, UInt())) + * val arb = Module(new Arbiter(UInt(), 2)) * arb.io.in(0) <> producer0.io.out * arb.io.in(1) <> producer1.io.out * consumer.io.in <> arb.io.out -- cgit v1.2.3