From nobody Mon Apr 08 13:14:33 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 4VCqLd24qzz5H1ZG; Mon, 8 Apr 2024 13:14:33 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VCqLd1F9pz4qGK; Mon, 8 Apr 2024 13:14:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1712582073; 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=Omw667sdFZZ8zidnD/BlGrnOkTg+xMGvq393TjXCyZc=; b=hbJ8rkhUo50rhC4P9EVjJ9w68ebpcoln7lxDKzZgtFwzDqwo/JsRysCprjwkAKOoSqmcny UJHFLS/8q36EogDGnVaVUHO7wuKTRLGJ3fmKSFvkfDWvzeAJPrAekukfQyV8jbwNTXwUB6 b+bVZxYw+TY9BVLp1it3wrbyNdkIpTy5aYaAB4rh5SFFgAxQePSsurJxmKK5r0VV+hvpgA JzegC2TX4VpZxHdN7dkR1ixzjvwd9a2rErMDShdFCywM0PBZIjGf9mfnfBHmpflWjbKJqc RX2E0cr89sJzGhZ/DAkbPdEGvZivpFi18noiRqgJu7xP2lrQYPvIL4klJaNZWw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1712582073; a=rsa-sha256; cv=none; b=BJjPKkdJ7Cv5bWQ0CcOUdQKxpG3sDO7qnwa+sorXB94TGwXIRqDqNMlIdK6M8VwfuCsFL+ YGiLW5OBaJBoYNjCLkRIxTCkjZF/g/0NOv4XI1XNTt9DnoN6l5puF66cy685/NLAy/7BpL KnUzyJUe4P6IuzhXLQK9ljLk0xodyC2/yTfO1K1/mlRkSND5UORl1DwNbsGNNo2OnkTj25 6JH7w3civ2SCNbRUhFuDzyq3fpQu7kT0AmEEqr92Gwi0F4UgLW15bDYysT3yIVYwOBuqTY +rCBQR9CTB/evpBthH3vrftcjbbOY9rPKs8h7WRuDA/iwWS4RSEHp2t+KpsfRQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1712582073; 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=Omw667sdFZZ8zidnD/BlGrnOkTg+xMGvq393TjXCyZc=; b=hHmxXfkM3DN6KVfwOlZkDSGa9uN3CXh+7x6C/JAXdrlsILQAhQ9Y2h7cTEN//X74FDzd7a ZflCuXAiKm9J/nnUp+JI/GExHOuZ4Bul4bi62myygCsoM1+J4KKd2lo0tCIffvLjeS9Qsg wKB2Fjr1nEnLIOwvI0Sj70aTTQvx4YbOStqcs0cvGW1aOOH7wgQWey5c2Cd4slcQvsCQG8 UKuIdpYFsSCbKJtip1CFsUctsnu7PT1gSg4eRUAZENPnKqErx0tABanUJYpsVPPhXDTG5F NU5L7w4+/pIezAeoCCIrhommvEYIy0UK+vgeEYNV31gbqwonZKAGwROwGwHj/Q== 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 4VCqLd0rqTz1BZ7; Mon, 8 Apr 2024 13:14:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 438DEXqZ000948; Mon, 8 Apr 2024 13:14:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 438DEXCq000945; Mon, 8 Apr 2024 13:14:33 GMT (envelope-from git) Date: Mon, 8 Apr 2024 13:14:33 GMT Message-Id: <202404081314.438DEXCq000945@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: 4696650782e2 - main - swap_pager: Unbusy readahead pages after an I/O error 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: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4696650782e2e5cf7ae5823f1de04550c05b5b75 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=4696650782e2e5cf7ae5823f1de04550c05b5b75 commit 4696650782e2e5cf7ae5823f1de04550c05b5b75 Author: Mark Johnston AuthorDate: 2024-04-08 13:02:48 +0000 Commit: Mark Johnston CommitDate: 2024-04-08 13:02:48 +0000 swap_pager: Unbusy readahead pages after an I/O error The swap pager itself allocates readahead pages, so should take care to unbusy them after a read error, just as it does in the non-error case. PR: 277538 Reviewed by: olce, dougm, alc, kib MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D44646 --- sys/vm/swap_pager.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/vm/swap_pager.c b/sys/vm/swap_pager.c index f6cfd45c3805..ee236c7f3988 100644 --- a/sys/vm/swap_pager.c +++ b/sys/vm/swap_pager.c @@ -1683,6 +1683,9 @@ swp_pager_async_iodone(struct buf *bp) * getpages so don't play cute tricks here. */ vm_page_invalid(m); + if (i < bp->b_pgbefore || + i >= bp->b_npages - bp->b_pgafter) + vm_page_free_invalid(m); } else { /* * If a write error occurs, reactivate page