https://git.reactos.org/?p=reactos.git;a=commitdiff;h=789d7a7741aeb95a2000fa4e5c5631503b1e29cf

commit 789d7a7741aeb95a2000fa4e5c5631503b1e29cf
Author:     Jérôme Gardou <[email protected]>
AuthorDate: Mon Aug 2 18:48:07 2021 +0200
Commit:     Jérôme Gardou <[email protected]>
CommitDate: Wed Aug 4 17:48:39 2021 +0200

    [NTOS:MM] When mapping pages for zeroing them, disable cache, enable write 
through
    
    Idea from Thomas Faber
---
 ntoskrnl/mm/ARM3/hypermap.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/ntoskrnl/mm/ARM3/hypermap.c b/ntoskrnl/mm/ARM3/hypermap.c
index 4113814e6a6..e72a6878cc7 100644
--- a/ntoskrnl/mm/ARM3/hypermap.c
+++ b/ntoskrnl/mm/ARM3/hypermap.c
@@ -150,6 +150,10 @@ MiMapPagesInZeroSpace(IN PMMPFN Pfn1,
     PointerPte += (Offset + 1);
     TempPte = ValidKernelPte;
 
+    /* Disable cache. Write through */
+    MI_PAGE_DISABLE_CACHE(&TempPte);
+    MI_PAGE_WRITE_THROUGH(&TempPte);
+
     /* Make sure the list isn't empty and loop it */
     ASSERT(Pfn1 != (PVOID)LIST_HEAD);
     while (Pfn1 != (PVOID)LIST_HEAD)

Reply via email to