[LTP] [PATCH v2 07/10] syscalls/cacheflush: Make use of TST_EXP_MACROS
Cyril Hrubis
chrubis@suse.cz
Thu Dec 10 15:15:45 CET 2020
Signed-off-by: Cyril Hrubis <chrubis@suse.cz>
---
testcases/kernel/syscalls/cacheflush/cacheflush01.c | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/testcases/kernel/syscalls/cacheflush/cacheflush01.c b/testcases/kernel/syscalls/cacheflush/cacheflush01.c
index 6ad8b953a..3daaff624 100644
--- a/testcases/kernel/syscalls/cacheflush/cacheflush01.c
+++ b/testcases/kernel/syscalls/cacheflush/cacheflush01.c
@@ -45,12 +45,8 @@ static void test_cacheflush(unsigned int i)
{
struct test_case_t *tc = &test_cases[i];
- TEST(tst_syscall(__NR_cacheflush, addr, getpagesize(), tc->cache));
- if (TST_RET == 0) {
- tst_res(TPASS, "%s passed", tc->desc);
- } else {
- tst_res(TFAIL | TTERRNO, "%s failed", tc->desc);
- }
+ TST_EXP_PASS(tst_syscall(__NR_cacheflush, addr, getpagesize(), tc->cache),
+ "%s", tc->desc);
}
static struct tst_test test = {
--
2.26.2
More information about the ltp
mailing list