Double packet delete problem is due to an interrupt device deleting a packet that the SimpleTimingPort also deletes. Since MessagePort descends from SimpleTimingPort, simply reimplement the failing code from SimpleTimingPort: recvTiming.
low.deliveryStatus = 0;
regs[APIC_INTERRUPT_COMMAND_LOW] = low;
}
- delete pkt->req;
- delete pkt;
DPRINTF(LocalApic, "ICR is now idle.\n");
return 0;
}
ApicList::iterator apicIt;
for (apicIt = apics.begin(); apicIt != apics.end(); apicIt++) {
PacketPtr pkt = buildIntRequest(*apicIt, message);
- if (timing)
+ if (timing) {
sendMessageTiming(pkt, latency);
- else
+ // The target handles cleaning up the packet in timing mode.
+ } else {
sendMessageAtomic(pkt);
+ delete pkt->req;
+ delete pkt;
+ }
}
}
virtual Tick
recvResponse(PacketPtr pkt)
{
- delete pkt->req;
- delete pkt;
return 0;
}