From bf6d4253ee61e7325d3cd61086924ae203e9726c Mon Sep 17 00:00:00 2001 From: alc Date: Tue, 8 Nov 2005 06:33:21 +0000 Subject: If a physical page is mapped by two or more virtual addresses, transmitted by the zero-copy sockets method, and written to before the transmission completes, we need to destroy all of the existing mappings to the page, not just the one that we fault on. Otherwise, the mappings will no longer be to the same page and changes made through one of the mappings will not be visible through the others. Observed by: tegge --- sys/vm/vm_page.c | 1 + 1 file changed, 1 insertion(+) (limited to 'sys') diff --git a/sys/vm/vm_page.c b/sys/vm/vm_page.c index 94943ec..9cc8642 100644 --- a/sys/vm/vm_page.c +++ b/sys/vm/vm_page.c @@ -1651,6 +1651,7 @@ vm_page_cowfault(vm_page_t m) pindex = m->pindex; retry_alloc: + pmap_remove_all(m); vm_page_remove(m); mnew = vm_page_alloc(object, pindex, VM_ALLOC_NORMAL); if (mnew == NULL) { -- cgit v1.1