vm: add a copy-on-write ref count to vm_page
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
#ifndef KERNEL_VM_H_
|
||||
#define KERNEL_VM_H_
|
||||
|
||||
#include <kernel/atomic.h>
|
||||
#include <kernel/bitmap.h>
|
||||
#include <kernel/btree.h>
|
||||
#include <kernel/locks.h>
|
||||
@@ -221,6 +222,9 @@ struct vm_page {
|
||||
};
|
||||
|
||||
union {
|
||||
/* how many vm_areas reference this vm_page. if >0, the page is
|
||||
* subject to copy-on-write. */
|
||||
atomic_t p_cow_ref;
|
||||
uint32_t p_priv2;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user