-#define SLOT_LOCK() do { pthread_mutex_lock(&g_slot_mutex); /* debug_msg("After Slot_mutex LOCK"); */ } while (0)
-#define SLOT_UNLOCK() do { pthread_mutex_unlock(&g_slot_mutex); /* debug_msg("After Slot_mutex UNLOCK"); */ } while (0)
+#ifdef DEBUG_DETAIL
+#define SLOT_LOCK() do { \
+ debug_msg("Before Slot_mutex LOCK"); \
+ pthread_mutex_lock(&g_slot_mutex); \
+ debug_msg("After Slot_mutex LOCK"); \
+} while (0)
+#define SLOT_UNLOCK() do { \
+ debug_msg("Before Slot_mutex UNLOCK"); \
+ pthread_mutex_unlock(&g_slot_mutex); \
+ debug_msg("After Slot_mutex UNLOCK"); \
+} while (0)
+#else
+#define SLOT_LOCK() do { pthread_mutex_lock(&g_slot_mutex); } while (0)
+#define SLOT_UNLOCK() do { pthread_mutex_unlock(&g_slot_mutex); } while (0)
+#endif