From owner-svn-src-head@freebsd.org Fri Feb 23 23:27:54 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 31FB2F29F0A; Fri, 23 Feb 2018 23:27:54 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D82417F30A; Fri, 23 Feb 2018 23:27:53 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id B49E61D2B1; Fri, 23 Feb 2018 23:27:53 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w1NNRrj4041209; Fri, 23 Feb 2018 23:27:53 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w1NNRr0L041208; Fri, 23 Feb 2018 23:27:53 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201802232327.w1NNRr0L041208@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Fri, 23 Feb 2018 23:27:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r329886 - head/sys/vm X-SVN-Group: head X-SVN-Commit-Author: markj X-SVN-Commit-Paths: head/sys/vm X-SVN-Commit-Revision: 329886 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Feb 2018 23:27:54 -0000 Author: markj Date: Fri Feb 23 23:27:53 2018 New Revision: 329886 URL: https://svnweb.freebsd.org/changeset/base/329886 Log: Correct some comments after r328954. Reviewed by: kib Differential Revision: https://reviews.freebsd.org/D14486 Modified: head/sys/vm/vm_reserv.c Modified: head/sys/vm/vm_reserv.c ============================================================================== --- head/sys/vm/vm_reserv.c Fri Feb 23 23:25:22 2018 (r329885) +++ head/sys/vm/vm_reserv.c Fri Feb 23 23:27:53 2018 (r329886) @@ -511,19 +511,14 @@ vm_reserv_populate(vm_reserv_t rv, int index) } /* - * Allocates a contiguous set of physical pages of the given size "npages" - * from existing or newly created reservations. All of the physical pages - * must be at or above the given physical address "low" and below the given - * physical address "high". The given value "alignment" determines the - * alignment of the first physical page in the set. If the given value - * "boundary" is non-zero, then the set of physical pages cannot cross any - * physical address boundary that is a multiple of that value. Both - * "alignment" and "boundary" must be a power of two. + * Attempts to allocate a contiguous set of physical pages from existing + * reservations. See vm_reserv_alloc_contig() for a description of the + * function's parameters. * * The page "mpred" must immediately precede the offset "pindex" within the * specified object. * - * The object and free page queue must be locked. + * The object must be locked. */ vm_page_t vm_reserv_extend_contig(int req, vm_object_t object, vm_pindex_t pindex, @@ -606,7 +601,7 @@ out: /* * Allocates a contiguous set of physical pages of the given size "npages" - * from existing or newly created reservations. All of the physical pages + * from newly created reservations. All of the physical pages * must be at or above the given physical address "low" and below the given * physical address "high". The given value "alignment" determines the * alignment of the first physical page in the set. If the given value @@ -614,6 +609,9 @@ out: * physical address boundary that is a multiple of that value. Both * "alignment" and "boundary" must be a power of two. * + * Callers should first invoke vm_reserv_extend_contig() to attempt an + * allocation from existing reservations. + * * The page "mpred" must immediately precede the offset "pindex" within the * specified object. * @@ -836,7 +834,9 @@ vm_reserv_extend(int req, vm_object_t object, vm_pinde } /* - * Allocates a page from an existing reservation. + * Attempts to allocate a new reservation for the object, and allocates a + * page from that reservation. Callers should first invoke vm_reserv_extend() + * to attempt an allocation from an existing reservation. * * The page "mpred" must immediately precede the offset "pindex" within the * specified object.