diff options
| author | David Stevens <[email protected]> | 2023-01-13 11:30:11 +0900 |
|---|---|---|
| committer | Andrew Morton <[email protected]> | 2023-02-02 22:33:13 -0800 |
| commit | 2cf1338454a8a9a0b3c1271ccb521afa2d6ae241 (patch) | |
| tree | 1fa315c5c83d181efda307004e7fae64270ac4ca /tools/perf/scripts/python/bin/stackcollapse-report | |
| parent | 2973d8229b78d3f148e0c45916a1e8b237dc6167 (diff) | |
mm: fix khugepaged with shmem_enabled=advise
Pass vm_flags as a parameter to shmem_is_huge, rather than reading the
flags from the vm_area_struct in question. This allows the updated flags
from hugepage_madvise to be passed to the check, which is necessary
because madvise does not update the vm_area_struct's flags until after
hugepage_madvise returns.
This fixes an issue when shmem_enabled=madvise, where MADV_HUGEPAGE on
shmem was not able to register the mm_struct with khugepaged. Prior to
cd89fb065099, the mm_struct was registered by MADV_HUGEPAGE regardless of
the value of shmem_enabled (which was only checked when scanning vmas).
Link: https://lkml.kernel.org/r/[email protected]
Fixes: cd89fb065099 ("mm,thp,shmem: make khugepaged obey tmpfs mount flags")
Signed-off-by: David Stevens <[email protected]>
Cc: David Stevens <[email protected]>
Cc: Hugh Dickins <[email protected]>
Cc: Rik van Riel <[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