Re: [LTP] [PATCH] fix the system call number of exit_group01

Garrett Cooper
2009-07-19T04:47:37Z

On Wed, Jul 15, 2009 at 5:37 PM, Wei Yongjun<yjwei@cn.fujitsu.com> wrote:
> The system call number is depend on the system architecture, not always 252. This patch fixed the problem.
>
> Signed-off-by: Wei Yongjun <yjwei@cn.fujitsu.com>
>
> --- a/testcases/kernel/syscalls/exit_group/exit_group01.c       2009-05-22 02:14:40.000000000 +0800
> +++ b/testcases/kernel/syscalls/exit_group/exit_group01.c       2009-07-15 09:26:23.000000000 +0800
> @@ -136,7 +136,7 @@ int main(int ac, char **av) {
>                      } else if (TEST_RETURN == 0){
>                                tst_resm(TINFO, "In the child process");
>                                sleep(5);
> -                               TEST(syscall(252,4));
> +                               TEST(syscall(__NR_exit_group,4));
>                      }else {
>                                tst_resm(TINFO,"in the parent process");
>                                TEST(w = wait(&status));

Hi Wei,
The best way to do this (IMHO) may be to add the relevant syscall
number to the architecture specific .in file in
testcases/kernel/include. Do you have the syscall number for your
architecture?
Thanks,
-Garrett