1
0
Fork 0

Utils: express cacheability from TL2 to TL1

This commit is contained in:
Wesley W. Terpstra 2016-09-17 00:16:40 -07:00
parent e3d2bd3323
commit c70045b8b3
1 changed files with 7 additions and 1 deletions

View File

@ -66,10 +66,16 @@ object GenerateGlobalAddrMap {
}
lazy val tl2Devices = peripheryManagers.map { manager =>
val cacheable = manager.regionType match {
case RegionType.CACHED => true
case RegionType.TRACKED => true
case RegionType.UNCACHED => true
case _ => false
}
val attr = MemAttr(
(if (manager.supportsGet) AddrMapProt.R else 0) |
(if (manager.supportsPutFull) AddrMapProt.W else 0) |
(if (manager.executable) AddrMapProt.X else 0))
(if (manager.executable) AddrMapProt.X else 0), cacheable)
val multi = manager.address.size > 1
manager.address.zipWithIndex.map { case (address, i) =>
require (!address.strided) // TL1 can't do this