add args.bin and large extmem to config

This commit is contained in:
Richard Yan
2023-09-15 11:18:22 -07:00
parent 59b0994620
commit 1c76515f17
3 changed files with 21 additions and 10 deletions

View File

@@ -6,13 +6,14 @@
package chipyard
import chisel3._
import org.chipsalliance.cde.config.{Parameters, Field}
import org.chipsalliance.cde.config.{Field, Parameters}
import freechips.rocketchip.subsystem._
import freechips.rocketchip.tilelink._
import freechips.rocketchip.devices.tilelink._
import freechips.rocketchip.diplomacy._
import freechips.rocketchip.util.{DontTouch}
import freechips.rocketchip.util.DontTouch
import java.nio.file.Paths
// ---------------------------------------------------------------------
// Base system that uses the debug test module (dtm) to bringup the core
@@ -31,6 +32,7 @@ class ChipyardSystem(implicit p: Parameters) extends ChipyardSubsystem
val bootROM = p(BootROMLocated(location)).map { BootROM.attach(_, this, CBUS) }
val maskROMs = p(MaskROMLocated(location)).map { MaskROM.attach(_, this, CBUS) }
p(RadianceArgsROMLocated()).foreach { BootROM.attachArgs(_, this, CBUS) }
// If there is no bootrom, the tile reset vector bundle will be tied to zero
if (bootROM.isEmpty) {

View File

@@ -1,8 +1,9 @@
package chipyard
import org.chipsalliance.cde.config.{Config}
import freechips.rocketchip.diplomacy.{AsynchronousCrossing}
import org.chipsalliance.cde.config.{Config, Field}
import freechips.rocketchip.diplomacy.AsynchronousCrossing
import freechips.rocketchip.devices.tilelink.{RadianceArgsROMLocated, RadianceArgsROMParams}
import freechips.rocketchip.subsystem.WithExtMemSize
// --------------
// Rocket Configs
// --------------
@@ -11,12 +12,20 @@ class RocketConfig extends Config(
new freechips.rocketchip.subsystem.WithNBigCores(1) ++ // single rocket-core
new chipyard.config.AbstractConfig)
class WithRadArgsROM(filename: String) extends Config((site, here, up) => {
case RadianceArgsROMLocated() => up(RadianceArgsROMLocated()).map(_.copy(
contentFileName = filename))
})
class RadianceConfig extends Config(
new freechips.rocketchip.subsystem.WithRadianceCores() ++
new freechips.rocketchip.subsystem.WithIncoherentBusTopology ++
new freechips.rocketchip.subsystem.WithNoMemPort ++
new testchipip.WithSbusScratchpad(banks=2) ++
new freechips.rocketchip.subsystem.WithCoherentBusTopology ++
// new freechips.rocketchip.subsystem.WithNoMemPort ++
// new testchipip.WithSbusScratchpad(banks=2) ++
// new testchipip.WithMbusScratchpad(banks=2) ++
new WithExtMemSize(BigInt("80000000", 16)) ++
new WithRadArgsROM("sims/vcs/args.bin") ++
new chipyard.config.AbstractConfig)
class TinyRocketConfig extends Config(