Index: /branches/reconfiguration/modules/vci_cc_vcache_wrapper/caba/source/src/vci_cc_vcache_wrapper.cpp
===================================================================
--- /branches/reconfiguration/modules/vci_cc_vcache_wrapper/caba/source/src/vci_cc_vcache_wrapper.cpp	(revision 923)
+++ /branches/reconfiguration/modules/vci_cc_vcache_wrapper/caba/source/src/vci_cc_vcache_wrapper.cpp	(revision 924)
@@ -2256,6 +2256,6 @@
     m_drsp.rdata = 0;
 
-    // watchdog timeout default value
-    bool dcache_watchdog_timeout = false;
+    // watchdog timeout signal
+    bool dcache_watchdog_timeout = (r_dcache_wdt.read() == r_dcache_wdt_max.read());
 
     switch (r_dcache_fsm.read())
@@ -4183,7 +4183,10 @@
         // increment watchdog timer for black-hole detection
         r_dcache_wdt = r_dcache_wdt.read() + 1;
-        if (r_dcache_wdt.read() == r_dcache_wdt_max.read())
-        {
-            dcache_watchdog_timeout = true;
+        if (dcache_watchdog_timeout)
+        {
+            r_mmu_detr = MMU_WDT_TIMEOUT;
+            m_drsp.valid = true;
+            m_drsp.error = true;
+            r_dcache_fsm = DCACHE_IDLE;
 
             // TODO: send the TRDID in the coherence packet to detect an early
@@ -4203,17 +4206,13 @@
             }
 #endif
+            break;
         }
 
         // wait the CC_TEST request to finish
-        if (not r_dcache_to_cc_test_req.read() or dcache_watchdog_timeout)
-        {
-            if (dcache_watchdog_timeout)
-            {
-                r_mmu_detr   = MMU_WDT_TIMEOUT;
-                m_drsp.error = true;
-            }
+        if (not r_dcache_to_cc_test_req.read())
+        {
             m_drsp.valid = true;
-
             r_dcache_fsm = DCACHE_IDLE;
+
 #if DEBUG_DCACHE
             if (m_debug_dcache_fsm)
@@ -4223,5 +4222,4 @@
                     << std::hex
                     << " / DEST = " << r_dcache_to_cc_test_dest.read()
-                    << " / TIMEOUT = " << dcache_watchdog_timeout
                     << std::dec << std::endl;
             }
@@ -4415,5 +4413,5 @@
         // increment watchdog timer for black-hole detection
         r_dcache_wdt = r_dcache_wdt.read() + 1;
-        if (r_dcache_wdt.read() == r_dcache_wdt_max.read())
+        if (dcache_watchdog_timeout)
         {
             r_mmu_detr   = MMU_WDT_TIMEOUT;
@@ -4659,5 +4657,5 @@
         // increment watchdog timer for black-hole detection
         r_dcache_wdt = r_dcache_wdt.read() + 1;
-        if (r_dcache_wdt.read() == r_dcache_wdt_max.read())
+        if (dcache_watchdog_timeout)
         {
             r_mmu_detr   = MMU_WDT_TIMEOUT;
