From 38646d48ebd32c551ce3c478e9dee47f83acdf1e Mon Sep 17 00:00:00 2001 From: Andreas Hansson Date: Fri, 19 Sep 2014 10:35:04 -0400 Subject: mem: Add checks to sendTimingReq in cache A small fix to ensure the return value is not ignored. --- src/mem/cache/cache_impl.hh | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src/mem') diff --git a/src/mem/cache/cache_impl.hh b/src/mem/cache/cache_impl.hh index a792de19d..8c091fa39 100644 --- a/src/mem/cache/cache_impl.hh +++ b/src/mem/cache/cache_impl.hh @@ -462,7 +462,9 @@ Cache::recvTimingReq(PacketPtr pkt) // Just forward the packet if caches are disabled. if (system->bypassCaches()) { - memSidePort->sendTimingReq(pkt); + // @todo This should really enqueue the packet rather + bool M5_VAR_USED success = memSidePort->sendTimingReq(pkt); + assert(success); return true; } @@ -483,7 +485,10 @@ Cache::recvTimingReq(PacketPtr pkt) snoopPkt->busFirstWordDelay = snoopPkt->busLastWordDelay = 0; snoopPkt->setExpressSnoop(); snoopPkt->assertMemInhibit(); - memSidePort->sendTimingReq(snoopPkt); + bool M5_VAR_USED success = memSidePort->sendTimingReq(snoopPkt); + // the packet is marked inhibited and will thus bypass any + // flow control + assert(success); // main memory will delete snoopPkt } // since we're the official target but we aren't responding, -- cgit v1.2.3