summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGabe Black <gabeblack@google.com>2019-10-28 19:55:15 -0700
committerGabe Black <gabeblack@google.com>2019-10-30 08:51:02 +0000
commit1c8ce99ac3a19bb93df13aa6b0b0c976bfe56e89 (patch)
tree8f980990662a1cd2466d1c7760512aaaede1b39e
parentf5f60a5e467f74dc14b10d431795363deff33b76 (diff)
downloadgem5-1c8ce99ac3a19bb93df13aa6b0b0c976bfe56e89.tar.xz
dev: Get PageBytes from the system in the ARM generic timer.
These will ultimately by ArmISA::PageBytes, but this is more consistent with other devices which don't know what ISA they're part of. Change-Id: Iac13d5010564512207ed009377a771ee5949eff3 Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/22269 Tested-by: kokoro <noreply+kokoro@google.com> Reviewed-by: Jason Lowe-Power <jason@lowepower.com> Maintainer: Jason Lowe-Power <jason@lowepower.com>
-rw-r--r--src/dev/arm/generic_timer.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/dev/arm/generic_timer.cc b/src/dev/arm/generic_timer.cc
index 396926f40..430b4ebfa 100644
--- a/src/dev/arm/generic_timer.cc
+++ b/src/dev/arm/generic_timer.cc
@@ -524,8 +524,9 @@ GenericTimerISA::readMiscReg(int reg)
GenericTimerMem::GenericTimerMem(GenericTimerMemParams *p)
: PioDevice(p),
- ctrlRange(RangeSize(p->base, TheISA::PageBytes)),
- timerRange(RangeSize(p->base + TheISA::PageBytes, TheISA::PageBytes)),
+ ctrlRange(RangeSize(p->base, sys->getPageBytes())),
+ timerRange(RangeSize(p->base + sys->getPageBytes(),
+ sys->getPageBytes())),
addrRanges{ctrlRange, timerRange},
systemCounter(),
physTimer(csprintf("%s.phys_timer0", name()),