Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 15 Jul 2012 21:46:20 +0000 (UTC)
From:      Alan Cox <alc@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r238510 - head/sys/vm
Message-ID:  <201207152146.q6FLkKZB076246@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: alc
Date: Sun Jul 15 21:46:19 2012
New Revision: 238510
URL: http://svn.freebsd.org/changeset/base/238510

Log:
  Correct an off-by-one error in vm_reserv_alloc_contig() that resulted in
  the last reservation of a multi-reservation allocation not being
  initialized.

Modified:
  head/sys/vm/vm_reserv.c

Modified: head/sys/vm/vm_reserv.c
==============================================================================
--- head/sys/vm/vm_reserv.c	Sun Jul 15 21:20:31 2012	(r238509)
+++ head/sys/vm/vm_reserv.c	Sun Jul 15 21:46:19 2012	(r238510)
@@ -457,7 +457,7 @@ vm_reserv_alloc_contig(vm_object_t objec
 		m += VM_LEVEL_0_NPAGES;
 		first += VM_LEVEL_0_NPAGES;
 		allocpages -= VM_LEVEL_0_NPAGES;
-	} while (allocpages > VM_LEVEL_0_NPAGES);
+	} while (allocpages > 0);
 	return (m_ret);
 
 	/*



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