Source-Changes-HG archive

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

[src/trunk]: src/sys/uvm uvm_km_kmem_alloc: return ENOMEM on failure in PMAP_...



details:   https://anonhg.NetBSD.org/src/rev/e6657954a506
branches:  trunk
changeset: 777620:e6657954a506
user:      rmind <rmind%NetBSD.org@localhost>
date:      Sat Feb 25 22:28:06 2012 +0000

description:
uvm_km_kmem_alloc: return ENOMEM on failure in PMAP_MAP_POOLPAGE case.

diffstat:

 sys/uvm/uvm_km.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (40 lines):

diff -r ffa64ce61f38 -r e6657954a506 sys/uvm/uvm_km.c
--- a/sys/uvm/uvm_km.c  Sat Feb 25 21:21:09 2012 +0000
+++ b/sys/uvm/uvm_km.c  Sat Feb 25 22:28:06 2012 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: uvm_km.c,v 1.122 2012/02/20 19:14:23 bouyer Exp $      */
+/*     $NetBSD: uvm_km.c,v 1.123 2012/02/25 22:28:06 rmind Exp $       */
 
 /*
  * Copyright (c) 1997 Charles D. Cranor and Washington University.
@@ -120,7 +120,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: uvm_km.c,v 1.122 2012/02/20 19:14:23 bouyer Exp $");
+__KERNEL_RCSID(0, "$NetBSD: uvm_km.c,v 1.123 2012/02/25 22:28:06 rmind Exp $");
 
 #include "opt_uvmhist.h"
 
@@ -729,6 +729,7 @@
                                uvm_wait("plpg");
                                goto again;
                        }
+                       return ENOMEM;
                }
                va = PMAP_MAP_POOLPAGE(VM_PAGE_TO_PHYS(pg));
                if (__predict_false(va == 0)) {
@@ -766,7 +767,7 @@
                                return ENOMEM;
                        }
                }
-       
+
                pg->flags &= ~PG_BUSY;  /* new page */
                UVM_PAGE_OWN(pg, NULL);
                pmap_kenter_pa(loopva, VM_PAGE_TO_PHYS(pg),
@@ -813,4 +814,3 @@
 
        return (free < (total / 10));
 }
-



Home | Main Index | Thread Index | Old Index