summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAli Saidi <saidi@eecs.umich.edu>2006-05-31 13:47:35 -0400
committerAli Saidi <saidi@eecs.umich.edu>2006-05-31 13:47:35 -0400
commit4d8ea8dc4774b7673cc98cfd3556b9af611ed6e7 (patch)
tree37e1845ac85f583ef6774859d62d1bd0ecd483c2 /src
parentd77d39daee5c3ba8483d58911a1d5b12c4707040 (diff)
parent0193c3fe7d8512124ef6bd7cca4794e58f762f4c (diff)
downloadgem5-4d8ea8dc4774b7673cc98cfd3556b9af611ed6e7.tar.xz
Merge zizzer:/bk/newmem
into zeep.pool:/z/saidi/work/m5.newmem --HG-- extra : convert_revision : ebd55fc18b09821712f73867c93bd3d888e7788c
Diffstat (limited to 'src')
-rw-r--r--src/dev/io_device.cc24
1 files changed, 14 insertions, 10 deletions
diff --git a/src/dev/io_device.cc b/src/dev/io_device.cc
index c644308b6..1a118812c 100644
--- a/src/dev/io_device.cc
+++ b/src/dev/io_device.cc
@@ -143,15 +143,19 @@ void
DmaPort::recvRetry()
{
Packet* pkt = transmitList.front();
- DPRINTF(DMA, "Retry on Packet %#x with senderState: %#x\n",
- pkt, pkt->senderState);
- if (sendTiming(pkt)) {
- DPRINTF(DMA, "-- Done\n");
- transmitList.pop_front();
- pendingCount--;
- assert(pendingCount >= 0);
- } else {
- DPRINTF(DMA, "-- Failed, queued\n");
+ bool result = true;
+ while (result && transmitList.size()) {
+ DPRINTF(DMA, "Retry on Packet %#x with senderState: %#x\n",
+ pkt, pkt->senderState);
+ result = sendTiming(pkt);
+ if (result) {
+ DPRINTF(DMA, "-- Done\n");
+ transmitList.pop_front();
+ pendingCount--;
+ assert(pendingCount >= 0);
+ } else {
+ DPRINTF(DMA, "-- Failed, queued\n");
+ }
}
}
@@ -198,7 +202,7 @@ DmaPort::sendDma(Packet *pkt)
if (state == Timing) { */
DPRINTF(DMA, "Attempting to send Packet %#x with senderState: %#x\n",
pkt, pkt->senderState);
- if (!sendTiming(pkt)) {
+ if (transmitList.size() || !sendTiming(pkt)) {
transmitList.push_back(pkt);
DPRINTF(DMA, "-- Failed: queued\n");
} else {