diff options
| author | Matt Turner <mattst88@gmail.com> | 2026-10-07 23:24:04 -0400 |
|---|---|---|
| committer | Magnus Lindholm <linmag7@gmail.com> | 2026-10-18 00:44:43 +0200 |
| commit | 7d2d545992c1dd57185759312a642f643053f02c (patch) | |
| tree | 39b7b370a9bc1876e8ada1c5a96e0763437e9a05 /tools/perf/scripts/python/stackcollapse.py | |
| parent | a2460bfc8ac90f008cad77af690eee8cc8222553 (diff) | |
| download | linux-7d2d545992c1dd57185759312a642f643053f02c.tar.gz linux-7d2d545992c1dd57185759312a642f643053f02c.zip | |
alpha: add missing page_table_check_pte_clear() to ptep_get_and_clear()
Alpha's CONFIG_COMPACTION-gated ptep_get_and_clear() overrides the
generic version in include/linux/pgtable.h but omits its
page_table_check_pte_clear() call. With CONFIG_PAGE_TABLE_CHECK=y the
map count taken by set_ptes() is therefore never dropped when a PTE is
cleared through this path. zap_pte_range() clears PTEs this way, so the
first page freed after it hits the BUG_ON() in
__page_table_check_zero().
The call was instead placed in ptep_clear_flush() by commit dd5712f3379c
("alpha: fix user-space corruption during memory compaction"), where it
was harmless until alpha enabled page table check.
Add the missing call, and drop the now-duplicate one in
ptep_clear_flush(), which already goes through ptep_get_and_clear().
Fixes: e761b6fe4085 ("alpha: add ARCH_SUPPORTS_PAGE_TABLE_CHECK support")
Reviewed-by: Magnus Lindholm <linmag7@gmail.com>
Tested-by: Magnus Lindholm <linmag7@gmail.com>
Signed-off-by: Matt Turner <mattst88@gmail.com>
Link: https://lore.kernel.org/r/20261007-alpha-hugepages-v2-1-8e108af2d961@gmail.com
Signed-off-by: Magnus Lindholm <linmag7@gmail.com>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions
