diff options
Diffstat (limited to 'src/dev/sparc/iob.cc')
-rw-r--r-- | src/dev/sparc/iob.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/dev/sparc/iob.cc b/src/dev/sparc/iob.cc index c8462b9be..55cb93f37 100644 --- a/src/dev/sparc/iob.cc +++ b/src/dev/sparc/iob.cc @@ -91,7 +91,8 @@ Iob::readIob(PacketPtr pkt) { Addr accessAddr = pkt->getAddr() - iobManAddr; - if (accessAddr >= IntManAddr && accessAddr < IntManAddr + IntManSize) { + assert(IntManAddr == 0); + if (accessAddr < IntManAddr + IntManSize) { int index = (accessAddr - IntManAddr) >> 3; uint64_t data = intMan[index].cpu << 8 | intMan[index].vector << 0; pkt->set(data); @@ -186,7 +187,8 @@ Iob::writeIob(PacketPtr pkt) int index; uint64_t data; - if (accessAddr >= IntManAddr && accessAddr < IntManAddr + IntManSize) { + assert(IntManAddr == 0); + if (accessAddr < IntManAddr + IntManSize) { index = (accessAddr - IntManAddr) >> 3; data = pkt->get<uint64_t>(); intMan[index].cpu = bits(data,12,8); |