Source-Changes-HG archive

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

[src/trunk]: src/sys/uvm Slightly better test for "object with no real pages"...



details:   https://anonhg.NetBSD.org/src/rev/2ebbe6505f37
branches:  trunk
changeset: 474537:2ebbe6505f37
user:      thorpej <thorpej%NetBSD.org@localhost>
date:      Sat Jul 10 20:29:24 1999 +0000

description:
Slightly better test for "object with no real pages".  Test for NULL
pgo_releasepg rather than if the pager is the device pager.

diffstat:

 sys/uvm/uvm_mmap.c |  10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diffs (30 lines):

diff -r e7433b9b75c5 -r 2ebbe6505f37 sys/uvm/uvm_mmap.c
--- a/sys/uvm/uvm_mmap.c        Sat Jul 10 20:17:21 1999 +0000
+++ b/sys/uvm/uvm_mmap.c        Sat Jul 10 20:29:24 1999 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: uvm_mmap.c,v 1.30 1999/07/08 00:52:45 thorpej Exp $    */
+/*     $NetBSD: uvm_mmap.c,v 1.31 1999/07/10 20:29:24 thorpej Exp $    */
 
 /*
  * Copyright (c) 1997 Charles D. Cranor and Washington University.
@@ -197,16 +197,16 @@
                lim = end < entry->end ? end : entry->end;
 
                /*
-                * Special case for mapped devices; these are always
-                * considered resident.
+                * Special case for objects with no "real" pages.  Those
+                * are always considered resident (mapped devices).
                 */
                if (UVM_ET_ISOBJ(entry)) {
-                       extern struct uvm_pagerops uvm_deviceops; /* XXX */
 #ifdef DIAGNOSTIC
                        if (UVM_OBJ_IS_KERN_OBJECT(entry->object.uvm_obj))
                                panic("mincore: user map has kernel object");
 #endif
-                       if (entry->object.uvm_obj->pgops == &uvm_deviceops) {
+                       if (entry->object.uvm_obj->pgops->pgo_releasepg
+                           == NULL) {
                                for (/* nothing */; start < lim;
                                     start += PAGE_SIZE, vec++)
                                        subyte(vec, 1);



Home | Main Index | Thread Index | Old Index