1
0

print the base address of each SCR as indicated

This commit is contained in:
Wei Song 2016-04-28 16:31:56 +01:00
parent 81ff127dc3
commit ed5bdf3c23

View File

@ -29,9 +29,11 @@ class SCRFileMap(prefix: String, maxAddress: Int, baseAddress: BigInt) {
def as_c_header(): String = {
addr2name.map{ case(address, name) =>
"#define " + prefix + "__" + name + "__PADDR 0x%x".format(baseAddress + address)
List(
"#define " + prefix + "__" + name + "__PADDR 0x%x".format(baseAddress + address),
"#define " + prefix + "__" + name + "__OFFSET 0x%x".format(address)
}.mkString("\n") + "\n"
)
}.flatten.mkString("\n") + "\n"
}
}