From d1ea97febae9fd119fcefbaaf031c63ce306aad2 Mon Sep 17 00:00:00 2001 From: Jihyeon Gim Date: Fri, 2 May 2025 06:54:31 +0900 Subject: [PATCH] LU-18968 libcfs: fix invalid cfs_print_to_console() calls The cfs_print_to_console() function was changed so that it no longer accepts mask information as a parameter. However, functions such as cfs_trace_debug_print() do not reflect this change and cause build errors because they conditionally compile with the LNET_DUMP_ON_PANIC macro enabled when --enable-panic_dumplog is enabled. This commit therefore resolves the issue by amending the code that calls the cfs_print_to_console() functions that were not updated. Test-Parameters: trivial Fixes: 02fc9e8977 ("LU-17623 libcfs: save msg_fn pointer to avoid race") Signed-off-by: Jihyeon Gim Change-Id: I6480642b246830393c09ed48d8a7c14111f7c39f Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/59061 Reviewed-by: James Simmons Reviewed-by: Emoly Liu Reviewed-by: Oleg Drokin Reviewed-by: Andreas Dilger Tested-by: Maloo Tested-by: jenkins --- libcfs/libcfs/tracefile.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libcfs/libcfs/tracefile.c b/libcfs/libcfs/tracefile.c index c967598..c38f7d1 100644 --- a/libcfs/libcfs/tracefile.c +++ b/libcfs/libcfs/tracefile.c @@ -853,8 +853,7 @@ void cfs_trace_debug_print(void) p += strlen(fn) + 1; len = hdr->ph_len - (int)(p - (char *)hdr); - cfs_print_to_console(hdr, D_EMERG, file, fn, - "%.*s", len, p); + cfs_print_to_console(hdr, file, fn, "%.*s", len, p); p += len; } @@ -880,8 +879,7 @@ void cfs_trace_debug_print(void) p += strlen(fn) + 1; len = hdr->ph_len - (int)(p - (char *)hdr); - cfs_print_to_console(hdr, D_EMERG, file, fn, - "%.*s", len, p); + cfs_print_to_console(hdr, file, fn, "%.*s", len, p); p += len; } -- 1.8.3.1