From nobody Fri Oct 21 06:14:06 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 4MtvLQ55mBz4gkdb; Fri, 21 Oct 2022 06:14:06 +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 4MtvLQ4Td2z3wnB; Fri, 21 Oct 2022 06:14:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1666332846; 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=ATD0RhjYFJaUI9IBOH1HNzl7ajYUjZn5hyGf0CadCc4=; b=dcRYZriVhBRkV/Js2iiHbYuNsHY8bHVIBKZR2KC6TXejIEaQBu9FFWLzsVGeIRiaEhy3LB nyS1t6D5FLg0l3CKOPxfW1u5Oe/WRRLVX0cT3huONn/ynHRd++9/E+X3jjvqzHAR+rv4vH bZj1ZWM7RBeMUcr4EYRx4DPVOngqsN9oFEEWgTUbikTkEMpw2I81r7GDIvjEtYhSyq0r0y /B6E4BndpqmpSD1g4xJ7Tj0SP/R9o7d3+QqNlrjDvxy59lLEsFYFJQlKWWCNYVoKmi+xkC qvH48FPv51x6YAUQYSIQ/EWrUsCNOWUPQ+oQTLfqfeR2TVORXETUaELPgsMGNQ== 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 4MtvLQ3XDkz170W; Fri, 21 Oct 2022 06:14:06 +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 29L6E6PR022424; Fri, 21 Oct 2022 06:14:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 29L6E6a9022423; Fri, 21 Oct 2022 06:14:06 GMT (envelope-from git) Date: Fri, 21 Oct 2022 06:14:06 GMT Message-Id: <202210210614.29L6E6a9022423@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ka Ho Ng Subject: git: f187bd281e52 - stable/13 - refcount.9: Update refcount_acquire(9) description after a67d540832b8 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: khng X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f187bd281e52a71e0fe0a6bf963d93ff950fcf7a Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1666332846; 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=ATD0RhjYFJaUI9IBOH1HNzl7ajYUjZn5hyGf0CadCc4=; b=xnrJzEdfcuFUt5JlyqFsVv9+D1F8qgshlJHGxZnTQV1jIebG6wmvcPfAcFpQlw83SbW6Kq QjGl14PLtgsLXS5IneRx827aX/NOzKykSEK74oDDkR0RWSiEOl5kJvnkuLl1rxL00xoW5N OvFcYmn8gGVSZXw3x2jur6tgq9fx7Rp9QcXOlAls3aHf14CccZpsOQEYJI0syNVLx1ta+J RcA1nBTDLk+Vrkxeso88OpHqAvNfar6AiPXVXSFsSd+0JPyZUM5n8Ip+4l0Md7mjpSpVhO nURHQ8go2Wv6RptWYX+Q9WvSYl8KZUXKY7Dd6lN4CFLauiC2mK8o6GoFnG7UiQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1666332846; a=rsa-sha256; cv=none; b=sOynxUhGpxLYAdNHhLNZaKzfEuzTtJYhCsaSw5XchT9iQUALg6SONHXephEd5DZy+ADOLn fYxWWiLg5nCgJOfNCE4fJ49sm/Oy0JLU92Zhy4EPWZJegU0uGPPLw1CCqqFVnGm9Lsvu02 4AIXLy7IFSTSCHJaYJu9epS0x9ROZQl/FwgbgOWJPfEixZ8r0cSMw12JL2i/o0QS2eq1SU BTHwn343RYD50FNcafJLMwvHYgUuWb+LqJ2A55xd3j6K+aTd4gFaTjJCexrxpjZlzNXHt0 wYax4dTr4oiU9sU+VHAeYmWfogKno9SZmaYRCIfCB32xlwndVPwUlhiAOu8SFw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by khng: URL: https://cgit.FreeBSD.org/src/commit/?id=f187bd281e52a71e0fe0a6bf963d93ff950fcf7a commit f187bd281e52a71e0fe0a6bf963d93ff950fcf7a Author: Ka Ho Ng AuthorDate: 2022-10-12 17:47:59 +0000 Commit: Ka Ho Ng CommitDate: 2022-10-21 06:13:25 +0000 refcount.9: Update refcount_acquire(9) description after a67d540832b8 MFC after: 3 days Sponsored by: Juniper Networks, Inc. Reviewed by: kib, markj Differential Revision: https://reviews.freebsd.org/D36943 (cherry picked from commit 87fa64c569c54c2ec444ada699acde2ada696d97) --- share/man/man9/refcount.9 | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/share/man/man9/refcount.9 b/share/man/man9/refcount.9 index 9171062a70b6..0b5a26d6e3cd 100644 --- a/share/man/man9/refcount.9 +++ b/share/man/man9/refcount.9 @@ -32,7 +32,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 2, 2020 +.Dd October 12, 2022 .Dt REFCOUNT 9 .Os .Sh NAME @@ -48,7 +48,7 @@ .Fn refcount_init "volatile u_int *count" "u_int value" .Ft u_int .Fn refcount_load "volatile u_int *count" -.Ft void +.Ft u_int .Fn refcount_acquire "volatile u_int *count" .Ft bool .Fn refcount_acquire_checked "volatile u_int *count" @@ -91,6 +91,7 @@ qualifier. The .Fn refcount_acquire function is used to acquire a new reference. +It returns the counter value before the new reference was acquired. The caller is responsible for ensuring that it holds a valid reference while obtaining a new reference. For example,