summaryrefslogtreecommitdiff
path: root/src/arch/alpha
diff options
context:
space:
mode:
authorAndreas Hansson <andreas.hansson@arm.com>2014-12-02 06:08:00 -0500
committerAndreas Hansson <andreas.hansson@arm.com>2014-12-02 06:08:00 -0500
commit74bbe20141aec3bd7639000fb6ad8ff5fe1a7237 (patch)
tree0f4c07d5ebe3810b9be06bd5db87e698f623b9c3 /src/arch/alpha
parent810349a8a789b0a99d6268fe725eca2e00cb9558 (diff)
downloadgem5-74bbe20141aec3bd7639000fb6ad8ff5fe1a7237.tar.xz
cpu: Always mask the snoop address when performing lock check
Ensure the snoop address check is always using a cache-block aligned address. This patch updates Alpha and Mips to match the other ISAs.
Diffstat (limited to 'src/arch/alpha')
-rw-r--r--src/arch/alpha/locked_mem.hh4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/arch/alpha/locked_mem.hh b/src/arch/alpha/locked_mem.hh
index 253b94be4..7998cbdf1 100644
--- a/src/arch/alpha/locked_mem.hh
+++ b/src/arch/alpha/locked_mem.hh
@@ -76,9 +76,7 @@ handleLockedSnoop(XC *xc, PacketPtr pkt, Addr cacheBlockMask)
return;
Addr locked_addr = xc->readMiscReg(MISCREG_LOCKADDR) & cacheBlockMask;
- Addr snoop_addr = pkt->getAddr();
-
- assert((cacheBlockMask & snoop_addr) == snoop_addr);
+ Addr snoop_addr = pkt->getAddr() & cacheBlockMask;
if (locked_addr == snoop_addr)
xc->setMiscReg(MISCREG_LOCKFLAG, false);