Merge "Small fixes for vmv_v_i test"
diff --git a/springbok/include/springbok.h b/springbok/include/springbok.h
index ebe4564..80905a7 100644
--- a/springbok/include/springbok.h
+++ b/springbok/include/springbok.h
@@ -4,25 +4,32 @@
#include <stdio.h>
#define ERROR_TAG "ERROR"
+#define WARN_TAG "WARN"
#define INFO_TAG "INFO"
#define DEBUG_TAG "DEBUG"
+#define NOISY_TAG "NOISY"
#define LOG_FMT "%s |"
#define LOG_ARGS(LOG_TAG) LOG_TAG
-#define LOG_MAX_SZ 256
+#define LOG_MAX_SZ 256
-#define SIMLOG(sim_log_level,fmt, ...) \
- do { \
- char tmp_log_msg[LOG_MAX_SZ]; \
- snprintf(tmp_log_msg, LOG_MAX_SZ, fmt, __VA_ARGS__); \
- springbok_simprint_##sim_log_level(tmp_log_msg, 0); \
- } while (0)
+#define SIMLOG(sim_log_level, fmt, ...) \
+ do { \
+ char tmp_log_msg[LOG_MAX_SZ]; \
+ snprintf(tmp_log_msg, LOG_MAX_SZ, fmt, __VA_ARGS__); \
+ springbok_simprint_##sim_log_level(tmp_log_msg, 0); \
+ } while (0)
-#define LOG_ERROR(msg, args...) SIMLOG(error, LOG_FMT msg, LOG_ARGS(ERROR_TAG), ## args)
-#define LOG_WARN(msg, args...) SIMLOG(warning, LOG_FMT msg, LOG_ARGS(ERROR_TAG), ## args)
-#define LOG_INFO(msg, args...) SIMLOG(info, LOG_FMT msg, LOG_ARGS(INFO_TAG), ## args)
-#define LOG_DEBUG(msg, args...) SIMLOG(debug, LOG_FMT msg, LOG_ARGS(DEBUG_TAG), ## args)
-#define LOG_NOISY(msg, args...) SIMLOG(noisy, LOG_FMT msg, LOG_ARGS(ERROR_TAG), ## args)
+#define LOG_ERROR(msg, args...) \
+ SIMLOG(error, LOG_FMT msg, LOG_ARGS(ERROR_TAG), ##args)
+#define LOG_WARN(msg, args...) \
+ SIMLOG(warning, LOG_FMT msg, LOG_ARGS(WARN_TAG), ##args)
+#define LOG_INFO(msg, args...) \
+ SIMLOG(info, LOG_FMT msg, LOG_ARGS(INFO_TAG), ##args)
+#define LOG_DEBUG(msg, args...) \
+ SIMLOG(debug, LOG_FMT msg, LOG_ARGS(DEBUG_TAG), ##args)
+#define LOG_NOISY(msg, args...) \
+ SIMLOG(noisy, LOG_FMT msg, LOG_ARGS(NOISY_TAG), ##args)
#endif