Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/uvm amap_cow_now: just free the fresh anon on error, no ...
details: https://anonhg.NetBSD.org/src/rev/afe5787102d9
branches: trunk
changeset: 768507:afe5787102d9
user: rmind <rmind%NetBSD.org@localhost>
date: Wed Aug 17 20:46:27 2011 +0000
description:
amap_cow_now: just free the fresh anon on error, no need to dispose it.
diffstat:
sys/uvm/uvm_amap.c | 14 ++++----------
1 files changed, 4 insertions(+), 10 deletions(-)
diffs (38 lines):
diff -r 46953b4b0eec -r afe5787102d9 sys/uvm/uvm_amap.c
--- a/sys/uvm/uvm_amap.c Wed Aug 17 19:28:36 2011 +0000
+++ b/sys/uvm/uvm_amap.c Wed Aug 17 20:46:27 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: uvm_amap.c,v 1.102 2011/08/06 17:25:03 rmind Exp $ */
+/* $NetBSD: uvm_amap.c,v 1.103 2011/08/17 20:46:27 rmind Exp $ */
/*
* Copyright (c) 1997 Charles D. Cranor and Washington University.
@@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: uvm_amap.c,v 1.102 2011/08/06 17:25:03 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: uvm_amap.c,v 1.103 2011/08/17 20:46:27 rmind Exp $");
#include "opt_uvmhist.h"
@@ -1039,17 +1039,11 @@
npg = NULL;
}
if (nanon == NULL || npg == NULL) {
-
- /*
- * XXXCDC: we should cause fork to fail, but we can't.
- */
-
+ amap_unlock(amap);
if (nanon) {
nanon->an_ref--;
KASSERT(nanon->an_ref == 0);
- uvm_anon_freelst(amap, nanon);
- } else {
- amap_unlock(amap);
+ uvm_anon_free(nanon);
}
uvm_wait("cownowpage");
goto ReStart;
Home |
Main Index |
Thread Index |
Old Index