diff options
author | alc <alc@FreeBSD.org> | 2005-11-01 04:30:21 +0000 |
---|---|---|
committer | alc <alc@FreeBSD.org> | 2005-11-01 04:30:21 +0000 |
commit | e3ab6622c5b23b577d5f658e095529d74069b75e (patch) | |
tree | 7b4cf9b2e9ab1f32853fa218dc8f07edc99d8055 | |
parent | 6e5e6ec0a4cef4beec206c97868cd73bdc69d9dd (diff) | |
download | FreeBSD-src-e3ab6622c5b23b577d5f658e095529d74069b75e.zip FreeBSD-src-e3ab6622c5b23b577d5f658e095529d74069b75e.tar.gz |
Consider the zero-copy transmission of a page that was wired by mlock(2).
If a copy-on-write fault occurs on the page, the new copy should inherit
a part of the original page's wire count.
Submitted by: tegge
MFC after: 1 week
-rw-r--r-- | sys/vm/vm_page.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/vm/vm_page.c b/sys/vm/vm_page.c index 98ec1ef..94943ec 100644 --- a/sys/vm/vm_page.c +++ b/sys/vm/vm_page.c @@ -1677,6 +1677,8 @@ vm_page_cowfault(vm_page_t m) mnew->valid = VM_PAGE_BITS_ALL; vm_page_dirty(mnew); vm_page_flag_clear(mnew, PG_BUSY); + mnew->wire_count = m->wire_count - m->cow; + m->wire_count = m->cow; } } |