From nobody Sat Oct 05 07:11:34 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4XLGmk6Cg5z5XrVW; Sat, 05 Oct 2024 07:11:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XLGmk2Wyzz4NL1; Sat, 5 Oct 2024 07:11:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1728112294; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=i18UpfiN+NBaCD0m2v0f+T1cHlCcQVdKsT7As8DT4Vc=; b=d5HgT/M18m42tXCZXEEDBsK9ZySUtD/GRloey/mYYg+aMsiVaYVv3dYyWW31UK+Cn++y3j 5i4Bii4epO85jCAsaDsxhncd3acnsT2GznwcA4yOlP83R4j4BWBamGgVBmwGnzy83KDxjV T+rp5Jdr9aRD4o0BZrn2YDZrEK0qlDDlqZdKvsNqPEzlWiCeRYDdra0q1beUgIUW10F1Cs rk48cCPgmHYVALqgxFdm83ybfroAVlcSb3PoGOMn8aHOJQrTsbU/N4IkmLQ6EyTSblC93h 3AyN0F7CAU1HG/w7IcSVXDBlnJgTa0FERSWLf5ysJEQRTgM3zGIqQPfFu3PBDg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1728112294; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=i18UpfiN+NBaCD0m2v0f+T1cHlCcQVdKsT7As8DT4Vc=; b=iaQh3uHeqs5TWdYsa0xAPV8mDpDIOOQIWPjcsgveRUs5mOnDTPNVt9yXLDkpGS3yt56dq6 Wd25zeKB4F6XjBuCCTU1+vis+ovQ9KtAsf6TgFKEb3cOjO+u8A1dnN2FZYo0aGWpiuSPML 4D17EPJYJKtGKvoJgSjxHV4H0biyW50/Hppb45VC5n+4/ouA7ZlrDRS5UTSkumIJf7MVLQ yZcEmrL9VXciDSuhCKm6w9Gh6oB2/nhNivpCkahzz7UkP9wkH2vpxRb+SPdonMHDZ7v+gK Sg9B0EV9qarFSXtcnkcN+gSspWdiQlD+G723jekWTHT6gvDDrSS1Rfu7tKbXKg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1728112294; a=rsa-sha256; cv=none; b=LnKod52/8HyulSVkQmwdcxC/bxf1fx2HWvyw8eGjo6P9uFzWQpZfFRlR4nijKLqy7QvrM1 7aCQrxbvopvtEG/jnFMYPeCVau4FK6dgqQ7U8zB74dEiwjU9s1yZWjHu+Hw3oYuRIex3XV UbsUTM49quoMfN63hJY0FZriZrZuYEk7JcVd0owVkp3X01fujqgOa+d03tqMaKv5Uw3yjw EDoRGrP9aRTXe01GQJenJA9PoChOTxoal86LZTID8jb1dyTLoHLwFbFaC4R3UsZ7vug/kr naN9/EdA+W9yLAHR8jpkSCnwsbMHL7CgJwUfKBLzGqiX+7/7NrUt/UalBlQcuQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4XLGmk28HSz183q; Sat, 5 Oct 2024 07:11:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 4957BYFG001853; Sat, 5 Oct 2024 07:11:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4957BYT1001849; Sat, 5 Oct 2024 07:11:34 GMT (envelope-from git) Date: Sat, 5 Oct 2024 07:11:34 GMT Message-Id: <202410050711.4957BYT1001849@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: b0e45fea61a5 - stable/14 - vm_page_free_pages_toq(): return the count of freed pages List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b0e45fea61a53bf7831e9a8de356cfda055e1d44 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=b0e45fea61a53bf7831e9a8de356cfda055e1d44 commit b0e45fea61a53bf7831e9a8de356cfda055e1d44 Author: Konstantin Belousov AuthorDate: 2024-09-27 16:20:31 +0000 Commit: Konstantin Belousov CommitDate: 2024-10-05 07:08:56 +0000 vm_page_free_pages_toq(): return the count of freed pages (cherry picked from commit 1784fb44498da8007fb8cd8ee5060894eb5fe1e6) --- sys/vm/vm_page.c | 5 +++-- sys/vm/vm_page.h | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/sys/vm/vm_page.c b/sys/vm/vm_page.c index 8496a39154de..fe104e1e87af 100644 --- a/sys/vm/vm_page.c +++ b/sys/vm/vm_page.c @@ -3993,14 +3993,14 @@ vm_page_free_toq(vm_page_t m) * from any VM object. In other words, this is equivalent to * calling vm_page_free_toq() for each page of a list of VM objects. */ -void +int vm_page_free_pages_toq(struct spglist *free, bool update_wire_count) { vm_page_t m; int count; if (SLIST_EMPTY(free)) - return; + return (0); count = 0; while ((m = SLIST_FIRST(free)) != NULL) { @@ -4011,6 +4011,7 @@ vm_page_free_pages_toq(struct spglist *free, bool update_wire_count) if (update_wire_count) vm_wire_sub(count); + return (count); } /* diff --git a/sys/vm/vm_page.h b/sys/vm/vm_page.h index a1df6f736aee..68f68d62d2be 100644 --- a/sys/vm/vm_page.h +++ b/sys/vm/vm_page.h @@ -706,7 +706,7 @@ int vm_page_is_valid(vm_page_t, int, int); void vm_page_test_dirty(vm_page_t); vm_page_bits_t vm_page_bits(int base, int size); void vm_page_zero_invalid(vm_page_t m, boolean_t setvalid); -void vm_page_free_pages_toq(struct spglist *free, bool update_wire_count); +int vm_page_free_pages_toq(struct spglist *free, bool update_wire_count); void vm_page_dirty_KBI(vm_page_t m); void vm_page_lock_KBI(vm_page_t m, const char *file, int line);