From nobody Mon Feb 07 09:50:51 2022 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 AA33A19C10F0; Mon, 7 Feb 2022 09:50:52 +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 4JshGg4z4Vz3sF0; Mon, 7 Feb 2022 09:50:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1644227452; 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=vvkbDV+85wKhYjCdWHI5T5JzGoaYOpe7p2dgo3ffjZ8=; b=AHfSdAps+Zi7ts1Vtvjdb+PeTN4l5QXSw20xiMU3Dd8l7oLri2NkIKdux1XEJAaTxp3quD oVeUGWz4XnGvoovSMzlxcrfgH4cIPz5Biz/cj+R+tJA3xodxC+//d0S5OCbcTwqjy2B97a JUYNRetpkptZ2JkwRXuSPm6nv9NMZqIKDapBeIY0aRgt1Ic4g1bZnpkvst+tpVMsBQRvDh wBzKYW6Bz8DarXX9peEV7EZbWKO15rPF7Twx0l6XfW08o35OqpimKZc5cQw+0p4sF1KztB l0vEnV/vo50niztS/+BnCqd31d9lEHSWKs8CVUSAybUxkwtmxhceOgiwP8CU8A== 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 3BA9323988; Mon, 7 Feb 2022 09:50:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 2179opP2058984; Mon, 7 Feb 2022 09:50:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2179opHG058983; Mon, 7 Feb 2022 09:50:51 GMT (envelope-from git) Date: Mon, 7 Feb 2022 09:50:51 GMT Message-Id: <202202070950.2179opHG058983@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: 4116ae3ece6e - stable/13 - buf_alloc(): lock the buffer with LK_NOWAIT 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4116ae3ece6ecf565e89d377f9f98c5dda2b53dd Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1644227452; 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=vvkbDV+85wKhYjCdWHI5T5JzGoaYOpe7p2dgo3ffjZ8=; b=tCMoVv/rPcZfS714K85fGunp9Y1w8VAC5I+PDdlsjQXRKy3dNwDfaRBfgiv/Gow7iOmf00 sMAMaSxOdVzCE63qSfDrqbu+ykVihUF7fS1c/PUGKQrbQo2sC4Ui7WkiAP2teGwCv4DRH+ QvexAA5BnR0E0u+P6fa6txkh5Qt+HbedT8IIVGZKb/SCW/yHZkUMFlVDZLPDwzEmXtCnJk Fz8/9wOXxg/udqWBpUVHYaAvd2ZfNeZeLCPgKCpwK1OAW/nrsQQ/90ppjTRWm1MHPNmuIJ Je09yY2rHHYlik+lEyDgmMGqHzyHwP6xHAmRbphPkIPsdr8HIXvQ/V/R5wGjMA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1644227452; a=rsa-sha256; cv=none; b=BDq/4Hjuonx8bCYSRU2Ief9apJdb2Hcte5/QJmZx0J41Fl4ksvyeJlbHP4WeCvv1cg3OgL MSvooCn+cCEdYfca2azd02p1dTaNsBSwZs4/4k2CJpyANs16ambGaLSSVlsZFxkI9CuXtk UJLh+3iRtJRL0KyNMOlmQP4SmO6gNDU9dqY1AjUJ5ECm97tJ7LJsGwCtuxR4r37gNfhB4s 19elQoUfeod0Zpjz7E5mIbNKm7Ty0OE/eJoveAXLP4XBk4MJhDccCKwBb2Kz6OF/dblIHO Wl1WTIE9dEYJO8Ex9wVOkqQ89M/Icicee885d871N4R34/9LlL2XqfjPAZu7xw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=4116ae3ece6ecf565e89d377f9f98c5dda2b53dd commit 4116ae3ece6ecf565e89d377f9f98c5dda2b53dd Author: Konstantin Belousov AuthorDate: 2022-01-18 01:39:05 +0000 Commit: Konstantin Belousov CommitDate: 2022-02-07 09:38:49 +0000 buf_alloc(): lock the buffer with LK_NOWAIT (cherry picked from commit 5875b94c74935affb47c7e059011f80ee2f6bf67) --- sys/kern/vfs_bio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/kern/vfs_bio.c b/sys/kern/vfs_bio.c index aaf7b69d47db..4491033d44eb 100644 --- a/sys/kern/vfs_bio.c +++ b/sys/kern/vfs_bio.c @@ -1709,7 +1709,7 @@ buf_alloc(struct bufdomain *bd) if (freebufs == bd->bd_lofreebuffers) bufspace_daemon_wakeup(bd); - error = BUF_LOCK(bp, LK_EXCLUSIVE, NULL); + error = BUF_LOCK(bp, LK_EXCLUSIVE | LK_NOWAIT, NULL); KASSERT(error == 0, ("%s: BUF_LOCK on free buf %p: %d.", __func__, bp, error)); (void)error;