This is an automated email from Gerrit. "Jan Matyas <jan.mat...@codasip.com>" just uploaded a new patch set to Gerrit, which you can find at https://review.openocd.org/c/openocd/+/8538
-- gerrit commit a6771a10713559c74cbf09c3c9e99d60a4b109cf Author: Jan Matyas <jan.mat...@codasip.com> Date: Sun Nov 3 19:04:48 2024 +0100 helper/log: Distinct prefix for LOG_LVL_DEBUG_IO Ensure that detailed I/O prints, printed by LOG_DEBUG_IO and displayed in log_level 4, have different log prefix than LOG_DEBUG prints, displayed starting from log_level 3. This allows to: - Process logs more easily - filter log items of interest. - Differentiate LOG_DEBUG_IO vs. LOG_DEBUG in unit tests. (Proposal for unit testing will be submitted in a separate patch.) Change-Id: I72ce77455fe1fe459e3932996281d22f425a4f7d Signed-off-by: Jan Matyas <jan.mat...@codasip.com> diff --git a/src/helper/log.c b/src/helper/log.c index 9ad00ce628..13c45b89c5 100644 --- a/src/helper/log.c +++ b/src/helper/log.c @@ -47,7 +47,7 @@ static const char * const log_strings[6] = { "Warn : ", /* want a space after each colon, all same width, colons aligned */ "Info : ", "Debug: ", - "Debug: " + "I/O : ", }; static int count; diff --git a/src/helper/log.h b/src/helper/log.h index dc8df6fbb6..ce1b306abb 100644 --- a/src/helper/log.h +++ b/src/helper/log.h @@ -101,7 +101,7 @@ extern int debug_level; #define LOG_DEBUG_IO(expr ...) \ do { \ if (debug_level >= LOG_LVL_DEBUG_IO) \ - log_printf_lf(LOG_LVL_DEBUG, \ + log_printf_lf(LOG_LVL_DEBUG_IO, \ __FILE__, __LINE__, __func__, \ expr); \ } while (0) --