Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 14 Aug 2019 09:44:48 +0000 (UTC)
From:      Konstantin Belousov <kib@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org
Subject:   svn commit: r351020 - stable/12/sys/vm
Message-ID:  <201908140944.x7E9im0T076140@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kib
Date: Wed Aug 14 09:44:48 2019
New Revision: 351020
URL: https://svnweb.freebsd.org/changeset/base/351020

Log:
  MFC r350758:
  Fix stack grow for init.

Modified:
  stable/12/sys/vm/vm_map.c
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/sys/vm/vm_map.c
==============================================================================
--- stable/12/sys/vm/vm_map.c	Wed Aug 14 09:44:04 2019	(r351019)
+++ stable/12/sys/vm/vm_map.c	Wed Aug 14 09:44:48 2019	(r351020)
@@ -4146,7 +4146,8 @@ vm_map_growstack(vm_map_t map, vm_offset_t addr, vm_ma
 	 * debugger or AIO daemon.  The reason is that the wrong
 	 * resource limits are applied.
 	 */
-	if (map != &p->p_vmspace->vm_map || p->p_textvp == NULL)
+	if (p != initproc && (map != &p->p_vmspace->vm_map ||
+	    p->p_textvp == NULL))
 		return (KERN_FAILURE);
 
 	MPASS(!map->system_map);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201908140944.x7E9im0T076140>