mem-cache: Only pendingModified MSHRs can satisfy CMO snoops
[gem5.git] / src / mem / cache / mshr.cc
index f1a9b985e3a84946a85a99043584111d61d227c1..493b7f02101a5fc04b70a79c36cfc1c6cad5c341 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012-2013, 2015-2017 ARM Limited
+ * Copyright (c) 2012-2013, 2015-2018 ARM Limited
  * All rights reserved.
  *
  * The license below extends only to copyright in the software and shall
@@ -452,7 +452,7 @@ MSHR::handleSnoop(PacketPtr pkt, Counter _order)
             postInvalidate = true;
         }
 
-        if (pkt->isClean()) {
+        if (isPendingModified() && pkt->isClean()) {
             pkt->setSatisfied();
         }
     }