summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Reinhardt <stever@eecs.umich.edu>2007-06-30 17:51:29 -0700
committerSteve Reinhardt <stever@eecs.umich.edu>2007-06-30 17:51:29 -0700
commitd10a843723009ddee79cdbf94a46704df1e5cee6 (patch)
treeb0c094f434e0dd0ca04c4812d671bbddc8a7d85f
parentee54ad318a63e868ab10bbc1b714bbb8209a11da (diff)
downloadgem5-d10a843723009ddee79cdbf94a46704df1e5cee6.tar.xz
Get rid of obsolete fixPacket() functions.
Handled by Packet::checkFunctional() now. --HG-- extra : convert_revision : 63642254e2789c80a369ac269f317ec054ffe3c0
-rw-r--r--src/mem/packet.cc25
-rw-r--r--src/mem/packet.hh16
-rw-r--r--src/mem/tport.cc7
3 files changed, 2 insertions, 46 deletions
diff --git a/src/mem/packet.cc b/src/mem/packet.cc
index 55fe13f3c..8de02f533 100644
--- a/src/mem/packet.cc
+++ b/src/mem/packet.cc
@@ -164,31 +164,6 @@ Packet::intersect(PacketPtr p)
return !(s1 > e2 || e1 < s2);
}
-bool
-fixDelayedResponsePacket(PacketPtr func, PacketPtr timing)
-{
- bool result;
-
- if (timing->isRead() || timing->isWrite()) {
- // Ugly hack to deal with the fact that we queue the requests
- // and don't convert them to responses until we issue them on
- // the bus. I tried to avoid this by converting packets to
- // responses right away, but this breaks during snoops where a
- // responder may do the conversion before other caches have
- // done the snoop. Would work if we copied the packet instead
- // of just hanging on to a pointer.
- MemCmd oldCmd = timing->cmd;
- timing->cmd = timing->cmd.responseCommand();
- result = fixPacket(func, timing);
- timing->cmd = oldCmd;
- }
- else {
- //Don't toggle if it isn't a read/write response
- result = fixPacket(func, timing);
- }
-
- return result;
-}
bool
Packet::checkFunctional(Addr addr, int size, uint8_t *data)
diff --git a/src/mem/packet.hh b/src/mem/packet.hh
index 10b9f490c..16bc6f458 100644
--- a/src/mem/packet.hh
+++ b/src/mem/packet.hh
@@ -574,22 +574,6 @@ class Packet : public FastAlloc
}
};
-
-
-/** Temporary for backwards compatibility.
- */
-inline
-bool fixPacket(PacketPtr func, PacketPtr timing) {
- return !func->checkFunctional(timing);
-}
-
-/** This function is a wrapper for the fixPacket field that toggles
- * the hasData bit it is used when a response is waiting in the
- * caches, but hasn't been marked as a response yet (so the fixPacket
- * needs to get the correct value for the hasData)
- */
-bool fixDelayedResponsePacket(PacketPtr func, PacketPtr timing);
-
std::ostream & operator<<(std::ostream &o, const Packet &p);
#endif //__MEM_PACKET_HH
diff --git a/src/mem/tport.cc b/src/mem/tport.cc
index d6ff64608..a4f791048 100644
--- a/src/mem/tport.cc
+++ b/src/mem/tport.cc
@@ -40,11 +40,8 @@ SimpleTimingPort::checkFunctional(PacketPtr pkt)
PacketPtr target = i->pkt;
// If the target contains data, and it overlaps the
// probed request, need to update data
- if (target->intersect(pkt)) {
- if (!fixPacket(pkt, target)) {
- // fixPacket returns true for continue, false for done
- return;
- }
+ if (pkt->checkFunctional(target)) {
+ return;
}
}
}