From: Daniel Vetter Date: Mon, 12 Aug 2013 10:26:35 +0000 (+0200) Subject: tests: s/return igt_retval();/igt_exit();/ X-Git-Tag: intel-gpu-tools-1.4~246 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=6877877558870c9c245e7fedcbd1d66ed2206d83;p=platform%2Fupstream%2Fintel-gpu-tools.git tests: s/return igt_retval();/igt_exit();/ Requested-by: Chris Wilson Signed-off-by: Daniel Vetter --- diff --git a/lib/drmtest.c b/lib/drmtest.c index 53cd633..f87f034 100644 --- a/lib/drmtest.c +++ b/lib/drmtest.c @@ -791,7 +791,7 @@ void igt_fail(int exitcode) } } -int igt_retval(void) +void igt_exit(void) { if (igt_only_list_subtests()) return 0; @@ -800,11 +800,11 @@ int igt_retval(void) assert(skipped_one || succeeded_one || failed_one); if (failed_one) - return igt_exitcode; + exit(igt_exitcode); else if (succeeded_one) - return 0; + exit(0); else - return 77; + exit(77); } static bool env_set(const char *env_var, bool default_value) diff --git a/lib/drmtest.h b/lib/drmtest.h index 51e223b..8a9e6e0 100644 --- a/lib/drmtest.h +++ b/lib/drmtest.h @@ -106,7 +106,7 @@ bool igt_only_list_subtests(void); void igt_skip(void); void igt_success(void); void igt_fail(int exitcode) __attribute__((noreturn)); -int igt_retval(void); +void igt_exit(void); /* check functions which auto-skip tests by calling igt_skip() */ void gem_check_caching(int fd); diff --git a/tests/gem_caching.c b/tests/gem_caching.c index b952a9d..510042d 100644 --- a/tests/gem_caching.c +++ b/tests/gem_caching.c @@ -301,5 +301,5 @@ int main(int argc, char **argv) close(fd); - return igt_retval(); + igt_exit(); } diff --git a/tests/gem_cs_tlb.c b/tests/gem_cs_tlb.c index fe49f2a..cff6680 100644 --- a/tests/gem_cs_tlb.c +++ b/tests/gem_cs_tlb.c @@ -177,5 +177,5 @@ int main(int argc, char **argv) close(fd); - return igt_retval(); + igt_exit(); } diff --git a/tests/gem_dummy_reloc_loop.c b/tests/gem_dummy_reloc_loop.c index 58f77b9..bbece79 100644 --- a/tests/gem_dummy_reloc_loop.c +++ b/tests/gem_dummy_reloc_loop.c @@ -208,5 +208,5 @@ int main(int argc, char **argv) close(fd); - return igt_retval(); + igt_exit(); } diff --git a/tests/gem_exec_nop.c b/tests/gem_exec_nop.c index 7b37016..7314b68 100644 --- a/tests/gem_exec_nop.c +++ b/tests/gem_exec_nop.c @@ -138,5 +138,5 @@ int main(int argc, char **argv) close(fd); - return igt_retval(); + igt_exit(); } diff --git a/tests/gem_partial_pwrite_pread.c b/tests/gem_partial_pwrite_pread.c index c4c729a..68994cb 100644 --- a/tests/gem_partial_pwrite_pread.c +++ b/tests/gem_partial_pwrite_pread.c @@ -306,5 +306,5 @@ int main(int argc, char **argv) close(fd); - return igt_retval(); + igt_exit(); } diff --git a/tests/gem_pread.c b/tests/gem_pread.c index b707882..0a6b63b 100644 --- a/tests/gem_pread.c +++ b/tests/gem_pread.c @@ -146,5 +146,5 @@ int main(int argc, char **argv) close(fd); - return igt_retval(); + igt_exit(); } diff --git a/tests/gem_pread_after_blit.c b/tests/gem_pread_after_blit.c index 6b0588c..8f34961 100644 --- a/tests/gem_pread_after_blit.c +++ b/tests/gem_pread_after_blit.c @@ -236,5 +236,5 @@ main(int argc, char **argv) close(fd); - return igt_retval(); + igt_exit(); } diff --git a/tests/gem_pwrite.c b/tests/gem_pwrite.c index 8b5b442..cf3c6aa 100644 --- a/tests/gem_pwrite.c +++ b/tests/gem_pwrite.c @@ -154,5 +154,5 @@ int main(int argc, char **argv) close(fd); - return igt_retval(); + igt_exit(); } diff --git a/tests/gem_pwrite_pread.c b/tests/gem_pwrite_pread.c index 8887338..175e1aa 100644 --- a/tests/gem_pwrite_pread.c +++ b/tests/gem_pwrite_pread.c @@ -515,5 +515,5 @@ int main(int argc, char **argv) close(fd); - return igt_retval(); + igt_exit(); }