Fix memcontrol02 test failure on powerpc.
PATCH 1/1 Fix memcontrol02 test failure on powerpc.
memcontrol02 test is failing on PowerPC with 50MB allocation. Increase to 100MB for both anonymous and page cache tests, and bump minimum device size from 300MB to 400MB accordingly.
--- testcases/kernel/controllers/memcg/memcontrol02.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-)
testcases/kernel/controllers/memcg/memcontrol02.c +7 -7
@@ -32,9 +32,9 @@ static struct tst_cg_group *cg_child;static int fd;static int file_to_all_error =10 ; -static void alloc_anon_50M_check (void ) +static void alloc_anon_100M_check (void ) { -const ssize_t size =MB (50 ); +const ssize_t size =MB (100 );char *buf, *ptr;ssize_t anon, current; const char *const anon_key_fmt =
@@ -58,9 +58,9 @@ static void alloc_anon_50M_check(void) current, anon); } -static void alloc_pagecache_50M_check (void ) +static void alloc_pagecache_100M_check (void ) { -const size_t size =MB (50 ); +const size_t size =MB (100 );size_t current, file;const char *const file_key_fmt =TST_CG_VER_IS_V1 (tst_cg,"memory" ) ?"cache %zd" :"file %zd" ;
@@ -102,9 +102,9 @@ static void test_memcg_current(unsigned int n) current);if (!n) -alloc_anon_50M_check (); +alloc_anon_100M_check ();else -alloc_pagecache_50M_check (); +alloc_pagecache_100M_check (); }else {tst_reap_children (); cg_child =tst_cg_group_rm (cg_child);
@@ -136,7 +136,7 @@ static struct tst_test test = { .tcnt = 2, .test = test_memcg_current, .mount_device = 1, - .dev_min_size = 300, + .dev_min_size = 400, .mntpoint = TMPDIR, .all_filesystems = 1, .forks_child = 1,
Signature · 5 lines
2.53.0 -- Mailing list info: https://lists.linux.it/listinfo/ltp
Hi Pavithra,
Quoted 3 lines · Pavithra
Fix memcontrol02 test failure on powerpc.
Signed-off-by Pavithra <[email protected]>
The patch is fixing a test regression so it needs a Fixes: tag pointing to the commit that introduced the 50 MB allocation values. Please add it at the end of the commit message body, before the Signed-off-by line.
---
Note:
Our agent completed the review of the patch. The agent can sometimes produce false positives although often its findings are genuine. If you find issues with the review, please comment this email or ignore the suggestions.
Regards,
LTP AI Reviewer
Signature · 1 line
Mailing list info: https://lists.linux.it/listinfo/ltp
Hi Pavithra,
Quoted 3 lines
memcontrol02 test is failing on PowerPC with 50MB allocation. Increase to 100MB for both anonymous and page cache tests, and bump minimum device size from 300MB to 400MB accordingly.
can you please explain better what's the real issue? We need a technical explaination of why this test is failing in PPC.
Quoted 11 lines
Signed-off-by Pavithra <[email protected]>--- testcases/kernel/controllers/memcg/memcontrol02.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-)testcases/kernel/controllers/memcg/memcontrol02.c +0
-0
testcases/kernel/controllers/memcg/memcontrol02.c static struct tst_cg_group *cg_child; · line 35
Quoted 5 lines
testcases/kernel/controllers/memcg/memcontrol02.c +1
-1@@ -32,9 +32,9 @@ static struct tst_cg_group *cg_child;static int fd;static int file_to_all_error =10 ; -static void alloc_anon_50M_check (void ) +static void alloc_anon_100M_check (void )
Also this function name is quite wrong. We are exposing internal function implementation in the name itself. This needs to be fixed with a name that is not exposing the quantity of MB we are actually allocating, since it may change in the future.
Regards,
--
Andrea Cervesato
SUSE QE Automation Engineer Linux
[email protected]
Signature · 1 line
Mailing list info: https://lists.linux.it/listinfo/ltp