[LTP] [PATCH 2/2] tree: Use TINFO_WARN

Petr Vorel pvorel@suse.cz
Tue May 28 14:05:54 CEST 2024


Signed-off-by: Petr Vorel <pvorel@suse.cz>
---
 lib/tst_supported_fs_types.c                    | 2 +-
 testcases/kernel/mem/hugetlb/lib/hugetlb.c      | 4 ++--
 testcases/kernel/syscalls/ipc/semctl/semctl08.c | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/lib/tst_supported_fs_types.c b/lib/tst_supported_fs_types.c
index bbbb8df19..8b8cf213a 100644
--- a/lib/tst_supported_fs_types.c
+++ b/lib/tst_supported_fs_types.c
@@ -158,7 +158,7 @@ const char **tst_get_supported_fs_types(const char *const *skiplist)
 	only_fs = getenv("LTP_SINGLE_FS_TYPE");
 
 	if (only_fs) {
-		tst_res(TINFO, "WARNING: testing only %s", only_fs);
+		tst_res(TINFO_WARN, "testing only %s", only_fs);
 		if (tst_fs_is_supported(only_fs))
 			fs_types[0] = only_fs;
 		return fs_types;
diff --git a/testcases/kernel/mem/hugetlb/lib/hugetlb.c b/testcases/kernel/mem/hugetlb/lib/hugetlb.c
index 43a677ce9..c612bf2d2 100644
--- a/testcases/kernel/mem/hugetlb/lib/hugetlb.c
+++ b/testcases/kernel/mem/hugetlb/lib/hugetlb.c
@@ -106,8 +106,8 @@ void rm_shm(int shm_id)
 	 * check for # of attaches ?
 	 */
 	if (shmctl(shm_id, IPC_RMID, NULL) == -1) {
-		tst_res(TINFO, "WARNING: shared memory deletion failed.");
-		tst_res(TINFO, "This could lead to IPC resource problems.");
+		tst_res(TINFO_WARN, "shared memory deletion failed");
+		tst_res(TINFO, "This could lead to IPC resource problems");
 		tst_res(TINFO, "id = %d", shm_id);
 	}
 }
diff --git a/testcases/kernel/syscalls/ipc/semctl/semctl08.c b/testcases/kernel/syscalls/ipc/semctl/semctl08.c
index 1878bd49d..aacdcf6a5 100644
--- a/testcases/kernel/syscalls/ipc/semctl/semctl08.c
+++ b/testcases/kernel/syscalls/ipc/semctl/semctl08.c
@@ -40,7 +40,7 @@ static void run(void)
 		tst_res(TPASS, "time_high fields cleared by the kernel");
 
 	if (semctl(semid, 0, IPC_RMID, arg) == -1)
-		tst_res(TINFO, "WARNING: semaphore deletion failed.");
+		tst_res(TINFO_WARN, "semaphore deletion failed");
 }
 
 static struct tst_test test = {
-- 
2.43.0



More information about the ltp mailing list