* [LTP] readahead02: change the test pass to 2M
@ 2014-05-09 5:45 Madan
2014-05-09 6:43 ` Jan Stancek
0 siblings, 1 reply; 2+ messages in thread
From: Madan @ 2014-05-09 5:45 UTC (permalink / raw)
To: ltp-list
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
Updating the change in the readahead behaviour of max 2M cache.
http://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/commit/?id=c7252018cef0da5db35cd03aa7b6c44ab597a0b7
Signed-off-by:Hoisaleshwara Madan V S <hoisalvs@in.ibm.com>
Patch :
diff --git a/testcases/kernel/syscalls/readahead/readahead02.c b/testcases/kernel/syscalls/readahe
index 66158f0..dc6a191 100644
--- a/testcases/kernel/syscalls/readahead/readahead02.c
+++ b/testcases/kernel/syscalls/readahead/readahead02.c
@@ -306,13 +306,14 @@ static void test_readahead(void)
tst_resm(TINFO, "cache can hold at least: %ld kB", cached_max);
tst_resm(TINFO, "read_testfile(0) used cache: %ld kB", cached);
tst_resm(TINFO, "read_testfile(1) used cache: %ld kB", cached_ra);
-
- if (cached_max * 1024 >= testfile_size) {
+
+ /* readahead will cache max of 2 M */
+ if (cached_max * 1024 >= 2 * 1024) {
/*
* if cache can hold ~testfile_size then cache increase
* for readahead should be at least testfile_size/2
*/
- if (cached_ra * 1024 > testfile_size / 2)
+ if (cached_ra * 1024 > 2 * 1024)
tst_resm(TPASS, "using cache as expected");
else
tst_resm(TWARN, "using less cache than expected");
------------------------------------------------------------------------------
Is your legacy SCM system holding you back? Join Perforce May 7 to find out:
• 3 signs your SCM is hindering your productivity
• Requirements for releasing software faster
• Expert tips and advice for migrating your SCM now
http://p.sf.net/sfu/perforce
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [LTP] readahead02: change the test pass to 2M
2014-05-09 5:45 [LTP] readahead02: change the test pass to 2M Madan
@ 2014-05-09 6:43 ` Jan Stancek
0 siblings, 0 replies; 2+ messages in thread
From: Jan Stancek @ 2014-05-09 6:43 UTC (permalink / raw)
To: madanvs; +Cc: ltp-list
----- Original Message -----
> From: "Madan" <madanvs@linux.vnet.ibm.com>
> To: ltp-list@lists.sourceforge.net
> Sent: Friday, 9 May, 2014 7:45:49 AM
> Subject: [LTP] readahead02: change the test pass to 2M
>
> 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
>
> Updating the change in the readahead behaviour of max 2M cache.
> http://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/commit/?id=c7252018cef0da5db35cd03aa7b6c44ab597a0b7
>
> Signed-off-by:Hoisaleshwara Madan V S <hoisalvs@in.ibm.com>
I posted a similar patch:
http://article.gmane.org/gmane.linux.ltp/20466
which keeps sizes, but makes multiple readahead calls.
Regards,
Jan
>
> Patch :
>
> diff --git a/testcases/kernel/syscalls/readahead/readahead02.c
> b/testcases/kernel/syscalls/readahe
> index 66158f0..dc6a191 100644
> --- a/testcases/kernel/syscalls/readahead/readahead02.c
> +++ b/testcases/kernel/syscalls/readahead/readahead02.c
> @@ -306,13 +306,14 @@ static void test_readahead(void)
> tst_resm(TINFO, "cache can hold at least: %ld kB", cached_max);
> tst_resm(TINFO, "read_testfile(0) used cache: %ld kB", cached);
> tst_resm(TINFO, "read_testfile(1) used cache: %ld kB", cached_ra);
> -
> - if (cached_max * 1024 >= testfile_size) {
> +
> + /* readahead will cache max of 2 M */
> + if (cached_max * 1024 >= 2 * 1024) {
> /*
> * if cache can hold ~testfile_size then cache increase
> * for readahead should be at least testfile_size/2
> */
> - if (cached_ra * 1024 > testfile_size / 2)
> + if (cached_ra * 1024 > 2 * 1024)
> tst_resm(TPASS, "using cache as expected");
> else
> tst_resm(TWARN, "using less cache than expected");
>
>
>
> ------------------------------------------------------------------------------
> Is your legacy SCM system holding you back? Join Perforce May 7 to find out:
> • 3 signs your SCM is hindering your productivity
> • Requirements for releasing software faster
> • Expert tips and advice for migrating your SCM now
> http://p.sf.net/sfu/perforce
> _______________________________________________
> Ltp-list mailing list
> Ltp-list@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ltp-list
>
------------------------------------------------------------------------------
Is your legacy SCM system holding you back? Join Perforce May 7 to find out:
• 3 signs your SCM is hindering your productivity
• Requirements for releasing software faster
• Expert tips and advice for migrating your SCM now
http://p.sf.net/sfu/perforce
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-05-09 6:43 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-09 5:45 [LTP] readahead02: change the test pass to 2M Madan
2014-05-09 6:43 ` Jan Stancek
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.