Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Nov 2021 13:46:21 GMT
From:      Mark Johnston <markj@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 0d900a16d0df - stable/13 - vm_pager: Optimize an assertion
Message-ID:  <202111221346.1AMDkLbQ037508@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by markj:

URL: https://cgit.FreeBSD.org/src/commit/?id=0d900a16d0df1334be01f2dd6313cd5103ede8d2

commit 0d900a16d0df1334be01f2dd6313cd5103ede8d2
Author:     Mark Johnston <markj@FreeBSD.org>
AuthorDate: 2021-11-15 16:33:30 +0000
Commit:     Mark Johnston <markj@FreeBSD.org>
CommitDate: 2021-11-22 13:44:08 +0000

    vm_pager: Optimize an assertion
    
    Obtained from:  jeff (object_concurrency patches)
    Reviewed by:    kib
    
    (cherry picked from commit b0acc3f11ba31f0aea8ca5ce2720b481dfa79d1b)
---
 sys/vm/vm_pager.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/sys/vm/vm_pager.c b/sys/vm/vm_pager.c
index 640e3d977e99..791fc1ebfe11 100644
--- a/sys/vm/vm_pager.c
+++ b/sys/vm/vm_pager.c
@@ -329,12 +329,11 @@ vm_pager_get_pages(vm_object_t object, vm_page_t *m, int count, int *rbehind,
 		 * updated the array.
 		 */
 #ifdef INVARIANTS
-		VM_OBJECT_RLOCK(object);
-		KASSERT(m[i] == vm_page_lookup(object, pindex++),
+		KASSERT(m[i] == vm_page_relookup(object, pindex++),
 		    ("%s: mismatch page %p pindex %ju", __func__,
 		    m[i], (uintmax_t )pindex - 1));
-		VM_OBJECT_RUNLOCK(object);
 #endif
+
 		/*
 		 * Zero out partially filled data.
 		 */



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