From: chrubis@suse.cz
To: Jan Stancek <jstancek@redhat.com>
Cc: ltp-list@lists.sourceforge.net
Subject: Re: [LTP] [PATCH 2/2] readahead02: read in 2M chunks
Date: Thu, 15 May 2014 13:47:01 +0200 [thread overview]
Message-ID: <20140515114701.GA23965@rei.Home> (raw)
In-Reply-To: <b98288e83160e3c44783a9a37078910a4b724f1a.1398155754.git.jstancek@redhat.com>
Hi!
> Max readahead size has been limited since commit:
> commit 6d2be915e589b58cb11418cbe1f22ff90732b6ac
> Author: Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com>
> Date: Thu Apr 3 14:48:23 2014 -0700
> mm/readahead.c: fix readahead failure for memoryless NUMA nodes
> and limit readahead pages
>
> Update testcase to read ahead in 2M chunks, this change is
> compatible with older kernels.
>
> Signed-off-by: Jan Stancek <jstancek@redhat.com>
> ---
> testcases/kernel/syscalls/readahead/readahead02.c | 9 +++++++--
> 1 files changed, 7 insertions(+), 2 deletions(-)
>
> diff --git a/testcases/kernel/syscalls/readahead/readahead02.c b/testcases/kernel/syscalls/readahead/readahead02.c
> index 8940821..5b1524e 100644
> --- a/testcases/kernel/syscalls/readahead/readahead02.c
> +++ b/testcases/kernel/syscalls/readahead/readahead02.c
> @@ -213,8 +213,13 @@ static void read_testfile(int do_readahead, const char *fname, size_t fsize,
> tst_brkm(TBROK | TERRNO, cleanup, "Failed to open %s", fname);
>
> if (do_readahead) {
> - TEST(ltp_syscall(__NR_readahead, fd, (off64_t) 0,
> - (size_t) fsize));
> + /* read ahead in chunks, 2MB is maximum since 3.15-rc1 */
> + for (i = 0; i < fsize; i += 2*1024*1024) {
> + TEST(ltp_syscall(__NR_readahead, fd,
> + (off64_t) i, 2*1024*1024));
> + if (TEST_RETURN != 0)
> + break;
> + }
These two patches looks good to me.
--
Cyril Hrubis
chrubis@suse.cz
------------------------------------------------------------------------------
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.
Get unparalleled scalability from the best Selenium testing platform available
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
prev parent reply other threads:[~2014-05-15 11:47 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-22 8:37 [LTP] [PATCH 1/2] readahead02: fix signed/unsigned comparison warnings Jan Stancek
2014-04-22 8:37 ` [LTP] [PATCH 2/2] readahead02: read in 2M chunks Jan Stancek
2014-05-13 5:18 ` Madan
2014-05-13 6:55 ` Jan Stancek
2014-05-13 8:42 ` Madan
2014-05-13 9:20 ` Jan Stancek
2014-05-15 11:47 ` chrubis [this message]
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=20140515114701.GA23965@rei.Home \
--to=chrubis@suse.cz \
--cc=jstancek@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.