Module Name:    src
Committed By:   martin
Date:           Mon Mar 19 10:31:56 UTC 2018

Modified Files:
        src/sys/arch/alpha/alpha: vm_machdep.c

Log Message:
Nowadays we can create new kernel threads late after boot, so if we are
unable to find physically continous pages for their uarea, just allocate
them via uvm_km_alloc(), that is: make cpu_uarea_alloc() fail instead
of panic. cpu_uarea_free() already deals with this.

Should fix PR port-alpha/53077.

Discussed with maxv and mrg.


To generate a diff of this commit:
cvs rdiff -u -r1.113 -r1.114 src/sys/arch/alpha/alpha/vm_machdep.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/alpha/alpha/vm_machdep.c
diff -u src/sys/arch/alpha/alpha/vm_machdep.c:1.113 src/sys/arch/alpha/alpha/vm_machdep.c:1.114
--- src/sys/arch/alpha/alpha/vm_machdep.c:1.113	Fri May 16 19:18:21 2014
+++ src/sys/arch/alpha/alpha/vm_machdep.c	Mon Mar 19 10:31:56 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.113 2014/05/16 19:18:21 matt Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.114 2018/03/19 10:31:56 martin Exp $ */
 
 /*
  * Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
@@ -29,7 +29,7 @@
 
 #include <sys/cdefs.h>			/* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.113 2014/05/16 19:18:21 matt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.114 2018/03/19 10:31:56 martin Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -227,11 +227,8 @@ cpu_uarea_alloc(bool system)
 	 * direct-mapped.
 	 */
 	error = uvm_pglistalloc(USPACE, 0, ptoa(physmem), 0, 0, &pglist, 1, 1);
-	if (error) {
-		if (!system)
-			return NULL;
-		panic("%s: uvm_pglistalloc failed: %d", __func__, error);
-	}
+	if (error)
+		return NULL;
 
 	/*
 	 * Get the physical address from the first page.

Reply via email to