From: Cyril Hrubis <chrubis@suse.cz>
To: Paulson Raja L <lpaulsonraja@gmail.com>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] RFC:[PATCH v1] Added testcase to test mmap with MAP_SHARED_VALIDATE flag
Date: Wed, 15 Feb 2023 16:21:30 +0100 [thread overview]
Message-ID: <Y+z4en9kAOOMgGk9@yuki> (raw)
In-Reply-To: <CA+O3cCQk5CEKTqdCkHnMmAwqWF8ePeGOOuHXKBMPqsqwvv7ihA@mail.gmail.com>
Hi!
> +static void test_mmap(void)
> +{
> + mapped_address = mmap(NULL, TEST_FILE_SIZE, PROT_READ | PROT_WRITE,
> + (1 << 7) | (1 << 9) | MAP_SHARED_VALIDATE, fd_file, 0);
> + if (mapped_address != MAP_FAILED)
> + tst_res(TFAIL | TERRNO, "mmap() is successful, but it should have
> failed.");
> + else if (errno == EOPNOTSUPP)
> + tst_res(TPASS, "mmap() failed with errno set to EOPNOTSUPP.");
> + else
> + tst_res(TFAIL | TERRNO, "mmap() failed with unexpected error.");
> +}
> +
> +static struct tst_test test = {
> + .min_kver = "4.15",
> + .setup = setup,
> + .cleanup = cleanup,
> + .test_all = test_mmap,
> + .needs_tmpdir = 1,
> +};
First of all all the whitespaces are messed up and some of the lines are
wrapped, quite likely this was done by your email client. Please make
sure to send patches so that they do not get mangled like this.
See: https://www.kernel.org/doc/html/v4.17/process/email-clients.html
--
Cyril Hrubis
chrubis@suse.cz
--
Mailing list info: https://lists.linux.it/listinfo/ltp
next prev parent reply other threads:[~2023-02-15 15:20 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-15 8:34 [LTP] RFC:[PATCH v1] Added testcase to test mmap with MAP_SHARED_VALIDATE flag Paulson Raja L
2023-02-15 15:21 ` Cyril Hrubis [this message]
2023-02-28 10:20 ` Richard Palethorpe
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=Y+z4en9kAOOMgGk9@yuki \
--to=chrubis@suse.cz \
--cc=lpaulsonraja@gmail.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