public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
From: Yang Xu <xuyang_jy_0410@163.com>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH v2] Fix prctl02
Date: Fri, 24 Jan 2020 21:06:44 +0800	[thread overview]
Message-ID: <f3c20a91-7903-6c8d-340f-defb34ebb325@163.com> (raw)
In-Reply-To: <20200124124847.GB31214@rei.lan>

Hi!
> Hi!
>>> The prctl() system call takes 5 integer arguments but only 3 of them were
>>> passed in the test. This means that the system call read random garbage
>>> from stack in place of the two missing arguments and failed even on some
>>> perfectly valid combinations of arguments on some platforms.
>>>
>>> - Change num_invalid to ULONG_MAX
>>> - Fix arguments in test case 9, 13 and 14
>>> - Fix test call of prctl() to have all 5 arguments
>> looks prctl manpages and kernel code, you are right, Thanks for the fix!
>> Feel free to add??
>> Reviewed-by: xuyang_jy_0410@163.com
>> Tested-by: xuyang_jy_0410@163.com
>>
>> Also, do we should use 5 arguments for other prctl test cases?
> 
> It depends on the option argument, the PR_CAP_AMBIENT explicitely states
> that arg4 and arg5 must be set to 0 as well as the
> PR_GET_SPECULATION_CTRL.
> 
> Some of the options explicitely say that some arguments are ignored.
> 
> And some, including PR_SET_NO_NEW_PRIVS does not say anyting.
Thanks for your answer. I see.
> 


  reply	other threads:[~2020-01-24 13:06 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-23 14:31 [LTP] [PATCH] Fix prctl02 Martin Doucha
2020-01-23 14:55 ` Jan Stancek
2020-01-23 15:18   ` [LTP] [PATCH v2] " Martin Doucha
2020-01-23 23:54     ` Jan Stancek
2020-01-24 11:10     ` Yang Xu
2020-01-24 12:48       ` Cyril Hrubis
2020-01-24 13:06         ` Yang Xu [this message]
2020-01-24 14:14     ` Cyril Hrubis

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=f3c20a91-7903-6c8d-340f-defb34ebb325@163.com \
    --to=xuyang_jy_0410@163.com \
    --cc=ltp@lists.linux.it \
    /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