Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

max_map_count: do not count [vdso] mapping on ia64 #17

Closed
dvlasenk opened this issue Jul 22, 2014 · 2 comments
Closed

max_map_count: do not count [vdso] mapping on ia64 #17

dvlasenk opened this issue Jul 22, 2014 · 2 comments

Comments

@dvlasenk
Copy link

I'm getting this on rhel5 on Itanium:
max_map_count 0 TINFO : set overcommit_memory to 2
max_map_count 0 TINFO : set max_map_count to 64
max_map_count 0 TINFO : set overcommit_memory to 2
max_map_count 0 TINFO : set max_map_count to 64
max_map_count 1 TFAIL : 66 map entries in total, but expected 64 entries
max_map_count 0 TINFO : set max_map_count to 256
max_map_count 0 TINFO : set overcommit_memory to 2
max_map_count 0 TINFO : set max_map_count to 64
max_map_count 1 TFAIL : 66 map entries in total, but expected 64 entries
max_map_count 0 TINFO : set max_map_count to 256
max_map_count 2 TFAIL : 258 map entries in total, but expected 256 entries
...

A possible fix is:

--- a/testcases/kernel/mem/tunable/max_map_count.c
+++ b/testcases/kernel/mem/tunable/max_map_count.c
@@ -137,6 +137,18 @@ static int filter_map(char *line)
{
return strncmp(line, "ffff0000-ffff1000", 17) == 0;
}
+#elif defined(ia64)
+static int filter_map(char *line)
+{

  •   char buf[BUFSIZ];
    
  •   int ret;
    
  •   ret = sscanf(line, "%_p-%_p %_4s %_p %_2d:%_2d %*d %s", buf);
    
  •   if (ret != 1)
    
  •           return 0;
    
  •   return strcmp(buf, "[vdso]") == 0;
    
    +}
    #else
    static int filter_map(char *line)
    {
@vapier
Copy link
Member

vapier commented Jul 22, 2014

i don't think we need to special case ia64. the default implementation should read the line and compare to "[vdso]" as that is the name almost all arches use.

@vapier
Copy link
Member

vapier commented Jul 22, 2014

fixed by commit 10dc4e0

@vapier vapier closed this as completed Jul 22, 2014
jstancek added a commit that referenced this issue May 22, 2017
Only newlib testcases support SAFE macros in cleanup().
When SAFE_UNLINK fails, it creates infinite loop between
tst_brk_ and cleanup:

 #0  tst_res__ at tst_res.c:153
 #1  0x0000000000407ba8 in tst_brk__ at tst_res.c:480
 #2  0x00000000004081fe in tst_brkm_ at tst_res.c:577
 #3  0x000000000040a7c9 in safe_unlink at safe_macros.c:358
 #4  0x0000000000404abd in cleanup () at pipeio.c:497
 #5  0x0000000000407bc7 in tst_brk__ at tst_res.c:498
 #6  0x00000000004081fe in tst_brkm_ at tst_res.c:577
 #7  0x000000000040c1d6 in def_handler at tst_sig.c:231
 #8  <signal handler called>
 #9  0x00007f29c2cbd1f7 in __GI_raise at ../nptl/sysdeps/unix/sysv/linux/raise.c:56
 #10 0x00007f29c2cbe8e8 in __GI_abort () at abort.c:90
 #11 0x00000000004081af in tst_brkm_ at tst_res.c:581
 #12 0x000000000040a7c9 in safe_unlink at safe_macros.c:358
 #13 0x0000000000404abd in cleanup () at pipeio.c:497
 #14 0x0000000000407bc7 in tst_brk__ at tst_res.c:498
 #15 0x00000000004081fe in tst_brkm_ at tst_res.c:577
 #16 0x000000000040c1d6 in def_handler at tst_sig.c:231
 #17 <signal handler called>
 #18 0x00007f29c2cbd1f7 in __GI_raise at ../nptl/sysdeps/unix/sysv/linux/raise.c:56
 #19 0x00007f29c2cbe8e8 in __GI_abort () at abort.c:90
 #20 0x00000000004081af in tst_brkm_ at tst_res.c:581
 #21 0x000000000040a7c9 in safe_unlink at safe_macros.c:358
 #22 0x0000000000404abd in cleanup () at pipeio.c:497
 ...

Signed-off-by: Jan Stancek <jstancek@redhat.com>
amir73il added a commit to amir73il/ltp that referenced this issue Jun 16, 2022
…oject#17

The test case (linux-test-project#17) should be placing an ignored mask on a directory
(DIR_PATH) with FAN_EVENT_ON_CHILD and see that the event on
a child (FILE_PATH) is ignored.

But what the test case was doing is setting an ignored mask
with FAN_EVENT_ON_CHILD on the child (FILE_PATH), which also
ignores the event, but that wasn't the purpose of the test case.

Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants