public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] quotactl01 testcases problem
@ 2010-01-05  8:30 Mitani
  2010-01-07 11:06 ` Subrata Modak
  0 siblings, 1 reply; 5+ messages in thread
From: Mitani @ 2010-01-05  8:30 UTC (permalink / raw)
  To: ltp-list

Hi,

I tried "quotactl01" testcases, and found two problems.
Second one occurred after first one's revise.

1) In the result of "quotactl01", "Success" are displayed in spite of
   failing in the test:

------------
quotactl01    1  TFAIL  :  cmd=0x800002: TEST_ERRNO=???(0): Success
quotactl01    2  TFAIL  :  cmd=0x800003: TEST_ERRNO=???(0): Success
quotactl01    3  TFAIL  :  cmd=0x800007: TEST_ERRNO=???(0): Success
quotactl01    4  TFAIL  :  cmd=0x800008: TEST_ERRNO=???(0): Success
quotactl01    5  TFAIL  :  cmd=0x800005: TEST_ERRNO=???(0): Success
quotactl01    6  TFAIL  :  cmd=0x800006: TEST_ERRNO=???(0): Success
quotactl01    7  TFAIL  :  cmd=0x800004: TEST_ERRNO=???(0): Success
quotactl01    8  TFAIL  :  cmd=0x800001: TEST_ERRNO=???(0): Success
------------

This problem occurred because the return value of system-call 
"(syscall(__NR_quotactl, cmd[i], ...))" is not judged correctly 
in "${LTPROOT}/testcases/kernel/syscalls/quotactl/quotactl01.c".
Above errors are caused by TFAIL and messages are printed by TTERRNO.
And there is only one place (Line 206) which uses TFAIL in "quotactl01.c"

The following patch can fix this problem:

============
--- quotactl01.c	2009-12-20 09:36:35.000000000 +0900
+++ quotactl01.c.new	2010-01-04 17:11:17.000000000 +0900
@@ -177,7 +177,6 @@
 	int id = getuid();
 	int newtid = -1;
 	int result;
-	int ret;
 	int i;
 	int lc;				 /* loop counter */
 	char *msg;			  /* message returned from
parse_opts */
@@ -199,10 +198,10 @@
 
 			for (i = 0; i <= 7; i++){
 
-				ret = syscall(__NR_quotactl, cmd[i],
+				TEST(syscall(__NR_quotactl, cmd[i],
 						(const char *)NULL, id,
-						(caddr_t)NULL);
-				if (ret != 0) {
+						(caddr_t)NULL));
+				if (TEST_RETURN != 0) {
 					tst_resm(TFAIL|TTERRNO, "cmd=0x%x",
cmd[i]);
 				} else {
 					tst_resm(TPASS, "quotactl call
succeeded");
============


However, new problem occurred after applying above patch.

2) The test failed with the following error in my system:

------------
quotactl01    1  TFAIL  :  cmd=0x800002: TEST_ERRNO=EFAULT(14): Bad address
quotactl01    2  TFAIL  :  cmd=0x800003: TEST_ERRNO=EFAULT(14): Bad address
quotactl01    3  TFAIL  :  cmd=0x800007: TEST_ERRNO=EFAULT(14): Bad address
quotactl01    4  TFAIL  :  cmd=0x800008: TEST_ERRNO=EFAULT(14): Bad address
quotactl01    5  TFAIL  :  cmd=0x800005: TEST_ERRNO=EFAULT(14): Bad address
quotactl01    6  TFAIL  :  cmd=0x800006: TEST_ERRNO=EFAULT(14): Bad address
quotactl01    7  TFAIL  :  cmd=0x800004: TEST_ERRNO=EFAULT(14): Bad address
quotactl01    8  TFAIL  :  cmd=0x800001: TEST_ERRNO=EFAULT(14): Bad address
------------

"EFAULT" means that there is an error in "addr".
The format of "quotactl" is following:
------------
int quotactl(int cmd, const char *special, int id, caddr_t addr);
------------

Therefore, "EFAULT" means that 4th argument of "quotactl()" has problem.

In "${LTPROOT}/testcases/kernel/syscalls/quotactl/quotactl01.c", 4th 
argument of "quotactl()" is "NULL":
Is it right?


I'm glad if I get your help.


Regards--


-Tomonori Mitani



------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

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

* Re: [LTP] quotactl01 testcases problem
  2010-01-05  8:30 [LTP] quotactl01 testcases problem Mitani
@ 2010-01-07 11:06 ` Subrata Modak
  2010-01-08  6:17   ` Mitani
  2010-01-13  2:10   ` Mitani
  0 siblings, 2 replies; 5+ messages in thread
From: Subrata Modak @ 2010-01-07 11:06 UTC (permalink / raw)
  To: Mitani; +Cc: ltp-list

Hello Mitani-San,

Did this get resolved for you ?

Regards--
Subrata

On Tue, 2010-01-05 at 17:30 +0900, Mitani wrote: 
> Hi,
> 
> I tried "quotactl01" testcases, and found two problems.
> Second one occurred after first one's revise.
> 
> 1) In the result of "quotactl01", "Success" are displayed in spite of
>    failing in the test:
> 
> ------------
> quotactl01    1  TFAIL  :  cmd=0x800002: TEST_ERRNO=???(0): Success
> quotactl01    2  TFAIL  :  cmd=0x800003: TEST_ERRNO=???(0): Success
> quotactl01    3  TFAIL  :  cmd=0x800007: TEST_ERRNO=???(0): Success
> quotactl01    4  TFAIL  :  cmd=0x800008: TEST_ERRNO=???(0): Success
> quotactl01    5  TFAIL  :  cmd=0x800005: TEST_ERRNO=???(0): Success
> quotactl01    6  TFAIL  :  cmd=0x800006: TEST_ERRNO=???(0): Success
> quotactl01    7  TFAIL  :  cmd=0x800004: TEST_ERRNO=???(0): Success
> quotactl01    8  TFAIL  :  cmd=0x800001: TEST_ERRNO=???(0): Success
> ------------
> 
> This problem occurred because the return value of system-call 
> "(syscall(__NR_quotactl, cmd[i], ...))" is not judged correctly 
> in "${LTPROOT}/testcases/kernel/syscalls/quotactl/quotactl01.c".
> Above errors are caused by TFAIL and messages are printed by TTERRNO.
> And there is only one place (Line 206) which uses TFAIL in "quotactl01.c"
> 
> The following patch can fix this problem:
> 
> ============
> --- quotactl01.c	2009-12-20 09:36:35.000000000 +0900
> +++ quotactl01.c.new	2010-01-04 17:11:17.000000000 +0900
> @@ -177,7 +177,6 @@
>  	int id = getuid();
>  	int newtid = -1;
>  	int result;
> -	int ret;
>  	int i;
>  	int lc;				 /* loop counter */
>  	char *msg;			  /* message returned from
> parse_opts */
> @@ -199,10 +198,10 @@
> 
>  			for (i = 0; i <= 7; i++){
> 
> -				ret = syscall(__NR_quotactl, cmd[i],
> +				TEST(syscall(__NR_quotactl, cmd[i],
>  						(const char *)NULL, id,
> -						(caddr_t)NULL);
> -				if (ret != 0) {
> +						(caddr_t)NULL));
> +				if (TEST_RETURN != 0) {
>  					tst_resm(TFAIL|TTERRNO, "cmd=0x%x",
> cmd[i]);
>  				} else {
>  					tst_resm(TPASS, "quotactl call
> succeeded");
> ============
> 
> 
> However, new problem occurred after applying above patch.
> 
> 2) The test failed with the following error in my system:
> 
> ------------
> quotactl01    1  TFAIL  :  cmd=0x800002: TEST_ERRNO=EFAULT(14): Bad address
> quotactl01    2  TFAIL  :  cmd=0x800003: TEST_ERRNO=EFAULT(14): Bad address
> quotactl01    3  TFAIL  :  cmd=0x800007: TEST_ERRNO=EFAULT(14): Bad address
> quotactl01    4  TFAIL  :  cmd=0x800008: TEST_ERRNO=EFAULT(14): Bad address
> quotactl01    5  TFAIL  :  cmd=0x800005: TEST_ERRNO=EFAULT(14): Bad address
> quotactl01    6  TFAIL  :  cmd=0x800006: TEST_ERRNO=EFAULT(14): Bad address
> quotactl01    7  TFAIL  :  cmd=0x800004: TEST_ERRNO=EFAULT(14): Bad address
> quotactl01    8  TFAIL  :  cmd=0x800001: TEST_ERRNO=EFAULT(14): Bad address
> ------------
> 
> "EFAULT" means that there is an error in "addr".
> The format of "quotactl" is following:
> ------------
> int quotactl(int cmd, const char *special, int id, caddr_t addr);
> ------------
> 
> Therefore, "EFAULT" means that 4th argument of "quotactl()" has problem.
> 
> In "${LTPROOT}/testcases/kernel/syscalls/quotactl/quotactl01.c", 4th 
> argument of "quotactl()" is "NULL":
> Is it right?
> 
> 
> I'm glad if I get your help.
> 
> 
> Regards--
> 
> 
> -Tomonori Mitani
> 
> 
> 
> ------------------------------------------------------------------------------
> This SF.Net email is sponsored by the Verizon Developer Community
> Take advantage of Verizon's best-in-class app development support
> A streamlined, 14 day to market process makes app distribution fast and easy
> Join now and get one step closer to millions of Verizon customers
> http://p.sf.net/sfu/verizon-dev2dev 
> _______________________________________________
> Ltp-list mailing list
> Ltp-list@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ltp-list


------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

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

* Re: [LTP] quotactl01 testcases problem
  2010-01-07 11:06 ` Subrata Modak
@ 2010-01-08  6:17   ` Mitani
  2010-01-13  2:10   ` Mitani
  1 sibling, 0 replies; 5+ messages in thread
From: Mitani @ 2010-01-08  6:17 UTC (permalink / raw)
  To: subrata; +Cc: ltp-list

Hello Subrata,

Not resolved yet.
I think that 4th argument of "${LTPROOT}/testcases/kernel/syscalls
/quotactl/quotactl01.c" is wrong, because the error is 
"TEST_ERRNO=EFAULT(14): Bad address".

I don't know how to revise it yet.


Regards--

-Tomonori Mitani

-----Original Message-----
From: Subrata Modak [mailto:subrata@linux.vnet.ibm.com] 
Sent: Thursday, January 07, 2010 8:06 PM
To: Mitani
Cc: ltp-list@lists.sourceforge.net
Subject: Re: [LTP] quotactl01 testcases problem

Hello Mitani-San,

Did this get resolved for you ?

Regards--
Subrata

On Tue, 2010-01-05 at 17:30 +0900, Mitani wrote: 
> Hi,
> 
> I tried "quotactl01" testcases, and found two problems.
> Second one occurred after first one's revise.
> 
> 1) In the result of "quotactl01", "Success" are displayed in spite of
>    failing in the test:
> 
> ------------
> quotactl01    1  TFAIL  :  cmd=0x800002: TEST_ERRNO=???(0): Success
> quotactl01    2  TFAIL  :  cmd=0x800003: TEST_ERRNO=???(0): Success
> quotactl01    3  TFAIL  :  cmd=0x800007: TEST_ERRNO=???(0): Success
> quotactl01    4  TFAIL  :  cmd=0x800008: TEST_ERRNO=???(0): Success
> quotactl01    5  TFAIL  :  cmd=0x800005: TEST_ERRNO=???(0): Success
> quotactl01    6  TFAIL  :  cmd=0x800006: TEST_ERRNO=???(0): Success
> quotactl01    7  TFAIL  :  cmd=0x800004: TEST_ERRNO=???(0): Success
> quotactl01    8  TFAIL  :  cmd=0x800001: TEST_ERRNO=???(0): Success
> ------------
> 
> This problem occurred because the return value of system-call 
> "(syscall(__NR_quotactl, cmd[i], ...))" is not judged correctly 
> in "${LTPROOT}/testcases/kernel/syscalls/quotactl/quotactl01.c".
> Above errors are caused by TFAIL and messages are printed by TTERRNO.
> And there is only one place (Line 206) which uses TFAIL in "quotactl01.c"
> 
> The following patch can fix this problem:
> 
> ============
> --- quotactl01.c	2009-12-20 09:36:35.000000000 +0900
> +++ quotactl01.c.new	2010-01-04 17:11:17.000000000 +0900
> @@ -177,7 +177,6 @@
>  	int id = getuid();
>  	int newtid = -1;
>  	int result;
> -	int ret;
>  	int i;
>  	int lc;				 /* loop counter */
>  	char *msg;			  /* message returned from
> parse_opts */
> @@ -199,10 +198,10 @@
> 
>  			for (i = 0; i <= 7; i++){
> 
> -				ret = syscall(__NR_quotactl, cmd[i],
> +				TEST(syscall(__NR_quotactl, cmd[i],
>  						(const char *)NULL, id,
> -						(caddr_t)NULL);
> -				if (ret != 0) {
> +						(caddr_t)NULL));
> +				if (TEST_RETURN != 0) {
>  					tst_resm(TFAIL|TTERRNO, "cmd=0x%x",
> cmd[i]);
>  				} else {
>  					tst_resm(TPASS, "quotactl call
> succeeded");
> ============
> 
> 
> However, new problem occurred after applying above patch.
> 
> 2) The test failed with the following error in my system:
> 
> ------------
> quotactl01    1  TFAIL  :  cmd=0x800002: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    2  TFAIL  :  cmd=0x800003: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    3  TFAIL  :  cmd=0x800007: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    4  TFAIL  :  cmd=0x800008: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    5  TFAIL  :  cmd=0x800005: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    6  TFAIL  :  cmd=0x800006: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    7  TFAIL  :  cmd=0x800004: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    8  TFAIL  :  cmd=0x800001: TEST_ERRNO=EFAULT(14): Bad
address
> ------------
> 
> "EFAULT" means that there is an error in "addr".
> The format of "quotactl" is following:
> ------------
> int quotactl(int cmd, const char *special, int id, caddr_t addr);
> ------------
> 
> Therefore, "EFAULT" means that 4th argument of "quotactl()" has problem.
> 
> In "${LTPROOT}/testcases/kernel/syscalls/quotactl/quotactl01.c", 4th 
> argument of "quotactl()" is "NULL":
> Is it right?
> 
> 
> I'm glad if I get your help.
> 
> 
> Regards--
> 
> 
> -Tomonori Mitani
> 
> 
> 
>
----------------------------------------------------------------------------
--
> This SF.Net email is sponsored by the Verizon Developer Community
> Take advantage of Verizon's best-in-class app development support
> A streamlined, 14 day to market process makes app distribution fast and
easy
> Join now and get one step closer to millions of Verizon customers
> http://p.sf.net/sfu/verizon-dev2dev 
> _______________________________________________
> Ltp-list mailing list
> Ltp-list@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ltp-list



------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

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

* Re: [LTP] quotactl01 testcases problem
  2010-01-07 11:06 ` Subrata Modak
  2010-01-08  6:17   ` Mitani
@ 2010-01-13  2:10   ` Mitani
  2010-01-13  8:19     ` Garrett Cooper
  1 sibling, 1 reply; 5+ messages in thread
From: Mitani @ 2010-01-13  2:10 UTC (permalink / raw)
  To: subrata, Garrett Cooper; +Cc: ltp-list

Garrett, Subrata,

I confirmed that "quotactl01" test is finished in "PASS" (TCONF) 
in my system.

Thank you for your revision.


-Tomonori Mitani

-----Original Message-----
From: Subrata Modak [mailto:subrata@linux.vnet.ibm.com] 
Sent: Thursday, January 07, 2010 8:06 PM
To: Mitani
Cc: ltp-list@lists.sourceforge.net
Subject: Re: [LTP] quotactl01 testcases problem

Hello Mitani-San,

Did this get resolved for you ?

Regards--
Subrata

On Tue, 2010-01-05 at 17:30 +0900, Mitani wrote: 
> Hi,
> 
> I tried "quotactl01" testcases, and found two problems.
> Second one occurred after first one's revise.
> 
> 1) In the result of "quotactl01", "Success" are displayed in spite of
>    failing in the test:
> 
> ------------
> quotactl01    1  TFAIL  :  cmd=0x800002: TEST_ERRNO=???(0): Success
> quotactl01    2  TFAIL  :  cmd=0x800003: TEST_ERRNO=???(0): Success
> quotactl01    3  TFAIL  :  cmd=0x800007: TEST_ERRNO=???(0): Success
> quotactl01    4  TFAIL  :  cmd=0x800008: TEST_ERRNO=???(0): Success
> quotactl01    5  TFAIL  :  cmd=0x800005: TEST_ERRNO=???(0): Success
> quotactl01    6  TFAIL  :  cmd=0x800006: TEST_ERRNO=???(0): Success
> quotactl01    7  TFAIL  :  cmd=0x800004: TEST_ERRNO=???(0): Success
> quotactl01    8  TFAIL  :  cmd=0x800001: TEST_ERRNO=???(0): Success
> ------------
> 
> This problem occurred because the return value of system-call 
> "(syscall(__NR_quotactl, cmd[i], ...))" is not judged correctly 
> in "${LTPROOT}/testcases/kernel/syscalls/quotactl/quotactl01.c".
> Above errors are caused by TFAIL and messages are printed by TTERRNO.
> And there is only one place (Line 206) which uses TFAIL in "quotactl01.c"
> 
> The following patch can fix this problem:
> 
> ============
> --- quotactl01.c	2009-12-20 09:36:35.000000000 +0900
> +++ quotactl01.c.new	2010-01-04 17:11:17.000000000 +0900
> @@ -177,7 +177,6 @@
>  	int id = getuid();
>  	int newtid = -1;
>  	int result;
> -	int ret;
>  	int i;
>  	int lc;				 /* loop counter */
>  	char *msg;			  /* message returned from
> parse_opts */
> @@ -199,10 +198,10 @@
> 
>  			for (i = 0; i <= 7; i++){
> 
> -				ret = syscall(__NR_quotactl, cmd[i],
> +				TEST(syscall(__NR_quotactl, cmd[i],
>  						(const char *)NULL, id,
> -						(caddr_t)NULL);
> -				if (ret != 0) {
> +						(caddr_t)NULL));
> +				if (TEST_RETURN != 0) {
>  					tst_resm(TFAIL|TTERRNO, "cmd=0x%x",
> cmd[i]);
>  				} else {
>  					tst_resm(TPASS, "quotactl call
> succeeded");
> ============
> 
> 
> However, new problem occurred after applying above patch.
> 
> 2) The test failed with the following error in my system:
> 
> ------------
> quotactl01    1  TFAIL  :  cmd=0x800002: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    2  TFAIL  :  cmd=0x800003: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    3  TFAIL  :  cmd=0x800007: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    4  TFAIL  :  cmd=0x800008: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    5  TFAIL  :  cmd=0x800005: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    6  TFAIL  :  cmd=0x800006: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    7  TFAIL  :  cmd=0x800004: TEST_ERRNO=EFAULT(14): Bad
address
> quotactl01    8  TFAIL  :  cmd=0x800001: TEST_ERRNO=EFAULT(14): Bad
address
> ------------
> 
> "EFAULT" means that there is an error in "addr".
> The format of "quotactl" is following:
> ------------
> int quotactl(int cmd, const char *special, int id, caddr_t addr);
> ------------
> 
> Therefore, "EFAULT" means that 4th argument of "quotactl()" has problem.
> 
> In "${LTPROOT}/testcases/kernel/syscalls/quotactl/quotactl01.c", 4th 
> argument of "quotactl()" is "NULL":
> Is it right?
> 
> 
> I'm glad if I get your help.
> 
> 
> Regards--
> 
> 
> -Tomonori Mitani
> 
> 
> 
>
----------------------------------------------------------------------------
--
> This SF.Net email is sponsored by the Verizon Developer Community
> Take advantage of Verizon's best-in-class app development support
> A streamlined, 14 day to market process makes app distribution fast and
easy
> Join now and get one step closer to millions of Verizon customers
> http://p.sf.net/sfu/verizon-dev2dev 
> _______________________________________________
> Ltp-list mailing list
> Ltp-list@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ltp-list



------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

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

* Re: [LTP] quotactl01 testcases problem
  2010-01-13  2:10   ` Mitani
@ 2010-01-13  8:19     ` Garrett Cooper
  0 siblings, 0 replies; 5+ messages in thread
From: Garrett Cooper @ 2010-01-13  8:19 UTC (permalink / raw)
  To: Mitani; +Cc: ltp-list

On Tue, Jan 12, 2010 at 6:10 PM, Mitani <mitani@ryobi.co.jp> wrote:
> Garrett, Subrata,
>
> I confirmed that "quotactl01" test is finished in "PASS" (TCONF)
> in my system.
>
> Thank you for your revision.
>
>
> -Tomonori Mitani
>
> -----Original Message-----
> From: Subrata Modak [mailto:subrata@linux.vnet.ibm.com]
> Sent: Thursday, January 07, 2010 8:06 PM
> To: Mitani
> Cc: ltp-list@lists.sourceforge.net
> Subject: Re: [LTP] quotactl01 testcases problem
>
> Hello Mitani-San,
>
> Did this get resolved for you ?
>
> Regards--
> Subrata
>
> On Tue, 2010-01-05 at 17:30 +0900, Mitani wrote:
>> Hi,
>>
>> I tried "quotactl01" testcases, and found two problems.
>> Second one occurred after first one's revise.
>>
>> 1) In the result of "quotactl01", "Success" are displayed in spite of
>>    failing in the test:
>>
>> ------------
>> quotactl01    1  TFAIL  :  cmd=0x800002: TEST_ERRNO=???(0): Success
>> quotactl01    2  TFAIL  :  cmd=0x800003: TEST_ERRNO=???(0): Success
>> quotactl01    3  TFAIL  :  cmd=0x800007: TEST_ERRNO=???(0): Success
>> quotactl01    4  TFAIL  :  cmd=0x800008: TEST_ERRNO=???(0): Success
>> quotactl01    5  TFAIL  :  cmd=0x800005: TEST_ERRNO=???(0): Success
>> quotactl01    6  TFAIL  :  cmd=0x800006: TEST_ERRNO=???(0): Success
>> quotactl01    7  TFAIL  :  cmd=0x800004: TEST_ERRNO=???(0): Success
>> quotactl01    8  TFAIL  :  cmd=0x800001: TEST_ERRNO=???(0): Success
>> ------------
>>
>> This problem occurred because the return value of system-call
>> "(syscall(__NR_quotactl, cmd[i], ...))" is not judged correctly
>> in "${LTPROOT}/testcases/kernel/syscalls/quotactl/quotactl01.c".
>> Above errors are caused by TFAIL and messages are printed by TTERRNO.
>> And there is only one place (Line 206) which uses TFAIL in "quotactl01.c"
>>
>> The following patch can fix this problem:
>>
>> ============
>> --- quotactl01.c      2009-12-20 09:36:35.000000000 +0900
>> +++ quotactl01.c.new  2010-01-04 17:11:17.000000000 +0900
>> @@ -177,7 +177,6 @@
>>       int id = getuid();
>>       int newtid = -1;
>>       int result;
>> -     int ret;
>>       int i;
>>       int lc;                          /* loop counter */
>>       char *msg;                        /* message returned from
>> parse_opts */
>> @@ -199,10 +198,10 @@
>>
>>                       for (i = 0; i <= 7; i++){
>>
>> -                             ret = syscall(__NR_quotactl, cmd[i],
>> +                             TEST(syscall(__NR_quotactl, cmd[i],
>>                                               (const char *)NULL, id,
>> -                                             (caddr_t)NULL);
>> -                             if (ret != 0) {
>> +                                             (caddr_t)NULL));
>> +                             if (TEST_RETURN != 0) {
>>                                       tst_resm(TFAIL|TTERRNO, "cmd=0x%x",
>> cmd[i]);
>>                               } else {
>>                                       tst_resm(TPASS, "quotactl call
>> succeeded");
>> ============
>>
>>
>> However, new problem occurred after applying above patch.
>>
>> 2) The test failed with the following error in my system:
>>
>> ------------
>> quotactl01    1  TFAIL  :  cmd=0x800002: TEST_ERRNO=EFAULT(14): Bad
> address
>> quotactl01    2  TFAIL  :  cmd=0x800003: TEST_ERRNO=EFAULT(14): Bad
> address
>> quotactl01    3  TFAIL  :  cmd=0x800007: TEST_ERRNO=EFAULT(14): Bad
> address
>> quotactl01    4  TFAIL  :  cmd=0x800008: TEST_ERRNO=EFAULT(14): Bad
> address
>> quotactl01    5  TFAIL  :  cmd=0x800005: TEST_ERRNO=EFAULT(14): Bad
> address
>> quotactl01    6  TFAIL  :  cmd=0x800006: TEST_ERRNO=EFAULT(14): Bad
> address
>> quotactl01    7  TFAIL  :  cmd=0x800004: TEST_ERRNO=EFAULT(14): Bad
> address
>> quotactl01    8  TFAIL  :  cmd=0x800001: TEST_ERRNO=EFAULT(14): Bad
> address
>> ------------
>>
>> "EFAULT" means that there is an error in "addr".
>> The format of "quotactl" is following:
>> ------------
>> int quotactl(int cmd, const char *special, int id, caddr_t addr);
>> ------------
>>
>> Therefore, "EFAULT" means that 4th argument of "quotactl()" has problem.
>>
>> In "${LTPROOT}/testcases/kernel/syscalls/quotactl/quotactl01.c", 4th
>> argument of "quotactl()" is "NULL":
>> Is it right?
>>
>>
>> I'm glad if I get your help.

    It's not completely fixed; the test was broken in the first place.
I'll need to create a script which will generate a tempfs filesystem,
enable quota on it, then jettison it after the test is done; otherwise
$TMP could have quotas enabled or disabled (nondeterministic)...
Thanks,
-Garrett

------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

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

end of thread, other threads:[~2010-01-13  8:19 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-05  8:30 [LTP] quotactl01 testcases problem Mitani
2010-01-07 11:06 ` Subrata Modak
2010-01-08  6:17   ` Mitani
2010-01-13  2:10   ` Mitani
2010-01-13  8:19     ` Garrett Cooper

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