Browse Source

fix: set p bit of cow page whose refcount is 1

greatbridf 2 years ago
parent
commit
8887ccd4ed
1 changed files with 1 additions and 0 deletions
  1. 1 0
      src/kernel/interrupt.cpp

+ 1 - 0
src/kernel/interrupt.cpp

@@ -196,6 +196,7 @@ extern "C" void int14_handler(int14_data* d)
         // if it is a dying page
         if (*page->ref_count == 1) {
             page->attr.in.cow = 0;
+            pte->in.p = 1;
             pte->in.a = 0;
             pte->in.rw = mm_area->attr.in.write;
             return;