diff options
author | Kevin Lim <ktlim@umich.edu> | 2006-11-07 14:25:54 -0500 |
---|---|---|
committer | Kevin Lim <ktlim@umich.edu> | 2006-11-07 14:25:54 -0500 |
commit | 8ba73da056ae8b34713dc5b927d4ceb238db969a (patch) | |
tree | d374baa289829a81a33f2e6c0f8de840cce27f8b /src/mem/bus.cc | |
parent | 244e0c884c60c141ea1bc63bb93e0aee25d6a854 (diff) | |
download | gem5-8ba73da056ae8b34713dc5b927d4ceb238db969a.tar.xz |
Fix up bus draining and add draining to the caches.
src/mem/bus.cc:
Fix up draining to work properly.
src/mem/bus.hh:
Initialize drainEvent to NULL.
src/mem/cache/base_cache.cc:
src/mem/cache/base_cache.hh:
Add draining to the caches.
--HG--
extra : convert_revision : 3082220a75d50876f10909f9f99bec535889f818
Diffstat (limited to 'src/mem/bus.cc')
-rw-r--r-- | src/mem/bus.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mem/bus.cc b/src/mem/bus.cc index 28ee3476b..7b65d252b 100644 --- a/src/mem/bus.cc +++ b/src/mem/bus.cc @@ -240,10 +240,10 @@ Bus::recvRetry(int id) busIdle.reschedule(tickNextIdle); } } - //If we weren't able to drain before, we might be able to now. - if (drainEvent && retryList.size() == 0 && curTick >= tickNextIdle) - drainEvent->process(); } + //If we weren't able to drain before, we might be able to now. + if (drainEvent && retryList.size() == 0 && curTick >= tickNextIdle) + drainEvent->process(); } Port * @@ -521,10 +521,10 @@ Bus::drain(Event * de) //waiting. We might be idle but have someone waiting if the device we //contacted for a retry didn't actually retry. if (curTick >= tickNextIdle && retryList.size() == 0) { + return 0; + } else { drainEvent = de; return 1; - } else { - return 0; } } |