ltp.lists.linux.it archive mirror
 help / color / mirror / Atom feed
From: Yang Xu <xuyang2018.jy@cn.fujitsu.com>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH 2/2] syscalls/ptrace08: Add exception for RHEL8 4.18 kernel
Date: Mon, 2 Nov 2020 19:45:32 +0800	[thread overview]
Message-ID: <5F9FF15C.8080308@cn.fujitsu.com> (raw)
In-Reply-To: <1604317338-22774-2-git-send-email-xuyang2018.jy@cn.fujitsu.com>

Hi All
Sorry, please ignore this email.:-[

> RHEL 4.18 kernel got this patch
> commit bd14406b78e6d ("perf/hw_breakpoint: Modify breakpoint even if the new attr has disabled set") since 4.18.0-49,
>
> therefore it will return success instead of EINVAL when modifying breakpoint.
>
> Without this fix, the test will fail on RHEL8 4.18 kernel with:
> tst_kernel.c:79: TINFO: uname.machine=x86_64 kernel is 64bit
> ptrace08.c:90: TINFO: Trying address 0xffff800000000000
> ptrace08.c:116: TFAIL: ptrace() breakpoint with kernel addr succeeded
> ptrace08.c:90: TINFO: Trying address 0xffffffffffffffff
> ptrace08.c:116: TFAIL: ptrace() breakpoint with kernel addr succeeded
> ptrace08.c:90: TINFO: Trying address 0xffffbfffffffffff
> ptrace08.c:116: TFAIL: ptrace() breakpoint with kernel addr succeeded
>
> Signed-off-by: Yang Xu <xuyang2018.jy@cn.fujitsu.com>
> ---
>  testcases/kernel/syscalls/ptrace/ptrace08.c | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/testcases/kernel/syscalls/ptrace/ptrace08.c b/testcases/kernel/syscalls/ptrace/ptrace08.c
> index 63086f1fd..741923e36 100644
> --- a/testcases/kernel/syscalls/ptrace/ptrace08.c
> +++ b/testcases/kernel/syscalls/ptrace/ptrace08.c
> @@ -56,6 +56,11 @@ static pid_t child_pid;
>  
>  static int deffered_check;
>  
> +static struct tst_kern_exv kvers[] = {
> +	{"RHEL8", "4.18.0-49"},
> +	{NULL, NULL},
> +};
> +
>  static void setup(void)
>  {
>  	/*
> @@ -72,7 +77,7 @@ static void setup(void)
>  	 * disabled instead and the EINVAL was returned when dr7 was written to
>  	 * enable it again.
>  	 */
> -	if (tst_kvercmp(4, 19, 0) < 0)
> +	if (tst_kvercmp2(4, 19, 0, kvers) < 0)
>  		deffered_check = 1;
>  }
>  




  reply	other threads:[~2020-11-02 11:45 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-02 11:42 [LTP] [PATCH 1/2] syscalls/ptrace03: Clean up and converted into new api Yang Xu
2020-11-02 11:42 ` [LTP] [PATCH 2/2] syscalls/ptrace08: Add exception for RHEL8 4.18 kernel Yang Xu
2020-11-02 11:45   ` Yang Xu [this message]
2020-11-10  6:57 ` [LTP] [PATCH 1/2] syscalls/ptrace03: Clean up and converted into new api Li Wang
  -- strict thread matches above, loose matches on Subject: below --
2020-10-29 16:35 [LTP] [PATCH 1/2] tst_kvercmp: Add rhel7,8 support Yang Xu
2020-10-29 16:35 ` [LTP] [PATCH 2/2] syscalls/ptrace08: Add exception for RHEL8 4.18 kernel Yang Xu

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=5F9FF15C.8080308@cn.fujitsu.com \
    --to=xuyang2018.jy@cn.fujitsu.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;
as well as URLs for NNTP newsgroup(s).