Initial commit.
[freedom-sifive.git] / src / main / scala / unleashed / u500vc707devkit / Configs.scala
1 // See LICENSE for license details.
2 package sifive.freedom.unleashed.u500vc707devkit
3
4 import config._
5 import coreplex.{WithL1DCacheWays, WithSmallCores, WithoutFPU, BootROMFile}
6 import rocketchip.{BaseConfig,WithRTCPeriod,WithJtagDTM}
7
8 // Don't use directly. Requires additional bootfile configuration
9 class DefaultFreedomUConfig extends Config(
10 new WithJtagDTM ++ new BaseConfig
11 )
12
13 class WithBootROMFile(bootROMFile: String) extends Config(
14 (pname, site, here) => pname match {
15 case BootROMFile => bootROMFile
16 case _ => throw new CDEMatchError
17 }
18 )
19
20 //----------------------------------------------------------------------------------
21 // Freedom U500 VC707 Dev Kit
22
23 class U500VC707DevKitConfig extends Config(
24 new WithBootROMFile("./bootrom/u500vc707devkit.img") ++
25 new WithRTCPeriod(62) ++ //Default value of 100 generates 1 Mhz clock @ 100Mhz, then corrected in sbi_entry.c
26 //Value 62 generates ~ 1Mhz clock @ 62.5Mhz
27 new WithoutFPU ++
28 new DefaultFreedomUConfig)