public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH] syscalls/keyctl07: skip test if syscall unavailable
@ 2018-02-01 19:07 Steve Muckle
  2018-02-06 11:41 ` Petr Vorel
  0 siblings, 1 reply; 2+ messages in thread
From: Steve Muckle @ 2018-02-01 19:07 UTC (permalink / raw)
  To: ltp

If the child is unable to run the test because the syscall is
unavailable TBROK is currently reported. Look for TCONF from the
child and report that in this scenario instead.

Signed-off-by: Steve Muckle <smuckle.linux@gmail.com>
---
 testcases/kernel/syscalls/keyctl/keyctl07.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/testcases/kernel/syscalls/keyctl/keyctl07.c b/testcases/kernel/syscalls/keyctl/keyctl07.c
index 39f07eb5fbce..08a585b6c956 100644
--- a/testcases/kernel/syscalls/keyctl/keyctl07.c
+++ b/testcases/kernel/syscalls/keyctl/keyctl07.c
@@ -106,6 +106,9 @@ static void do_test(void)
 		return;
 	}
 
+	if (WIFEXITED(status) && WEXITSTATUS(status) == TCONF)
+		tst_brk(TCONF, "syscall not implemented");
+
 	tst_brk(TBROK, "Child %s", tst_strstatus(status));
 }
 
-- 
2.13.6


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [LTP] [PATCH] syscalls/keyctl07: skip test if syscall unavailable
  2018-02-01 19:07 [LTP] [PATCH] syscalls/keyctl07: skip test if syscall unavailable Steve Muckle
@ 2018-02-06 11:41 ` Petr Vorel
  0 siblings, 0 replies; 2+ messages in thread
From: Petr Vorel @ 2018-02-06 11:41 UTC (permalink / raw)
  To: ltp

Hi,
> If the child is unable to run the test because the syscall is
> unavailable TBROK is currently reported. Look for TCONF from the
> child and report that in this scenario instead.

> Signed-off-by: Steve Muckle <smuckle.linux@gmail.com>
> ---
>  testcases/kernel/syscalls/keyctl/keyctl07.c | 3 +++
>  1 file changed, 3 insertions(+)

> diff --git a/testcases/kernel/syscalls/keyctl/keyctl07.c b/testcases/kernel/syscalls/keyctl/keyctl07.c
> index 39f07eb5fbce..08a585b6c956 100644
> --- a/testcases/kernel/syscalls/keyctl/keyctl07.c
> +++ b/testcases/kernel/syscalls/keyctl/keyctl07.c
> @@ -106,6 +106,9 @@ static void do_test(void)
>  		return;
>  	}

> +	if (WIFEXITED(status) && WEXITSTATUS(status) == TCONF)
> +		tst_brk(TCONF, "syscall not implemented");
> +
>  	tst_brk(TBROK, "Child %s", tst_strstatus(status));
>  }

Pushed, thanks.

Kind regards,
Petr

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-02-06 11:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-01 19:07 [LTP] [PATCH] syscalls/keyctl07: skip test if syscall unavailable Steve Muckle
2018-02-06 11:41 ` Petr Vorel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox