feat: implement proper destruction of pages, including for shared pages

This commit is contained in:
2024-12-05 22:23:50 +00:00
parent dd46200256
commit 9aa9cdb91e
4 changed files with 119 additions and 45 deletions

View File

@@ -45,8 +45,7 @@ struct shared_file_page
};
bool init_pages (struct hash *pages);
struct page_entry *page_insert_swapped (void *upage, void* kpage,
struct thread *owner);
bool page_insert_swapped (void *upage, void *kpage, struct list *owners);
struct page_entry *page_insert_file (struct file *file, off_t ofs, void *upage,
uint32_t read_bytes, uint32_t zero_bytes,
bool writable, enum page_type);