From: naresh k. <nar...@gm...> - 2009-06-19 13:01:34
|
Hi, Thanks for your review comments. I have attached and placed below the latest patch. Best regards Naresh Kamboju Signed-off-by: Naresh Kamboju < nar...@gm... > diff -Naurb a/testcases/kernel/syscalls/set_thread_area/set_thread_area01.c b/testcases/kernel/syscalls/set_thread_area/set_thread_area01.c --- a/testcases/kernel/syscalls/set_thread_area/set_thread_area01.c 2009-05-22 00:00:29.000000000 +0530 +++ b/testcases/kernel/syscalls/set_thread_area/set_thread_area01.c 2009-06-19 17:49:41.000000000 +0530 @@ -123,7 +123,6 @@ int main(int ac, char **av) { struct user_desc u_info; - int result; int lc; /* loop counter */ char *msg; /* message returned from parse_opts */ @@ -145,7 +144,7 @@ * This call to get_thread_area function should be sucessful. */ - TEST(result = syscall(244, &u_info)); //call get_thread_area() + TEST(syscall(__NR_get_thread_area, &u_info)); //call get_thread_area() if(TEST_RETURN == 0) { tst_resm(TPASS, "get_thread_area call succeeded"); } @@ -160,7 +159,7 @@ * This call to set_thread_area function should be sucessful. */ - TEST(result = syscall(243, &u_info)); //call set_thread_area() + TEST(result = syscall(__NR_set_thread_area, &u_info)); //call set_thread_area() if(TEST_RETURN == 0) { tst_resm(TPASS, "set_thread_area call succeeded"); } diff -Naurb a/testcases/kernel/syscalls/set_thread_area/set_thread_area02.c b/testcases/kernel/syscalls/set_thread_area/set_thread_area02.c --- a/testcases/kernel/syscalls/set_thread_area/set_thread_area02.c 2009-05-22 00:01:38.000000000 +0530 +++ b/testcases/kernel/syscalls/set_thread_area/set_thread_area02.c 2009-06-19 17:45:36.000000000 +0530 @@ -124,7 +124,6 @@ int main(int ac, char **av) { struct user_desc u_info; - int result; int lc; /* loop counter */ char *msg; /* message returned from parse_opts */ @@ -146,7 +145,7 @@ * This call to get_thread_area function should be sucessful. */ - TEST(result = syscall(244, &u_info)); //call get_thread_area() + TEST(syscall(__NR_get_thread_area, &u_info)); //call get_thread_area() if(TEST_RETURN == -1) { tst_resm(TFAIL, "call get_thraed_area() failed with errno = %d ", TEST_ERRNO, strerror(TEST_ERRNO)); cleanup(); @@ -158,13 +157,13 @@ * This call to set_thread_area function with invalid entry_number should be FAILED. */ - TEST(result = syscall(243, &u_info)); //call set_thread_area() + TEST(syscall(__NR_set_thread_area, &u_info)); //call set_thread_area() if(TEST_RETURN == -1) { if(TEST_ERRNO == EINVAL){ - tst_resm(TPASS, "Call to set_thread_area call failed with invalid entry_number result = %d (expected EINVAL)",TEST_ERRNO); + tst_resm(TPASS, "Call to set_thread_area call failed with invalid entry_number errno = %d (expected EINVAL)",TEST_ERRNO); } else { - tst_resm(TPASS,"Call to set_thread_area with invalid entry_number got unexpected result = %d (expected EINVAL)",TEST_ERRNO); + tst_resm(TFAIL,"Call to set_thread_area with invalid entry_number got unexpected errno = %d (expected EINVAL)",TEST_ERRNO); } } else { @@ -177,13 +176,13 @@ * This call to set_thread_area function with an invalid pointer should be FAILED with EFAULT. */ - TEST(result = syscall(243,(struct user_desc *)-9)); //call set_thread_area() + TEST(syscall(__NR_set_thread_area,(struct user_desc *)-9)); //call set_thread_area() if(TEST_RETURN == -1) { if(TEST_ERRNO == EFAULT){ - tst_resm(TPASS, "Call to set_thread_area call with invalid entry_number result = %d (got expected error EFAULT)",TEST_ERRNO); + tst_resm(TPASS, "Call to set_thread_area call with invalid entry_number errno = %d (got expected error EFAULT)",TEST_ERRNO); } else { - tst_resm(TPASS,"Call to set_thread_area with invalid entry_number got unexpected result = %d (expected EFAULT)",TEST_ERRNO); + tst_resm(TFAIL,"Call to set_thread_area with invalid entry_number got unexpected errno = %d (expected EFAULT)",TEST_ERRNO); } } else { On Thu, Jun 18, 2009 at 1:51 AM, naresh kamboju<nar...@gm...> wrote: > Hi, > > I have noticed following failures and fixed. > 1. set_tid_address01.c > 2. set_tid_address02.c > > > Please find the patch below and as attachment. > > Best regards > Naresh Kamboju > > Signed-off-by: Naresh Kamboju < nar...@gm... > > diff -Naurb a/testcases/kernel/syscalls/set_thread_area/set_thread_area01.c > b/testcases/kernel/syscalls/set_thread_area/set_thread_area01.c > --- a/testcases/kernel/syscalls/set_thread_area/set_thread_area01.c 2009-05-22 > 00:00:29.000000000 +0530 > +++ b/testcases/kernel/syscalls/set_thread_area/set_thread_area01.c 2009-06-17 > 23:13:22.000000000 +0530 > @@ -145,7 +145,7 @@ > * This call to get_thread_area function should be sucessful. > */ > > - TEST(result = syscall(244, &u_info)); //call > get_thread_area() > + TEST(result = syscall(__NR_get_thread_area, > &u_info)); //call get_thread_area() > if(TEST_RETURN == 0) { > tst_resm(TPASS, "get_thread_area call succeeded"); > } > @@ -160,7 +160,7 @@ > * This call to set_thread_area function should be sucessful. > */ > > - TEST(result = syscall(243, &u_info)); //call > set_thread_area() > + TEST(result = syscall(__NR_set_thread_area, > &u_info)); //call set_thread_area() > if(TEST_RETURN == 0) { > tst_resm(TPASS, "set_thread_area call succeeded"); > } > diff -Naurb a/testcases/kernel/syscalls/set_thread_area/set_thread_area02.c > b/testcases/kernel/syscalls/set_thread_area/set_thread_area02.c > --- a/testcases/kernel/syscalls/set_thread_area/set_thread_area02.c 2009-05-22 > 00:01:38.000000000 +0530 > +++ b/testcases/kernel/syscalls/set_thread_area/set_thread_area02.c 2009-06-17 > 23:34:04.000000000 +0530 > @@ -146,7 +146,7 @@ > * This call to get_thread_area function should be sucessful. > */ > > - TEST(result = syscall(244, &u_info)); //call > get_thread_area() > + TEST(result = syscall(__NR_get_thread_area, > &u_info)); //call get_thread_area() > if(TEST_RETURN == -1) { > tst_resm(TFAIL, "call get_thraed_area() failed > with errno = %d ", TEST_ERRNO, strerror(TEST_ERRNO)); > cleanup(); > @@ -158,7 +158,7 @@ > * This call to set_thread_area function with invalid > entry_number should be FAILED. > */ > > - TEST(result = syscall(243, &u_info)); //call > set_thread_area() > + TEST(result = syscall(__NR_set_thread_area, > &u_info)); //call set_thread_area() > if(TEST_RETURN == -1) { > if(TEST_ERRNO == EINVAL){ > tst_resm(TPASS, "Call to set_thread_area call failed with invalid > entry_number result = %d (expected EINVAL)",TEST_ERRNO); > @@ -177,7 +177,7 @@ > * This call to set_thread_area function with an invalid > pointer should be FAILED with EFAULT. > */ > > - TEST(result = syscall(243,(struct user_desc > *)-9)); //call set_thread_area() > + TEST(result = > syscall(__NR_set_thread_area,(struct user_desc *)-9)); //call > set_thread_area() > if(TEST_RETURN == -1) { > if(TEST_ERRNO == EFAULT){ > tst_resm(TPASS, "Call to set_thread_area call with invalid > entry_number result = %d (got expected error EFAULT)",TEST_ERRNO); > |