summaryrefslogtreecommitdiffstats
path: root/kernel/mm/mmu_notifier.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/mm/mmu_notifier.c')
-rw-r--r--kernel/mm/mmu_notifier.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/kernel/mm/mmu_notifier.c b/kernel/mm/mmu_notifier.c
index 3b9b3d074..5fbdd367b 100644
--- a/kernel/mm/mmu_notifier.c
+++ b/kernel/mm/mmu_notifier.c
@@ -123,6 +123,23 @@ int __mmu_notifier_clear_flush_young(struct mm_struct *mm,
return young;
}
+int __mmu_notifier_clear_young(struct mm_struct *mm,
+ unsigned long start,
+ unsigned long end)
+{
+ struct mmu_notifier *mn;
+ int young = 0, id;
+
+ id = srcu_read_lock(&srcu);
+ hlist_for_each_entry_rcu(mn, &mm->mmu_notifier_mm->list, hlist) {
+ if (mn->ops->clear_young)
+ young |= mn->ops->clear_young(mn, mm, start, end);
+ }
+ srcu_read_unlock(&srcu, id);
+
+ return young;
+}
+
int __mmu_notifier_test_young(struct mm_struct *mm,
unsigned long address)
{