From nobody Mon Sep 26 18:16:01 2022 X-Original-To: dev-commits-src-branches@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 4MbrXx2r7mz4cPfH; Mon, 26 Sep 2022 18:16:01 +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 4MbrXx22gmz3QlK; Mon, 26 Sep 2022 18:16:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1664216161; 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=rou4Pzy7hFJPyMMBj+Pj9pdHgU1F89rxJg3457xTBOY=; b=WCsa4c7ZtFwkYY5MYBepQyq+EOvHuQ+BtMgcgxb+L7yl43sH0K/F6d8QrkrqI1WmTwdFaY Bef1iMTIcVdYxkc0EJWN5Q54U5jr+k29row4OvjJ7Rrmg54sePKrahcN7DonyzBUTRuJCq onkrwAVuw725GGUm2/5QScuG6AludloNsbzH/xdxh0FtHn5VqRZQSOE9ac79sCzQSwuiGB dmq8csZk7rzIVCfAEYeoBYznPN70vgyAnig/H/PaWYhCXMQLj2PbQZabRpWfFfNwLur0mP KQAYP76RmvFFAQv1QdhF/N0pkXJLOwSC1MB5mXuEqQzjfYO6tsLaPnA8Kp4g9Q== 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 4MbrXx15yZzrXH; Mon, 26 Sep 2022 18:16:01 +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 28QIG1Pm050179; Mon, 26 Sep 2022 18:16:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 28QIG1BO050178; Mon, 26 Sep 2022 18:16:01 GMT (envelope-from git) Date: Mon, 26 Sep 2022 18:16:01 GMT Message-Id: <202209261816.28QIG1BO050178@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Brooks Davis Subject: git: 327705fbba74 - stable/12 - cpuset(9): Refer to CPU_SETSIZE not MAXCPU List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: brooks X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: 327705fbba740a28101aa2f5bd6a035046a5a7c5 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1664216161; 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=rou4Pzy7hFJPyMMBj+Pj9pdHgU1F89rxJg3457xTBOY=; b=aVbLra4vh+z6jsE/rqyUdEB91VcxG39M27ypwqTTvrOFLL2W/YyssdeJIyjlFfqo1h0Rus jxCyfNrCtUQ6za7s+PCFjzeiHLNWStVAuBqIWUbJmJcDoMnHhmGlGkQYtimFzGzSquh/4s OKDpFZEV8SNzXUZDk5ibVOhsKnCxUPtSd63RVCFl6FQwnGJ5/jAGnqR8U3xl4WB8VFShoa fwp7b2E+ta8Wi0DnQFwhWgO/9kqzWBWlqjXuTsZovDaiJb0EYKUUwf0sp1ywZPiQQ0kwVl /YaP0DzNcjQrdh1XqM1vEouAIoF/dqUcQsu+M/ChOA9wfEaZ7NbyPQ0LBGkLVg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1664216161; a=rsa-sha256; cv=none; b=KMctOvU1b6HqxSUkBWx1OPUB15qhhw+pLyxsu4OrB2IWjnhl/BXj3krI4HQxJUbGUbJ7u/ GJdIiYKmlBueI58yZhD1TDAppEnsJ7G8TgBiAa0s8O2HDPvDzPIg5mMKiE/NPALtq9H8xg XjA+29ztWWCkySbWWNQW66YdbihgibKPPL9xTyYCbNJ+hMcIzubVXi/yQX1WsrNsTQqih0 xJnQIjpR1TlEMW4pJY4y47/eBh3wv3BxvjUSi6lVRusdniWA5CcOMnq/89wIEoVBCj0/Yj /zRdVXCga49iMajgpsQ+8BRUdUvCTStEzl6wR0b5rfCdgfeHFZ2KC4yKF3rang== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/12 has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=327705fbba740a28101aa2f5bd6a035046a5a7c5 commit 327705fbba740a28101aa2f5bd6a035046a5a7c5 Author: Brooks Davis AuthorDate: 2022-09-23 20:20:52 +0000 Commit: Brooks Davis CommitDate: 2022-09-26 18:15:29 +0000 cpuset(9): Refer to CPU_SETSIZE not MAXCPU The maximum CPU number of a cpuset_t is determined by CPU_SETSIZE. In the kernel this is MAXCPU, but in userspace it is CPU_MAXSIZE unless CPU_SETSIZE is defined before including sys/_cpuset.h. CPU_MAXSIZE is 256 and in userspace MAXCPU is generally 1 because it being set to a larger MD value is gated on SMP being defined (not generally the case in userspace). Reported by: Nathaniel Wesley Filardo Reviewed by: cem, jhb Differential Revision: https://reviews.freebsd.org/D36679 (cherry picked from commit 8232a1eddadd6e70ce7bee085344b182517d44a7) --- share/man/man9/cpuset.9 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/share/man/man9/cpuset.9 b/share/man/man9/cpuset.9 index 1d778ad940d3..e8522684e1ee 100644 --- a/share/man/man9/cpuset.9 +++ b/share/man/man9/cpuset.9 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 29, 2016 +.Dd September 23, 2022 .Dt CPUSET 9 .Os .Sh NAME @@ -108,9 +108,9 @@ Each CPU is represented by a single bit. The maximum number of CPUs representable by .Vt cpuset_t is -.Va MAXCPU . +.Va CPU_SETSIZE . Individual CPUs in cpusets are referenced with indices zero through -.Fa MAXCPU - 1 . +.Fa CPU_SETSIZE - 1 . .Pp The .Fn CPUSET_T_INITIALIZER