Linux Kernel Selftest development
 help / color / mirror / Atom feed
From: Jie2x Zhou <jie2x.zhou@intel.com>
To: jie2x.zhou@intel.com, shuah@kernel.org, adobriyan@gmail.com,
	guozhengkui@vivo.com
Cc: akpm@linux-foundation.org, linux-kernel@vger.kernel.org,
	linux-fsdevel@vger.kernel.org, linux-kselftest@vger.kernel.org,
	Philip Li <philip.li@intel.com>
Subject: make run_tests -C proc: proc-pid-vm assertion failed.
Date: Fri,  9 Sep 2022 10:19:16 +0800	[thread overview]
Message-ID: <20220909021916.43293-1-jie2x.zhou@intel.com> (raw)

hi,

The test error is caused by g_vsyscall set failed.

Error output:
 selftests: proc: proc-pid-vm
 proc-pid-vm: proc-pid-vm.c:389: main: Assertion `rv == len' failed.
 Aborted

g_vsyscall is set to 0.
In proc-pid-vm.c:
/*
 * 0: vsyscall VMA doesn't exist        vsyscall=none
 * 1: vsyscall VMA is r-xp              vsyscall=emulate
 * 2: vsyscall VMA is --xp              vsyscall=xonly
 */
static int g_vsyscall;
static const char *str_vsyscall;

static const char str_vsyscall_0[] = "";
static const char str_vsyscall_1[] =
"ffffffffff600000-ffffffffff601000 r-xp 00000000 00:00 0                  [vsyscall]\n";
static const char str_vsyscall_2[] =
"ffffffffff600000-ffffffffff601000 --xp 00000000 00:00 0                  [vsyscall]\n";

The /proc/%u/maps output is:
buf=100000000-100001000 r-xp 00000000 00:2d 2                                /tmp/#2 (deleted)
ffffffffff600000-ffffffffff601000 --xp 00000000 00:00 0                  [vsyscall]

So the g_vsyscall should be 2 according to commentary(2: vsyscall VMA is --xp).
Is it a bug?

best regards,

             reply	other threads:[~2022-09-09  2:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-09  2:19 Jie2x Zhou [this message]
2022-09-09  5:20 ` make run_tests -C proc: proc-pid-vm assertion failed Alexey Dobriyan
2022-09-13  5:13   ` Zhou, Jie2X

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=20220909021916.43293-1-jie2x.zhou@intel.com \
    --to=jie2x.zhou@intel.com \
    --cc=adobriyan@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=guozhengkui@vivo.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=philip.li@intel.com \
    --cc=shuah@kernel.org \
    /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