diff options
author | Ron Dreslinski <rdreslin@umich.edu> | 2006-11-12 06:35:39 -0500 |
---|---|---|
committer | Ron Dreslinski <rdreslin@umich.edu> | 2006-11-12 06:35:39 -0500 |
commit | c577665040342bf27808bfdea272626e4dac786d (patch) | |
tree | a635e61b9b235130f613150706812790258b8414 /src/mem/packet.cc | |
parent | f876bc2bf0e04b888c2748c0cabf8d11b31f41b7 (diff) | |
download | gem5-c577665040342bf27808bfdea272626e4dac786d.tar.xz |
Fix functional access errors related to delayed respnoses in cachePort
src/mem/cache/base_cache.cc:
On a delayed response, be sure to call the fixPacket wrapper to toggle hasData flag.
src/mem/packet.cc:
src/mem/packet.hh:
Create a wrapper to toggle the hasData flag on delayed responses
--HG--
extra : convert_revision : 1ced8d4e3dc12a059fb7636d59e429cd3dd46901
Diffstat (limited to 'src/mem/packet.cc')
-rw-r--r-- | src/mem/packet.cc | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/mem/packet.cc b/src/mem/packet.cc index 938116ab5..e2faf4527 100644 --- a/src/mem/packet.cc +++ b/src/mem/packet.cc @@ -144,6 +144,24 @@ Packet::intersect(PacketPtr p) } bool +fixDelayedResponsePacket(PacketPtr func, PacketPtr timing) +{ + bool result; + + if (timing->isRead() || timing->isWrite()) { + timing->toggleData(); + result = fixPacket(func, timing); + timing->toggleData(); + } + else { + //Don't toggle if it isn't a read/write response + result = fixPacket(func, timing); + } + + return result; +} + +bool fixPacket(PacketPtr func, PacketPtr timing) { Addr funcStart = func->getAddr(); |