Index: firmware/thread.c
===================================================================
--- firmware/thread.c	(revision 29005)
+++ firmware/thread.c	(working copy)
@@ -37,7 +37,7 @@
  ***************************************************************************/
 
 /* Define THREAD_EXTRA_CHECKS as 1 to enable additional state checks */
-#ifdef DEBUG
+#if 1 //def DEBUG
 #define THREAD_EXTRA_CHECKS 1 /* Always 1 for DEBUG */
 #else
 #define THREAD_EXTRA_CHECKS 0
@@ -656,7 +656,10 @@
         next = bl->thread;
 
         if (UNLIKELY(next == tstart))
+        {
+            THREAD_PANICF("Deadlock detected!", current);
             break; /* Full-circle - deadlock! */
+        }
 
         UNLOCK_THREAD(current);
 
@@ -756,7 +759,10 @@
         next = bl->thread;
 
         if (UNLIKELY(next == tstart))
+        {
+            THREAD_PANICF("Deadlock detected!", tstart);
             break; /* Full-circle - deadlock! */
+        }
 
         UNLOCK_THREAD(thread);
 
@@ -2064,7 +2070,10 @@
                     next = bl->thread;
 
                     if (UNLIKELY(next == tstart))
+                    {
+                        THREAD_PANICF("Deadlock detected!", tstart);
                         break; /* Full-circle */
+                    }
 
                     UNLOCK_THREAD(thread);
 
