diff options
| author | Cheng Li <[email protected]> | 2022-09-09 07:31:09 +0000 |
|---|---|---|
| committer | Andrew Morton <[email protected]> | 2022-10-03 14:03:08 -0700 |
| commit | 14455eabd8404a503dc8e80cd8ce185e96a94b22 (patch) | |
| tree | ebe035ca739c4efeecb5c1679aeb839db43ab101 /tools/perf/scripts/python/bin/stackcollapse-report | |
| parent | 0d83b2d89dbfad17b62d4e7fb8f0b0525ba1a204 (diff) | |
mm: use nth_page instead of mem_map_offset mem_map_next
To handle the discontiguous case, mem_map_next() has a parameter named
`offset`. As a function caller, one would be confused why "get next
entry" needs a parameter named "offset". The other drawback of
mem_map_next() is that the callers must take care of the map between
parameter "iter" and "offset", otherwise we may get an hole or duplication
during iteration. So we use nth_page instead of mem_map_next.
And replace mem_map_offset with nth_page() per Matthew's comments.
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Cheng Li <[email protected]>
Fixes: 69d177c2fc70 ("hugetlbfs: handle pages higher order than MAX_ORDER")
Reviewed-by: Matthew Wilcox (Oracle) <[email protected]>
Cc: Mike Kravetz <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/bin/stackcollapse-report')
0 files changed, 0 insertions, 0 deletions