mm/khugepaged: fix the address passed to notifier on testing young
Commit8ee53820ed
("thp: mmu_notifier_test_young") introduced mmu_notifier_test_young(), but we are passing the wrong address. In xxx_scan_pmd(), the actual iteration address is "_address" not "address". We seem to misuse the variable on the very beginning. Change it to the right one. [akpm@linux-foundation.org fix whitespace, per everyone] Link: https://lkml.kernel.org/r/20250822063318.11644-1-richard.weiyang@gmail.com Fixes:8ee53820ed
("thp: mmu_notifier_test_young") Signed-off-by: Wei Yang <richard.weiyang@gmail.com> Reviewed-by: Dev Jain <dev.jain@arm.com> Reviewed-by: Zi Yan <ziy@nvidia.com> Acked-by: David Hildenbrand <david@redhat.com> Reviewed-by: Lorenzo Stoakes <lorenzo.stoakes@oracle.com> Cc: Baolin Wang <baolin.wang@linux.alibaba.com> Cc: Liam R. Howlett <Liam.Howlett@oracle.com> Cc: Nico Pache <npache@redhat.com> Cc: Ryan Roberts <ryan.roberts@arm.com> Cc: Barry Song <baohua@kernel.org> Cc: <stable@vger.kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
This commit is contained in:
parent
e6b9dce0ae
commit
394bfac1c7
|
@ -1417,8 +1417,8 @@ static int hpage_collapse_scan_pmd(struct mm_struct *mm,
|
|||
*/
|
||||
if (cc->is_khugepaged &&
|
||||
(pte_young(pteval) || folio_test_young(folio) ||
|
||||
folio_test_referenced(folio) || mmu_notifier_test_young(vma->vm_mm,
|
||||
address)))
|
||||
folio_test_referenced(folio) ||
|
||||
mmu_notifier_test_young(vma->vm_mm, _address)))
|
||||
referenced++;
|
||||
}
|
||||
if (!writable) {
|
||||
|
|
Loading…
Reference in New Issue