public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
From: Wanlong Gao <gaowanlong@cn.fujitsu.com>
To: Nitin Yadav <Nitin.Yadav@mphasis.com>
Cc: ltp-list@lists.sourceforge.net
Subject: Re: [LTP] [PATCH] io_submit: uninitialized iocb may not return -EINVAL
Date: Tue, 16 Oct 2012 10:31:17 +0800	[thread overview]
Message-ID: <507CC6F5.3090409@cn.fujitsu.com> (raw)
In-Reply-To: <E351E450E8B9F54684A699D42DC5ADF225E9C6D3@MPBAGVEX02.corp.mphasis.com>

On 10/09/2012 02:08 PM, Nitin Yadav wrote:
> Hi Wanlong,
>    
>   Below are the output where I am getting - EPERM (returned value = 1) as a return value from io_submit. 
> 
> io_submit01    1  TPASS  :  expected failure - returned value = -22 : Invalid argument
> io_submit01    2  TPASS  :  expected failure - returned value = -22 : Invalid argument
> io_submit01    3  TFAIL    :  unexpected failure - returned value = 1 : Unknown error 18446744073709551615, expected one of -EINVAL, -EBADF, -EFAULT
> io_submit01    4  TPASS  :  expected failure - returned value = -14 : Bad address
> io_submit01    5  TPASS  :  expected failure - returned value = -22 : Invalid argument
> io_submit01    6  TPASS  :  expected failure - returned value = -9   : Bad file descriptor
> io_submit01    7  TPASS  :  expected success - returned value = 0
> io_submit01    8  TPASS  :  expected success - returned value = 1
> 
> Could you please let me know can we consider - EPERM case as a return value for io_submit.

OK, maybe I missed something, so, can you show us how did you produce this in detail?

Thanks,
Wanlong Gao

> 
> Thanks,
> Nitin Yadav
> 
> 
> 
> Hi Jan,
> 
>>>> --- a/testcases/kernel/syscalls/io_submit/io_submit01.c
>>>> +++ b/testcases/kernel/syscalls/io_submit/io_submit01.c
>>>> @@ -126,7 +126,21 @@ int main(int argc, char *argv[])
>>>>             /* 1.3 - EINVAL: uninitialized iocb */
>>>>             iocbs[0] = &iocb;
>>>>             TEST(io_submit(ctx, 1, iocbs));
>>>> -           check_result(-EINVAL, TEST_RETURN);
>>>> +           switch(TEST_RETURN) {
>>>> +                   case -EINVAL:
>>>> +                   case -EBADF:
>>>> +                   case -EFAULT:
>>>> +                   case -EPERM:
>>>
>>>
>>> I don't think io_submit(2) can return -EPERM.
>>>
>>> Do you think so?
>>
>> I was trying all sorts of random data and I remember seeing once "-1".
>> I'm failing to reproduce it today, so I could be wrong. If I fail to find
>> data that gives -EPERM, I'll remove it in v2.
> 
> 
> I looked into the io_submit(2) code in kernel and didn't see any path can
> return -EPERM, so I think you should confirm on it again.
> 
> Thanks,
> Wanlong Gao
> 
>>
>> Regards,
>> Jan
>>
>>>
>>> Thanks,
>>> Wanlong Gao
>>>
>>
>>
> 
> 
> Information transmitted by this e-mail is proprietary to MphasiS, its associated companies and/ or its customers and is intended 
> for use only by the individual or entity to which it is addressed, and may contain information that is privileged, confidential or 
> exempt from disclosure under applicable law. If you are not the intended recipient or it appears that this mail has been forwarded 
> to you without proper authority, you are notified that any use or dissemination of this information in any manner is strictly 
> prohibited. In such cases, please notify us immediately at mailmaster@mphasis.com and delete this mail from your records.
> 


------------------------------------------------------------------------------
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

  reply	other threads:[~2012-10-16  2:33 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-27  9:52 [LTP] crashme:fork12 test may kill other process that is not forked child 羅秉鈞
2012-06-29  7:45 ` Wanlong Gao
2012-10-09  6:08   ` [LTP] [PATCH] io_submit: uninitialized iocb may not return -EINVAL Nitin Yadav
2012-10-16  2:31     ` Wanlong Gao [this message]
2012-10-16  6:53       ` Jan Stancek
2012-10-16 10:11         ` chrubis
     [not found]           ` <E351E450E8B9F54684A699D42DC5ADF2263AF477@MPBAGVEX02.corp.mphasis.com>
     [not found]             ` <E351E450E8B9F54684A699D42DC5ADF22640E162@MPBAGVEX02.corp.mphasis.com>
2012-10-17 12:44               ` [LTP] [PATCH] io_submit: uninitialized iocb may notreturn-EINVAL chrubis
2012-06-29 16:22 ` [LTP] crashme:fork12 test may kill other process that is not forked child chrubis
  -- strict thread matches above, loose matches on Subject: below --
2012-07-05 13:03 [LTP] [PATCH] io_submit: uninitialized iocb may not return -EINVAL Nitin Yadav
2012-03-14 14:53 Jan Stancek
2012-03-15  1:09 ` Wanlong Gao
2012-03-15  2:09   ` Wanlong Gao
2012-03-15  7:48   ` Jan Stancek
2012-03-15  7:56     ` Wanlong Gao

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=507CC6F5.3090409@cn.fujitsu.com \
    --to=gaowanlong@cn.fujitsu.com \
    --cc=Nitin.Yadav@mphasis.com \
    --cc=ltp-list@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox