Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/uvm Upon further investigation, in uvm_map_pageable(), e...



details:   https://anonhg.NetBSD.org/src/rev/6844423eb153
branches:  trunk
changeset: 473252:6844423eb153
user:      thorpej <thorpej%NetBSD.org@localhost>
date:      Wed May 26 23:53:48 1999 +0000

description:
Upon further investigation, in uvm_map_pageable(), entry->protection is the
right access_type to pass to uvm_fault_wire().  This way, if the entry has
VM_PROT_WRITE, and the entry is marked COW, the copy will happen immediately
in uvm_fault(), as if the access were performed.

diffstat:

 sys/uvm/uvm_map.c |  10 ++--------
 1 files changed, 2 insertions(+), 8 deletions(-)

diffs (25 lines):

diff -r a957a8a219ed -r 6844423eb153 sys/uvm/uvm_map.c
--- a/sys/uvm/uvm_map.c Wed May 26 22:19:33 1999 +0000
+++ b/sys/uvm/uvm_map.c Wed May 26 23:53:48 1999 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: uvm_map.c,v 1.45 1999/05/26 19:16:36 thorpej Exp $     */
+/*     $NetBSD: uvm_map.c,v 1.46 1999/05/26 23:53:48 thorpej Exp $     */
 
 /* 
  * Copyright (c) 1997 Charles D. Cranor and Washington University.
@@ -2169,14 +2169,8 @@
                if (rv) {
                        entry->wired_count--;
                } else if (entry->wired_count == 1) {
-                       /*
-                        * XXXTHORPEJ: VM_PROT_NONE.  What about COW
-                        * entries?  Should we enter with max_protection
-                        * so that we're guaranteed not even mod/ref
-                        * emulation faults will occur?
-                        */
                        rv = uvm_fault_wire(map, entry->start, entry->end,
-                           VM_PROT_NONE);
+                           entry->protection);
                        if (rv) {
                                failed = entry->start;
                                entry->wired_count--;



Home | Main Index | Thread Index | Old Index