Index: kernel/generic/include/debug.h
===================================================================
--- kernel/generic/include/debug.h	(revision 8aa9265ecf5640a0c80c5b17e09018fd7bbaefd4)
+++ kernel/generic/include/debug.h	(revision 3500f75cbc503f782a566e67a039f9b9368cbfe2)
@@ -37,16 +37,7 @@
 
 #include <panic.h>
-#include <arch/debug.h>
+#include <symtab.h>
 
 #define CALLER  ((uintptr_t) __builtin_return_address(0))
-
-
-#ifndef HERE
-
-/** Current Instruction Pointer address */
-#define HERE ((uintptr_t *) 0)
-
-#endif /* HERE */
-
 
 #ifdef CONFIG_DEBUG
@@ -62,7 +53,8 @@
  */
 #define ASSERT(expr) \
-	if (!(expr)) { \
-		panic("Assertion failed (%s), caller=%p.", #expr, CALLER); \
-	}
+	do { \
+		if (!(expr)) \
+			panic("Assertion failed (%s)", #expr); \
+	} while (0)
 
 /** Debugging verbose ASSERT macro
@@ -78,7 +70,8 @@
  */
 #define ASSERT_VERBOSE(expr, msg) \
-	if (!(expr)) { \
-		panic("Assertion failed (%s, %s), caller=%p.", #expr, msg, CALLER); \
-	}
+	do { \
+		if (!(expr)) \
+			panic("Assertion failed (%s, %s)", #expr, msg); \
+	} while (0)
 
 #else /* CONFIG_DEBUG */
@@ -88,5 +81,4 @@
 
 #endif /* CONFIG_DEBUG */
-
 
 #ifdef CONFIG_LOG
@@ -100,6 +92,8 @@
  */
 #define LOG(format, ...) \
-	printf("%s() at %s:%u: " format "\n", __func__, __FILE__, \
-	    __LINE__, ##__VA_ARGS__);
+	do { \
+		printf("%s->%s() at %s:%u: " format "\n", symtab_fmt_name_lookup(CALLER), \
+		    __func__, __FILE__, __LINE__, ##__VA_ARGS__); \
+	} while (0)
 
 /** Extensive logging execute macro
@@ -111,14 +105,14 @@
  */
 #define LOG_EXEC(fnc) \
-	{ \
-		printf("%s() at %s:%u: " #fnc "\n", __func__, __FILE__, \
-		    __LINE__); \
+	do { \
+		printf("%s->%s() at %s:%u: " #fnc "\n", symtab_fmt_name_lookup(CALLER), \
+		    __func__, __FILE__, __LINE__); \
 		fnc; \
-	}
-	
-#else /* CONFOG_LOG */
+	} while (0)
+
+#else /* CONFIG_LOG */
 
 #define LOG(format, ...)
-#define LOG_EXEC(fnc) fnc
+#define LOG_EXEC(fnc)     fnc
 
 #endif /* CONFOG_LOG */
Index: kernel/generic/include/panic.h
===================================================================
--- kernel/generic/include/panic.h	(revision 8aa9265ecf5640a0c80c5b17e09018fd7bbaefd4)
+++ kernel/generic/include/panic.h	(revision 3500f75cbc503f782a566e67a039f9b9368cbfe2)
@@ -41,20 +41,25 @@
 
 #ifdef CONFIG_DEBUG
-#	define panic(format, ...) \
-		do { \
-			silent = false; \
-			printf("Kernel panic in %s() at %s:%u.\n", \
-			    __func__, __FILE__, __LINE__); \
-			stack_trace(); \
-			panic_printf("Panic message: " format "\n", \
-			    ##__VA_ARGS__);\
-		} while (0)
-#else
-#	define panic(format, ...) \
-		do { \
-			silent = false; \
-			panic_printf("Kernel panic: " format "\n", ##__VA_ARGS__); \
-		} while (0)
-#endif
+
+#define panic(format, ...) \
+	do { \
+		silent = false; \
+		printf("Kernel panic in %s() at %s:%u\n", \
+		    __func__, __FILE__, __LINE__); \
+		stack_trace(); \
+		panic_printf("Panic message: " format "\n", \
+		    ##__VA_ARGS__);\
+	} while (0)
+
+#else /* CONFIG_DEBUG */
+
+#define panic(format, ...) \
+	do { \
+		silent = false; \
+		panic_printf("Kernel panic: " format "\n", ##__VA_ARGS__); \
+		stack_trace(); \
+	} while (0)
+
+#endif /* CONFIG_DEBUG */
 
 extern bool silent;
