From nobody Mon Sep 15 00:14:22 2025 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 4cQ5Bl1vpVz67jBD; Mon, 15 Sep 2025 00:14:55 +0000 (UTC) (envelope-from dbaio@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQ5Bl0kYHz3bDC; Mon, 15 Sep 2025 00:14:55 +0000 (UTC) (envelope-from dbaio@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757895295; 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: in-reply-to:in-reply-to:references:references; bh=uC7YIZaIQoZh3b6e88J7RzaKpDeDLlK1rBXgayS8Aac=; b=HvrpTzAJVlTRlNTsE6SycwF8cLOIa8d3KQF0HkVhEWInv2yyjvN7ATCpp2lh+NNZDdIIq4 amh0backPEt71tyCBqXgOVucuBG0+QXXYvTL9KIzf/gK4VAP2y6vV0dvp54BRHqSfxw5Iv 3jH9orHr4BIISFGdeIjYGFhx8gu7wqKnv9xWmt/R8BKcVb6yhKpqVGmiTpSCANv31O5HmR l5vpF9UlVET3/fSiQB/Q4plPTP8thsMfpvf6gs6QbaUWocVTe9L0Tqpt3UuZ7fLH3Xk6oW lo7obU7rv9OlqoJfQ1soQIQuRFnqNW5xwuyfMOrmjdx3KTEgoSoLsdyF382WhA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757895295; 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: in-reply-to:in-reply-to:references:references; bh=uC7YIZaIQoZh3b6e88J7RzaKpDeDLlK1rBXgayS8Aac=; b=LPiOHA/416g81/3vNsDEG34gxomuxDayiG5FA+ljfhObJgTvjKE+kzj+PIKPE/nWZlp1t0 xLpT1yvGpg8PNTo7Aljd5APLHVOwvjLxy+APGwh0GYRl7a7j57gt9uV6EDk+d0wvvTAzdU xbU0NgnY5eRfQG2fVKj2Jbh8bXlsHZpxfsvkVdEAfeX/HpqvirB2oiC0S1a9xdOcAUb6ns +s98W2s8t3dAk4O9XvivYSbADYJtPJGUsh5Qqr26QyB1vA3J7ndYhePw1OCyocw39gQcZ3 IzDeTWXWaMZyiyOzZLCj3ZLDIH223xsPj1h742VvUF5FZTBp4QU5lQ0i72DXeA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757895295; a=rsa-sha256; cv=none; b=osxYJvplH/mS1ckoDMUzpxsDrtWUwvNdBARwDSo0697b+g5MW95Rxp/oCu2j9OSSUaPfJI 1QBWdpfSU9Y8s8JTRbXNsC0D7hXIjuGIkR6/fusC1D5cBDdVoz2zSRvm7KunlL6JHqfTd6 FDa/AFk4pXre/GRc/rMhLqirjlKIpAKyckowifdzlgwnDj+62n+XTafrEJ0jKHSus3/oBm PRzig/WGxXGErJJ0hGP8nHP9UEBSoxUC0B/yxdFc0ZA+TnglRxt6svrdUMPxJfaF2pKAgU cQFMQpLNWHKbCmSBJ79gBzXHU2g6y7NUtPi8Fcbwdrhb2T3aobaSNIg4QfF9Pg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from fauth-a2-smtp.messagingengine.com (fauth-a2-smtp.messagingengine.com [103.168.172.201]) (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) (Authenticated sender: dbaio/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cQ5Bk6z96zpcc; Mon, 15 Sep 2025 00:14:54 +0000 (UTC) (envelope-from dbaio@freebsd.org) Received: from phl-compute-02.internal (phl-compute-02.internal [10.202.2.42]) by mailfauth.phl.internal (Postfix) with ESMTP id A78F2F40068; Sun, 14 Sep 2025 20:14:54 -0400 (EDT) Received: from phl-imap-15 ([10.202.2.104]) by phl-compute-02.internal (MEProxy); Sun, 14 Sep 2025 20:14:54 -0400 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtdeggdefiedvvdcutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpuffrtefokffrpgfnqfghnecuuegr ihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjug hrpefoggffhffvkfgjfhfutgfgsehtjeertdertddtnecuhfhrohhmpedfffgrnhhilhho ucfirdcuuegrihhofdcuoegusggrihhosefhrhgvvgeuufffrdhorhhgqeenucggtffrrg htthgvrhhnpeehveefgeeihfekueeikeffvdehgedvuefhleeftdeggfdtvdeileffgfeg veehheenucffohhmrghinhepfhhrvggvsghsugdrohhrghenucevlhhushhtvghrufhiii gvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegusggrihhoodhmvghsmhhtphgruhht hhhpvghrshhonhgrlhhithihqdduudekudefleduvddtqddvieektddvjeeikedquggsrg hioheppehfrhgvvggsshgurdhorhhgsehfrghsthhmrghilhdrtghomhdpnhgspghrtghp thhtohepgedpmhhouggvpehsmhhtphhouhhtpdhrtghpthhtohepuggvvhdqtghomhhmih htshdqshhrtgdqrghllhesfhhrvggvsghsugdrohhrghdprhgtphhtthhopeguvghvqdgt ohhmmhhithhsqdhsrhgtqdhmrghinhesfhhrvggvsghsugdrohhrghdprhgtphhtthhope hkvghvrghnshesfhhrvggvsghsugdrohhrghdprhgtphhtthhopehsrhgtqdgtohhmmhhi thhtvghrshesfhhrvggvsghsugdrohhrgh X-ME-Proxy: Feedback-ID: i9d2946a4:Fastmail Received: by mailuser.phl.internal (Postfix, from userid 501) id 776FD78026F; Sun, 14 Sep 2025 20:14:54 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface 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 X-ThreadId: Am1ynKg1lObs Date: Sun, 14 Sep 2025 21:14:22 -0300 From: "Danilo G. Baio" To: "Kyle Evans" , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Message-Id: <54e7f090-c031-47f2-bc51-c020a77ab00a@app.fastmail.com> In-Reply-To: <202507260314.56Q3E5cY002869@gitrepo.freebsd.org> References: <202507260314.56Q3E5cY002869@gitrepo.freebsd.org> Subject: Re: git: dbaaadd4373a - main - jls: minor simplification to arg handling Content-Type: text/plain Content-Transfer-Encoding: 7bit On Sat, Jul 26, 2025, at 00:14, Kyle Evans wrote: > The branch main has been updated by kevans: > > URL: > https://cgit.FreeBSD.org/src/commit/?id=dbaaadd4373a725950ad11e578dab61537b7c4f2 > > commit dbaaadd4373a725950ad11e578dab61537b7c4f2 > Author: Kyle Evans > AuthorDate: 2025-07-26 03:13:41 +0000 > Commit: Kyle Evans > CommitDate: 2025-07-26 03:13:41 +0000 > > jls: minor simplification to arg handling > > It's easier to reason about the state of argc/argv if we just augment > them by optind after our getopt() loop. > > No functional change, but this sets the stage for another change to add > a `-c` mode to (c)heck for the existence of a jail quietly without > the caller having to worry about spurious output. > > Reviewed by: jamie > Differential Revision: https://reviews.freebsd.org/D51540 > --- > usr.sbin/jls/jls.c | 10 ++++++---- > 1 file changed, 6 insertions(+), 4 deletions(-) > > diff --git a/usr.sbin/jls/jls.c b/usr.sbin/jls/jls.c > index bd193a69c458..a1d1716713aa 100644 > --- a/usr.sbin/jls/jls.c > +++ b/usr.sbin/jls/jls.c > @@ -140,8 +140,11 @@ main(int argc, char **argv) > ip4_ok = feature_present("inet"); > #endif > > + argc -= optind; > + argv += optind; > + > /* Add the parameters to print. */ > - if (optind == argc) { > + if (argc == 0) { > if (pflags & (PRINT_HEADER | PRINT_NAMEVAL)) > add_param("all", NULL, (size_t)0, NULL, JP_USER); > else if (pflags & PRINT_VERBOSE) { > @@ -179,9 +182,8 @@ main(int argc, char **argv) > } > } else { > pflags &= ~PRINT_VERBOSE; > - while (optind < argc) > - add_param(argv[optind++], NULL, (size_t)0, NULL, > - JP_USER); > + for (i = 0; i < argc; i++) > + add_param(argv[i], NULL, (size_t)0, NULL, JP_USER); > } > > if (pflags & PRINT_SKIP) { Hi, Just replying to one of the recent changes on `jls`. We use `jls -n` in many scripts, and recently, it stopped working. The last build that was working for us: FreeBSD 15.0-CURRENT #0 main-n278879-4be9c6f38e78: Sat Jul 19 13:19:25 UTC 2025 We are now encountering the following issue on this build: FreeBSD 16.0-CURRENT #0 main-n280141-5e82eeccd252: Sat Sep 6 05:27:34 UTC 2025 $ jls -n desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable sysvsem=disable sysvshm=disable vnet=disable zfs=disable allow.noadjtime allow.nochflags allow.noextattr allow.nomlock allow.nomount allow.mount.nodevfs allow.mount.nofdescfs allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets allow.noread_msgbuf allow.noreserved_ports allow.norouting allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuser allow.nosysvipc allow.nounprivileged_parent_tampering allow.nounprivileged_proc_debug children.cur=0 children.max=0 cpuset.id=0 host.domainname="" host.hostid=0 host.hostname="" host.hostuuid="" ip4.addr=0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0 ip4.nosaddrsel ip6.addr=::,::,::,::,::,:: ip6.nosaddrsel zfs.mount_snapshot=0 desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable sysvsem=disable sysvshm=disable vnet=disable zfs=disable allow.noadjtime allow.nochflags allow.noextattr allow.nomlock allow.nomount allow.mount.nodevfs allow.mount.nofdescfs allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets allow.noread_msgbuf allow.noreserved_ports allow.norouting allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuser allow.nosysvipc allow.nounprivileged_parent_tampering allow.nounprivileged_proc_debug children.cur=0 children.max=0 cpuset.id=0 host.domainname="" host.hostid=0 host.hostname="" host.hostuuid="" ip4.addr=0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0 ip4.nosaddrsel ip6.addr=::,::,::,::,::,:: ip6.nosaddrsel zfs.mount_snapshot=0 desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable sysvsem=disable sysvshm=disable vnet=disable zfs=disable allow.noadjtime allow.nochflags allow.noextattr allow.nomlock allow.nomount allow.mount.nodevfs allow.mount.nofdescfs allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets allow.noread_msgbuf allow.noreserved_ports allow.norouting allow.noset_hostname allow.nosettime [...] infinite loop -- Danilo G. Baio From nobody Mon Sep 15 00:31:24 2025 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 4cQ5Ym2rv7z67kVF; Mon, 15 Sep 2025 00:31:24 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQ5Ym2LRVz3clf; Mon, 15 Sep 2025 00:31:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757896284; 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=NLi0BLfnbn1bGBDIJe/6RxHe3qDbn6IwBJnspWbpYZU=; b=xfzDZvBryayRoRI+1Cu0aJN+YNo9ZsVExRxuKwyWEQ84q2/1MJ2zZZSPHmDRjpoA596SDV /rW8L/0titg2AMXobRNk1+bTuwH0AHs/N+Ozsh5qrpJ3SxXp6b4VBku3azSbHghk0Fat/x prUnCHij8y013zWkTLTjIEoLwlTxbvkPShSiXVbf83Kv972Y+UzxO4ITqLLydNlRLaLr6u VBCTl++riZS/9xKRxxKFgZMztVgIXutrAYgSWPolxJwLNm579NzA+Io+xtH/MPBgCB8xcE ICpgvLq4pkoctSmGPjqnNp5tmwJD4Dw7Ect1LLc+fATyjjUt0HmiJ1JLzXq/dA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757896284; 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=NLi0BLfnbn1bGBDIJe/6RxHe3qDbn6IwBJnspWbpYZU=; b=Fi0TjYoDOQ8vmIzitrRNL250U7hKl9yad9LqY1Ce1hiu3zP9LOJs6F2lnipb+CFQ+IfXgr il/8enxPX+Vysxv6IlZtpIUwpjBrl6GMYH8DOvSLoVjjJyoypR+gbyj5uS6VEOLSvTO9gq oHNrO0xRYEJRNkwGq8ChbpVn3yBNRwfsiLJ51np3y6JhOZmj4BhMhI5AcclboUCzUCTJsu wOodz2J0mAP6fjm6+8lumIWGQ7CDq7gwn6Tg0mVKKuUarQ2adnXSp3v5ABJ7UpgbM5SyXH o0qSldyXu6yCGA69Cwj3JgwFf1PAnwyb7zQcMlt5R5/Qes5h4lQBvH9sLEVTMw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757896284; a=rsa-sha256; cv=none; b=tNxxczmLIG6zfjM264pFlbiqtSduM0Exim3pxn+0Q2jfVK3Gv23i22s7smtTSjgkoyFNEq eTDCQm1YprBv3V3f5z/NPCSv5kU/V/bTmjozOJwETiHOi0m37tygo9nBy34EX/5NjSXzP7 7wfkUsa0J2dUOE8+9fOSKD2cDmqrR9Yc8g6cd+98hNwjahPtdjlYlo9MAWw+ONQQ1ACt5j 8j24Q7kGOn3KnO2TZ17cTrYKz4usDN+xHcKifftVyVmNleE/XCcfkg5myPUIJVNLZbx/5/ OAHfDG+bhkq36Ddx/tX+UQbaLKNluJ42qhEkheAJDW/p/SC1eoPALqkCcGNgCw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQ5Ym1xxnzX2K; Mon, 15 Sep 2025 00:31:24 +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 58F0VOLV049063; Mon, 15 Sep 2025 00:31:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58F0VOhb049060; Mon, 15 Sep 2025 00:31:24 GMT (envelope-from git) Date: Mon, 15 Sep 2025 00:31:24 GMT Message-Id: <202509150031.58F0VOhb049060@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alan Somers Subject: git: d1eaa52d10f9 - main - fusefs: fix the last_local_modify LLM/LastLocalModify.lookup/3 test 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: asomers X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d1eaa52d10f9b85e5f6358e1a280899b9d55dd07 Auto-Submitted: auto-generated The branch main has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=d1eaa52d10f9b85e5f6358e1a280899b9d55dd07 commit d1eaa52d10f9b85e5f6358e1a280899b9d55dd07 Author: Alan Somers AuthorDate: 2025-09-15 00:22:36 +0000 Commit: Alan Somers CommitDate: 2025-09-15 00:30:30 +0000 fusefs: fix the last_local_modify LLM/LastLocalModify.lookup/3 test The LastLocalModify tests were originally written to simulate a race condition between VOP_SETATTR and VOP_LOOKUP. They were later extended to cover some other VOPs that can affect file size, including VOP_WRITE. However, the test never correctly simulated the race with VOP_WRITE. So that test only ever passed by accident. Fix it by always opening the file with O_DIRECT. PR: 289237 Reported by: Siva Mahadevan MFC after: 1 week --- tests/sys/fs/fusefs/last_local_modify.cc | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/tests/sys/fs/fusefs/last_local_modify.cc b/tests/sys/fs/fusefs/last_local_modify.cc index 5fcd3c36c892..6b8c19f1efc7 100644 --- a/tests/sys/fs/fusefs/last_local_modify.cc +++ b/tests/sys/fs/fusefs/last_local_modify.cc @@ -174,7 +174,15 @@ static void* write_th(void* arg) { if (sem) sem_wait(sem); - fd = open("mountpoint/some_file.txt", O_RDWR); + /* + * Open the file in direct mode. + * The race condition affects both direct and non-direct writes, and + * they have separate code paths. However, in the non-direct case, the + * kernel updates last_local_modify _before_ sending FUSE_WRITE to the + * server. So the technique that this test program uses to invoke the + * race cannot work. Therefore, test with O_DIRECT only. + */ + fd = open("mountpoint/some_file.txt", O_RDWR | O_DIRECT); if (fd < 0) return (void*)(intptr_t)errno; @@ -332,7 +340,7 @@ TEST_P(LastLocalModify, lookup) /* Wait for FUSE_SETATTR to be sent */ sem_wait(&sem); - /* Lookup again, which will race with setattr */ + /* Lookup again, which will race with the mutator */ ASSERT_EQ(0, stat(FULLPATH, &sb)) << strerror(errno); ASSERT_EQ((off_t)newsize, sb.st_size); From nobody Mon Sep 15 00:32:54 2025 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 4cQ5bV3X35z67kPL; Mon, 15 Sep 2025 00:32:54 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQ5bV2zS1z3d6s; Mon, 15 Sep 2025 00:32:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757896374; 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=anMn8uNGib/O1w8+bMeZNWk+A3vffjPFPiCwxQvP/90=; b=S40QMzKvZacOs+yFObRaTviG1sn8vdLKZibykNaSlHz01+N8Dg13dkhZId2HzBsqboX2ZN amXfmCxUouuLUyWYkpdejmM1Xhhz83CdfJlh3Cq/wPase5vezgEkNsdHvWpgqFJIQXqigS yTONHpMTh/y3tGT2l9igOIZHSvguj//7UEe00E5e7b7lAFK0BQRYwufXD6PPzwIctTZYbb aCdBEqxa/YlEuI9POkvSDaGV8d/s3j6a/ZtFfnOiLusC9WrGlpFJaaoRd+QLIdCCqjHAQL W+QXsLbY6SWsGyeX0RlS1gKBQ9hQbx+hXpKSWgqhiY74pSEU9YdDqr9l2rvu4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757896374; 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=anMn8uNGib/O1w8+bMeZNWk+A3vffjPFPiCwxQvP/90=; b=Z5cyWqznykpTrmdbjJjZOPNqUKL2x6kU9jFw2DyBfVgJjI9OHQBLaYofeWv82tR8tzOGCR x5e//hnlQqJYZeO9jpu0b8spViIZfOPW0kE1vbxCLCaOGON3ERIWPRV+gjclWQO9ozB4wJ XUlydDetiszVjwoCKj8iMt0FoBP+AWuxjFW04N04pVu8j9goj43F6DVic0YBnohuaThawX 2g7AdjvCIN7pDyg+B7Gj7pJsPf39bvAZHPZzIRQCNzFN4oycjmp5KKyZRYP8/kAphgqBVO SYwYNoDlYtQr22mRY1XiBp6r26nkUSErXJBLTwmyHIbF6sZA8eYZgo2nEALTAA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757896374; a=rsa-sha256; cv=none; b=LDOVLUb7C+l9slpuh1/m9xAdbFJffUX/xH0jUk0TB0K7r7tD9Rbtdb2/F9g+/6OQRtDkz/ dgxVPKIYXua3arKK85NRc0tWaHrT+qxmKGFlVL9DBbjpbevPosy4johTac7PlapYQ5R2In 9S3JhPDYoMMvPjXB1M4NRuq2PDDeKCFyt5S/NLgkNloXv1xkowjb/B3opvNkTHaigbbLXV UdMYXIRd28zUsv1O9ut7fzaNhSATYM50P1Gk4SmpNiUiym7liHGJb2BmyodpxF9ZK/3Gj7 PvWP4wui1eAp+SjLEjLsXEGLDI2v2Ln4g7TTZtPZwrQZRj4aSGjwvSOt75NWiw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQ5bV2bDmzXZv; Mon, 15 Sep 2025 00:32:54 +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 58F0WsOh051976; Mon, 15 Sep 2025 00:32:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58F0WsZo051973; Mon, 15 Sep 2025 00:32:54 GMT (envelope-from git) Date: Mon, 15 Sep 2025 00:32:54 GMT Message-Id: <202509150032.58F0WsZo051973@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alan Somers Subject: git: 2918cf358291 - main - fusefs: spaces to tabs. No functional change. 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: asomers X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2918cf3582915bd8853784f53c88e2c34055df1f Auto-Submitted: auto-generated The branch main has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=2918cf3582915bd8853784f53c88e2c34055df1f commit 2918cf3582915bd8853784f53c88e2c34055df1f Author: Alan Somers AuthorDate: 2025-09-15 00:31:56 +0000 Commit: Alan Somers CommitDate: 2025-09-15 00:31:56 +0000 fusefs: spaces to tabs. No functional change. [skip ci] --- sys/fs/fuse/fuse_vnops.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/fs/fuse/fuse_vnops.c b/sys/fs/fuse/fuse_vnops.c index de60a4717dd4..8712679375c6 100644 --- a/sys/fs/fuse/fuse_vnops.c +++ b/sys/fs/fuse/fuse_vnops.c @@ -953,7 +953,7 @@ fuse_vnop_copy_file_range(struct vop_copy_file_range_args *ap) *ap->a_outoffp += fwo->size; fuse_internal_clear_suid_on_write(outvp, outcred, td); if (*ap->a_outoffp > outfvdat->cached_attrs.va_size) { - fuse_vnode_setsize(outvp, *ap->a_outoffp, false); + fuse_vnode_setsize(outvp, *ap->a_outoffp, false); getnanouptime(&outfvdat->last_local_modify); } fuse_vnode_update(invp, FN_ATIMECHANGE); From nobody Mon Sep 15 01:00:54 2025 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 4cQ6Cr294Vz67mNG; Mon, 15 Sep 2025 01:00:56 +0000 (UTC) (envelope-from kevans@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQ6Cr1TQXz3jkm; Mon, 15 Sep 2025 01:00:56 +0000 (UTC) (envelope-from kevans@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757898056; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=SJqx6rs8OGgTffmC2BwzN/DorYSgvL5/ArPU6ArS7b8=; b=Q6NBcLCIXspH4chZFOuJzyrEs5Mf1saC0Ht9Ax0C6UULtJc66UinpD0dM9SOMix3m+DEFk Djx6MDEbOK4CLUlgp+dfISQzso++kjY8TcTmuWvrRCZRAdS8QMn74KXGlqhUgDyZLJhkXd 3XWho6rUYdWr+NVsJg8Fyj70b3mNH57VZvZoT/xb2ikficT95Bt++Q5NJZq8TE4BHNNTZ5 wF1DVUHEfZZM9iv10lekU00oaQhrQIbmhqopekOMT4z3hhx/8P5nW6f5l8V5Z4SpEbH4hm 4iNuek76H2uRfqvJENQI+y3CeGa474MX50Z5LrV6MKqZgLbTeF7dXym67+KUEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757898056; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=SJqx6rs8OGgTffmC2BwzN/DorYSgvL5/ArPU6ArS7b8=; b=TJrU4FY4HXZIZXGZlQh2DhodYgDOoU/NnnT9HlUAhbsG3h7U+Ywx+//GUwvNvGSnEVmkgq m20u8pf8eCJE0kX/E0UVO92tv2yz15yzFvwskwbva+eUEAOFbtN4gY6p10vRyaCYc0kYHP QeF3mwqI1l7hsnQSO1uXWCkkvi7AhGMzr/JUhoMEBOJSgYwVp1Jxxyai0oHKqwajzVn8Lh bcL4yJV/y5womacfD7Uho8FDT3KD1YQ8z29U+gMvyk/XiE2Xbw7jSZ6e3hiHKkbae7wjGV v+QUpkmq9dIpXTvxRS5ZfhJndqivl6CGbXvxT1jZtoLrD8xpaHxJRk209tnxiQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757898056; a=rsa-sha256; cv=none; b=N9vJmG8WxuyntcbCemJE43YckYN6uiJC373R1CuUpDcp0BBW5Yhzg8dx24fY4HySPIfGC/ QWGusFLnExEOabbpZOJIJFqD9nPYD+NyFIjScqvE0Di14ZAO501yfPY5Nn58Q2mbAtyxJ/ mKRVlDAZMmxWWQ+3jAXYlOzvWlqzWeBaeMQk6XFqqS332c+FNeF4+YMiC6nAjMOu7kNRad ztMC2kiGYTNaggMn7doMxNjagAHAHF76Fysxl9iUhqZeta2fB04H97IBbAarEWWLsmL8Rz OtGeSKMO0JYItAD2Oxsiq2auwOyWd8GdsW3g/ErJwKBC/iOJtXFLEimEEbXT5A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from [10.9.4.95] (unknown [209.182.120.176]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: kevans/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cQ6Cq4vkbzqFL; Mon, 15 Sep 2025 01:00:55 +0000 (UTC) (envelope-from kevans@FreeBSD.org) Message-ID: Date: Sun, 14 Sep 2025 20:00:54 -0500 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 User-Agent: Mozilla Thunderbird Subject: Re: git: dbaaadd4373a - main - jls: minor simplification to arg handling To: "Danilo G. Baio" , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org References: <202507260314.56Q3E5cY002869@gitrepo.freebsd.org> <54e7f090-c031-47f2-bc51-c020a77ab00a@app.fastmail.com> Content-Language: en-US Cc: James Gritton From: Kyle Evans In-Reply-To: <54e7f090-c031-47f2-bc51-c020a77ab00a@app.fastmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 9/14/25 19:14, Danilo G. Baio wrote: > > > On Sat, Jul 26, 2025, at 00:14, Kyle Evans wrote: >> The branch main has been updated by kevans: >> >> URL: >> https://cgit.FreeBSD.org/src/commit/?id=dbaaadd4373a725950ad11e578dab61537b7c4f2 >> >> commit dbaaadd4373a725950ad11e578dab61537b7c4f2 >> Author: Kyle Evans >> AuthorDate: 2025-07-26 03:13:41 +0000 >> Commit: Kyle Evans >> CommitDate: 2025-07-26 03:13:41 +0000 >> >> jls: minor simplification to arg handling >> >> It's easier to reason about the state of argc/argv if we just augment >> them by optind after our getopt() loop. >> >> No functional change, but this sets the stage for another change to add >> a `-c` mode to (c)heck for the existence of a jail quietly without >> the caller having to worry about spurious output. >> >> Reviewed by: jamie >> Differential Revision: https://reviews.freebsd.org/D51540 >> --- >> usr.sbin/jls/jls.c | 10 ++++++---- >> 1 file changed, 6 insertions(+), 4 deletions(-) >> >> diff --git a/usr.sbin/jls/jls.c b/usr.sbin/jls/jls.c >> index bd193a69c458..a1d1716713aa 100644 >> --- a/usr.sbin/jls/jls.c >> +++ b/usr.sbin/jls/jls.c >> @@ -140,8 +140,11 @@ main(int argc, char **argv) >> ip4_ok = feature_present("inet"); >> #endif >> >> + argc -= optind; >> + argv += optind; >> + >> /* Add the parameters to print. */ >> - if (optind == argc) { >> + if (argc == 0) { >> if (pflags & (PRINT_HEADER | PRINT_NAMEVAL)) >> add_param("all", NULL, (size_t)0, NULL, JP_USER); >> else if (pflags & PRINT_VERBOSE) { >> @@ -179,9 +182,8 @@ main(int argc, char **argv) >> } >> } else { >> pflags &= ~PRINT_VERBOSE; >> - while (optind < argc) >> - add_param(argv[optind++], NULL, (size_t)0, NULL, >> - JP_USER); >> + for (i = 0; i < argc; i++) >> + add_param(argv[i], NULL, (size_t)0, NULL, JP_USER); >> } >> >> if (pflags & PRINT_SKIP) { > > > Hi, > > Just replying to one of the recent changes on `jls`. > > We use `jls -n` in many scripts, and recently, it stopped working. > > The last build that was working for us: > FreeBSD 15.0-CURRENT #0 main-n278879-4be9c6f38e78: Sat Jul 19 13:19:25 UTC 2025 > > We are now encountering the following issue on this build: > FreeBSD 16.0-CURRENT #0 main-n280141-5e82eeccd252: Sat Sep 6 05:27:34 UTC 2025 > > $ jls -n > desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable sysvsem=disable sysvshm=disable vnet=disable zfs=disable allow.noadjtime allow.nochflags allow.noextattr allow.nomlock allow.nomount allow.mount.nodevfs allow.mount.nofdescfs allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets allow.noread_msgbuf allow.noreserved_ports allow.norouting allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuser allow.nosysvipc allow.nounprivileged_parent_tampering allow.nounprivileged_proc_debug children.cur=0 children.max=0 cpuset.id=0 host.domainname="" host.hostid=0 host.hostname="" host.hostuuid="" ip4.addr=0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0 ip4.nosaddrsel ip6.addr=::,::,::,::,::,:: ip6.nosaddrsel zfs.mount_snapshot=0 > desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable sysvsem=disable sysvshm=disable vnet=disable zfs=disable allow.noadjtime allow.nochflags allow.noextattr allow.nomlock allow.nomount allow.mount.nodevfs allow.mount.nofdescfs allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets allow.noread_msgbuf allow.noreserved_ports allow.norouting allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuser allow.nosysvipc allow.nounprivileged_parent_tampering allow.nounprivileged_proc_debug children.cur=0 children.max=0 cpuset.id=0 host.domainname="" host.hostid=0 host.hostname="" host.hostuuid="" ip4.addr=0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0 ip4.nosaddrsel ip6.addr=::,::,::,::,::,:: ip6.nosaddrsel zfs.mount_snapshot=0 > desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable sysvsem=disable sysvshm=disable vnet=disable zfs=disable allow.noadjtime allow.nochflags allow.noextattr allow.nomlock allow.nomount allow.mount.nodevfs allow.mount.nofdescfs allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets allow.noread_msgbuf allow.noreserved_ports allow.norouting allow.noset_hostname allow.nosettime > [...] > infinite loop > Adding jamie@, neither of the changes to jls(1) should've caused this, as far as I can reason about (and I haven't observed this here, yet). This looks like a failure to terminate the print_jail loop at the end? From nobody Mon Sep 15 02:30:02 2025 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 4cQ8Bg4qbkz67sdy; Mon, 15 Sep 2025 02:30:03 +0000 (UTC) (envelope-from kevans@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQ8Bg49CFz3pXn; Mon, 15 Sep 2025 02:30:03 +0000 (UTC) (envelope-from kevans@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757903403; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=kdfNwAAa1b+fNjKrXYAIb7p5VOhytlBuRnEOlvzIeBA=; b=ARjxGbMOqUDS3db+J4O6tsZy9jJJ+afoMolwMOYrG918qiKAKt7xXA3jXAQWpNPAvLG3ZK mIA6Emm8hlDV1iX/aSdIMDNgpKaC3eDC/tpHuXVFRXzxUM6SlOl7O5wIjuTaehD5Jj1HoX AGV8uD2i1mV+yka+Og4N1WrG7bQovfFMoJqapzlwXPVGxqrXQeqcR20P0SX55Kbpxx9lZI 2SnZoMXTCz6+okuqt60F2yfiiO5xiawIsmjQH2lVpCQnq+lZr6AEtAW5C62cjsZ2eIuXA9 iB8o2MsG1xwMSo6RSy1p4+1LHORx2/zh1vhtGg9pZs/dhseFRhcErYnMpVCgyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757903403; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=kdfNwAAa1b+fNjKrXYAIb7p5VOhytlBuRnEOlvzIeBA=; b=nE/pXx2WFP67WFTh+ZXOg9cmlgGcNAcOAgcm4V6MumGzmO+EuNqoiT+oXjDm0Tnywao880 XkA80VoMwf62/sCEJrxHJ+qcNSDF6cYhc0Xaffavbow58XY4rB8wgl2dnN2CSYkjxP1p7A aq93GgE0YH8LTPik1alBoVZ51JMDX89OFDzythz0RFUpkFWhjEgpn5uPYaHa9/it2o8xj3 eBVr5RQ2bQqXklFvMuz0D8Lei0CMtAo6ZRXlaGE91gMwohWj4jX6150RyvT9ynrQMcOOrK LTTvZFwr2uq+4bcdBOcbZb4FXIPKy3CbLTftbgIRgGfGu0POFqP21ml1NuvbSw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757903403; a=rsa-sha256; cv=none; b=chLndDHJIU4+MUCB6KL/DRuW8B1ZPnR35bHntl+ruEx86mVeS2DEmmNQdOKAbysz2c4i98 gUHWBZzlmZBUGmQ5zqHFkvzDXOrIr8Df/Er8l0l0u8vaR5bScgUrIVCSfTZINAl1K+IG7j ikA0Z5vR+Sn6lQ8nDJDqfyDz6JkQeXLj8/mWCZcMyX2rc5BndTent8J/Re15/R/gg+/RCQ kGZxXEgK95ohi+zklEZ9DDii6L3vnWv11TT9ZISnEz8/sf4iAzlvUj+q5tfXle0pSEXiFX VNDXl7Ke43KLrVALFfi0O4iUrSF3zPEfdHuGHmXz/B5PSbdlaRNZC/BSNBksGA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from [10.9.4.95] (unknown [209.182.120.176]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: kevans/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cQ8Bg0cVpzpRq; Mon, 15 Sep 2025 02:30:02 +0000 (UTC) (envelope-from kevans@FreeBSD.org) Message-ID: Date: Sun, 14 Sep 2025 21:30:02 -0500 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 User-Agent: Mozilla Thunderbird Subject: Re: git: dbaaadd4373a - main - jls: minor simplification to arg handling From: Kyle Evans To: "Danilo G. Baio" , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Cc: James Gritton References: <202507260314.56Q3E5cY002869@gitrepo.freebsd.org> <54e7f090-c031-47f2-bc51-c020a77ab00a@app.fastmail.com> Content-Language: en-US In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 9/14/25 20:00, Kyle Evans wrote: > On 9/14/25 19:14, Danilo G. Baio wrote: >> >> >> On Sat, Jul 26, 2025, at 00:14, Kyle Evans wrote: >>> The branch main has been updated by kevans: >>> >>> URL: >>> https://cgit.FreeBSD.org/src/commit/?id=dbaaadd4373a725950ad11e578dab61537b7c4f2 >>> >>> commit dbaaadd4373a725950ad11e578dab61537b7c4f2 >>> Author:     Kyle Evans >>> AuthorDate: 2025-07-26 03:13:41 +0000 >>> Commit:     Kyle Evans >>> CommitDate: 2025-07-26 03:13:41 +0000 >>> >>>      jls: minor simplification to arg handling >>>      It's easier to reason about the state of argc/argv if we just augment >>>      them by optind after our getopt() loop. >>>      No functional change, but this sets the stage for another change to add >>>      a `-c` mode to (c)heck for the existence of a jail quietly without >>>      the caller having to worry about spurious output. >>>      Reviewed by:    jamie >>>      Differential Revision:  https://reviews.freebsd.org/D51540 >>> --- >>>   usr.sbin/jls/jls.c | 10 ++++++---- >>>   1 file changed, 6 insertions(+), 4 deletions(-) >>> >>> diff --git a/usr.sbin/jls/jls.c b/usr.sbin/jls/jls.c >>> index bd193a69c458..a1d1716713aa 100644 >>> --- a/usr.sbin/jls/jls.c >>> +++ b/usr.sbin/jls/jls.c >>> @@ -140,8 +140,11 @@ main(int argc, char **argv) >>>       ip4_ok = feature_present("inet"); >>>   #endif >>> >>> +    argc -= optind; >>> +    argv += optind; >>> + >>>       /* Add the parameters to print. */ >>> -    if (optind == argc) { >>> +    if (argc == 0) { >>>           if (pflags & (PRINT_HEADER | PRINT_NAMEVAL)) >>>               add_param("all", NULL, (size_t)0, NULL, JP_USER); >>>           else if (pflags & PRINT_VERBOSE) { >>> @@ -179,9 +182,8 @@ main(int argc, char **argv) >>>           } >>>       } else { >>>           pflags &= ~PRINT_VERBOSE; >>> -        while (optind < argc) >>> -            add_param(argv[optind++], NULL, (size_t)0, NULL, >>> -                JP_USER); >>> +        for (i = 0; i < argc; i++) >>> +            add_param(argv[i], NULL, (size_t)0, NULL, JP_USER); >>>       } >>> >>>       if (pflags & PRINT_SKIP) { >> >> >> Hi, >> >> Just replying to one of the recent changes on `jls`. >> >> We use `jls -n` in many scripts, and recently, it stopped working. >> >> The last build that was working for us: >> FreeBSD 15.0-CURRENT #0 main-n278879-4be9c6f38e78: Sat Jul 19 13:19:25 UTC 2025 >> >> We are now encountering the following issue on this build: >> FreeBSD 16.0-CURRENT #0 main-n280141-5e82eeccd252: Sat Sep  6 05:27:34 UTC 2025 >> >> $ jls -n >> desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable sysvsem=disable sysvshm=disable vnet=disable zfs=disable allow.noadjtime allow.nochflags allow.noextattr allow.nomlock allow.nomount allow.mount.nodevfs allow.mount.nofdescfs allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets allow.noread_msgbuf allow.noreserved_ports allow.norouting allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuser allow.nosysvipc allow.nounprivileged_parent_tampering allow.nounprivileged_proc_debug children.cur=0 children.max=0 cpuset.id=0 host.domainname="" host.hostid=0 host.hostname="" host.hostuuid="" ip4.addr=0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0 ip4.nosaddrsel ip6.addr=::,::,::,::,::,:: ip6.nosaddrsel zfs.mount_snapshot=0 >> desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable sysvsem=disable sysvshm=disable vnet=disable zfs=disable allow.noadjtime allow.nochflags allow.noextattr allow.nomlock allow.nomount allow.mount.nodevfs allow.mount.nofdescfs allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets allow.noread_msgbuf allow.noreserved_ports allow.norouting allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuser allow.nosysvipc allow.nounprivileged_parent_tampering allow.nounprivileged_proc_debug children.cur=0 children.max=0 cpuset.id=0 host.domainname="" host.hostid=0 host.hostname="" host.hostuuid="" ip4.addr=0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0 ip4.nosaddrsel ip6.addr=::,::,::,::,::,:: ip6.nosaddrsel zfs.mount_snapshot=0 >> desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable sysvsem=disable sysvshm=disable vnet=disable zfs=disable allow.noadjtime allow.nochflags allow.noextattr allow.nomlock allow.nomount allow.mount.nodevfs allow.mount.nofdescfs allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets allow.noread_msgbuf allow.noreserved_ports allow.norouting allow.noset_hostname allow.nosettime >> [...] >> infinite loop >> > > Adding jamie@, neither of the changes to jls(1) should've caused this, as far as I can reason about (and I haven't observed this here, yet).  This looks like a failure to terminate the print_jail loop at the end? I still can't functionally update, but looking at the recent jaildesc work, I wonder if this is a side effect that has since been fixed in e75dda31c1eead9ad40580bd8 by removing the "desc" parameter. It would have been included in jailparam_all(), and I wonder if that somehow broke jls-style iteration? From nobody Mon Sep 15 03:03:48 2025 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 4cQ8xk5k3vz67vqY; Mon, 15 Sep 2025 03:03:54 +0000 (UTC) (envelope-from jamie@gritton.org) Received: from m2.gritton.org (gritton.org [67.43.236.212]) (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 mx1.freebsd.org (Postfix) with ESMTPS id 4cQ8xk2wVJz3vsF; Mon, 15 Sep 2025 03:03:54 +0000 (UTC) (envelope-from jamie@gritton.org) Authentication-Results: mx1.freebsd.org; none Received: from gritton.org (localgritton [127.0.0.212]) by m2.gritton.org (Postfix) with ESMTPSA id 638017D3EF; Sun, 14 Sep 2025 20:03:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=gritton.org; s=m2; t=1757905428; bh=sjWAkFKxYJxPTTM8Dh6QypNkseGfIcV+dcE17JA7JTs=; h=Date:From:To:Cc:Subject:In-Reply-To:References; b=hl9RSS2lVadqrI4yfyIGfDvbEy7yQ68CoE3GixdsN+HWnR3XBPl0fXwu7kgBwYEpe GNaQ3PlSYyNOEdyf0VhMzHMTlnwccAknkwZx0KQ3ggBTGh+51ATDL9IUV3H+tyd3yM DViLuBGXgch1qRAFR7swjQB2Zf/lLXmIRgn+G1rM= 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 Date: Sun, 14 Sep 2025 20:03:48 -0700 From: James Gritton To: Kyle Evans Cc: "Danilo G. Baio" , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: dbaaadd4373a - main - jls: minor simplification to arg handling In-Reply-To: References: <202507260314.56Q3E5cY002869@gitrepo.freebsd.org> <54e7f090-c031-47f2-bc51-c020a77ab00a@app.fastmail.com> Message-ID: X-Sender: jamie@gritton.org Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:36666, ipnet:67.43.224.0/20, country:CA] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4cQ8xk2wVJz3vsF On 2025-09-14 19:30, Kyle Evans wrote: > On 9/14/25 20:00, Kyle Evans wrote: >> On 9/14/25 19:14, Danilo G. Baio wrote: >>> >>> >>> On Sat, Jul 26, 2025, at 00:14, Kyle Evans wrote: >>>> The branch main has been updated by kevans: >>>> >>>> URL: >>>> https://cgit.FreeBSD.org/src/commit/?id=dbaaadd4373a725950ad11e578dab61537b7c4f2 >>>> >>>> commit dbaaadd4373a725950ad11e578dab61537b7c4f2 >>>> Author:     Kyle Evans >>>> AuthorDate: 2025-07-26 03:13:41 +0000 >>>> Commit:     Kyle Evans >>>> CommitDate: 2025-07-26 03:13:41 +0000 >>>> >>>>      jls: minor simplification to arg handling >>>>      It's easier to reason about the state of argc/argv if we just >>>> augment >>>>      them by optind after our getopt() loop. >>>>      No functional change, but this sets the stage for another >>>> change to add >>>>      a `-c` mode to (c)heck for the existence of a jail quietly >>>> without >>>>      the caller having to worry about spurious output. >>>>      Reviewed by:    jamie >>>>      Differential Revision:  https://reviews.freebsd.org/D51540 >>>> --- >>>>   usr.sbin/jls/jls.c | 10 ++++++---- >>>>   1 file changed, 6 insertions(+), 4 deletions(-) >>>> >>>> diff --git a/usr.sbin/jls/jls.c b/usr.sbin/jls/jls.c >>>> index bd193a69c458..a1d1716713aa 100644 >>>> --- a/usr.sbin/jls/jls.c >>>> +++ b/usr.sbin/jls/jls.c >>>> @@ -140,8 +140,11 @@ main(int argc, char **argv) >>>>       ip4_ok = feature_present("inet"); >>>>   #endif >>>> >>>> +    argc -= optind; >>>> +    argv += optind; >>>> + >>>>       /* Add the parameters to print. */ >>>> -    if (optind == argc) { >>>> +    if (argc == 0) { >>>>           if (pflags & (PRINT_HEADER | PRINT_NAMEVAL)) >>>>               add_param("all", NULL, (size_t)0, NULL, JP_USER); >>>>           else if (pflags & PRINT_VERBOSE) { >>>> @@ -179,9 +182,8 @@ main(int argc, char **argv) >>>>           } >>>>       } else { >>>>           pflags &= ~PRINT_VERBOSE; >>>> -        while (optind < argc) >>>> -            add_param(argv[optind++], NULL, (size_t)0, NULL, >>>> -                JP_USER); >>>> +        for (i = 0; i < argc; i++) >>>> +            add_param(argv[i], NULL, (size_t)0, NULL, JP_USER); >>>>       } >>>> >>>>       if (pflags & PRINT_SKIP) { >>> >>> >>> Hi, >>> >>> Just replying to one of the recent changes on `jls`. >>> >>> We use `jls -n` in many scripts, and recently, it stopped working. >>> >>> The last build that was working for us: >>> FreeBSD 15.0-CURRENT #0 main-n278879-4be9c6f38e78: Sat Jul 19 >>> 13:19:25 UTC 2025 >>> >>> We are now encountering the following issue on this build: >>> FreeBSD 16.0-CURRENT #0 main-n280141-5e82eeccd252: Sat Sep  6 >>> 05:27:34 UTC 2025 >>> >>> $ jls -n >>> desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable >>> ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 >>> osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable >>> sysvsem=disable sysvshm=disable vnet=disable zfs=disable >>> allow.noadjtime allow.nochflags allow.noextattr allow.nomlock >>> allow.nomount allow.mount.nodevfs allow.mount.nofdescfs >>> allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs >>> allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets >>> allow.noread_msgbuf allow.noreserved_ports allow.norouting >>> allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuser >>> allow.nosysvipc allow.nounprivileged_parent_tampering >>> allow.nounprivileged_proc_debug children.cur=0 children.max=0 >>> cpuset.id=0 host.domainname="" host.hostid=0 host.hostname="" >>> host.hostuuid="" >>> ip4.addr=0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0 >>> ip4.nosaddrsel ip6.addr=::,::,::,::,::,:: ip6.nosaddrsel >>> zfs.mount_snapshot=0 >>> desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable >>> ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 >>> osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable >>> sysvsem=disable sysvshm=disable vnet=disable zfs=disable >>> allow.noadjtime allow.nochflags allow.noextattr allow.nomlock >>> allow.nomount allow.mount.nodevfs allow.mount.nofdescfs >>> allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs >>> allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets >>> allow.noread_msgbuf allow.noreserved_ports allow.norouting >>> allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuser >>> allow.nosysvipc allow.nounprivileged_parent_tampering >>> allow.nounprivileged_proc_debug children.cur=0 children.max=0 >>> cpuset.id=0 host.domainname="" host.hostid=0 host.hostname="" >>> host.hostuuid="" >>> ip4.addr=0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0 >>> ip4.nosaddrsel ip6.addr=::,::,::,::,::,:: ip6.nosaddrsel >>> zfs.mount_snapshot=0 >>> desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable >>> ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 >>> osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable >>> sysvsem=disable sysvshm=disable vnet=disable zfs=disable >>> allow.noadjtime allow.nochflags allow.noextattr allow.nomlock >>> allow.nomount allow.mount.nodevfs allow.mount.nofdescfs >>> allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs >>> allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets >>> allow.noread_msgbuf allow.noreserved_ports allow.norouting >>> allow.noset_hostname allow.nosettime >>> [...] >>> infinite loop >>> >> >> Adding jamie@, neither of the changes to jls(1) should've caused this, >> as far as I can reason about (and I haven't observed this here, yet).  >> This looks like a failure to terminate the print_jail loop at the end? > > I still can't functionally update, but looking at the recent jaildesc > work, I wonder > if this is a side effect that has since been fixed in > e75dda31c1eead9ad40580bd8 by > removing the "desc" parameter. It would have been included in > jailparam_all(), and > I wonder if that somehow broke jls-style iteration? I'm nearly certain that it is. I noticed that "jls desc" produced such a loop, so I expect the exclusion of desc as a real parameter fixes it. - Jamie From nobody Mon Sep 15 03:04:11 2025 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 4cQ8y35xFrz67w1y; Mon, 15 Sep 2025 03:04:11 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQ8y34CfFz3w37; Mon, 15 Sep 2025 03:04:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757905451; 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=wmXQG1dDWgnoL47x3VA7eEKgQY70wx/f78TwmpOw+2s=; b=Bgr+NF9kW9l6kBDNDUR+BmFMdo6T8ENsoj2EUkwn936XOhlHfQuJ1B+QcscOui5fU31nTf u9i+iODKzHpNT/ZdgsxPE8P4x72dz34O30BPrSKb2W7F0nP8x2FI5qvHce63yWFENTEFxc vjcyX96/wOmCN241nlLhQXso1tBglhXPf6OCFykWdgyqZ/IZbVuQij2PyLytHHslv/WYjj 5iEI+SsM76R6JBgCe5uq3WUV2s1AojTlx/DkBQVoLEnVowElJQbthVdIM2TBbN1t9R+GUD mT4E5CkKbX/DIdLWPMRQAI73Kx5bEqv1vHZwN6amZ3/Eq7ELTUBiaOQRDEjQBQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757905451; 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=wmXQG1dDWgnoL47x3VA7eEKgQY70wx/f78TwmpOw+2s=; b=E/GAkhHwl64AB250BxRmHQ3uy4zb5ZPiyD5JoTRFhHj/XH50V93LWzLUR3xAkp/Lp0d+j2 Ooy464CZvOGNAo8/5C4+gX21T60mSc86bnQd0ustSDrTdLB/mpbxnNkCuAUg0kmmMJP8At iyHSo43rjvNxLGb/GBBZiKs7HNlPiYVt5s/PqtFs1wmB8WZgPD/d7Bk30ZSrdKtMQllQmd ymjXsd+RluUR/3AlPhLHBsXZlcI9CNdNesyY95DQWCyk+gIz7nh4Ah0DLF8j6jICKIdKMr E9GvXurzUI5U0C7/fo3mypDjlgtiCPbARIM3Vr2ppLtryk4DRQtGhMHjcqzorw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757905451; a=rsa-sha256; cv=none; b=j3bYCxALzXLMDanjHa9bHY4p2zBMjAYD6NfvYPaIvshT7ujYHMvR3Co8RqMxABGXa1F0m2 +/H6Vxp0yta7fN/LzRh7JWpe6mlxVRbsARiGKkETE1oY3QpcBieMKThSiN3c7g1hsHUlZ+ XKRhpfy4kXx1/wE20VUuA2P7UsqA/gct40ofJU8qaHPEVnsdNqbio1YzzI+QP8ROTUDU/c YgYioRiiHP7v6cXkfhjAncbO2HwcjcoCUnjus/Mgo5JcaW3MV9H+7vwkDOxHPKRVfsKaou XBDQL3Wy7Knz8qR7MRwBjA8+PHJKMikrFiDKppJCoYenmjXYp+WoIqfSS5Dpqg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQ8y33nQtzcRN; Mon, 15 Sep 2025 03:04:11 +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 58F34B5T035105; Mon, 15 Sep 2025 03:04:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58F34BWJ035102; Mon, 15 Sep 2025 03:04:11 GMT (envelope-from git) Date: Mon, 15 Sep 2025 03:04:11 GMT Message-Id: <202509150304.58F34BWJ035102@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 5e0a4859f28a - main - iwlwifi: Don't compile for gcc before 14 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: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5e0a4859f28ad4869f7a73faf42debc355a370bf Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=5e0a4859f28ad4869f7a73faf42debc355a370bf commit 5e0a4859f28ad4869f7a73faf42debc355a370bf Author: Warner Losh AuthorDate: 2025-09-14 18:03:16 +0000 Commit: Warner Losh CommitDate: 2025-09-15 03:03:45 +0000 iwlwifi: Don't compile for gcc before 14 gcc 13 and earlier don't have __builtin_bitcountg. The linux wifi kpi uses this unconditionally. While in this one use, it might not be needed, I opted to not compile iwlwifi when building gcc12 or 13 rather than risk breaking it for everbody else. With this change gcc12 builds the kernel. Maybe this will stop jenkins email for every commit I make. Sponsored by: Netflix --- sys/modules/Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/modules/Makefile b/sys/modules/Makefile index 5315d518afd8..f9fdbca78869 100644 --- a/sys/modules/Makefile +++ b/sys/modules/Makefile @@ -576,7 +576,10 @@ _mlx5ib= mlx5ib ${MACHINE_CPUARCH} == "i386" _ena= ena _gve= gve +# gcc13 and earlier lack __builtin_bitcountg used by linux emulation +.if !(${COMPILER_TYPE} == "gcc" && ${COMPILER_VERSION} < 140000) _iwlwifi= iwlwifi +.endif _rtw88= rtw88 _rtw89= rtw89 _vmware= vmware From nobody Mon Sep 15 03:15:36 2025 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 4cQ9CD6gVCz67wr2; Mon, 15 Sep 2025 03:15:36 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQ9CD5DhSz3wgg; Mon, 15 Sep 2025 03:15:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757906136; 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=58S8qt0IxlezCZkk5uQSD0I5WNVfpDGq8UnudLcT+Ik=; b=Rn6fkbiZ0rT8qZgsB3ALLrAhOvKsIbBvc+arSzIcSn8zgNKkOBMOKhRt9Ff4GdDU2v9M2h /kAE1BRuuovZ+9GTffa4UMKt2P93Iv/gyPC+T+vKXcW7n+9tSAQm0mu4eQ2gpr4KgJQHhI BZzsOA4DhVoLyRKlnz5k2X9T+7PdODo78JgFMkRA6F/D2mRnnRKZ4lwcB32vIwz6i+SnYC Y82SaXRikDqpxn5WyZyXMOwtWFOg6gu5EHKeBXmiSEWYH4eI1r5h4W2GA0HAOvqi6ETc3v z/SJf+fm0S2PmOxFYrsiMNe0dQ+/PVrinAuI907O2fWwRumAjzQkhg5qIbdwrw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757906136; 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=58S8qt0IxlezCZkk5uQSD0I5WNVfpDGq8UnudLcT+Ik=; b=tQhnQOlg4mv6jdtou+P9HuEd4CZb0KztsmY/5KSRfZYxzlMDuffMaYO4qWrkyJiCtzzQSk SxLnHyHnNle7gnXUPcdDQ/RpG4upYQDXYNn2BYYNL2CU9oFFYKYwBaCl74TZfibBa1unkh ZisqHA/rOxmk1Fr2z2PwtXH/EiCEw2IIjkymEYCnS6MfSwdhk1poEXt4uivy68SQ1odZOC G/HZEhRDEp7BBJq9bscZmYMCfmq/c8gbYycU25qfSE9NrXWY2m8dfkco+/ZOBnIvkaxibC 470PndAmlAgsNYmCYaiK5OmsT0B0I+9n9nB1rnbKX1IvWGqbxLrwuk9kENxJSA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757906136; a=rsa-sha256; cv=none; b=YDRZ5ksNwiMs3woI+sVcZ+jJcvLReUWbw+HUeHTYxRXDQbLhs07Vxrvjfe7K/J+8rWyKN1 R8HDqwHblh7kuHbiHzDctnGgDyTgddeE8rEOXJjYdgGOn9ENH1euwpq4aZl99pefvpt/9A Hb2roroQd8jzJc36jjjzrAdY7Eqm80rI99U0gQFOZQf66lgyrH9YIb3l2OmZk/F0Sh0hLc KOAirZPXy56xVHAyft2Pv4iTi8unAbVGowXQFDcxnt6kebviTB2OKlvHDqJS8/mwJQWV3R 5S7k1WS+qIggH8m28EepSR/+oI0IrTe9UQQLgMMgxEpanO43n3E8s2V6qqafaw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQ9CD4ncmzd87; Mon, 15 Sep 2025 03:15:36 +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 58F3FaG4053892; Mon, 15 Sep 2025 03:15:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58F3FaLU053889; Mon, 15 Sep 2025 03:15:36 GMT (envelope-from git) Date: Mon, 15 Sep 2025 03:15:36 GMT Message-Id: <202509150315.58F3FaLU053889@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: e239f49146e0 - main - UPDATING: fix typos 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: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e239f49146e0b8a400db5eb014f4a3f706380780 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=e239f49146e0b8a400db5eb014f4a3f706380780 commit e239f49146e0b8a400db5eb014f4a3f706380780 Author: Harry Fellowes AuthorDate: 2025-09-14 18:12:33 +0000 Commit: Warner Losh CommitDate: 2025-09-15 03:07:13 +0000 UPDATING: fix typos Fixed typos in UPDATING Signed-off-by: Harry Fellowes Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1846 --- UPDATING | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/UPDATING b/UPDATING index f36cfdd9997d..999babfb6d7d 100644 --- a/UPDATING +++ b/UPDATING @@ -333,8 +333,8 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 16.x IS SLOW: 20250106: A new SOC_ROCKCHIP options appeared, so if you have a custom kernel configuration - targetting Rockchip SoC you need to add it so shared and mandatory drivers for - this SoC familly will be selected. + targeting Rockchip SoC you need to add it so shared and mandatory drivers for + this SoC family will be selected. Also a new rk8xx device was added, this select the base driver for Rockchip PMIC. 20241223: @@ -529,7 +529,7 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 16.x IS SLOW: 20230817: Serial communication (in boot loaders, kernel, and userland) has been changed to default to 115200 bps, in line with common industry - practice and typcial firmware serial console redirection + practice and typical firmware serial console redirection configuration. Note that the early x86 BIOS bootloader (i.e., boot0sio) does not @@ -613,7 +613,7 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 16.x IS SLOW: runs make -j${JOB_MAX} buildworld > ../buildworld.log 2>&1 - where JOB_MAX is derrived from ncpus in local.sys.mk if not set in env. + where JOB_MAX is derived from ncpus in local.sys.mk if not set in env. 20230316: Video related devices for some arm devices have been renamed. @@ -641,7 +641,7 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 16.x IS SLOW: 20230130: As of commit 7c40e2d5f685, the dependency on netlink(4) has been added to the linux_common(4) module. Users relying on linux_common may need - to complile netlink(4) module if it is not present in their kernel. + to compile netlink(4) module if it is not present in their kernel. 20230126: The WITHOUT_CXX option has been removed. C++ components in the base @@ -661,7 +661,7 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 16.x IS SLOW: 20221205: dma(8) has replaced sendmail(8) as the default mta. For people willing - to reenable sendmail(8): + to re-enable sendmail(8): $ cp /usr/share/examples/sendmail/mailer.conf /etc/mail/mailer.conf From nobody Mon Sep 15 04:04:16 2025 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 4cQBHP2JSsz680H3; Mon, 15 Sep 2025 04:04:17 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQBHP1dWjz42Pw; Mon, 15 Sep 2025 04:04:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757909057; 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=ubYt7Hc+cCTNB+c1ErPeahrH/AmOoWAx/fLXDa7fmtY=; b=GK90yrDJa09idlZ+t1CCHbLBG/LirA8TVdfRmul9xZbsR3fDVIFlgXaLfOLREVZF37V0mr FyW/tqt7Nz00ng111BXuT4wkIlKCuqotfPV0qTgwV2S4viclMndFaDqt93+k6+/wC2ZNaM k+eNeYwGCHroTpx4f+8YTYMDcFcX9rA0Y+y8EAe/N91KHb8Q13RVQdrVqFEZ+ZbwP/WoF2 0pDcdX/zuoDe5TeuV6EAx2Hacx8aieq3WR1PpHu5GOHo0ZA0yCEMgfadz+v3JqNqhjcN4E JD3Bj8ofdknowpg02HPoHSdEF2ByyZ+c48570GYAzYHTKnIhSzEKWajX8H+DmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757909057; 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=ubYt7Hc+cCTNB+c1ErPeahrH/AmOoWAx/fLXDa7fmtY=; b=Pl8JDUQ5JzZa0ZIyNeWN0BoExWjgZ4sgZUIqlWF5gKxuNph4E9PoxYy0QjpjOkQF9QMkb5 M6Wl15WOJ1s92Avi3Y6OlWPZXPvVBxM1VK6of/iA9g6Mt7RoeTeZhRYh9QLIT+qyIGXbBc XmBg3KUJohNN9ctguAvyifgg5Jhb0SjQ1LsOiYbekYiKZgkWQWP33b+gCG6ckjLYLPL6lC CvMhT1LrwPi0bs+43yeImu2RNhM4hLBiwG1dQeQSOKQO8t1peZSGVXcMmgUlnMUjd/pohl m+JvS3PlZqtCphIMpXjIymf7NCLDFfkNWrPdQwZVsBBMM+F7UWKsLqLbUCA55g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757909057; a=rsa-sha256; cv=none; b=Ml3zdRs3o4ApfLeooaBUa20nVnwUeM2fTDIdzXSsIALKdhzp99eQReA3qNm6GaONpp/zjE w2Y3K4hb4fyacomIplaocvvQeeadpnLfhep2GP98mpeUGRTR3s1wId9fz4OPzWUhN1Ipx4 x8k+ye3Rw4H/9SDlp9gKSRsWNBRim5Grrq5i7PSdm4A3N1GVoXquG+S9IUlDsMjG8aL4M9 W5PDV169F5SkUjS11VzhAHQAx1D4z8HTHQGbnB+oFx06vMWxwJxqX//WmxSCWRA9Uz47xC LgFtY4/RLTDDiUgPHA5Spq0x2c4zgCMX1HkhkbDp7EZWgrNXk2KyA7C/GRv34A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQBHP0fvbzfVM; Mon, 15 Sep 2025 04:04:17 +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 58F44GGs046666; Mon, 15 Sep 2025 04:04:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58F44G5K046663; Mon, 15 Sep 2025 04:04:16 GMT (envelope-from git) Date: Mon, 15 Sep 2025 04:04:16 GMT Message-Id: <202509150404.58F44G5K046663@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Jamie Gritton Subject: git: 1a849ff1e9a9 - stable/15 - jail: simplify EVFILT_JAIL events 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: jamie X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 1a849ff1e9a93f2d0f66c962a17b20af13796f01 Auto-Submitted: auto-generated The branch stable/15 has been updated by jamie: URL: https://cgit.FreeBSD.org/src/commit/?id=1a849ff1e9a93f2d0f66c962a17b20af13796f01 commit 1a849ff1e9a93f2d0f66c962a17b20af13796f01 Author: Jamie Gritton AuthorDate: 2025-09-12 05:22:45 +0000 Commit: Jamie Gritton CommitDate: 2025-09-15 03:33:18 +0000 jail: simplify EVFILT_JAIL events Instead of using the EVFILT_PROC model of attempting to automatically register new events when a child jail is created, just give a single event when a child jail is created. As was already done with jail attach events, make a best-effort report of the added jail's id in kn_data. If the are multiple NOTE_JAIL_CHILD and/or NOTE_JAIL_ATTACH events, set the NOTE_JAIL_MULTI flag, and don't report anything in data, indicating that the caller will need to query the system state on their own. (cherry picked from commit dbcaac13e49c88d1c077f34f56dd2b7ba77a145a) --- lib/libsys/kqueue.2 | 41 +++++++++++------------------ sys/kern/kern_event.c | 71 +++++++++++---------------------------------------- sys/kern/kern_jail.c | 4 +-- sys/sys/event.h | 17 ++++++------ 4 files changed, 39 insertions(+), 94 deletions(-) diff --git a/lib/libsys/kqueue.2 b/lib/libsys/kqueue.2 index e413f7d4fbca..aafb5317c5e0 100644 --- a/lib/libsys/kqueue.2 +++ b/lib/libsys/kqueue.2 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd September 4, 2025 +.Dd September 11, 2025 .Dt KQUEUE 2 .Os .Sh NAME @@ -614,41 +614,30 @@ The process ID will be stored in If more than one process has attached since the last call to .Fn kevent , .Va data -will contain the most recently attached process ID, -with -.Dv NOTE_JAIL_ATTACH_MULTI -set in -.Va fflags . +will be zero. .It Dv NOTE_JAIL_REMOVE The jail has been removed. .It Dv NOTE_JAIL_CHILD A child of the watched jail has been created. -.It Dv NOTE_TRACK -Follow child jails created under this jail. -Register a new kevent to monitor the child jail using the same -.Va fflags -as the original event. -The child jail will signal an event with -.Dv NOTE_CHILD -set in -.Va fflags -and the parent JID in +Its jail ID will be stored in .Va data . -.Pp -If registering a new kevent fails -.Pq usually due to resource limitations , -it will signal an event with -.Dv NOTE_TRACKERR -set in -.Va fflags , -and the child jail will not signal a -.Dv NOTE_CHILD -event. +If more than one jail has been created since the last call to +.Fn kevent , +.Va data +will be zero. .El .Pp On return, .Va fflags contains the events which triggered the filter. +It will also contain +.Dv NOTE_JAIL_MULTI +if more than one +.Dv NOTE_JAIL_ATTACH +or +.Dv NOTE_JAIL_CHILD +event has been received since the last call to +.Fn kevent . .It Dv EVFILT_TIMER Establishes an arbitrary timer identified by .Va ident . diff --git a/sys/kern/kern_event.c b/sys/kern/kern_event.c index 501adc151d44..8d1ff313735b 100644 --- a/sys/kern/kern_event.c +++ b/sys/kern/kern_event.c @@ -539,8 +539,7 @@ filt_proc(struct knote *kn, long hint) * process forked. Additionally, for each knote attached to the * parent, check whether user wants to track the new process. If so * attach a new knote to it, and immediately report an event with the - * child's pid. This is also called on jail creation, which is treated - * the same way by jail events. + * child's pid. */ void knote_fork(struct knlist *list, int pid) @@ -567,8 +566,6 @@ knote_fork(struct knlist *list, int pid) /* * The same as knote(), activate the event. */ - _Static_assert(NOTE_JAIL_CHILD == NOTE_FORK, - "NOTE_JAIL_CHILD should be the same as NOTE_FORK"); if ((kn->kn_sfflags & NOTE_TRACK) == 0) { if (kn->kn_fop->f_event(kn, NOTE_FORK)) KNOTE_ACTIVATE(kn, 1); @@ -632,30 +629,11 @@ int filt_jailattach(struct knote *kn) { struct prison *pr; - bool immediate; - immediate = false; if (kn->kn_id == 0) { /* Let jid=0 watch the current prison (including prison0). */ pr = curthread->td_ucred->cr_prison; mtx_lock(&pr->pr_mtx); - } else if (kn->kn_flags & (EV_FLAG1 | EV_FLAG2)) { - /* - * The kernel registers prisons before they are valid, - * so prison_find_child will fail. - */ - TAILQ_FOREACH(pr, &allprison, pr_list) { - if (pr->pr_id < kn->kn_id) - continue; - if (pr->pr_id > kn->kn_id) { - pr = NULL; - break; - } - mtx_lock(&pr->pr_mtx); - break; - } - if (pr == NULL) - return (ENOENT); } else { sx_slock(&allprison_lock); pr = prison_find_child(curthread->td_ucred->cr_prison, @@ -670,32 +648,7 @@ filt_jailattach(struct knote *kn) } kn->kn_ptr.p_prison = pr; kn->kn_flags |= EV_CLEAR; - - /* - * Internal flag indicating registration done by kernel for the - * purposes of getting a NOTE_CHILD notification. - */ - if (kn->kn_flags & EV_FLAG2) { - kn->kn_flags &= ~EV_FLAG2; - kn->kn_data = kn->kn_sdata; /* parent id */ - kn->kn_fflags = NOTE_CHILD; - kn->kn_sfflags &= ~NOTE_JAIL_CTRLMASK; - immediate = true; /* Force immediate activation of child note. */ - } - /* - * Internal flag indicating registration done by kernel (for other than - * NOTE_CHILD). - */ - if (kn->kn_flags & EV_FLAG1) { - kn->kn_flags &= ~EV_FLAG1; - } - knlist_add(pr->pr_klist, kn, 1); - - /* Immediately activate any child notes. */ - if (immediate) - KNOTE_ACTIVATE(kn, 0); - mtx_unlock(&pr->pr_mtx); return (0); } @@ -720,18 +673,24 @@ filt_jail(struct knote *kn, long hint) if (pr == NULL) /* already activated, from attach filter */ return (0); - /* Mask off extra data. */ - event = (u_int)hint & NOTE_JAIL_CTRLMASK; + /* + * Mask off extra data. In the NOTE_JAIL_CHILD case, that's + * everything except the NOTE_JAIL_CHILD bit itself, since a + * JID is any positive integer. + */ + event = ((u_int)hint & NOTE_JAIL_CHILD) ? NOTE_JAIL_CHILD : + (u_int)hint & NOTE_JAIL_CTRLMASK; /* If the user is interested in this event, record it. */ if (kn->kn_sfflags & event) kn->kn_fflags |= event; - /* Report the attached process id. */ - if (event == NOTE_JAIL_ATTACH) { + /* Report the created jail id or attached process id. */ + if (event == NOTE_JAIL_CHILD || event == NOTE_JAIL_ATTACH) { if (kn->kn_data != 0) - kn->kn_fflags |= NOTE_JAIL_ATTACH_MULTI; - kn->kn_data = hint & NOTE_JAIL_DATAMASK; + kn->kn_fflags |= NOTE_JAIL_MULTI; + kn->kn_data = (kn->kn_fflags & NOTE_JAIL_MULTI) ? 0U : + (u_int)hint & ~event; } /* Prison is gone, so flag the event as finished. */ @@ -1729,8 +1688,8 @@ findkn: /* * If possible, find an existing knote to use for this kevent. */ - if ((kev->filter == EVFILT_PROC || kev->filter == EVFILT_JAIL) - && (kev->flags & (EV_FLAG1 | EV_FLAG2)) != 0) { + if (kev->filter == EVFILT_PROC && + (kev->flags & (EV_FLAG1 | EV_FLAG2)) != 0) { /* This is an internal creation of a process tracking * note. Don't attempt to coalesce this with an * existing note. diff --git a/sys/kern/kern_jail.c b/sys/kern/kern_jail.c index 3d18b03119ff..d90ccf4a04c8 100644 --- a/sys/kern/kern_jail.c +++ b/sys/kern/kern_jail.c @@ -2221,9 +2221,7 @@ kern_jail_set(struct thread *td, struct uio *optuio, int flags) */ if (created) { sx_assert(&allprison_lock, SX_XLOCKED); - mtx_lock(&ppr->pr_mtx); - knote_fork(ppr->pr_klist, pr->pr_id); - mtx_unlock(&ppr->pr_mtx); + prison_knote(ppr, NOTE_JAIL_CHILD | pr->pr_id); mtx_lock(&pr->pr_mtx); drflags |= PD_LOCKED; pr->pr_state = PRISON_STATE_ALIVE; diff --git a/sys/sys/event.h b/sys/sys/event.h index f161d2c938c1..91fbaa4834f7 100644 --- a/sys/sys/event.h +++ b/sys/sys/event.h @@ -205,19 +205,18 @@ struct freebsd11_kevent32 { #define NOTE_PCTRLMASK 0xf0000000 /* mask for hint bits */ #define NOTE_PDATAMASK 0x000fffff /* mask for pid */ +/* additional flags for EVFILT_PROC */ +#define NOTE_TRACK 0x00000001 /* follow across fork/create */ +#define NOTE_TRACKERR 0x00000002 /* could not track child */ +#define NOTE_CHILD 0x00000004 /* am a child process */ + /* data/hint flags for EVFILT_JAIL */ -#define NOTE_JAIL_SET 0x80000000 /* jail was modified */ -#define NOTE_JAIL_CHILD 0x40000000 /* child jail was created */ +#define NOTE_JAIL_CHILD 0x80000000 /* child jail was created */ +#define NOTE_JAIL_SET 0x40000000 /* jail was modified */ #define NOTE_JAIL_ATTACH 0x20000000 /* jail was attached to */ #define NOTE_JAIL_REMOVE 0x10000000 /* jail was removed */ -#define NOTE_JAIL_ATTACH_MULTI 0x08000000 /* multiple procs attached */ +#define NOTE_JAIL_MULTI 0x08000000 /* multiple child or attach */ #define NOTE_JAIL_CTRLMASK 0xf0000000 /* mask for hint bits */ -#define NOTE_JAIL_DATAMASK 0x000fffff /* mask for pid */ - -/* additional flags for EVFILT_PROC and EVFILT_JAIL */ -#define NOTE_TRACK 0x00000001 /* follow across fork/create */ -#define NOTE_TRACKERR 0x00000002 /* could not track child */ -#define NOTE_CHILD 0x00000004 /* am a child process/jail */ /* additional flags for EVFILT_TIMER */ #define NOTE_SECONDS 0x00000001 /* data is seconds */ From nobody Mon Sep 15 04:04:18 2025 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 4cQBHQ2x3jz6803L; Mon, 15 Sep 2025 04:04:18 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQBHQ259Hz42c1; Mon, 15 Sep 2025 04:04:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757909058; 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=O2/2gBiE+llPpteg7Cbzx1xrm6XVAjHDh73z1fiQgEQ=; b=ZijFlgYp2lJcfWJTf+NlowZVKpSBvhW8shcIOGCdA8J/Zrvk3tM8SfVUIhUmsDyrhyMNj8 mACcowsCxRxXPkAef4CGhJTfdRJXkXIR+FcvyqD5V3a5cvSmnv5A8Z4/aXOhslmLY0X+7i tocEjAHIQtKu6aOEwTfvCBqdX5Y+NlB+yPEgTPRlGbaq652E2mzMaegPs0YzvyIjfcw1G4 S9l+e3Ngzhm70kcFxKVZxF1HbINHF+Qdj6nLIipGXH9smdXFROF22Hgcg+3XJb1yL4uPr/ wO/TzsRDI36L6t3Sew8Lxx6AjM3A0z7uxVJm5YDhPSkfDdwAWEXDnTCwBgHe9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757909058; 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=O2/2gBiE+llPpteg7Cbzx1xrm6XVAjHDh73z1fiQgEQ=; b=qfjAmVz0KpPKuxnM/Dxmmjn+FNppgJHKKi86yuzRqXgu5TnO5ZxyLaP4Zmdu1oL6VcC6wU tYbibW0vi4QppbOXCD41QibAXYEVVCgW9HYPyvmII0KH0V5Fg0Fpfg+9UAnTAKwHMn6tBY 65VhHxttOzge78e1MhByQfr9jqlHpK7qe2HEvjDhzVozDW0MqyHfTBLZ5VKJTkiMRHJMJM m8WW1L8paX09/ycUUIhSgUXbsdoDHp7758xKS2HtvqfnY7NTOzAzaLvMknvcW+nbI+kRrq jNvKtkAwthhpltJrEpjJB6iddWlkIZABYAeeKTDB7tTL8QTATx/gCoHnT0gbfg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757909058; a=rsa-sha256; cv=none; b=Sd2CZ9XF5/N7CRVhvHlH0vXF3cBE+dOz8Zxu2gE6JBOzIT+4T0H69AjTYYYOye6atxrbQ1 xMJL3tdkgv34Nva4J6RAceAJTboReApzlFL/jdn3vjJ2w/JH9tPUC1/o12OlWlaAkMM7fx EkcJ+lfZtc3i1FLo9h/Q3Y7an2J39JIjJUvtAE7ITsoTuMAWuvpUp3FHlaC65BvD3vI+my bZcnm9o6t0arfYOMJRjBqpnV85NEp+k3oER19UpB/xwH/hHdttzdZnVsCnAPG31Lre0C7f 9M23BYlUL1xZPH29wxrlTGaYjpTwPaVsrWKYLbO0Mdv70VwFGeyIXkAXlc0rrg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQBHQ1QhZzfkM; Mon, 15 Sep 2025 04:04:18 +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 58F44Ic9046700; Mon, 15 Sep 2025 04:04:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58F44IaE046697; Mon, 15 Sep 2025 04:04:18 GMT (envelope-from git) Date: Mon, 15 Sep 2025 04:04:18 GMT Message-Id: <202509150404.58F44IaE046697@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Jamie Gritton Subject: git: 9d7f89ef2607 - stable/15 - jaildesc: add kevent support 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: jamie X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 9d7f89ef26073bb56e6ec9c3370089067a71babc Auto-Submitted: auto-generated The branch stable/15 has been updated by jamie: URL: https://cgit.FreeBSD.org/src/commit/?id=9d7f89ef26073bb56e6ec9c3370089067a71babc commit 9d7f89ef26073bb56e6ec9c3370089067a71babc Author: Jamie Gritton AuthorDate: 2025-09-12 18:33:19 +0000 Commit: Jamie Gritton CommitDate: 2025-09-15 03:33:48 +0000 jaildesc: add kevent support Give jail descriptors the same kevent flags as jails. Also fix the event reporting in jails, where it was including data for events the user didn't ask for. (cherry picked from commit 66d8ffe3046ded1eb3f78599c6af8eb965482ef5) --- lib/libsys/kqueue.2 | 15 +++++- sys/kern/kern_event.c | 18 ++++--- sys/kern/kern_jail.c | 1 + sys/kern/kern_jaildesc.c | 138 ++++++++++++++++++++++++++++++++++++++++++++++- sys/sys/event.h | 5 +- sys/sys/jaildesc.h | 4 ++ 6 files changed, 168 insertions(+), 13 deletions(-) diff --git a/lib/libsys/kqueue.2 b/lib/libsys/kqueue.2 index aafb5317c5e0..96c9b0222a37 100644 --- a/lib/libsys/kqueue.2 +++ b/lib/libsys/kqueue.2 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd September 11, 2025 +.Dd September 12, 2025 .Dt KQUEUE 2 .Os .Sh NAME @@ -638,6 +638,19 @@ or .Dv NOTE_JAIL_CHILD event has been received since the last call to .Fn kevent . +.It Dv EVFILT_JAILDESC +Takes a jail descriptor returned by +.Xr jail_set 2 +or +.Xr jail_get 2 +as the identifier and the events to watch for in +.Va fflags , +and returns when the jail performs one or more of the requested events. +The events to monitor and the resulting +.Va fflags +are the same as those listed in +.Dv EVFILT_JAIL , +above. .It Dv EVFILT_TIMER Establishes an arbitrary timer identified by .Va ident . diff --git a/sys/kern/kern_event.c b/sys/kern/kern_event.c index 8d1ff313735b..57cbfb8a0361 100644 --- a/sys/kern/kern_event.c +++ b/sys/kern/kern_event.c @@ -51,6 +51,7 @@ #include #include #include +#include #include #include #include @@ -376,6 +377,7 @@ static struct { [~EVFILT_SENDFILE] = { &null_filtops }, [~EVFILT_EMPTY] = { &file_filtops, 1 }, [~EVFILT_JAIL] = { &jail_filtops, 1 }, + [~EVFILT_JAILDESC] = { &file_filtops, 1 }, }; /* @@ -682,15 +684,15 @@ filt_jail(struct knote *kn, long hint) (u_int)hint & NOTE_JAIL_CTRLMASK; /* If the user is interested in this event, record it. */ - if (kn->kn_sfflags & event) + if (kn->kn_sfflags & event) { kn->kn_fflags |= event; - - /* Report the created jail id or attached process id. */ - if (event == NOTE_JAIL_CHILD || event == NOTE_JAIL_ATTACH) { - if (kn->kn_data != 0) - kn->kn_fflags |= NOTE_JAIL_MULTI; - kn->kn_data = (kn->kn_fflags & NOTE_JAIL_MULTI) ? 0U : - (u_int)hint & ~event; + /* Report the created jail id or attached process id. */ + if (event == NOTE_JAIL_CHILD || event == NOTE_JAIL_ATTACH) { + if (kn->kn_data != 0) + kn->kn_fflags |= NOTE_JAIL_MULTI; + kn->kn_data = (kn->kn_fflags & NOTE_JAIL_MULTI) ? 0U : + (u_int)hint & ~event; + } } /* Prison is gone, so flag the event as finished. */ diff --git a/sys/kern/kern_jail.c b/sys/kern/kern_jail.c index d90ccf4a04c8..43035dc009b3 100644 --- a/sys/kern/kern_jail.c +++ b/sys/kern/kern_jail.c @@ -5371,6 +5371,7 @@ prison_knote(struct prison *pr, long hint) if (!locked) mtx_lock(&pr->pr_mtx); KNOTE_LOCKED(pr->pr_klist, hint); + jaildesc_knote(pr, hint); if (!locked) mtx_unlock(&pr->pr_mtx); } diff --git a/sys/kern/kern_jaildesc.c b/sys/kern/kern_jaildesc.c index c9e80f5d8941..3f322b271400 100644 --- a/sys/kern/kern_jaildesc.c +++ b/sys/kern/kern_jaildesc.c @@ -36,6 +36,7 @@ #include #include #include +#include #include #include #include @@ -46,6 +47,8 @@ MALLOC_DEFINE(M_JAILDESC, "jaildesc", "jail descriptors"); +static fo_poll_t jaildesc_poll; +static fo_kqfilter_t jaildesc_kqfilter; static fo_stat_t jaildesc_stat; static fo_close_t jaildesc_close; static fo_fill_kinfo_t jaildesc_fill_kinfo; @@ -56,8 +59,8 @@ static struct fileops jaildesc_ops = { .fo_write = invfo_rdwr, .fo_truncate = invfo_truncate, .fo_ioctl = invfo_ioctl, - .fo_poll = invfo_poll, - .fo_kqfilter = invfo_kqfilter, + .fo_poll = jaildesc_poll, + .fo_kqfilter = jaildesc_kqfilter, .fo_stat = jaildesc_stat, .fo_close = jaildesc_close, .fo_chmod = invfo_chmod, @@ -135,6 +138,7 @@ jaildesc_alloc(struct thread *td, struct file **fpp, int *fdp, int owning) finit(fp, priv_check_cred(fp->f_cred, PRIV_JAIL_SET) == 0 ? FREAD | FWRITE : FREAD, DTYPE_JAILDESC, jd, &jaildesc_ops); JAILDESC_LOCK_INIT(jd); + knlist_init_mtx(&jd->jd_selinfo.si_note, &jd->jd_lock); if (owning) jd->jd_flags |= JDF_OWNING; *fpp = fp; @@ -176,6 +180,36 @@ jaildesc_prison_cleanup(struct prison *pr) } } +/* + * Pass a note to all listening kqueues. + */ +void +jaildesc_knote(struct prison *pr, long hint) +{ + struct jaildesc *jd; + int prison_locked; + + if (!LIST_EMPTY(&pr->pr_descs)) { + prison_locked = mtx_owned(&pr->pr_mtx); + if (!prison_locked) + prison_lock(pr); + LIST_FOREACH(jd, &pr->pr_descs, jd_list) { + JAILDESC_LOCK(jd); + if (hint == NOTE_JAIL_REMOVE) { + jd->jd_flags |= JDF_REMOVED; + if (jd->jd_flags & JDF_SELECTED) { + jd->jd_flags &= ~JDF_SELECTED; + selwakeup(&jd->jd_selinfo); + } + } + KNOTE_LOCKED(&jd->jd_selinfo.si_note, hint); + JAILDESC_UNLOCK(jd); + } + if (!prison_locked) + prison_unlock(pr); + } +} + static int jaildesc_close(struct file *fp, struct thread *td) { @@ -223,12 +257,112 @@ jaildesc_close(struct file *fp, struct thread *td) } prison_free(pr); } + knlist_destroy(&jd->jd_selinfo.si_note); JAILDESC_LOCK_DESTROY(jd); free(jd, M_JAILDESC); } return (0); } +static int +jaildesc_poll(struct file *fp, int events, struct ucred *active_cred, + struct thread *td) +{ + struct jaildesc *jd; + int revents; + + revents = 0; + jd = fp->f_data; + JAILDESC_LOCK(jd); + if (jd->jd_flags & JDF_REMOVED) + revents |= POLLHUP; + if (revents == 0) { + selrecord(td, &jd->jd_selinfo); + jd->jd_flags |= JDF_SELECTED; + } + JAILDESC_UNLOCK(jd); + return (revents); +} + +static void +jaildesc_kqops_detach(struct knote *kn) +{ + struct jaildesc *jd; + + jd = kn->kn_fp->f_data; + knlist_remove(&jd->jd_selinfo.si_note, kn, 0); +} + +static int +jaildesc_kqops_event(struct knote *kn, long hint) +{ + struct jaildesc *jd; + u_int event; + + jd = kn->kn_fp->f_data; + if (hint == 0) { + /* + * Initial test after registration. Generate a + * NOTE_JAIL_REMOVE in case the prison already died + * before registration. + */ + event = jd->jd_flags & JDF_REMOVED ? NOTE_JAIL_REMOVE : 0; + } else { + /* + * Mask off extra data. In the NOTE_JAIL_CHILD case, + * that's everything except the NOTE_JAIL_CHILD bit + * itself, since a JID is any positive integer. + */ + event = ((u_int)hint & NOTE_JAIL_CHILD) ? NOTE_JAIL_CHILD : + (u_int)hint & NOTE_JAIL_CTRLMASK; + } + + /* If the user is interested in this event, record it. */ + if (kn->kn_sfflags & event) { + kn->kn_fflags |= event; + /* Report the created jail id or attached process id. */ + if (event == NOTE_JAIL_CHILD || event == NOTE_JAIL_ATTACH) { + if (kn->kn_data != 0) + kn->kn_fflags |= NOTE_JAIL_MULTI; + kn->kn_data = (kn->kn_fflags & NOTE_JAIL_MULTI) ? 0U : + (u_int)hint & ~event; + } + } + + /* Prison is gone, so flag the event as finished. */ + if (event == NOTE_JAIL_REMOVE) { + kn->kn_flags |= EV_EOF | EV_ONESHOT; + if (kn->kn_fflags == 0) + kn->kn_flags |= EV_DROP; + return (1); + } + + return (kn->kn_fflags != 0); +} + +static const struct filterops jaildesc_kqops = { + .f_isfd = 1, + .f_detach = jaildesc_kqops_detach, + .f_event = jaildesc_kqops_event, +}; + +static int +jaildesc_kqfilter(struct file *fp, struct knote *kn) +{ + struct jaildesc *jd; + + jd = fp->f_data; + switch (kn->kn_filter) { + case EVFILT_JAILDESC: + kn->kn_fop = &jaildesc_kqops; + kn->kn_flags |= EV_CLEAR; + knlist_add(&jd->jd_selinfo.si_note, kn, 0); + return (0); + default: + return (EINVAL); + } +} + static int jaildesc_stat(struct file *fp, struct stat *sb, struct ucred *active_cred) { diff --git a/sys/sys/event.h b/sys/sys/event.h index 91fbaa4834f7..084eaafcbdc0 100644 --- a/sys/sys/event.h +++ b/sys/sys/event.h @@ -46,7 +46,8 @@ #define EVFILT_SENDFILE (-12) /* attached to sendfile requests */ #define EVFILT_EMPTY (-13) /* empty send socket buf */ #define EVFILT_JAIL (-14) /* attached to struct prison */ -#define EVFILT_SYSCOUNT 14 +#define EVFILT_JAILDESC (-15) /* attached to jail descriptors */ +#define EVFILT_SYSCOUNT 15 #if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L #define EV_SET(kevp_, a, b, c, d, e, f) do { \ @@ -210,7 +211,7 @@ struct freebsd11_kevent32 { #define NOTE_TRACKERR 0x00000002 /* could not track child */ #define NOTE_CHILD 0x00000004 /* am a child process */ -/* data/hint flags for EVFILT_JAIL */ +/* data/hint flags for EVFILT_JAIL and EVFILT_JAILDESC */ #define NOTE_JAIL_CHILD 0x80000000 /* child jail was created */ #define NOTE_JAIL_SET 0x40000000 /* jail was modified */ #define NOTE_JAIL_ATTACH 0x20000000 /* jail was attached to */ diff --git a/sys/sys/jaildesc.h b/sys/sys/jaildesc.h index 2451b04f7302..fda270d62e70 100644 --- a/sys/sys/jaildesc.h +++ b/sys/sys/jaildesc.h @@ -35,6 +35,7 @@ #ifdef _KERNEL #include +#include #include #include #include @@ -54,6 +55,7 @@ struct jaildesc { LIST_ENTRY(jaildesc) jd_list; /* (d,p) this prison's descs */ struct prison *jd_prison; /* (d) the prison */ struct mtx jd_lock; + struct selinfo jd_selinfo; /* (d) event notification */ unsigned jd_flags; /* (d) JDF_* flags */ }; @@ -69,6 +71,7 @@ struct jaildesc { /* * Flags for the jd_flags field */ +#define JDF_SELECTED 0x00000001 /* issue selwakeup() */ #define JDF_REMOVED 0x00000002 /* jail was removed */ #define JDF_OWNING 0x00000004 /* closing descriptor removes jail */ @@ -77,6 +80,7 @@ int jaildesc_find(struct thread *td, int fd, struct prison **prp, int jaildesc_alloc(struct thread *td, struct file **fpp, int *fdp, int owning); void jaildesc_set_prison(struct file *jd, struct prison *pr); void jaildesc_prison_cleanup(struct prison *pr); +void jaildesc_knote(struct prison *pr, long hint); #endif /* _KERNEL */ From nobody Mon Sep 15 04:04:19 2025 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 4cQBHS4dgvz67yYX; Mon, 15 Sep 2025 04:04:20 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQBHR4pLYz42pl; Mon, 15 Sep 2025 04:04:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757909059; 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=MYc6HaxLe749fbOs/vEyPnAmUpGWgCIJXAbwGj6aPRk=; b=UcpwCrodOT0SDIgB706Rtej3q9fCD1VP4+LQiClP2xj+r5FVa4ljQAB45jjAy9LSdZo3fV 1BDW3rJVcnfsPZS+XRfgCsg8YD4pBKq0G62ATS/QsRrZjgf5gXBjjm0RaxRRbKIkv8uC10 1GqNiMBhafV6McOUDEnkoC+w176xcHblmIE9LWfAwRcyIkDeLYMuDhb8BI6XKQrl4VIhjM 8IqVpcfkosGFOMvSUG7Z2WKB9YiGXDWgsjv6sRwSZ+L0tP6n+Z5fUiMB8TA5vjMHJ2yU+C U1+G08sGuPDdOI55h5JNuIGBUNh/3EWtLPvWdKr6GaZOPoJX8Fi15/9EQhTGpA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757909059; 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=MYc6HaxLe749fbOs/vEyPnAmUpGWgCIJXAbwGj6aPRk=; b=Mjb0pno2ZuEGu2YK9KIKQpKYchZUQ85MMdMPQ9/fexNyXApSyOG9R4v5chRpqaBAsqf0QO FKIUcLu+c1e1ateGDyiYg1WieiI96bHJKPpfKM61/Z6ztqrnweDmfyCm8Yx4oZpcBiyC3y p7lGWp3HA7oONMQMTLWiAYP1e53W+yADrmO453h98Dvs/tOfd2ciqf6l9r1BQ007i1bmU1 +xVP4CwveiIPyf6qY0mXz3Bp57ApAhCbbUABY1JP/ra8537UchsRFuz8SQQ2NvHEEf4kv2 ljW5+x+HHWiqg45E1lyjgd+WU1yHiADA/oSIDStN0Ja8j+6AIN40+u9CqFTv3Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757909059; a=rsa-sha256; cv=none; b=w6+0Bx8zXrSWIZzHRvNeN0Qza9zaLDxnXcANTKjXj/D0A4QViBxDzmLbtIJx5lnBKQMCWd CajRBwFLGWS5yjDiMj20RZpi4DFGJMaAieZBsgyzO6kAQ0RaFbuoVidKIVEfeC/MFhnRwE jemfKt7v/zd8HJR+bvbPzf5DvTutpG9gTdOrMmsIJ+0/Ik400btk+WNmKN5rI6L2b3Z8yb u7XpbiwzzUCMsExrzQfXZNMx0vFAH+cfhcM4l54wvN7yFQC0gEbUSM8YL45s1rTTKiORIx ACpSl6dFDfJ1qaQqZD3ZacC3lTAmjyA1XGCP7BWUA2NHTy+NJnEBaZ1Sit8Kgw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQBHR2NGtzfkN; Mon, 15 Sep 2025 04:04:19 +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 58F44JY4046739; Mon, 15 Sep 2025 04:04:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58F44J5w046736; Mon, 15 Sep 2025 04:04:19 GMT (envelope-from git) Date: Mon, 15 Sep 2025 04:04:19 GMT Message-Id: <202509150404.58F44J5w046736@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Jamie Gritton Subject: git: deaa609d065d - stable/15 - jaildesc: remove desc from the sysctl parameter list 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: jamie X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: deaa609d065d525a13392d09057afa237fbe4d68 Auto-Submitted: auto-generated The branch stable/15 has been updated by jamie: URL: https://cgit.FreeBSD.org/src/commit/?id=deaa609d065d525a13392d09057afa237fbe4d68 commit deaa609d065d525a13392d09057afa237fbe4d68 Author: Jamie Gritton AuthorDate: 2025-09-13 22:30:14 +0000 Commit: Jamie Gritton CommitDate: 2025-09-15 03:34:00 +0000 jaildesc: remove desc from the sysctl parameter list Like lastjid, desc should count as a pseudo-parameter. The difference lies entirely in the security.jail.param sysctls, which list all of the jail parameters. Since desc opens and returns a file descriptor, it has no place in such uses as "jls all." Like lastjid, it's still recognized by the kernel if passed in/out, and hard-coded into libjail so it can be recognized there. (cherry picked from commit e75dda31c1eead9ad40580bd8fec17f2bbf55a21) --- lib/libjail/jail.c | 10 +++++++++- sys/kern/kern_jail.c | 1 - 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/lib/libjail/jail.c b/lib/libjail/jail.c index f761bc6993e5..ad3348af0d2d 100644 --- a/lib/libjail/jail.c +++ b/lib/libjail/jail.c @@ -920,13 +920,21 @@ jailparam_type(struct jailparam *jp) } desc; int mib[CTL_MAXNAME]; - /* The "lastjid" parameter isn't real. */ + /* + * Some pseudo-parameters don't show up in the sysctl + * parameter list. + */ name = jp->jp_name; if (!strcmp(name, "lastjid")) { jp->jp_valuelen = sizeof(int); jp->jp_ctltype = CTLTYPE_INT | CTLFLAG_WR; return (0); } + if (!strcmp(name, "desc")) { + jp->jp_valuelen = sizeof(int); + jp->jp_ctltype = CTLTYPE_INT | CTLFLAG_RW; + return (0); + } /* Find the sysctl that describes the parameter. */ mib[0] = 0; diff --git a/sys/kern/kern_jail.c b/sys/kern/kern_jail.c index 43035dc009b3..a75ba89d2a7e 100644 --- a/sys/kern/kern_jail.c +++ b/sys/kern/kern_jail.c @@ -4935,7 +4935,6 @@ sysctl_jail_param(SYSCTL_HANDLER_ARGS) * jail creation time but cannot be changed in an existing jail. */ SYSCTL_JAIL_PARAM(, jid, CTLTYPE_INT | CTLFLAG_RDTUN, "I", "Jail ID"); -SYSCTL_JAIL_PARAM(, desc, CTLTYPE_INT | CTLFLAG_RW, "I", "Jail descriptor"); SYSCTL_JAIL_PARAM(, parent, CTLTYPE_INT | CTLFLAG_RD, "I", "Jail parent ID"); SYSCTL_JAIL_PARAM_STRING(, name, CTLFLAG_RW, MAXHOSTNAMELEN, "Jail name"); SYSCTL_JAIL_PARAM_STRING(, path, CTLFLAG_RDTUN, MAXPATHLEN, "Jail root path"); From nobody Mon Sep 15 04:05:24 2025 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 4cQBJj3p13z67yxQ; Mon, 15 Sep 2025 04:05:25 +0000 (UTC) (envelope-from jamie@gritton.org) Received: from m2.gritton.org (gritton.org [67.43.236.212]) (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 mx1.freebsd.org (Postfix) with ESMTPS id 4cQBJj1Gd3z43Qc; Mon, 15 Sep 2025 04:05:25 +0000 (UTC) (envelope-from jamie@gritton.org) Authentication-Results: mx1.freebsd.org; none Received: from gritton.org (localgritton [127.0.0.212]) by m2.gritton.org (Postfix) with ESMTPSA id AE20F7F295; Sun, 14 Sep 2025 21:05:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=gritton.org; s=m2; t=1757909124; bh=JpVodKY+lLtlGHxKF0kflf7hUCo3OK9kNFzGcahxP50=; h=Date:From:To:Cc:Subject:In-Reply-To:References; b=J9c67R0bC5k3Cj9FUfVKCXRu2vSLeXdFQ0wgxhkB/Jc1x6Fe2wxihtxiJFjnoKIzZ jyiGLNuNRIE0iQ4wWOkp3teuIxfo5LEF6L25gJMdaNOIAJgeLYF5AQxDoUaCRo6Jg/ kQdsro1Dnlof5uYRaOdZ/D8nsAXBdLhEtTIyi8yc= 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 Date: Sun, 14 Sep 2025 21:05:24 -0700 From: James Gritton To: Kyle Evans Cc: "Danilo G. Baio" , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: dbaaadd4373a - main - jls: minor simplification to arg handling In-Reply-To: References: <202507260314.56Q3E5cY002869@gitrepo.freebsd.org> <54e7f090-c031-47f2-bc51-c020a77ab00a@app.fastmail.com> Message-ID: X-Sender: jamie@gritton.org Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4cQBJj1Gd3z43Qc On 2025-09-14 19:30, Kyle Evans wrote: > On 9/14/25 20:00, Kyle Evans wrote: >> On 9/14/25 19:14, Danilo G. Baio wrote: >>> >>> >>> On Sat, Jul 26, 2025, at 00:14, Kyle Evans wrote: >>>> The branch main has been updated by kevans: >>>> >>>> URL: >>>> https://cgit.FreeBSD.org/src/commit/?id=dbaaadd4373a725950ad11e578dab61537b7c4f2 >>>> >>>> commit dbaaadd4373a725950ad11e578dab61537b7c4f2 >>>> Author:     Kyle Evans >>>> AuthorDate: 2025-07-26 03:13:41 +0000 >>>> Commit:     Kyle Evans >>>> CommitDate: 2025-07-26 03:13:41 +0000 >>>> >>>>      jls: minor simplification to arg handling >>>>      It's easier to reason about the state of argc/argv if we just >>>> augment >>>>      them by optind after our getopt() loop. >>>>      No functional change, but this sets the stage for another >>>> change to add >>>>      a `-c` mode to (c)heck for the existence of a jail quietly >>>> without >>>>      the caller having to worry about spurious output. >>>>      Reviewed by:    jamie >>>>      Differential Revision:  https://reviews.freebsd.org/D51540 >>>> --- >>>>   usr.sbin/jls/jls.c | 10 ++++++---- >>>>   1 file changed, 6 insertions(+), 4 deletions(-) >>>> >>>> diff --git a/usr.sbin/jls/jls.c b/usr.sbin/jls/jls.c >>>> index bd193a69c458..a1d1716713aa 100644 >>>> --- a/usr.sbin/jls/jls.c >>>> +++ b/usr.sbin/jls/jls.c >>>> @@ -140,8 +140,11 @@ main(int argc, char **argv) >>>>       ip4_ok = feature_present("inet"); >>>>   #endif >>>> >>>> +    argc -= optind; >>>> +    argv += optind; >>>> + >>>>       /* Add the parameters to print. */ >>>> -    if (optind == argc) { >>>> +    if (argc == 0) { >>>>           if (pflags & (PRINT_HEADER | PRINT_NAMEVAL)) >>>>               add_param("all", NULL, (size_t)0, NULL, JP_USER); >>>>           else if (pflags & PRINT_VERBOSE) { >>>> @@ -179,9 +182,8 @@ main(int argc, char **argv) >>>>           } >>>>       } else { >>>>           pflags &= ~PRINT_VERBOSE; >>>> -        while (optind < argc) >>>> -            add_param(argv[optind++], NULL, (size_t)0, NULL, >>>> -                JP_USER); >>>> +        for (i = 0; i < argc; i++) >>>> +            add_param(argv[i], NULL, (size_t)0, NULL, JP_USER); >>>>       } >>>> >>>>       if (pflags & PRINT_SKIP) { >>> >>> >>> Hi, >>> >>> Just replying to one of the recent changes on `jls`. >>> >>> We use `jls -n` in many scripts, and recently, it stopped working. >>> >>> The last build that was working for us: >>> FreeBSD 15.0-CURRENT #0 main-n278879-4be9c6f38e78: Sat Jul 19 >>> 13:19:25 UTC 2025 >>> >>> We are now encountering the following issue on this build: >>> FreeBSD 16.0-CURRENT #0 main-n280141-5e82eeccd252: Sat Sep  6 >>> 05:27:34 UTC 2025 >>> >>> $ jls -n >>> desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable >>> ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 >>> osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable >>> sysvsem=disable sysvshm=disable vnet=disable zfs=disable >>> allow.noadjtime allow.nochflags allow.noextattr allow.nomlock >>> allow.nomount allow.mount.nodevfs allow.mount.nofdescfs >>> allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs >>> allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets >>> allow.noread_msgbuf allow.noreserved_ports allow.norouting >>> allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuser >>> allow.nosysvipc allow.nounprivileged_parent_tampering >>> allow.nounprivileged_proc_debug children.cur=0 children.max=0 >>> cpuset.id=0 host.domainname="" host.hostid=0 host.hostname="" >>> host.hostuuid="" >>> ip4.addr=0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0 >>> ip4.nosaddrsel ip6.addr=::,::,::,::,::,:: ip6.nosaddrsel >>> zfs.mount_snapshot=0 >>> desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable >>> ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 >>> osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable >>> sysvsem=disable sysvshm=disable vnet=disable zfs=disable >>> allow.noadjtime allow.nochflags allow.noextattr allow.nomlock >>> allow.nomount allow.mount.nodevfs allow.mount.nofdescfs >>> allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs >>> allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets >>> allow.noread_msgbuf allow.noreserved_ports allow.norouting >>> allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuser >>> allow.nosysvipc allow.nounprivileged_parent_tampering >>> allow.nounprivileged_proc_debug children.cur=0 children.max=0 >>> cpuset.id=0 host.domainname="" host.hostid=0 host.hostname="" >>> host.hostuuid="" >>> ip4.addr=0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0 >>> ip4.nosaddrsel ip6.addr=::,::,::,::,::,:: ip6.nosaddrsel >>> zfs.mount_snapshot=0 >>> desc=0 devfs_ruleset=0 nodying enforce_statfs=0 env="" host=disable >>> ip4=disable ip6=disable jid=0 meta="" name="" osreldate=0 >>> osrelease="" parent=0 path="" nopersist securelevel=0 sysvmsg=disable >>> sysvsem=disable sysvshm=disable vnet=disable zfs=disable >>> allow.noadjtime allow.nochflags allow.noextattr allow.nomlock >>> allow.nomount allow.mount.nodevfs allow.mount.nofdescfs >>> allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs >>> allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets >>> allow.noread_msgbuf allow.noreserved_ports allow.norouting >>> allow.noset_hostname allow.nosettime >>> [...] >>> infinite loop >>> >> >> Adding jamie@, neither of the changes to jls(1) should've caused this, >> as far as I can reason about (and I haven't observed this here, yet).  >> This looks like a failure to terminate the print_jail loop at the end? > > I still can't functionally update, but looking at the recent jaildesc > work, I wonder > if this is a side effect that has since been fixed in > e75dda31c1eead9ad40580bd8 by > removing the "desc" parameter. It would have been included in > jailparam_all(), and > I wonder if that somehow broke jls-style iteration? I've verified that the patch stocks the problem, and took the liberty of MFCing it a day early. - Jamie From nobody Mon Sep 15 08:53:53 2025 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 4cQJjY31QYz68HQy; Mon, 15 Sep 2025 08:53:53 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQJjY2LFhz3c0Y; Mon, 15 Sep 2025 08:53:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757926433; 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=uhzHiLap/N67kzfqtPCYLFhB94M9q5JlnYy/M+2cvtE=; b=UUEjXniimUu479Ne/444rNSCR4dCMA2YcqCvNOn3Tx+6jJKlTL/T79Zu2pYoonc7vQyfh5 ySYyqtm2rEX88jyeUoKMDkBPZXoXi3+vMCabN2bV8oGFfMvyv8Uo4nOGGZdJoNGzhGYlRs zYHBx1fCvUys/OhtolT757XSwxvbB0D8J3UI9/Bi6GZVkjhS9BFk8hvgBPkYfQOauVvG9p Nq/FtsTxliwoQwPdSfM6gA5giq7Fi6mh87Xt+s1QI7Dac/9/AicuS7uMeQX7IKnZrN4uSJ G35a9sUy4C7e+KyXyzKLIgmrmrWQXWGQYLo1hsZXgyLD89ZcD0f6pbUAmrHjaw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757926433; 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=uhzHiLap/N67kzfqtPCYLFhB94M9q5JlnYy/M+2cvtE=; b=e4qz8MELOFaRGE1mxJg5KLC8Jc/85wuGZp2G5aBG15SHzSIpCocLdIRok7N1MLCqJuukFV fJxTcruyS83XcW4jG1N6AyfQi25enON4ZmnbRa/34Olg+irGii1d6bssyA/+Oxgual0cAV d2zUaDXkxeF4qZGwXHt7DTc6lE0Flhdt4x7AfP481+ME7EBonNdXzk0e8mjaesuDvvu2vo czrvUsk9PsGX9d4ROoomVOh8uZYNYXIr0DcH+NJpZXvmXZgQ36BCMz+lpCl5qTyRazn/24 CHO3jjN2R34mj2EdY26EbQoDskuUd6GERjrzxc4ha1krkxbfpQGanmwL6MJpUg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757926433; a=rsa-sha256; cv=none; b=sPfLUG46XwaB3HqD7auRQnd6DDz2Wr3+ysb87Wsffx2NJAQHCKRpR2O9LaSDaAEaBv/V5R l6ZNAviZacxb4d0uR9GEActVmjmq8mj5H/ugrKjckv++bQAct1LmvrBRTY6aGr89n7Lkty fo3QKG0RTZeNIh5HxDRf3s1GZzSwdYFNln5cphmN5hvV1QmmFVRy7wMmA+I0UTWoqbp+4N AE5vNrB9yuFY1JAmv8GTdl4DiUqE3sH4R/ZPLFBrspoPvBRoiszV68z7GBuUEtOMLEsvht PdHwM2+qRkBaqEI1vhtx4SdpighVNbLUnLMXa87tHBim+RsOvtN7VWcHFNRpaA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQJjY1nq2znSK; Mon, 15 Sep 2025 08:53:53 +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 58F8rrYP088308; Mon, 15 Sep 2025 08:53:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58F8rrtK088305; Mon, 15 Sep 2025 08:53:53 GMT (envelope-from git) Date: Mon, 15 Sep 2025 08:53:53 GMT Message-Id: <202509150853.58F8rrtK088305@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Peter Holm Subject: git: 7780766b403d - main - stress2: Do not exit the test program without clearing the trace flags Discussed with: kib 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: pho X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7780766b403dd00b04cc597b44b6358010986616 Auto-Submitted: auto-generated The branch main has been updated by pho: URL: https://cgit.FreeBSD.org/src/commit/?id=7780766b403dd00b04cc597b44b6358010986616 commit 7780766b403dd00b04cc597b44b6358010986616 Author: Peter Holm AuthorDate: 2025-09-15 08:48:01 +0000 Commit: Peter Holm CommitDate: 2025-09-15 08:48:01 +0000 stress2: Do not exit the test program without clearing the trace flags Discussed with: kib --- tools/test/stress2/misc/kevent10.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/test/stress2/misc/kevent10.sh b/tools/test/stress2/misc/kevent10.sh index b7f74f487cec..cebbd040c37d 100755 --- a/tools/test/stress2/misc/kevent10.sh +++ b/tools/test/stress2/misc/kevent10.sh @@ -72,15 +72,15 @@ main(void) struct kevent events; char *fn = "/tmp/kevent10.trace"; - if (open(fn, O_RDWR | O_CREAT, 0666) == -1) - err(1, "%s", fn); + if (open(fn, O_RDWR | O_CREAT | O_TRUNC, 0666) == -1) + err(1, "open(%s)", fn); if (ktrace(fn, KTRFLAG_DESCEND | KTROP_SET, KTRFAC_GENIO, 0) == -1) err(1, "ktrace"); memset(&changes, 0, sizeof(struct kevent)); memset(&events, 0, sizeof(struct kevent)); if (kevent(0, &changes, -1, &events, 1, 0) == -1) - if (errno != EBADF) - err(1, "kevent"); + if (errno != EBADF && errno != EINVAL) + warn("kevent"); if (ktrace(fn, KTROP_CLEARFILE, KTRFAC_GENIO, 0) == -1) err(1, "ktrace clear"); From nobody Mon Sep 15 09:30:21 2025 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 4cQKWf1t54z68KbL; Mon, 15 Sep 2025 09:30:22 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQKWf1312z3gB8; Mon, 15 Sep 2025 09:30:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757928622; 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=buL/w5ofoNu2fnKMD3M6s8Qun1+XwtwmdmjpzGB2icw=; b=tFkcmuY4+yXYLqsWCxDHcSenqG3ofRAOQ7lMjzcrniNKhXwsAY/dIkcNav30+yIzYWx9k2 dO4R6VUMPySCAEhLqfJiVmJwrTOYIMwVRzoaVFn+WQJ8RUOXNBEtLlFKhZXOB3Hp12Uns+ TUZ3uXpCA5YUjUn4vHvKj/JgAud/N68WYmkBzcBZ2P3j5mEgFFkeEL5uWP92gC1MrbrpWQ KRW5GURClTjnHKqH11JPuMQ4Sr+J0O1RQ9wbxb8AUyaP6ejgu075D8eTCm8IZsE/WDPO2J vgbcQAR1XI5cGWv2uAdn6lxND7zbebLyOteEv/Yknrkt/YwVdAswfU+ZiKjQhw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757928622; 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=buL/w5ofoNu2fnKMD3M6s8Qun1+XwtwmdmjpzGB2icw=; b=snsZM66WD3Dc+zdxZPrUjKNXZF567lXSy8zvUEXVUS2k/aq2QwmfVuA59GUZtTui2aUWtI pKgavtUYmLdfa3z6a+yg9AY0DtLwk6Yun1As3qAz7iHOq47uvDVCRyubyeY+AtrK0RvnXR L6kWvF1foAvKbScG8spdfeAsab+2GGyMj28Y+bBv3b+dsoWE3UAoVZkpt/bQvkLIxftRur /OcEbv4/ffxzdVHdqQOkf6ZInfipLX+o6WIwmlz0v74EP6+YRsz5/zrdxStpLO8q/R6Ok9 EVjwU65FqdpwO9ULv67SQ0HUl3sCLHWlo+lQu4vJLRpvoqKJhPs4elZp/c1aMg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757928622; a=rsa-sha256; cv=none; b=O4Zbc1jTTPC37p0UTU2sI53pswmwJWK2zBYXdtucSh7/9GDb+sk7gH+LlS10Xah9GQ06NX G5o+pMdyDrVBrUzWIqKB60yfUVuEG6JMSbxdFcKK5sz9r1uj/UFgXajYjJokkzfuFknbE5 TC29sesDah873WGiWPPmw86Ra6yg0Nr8pi/wOUuynPzour6cbLuXGWlDWcpKRLyfYBCizO LFSyNkgjqzwR2eL5gdBkzWLzgf32TTIuFCsM8fXl1goQY9W6v1kxbrq3Y25pFueSc2QF2K Fg2/yyomgH+MQN3ePzFc07WqsnSFuQujbcTlRP0nfjvHrkT0pJE6dyACn23mqA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQKWf02SMzprN; Mon, 15 Sep 2025 09:30:22 +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 58F9ULst055230; Mon, 15 Sep 2025 09:30:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58F9ULsG055227; Mon, 15 Sep 2025 09:30:21 GMT (envelope-from git) Date: Mon, 15 Sep 2025 09:30:21 GMT Message-Id: <202509150930.58F9ULsG055227@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: ef2f36be8fce - main - jail.2: Mention EPERM is returned on open directories 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ef2f36be8fce8cf7a62ce7d33ab1c4a181fac3e2 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=ef2f36be8fce8cf7a62ce7d33ab1c4a181fac3e2 commit ef2f36be8fce8cf7a62ce7d33ab1c4a181fac3e2 Author: Olivier Certner AuthorDate: 2025-09-01 09:31:23 +0000 Commit: Olivier Certner CommitDate: 2025-09-15 09:29:44 +0000 jail.2: Mention EPERM is returned on open directories The manual page does not directly mention this reason for getting EPERM, instead referring the reader to chroot(2). We have had some questions about it recently, in part due to a bug (fixed), and this case is not an obvious permission/problem, so let's be more explicit. PR: 280809 Reviewed by: jamie MFC after: 3 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52319 --- lib/libsys/jail.2 | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/libsys/jail.2 b/lib/libsys/jail.2 index d3f871608c1d..ee4e5b03d38e 100644 --- a/lib/libsys/jail.2 +++ b/lib/libsys/jail.2 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd September 9, 2025 +.Dd September 15, 2025 .Dt JAIL 2 .Os .Sh NAME @@ -555,6 +555,9 @@ and call .Xr chroot 2 internally, so they can fail for all the same reasons. +In particular, they return the +.Bq Er EPERM +error when the process to join a jail has open directories. Please consult the .Xr chroot 2 manual page for details. From nobody Mon Sep 15 09:30:22 2025 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 4cQKWg1hpZz68KJb; Mon, 15 Sep 2025 09:30:23 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQKWg0YVdz3gF0; Mon, 15 Sep 2025 09:30:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757928623; 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=qNGFo8ln5KX1NMT2VLcO1+9GehxoQI/d2lLKT9Onn6s=; b=HIm1WB83FAXR4Y9F2fGkvDA8OZ2TwLIh1VP98fQ1QOCDvOgrttDqCExfrKDA05HsceBlWK rNwFlbB+bYS9OucrA+s+lr2GNEoaq8AncgBEsS/xqdYENjdAstawjRoQLe56EIbC4WSF/+ h8ZZbVZT19qijX71AZUvdmb+ZcR3oB0Z77cSA4j9SxwS4ghsnad62A+1rOEpBYzV42gmte ucvPwsx/z3gtR3tq4pebXdXoUC8OqOAOxt6ahRMSwgwzSPpXYqEFQuJxSTeg/wGovLuPdl ABHgLYQ3TCjl0rEKiK1So+8rvZCwzg7shc45qUSUjdSCMR9xaXbjPWtWuyHzgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757928623; 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=qNGFo8ln5KX1NMT2VLcO1+9GehxoQI/d2lLKT9Onn6s=; b=bsBKJdolK7XuRjyNoN0fApYpLcc5lc6Wk8YjzSm7uKD0xKvAC+jGT1oD28tlEJ0/Sdkv9s CCGYgtyh+V8WnlxFxfeoT1Od/8PJu9LMYLNFxb3RWamR5JW8xA3KOQLqhu7fpjPB8cUEBq bjQOPo3IjUDkpvQVxVKcccuQYn2bS1AlbJqN1W8fcnMxkyhoOLBN26nNMJggjyMUdfVn6R U5wCsNHMPICVA5UHckL+hDeN7/89y3LjlZ9e0D+UzP304KRBugITxCQwkMh3Hb0d2yWHe7 HoCFCOmp5pgcEyBEFf785efj24hkQfCAwSaG9iW3WznFNrXNMnZ0hOZMptZk8g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757928623; a=rsa-sha256; cv=none; b=qiTXWk2/NYyuEwl9QRhZpHi7oVtbL65a5iSCqpwwcUUAsTwByFJbDl1gc6oqdwNXfN5ypP iK0MnQQRjk4mbiFw0oO+sU44H8WTq9DLE9ffT15zM6Ut3vDxXaI3bukjm2Ut7E0+on0AS2 McV+QFLb+U4sXC1O7/YsE+1nE6Ck9jHZ1Blc9MZrOy92HdlAOR5JakZVGURSz01qGmbt5A a5f1tR0Rt+hyK+eaAEY9/BSmwRFEpdbRABngrPi97IgPVcoOgRLg2JCy//sLokJIG80l5F 8lAQttZrIwQWGMTlSfUV1qUx2UY7y9Qr7CubIoqUAtwSYsna0J+rE7XwEaVFxA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQKWf72YszpXm; Mon, 15 Sep 2025 09:30:22 +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 58F9UMnT055265; Mon, 15 Sep 2025 09:30:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58F9UM9C055262; Mon, 15 Sep 2025 09:30:22 GMT (envelope-from git) Date: Mon, 15 Sep 2025 09:30:22 GMT Message-Id: <202509150930.58F9UM9C055262@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 4894f5ba3943 - main - acpi: Fix build when `ACPI_DEBUG_OUTPUT` defined 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4894f5ba394306a75dbed9ed4377ab0eae75aede Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=4894f5ba394306a75dbed9ed4377ab0eae75aede commit 4894f5ba394306a75dbed9ed4377ab0eae75aede Author: Aymeric Wibo AuthorDate: 2025-09-15 09:17:57 +0000 Commit: Olivier Certner CommitDate: 2025-09-15 09:29:49 +0000 acpi: Fix build when `ACPI_DEBUG_OUTPUT` defined Reviewed by: olce Fixes: ce5e22b28ef6 ("acpi: Use sleep types defined in sys/power.h") Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52545 --- sys/dev/acpica/acpi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index 702e1ecb5340..175bfe835e6f 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -3425,7 +3425,7 @@ acpi_EnterSleepState(struct acpi_softc *sc, enum power_stype stype) enum acpi_sleep_state slp_state; int sleep_result; - ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, state); + ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, stype); if (stype <= POWER_STYPE_AWAKE || stype >= POWER_STYPE_COUNT) return_ACPI_STATUS (AE_BAD_PARAMETER); @@ -3939,7 +3939,7 @@ acpi_system_eventhandler_sleep(void *arg, enum power_stype stype) struct acpi_softc *sc = (struct acpi_softc *)arg; int ret; - ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, state); + ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, stype); /* Check if button action is disabled or unknown. */ if (stype == ACPI_STATE_UNKNOWN) From nobody Mon Sep 15 11:49:03 2025 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 4cQNc55tDLz67FMf; Mon, 15 Sep 2025 11:49:25 +0000 (UTC) (envelope-from dbaio@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNc556pzz42xR; Mon, 15 Sep 2025 11:49:25 +0000 (UTC) (envelope-from dbaio@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757936965; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=m+v1FfL7YSmcELVN+/L/+3bupzJdnCviVTNnQGHP9rU=; b=Mv1J0Lo9wYrNScYVxknOlWWb0au+8HpqP5NYSxW750gzR2r+UKXoBkIa8d+DAmqlTS5mpA d7HHdS7aynSaHFwMsed0KTbsDbzwun/odAFRo5qWVz3EnNvKj6C2o1/WYOMQQmIuZgLfuA XxgGS7bG1VcRy8UeufjLeDjbxW/24j+ngrV0i54yysIkakQlmFsGBJmHETay3xqiT6PxYo 9vkWAxfUTemE1GiaRyrwSlfWLsji4IPLRa3DTr/OIRKO3suD327698nhnwKCfBcGab7gtQ KMF5n4kBMuKPAzyDkazU0xC86Kvg4UAhfesr7XOPrN5afWRcKJxpUeKzwDjp2A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757936965; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=m+v1FfL7YSmcELVN+/L/+3bupzJdnCviVTNnQGHP9rU=; b=LgLYN8+WvQcW6fW24iWox6kZwqghIG+7LfImsBt7U0yEeaX6jrS+j+SMoyWHOeVlaFehKx UWKGrtNN2NhkK1byVndOQwGPhODOai/9BGsxw7KX3Td/G3WttXkt3PnQvzYWGQGx82BwLs g41Yy7GIZ2h6f9mfTf41Ax+B6387wSPAS1zG344Z/Qj7owWQvdTCiD8l5qg5YECwjjagTB i/M3P+xta6ZYkNqFVM7zzeVEbXJWpnEyBIg8SYo5HoF7URpNa4YoiMHK8+fr03dKxdjL2d SDX9T4Zi8aXIc1DcVpZKfwfXk/yItKrpADKZYuPBBc4kXgeBjvCdxPErm+hIZw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757936965; a=rsa-sha256; cv=none; b=Us1B3vt7ObduDO6eP0yiCPYMzDcxrE3cgpzXZEjtBn2lZFB1MbO5pbZV8aMoJ5fULzf+mn 3hWtE38KGotDcotuYQWzPCI3iCVjwAmL73DqhYPduHthJ/1ObzigyMrdJP6nYIUtcl19ro oiTdTzLyYFsw5EnM3yi5gItqTQkO3QIyX8H2BUom/OXNwZxyR9fonH/n1U3anwdlUOAAX6 dYdcVkZkM/LtHnmHPF31ykQh0TUW3FH4itESQ4nRTnXUoYkxTOLMxGXK8D/l4ar36zHYSF EZg7HV6ULg/S2QYFzbbh8Z8FmponUoeU/YeNjMB2rglMoJxbBqV/zdloAjeNLQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from fauth-a2-smtp.messagingengine.com (fauth-a2-smtp.messagingengine.com [103.168.172.201]) (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) (Authenticated sender: dbaio/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cQNc546jZz13XL; Mon, 15 Sep 2025 11:49:25 +0000 (UTC) (envelope-from dbaio@FreeBSD.org) Received: from phl-compute-02.internal (phl-compute-02.internal [10.202.2.42]) by mailfauth.phl.internal (Postfix) with ESMTP id B5AD5F40066; Mon, 15 Sep 2025 07:49:24 -0400 (EDT) Received: from phl-imap-15 ([10.202.2.104]) by phl-compute-02.internal (MEProxy); Mon, 15 Sep 2025 07:49:24 -0400 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtdeggdefjeeiudcutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpuffrtefokffrpgfnqfghnecuuegr ihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjug hrpefoggffhffvvefkjghfufgtgfesthhqredtredtjeenucfhrhhomhepfdffrghnihhl ohcuifdruceurghiohdfuceouggsrghioheshfhrvggvuefuffdrohhrgheqnecuggftrf grthhtvghrnhepgeeuheefudfffeevjeeikeejvdeuffetkeekieelueekheeuledtuefg vddufeeunecuffhomhgrihhnpehfrhgvvggsshgurdhorhhgnecuvehluhhsthgvrhfuih iivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepuggsrghiohdomhgvshhmthhprghu thhhphgvrhhsohhnrghlihhthidquddukedufeeluddvtddqvdeikedtvdejieekqdgusg grihhopeephfhrvggvuefuffdrohhrghesfhgrshhtmhgrihhlrdgtohhmpdhnsggprhgt phhtthhopeehpdhmohguvgepshhmthhpohhuthdprhgtphhtthhopeguvghvqdgtohhmmh hithhsqdhsrhgtqdgrlhhlsehfrhgvvggsshgurdhorhhgpdhrtghpthhtohepuggvvhdq tghomhhmihhtshdqshhrtgdqmhgrihhnsehfrhgvvggsshgurdhorhhgpdhrtghpthhtoh epkhgvvhgrnhhssehfrhgvvggsshgurdhorhhgpdhrtghpthhtohepshhrtgdqtghomhhm ihhtthgvrhhssehfrhgvvggsshgurdhorhhgpdhrtghpthhtohepjhgrmhhivgesghhrih htthhonhdrohhrgh X-ME-Proxy: Feedback-ID: i9d2946a4:Fastmail Received: by mailuser.phl.internal (Postfix, from userid 501) id 8C495780271; Mon, 15 Sep 2025 07:49:24 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface 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 X-ThreadId: Am1ynKg1lObs Date: Mon, 15 Sep 2025 08:49:03 -0300 From: "Danilo G. Baio" To: "James Gritton" , "Kyle Evans" Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Message-Id: In-Reply-To: References: <202507260314.56Q3E5cY002869@gitrepo.freebsd.org> <54e7f090-c031-47f2-bc51-c020a77ab00a@app.fastmail.com> Subject: Re: git: dbaaadd4373a - main - jls: minor simplification to arg handling Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On Mon, Sep 15, 2025, at 01:05, James Gritton wrote: > On 2025-09-14 19:30, Kyle Evans wrote: >> On 9/14/25 20:00, Kyle Evans wrote: >>> On 9/14/25 19:14, Danilo G. Baio wrote: >>>>=20 >>>>=20 >>>> On Sat, Jul 26, 2025, at 00:14, Kyle Evans wrote: >>>>> The branch main has been updated by kevans: >>>>>=20 >>>>> URL: >>>>> https://cgit.FreeBSD.org/src/commit/?id=3Ddbaaadd4373a725950ad11e5= 78dab61537b7c4f2 >>>>>=20 >>>>> commit dbaaadd4373a725950ad11e578dab61537b7c4f2 >>>>> Author:=C2=A0=C2=A0=C2=A0=C2=A0 Kyle Evans >>>>> AuthorDate: 2025-07-26 03:13:41 +0000 >>>>> Commit:=C2=A0=C2=A0=C2=A0=C2=A0 Kyle Evans >>>>> CommitDate: 2025-07-26 03:13:41 +0000 >>>>>=20 >>>>> =C2=A0=C2=A0=C2=A0=C2=A0 jls: minor simplification to arg handling >>>>> =C2=A0=C2=A0=C2=A0=C2=A0 It's easier to reason about the state of = argc/argv if we just=20 >>>>> augment >>>>> =C2=A0=C2=A0=C2=A0=C2=A0 them by optind after our getopt() loop. >>>>> =C2=A0=C2=A0=C2=A0=C2=A0 No functional change, but this sets the s= tage for another=20 >>>>> change to add >>>>> =C2=A0=C2=A0=C2=A0=C2=A0 a `-c` mode to (c)heck for the existence = of a jail quietly=20 >>>>> without >>>>> =C2=A0=C2=A0=C2=A0=C2=A0 the caller having to worry about spurious= output. >>>>> =C2=A0=C2=A0=C2=A0=C2=A0 Reviewed by:=C2=A0=C2=A0=C2=A0 jamie >>>>> =C2=A0=C2=A0=C2=A0=C2=A0 Differential Revision:=C2=A0 https://revi= ews.freebsd.org/D51540 >>>>> --- >>>>> =C2=A0 usr.sbin/jls/jls.c | 10 ++++++---- >>>>> =C2=A0 1 file changed, 6 insertions(+), 4 deletions(-) >>>>>=20 >>>>> diff --git a/usr.sbin/jls/jls.c b/usr.sbin/jls/jls.c >>>>> index bd193a69c458..a1d1716713aa 100644 >>>>> --- a/usr.sbin/jls/jls.c >>>>> +++ b/usr.sbin/jls/jls.c >>>>> @@ -140,8 +140,11 @@ main(int argc, char **argv) >>>>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ip4_ok =3D feature_present("inet"); >>>>> =C2=A0 #endif >>>>>=20 >>>>> +=C2=A0=C2=A0=C2=A0 argc -=3D optind; >>>>> +=C2=A0=C2=A0=C2=A0 argv +=3D optind; >>>>> + >>>>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 /* Add the parameters to print. */ >>>>> -=C2=A0=C2=A0=C2=A0 if (optind =3D=3D argc) { >>>>> +=C2=A0=C2=A0=C2=A0 if (argc =3D=3D 0) { >>>>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if (pflags = & (PRINT_HEADER | PRINT_NAMEVAL)) >>>>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 add_param("all", NULL, (size_t)0, NULL, JP_USER); >>>>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 else if (pf= lags & PRINT_VERBOSE) { >>>>> @@ -179,9 +182,8 @@ main(int argc, char **argv) >>>>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 } >>>>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 } else { >>>>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 pflags &=3D= ~PRINT_VERBOSE; >>>>> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 while (optind < argc) >>>>> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= add_param(argv[optind++], NULL, (size_t)0, NULL, >>>>> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0 JP_USER); >>>>> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 for (i =3D 0; i < argc= ; i++) >>>>> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= add_param(argv[i], NULL, (size_t)0, NULL, JP_USER); >>>>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 } >>>>>=20 >>>>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if (pflags & PRINT_SKIP) { >>>>=20 >>>>=20 >>>> Hi, >>>>=20 >>>> Just replying to one of the recent changes on `jls`. >>>>=20 >>>> We use `jls -n` in many scripts, and recently, it stopped working. >>>>=20 >>>> The last build that was working for us: >>>> FreeBSD 15.0-CURRENT #0 main-n278879-4be9c6f38e78: Sat Jul 19=20 >>>> 13:19:25 UTC 2025 >>>>=20 >>>> We are now encountering the following issue on this build: >>>> FreeBSD 16.0-CURRENT #0 main-n280141-5e82eeccd252: Sat Sep=C2=A0 6=20 >>>> 05:27:34 UTC 2025 >>>>=20 >>>> $ jls -n >>>> desc=3D0 devfs_ruleset=3D0 nodying enforce_statfs=3D0 env=3D"" host= =3Ddisable=20 >>>> ip4=3Ddisable ip6=3Ddisable jid=3D0 meta=3D"" name=3D"" osreldate=3D= 0=20 >>>> osrelease=3D"" parent=3D0 path=3D"" nopersist securelevel=3D0 sysvm= sg=3Ddisable=20 >>>> sysvsem=3Ddisable sysvshm=3Ddisable vnet=3Ddisable zfs=3Ddisable=20 >>>> allow.noadjtime allow.nochflags allow.noextattr allow.nomlock=20 >>>> allow.nomount allow.mount.nodevfs allow.mount.nofdescfs=20 >>>> allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs=20 >>>> allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets=20 >>>> allow.noread_msgbuf allow.noreserved_ports allow.norouting=20 >>>> allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuse= r=20 >>>> allow.nosysvipc allow.nounprivileged_parent_tampering=20 >>>> allow.nounprivileged_proc_debug children.cur=3D0 children.max=3D0=20 >>>> cpuset.id=3D0 host.domainname=3D"" host.hostid=3D0 host.hostname=3D= ""=20 >>>> host.hostuuid=3D""=20 >>>> ip4.addr=3D0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0=20 >>>> ip4.nosaddrsel ip6.addr=3D::,::,::,::,::,:: ip6.nosaddrsel=20 >>>> zfs.mount_snapshot=3D0 >>>> desc=3D0 devfs_ruleset=3D0 nodying enforce_statfs=3D0 env=3D"" host= =3Ddisable=20 >>>> ip4=3Ddisable ip6=3Ddisable jid=3D0 meta=3D"" name=3D"" osreldate=3D= 0=20 >>>> osrelease=3D"" parent=3D0 path=3D"" nopersist securelevel=3D0 sysvm= sg=3Ddisable=20 >>>> sysvsem=3Ddisable sysvshm=3Ddisable vnet=3Ddisable zfs=3Ddisable=20 >>>> allow.noadjtime allow.nochflags allow.noextattr allow.nomlock=20 >>>> allow.nomount allow.mount.nodevfs allow.mount.nofdescfs=20 >>>> allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs=20 >>>> allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets=20 >>>> allow.noread_msgbuf allow.noreserved_ports allow.norouting=20 >>>> allow.noset_hostname allow.nosettime allow.nosocket_af allow.nosuse= r=20 >>>> allow.nosysvipc allow.nounprivileged_parent_tampering=20 >>>> allow.nounprivileged_proc_debug children.cur=3D0 children.max=3D0=20 >>>> cpuset.id=3D0 host.domainname=3D"" host.hostid=3D0 host.hostname=3D= ""=20 >>>> host.hostuuid=3D""=20 >>>> ip4.addr=3D0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0,0.0.0.0=20 >>>> ip4.nosaddrsel ip6.addr=3D::,::,::,::,::,:: ip6.nosaddrsel=20 >>>> zfs.mount_snapshot=3D0 >>>> desc=3D0 devfs_ruleset=3D0 nodying enforce_statfs=3D0 env=3D"" host= =3Ddisable=20 >>>> ip4=3Ddisable ip6=3Ddisable jid=3D0 meta=3D"" name=3D"" osreldate=3D= 0=20 >>>> osrelease=3D"" parent=3D0 path=3D"" nopersist securelevel=3D0 sysvm= sg=3Ddisable=20 >>>> sysvsem=3Ddisable sysvshm=3Ddisable vnet=3Ddisable zfs=3Ddisable=20 >>>> allow.noadjtime allow.nochflags allow.noextattr allow.nomlock=20 >>>> allow.nomount allow.mount.nodevfs allow.mount.nofdescfs=20 >>>> allow.mount.nonullfs allow.mount.noprocfs allow.mount.notmpfs=20 >>>> allow.mount.nozfs allow.nonfsd allow.noquotas allow.noraw_sockets=20 >>>> allow.noread_msgbuf allow.noreserved_ports allow.norouting=20 >>>> allow.noset_hostname allow.nosettime >>>> [...] >>>> infinite loop >>>>=20 >>>=20 >>> Adding jamie@, neither of the changes to jls(1) should've caused thi= s,=20 >>> as far as I can reason about (and I haven't observed this here, yet)= .=C2=A0=20 >>> This looks like a failure to terminate the print_jail loop at the en= d? >>=20 >> I still can't functionally update, but looking at the recent jaildesc=20 >> work, I wonder >> if this is a side effect that has since been fixed in=20 >> e75dda31c1eead9ad40580bd8 by >> removing the "desc" parameter. It would have been included in=20 >> jailparam_all(), and >> I wonder if that somehow broke jls-style iteration? > > I've verified that the patch stocks the problem, and took the liberty = of=20 > MFCing it a day early. > > - Jamie Thanks to both of you for taking a look at this. --=20 Danilo G. Baio From nobody Mon Sep 15 11:54:19 2025 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 4cQNjl6sv0z67Fj5; Mon, 15 Sep 2025 11:54:19 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNjl5wwRz43vZ; Mon, 15 Sep 2025 11:54:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937259; 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=mzZvZKB+72y6P2sLYUtfaCnIrMt4IsK2xQNvd8KEVvQ=; b=Z/EQ9TBXaWy730hpuhk82B9zVKBm4Y7WW6u0vQph9BrCo9jFhh5htecafNIWNHtlSkoFvo bwkSXN8G1VXPV0EwAjrcjQaF6RJ+TEbhLfhWT6IDaELPg2ExYCIL97DNoU1DzHMlVn5nbl J4YGW1S+XByXyMGbTIoWusDHam2yGliGJtKgFeFH0JFAXGzxPuejl4af2DkqHwEaafM70e M/PkTdIWpTKAGc+fuHYKsScKjxoEHTxtLY2nRqXJr9cBHY4Gv6RaIYvBidJol082nEn8QV da3QHfUre8TVNJ2Bq6NWi/wP9mgQ/+IAHZFe5LQHXTvgxjyurSRQF4UTpwxROg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937259; 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=mzZvZKB+72y6P2sLYUtfaCnIrMt4IsK2xQNvd8KEVvQ=; b=mrv38Yu4MEt4km0WYtR8fXQLnh6DrO5DRXCR1vmbjHD9gdDYv9gsONv7+gHGXwBS+bd+hg DTYqmv3m3r1ZuGCzfHHZRTcYbExN5Vk86GZNCFn1UWqnMa2rQAm2uqQGQdw2yyh9hs/Jci Cx/ukEUv0mB8mg4ROhzoc/ozopYvG/5UIZIfnkrdlDaeG0c0aM9nc9n51ve9yWDxdAz2HF 4+8aNV5vXnL3X2QZ90C0QzZGCXJfELn9ox0o2LUuqBWUKBK58xGIE6MjZBCITuVMI5bJvO Cs1QyLnDpu7Oh7N/VKVdWdN/QwrjBPZEE7mv5SsDbsIHhm8Be7Ci9VlZpAyJyw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757937259; a=rsa-sha256; cv=none; b=NuFUB8T2kMvyJ2qJrgXlhYIzazK4NYF+JoulWZPxi9L1ljnrzq9yiwqum1Tkkvrm/EOJks Ep33BV0nvFlGsBDi+GuRLH4JxfMeG4P0ROmB4GxeT+vtBYRiItuGNcHcYntZxiVvrU8AMn FVYcwQzOVJwR8gDegUDtZ9io/xX6FhDzjVzdatOVV9hIEFnmJsVHsj/xMW4P7aSwzudqXY XRGE4yQpGogv5OLJlpO0MR1r6/7o5DurFbHMP2A0u7onRc6vT4429o8bLpdJxmyQWn6+t3 opQqTrcsQ3u6K4FWl8yEm05+fels6Exh8viiTd4pmvRKQhLPwcH4P8f+DQY7xA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQNjl5PRLztJP; Mon, 15 Sep 2025 11:54:19 +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 58FBsJDe025279; Mon, 15 Sep 2025 11:54:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FBsJks025276; Mon, 15 Sep 2025 11:54:19 GMT (envelope-from git) Date: Mon, 15 Sep 2025 11:54:19 GMT Message-Id: <202509151154.58FBsJks025276@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: c2d03a920ec7 - main - pfctl: fix anchortypes bounds test 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c2d03a920ec75c431f0c6af0ad9cb6ae43e48dda Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=c2d03a920ec75c431f0c6af0ad9cb6ae43e48dda commit c2d03a920ec75c431f0c6af0ad9cb6ae43e48dda Author: Kristof Provost AuthorDate: 2025-08-20 14:26:00 +0000 Commit: Kristof Provost CommitDate: 2025-09-15 09:32:33 +0000 pfctl: fix anchortypes bounds test found by "buffer overflow 'anchortypes' 10 <= 12" smatch error feedback and ok sashan@, ok miod@ on an earlier version Obtained from: OpenBSD, jsg , 730c5d0121 Sponsored by: Rubicon Communications, LLC ("Netgate") --- sbin/pfctl/pfctl_parser.c | 29 +++++++++++++++-------------- 1 file changed, 15 insertions(+), 14 deletions(-) diff --git a/sbin/pfctl/pfctl_parser.c b/sbin/pfctl/pfctl_parser.c index ce58e0636022..6df7af0cc574 100644 --- a/sbin/pfctl/pfctl_parser.c +++ b/sbin/pfctl/pfctl_parser.c @@ -853,21 +853,22 @@ print_rule(struct pfctl_rule *r, const char *anchor_call, int verbose, int numer if (verbose) printf("@%d ", r->nr); - if (r->action == PF_MATCH) - printf("match"); - else if (r->action > PF_NORDR) - printf("action(%d)", r->action); - else if (anchor_call[0]) { - p = strrchr(anchor_call, '/'); - if (p ? p[1] == '_' : anchor_call[0] == '_') - printf("%s", anchortypes[r->action]); - else - printf("%s \"%s\"", anchortypes[r->action], - anchor_call); + if (anchor_call[0]) { + if (r->action >= nitems(anchortypes)) { + printf("anchor(%d)", r->action); + } else { + p = strrchr(anchor_call, '/'); + if (p ? p[1] == '_' : anchor_call[0] == '_') + printf("%s", anchortypes[r->action]); + else + printf("%s \"%s\"", anchortypes[r->action], + anchor_call); + } } else { - printf("%s", actiontypes[r->action]); - if (r->natpass) - printf(" pass"); + if (r->action >= nitems(actiontypes)) + printf("action(%d)", r->action); + else + printf("%s", actiontypes[r->action]); } if (r->action == PF_DROP) { if (r->rule_flag & PFRULE_RETURN) From nobody Mon Sep 15 11:54:20 2025 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 4cQNjn0Tx2z67Flf; Mon, 15 Sep 2025 11:54:21 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNjm6vdDz442d; Mon, 15 Sep 2025 11:54:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937261; 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=dEyquR/JWZTUEgavovW0LVJK+hUo25vqb7bEGmp7NH8=; b=ec61XGX3uDo3zocY4w/yEWoKJAfL6veqdgVkIuUfkHh1Fq9qPFMCDjOAHNZ/vDjlafo2wm FySmMC+QsMV6h/FX5o/bNiR28VY9sl4nwhjD7oFwuch6ZKaYrs3WYz8x7QIfEM+cEkrtz0 8Db+GItAWcW1UeklpY219yvEGrLLg5ENIl124LYwlfdXYJPVq6ge85qQcEKPzkbCDwoNCs AAM/u3DQI4TWrYKnK0IGA5yDI8pzHYfupW8b361xG4aYeEqlEkA85gfBBJOUe/7oX1pgPE 1eEb4HElxikYZDVK/ZDoHOtCVVWLs/FakeAeHjqAOi1cYMlb5fT90vddr+hnmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937261; 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=dEyquR/JWZTUEgavovW0LVJK+hUo25vqb7bEGmp7NH8=; b=ZlO4xi+BDAGprqq98s0eO7vf5d+ogR06K5NVFcGrwNS1IxrQHYv2DBFaEoj7HkxJZ6pfPJ nt9D2lnP3Xo14jwPxmX2Jmp1BXpJPSWsnghf13xS9rzOL27AztITUUTgjBRxjdJ/n4vnkh K4p0ss/oPbfpFYidjLtIdEGn7KT+C4fUZt4Ha67Xd7W606AwBUrTUQVQhA2CI1KPN9DNyQ vWFWKY75JUmfBS+vhyGxfk2LDb0RiYEUmqv0OyKx28Lpm4GuhM2zacq7tMsdekdoAXANET Ja36ced8Irv3PgL3rnORnelljLAX40srCif/6F4Vijge6ZW/PS82lsqqCv/0pw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757937261; a=rsa-sha256; cv=none; b=bRaWj7KG5RDxLYlqxrCVD5v8D2lcEmDXBXUcz1Wg8qKsAbwTFZBRguKeSQBZspVw0x0PAM X9vu8EsGuCWzJLdi+wPpIL52BftjZJ41S8QkXF1AznFb/mzb5bGEu6rRAuXmDaQSGImvFZ 9OCxNsbDtBGMN16TjHlJpZqgvo0G+TlpJm83Aks7qcr3CXLBHUHxwUd+oONk65+H6glNSu rCIt7EkuEa4MuBHc6XO50OeCR/gHrlxGFowPUz8ernGdiMkwdagBri62czCD3XwQAZJ57z f1BngrIITgO/ugm8gtd0pu4xGN8jvmZPHPYV0sNJ+syBp71vun/+bDCbLu9iDQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQNjm6MVSztdT; Mon, 15 Sep 2025 11:54:20 +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 58FBsK1G025312; Mon, 15 Sep 2025 11:54:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FBsKYP025309; Mon, 15 Sep 2025 11:54:20 GMT (envelope-from git) Date: Mon, 15 Sep 2025 11:54:20 GMT Message-Id: <202509151154.58FBsKYP025309@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 79a0959affec - main - pfctl: add af-to and other missing action types in print_rule() 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 79a0959affecd2b055b9048002c0635018576103 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=79a0959affecd2b055b9048002c0635018576103 commit 79a0959affecd2b055b9048002c0635018576103 Author: Kristof Provost AuthorDate: 2025-08-20 14:28:24 +0000 Commit: Kristof Provost CommitDate: 2025-09-15 09:32:34 +0000 pfctl: add af-to and other missing action types in print_rule() Sponsored by: Rubicon Communications, LLC ("Netgate") --- sbin/pfctl/pfctl_parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/pfctl/pfctl_parser.c b/sbin/pfctl/pfctl_parser.c index 6df7af0cc574..a2b1e4d0841d 100644 --- a/sbin/pfctl/pfctl_parser.c +++ b/sbin/pfctl/pfctl_parser.c @@ -844,7 +844,7 @@ print_rule(struct pfctl_rule *r, const char *anchor_call, int verbose, int numer { static const char *actiontypes[] = { "pass", "block", "scrub", "no scrub", "nat", "no nat", "binat", "no binat", "rdr", "no rdr", - "", "", "match"}; + "synproxy drop", "defer", "match", "af-rt", "route-to" }; static const char *anchortypes[] = { "anchor", "anchor", "anchor", "anchor", "nat-anchor", "nat-anchor", "binat-anchor", "binat-anchor", "rdr-anchor", "rdr-anchor" }; From nobody Mon Sep 15 11:54:21 2025 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 4cQNjp5rs9z67Fj6; Mon, 15 Sep 2025 11:54:22 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNjp0f1Vz442r; Mon, 15 Sep 2025 11:54:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937262; 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=MYN7t59ouROpZFehitW/O94UfH7lDnWgUqZFrkHWqn8=; b=jXRcuMyRly6/5lzubgj0DojJE00LUg2WPSZ/Otd/P6YfbrLVgbpZXYso2Ows0oyQzhJgZn oUAWo4UeVBEgztMqF3nzA8b5v5esbMJt3Vbtque2qPKU55XcgzhvEDDMbEOXVeirL56lij IFXyPu/L5ZwZkjWPrylfMmOwrJRk2JTRM4uukZ3Culm0FJjfxpBDioICKO5OGZGQl5ZzRQ PxSHiMnxOnwe/KicDmE8rfZs7xl2Fx3QPpCKeCml7NPTr7v4myTEfzI3XdNuAPxt7WYtbv tAcTSFwy6y4IAAtDMgdoDLFvosB7Gr2/CZiCHutCMaLBMr9eDpcWCKu2bxR3AA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937262; 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=MYN7t59ouROpZFehitW/O94UfH7lDnWgUqZFrkHWqn8=; b=CGN1P+DjJRvfULhnC6uFRnRne+v+30VfxSLRTcnqgwKaSSoZAwN2L7fNUFXnsTmvLwsWkR dKW6nNxzCV6Vq6SOOUz/hs3FPAUiKda4CKuodTWwyRDBf+s4ZFiTdf2X+yRnU56G42aQz7 KnSW1vAh0FcI8is7HPXCBOy4D31x2jLzSmKTsj3O2arCNwFFtl0cgW8XcQXCxGEtMVxNsQ 3VyNEnyfYdZMPVxqr6Wa/+IiWnmDkzm5HkK8kFp5vKJR3oQteNECZM7XgRiYbxk/3jjqGW r7TmBBHsA+qV7zQzrzMcqsH860U+4+hNXRHboJ4HClgRXFD/FF0VjnjVgTuMmA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757937262; a=rsa-sha256; cv=none; b=WZ/sZGcpgtskW/Y30x2y44/oDyEGtJoEgOt813NWNFrmmziDJ7Kc0DMsf5SxwvH6GLgRHF 12QLBzIFDJD+SGJumtbeSIqL4hPIOR2r1aPNT2HEcL6GQCFN2dH+G/oIoJJYlJFITBLMO5 n+skJIVT/eq2O6RtbJIQalNMWQU7NLw1ilO1vF1R84viIXEsSaeZ7c1jdkZ1eUpTYVHUcO 81+1sulf4VSPx4UsmLJTZU92g9lozuWGihIg8rj3/JdBTeQxzc9LHOBfzBqxlwnI4OD2oG GB4p6zcUZxxn7FXEjPn5tKEkr7Ht0s6MSGtqJZuX8yi4WotonHB4EpkezS1XBQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQNjp0FlBztcT; Mon, 15 Sep 2025 11:54:22 +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 58FBsLDW025345; Mon, 15 Sep 2025 11:54:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FBsLTw025342; Mon, 15 Sep 2025 11:54:21 GMT (envelope-from git) Date: Mon, 15 Sep 2025 11:54:21 GMT Message-Id: <202509151154.58FBsLTw025342@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 864458ce5025 - main - pf.conf.5: document tcp.tsdiff 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 864458ce5025ab83c3d8cbaa514185b8cbc53acf Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=864458ce5025ab83c3d8cbaa514185b8cbc53acf commit 864458ce5025ab83c3d8cbaa514185b8cbc53acf Author: Kristof Provost AuthorDate: 2025-08-20 14:33:14 +0000 Commit: Kristof Provost CommitDate: 2025-09-15 09:32:34 +0000 pf.conf.5: document tcp.tsdiff from jesper wallin ok bluhm Obtained from: OpenBSD, jmc , 8c83d32726 Sponsored by: Rubicon Communications, LLC ("Netgate") --- share/man/man5/pf.conf.5 | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/share/man/man5/pf.conf.5 b/share/man/man5/pf.conf.5 index bdd8a843d72a..271a83a89ee5 100644 --- a/share/man/man5/pf.conf.5 +++ b/share/man/man5/pf.conf.5 @@ -27,7 +27,7 @@ .\" ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd July 30, 2025 +.Dd August 20, 2025 .Dt PF.CONF 5 .Os .Sh NAME @@ -274,6 +274,9 @@ The state after the first packet. .It Ar tcp.opening The state after the second packet but before both endpoints have acknowledged the connection. +.It Ar tcp.tsdiff +Maximum allowed time difference between RFC 1323 compliant packet timestamps. +30 seconds by default. .It Ar tcp.established The fully established state. .It Ar tcp.closing @@ -3580,7 +3583,7 @@ fragmentation = [ "fragment reassemble" ] timeout-list = timeout [ [ "," ] timeout-list ] timeout = ( "tcp.first" | "tcp.opening" | "tcp.established" | - "tcp.closing" | "tcp.finwait" | "tcp.closed" | + "tcp.closing" | "tcp.finwait" | "tcp.closed" | "tcp.tsdiff" | "sctp.first" | "sctp.opening" | "sctp.established" | "sctp.closing" | "sctp.closed" | "udp.first" | "udp.single" | "udp.multiple" | From nobody Mon Sep 15 11:54:23 2025 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 4cQNjq5s3yz67Fdk; Mon, 15 Sep 2025 11:54:23 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNjq1YZLz448q; Mon, 15 Sep 2025 11:54:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937263; 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=fMsmWGQrVO+bpHeSAH1urIRGM6q8ePQGN2yZO4InGEw=; b=c5HQBW2mTzTfvBLkuolIR0iOlcGw5qiReIaSwe77KBMN7A1ZCtW+7+dElLhQdJKv+xCNTG H1LbAiZnQ9PcbxyiIh+jzJAZXGl5i2o/5kw1WqEIT5AXZMmMbhIddqJYMj9vmiN1PvhXkE nykeFrHBoou85WBhrDv63huOsryGp2YX5dDyVFit7ze40Snm7mXRo/dqWZ7F5EchXcIqu2 UE9QmrdsBcf0B1/K3LQINewhfOVHocPdqACOje/QNxmyFSF+jM5jt2e7Qlqq0XREeoHBs2 fdEWviYiOvMAUlyEgzhj4jv/9Bj/fo+T/oX0g283MjkCstiG4CXAiGMzmF8SSw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937263; 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=fMsmWGQrVO+bpHeSAH1urIRGM6q8ePQGN2yZO4InGEw=; b=xHJGkmj/hEHMx3XYRU13SFuginejylTX79/XUqBXDmzbyQ3YIlrQzsAVPF+chuEowBbI9b Y71HYMIE0Du9HLyLrmXsDJnpIOmNh2YNx6ePKsDsDxsvuHEzu+smciIwHqoos4HVJHtZBv 1tT3V00PAq90Robcy2XrGx+iy9whuIEho9GYQZgGK4XqAaeAbUKGP18ImEr5K08ZyA+fti tUsX4bUTTapHc/CjKi7MX28986+vYVRN7s+eanelbi48FjoaQhQzur+MQ/oB6r1ROF6ThK tOyYeGJ36poDfQDjYtPC9aGftPi4eJfHwazRvurRLZ5X+n8pv9SLmhUwSQGL/g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757937263; a=rsa-sha256; cv=none; b=SfmUGce7JG5iuNNGC6vrhgGi20+KLb5Zyq+1lJB4XltxPMT6t7lv9QH6tGSEwkMze+7yFy JZcJ7Xp0XqpyeZ4dee18+UWNNrj+VweECeOxw2sYCMgTB8Fi/24LuX90rtFUM/sM3JqKZc 1DqXeUT2r1FmVQh90Blem0vFjaIZwe8lBbLKvaAahfzMsVC15ZMgwVxtc0HuNmqxOK7OfT AEyfwG6f+736ayHB8ujeXQUx/xCkkPLQw3kGpoxahjigAGYBbSTN8pbda6bOZ2QTQrt6/C hnpWQIaHZLTnegzQMX2FAMZwF9kfhZbSwVwZh2UoNGlxKqBtoPQZLMaIZjvQ3g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQNjq18lGztcW; Mon, 15 Sep 2025 11:54:23 +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 58FBsN56025378; Mon, 15 Sep 2025 11:54:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FBsN6I025375; Mon, 15 Sep 2025 11:54:23 GMT (envelope-from git) Date: Mon, 15 Sep 2025 11:54:23 GMT Message-Id: <202509151154.58FBsN6I025375@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 0a67f601fe4f - main - pf.conf.5: hint how to set tcp timeout collectively 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0a67f601fe4f2e8af72cb0f99785cba4c91f7d7c Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=0a67f601fe4f2e8af72cb0f99785cba4c91f7d7c commit 0a67f601fe4f2e8af72cb0f99785cba4c91f7d7c Author: Kristof Provost AuthorDate: 2025-08-20 14:34:33 +0000 Commit: Kristof Provost CommitDate: 2025-09-15 09:32:34 +0000 pf.conf.5: hint how to set tcp timeout collectively Hint that the tcp timeout values can be adjusted collectively via "set optimization". from jesper wallin ok bluhm Obtained from: OpenBSD, jmc , df80715c2d Sponsored by: Rubicon Communications, LLC ("Netgate") --- share/man/man5/pf.conf.5 | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/share/man/man5/pf.conf.5 b/share/man/man5/pf.conf.5 index 271a83a89ee5..edaa160dddf2 100644 --- a/share/man/man5/pf.conf.5 +++ b/share/man/man5/pf.conf.5 @@ -267,6 +267,10 @@ which corresponds to the connection state. Each packet which matches this state will reset the TTL. Tuning these values may improve the performance of the firewall at the risk of dropping valid idle connections. +Alternatively, these values may be adjusted collectively +in a manner suitable for a specific environment using +.Cm set optimization +(see above). .Pp .Bl -tag -width xxxx -compact .It Ar tcp.first From nobody Mon Sep 15 11:54:24 2025 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 4cQNjr43Bwz67Fdq; Mon, 15 Sep 2025 11:54:24 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNjr2CKNz44CV; Mon, 15 Sep 2025 11:54:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937264; 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=S+7BHnIO15Szi6Qqtsj3g/IQ+S1di4+hTS1U08tN22U=; b=hCqrBQhnJxjPRju2oAcbJQf0Bw3W1wdVgjEaZNH2XMxRHUjykUAWkrSwTmFKnMdXkk6+WL kSTwVjOg/wE6seeDKeeylPMEzJgXx1jnsS7SuMvcZ+m83WzHCqjpyE/YrHFdC1xL3mzvK+ PCSaJOhwsRjq6hNkb1vfnSJsVOQt0mT2/18DTSXMCQ4Vo/BYOr0nRVbFmG1XYeWhjo8ZAE YS2R3w5zccSs2ZnIsMJ/mRXLyPDE4QmGdSh+tqNI8m9NvkHBxKYa6MTy73LS+fysAS1FLM 8VNwlR0OhXAD2EjWqtB6Q/3K1jxvvFPSn9j2/y0yPgfUGEJZsVmkB7GAdpx0kw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937264; 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=S+7BHnIO15Szi6Qqtsj3g/IQ+S1di4+hTS1U08tN22U=; b=tQln6KI8N5P6O3cjQgbxp6C32DXxvyGVJq9giUqN8SZfUY++OUllay15A4pjUdGDV01RFT 4eCK5uLPs87v51Gnb55C68FCDAiMDTp0Q7lSdj7+lAMU4LtTOKSAvt1RzoMmuJZUq9Kkz5 TWRB9uRDwyuZwciM/bxMqlUwsDdjEmyu8N+XV2phrjqq1/MQz3rgHnoLA/sZOn0EHXmnC7 9qkQq7Zu1FpttxOOazpbj9eVhfFQQ2bf1Iw2iQ7vzXogmia5G8BJBy5HLZYEh0VisNF2eL MXYrHAknR3LMXoFPXrgGVnT1VzuOqxvO7qps/7qEm532ikk8vrVY+uDq8+lNKA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757937264; a=rsa-sha256; cv=none; b=Q+r9SmIKwwNPpoJa0BIne70bkubxVOGsdsTyVLIaBAJXW4nePygUE3H8b6e2fsH5WEDSnv 0Kc2PIwG/fwYBDTl4adB3yOsuZqwW378VCMM/OmhLSciRqNP2ZKdo4sr9SKl3zxdBVoPwK TTKu1EXHvZvQnc6tRVk2h+Fkyw5NXKpru7yJ737ivPgQ1q+UsUimo5o2EvZ5MSuKy7ICb1 98pHsAD/5T/NOKm39mc99yd4+I6WqaoD7aPzFLF8KTfFkZ57Q/N97qHRCrowE0n1JSASAl 0Jsryl9HQHGrdIJ+PwJvmjLAp5h6ZmxFLVxrlMBJow5InYcHl4mgiLRFyWgwzA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQNjr1pMzzt70; Mon, 15 Sep 2025 11:54:24 +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 58FBsO6Y025411; Mon, 15 Sep 2025 11:54:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FBsOMZ025408; Mon, 15 Sep 2025 11:54:24 GMT (envelope-from git) Date: Mon, 15 Sep 2025 11:54:24 GMT Message-Id: <202509151154.58FBsOMZ025408@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: c00aca9a714e - main - pf: Show pf fragment reassembly counters. 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c00aca9a714ee3cdb867d4014898ec4e345465a5 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=c00aca9a714ee3cdb867d4014898ec4e345465a5 commit c00aca9a714ee3cdb867d4014898ec4e345465a5 Author: Kristof Provost AuthorDate: 2025-08-21 08:09:13 +0000 Commit: Kristof Provost CommitDate: 2025-09-15 09:32:34 +0000 pf: Show pf fragment reassembly counters. Framgent count and statistics are stored in struct pf_status. From there pfctl(8) and systat(1) collect and show them. Note that pfctl -s info needs the -v switch to show fragments. input claudio@; OK henning@ Obtained from: OpenBSD, bluhm , 19e99d0613 Sponsored by: Rubicon Communications, LLC ("Netgate") --- lib/libpfctl/libpfctl.c | 3 +++ lib/libpfctl/libpfctl.h | 2 ++ sbin/pfctl/pfctl_parser.c | 14 ++++++++++++++ sys/net/pfvar.h | 2 ++ sys/netpfil/pf/pf.h | 6 ++++++ sys/netpfil/pf/pf_ioctl.c | 6 ++++++ sys/netpfil/pf/pf_nl.c | 3 +++ sys/netpfil/pf/pf_nl.h | 2 ++ sys/netpfil/pf/pf_norm.c | 12 ++++++++++++ 9 files changed, 50 insertions(+) diff --git a/lib/libpfctl/libpfctl.c b/lib/libpfctl/libpfctl.c index 190ee46baf21..b96b973ddc7c 100644 --- a/lib/libpfctl/libpfctl.c +++ b/lib/libpfctl/libpfctl.c @@ -391,6 +391,8 @@ static const struct snl_attr_parser ap_getstatus[] = { { .type = PF_GS_CHKSUM, .off = _OUT(pf_chksum), .arg_u32 = PF_MD5_DIGEST_LENGTH, .cb = snl_attr_get_bytes }, { .type = PF_GS_BCOUNTERS, .off = _OUT(bcounters), .arg_u32 = 2 * 2, .cb = snl_attr_get_uint64_array }, { .type = PF_GS_PCOUNTERS, .off = _OUT(pcounters), .arg_u32 = 2 * 2 * 2, .cb = snl_attr_get_uint64_array }, + { .type = PF_GS_NCOUNTERS, .off = _OUT(ncounters), .cb = snl_attr_get_counters }, + { .type = PF_GS_FRAGMENTS, .off = _OUT(fragments), .cb = snl_attr_get_uint64 }, }; SNL_DECLARE_PARSER(getstatus_parser, struct genlmsghdr, snl_f_p_empty, ap_getstatus); #undef _OUT @@ -429,6 +431,7 @@ pfctl_get_status_h(struct pfctl_handle *h) TAILQ_INIT(&status->lcounters); TAILQ_INIT(&status->fcounters); TAILQ_INIT(&status->scounters); + TAILQ_INIT(&status->ncounters); while ((hdr = snl_read_reply_multi(&h->ss, seq_id, &e)) != NULL) { if (! snl_parse_nlmsg(&h->ss, hdr, &getstatus_parser, status)) diff --git a/lib/libpfctl/libpfctl.h b/lib/libpfctl/libpfctl.h index da16d5179ec0..dd76cab163b5 100644 --- a/lib/libpfctl/libpfctl.h +++ b/lib/libpfctl/libpfctl.h @@ -62,6 +62,8 @@ struct pfctl_status { struct pfctl_status_counters lcounters; struct pfctl_status_counters fcounters; struct pfctl_status_counters scounters; + struct pfctl_status_counters ncounters; + uint64_t fragments; uint64_t pcounters[2][2][2]; uint64_t bcounters[2][2]; }; diff --git a/sbin/pfctl/pfctl_parser.c b/sbin/pfctl/pfctl_parser.c index a2b1e4d0841d..9609e880584f 100644 --- a/sbin/pfctl/pfctl_parser.c +++ b/sbin/pfctl/pfctl_parser.c @@ -614,6 +614,20 @@ print_status(struct pfctl_status *s, struct pfctl_syncookies *cookies, int opts) printf("%14s\n", ""); } } + if (opts & PF_OPT_VERBOSE) { + printf("Fragments\n"); + printf(" %-25s %14ju %14s\n", "current entries", + s->fragments, ""); + TAILQ_FOREACH(c, &s->ncounters, entry) { + printf(" %-25s %14ju ", c->name, + c->counter); + if (runtime > 0) + printf("%14.1f/s\n", + (double)c->counter / (double)runtime); + else + printf("%14s\n", ""); + } + } printf("Counters\n"); TAILQ_FOREACH(c, &s->counters, entry) { printf(" %-25s %14ju ", c->name, c->counter); diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index e6fb1c2c3e1b..af207d6ece24 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -1751,6 +1751,7 @@ struct pf_kstatus { counter_u64_t lcounters[KLCNT_MAX]; /* limit counters */ struct pf_counter_u64 fcounters[FCNT_MAX]; /* state operation counters */ counter_u64_t scounters[SCNT_MAX]; /* src_node operation counters */ + counter_u64_t ncounters[NCNT_MAX]; uint32_t states; uint32_t src_nodes; uint32_t running; @@ -2440,6 +2441,7 @@ int pf_match_port(u_int8_t, u_int16_t, u_int16_t, u_int16_t); void pf_normalize_init(void); void pf_normalize_cleanup(void); +uint64_t pf_normalize_get_frag_count(void); int pf_normalize_tcp(struct pf_pdesc *); void pf_normalize_tcp_cleanup(struct pf_kstate *); int pf_normalize_tcp_init(struct pf_pdesc *, diff --git a/sys/netpfil/pf/pf.h b/sys/netpfil/pf/pf.h index 8edd5a5110a1..54ffdbed3de5 100644 --- a/sys/netpfil/pf/pf.h +++ b/sys/netpfil/pf/pf.h @@ -247,6 +247,12 @@ enum { PF_ADDR_ADDRMASK, PF_ADDR_NOROUTE, PF_ADDR_DYNIFTL, #define SCNT_SRC_NODE_REMOVALS 2 #define SCNT_MAX 3 +/* fragment counters */ +#define NCNT_FRAG_SEARCH 0 +#define NCNT_FRAG_INSERT 1 +#define NCNT_FRAG_REMOVALS 2 +#define NCNT_MAX 3 + #define PF_TABLE_NAME_SIZE 32 #define PF_QNAME_SIZE 64 diff --git a/sys/netpfil/pf/pf_ioctl.c b/sys/netpfil/pf/pf_ioctl.c index 06c40a03f575..5bfbb2c83f0e 100644 --- a/sys/netpfil/pf/pf_ioctl.c +++ b/sys/netpfil/pf/pf_ioctl.c @@ -421,6 +421,8 @@ pfattach_vnet(void) pf_counter_u64_init(&V_pf_status.fcounters[i], M_WAITOK); for (int i = 0; i < SCNT_MAX; i++) V_pf_status.scounters[i] = counter_u64_alloc(M_WAITOK); + for (int i = 0; i < NCNT_MAX; i++) + V_pf_status.ncounters[i] = counter_u64_alloc(M_WAITOK); if (swi_add(&V_pf_swi_ie, "pf send", pf_intr, curvnet, SWI_NET, INTR_MPSAFE, &V_pf_swi_cookie) != 0) @@ -2508,6 +2510,8 @@ pf_ioctl_clear_status(void) pf_counter_u64_zero(&V_pf_status.fcounters[i]); for (int i = 0; i < SCNT_MAX; i++) counter_u64_zero(V_pf_status.scounters[i]); + for (int i = 0; i < NCNT_MAX; i++) + counter_u64_zero(V_pf_status.ncounters[i]); for (int i = 0; i < KLCNT_MAX; i++) counter_u64_zero(V_pf_status.lcounters[i]); V_pf_status.since = time_uptime; @@ -6949,6 +6953,8 @@ pf_unload_vnet(void) pf_counter_u64_deinit(&V_pf_status.fcounters[i]); for (int i = 0; i < SCNT_MAX; i++) counter_u64_free(V_pf_status.scounters[i]); + for (int i = 0; i < NCNT_MAX; i++) + counter_u64_free(V_pf_status.ncounters[i]); rm_destroy(&V_pf_rules_lock); sx_destroy(&V_pf_ioctl_lock); diff --git a/sys/netpfil/pf/pf_nl.c b/sys/netpfil/pf/pf_nl.c index 73f018db0266..5c8f56ea4567 100644 --- a/sys/netpfil/pf/pf_nl.c +++ b/sys/netpfil/pf/pf_nl.c @@ -1234,6 +1234,9 @@ pf_handle_get_status(struct nlmsghdr *hdr, struct nl_pstate *npt) V_pf_status.fcounters); nlattr_add_counters(nw, PF_GS_SCOUNTERS, SCNT_MAX, pf_fcounter, V_pf_status.scounters); + nlattr_add_counters(nw, PF_GS_NCOUNTERS, NCNT_MAX, pf_fcounter, + V_pf_status.ncounters); + nlattr_add_u64(nw, PF_GS_FRAGMENTS, pf_normalize_get_frag_count()); pfi_update_status(V_pf_status.ifname, &s); nlattr_add_u64_array(nw, PF_GS_BCOUNTERS, 2 * 2, (uint64_t *)s.bcounters); diff --git a/sys/netpfil/pf/pf_nl.h b/sys/netpfil/pf/pf_nl.h index b60d3d4797c6..b769421bbfcc 100644 --- a/sys/netpfil/pf/pf_nl.h +++ b/sys/netpfil/pf/pf_nl.h @@ -352,6 +352,8 @@ enum pf_get_status_types_t { PF_GS_CHKSUM = 14, /* byte array */ PF_GS_PCOUNTERS = 15, /* u64 array */ PF_GS_BCOUNTERS = 16, /* u64 array */ + PF_GS_NCOUNTERS = 17, /* nested, */ + PF_GS_FRAGMENTS = 18, /* u64, */ }; enum pf_natlook_types_t { diff --git a/sys/netpfil/pf/pf_norm.c b/sys/netpfil/pf/pf_norm.c index 56074bedbc40..53010222dd07 100644 --- a/sys/netpfil/pf/pf_norm.c +++ b/sys/netpfil/pf/pf_norm.c @@ -211,6 +211,12 @@ pf_normalize_cleanup(void) mtx_destroy(&V_pf_frag_mtx); } +uint64_t +pf_normalize_get_frag_count(void) +{ + return (uma_zone_get_cur(V_pf_frent_z)); +} + static int pf_frnode_compare(struct pf_frnode *a, struct pf_frnode *b) { @@ -314,6 +320,7 @@ pf_free_fragment(struct pf_fragment *frag) /* Free all fragment entries */ while ((frent = TAILQ_FIRST(&frag->fr_queue)) != NULL) { TAILQ_REMOVE(&frag->fr_queue, frent, fr_next); + counter_u64_add(V_pf_status.ncounters[NCNT_FRAG_REMOVALS], 1); m_freem(frent->fe_m); uma_zfree(V_pf_frent_z, frent); @@ -331,6 +338,7 @@ pf_find_fragment(struct pf_frnode *key, uint32_t id) PF_FRAG_ASSERT(); frnode = RB_FIND(pf_frnode_tree, &V_pf_frnode_tree, key); + counter_u64_add(V_pf_status.ncounters[NCNT_FRAG_SEARCH], 1); if (frnode == NULL) return (NULL); MPASS(frnode->fn_fragments >= 1); @@ -438,6 +446,7 @@ pf_frent_insert(struct pf_fragment *frag, struct pf_frent *frent, ("overlapping fragment")); TAILQ_INSERT_AFTER(&frag->fr_queue, prev, frent, fr_next); } + counter_u64_add(V_pf_status.ncounters[NCNT_FRAG_INSERT], 1); if (frag->fr_firstoff[index] == NULL) { KASSERT(prev == NULL || pf_frent_index(prev) < index, @@ -496,6 +505,7 @@ pf_frent_remove(struct pf_fragment *frag, struct pf_frent *frent) } TAILQ_REMOVE(&frag->fr_queue, frent, fr_next); + counter_u64_add(V_pf_status.ncounters[NCNT_FRAG_REMOVALS], 1); KASSERT(frag->fr_entries[index] > 0, ("No fragments remaining")); frag->fr_entries[index]--; @@ -768,6 +778,7 @@ pf_join_fragment(struct pf_fragment *frag) frent = TAILQ_FIRST(&frag->fr_queue); TAILQ_REMOVE(&frag->fr_queue, frent, fr_next); + counter_u64_add(V_pf_status.ncounters[NCNT_FRAG_REMOVALS], 1); m = frent->fe_m; if ((frent->fe_hdrlen + frent->fe_len) < m->m_pkthdr.len) @@ -775,6 +786,7 @@ pf_join_fragment(struct pf_fragment *frag) uma_zfree(V_pf_frent_z, frent); while ((frent = TAILQ_FIRST(&frag->fr_queue)) != NULL) { TAILQ_REMOVE(&frag->fr_queue, frent, fr_next); + counter_u64_add(V_pf_status.ncounters[NCNT_FRAG_REMOVALS], 1); m2 = frent->fe_m; /* Strip off ip header. */ From nobody Mon Sep 15 11:54:25 2025 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 4cQNjt19RHz67Fg9; Mon, 15 Sep 2025 11:54:26 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNjs34nZz44Fp; Mon, 15 Sep 2025 11:54:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937265; 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=+CRd18LE9luJlPyfDdrPrKED+PyuEFwOL0QT7gS4oMI=; b=DcOc5QOTy2NWRrDHMlIRjB9lUb6TDxpqW48xt4c7cGlYHqS5onVNjv1ytwCNXrEtDjHHPk 89IQtLZQxgET1CRXY+zFBMeDbDiRUCSITxv+vmD0+dhdRe+AizB8FI194k6xW0DSFUksum 2Fyy82LmGRoviHP8CtEyV4r+ZdOSGJ30JA7mGxTg7Ievy48tfEt3U27U9qsD6XRu3rJN5k EsucVVeK8ZlO8yp3ediUZ67KsslxpC88xZWNj/9MxA43ESclTbMtkTBXmsYfEQMyutojDY tp4sztIhb/ufgnPJhY5QkC26q81oQK/3eYkuq94AcceFXrCMTsUmjfXxSqc2gg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937265; 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=+CRd18LE9luJlPyfDdrPrKED+PyuEFwOL0QT7gS4oMI=; b=IpWJNIN11q2Jt+WD4MosnXK8ppr07jv+e3cff3DK9NxyYfOQSZbSSvgP0tG9K/0qujP+rf 55z8YTFssW3tYnAaenBshr3c6HEsefFyJC2WWLLh9HPtgm2w2veNbT1u2IJG+x7sATC/y4 7aw6tyCuLoN2uhgrJuCkQRd6ieWYf4PHHkFjpsLVxwrdfOYx3tlo3gaG4+nqdb0ZhT8tpf L33/gt01z7GHTJeMwc3YFS51Z8uuU/1yWDSPHAAfS+n9ztfcuKhEG5oiGUg3BaTdQhbjF+ OIbMrk13o77s4HqgBY04+VHle/qmvRByyLoq0DezbdGLpJ+unwWFm48It3lciw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757937265; a=rsa-sha256; cv=none; b=c5pRJljlQKF+o/m8zvKePIng0f/9ewWhAT5pj7W2BlbB/jGmg5A/mDNPn0wftI0xrxo9zK YJD36W1VLRVWO1pfAb4UZKtTjO6aFkiqe1to8JBfpiKpiJDH9n0aQySRygzcvnpM04V5hj sSzw0qgbSDO6J9z4oYbBRch8+OKj8C4VdyUkRQsbCHS+/bC2P7oZfWDlxOdW2cNbPmNBci Dp/v80Xcpx/MB6cpwwKW2PIT2L6lm66rBe2pwtemudzkuBdvpYQC7LKl3fHHnuR6qb07aX 9IsMqCvR7VpSleEHFVvJSBbhHrM/8EV8sHJMwuQ2bgf2L57dTVgRpXeI8oCFqg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQNjs2Xb4zt9y; Mon, 15 Sep 2025 11:54:25 +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 58FBsP5r025444; Mon, 15 Sep 2025 11:54:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FBsPZv025441; Mon, 15 Sep 2025 11:54:25 GMT (envelope-from git) Date: Mon, 15 Sep 2025 11:54:25 GMT Message-Id: <202509151154.58FBsPZv025441@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 5e89648ee68e - main - pf tests: test fragment counters 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5e89648ee68e44d01d00d41d53b6934c604f8c50 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=5e89648ee68e44d01d00d41d53b6934c604f8c50 commit 5e89648ee68e44d01d00d41d53b6934c604f8c50 Author: Kristof Provost AuthorDate: 2025-08-21 08:10:08 +0000 Commit: Kristof Provost CommitDate: 2025-09-15 09:32:35 +0000 pf tests: test fragment counters Ensure that the fragmentation counters work as expected. Sponsored by: Rubicon Communications, LLC ("Netgate") --- tests/sys/netpfil/pf/fragmentation_pass.sh | 67 ++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) diff --git a/tests/sys/netpfil/pf/fragmentation_pass.sh b/tests/sys/netpfil/pf/fragmentation_pass.sh index 5deaba18301d..c749aac793ee 100644 --- a/tests/sys/netpfil/pf/fragmentation_pass.sh +++ b/tests/sys/netpfil/pf/fragmentation_pass.sh @@ -648,6 +648,72 @@ dummynet_fragmented_cleanup() pft_cleanup } +atf_test_case "counters" "cleanup" +counters_head() +{ + atf_set descr 'Test fragment counters' + atf_set require.user root +} + +counters_body() +{ + pft_init + + epair=$(vnet_mkepair) + vnet_mkjail alcatraz ${epair}a + + ifconfig ${epair}b inet 192.0.2.1/24 up + jexec alcatraz ifconfig ${epair}a 192.0.2.2/24 up + + jexec alcatraz pfctl -e + pft_set_rules alcatraz \ + "set reassemble yes" \ + "pass keep state" + + # All fragment counters are zero + counters=$(jexec alcatraz pfctl -si -v | grep -A 4 '^Fragments') + atf_check -s exit:0 -o match:"current entries[[:space:]]+0" \ + echo $counters + atf_check -s exit:0 -o match:"searches[[:space:]]+0" \ + echo $counters + atf_check -s exit:0 -o match:"inserts[[:space:]]+0" \ + echo $counters + atf_check -s exit:0 -o match:"removals[[:space:]]+0" \ + echo $counters + + # They remain zero after we've seen non-fragmented traffic + atf_check -s exit:0 -o ignore \ + ping -c 1 192.0.2.2 + counters=$(jexec alcatraz pfctl -si -v | grep -A 4 '^Fragments') + atf_check -s exit:0 -o match:"current entries[[:space:]]+0" \ + echo $counters + atf_check -s exit:0 -o match:"searches[[:space:]]+0" \ + echo $counters + atf_check -s exit:0 -o match:"inserts[[:space:]]+0" \ + echo $counters + atf_check -s exit:0 -o match:"removals[[:space:]]+0" \ + echo $counters + + # But once we've reassembled they're no longer zero + # (Count is 2, because in + out) + atf_check -s exit:0 -o ignore \ + ping -c 1 -s 2000 192.0.2.2 + counters=$(jexec alcatraz pfctl -si -v | grep -A 4 '^Fragments') + atf_check -s exit:0 -o match:"current entries[[:space:]]+0" \ + echo $counters + atf_check -s exit:0 -o match:"searches[[:space:]]+2" \ + echo $counters + atf_check -s exit:0 -o match:"inserts[[:space:]]+2" \ + echo $counters + atf_check -s exit:0 -o match:"removals[[:space:]]+2" \ + echo $counters +} + +counters_cleanup() +{ + pft_cleanup +} + atf_init_test_cases() { atf_add_test_case "too_many_fragments" @@ -665,4 +731,5 @@ atf_init_test_cases() atf_add_test_case "dummynet" atf_add_test_case "dummynet_nat" atf_add_test_case "dummynet_fragmented" + atf_add_test_case "counters" } From nobody Mon Sep 15 11:54:27 2025 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 4cQNjv6GN6z67FRB; Mon, 15 Sep 2025 11:54:27 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNjv53JNz44GV; Mon, 15 Sep 2025 11:54:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937267; 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=spVJaeTMaY7zISx3BJc5aFuLcvx2GnuvjVrTfnLNr+A=; b=xlEAjVEB/vAh/D9TbCQzZ2hSXqXEOxAbeNhlJH/iM6gtfmdiUre8pDENSbOc/bryhy1eWH gKILy88eE3uQoV6ir1eYLFiLtA5ekPL41m5SuYCPti69E15euJtrzXjWJP/dgDl6gdjGMJ 5BA9AEg3GVuEfCiLiSGcD9Khrvi1Cly2E8cW3jmeC6/8ncEZH2Xf+Z1IHlBLVw102ZKkJf 8u2O3a2DJuf/CXJ1FFJNaSVi4Jns8K57Gd+uttfv8Hm8NvrkSqpZuM7/ifOu1BWkiCa0N0 chJRP+RdAr3GrZkSYk9qkDe/6+LRSoahyQ4UcY8LbxRfKYItxw3uQgsHQA0HnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937267; 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=spVJaeTMaY7zISx3BJc5aFuLcvx2GnuvjVrTfnLNr+A=; b=Tl15lCjebDN9QbmuPnGSdxMc+Lit7WrApYpp60EYYLL9aIGB86iQt50+bTTLOkwkiPlb1B rvbZ4ewFOtK39Pj0ca6sGq8i/mDRlKsLTy0CURJ7hktzW1GOCeXD+hRnRffzRTivuQa+hg WJK/udKFu7lVZRB4W7jqL7/9+L4sZlBbSgHC0FL+SXHTFH5OgkCxkQl064DeIwX/X5v6nl FDf6bggxeUc/qzmCusLQTgRYUESCONwiqVua1GOecWQGcMIxHDrZdSFdUSWx5qjwFqUEJ6 ugLQ6A+WEjN8vB2dNbO0r99/WRJtqezsdRmG7vLYQbB1DwJ2yLNyR9cTvPjIvA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757937267; a=rsa-sha256; cv=none; b=CDECyyYa/kY7DK+jCztXNzGvsSIBKLX40FaNDmzTwJXnCHRq2t6WmWviZDOfGfwOqbY/PC webvYksXzKD8uSX/9yDO74fSjKhqyPrF2qTQ0Wf4HAv9luF8503HJXKdNyt1tPQz8ygR9F s1vaeH0Zzkfp6W/S5mmzJ7Ya2nQqxI4UlOh/13/lPE89HPh+pOVJj+SntzXaMQYg+e+tbZ 3RQnFdDlNtbvhEmtyrdCbUSpQKTZTVN+umd4CSLDO9/2ndm5ptRD+/3siOZdmnJ+PdAOef gcR71GknHaB61QD5sReUTsi7Qru/uGm59zDtIjpLV3HiDw03r9rbNRxEfRQtRw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQNjv4cWtztgs; Mon, 15 Sep 2025 11:54:27 +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 58FBsRWA025511; Mon, 15 Sep 2025 11:54:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FBsR7A025508; Mon, 15 Sep 2025 11:54:27 GMT (envelope-from git) Date: Mon, 15 Sep 2025 11:54:27 GMT Message-Id: <202509151154.58FBsR7A025508@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: a66df2b575c8 - main - pf: sync_ifp doesn't exist, remove externs 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a66df2b575c8add6331fc0a0a0f536e90ccfafb7 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=a66df2b575c8add6331fc0a0a0f536e90ccfafb7 commit a66df2b575c8add6331fc0a0a0f536e90ccfafb7 Author: Kristof Provost AuthorDate: 2025-08-21 09:33:06 +0000 Commit: Kristof Provost CommitDate: 2025-09-15 09:32:35 +0000 pf: sync_ifp doesn't exist, remove externs Obtained from: OpenBSD, jsg , 7ac7a88014 Sponsored by: Rubicon Communications, LLC ("Netgate") --- sys/net/pfvar.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index af207d6ece24..e0fda082fefe 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -2392,8 +2392,6 @@ extern u_int16_t pf_cksum_fixup(u_int16_t, u_int16_t, u_int16_t, extern u_int16_t pf_proto_cksum_fixup(struct mbuf *, u_int16_t, u_int16_t, u_int16_t, u_int8_t); -VNET_DECLARE(struct ifnet *, sync_ifp); -#define V_sync_ifp VNET(sync_ifp); VNET_DECLARE(struct pf_krule, pf_default_rule); #define V_pf_default_rule VNET(pf_default_rule) extern void pf_addrcpy(struct pf_addr *, const struct pf_addr *, From nobody Mon Sep 15 11:54:26 2025 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 4cQNjv2VNjz67Flp; Mon, 15 Sep 2025 11:54:27 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNjt4sYYz43tG; Mon, 15 Sep 2025 11:54:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937266; 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=R2Wrbt4yKQTsNx9wtj2Lw/HejWUqKWUb01+Y/AFJp5Y=; b=lQf+HBJjPsewydbrgxowZKaFzmhADMDpcIr8RopdS50friV2kqK/joY3JcpK9lWyJiOduD UNWdRnxCA+Hagwkq+UvKsW5/pd1DLMf0MPQIo0mxVcSjWO9uRBLBFBoIsEXEvegiJGfq8C f84njUiXdKG73lU0jJSN5ValI2Jc4t74vCv7kReAvKpms4hBclAnBtG68LRl2GH5ipqsbb 3t+sWNxJP7yW1+fxz30ejUluc4lGlAbZbtIqkJAZlWgcTwOD2S3l6i0eAfvPEBw4F7kkuo HREjfjAlw+PfHvkWh/buxPtOlCW/W7tsgOafIELeC/AJOFpur4u3oQsRSMjjPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937266; 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=R2Wrbt4yKQTsNx9wtj2Lw/HejWUqKWUb01+Y/AFJp5Y=; b=tGV26pWrlWm8UlCfImfRIkGOTDXK9HgUjBg/wiNgKSWmGW39qiilKlZj/mcPZZq5+eafIe 6aGlnLG1Gl49bTkn56qm5ppgZhFWA2YETG5fbEkJqr78D+uK2tQZ6CpOK1A7KF+6XzTC2Y TOba+5lEO1E4I9qnoMq1P/9qnsyXblTdjX2eZmZFv9rOZ7XuYDdO+E5DkeIHtMPWUHW1SX yOraS5W5iiFuP4GszW32aEwkjLLjhAOEC8Hbi/EKpL6r2e6dPVzFca7jirxOPDy35O1dzw RkwJ1UTHzjvWk2wQBXtLWGEAPVjGzXshJoEt716apY3YK9luBO5Q5a663PoTkA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757937266; a=rsa-sha256; cv=none; b=LuxXXOqHjO6jmJ3DkhZlvL6n5LOseQu//J5slwkeOUe0LmzjZKmKZtexVTTKn9aGVC4+9s +3Q/JmD+PCLbxrvkimhvYanQnwO8MhsrmOg9ZkQx26EQIeYBrboEwN6wqmaGHdOtE7WMp8 l4Wh8BrmftQ040T8AHGhPO9/yYKe3pA3219MeUCTrQQL2uTN2xUFZEmUzItHGjoM6sJxnk Qm2sjXliH1AVY++9TVFMm48XD1LBZMpd70nKrXp5Rj6TFngqBpAZVlHeXUhwEBSeu4Af7s 7yEuB6O2zYOwq4RkAPgac1Uywu9DPa62xi1zPkHZxiKsVVH/vWTy74TjBlvBfA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQNjt3dHZztGS; Mon, 15 Sep 2025 11:54:26 +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 58FBsQb0025478; Mon, 15 Sep 2025 11:54:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FBsQAg025475; Mon, 15 Sep 2025 11:54:26 GMT (envelope-from git) Date: Mon, 15 Sep 2025 11:54:26 GMT Message-Id: <202509151154.58FBsQAg025475@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 2c42aecee696 - main - pfctl: ctime(3) and ctime_r(3) can fail when timestamps are way off. 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2c42aecee69696aba85f1ad4c45033dd2db86b02 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=2c42aecee69696aba85f1ad4c45033dd2db86b02 commit 2c42aecee69696aba85f1ad4c45033dd2db86b02 Author: Kristof Provost AuthorDate: 2025-08-21 09:01:21 +0000 Commit: Kristof Provost CommitDate: 2025-09-15 09:32:35 +0000 pfctl: ctime(3) and ctime_r(3) can fail when timestamps are way off. Add missing error checks Input kettenis, millert OK millert Obtained from: OpenBSD, florian , a7b9eedcb4 Sponsored by: Rubicon Communications, LLC ("Netgate") --- sbin/pfctl/pfctl_table.c | 35 +++++++++++++++++++++++++---------- 1 file changed, 25 insertions(+), 10 deletions(-) diff --git a/sbin/pfctl/pfctl_table.c b/sbin/pfctl/pfctl_table.c index 0845f765a063..745ab84b3159 100644 --- a/sbin/pfctl/pfctl_table.c +++ b/sbin/pfctl/pfctl_table.c @@ -437,14 +437,19 @@ print_table(const struct pfr_table *ta, int verbose, int debug) int print_tstats(const struct pfr_tstats *ts, int debug) { - time_t time = ts->pfrts_tzero; - int dir, op; + time_t time = ts->pfrts_tzero; + int dir, op; + char *ct; if (!debug && !(ts->pfrts_flags & PFR_TFLAG_ACTIVE)) return (0); + ct = ctime(&time); print_table(&ts->pfrts_t, 1, debug); printf("\tAddresses: %d\n", ts->pfrts_cnt); - printf("\tCleared: %s", ctime(&time)); + if (ct) + printf("\tCleared: %s", ct); + else + printf("\tCleared: %lld\n", (long long)time); printf("\tReferences: [ Anchors: %-18d Rules: %-18d ]\n", ts->pfrts_refcnt[PFR_REFCNT_ANCHOR], ts->pfrts_refcnt[PFR_REFCNT_RULE]); @@ -543,12 +548,17 @@ nonzero_astats(struct pfr_astats *as) void print_astats(struct pfr_astats *as, int dns) { - time_t time = as->pfras_tzero; - int dir, op; + time_t time = as->pfras_tzero; + int dir, op; + char *ct; + ct = ctime(&time); print_addrx(&as->pfras_a, NULL, dns); - printf("\tCleared: %s", ctime(&time)); - if (as->pfras_a.pfra_fback == PFR_FB_NOCOUNT) + if (ct) + printf("\tCleared: %s", ct); + else + printf("\tCleared: %lld\n", (long long)time); + if (as->pfras_a.pfra_fback == PFR_FB_NOCOUNT) return; for (dir = 0; dir < PFR_DIR_MAX; dir++) for (op = 0; op < PFR_OP_ADDR_MAX; op++) @@ -653,8 +663,9 @@ pfctl_show_ifaces(const char *filter, int opts) void print_iface(struct pfi_kif *p, int opts) { - time_t tzero = p->pfik_tzero; - int i, af, dir, act; + time_t tzero = p->pfik_tzero; + int i, af, dir, act; + char *ct; printf("%s", p->pfik_name); if (opts & PF_OPT_VERBOSE) { @@ -665,7 +676,11 @@ print_iface(struct pfi_kif *p, int opts) if (!(opts & PF_OPT_VERBOSE2)) return; - printf("\tCleared: %s", ctime(&tzero)); + ct = ctime(&tzero); + if (ct) + printf("\tCleared: %s", ct); + else + printf("\tCleared: %lld\n", (long long)tzero); printf("\tReferences: %-18d\n", p->pfik_rulerefs); for (i = 0; i < 8; i++) { af = (i>>2) & 1; From nobody Mon Sep 15 11:54:28 2025 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 4cQNjx1Y0Vz67FRD; Mon, 15 Sep 2025 11:54:29 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNjw63pcz44Gp; Mon, 15 Sep 2025 11:54:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937268; 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=TqgbwlzJ9ELssUIuIS0L0d9VDbgIq+s/AMB0sVWqhKM=; b=dSXmyszEuPvEOcDtavstdFwvjF+HqKw0CNcyq3Fxm3tRt0t3SwXU+aR+2x74hUPHAFNE+j ojc3GU/INA7OkBOUyfcGn6EPSRdHHqQX9zAI0A7oEoWAx/Pl4BVG7YnY/T1zPzrTln30bC KQFzWP1/aKsNN34HkGae/yifzdOV1ltmIOpwQVH5I4G7zdX9hUb/TwGg+Vmvfm+PECrkay pAxQ1xXBHd3lIrvs6u9dl67a3eSb0jX1a/2UZC/1SDqAzfMfEqRn7KPverLsAQ9DEZcFSi iDWK1VaNxw0nud8/h70VVZKQ9Vl/Jc2mnG4+kpwLzvF2k6AzoHSz8lEJGWz9Aw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937268; 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=TqgbwlzJ9ELssUIuIS0L0d9VDbgIq+s/AMB0sVWqhKM=; b=g9i/oZSs35hRxg/tqmqDxzdAbIccJVKegRQq1lk7DeIEMXCXzFffIzdieCMUhkUw5jjgK+ u/6ieNDUapsGX1X3rKphCuUFlnUzSk7ameXCkQnbhGJu90jfvrQqdd8DRwzDJRlX9bCO0m CxEQnh/La8qJJ4xvarcU2vc5/Z0CV1UKSlMjLAjG1MlNWEzWZAInJbGs94sujSVLdnPs4+ DG3wXjRYF8ySokyY2Acb/bu8Pf9Dle/7xzKJa31YdiY7H0vOazI8/l8poCuz+MBEsemDrb RWlSdXkrcX3SbfvhTPuUgLIUW9CXFpl0qnhKgw5wLOtpdpPnib7XZMbrI/1lPw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757937268; a=rsa-sha256; cv=none; b=UKG6JYiSkeVoGfRliRunv6EpJjmyKNIg44w13ioFK1ERTJnKKAm1WP59LDQNpM1KuzFVTE /gcYhgVdynllb6ArKU7uvYgaC5yqf2zqIMqQ17HB7n5DGIlCWQNiWDnLMxAaVu5u9zmc8d GSXdkh1AqhEe+oHL3SCnxh9AYdEYvzo6cWgBpT7zzRG9wlvfQmhtPLrVuFP06ycd7jpWMW WEe7bQys7Vu5AFPEcDdP7ytomGUVBYCbAtMHnM72q3RrQoEhVxSs+VEk9Du3p1d16B7lKD H2mvHuYjBPlWO2fUDRQTIHhHwifAbERqbRDUAPZIa0CULLCucbeYON8hp+9h8g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQNjw5cFBztdV; Mon, 15 Sep 2025 11:54:28 +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 58FBsSqh025547; Mon, 15 Sep 2025 11:54:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FBsSUX025544; Mon, 15 Sep 2025 11:54:28 GMT (envelope-from git) Date: Mon, 15 Sep 2025 11:54:28 GMT Message-Id: <202509151154.58FBsSUX025544@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 8e84e9443bb6 - main - pfctl: remove prototypes with no matching function 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8e84e9443bb6655f7e6c73546ac28549f768f4f3 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=8e84e9443bb6655f7e6c73546ac28549f768f4f3 commit 8e84e9443bb6655f7e6c73546ac28549f768f4f3 Author: Kristof Provost AuthorDate: 2025-08-21 09:35:07 +0000 Commit: Kristof Provost CommitDate: 2025-09-15 09:32:36 +0000 pfctl: remove prototypes with no matching function Obtained from: OpenBSD, jsg , 6768654732 Sponsored by: Rubicon Communications, LLC ("Netgate") --- sbin/pfctl/pfctl.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/sbin/pfctl/pfctl.h b/sbin/pfctl/pfctl.h index afecc78086e0..37e06e93dde6 100644 --- a/sbin/pfctl/pfctl.h +++ b/sbin/pfctl/pfctl.h @@ -62,7 +62,6 @@ struct pfr_anchoritem { SLIST_HEAD(pfr_anchors, pfr_anchoritem); -int pfr_get_fd(void); int pfr_add_table(struct pfr_table *, int *, int); int pfr_del_table(struct pfr_table *, int *, int); int pfr_get_tables(struct pfr_table *, struct pfr_table *, int *, int); @@ -85,7 +84,6 @@ int pfr_buf_load(struct pfr_buffer *, char *, int, int (*)(struct pfr_buffer *, char *, int, int), int); char *pf_strerror(int); int pfi_get_ifaces(const char *, struct pfi_kif *, int *); -int pfi_clr_istats(const char *, int *, int); void pfctl_print_title(char *); int pfctl_do_clear_tables(const char *, int); From nobody Mon Sep 15 11:54:29 2025 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 4cQNjy2YLGz67FRH; Mon, 15 Sep 2025 11:54:30 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQNjx6wKcz44Bb; Mon, 15 Sep 2025 11:54:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937270; 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=aqw+vKy9BCKguw5IZKnrNEkV6ifPi32mPyaB2lUGgIU=; b=tjTJNoj6+JMKWiu/4BapnYWWW+4zyGgcd+JQbdsX06nvGxJEdqZjgceWCD/1NK+lZEYi6Q SDxzmV94mQ+VPSrNTHmHbalJiAx+/ql99V7Rpmua+W5XcG4VyDC/8vlx1ln/0EDb9DcVZd EvzYcRaeKGTmP1aV/ZrkO2YSQOrJhyKTFdXmov8q9DpKdF3cmhF2inh1kcxcdS0huwJSaM Cs8nFC/nWja2MKy/biY06XhbEmtDX7dO0Rc58xsYueSgdjn+yA8TSMhaaDUEsBbl2wea6X lOFhBv66cYfc075pWyulyW+YuminAzHCj7WcaAKAzEkmDvL5AyufB/GrpXNfVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757937270; 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=aqw+vKy9BCKguw5IZKnrNEkV6ifPi32mPyaB2lUGgIU=; b=ls+CXZg1tyveiX+l8oRVyvB5vx/uxIduSR8iAwJpSP6kjKQdzX0/lUgpEDWRiJgcWG0qmn hhNgfrEMv5AC2haVYWPH4ysbEzFVSZjYBsS4sIUc4k+rvDRde5XxRemIFfDPQOfPEjBAn1 ZYYXLWkAzr4PCutJKQ51u9qspnrwutGuVMG/aN/SX7wRcygAXvwb7SNjAYRxtIoYRG6p+G OlKbiuM6k1wy2cV/FZVx/908V5aNvUEMPSNcyYwX0YIPz1f0ZbNnUlCtrfg4n9m1POptOi 9aMJdRz8JasOTggtbw6HYSZ7yzFJWShZxbtyl8d5Wm2tmExoI2pB/d/B87BljQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757937270; a=rsa-sha256; cv=none; b=pWwkY01x+jZK57/aU4M27tqfMRTodF11xZXiq9wbEzuvCSya1mV7rlYKviYIivQooNzfI3 Jm0G3DSQzEmW4E3W5dOXu/lJ9tQd6dAL1N+Qs0Q3kM14fHmK149TrMMOKAnO+tJbXFRftD QjLCHZ31AXxlbMvLuGfsMVlB8Wcz+FB1JgPVN7GrYbJCg7XWRJJw0ixAEFDa/qgigJ+7tI LmBWc21h8qveffPkmRbwFb0L9ixJuNdcxDiKXAe1sXbiPPTvYD2tqxKGkJEK8kmEdskkgu e24O4rg37i9DWvv+akstfd1U+sNZ1WCflRyz8v3Nj31z8lvQ9XBJj5DenjXOzQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQNjx6PsDztB0; Mon, 15 Sep 2025 11:54:29 +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 58FBsTiY025580; Mon, 15 Sep 2025 11:54:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FBsT2d025577; Mon, 15 Sep 2025 11:54:29 GMT (envelope-from git) Date: Mon, 15 Sep 2025 11:54:29 GMT Message-Id: <202509151154.58FBsT2d025577@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: d0ea3de0fe71 - main - pf tests: verify rule numbers in pflog output 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d0ea3de0fe71fe67537f84df59da69770784fa9a Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=d0ea3de0fe71fe67537f84df59da69770784fa9a commit d0ea3de0fe71fe67537f84df59da69770784fa9a Author: Kristof Provost AuthorDate: 2025-08-21 13:08:05 +0000 Commit: Kristof Provost CommitDate: 2025-09-15 09:32:36 +0000 pf tests: verify rule numbers in pflog output Sponsored by: Rubicon Communications, LLC ("Netgate") --- tests/sys/netpfil/pf/pflog.sh | 59 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) diff --git a/tests/sys/netpfil/pf/pflog.sh b/tests/sys/netpfil/pf/pflog.sh index a34ec893a75c..550548a59c11 100644 --- a/tests/sys/netpfil/pf/pflog.sh +++ b/tests/sys/netpfil/pf/pflog.sh @@ -394,6 +394,64 @@ rdr_action_cleanup() pft_cleanup } +atf_test_case "rule_number" "cleanup" +rule_number_head() +{ + atf_set descr 'Test rule numbers with anchors' + atf_set require.user root +} + +rule_number_body() +{ + pflog_init + + epair=$(vnet_mkepair) + + vnet_mkjail alcatraz ${epair}b + jexec alcatraz ifconfig ${epair}b 192.0.2.1/24 up + + ifconfig ${epair}a 192.0.2.2/24 up + ifconfig ${epair}a inet alias 192.0.2.3/24 up + ifconfig ${epair}a inet alias 192.0.2.4/24 up + + jexec alcatraz pfctl -e + jexec alcatraz ifconfig pflog0 up + pft_set_rules alcatraz \ + "pass log from 192.0.2.2" \ + "anchor \"foo\" {\n \ + pass log from 192.0.2.3\n \ + }" \ + "pass log from 192.0.2.4" + + jexec alcatraz tcpdump -n -e -ttt --immediate-mode -l -U -i pflog0 >> pflog.txt & + sleep 1 # Wait for tcpdump to start + + atf_check -s exit:0 -o ignore \ + ping -c 1 -S 192.0.2.2 192.0.2.1 + atf_check -s exit:0 -o ignore \ + ping -c 1 -S 192.0.2.3 192.0.2.1 + atf_check -s exit:0 -o ignore \ + ping -c 1 -S 192.0.2.4 192.0.2.1 + + jexec alcatraz pfctl -sr -a '*' -vv + + # Give tcpdump a little time to finish writing to the file + sleep 1 + cat pflog.txt + + atf_check -o match:"rule 0/0\(match\): pass in.*: 192.0.2.2.*ICMP echo request" \ + cat pflog.txt + atf_check -o match:"rule 1.foo.0/0\(match\): pass in.*: 192.0.2.3.*: ICMP echo request" \ + cat pflog.txt + atf_check -o match:"rule 2/0\(match\): pass in.*: 192.0.2.4.*: ICMP echo request" \ + cat pflog.txt +} + +rule_number_cleanup() +{ + pft_cleanup +} + atf_init_test_cases() { atf_add_test_case "malformed" @@ -403,4 +461,5 @@ atf_init_test_cases() atf_add_test_case "unspecified_v4" atf_add_test_case "unspecified_v6" atf_add_test_case "rdr_action" + atf_add_test_case "rule_number" } From nobody Mon Sep 15 13:11:00 2025 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 4cQQQF1052z67Ksj; Mon, 15 Sep 2025 13:11: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQQQF0JvJz3DT5; Mon, 15 Sep 2025 13:11:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757941861; 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=rC0mOiFvrJLhfvV9x17uW+PPB3AZFublLO+OoRb4k1Q=; b=fwEqg/pHCU06nDkO2LAnQ3ASBI9Qy7rxpNqMMTKiaThNtOj7suerJap/ad0YLWrqQGjmvD hVk8LK2Rd6Gd1MVfwTpY4iL+Ifhy7q61CJho0B7vAOTM1JmnzSc4tjPKPzsIkqeA+rLLZx gcFFKzjJ99GUXv0Hpr6mzJUn98T70Q3Myyy4ngq0Q2/mkt2xIvRFHX/hg0ColzGxEwcezu tOmLx7jBs3Prax3bWHpIP+hPL1mVR/FsGkEC6G7PofoG8pYdW7TFfWcGam7dndllh7lW5R ep2zWATvrSW6YvX9ncfM237dbKbsdeACyQDVAQSZoUgAbBi45CTqOLiS5FbjmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757941861; 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=rC0mOiFvrJLhfvV9x17uW+PPB3AZFublLO+OoRb4k1Q=; b=myYJYk3gCwioXBpvogAClneLvT8jgwdA3yrJgzWJIFq0VwTZV3JO5dzmWRKv3cTJe4+CAJ mEudLUgWGg6ADhUmmP9jNutJ4c77D+T/tp+Z1WXCWkIY+qe957+R4u6XhwpvGx+LJrujLq DmuBFB6MjLWFuBo4Dv2/McKG3HYHqqs3cTNnjMgF8ZAsM1+ZvdwJd6GGa49wfTaj6RW0zH MWz7bZugTwTzAHes2kR82/L9LjODwyGyHDwLnxSGncAYnNq/hXXYNmJ5Hfauv6W9Q5gc5P pGdzO6xhKW4UVh3pmPDD2Bp4V3BDtHqvJDOPWnUUZGcuRY+CQBPbFxPrbCbnIw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757941861; a=rsa-sha256; cv=none; b=Hgwf6DlHV8FeemTC7XTHu6blwFAMTOZTKqqzNs/unE8yub8dCjkyMwAD0i08V69n4PnTlZ b4ZZreErRGmVLDNceeWhA5Ym5qyPyhpIhv0DvGJ3SUpPXD0oq8y/6zAfknqHkEy1wf+hyC gdttEUomoViGH+hnxvTXAAbBSfBZVJksYCNu317KsRd5CI1WsaU1k3h1j705I8PMm4y3I/ Kf2lnszTTlcUleF/GkYZLDPbKCxCXmHz472eHmUKWmVUlUQVdMTWhstYpHcJ1ShGOeJG21 49NnM2SYMdo9UJZ9p5Mm1WKWxZclS0/3IZsqvS2tl6JTXY8M2R8XVnJo5mIlyg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQQQD72X0zvQ0; Mon, 15 Sep 2025 13:11:00 +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 58FDB0WE072207; Mon, 15 Sep 2025 13:11:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FDB0eo072204; Mon, 15 Sep 2025 13:11:00 GMT (envelope-from git) Date: Mon, 15 Sep 2025 13:11:00 GMT Message-Id: <202509151311.58FDB0eo072204@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: dafd960a3d65 - main - libsamplerate: Define as PRIVATELIB 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: dafd960a3d65cdaccb1f8b9395fad14092ec9eb2 Auto-Submitted: auto-generated The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=dafd960a3d65cdaccb1f8b9395fad14092ec9eb2 commit dafd960a3d65cdaccb1f8b9395fad14092ec9eb2 Author: Christos Margiolis AuthorDate: 2025-09-15 13:09:38 +0000 Commit: Christos Margiolis CommitDate: 2025-09-15 13:09:38 +0000 libsamplerate: Define as PRIVATELIB Fixes the following warnings: ld: error: relocation R_X86_64_32S cannot be used against local symbol; recompile with -fPIC >>> defined in /usr/obj/usr/src/amd64.amd64/lib/libsamplerate/libsamplerate.a(samplerate.o) >>> referenced by samplerate.c:498 (/usr/src/contrib/libsamplerate/samplerate.c:498) >>> >>> samplerate.o:(src_new) in archive /usr/obj/usr/src/amd64.amd64/lib/libsamplerate/libsamplerate.a Related discussion: https://reviews.freebsd.org/D52306 Sponsored by: The FreeBSD Foundation Reviewed by: fuz Differential Revision: https://reviews.freebsd.org/D52307 --- etc/mtree/BSD.usr.dist | 2 ++ lib/libsamplerate/Makefile | 2 +- share/mk/src.libnames.mk | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/etc/mtree/BSD.usr.dist b/etc/mtree/BSD.usr.dist index 7d3a72f43fa1..19da845e962f 100644 --- a/etc/mtree/BSD.usr.dist +++ b/etc/mtree/BSD.usr.dist @@ -26,6 +26,8 @@ .. .. .. + samplerate + .. sqlite3 .. ucl diff --git a/lib/libsamplerate/Makefile b/lib/libsamplerate/Makefile index 256f2087284f..6ca87d8b20ca 100644 --- a/lib/libsamplerate/Makefile +++ b/lib/libsamplerate/Makefile @@ -1,7 +1,7 @@ .PATH: ${SRCTOP}/contrib/libsamplerate LIB= samplerate -INTERNALLIB= +PRIVATELIB= SRCS= samplerate.c \ src_linear.c \ diff --git a/share/mk/src.libnames.mk b/share/mk/src.libnames.mk index 9ca043e7733c..d6597caf7e2a 100644 --- a/share/mk/src.libnames.mk +++ b/share/mk/src.libnames.mk @@ -29,6 +29,7 @@ _PRIVATELIBS= \ heimipcs \ kldelf \ ldns \ + samplerate \ sqlite3 \ ssh \ ucl \ @@ -72,7 +73,6 @@ _INTERNALLIBS= \ pfctl \ pkgecc \ pmcstat \ - samplerate \ sl \ sm \ smdb \ From nobody Mon Sep 15 13:11:02 2025 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 4cQQQG3PjMz67L1H; Mon, 15 Sep 2025 13:11:02 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQQQG16W4z3D7s; Mon, 15 Sep 2025 13:11:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757941862; 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=ZQ4A3mbexEQT7FeqNm4xIA4c37mlrxbiWsmp8SjjDBg=; b=D3TBp+O15Zg7zkx2dsgYa78sJs1hgXV7ZqKnDss2OMvUzLwn+peeJ+icZ3XLwesFG92tPD lcXd71n8K3/cQj614v9V9b16OLDhsZB0kU4sOiqXTMf0aUyiKbAOvGlHgB7wcyjxp1cd1J RotDZ66hr03tL3/9U+VNRHRK0cGvuThBgkcx+tRLHg7iLrVPMucrqfa2b2Hkgs9yKR64Xr dagzC9jqDKmKkXV16EHiREUUzsTG1SCEw489VSzxmhM/vyy+QCEuCCz18Y9YVfTjyAiuTq +WYGIqxxpbTF2iBw2FlWQHO4x3qxe3zXAx5OWKWnqT2lAPbImuFQWZLqJEml0g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757941862; 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=ZQ4A3mbexEQT7FeqNm4xIA4c37mlrxbiWsmp8SjjDBg=; b=BeLTmbVAXFZ1NY5fXYcbB7nCJX3/qTqbKUrdcETSBorWT9b96a1LBSqXvi32YcqXRyA2cC BtHcs8JEObcLPsGYemICkZjBU4UB2AQA4+PFsOiAXHWfpNeamlleRGiu6guRWz7BfnyMyW 1iCkGliDiTTgrFUWZfk2azOtSlM4oX4wG2gkUWsqqePb7Z9hFwTcOpfOyhaB+KelSADgXi XvvEV/rqacr2hXc/x8piqAwc+5Db3C4sdA+QQi1NZVvKPdL1BPQ5uSd/mUbV++JeOONl/H vI7G3nK6QJYbr1Ynzmx4clZqsOvLCk5vSuW/Xb7n4Lhfm3TaC084/QkFt6S4DQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757941862; a=rsa-sha256; cv=none; b=xcYlu8cHLiaDczFxnEbpXiXVBj8tjcXUtrmBuezybOgG+k4vVgJzvtjTyEUYkkssSYUgt6 iXXFdceieaqUpe/tq8dT3SCCb2n3LIDzbDz+8gVMVpvw/kAFkh4JQlQmP543E+ydlRIBkm 8N6zumNSmNJXuqhxmCtMzLvAJtFaM8d1+LGj0d4/gTK3g4tCfH9OY1Z3LfxRo4brNxdMKz 9syclK1V5tj7vnmlu+Sp6E0TVM6lRMsWVRnSMC0DE14CAhxlCvfiJvCcA2f9hzZPuJ1tAX kHQIqJrA0wjWu2BJECYz9YU9Bzbh3Z6YgaqK0pGpDctVShs6DnIZS0E7U/sIrA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQQQG0Z5hzw0w; Mon, 15 Sep 2025 13:11:02 +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 58FDB2ki072241; Mon, 15 Sep 2025 13:11:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FDB2S7072238; Mon, 15 Sep 2025 13:11:02 GMT (envelope-from git) Date: Mon, 15 Sep 2025 13:11:02 GMT Message-Id: <202509151311.58FDB2S7072238@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: 680f9acc3657 - main - ng_hci: Cast NG_HCI_BDADDR_ANY to const bdaddr_t * 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 680f9acc3657efcea07d8ac0954645b6eaf8dac8 Auto-Submitted: auto-generated The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=680f9acc3657efcea07d8ac0954645b6eaf8dac8 commit 680f9acc3657efcea07d8ac0954645b6eaf8dac8 Author: Christos Margiolis AuthorDate: 2025-09-15 13:09:42 +0000 Commit: Christos Margiolis CommitDate: 2025-09-15 13:09:42 +0000 ng_hci: Cast NG_HCI_BDADDR_ANY to const bdaddr_t * This is needed to address some compiler errors cleanly, where consumer functions want this address to be a const pointer. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D52310 --- sys/netgraph/bluetooth/include/ng_hci.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netgraph/bluetooth/include/ng_hci.h b/sys/netgraph/bluetooth/include/ng_hci.h index 44a14e62f4ed..ce3291770740 100644 --- a/sys/netgraph/bluetooth/include/ng_hci.h +++ b/sys/netgraph/bluetooth/include/ng_hci.h @@ -448,7 +448,7 @@ typedef struct { typedef bdaddr_t * bdaddr_p; /* Any BD_ADDR. Note: This is actually 7 bytes (count '\0' terminator) */ -#define NG_HCI_BDADDR_ANY ((bdaddr_p) "\000\000\000\000\000\000") +#define NG_HCI_BDADDR_ANY (&(const bdaddr_t){"\000\000\000\000\000\000"}) /* HCI status return parameter */ typedef struct { From nobody Mon Sep 15 13:33:07 2025 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 4cQQvl52mnz67M6R; Mon, 15 Sep 2025 13:33:07 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQQvl42h3z3H2k; Mon, 15 Sep 2025 13:33:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757943187; 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=Yom6LlgE3Ok8iUO0O4vnI3iyvpcjyQB9My9DSnm1bnA=; b=d5Vou+Z8HB03rTXhc2wuDvMff7mX+OdBnIZUEt40zxgl7PPjZem/LXp+ZDP0fnW1JOZnSG YNL5edYMoqqR4xWtpS/iGb4LICir0Vx9BYNhl6Dbq1DWvMMIyteNYDxCSf0Mw/PUnEKNWw 8TsoCDmsF+xwXUODAM3jerey+dOF9gMxAccRAzjmq6U9DNqnaAO6plLPAIn4QXDVxJlkEi Pq0WJGGOrSKTbMZ2tuh38jmA8HYObHS/kl7icR8kslu4xBPE78izqCT0FGBrtpznbrXuXi 0rp1fqK7D1wOFlMfkvChUQV3u7YiBud4vPoBX5pzT/UTIrb/sflM9jLzNMpy2g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757943187; 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=Yom6LlgE3Ok8iUO0O4vnI3iyvpcjyQB9My9DSnm1bnA=; b=tzWwQ8vAvY1zERLOoMIdU0T0NKwWYkwzvttGpLHP1uUDaZQ5XpoftEXD2rlDQRCZ3bb3KE YQL+FVK45hhxkvN4pzByhkK3zrw7k1mfqmwWjvaWB61p2XpOWQzgQrP8jMh2BSOP47F4OA JuT5TImk3A/Pvr4DTCfg40WrM4ZMJDd7HOQFYfUNd+FrZTet/HObn1BNS82oGjibkHpSDo 0pmcefPx0oI1v0/sHRzSSciuP4SaXi5t0eFsC2aHRgKXfKSBvjs+6Xww8n4PEAaSvnoEzT lGfH7Dx+MZmKGwG4cwuEvnQK87CJrNbGWLh4HdfMKd7CVdKpMSbsVmvhHrERig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757943187; a=rsa-sha256; cv=none; b=V/lKfXG9ofNEIyGDVUtlldhAw0iaqEJjf35tfgFLs0X2FRv2o3kw7U0a6+Vmg8Z8oqZ6bx oGJvaTrdh855jlvAFXJGGG0VNjKee1TsCVxDe7sOqszFY4y9zDNUwCeJyccuTBueluiRkO +PXdTEX3YcWPVKV2nNy/6MneRyX0u7Om6pOfTY7KZr8rV4w46rLY1apHy65Qb7qrca0MDw 9ut1vx1vUCk406QZSkfzME+s0pBaQksUSpVvHYs3SZpA7I+9SKLhyC/W1516oveG8g7Siv AQs4oWHwSUPPuAk9JqbFnrUSIM67sDvef22rKtfZwfbw71HPRh8Tf3wwFM7FgQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQQvl3YRLzxC8; Mon, 15 Sep 2025 13:33:07 +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 58FDX7BE014037; Mon, 15 Sep 2025 13:33:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FDX70N014034; Mon, 15 Sep 2025 13:33:07 GMT (envelope-from git) Date: Mon, 15 Sep 2025 13:33:07 GMT Message-Id: <202509151333.58FDX70N014034@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Turner Subject: git: 8fee6b9ecc84 - main - arm64: Add the new C1 CPU IDs 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: andrew X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8fee6b9ecc84d3602a461f1cd33df91e50849cdf Auto-Submitted: auto-generated The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=8fee6b9ecc84d3602a461f1cd33df91e50849cdf commit 8fee6b9ecc84d3602a461f1cd33df91e50849cdf Author: Andrew Turner AuthorDate: 2025-09-15 12:05:05 +0000 Commit: Andrew Turner CommitDate: 2025-09-15 13:32:18 +0000 arm64: Add the new C1 CPU IDs Add the Arm C1-Nano, C1-Pro, C1-Premium, and C1-Ultra CPUs from their Technical Reference Manuals. Sponsored by: Arm Ltd --- sys/arm64/arm64/identcpu.c | 4 ++++ sys/arm64/include/cpu.h | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/sys/arm64/arm64/identcpu.c b/sys/arm64/arm64/identcpu.c index a001be200518..01b4ece59861 100644 --- a/sys/arm64/arm64/identcpu.c +++ b/sys/arm64/arm64/identcpu.c @@ -232,6 +232,10 @@ static const struct cpu_parts cpu_parts_arm[] = { { CPU_PART_CORTEX_X2, "Cortex-X2" }, { CPU_PART_CORTEX_X3, "Cortex-X3" }, { CPU_PART_CORTEX_X4, "Cortex-X4" }, + { CPU_PART_C1_NANO, "C1-Nano" }, + { CPU_PART_C1_PRO, "C1-Pro" }, + { CPU_PART_C1_PREMIUM, "C1-Premium" }, + { CPU_PART_C1_ULTRA, "C1-Ultra" }, { CPU_PART_NEOVERSE_E1, "Neoverse-E1" }, { CPU_PART_NEOVERSE_N1, "Neoverse-N1" }, { CPU_PART_NEOVERSE_N2, "Neoverse-N2" }, diff --git a/sys/arm64/include/cpu.h b/sys/arm64/include/cpu.h index 07a783138f42..124da8c215ed 100644 --- a/sys/arm64/include/cpu.h +++ b/sys/arm64/include/cpu.h @@ -125,7 +125,11 @@ #define CPU_PART_NEOVERSE_V3 0xD84 #define CPU_PART_CORTEX_X925 0xD85 #define CPU_PART_CORTEX_A725 0xD87 +#define CPU_PART_C1_NANO 0xD8A +#define CPU_PART_C1_PRO 0xD8B +#define CPU_PART_C1_ULTRA 0xD8C #define CPU_PART_NEOVERSE_N3 0xD8E +#define CPU_PART_C1_PREMIUM 0xD90 /* Cavium Part numbers */ #define CPU_PART_THUNDERX 0x0A1 From nobody Mon Sep 15 13:33:08 2025 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 4cQQvm5Mvmz67MXM; Mon, 15 Sep 2025 13:33:08 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQQvm4PRrz3HNg; Mon, 15 Sep 2025 13:33:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757943188; 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=DO6KLdnGNv1vC7U7Mo3WBTGIeYcjMgBpzvQtahMdmE4=; b=aKEsPL7AN7H3oXyP9sToOyD/Qzb5s2uPqd+6jmQkwkI3URMlUxelfPymIHpejCjr8G75Iw 09VwbXnBDraF1i8WPktX+qDKEKbXIq3lMqvVhH3Afc1Sb6ZonRVqMhZK5qtf07oBqRdUfW ts5H82aRVaRYwF+6xrjgyjmOnj1P6aTqv6YNrKqrJnqztJGT/52UemZpB8/EOrIRhcY+rk 1fDPYMCaiP5OmzOnov+MtLmRM2tKdrAm9y9m7z/0Wj7eeRfpHQMlNQo6wx/7Dm8gXI3ibF jQmCSU4QNlmRdWrC6+zJKPBlhtX4LReSGegVZBhqkwvuNnh3LYmSkxNj01CzSg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757943188; 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=DO6KLdnGNv1vC7U7Mo3WBTGIeYcjMgBpzvQtahMdmE4=; b=vEr97rMRMxFVqDsF9YGYldfajmyE9tUDarmIPbWVjvr5IZgqXSvq0shoT+Bh8gwx/1ESMB ZPIGZwxOgLcXGG8S/I8BTzHSI+9QQR4PFcxC6iznkBymHclluJc9SskyDJEBZ50L/l2kog 1TDxJ6Uc4GFs9GpqcZyosZKuNb1ivOAhh82MucfNdHieWhEkmSdZ/fivZ7Is6Ebv+fud06 1FFGbT76UHhLoKe0HTGiM+42E1FZvMoTgTfcfQxGm2UAdUSILPfTIKb2ZNM3wFSLKWGUp4 ME+LKOQcWY9WSZhFc/ez4XW2SGjjBrCNyHDvRHbYer2iLt7guLvyZM+anM/Xow== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757943188; a=rsa-sha256; cv=none; b=D8hxfB/Ma3zAzENg3pSi+egiM6T1OmLl3Y+Iy7h/IshWF7giMTpTJwq73vxt5ELdFECKIm jQCROk477bRruR0gRiooq+W5h/Q0I5yLLXykkLYji2g1YnM4oVklJN+kEzen/7Zzhq0NIT omIg8I2Uj88+n0OHUkS0u1W70ve/UZrms+S+7ZM6LTEXnLn0T1USKZ958fRjBvPwJDJfDE kelEc08Bk+R0MGRsJFEDkDJfGL2TZuud4VNl8GuTL7V9/II6+YBmq7U84aymWQ5G1maIHu jiVLbhmnChQH0nnpUVgNoQbsyqmalM77tv8Yng/xnctyz8StZIf4CGKQq86kqw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQQvm3zkFzwjf; Mon, 15 Sep 2025 13:33:08 +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 58FDX8OZ014070; Mon, 15 Sep 2025 13:33:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FDX8ev014067; Mon, 15 Sep 2025 13:33:08 GMT (envelope-from git) Date: Mon, 15 Sep 2025 13:33:08 GMT Message-Id: <202509151333.58FDX8ev014067@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Turner Subject: git: 226375a1f6e3 - main - arm64: Fix the FEAT_WFxT check 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: andrew X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 226375a1f6e3a71ca250c717e8d6d2c2e4b0b2e7 Auto-Submitted: auto-generated The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=226375a1f6e3a71ca250c717e8d6d2c2e4b0b2e7 commit 226375a1f6e3a71ca250c717e8d6d2c2e4b0b2e7 Author: Andrew Turner AuthorDate: 2025-09-15 12:08:04 +0000 Commit: Andrew Turner CommitDate: 2025-09-15 13:32:18 +0000 arm64: Fix the FEAT_WFxT check The check was always true so would incorrectly enable the feature when it wasn't supported. Due to another bug this was harmless. Sponsored by: Arm Ltd --- sys/arm/arm/generic_timer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/arm/arm/generic_timer.c b/sys/arm/arm/generic_timer.c index 97976408c943..dacef8de2257 100644 --- a/sys/arm/arm/generic_timer.c +++ b/sys/arm/arm/generic_timer.c @@ -889,7 +889,7 @@ wfxt_check(const struct cpu_feat *feat __unused, u_int midr __unused) if (!get_kernel_reg(ID_AA64ISAR2_EL1, &id_aa64isar2)) return (FEAT_ALWAYS_DISABLE); - if (ID_AA64ISAR2_WFxT_VAL(id_aa64isar2) >= ID_AA64ISAR2_WFxT_NONE) + if (ID_AA64ISAR2_WFxT_VAL(id_aa64isar2) >= ID_AA64ISAR2_WFxT_IMPL) return (FEAT_DEFAULT_ENABLE); return (FEAT_ALWAYS_DISABLE); From nobody Mon Sep 15 13:52:30 2025 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 4cQRL73XdKz67Nn2; Mon, 15 Sep 2025 13:52:31 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQRL715l2z3LLq; Mon, 15 Sep 2025 13:52:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757944351; 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=kSBoVhGC9g/5tYEJMCgvbp03KG6ky3AfPKXYaINBKY4=; b=SkdH5AI+9zBHILJKxHn8erZHekEXyZYZrtL+SkmeQFm/bwGp4qJHJG89phan1iuIdgh8hG wLHoUkZ6qRnyRynMFT/m53V1oRUQT4HUTZeLsBF+67H5PydxJqYBV73B52CmY0s58MqVT4 vrEAMlpb+Tlk8SjEXuzxRxl0qEY5LA/4kIz1lmajKAWzoaudkMwn9hXhDlvOLQFwmK9JL5 4uO30V8XK5Q6M2vVlHz6+QzR8O3NcTcZgsgaLdApq0w7mno2ENX8IYeUDnEw0goTXc5Zqt rWUwfryJ7TTl2M5E+rXXwn41RRybz6klFrURQVjBJ4ffLCMNcjHq1qM+UJZTGQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757944351; 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=kSBoVhGC9g/5tYEJMCgvbp03KG6ky3AfPKXYaINBKY4=; b=vqElP3uqsb+kIE6AFnGzsLdJK8//RhbtsHdWkLvj1Wh3GN3j3X2r0tYGW1mDZFs2nZ05rm w+R6ZgQ9PcYhzaa/eXjUMS3b6ReP5fzP/gxzOLPZfUS+UbyDcjVjkRmOQlrJDYNMUihUSa T/qwGPulTqpbmH8nh3jpA51F8W+migJyssAq4KLNnxIqGOAhrfizMp7Y6e7YWAEgESMaRz k6CuPmpc2c2mb7CYBuFA+ix41gpPuZW3wy3iKzvFIO2rHJU82hvVVuhUIjpRyeZAzWFuSl CwzNjyefKHIcyXaKZbnwURo4BZtYGdzoR5SThjCGf6vAmEJyQcnAeTtKfXiwFQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757944351; a=rsa-sha256; cv=none; b=wY4pae6eZq/azqER5038D5CSsnQWN9erQNH5Pfi10k2riZO0+RnQDHFasUyTKdk3Hbal5U cS+qfm/NjwQrMQSmCiHa+WRI7WrdFuoiiX4Wo0F/O9ZuT8w1vFlABeHv/nmKrvIbGSgqz4 5mC0Mh+gQx94jMNfEo/hiXb4UsVTxcNX1RMafOD0Gz9ZSI7EMxcHo1XWkJIN/YAI2N5Fjy Zux4JeAgw3X0BtbdcZu7B63+4IdXx18uUIdEUHQsbdnhAeEua5Kkm+Uq7YpF6L4tWcFnL+ 1CAga8A7vbr+uG8Px6X+nMJ2xiofBdIrjDufNCEWC4aCsVkXGYlNwYx8D93WmA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQRL70jJ7zwh7; Mon, 15 Sep 2025 13:52:31 +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 58FDqVvW051639; Mon, 15 Sep 2025 13:52:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FDqUAv051636; Mon, 15 Sep 2025 13:52:30 GMT (envelope-from git) Date: Mon, 15 Sep 2025 13:52:30 GMT Message-Id: <202509151352.58FDqUAv051636@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 70caaeb8b63f - stable/14 - sys: add MBIM (mobile broadband interface module) interface type. 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: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 70caaeb8b63f9e11e1f495ab3918119c537a8677 Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=70caaeb8b63f9e11e1f495ab3918119c537a8677 commit 70caaeb8b63f9e11e1f495ab3918119c537a8677 Author: Pierre Pronchery AuthorDate: 2025-01-20 23:39:17 +0000 Commit: Ed Maste CommitDate: 2025-09-15 13:51:43 +0000 sys: add MBIM (mobile broadband interface module) interface type. This is part of the upcoming USB umb(4) work. PR: 263783 Approved by: adrian, zlei Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D48167 (cherry picked from commit 86bfbaf1002c88b5c1a6d3ed261becedb533490b) --- sys/net/if_types.h | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/net/if_types.h b/sys/net/if_types.h index 17227726a663..dee71af80a5d 100644 --- a/sys/net/if_types.h +++ b/sys/net/if_types.h @@ -256,6 +256,7 @@ typedef enum { IFT_PFLOG = 0xf6, /* PF packet filter logging */ IFT_PFSYNC = 0xf7, /* PF packet filter synchronization */ IFT_WIREGUARD = 0xf8, /* WireGuard tunnel */ + IFT_MBIM = 0xf9, /* Mobile Broadband Interface Model */ } ifType; /* From nobody Mon Sep 15 14:09:08 2025 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 4cQRjK0PXHz67Pv3; Mon, 15 Sep 2025 14:09:09 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQRjJ6vv9z3MSb; Mon, 15 Sep 2025 14:09:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757945349; 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=tALl1Kbo+4p4zFI/ZJl+0M6i5RHx78txtgBKm4fd9nA=; b=OW9YdtBwo4J1zorOYunzx+lPLhCmlbxzVk1eBo4b9U2nnXf7hE47gG4TC3PAkiNiPAVlUn i72ZIHWzVZd1iKASxh2wJzPoUhTBOAGITovNpSoIiIwfvcjImjGgZ0nnpRO4fnKlEL64EJ BSBhGs8GAaN3B4yjIqREVcp9L+w111YCUOe6BudSAzWieYdJFwRjp+LPMgOiGqEmv7lqc6 Wa6iR7ZL5NKwzJ3jr2HW5EU7ET7m8MgimG8NwgT09b6yaFy6T9lWJ7bEn0/2efU9Z74ebD Rj7l8scsoJXxYo/5dZdGiS3u48uBwy3DHdIEzIplEpIDOxNYZ3Bx8NKL/IeAIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757945349; 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=tALl1Kbo+4p4zFI/ZJl+0M6i5RHx78txtgBKm4fd9nA=; b=E9z0F5TMSy1ksv5p19EGzvy28p7tsF2pd0UBbBCBh5S1K8c3Bh6G4hkeL6LTQ/xiRmab6u i38IDOZQpDXUVocGfPmrEdKTarJ4Q3wXvwj/aB1nl5XOP6F0OtVi3pPl21LCoTUkZdX4GS LOYzInjgC/R6EGlL+stsmFbG/bcoNM6FfB20nSZBYJmdCPd780mP8OYe0y1IovCRwXPBxg BPke08MPwNkTtub+yRoEPBnn90LzRRdY6oG2P2vSlgjNoYhBkbBGXcBM2gdcymkl2G4SEI ThA3zPLyJiI7SVESEuOvjQla2DA7aQgZkvLIwUE9wzSwWon9zaZyDSsKHnxVKw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757945349; a=rsa-sha256; cv=none; b=l94MyKe+vOavbfn6ct1Jx2/HYzaum8rnWQ1bgqiyxqYB+jbh4tEwrEovLJweYrvfifoAwM xcKC5ZZpqNCZxchQnbb8jrgsMlb2HaRqrKVGU/Fw+Mt2uB2uLcHTQQxFnDQbPvfqZiibQI m5DHkOBYChZulmLatXqWdJqaWinVRZPYFZYKfjpiq9a3oQk/7HXsCOhQvO1TKQXtpdX4MS mCYudgzvGLC4/NJXDZ5pGISfzsODWQVfcXczPKej8B3OVVdH6FJeM8XAvurk7qbC4szNNP qfD9IXwPj0ndJ/zyyXxIFu3Tx9Y+4b3C3o75s41GYR/8Gm950Hzwghms/AOsmw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQRjJ6KTHzx31; Mon, 15 Sep 2025 14:09:08 +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 58FE98KU074031; Mon, 15 Sep 2025 14:09:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FE98om074028; Mon, 15 Sep 2025 14:09:08 GMT (envelope-from git) Date: Mon, 15 Sep 2025 14:09:08 GMT Message-Id: <202509151409.58FE98om074028@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: 7fbd362c091b - main - qat: enable qat driver for 402xx device 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7fbd362c091b2b384d14c3ed5af9234bb2eff9c2 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=7fbd362c091b2b384d14c3ed5af9234bb2eff9c2 commit 7fbd362c091b2b384d14c3ed5af9234bb2eff9c2 Author: Hareshx Sankar Raj AuthorDate: 2025-09-04 18:21:36 +0000 Commit: Mark Johnston CommitDate: 2025-09-15 13:48:45 +0000 qat: enable qat driver for 402xx device Enabled qat driver support for 402xx device with ID 0x4944/0x4945. This is an additional device supported under the existing qat_4xxx driver. Firmwares specific to the 402xx device are added. Signed-off-by: Hareshx Sankar Raj Relnotes: yes Sponsored by: Intel Corporation MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D52488 --- sys/contrib/dev/qat/qat_402xx.bin | Bin 0 -> 665360 bytes sys/contrib/dev/qat/qat_402xx_mmp.bin | Bin 0 -> 150084 bytes sys/dev/qat/include/common/adf_accel_devices.h | 4 ++ sys/dev/qat/qat_api/include/icp_sal_versions.h | 2 +- sys/dev/qat/qat_common/qat_uclo.c | 1 + sys/dev/qat/qat_hw/qat_4xxx/adf_4xxx_hw_data.c | 58 +++++++++++++++++++------ sys/dev/qat/qat_hw/qat_4xxx/adf_4xxx_hw_data.h | 6 +++ sys/dev/qat/qat_hw/qat_4xxx/adf_drv.c | 15 ++++--- sys/dev/qat/qat_hw/qat_4xxxvf/adf_drv.c | 15 ++++--- sys/modules/qatfw/qat_4xxx/Makefile | 5 ++- 10 files changed, 78 insertions(+), 28 deletions(-) diff --git a/sys/contrib/dev/qat/qat_402xx.bin b/sys/contrib/dev/qat/qat_402xx.bin new file mode 100644 index 000000000000..74151547edce Binary files /dev/null and b/sys/contrib/dev/qat/qat_402xx.bin differ diff --git a/sys/contrib/dev/qat/qat_402xx_mmp.bin b/sys/contrib/dev/qat/qat_402xx_mmp.bin new file mode 100644 index 000000000000..6404eb009d2f Binary files /dev/null and b/sys/contrib/dev/qat/qat_402xx_mmp.bin differ diff --git a/sys/dev/qat/include/common/adf_accel_devices.h b/sys/dev/qat/include/common/adf_accel_devices.h index c09aee8ea4bd..eeffc6a9132c 100644 --- a/sys/dev/qat/include/common/adf_accel_devices.h +++ b/sys/dev/qat/include/common/adf_accel_devices.h @@ -39,12 +39,16 @@ #define ADF_4XXXIOV_PCI_DEVICE_ID 0x4941 #define ADF_401XX_PCI_DEVICE_ID 0x4942 #define ADF_401XXIOV_PCI_DEVICE_ID 0x4943 +#define ADF_402XX_PCI_DEVICE_ID 0x4944 +#define ADF_402XXIOV_PCI_DEVICE_ID 0x4945 #define IS_QAT_GEN3(ID) ({ (ID == ADF_C4XXX_PCI_DEVICE_ID); }) static inline bool IS_QAT_GEN4(const unsigned int id) { return (id == ADF_4XXX_PCI_DEVICE_ID || id == ADF_401XX_PCI_DEVICE_ID || + id == ADF_402XX_PCI_DEVICE_ID || + id == ADF_402XXIOV_PCI_DEVICE_ID || id == ADF_4XXXIOV_PCI_DEVICE_ID || id == ADF_401XXIOV_PCI_DEVICE_ID); } diff --git a/sys/dev/qat/qat_api/include/icp_sal_versions.h b/sys/dev/qat/qat_api/include/icp_sal_versions.h index 03bcef4fcbbb..0eb227ade09c 100644 --- a/sys/dev/qat/qat_api/include/icp_sal_versions.h +++ b/sys/dev/qat/qat_api/include/icp_sal_versions.h @@ -26,7 +26,7 @@ /* Part name and number of the accelerator device */ #define SAL_INFO2_DRIVER_SW_VERSION_MAJ_NUMBER 3 -#define SAL_INFO2_DRIVER_SW_VERSION_MIN_NUMBER 15 +#define SAL_INFO2_DRIVER_SW_VERSION_MIN_NUMBER 16 #define SAL_INFO2_DRIVER_SW_VERSION_PATCH_NUMBER 0 /** diff --git a/sys/dev/qat/qat_common/qat_uclo.c b/sys/dev/qat/qat_common/qat_uclo.c index 54e8e8eb7421..b17020286d24 100644 --- a/sys/dev/qat/qat_common/qat_uclo.c +++ b/sys/dev/qat/qat_common/qat_uclo.c @@ -892,6 +892,7 @@ qat_uclo_get_dev_type(struct icp_qat_fw_loader_handle *handle) return ICP_QAT_AC_C4XXX_DEV_TYPE; case ADF_4XXX_PCI_DEVICE_ID: case ADF_401XX_PCI_DEVICE_ID: + case ADF_402XX_PCI_DEVICE_ID: return ICP_QAT_AC_4XXX_A_DEV_TYPE; default: pr_err("QAT: unsupported device 0x%x\n", diff --git a/sys/dev/qat/qat_hw/qat_4xxx/adf_4xxx_hw_data.c b/sys/dev/qat/qat_hw/qat_4xxx/adf_4xxx_hw_data.c index d730efd5952b..49e1e1859e78 100644 --- a/sys/dev/qat/qat_hw/qat_4xxx/adf_4xxx_hw_data.c +++ b/sys/dev/qat/qat_hw/qat_4xxx/adf_4xxx_hw_data.c @@ -536,8 +536,8 @@ adf_exit_accel_units(struct adf_accel_dev *accel_dev) } static const char * -get_obj_name(struct adf_accel_dev *accel_dev, - enum adf_accel_unit_services service) +get_obj_name_4xxx(struct adf_accel_dev *accel_dev, + enum adf_accel_unit_services service) { switch (service) { case ADF_ACCEL_ASYM: @@ -553,6 +553,24 @@ get_obj_name(struct adf_accel_dev *accel_dev, } } +static const char * +get_obj_name_402xx(struct adf_accel_dev *accel_dev, + enum adf_accel_unit_services service) +{ + switch (service) { + case ADF_ACCEL_ASYM: + return ADF_402XX_ASYM_OBJ; + case ADF_ACCEL_CRYPTO: + return ADF_402XX_SYM_OBJ; + case ADF_ACCEL_COMPRESSION: + return ADF_402XX_DC_OBJ; + case ADF_ACCEL_ADMIN: + return ADF_402XX_ADMIN_OBJ; + default: + return NULL; + } +} + static uint32_t get_objs_num(struct adf_accel_dev *accel_dev) { @@ -982,8 +1000,23 @@ adf_init_hw_data_4xxx(struct adf_hw_device_data *hw_data, u32 id) hw_data->clock_frequency = ADF_4XXX_AE_FREQ; hw_data->get_sku = get_sku; hw_data->heartbeat_ctr_num = ADF_NUM_HB_CNT_PER_AE; - hw_data->fw_name = ADF_4XXX_FW; - hw_data->fw_mmp_name = ADF_4XXX_MMP; + switch (id) { + case ADF_402XX_PCI_DEVICE_ID: + hw_data->fw_name = ADF_402XX_FW; + hw_data->fw_mmp_name = ADF_402XX_MMP; + hw_data->asym_ae_active_thd_mask = DEFAULT_4XXX_ASYM_AE_MASK; + break; + case ADF_401XX_PCI_DEVICE_ID: + hw_data->fw_name = ADF_4XXX_FW; + hw_data->fw_mmp_name = ADF_4XXX_MMP; + hw_data->asym_ae_active_thd_mask = DEFAULT_401XX_ASYM_AE_MASK; + break; + + default: + hw_data->fw_name = ADF_4XXX_FW; + hw_data->fw_mmp_name = ADF_4XXX_MMP; + hw_data->asym_ae_active_thd_mask = DEFAULT_4XXX_ASYM_AE_MASK; + } hw_data->init_admin_comms = adf_init_admin_comms; hw_data->exit_admin_comms = adf_exit_admin_comms; hw_data->send_admin_init = adf_4xxx_send_admin_init; @@ -1002,7 +1035,13 @@ adf_init_hw_data_4xxx(struct adf_hw_device_data *hw_data, u32 id) hw_data->get_ring_svc_map_data = get_ring_svc_map_data; hw_data->admin_ae_mask = ADF_4XXX_ADMIN_AE_MASK; hw_data->get_objs_num = get_objs_num; - hw_data->get_obj_name = get_obj_name; + switch (id) { + case ADF_402XX_PCI_DEVICE_ID: + hw_data->get_obj_name = get_obj_name_402xx; + break; + default: + hw_data->get_obj_name = get_obj_name_4xxx; + } hw_data->get_obj_cfg_ae_mask = get_obj_cfg_ae_mask; hw_data->get_service_type = adf_4xxx_get_service_type; hw_data->set_msix_rttable = set_msix_default_rttable; @@ -1022,15 +1061,6 @@ adf_init_hw_data_4xxx(struct adf_hw_device_data *hw_data, u32 id) hw_data->query_storage_cap = 1; hw_data->ring_pair_reset = adf_gen4_ring_pair_reset; - switch (id) { - case ADF_401XX_PCI_DEVICE_ID: - hw_data->asym_ae_active_thd_mask = DEFAULT_401XX_ASYM_AE_MASK; - break; - case ADF_4XXX_PCI_DEVICE_ID: - default: - hw_data->asym_ae_active_thd_mask = DEFAULT_4XXX_ASYM_AE_MASK; - } - adf_gen4_init_hw_csr_info(&hw_data->csr_info); adf_gen4_init_pf_pfvf_ops(&hw_data->csr_info.pfvf_ops); } diff --git a/sys/dev/qat/qat_hw/qat_4xxx/adf_4xxx_hw_data.h b/sys/dev/qat/qat_hw/qat_4xxx/adf_4xxx_hw_data.h index c35ebbcadcd7..fa7249dca596 100644 --- a/sys/dev/qat/qat_hw/qat_4xxx/adf_4xxx_hw_data.h +++ b/sys/dev/qat/qat_hw/qat_4xxx/adf_4xxx_hw_data.h @@ -87,6 +87,12 @@ #define ADF_4XXX_SYM_OBJ "qat_4xxx_sym.bin" #define ADF_4XXX_ASYM_OBJ "qat_4xxx_asym.bin" #define ADF_4XXX_ADMIN_OBJ "qat_4xxx_admin.bin" +#define ADF_402XX_FW "qat_402xx_fw" +#define ADF_402XX_MMP "qat_402xx_mmp_fw" +#define ADF_402XX_DC_OBJ "qat_402xx_dc.bin" +#define ADF_402XX_SYM_OBJ "qat_402xx_sym.bin" +#define ADF_402XX_ASYM_OBJ "qat_402xx_asym.bin" +#define ADF_402XX_ADMIN_OBJ "qat_402xx_admin.bin" /* Only 3 types of images can be loaded including the admin image */ #define ADF_4XXX_MAX_OBJ 3 diff --git a/sys/dev/qat/qat_hw/qat_4xxx/adf_drv.c b/sys/dev/qat/qat_hw/qat_4xxx/adf_drv.c index cb534dd03b86..f9ad39fa45f0 100644 --- a/sys/dev/qat/qat_hw/qat_4xxx/adf_drv.c +++ b/sys/dev/qat/qat_hw/qat_4xxx/adf_drv.c @@ -22,12 +22,14 @@ static MALLOC_DEFINE(M_QAT_4XXX, "qat_4xxx", "qat_4xxx"); PCI_VENDOR_ID_INTEL, device_id \ } -static const struct pci_device_id adf_pci_tbl[] = - { ADF_SYSTEM_DEVICE(ADF_4XXX_PCI_DEVICE_ID), - ADF_SYSTEM_DEVICE(ADF_401XX_PCI_DEVICE_ID), - { - 0, - } }; +static const struct pci_device_id adf_pci_tbl[] = { + ADF_SYSTEM_DEVICE(ADF_4XXX_PCI_DEVICE_ID), + ADF_SYSTEM_DEVICE(ADF_401XX_PCI_DEVICE_ID), + ADF_SYSTEM_DEVICE(ADF_402XX_PCI_DEVICE_ID), + { + 0, + } +}; static int adf_probe(device_t dev) @@ -135,6 +137,7 @@ adf_cleanup_accel(struct adf_accel_dev *accel_dev) switch (pci_get_device(accel_pci_dev->pci_dev)) { case ADF_4XXX_PCI_DEVICE_ID: case ADF_401XX_PCI_DEVICE_ID: + case ADF_402XX_PCI_DEVICE_ID: adf_clean_hw_data_4xxx(accel_dev->hw_device); break; default: diff --git a/sys/dev/qat/qat_hw/qat_4xxxvf/adf_drv.c b/sys/dev/qat/qat_hw/qat_4xxxvf/adf_drv.c index 2bbccb4d6b17..dbe40835ccbf 100644 --- a/sys/dev/qat/qat_hw/qat_4xxxvf/adf_drv.c +++ b/sys/dev/qat/qat_hw/qat_4xxxvf/adf_drv.c @@ -22,12 +22,14 @@ static MALLOC_DEFINE(M_QAT_4XXXVF, "qat_4xxxvf", "qat_4xxxvf"); PCI_VENDOR_ID_INTEL, device_id \ } -static const struct pci_device_id adf_pci_tbl[] = - { ADF_SYSTEM_DEVICE(ADF_4XXXIOV_PCI_DEVICE_ID), - ADF_SYSTEM_DEVICE(ADF_401XXIOV_PCI_DEVICE_ID), - { - 0, - } }; +static const struct pci_device_id adf_pci_tbl[] = { + ADF_SYSTEM_DEVICE(ADF_4XXXIOV_PCI_DEVICE_ID), + ADF_SYSTEM_DEVICE(ADF_401XXIOV_PCI_DEVICE_ID), + ADF_SYSTEM_DEVICE(ADF_402XXIOV_PCI_DEVICE_ID), + { + 0, + } +}; static int adf_probe(device_t dev) @@ -76,6 +78,7 @@ adf_cleanup_accel(struct adf_accel_dev *accel_dev) switch (pci_get_device(accel_pci_dev->pci_dev)) { case ADF_4XXXIOV_PCI_DEVICE_ID: case ADF_401XXIOV_PCI_DEVICE_ID: + case ADF_402XXIOV_PCI_DEVICE_ID: adf_clean_hw_data_4xxxiov(accel_dev->hw_device); break; default: diff --git a/sys/modules/qatfw/qat_4xxx/Makefile b/sys/modules/qatfw/qat_4xxx/Makefile index fb7171bcaf45..f6f19d6cbe32 100644 --- a/sys/modules/qatfw/qat_4xxx/Makefile +++ b/sys/modules/qatfw/qat_4xxx/Makefile @@ -4,6 +4,9 @@ KMOD= qat_4xxx_fw -FIRMWS= qat_4xxx.bin:qat_4xxx_fw:111 qat_4xxx_mmp.bin:qat_4xxx_mmp_fw:111 +FIRMWS= qat_4xxx.bin:qat_4xxx_fw:111 \ + qat_4xxx_mmp.bin:qat_4xxx_mmp_fw:111 \ + qat_402xx.bin:qat_402xx_fw:111 \ + qat_402xx_mmp.bin:qat_402xx_mmp_fw:111 .include From nobody Mon Sep 15 14:09:09 2025 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 4cQRjL1HKZz67Q9X; Mon, 15 Sep 2025 14:09:10 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQRjL0ZNWz3MwP; Mon, 15 Sep 2025 14:09:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757945350; 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=HtU1xlqBZXOAjBn0w21bk4emV8iDx5JUHgoKuDcN45s=; b=Bgb8xwIi/L04/xyZpH/+u8YP+w10a97eTOZrd2WohbJ2vwSWGU5XtA0DhM9yXikxzmAPQc KQ9VwvmtngNV2De4Qsr9V1Td0KXAbHOjWz66jFEUlLRhTiZlc6NCFwbhKGDFvjEIbc25BI lMfiacaM1+ToTOMiXxMCOb9ba84w5zP6VZAfsClQZJCnSmyRc+VsEdQaHQsnvCZ3hPdDph 9HjQB0UlxVNRRBvMmNTnOFFHw+AFvf5xyEsKpRPpR2Is+mtcwvsoF+355FzQenJx/kqCtj wxnipNXnQXKHut2KDQtLorw5zz+zKyRKE4s9j25k91oYv0Q+g3+bBHuGmaQjdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757945350; 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=HtU1xlqBZXOAjBn0w21bk4emV8iDx5JUHgoKuDcN45s=; b=v76IElDxU93mCrZtbn00zH6yopjp5rxJliCWxVdW1UkvHBUWIWa+UwZC6w7tmH5YyfVnzJ S1dI8ChN14Nfdxd4yQit4/N7T6lc+v0DMfSIHhwchwEwmSmd3TF1ZPlwDwswi2rPe8qwzZ F1nqSLrQph5Ht8xrtV2mQKuFVN1s14ksafQZWeeZ8RE7WnwmxOlsfG3JeOA5pYx4E3/OJD UkqVIbGXljsaCbyaBU67LrkQ+Ik+ipYuD17Oi90TwvukzkhZnyP3fOBTJwUSQL2nDR2TUF TPm36xotR+eywAiQnQUKaZrCzxnJxQ6bjGWMWO0rdj8gqO7B1cTFhuAKnQFs3w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757945350; a=rsa-sha256; cv=none; b=k5BLdHLBpyzrY2DA7yXgrENErmhD/XKMGV0UGViXY6eX+3jSfhIMkULJrUxw0zXCAaq4uR ewkLWENbKPwUww4kIc9xyIHH+lshjf4FsgXX+60FqTWftOCga5Y1NglVtdY8O40QMMdmci oVNsLmUnhehXe3xrEwWt2vxJ5+pZlHnpOFm7A4jPrR33oZLYiLz9tmxCfiRH5hSyiWE2Rf hsliqVX9lai7uXpYK45JgxrmhXRYuWI+7DwlcR8p76zqCR2OILNRjysgS1SHI09sNvloDu hoFrIAjNWAohEyzqv+COGsPy6tFXqwanQCGm97hhxgMtMGlJtdS/ZkMkuGJhgA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQRjL08zGzxWX; Mon, 15 Sep 2025 14:09:10 +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 58FE99Of074063; Mon, 15 Sep 2025 14:09:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FE99QY074060; Mon, 15 Sep 2025 14:09:09 GMT (envelope-from git) Date: Mon, 15 Sep 2025 14:09:09 GMT Message-Id: <202509151409.58FE99QY074060@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: 18fd3f8ec5c5 - main - ng_btsocket_rfcomm: Mark a couple buffers as const in a helper function 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 18fd3f8ec5c50da21515757af24421a078a4a468 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=18fd3f8ec5c50da21515757af24421a078a4a468 commit 18fd3f8ec5c50da21515757af24421a078a4a468 Author: Mark Johnston AuthorDate: 2025-09-15 13:57:19 +0000 Commit: Mark Johnston CommitDate: 2025-09-15 13:57:19 +0000 ng_btsocket_rfcomm: Mark a couple buffers as const in a helper function Fixes: 680f9acc3657 ("ng_hci: Cast NG_HCI_BDADDR_ANY to const bdaddr_t *") --- sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c b/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c index 6c0a6fda1fb1..73a0897857b2 100644 --- a/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c +++ b/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c @@ -113,7 +113,7 @@ static void ng_btsocket_rfcomm_connect_cfm static int ng_btsocket_rfcomm_session_create (ng_btsocket_rfcomm_session_p *sp, struct socket *l2so, - bdaddr_p src, bdaddr_p dst, struct thread *td); + const bdaddr_t *src, const bdaddr_t *dst, struct thread *td); static int ng_btsocket_rfcomm_session_accept (ng_btsocket_rfcomm_session_p s0); static int ng_btsocket_rfcomm_session_connect @@ -1250,7 +1250,7 @@ ng_btsocket_rfcomm_connect_cfm(ng_btsocket_rfcomm_session_p s) static int ng_btsocket_rfcomm_session_create(ng_btsocket_rfcomm_session_p *sp, - struct socket *l2so, bdaddr_p src, bdaddr_p dst, + struct socket *l2so, const bdaddr_t *src, const bdaddr_t *dst, struct thread *td) { ng_btsocket_rfcomm_session_p s = NULL; From nobody Mon Sep 15 14:09:11 2025 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 4cQRjM2j9Zz67Q54; Mon, 15 Sep 2025 14:09:11 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQRjM1DK3z3Mr4; Mon, 15 Sep 2025 14:09:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757945351; 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=8KmA5WXiGbjESSoXOxXVJS7fmEUFBdAuI9dtagXG5eo=; b=ZaMDJa/dfWPuF7ngJl4muWAai1inGgfArt7uIHH3EWy3YT+eZFgZcuA+saMMtpMFKQJABK YGhp5e63HYqTrOUSDKECwmkN8Z3NccwSsM+K0zVrI1nMy3MOlc++VsqsMK020seNDNAgEi IGEDSMOD/wwb65lfYHxX7aNDowJDc9sndam0osex5l/69ANWntb6G6B0h4CW46mFxmwcIr Ni+qDdh6x0YenwFaeVL1y/L+zQCdTzFJdxUFkC50kPJ4GYHcPld1s9B4MgZnlnH7VD+9Fh R/RQhbC6MoRHyofx4V6AwxINqIa0gw6oqpWDZfyH22T+LU49/dQ6+2TlVxuUnw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757945351; 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=8KmA5WXiGbjESSoXOxXVJS7fmEUFBdAuI9dtagXG5eo=; b=pG06LtXqpmkU6FZ5/cySBsVsuff8hGOfiXl7H8BVAXX9pHaKUxrjUGlXZJFWs0V8QKeJWm RLXuW+iWRLcHhx3H+g2nBXeis8tZ7iEwHORM25wHktzFFjNt6dwHRA+Pj11it1n7eOmQcM 32Ga4yylPE25c6HtMQzGl9bccxuGSE8e+kayJB3j1NXQenW0Ln8ZEbRMzlu+sByW7nY40M os2CNMDtxnZXOmz+9j8S0UrgU5dSNPjqXvB1z1AWkVQp9wdvkgwMe9RixfkzN1IfiuKhtO +G8A7p6gr+7SazaBNXRJt6EK0QEodcO9AFDQ6cxYv3NjV8fHEHVBz3ArSmm6ew== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757945351; a=rsa-sha256; cv=none; b=POFcqC44imJTZhK4CoRDYe1leN9rplIIwkvS9qXrO653G5j6boDDqwuBSBvwD/Pb7xWKoi lY5KwkyQIqhnUs3++zksL4YRXl0QKJ0Fzps6vcQl0bSRCgn2f0u1uB16eWXwDQ5bpbvW3c ATZzwhXnCgscMdBNjvH3atPgEHN7iv9cr+ujzKnAd5Bsduo++ZDdVRUvvr4KIqH2Z9/bSA YUerwq4xErvQyKd+cHa/A1uHe3y7LzjICm67XQtMEBd8k7z/cmR6MZJayOTElvd6mQ/+U/ 17gJaGgkyws31h7TJGKm9ZplxF+pJlx5ls838z3Nm141TT7BG7Uu6TlI3QrG2g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQRjM0nD8zxYk; Mon, 15 Sep 2025 14:09:11 +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 58FE9BCE074102; Mon, 15 Sep 2025 14:09:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FE9BsE074099; Mon, 15 Sep 2025 14:09:11 GMT (envelope-from git) Date: Mon, 15 Sep 2025 14:09:11 GMT Message-Id: <202509151409.58FE9BsE074099@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: 081f0e38e332 - main - zfs: Use the correct type for raidz_outlier_check_interval_ms 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 081f0e38e3324dd3ca63a2d5036a15f52e6cf858 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=081f0e38e3324dd3ca63a2d5036a15f52e6cf858 commit 081f0e38e3324dd3ca63a2d5036a15f52e6cf858 Author: Mark Johnston AuthorDate: 2025-09-15 14:07:35 +0000 Commit: Mark Johnston CommitDate: 2025-09-15 14:07:35 +0000 zfs: Use the correct type for raidz_outlier_check_interval_ms raidz_outlier_check_interval_ms has type hrtime_t, which is a long long, which is 64 bits wide on all supported platforms. --- sys/contrib/openzfs/module/zfs/vdev_raidz.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/contrib/openzfs/module/zfs/vdev_raidz.c b/sys/contrib/openzfs/module/zfs/vdev_raidz.c index 80727b0d8f91..56b8e3b60b22 100644 --- a/sys/contrib/openzfs/module/zfs/vdev_raidz.c +++ b/sys/contrib/openzfs/module/zfs/vdev_raidz.c @@ -5495,7 +5495,7 @@ ZFS_MODULE_PARAM(zfs, zfs_, scrub_after_expand, INT, ZMOD_RW, "completes"); ZFS_MODULE_PARAM(zfs_vdev, vdev_, read_sit_out_secs, ULONG, ZMOD_RW, "Raidz/draid slow disk sit out time period in seconds"); -ZFS_MODULE_PARAM(zfs_vdev, vdev_, raidz_outlier_check_interval_ms, ULONG, +ZFS_MODULE_PARAM(zfs_vdev, vdev_, raidz_outlier_check_interval_ms, U64, ZMOD_RW, "Interval to check for slow raidz/draid children"); ZFS_MODULE_PARAM(zfs_vdev, vdev_, raidz_outlier_insensitivity, UINT, ZMOD_RW, "How insensitive the slow raidz/draid child check should be"); From nobody Mon Sep 15 14:12:48 2025 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 4cQRnX6WZqz67PyK; Mon, 15 Sep 2025 14:12:48 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQRnX631Lz3QDs; Mon, 15 Sep 2025 14:12:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757945568; 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=x+X7cHWm6+XlPNcqxj3INm4ULbsgbKa4LJhjoAreVQk=; b=IVb3ngY0VI+eFvzrz4/hRgzkvM3Wy4WSUP5EgGD9iygIdDqSngIinqQ/Z7SOtfqhpFypGm VWRb85043ejW2k5llH9SHvKP+KjpjYruatUcKstqJ97VrcjTR45k2kOuMCx8wdoompVgxL I7GUDld2ChxNBBbPIAoOaJaDZscLkt0KbaBfrtO4xJMPnH1IAq1SXHjAlDVLgteMt1oYgi qlSm7ryo+uYjPDNSerDFszcI6y4iDgdh/lb+O2j0Fvq4IUZ8HOwjLFKz2QemMeKfAZRQrR lzclVMf2isdGAFNehne/a6BD8QZppShxXG1JOzttIhRo1ei1QVWcUs9Kt+yUnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757945568; 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=x+X7cHWm6+XlPNcqxj3INm4ULbsgbKa4LJhjoAreVQk=; b=NG2xBYPTqMxP9Vqz7OO/EeneLb1IMf2kbN1Lj/vFqF5zRtrJ+niC8mnr7/XGWIoRYWqcJO js8S2+XDUvn7Z8vCAgiaWunr9XqJLj2WvZLH48NMaFiX75LVzlaM3hlamT3zf+YB1mk+xy tZ1mGsQ3CVZES+OV0nr80I+fIPEfJsLDRcdjCOyjevBkP9rpDYbYeh5drGU+OVatUuYfrY wLlOhYTHOBDQ6mF87nmHaKzjWlOYosKkmTrDqSC9rYRHMCBHsWlZgsYToVW7GdpgR5Jucp nmYNE4hR1DNaELmooxG7oHlrjsSV6r5mHcOS8xWC4lq3K6Iuv3lIzL/Gh0Q5/w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757945568; a=rsa-sha256; cv=none; b=lpOkHk52F5GHwNvf1mrQnbWylD1t0vpTSE/fO+i3WakQ+9hi+sX3fpRt0pFzppWyNmSMdC 5xgx1oz+9KW5gLXStKYedc++oXUHs0Ty7bb/yxLOt0/dpZ4cauK4xHaxnoTBukiZVm4dlQ B2IVLtfs/JqqCgUqJ5RQhZdASD6Z8pLOpE2RqeWkmoa+YrizA9ocZ6w1Ihb95kXNoqEWyS 49tNgIuYgE/vLXENGEKbl1icF5aXnqpBKYwgFEa+Xp/uXro5CZpYuTzEwckO4G9R0ezZn1 SJ4QvweItm3a2h8oc1EJ7Q/C0VI9TioLFN8O2S712PCgHO5Y9baMMqIBfrlYAA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQRnX5cgfzxyX; Mon, 15 Sep 2025 14:12:48 +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 58FECmF8091259; Mon, 15 Sep 2025 14:12:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FECmcW091256; Mon, 15 Sep 2025 14:12:48 GMT (envelope-from git) Date: Mon, 15 Sep 2025 14:12:48 GMT Message-Id: <202509151412.58FECmcW091256@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: f1b656f14464 - main - vm_fault_busy_sleep(): update comment after addition of allocflags arg 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/main X-Git-Reftype: branch X-Git-Commit: f1b656f14464c2e3ec4ab2eeade3b00dce4bd459 Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=f1b656f14464c2e3ec4ab2eeade3b00dce4bd459 commit f1b656f14464c2e3ec4ab2eeade3b00dce4bd459 Author: Konstantin Belousov AuthorDate: 2025-09-15 00:52:47 +0000 Commit: Konstantin Belousov CommitDate: 2025-09-15 14:11:57 +0000 vm_fault_busy_sleep(): update comment after addition of allocflags arg Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D52538 --- sys/vm/vm_fault.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/sys/vm/vm_fault.c b/sys/vm/vm_fault.c index 3dddc7a307d4..524aed2be2ff 100644 --- a/sys/vm/vm_fault.c +++ b/sys/vm/vm_fault.c @@ -1456,11 +1456,10 @@ vm_fault_getpages(struct faultstate *fs, int *behindp, int *aheadp) * and we could end up trying to pagein and pageout the same page * simultaneously. * - * We can theoretically allow the busy case on a read fault if the page - * is marked valid, but since such pages are typically already pmap'd, - * putting that special case in might be more effort then it is worth. - * We cannot under any circumstances mess around with a shared busied - * page except, perhaps, to pmap it. + * We allow the busy case on a read fault if the page is valid. We + * cannot under any circumstances mess around with a shared busied + * page except, perhaps, to pmap it. This is controlled by the + * VM_ALLOC_SBUSY bit in the allocflags argument. */ static void vm_fault_busy_sleep(struct faultstate *fs, int allocflags) From nobody Mon Sep 15 14:45:09 2025 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 4cQSVs4LLqz67RvK; Mon, 15 Sep 2025 14:45:09 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQSVs3nVhz3Ryv; Mon, 15 Sep 2025 14:45:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757947509; 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=C2Hoe4GKga5zTRjJTksnPrlAA72PV2JYx83UhpPznIo=; b=DQyOBri37gkYl6KToGGA9gJyH9EBJJiVIxx6z4CEjx/9PLQfO6zzenPj+emnwOARRUt0st b4/UFWGvOURDKpTwYy/jmvslmH912rGnO0COJBS3bniEQFgzi9PeCGxICnZaz5q3fj5Imo 0sRUvASQ/dJJwzH9zuanx09ZXfd9b1oTeep8VrB8tmM7Xuu6tdsrAEzU/CWI35T6b6hzIY 8uH68PaOeNObIRDpE5lXEaFJRch62FYuQLhQfrTpiTJ1VYM/V67+AjBF0pjLkohGpNeu8H 0FqVW8LqE1vJ2pbczaR9hhU9yRZq54GWT3IH2J0hkqzWO01dTdSvUS6gLp+FHg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757947509; 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=C2Hoe4GKga5zTRjJTksnPrlAA72PV2JYx83UhpPznIo=; b=vIqRl0MBY3vjPENg9ci61+wdho1v2gGIFSaVhXcn+4b9OjWaRWzI3VBB7VKdbPZZwQ6zai bUq8iVvi1vLq3BAXHgdZVKUW27Yn/ua7as8PmYBAZNllEv2WzJf+CS0GTa2j+I9OLbW7dZ o4TgU+Ks1/lksa9ZmWiijxWp+19ymKZCssAj9LLwVWF/9jjRHKVwYO4fwLH7jNmKz99jBy WGXnbnEH0bRs1YXcLt+9uu/zHrV0IkCHTvSVOxwwg9TsNyTb7Kqg9T8EoxoWYIpGmMvl17 2tKAmw6zDd1ZfeG+qXiL7GUusnA0eX5YNdli0oHn0PcT/u3VlWG7Ki4+H4gsQg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757947509; a=rsa-sha256; cv=none; b=hN2zORCrcQSUOvyZkBNuVXtq07fsfCV4dHmBjns27hgzts4soq5Rw1oAsLm7ptzUN8Z1wJ nreK5m//nWjvAOaLqJCbPdkLkI3GQYYuJrL7xBME+q1nYEYxF4bOh8pwUxbA2krkTjQQ0a ooL0hKuryYWHPrUZzdsA/20XWje66zuStO7bcZXdFhKs+kqW7lAWuf1+ug1qhag0HJLeo+ cx8y1h3nQ0UhRIVu8THrjvtLzXHd7kheD8lst9cp9hyq6GsAlEN436QB5QJgKvOCnxSfvn IhRZShwAS+kYCP5Qke+v58kRBuT0twtpwk0J+AHSEIPPs5VeRRltGYfMvnlIZQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQSVs36Slzym3; Mon, 15 Sep 2025 14:45:09 +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 58FEj90v047520; Mon, 15 Sep 2025 14:45:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FEj9BY047517; Mon, 15 Sep 2025 14:45:09 GMT (envelope-from git) Date: Mon, 15 Sep 2025 14:45:09 GMT Message-Id: <202509151445.58FEj9BY047517@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Tom Jones Subject: git: d566b6a70bcb - main - udbc: Add usb debug host mode driver 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: thj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d566b6a70bcbc329e8c690464043401fa8bdd49f Auto-Submitted: auto-generated The branch main has been updated by thj: URL: https://cgit.FreeBSD.org/src/commit/?id=d566b6a70bcbc329e8c690464043401fa8bdd49f commit d566b6a70bcbc329e8c690464043401fa8bdd49f Author: Tom Jones AuthorDate: 2025-07-08 08:04:00 +0000 Commit: Tom Jones CommitDate: 2025-09-15 14:44:05 +0000 udbc: Add usb debug host mode driver xhci offers a debugging interface which uses a special usb 3 cable with the D+, D- and VBUS pairs disconnected. This interface allows a target device to configure its xhci controller as a debugging channel which can then be used to provide a serial link between the target and a debug host. This change extracts the udbc host mode driver from hrs@'s xhci debug implementation. Reviewed by: bcr (man page) MFC after: Before 15-ALPHA3 builds Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D51299 --- share/man/man4/udbc.4 | 132 ++++++++++++++ sys/dev/usb/serial/udbc.c | 404 ++++++++++++++++++++++++++++++++++++++++++ sys/modules/usb/Makefile | 7 +- sys/modules/usb/udbc/Makefile | 9 + 4 files changed, 548 insertions(+), 4 deletions(-) diff --git a/share/man/man4/udbc.4 b/share/man/man4/udbc.4 new file mode 100644 index 000000000000..c8fa02ec18f1 --- /dev/null +++ b/share/man/man4/udbc.4 @@ -0,0 +1,132 @@ +.\" +.\" Copyright (c) 2025 The FreeBSD Foundation +.\" +.\" This documentation was written by Tom Jones under +.\" sponsorship from the FreeBSD Foundation. +.\" +.\" SPDX-License-Identifier: BSD-2-Clause +.\" +.\" +.Dd September 3, 2025 +.Dt UDBC 4 +.Os +.Sh NAME +.Nm udbc +.Nd USB Debug Class device driver +.Sh SYNOPSIS +.Cd "device usb" +.Cd "device ucom" +.Cd "device udbc" +.Pp +In +.Xr rc.conf 5 : +.Cd kld_list="udbc" +.Sh DESCRIPTION +The +.Nm +driver provides support for USB Debug Class devices whose +interface class is Diagnostic Class and the subclass is DbC.GP. +.Pp +The USB Debug Class is defined in the USB 3.1 Device Class +Specification for Debug Devices. +This is designed to provide a general-purpose communication channel +for debugging. +It has also been widely implemented in USB xHCs +.Pq USB eXtensible Host Controllers , +which can be found on many commodity computers, +as an optional feature. +Once this feature is enabled on a USB xHC, one of the USB ports will +behave as a USB Debug Class device, +not a host port, +when a USB debug cable is connected. +The supported class in USB xHCs is typically DbC.GP, +while the specification defines several types of Debug Class devices. +The DbC.GP uses IN and OUT endpoint pairs and realizes a single +bidirectional serial communication channel. +On most systems, +including +.Fx , +the DbC.GP is seen as a simple serial device. +.Pp +Most systems with USB xHC can be configured to provide DbC.GP access. +The +.Nm +is a driver that connects to DbC.GP-supported devices, +offering +.Xr tty 4 +devices to connect to them via the +.Xr ucom 4 +device driver. +.Sh HARDWARE CONFIGURATION +A native DbC.GP device can be attached using the +.Nm +driver in a straightforward way. +.Pp +A USB xHC DbC.GP device on a target system needs a special hardware +configuration because all of the ports are supposed to be a USB Host. +There is one method to expose DbC.GP is to use a USB 3.1 A-to-A cable +.Pq section 5.5.2 in USB 3.1 Legacy Cable and Connector Specification . +When this cable is connected to a USB 3.1 port on the target system, +the DbC-enabled USB xHC automatically switches the port as a USB Device. +The +.Nm +driver can find a DbC.GP device on that port. +.Pp +Note that a USB xHC with USB 3.2 support +.Pq USB Type-C connectors +is not compatible with the USB 3.1 A-to-A cable. +Connecting a USB 3.2 C-to-C cable or A-to-C cable does not automatically work, +either, +because it needs role configuration of the port, which is not supported on +.Fx +yet. +.Sh FILES +.Bl -tag -width "/dev/ttyU*.*.init" -compact +.It Pa /dev/ttyU*.* +for callin ports +.It Pa /dev/ttyU*.*.init +.It Pa /dev/ttyU*.*.lock +corresponding callin initial-state and lock-state devices +.Pp +.It Pa /dev/cuaU*.* +for callout ports +.It Pa /dev/cuaU*.*.init +.It Pa /dev/cuaU*.*.lock +corresponding callout initial-state and lock-state devices +.El +.Sh SEE ALSO +.Xr tty 4 , +.Xr ucom 4 , +.Xr usb 4 , +.Xr xhci 4 +.Sh STANDARDS +.Rs +.%T eXtensible Host Controller Interface for Universal Serial Bus (XHCI) +.%U https://www.intel.com/content/dam/www/public/us/en/documents/technical-specifications/extensible-host-controler-interface-usb-xhci.pdf +.Re +.Rs +.%T USB 3.1 Device Class Specification for Debug Devices +.%U https://www.usb.org/sites/default/files/documents/usb_debug_class_rev_1_0_final_0.pdf +.Re +.Rs +.%T USB 3.1 Legacy Cable and Connector Specification +.%U https://www.usb.org/document-library/usb-31-legacy-cable-and-connector-revision-10 +.Re +.Sh HISTORY +The +.Nm +driver first appeared +.Fx +15.0. +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was written by +.An Hiroki Sato Aq Mt hrs@FreeBSD.org . +.Sh BUGS +According to the XHCI specification the host side of USB Debug should work with +any USB 3.0 port, +whether connected directly to a controller or with a hub in between. +Testing on some controllers has encountered issues when using a hub rather than +a directly connected port on the controller. diff --git a/sys/dev/usb/serial/udbc.c b/sys/dev/usb/serial/udbc.c new file mode 100644 index 000000000000..d7ca6b25bf32 --- /dev/null +++ b/sys/dev/usb/serial/udbc.c @@ -0,0 +1,404 @@ +/*- + * SPDX-License-Identifier: BSD-2-Clause-NetBSD + * + * Copyright (c) 2000 The NetBSD Foundation, Inc. + * Copyright (c) 2016-2024 Hiroki Sato + * All rights reserved. + * + * This code is derived from software contributed to The NetBSD Foundation + * by Lennart Augustsson (lennart@augustsson.net). + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED + * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include + +#include "usbdevs.h" + +#define USB_DEBUG_VAR udbc_debug +#include +#include +#include + +static SYSCTL_NODE(_hw_usb, OID_AUTO, udbc, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, + "USB DbC Client"); + +#ifdef USB_DEBUG +static int udbc_debug = 0; +SYSCTL_INT(_hw_usb_udbc, OID_AUTO, debug, CTLFLAG_RWTUN, &udbc_debug, 0, + "Debug level"); +#endif + +#define UDBC_CONFIG_INDEX 0 + +#define UDBC_IBUFSIZE 1024 +#define UDBC_OBUFSIZE 1024 + +enum { + UDBC_BULK_DT_WR, + UDBC_BULK_DT_RD, + UDBC_N_TRANSFER, /* n of EP */ +}; + +struct udbc_softc { + struct ucom_super_softc sc_super_ucom; + struct ucom_softc sc_ucom; + + struct usb_device *sc_udev; + struct usb_xfer *sc_xfer[UDBC_N_TRANSFER]; + device_t sc_dev; + struct mtx sc_mtx; + + uint32_t sc_unit; +}; + +/* prototypes */ + +static device_probe_t udbc_probe; +static device_attach_t udbc_attach; +static device_detach_t udbc_detach; +static void udbc_free_softc(struct udbc_softc *); + +static usb_callback_t udbc_write_callback; +static usb_callback_t udbc_read_callback; + +static void udbc_free(struct ucom_softc *); +static void udbc_cfg_open(struct ucom_softc *); +static void udbc_cfg_close(struct ucom_softc *); +static int udbc_pre_param(struct ucom_softc *, struct termios *); +static int udbc_ioctl(struct ucom_softc *, uint32_t, caddr_t, int, + struct thread *); +static void udbc_start_read(struct ucom_softc *); +static void udbc_stop_read(struct ucom_softc *); +static void udbc_start_write(struct ucom_softc *); +static void udbc_stop_write(struct ucom_softc *); +static void udbc_poll(struct ucom_softc *ucom); + +static const struct usb_config udbc_config[UDBC_N_TRANSFER] = { + [UDBC_BULK_DT_WR] = { + .type = UE_BULK, + .endpoint = UE_ADDR_ANY, + .direction = UE_DIR_OUT, + .bufsize = UDBC_OBUFSIZE, + .flags = {.pipe_bof = 1,}, + .callback = &udbc_write_callback, + }, + + [UDBC_BULK_DT_RD] = { + .type = UE_BULK, + .endpoint = UE_ADDR_ANY, + .direction = UE_DIR_IN, + .bufsize = UDBC_IBUFSIZE, + .flags = {.pipe_bof = 1,.short_xfer_ok = 1,}, + .callback = &udbc_read_callback, + }, +}; + +static const struct ucom_callback udbc_callback = { + .ucom_cfg_open = &udbc_cfg_open, + .ucom_cfg_close = &udbc_cfg_close, + .ucom_pre_param = &udbc_pre_param, + .ucom_ioctl = &udbc_ioctl, + .ucom_start_read = &udbc_start_read, + .ucom_stop_read = &udbc_stop_read, + .ucom_start_write = &udbc_start_write, + .ucom_stop_write = &udbc_stop_write, + .ucom_poll = &udbc_poll, + .ucom_free = &udbc_free, +}; + +static device_method_t udbc_methods[] = { + /* Device interface */ + DEVMETHOD(device_probe, udbc_probe), + DEVMETHOD(device_attach, udbc_attach), + DEVMETHOD(device_detach, udbc_detach), + DEVMETHOD_END +}; + +static int +udbc_probe(device_t dev) +{ + struct usb_attach_arg *uaa = device_get_ivars(dev); + + if (uaa->usb_mode != USB_MODE_HOST) + return (ENXIO); + if (uaa->info.bConfigIndex != UDBC_CONFIG_INDEX) + return (ENXIO); + if (uaa->info.bInterfaceClass != UICLASS_DIAGNOSTIC) + return (ENXIO); + if (uaa->info.bDeviceProtocol != 0x00) /* GNU GDB == 1 */ + return (ENXIO); + + return (BUS_PROBE_SPECIFIC); +} + +static int +udbc_attach(device_t dev) +{ + struct usb_attach_arg *uaa = device_get_ivars(dev); + struct udbc_softc *sc = device_get_softc(dev); + int error; + + DPRINTF("\n"); + + sc->sc_udev = uaa->device; + sc->sc_dev = dev; + sc->sc_unit = device_get_unit(dev); + + device_set_usb_desc(dev); + mtx_init(&sc->sc_mtx, "udbc", NULL, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); + + sc->sc_ucom.sc_portno = 0; + + error = usbd_transfer_setup(uaa->device, &uaa->info.bIfaceIndex, + sc->sc_xfer, udbc_config, UDBC_N_TRANSFER, sc, &sc->sc_mtx); + + if (error) { + device_printf(dev, + "allocating USB transfers failed\n"); + goto detach; + } + /* clear stall at first run */ + mtx_lock(&sc->sc_mtx); + usbd_xfer_set_stall(sc->sc_xfer[UDBC_BULK_DT_WR]); + usbd_xfer_set_stall(sc->sc_xfer[UDBC_BULK_DT_RD]); + mtx_unlock(&sc->sc_mtx); + + error = ucom_attach(&sc->sc_super_ucom, &sc->sc_ucom, 1, sc, + &udbc_callback, &sc->sc_mtx); + if (error) + goto detach; + ucom_set_pnpinfo_usb(&sc->sc_super_ucom, dev); + + return (0); /* success */ + +detach: + udbc_detach(dev); + return (ENXIO); +} + +static int +udbc_detach(device_t dev) +{ + struct udbc_softc *sc = device_get_softc(dev); + + ucom_detach(&sc->sc_super_ucom, &sc->sc_ucom); + usbd_transfer_unsetup(sc->sc_xfer, UDBC_N_TRANSFER); + + device_claim_softc(dev); + + udbc_free_softc(sc); + + return (0); +} + +UCOM_UNLOAD_DRAIN(udbc); + +static void +udbc_free_softc(struct udbc_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +udbc_free(struct ucom_softc *ucom) +{ + udbc_free_softc(ucom->sc_parent); +} + +static void +udbc_cfg_open(struct ucom_softc *ucom) +{ + /* + * This do-nothing open routine exists for the sole purpose of this + * DPRINTF() so that you can see the point at which open gets called + * when debugging is enabled. + */ + DPRINTF("\n"); +} + +static void +udbc_cfg_close(struct ucom_softc *ucom) +{ + /* + * This do-nothing close routine exists for the sole purpose of this + * DPRINTF() so that you can see the point at which close gets called + * when debugging is enabled. + */ + DPRINTF("\n"); +} + +static void +udbc_write_callback(struct usb_xfer *xfer, usb_error_t error) +{ + struct udbc_softc *sc = usbd_xfer_softc(xfer); + struct usb_page_cache *pc; + uint32_t buflen; + + DPRINTFN(3, "\n"); + + switch (USB_GET_STATE(xfer)) { + default: /* Error */ + if (error != USB_ERR_CANCELLED) { + /* try to clear stall first */ + usbd_xfer_set_stall(xfer); + } + /* FALLTHROUGH */ + case USB_ST_SETUP: + case USB_ST_TRANSFERRED: + pc = usbd_xfer_get_frame(xfer, 0); + if (ucom_get_data(&sc->sc_ucom, pc, 0, UDBC_OBUFSIZE, + &buflen) == 0) + break; + if (buflen != 0) { + usbd_xfer_set_frame_len(xfer, 0, buflen); + usbd_transfer_submit(xfer); + } + break; + } +} + +static void +udbc_read_callback(struct usb_xfer *xfer, usb_error_t error) +{ + struct udbc_softc *sc = usbd_xfer_softc(xfer); + struct usb_page_cache *pc; + int buflen; + + DPRINTFN(3, "\n"); + + usbd_xfer_status(xfer, &buflen, NULL, NULL, NULL); + + switch (USB_GET_STATE(xfer)) { + case USB_ST_TRANSFERRED: + pc = usbd_xfer_get_frame(xfer, 0); + ucom_put_data(&sc->sc_ucom, pc, 0, buflen); + /* FALLTHROUGH */ + case USB_ST_SETUP: +tr_setup: + usbd_xfer_set_frame_len(xfer, 0, usbd_xfer_max_len(xfer)); + usbd_transfer_submit(xfer); + return; + + default: /* Error */ + if (error != USB_ERR_CANCELLED) { + /* try to clear stall first */ + usbd_xfer_set_stall(xfer); + goto tr_setup; + } + return; + } +} + +static int +udbc_pre_param(struct ucom_softc *ucom, struct termios *t) +{ + DPRINTF("\n"); + + return (0); +} + +static int +udbc_ioctl(struct ucom_softc *ucom, uint32_t cmd, caddr_t data, int flag, + struct thread *td) +{ + return (ENOIOCTL); +} + +static void +udbc_start_read(struct ucom_softc *ucom) +{ + struct udbc_softc *sc = ucom->sc_parent; + + usbd_transfer_start(sc->sc_xfer[UDBC_BULK_DT_RD]); +} + +static void +udbc_stop_read(struct ucom_softc *ucom) +{ + struct udbc_softc *sc = ucom->sc_parent; + + usbd_transfer_stop(sc->sc_xfer[UDBC_BULK_DT_RD]); +} + +static void +udbc_start_write(struct ucom_softc *ucom) +{ + struct udbc_softc *sc = ucom->sc_parent; + + usbd_transfer_start(sc->sc_xfer[UDBC_BULK_DT_WR]); +} + +static void +udbc_stop_write(struct ucom_softc *ucom) +{ + struct udbc_softc *sc = ucom->sc_parent; + + usbd_transfer_stop(sc->sc_xfer[UDBC_BULK_DT_WR]); +} + +static void +udbc_poll(struct ucom_softc *ucom) +{ + struct udbc_softc *sc = ucom->sc_parent; + + usbd_transfer_poll(sc->sc_xfer, UDBC_N_TRANSFER); +} + +static driver_t udbc_driver = { + .name = "udbc", + .methods = udbc_methods, + .size = sizeof(struct udbc_softc), +}; + +DRIVER_MODULE(udbc, uhub, udbc_driver, NULL, NULL); +MODULE_DEPEND(udbc, ucom, 1, 1, 1); +MODULE_DEPEND(udbc, usb, 1, 1, 1); +MODULE_VERSION(udbc, 1); diff --git a/sys/modules/usb/Makefile b/sys/modules/usb/Makefile index 1290b878fa37..d9b1c8635b30 100644 --- a/sys/modules/usb/Makefile +++ b/sys/modules/usb/Makefile @@ -46,10 +46,9 @@ SUBDIR = usb SUBDIR += ${_dwc_otg} ehci ${_musb} ohci uhci xhci ${_uss820dci} \ ${_atmegadci} ${_avr32dci} ${_rsu} ${_rsufw} ${_bcm2838_xhci} SUBDIR += mtw ${_rum} ${_run} ${_runfw} ${_uath} upgt usie ural ${_zyd} ${_urtw} -SUBDIR += atp cfumass uhid uhid_snes ukbd ums udbp uep wmt wsp ugold uled \ - usbhid -SUBDIR += ucom u3g uark ubsa ubser uchcom ucycom ufoma uftdi ugensa uipaq ulpt \ - umb umct umcs umodem umoscom uplcom uslcom uvisor uvscom +SUBDIR += atp cfumass uhid uhid_snes ukbd ums udbp uep wmt wsp ugold uled usbhid +SUBDIR += ucom u3g uark ubsa ubser uchcom ucycom udbc ufoma uftdi ugensa uipaq +SUBDIR += ulpt umb umct umcs umodem umoscom uplcom uslcom uvisor uvscom SUBDIR += i2ctinyusb SUBDIR += cp2112 SUBDIR += udl diff --git a/sys/modules/usb/udbc/Makefile b/sys/modules/usb/udbc/Makefile new file mode 100644 index 000000000000..9996b2e391fb --- /dev/null +++ b/sys/modules/usb/udbc/Makefile @@ -0,0 +1,9 @@ +S= ${SRCTOP}/sys + +.PATH: $S/dev/usb/serial + +KMOD= udbc +SRCS= opt_bus.h opt_usb.h device_if.h bus_if.h usb_if.h usbdevs.h \ + udbc.c + +.include From nobody Mon Sep 15 16:49:38 2025 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 4cQWGV3LXCz67cC1; Mon, 15 Sep 2025 16:49:38 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQWGV2nWbz3kGN; Mon, 15 Sep 2025 16:49:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757954978; 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=jnuJ00Xx0Dl/4jbITgaQ64vk1FLGGmUn300eEXrO8Oc=; b=e9FixbXeDZtE3tYAhKW2TUcxyEEWLr3kkDehqGwJ2R6NafBppU+ReRIGiutRDZ2bVl7K44 lpc70aMBmf/sICErHdT1Z3V8t/R+XyvdAN54AZyrhYn1S1dK6HRJU5+xQlN+UBpmjiU9kE OJQZMBiVQWI6ytxVyGgrRtqmbfcP70QzulaCuzSTLip3pm40sgQqJ+slk58eTUe43UHUor +wb67Coy1zrrgtSV6ihtUKcTEyaIN+d2LFDRne2v8rOPsFYRCzw6hnM/j5lyngRqUvHRK2 G19pSI6RF8h+lUHHawzgpfasH/mTrLceCfpFBxwgvEQFm8Z3CYeaaqn4MBo+KA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757954978; 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=jnuJ00Xx0Dl/4jbITgaQ64vk1FLGGmUn300eEXrO8Oc=; b=om9oTnvjh6wPj/lsF9Bxn4y2ttuffAsJegNQYJ/DcFKBttRK0jfnW4WLPTyMiTv0CwhBEi JbrDFfodUIYLaZ1cQv2ZpS63Pqq+36Rb76vEq8WWUDcTq7iPgwIa8ZfDhtT6p05CaWpouy 7q1tqgAGUTFjTgvhU2Vs1yeay3c3jXy/af9CDMzpp6DG8C9Xm0PXfPLOHZYNNosDsrwaub FuNhbHVo0X5EhTbnPHyy2Zsp377XAh96HqJaCEIHK5kZCnFeJc/VtDCMRcO9Kq6Et6suHY jg9viMfOwrw5HOeNdYTo/D9FpEw20UDUDX/HPlpyZRm/7CUBGDqxApUEkdQvCA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757954978; a=rsa-sha256; cv=none; b=e0nbFiRzH8lpetQCBjjPfjABceIA1JDy34/ycMSXVUQzkQlnCv/eEsdRYkZHxQG8E07pGH mnJU85YwK2FL2IiU5AHe7P15DMeU2QztLiGM90KKOHf5h1YVfwO0bb3T37hPzvopcOekVC fuNz5L46ttpb3CNJ4GQ+MYOo7o99KkEhASmPaHL4VXJV9Y6QX5ibfk7IozkV02z43TASo2 i/b6oCF9qD/86Khx9K062UqHC9/HMF1YlaWzB1aIpV+d6es3HccYXV5gkPZJm5bV2SsoNt ZqkU5fdFzOIhYMixP/HULFuMcXI+xG+w1JtqsYdsuBA1zqYl1rA2/WdrboDQPw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQWGV2Jqqz137Y; Mon, 15 Sep 2025 16:49:38 +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 58FGncU0073624; Mon, 15 Sep 2025 16:49:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FGnc63073621; Mon, 15 Sep 2025 16:49:38 GMT (envelope-from git) Date: Mon, 15 Sep 2025 16:49:38 GMT Message-Id: <202509151649.58FGnc63073621@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: "Jonathan T. Looney" Subject: git: cd02a8a9f8be - main - ip6: add SO_BINTIME support 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: jtl X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: cd02a8a9f8be2085d5242606a79668dc3720e7b0 Auto-Submitted: auto-generated The branch main has been updated by jtl: URL: https://cgit.FreeBSD.org/src/commit/?id=cd02a8a9f8be2085d5242606a79668dc3720e7b0 commit cd02a8a9f8be2085d5242606a79668dc3720e7b0 Author: Jonathan T. Looney AuthorDate: 2025-09-12 17:49:17 +0000 Commit: Jonathan T. Looney CommitDate: 2025-09-15 16:46:03 +0000 ip6: add SO_BINTIME support This adds support for obtaining timestamps from IPv6 packets using the SO_BINTIME socket option, bringing it in parity with IPv4 behavior. Enable testing the SO_BINTIME option in the relevant (manual) regression test. PR: 289423 Reviewed by: markj MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D52504 --- sys/netinet6/ip6_input.c | 53 +++++++++++++++------- .../regression/sockets/udp_pingpong/udp_pingpong.c | 8 ++-- 2 files changed, 39 insertions(+), 22 deletions(-) diff --git a/sys/netinet6/ip6_input.c b/sys/netinet6/ip6_input.c index 45fd23ea6c21..b22491a6007f 100644 --- a/sys/netinet6/ip6_input.c +++ b/sys/netinet6/ip6_input.c @@ -1197,8 +1197,8 @@ ip6_savecontrol_v4(struct inpcb *inp, struct mbuf *m, struct mbuf **mp, { struct ip6_hdr *ip6 = mtod(m, struct ip6_hdr *); -#ifdef SO_TIMESTAMP - if ((inp->inp_socket->so_options & SO_TIMESTAMP) != 0) { +#if defined(SO_TIMESTAMP) && defined(SO_BINTIME) + if ((inp->inp_socket->so_options & (SO_TIMESTAMP | SO_BINTIME)) != 0) { union { struct timeval tv; struct bintime bt; @@ -1206,47 +1206,66 @@ ip6_savecontrol_v4(struct inpcb *inp, struct mbuf *m, struct mbuf **mp, } t; struct bintime boottimebin, bt1; struct timespec ts1; + int ts_clock; bool stamped; + ts_clock = inp->inp_socket->so_ts_clock; stamped = false; - switch (inp->inp_socket->so_ts_clock) { - case SO_TS_REALTIME_MICRO: + + /* + * Handle BINTIME first. We create the same output options + * for both SO_BINTIME and the case where SO_TIMESTAMP is + * set with the timestamp clock set to SO_TS_BINTIME. + */ + if ((inp->inp_socket->so_options & SO_BINTIME) != 0 || + ts_clock == SO_TS_BINTIME) { if ((m->m_flags & (M_PKTHDR | M_TSTMP)) == (M_PKTHDR | M_TSTMP)) { mbuf_tstmp2timespec(m, &ts1); - timespec2bintime(&ts1, &bt1); + timespec2bintime(&ts1, &t.bt); getboottimebin(&boottimebin); - bintime_add(&bt1, &boottimebin); - bintime2timeval(&bt1, &t.tv); + bintime_add(&t.bt, &boottimebin); } else { - microtime(&t.tv); + bintime(&t.bt); } - *mp = sbcreatecontrol(&t.tv, sizeof(t.tv), - SCM_TIMESTAMP, SOL_SOCKET, M_NOWAIT); + *mp = sbcreatecontrol(&t.bt, sizeof(t.bt), SCM_BINTIME, + SOL_SOCKET, M_NOWAIT); if (*mp != NULL) { mp = &(*mp)->m_next; stamped = true; } - break; - case SO_TS_BINTIME: + /* + * Suppress other timestamps if SO_TIMESTAMP is not + * set. + */ + if ((inp->inp_socket->so_options & SO_TIMESTAMP) == 0) + ts_clock = SO_TS_BINTIME; + } + + switch (ts_clock) { + case SO_TS_REALTIME_MICRO: if ((m->m_flags & (M_PKTHDR | M_TSTMP)) == (M_PKTHDR | M_TSTMP)) { mbuf_tstmp2timespec(m, &ts1); - timespec2bintime(&ts1, &t.bt); + timespec2bintime(&ts1, &bt1); getboottimebin(&boottimebin); - bintime_add(&t.bt, &boottimebin); + bintime_add(&bt1, &boottimebin); + bintime2timeval(&bt1, &t.tv); } else { - bintime(&t.bt); + microtime(&t.tv); } - *mp = sbcreatecontrol(&t.bt, sizeof(t.bt), SCM_BINTIME, - SOL_SOCKET, M_NOWAIT); + *mp = sbcreatecontrol(&t.tv, sizeof(t.tv), + SCM_TIMESTAMP, SOL_SOCKET, M_NOWAIT); if (*mp != NULL) { mp = &(*mp)->m_next; stamped = true; } break; + case SO_TS_BINTIME: + break; + case SO_TS_REALTIME: if ((m->m_flags & (M_PKTHDR | M_TSTMP)) == (M_PKTHDR | M_TSTMP)) { diff --git a/tools/regression/sockets/udp_pingpong/udp_pingpong.c b/tools/regression/sockets/udp_pingpong/udp_pingpong.c index 2fe342debdc6..e852f7a7af87 100644 --- a/tools/regression/sockets/udp_pingpong/udp_pingpong.c +++ b/tools/regression/sockets/udp_pingpong/udp_pingpong.c @@ -601,11 +601,9 @@ main(void) test_run(TT_TIMESTAMP, i, 1, "send()/recvmsg(), setsockopt(SO_TIMESTAMP, 1)"); printf("OK\n"); - if (i == 0) { - test_run(TT_BINTIME, i, 1, - "send()/recvmsg(), setsockopt(SO_BINTIME, 1)"); - printf("OK\n"); - } + test_run(TT_BINTIME, i, 1, + "send()/recvmsg(), setsockopt(SO_BINTIME, 1)"); + printf("OK\n"); test_run(TT_REALTIME_MICRO, i, 1, "send()/recvmsg(), setsockopt(SO_TS_CLOCK, SO_TS_REALTIME_MICRO)"); printf("OK\n"); From nobody Mon Sep 15 17:26:28 2025 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 4cQX510Wflz67gFG; Mon, 15 Sep 2025 17:26:29 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQX506wJYz3sRc; Mon, 15 Sep 2025 17:26:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757957189; 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=rBbUeQt8+euoRj3G3Frz5sdlLSZQrGfMkPkbbHcGMtE=; b=ftXWN/CBX+snlVTbe4QVmr9O6gTZ9a2oJca7woC6W55Pa9znTMyFXYMfZ07BF0G9lyKAmA TVgHwla5iOwWc+f/2eOkcwTDxBdpPI4c9vmmCIEpHJIVN46wnzyhew612yeAvYOO79Ze24 3tNW4OAyOP8cllJFgoDovlutiyUt+ruoX+Qz7UG+SRl0USiIEDQNhs1biJgCOxHRb2BRjP MCREx3M3IDRCZ/zBXzd0btEYSI4TRIQEuqa2CsOoeR10hMgklEICmQuzsmk+aR2DxwtRpM yyd3NTA+ecEkWC9rj+9XWKkAf+S/lcDhEEHiL0Pw1mqFyCYpBicw/e2vUgfUzQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757957189; 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=rBbUeQt8+euoRj3G3Frz5sdlLSZQrGfMkPkbbHcGMtE=; b=vBO5i3R3+cTAzWqaEGjHbbABvk3z1yJhsN/Q3ulvIMqz0qyZkEZ+xw3g30IPKbPnUkJX/d mhruZGzQ6Lk7M+u4Ov6fb92weBIkzNTF5VcrUGr8M8Fb9+ymOzsJDosbAHxT5RayYrfdEA b+R2Zu5ly5B0YlFifr2QuxMjRKPPrV7S0bdUxhOUmRev18RZ+4cBiP4BjQWqds24K6TeyX K2DF/gLibt3iiqt+NLcNY8wBc7IfDLp+SF8Vt/sXEyiY1hR9FuDfQecEutPnsyBDjsHPFN 0XqskkcNgL6PtWwmcJWhywKuNEuIwpzI2+pSwgQSxW+sTCexTYZGDY7P3JMEJg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757957189; a=rsa-sha256; cv=none; b=I3pvNW+89kOjlKdF0Q+cZ75ijTo6Ov889NcP5fpgB54JdJYhWl4OWSI8u6vRM6lQWmVY7g MgD44gynQ3xrmTkrZvImpjdeKuRL2SZE9IUAVpRBihZhFOAKxdIGmo/+Bbyw41sr19DiXh WCk65RccbEzaCRDPP2nLh2lav7N6PzH3DiW5+Obwpo1WiXmTYPaB1IeFZgZ5Iog6pRb/pT ASdzPRLkdq8QM7cw1ghawcqPBJdbQQNdg7P7AqyZTbiYu9eKaJA5rj5bcu2qFRzM9KhVSr CW2Bi6lOOoJnBcFHopXwJ0tNDHAxIU+XOemiTpahvUPyc8cK5EAsKTCCS0ee2A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQX506QSqz13Rc; Mon, 15 Sep 2025 17:26:28 +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 58FHQSjk048507; Mon, 15 Sep 2025 17:26:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FHQSdN048504; Mon, 15 Sep 2025 17:26:28 GMT (envelope-from git) Date: Mon, 15 Sep 2025 17:26:28 GMT Message-Id: <202509151726.58FHQSdN048504@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: 246d7e9fc239 - main - jail: Optionally allow audit session state to be configured in a jail 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 246d7e9fc23928be22db38220f5439f5cdee5264 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=246d7e9fc23928be22db38220f5439f5cdee5264 commit 246d7e9fc23928be22db38220f5439f5cdee5264 Author: Mark Johnston AuthorDate: 2025-09-15 17:23:50 +0000 Commit: Mark Johnston CommitDate: 2025-09-15 17:23:50 +0000 jail: Optionally allow audit session state to be configured in a jail Currently it is impossible for a privileged, jailed process to set audit session state. This can result in suprising audit event misattribution. For example, suppose a user ssh'es into a jail and restarts a service; normally, sshd sets audit state such that events generated by the SSH session are attributed to the newly authenticated user, but in a jail, the corresponding setaudit(2) call fails, so events are attributed to the user who had started sshd in the jail (typically the user who had started the jail itself by some means). While this behaviour is reasonable, administrators might want to trust the jailed sshd to reset audit state, such that the authenticated user appears in audit logs. Add a jail knob to enable this. Add a simple regression test. Reviewed by: kevans, jamie MFC after: 1 week Sponsored by: Modirum MDPay Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D51719 --- sys/kern/kern_jail.c | 13 ++++++++++++- sys/security/audit/audit_syscalls.c | 12 ------------ sys/sys/jail.h | 3 ++- usr.sbin/jail/jail.8 | 19 +++++++++++++++---- usr.sbin/jail/tests/jail_basic_test.sh | 20 ++++++++++++++++++++ 5 files changed, 49 insertions(+), 18 deletions(-) diff --git a/sys/kern/kern_jail.c b/sys/kern/kern_jail.c index a75ba89d2a7e..3697d95fe0e5 100644 --- a/sys/kern/kern_jail.c +++ b/sys/kern/kern_jail.c @@ -243,6 +243,9 @@ static struct bool_flags pr_flag_allow[NBBY * NBPW] = { {"allow.unprivileged_parent_tampering", "allow.nounprivileged_parent_tampering", PR_ALLOW_UNPRIV_PARENT_TAMPER}, +#ifdef AUDIT + {"allow.setaudit", "allow.nosetaudit", PR_ALLOW_SETAUDIT}, +#endif }; static unsigned pr_allow_all = PR_ALLOW_ALL_STATIC; const size_t pr_flag_allow_size = sizeof(pr_flag_allow); @@ -4289,7 +4292,6 @@ prison_priv_check(struct ucred *cred, int priv) */ case PRIV_KTRACE: -#if 0 /* * Allow jailed processes to configure audit identity and * submit audit records (login, etc). In the future we may @@ -4298,6 +4300,11 @@ prison_priv_check(struct ucred *cred, int priv) */ case PRIV_AUDIT_GETAUDIT: case PRIV_AUDIT_SETAUDIT: + if (cred->cr_prison->pr_allow & PR_ALLOW_SETAUDIT) + return (0); + else + return (EPERM); +#if 0 case PRIV_AUDIT_SUBMIT: #endif @@ -5034,6 +5041,10 @@ SYSCTL_JAIL_PARAM(_allow, settime, CTLTYPE_INT | CTLFLAG_RW, "B", "Jail may set system time"); SYSCTL_JAIL_PARAM(_allow, routing, CTLTYPE_INT | CTLFLAG_RW, "B", "Jail may modify routing table"); +#ifdef AUDIT +SYSCTL_JAIL_PARAM(_allow, setaudit, CTLTYPE_INT | CTLFLAG_RW, + "B", "Jail may set and get audit session state"); +#endif SYSCTL_JAIL_PARAM_SUBNODE(allow, mount, "Jail mount/unmount permission flags"); SYSCTL_JAIL_PARAM(_allow_mount, , CTLTYPE_INT | CTLFLAG_RW, diff --git a/sys/security/audit/audit_syscalls.c b/sys/security/audit/audit_syscalls.c index 40b2fb3d1c9f..262f2c1ae1e3 100644 --- a/sys/security/audit/audit_syscalls.c +++ b/sys/security/audit/audit_syscalls.c @@ -592,8 +592,6 @@ sys_getauid(struct thread *td, struct getauid_args *uap) { int error; - if (jailed(td->td_ucred)) - return (ENOSYS); error = priv_check(td, PRIV_AUDIT_GETAUDIT); if (error) return (error); @@ -609,8 +607,6 @@ sys_setauid(struct thread *td, struct setauid_args *uap) au_id_t id; int error; - if (jailed(td->td_ucred)) - return (ENOSYS); error = copyin(uap->auid, &id, sizeof(id)); if (error) return (error); @@ -650,8 +646,6 @@ sys_getaudit(struct thread *td, struct getaudit_args *uap) int error; cred = td->td_ucred; - if (jailed(cred)) - return (ENOSYS); error = priv_check(td, PRIV_AUDIT_GETAUDIT); if (error) return (error); @@ -674,8 +668,6 @@ sys_setaudit(struct thread *td, struct setaudit_args *uap) struct auditinfo ai; int error; - if (jailed(td->td_ucred)) - return (ENOSYS); error = copyin(uap->auditinfo, &ai, sizeof(ai)); if (error) return (error); @@ -715,8 +707,6 @@ sys_getaudit_addr(struct thread *td, struct getaudit_addr_args *uap) { int error; - if (jailed(td->td_ucred)) - return (ENOSYS); if (uap->length < sizeof(*uap->auditinfo_addr)) return (EOVERFLOW); error = priv_check(td, PRIV_AUDIT_GETAUDIT); @@ -734,8 +724,6 @@ sys_setaudit_addr(struct thread *td, struct setaudit_addr_args *uap) struct auditinfo_addr aia; int error; - if (jailed(td->td_ucred)) - return (ENOSYS); error = copyin(uap->auditinfo_addr, &aia, sizeof(aia)); if (error) return (error); diff --git a/sys/sys/jail.h b/sys/sys/jail.h index e12e8c3178c9..e6a13e6719dd 100644 --- a/sys/sys/jail.h +++ b/sys/sys/jail.h @@ -271,6 +271,7 @@ struct prison_racct { #define PR_ALLOW_SETTIME 0x00100000 #define PR_ALLOW_ROUTING 0x00200000 #define PR_ALLOW_UNPRIV_PARENT_TAMPER 0x00400000 +#define PR_ALLOW_SETAUDIT 0x00800000 /* * PR_ALLOW_PRISON0 are the allow flags that we apply by default to prison0, @@ -278,7 +279,7 @@ struct prison_racct { * build time. PR_ALLOW_ALL_STATIC should contain any bit above that we expect * to be used on the system, while PR_ALLOW_PRISON0 will be some subset of that. */ -#define PR_ALLOW_ALL_STATIC 0x007f87ff +#define PR_ALLOW_ALL_STATIC 0x00ff87ff #define PR_ALLOW_PRISON0 \ (PR_ALLOW_ALL_STATIC & ~(PR_ALLOW_UNPRIV_PARENT_TAMPER)) diff --git a/usr.sbin/jail/jail.8 b/usr.sbin/jail/jail.8 index 421aa9babb4c..d44b7f66a64e 100644 --- a/usr.sbin/jail/jail.8 +++ b/usr.sbin/jail/jail.8 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 7, 2025 +.Dd September 15, 2025 .Dt JAIL 8 .Os .Sh NAME @@ -702,15 +702,15 @@ The super-user will be disabled automatically if its parent system has it disabled. The super-user is enabled by default. .It Va allow.extattr -Allow privileged process in the jail to manipulate filesystem extended +Allow privileged processes in the jail to manipulate filesystem extended attributes in the system namespace. .It Va allow.adjtime -Allow privileged process in the jail to slowly adjusting global operating system +Allow privileged processes in the jail to slowly adjusting global operating system time. For example through utilities like .Xr ntpd 8 . .It Va allow.settime -Allow privileged process in the jail to set global operating system data +Allow privileged processes in the jail to set global operating system data and time. For example through utilities like .Xr date 1 . @@ -719,6 +719,17 @@ This permission includes also .It Va allow.routing Allow privileged process in the non-VNET jail to modify the system routing table. +.It Va allow.setaudit +Allow privileged processes in the jail to set +.Xr audit 4 +session state using +.Xr setaudit 2 +and related system calls. +This is useful, for example, for allowing a jailed +.Xr sshd 8 +to set the audit user ID for an authenticated session. +However, it gives jailed processes the ability to modify or disable audit +session state, so should be configured with care. .El .El .Pp diff --git a/usr.sbin/jail/tests/jail_basic_test.sh b/usr.sbin/jail/tests/jail_basic_test.sh index 6802da7b049a..c781eed78756 100755 --- a/usr.sbin/jail/tests/jail_basic_test.sh +++ b/usr.sbin/jail/tests/jail_basic_test.sh @@ -306,6 +306,25 @@ param_consistency_cleanup() fi } +atf_test_case "setaudit" +setaudit_head() +{ + atf_set descr 'Test that setaudit works in a jail when configured with allow.setaudit' + atf_set require.user root + atf_set require.progs setaudit +} + +setaudit_body() +{ + # Try to modify the audit mask within a jail without + # allow.setaudit configured. + atf_check -s not-exit:0 -o empty -e not-empty jail -c name=setaudit_jail \ + command=setaudit -m fr ls / + # The command should succeed if allow.setaudit is configured. + atf_check -s exit:0 -o ignore -e empty jail -c name=setaudit_jail \ + allow.setaudit command=setaudit -m fr ls / +} + atf_init_test_cases() { atf_add_test_case "basic" @@ -314,4 +333,5 @@ atf_init_test_cases() atf_add_test_case "commands" atf_add_test_case "jid_name_set" atf_add_test_case "param_consistency" + atf_add_test_case "setaudit" } From nobody Mon Sep 15 17:44:21 2025 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 4cQXTd4W8Rz67hbs; Mon, 15 Sep 2025 17:44:21 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQXTd3rP3z3vvN; Mon, 15 Sep 2025 17:44:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757958261; 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=xViwxX4DzWYCmkSyvv42RXiEWLAoN2gaaCNoWLMSXVs=; b=VnMxJ1YTGiuU8YN7Yzb1NWl0Ia6eTffxA9Vwg8O6pXRPk5rgwxdfY4I/2gkz8FvB1UBAqh 70zZUBLYQXXquVjERzBcoFohLj5zFnrYTa3lbPRZWlc65pI0vVxJJEjr+ihUxMwG6DjY0B o/64e0bjuyfvlMbT/msbPJAFflj0H3SPMTsuI6uTPMLG2GmPBH/OePeW5Lf8f1103p7KEy aRtbJ0mt2IL5YelehGvQEY0XeQwWqcYEiaOaNImL14/4+4ssr0Xz+MjZewWj8eYlM1ox7p YAtm6eZ4O8GaF9nrAYmJGZHyeiGVKFYpGifbTBVkT/TNSLdJHIKK6+7NgJHUCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757958261; 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=xViwxX4DzWYCmkSyvv42RXiEWLAoN2gaaCNoWLMSXVs=; b=pCNhgnxX+onFI7bT8jPGk/iUZH7bfsI2JbVWBbD4JpY56rDTaocAf2vwujgbeYmQ2xa6Id +Yaj9CWdbl6sPl68XK9HwcFp0XeQxRl8JQO3JdIccwtaFcLkLV24QyNuDaA5cvBjvgqIoa a0ZSgusoCXBApKNQnOicSMxdOIUUE2lmLrFkbt81UXFGpef+DO9ETAUIaK0inqqucYtQCr irNlwdFOBgvKwfYLLaqPZrjTcz+yjtJTcfrH/fEa2pc/xoUHZVKNuO+wss95CumNRGtfQQ hw+YBrxZ8rRHrBCUxWxYCYC7w2oECEwjWACG6onQIoxkDKS/HlLOn754n4+zLg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757958261; a=rsa-sha256; cv=none; b=hiEhLA/eIEcAPpZMCtOXNlX8C6NFa+THt9Z5GGg1NFx1Zoz4eySNNQcwMRE+3OWEpKZWLp I1yNLS3TY8Q50SnIMyjgbdEf2rnjALiyl7Dk1H5QwV7KB2RQG3iESYqdStgTM/7tXVDBNG 2UtyQxx4DFJA8+N+2Pfl6Ejqlo2gAdpsN4ZufUeaVdcHdPWqQWY8oowhyCbJ9q1i4vPOSr M2pIJlm7TiBXtiFE79mSOr4DA0oyipaq7iAc0dyFS/+c0jVJEWNRoVFjWEzOlepQKtovp1 u8TTlTPWQvPDQkZ40Q4jKQ999SJqQMsoYWAOlOmNGDz8biPub3eDmGp+4DO3aQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQXTd3J8Tz13tG; Mon, 15 Sep 2025 17:44:21 +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 58FHiL3P086057; Mon, 15 Sep 2025 17:44:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FHiLZg086054; Mon, 15 Sep 2025 17:44:21 GMT (envelope-from git) Date: Mon, 15 Sep 2025 17:44:21 GMT Message-Id: <202509151744.58FHiLZg086054@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: e8b5025c3880 - main - sound: Honor CHN_F_NBIO 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e8b5025c3880b04c1c2139fe73b65fbd6deb41d4 Auto-Submitted: auto-generated The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=e8b5025c3880b04c1c2139fe73b65fbd6deb41d4 commit e8b5025c3880b04c1c2139fe73b65fbd6deb41d4 Author: Damjan Jovanovic AuthorDate: 2025-09-15 17:42:41 +0000 Commit: Christos Margiolis CommitDate: 2025-09-15 17:42:41 +0000 sound: Honor CHN_F_NBIO If the device is opened with O_NONBLOCK, even though we check for it in order to set CHN_F_NBIO, the subsequent chn_reset() calls will clear all flags, except those set in CHN_F_RESET, which does not include CHN_F_NBIO. Add CHN_F_NBIO to CHN_F_RESET. Additionally, because primary channels can be reused, make sure we do not unintentionally keep CHN_F_NBIO set if the channel is re-opened, but without O_NONBLOCK. PR: 289441 MFC after: 2 days Reviewed by: christos, markj Differential Revision: https://reviews.freebsd.org/D52493 --- sys/dev/sound/pcm/channel.h | 2 +- sys/dev/sound/pcm/dsp.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/dev/sound/pcm/channel.h b/sys/dev/sound/pcm/channel.h index fab182b22774..9ad21d219001 100644 --- a/sys/dev/sound/pcm/channel.h +++ b/sys/dev/sound/pcm/channel.h @@ -408,7 +408,7 @@ enum { #define CHN_F_RESET (CHN_F_BUSY | CHN_F_DEAD | \ CHN_F_VIRTUAL | CHN_F_HAS_VCHAN | \ - CHN_F_VCHAN_DYNAMIC | \ + CHN_F_VCHAN_DYNAMIC | CHN_F_NBIO | \ CHN_F_PASSTHROUGH | CHN_F_EXCLUSIVE) #define CHN_F_MMAP_INVALID (CHN_F_DEAD | CHN_F_RUNNING) diff --git a/sys/dev/sound/pcm/dsp.c b/sys/dev/sound/pcm/dsp.c index aa6ad4a59778..da38f52021ae 100644 --- a/sys/dev/sound/pcm/dsp.c +++ b/sys/dev/sound/pcm/dsp.c @@ -299,7 +299,7 @@ dsp_close(void *data) CHN_LOCK(rdch); chn_abort(rdch); /* won't sleep */ rdch->flags &= ~(CHN_F_RUNNING | CHN_F_MMAP | - CHN_F_DEAD | CHN_F_EXCLUSIVE); + CHN_F_DEAD | CHN_F_EXCLUSIVE | CHN_F_NBIO); chn_reset(rdch, 0, 0); chn_release(rdch); if (rdch->flags & CHN_F_VIRTUAL) { @@ -323,7 +323,7 @@ dsp_close(void *data) CHN_LOCK(wrch); chn_flush(wrch); /* may sleep */ wrch->flags &= ~(CHN_F_RUNNING | CHN_F_MMAP | - CHN_F_DEAD | CHN_F_EXCLUSIVE); + CHN_F_DEAD | CHN_F_EXCLUSIVE | CHN_F_NBIO); chn_reset(wrch, 0, 0); chn_release(wrch); if (wrch->flags & CHN_F_VIRTUAL) { From nobody Mon Sep 15 17:57:33 2025 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 4cQXms3lYdz67jfN; Mon, 15 Sep 2025 17:57: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQXms37XSz3y0V; Mon, 15 Sep 2025 17:57:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757959053; 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=7WN0FlCVkQJd7vZFV+GyfjlAU0q2XtLBvzKseoKZdNY=; b=h0exXuiUHka38qFf+5FzkcDEUJazBkjLjCe/VXLZRlWm4h+2NO7OV54COCk8dVxSeLAYlW x7Wegv2i/sCQWZsoMgBNvi4MscVELLxTZqojeak/T98GCIKEBfPhQRLXkcLc1Qf1dYLAdZ LH3ZeEf1/My80V41e5TbCHLDsBxXC1tMSwbe8hmCLfXJAAMMnY+Ylk+hnArVAB3tjt4Cx/ IYyZDqFGFSrgAc0Sb9PVx+9qMxexQZ+saWR5/zZaP8idZLx+nMINaWwV1kxPc4Dl3uQq1r EFjl0P+z8BxDBakhRqDz9BjXRQhPdl5zTzwMlbz2nboeSlQAK7iJugI2Y+3vdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757959053; 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=7WN0FlCVkQJd7vZFV+GyfjlAU0q2XtLBvzKseoKZdNY=; b=yokYJBI12jpLJWPT2UTsM5juFSp7+Z5UW2yBBkYtIyXEuCuC6PqF8W4EVkhH1kKfw8zl/m k9AJs95FSD1Gd2dBLP+yh4wjSsmJXM5FLAddZejvs/1U47z1HVM4UaaHSR2uPxGssquu75 Z7clCxHrFeWMccLLEeGdPhiBJoqXcc7qGH6h8aW+R9WccakiKvse8HVAKaoieJo4RjLp9W Zh4vedS4Z5yGgA3pu7AAaCnxS6Xw774ZcRse0/kC284x2v2h35BG+QWSCBT2bMm3TI0vvk dWOha1DB1/uAYujnXov4XzNK9UkcTL3yBB6eXC+OnjQkDj68gI/kGAR1mGk8JQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757959053; a=rsa-sha256; cv=none; b=YqI9YxSjRG3A8eiLIu1IM0OhIkzxs4oODACvIgEdQflcJftJMVGT68mNESvGPtRc3FFowP K94+2W/EHKPHQNExCRDhx5wJDMgVNpQh84SVLQZ/pnQqkxyJAzoIkc1NeI4pWRcbRzgct3 iwbJujTBF/eI2H15Q0q3eWLGr2u6Jn4fKR22Xv7zB0AGomXHqhrsgUSa0QtzNRn/YDH73B xgPvgDwdfnJDEkjPdQ6y4VlXC7y3rDh2mxNHdbBIMnJTI1eP7AMw5bn9uwp1hVA8uGL3jU uR3wW9csdYcTEEPLGyc8q1Vqo6iDj3Tw/FBa4yF+r/GPV/ERk7zs1sXYvhj3MA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQXms2cYyz14TD; Mon, 15 Sep 2025 17:57:33 +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 58FHvXlZ005197; Mon, 15 Sep 2025 17:57:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FHvXZr005194; Mon, 15 Sep 2025 17:57:33 GMT (envelope-from git) Date: Mon, 15 Sep 2025 17:57:33 GMT Message-Id: <202509151757.58FHvXZr005194@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 18fd1443d205 - main - ifconfig: Enter jail as soon as possible 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: des X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 18fd1443d205aed6be22966125a4820f77571948 Auto-Submitted: auto-generated The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=18fd1443d205aed6be22966125a4820f77571948 commit 18fd1443d205aed6be22966125a4820f77571948 Author: Dag-Erling Smørgrav AuthorDate: 2025-09-15 17:56:33 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-15 17:56:33 +0000 ifconfig: Enter jail as soon as possible Some options (in particular, -g) are processed immediately upon being parsed. This will produce the wrong result in combination with -j since we only attach to the jail after we're done parsing arguments. Solve this by attaching to the jail immediately when -j is encountered. The downside is that e.g. `ifconfig -j foo -j bar` would previously attach to jail “bar”, whereas now it will attempt to attach to jail “foo”, and if successful, attempt to attach to jail “bar” within jail “foo”. This may be considered a feature. PR: 289134 MFC after: 1 week Reviewed by: zlei Differential Revision: https://reviews.freebsd.org/D52501 --- sbin/ifconfig/ifconfig.8 | 42 +++++++++++++++++++++--------------------- sbin/ifconfig/ifconfig.c | 22 ++++++++-------------- sbin/ifconfig/ifconfig.h | 1 - 3 files changed, 29 insertions(+), 36 deletions(-) diff --git a/sbin/ifconfig/ifconfig.8 b/sbin/ifconfig/ifconfig.8 index b580191383b3..c4184ba61ee4 100644 --- a/sbin/ifconfig/ifconfig.8 +++ b/sbin/ifconfig/ifconfig.8 @@ -28,7 +28,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 10, 2025 +.Dd September 12, 2025 .Dt IFCONFIG 8 .Os .Sh NAME @@ -36,7 +36,7 @@ .Nd configure network interface parameters .Sh SYNOPSIS .Nm -.Op Fl j Ar jail +.Op Fl j Ar jid .Op Fl DkLmn .Op Fl f Ar type Ns Cm \&: Ns Ar format .Ar interface @@ -50,11 +50,11 @@ .Oc .Op Ar parameters .Nm -.Op Fl j Ar jail +.Op Fl j Ar jid .Ar interface .Cm destroy .Nm -.Op Fl j Ar jail +.Op Fl j Ar jid .Fl a .Op Fl dDkLmuv .Op Fl f Ar type Ns Cm \&: Ns Ar format @@ -64,16 +64,16 @@ .Nm .Fl C .Nm -.Op Fl j Ar jail +.Op Fl j Ar jid .Fl g Ar groupname .Nm -.Op Fl j Ar jail +.Op Fl j Ar jid .Fl l .Op Fl du .Op Fl g Ar groupname .Op Ar address_family .Nm -.Op Fl j Ar jail +.Op Fl j Ar jid .Op Fl dkLmuv .Op Fl f Ar type Ns Cm \&: Ns Ar format .Sh DESCRIPTION @@ -257,22 +257,22 @@ Setting to .Cm all selects all interfaces. -.It Fl j Ar jail -Perform the actions inside the -.Ar jail . +.It Fl j Ar jid +Perform the actions inside the jail specified by +.Ar jid , +which may be either a jail name or a numeric jail ID. .Pp The -.Cm ifconfig -will first attach to the -.Ar jail -(by jail id or jail name) before performing the effects. -.Pp -This allow network interfaces of -.Ar jail -to be configured even if the -.Cm ifconfig -binary is not available in -.Ar jail . +.Nm +utility will attach to the specified jail immediately upon +encountering the option on the command line. +The option may be specified multiple times to attach to a nested jail +(jail within a jail). +.Pp +This makes it possible to configure network interfaces within a vnet +jail even if the +.Nm +binary is not available inside the jail. .It Fl k Print keying information for the .Ar interface , diff --git a/sbin/ifconfig/ifconfig.c b/sbin/ifconfig/ifconfig.c index 3f998b7f2b52..c323a26ec1a8 100644 --- a/sbin/ifconfig/ifconfig.c +++ b/sbin/ifconfig/ifconfig.c @@ -463,6 +463,9 @@ args_parse(struct ifconfig_args *args, int argc, char *argv[]) { char options[1024]; struct option *p; +#ifdef JAIL + int jid; +#endif int c; /* Parse leading line options */ @@ -494,7 +497,11 @@ args_parse(struct ifconfig_args *args, int argc, char *argv[]) #ifdef JAIL if (optarg == NULL) usage(); - args->jail_name = optarg; + jid = jail_getid(optarg); + if (jid == -1) + Perror("jail not found"); + if (jail_attach(jid) != 0) + Perror("cannot attach to jail"); #else Perror("not built with jail support"); #endif @@ -611,9 +618,6 @@ main(int ac, char *av[]) { char *envformat; int flags; -#ifdef JAIL - int jid; -#endif struct ifconfig_args _args = {}; struct ifconfig_args *args = &_args; @@ -638,16 +642,6 @@ main(int ac, char *av[]) args_parse(args, ac, av); -#ifdef JAIL - if (args->jail_name) { - jid = jail_getid(args->jail_name); - if (jid == -1) - Perror("jail not found"); - if (jail_attach(jid) != 0) - Perror("cannot attach to jail"); - } -#endif - if (!args->all && !args->namesonly) { /* not listing, need an argument */ args->ifname = args_pop(args); diff --git a/sbin/ifconfig/ifconfig.h b/sbin/ifconfig/ifconfig.h index 468c9b4e80da..672020443b8c 100644 --- a/sbin/ifconfig/ifconfig.h +++ b/sbin/ifconfig/ifconfig.h @@ -249,7 +249,6 @@ struct ifconfig_args { const char *matchgroup; /* Group name to match */ const char *nogroup; /* Group name to exclude */ const struct afswtch *afp; /* AF we're operating on */ - const char *jail_name; /* Jail name or jail id specified */ }; struct option { From nobody Mon Sep 15 18:34:54 2025 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 4cQYbz0cwRz67m1l; Mon, 15 Sep 2025 18:34:55 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQYby6hWsz45Wy; Mon, 15 Sep 2025 18:34:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757961294; 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=haVfUuLh1PMf/00LO169qK3ASa8Ejz+8mRBljFJMhsc=; b=H2mZhERZi9sJYe2BcPEPZDCv32+JHtbNl7XjPnAq976oQkezr/8Gt053ETY2zqMOdT5+n/ FJmyLefDLBHWQ4wzptqP2xWvqMAAHUTyfHdVE/7sOESbojosgXneYUHB7NFU8SleDmtk5o cvV9e7NtczQQ+Q78pMEeQjJRcNeZnDFtobMX49omrR8fOP1o+IOsAWoC0ni9ls3UGRkJlo Qg+JRtwg3QRgBnBqDvUbRfZlTRVj/kCdBd7pNrKScPygTkM8GsUvUjsneRkJ4YzjWXWJ+t owGLnxUT8wSPKZ3EX4xKM0OnT54BJUUSNM7v9VbpsD1ClQWAZ2kgV8tqlSdesw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757961294; 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=haVfUuLh1PMf/00LO169qK3ASa8Ejz+8mRBljFJMhsc=; b=abz3kpZa/KVWSZpJCmbOdmTEOuNCE+vfcFcys6i7z5y8FS0ddz99bbzap1n7wXgNaXSN/k +vbQznSpLkpLEBX29/Dr5BjIf37pBYyQTSKF2d01lIA7J3ec/bNAJDhUYZFC8OoLB8ym6u kuOsSCAhVq8CQoJxnB4DTNR+Hf/p8Zise9PvnrOeulrHOtxjPQ2NzWDD+CQ4o/2H8XtFjW 4pviRTrD0rFD+x8G5A02OGS5gV7Z+HShq4/ZOeA+LJRdW2ySd/vECIQhfwdPDiop8tQZwa D7XhfjPcDBkjwwZVcrgO3qZO4YSG35qOjEU1OsPQ1e2Hxno2PG4NfNxYVJq0ag== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757961294; a=rsa-sha256; cv=none; b=vQPhZDeNu9359WI5UQHEj6M4JFQJtGNmYR/rL9uO1PjD2Wne0ET1i3ILZuhPgQIrybpdmX OWxImcOUaqSB92qDTLY31aZcMBw0tI3M5NHopXFg89J8WSt6sZLTdGwg9VGXr2XUitCM44 8BTyEZuUVvYqJPSEbry8fAVGvF2MU2zSvigKJfEifxAzKIpa6D/5PuMEzseoGdnxEMNiT6 mjXkBftWg184AiUtPyXnqEHfhwpZq39vk1/CiS2RmPBITGTa1NlCsqMl3TupdWfWbzz5s9 Uyc/MQDu3N1MwEOt1f9M1tYE1mwie3IVlXPIvT0bweo/40z8n1PvIkeNdN1XDg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQYby6H0Zz15wY; Mon, 15 Sep 2025 18:34:54 +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 58FIYsPW079689; Mon, 15 Sep 2025 18:34:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FIYswp079685; Mon, 15 Sep 2025 18:34:54 GMT (envelope-from git) Date: Mon, 15 Sep 2025 18:34:54 GMT Message-Id: <202509151834.58FIYswp079685@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Li-Wen Hsu Subject: git: a75c3c2c633d - main - udbc(4): connect to build 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: lwhsu X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a75c3c2c633dfa29b628f692fc7274cab1920640 Auto-Submitted: auto-generated The branch main has been updated by lwhsu: URL: https://cgit.FreeBSD.org/src/commit/?id=a75c3c2c633dfa29b628f692fc7274cab1920640 commit a75c3c2c633dfa29b628f692fc7274cab1920640 Author: Li-Wen Hsu AuthorDate: 2025-09-15 18:34:43 +0000 Commit: Li-Wen Hsu CommitDate: 2025-09-15 18:34:43 +0000 udbc(4): connect to build Reviewed by: thj MFC with: d566b6a70bcbc329e8c690464043401fa8bdd49f Sponsored by: The FreeBSD Foundation --- share/man/man4/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/share/man/man4/Makefile b/share/man/man4/Makefile index 1d708cfda019..c454a696f112 100644 --- a/share/man/man4/Makefile +++ b/share/man/man4/Makefile @@ -1065,6 +1065,7 @@ MAN+= \ ucom.4 \ ucycom.4 \ udav.4 \ + udbc.4 \ udbp.4 \ udl.4 \ uep.4 \ From nobody Mon Sep 15 18:35:27 2025 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 4cQYcb6Nd1z67mZc; Mon, 15 Sep 2025 18:35:27 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQYcb5wNNz45kc; Mon, 15 Sep 2025 18:35:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757961327; 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=TDTIx5pj1zawg+QdfXrNhX2hf3qo3yv4Ae74Hm+SFV8=; b=xd6YuNGBoBG/sG4kLB3IoRybKDCfDpES1ae8z5df4fhJvdTz/ONq2LGGbN9u0ob1uy58vZ Ka3NGRhURHOT3RdeyuFkGACX5x3NkyKYHXPn18/+fAOjOxHtl0I9tDv4eZjHveuPbF000v eqX5PMgp9x42442DF5GQ2tEarH4OMCo+IB6mnO12yhvF+0QeCWqwwVmb+9Z9BcEM7+bAIR PRaxetRcx5x568HvcW4AlS0UDhHUA/MmY/I8bHRMe0lu0Ln2KVQ9/y51JmtnhHcnLLbo+C SlVz8DJJuY/fRKdjQ5WrGBlgbmM8gSBwJa8d5botB1xDtq44gMAUyLB/5fH5tQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757961327; 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=TDTIx5pj1zawg+QdfXrNhX2hf3qo3yv4Ae74Hm+SFV8=; b=FkjJDw+c0HYm8JcB2Kp0SvuRudtGQ7ZyDIFpwn51OWiK1vi/51oh8Y+19mXUfc2fZQEjOl PzD1L8q+HUG9lewXw99PaDgp1YRrJpJc8HjINXs6CzRlNyYILfIM82JvV5RiNdzYAkMGya b0fzuPXtGsXsD5/LjS93Bfrm2K9P+tYD08KNpXAv8faWOAS1w+ovNS4z9rVY84LHtoCDI2 /sdTrSGwXjVFlBIvcx7FRaWJtPMSPDNfNxZDtuxqalkfcSX87Vgs8FBQw3hVhsRmCbgdzd CuWMJ02EHzKLd4dfx7Mk0NgQV8t0jrOuqHVjmnczEU7dw8s7oqxZ3/X+FSULag== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757961327; a=rsa-sha256; cv=none; b=JAD/c2zTNWl5Lk9tgSiGAJ4483E6gBMeFlACVsBFp9L19/pwXIUSRZ6TO+ghwMjhd6auqW qa+US/ijrh+nZ06KWwgdiWzRTwLehOTxOzNZc2fJJMXi1Xx75pbdJxS/KsF2VKd8kchL7c AjoK3zpiBm+I+jwR5YXm7CPwVuE5j742FhoMrhXK9br6ZtaV0iOCp7piJgx12h1IhRHbYs 4PwKspHnz47fyvIxc/gLo4jys7RMz9YFDgdivsTr2jQPKDkgLZtM5FyA+WY9LSz+97TAZu aI0r9xGDZc+hd5Gr+1XWrQKWwkdkrcPI6SeNFdna1AahLMFyZm1sKKAqJOnO8g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQYcb5Vf9z15dT; Mon, 15 Sep 2025 18:35:27 +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 58FIZR6Y079999; Mon, 15 Sep 2025 18:35:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FIZRoW079996; Mon, 15 Sep 2025 18:35:27 GMT (envelope-from git) Date: Mon, 15 Sep 2025 18:35:27 GMT Message-Id: <202509151835.58FIZRoW079996@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Lexi Winter Subject: git: 6d83ae143b1f - main - share/man/man[49]: Set PACKAGE=kernel-man 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6d83ae143b1f598b5f8868508f6e8a7d3440f568 Auto-Submitted: auto-generated The branch main has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=6d83ae143b1f598b5f8868508f6e8a7d3440f568 commit 6d83ae143b1f598b5f8868508f6e8a7d3440f568 Author: Lexi Winter AuthorDate: 2025-09-15 18:22:09 +0000 Commit: Lexi Winter CommitDate: 2025-09-15 18:35:18 +0000 share/man/man[49]: Set PACKAGE=kernel-man When MANSPLITPKG is disabled (which is now the default), the kernel manpages in sections 4 and 9 are installed in the -kernel package instead of the -kernel-man package, because bsd.man.mk doesn't add the -man suffix. Since we already have handling for kernel-man in generate-ucl.lua, set PACKAGE=kernel-man to make sure they're always in the right package. To avoid creating -kernel-man-man when WITH_MANSPLITPKG is enabled, add some logic to bsd.man.mk (suggested by kevans) to avoid adding the -man suffix if the package already has a -man suffix, and while here, ensure ${__group}PACKAGE is always defined. MFC after: 3 seconds Reviewed by: des, bapt Differential Revision: https://reviews.freebsd.org/D52525 --- share/man/man4/Makefile | 2 +- share/man/man9/Makefile | 2 +- share/mk/bsd.man.mk | 7 ++++--- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/share/man/man4/Makefile b/share/man/man4/Makefile index c454a696f112..f5d7a0e081fc 100644 --- a/share/man/man4/Makefile +++ b/share/man/man4/Makefile @@ -1,7 +1,7 @@ .include MANGROUPS= MAN -MANPACKAGE= kernel +MANPACKAGE= kernel-man # If you add a new file here, please consider adding an entry to the # hardware notes template (website/archetypes/release/hardware.adoc in diff --git a/share/man/man9/Makefile b/share/man/man9/Makefile index 5bcde3030ebc..30f41073bcbf 100644 --- a/share/man/man9/Makefile +++ b/share/man/man9/Makefile @@ -1,6 +1,6 @@ .include -PACKAGE= kernel +PACKAGE= kernel-man MAN= accept_filter.9 \ accf_data.9 \ diff --git a/share/mk/bsd.man.mk b/share/mk/bsd.man.mk index a2c34eff9e3e..0a3594e05d94 100644 --- a/share/mk/bsd.man.mk +++ b/share/mk/bsd.man.mk @@ -105,15 +105,16 @@ manlinksinstall: manlinksinstall-${__group} ${__group}OWN?= ${MANOWN} ${__group}GRP?= ${MANGRP} ${__group}MODE?= ${MANMODE} +${__group}PACKAGE?= ${PACKAGE:Uutilities} # Tag processing is only done for NO_ROOT installs. .if defined(NO_ROOT) .if !defined(${__group}TAGS) || ! ${${__group}TAGS:Mpackage=*} -.if ${MK_MANSPLITPKG} == "no" -${__group}TAGS+= package=${${__group}PACKAGE:U${PACKAGE:Uutilities}} +.if ${MK_MANSPLITPKG} == "no" || ${${__group}PACKAGE:M*-man} +${__group}TAGS+= package=${${__group}PACKAGE} .else -${__group}TAGS+= package=${${__group}PACKAGE:U${PACKAGE:Uutilities}}-man +${__group}TAGS+= package=${${__group}PACKAGE}-man .endif .endif From nobody Mon Sep 15 19:11:05 2025 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 4cQZPj5V3yz67sYn; Mon, 15 Sep 2025 19:11:05 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPj4v2jz4FDk; Mon, 15 Sep 2025 19:11:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963465; 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=byRJElEum4P/zcHOdwdkDgY2atPVe4RXpqg+J8RB9G8=; b=B2i6oKIe2JKx+pWx3Nhl7/Rz1dELv2Kfi/2qVUoSkoeCwLJqBMqyIrb+B2RmqBSPma98IR 8XqRMJGwVfVn6oq2H+H7pv5nYM+myd4TJsTWcuLASD2tCrZ/vlVFG3Gh5xrRX+GEcEPNdl SNWZYF6i78hXVm789T1KytCLzBZFSILwxQIEKwfXvgRugAAaMLBUCWrAWbSzU9C7mZ8Te6 lZcvQiPH7dLTgH277DSH46uUYe5VDdsrrM3PYhQLL+Yeb8oAJu1i3Dq2lB4/WThfNWg/o8 wowR5Y/TlAAdaJF1UnTYLEZxQuUjU0GfIo1k0w23iScvyIjQLXnn3PxokbWD3A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963465; 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=byRJElEum4P/zcHOdwdkDgY2atPVe4RXpqg+J8RB9G8=; b=g4C3tnz6Q95WAZjWuhJLNoqn8vUjlmnPvoNLhQ3C6oDlsTtlMu/DDss+gX6y2e1q6Q628X e92WISIF3IrHunzEJ85ftsuV7RqaGfJmsMc20FAuB85XXBcMijYXvd/vhdqLhjib+SfYOf 3dvXEC6qOvWaeIhLjSb+7a8BmfrEb5IQxOxEjmpoyWe56VRB1ujfHfuLt/9EjFiEN9IZjF c2pt9gzU/96lWctwwRYcrSCCsKEreZCiuEFFZ/hAoQWEpnWEykqeY4s1ZN/MF/zYYnMKsy tfEDSo7trZfWoKV+f/K5jhPGvVapFTC/F8Ld32Fln+RPaPg6f86vLt1CSAkDjw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963465; a=rsa-sha256; cv=none; b=JYRIPa6ThHFLvsnjQNez0HfVdmo+Vu4NC9BTYYtUb2knoOe0Oun8RaTOe8K9CCdZGnUkzB 2JX9yZRAVhIfa8pZEdx05c4LLHs5UdgrQSj+gU1vOmZFynMdSYP69cMbumqshjuPyxCVTS rCVtBnbYscrCSL1GKUWuQtDFGWjoe2TA1GaHi7CW6PVfusYpnQjlTkzDLtKlYNEGNrSKdo cOEmAK3NgFZxIPZYPu3win8nRHNVS6FTKGeZ7/7RxXq97EnHEjJWMTCqwkTQUQ9ixz+txz 875g+2OWMMV5pJaAvYCTdAfsI+sl4KKK1NSSyeGSnqAvZN7j1bHyHncuYE8BJg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPj4VPhz16s6; Mon, 15 Sep 2025 19:11:05 +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 58FJB5MS049590; Mon, 15 Sep 2025 19:11:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJB5xj049587; Mon, 15 Sep 2025 19:11:05 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:05 GMT Message-Id: <202509151911.58FJB5xj049587@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 68f8fa4ada24 - stable/15 - LinuxKPI: pci: implement for_each_pci_dev() and improve pci_get_device() 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 68f8fa4ada24aaf53a2d463b53259439dfb32146 Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=68f8fa4ada24aaf53a2d463b53259439dfb32146 commit 68f8fa4ada24aaf53a2d463b53259439dfb32146 Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:20:15 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:50:49 +0000 LinuxKPI: pci: implement for_each_pci_dev() and improve pci_get_device() Implement for_each_pci_dev() needed by a wireless driver update. For that also improve pci_get_device() and add the functionality to support the odev argument to start searching from that. Sponsored by: The FreeBSD Foundation (intially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52066 (cherry picked from commit 910cf345d0ee9a5d72856a1ba35382eb4f0db951) --- sys/compat/linuxkpi/common/include/linux/pci.h | 3 +++ sys/compat/linuxkpi/common/src/linux_pci.c | 12 +++++++++--- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/pci.h b/sys/compat/linuxkpi/common/include/linux/pci.h index 3fd4191b9917..df29af87f160 100644 --- a/sys/compat/linuxkpi/common/include/linux/pci.h +++ b/sys/compat/linuxkpi/common/include/linux/pci.h @@ -1445,6 +1445,9 @@ linuxkpi_pci_get_device(uint32_t vendor, uint32_t device, struct pci_dev *odev) return (lkpi_pci_get_device(vendor, device, odev)); } +#define for_each_pci_dev(_pdev) \ + while ((_pdev = linuxkpi_pci_get_device(PCI_ANY_ID, PCI_ANY_ID, _pdev)) != NULL) + /* This is a FreeBSD extension so we can use bus_*(). */ static inline void linuxkpi_pcim_want_to_use_bus_functions(struct pci_dev *pdev) diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c index d5bbbea1eb2c..00d4a25e86ed 100644 --- a/sys/compat/linuxkpi/common/src/linux_pci.c +++ b/sys/compat/linuxkpi/common/src/linux_pci.c @@ -289,12 +289,18 @@ lkpi_pci_get_device(uint32_t vendor, uint32_t device, struct pci_dev *odev) { struct pci_dev *pdev, *found; - KASSERT(odev == NULL, ("%s: odev argument not yet supported\n", __func__)); - found = NULL; spin_lock(&pci_lock); list_for_each_entry(pdev, &pci_devices, links) { - if (pdev->vendor == vendor && pdev->device == device) { + /* Walk until we find odev. */ + if (odev != NULL) { + if (pdev == odev) + odev = NULL; + continue; + } + + if ((pdev->vendor == vendor || vendor == PCI_ANY_ID) && + (pdev->device == device || device == PCI_ANY_ID)) { found = pdev; break; } From nobody Mon Sep 15 19:11:06 2025 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 4cQZPl1F9Pz67sbb; Mon, 15 Sep 2025 19:11:07 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPk5mwrz4FDn; Mon, 15 Sep 2025 19:11:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963466; 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=1AOB44YM9X2s/g5yQ0ZVLJ8amuRHQe8NTCOwoRczxCQ=; b=qGC521587DaydU8l68NShPUBzDjRINO0p+uf3Pxw1Y2ZKzrlPqqRCUaTw41yQbNRrc2L6o 68iiLXc+8oL4J7Ie7Py2EFB12eL1DPEOAP9jB4GzIvCmYG1olLPKtAYjXyIUo/jedaGCVg w/SXTRkRxXPGgcbWEcmEWgMop53gA8qhGxZLa7hylt3SwxprSeCSxyJhYM1Ni9VaDLVjmh dzxM9aNED9CHvh5hT3ef60jgDoQI1uPq+z01ABGj52JoSPc5QQeE7arg6n2xMhTcNu+1J6 9XVoBM69Zbiq5gqmk6XHtccHBquLcl0oNc0nEetxnfVS+saADpyhkGaSD08Rsg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963466; 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=1AOB44YM9X2s/g5yQ0ZVLJ8amuRHQe8NTCOwoRczxCQ=; b=TESo9t8ZocMLUmkpzKqDmPjI3vYIMoO7zIXzZ0v2d80Ghzr/JPBSqlH2AY8LQiGGCbEPgp KkOrYqZhvnONoexc7ShNaV8BWRyOQIGHAaET4iWTXz9f0Gsre1dBPgW2uFtd5ItCQEynKq VkdwBeAdX2xy2ejA+cIRPbneIQmNYkoB19dmO5rhy6IoiCnBygXlhB0pq/sYgCNJVpWafr A3JCNa8YssQ09TROZ7WwdsSq5lPngm2rLkE7VFPK2iOOsDQpqZu+T8OVK1x+SiI2GdcIUw z3JM76f3jNmnRanj8+tnLzQus/ni7k4Rne9B1Jtt72vMIUFrq3MBJWAaUK2g0Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963466; a=rsa-sha256; cv=none; b=M3F1ybCysINUFsaZqQE4eSEfPVzzd3e2bZSB5oxxgjhfENAWBaQe91BUU4VGb5fCBOBME3 gZJujTsCTyyXZt+sOF5re/dLZ+R51rcyoWRveXxUQabdllxaJP//E269HIXITE9EfUFmsL P7usLZZsz+QUzA4HzLeQBu5b+CpbQAWrZTlS3qP0ukswOVn0GsZXUBl8UkfAyfrgGuYkSq pISaHeORY15NmawXwo5439WnT+AwGahyFkwnW5N8u845R3fFKP8m6a4j4E009m5L7iKp37 O/4NruMKu7yEzwlzRXGVbPc01ZaiIWWGTycxuym7pBYvV6jzLyWoWmpKNFtZCw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPk5Ctyz16jC; Mon, 15 Sep 2025 19:11:06 +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 58FJB65R049626; Mon, 15 Sep 2025 19:11:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJB6Kf049623; Mon, 15 Sep 2025 19:11:06 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:06 GMT Message-Id: <202509151911.58FJB6Kf049623@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: cfb8f4bf2c2b - stable/15 - LinuxKPI: pci: implement pcim_iomap() 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: cfb8f4bf2c2b9cfc8d5ed5a19b98f4a19f023ba6 Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=cfb8f4bf2c2b9cfc8d5ed5a19b98f4a19f023ba6 commit cfb8f4bf2c2b9cfc8d5ed5a19b98f4a19f023ba6 Author: Bjoern A. Zeeb AuthorDate: 2025-07-31 17:45:26 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:51:01 +0000 LinuxKPI: pci: implement pcim_iomap() Like pci_iomap() add the devres version pcim_iomap() using the former to get the resource. Add a helper function to validate that the bar is within a valid range and sprinkle that check also to other related functions. Sponsored by: The FreeBSD Foundation (intially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52067 (cherry picked from commit 2f9064a5d2b50f292cc8699d2be5c66c317f1dc7) --- sys/compat/linuxkpi/common/include/linux/pci.h | 3 ++ sys/compat/linuxkpi/common/src/linux_pci.c | 58 +++++++++++++++++++++++++- 2 files changed, 59 insertions(+), 2 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/pci.h b/sys/compat/linuxkpi/common/include/linux/pci.h index df29af87f160..49d2cd79d474 100644 --- a/sys/compat/linuxkpi/common/include/linux/pci.h +++ b/sys/compat/linuxkpi/common/include/linux/pci.h @@ -365,6 +365,7 @@ void __iomem **linuxkpi_pcim_iomap_table(struct pci_dev *pdev); void *linuxkpi_pci_iomap_range(struct pci_dev *, int, unsigned long, unsigned long); void *linuxkpi_pci_iomap(struct pci_dev *, int, unsigned long); +void *linuxkpi_pcim_iomap(struct pci_dev *, int, unsigned long); void linuxkpi_pci_iounmap(struct pci_dev *pdev, void *res); int linuxkpi_pcim_iomap_regions(struct pci_dev *pdev, uint32_t mask, const char *name); @@ -803,6 +804,8 @@ static inline void pci_disable_sriov(struct pci_dev *dev) linuxkpi_pci_iomap_range(pdev, mmio_bar, mmio_off, mmio_size) #define pci_iomap(pdev, mmio_bar, mmio_size) \ linuxkpi_pci_iomap(pdev, mmio_bar, mmio_size) +#define pcim_iomap(pdev, bar, maxlen) \ + linuxkpi_pcim_iomap(pdev, bar, maxlen) #define pci_iounmap(pdev, res) \ linuxkpi_pci_iounmap(pdev, res) diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c index 00d4a25e86ed..44024e495bb2 100644 --- a/sys/compat/linuxkpi/common/src/linux_pci.c +++ b/sys/compat/linuxkpi/common/src/linux_pci.c @@ -145,6 +145,23 @@ struct linux_dma_priv { #define DMA_PRIV_LOCK(priv) mtx_lock(&(priv)->lock) #define DMA_PRIV_UNLOCK(priv) mtx_unlock(&(priv)->lock) +static void +lkpi_set_pcim_iomap_devres(struct pcim_iomap_devres *dr, int bar, + void *res) +{ + dr->mmio_table[bar] = (void *)rman_get_bushandle(res); + dr->res_table[bar] = res; +} + +static bool +lkpi_pci_bar_id_valid(int bar) +{ + if (bar < 0 || bar > PCIR_MAX_BAR_0) + return (false); + + return (true); +} + static int linux_pdev_dma_uninit(struct pci_dev *pdev) { @@ -763,6 +780,9 @@ _lkpi_pci_iomap(struct pci_dev *pdev, int bar, unsigned long maxlen __unused) struct pci_mmio_region *mmio, *p; int type; + if (!lkpi_pci_bar_id_valid(bar)) + return (NULL); + type = pci_resource_type(pdev, bar); if (type < 0) { device_printf(pdev->dev.bsddev, "%s: bar %d type %d\n", @@ -803,6 +823,9 @@ linuxkpi_pci_iomap_range(struct pci_dev *pdev, int bar, { struct resource *res; + if (!lkpi_pci_bar_id_valid(bar)) + return (NULL); + res = _lkpi_pci_iomap(pdev, bar, maxlen); if (res == NULL) return (NULL); @@ -816,9 +839,41 @@ linuxkpi_pci_iomap_range(struct pci_dev *pdev, int bar, void * linuxkpi_pci_iomap(struct pci_dev *pdev, int bar, unsigned long maxlen) { + if (!lkpi_pci_bar_id_valid(bar)) + return (NULL); + return (linuxkpi_pci_iomap_range(pdev, bar, 0, maxlen)); } +void * +linuxkpi_pcim_iomap(struct pci_dev *pdev, int bar, unsigned long maxlen) +{ + struct pcim_iomap_devres *dr; + void *res; + + if (!lkpi_pci_bar_id_valid(bar)) + return (NULL); + + dr = lkpi_pcim_iomap_devres_find(pdev); + if (dr == NULL) + return (NULL); + + if (dr->res_table[bar] != NULL) + return (dr->res_table[bar]); + + res = linuxkpi_pci_iomap(pdev, bar, maxlen); + if (res == NULL) { + /* + * Do not free the devres in case there were + * other valid mappings before already. + */ + return (NULL); + } + lkpi_set_pcim_iomap_devres(dr, bar, res); + + return (res); +} + void linuxkpi_pci_iounmap(struct pci_dev *pdev, void *res) { @@ -870,8 +925,7 @@ linuxkpi_pcim_iomap_regions(struct pci_dev *pdev, uint32_t mask, const char *nam res = _lkpi_pci_iomap(pdev, bar, 0); if (res == NULL) goto err; - dr->mmio_table[bar] = (void *)rman_get_bushandle(res); - dr->res_table[bar] = res; + lkpi_set_pcim_iomap_devres(dr, bar, res); mappings |= (1 << bar); } From nobody Mon Sep 15 19:11:07 2025 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 4cQZPm2T8wz67sQy; Mon, 15 Sep 2025 19:11:08 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPl6S94z4F67; Mon, 15 Sep 2025 19:11:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963467; 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=lHZSTSLbqVHWaIXgXDu0YKXOI3bNdstdWixSfzHZEI4=; b=FaTyFnU9N2iePPzIRjgp/N2KkXAVbPQtkdNZsC6NGw1Rj6GHbRmQzRojzwB5cI+S3BBik7 OyqaeIXzc+RcmM37XVGlrD8nmRjOwPq/7qkc6+15fuEA/p0rr2kVV/TJ/tltbLMX7agZaq vmLHx16f5JtJf0ntLymAc8Hz5tWdPfon99SIP/nBTuxCsyEx3uq+AAvMPNX7ANbaVcdMkr tilc4sCTovB+pBRyd171F23nY5aOYO6hPU5gc4fGjbOympNDicg/oTvtoWuKpABpOigErA p73Skl9Ld1/GpdG0Rzt910kmNN+2xEZtkqNEyCYIn4TbuYjHiXk2IBviv8BWUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963467; 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=lHZSTSLbqVHWaIXgXDu0YKXOI3bNdstdWixSfzHZEI4=; b=QgtQ6Kno9JEzLxu7I2uIQuDmehwo44tdOYhSQxSLUFk0t3wms43sYE4F+rEvTT5sU7ClIg KJWxJonm22o4xnTuo6OHgzerf64MdRIR5/Aq9dEPlKjzXAwUFN1zI9+ldVRNat5TStTfpy lV2fLnGytbzN+4FEa7zssCVkPTX6fsRBZgtq1ziDnA+DJhF/say//NcU4VXY34+olB2Lay NKY6Aofrec/nsqR3E1pZzi4f8gVP1Ror9/fto9HdDN9UgeTfqTgkssVOxedd47O3If7QQa Y9Mgg42vjw3ObyLDty5uI2Hz4oOWo3IXYM/xT7cbOyyLsMVsaQz7OieEr99i5A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963467; a=rsa-sha256; cv=none; b=lhiRy+bopw8MJt4ShJ6TkWFXm+gC1xAUoQWjSFWsdo+3T59/sK6jslDx0q9qusCaWhH1me BkolDWKRVM7D1Fr3WoqfVq/FEUDA9RVMsk+OflA29rodL1wUE46anCIwFR/Rad57nlDpmI Ua6GMmeZPMTxm8ZRoV9JzoBAITTJ1aciInwXu7/I26T03OiH9IjqHMM29FDDU/tEKG06Tw h8JCb3FRXSmm9lwC6e9jIRhlqg9vl/hP0o7MWmNCYcu045Wqj5RcMyBGSL+J5YN0Y3wuLX NJWaROompbrzLx845EWIxq03jly6ct59HHd7fZcwuNw1lxBgMDbraIefW1gR2Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPl5vj8z16gS; Mon, 15 Sep 2025 19:11:07 +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 58FJB74b049667; Mon, 15 Sep 2025 19:11:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJB7uf049664; Mon, 15 Sep 2025 19:11:07 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:07 GMT Message-Id: <202509151911.58FJB7uf049664@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: ff31767e530a - stable/15 - LinuxKPI: pci: implement [linuxkpi_]pcim_request_all_regions() 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: ff31767e530abb4a54131af199fed6ec946a5fa4 Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=ff31767e530abb4a54131af199fed6ec946a5fa4 commit ff31767e530abb4a54131af199fed6ec946a5fa4 Author: Bjoern A. Zeeb AuthorDate: 2025-07-31 18:28:22 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:51:12 +0000 LinuxKPI: pci: implement [linuxkpi_]pcim_request_all_regions() Factor out the pci_request_region() implementation into an internal function and make pci_request_region() a simple wrapperaround it. Likewise implement pcim_request_all_regions() as a loop calling pci_request_region() for each entry. In two cases which we returned an error before (bar index is valid but bar is not (no len), and neither IO nor MEM) we now reutrn success (nothing to do for us). Otherwise callers, especially pcim_request_all_regions() would error out for the wrong reasons. This seems to also match the expected behaviour of pci_request_region(). Sponsored by: The FreeBSD Foundation (intially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52068 (cherry picked from commit 7e21158d44cd46e720395604ca6f00f2fa36b20c) --- sys/compat/linuxkpi/common/include/linux/pci.h | 11 ++++-- sys/compat/linuxkpi/common/src/linux_pci.c | 55 ++++++++++++++++++++++---- 2 files changed, 56 insertions(+), 10 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/pci.h b/sys/compat/linuxkpi/common/include/linux/pci.h index 49d2cd79d474..d891d0df3546 100644 --- a/sys/compat/linuxkpi/common/include/linux/pci.h +++ b/sys/compat/linuxkpi/common/include/linux/pci.h @@ -355,7 +355,6 @@ struct pci_dev { TAILQ_HEAD(, pci_mmio_region) mmio; }; -int pci_request_region(struct pci_dev *pdev, int bar, const char *res_name); int pci_alloc_irq_vectors(struct pci_dev *pdev, int minv, int maxv, unsigned int flags); bool pci_device_is_present(struct pci_dev *pdev); @@ -369,7 +368,9 @@ void *linuxkpi_pcim_iomap(struct pci_dev *, int, unsigned long); void linuxkpi_pci_iounmap(struct pci_dev *pdev, void *res); int linuxkpi_pcim_iomap_regions(struct pci_dev *pdev, uint32_t mask, const char *name); +int linuxkpi_pci_request_region(struct pci_dev *, int, const char *); int linuxkpi_pci_request_regions(struct pci_dev *pdev, const char *res_name); +int linuxkpi_pcim_request_all_regions(struct pci_dev *, const char *); void linuxkpi_pci_release_region(struct pci_dev *pdev, int bar); void linuxkpi_pci_release_regions(struct pci_dev *pdev); int linuxkpi_pci_enable_msix(struct pci_dev *pdev, struct msix_entry *entries, @@ -562,12 +563,16 @@ done: return (pdev->bus->self); } +#define pci_request_region(pdev, bar, res_name) \ + linuxkpi_pci_request_region(pdev, bar, res_name) #define pci_release_region(pdev, bar) \ linuxkpi_pci_release_region(pdev, bar) -#define pci_release_regions(pdev) \ - linuxkpi_pci_release_regions(pdev) #define pci_request_regions(pdev, res_name) \ linuxkpi_pci_request_regions(pdev, res_name) +#define pci_release_regions(pdev) \ + linuxkpi_pci_release_regions(pdev) +#define pcim_request_all_regions(pdev, name) \ + linuxkpi_pcim_request_all_regions(pdev, name) static inline void lkpi_pci_disable_msix(struct pci_dev *pdev) diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c index 44024e495bb2..7db8af8e88f9 100644 --- a/sys/compat/linuxkpi/common/src/linux_pci.c +++ b/sys/compat/linuxkpi/common/src/linux_pci.c @@ -1159,8 +1159,9 @@ pci_resource_len(struct pci_dev *pdev, int bar) return (rle->count); } -int -pci_request_region(struct pci_dev *pdev, int bar, const char *res_name) +static int +lkpi_pci_request_region(struct pci_dev *pdev, int bar, const char *res_name, + bool managed) { struct resource *res; struct pci_devres *dr; @@ -1168,9 +1169,20 @@ pci_request_region(struct pci_dev *pdev, int bar, const char *res_name) int rid; int type; + if (!lkpi_pci_bar_id_valid(bar)) + return (-EINVAL); + + /* + * If the bar is not valid, return success without adding the BAR; + * otherwise linuxkpi_pcim_request_all_regions() will error. + */ + if (pci_resource_len(pdev, bar) == 0) + return (0); + /* Likewise if it is neither IO nor MEM, nothing to do for us. */ type = pci_resource_type(pdev, bar); if (type < 0) - return (-ENODEV); + return (0); + rid = PCIR_BAR(bar); res = bus_alloc_resource_any(pdev->dev.bsddev, type, &rid, RF_ACTIVE|RF_SHAREABLE); @@ -1183,11 +1195,16 @@ pci_request_region(struct pci_dev *pdev, int bar, const char *res_name) /* * It seems there is an implicit devres tracking on these if the device - * is managed; otherwise the resources are not automatiaclly freed on - * FreeBSD/LinuxKPI tough they should be/are expected to be by Linux - * drivers. + * is managed (lkpi_pci_devres_find() case); otherwise the resources are + * not automatically freed on FreeBSD/LinuxKPI though they should be/are + * expected to be by Linux drivers. + * Otherwise if we are called from a pcim-function with the managed + * argument set, we need to track devres independent of pdev->managed. */ - dr = lkpi_pci_devres_find(pdev); + if (managed) + dr = lkpi_pci_devres_get_alloc(pdev); + else + dr = lkpi_pci_devres_find(pdev); if (dr != NULL) { dr->region_mask |= (1 << bar); dr->region_table[bar] = res; @@ -1203,6 +1220,12 @@ pci_request_region(struct pci_dev *pdev, int bar, const char *res_name) return (0); } +int +linuxkpi_pci_request_region(struct pci_dev *pdev, int bar, const char *res_name) +{ + return (lkpi_pci_request_region(pdev, bar, res_name, false)); +} + int linuxkpi_pci_request_regions(struct pci_dev *pdev, const char *res_name) { @@ -1219,6 +1242,24 @@ linuxkpi_pci_request_regions(struct pci_dev *pdev, const char *res_name) return (0); } +int +linuxkpi_pcim_request_all_regions(struct pci_dev *pdev, const char *res_name) +{ + int bar, error; + + for (bar = 0; bar <= PCIR_MAX_BAR_0; bar++) { + error = lkpi_pci_request_region(pdev, bar, res_name, true); + if (error != 0) { + device_printf(pdev->dev.bsddev, "%s: bar %d res_name '%s': " + "lkpi_pci_request_region returned %d\n", __func__, + bar, res_name, error); + pci_release_regions(pdev); + return (error); + } + } + return (0); +} + void linuxkpi_pci_release_region(struct pci_dev *pdev, int bar) { From nobody Mon Sep 15 19:11:08 2025 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 4cQZPn3ydHz67sc7; Mon, 15 Sep 2025 19:11:09 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPn0dQTz4FVr; Mon, 15 Sep 2025 19:11:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963469; 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=PPal/o6nwQYKaRdXMS2pL0g7Xd1yReFbl7CE880yCPA=; b=qNRvjQAYyRl1mkG/QL1/7Q/Eruw26pbPgG4YZ4AYZ7RdvNJT550tQQSunLaZrQpuEBoI3l 5vmyETpIAtVvPaaWqcXxXpIsF5KGASXmEQ8wcUilPFGDnZXiiRxVStOWzGcCemWx0Ko2ij xYKl0i8F8Pi9Fv1mT8oIwoRu7hREVPXk+9KEEBfcCAoRXUVoycTcNrDCaEGp3Y9RTKvzBL +IQivo5Vn3iAi2K6IZDAqDqL+cCdkNQTVeaE2dJfJMFUyiNaTIBq96TtnVj3AAPtan3bRN v+gDhTANYNY66+jtObks4Zpm0tS4Zukg0zS9mNL+13Cq6AtqFZYwyC2PEV+juA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963469; 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=PPal/o6nwQYKaRdXMS2pL0g7Xd1yReFbl7CE880yCPA=; b=lvDKTS3OadkaJXRDVSW1Pqnc7OVskfmWm8f54OwHUeiNv8nyBXOmINqR7vhqXab15Fgrw9 F4MyRyXoMnTS3lqlKOaHPz4RXeh5x9st/qu0Id1bNU8E0pp5fpl2t+NYyq1OifkoVa1j8/ ALrjkGL04G0VhvIrGE/Y0g60a0liIVsfNpJhwtIzwsfI3LXyCPvy735D1Nty1mues4kfVi LQScEbing0TO5SbiB+fSYp0o4L+qCUsv6XPwN7HsQHTcatfbpbplUkcV2rLg5ghAmfbkDk 7N/oSqZDW7ddD8Xl8EIa+MAUUXQOI6WhXNZBGKz66NvqO2A6DElS/QdybnKiJQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963469; a=rsa-sha256; cv=none; b=ZCLWPVhef3I1ECNK3vTFVFN5gj3c4XoIP1YJhdwsbbljFwZi3J/sILAxBG2gf61/whmJ3U pQ7cQ3bn9+XSazxWJBUIIzM7HYuj5I1sUW/PO5292lOL3FhQpChWDhTMII4cc9C6BCDRpH 0O8LEaqdsg1MeFGi8HqkKasmwuu2z7RBNXPROHyW/MJaY4SLFz/hsru7GccjV5lQGF6xcJ BZwMyJjXP8/BFv3IU2kfz53kbucLQhnJ5QqcDq7xC6nw9roJ9ArO317NzsGcLwqRXDVyht c4zu/QXoU2dklANSnld6SZzTaOz/xdMefTi8eocOFdnmUUK3pN9ud1+l/gTc/Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPn05hCz16RC; Mon, 15 Sep 2025 19:11:09 +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 58FJB8BH049702; Mon, 15 Sep 2025 19:11:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJB8HE049699; Mon, 15 Sep 2025 19:11:08 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:08 GMT Message-Id: <202509151911.58FJB8HE049699@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 8fca57469f7c - stable/15 - LinuxKPI: pci: allow children to be attached to a pci_dev 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 8fca57469f7c33367c5f32f738a8fa8af40b6dda Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=8fca57469f7c33367c5f32f738a8fa8af40b6dda commit 8fca57469f7c33367c5f32f738a8fa8af40b6dda Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:22:30 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:51:18 +0000 LinuxKPI: pci: allow children to be attached to a pci_dev This will be used for hooking suspend/resume in for LinuxKPI 802.11 based drivers. Sponsored by: The FreeBSD Foundation (initially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52070 (cherry picked from commit 627234627b51c2f12c29d10617d7bbd18936ea55) --- sys/compat/linuxkpi/common/src/linux_pci.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c index 7db8af8e88f9..43fd6ad28ac4 100644 --- a/sys/compat/linuxkpi/common/src/linux_pci.c +++ b/sys/compat/linuxkpi/common/src/linux_pci.c @@ -111,6 +111,9 @@ static device_method_t pci_methods[] = { DEVMETHOD(pci_iov_uninit, linux_pci_iov_uninit), DEVMETHOD(pci_iov_add_vf, linux_pci_iov_add_vf), + /* Bus interface. */ + DEVMETHOD(bus_add_child, bus_generic_add_child), + /* backlight interface */ DEVMETHOD(backlight_update_status, linux_backlight_update_status), DEVMETHOD(backlight_get_status, linux_backlight_get_status), From nobody Mon Sep 15 19:11:10 2025 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 4cQZPp3vsqz67sdy; Mon, 15 Sep 2025 19:11:10 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPp1mh7z4FQV; Mon, 15 Sep 2025 19:11:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963470; 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=BB/ROqrld5XbbeL3exq9RINmiHGeK5ll9PflvufRsms=; b=VPsMDZOygl9FOIjh1BngyHPVF2ujyYZhZoOXiASWngCpUZV7k+J9qlG5LhUruDWZ/L4AVl SdxtqZG4XUbpEkOLpCYJorFxEyKkPJzmaU2lthE/AdsLmWx4ddqtBxBO7P6ziHUbA3j47w oC+makNiKolN28BIF83+zDMLGzG94rHLojfty+SnvgG4j4qe6q4r92UHBG3UlfNn2GUpo7 Y3UKgv6lYjD3YBOLzGIx2FAmOtxAB32dGfLKWIVXYg7KaWg1tzmqHlfV4Eex8sjA87nfud yLwwSVxLXrmM26IEn/ujgfc771z4LUOQbzLNEHdYyAoY5V+7SW2VIYWcu0/9tg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963470; 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=BB/ROqrld5XbbeL3exq9RINmiHGeK5ll9PflvufRsms=; b=YQGG2PqnlRE+RCmdTYuubXVd1BNouWaw5wGJnDwwkNtrRpcfcKSpt2W7E3ZV3Em9elKmw6 N2bjuezsYiv02OkAXec4Eg877LPbSDqlKLcAO9reAiT+cTMiim8u+MOscpLGYhwkfVQnYK 26TR+kwnDuFM0yNwlttEk6Hyl6waAdRMwmO4vvUzBad52slZ8gycw47BhRVS/SAhiQ6S/X 4+oZKENu0Iq/al7L1EqVSlk3kHzBwrr242JxuhrMGPdpbIq5duWoWLKI6ngwb9SSVP2BRm 7XBpX3LKUIUoCq0oDuEy4L01q7y7dLJtI1G7DQxzbVvndApPZfqNtNdOqj32mQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963470; a=rsa-sha256; cv=none; b=yUyeci2jHZSODJJBHViZXPebLqjalWAriP/LEU46bIOSTaI6fc1FwFl4G/dl42MPjVIWWx ox1ZnTKZi7U1Q2JJOCcbAUL1amJmuK9+zaBYeKrozaW6PMJYl3FNeNl0F8uTH0wMqsVl8k D8Ta05b7MpFrtAraNMImu+0tUIj4bM5RUKhMnnk9WKWfuVx4Vdy2C++/gVb+Mobvxy3Nkh cQSvzPzi2yeXIzIyRWbi7DIwvfFYuqHj9bNXQNcIPgd+phXLu/Yo4K/cvpKIjmmdErvlB+ bZ+x5M0LwJbLNUrKSEAWLiPoy1xZccl1uUdBMkdDngNvqGZu1oNxXOgtgKU9dA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPp1681z15g4; Mon, 15 Sep 2025 19:11:10 +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 58FJBAsH049737; Mon, 15 Sep 2025 19:11:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBArQ049734; Mon, 15 Sep 2025 19:11:10 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:10 GMT Message-Id: <202509151911.58FJBArQ049734@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: ab45c859374d - stable/15 - LinuxKPI: correct the LINUXKPI_VERSION check for abs_diff() 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: ab45c859374d750a6b68292cf40889b8ca5db04a Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=ab45c859374d750a6b68292cf40889b8ca5db04a commit ab45c859374d750a6b68292cf40889b8ca5db04a Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:23:00 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:51:26 +0000 LinuxKPI: correct the LINUXKPI_VERSION check for abs_diff() The code introduced abs_diff() as migrated from drm to standard linux headers. The LINUXKPI_VERSION check did not allow this to be visible by default in-tree. Make sure the v6.6 check is optional. drm-kmod always defines LINUXKPI_VERSION so this should be fine. Sponsored by: The FreeBSD Foundation (initially) Fixes: afc450fac9f04 Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52071 (cherry picked from commit 736b16e88d2384f9dd0ec11c0492e825b8d42193) --- sys/compat/linuxkpi/common/include/linux/math.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/include/linux/math.h b/sys/compat/linuxkpi/common/include/linux/math.h index 5a348a57747b..1d50e011f66d 100644 --- a/sys/compat/linuxkpi/common/include/linux/math.h +++ b/sys/compat/linuxkpi/common/include/linux/math.h @@ -56,7 +56,7 @@ __ret; \ }) -#if defined(LINUXKPI_VERSION) && LINUXKPI_VERSION >= 60600 +#if !defined(LINUXKPI_VERSION) || (LINUXKPI_VERSION >= 60600) #define abs_diff(x, y) ({ \ __typeof(x) _x = (x); \ __typeof(y) _y = (y); \ From nobody Mon Sep 15 19:11:11 2025 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 4cQZPq4k5cz67skp; Mon, 15 Sep 2025 19:11:11 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPq2SG0z4FFS; Mon, 15 Sep 2025 19:11:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963471; 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=O2sawGkUpp4oIJbTADLG4rD821dWEiuZuBMoz70uBxE=; b=jku1MDnHhGc0nebSXP95UFzGjnqAXXdeRzgxZw4ICHOIOnzTcA8xyR+lN46zX4jFwXKpLU mqIWQW+NlEzk3P1ZjoG4vslA7xGvk1OST9Ynwr2i73JXDH6txSDxM/8gDTjS3yFL+1aS8/ IaPonjOhulMgA4qZhf4AtPDCF6mn60yXtf0N7b30EqIINjgXnHUNVo/Zw+Cay5AcDhFnsU wY3ANASCpr16SSSCRIB2F6mR4RqzUUU6m40zdck+ljpQNsHxnxd0BM9krPfPN6aG+QjY9z NYaEOM4ljtUqLopyTSKOvPHdnI8aSFNvYBVZFobct8Q0PiYVl/KFVhE8p+T63A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963471; 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=O2sawGkUpp4oIJbTADLG4rD821dWEiuZuBMoz70uBxE=; b=YINLjSCedtDUJTTRC0OJC6MnOfgglqun5UFVJLQbvYL8EE0w4gOygpVKdqJR7tpUsT7m+5 m2h6TdTn4qJw1bSc/LIDDxz4kG/3UWLvyXQO2j3phAK61RpkrQabPWGvORmRYvrGW/KKyt vE/CYnjeiKqac8cSysaCOEeAQQgaeCmPw6S+KDWX5eZ7CMeq2xZBsJckX3YF3YnzyqJY2M XJkPqcSXTMQVMd8gVgTIxBUVNxUUf7XqJeIaZRzaduKQkLzeWtJ02+Q3bPi0G2DIkV6SVo /wsx96RX+ANbLRyLBTW2UFjkxYndv65sswLf7xcol71SrMxFCmWHpkqarZlrdA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963471; a=rsa-sha256; cv=none; b=LZerANa6bFmNr5LReNn9QPGLIrEoEebrwUkY8++A0V9ztKa/2KWMJHJNLUxwVl3fwetZXM t6mHOWq0MN1qQPGeFOyRY7KYhiZ+j5lk+Oi6pi2spHjYK/tJp/AAZl9HjXb8W4InHLBlu1 C5vUoJwIVG2zZFXWSc5s8PP+CfZMYuIJ8a+BGePbDekwWl8DomLu93tsImVT/0LSPM/7/D 7dT0zuPDRNLGD413T6Jmb82uf8I6CFimpN8v+6aNnSzC3wgBcihY3svyi7k4hWJvl4Q+Bt YLOjOjkG/oZQEIbp//rMuVVFgnwjVyZUC45mM8qTBlT2q3BSs02C7WSlVewksw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPq1zytz16VL; Mon, 15 Sep 2025 19:11:11 +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 58FJBB5Q049778; Mon, 15 Sep 2025 19:11:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBBh0049775; Mon, 15 Sep 2025 19:11:11 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:11 GMT Message-Id: <202509151911.58FJBBh0049775@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: aa673b7101d9 - stable/15 - LinuxKPI: acpi; fix type to acpi_get_handle() 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: aa673b7101d9ca8c2f1353d1d5093fb548f8388d Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=aa673b7101d9ca8c2f1353d1d5093fb548f8388d commit aa673b7101d9ca8c2f1353d1d5093fb548f8388d Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:23:31 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:51:36 +0000 LinuxKPI: acpi; fix type to acpi_get_handle() The native AcpiGetHandle() and acpi_get_handle() take a const char * argument for pathname and not an acpi_string (char *). For that they spell it out fully as 'const char *', so should we. Sponsored by: The FreeBSD Foundation (intially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52072 (cherry picked from commit c1264b6238c97810849bc38818d27c1ade1d4fc1) --- sys/compat/linuxkpi/common/include/acpi/acpi.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/include/acpi/acpi.h b/sys/compat/linuxkpi/common/include/acpi/acpi.h index 016c7ede0f6e..9bb435591daa 100644 --- a/sys/compat/linuxkpi/common/include/acpi/acpi.h +++ b/sys/compat/linuxkpi/common/include/acpi/acpi.h @@ -131,7 +131,7 @@ acpi_format_exception(ACPI_STATUS Exception) } static inline ACPI_STATUS -acpi_get_handle(ACPI_HANDLE Parent, ACPI_STRING Pathname, +acpi_get_handle(ACPI_HANDLE Parent, const char *Pathname, ACPI_HANDLE *RetHandle) { return (AcpiGetHandle(Parent, Pathname, RetHandle)); From nobody Mon Sep 15 19:11:12 2025 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 4cQZPs1Gvzz67sj2; Mon, 15 Sep 2025 19:11:13 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPr3LYWz4FYt; Mon, 15 Sep 2025 19:11:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963472; 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=T+fxD+sUhf5NFs9285ZI182mqpG/kQE2UUMQqMqFYqs=; b=MP/DDi6+mJpHL6PDTiZOCSDkY0dyFYo3aKg6/LtoPtX+lm60+CLJXc+4/JGRz1zG3GX++2 MHAl1+JoH1JzBkBWupuw2efCZ2gNQiPDddIvIH5IXxXSoYY+0SMs+sy6tKsFMH3vIg3K39 Tfa/zcP8Vd0zU5My3l9QlNuEsJYLVc/1ErE+mYimOmKgMczx47kV/f1oOOMQyUhoSMU8Sr Mi5fcQ0kirVHEbsadLyFEr/a3fn6XB9lACxPMsP4TJV51Bz6Rtbnu/eFH1Ss9Yi6Kpj3Sy GeDIGErg2NRYV7bETmrDX9aDiIkz+sIZF9DJBf/rsipM9iwKElknOAYubvBZEg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963472; 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=T+fxD+sUhf5NFs9285ZI182mqpG/kQE2UUMQqMqFYqs=; b=ZYFSUaYhHw+jPmqH5EjINtTdnngFRZNYG5nGYXvkLwgCQAuUI60AM6e0CeCit7JPJu6S40 0LIlrQ6y2MxW3UNn3M+56vSkc0MPlD7baK4Lcixl//95mx+JXYfInWDuVHIfU5mvcSgfYj 7VZ/PeXGKcWxVQo6Pg/b5H4foR71cX22+czeJGyZvpMEHSxSQcQluu/D6dpZ98X4QpNY7x wKCeuy7OyDwik/ZrqUj1s3JUXicbylvWGZPGWN3mTCFaXFmxfVzzaHJSCEyD6W64KAIOza KJBHmdaX8jI5Bz+eKLA8fjljL0utBua/k6JznQfdfhulDTucLCBLqkc/uW5kRw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963472; a=rsa-sha256; cv=none; b=EuW/WNe6yvBTiAcuqzmlZ/ei7tIq8tE6iPCDpLHVnDZUos4YFIYtEMhnq4DDFUF31QPb0b KC0mCueFKAof2pPROSvLu0V6nt6f5eSlp6Pape9smo5qCpqvzweCcCH5T0bdGT7nsy11ZX +ZJQAkNgIiK9u4yU4BsT4GQ9Ks42WQUZQUS4sOIkbaSJSKhh7UfWMT+A6tCPJEpBgzB7nR ggwI5LY0YBKKvGmLPfPwM6lPFEC3M++kqrzQM8juQZlVypiMn+ZC+Lc4Qsrq/4GFGidG88 /T8ovkX0D/8JlGEEJfLwDvqigBlbEte+io4O26DhRy2lZElg+LADHCKigAPpGg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPr2hCbz16dx; Mon, 15 Sep 2025 19:11:12 +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 58FJBCu6049816; Mon, 15 Sep 2025 19:11:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBCer049812; Mon, 15 Sep 2025 19:11:12 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:12 GMT Message-Id: <202509151911.58FJBCer049812@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 352be5b48ba8 - stable/15 - LinuxKPI: rename from_timer() to timer_container_of() 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 352be5b48ba8b3ec1e3e5dd0dbee4da8d1fa78b0 Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=352be5b48ba8b3ec1e3e5dd0dbee4da8d1fa78b0 commit 352be5b48ba8b3ec1e3e5dd0dbee4da8d1fa78b0 Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:23:57 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:51:41 +0000 LinuxKPI: rename from_timer() to timer_container_of() With Linux 6.16 from_timer() got renamed to timer_container_of(); add the LINUXKPI_VERSION check with a default to the current version. Update all in-tree consumers (apart from wireless drivers managed otherwise). Sponsored by: The FreeBSD Foundation (initially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52073 (cherry picked from commit 81cb7c4c8e7bc4951c77fe64a63a847ed6abee38) --- sys/compat/linuxkpi/common/include/linux/timer.h | 5 +++++ sys/compat/linuxkpi/common/src/linux_80211.c | 2 +- sys/dev/irdma/irdma_cm.c | 2 +- sys/dev/irdma/irdma_utils.c | 4 ++-- sys/dev/qat/qat_common/adf_gen4_timer.c | 2 +- 5 files changed, 10 insertions(+), 5 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/timer.h b/sys/compat/linuxkpi/common/include/linux/timer.h index a635f0faea59..bd06e3158fa3 100644 --- a/sys/compat/linuxkpi/common/include/linux/timer.h +++ b/sys/compat/linuxkpi/common/include/linux/timer.h @@ -49,8 +49,13 @@ extern unsigned long linux_timer_hz_mask; #define TIMER_IRQSAFE 0x0001 +#if defined(LINUXKPI_VERSION) && (LINUXKPI_VERSION < 61600) #define from_timer(var, arg, field) \ container_of(arg, typeof(*(var)), field) +#else +#define timer_container_of(var, arg, field) \ + container_of(arg, typeof(*(var)), field) +#endif #define timer_setup(timer, func, flags) do { \ CTASSERT(((flags) & ~TIMER_IRQSAFE) == 0); \ diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index f0881773726f..d00734001a59 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -7814,7 +7814,7 @@ lkpi_wiphy_delayed_work_timer(struct timer_list *tl) { struct wiphy_delayed_work *wdwk; - wdwk = from_timer(wdwk, tl, timer); + wdwk = timer_container_of(wdwk, tl, timer); wiphy_work_queue(wdwk->wiphy, &wdwk->work); } diff --git a/sys/dev/irdma/irdma_cm.c b/sys/dev/irdma/irdma_cm.c index 450fae662dd8..d4d4f328fb43 100644 --- a/sys/dev/irdma/irdma_cm.c +++ b/sys/dev/irdma/irdma_cm.c @@ -1316,7 +1316,7 @@ irdma_cm_timer_tick(struct timer_list *t) struct irdma_timer_entry *send_entry, *close_entry; struct list_head *list_core_temp; struct list_head *list_node; - struct irdma_cm_core *cm_core = from_timer(cm_core, t, tcp_timer); + struct irdma_cm_core *cm_core = timer_container_of(cm_core, t, tcp_timer); struct irdma_sc_vsi *vsi; u32 settimer = 0; unsigned long timetosend; diff --git a/sys/dev/irdma/irdma_utils.c b/sys/dev/irdma/irdma_utils.c index 5fc37022981f..038f1980082b 100644 --- a/sys/dev/irdma/irdma_utils.c +++ b/sys/dev/irdma/irdma_utils.c @@ -876,7 +876,7 @@ irdma_terminate_done(struct irdma_sc_qp *qp, int timeout_occurred) static void irdma_terminate_timeout(struct timer_list *t) { - struct irdma_qp *iwqp = from_timer(iwqp, t, terminate_timer); + struct irdma_qp *iwqp = timer_container_of(iwqp, t, terminate_timer); struct irdma_sc_qp *qp = &iwqp->sc_qp; irdma_terminate_done(qp, 1); @@ -1528,7 +1528,7 @@ static void irdma_hw_stats_timeout(struct timer_list *t) { struct irdma_vsi_pestat *pf_devstat = - from_timer(pf_devstat, t, stats_timer); + timer_container_of(pf_devstat, t, stats_timer); struct irdma_sc_vsi *sc_vsi = pf_devstat->vsi; if (sc_vsi->dev->hw_attrs.uk_attrs.hw_rev >= IRDMA_GEN_2) diff --git a/sys/dev/qat/qat_common/adf_gen4_timer.c b/sys/dev/qat/qat_common/adf_gen4_timer.c index 96b65cdff181..2c74d09418e5 100644 --- a/sys/dev/qat/qat_common/adf_gen4_timer.c +++ b/sys/dev/qat/qat_common/adf_gen4_timer.c @@ -57,7 +57,7 @@ end: static void timer_handler(struct timer_list *tl) { - struct adf_int_timer *int_timer = from_timer(int_timer, tl, timer); + struct adf_int_timer *int_timer = timer_container_of(int_timer, tl, timer); struct adf_accel_dev *accel_dev = int_timer->accel_dev; struct adf_hb_timer_data *hb_timer_data = NULL; u64 timeout_val = adf_get_next_timeout(int_timer->timeout_val); From nobody Mon Sep 15 19:11:13 2025 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 4cQZPs6kj2z67sTv; Mon, 15 Sep 2025 19:11:13 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPs487Sz4FnP; Mon, 15 Sep 2025 19:11:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963473; 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=9Q8glrBFEMy5ICMx4ChAhBmD2a7noMLrdvt0QZk9ZJw=; b=IcdxnHJRKmTq/UnxF4pU4Vy9UPjS3cy5yRvhHnavuxj8WW9vBoiJAgMvnX8OxD9gMa7gZd O0rTchWL5qU5RN7gvAjZ/0JbKU2E+zat08UbsQ+/k6421hOiAgvV+65k0wFaMT89Z2fwOY dSNSB2wmiVu9QYSveXHnCpNvXQJlahwiYxmlWH6UI6xX/mrWSXSRGchaIL5HMYwi/WKWG7 FTWXDm/pJaZTwqjEptnXZHKSIGn1INQsGTWyikjXGM2YbDIx4nhFdk/4jz/WvuSs0FVoKO kXierEhRTYOCjr4UfxMlPGc+xImndD2fNe6WhkBCy2cZicrZgjht+g4DzG4cLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963473; 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=9Q8glrBFEMy5ICMx4ChAhBmD2a7noMLrdvt0QZk9ZJw=; b=i6LpPL2o1A8M9bwT9ixEudiqm9F5L3daLhshdCH63QRKND9nq49nPBLZzZzvHJEfCBjT2+ hT0qHuHp6O7vAZIGbqHVxsfZ4MAjlN5iC87NQdYPUP9qNKxhQCVrOTcnVoBdMNlaQgJ4vE UbBYW4D/rrbGzTD75AqtksRkrsF98zF5Q4i7l68b2wIuWuZCpeoewaVU306dJtUbrs/qTm aR0OWEb+N5fYHHlgxrutn11bciYUuxbEJzpb/tiYBCcqKYC6On35PMf91tmuDhYJGAO3Jw Ezyp/BlI+bFdCtkBLnRciHN7GI6mvWiw9KFd2y19xkWrC4UO4XPj27y6C6pVLA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963473; a=rsa-sha256; cv=none; b=XcLoj4WgacIlY08YqNN8EMm0BrOXJXus8foIbDaRCMpvXNkwoA8DKv/pRP4BAjEk5PULcj FKTBhdrkdFVzO+ex6lLjUaF1zEy1GEcaxsngyp5vxMwuiDESmjeljqNrJFzHWUYMgUTb4W 3dkaS0ulKHfl/a4XutLbossb+JOY21pSd7mhnIzjcnZlCxBfIpLtyxBB/e//qQh4ieVy8p cO10tQC7qgGciuWNQpkNOQT/Dtc/ZUisTiNjK3jMx9sjoAhaSIGAmph1h3289Ov53oUEcO IKMRpaEAipVBxDrRSJLa8Fm2coVTiSVzf+GGAzcJQ5TV59Ay4dODRQmJZ1qT9Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPs3Qb8z16Bx; Mon, 15 Sep 2025 19:11:13 +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 58FJBDmF049852; Mon, 15 Sep 2025 19:11:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBD6w049849; Mon, 15 Sep 2025 19:11:13 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:13 GMT Message-Id: <202509151911.58FJBD6w049849@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 88198564dbd8 - stable/15 - LinuxKPI: timer KPI *_timer -> timer_* 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 88198564dbd82a97d655e73459c03eccf7031331 Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=88198564dbd82a97d655e73459c03eccf7031331 commit 88198564dbd82a97d655e73459c03eccf7031331 Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:24:26 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:51:48 +0000 LinuxKPI: timer KPI *_timer -> timer_* del_timer() got renamed to timer_delete() approximately in Linux 6.2 (similar for *_sync and likely others). Keep the old functions as compat; unclear when we can gc them. We should also re-define them with a linuxkpi_ prefix to avoid possible conflicts in the future if we do a full pass over this at some point. Sponsored by: The FreeBSD Foundation (intiially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52074 (cherry picked from commit 5cb64a1d3fe75526fb879ef4dce5860bbb4e4aea) --- sys/compat/linuxkpi/common/include/linux/timer.h | 16 ++++++++++++++-- sys/compat/linuxkpi/common/src/linux_compat.c | 11 ++--------- 2 files changed, 16 insertions(+), 11 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/timer.h b/sys/compat/linuxkpi/common/include/linux/timer.h index bd06e3158fa3..d48939e28a02 100644 --- a/sys/compat/linuxkpi/common/include/linux/timer.h +++ b/sys/compat/linuxkpi/common/include/linux/timer.h @@ -84,11 +84,23 @@ extern unsigned long linux_timer_hz_mask; extern int mod_timer(struct timer_list *, unsigned long); extern void add_timer(struct timer_list *); extern void add_timer_on(struct timer_list *, int cpu); -extern int del_timer(struct timer_list *); -extern int del_timer_sync(struct timer_list *); + +extern int timer_delete(struct timer_list *); extern int timer_delete_sync(struct timer_list *); extern int timer_shutdown_sync(struct timer_list *); +static inline int +del_timer(struct timer_list *tl) +{ + return (timer_delete(tl)); +} + +static inline int +del_timer_sync(struct timer_list *tl) +{ + return (timer_delete_sync(tl)); +} + #define timer_pending(timer) callout_pending(&(timer)->callout) #define round_jiffies(j) \ ((unsigned long)(((j) + linux_timer_hz_mask) & ~linux_timer_hz_mask)) diff --git a/sys/compat/linuxkpi/common/src/linux_compat.c b/sys/compat/linuxkpi/common/src/linux_compat.c index dcdec0dfcc78..458744a9fec6 100644 --- a/sys/compat/linuxkpi/common/src/linux_compat.c +++ b/sys/compat/linuxkpi/common/src/linux_compat.c @@ -2120,7 +2120,7 @@ add_timer_on(struct timer_list *timer, int cpu) } int -del_timer(struct timer_list *timer) +timer_delete(struct timer_list *timer) { if (callout_stop(&(timer)->callout) == -1) @@ -2129,7 +2129,7 @@ del_timer(struct timer_list *timer) } int -del_timer_sync(struct timer_list *timer) +timer_delete_sync(struct timer_list *timer) { if (callout_drain(&(timer)->callout) == -1) @@ -2137,13 +2137,6 @@ del_timer_sync(struct timer_list *timer) return (1); } -int -timer_delete_sync(struct timer_list *timer) -{ - - return (del_timer_sync(timer)); -} - int timer_shutdown_sync(struct timer_list *timer) { From nobody Mon Sep 15 19:11:14 2025 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 4cQZPv4MqYz67snw; Mon, 15 Sep 2025 19:11:15 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPt50wNz4FXC; Mon, 15 Sep 2025 19:11:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963474; 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=+wEUYJn+AYT61BINbX2MbkEoDLUgdRbrwnWrIhXYli0=; b=pjPgOsgRjehfChWt2+39XDU7mS873q+q/wummQUxED2F03UN/30hzs7s579SdQLaWxA8cT yjHpcKaIPQEUf3sAi1FeC3tm0+2yIMUA6fIHwtXVahu4YCdq7/uxspnmuKQFAjyVOcrNSl QUH11Rg23FuQwkYDCrQraEgHZneIJnuhXX5FIb7uto7X8pIaZIfESzGiI1CsEl3RwL3wZ4 RbblpYWUsPXK1hSsmQM5AL6gNJwsZubt3LAGROEG45fAcltFrfEF8/l5h1SGq+BF+rALKP NbI7iGzVSfn9wiYWXXI/yvtzCTU+sSvtJ0cL4FTSf5Afkvgrt8CavK1cDFr8iw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963474; 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=+wEUYJn+AYT61BINbX2MbkEoDLUgdRbrwnWrIhXYli0=; b=Gp4DlkWe/KzTfM6hjStch98Zi7k1uu4ZSseden/N2prbMnx7NK29rL5a1E+Um1qjQTB2Z/ 5HYGhJ6UpxPIYEfn0hKc/HkWPPW9BLfIQQ78+ax3SuqCBcY5/Hx8d5nMFQ/AXV0nSELwSd ExVI+qsnmCKCFUTxZl5qMCrUUPLVUuIe8hKtBZV4L7BWZSuw+DQt0lpmlcNudFsPLOdyHQ q+o25tOHXoOeSAwLBEOMytiR+EsCwxXAvlVlXhdQunO9hM1GTLhPITOesFTsNIue3aKlZJ wfZ5yxF/LcT3hbHkApdZQhrJ9CZA0hqjbo3gTzUbkuQCY/dSh051zKnADTDIig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963474; a=rsa-sha256; cv=none; b=k9sdgmIkQGqqjg1nE7h+22NZ7aA9DXSrhBxMJm3Fu3ISXDy7MxoY1fbE7o/jCCn0GRir1n X1tH9QgB1SNibfe9mzBBE1UFYOyTkAzWwlw/XAxcZD2CJq2BGRjw+FYq86hPqRgf7l9lmx 7HIcQT3j5e1M3dzArinfo0P8XnIWBoJZ+rcuknffLY2vSqN5r465tth8Or4VnCnikmuV2/ kB7Oxo9EwLeWw0umLe6SWN0Q7rYLcZptM0hXSrDLV/l8S7t+IRReKf8zkktgAtQwgIcAuR Aa5USTO8akWLPU/pQ0cXByCi4BMA1n4qTslxrRqTf6qp5qUAj+Srh8Q0uOX41A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPt4XC0z16By; Mon, 15 Sep 2025 19:11:14 +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 58FJBEJV049887; Mon, 15 Sep 2025 19:11:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBE2m049884; Mon, 15 Sep 2025 19:11:14 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:14 GMT Message-Id: <202509151911.58FJBE2m049884@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 830cc677d97e - stable/15 - LinuxKPI: cleanup: implement __free() and DEFINE_FREE(); use for kfree() 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 830cc677d97eebd02ade8b33ec17de38f2705a73 Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=830cc677d97eebd02ade8b33ec17de38f2705a73 commit 830cc677d97eebd02ade8b33ec17de38f2705a73 Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:24:55 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:52:25 +0000 LinuxKPI: cleanup: implement __free() and DEFINE_FREE(); use for kfree() A wifi driver update needs this. Sponsored by: The FreeBSD Foundation (initially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52075 (cherry picked from commit 39e9290d890b2aa07b68f2fe956b96e5df9a1da2) --- sys/compat/linuxkpi/common/include/linux/cleanup.h | 14 +++++++++++++- sys/compat/linuxkpi/common/include/linux/slab.h | 4 ++++ 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/include/linux/cleanup.h b/sys/compat/linuxkpi/common/include/linux/cleanup.h index 01f234f0cbe7..45c2a2359ddf 100644 --- a/sys/compat/linuxkpi/common/include/linux/cleanup.h +++ b/sys/compat/linuxkpi/common/include/linux/cleanup.h @@ -1,7 +1,7 @@ /*- * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2024 The FreeBSD Foundation + * Copyright (c) 2024-2025 The FreeBSD Foundation * * This software was developed by Björn Zeeb under sponsorship from * the FreeBSD Foundation. @@ -43,4 +43,16 @@ guard_ ## _n ## _t guard_ ## _n ## _ ## __COUNTER__ \ __cleanup(guard_ ## _n ## _destroy) = guard_ ## _n ## _create +#define DEFINE_FREE(_n, _t, _f) \ + static inline void \ + __free_ ## _n(void *p) \ + { \ + _t _T; \ + \ + _T = *(_t *)p; \ + _f; \ + } + +#define __free(_n) __cleanup(__free_##_n) + #endif /* _LINUXKPI_LINUX_CLEANUP_H */ diff --git a/sys/compat/linuxkpi/common/include/linux/slab.h b/sys/compat/linuxkpi/common/include/linux/slab.h index 47e3d133eb6c..0e649e1e3c4a 100644 --- a/sys/compat/linuxkpi/common/include/linux/slab.h +++ b/sys/compat/linuxkpi/common/include/linux/slab.h @@ -40,8 +40,10 @@ #include #include #include +#include #include #include +#include MALLOC_DECLARE(M_KMALLOC); @@ -153,6 +155,8 @@ kfree(const void *ptr) lkpi_kfree(ptr); } +DEFINE_FREE(kfree, void *, if (!IS_ERR_OR_NULL(_T)) kfree(_T)) + /* * Other k*alloc() funtions using the above as underlying allocator. */ From nobody Mon Sep 15 19:11:15 2025 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 4cQZPw1qdxz67srb; Mon, 15 Sep 2025 19:11:16 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPv6CkQz4FcN; Mon, 15 Sep 2025 19:11:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963476; 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=ymXwOI3IAC84SWhsyd0PH46YuHyYKT5sF2r3sb7Pu+o=; b=nmAht87scB1pa2xOZ4X79NTYGScASpkALYLf+1K05Pv25of9K1zp0Lj1eop/8bR1yiodXU ZZVrzfCTBQQzri7Ni7jmaHraTbWltIc7mQo8OEwVQxSzeEeyEXbTke9P1jfIEckVmGoH34 YeM6qTHslYyMldY7P3ZIj1C2Z7W0+9YSV1Lqw+u2OHMKnpaIh+dCdEGw4Xvm7B7RWIYbVZ qfYidHiYGbSb6Fdl9dAo3Ijof7pcUQ67IC/uNKaMwjcEWr+eEGUZ+N8GyDVUbh+1zY7beM GUfo1gYZTDC0ThRXf1xPDCFnfwxWYEVzSWycoko5HBku2+OAvOTnbWRsWsLcsA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963476; 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=ymXwOI3IAC84SWhsyd0PH46YuHyYKT5sF2r3sb7Pu+o=; b=gF1bKwQbYtmL1kOul7WHKZhfWErFoN2xA4offuk//gHVaf0xgVnsFJiVy3N+iCg6F0wG5q tTlkDi7BMZdjFP8qYh4uo1716yuDj3DBqApxl88ARFInKtamk+BD2LKQHvqWVx2zX7NyMY Emx3bZ7CNh+JD/wPvBrJbSLvNC7AcADwPxiN/g0oOxAIN+kfAOU6IBAJ/seJJzin0jBBU0 uBgrnc2uU81FDDxOYf4gaQr/I02Zj59ALuUZvQPv/pc32FSBceqTDuAxfbZn5DHkDoPLBE XtF+cb11Gjll1NkM/JR4cuUgUnug9omXsTkM2d/Os9U3mA35q3A/0u/u+gc58g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963476; a=rsa-sha256; cv=none; b=mlp963fvPFuyomhB4Yqfc1Utht0lZm1ZhCBxWLPlvQh4aJmBakA8tc+m1I955tChb7seDh Fuuc90OoMNgxuEcu2doqp1uo5UhewJ8mt3jbhqJcg6hGJHbEuzyYnt0Lva7dLecw3kB4uL wMp5RLrF7jfH+lddoN52V6OoboEGHcZLHgSWD/lL4/mIEQE8mwxGoG0WX+fqTT+936JFPl cyh8uQI5jfM9DdBw8eUFWKtrDQ70lYv4Nn9COV4dYn4h2mcC27e9Cp0azM8Hjs5TgY34RT OVjxO+3ZsFRTGdCdMvlDzrFtI+jsP5AUzI2bfZlMACpVW1YgJ/+2qVMIXmJccw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPv5nX0z16s9; Mon, 15 Sep 2025 19:11:15 +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 58FJBFRi049922; Mon, 15 Sep 2025 19:11:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBF9x049919; Mon, 15 Sep 2025 19:11:15 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:15 GMT Message-Id: <202509151911.58FJBF9x049919@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 4d5a78c5f40a - stable/15 - LinuxKPI: add DEFINE_LOCK_GUARD_0 for rcu 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 4d5a78c5f40aa2dfd672ccfa4a6fff93e216c32b Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=4d5a78c5f40aa2dfd672ccfa4a6fff93e216c32b commit 4d5a78c5f40aa2dfd672ccfa4a6fff93e216c32b Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:25:30 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:52:31 +0000 LinuxKPI: add DEFINE_LOCK_GUARD_0 for rcu This adds guard support for non-real-types like rcu locking meaning that we need to keep the lock state separately ourselves. _T is still special and needs to be updated. Given it may not be used it needs an __unused attribute (we are using the LinuxKPI __maybe_unused which indeed is more expressive in this case). Sponsored by: The FreeBSD Foundation (initially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52076 (cherry picked from commit 3f48a0fe53ca7e001852f4a406c1bdfab1cd2f6d) --- sys/compat/linuxkpi/common/include/linux/cleanup.h | 35 ++++++++++++++++++++++ .../linuxkpi/common/include/linux/rcupdate.h | 5 +++- 2 files changed, 39 insertions(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/include/linux/cleanup.h b/sys/compat/linuxkpi/common/include/linux/cleanup.h index 45c2a2359ddf..5bb146f082ed 100644 --- a/sys/compat/linuxkpi/common/include/linux/cleanup.h +++ b/sys/compat/linuxkpi/common/include/linux/cleanup.h @@ -55,4 +55,39 @@ #define __free(_n) __cleanup(__free_##_n) +/* + * Given this is a _0 version it should likely be broken up into parts. + * But we have no idead what a _1, _2, ... version would do different + * until we see a call. + * This is used for a not-real-type (rcu). We use a bool to "simulate" + * the lock held. Also _T still special, may not always be used, so tag + * with __unused (or better the LinuxKPI __maybe_unused). + */ +#define DEFINE_LOCK_GUARD_0(_n, _lock, _unlock, ...) \ + \ + typedef struct { \ + bool lock; \ + __VA_ARGS__; \ + } guard_ ## _n ## _t; \ + \ + static inline void \ + guard_ ## _n ## _destroy(guard_ ## _n ## _t *_T) \ + { \ + if (_T->lock) { \ + _unlock; \ + } \ + } \ + \ + static inline guard_ ## _n ## _t \ + guard_ ## _n ## _create(void) \ + { \ + guard_ ## _n ## _t _tmp; \ + guard_ ## _n ## _t *_T __maybe_unused; \ + \ + _tmp.lock = true; \ + _T = &_tmp; \ + _lock; \ + return (_tmp); \ + } + #endif /* _LINUXKPI_LINUX_CLEANUP_H */ diff --git a/sys/compat/linuxkpi/common/include/linux/rcupdate.h b/sys/compat/linuxkpi/common/include/linux/rcupdate.h index 85d766c8dbc9..4aceb7296cd6 100644 --- a/sys/compat/linuxkpi/common/include/linux/rcupdate.h +++ b/sys/compat/linuxkpi/common/include/linux/rcupdate.h @@ -1,7 +1,7 @@ /*- * Copyright (c) 2016-2017 Mellanox Technologies, Ltd. * All rights reserved. - * Copyright (c) 2024 The FreeBSD Foundation + * Copyright (c) 2024-2025 The FreeBSD Foundation * * Portions of this software were developed by Björn Zeeb * under sponsorship from the FreeBSD Foundation. @@ -35,6 +35,7 @@ #include #include #include +#include #include @@ -162,4 +163,6 @@ void linux_synchronize_rcu(unsigned type); #define init_rcu_head_on_stack(...) #define destroy_rcu_head_on_stack(...) +DEFINE_LOCK_GUARD_0(rcu, rcu_read_lock(), rcu_read_unlock()) + #endif /* _LINUXKPI_LINUX_RCUPDATE_H_ */ From nobody Mon Sep 15 19:11:16 2025 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 4cQZPx2J8Pz67sm3; Mon, 15 Sep 2025 19:11:17 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPx0Df3z4Fnw; Mon, 15 Sep 2025 19:11:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963477; 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=7+wsrIQsuDCL9ZeCZPzMvZ+6FVfO5032a1QDl4BYnfc=; b=KDhq+cdR7iwm1gRpsCIvRp56Ff3UgqbiDqjDXDQB9PA0aJHO4gRLOwEwSl7hWVf51LYAuX XtfW7zV1Vnv9/xtQ+ID0fjxZNCxH3se+qGPVRvPFC1pDSiOy6AQOv8a/bile9IL0wji6zx GMbxe53f20D2eiGuAK6dpiCeYyXY9gjaUS5ACNQbh3+07fOCcYkqcLeczwUo8GimnUJkEL VZ7k2XMd9n3BvHBFMsZTRYEzrfxGOfOL2hhZlbHLVjZaXL8KFsQ62FfnLFzFpcOugguVWH kFzOft6YaxUeMikqDHOJSa2DfSCfYs43Y6CtMLfCxqj0E9fMF5Ql7NuljAetiw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963477; 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=7+wsrIQsuDCL9ZeCZPzMvZ+6FVfO5032a1QDl4BYnfc=; b=iLsv8jrLrUv+gE9glBa/iwnlWYt6ky99gRf4iIZBuDLdzZlWG9yM5CMluWo0W0/TBznPhe wAxpRN5tgtlE/vM5lv5LTzK3dY8LPF5D7efUK0p5coONYEK7xqyFFVey3CQbYi1CPOtmHJ OtJUtzgxmX27Sj9pWkVM9LIOaxJ/5wYdvzrbHDdGx7ypqalhBMdzACIcaLbBDxBxfJf4cX ZOkSZdUSZ9xhEIpO5xHuUMEe+/a4STp+UhwSmg8Gtgi4Ekfl/8e82W0XeuCf1fYnsVSSHn Du6Mv9P8YrVvKSIdJ3Oh0HZZm5dgp9Pi7ZsvjB1nGKhqVf0kbAWsiiNl7lMcFg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963477; a=rsa-sha256; cv=none; b=V19WsWf8mwufwvkMS4RXNmJ7je5C/QRY9I7e5FFpVXNyMUQrPD4RTtpD+8WBUFsU8Dr8uB q8xjgS8/dYFkvowwz42nYtrl4gI/RBLDokXDJqQZTA9ZvAZ2nEAxyc5CBeL7ViMhRWKCTp soj5abuE6NF0S+5uJxaK1Mm7/HP4y/bw5EmNtGEk+CFOqbPUWz5D4Ky2ymjiF+K/QpyVOx qgHAVQjyAKMEyBbsm7Z3ahq3bkgAMJY/5UHUBA66QOA5KhcYv7/vn5jiq6SUPk0jBPGm8p 7tEJbKo5emwI0rSn+PqpIQlW7EBnK0JbzKVYMPnwbJwXKc4jmDqX2pYAmdld4g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPw6n4Qz16dy; Mon, 15 Sep 2025 19:11:16 +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 58FJBG35049957; Mon, 15 Sep 2025 19:11:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBGNI049954; Mon, 15 Sep 2025 19:11:16 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:16 GMT Message-Id: <202509151911.58FJBGNI049954@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 310885b40ad2 - stable/15 - LinuxKPI: add __struct_size 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 310885b40ad256b054d65353c375b29700ee024c Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=310885b40ad256b054d65353c375b29700ee024c commit 310885b40ad256b054d65353c375b29700ee024c Author: Bjoern A. Zeeb AuthorDate: 2025-08-18 19:53:55 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:52:36 +0000 LinuxKPI: add __struct_size Use __builtin_object_size() by default. If __builtin_dynamic_object_size() is available use that instead. I would hope that in a future version we can remove the conditional checks but in order to be able to MFC this without checking all compiler versions simply keep it this way for now. Sponsored by: The FreeBSD Foundation (initially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52077 (cherry picked from commit ff5bcb742899f8398ccb1b9e292b2e5aeeb7fedb) --- sys/compat/linuxkpi/common/include/linux/compiler.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/compiler.h b/sys/compat/linuxkpi/common/include/linux/compiler.h index fb5ad3bf4fe4..948396144ad6 100644 --- a/sys/compat/linuxkpi/common/include/linux/compiler.h +++ b/sys/compat/linuxkpi/common/include/linux/compiler.h @@ -130,4 +130,10 @@ #define is_signed_type(t) ((t)-1 < (t)1) #define is_unsigned_type(t) ((t)-1 > (t)1) +#if __has_builtin(__builtin_dynamic_object_size) +#define __struct_size(_s) __builtin_dynamic_object_size(_s, 0) +#else +#define __struct_size(_s) __builtin_object_size(_s, 0) +#endif + #endif /* _LINUXKPI_LINUX_COMPILER_H_ */ From nobody Mon Sep 15 19:11:17 2025 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 4cQZPy47Qbz67ss5; Mon, 15 Sep 2025 19:11:18 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPy0zbYz4FhH; Mon, 15 Sep 2025 19:11:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963478; 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=J6hXeTq3TkNGT2PJiwwujL4mN/Y1XqF8/N9S5wMunOU=; b=jwQZioTHqPb5Rdoji/IQIWaePreykiwEYaQcQdXY7Kp6/toz0CGNybA8NJhBPZnFKFbwxD xrk5ASNjn8XYsOPbrU9hjwizJz4BmcieSjcuvl4BNhiYoyOqnMdcT5FGXR1wZrkjJpjcI4 UPxFgW5XX+NLZWkTMCNJ9cP+oi8sDnMJRxDLNNM3mYU7tS0joDsBx0Po7g63XJ1YrPwEeJ y/ZqSAmeEFLFge7B2x5c/SzQfmbeE4xVw7t3SQM+VcCjIqP84tdLyjnQWGhkIqjvqgEGbm V4Pz2QSgSEbfPdN/juEI6ZkCmbCAlYlOehUBGjf632gnaHoGbqvn+wm9t+SbDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963478; 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=J6hXeTq3TkNGT2PJiwwujL4mN/Y1XqF8/N9S5wMunOU=; b=WhOX9Ef9tiCnhUMcuwD32oOBF8hwSehviCSvldegrJ4EeX0AdxIwxhTwe+aaUixiYHGCUD qZMjQu2Oq3pBj3TY7Yq25L5NIh+fF8s7YjQ7La5cOWF52W/CjR3I2OeSvmFZbK9FoqJMXC UmajU72q4GaqffduT3pwFkuNAF/gI5okMoadRJF4kmJO+25M92E2OJWKEsMva6GM/BCyqQ bF+dO5k7P/jSLQRsHb0AWOU8dW58frlFxQhjB5dI0KWJlOvqhPihT8xe56js1l73H6fC8C rNWRyQSpA3vADsNuVR4bLI+P8xN6oJdOuRbnrhKP5D7O/f9nuuoTexky/ev/rg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963478; a=rsa-sha256; cv=none; b=WJKQenKKE26rwqxkOOjRRLEjdAP40NwifN4Xvjq8SN8GjpnKTNBJBEPJq4IcZJHxmrtOay bqo8TrqLtZ4Psk3tYMeqVmjCkfVGMQZo5g0EcgcClaGWQAkUK9dbSKzLdzuZ5Hhst4b08F iG7IcK5kUWVG4Jvmom4SakZcWF3v/SKu/I2hgGwuQcNMeUlz/3ef9Xrz8Jdq0xrmR60Ssr ughvmMXzAZjlLG3EItRkYxM/FaaZY9dRAU6ErL+wFwR0ZN8kOfXAkx9WTdSaD6WzMv+DL9 wdWu9XFnTdtOoQltESdAUv9WP5e9LnPkzTv9hAKvIdM0W5FMKL//u5gjND2OcQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPx70t9z16sB; Mon, 15 Sep 2025 19:11:17 +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 58FJBHri049992; Mon, 15 Sep 2025 19:11:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBHda049989; Mon, 15 Sep 2025 19:11:17 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:17 GMT Message-Id: <202509151911.58FJBHda049989@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: cd2bd8bf672c - stable/15 - LinuxKPI: sync overflow.h from Linux v6.16 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: cd2bd8bf672cd5925531b6440d57f1c48e025079 Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=cd2bd8bf672cd5925531b6440d57f1c48e025079 commit cd2bd8bf672cd5925531b6440d57f1c48e025079 Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:26:32 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:52:42 +0000 LinuxKPI: sync overflow.h from Linux v6.16 It seems overflow.h wsa imported directly from Linux in 3208d4ad2b8320a. Update the file to the newer version as needed for wireless driver updates. Sponsored by: The FreeBSD Foundation (initially) Obtained from: git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 038d61fd642278 (tag: v6.16) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52078 (cherry picked from commit 70c508e691de1ed0f70b4a6f0773bfb5d627050d) --- .../linuxkpi/common/include/linux/overflow.h | 180 +++++++++++++++++---- 1 file changed, 153 insertions(+), 27 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/overflow.h b/sys/compat/linuxkpi/common/include/linux/overflow.h index 9ba9b9500f11..e811037b8ecc 100644 --- a/sys/compat/linuxkpi/common/include/linux/overflow.h +++ b/sys/compat/linuxkpi/common/include/linux/overflow.h @@ -33,8 +33,10 @@ * credit to Christian Biere. */ #define __type_half_max(type) ((type)1 << (8*sizeof(type) - 1 - is_signed_type(type))) -#define type_max(T) ((T)((__type_half_max(T) - 1) + __type_half_max(T))) -#define type_min(T) ((T)((T)-type_max(T)-(T)1)) +#define __type_max(T) ((T)((__type_half_max(T) - 1) + __type_half_max(T))) +#define type_max(t) __type_max(typeof(t)) +#define __type_min(T) ((T)((T)-type_max(T)-(T)1)) +#define type_min(t) __type_min(typeof(t)) /* * Avoids triggering -Wtype-limits compilation warning, @@ -59,45 +61,122 @@ static inline bool __must_check __must_check_overflow(bool overflow) * @b: second addend * @d: pointer to store sum * - * Returns 0 on success. + * Returns true on wrap-around, false otherwise. * - * *@d holds the results of the attempted addition, but is not considered - * "safe for use" on a non-zero return value, which indicates that the - * sum has overflowed or been truncated. + * *@d holds the results of the attempted addition, regardless of whether + * wrap-around occurred. */ #define check_add_overflow(a, b, d) \ __must_check_overflow(__builtin_add_overflow(a, b, d)) +/** + * wrapping_add() - Intentionally perform a wrapping addition + * @type: type for result of calculation + * @a: first addend + * @b: second addend + * + * Return the potentially wrapped-around addition without + * tripping any wrap-around sanitizers that may be enabled. + */ +#define wrapping_add(type, a, b) \ + ({ \ + type __val; \ + __builtin_add_overflow(a, b, &__val); \ + __val; \ + }) + +/** + * wrapping_assign_add() - Intentionally perform a wrapping increment assignment + * @var: variable to be incremented + * @offset: amount to add + * + * Increments @var by @offset with wrap-around. Returns the resulting + * value of @var. Will not trip any wrap-around sanitizers. + * + * Returns the new value of @var. + */ +#define wrapping_assign_add(var, offset) \ + ({ \ + typeof(var) *__ptr = &(var); \ + *__ptr = wrapping_add(typeof(var), *__ptr, offset); \ + }) + /** * check_sub_overflow() - Calculate subtraction with overflow checking * @a: minuend; value to subtract from * @b: subtrahend; value to subtract from @a * @d: pointer to store difference * - * Returns 0 on success. + * Returns true on wrap-around, false otherwise. * - * *@d holds the results of the attempted subtraction, but is not considered - * "safe for use" on a non-zero return value, which indicates that the - * difference has underflowed or been truncated. + * *@d holds the results of the attempted subtraction, regardless of whether + * wrap-around occurred. */ #define check_sub_overflow(a, b, d) \ __must_check_overflow(__builtin_sub_overflow(a, b, d)) +/** + * wrapping_sub() - Intentionally perform a wrapping subtraction + * @type: type for result of calculation + * @a: minuend; value to subtract from + * @b: subtrahend; value to subtract from @a + * + * Return the potentially wrapped-around subtraction without + * tripping any wrap-around sanitizers that may be enabled. + */ +#define wrapping_sub(type, a, b) \ + ({ \ + type __val; \ + __builtin_sub_overflow(a, b, &__val); \ + __val; \ + }) + +/** + * wrapping_assign_sub() - Intentionally perform a wrapping decrement assign + * @var: variable to be decremented + * @offset: amount to subtract + * + * Decrements @var by @offset with wrap-around. Returns the resulting + * value of @var. Will not trip any wrap-around sanitizers. + * + * Returns the new value of @var. + */ +#define wrapping_assign_sub(var, offset) \ + ({ \ + typeof(var) *__ptr = &(var); \ + *__ptr = wrapping_sub(typeof(var), *__ptr, offset); \ + }) + /** * check_mul_overflow() - Calculate multiplication with overflow checking * @a: first factor * @b: second factor * @d: pointer to store product * - * Returns 0 on success. + * Returns true on wrap-around, false otherwise. * - * *@d holds the results of the attempted multiplication, but is not - * considered "safe for use" on a non-zero return value, which indicates - * that the product has overflowed or been truncated. + * *@d holds the results of the attempted multiplication, regardless of whether + * wrap-around occurred. */ #define check_mul_overflow(a, b, d) \ __must_check_overflow(__builtin_mul_overflow(a, b, d)) +/** + * wrapping_mul() - Intentionally perform a wrapping multiplication + * @type: type for result of calculation + * @a: first factor + * @b: second factor + * + * Return the potentially wrapped-around multiplication without + * tripping any wrap-around sanitizers that may be enabled. + */ +#define wrapping_mul(type, a, b) \ + ({ \ + type __val; \ + __builtin_mul_overflow(a, b, &__val); \ + __val; \ + }) + /** * check_shl_overflow() - Calculate a left-shifted value and check overflow * @a: Value to be shifted @@ -122,7 +201,7 @@ static inline bool __must_check __must_check_overflow(bool overflow) typeof(a) _a = a; \ typeof(s) _s = s; \ typeof(d) _d = d; \ - u64 _a_full = _a; \ + unsigned long long _a_full = _a; \ unsigned int _to_shift = \ is_non_negative(_s) && _s < 8 * sizeof(*d) ? _s : 0; \ *_d = (_a_full << _to_shift); \ @@ -132,10 +211,10 @@ static inline bool __must_check __must_check_overflow(bool overflow) #define __overflows_type_constexpr(x, T) ( \ is_unsigned_type(typeof(x)) ? \ - (x) > type_max(typeof(T)) : \ + (x) > type_max(T) : \ is_unsigned_type(typeof(T)) ? \ - (x) < 0 || (x) > type_max(typeof(T)) : \ - (x) < type_min(typeof(T)) || (x) > type_max(typeof(T))) + (x) < 0 || (x) > type_max(T) : \ + (x) < type_min(T) || (x) > type_max(T)) #define __overflows_type(x, T) ({ \ typeof(T) v = 0; \ @@ -312,27 +391,40 @@ static inline size_t __must_check size_sub(size_t minuend, size_t subtrahend) struct_size((type *)NULL, member, count) /** - * _DEFINE_FLEX() - helper macro for DEFINE_FLEX() family. - * Enables caller macro to pass (different) initializer. + * __DEFINE_FLEX() - helper macro for DEFINE_FLEX() family. + * Enables caller macro to pass arbitrary trailing expressions * * @type: structure type name, including "struct" keyword. * @name: Name for a variable to define. * @member: Name of the array member. * @count: Number of elements in the array; must be compile-time const. - * @initializer: initializer expression (could be empty for no init). + * @trailer: Trailing expressions for attributes and/or initializers. */ -#define _DEFINE_FLEX(type, name, member, count, initializer) \ +#define __DEFINE_FLEX(type, name, member, count, trailer...) \ _Static_assert(__builtin_constant_p(count), \ "onstack flex array members require compile-time const count"); \ union { \ u8 bytes[struct_size_t(type, member, count)]; \ type obj; \ - } name##_u initializer; \ + } name##_u trailer; \ type *name = (type *)&name##_u /** - * DEFINE_FLEX() - Define an on-stack instance of structure with a trailing - * flexible array member. + * _DEFINE_FLEX() - helper macro for DEFINE_FLEX() family. + * Enables caller macro to pass (different) initializer. + * + * @type: structure type name, including "struct" keyword. + * @name: Name for a variable to define. + * @member: Name of the array member. + * @count: Number of elements in the array; must be compile-time const. + * @initializer: Initializer expression (e.g., pass `= { }` at minimum). + */ +#define _DEFINE_FLEX(type, name, member, count, initializer...) \ + __DEFINE_FLEX(type, name, member, count, = { .obj initializer }) + +/** + * DEFINE_RAW_FLEX() - Define an on-stack instance of structure with a trailing + * flexible array member, when it does not have a __counted_by annotation. * * @type: structure type name, including "struct" keyword. * @name: Name for a variable to define. @@ -342,8 +434,42 @@ static inline size_t __must_check size_sub(size_t minuend, size_t subtrahend) * Define a zeroed, on-stack, instance of @type structure with a trailing * flexible array member. * Use __struct_size(@name) to get compile-time size of it afterwards. + * Use __member_size(@name->member) to get compile-time size of @name members. + * Use STACK_FLEX_ARRAY_SIZE(@name, @member) to get compile-time number of + * elements in array @member. + */ +#define DEFINE_RAW_FLEX(type, name, member, count) \ + __DEFINE_FLEX(type, name, member, count, = { }) + +/** + * DEFINE_FLEX() - Define an on-stack instance of structure with a trailing + * flexible array member. + * + * @TYPE: structure type name, including "struct" keyword. + * @NAME: Name for a variable to define. + * @MEMBER: Name of the array member. + * @COUNTER: Name of the __counted_by member. + * @COUNT: Number of elements in the array; must be compile-time const. + * + * Define a zeroed, on-stack, instance of @TYPE structure with a trailing + * flexible array member. + * Use __struct_size(@NAME) to get compile-time size of it afterwards. + * Use __member_size(@NAME->member) to get compile-time size of @NAME members. + * Use STACK_FLEX_ARRAY_SIZE(@name, @member) to get compile-time number of + * elements in array @member. + */ +#define DEFINE_FLEX(TYPE, NAME, MEMBER, COUNTER, COUNT) \ + _DEFINE_FLEX(TYPE, NAME, MEMBER, COUNT, = { .COUNTER = COUNT, }) + +/** + * STACK_FLEX_ARRAY_SIZE() - helper macro for DEFINE_FLEX() family. + * Returns the number of elements in @array. + * + * @name: Name for a variable defined in DEFINE_RAW_FLEX()/DEFINE_FLEX(). + * @array: Name of the array member. */ -#define DEFINE_FLEX(type, name, member, count) \ - _DEFINE_FLEX(type, name, member, count, = {}) +#define STACK_FLEX_ARRAY_SIZE(name, array) \ + (__member_size((name)->array) / sizeof(*(name)->array) + \ + __must_be_array((name)->array)) #endif /* _LINUXKPI_LINUX_OVERFLOW_H */ From nobody Mon Sep 15 19:11:20 2025 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 4cQZQ05wgnz67sq2; Mon, 15 Sep 2025 19:11:20 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZQ02Ytfz4Frg; Mon, 15 Sep 2025 19:11:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963480; 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=mBAHnhuIJ/iFpf8D0h+lI+yw/MzG+pXe/GhB96ZQKnw=; b=CnBv5XM+1ADFQxr7XBiMS4xAI60zXxhusHDzY5vL6VFLKVdsW4saLSeQxqNKpn+KtMRdUE EVS04Wektzir71sBGI135lb6csYpO1tPnVfYt64uR6a4pnVDkbltpWnbnJKOENdin8luiB 1yaHMFp8cqUbIZhA5H9n04qNyCeoK4ZIGi4FjSAnLjuYNjIKOYF6g4e4BhurawnoTZgKgp vQ/GU31b3q9dEaTwU88jsFxsZjLexAqdFlwxXntq6I8vG4KMZq8uGA6bpxtQEoiTWL4u3H DC8pqHQKMkfLaW8aer0svuYDJZY29MzBMMJprvDTQzFrqC1vUUIrpFFWIh1MIw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963480; 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=mBAHnhuIJ/iFpf8D0h+lI+yw/MzG+pXe/GhB96ZQKnw=; b=cQGo66kPZWv2HCogNZTSg3S8UvM7sTCo9+OLUO+z1i40B3iMJ3Ro3oKsl6TTwu83Zg4Jq9 WdttRycGamP8fp7t78bzib/+uza20ZiUVflnxOKIGaENeDkqjCSEUxIPHP0S2HaP+rkuxv DTkTS+8sIVOUcgpAjxDS93qYkq4yZartPVUCeeneJK2PbdoZDhrQDoWzpVqTh9L4XBMFbn krhJhY17vrVoaSXljCbDur/pyTlt/E7jDzTGGFWIeV/GEeN8/zYLLiqPywr8CwHaPjmHZL 5PBllDwaw9Aq8higKUweLmwIiqnaaich9311bV5ZOEIkcjsSve8huuo6aDnrDw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963480; a=rsa-sha256; cv=none; b=hidaPe8wUdqWZISZubd2pt6+4Nl5/Mx8xsF4YzKGsYyGRIyH42dY9G/FY45AW/H11Nh+EC J6eayb7Ny6klIeGyXwEeOATK5vqainb7WTe14CQ5VEsVH7UEYY26+NCZXDJZtlqsOlpYiq qoeTEaE8CJ4TIYL7J3v2HBdHr5J63vnQ2Eoa2JjAkG/3valkTJl7kDZNXJuIREJ+4VY+GM hxtHReJOvgcKvuoBYjwob2QPHDAxnHl3b8SmKipSAhrd5ApYMiuOh3aSBjdDrmhjJ0dCSW NayoAE8w70Ct9HtfGTGGaBCkOU6OsHiYeQesPmWCeSU97MtAcjQUfHmnB1l4sA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZQ01KlMz16sD; Mon, 15 Sep 2025 19:11:20 +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 58FJBK4r051122; Mon, 15 Sep 2025 19:11:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBK28051119; Mon, 15 Sep 2025 19:11:20 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:20 GMT Message-Id: <202509151911.58FJBK28051119@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 88122c8eb70d - stable/15 - LinuxKPI: maths64: implement roundup_u64() 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 88122c8eb70d81decb7c6dd16e551c3df6ad3818 Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=88122c8eb70d81decb7c6dd16e551c3df6ad3818 commit 88122c8eb70d81decb7c6dd16e551c3df6ad3818 Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:27:48 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:52:54 +0000 LinuxKPI: maths64: implement roundup_u64() Needed by a wifi driver update. Sponsored by: The FreeBSD Foundation (initially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52080 (cherry picked from commit 2a44e10edb13e6b2be7fa2814b418a6959cb1171) --- sys/compat/linuxkpi/common/include/linux/math64.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/math64.h b/sys/compat/linuxkpi/common/include/linux/math64.h index a216d350570f..25ca9da1b622 100644 --- a/sys/compat/linuxkpi/common/include/linux/math64.h +++ b/sys/compat/linuxkpi/common/include/linux/math64.h @@ -98,6 +98,12 @@ div64_u64_round_up(uint64_t dividend, uint64_t divisor) return ((dividend + divisor - 1) / divisor); } +static inline uint64_t +roundup_u64(uint64_t x1, uint32_t x2) +{ + return (div_u64(x1 + x2 - 1, x2) * x2); +} + #define DIV64_U64_ROUND_UP(...) \ div64_u64_round_up(__VA_ARGS__) From nobody Mon Sep 15 19:11:18 2025 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 4cQZPz5D60z67sxV; Mon, 15 Sep 2025 19:11:19 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZPz15Zlz4FrT; Mon, 15 Sep 2025 19:11:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963479; 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=Vo7twbnppyUdkHTfnqulNUX55uF1aqJ2eKhiCXwjH00=; b=O02xyrrTVAAyEstRs0J2I3VOGjX9XuCAlOK1HusZXUGgJFs+NpqDoLy9n9qA6F038votkZ /8I0qBoHq9jiIrWeFOnVOfU6FeZGh+s8YACVfjWtwwK32fY0Fz/1AEqKmcI0cwmEo4nSsv zH7ie9Rwa7jlgNPaDj3Yc5ckJZ+yE2qrS14ewQLPIdabYsF9ciTHCfrAYgqXvusYPVsr1o hazFAiOOa8Gs1ulPpWGEDbMEFXMhedwUYqhCoKNq9MwvS9qengnKdd10+WmHFnVckmeQuS R9oHKMIUdmNafNeKUo08XzEsgYPKNVlP66cNQr+RNCRQ3jyWp4IJqWlIPZTqJg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963479; 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=Vo7twbnppyUdkHTfnqulNUX55uF1aqJ2eKhiCXwjH00=; b=sr+1XK4PCZT9Bxd3ck1ts7pU2bZGm0nixhoKiu3ucYJWPqCbYZ9y7OZKltbI9GOCs4nfJ5 LS/OFPJNHmZceh6n1J49HFpWOrUSSU7x6ecFS7n/CfJC/Z6Fkp/xEzvq3zqJexfAVtoYO2 bqh6DGgEbUrRJLgttSa1Q3YJGe493mCGa6miLy96tkqNVz9ogZFtfmD1sPsappF1PnHAAn bsgVZFx10OeongRHJhytP1Nr6UAfVhBWQbo6GRZYXVyU9Ge+F7NYKipn0gBwo+tNoiZeu2 sSjWcd2LcXsfH01lHU3X9+I7b4BgOwHDTTwg8I4+gUx/ZO9/kBb0x0xCouxHhA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963479; a=rsa-sha256; cv=none; b=latV6CujeDWGXaKpmiHuzFmjGGrtJVU7ex7Fol2Gxb6RKSXTlbr39nGrTXp6MVZ1uLKb1d DiVOhcYGuaVrhZ/qlGp74ghubh+wN0rRW4XseVn9iEHhuH5IZ7T6b2oJS7oMVmhPyqcgRF PBkI4C/mz9lUBQAaiQTrT3K71IWMgxKUxU3i49kts0cfXtxneMVSxrz3TwSZm8S+0/kvV/ ehnwHtwKbDgrbdTMYHgqMF9ICPc1NVhJJ3aDpqDcynLWpncy5Vd/nk328ZrwoAyMQIOwmo WNmkzt9HiVZjQdQq6UuNUhwe72CHAZ+l+I8YSzQOx6HKdhh4eGUzyxhmAVZ3DA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZPz0QDDz16C0; Mon, 15 Sep 2025 19:11:19 +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 58FJBIbS050778; Mon, 15 Sep 2025 19:11:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBIF6050756; Mon, 15 Sep 2025 19:11:18 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:18 GMT Message-Id: <202509151911.58FJBIF6050756@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 3753913c9e1c - stable/15 - LinuxKPI: kunit: add static_stub.h and more dummy headers 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 3753913c9e1c3375be29b8f4ab925b054fe1ac4b Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=3753913c9e1c3375be29b8f4ab925b054fe1ac4b commit 3753913c9e1c3375be29b8f4ab925b054fe1ac4b Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:27:16 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:52:49 +0000 LinuxKPI: kunit: add static_stub.h and more dummy headers These came up during a wifi driver update. Sponsored by: The FreeBSD Foundation (initially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52079 (cherry picked from commit 7c473933624f701263a83da526cac680b1ca69ed) --- sys/compat/linuxkpi/common/include/kunit/static_stub.h | 15 +++++++++++++++ sys/compat/linuxkpi/dummy/include/kunit/skbuff.h | 0 sys/compat/linuxkpi/dummy/include/kunit/test-bug.h | 0 sys/compat/linuxkpi/dummy/include/kunit/test.h | 0 4 files changed, 15 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/kunit/static_stub.h b/sys/compat/linuxkpi/common/include/kunit/static_stub.h new file mode 100644 index 000000000000..9d425d46dbb0 --- /dev/null +++ b/sys/compat/linuxkpi/common/include/kunit/static_stub.h @@ -0,0 +1,15 @@ +/* + * Copyright (c) 2025 The FreeBSD Foundation + * + * This software was developed by Björn Zeeb under sponsorship from + * the FreeBSD Foundation. + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +#ifndef _LINUXKPI_KUNIT_STATIC_STUB_H +#define _LINUXKPI_KUNIT_STATIC_STUB_H + +#define KUNIT_STATIC_STUB_REDIRECT(_fn, ...) do { } while(0) + +#endif /* _LINUXKPI_KUNIT_STATIC_STUB_H */ diff --git a/sys/compat/linuxkpi/dummy/include/kunit/skbuff.h b/sys/compat/linuxkpi/dummy/include/kunit/skbuff.h new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/sys/compat/linuxkpi/dummy/include/kunit/test-bug.h b/sys/compat/linuxkpi/dummy/include/kunit/test-bug.h new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/sys/compat/linuxkpi/dummy/include/kunit/test.h b/sys/compat/linuxkpi/dummy/include/kunit/test.h new file mode 100644 index 000000000000..e69de29bb2d1 From nobody Mon Sep 15 19:11:21 2025 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 4cQZQ14hskz67sqB; Mon, 15 Sep 2025 19:11:21 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZQ12rJJz4FbG; Mon, 15 Sep 2025 19:11:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963481; 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=lkEXNkEHS1H3I8jWOmq6kF765VaAihA9HImV1/S4mlc=; b=AM06WdTnZjWkG82bnVHkG2x36ew+kns1AjuRnn3Fl4F4thUtbAVzv0LSxlIVJaLa66p1/+ ofeg/SYZPqmNz4s9whIhj41OV4hrOLduApX2A1EFN1VHabKBBx4UQL8tTjlw2w+Mf40XgM gRTY4U4i2rX0ONzqJIhMMEzem9fZ5eQtZlYYiemvi97V9ByAY8wE9iLw2R/KQuRuRKChwU KxhteNh6f+rtx7ZFkTtWGmgXLeDTFGbrJDiXtY/qpaUIY7CXutl+ZNObL356A+Z1XdRyTY lnZDaqCR9pl8YFdFQIN8x9+OXCzASCF3spUjjG781Va8jqEPlzQND/VMK5h5zA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963481; 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=lkEXNkEHS1H3I8jWOmq6kF765VaAihA9HImV1/S4mlc=; b=kuecUgPlDDHU585uTmJgoafypug9C8wJbjsImJHsYdFiMq40lcCzntQHqloDYtmS/dQzBt j0/i6gNxMMUcazXYek47KKUyui7WvsLuWfPlMxVj0SV4Tn8Sdts3yMjmvPQNs1sC/aqqBI Tfbp30cm7Mr0EmxYd1w73kUSC6yEW28sUutL1dP2iKLSXOe66j35elLKUuLQZL+uTNBF4o og+nIBHkXuGnt2isY+xWFaPKvsp2ntThPHuHKj4vdIMUb2OvfRngQelXqEJ6U/JEr/OUhu 50oYfXU5rm5RPCPGQOPG9U70XFNGvrbdB9GQAv5XniY2S5GBakZETfY3iECA/A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963481; a=rsa-sha256; cv=none; b=IFvmnmOFRzA/5l1254594+Iu6GxM6LZ64320E8jUyfyqK7RcwE8QVQMPbKo+xgRLwNY74Y +/hKsx3wPBcfJkfDcipx6SMwvehj0r27ian6iqakoZbEIfVkfj6uvjb0u1ASJuAHRlwTO5 QanKaYyduMPjpgL03N8QAsnkaJqh2Gx6PH2sVhqNELeGpM2KMVRjHMxlowZaWUl5QSwQql H5zs4/ZRIAlPVS6P+4drHOopfcXq6DjAyR8dKmVmJhiSfKk3zbu+Mnmc7h/MKPds7x1W+/ /krBoZWXGL5RrZQTiNeuBl9EFFKy54hFORrXGhFyy8CH/tcf+2YYLQE8eSZZ4g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZQ12GbHz16gc; Mon, 15 Sep 2025 19:11:21 +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 58FJBLh1051158; Mon, 15 Sep 2025 19:11:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBLsA051155; Mon, 15 Sep 2025 19:11:21 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:21 GMT Message-Id: <202509151911.58FJBLsA051155@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: f20a09e161f0 - stable/15 - LinuxKPI: devres: divorce dem_kfree from lkpi_devm_kmalloc_release 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: f20a09e161f07874c3a01b1579e8a5d2356df8ce Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=f20a09e161f07874c3a01b1579e8a5d2356df8ce commit f20a09e161f07874c3a01b1579e8a5d2356df8ce Author: Bjoern A. Zeeb AuthorDate: 2025-09-04 20:28:18 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:53:01 +0000 LinuxKPI: devres: divorce dem_kfree from lkpi_devm_kmalloc_release dem_kfree() is called from all over the place and should actually do something; contrary to lkpi_devm_kmalloc_release() it can also take a const void *. We have to __DECONST() that though as the entire devres framework does otherwise not take a const argument. This was discovered during the rtw89 upadte to 6.16. Sponsored by: The FreeBSD Foundation (initially) Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D52082 (cherry picked from commit 4ab64e34911ab06e567caaf07ed18f7770a61cc8) --- sys/compat/linuxkpi/common/include/linux/device.h | 5 +++-- sys/compat/linuxkpi/common/src/linux_devres.c | 26 ++++++++++++++++++++++- 2 files changed, 28 insertions(+), 3 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/device.h b/sys/compat/linuxkpi/common/include/linux/device.h index 2556b0c45e49..7dd6340746d2 100644 --- a/sys/compat/linuxkpi/common/include/linux/device.h +++ b/sys/compat/linuxkpi/common/include/linux/device.h @@ -4,7 +4,7 @@ * Copyright (c) 2010 Panasas, Inc. * Copyright (c) 2013-2016 Mellanox Technologies, Ltd. * All rights reserved. - * Copyright (c) 2021-2022 The FreeBSD Foundation + * Copyright (c) 2021-2025 The FreeBSD Foundation * * Portions of this software were developed by Björn Zeeb * under sponsorship from the FreeBSD Foundation. @@ -284,7 +284,8 @@ int lkpi_devres_destroy(struct device *, void(*release)(struct device *, void *) void lkpi_devres_release_free_list(struct device *); void lkpi_devres_unlink(struct device *, void *); void lkpi_devm_kmalloc_release(struct device *, void *); -#define devm_kfree(_d, _p) lkpi_devm_kmalloc_release(_d, _p) +void lkpi_devm_kfree(struct device *, const void *); +#define devm_kfree(_d, _p) lkpi_devm_kfree(_d, _p) static inline const char * dev_driver_string(const struct device *dev) diff --git a/sys/compat/linuxkpi/common/src/linux_devres.c b/sys/compat/linuxkpi/common/src/linux_devres.c index 84f03ba0dd7d..23c91cb5ab2f 100644 --- a/sys/compat/linuxkpi/common/src/linux_devres.c +++ b/sys/compat/linuxkpi/common/src/linux_devres.c @@ -1,7 +1,7 @@ /*- * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2020-2021 The FreeBSD Foundation + * Copyright (c) 2020-2025 The FreeBSD Foundation * * This software was developed by Bj\xc3\xb6rn Zeeb under sponsorship from * the FreeBSD Foundation. @@ -223,6 +223,30 @@ lkpi_devm_kmalloc_release(struct device *dev __unused, void *p __unused) /* Nothing to do. Freed with the devres. */ } +static int +lkpi_devm_kmalloc_match(struct device *dev __unused, void *p, void *mp) +{ + return (p == mp); +} + +void +lkpi_devm_kfree(struct device *dev, const void *p) +{ + void *mp; + int error; + + if (p == NULL) + return; + + /* I assume Linux simply casts the const away... */ + mp = __DECONST(void *, p); + error = lkpi_devres_destroy(dev, lkpi_devm_kmalloc_release, + lkpi_devm_kmalloc_match, mp); + if (error != 0) + dev_warn(dev, "%s: lkpi_devres_destroy failed with %d\n", + __func__, error); +} + struct devres_action { void *data; void (*action)(void *); From nobody Mon Sep 15 19:11:22 2025 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 4cQZQ25Znzz67skb; Mon, 15 Sep 2025 19:11:22 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZQ23jWbz4Fxm; Mon, 15 Sep 2025 19:11:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963482; 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=7AFSANaG7Q/6M9HARXrcPO8HeSZlrDL1Hm6ra0bOKr0=; b=JZmQ/cEmnmmr/8f5TRa7GFpuhB7x9JOSsipdVr/rQvLlscteI2eRP2Da3mG1mDyYB1qJN7 AEooc3UNHhBmPsKkpQXFUdUlP0qj6Z7tFVn4V2pWHDOqQQS9Flwk1u2G7P+Zk3qbq6cwxZ 2roqBT0lvh7CvexmTUpAspw8ad6lhUp3/LcgVqGrihyzYyGNk3KtBqe0ghbjKXE5u7R1eQ zob0AyF5m8Ct9sKHR8H34Okcfwvk3MZk+vVV3kI6MYafNxuA6wN9PyyslHh76F3OaYRRdD AdZVdCspfrrI9Cw4ZdX/FHqyuNycp+nYSia7UeYd+ZKTom1Ngi+sTCpqoumNhw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757963482; 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=7AFSANaG7Q/6M9HARXrcPO8HeSZlrDL1Hm6ra0bOKr0=; b=shzzVlifKeU6h9/YGvoYboWRiTruOGsHBHxI2UyfLrFJBzaU4KfZRn/p6rNO3N6U9ssW9n KrNokFzPYlYlU0XqxQCkBYDmnTub2Pp9asGOQc6aBXJmBnJY6aMRzK4zeVODvgpH3dlOJZ kjpbqQyBIXC1N0SbxWeP3p6WtfFrzDpzHA+pVQnYlW/Ny2g4wXVPaijKxZnx6+6FuCt8ak DtLOoug7HeT5zlZ/R6dRbGUEk2XHIZnDd2oJnmUYKQiWGT9MfMDkuq0vj30zsWcxlMUq6p 5fo6TchncHUokFjZroz76CewyybfAmQMYMQvUwl3ITa1ZC7iMecGbP9m4wU/cw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757963482; a=rsa-sha256; cv=none; b=rAJBfi2hbT51kEx1eRbuyoA7JyPljmainOwvQFVmWz4ae2sFLgpp8CosU+E57J+fxE+bs7 XK1bos07KnhkSw9rjVYNwkAkiNFPWjFTPprKORVY6OEFGWcMr0of4Fi6g45EupllxaFa4W JrAwG/PEbhtEwrxzUwYu2B9vw+YluygVxRnZ88yzP3hpthOZjiV2hBAdvTL7YKLLYpyhdE P+S46jVTK2nWSoj7tJQn3QItjcz0rabeSrlDF/JOTXhi1JP4+F05L22NV9Do1N37G/R+zx mxXpnp6cwG3cHfzZqmX9r/TwldxU3TwOGryxpM3rHtXZ7PzZ2/fKu8xNu1eS7w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZQ23Jvmz16jD; Mon, 15 Sep 2025 19:11:22 +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 58FJBMcV051194; Mon, 15 Sep 2025 19:11:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJBMPL051191; Mon, 15 Sep 2025 19:11:22 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:11:22 GMT Message-Id: <202509151911.58FJBMPL051191@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: b0469fa7f10f - stable/15 - LinuxKPI: 802.11: avoid recursive wiphy lock 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: b0469fa7f10f9fe5510a5445f38d1bf0b832c1e7 Auto-Submitted: auto-generated The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=b0469fa7f10f9fe5510a5445f38d1bf0b832c1e7 commit b0469fa7f10f9fe5510a5445f38d1bf0b832c1e7 Author: Bjoern A. Zeeb AuthorDate: 2025-09-11 14:44:10 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-09-15 14:53:07 +0000 LinuxKPI: 802.11: avoid recursive wiphy lock When freeing the last reference of the net80211 node the net80211 node_free() code may directly call into the crypto code to delete the keys. While we still holding the wiphy lock this would lead to a recursion on the non-recursive wiphy lock. Defer freeing the reference until we are back under the net80211 com lock. Reported by: Mark Phillips (mark freebsdfoundation.org) on 15.0-ALPHA1 (cherry picked from commit 3c38dce87ecd2c87744e4b7ff1904ee841f88a47) --- sys/compat/linuxkpi/common/src/linux_80211.c | 54 ++++++++++++++++++---------- 1 file changed, 36 insertions(+), 18 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index d00734001a59..bc4b334de28e 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2568,12 +2568,6 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int lvif->lvif_bss_synched = false; LKPI_80211_LVIF_UNLOCK(lvif); lkpi_lsta_remove(lsta, lvif); - /* - * The very last release the reference on the ni for the ni/lsta on - * lvif->lvif_bss. Upon return from this both ni and lsta are invalid - * and potentially freed. - */ - ieee80211_free_node(ni); /* conf_tx */ @@ -2582,6 +2576,18 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int out: wiphy_unlock(hw->wiphy); IEEE80211_LOCK(vap->iv_ic); + if (error == 0) { + /* + * We do this outside the wiphy lock as net80211::node_free() may call + * into crypto code to delete keys and we have a recursed on + * non-recursive sx panic. Also only do this if we get here w/o error. + * + * The very last release the reference on the ni for the ni/lsta on + * lvif->lvif_bss. Upon return from this both ni and lsta are invalid + * and potentially freed. + */ + ieee80211_free_node(ni); + } return (error); } @@ -2906,12 +2912,6 @@ _lkpi_sta_assoc_to_down(struct ieee80211vap *vap, enum ieee80211_state nstate, i lvif->lvif_bss_synched = false; LKPI_80211_LVIF_UNLOCK(lvif); lkpi_lsta_remove(lsta, lvif); - /* - * The very last release the reference on the ni for the ni/lsta on - * lvif->lvif_bss. Upon return from this both ni and lsta are invalid - * and potentially freed. - */ - ieee80211_free_node(ni); /* conf_tx */ @@ -2921,6 +2921,18 @@ _lkpi_sta_assoc_to_down(struct ieee80211vap *vap, enum ieee80211_state nstate, i out: wiphy_unlock(hw->wiphy); IEEE80211_LOCK(vap->iv_ic); + if (error == EALREADY) { + /* + * We do this outside the wiphy lock as net80211::node_free() may call + * into crypto code to delete keys and we have a recursed on + * non-recursive sx panic. Also only do this if we get here w/o error. + * + * The very last release the reference on the ni for the ni/lsta on + * lvif->lvif_bss. Upon return from this both ni and lsta are invalid + * and potentially freed. + */ + ieee80211_free_node(ni); + } outni: return (error); } @@ -3522,12 +3534,6 @@ lkpi_sta_run_to_init(struct ieee80211vap *vap, enum ieee80211_state nstate, int lvif->lvif_bss = NULL; lvif->lvif_bss_synched = false; LKPI_80211_LVIF_UNLOCK(lvif); - /* - * The very last release the reference on the ni for the ni/lsta on - * lvif->lvif_bss. Upon return from this both ni and lsta are invalid - * and potentially freed. - */ - ieee80211_free_node(ni); /* conf_tx */ @@ -3537,6 +3543,18 @@ lkpi_sta_run_to_init(struct ieee80211vap *vap, enum ieee80211_state nstate, int out: wiphy_unlock(hw->wiphy); IEEE80211_LOCK(vap->iv_ic); + if (error == EALREADY) { + /* + * We do this outside the wiphy lock as net80211::node_free() may call + * into crypto code to delete keys and we have a recursed on + * non-recursive sx panic. Also only do this if we get here w/o error. + * + * The very last release the reference on the ni for the ni/lsta on + * lvif->lvif_bss. Upon return from this both ni and lsta are invalid + * and potentially freed. + */ + ieee80211_free_node(ni); + } outni: return (error); } From nobody Mon Sep 15 19:21:47 2025 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 4cQZf3539Lz67v0d; Mon, 15 Sep 2025 19:21:47 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZf345BPz4LFK; Mon, 15 Sep 2025 19:21:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757964107; 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=XHEs5mNFC8dA8lfBSw9XW7yWKKK1FRGr2//cvKyjU64=; b=RGGnwIlvLba5c4j3wy1j8K033i03mpX57Zg64oCtaCDwfQiM34vSmKA6ciP5hiz9ZXFxFA pQTHCunA2ztbggQX8mUBRnvnieVdrS8QgBScllJPsYuQ5IQQC4F4Vtco6LO82T2Zn9Evo6 s5GeO13nnBgPa9yJCL/bUJhUgDnNKRMDkkrbYU1gUkF+FwBa2hFG7/BIR30j4Gwd6nxCmJ E1eJQ4ej63hHEEQOWu+BOSQVW5Py6ds5JdosLmpo6MU8RYZ2Kp/RZufSSQssHBc4LjOrwW A/d7erVv5/TWpf+QIHi9N4Zql2FVRQAsQhvevL1n+L3hOHthNtdQjMzmD0xgnA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757964107; 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=XHEs5mNFC8dA8lfBSw9XW7yWKKK1FRGr2//cvKyjU64=; b=A5pDHKCTCXAWh+uJPIxww1k/Rzlr6mf1i2bvIIi9G54Cv930l/JBwK50vCEOVjjBWkchpj WbXHeXd8d4MVa3JVzeFytTeH78xaTmrOC2xq4hNJn5VTNLLyKtfYuw8663AUjLKxWowQTX 2K14H68jKjha25j3xlHFRpn9f8X12a/DGivlTmSxsv/ANDbdmsCoL81+uQhfOTyIDQw/3N E2nnAhtAbkk+76syauBIvkhqcKCDXQkUFdRr92XdHGPlaF1MBhfATxh1ky6NcWKvLepNqp bTreEK/keadGnVHnLFIO0fuPi4V0/kRH+8oOZI+mIKfx++SUX7IwDbNQ9+E/Lg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757964107; a=rsa-sha256; cv=none; b=MnOaRLiE5f7eZA+jSjGDjv59/YN97HmaAoklUulv4YPN3hG7dD08Ofpm0shEGrg8KQUALo fsjhobHofpMEtWjJuMz7PC1b5THlho9dxc2L386rUvWfZFEEakVdoGJ0/DHUjiS3DtJp/f FxFFM6OSiJysbGQOjks0EnwSmZcYkns2fa5he29POUFa4h25h1kMzjSBVCNmhBmBnAhZTR t+d8hn9MnQOmBh4OuvRN5Jaf5GUG+feRTb0BnKRRuouc34/0B5BW6ju/QBsPugqjchCI56 PGKPF84VA1J/URRBHg3OzyXF2YVZiBrQ0yhF0LwhhpDQoQngEpceGtvr0lA/OA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZf33b67z16y1; Mon, 15 Sep 2025 19:21:47 +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 58FJLl1Y073278; Mon, 15 Sep 2025 19:21:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJLlHh073275; Mon, 15 Sep 2025 19:21:47 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:21:47 GMT Message-Id: <202509151921.58FJLlHh073275@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 4efc1b22aab1 - stable/14 - riscv: Fix SSTC extension support 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: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 4efc1b22aab1a15bff95012deb789696d71f97ec Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=4efc1b22aab1a15bff95012deb789696d71f97ec commit 4efc1b22aab1a15bff95012deb789696d71f97ec Author: Ruslan Bukin AuthorDate: 2024-05-22 14:51:45 +0000 Commit: Mitchell Horne CommitDate: 2025-09-15 19:20:27 +0000 riscv: Fix SSTC extension support From the SSTC spec: "If the stimecmp (supervisor-mode timer compare) register is implemented, then STIP is read-only in mip and reflects the supervisor-level timer interrupt signal resulting from stimecmp. This timer interrupt signal is cleared by writing stimecmp with a value greater than the current time value." This fixes operation in Spike with sstc extension enabled. Example: spike --isa RV64IMAFDCH_zicntr_zihpm_sstc Reviewed by: mhorne Differential Revision: https://reviews.freebsd.org/D45226 (cherry picked from commit ddd0d4f4cd65341a07bb3bb833dee7982018fd60) --- sys/riscv/riscv/timer.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/riscv/riscv/timer.c b/sys/riscv/riscv/timer.c index e3d7fc87cea2..b4aa054cae9d 100644 --- a/sys/riscv/riscv/timer.c +++ b/sys/riscv/riscv/timer.c @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2015-2017 Ruslan Bukin + * Copyright (c) 2015-2024 Ruslan Bukin * All rights reserved. * * Portions of this software were developed by SRI International and the @@ -144,7 +144,10 @@ riscv_timer_intr(void *arg) sc = (struct riscv_timer_softc *)arg; - csr_clear(sip, SIP_STIP); + if (has_sstc) + csr_write(stimecmp, -1UL); + else + csr_clear(sip, SIP_STIP); if (sc->et.et_active) sc->et.et_event_cb(&sc->et, sc->et.et_arg); From nobody Mon Sep 15 19:21:48 2025 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 4cQZf5074dz67v2Y; Mon, 15 Sep 2025 19:21:49 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZf44rL6z4Ktc; Mon, 15 Sep 2025 19:21:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757964108; 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=0HOypQaA0WPzT47C6sntgC2fYZogYt10V4YrdfX+4y0=; b=DDs4LeqiHaJboJJvWdzATgl8felho3u0myz2h5FAq5vk/G/oLj/g8tQlb4+PTRHTrKJsOj V54gfUOhLN57TS1xz3z0hOoBuz31TaEFpxVEB7nuDCxKL1b9ZVB0+uziL/utnnqQDXZXAT srnNK4QvUkR7dCzneuxPfIkB8SezDU0AUMtXmZ+droj6D/vfDd9FQq0jdFoUpeQRrXIsmK 6UkPcDNuAfcNbYAe9TYZEgpyE2uXCLT4gJoQVTtIzaMybUnKwXFv7xFCLdTPwY+dqxfy49 oVo680ac9bfXU0y/7VHOhaqMcTLw3iq6BJ0MmOT0JRCF7w3/1oAuFRvoRZwsEA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757964108; 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=0HOypQaA0WPzT47C6sntgC2fYZogYt10V4YrdfX+4y0=; b=sA/mJltIf7wTu0AK/Qb0DvqHCcyPe/m1zMI7p9D6SnMsDEhqV0gebU5/WY8y4UPKU9lLzF EDrZLwcyjAZeqDLi9kE3OdJd3xb6sbAfjc98c2gP/EBFstvU9DAlXLDMufxJN0pxE8QGSB E1zCx3kaxwWnnQzmCHgf0veNmMjXnnb83u/OqV6yd58VjU8JZsfAl/kh9maOdp0up1W+ej 2gHR6KfIzHdmOt5LwabFYicsDX3w8nFPNBvnIf6YPz9sLesZLZ7jvdIoPvoYvg8xiWwnfl vR4xjrXRp9pxoolLRVvNURq3jBOVBFOIvbA2YehJdaKeQajPd//PfJsGsL6yyQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757964108; a=rsa-sha256; cv=none; b=htMtAsck8Db/3qHUVpWwPJQ36hvSSOmyM7qNE7ONMOGIcJ4klxAOjQEr4d/t/CV+v9wQXU zG66yJuFI5DlCrQJ+pnwb29sZnX7daJIlSXKidVXu2PGLaSuMqrGTpZnVQN/gc90L90Keo m7aVRYccvv5qq4YbHJLWRuyXcbWfjQp9E1ys9f7HNN0UpKmWT0YXa62kPCOCOENHsMe/UT XU1CucA9knNSSrDWSa4PsN5g5koAjeNV/upueoTZT0EbnWty7Xe9aiFzB25IDdEN7qpwHH kKgzb3sykEcV/cO0eu6M7CENGdBvYM07AF2jzzG+rxH1zb6zEhNuXZQdqsGgGQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZf44RRXz16y2; Mon, 15 Sep 2025 19:21:48 +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 58FJLmW3073319; Mon, 15 Sep 2025 19:21:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJLmgZ073315; Mon, 15 Sep 2025 19:21:48 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:21:48 GMT Message-Id: <202509151921.58FJLmgZ073315@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 31eaa0141c49 - stable/14 - riscv timer: fix interrupt handling. 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: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 31eaa0141c49128fabfc65f3d282997a8d5e9cdc Auto-Submitted: auto-generated The branch stable/14 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=31eaa0141c49128fabfc65f3d282997a8d5e9cdc commit 31eaa0141c49128fabfc65f3d282997a8d5e9cdc Author: Ruslan Bukin AuthorDate: 2025-03-26 08:09:50 +0000 Commit: Mitchell Horne CommitDate: 2025-09-15 19:20:32 +0000 riscv timer: fix interrupt handling. Based on the spec the STIP bit of SIP register is read-only. To clear STIP bit from supervisor we have to do an SBI call to firmware. Upon reception of SBI request, the machine-mode firmware clears the STIP bit in the MIP register. This fixes operation on Codasip A730. Reviewed by: mhorne Differential Revision: https://reviews.freebsd.org/D49487 (cherry picked from commit 6d58c670060a17817fa0c8ebf4e7543c3d2b4523) --- sys/riscv/riscv/timer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/riscv/riscv/timer.c b/sys/riscv/riscv/timer.c index b4aa054cae9d..8390fa9c448c 100644 --- a/sys/riscv/riscv/timer.c +++ b/sys/riscv/riscv/timer.c @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2015-2024 Ruslan Bukin + * Copyright (c) 2015-2025 Ruslan Bukin * All rights reserved. * * Portions of this software were developed by SRI International and the @@ -147,7 +147,7 @@ riscv_timer_intr(void *arg) if (has_sstc) csr_write(stimecmp, -1UL); else - csr_clear(sip, SIP_STIP); + sbi_set_timer(-1UL); if (sc->et.et_active) sc->et.et_event_cb(&sc->et, sc->et.et_arg); From nobody Mon Sep 15 19:26:02 2025 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 4cQZl245Htz67vkk; Mon, 15 Sep 2025 19:26:06 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZl23VYkz4Lt9; Mon, 15 Sep 2025 19:26:06 +0000 (UTC) (envelope-from bz@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757964366; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=yLCpkVcr2NRCTIkbzm1omgfwEG2vZoQ6wOK3X6SCdRU=; b=rqPIv258acT23qfukEPKB9b+LnPp7JOt55N4Xw3vT1fXDCu+YjdfeSuO4tHEmos0sFdAPt gc+m4aqMdPJfVLjnrVx0LgEU0yIl/J/heY0ycMe/aBiVhtW+q/KZWltqVlB+3EWdpQ1BVj DeUraVT4/0mcYPmXM142UBmCcLgf8f0gUNwIEtaRRZwZvbZ9C2PBl9RQ+LZ9Dce297ddS1 u04HjdcjCgBYvkazXgRojjlpsj15gnx6rWQ9Oxgk6iR4lVAYHtNAYFJ24r0vCtQAVURwXG BwAIb9HzxCdFo+Y9bnUg1a+sBp4GGj+yaeu2ga8zpmm1jsKwMexLkffbAgqWNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757964366; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=yLCpkVcr2NRCTIkbzm1omgfwEG2vZoQ6wOK3X6SCdRU=; b=krFsDRNvxMp2qKwTOadDiHnCvy6fhwG16cPs31Y8kvy6UdErLDVn9kMimAMcmjMvv5dTZZ yxCGiA9ApCswjGIjhFw/MNT4dvqKLWerUQTedIuPlLKdtdPgKUxrp4DHLQXr3Hft4NMbBJ 9t+gK35fB7tsTDbKul7Joqree4zyhJnbbNKnktbLS8qTr77zdJ5xSuaAZTd9CaAw9xwOUA TWcK5lx7aHYa8fK5XiThCti0vRWuxMHnkOZ7G/s6XLp3VdHG0bI3Zo0kp55S09e5RqVF3H 4gP0S77Byq+f/YJj62czFtDyf/Ws33BE6FfdvP+tNW7zjuMetOQ5fi8jsI4x5Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757964366; a=rsa-sha256; cv=none; b=xAOVaMOgWNJVMci6adr2UbFKcrqvTGkKO1eJ6N1CtUzEYToIRgUbsEuIuyHmJLZVVjhjnR iny72ijL53WsDxy9PdxI3LiNhzM+cu+RhqH8hppLg9uhipVtkqjMeAOEiKgKm6T08A4xCF D4u9tH11PXE31tj/MBrszCoIZFNQp28n50VR/be/TCP7Ch/8iRibYDZIQs3xQxMGXvbnl6 6TVbOLW3Hg1RxmT4t812y4fX2SYhxAulXIY+Q9DVyonzTl1HvzMmcwNexJ9Gcao28mlxpg NiHEOW+94xx6DUesAYueeWAhvQw8xCkE/rQy/hcKBOas7RgygY8fFkq+4Wf2Ug== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from mx-01.divo.sbone.de (mx-01.divo.sbone.de [IPv6:2003:a:140a:2200:6:594:fffe:19]) (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 ECDSA (prime256v1) client-digest SHA256) (Client CN "mx-01.divo.sbone.de", Issuer "E6" (verified OK)) (Authenticated sender: bz/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cQZl220YSzc2; Mon, 15 Sep 2025 19:26:06 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from mail.sbone.de (mail.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:1025]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by mx-01.divo.sbone.de (Postfix) with ESMTPS id ED1ABA64805; Mon, 15 Sep 2025 19:25:55 +0000 (UTC) Received: from content-filter.t4-02.sbone.de (content-filter.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:2742]) (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) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPS id 707552D029E6; Mon, 15 Sep 2025 19:26:04 +0000 (UTC) X-Virus-Scanned: amavisd-new at sbone.de Received: from mail.sbone.de ([IPv6:fde9:577b:c1a9:4902:0:7404:2:1025]) by content-filter.t4-02.sbone.de (content-filter.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:2742]) (amavisd-new, port 10024) with ESMTP id fTgPfo-Os28w; Mon, 15 Sep 2025 19:26:03 +0000 (UTC) Received: from strong-iwl0.sbone.de (strong-iwl0.sbone.de [IPv6:fde9:577b:c1a9:4902:a66b:b6ff:fe40:39a9]) (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) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPSA id D55462D029D8; Mon, 15 Sep 2025 19:26:02 +0000 (UTC) Date: Mon, 15 Sep 2025 19:26:02 +0000 (UTC) From: "Bjoern A. Zeeb" To: Warner Losh , =?UTF-8?Q?Jean-S=C3=A9bastien_P=C3=A9dron?= cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 5e0a4859f28a - main - iwlwifi: Don't compile for gcc before 14 In-Reply-To: <202509150304.58F34BWJ035102@gitrepo.freebsd.org> Message-ID: References: <202509150304.58F34BWJ035102@gitrepo.freebsd.org> X-OpenPGP-Key-Id: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 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; format=flowed; charset=US-ASCII On Mon, 15 Sep 2025, Warner Losh wrote: > The branch main has been updated by imp: > > URL: https://cgit.FreeBSD.org/src/commit/?id=5e0a4859f28ad4869f7a73faf42debc355a370bf > > commit 5e0a4859f28ad4869f7a73faf42debc355a370bf > Author: Warner Losh > AuthorDate: 2025-09-14 18:03:16 +0000 > Commit: Warner Losh > CommitDate: 2025-09-15 03:03:45 +0000 > > iwlwifi: Don't compile for gcc before 14 > > gcc 13 and earlier don't have __builtin_bitcountg. The linux wifi kpi > uses this unconditionally. While in this one use, it might not be > needed, I opted to not compile iwlwifi when building gcc12 or 13 rather > than risk breaking it for everbody else. > > With this change gcc12 builds the kernel. Maybe this will stop jenkins > email for every commit I make. > > Sponsored by: Netflix > --- > sys/modules/Makefile | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/sys/modules/Makefile b/sys/modules/Makefile > index 5315d518afd8..f9fdbca78869 100644 > --- a/sys/modules/Makefile > +++ b/sys/modules/Makefile > @@ -576,7 +576,10 @@ _mlx5ib= mlx5ib > ${MACHINE_CPUARCH} == "i386" > _ena= ena > _gve= gve > +# gcc13 and earlier lack __builtin_bitcountg used by linux emulation (a) I beleive there is no __builtin_bitcountg but you mean __builtin_popcountg both here and in the commit message. (b) That was introduced in 7cbc4d875971860d941cc15d7f42e6cfeffbfe66 for DRM (c) There is no direct use in any LinuxKPI based wireless driver: % grep -r __builtin_popcountg sys/contrib/dev % (4) iwlwifi only uses HWEIGHT32, which was changed by the aforementioned commit in LinuxKPI. (5) Please do it right and in the place where it is actually defined to be used, in LinuxKPI, and not here as it can be easily fixed there with an #ifdef or otherwise as there were alternatives on the review if I remember correctly. I am Cc:ing dumbbell as well as he needed the change for DRM. PS: we also need to fix this in sys/sys at some point and save us some trouble. > +.if !(${COMPILER_TYPE} == "gcc" && ${COMPILER_VERSION} < 140000) > _iwlwifi= iwlwifi > +.endif > _rtw88= rtw88 > _rtw89= rtw89 > _vmware= vmware > -- Bjoern A. Zeeb r15:7 From nobody Mon Sep 15 19:34:50 2025 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 4cQZx63WWzz67wSn; Mon, 15 Sep 2025 19:34:50 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZx632MMz4Myj; Mon, 15 Sep 2025 19:34:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757964890; 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=Hc1e/UFpSzpgqypsIXw8O/Tblu6lgcm1E8EsZTAsNu0=; b=Yjx4Su3+CUDctNdRXuzXZHMpRQMdfEX7IKSOeb3Njjl/Vwkk3pKINmynPd4/pOlpH70w6e CG/oLp3KRA9PdR/jWUxbXW1Fb8pkJNCzt17YVUIJ9dcuYWgNsvfoqeoHgAwmlGrqLaDxE+ vrSWRuMDzpWjxhN71QrEbsr9QBG5aBv7msc+v9DXuqgmfYHo3lcRef7WbUBJaYG/9iwOK9 s9gSeAgli4k4u4/9umazMO9JfhSz81OZhPkdOgeLfvaFQYbREgYQCwrdcBl0F3SngcI9md sYMd2hthD01gXSTHVk1gHgJMLY/zydgBUjXFDPvwYT/bJwz4im4lNdb4FPgOhA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757964890; 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=Hc1e/UFpSzpgqypsIXw8O/Tblu6lgcm1E8EsZTAsNu0=; b=fMiUM39XeMMgeXfTgdbxBCQiolBuhamrxT98BlPG8wOg1Kv60zzjlHjVyH/AzjdGpXZKde mmoLwL2un5lKRt5hmr4zfrNyY6YG/pFUn07OlQGeIeswgs5lbqjTFMXfvUqzKRDnx+XF8e r5Y7uve6MmJVq/5leidWNrid1c0bCYLYwaMDXoSAkgNIrMaD+uk9tK9aqVML+A1iMRZ+cn /7VyXjiOg8VL87lE8aU+1RiCuxoPw7d44oVLN7oQBVRnoPi02oD8J/VHO10lUYkLsDxwEk pghl2UjgfWnFr4EY8mY1LYei4we3kL9b6vjOW/ieMddQBxdz0jnX7Uux35KGEw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757964890; a=rsa-sha256; cv=none; b=Z7Mw/1JCkIjdmr5QpMc/QJAZiUeZ9JVd3sRez4dmkhMGrW9lLeVABu331Ji3xmhRXopnYN LvVkSCG6j/PgRQLsx8Zu6vlz1LRFtIcpXORUDAG7tfSzxT+rInT8D0H4T1hiPIug7cWMB1 +0xNC8jvSbP9S5BjvQ6BIoCUPIXilNxq+RsdzBxbF3L3GcRRE5TsbqtaXefuYEEWu2SxO5 l7XwZjTTfBep8j7Ql1HI6cIGrPNuis3HWSpMPUe5tFMVwRcIfKiiVlz30s2/1k0nx3zTS4 MJFmCJSGFAHLb88E2l2pFNVIn9BaGI026D/Sur6LcIJZYJZ0XKJ9TBxPMGdXvw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZx62RB9z17KV; Mon, 15 Sep 2025 19:34:50 +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 58FJYoDP092989; Mon, 15 Sep 2025 19:34:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJYor9092985; Mon, 15 Sep 2025 19:34:50 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:34:50 GMT Message-Id: <202509151934.58FJYor9092985@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 850182848dad - stable/13 - riscv: Fix SSTC extension support 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: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 850182848dada6f8524e9df2a75a01aa50b09b69 Auto-Submitted: auto-generated The branch stable/13 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=850182848dada6f8524e9df2a75a01aa50b09b69 commit 850182848dada6f8524e9df2a75a01aa50b09b69 Author: Ruslan Bukin AuthorDate: 2024-05-22 14:51:45 +0000 Commit: Mitchell Horne CommitDate: 2025-09-15 19:32:14 +0000 riscv: Fix SSTC extension support From the SSTC spec: "If the stimecmp (supervisor-mode timer compare) register is implemented, then STIP is read-only in mip and reflects the supervisor-level timer interrupt signal resulting from stimecmp. This timer interrupt signal is cleared by writing stimecmp with a value greater than the current time value." This fixes operation in Spike with sstc extension enabled. Example: spike --isa RV64IMAFDCH_zicntr_zihpm_sstc Reviewed by: mhorne Differential Revision: https://reviews.freebsd.org/D45226 (cherry picked from commit ddd0d4f4cd65341a07bb3bb833dee7982018fd60) --- sys/riscv/riscv/timer.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/riscv/riscv/timer.c b/sys/riscv/riscv/timer.c index 66131914607c..f7657130ff70 100644 --- a/sys/riscv/riscv/timer.c +++ b/sys/riscv/riscv/timer.c @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2015-2017 Ruslan Bukin + * Copyright (c) 2015-2024 Ruslan Bukin * All rights reserved. * * Portions of this software were developed by SRI International and the @@ -142,7 +142,10 @@ riscv_timer_intr(void *arg) sc = (struct riscv_timer_softc *)arg; - csr_clear(sip, SIP_STIP); + if (has_sstc) + csr_write(stimecmp, -1UL); + else + csr_clear(sip, SIP_STIP); if (sc->et.et_active) sc->et.et_event_cb(&sc->et, sc->et.et_arg); From nobody Mon Sep 15 19:34:51 2025 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 4cQZx746Jmz67wSp; Mon, 15 Sep 2025 19:34:51 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQZx73DQFz4MqL; Mon, 15 Sep 2025 19:34:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757964891; 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=iBvMIypVFbq2BGP+q7FJ1GNvfFt9tD0g0g8/sr/0gM4=; b=o/7bakfISDge/zte+0PgBMypGYUGVKNTGdmaJzwF2i0IKGMdU1y3mdK3ks3fz1eCr9VG8w ao250bVoqpM24CFLUOeVLLYgtaeMyAHEa6kwsd2oOnXRCmsqBRHBj2gOvLfbGkSzI0U0Rn laCsjVuj4SZPxcMB1dhrzZC/by/GsCfx26ZTPVlp6aF7Hg7cXo6gKArJEAAbBZBYqzIZAs 0wzYwgqrdp1dFvWCovaCX73ovZtBvKigKHvBffpvtjBaxpQKUFmoqLgs7r/XssqidqnqwH beNjWCz6zNFgF0h+MfGfSUInA8rZwVPpzaNnIBuQJAjzfywrhpGF5Fav0ubbaw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757964891; 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=iBvMIypVFbq2BGP+q7FJ1GNvfFt9tD0g0g8/sr/0gM4=; b=QSpYFZEtZ4bWGV3GIJpSr+aKhQnK3HW8SL7J4qmHx2iKY6w0xTk7oZr4qzdxwMOi7g/ViP op4kr6OSS1rhTlS2SnWs/25STHk0m1fkaGCbuNMJkLIDiZ+mijLFz/Lafkc6/P0bYRveea B8mpVUUchXsLgv+zelFj7YQqd+NanveFHt4hgwlCEOnMG8b59hS9HCj1x92kvqgUbTxtGA +DKmkajRS6WwEVOEEhgTpcc1igcja1S0ZErcDmMZpKD0gdNkCgfABIf17BRxY0M8AbJKXf FVzN3YiNKFlcmwMcXZtiImAT9KOeUOUygLxf5mHja1J7NtDSt1oTDwIWS+UeFQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757964891; a=rsa-sha256; cv=none; b=I66i5vzJJnoQ4JhHRhqGGwKs9s+jjF4nqaiDKl7lNAsAdGIoKBfyShoC+iegsllWTSXVpn COGt3eZgGdFDmoPDoKtUbMcB+IRyihW0DpJ+RiJsJoiMkFVWFY7svdzDQRoyYZxfWAxs4Z IdXXEJUwPXimcrZsy/SjYWIvCOVt2Z2DaNXkRF81O4eu6vdE8cLa56zksTLWnD9pgR8CeK YzCmbAnlodSW1jSRInwQMsao5UEWwXoaAnlqOjx/aflFYLh0JGBJnQ80EVE7QvZg2oq0d4 kT+CFl3FTnyxQSvEWK1/dpixaaFJC2bL6dFSy0+LvsHH3K4SRYEDispM0ikH/g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQZx72kQsz16wZ; Mon, 15 Sep 2025 19:34:51 +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 58FJYph7093028; Mon, 15 Sep 2025 19:34:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FJYpj8093024; Mon, 15 Sep 2025 19:34:51 GMT (envelope-from git) Date: Mon, 15 Sep 2025 19:34:51 GMT Message-Id: <202509151934.58FJYpj8093024@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 8302f09d844c - stable/13 - riscv timer: fix interrupt handling. 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: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 8302f09d844cdf2c942af57ee7babea127675990 Auto-Submitted: auto-generated The branch stable/13 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=8302f09d844cdf2c942af57ee7babea127675990 commit 8302f09d844cdf2c942af57ee7babea127675990 Author: Ruslan Bukin AuthorDate: 2025-03-26 08:09:50 +0000 Commit: Mitchell Horne CommitDate: 2025-09-15 19:32:17 +0000 riscv timer: fix interrupt handling. Based on the spec the STIP bit of SIP register is read-only. To clear STIP bit from supervisor we have to do an SBI call to firmware. Upon reception of SBI request, the machine-mode firmware clears the STIP bit in the MIP register. This fixes operation on Codasip A730. Reviewed by: mhorne Differential Revision: https://reviews.freebsd.org/D49487 (cherry picked from commit 6d58c670060a17817fa0c8ebf4e7543c3d2b4523) --- sys/riscv/riscv/timer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/riscv/riscv/timer.c b/sys/riscv/riscv/timer.c index f7657130ff70..122591960101 100644 --- a/sys/riscv/riscv/timer.c +++ b/sys/riscv/riscv/timer.c @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2015-2024 Ruslan Bukin + * Copyright (c) 2015-2025 Ruslan Bukin * All rights reserved. * * Portions of this software were developed by SRI International and the @@ -145,7 +145,7 @@ riscv_timer_intr(void *arg) if (has_sstc) csr_write(stimecmp, -1UL); else - csr_clear(sip, SIP_STIP); + sbi_set_timer(-1UL); if (sc->et.et_active) sc->et.et_event_cb(&sc->et, sc->et.et_arg); From nobody Mon Sep 15 21:17:58 2025 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 4cQdDY3lwqz684Jv for ; Mon, 15 Sep 2025 21:18:21 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pl1-x636.google.com (mail-pl1-x636.google.com [IPv6:2607:f8b0:4864:20::636]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQdDY0qy8z3L1k for ; Mon, 15 Sep 2025 21:18:21 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pl1-x636.google.com with SMTP id d9443c01a7336-2616549b925so21358485ad.1 for ; Mon, 15 Sep 2025 14:18:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1757971090; x=1758575890; darn=freebsd.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=4RG3e6qX6+ru5ufRMZdFJFc3A8SB9vobUnyGRuygRLI=; b=qi/6ljuf2noFE24USGIvLSXeC5TUCriPUiw6p1GvONN8NbjsbkW8yZ2nAvitsv1vIy wUkTYc6YSMCdAYY3o8qmP+MVgN9tICo8Ojc8Roa8lC9xCC3FNzLwZS9vbYt+vbP0dDqX YmmMavSouaUA8fxuG+UfNEp7zi9MUK0Hl74omyMZiU2KHL4GuIa1JJ/x9Pf37+uoyvtj JXkdC8pvwsr5PUpGJJmsWsVQVnfZ2F7oOOoj2bnBg8fQ65z6oLqAPem3ylbQ6j8KQbnT H6FbRr+JEgXxRQEllZEAdhqKAQEoaaW2H8gOEsBwCFPeq2TXHUust2RGLhbXwHX8il/S z0xQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1757971090; x=1758575890; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=4RG3e6qX6+ru5ufRMZdFJFc3A8SB9vobUnyGRuygRLI=; b=rTFr4igogC2yE3SAZ969c5ydtBGkB7Pdhpgj5HCj4n9Zqeu3a59970Q3a4DTtLDS50 fYJ8ssguLYs3YCvYfC1JOL4aSnnHAiRMIfR2pXtJprBbRtBuh8oXm9DCMn+qqCGwM5lP M8nRdpIlxhPdgfWksD+2sei8yfkq2EHgvcq0vAj+d6ZKiz0XqcfkaoGzBEWG39z+h6gC eJTm6rpK4t+WgYZuGsLwXSDjKUDrzIs37aX1/DFuKXYHV61BIA5vTLbU8DdJ5tHF7Lks 5e0HZZTNSpoWpLyhSki4dE6O79G0erEfthZyLPK9LS+2WCZwad/Qym/8xW3GnAqKV7aY fJ/w== X-Forwarded-Encrypted: i=1; AJvYcCWLrtSh4EjLpmw+Q9HPmrWORPXDuKB+YyeJ9mTDY+A1PoC+M7+qK1Pp5/QoiuDp+7YN4pxlLWCY6G7b+v0ZqK7XbPNZ@freebsd.org X-Gm-Message-State: AOJu0YxTXdJvHNU/4AKyM4o1ofQSUVFKwom44xd3DFPIRyNml8b5WWud IknZDwbpJVT19GvaEtV1fHaQPD8YdRritxOrLTTMjYhJFP857CMy6Z47ublpZCngeXGNexwsuqK kT35xfVjO1M5R/TXKRImMx3oxjNcYUrQfExeH8mJ7b2p68loabADl1eY= X-Gm-Gg: ASbGncuOYf4Yp2Bzfd7A9XyeluE8v1qdyxA0s9Kya2XGAllHLh2mczpnlFtsAx1sc3X vWxRy+bGErMAZIifhtcT3m1pAyPROv7bW0XtEdKcJ4LIYkudV4gu/jKVopC81H7S0Fih4urzVy0 rbZvPaZdTt8Q2mJVacaTrLtUfzc6FbsvGZRFrpFKF9ckMfubPDClO01Q3OM5AiMaPDMwaqlkLcA s6Y2h/k0/6GB4Qsq6CWHHpZj/Fm/WK3MmwTDxfEDZKKrN5FPUd3B+wKBk1I0Z4+zJHz/OvUAYJC F0JN X-Google-Smtp-Source: AGHT+IEVqSQmFROgkN+Z+iKrolE9z874vUzYWiKirlYe8gp1cnr2Er8RpI7tEgnYt7hS99jX0XWaysR/db6F8GUaqfM= X-Received: by 2002:a17:903:24c:b0:250:bd52:4cdb with SMTP id d9443c01a7336-25d27624318mr141391255ad.32.1757971089883; Mon, 15 Sep 2025 14:18:09 -0700 (PDT) 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 References: <202509150304.58F34BWJ035102@gitrepo.freebsd.org> In-Reply-To: From: Warner Losh Date: Mon, 15 Sep 2025 15:17:58 -0600 X-Gm-Features: Ac12FXwInvHoJAxFJZuHS318Rs6CgAVefGNHJhJA6xVfuJP5O4nGo_za49LzGCA Message-ID: Subject: Re: git: 5e0a4859f28a - main - iwlwifi: Don't compile for gcc before 14 To: "Bjoern A. Zeeb" Cc: Warner Losh , =?UTF-8?B?SmVhbi1Tw6liYXN0aWVuIFDDqWRyb24=?= , src-committers , "" , "" Content-Type: multipart/alternative; boundary="000000000000569709063edd8a31" X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4cQdDY0qy8z3L1k --000000000000569709063edd8a31 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, Sep 15, 2025, 1:26=E2=80=AFPM Bjoern A. Zeeb wrote= : > On Mon, 15 Sep 2025, Warner Losh wrote: > > > The branch main has been updated by imp: > > > > URL: > https://cgit.FreeBSD.org/src/commit/?id=3D5e0a4859f28ad4869f7a73faf42debc= 355a370bf > > > > commit 5e0a4859f28ad4869f7a73faf42debc355a370bf > > Author: Warner Losh > > AuthorDate: 2025-09-14 18:03:16 +0000 > > Commit: Warner Losh > > CommitDate: 2025-09-15 03:03:45 +0000 > > > > iwlwifi: Don't compile for gcc before 14 > > > > gcc 13 and earlier don't have __builtin_bitcountg. The linux wifi kp= i > > uses this unconditionally. While in this one use, it might not be > > needed, I opted to not compile iwlwifi when building gcc12 or 13 > rather > > than risk breaking it for everbody else. > > > > With this change gcc12 builds the kernel. Maybe this will stop jenki= ns > > email for every commit I make. > > > > Sponsored by: Netflix > > --- > > sys/modules/Makefile | 3 +++ > > 1 file changed, 3 insertions(+) > > > > diff --git a/sys/modules/Makefile b/sys/modules/Makefile > > index 5315d518afd8..f9fdbca78869 100644 > > --- a/sys/modules/Makefile > > +++ b/sys/modules/Makefile > > @@ -576,7 +576,10 @@ _mlx5ib=3D mlx5ib > > ${MACHINE_CPUARCH} =3D=3D "i386" > > _ena=3D ena > > _gve=3D gve > > +# gcc13 and earlier lack __builtin_bitcountg used by linux emulation > > (a) I beleive there is no __builtin_bitcountg but you mean > __builtin_popcountg > both here and in the commit message. > Yes. (b) That was introduced in 7cbc4d875971860d941cc15d7f42e6cfeffbfe66 for DRM > > (c) There is no direct use in any LinuxKPI based wireless driver: > % grep -r __builtin_popcountg sys/contrib/dev > % > > (4) iwlwifi only uses HWEIGHT32, which was changed by the aforementioned > commit > in LinuxKPI. > Yes. I noticed all that. Didn't see a trivial way to fix it right. (5) Please do it right and in the place where it is actually defined to be > used, > in LinuxKPI, and not here as it can be easily fixed there with an > #ifdef or > otherwise as there were alternatives on the review if I remember > correctly. > Knock yourselves out. I was tired of the CI jobs whining and this was the easiest way to make that stop. I've got too many things on my plate to refine this more. If you want to support older gcc for this driver, that's up to you. The ci jobs have been failing for weeks if not longer I am Cc:ing dumbbell as well as he needed the change for DRM. > > PS: we also need to fix this in sys/sys at some point and save us some > trouble. > What's to fix? Creating the Generic wrapper around builtin_popcount? Warner > > +.if !(${COMPILER_TYPE} =3D=3D "gcc" && ${COMPILER_VERSION} < 140000) > > _iwlwifi=3D iwlwifi > > +.endif > > _rtw88=3D rtw88 > > _rtw89=3D rtw89 > > _vmware=3D vmware > > > > -- > Bjoern A. Zeeb r15:7 > --000000000000569709063edd8a31 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Mon, Sep 15, 2025, 1:26=E2=80= =AFPM Bjoern A. Zeeb <bz@freebsd.org> wrote:
On Mon, 15 Sep 2025, = Warner Losh wrote:

> The branch main has been updated by imp:
>
> URL:
https://cgit.FreeBSD.org/src/commit/?id=3D5e0a4859f28ad4869f7a73faf42deb= c355a370bf
>
> commit 5e0a4859f28ad4869f7a73faf42debc355a370bf
> Author:=C2=A0 =C2=A0 =C2=A0Warner Losh <imp@FreeBSD.org>
> AuthorDate: 2025-09-14 18:03:16 +0000
> Commit:=C2=A0 =C2=A0 =C2=A0Warner Losh <imp@FreeBSD.org>
> CommitDate: 2025-09-15 03:03:45 +0000
>
>=C2=A0 =C2=A0 iwlwifi: Don't compile for gcc before 14
>
>=C2=A0 =C2=A0 gcc 13 and earlier don't have __builtin_bitcountg. Th= e linux wifi kpi
>=C2=A0 =C2=A0 uses this unconditionally. While in this one use, it migh= t not be
>=C2=A0 =C2=A0 needed, I opted to not compile iwlwifi when building gcc1= 2 or 13 rather
>=C2=A0 =C2=A0 than risk breaking it for everbody else.
>
>=C2=A0 =C2=A0 With this change gcc12 builds the kernel. Maybe this will= stop jenkins
>=C2=A0 =C2=A0 email for every commit I make.
>
>=C2=A0 =C2=A0 Sponsored by:=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0Net= flix
> ---
> sys/modules/Makefile | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/sys/modules/Makefile b/sys/modules/Makefile
> index 5315d518afd8..f9fdbca78869 100644
> --- a/sys/modules/Makefile
> +++ b/sys/modules/Makefile
> @@ -576,7 +576,10 @@ _mlx5ib=3D mlx5ib
>=C2=A0 =C2=A0 =C2=A0${MACHINE_CPUARCH} =3D=3D "i386"
> _ena=3D=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0ena
> _gve=3D=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0gve
> +# gcc13 and earlier lack __builtin_bitcountg used by linux emulation<= br>
(a) I beleive there is no __builtin_bitcountg but you mean __builtin_popcou= ntg
both here and in the commit message.

Yes.

(b) That was introduced in 7cbc4d875971860d941cc15d7f42e6cfeffbfe66 for DRM=

(c) There is no direct use in any LinuxKPI based wireless driver:
% grep -r __builtin_popcountg sys/contrib/dev
%

(4) iwlwifi only uses HWEIGHT32, which was changed by the aforementioned co= mmit
=C2=A0 =C2=A0 =C2=A0in LinuxKPI.

Yes. I noticed all that. Didn't see a t= rivial way to fix it right.

(5) Please do it right and in the place where it is actually defined to be = used,
=C2=A0 =C2=A0 =C2=A0in LinuxKPI, and not here as it can be easily fixed the= re with an #ifdef or
=C2=A0 =C2=A0 =C2=A0otherwise as there were alternatives on the review if I= remember correctly.

Knock yourselves out. I was tired of the CI jobs whinin= g and this was the easiest way to make that stop. I've got too many thi= ngs on my plate to refine this more. If you want to support older gcc for t= his driver, that's up to you. The ci jobs have been failing for weeks i= f not longer

I am Cc:ing dumbbell as well as he needed the change for DRM.

PS: we also need to fix this in sys/sys at some point and save us some
trouble.

What's to fix? Creating the Generic wrapper around builtin_po= pcount?

Warner


> +.if !(${COMPILER_TYPE} =3D=3D "gcc" && ${COMPILER_V= ERSION} < 140000)
> _iwlwifi=3D=C2=A0 =C2=A0 =C2=A0iwlwifi
> +.endif
> _rtw88=3D=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0rtw88<= br> > _rtw89=3D=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0rtw89<= br> > _vmware=3D=C2=A0 =C2=A0 =C2=A0 vmware
>

--
Bjoern A. Zeeb=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0r15:7
--000000000000569709063edd8a31-- From nobody Mon Sep 15 21:32:12 2025 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 4cQdXc4krcz685CG; Mon, 15 Sep 2025 21:32:16 +0000 (UTC) (envelope-from bz@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQdXc4241z3LgV; Mon, 15 Sep 2025 21:32:16 +0000 (UTC) (envelope-from bz@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757971936; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=bMKxtR1nO7tCnPJEUnIF2mIazjotx0l2HClE0YXFB0g=; b=Yduht1iJacHR9DICVzwJSgADvU6hZ05rLRNZiSdiwHkcXBixaY96NbAYYIUznKuFld17v2 efrIZAMa2B1nn+MdvUs7wVD1E1ToBAxwYMLO5jlMpaewthLxm8+1Gl1v4rcEQyy5cckDXA r6I9YGq5RhJ54F5HftJR7HCLldJUlzuTK5SH74Z/oW2knTQ8pGM974f0RvidGdjq8W5Mj8 YHizlrtFPiGGkC60hbWzZqgZUP1knfOky4e3OqEZtgnhiv6422HtQ1oq+gBl2XlXq8rxrr F9NnS70lEKgCP/mtfCZr36xuL36Ff7aJ+qZw+YzZf+PMATRjkdPnN0O63VrQBA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757971936; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=bMKxtR1nO7tCnPJEUnIF2mIazjotx0l2HClE0YXFB0g=; b=f/+8hPEk7AMO8c/dLvKpxE70dxRrMcY9agt6+aLb/zk3ZB/Pj2Ilz/H/waYgqnwlXz335o hPUIW+S7DRYbGap8IgG98onHpKpgJ/Vu2E6hZ/lYIArEGRO0YiNY3k8cIp2EqtQ0oo9oIA 98ftuLWfYrflWXddNo1vudXtnKLUxOMEwOF3bLkuNtJKkFJ8H7CGWe4A0lBThGRxEJLnTm PW1ixiu+kC1zgJ4wBsChvwiek4n6B8iO5sJqx74fl/14grpDVadhhMr7MFh0urDnqsk4xn p33ewMvZtc7rbgq6IrW7RJV1HZ9WcBlACdcJQZk5dvgdJFqXymeZZMxXgS+bHA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757971936; a=rsa-sha256; cv=none; b=PZQRVRjb5bFLdSpeciz1vnUn2e1LgZQmTfdy0zJqMWrPRLqgyhwU7kPXVa0jFjHi/J/FD5 WupN7XMjfmHtMGH/FP8YsZJLo63zE02IQ1NpoCaUy9DIVBnnns1EJJnHz7vu3AEERivfc+ j+FoLVnRJ/Js1rUHW6sI4iyRivzN7ubvvTDK0yjcbEg7qiX1RXP0Plkos2ThvRXiO0pnPU WNvgshRwf6Kz4F/6CGcqg6iQerZDEPrarC74cukDlDzq0/dm1dXny+3aoXNdDS63TshwKk AbMlFOvd3dxSN/rhlxGnch7GeQiGQwVps0ADDvEapSadDBuNeVvATo95mS17DA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from mx-01.divo.sbone.de (mx-01.divo.sbone.de [IPv6:2003:a:140a:2200:6:594:fffe:19]) (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 ECDSA (prime256v1) client-digest SHA256) (Client CN "mx-01.divo.sbone.de", Issuer "E6" (verified OK)) (Authenticated sender: bz/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cQdXc21yRz3Bs; Mon, 15 Sep 2025 21:32:16 +0000 (UTC) (envelope-from bz@freebsd.org) Received: from mail.sbone.de (mail.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:1025]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by mx-01.divo.sbone.de (Postfix) with ESMTPS id C9E31A64805; Mon, 15 Sep 2025 21:32:05 +0000 (UTC) Received: from content-filter.t4-02.sbone.de (content-filter.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:2742]) (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) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPS id 4FA682D029E6; Mon, 15 Sep 2025 21:32:14 +0000 (UTC) X-Virus-Scanned: amavisd-new at sbone.de Received: from mail.sbone.de ([IPv6:fde9:577b:c1a9:4902:0:7404:2:1025]) by content-filter.t4-02.sbone.de (content-filter.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:2742]) (amavisd-new, port 10024) with ESMTP id 5Uwd4HrnlGBx; Mon, 15 Sep 2025 21:32:13 +0000 (UTC) Received: from strong-iwl0.sbone.de (strong-iwl0.sbone.de [IPv6:fde9:577b:c1a9:4902:a66b:b6ff:fe40:39a9]) (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) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPSA id 188A72D029D8; Mon, 15 Sep 2025 21:32:13 +0000 (UTC) Date: Mon, 15 Sep 2025 21:32:12 +0000 (UTC) From: "Bjoern A. Zeeb" To: Warner Losh cc: Warner Losh , =?UTF-8?Q?Jean-S=C3=A9bastien_P=C3=A9dron?= , src-committers , "" , "" Subject: Re: git: 5e0a4859f28a - main - iwlwifi: Don't compile for gcc before 14 In-Reply-To: Message-ID: References: <202509150304.58F34BWJ035102@gitrepo.freebsd.org> X-OpenPGP-Key-Id: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 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: multipart/mixed; boundary="1098556516-186450911-1757971933=:4619" This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --1098556516-186450911-1757971933=:4619 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8BIT On Mon, 15 Sep 2025, Warner Losh wrote: > On Mon, Sep 15, 2025, 1:26 PM Bjoern A. Zeeb wrote: > >> On Mon, 15 Sep 2025, Warner Losh wrote: >> >>> The branch main has been updated by imp: >>> >>> URL: >> https://cgit.FreeBSD.org/src/commit/?id=5e0a4859f28ad4869f7a73faf42debc355a370bf >>> >>> commit 5e0a4859f28ad4869f7a73faf42debc355a370bf >>> Author: Warner Losh >>> AuthorDate: 2025-09-14 18:03:16 +0000 >>> Commit: Warner Losh >>> CommitDate: 2025-09-15 03:03:45 +0000 >>> >>> iwlwifi: Don't compile for gcc before 14 >>> >>> gcc 13 and earlier don't have __builtin_bitcountg. The linux wifi kpi >>> uses this unconditionally. While in this one use, it might not be >>> needed, I opted to not compile iwlwifi when building gcc12 or 13 >> rather >>> than risk breaking it for everbody else. >>> >>> With this change gcc12 builds the kernel. Maybe this will stop jenkins >>> email for every commit I make. >>> >>> Sponsored by: Netflix >>> --- >>> sys/modules/Makefile | 3 +++ >>> 1 file changed, 3 insertions(+) >>> >>> diff --git a/sys/modules/Makefile b/sys/modules/Makefile >>> index 5315d518afd8..f9fdbca78869 100644 >>> --- a/sys/modules/Makefile >>> +++ b/sys/modules/Makefile >>> @@ -576,7 +576,10 @@ _mlx5ib= mlx5ib >>> ${MACHINE_CPUARCH} == "i386" >>> _ena= ena >>> _gve= gve >>> +# gcc13 and earlier lack __builtin_bitcountg used by linux emulation >> >> (a) I beleive there is no __builtin_bitcountg but you mean >> __builtin_popcountg >> both here and in the commit message. >> > > Yes. > > (b) That was introduced in 7cbc4d875971860d941cc15d7f42e6cfeffbfe66 for DRM >> >> (c) There is no direct use in any LinuxKPI based wireless driver: >> % grep -r __builtin_popcountg sys/contrib/dev >> % >> >> (4) iwlwifi only uses HWEIGHT32, which was changed by the aforementioned >> commit >> in LinuxKPI. >> > > Yes. I noticed all that. Didn't see a trivial way to fix it right. > > (5) Please do it right and in the place where it is actually defined to be >> used, >> in LinuxKPI, and not here as it can be easily fixed there with an >> #ifdef or >> otherwise as there were alternatives on the review if I remember >> correctly. >> > > Knock yourselves out. I was tired of the CI jobs whining and this was the > easiest way to make that stop. I've got too many things on my plate to > refine this more. If you want to support older gcc for this driver, that's > up to you. The ci jobs have been failing for weeks if not longer Okay, will do. But gcc12/13 had been whining for months on a lot of things constantly. I really don't know how a day to do it right would have made a difference. -- Bjoern A. Zeeb r15:7 --1098556516-186450911-1757971933=:4619-- From nobody Mon Sep 15 21:40:26 2025 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 4cQdk26MDfz685lT; Mon, 15 Sep 2025 21:40:26 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQdk25qlcz3NRR; Mon, 15 Sep 2025 21:40:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757972426; 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=06f3vAgAWyusL3V70NrEH2PNomgExo+7cQepHXoBmdQ=; b=hxOjHjDkBL5zkyTspRgWOiykSTJY17Dj/OeVP9BUciJ6Nlr8hBkrfXy4Nr2+Wm1lqWCVeS /I6g2+0ey439qIDxCGCrchxElCAGalfzzqI0iz/G3PEbLJcVbRUIi6r8vmXUa+PFZ+USGj RnFEnUOp4LzN5EvnQaIPw8PML2ehseEFAGZLtEIgkW4KWFutHPhrkOwXir1Z1dr6j7VKJx nVWqGYfC8iDPVtC/7Iy9uvmP2wPKHI0MooZhHDdxNN/UOPGVsdWhjulVyWW4h2GifUoNfL 7aGfvKupN/nGJlOpxjOpClsV0+qhFCEmS7zR3ZNTxIQmkkvqFKqPrw6ZdzHI6A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757972426; 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=06f3vAgAWyusL3V70NrEH2PNomgExo+7cQepHXoBmdQ=; b=fkbiZYkyjleZn0lyIwWJ/BHS1OKG9A82JcmIVdGYGTxiyB6P9ejI1b18YOx5e+YyUSbaXJ uxSPySMDIhpS3MYWB4gnOOfkJr7K0sBSHA9eH5/SUNZH4qO0vNSIsLKt/GqqyZ/k9GnX0m jH7E0TG8tXi1h4t6BhLb6AZ37WTmeJUWQu2hJvdEPlC2KKnEmBDq8XWxHHWSETJXemS24w 1o0VxJbMLY4ooa08YhhGvjCFpcCxsJlnGWr1iGTuoPNW9+xgRTlPFyzrf+8SqwJKkcyO1y iSpxkFAFuSaaj8JHT8+R2LjAmAiziSw4oxJoulHLk+kZZ6UMKBJgmgPNii6a8Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757972426; a=rsa-sha256; cv=none; b=hv5AnR+n4KNtMfkH6X6Wl+K2rYkMxPSnUQTd716ExdYxUqjGTsrvgcSM92ytLAzQTzxPwr 0nJ035BA98RRqTDheVd7WqNnud/U02+UfNBFQ6Wu0vbtfEt/RMuAu+3EP26i6OTEWHkNK8 Gq8QP3eQT6YzaPQ5pEJtkfwkbR8er7tUG53ji+w1+P7/JGLV3z5ss8EAeQq/K1PHWjYwMw z/NSVNf5Z0BC9YIAUU1Fmv7HfXVPL6XRZdcv23OjfGgEDsm4c296D/g5sc4OOWKoONIMO5 O1vtLi2kmhks1k0f6XHJb9q9D41PXhK3B+dvuaau7MdkrjK8F85NOUPp/Hf4FA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQdk25K99z19bb; Mon, 15 Sep 2025 21:40:26 +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 58FLeQth030084; Mon, 15 Sep 2025 21:40:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FLeQQF030081; Mon, 15 Sep 2025 21:40:26 GMT (envelope-from git) Date: Mon, 15 Sep 2025 21:40:26 GMT Message-Id: <202509152140.58FLeQQF030081@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ahmad Khalifa Subject: git: 27699e31fa50 - main - boot/universe.sh: toggle LOADER_BIOS_TEXTONLY 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: vexeduxr X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 27699e31fa50e2bee6fdd0b5a0bfb92b4d35d7b7 Auto-Submitted: auto-generated The branch main has been updated by vexeduxr: URL: https://cgit.FreeBSD.org/src/commit/?id=27699e31fa50e2bee6fdd0b5a0bfb92b4d35d7b7 commit 27699e31fa50e2bee6fdd0b5a0bfb92b4d35d7b7 Author: Ahmad Khalifa AuthorDate: 2025-09-15 20:15:02 +0000 Commit: Ahmad Khalifa CommitDate: 2025-09-15 21:38:56 +0000 boot/universe.sh: toggle LOADER_BIOS_TEXTONLY Build without LOADER_BIOS_TEXTONLY since it is now the default. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D52559 --- tools/boot/universe.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/boot/universe.sh b/tools/boot/universe.sh index e97858ff2bcb..80a9cc0b90ff 100755 --- a/tools/boot/universe.sh +++ b/tools/boot/universe.sh @@ -95,11 +95,11 @@ for i in \ dobuild $ta _.boot.${ta}.no_zfs.log "MK_LOADER_ZFS=no" done -# Build w/ LOADER_BIOS_TEXTONLY +# Build w/o LOADER_BIOS_TEXTONLY for i in \ amd64/amd64 \ i386/i386 \ ; do ta=${i##*/} - dobuild $ta _.boot.${ta}.no_zfs.log "MK_LOADER_BIOS_TEXTONLY=yes" + dobuild $ta _.boot.${ta}.no_zfs.log "MK_LOADER_BIOS_TEXTONLY=no" done From nobody Mon Sep 15 21:44:08 2025 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 4cQdpc1PFhz6863d for ; Mon, 15 Sep 2025 21:44:24 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pj1-x1036.google.com (mail-pj1-x1036.google.com [IPv6:2607:f8b0:4864:20::1036]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQdpb569zz3P4g for ; Mon, 15 Sep 2025 21:44:23 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pj1-x1036.google.com with SMTP id 98e67ed59e1d1-329a41dc2ebso4077062a91.3 for ; Mon, 15 Sep 2025 14:44:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1757972661; x=1758577461; darn=freebsd.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=ruKDfFtNRskvG2+OP7WSMtGiYD21uyK/2+J3o5Su2pg=; b=Gf1cJlEci+c1qbqw0zEn4YkWX8QwzUutDovBUWq8WTA6UYCDHlSJqtfYBvg9bahlYv Iexr8kgxM0u5N8mg3cjQ4Ckee3TM2VrrC4zIXAiI5s0NCY2RNFRdWHnWICTte2W5s6Ff zvanAF09Nk4PYYmdHkiU/nLC42RXoyje0Ps8xBOdUNOxN06MQYOR6sPHi9kvxhmdSHoi vtbmrgx7tK7Yn0Xw4SbZbUntcqE9TYpqBerCACILyY9zAVePC5oeAWnknCYuoHLyk38N lbDF83/F6GTSVJRmkvZTI03S6Gn+Eyz+fzWuDxNA/01RZkzbmW8bEeWH6LK2X6DUoA4j nReA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1757972661; x=1758577461; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ruKDfFtNRskvG2+OP7WSMtGiYD21uyK/2+J3o5Su2pg=; b=Ukz34HbnkwCJTgRx/Uy7oVt0wkbeV+WHPqmJFg1SrcNETaxHaZZOoP8GoWk+yCHb8g WQJvBqhdRBe3oc1MSBV/06GaIMgiLHVW2k02Zm7aYfSXctKhUt+wgnuJjCZUsOtXdj8j yz14EikfFxfj7g6kFSy99c6Qpp9lYWJZEGq9YuemSITRWeeWDqCV9KnLGw7RFlQocVP4 1nfimiFX4ZYv+cxcWtz8F+66tPWEKUhjWy+GC+Hsye8SZSsmy6Z1ZRxaCGdVAsx1XlR/ Ippg+UIF6GDe4aE4rM4iXIVYWMpR4XKF1Kxb96Iz18a/lr1f0VbDE5X6gKXZtVC2zxY3 bpuw== X-Forwarded-Encrypted: i=1; AJvYcCVEkf1iRfLLj97SG0URKwSHPWk3218JnhPhFRKDasoRrmNzCKrvsy7Qo0NK9CyPcJjffJAs2TwhQQRZjdhdM+pULZx1@freebsd.org X-Gm-Message-State: AOJu0Yxtsa/T7BC3t2UaWDB/OMHnFQKFqdGT90ZZbpuw82FAYVBbu/+l xeqABTk12P0n3hMYNCsjvRMvO6GOGSXgwGdA0PwErfJBJPOMHuwZu+Fzd7Ny2/Nl8sFRDw+Ogwx DQ07VGbPAdo1cwiyC0goXBRc2IBPirHPBiloGfEi/HA== X-Gm-Gg: ASbGnct6cYGRVoJpdO9DM1MJciZdezhCoKs6fYej64H8bAqViRZ+7OAzHObh7LQoV98 G3INAkcTUQIDyt4XkdXU/gwRypJ7wj7mPrkoEsaJIjD3iTlHl0fznn6RqOeuJ6GOLnEqmON4I+B 8MFDE6BlsTyL27ruubSUDnZ2eRfzIUfBwOfB/DXGkhRRbDV+UgJkIMi9HnuRoGU10RyXUPpKFfo NY1nWul1CN7t2DijKqAmSATr+IdTx9gxF9/mB4GzO3SyysiBQ== X-Google-Smtp-Source: AGHT+IEC1Pl7WKurBGNvpSwBPTJv0jjb1b5CLlBwKtcoZuzdLESPS+XqGaWS7NXUAIQ4BY3MaJtoJ3NdYCkKwhBUthk= X-Received: by 2002:a17:90b:4cc9:b0:32e:59ef:f403 with SMTP id 98e67ed59e1d1-32e59f01354mr7409891a91.17.1757972660668; Mon, 15 Sep 2025 14:44:20 -0700 (PDT) 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 References: <202509150304.58F34BWJ035102@gitrepo.freebsd.org> In-Reply-To: From: Warner Losh Date: Mon, 15 Sep 2025 15:44:08 -0600 X-Gm-Features: Ac12FXybeel4qYdHNfURW_7Wcqwos95JmqPCiZq0fQ_MurWuHmAUoy7iMF3ekkA Message-ID: Subject: Re: git: 5e0a4859f28a - main - iwlwifi: Don't compile for gcc before 14 To: "Bjoern A. Zeeb" Cc: Warner Losh , =?UTF-8?B?SmVhbi1Tw6liYXN0aWVuIFDDqWRyb24=?= , src-committers , "" , "" Content-Type: multipart/alternative; boundary="000000000000f6dd5e063edde708" X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4cQdpb569zz3P4g --000000000000f6dd5e063edde708 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, Sep 15, 2025 at 3:32=E2=80=AFPM Bjoern A. Zeeb wro= te: > On Mon, 15 Sep 2025, Warner Losh wrote: > > > On Mon, Sep 15, 2025, 1:26=E2=80=AFPM Bjoern A. Zeeb w= rote: > > > >> On Mon, 15 Sep 2025, Warner Losh wrote: > >> > >>> The branch main has been updated by imp: > >>> > >>> URL: > >> > https://cgit.FreeBSD.org/src/commit/?id=3D5e0a4859f28ad4869f7a73faf42debc= 355a370bf > >>> > >>> commit 5e0a4859f28ad4869f7a73faf42debc355a370bf > >>> Author: Warner Losh > >>> AuthorDate: 2025-09-14 18:03:16 +0000 > >>> Commit: Warner Losh > >>> CommitDate: 2025-09-15 03:03:45 +0000 > >>> > >>> iwlwifi: Don't compile for gcc before 14 > >>> > >>> gcc 13 and earlier don't have __builtin_bitcountg. The linux wifi > kpi > >>> uses this unconditionally. While in this one use, it might not be > >>> needed, I opted to not compile iwlwifi when building gcc12 or 13 > >> rather > >>> than risk breaking it for everbody else. > >>> > >>> With this change gcc12 builds the kernel. Maybe this will stop > jenkins > >>> email for every commit I make. > >>> > >>> Sponsored by: Netflix > >>> --- > >>> sys/modules/Makefile | 3 +++ > >>> 1 file changed, 3 insertions(+) > >>> > >>> diff --git a/sys/modules/Makefile b/sys/modules/Makefile > >>> index 5315d518afd8..f9fdbca78869 100644 > >>> --- a/sys/modules/Makefile > >>> +++ b/sys/modules/Makefile > >>> @@ -576,7 +576,10 @@ _mlx5ib=3D mlx5ib > >>> ${MACHINE_CPUARCH} =3D=3D "i386" > >>> _ena=3D ena > >>> _gve=3D gve > >>> +# gcc13 and earlier lack __builtin_bitcountg used by linux emulation > >> > >> (a) I beleive there is no __builtin_bitcountg but you mean > >> __builtin_popcountg > >> both here and in the commit message. > >> > > > > Yes. > > > > (b) That was introduced in 7cbc4d875971860d941cc15d7f42e6cfeffbfe66 for > DRM > >> > >> (c) There is no direct use in any LinuxKPI based wireless driver: > >> % grep -r __builtin_popcountg sys/contrib/dev > >> % > >> > >> (4) iwlwifi only uses HWEIGHT32, which was changed by the aforemention= ed > >> commit > >> in LinuxKPI. > >> > > > > Yes. I noticed all that. Didn't see a trivial way to fix it right. > > > > (5) Please do it right and in the place where it is actually defined to > be > >> used, > >> in LinuxKPI, and not here as it can be easily fixed there with an > >> #ifdef or > >> otherwise as there were alternatives on the review if I remember > >> correctly. > >> > > > > Knock yourselves out. I was tired of the CI jobs whining and this was t= he > > easiest way to make that stop. I've got too many things on my plate to > > refine this more. If you want to support older gcc for this driver, > that's > > up to you. The ci jobs have been failing for weeks if not longer > > Okay, will do. > > But gcc12/13 had been whining for months on a lot of things constantly. > I really don't know how a day to do it right would have made a difference= . > I thought this was right since I didn't see a good way to backport the macros to gcc12/13, but your point is well taken. But at the same time, I had a few minutes and this was the last thing in the way. Had there been a bunch more, I'd likely have gotten reviews for everything. Warner --000000000000f6dd5e063edde708 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Mon, Sep 15,= 2025 at 3:32=E2=80=AFPM Bjoern A. Zeeb <bz@freebsd.org> wrote:
On Mon, 15 Sep 2025, Warner Losh wrote:

> On Mon, Sep 15, 2025, 1:26=E2=80=AFPM Bjoern A. Zeeb <bz@freebsd.org> wrote:
>
>> On Mon, 15 Sep 2025, Warner Losh wrote:
>>
>>> The branch main has been updated by imp:
>>>
>>> URL:
>> https://c= git.FreeBSD.org/src/commit/?id=3D5e0a4859f28ad4869f7a73faf42debc355a370bf
>>>
>>> commit 5e0a4859f28ad4869f7a73faf42debc355a370bf
>>> Author:=C2=A0 =C2=A0 =C2=A0Warner Losh <imp@FreeBSD.org>=
>>> AuthorDate: 2025-09-14 18:03:16 +0000
>>> Commit:=C2=A0 =C2=A0 =C2=A0Warner Losh <imp@FreeBSD.org>=
>>> CommitDate: 2025-09-15 03:03:45 +0000
>>>
>>>=C2=A0 =C2=A0 iwlwifi: Don't compile for gcc before 14
>>>
>>>=C2=A0 =C2=A0 gcc 13 and earlier don't have __builtin_bitco= untg. The linux wifi kpi
>>>=C2=A0 =C2=A0 uses this unconditionally. While in this one use,= it might not be
>>>=C2=A0 =C2=A0 needed, I opted to not compile iwlwifi when build= ing gcc12 or 13
>> rather
>>>=C2=A0 =C2=A0 than risk breaking it for everbody else.
>>>
>>>=C2=A0 =C2=A0 With this change gcc12 builds the kernel. Maybe t= his will stop jenkins
>>>=C2=A0 =C2=A0 email for every commit I make.
>>>
>>>=C2=A0 =C2=A0 Sponsored by:=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0Netflix
>>> ---
>>> sys/modules/Makefile | 3 +++
>>> 1 file changed, 3 insertions(+)
>>>
>>> diff --git a/sys/modules/Makefile b/sys/modules/Makefile
>>> index 5315d518afd8..f9fdbca78869 100644
>>> --- a/sys/modules/Makefile
>>> +++ b/sys/modules/Makefile
>>> @@ -576,7 +576,10 @@ _mlx5ib=3D mlx5ib
>>>=C2=A0 =C2=A0 =C2=A0${MACHINE_CPUARCH} =3D=3D "i386"<= br> >>> _ena=3D=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0ena
>>> _gve=3D=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0gve
>>> +# gcc13 and earlier lack __builtin_bitcountg used by linux em= ulation
>>
>> (a) I beleive there is no __builtin_bitcountg but you mean
>> __builtin_popcountg
>> both here and in the commit message.
>>
>
> Yes.
>
> (b) That was introduced in 7cbc4d875971860d941cc15d7f42e6cfeffbfe66 fo= r DRM
>>
>> (c) There is no direct use in any LinuxKPI based wireless driver:<= br> >> % grep -r __builtin_popcountg sys/contrib/dev
>> %
>>
>> (4) iwlwifi only uses HWEIGHT32, which was changed by the aforemen= tioned
>> commit
>>=C2=A0 =C2=A0 =C2=A0 in LinuxKPI.
>>
>
> Yes. I noticed all that. Didn't see a trivial way to fix it right.=
>
> (5) Please do it right and in the place where it is actually defined t= o be
>> used,
>>=C2=A0 =C2=A0 =C2=A0 in LinuxKPI, and not here as it can be easily = fixed there with an
>> #ifdef or
>>=C2=A0 =C2=A0 =C2=A0 otherwise as there were alternatives on the re= view if I remember
>> correctly.
>>
>
> Knock yourselves out. I was tired of the CI jobs whining and this was = the
> easiest way to make that stop. I've got too many things on my plat= e to
> refine this more. If you want to support older gcc for this driver, th= at's
> up to you. The ci jobs have been failing for weeks if not longer

Okay, will do.

But gcc12/13 had been whining for months on a lot of things constantly.
I really don't know how a day to do it right would have made a differen= ce.


--000000000000f6dd5e063edde708-- From nobody Mon Sep 15 21:44:48 2025 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 4cQdq44TBHz6865G; Mon, 15 Sep 2025 21:44:48 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQdq43clnz3PhQ; Mon, 15 Sep 2025 21:44:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757972688; 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=rHY3VPB36PKzs6Pl9351UKgc7vgENOkU/h1inI1u9GQ=; b=aHBo3UaXLdD5Jf6ZeMsuKG2P+RkkMTQGDUWzLWyK8l4qpdmXGvzxkEJL2LDozo+lZ899KD +Ppmw8SXFzALUL18fd2JnQHUJ+mpk0t4dgcM4NWIINyX2pm8j6knCf/RKdTr31JpO4jMx6 3JgSiA9sxDAO1X5bJkOvADh69izBRPElBXovQg5TCKSvWxKP+EIAd2rxgSWK3F2VeE9M/y KFB7GLAScQH38MG9wIAAq2cZ321tqegZLMd9Pm9uyh8EGyrC7/WqUZQLugcRKi7GcA1nTh JdCiemo0Hb7IRsZpXVDceOBVM8ESBLcmRG1AEDg/j0IQahwVEkAcHwVSyh5tig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757972688; 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=rHY3VPB36PKzs6Pl9351UKgc7vgENOkU/h1inI1u9GQ=; b=Sqv6Zqwofn1TFsfa+fOQTzFAORCxMJQXvuGFQTJRi3/QpIeSZlKXL4U0eEg7fP50/t6EPi UP8dvQC/iQEk62iREMusRA+kdxYxVy2aA6X3ML9pUJXxR3iNq7C9Wpl9dbwYZKw8i0ONq3 M7TH+oqVl4/2XA1FtdNt/+PTuMv5ZBhGVUWDPZNfvqZaUykDt0ABoRebZbGL2fpfhoZi9U O73Vm11M8qRAj/1dQgYXFts8BQixyYafh2xR8fU9yJPT8hQAXKiDT2yHVd92U+F5CKt7iG TQpVMVx0PyBuXqn2uWsfAW2fIS8u4xSIBvUWllvDpuLdV3vdHs1iRQkS6Ihvfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757972688; a=rsa-sha256; cv=none; b=t/kcKHwPtmZYaChRUKMhCegeWdJsBDEC3kLCAH1kDvUyKu2nA23hFmPKvscwCcu1eHbQrI qcSFqkFO6ksBZeVvnwFPXf033y/OP0luitf1aAfTA0JvuswHNh6zB3T/Z/dIRljMtukJqO jAM8KItetQIZHmc7egeblhGP0WkZV4qd6EX5HSEOAzwOXAy+BO/ga5hOBRNIHHoLXXbih7 g7dyJShCELaXpyZtB3bZIu62gnju/ELYXpji7ub2gVEtXgXN3K3sBC3ERYscvrerI5jdUa 9tLJWDGnYLbQ9XX/EDa/CC7pqt6brOOKE1j1Z1YXENa+Yy0RBRaKrY7TaQ7ufA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQdq42h0Tz1Bkn; Mon, 15 Sep 2025 21:44:48 +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 58FLim3B037532; Mon, 15 Sep 2025 21:44:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FLimB4037529; Mon, 15 Sep 2025 21:44:48 GMT (envelope-from git) Date: Mon, 15 Sep 2025 21:44:48 GMT Message-Id: <202509152144.58FLimB4037529@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John-Mark Gurney Subject: git: e1bc42cb1551 - main - e1000: fix/complete merge of previous two commits 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: jmg X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e1bc42cb1551ca2a18ef60c38247fb5dc2509ea2 Auto-Submitted: auto-generated The branch main has been updated by jmg: URL: https://cgit.FreeBSD.org/src/commit/?id=e1bc42cb1551ca2a18ef60c38247fb5dc2509ea2 commit e1bc42cb1551ca2a18ef60c38247fb5dc2509ea2 Author: John-Mark Gurney AuthorDate: 2025-09-15 21:29:11 +0000 Commit: John-Mark Gurney CommitDate: 2025-09-15 21:43:54 +0000 e1000: fix/complete merge of previous two commits When fixing the conflicts caused by gallatin's commit and the reviewed patch, I missed this location because it didn't exist when gallatin did their change. Obtained from: Juniper Networks, Inc. --- sys/dev/e1000/if_em.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/dev/e1000/if_em.c b/sys/dev/e1000/if_em.c index 20df466b4e76..247cf9d7fed3 100644 --- a/sys/dev/e1000/if_em.c +++ b/sys/dev/e1000/if_em.c @@ -4815,7 +4815,8 @@ em_if_get_vf_counter(if_ctx_t ctx, ift_counter cnt) case IFCOUNTER_IERRORS: return sc->dropped_pkts; case IFCOUNTER_OERRORS: - return sc->watchdog_events; + return (if_get_counter_default(ifp, cnt) + + sc->watchdog_events); default: return (if_get_counter_default(ifp, cnt)); } From nobody Mon Sep 15 22:09:50 2025 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 4cQfMy44NNz687pF; Mon, 15 Sep 2025 22:09:50 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQfMy3Z1Wz3SsY; Mon, 15 Sep 2025 22:09:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757974190; 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=xzbes/4mD8VASssDDkgL5X5KvDNP8k346Gu8C/EPbhs=; b=mKj2D8A/Fn2cC5Jg0Yf7ErePZk+z+vAX8nNPpsAa7Xc0jfwo1LLIrrJYjY/vLe9yKguq6O VgWpoO5iykKv2o2iUIQXojLkOe99rqWSNKXD7oMGq9YQY78x7D18NK93PavHYXM/k+g0bS rTxOxFOPafs6wHpGVA2RScNQkxmPNM7Rl4Jfww2oTsDYmLLhPDcB72VzfbfEeoHmAh52GR xZ3mONvQDBXTvRTsphVqe9WH7r9N5tdKvBP4KR0QkALnsenhTfMj7cKMAO+aobQnAjbXIG TAclTxcL9bm4y3BZtGXDFuIntl8RIJ694L90h3q1Hx3o6mTG9rtokytgECxtsQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757974190; 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=xzbes/4mD8VASssDDkgL5X5KvDNP8k346Gu8C/EPbhs=; b=uHVDGpNIevmOEnjnUYtEyaY6Huv2gy2tgIGbWlxWoMgGXfchthbQqtlfTGaKRiZT8U1e5c jnJHRAMCdK9dA9AVU+VHlu1n9ycAGbYL61nzpA54KI38Xng+F0oUuM5kNxdM4V5/yeJ0q+ 3oZ268qsjZzFprf03uTlUEjoy50J4Ju04L4d2Bbe0F5TT9XHC94aQwNo0SL7khBvCxyv3J eHU/rqDtu/85hmdOjkU7l7kKNk61eRI9PQY5CHGPi/Kaqxrablr/+Zh/i3nQf7N+m8V1S+ JLVQnQsf4/0qG34xybtBg3vFRxUQAdv48HYaxKDgxbSydSCATIyMpsJzsaRf9g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757974190; a=rsa-sha256; cv=none; b=WeILlNWkaXHtRFnj/k4jtLWVKMhN5mDFQomDTjSMDVFDZeo0K9T8+mqA6QIbETdxqdrhYY S+4oz9qlPDBEzNKbfgGY3AMWCRSXhvFWy/SSHg1DuZJBHAUkRyXHga8M3KBfglioFuUW+9 tRw4svMs0L0M75Vq5C3CW6OG2AlDNbVVK2hqyFbOerUOGbVJKKczo4Jmc/tDQCk/3IGil1 TTB3FFn/TVpvOWYzw+sASHOFLdhojCE3i69CDKtAgKm25zvZrbni6gtrSoBSvdK8dk/JUv FclKQGSTwdHpBxXYL+EsngxAWEqW2eaYX/7M2RECJfWgPOtYYw6IEHsaR2Xt+g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQfMy2s0kz1Blv; Mon, 15 Sep 2025 22:09:50 +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 58FM9of5077665; Mon, 15 Sep 2025 22:09:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FM9o0S077662; Mon, 15 Sep 2025 22:09:50 GMT (envelope-from git) Date: Mon, 15 Sep 2025 22:09:50 GMT Message-Id: <202509152209.58FM9o0S077662@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alex Richardson Subject: git: 90234b9dd8cb - main - riscv: Provide prototypes for fpgetmask/fpsetmask 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: arichardson X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 90234b9dd8cb293f3eb9ce3765b17ebc05f9201a Auto-Submitted: auto-generated The branch main has been updated by arichardson: URL: https://cgit.FreeBSD.org/src/commit/?id=90234b9dd8cb293f3eb9ce3765b17ebc05f9201a commit 90234b9dd8cb293f3eb9ce3765b17ebc05f9201a Author: Alex Richardson AuthorDate: 2025-09-15 22:07:32 +0000 Commit: Alex Richardson CommitDate: 2025-09-15 22:08:14 +0000 riscv: Provide prototypes for fpgetmask/fpsetmask These functions are stubs that do nothing but are called by some software and not providing them results in implicit function declaration errors. This was missed in D25740. Reviewed by: #riscv, mhorne MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52035 --- sys/riscv/include/ieeefp.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sys/riscv/include/ieeefp.h b/sys/riscv/include/ieeefp.h index 03a96e8a000f..84b554a04c65 100644 --- a/sys/riscv/include/ieeefp.h +++ b/sys/riscv/include/ieeefp.h @@ -5,4 +5,9 @@ /* TODO */ typedef int fp_except_t; +__BEGIN_DECLS +extern fp_except_t fpgetmask(void); +extern fp_except_t fpsetmask(fp_except_t); +__END_DECLS + #endif /* _MACHINE_IEEEFP_H_ */ From nobody Mon Sep 15 22:09:51 2025 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 4cQfMz4mJ3z687gQ; Mon, 15 Sep 2025 22:09:51 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQfMz3y8Qz3SvJ; Mon, 15 Sep 2025 22:09:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757974191; 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=WaVKwC3xJT7jb7h9KYtc/n00+TBB+iRRZfuMMjnQeTE=; b=TF/oFUJTIkODpE/wUMz3nJmViJkEVjLzUCUy3AIPy0mQLM7PyeEnCLS9iQ8uuWAVh6acsW edoEWNh3znzTqHd5lbGrTt+gng7LWHcrXehygKHG8/9Q77i9pH1I7MCg/vzJjwyV2/KA06 qO6TkUZI928wdRtJ+n1gOKjFMF73f5bSTQBjCD7lQatYcqosEDNaB7h041yh+YGmthBN9p G1Nw5P0cbuQhrizn5QtocKFMv7aadpMREZ3mDGNG38MF9nUTyiMUf+pEHzBdCHl48c0RQb K2qKt87AqEmqOTZCmKRaQOiELlHMjnzvYwtBW5CqNrlp/PfryKKBLgFaiH647A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757974191; 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=WaVKwC3xJT7jb7h9KYtc/n00+TBB+iRRZfuMMjnQeTE=; b=nq0ASSh2NIdukk0hS0TJAz0RhCd+ooUrjRmy2ztuaW2S7ArRBPKRoYgcjODhEVcvBUHBgG beKwg2rqf4AiUP/mcPJKHk75qOfsAEsRh/dwEGZ0k6gphrTMfAdpKb7TsxIcPwfQ3tMYB+ GtbtvcIugFWs9HkgxnuEGS8UZshtku+pnNj/I9scFmUJaSKv91MyeegBrq8kvY28mTWxHp VaSPcQ5nxcOYLU47Ea8fQ/JAw6Ov1yiampen3zWTOkqlesqT01EsPNi6g4slERjjFZAmOK 8/mU3DPPTumBEPXcG9KZA1NOp7TNgf4NxLrHqBKjoDzcTVeRgZ3FYXjoTm/Dew== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757974191; a=rsa-sha256; cv=none; b=DSczGVBF6JuS05Tf36tdGUGUpYuWMeX7rZ/JpvucYQNZuTX8ANPIygTptAbs6GsLzUXIKU rginfxZQF2imZOz7M4RU7+fBmSTnGxJbiGi6yiycWgIjkq0f/Zkmu53xePvyBmL4xnuml1 CXEVvmdjnHw+j3TFydxQXZ6YMswv0CsmHTeg+VzOcFPUmglUPVzvZrhJf5B8NeaMxgELLB Q8S5OEHjYcWyRWGMW/0gnG4liPqCHja8voD4BnlNdOGZlYexOYK0Ti76H33gfUT5SbbtZq 3ndPNqW8Y2PZ2pSrb2FTB5uj+VN8aJabNYjHpcZI0P46baW+nxLzx3CxmVaeWw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQfMz3X0Nz1Bs0; Mon, 15 Sep 2025 22:09:51 +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 58FM9pKd077704; Mon, 15 Sep 2025 22:09:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FM9ptY077701; Mon, 15 Sep 2025 22:09:51 GMT (envelope-from git) Date: Mon, 15 Sep 2025 22:09:51 GMT Message-Id: <202509152209.58FM9ptY077701@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alex Richardson Subject: git: 969be39fb3ca - main - if_ovpn.c: fix use of uninitialized variable 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: arichardson X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 969be39fb3caf4272f128dbf3267ceba5966a6ce Auto-Submitted: auto-generated The branch main has been updated by arichardson: URL: https://cgit.FreeBSD.org/src/commit/?id=969be39fb3caf4272f128dbf3267ceba5966a6ce commit 969be39fb3caf4272f128dbf3267ceba5966a6ce Author: Alex Richardson AuthorDate: 2025-09-15 22:08:43 +0000 Commit: Alex Richardson CommitDate: 2025-09-15 22:08:44 +0000 if_ovpn.c: fix use of uninitialized variable In case we use OVPN_CIPHER_ALG_NONE, the memcpy will attempt to copy 0 bytes from an uninitialized pointer. While the memcpy() implementation will treat this as a no-op and not actually dereferece the undefined variable it is still undefined behaviour to the compiler and should be fixed. Found by building with clang HEAD Reviewed by: kp MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52543 --- sys/net/if_ovpn.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/net/if_ovpn.c b/sys/net/if_ovpn.c index fe015632f33e..1c18baac3417 100644 --- a/sys/net/if_ovpn.c +++ b/sys/net/if_ovpn.c @@ -904,9 +904,11 @@ ovpn_create_kkey_dir(struct ovpn_kkey_dir **kdirp, kdir->cipher = cipher; kdir->keylen = keylen; kdir->tx_seq = 1; - memcpy(kdir->key, key, keylen); + if (keylen != 0) + memcpy(kdir->key, key, keylen); kdir->noncelen = ivlen; - memcpy(kdir->nonce, iv, ivlen); + if (ivlen != 0) + memcpy(kdir->nonce, iv, ivlen); if (kdir->cipher != OVPN_CIPHER_ALG_NONE) { /* Crypto init */ From nobody Mon Sep 15 22:35:23 2025 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 4cQfxR6d7wz689nk; Mon, 15 Sep 2025 22:35:23 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQfxR54S4z3Wpy; Mon, 15 Sep 2025 22:35:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757975723; 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=gdGWKj5NI/svEmvfuD9OL2ROGdlSbmZTCKwWZgQ1QvY=; b=b+tWpguDPIRBhC3kOZGlyLMHm2cpLGWLoYKDUFQ7g1xN6yCsdJwPaypOSQsFKExkdtlVc0 Z4k632Sfa3OMFasCfp0PDcyaXXx/AHlC1V/RJoePPq0FGAEXmH+7SPpUySyNeSQ8XeqJh2 uFZ6bQz1c45KTITvK00bQcWEddLogHQZ+CLk1XVDLCybH7vL1+YN3Pn2U6eda1mgYbnMo4 UHtAhN2M1YgBW6f62li+fT3vs7Re8TI4LFnMMydcnNmoNe7zEoOPiJmlRdprxe64GaFIiA estMwaDEaP7nypCIuIeTi1NbZcKeIx21lGa1GyKsfi5MDfZVfhkVaHlurBc12g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757975723; 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=gdGWKj5NI/svEmvfuD9OL2ROGdlSbmZTCKwWZgQ1QvY=; b=JNftfUg1ma0xrOuddASEbfm8yCxlXo4O+R1BUU9jazHJxSJq2NBRZwVZ1uG7xcNY1NCIZQ H1J5OVZ+Lx+Sg233d2Vxt5v6vawWxkZunRNEly70aL21t6XR2eBRaU5yg6WmlNhuq8JvOn AosjQVcAuz8SUjCoP5heSXG817jDHB0VjeFXf1wIVUO2G0TphnW0s1iFop4R76evMbP62c Ll0HUL0b2reDRt3itLFgtHpxrPfDwEl/km71vp4rROs9rC2IwfnZA3nfcVKGRbG/G9u6bF Tw/ziEDZrYnqq7UYPRbHdF8ekJUFuq3y3l+ikfpPeywMcrrgzwto3UBhfvHGfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757975723; a=rsa-sha256; cv=none; b=pvBgRgp25iCKopSfXFfjWN4t+OUxR1k9JmdTiJ4/mQ5/rTZHSu1el/24soNLdM7L/B0QBl FD32vJTZZctp4ZvU+ROXZ/QsJ6TLKS5YvusJoADbL6Qnz2XM2qgWAyGiSkBsJS2/SUY+2Z 7kjcIDg1Ux6cnN5zGUKlc2CoOqPc5k3YqUWXVhdahVUaFakUyxcWPwM8savOFWPeZqvLVj aGpyM0uEXNJ8l/GQ5/+LY/D4CGzMnfBtKG4ysB7jOIau42A2URSRnjHGC6sH6kd2PMzFXy HJj1SHGkmqJ8cw4U11m3z7+Vd9KNjqSzdlxN07n6FznHgSXqfnFi653PIkFGVg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQfxR4gSKz1Chr; Mon, 15 Sep 2025 22:35:23 +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 58FMZNa4031244; Mon, 15 Sep 2025 22:35:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FMZNu5031241; Mon, 15 Sep 2025 22:35:23 GMT (envelope-from git) Date: Mon, 15 Sep 2025 22:35:23 GMT Message-Id: <202509152235.58FMZNu5031241@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alex Richardson Subject: git: d61c75f634cf - main - libc++: avoid use of deprecated builtin 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: arichardson X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d61c75f634cf52fdef9590601d881f85275eee9a Auto-Submitted: auto-generated The branch main has been updated by arichardson: URL: https://cgit.FreeBSD.org/src/commit/?id=d61c75f634cf52fdef9590601d881f85275eee9a commit d61c75f634cf52fdef9590601d881f85275eee9a Author: Alex Richardson AuthorDate: 2025-09-15 22:10:07 +0000 Commit: Alex Richardson CommitDate: 2025-09-15 22:11:08 +0000 libc++: avoid use of deprecated builtin This pulls in LLVM commit accfbd4cb327411ad66c0109ba1841482b871967 to avoid the use of __libcpp_is_trivially_relocatable. This fixes building FreeBSD libc++ with clang HEAD as of today. Original commit message: [libc++] Replace __is_trivially_relocatable by is_trivially_copyable (#124970) The __is_trivially_relocatable builtin has semantics that do not correspond to any current or future notion of trivial relocation. Furthermore, it currently leads to incorrect optimizations for some types on supported compilers: - Clang on Windows where types with non-trivial destructors get incorrectly optimized - AppleClang where types with non-trivial move constructors get incorrectly optimized Until there is an agreed upon and bugfree implementation of what it means to be trivially relocatable, it is safer to simply use trivially copyable instead. This doesn't leave a lot of types behind and is definitely correct. Reviewed by: dim MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52529 --- .../libcxx/include/__type_traits/is_trivially_relocatable.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/contrib/llvm-project/libcxx/include/__type_traits/is_trivially_relocatable.h b/contrib/llvm-project/libcxx/include/__type_traits/is_trivially_relocatable.h index c0871731cc00..9b0e240de55f 100644 --- a/contrib/llvm-project/libcxx/include/__type_traits/is_trivially_relocatable.h +++ b/contrib/llvm-project/libcxx/include/__type_traits/is_trivially_relocatable.h @@ -11,7 +11,6 @@ #include <__config> #include <__type_traits/enable_if.h> -#include <__type_traits/integral_constant.h> #include <__type_traits/is_same.h> #include <__type_traits/is_trivially_copyable.h> @@ -23,8 +22,11 @@ _LIBCPP_BEGIN_NAMESPACE_STD // A type is trivially relocatable if a move construct + destroy of the original object is equivalent to // `memcpy(dst, src, sizeof(T))`. - -#if __has_builtin(__is_trivially_relocatable) +// +// Note that we don't use the __is_trivially_relocatable Clang builtin right now because it does not +// implement the semantics of any current or future trivial relocation proposal and it can lead to +// incorrect optimizations on some platforms (Windows) and supported compilers (AppleClang). +#if __has_builtin(__is_trivially_relocatable) && 0 template struct __libcpp_is_trivially_relocatable : integral_constant {}; #else From nobody Mon Sep 15 22:35:24 2025 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 4cQfxS6gkrz689Zb; Mon, 15 Sep 2025 22:35:24 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQfxS5qSpz3X2J; Mon, 15 Sep 2025 22:35:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757975724; 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=LBn9l8SAlGu9uAX7P5pUHWHCpqCiQhr0nWPla4xE3Tw=; b=ESn+IoQcufYGatiZxxShxwfJbd+BIcqR+0q9tH19iWA15QB4+jWCseokEq8/egTPI5wVsR ZbnHAGIKvYUdKXz2ehx0xO1cis7J4uWJbpTLI/1C91ktMQiVME3zxKPIbTjkFVOtxoFP8C lVHIqIgErjkGPVqJmZZEz8zITWmKPtW5UqYktUTlI0UIg7Ku4zPJZJYOrMtSl13Z0Qi82Q feEzsQq/2O33vvui0S4rwgBGO0w45uvSpQJrrpGmogjrZnGCIwxCZEo9oTcCzLghCxn8b3 Q4HlqIM8iCzY0EqJqYBF5e6hAlGPfWKnPR/mYF+V6tq3cZNDsWXZG2S0sJ74wA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757975724; 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=LBn9l8SAlGu9uAX7P5pUHWHCpqCiQhr0nWPla4xE3Tw=; b=UDM9Lr+QSMK3lazhSAIR1wQEhNAZaj850GzTlAV1M8FfXiHED9XhU4ZkXlhede7tG/Q8Qm McdTXJcxk7cEqJiveonLE9u32N+6yWD4bR6Af/OUIPuZspsmqakhbkfa5+wbOXsQDqY1Ol cvLt3VWQUhGm/ARnXPSilh6A5WOhEwanC5FkJaEf7o3HX9frMCCxm2nvaawvEGMVLG7aPl wj4BQBziZ6J1+iMcMNuYlu7Y6RD/vFXTod7clQXUS5elykb3yin3mEhBTKWGh52rtg8EAL ex5AVkHoBVzn9m03PiENmo/mPak93zlsFBba2r3p7Tmv72RcbdAvKZ9V2gkJyg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757975724; a=rsa-sha256; cv=none; b=EAWUIJgsvFriwUjbqmLzQ3JfJIQ7xNTgzN1ZTmk6S/Zi22j6ZR5YZp45k47JFJ/xan01E+ nsAMRKxTMywshDk5w5DB/hjuiDYjV0AtafYp2eETUCicQhkq/8krQ82Z56PU5LxUpNUASK Gpo/KN2ut2gHzqqgMvTeOidVq64BcuaMZ5CC/A32+6Es2xsK5xdkDnlZ1U/+aYiVlO4xqW Ibb2SZPyqmaEuZZ30zKch/XwvquTfjht3UyrWbfHcAlfjgr8JYNb123n/reGyINAZiBdU1 MgJLoZsP0wn99GDyZIUkrck2J3oOO5ZDdpYp4eeQ91zPCnfY/JwxsHmYT0uXzQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQfxS5KzZz1Cf2; Mon, 15 Sep 2025 22:35:24 +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 58FMZOpS031277; Mon, 15 Sep 2025 22:35:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FMZOib031274; Mon, 15 Sep 2025 22:35:24 GMT (envelope-from git) Date: Mon, 15 Sep 2025 22:35:24 GMT Message-Id: <202509152235.58FMZOib031274@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alex Richardson Subject: git: dee76cf2f3da - main - libc++: avoid use of deprecated __reference_binds_to_temporary 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: arichardson X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: dee76cf2f3dace6290ccab07c2db17355994e70f Auto-Submitted: auto-generated The branch main has been updated by arichardson: URL: https://cgit.FreeBSD.org/src/commit/?id=dee76cf2f3dace6290ccab07c2db17355994e70f commit dee76cf2f3dace6290ccab07c2db17355994e70f Author: Alex Richardson AuthorDate: 2025-09-15 22:11:39 +0000 Commit: Alex Richardson CommitDate: 2025-09-15 22:12:45 +0000 libc++: avoid use of deprecated __reference_binds_to_temporary This was removed in upstream libc++ in commit 437ad06f762ab07d89badecdd20627db200b98d3, but as this does not apply cleanly to the current repository, I am applying the equivalent change in a minimally invasive way. This is needed to build with latest clang HEAD as of today. Reviewed by: dim MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52530 --- contrib/llvm-project/libcxx/include/tuple | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/libcxx/include/tuple b/contrib/llvm-project/libcxx/include/tuple index 081b90c7bbec..1d39974d5a6b 100644 --- a/contrib/llvm-project/libcxx/include/tuple +++ b/contrib/llvm-project/libcxx/include/tuple @@ -302,7 +302,9 @@ class __tuple_leaf { template static _LIBCPP_HIDE_FROM_ABI constexpr bool __can_bind_reference() { -# if __has_keyword(__reference_binds_to_temporary) +# if __has_keyword(__reference_constructs_from_temporary) + return !__reference_constructs_from_temporary(_Hp, _Tp); +# elif __has_keyword(__reference_binds_to_temporary) return !__reference_binds_to_temporary(_Hp, _Tp); # else return true; From nobody Mon Sep 15 22:35:25 2025 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 4cQfxV67S7z689jD; Mon, 15 Sep 2025 22:35:26 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQfxV0FSPz3Wq5; Mon, 15 Sep 2025 22:35:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757975726; 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=L0Uor2HiTElHq5kSTPunLw02oHsPNFjHD0oFi9SsTcs=; b=w3Y17rbi81IEqXu82kP6UtfVNbz80nM0+PDDFXgb9vevgGwJMT3EIDBqe//RZ0UQKynxb2 fB0Svqf6gVWjZ0bSqXV3TtuHi0RlcjXzj3b/88re6LMydwvAH3IxRYPSbzRvaElN2e8L/J nwUcwWf9siQEcNsTfQhJm2m3t47iRV8BzJ/Kxzkt9Iukq1JyzbHztr4Q9keIaqjCE2Z7Sc hynhU3D2S7mIphLPXD/7erH8XvtTfE7p9PohBPd2GVdGup6kGggR7zvn/CVLmyPVU4gKDf FIqC9n1GyQnAkJkQRRktbIqtQL+kgOZc9faNODQR4laYC2ruO8nKlop62+quag== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757975726; 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=L0Uor2HiTElHq5kSTPunLw02oHsPNFjHD0oFi9SsTcs=; b=Q6sFfXwXG7nmkXcGFmWkbbch4vdvuanU8zc4qUGtr4lTMVlvCh40cTaQyNyKPU5gjv8axv pcGDNhEJcXQ2UwoEAcnRabEjLHtapBPxAMa7hBg+xfCRtFvCL9ZPNRrBCL6+M6IzLW5rhl DB9AQpokPmvhKkRJazQ2jHXyDGEwL3P37Xqg4WItqp5HBKchUzkZWyvl5q3DogQFt4aZN5 D2728d0kW7NiltJnqJezG7N/7kGSCYvLIXxrt1gxUb20Oaq/kSPhRsLDWZpKFdoxMqtFV1 4Va6QNMuasmn9sz3eyx475onuV8n4hE8GH8Pqb4FcSoewbuHsPAuiGeWZ+m6zA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757975726; a=rsa-sha256; cv=none; b=rPe+fKuhy1Uh0yisvRaNh8uM1Ur21cb/sYECJXCVntLiM+/AWhr0ZgmxfT4Bl3eDeuMTVH obBntDikZcfX1YhEPkLDgrmR8+LQhQrOQ+19HK7zxbS3492B9SJzs1HgayGGeGNZP/m0yS ys5rX4FJT39jFn9upUJiye8/mcsIALAI7Vy/4MmJbaIy2ub0pPGMW1ECWmj+jsoTHcqT7f noS6/+eCLep8PXPi0EIGaeEHHX0wIwXb2pADBw1O+P++OLvEGot3kxoQcczmzUhs0DYS6+ H5G3kZynexRl9/8gX12q0YAII55JST0SU7AvZxIGp82zLTIDjP/uhumDUY/Duw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQfxT6Gf0z1Cf3; Mon, 15 Sep 2025 22:35:25 +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 58FMZPWV031316; Mon, 15 Sep 2025 22:35:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FMZPKX031312; Mon, 15 Sep 2025 22:35:25 GMT (envelope-from git) Date: Mon, 15 Sep 2025 22:35:25 GMT Message-Id: <202509152235.58FMZPKX031312@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alex Richardson Subject: git: 086ce467adec - main - libc++: Fix deprecation warnings with latest clang 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: arichardson X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 086ce467adec42d58414fdb4d54c2b6819cf0c07 Auto-Submitted: auto-generated The branch main has been updated by arichardson: URL: https://cgit.FreeBSD.org/src/commit/?id=086ce467adec42d58414fdb4d54c2b6819cf0c07 commit 086ce467adec42d58414fdb4d54c2b6819cf0c07 Author: Alex Richardson AuthorDate: 2025-09-15 22:13:46 +0000 Commit: Alex Richardson CommitDate: 2025-09-15 22:13:46 +0000 libc++: Fix deprecation warnings with latest clang Latest clang has become more strict in diagnosing deprecated decls, so pull in LLVM commit 9feac2cbd0d80927ce9a8b4c3e810d2b81802d55. Original commit message: [libc++] Improve deprecated diagnostic guards. Recent Clang-21 builds improved the deprecated diagnotics. This uncovered missing guards in libc++ internally. Reviewed by: dim MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52531 --- contrib/llvm-project/libcxx/include/__functional/binary_function.h | 5 ++--- contrib/llvm-project/libcxx/include/__functional/unary_function.h | 5 ++--- contrib/llvm-project/libcxx/include/__functional/weak_result_type.h | 2 ++ contrib/llvm-project/libcxx/include/__memory/allocator_traits.h | 2 ++ 4 files changed, 8 insertions(+), 6 deletions(-) diff --git a/contrib/llvm-project/libcxx/include/__functional/binary_function.h b/contrib/llvm-project/libcxx/include/__functional/binary_function.h index ddee3b170311..18879f65112b 100644 --- a/contrib/llvm-project/libcxx/include/__functional/binary_function.h +++ b/contrib/llvm-project/libcxx/include/__functional/binary_function.h @@ -39,11 +39,10 @@ struct __binary_function_keep_layout_base { }; #if _LIBCPP_STD_VER <= 14 || defined(_LIBCPP_ENABLE_CXX17_REMOVED_UNARY_BINARY_FUNCTION) -_LIBCPP_DIAGNOSTIC_PUSH -_LIBCPP_CLANG_DIAGNOSTIC_IGNORED("-Wdeprecated-declarations") +_LIBCPP_SUPPRESS_DEPRECATED_PUSH template using __binary_function = binary_function<_Arg1, _Arg2, _Result>; -_LIBCPP_DIAGNOSTIC_POP +_LIBCPP_SUPPRESS_DEPRECATED_POP #else template using __binary_function = __binary_function_keep_layout_base<_Arg1, _Arg2, _Result>; diff --git a/contrib/llvm-project/libcxx/include/__functional/unary_function.h b/contrib/llvm-project/libcxx/include/__functional/unary_function.h index 69b1bc94220a..d46df2e86fbd 100644 --- a/contrib/llvm-project/libcxx/include/__functional/unary_function.h +++ b/contrib/llvm-project/libcxx/include/__functional/unary_function.h @@ -36,11 +36,10 @@ struct __unary_function_keep_layout_base { }; #if _LIBCPP_STD_VER <= 14 || defined(_LIBCPP_ENABLE_CXX17_REMOVED_UNARY_BINARY_FUNCTION) -_LIBCPP_DIAGNOSTIC_PUSH -_LIBCPP_CLANG_DIAGNOSTIC_IGNORED("-Wdeprecated-declarations") +_LIBCPP_SUPPRESS_DEPRECATED_PUSH template using __unary_function = unary_function<_Arg, _Result>; -_LIBCPP_DIAGNOSTIC_POP +_LIBCPP_SUPPRESS_DEPRECATED_POP #else template using __unary_function = __unary_function_keep_layout_base<_Arg, _Result>; diff --git a/contrib/llvm-project/libcxx/include/__functional/weak_result_type.h b/contrib/llvm-project/libcxx/include/__functional/weak_result_type.h index ad7a8395186c..488fec9dac21 100644 --- a/contrib/llvm-project/libcxx/include/__functional/weak_result_type.h +++ b/contrib/llvm-project/libcxx/include/__functional/weak_result_type.h @@ -77,6 +77,7 @@ struct __maybe_derive_from_unary_function // bool is true template struct __maybe_derive_from_unary_function<_Tp, false> {}; +_LIBCPP_SUPPRESS_DEPRECATED_PUSH template ::value> struct __maybe_derive_from_binary_function // bool is true : public __derives_from_binary_function<_Tp>::type {}; @@ -99,6 +100,7 @@ struct __weak_result_type_imp<_Tp, false> template struct __weak_result_type : public __weak_result_type_imp<_Tp> {}; +_LIBCPP_SUPPRESS_DEPRECATED_POP // 0 argument case diff --git a/contrib/llvm-project/libcxx/include/__memory/allocator_traits.h b/contrib/llvm-project/libcxx/include/__memory/allocator_traits.h index c5fcc89327b8..f3e327edda12 100644 --- a/contrib/llvm-project/libcxx/include/__memory/allocator_traits.h +++ b/contrib/llvm-project/libcxx/include/__memory/allocator_traits.h @@ -40,6 +40,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template \ struct NAME<_Tp, __void_t > : true_type {} +_LIBCPP_SUPPRESS_DEPRECATED_PUSH // __pointer template { using type _LIBCPP_NODEBUG = typename pointer_traits<_Ptr>::template rebind; #endif }; +_LIBCPP_SUPPRESS_DEPRECATED_POP // __void_pointer _LIBCPP_ALLOCATOR_TRAITS_HAS_XXX(__has_void_pointer, void_pointer); From nobody Mon Sep 15 22:35:26 2025 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 4cQfxW4K9Jz689Zf; Mon, 15 Sep 2025 22:35:27 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQfxW0Sywz3X45; Mon, 15 Sep 2025 22:35:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757975727; 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=GP5PWxMNN7fG9Mj8rTGPsFM40X8nJcxA/rv5rg7XSuY=; b=axK8lLg/8MIJl+99zy7xp+rKsJp8jdO+pR5l9G0XbbGDNpqbRUBH4In9lHA/Bb3TT+peri g+JPPtPxsFnJ2bLCnGkc87rlgmWbK6AGAXoceNbiGCbKzd2simKNaqCaLFXfFYvBY4HWtG xdXAQkiwbpAWMLT2Hah+dNskR4AToib8cCntPEH6KSbmzt4oDddYkjwwQn0x9N1DnE3HaA eDzM2XgGNsOEVg2Z63qUA27OdiFhJEAmtYUr3GhxXXbgBQulPHtf9+Ujh/fvayVBve35KM gbaSiGRVSeciQSUsML+S+CO0/2rKsx7jVLxKwvqnFrnsNmzlMlU62ssFbS8gAw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757975727; 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=GP5PWxMNN7fG9Mj8rTGPsFM40X8nJcxA/rv5rg7XSuY=; b=M2AK2fLyFFOd7e2VSpGxUcTG1SNAYwVnm6wj1NH3/WZOhZ3nMgh6koRaNOgRRpiN5RJULn 4/DNjOLIjGQQuZvATylHXKLg54On04JmokNofnAcjBO0UhBD+sthp1yQ8MfdU8FAROBDAA qbrciDQYhVvQiO3vXIeBK5jdyMCtUxAVk/IP/79v+zV1J2rQlYkKbfxskNzl/TSbiBOQ6G klWoQcSR2N3jKDKtbAkIRywP/mGLymqW2CjK0nMS80hjq5uGcB6jO+zWkXiO2LxKfBYGsa rINnzLhLPCnmEiK5ecNSk0liVZZCYy2mq9uCspaQOtjP1wP//zpNzmnWSnXc/w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757975727; a=rsa-sha256; cv=none; b=HipMfrkajIe0IIuTpyI+mEpCMRbZS2ZEMQQENixV5YPsbq4ju9umZsqM5I/Hsj029fiF7/ t1PdxspGzEr+R12P7Zk/aO6wvuT6IKW8bsdTyJiISWewHJTJ/JWUTk1wRdAhgMA4MCvZOV 7Yh7hjLsL+U/CbYu8PGq1o1vx0UO8nqR5o626RPcznbD5K3w/flrciqJiIVzfY3ssMZ1MY x0jGXQ7KY+QYtqyz5fiu//weRUy4uHT+FJa+L71o0LzeIMwnoD4VtcEZbm6GjTlMIV4jnS VDLu2h/WU8EbNxmH8pCXaG97tsYUiWKzzEnMHrMpaLc1qtasCJr+jEeRGGnOWA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQfxV6mFFz1Cl2; Mon, 15 Sep 2025 22:35:26 +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 58FMZQqC031353; Mon, 15 Sep 2025 22:35:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58FMZQjR031350; Mon, 15 Sep 2025 22:35:26 GMT (envelope-from git) Date: Mon, 15 Sep 2025 22:35:26 GMT Message-Id: <202509152235.58FMZQjR031350@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alex Richardson Subject: git: 34a006eaa39c - main - libc++: silence -Wnontrivial-memaccess warning with newer clang 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: arichardson X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 34a006eaa39ceb6b0a96fa386c9b9b8a44681979 Auto-Submitted: auto-generated The branch main has been updated by arichardson: URL: https://cgit.FreeBSD.org/src/commit/?id=34a006eaa39ceb6b0a96fa386c9b9b8a44681979 commit 34a006eaa39ceb6b0a96fa386c9b9b8a44681979 Author: Alex Richardson AuthorDate: 2025-09-15 22:14:18 +0000 Commit: Alex Richardson CommitDate: 2025-09-15 22:14:18 +0000 libc++: silence -Wnontrivial-memaccess warning with newer clang Apply part of LLVM commit 71315698c91d0cda054b903da0594ca6f072c350 to silence the -Wnontrivial-memaccess warning that is triggered any time this function is instantiated by user code. This fixes another buildworld failure with Clang HEAD. Original commit message: [clang] Warn about memset/memcpy to NonTriviallyCopyable types (#111434) This implements a warning that's similar to what GCC does in that context: both memcpy and memset require their first and second operand to be trivially copyable, let's warn if that's not the case. Reviewed by: emaste, dim MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52534 --- .../llvm-project/libcxx/include/__memory/uninitialized_algorithms.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/libcxx/include/__memory/uninitialized_algorithms.h b/contrib/llvm-project/libcxx/include/__memory/uninitialized_algorithms.h index 7475ef5cf85d..79cab80dcf73 100644 --- a/contrib/llvm-project/libcxx/include/__memory/uninitialized_algorithms.h +++ b/contrib/llvm-project/libcxx/include/__memory/uninitialized_algorithms.h @@ -642,7 +642,8 @@ __uninitialized_allocator_relocate(_Alloc& __alloc, _Tp* __first, _Tp* __last, _ __guard.__complete(); std::__allocator_destroy(__alloc, __first, __last); } else { - __builtin_memcpy(const_cast<__remove_const_t<_Tp>*>(__result), __first, sizeof(_Tp) * (__last - __first)); + // Casting to void* to suppress clang complaining that this is technically UB. + __builtin_memcpy(static_cast(const_cast<__remove_const_t<_Tp>*>(__result)), __first, sizeof(_Tp) * (__last - __first)); } } From nobody Tue Sep 16 01:11:29 2025 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 4cQkPY6rd7z67gZB; Tue, 16 Sep 2025 01:11:29 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQkPY6Jtzz3p2v; Tue, 16 Sep 2025 01:11:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757985089; 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=7LfE/pbUqgF079w3NOTleNCb7E7puKnoJR2IYERtHpk=; b=Kn92f/fr49Y7nYmwcIdanUlfOu/5PXmrgwwHXA70pBpw4i9KDRxNjuiaOKQKGVlI8dcxzR LuDfNZJBVymAPau6xt/qRcH5yrVS3FBz36Q2OvhEIyI9fBxET6pTMPFTTb1ekuUzZNHlfb TpkTNTQeOTvv5bh8R6j5oIFfxm2M2/Pc4fgvb8s7mLJ4Y5Vf/oureoNqAMw+7s2e7lUrfM XfnMsqaZAUeC3UlWoNH9Ooz8ULNe/M1jo3naW26VjZjtaB72ZSTPN7iHdUhk6T/ZqgxRjy WOPZkGV7i7S5xKZa9X1OZJO8Ow6nJMTYMCeEzGdHv+NZLkFi+KhT2pss5L9aFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757985089; 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=7LfE/pbUqgF079w3NOTleNCb7E7puKnoJR2IYERtHpk=; b=oQy7E59znQ8k0bDVYUjALJLoieLfjUs40hSNBoRsf9X8J4mwrgDv7uxhRADipvcScP9kOF kYjv+f/5D6GW6qW33Eilc1yZTM2lpIlY1pKD75U0OoNe0X83YHqQTOayoG+RdTUiVVqNXB S0DOG/LjZ0r9GYgURlZaCRPPGawZst8XLp4WBVrYrmYTJPq/ilv+LQizLHfTPWHZcNI35b JfFnBmLpD1jAjzsCCoXU1IlTzHGbZ59V7GWCov7eTnSWAGgjewJqyahbzdiXQZpsWY/+6M v6azTs4TwZgwSqRRWzDLL8MJcmQDUCAfLRHemWALeJzRmQh9kqrEdlgD4WyQTA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757985089; a=rsa-sha256; cv=none; b=WIgUTowivybzkFvKcuxr9cRkZXmouHA1QbjEpNV2jBJbB1bcIuFxGiwxTjLOsb8YR4QKzD pLKBbo0hm0540gPM/JKkmsBnFgyW+K0KlJ7ZCmj93sZCtqpFk7KlRNRbJCgtaW8LQGyDB1 itt5ud2OQMnn3lPiXRoPGqASYP9V3JHdEC2/hKp9bCWgVx9VMvu7LO0WWaJMZ/rDFSsaj4 WQr7geUk1KP8X+1sL5P4yUEbqpPxbbpG3OwpGU7+3ENf59FnVPKoeV/WMzsKk+rEcUoPSw XL8Xgfe65dTU8nktcF6Ahc505ALu4qOeMcARh62tknZ0bGNceNnqVgRrKeHI4w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQkPY5cS7z3hF; Tue, 16 Sep 2025 01:11:29 +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 58G1BTCm024228; Tue, 16 Sep 2025 01:11:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G1BTum024225; Tue, 16 Sep 2025 01:11:29 GMT (envelope-from git) Date: Tue, 16 Sep 2025 01:11:29 GMT Message-Id: <202509160111.58G1BTum024225@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Colin Percival Subject: git: b050bfa88d4e - main - release: Pass ABI to running pkgbase-stage on dvd 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b050bfa88d4ee2acedb590777603e5c3656cdaca Auto-Submitted: auto-generated The branch main has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=b050bfa88d4ee2acedb590777603e5c3656cdaca commit b050bfa88d4ee2acedb590777603e5c3656cdaca Author: Colin Percival AuthorDate: 2025-09-16 01:04:56 +0000 Commit: Colin Percival CommitDate: 2025-09-16 01:11:21 +0000 release: Pass ABI to running pkgbase-stage on dvd I did this for disc1 but forgot to amend the dvd invocation. Fixes: 340e68fd7c0d ("release: Pass ABI to pkgbase-stage.lua") MFC after: 3 days Sponsored by: https://www.patreon.com/cperciva --- release/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/Makefile b/release/Makefile index 5dede64ac9c1..41bca6dceebc 100644 --- a/release/Makefile +++ b/release/Makefile @@ -309,7 +309,7 @@ dvd: ${PKGBASE_REPO} ${.CURDIR}/scripts/pkgbase-stage.lua dvd \ ${.OBJDIR}/pkgbase-repo/${PKG_ABI}/latest \ ${.TARGET}/usr/freebsd-packages/offline \ - "${_ALL_libcompats}" + "${_ALL_libcompats}" ${PKG_ABI} cp ${.CURDIR}/scripts/FreeBSD-base-offline.conf \ ${.TARGET}/usr/freebsd-packages/repos/ mtree -c -p ${.TARGET}/usr/freebsd-packages | \ From nobody Tue Sep 16 01:11:30 2025 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 4cQkPb0gLwz67gTL; Tue, 16 Sep 2025 01:11:31 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQkPZ6tkFz3p9r; Tue, 16 Sep 2025 01:11:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757985091; 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=St612i3RMjYGfw+FCuasTPFGQWdF7yefN4Htme+CUtM=; b=jyzmy8ZhtCCY1qYx725fnsWQE9LRGqsAIY+3gSBFU9M19tX6JP1GJY+Dfust/+FBeTdOCC OFBAXlIBi7ThXsC9Cu/U2gWRm1vJoAPuqT4GyhTLxJNX7ubSafyl5Su7MCjZ0dkby5e36I NvfjPgmtMAB5WCZhocq2egj1USUZthAZY1Fjs658S7/NWvJsw1577DoN34MMXjwqQ2DuGR o0x1jc2nO4PNwqfajOdVtzgu5FKY4n58uBOxNA9/UCzyVnrKUGQ7K7tHE23PvFOxgtPfs/ HQV8uhnvfrpltDH9Xrw3r2kCDG6vVO3R2xTFUttjDXQ7cGCYVZtUxs9fUwxikA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757985091; 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=St612i3RMjYGfw+FCuasTPFGQWdF7yefN4Htme+CUtM=; b=FnVYU8Kl1HEOesYPVDHkGmofINXLPTxvFw/g5ldb9Nks0VES3/XDJHA13ITcDK+BrjIbNG x9kOH3Nk3aGmhH4J7dJ5kZ2+g0TRavncP3FHANU5KS9fWPhui8aZ2dE1Jy7/JPNXrIAfm3 FRrjha+2jS2CCgTIuYzLzIdloaDdxYBvOBX0+rWVa4ULJjp+jGeqkOqPPY9IHPseRy9xAX 6Dbq4L0GDo+Mixhf7f03UUroa0ovU8QNK1D+473/axEIGmr07u49Eif2rcEdjZcTNXRmyA DTkoPiRM+C43QM8yg3TxPVwOHOMDgu+9VuGIoKJIWTOErJcVIejV855QjXecMw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757985091; a=rsa-sha256; cv=none; b=suHAWoxehNP8Y4+bLrUWacPXLE7XKF67asiqTqZzXiH0iOV9VQ91gkdHlmWqeVQ21d59jK q+6j7BASEubjW6/fSXUkldcuos/IGVJjpjRtcpvMVh6DwfTJNqDivkBfczhaao9txi4dOQ dqYD12HDKa2jAvifsmAnA5GUUggcUbyC4l4T8VJTI9S+Fp3iCuu9IFqaO1UryjIOt03DKL cWBR8o7DMm2C7KpdGm5HMbSmsZkFctlA179NdSIDIohMZwBaayvA5jomi1w1UT9nEpsxJ2 LVv6JDW9TAViAZ92iaN2rwgqrGPdmaYB6ZiCwfM8NzWijiEzgG9fVquwU5Qhmw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQkPZ6SHhz36k; Tue, 16 Sep 2025 01:11:30 +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 58G1BUgT024261; Tue, 16 Sep 2025 01:11:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G1BUTr024258; Tue, 16 Sep 2025 01:11:30 GMT (envelope-from git) Date: Tue, 16 Sep 2025 01:11:30 GMT Message-Id: <202509160111.58G1BUTr024258@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Colin Percival Subject: git: 8c9a919abaa3 - main - release: Fix typo in powerpc mkisoimages.sh 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8c9a919abaa3f6f16a17586ca72bab939788bf69 Auto-Submitted: auto-generated The branch main has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=8c9a919abaa3f6f16a17586ca72bab939788bf69 commit 8c9a919abaa3f6f16a17586ca72bab939788bf69 Author: Colin Percival AuthorDate: 2025-09-16 01:09:05 +0000 Commit: Colin Percival CommitDate: 2025-09-16 01:11:21 +0000 release: Fix typo in powerpc mkisoimages.sh "[ n foo ]" is an error and should have been "[ -n foo ]". Fortunately the only ill effect was to result in garbage in /tmp/ when creating powerpc ISO images. Fixes: 6c3e01bf8578 ("release: Randomize powerpc boot block file name") MFC after: 3 days Sponsored by: https://www.patreon.com/cperciva --- release/powerpc/mkisoimages.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/powerpc/mkisoimages.sh b/release/powerpc/mkisoimages.sh index 9d83390f1a4e..705545dead4b 100644 --- a/release/powerpc/mkisoimages.sh +++ b/release/powerpc/mkisoimages.sh @@ -112,7 +112,7 @@ if [ -n "${METALOG}" ]; then fi ${MAKEFS} -D -N ${BASEBITSDIR}/etc -t cd9660 $bootable -o rockridge -o label="$LABEL" -o publisher="$publisher" "$NAME" "$MAKEFSARG" "$@" rm -f "$BASEBITSDIR/etc/fstab" -if [ n "$bootable" ]; then +if [ -n "$bootable" ]; then rm $BOOTBLOCK fi rm -rf "$BASEBITSDIR/ppc" From nobody Tue Sep 16 02:49:47 2025 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 4cQmZz6m8fz685fg; Tue, 16 Sep 2025 02:49:47 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQmZz5YD2z46vl; Tue, 16 Sep 2025 02:49:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757990987; 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=OWZsHcTpuJYeK/5b79+zyHuAtx0uCd94YdBvLqv2PRk=; b=Eeei9XdB4jN9b5w+LqllZ0xcI5aQFBDlODwOzmY2mVK7L/GVzfdjWKKxiYPwk+zqamSi+w lU3VBC+KwWHGkoTL+SSUc6EZwp2ETZubm3bu3w9yDOKWywyVUdefYrsXH9b+Y2xsPfaRKM OErQbaOivxjCIKAY36kcNY3yIl2fu7B7LtER+IUiHyB3SoMkU5QaMrf8VGGzuNVrm6DG6G q+twMUvEPg7SaSqbJ3WbG+96jtM+D0vx53E8l/H4DnpfTFUPRgtinI7FsLEVuv6R5PMX2o Od7Rc+M18C7IiJfo1Q5YA51OOgujtKe6MI6oESeqvW+wo8vKtm4bUD2sFN8VxQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757990987; 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=OWZsHcTpuJYeK/5b79+zyHuAtx0uCd94YdBvLqv2PRk=; b=PRZQigG841FURczJIIXrb1/4IWpeHoadc52wcpB1Rm1xjTgEXBqv5NsT3rdfRuVl+gc37h BVBvXBI/dxau0l00C2OPIhaOAqMsZim9V/692rxtw45JFKnyLq5dTXWsPf+5Ka1HksDiBq 7G16k0LpeUS254hsYiyCx23EIyhEApRFYtXdHH+9WyHCjbGQzGRKqxcMrqRZ7rgMkjrTFM cLbKqkoMrTw1DVPujdLIjO42JXZgY3PBp2WVUydiyqzupUWoSATouRCn0tOFmRPrPNXeiB w0MakV3SuarMV9bGod34Rl0XkJJJagoChvk5bFPLZvmXnCVHuKqsEE1RvIE+9Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757990987; a=rsa-sha256; cv=none; b=V2VueCqhOTy6FhY4gt/YW+2nOvJ4MFlPWGPT+AW4PP2V5O/xnOVWVLryHW6NrT8zoG5/LT 24oeT3f+d3YLFxMUsuKtlHYAeigVS4K/nC/m2cm+0gBnCkn5krLRB15JQSvRZaWwtbNVHz 1CLBY4n45XqGE2Wwd/kKRhX+PFu35/eUWeSPf4YTsQQ4Eq1tdH5rdgAQ1wo7QyNPMA7c4n k1erc15Z/ERolzkOHx8aannky1ht9Zz+TT5nSJD/Tm3VszL1Ql+Qf//kvsFIipW775nJrd eMHzUvNtjCdTLeBpaswjFqheOsdGtdNTz4QC9Frz/Me/9wAdsFDSDJiI/QuV4w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQmZz51YLz69F; Tue, 16 Sep 2025 02:49:47 +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 58G2nl1v099882; Tue, 16 Sep 2025 02:49:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G2nlRu099878; Tue, 16 Sep 2025 02:49:47 GMT (envelope-from git) Date: Tue, 16 Sep 2025 02:49:47 GMT Message-Id: <202509160249.58G2nlRu099878@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: 7140a4790cbc - stable/15 - kern_thr_exit(): clear kASTs in advance 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/15 X-Git-Reftype: branch X-Git-Commit: 7140a4790cbc6c897673276299a1bc3ad63dc3f8 Auto-Submitted: auto-generated The branch stable/15 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=7140a4790cbc6c897673276299a1bc3ad63dc3f8 commit 7140a4790cbc6c897673276299a1bc3ad63dc3f8 Author: Konstantin Belousov AuthorDate: 2025-09-08 03:43:09 +0000 Commit: Konstantin Belousov CommitDate: 2025-09-16 02:45:12 +0000 kern_thr_exit(): clear kASTs in advance PR: 289204 (cherry picked from commit f51d7d5139a76d225c9f537bd948525ababdef0c) --- sys/kern/kern_thr.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/sys/kern/kern_thr.c b/sys/kern/kern_thr.c index 0e8c2b9f362e..4329959a2ef4 100644 --- a/sys/kern/kern_thr.c +++ b/sys/kern/kern_thr.c @@ -346,6 +346,17 @@ kern_thr_exit(struct thread *td) p = td->td_proc; + /* + * Clear kernel ASTs in advance of selecting the last exiting + * thread and acquiring schedulers locks. It is fine to + * clear the ASTs here even if we are not going to exit after + * all. On the other hand, leaving them pending could trigger + * execution in subsystems in a context where they are not + * prepared to handle top kernel actions, even in execution of + * an unrelated thread. + */ + ast_kclear(td); + /* * If all of the threads in a process call this routine to * exit (e.g. all threads call pthread_exit()), exactly one From nobody Tue Sep 16 02:49:48 2025 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 4cQmb101pmz685w1; Tue, 16 Sep 2025 02:49:49 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQmb061VCz46yJ; Tue, 16 Sep 2025 02:49:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757990988; 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=2uw20ZbpZNtfE8QtSjA2Cj8UY06o4t/1Acew+P9zIog=; b=PcFw4A60wa3a1GrEgnZpNE+zvP3lu7nVoBvxQq2BGWm+cOBnF0zXhH8/bRm9IHgF14/bh5 fsF7usLiD/qoA04zWgw84tJK4+MaClMEAAvLGQUQgTcMQAaqjWJZON6IVBV4d3XqSs8/sp yv1oIYSTaNFPW6Rfof0YCkUEeACbtOi3z0LfRqlb7Qt8SxKi/BS1mS7x5ehfYQjWQFUODY 3fR0/Cw+oFtRvDhjLD7EHShd2uFyee/qYxGM6lhAxSexPOI8HR9LAxTT8wvqBT8lVDP538 TsCvBgTOyBLFrMsBi/MGKPMccqWoBehDf6H9MPCjnD8REhvQCJiadh1c12Am1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757990988; 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=2uw20ZbpZNtfE8QtSjA2Cj8UY06o4t/1Acew+P9zIog=; b=NqLV+eTNLMCDFlGMTvWmFgRbcCzfeM+POL0oXEYp6ph7EKJx7tng5bWEgRSy9wnPryI5Tc chXhb25mZWLE6c9WPyVqklW6DavMX1htsSKC4otMHSFjxl0XngJQ39UU7ExF9Vn7ItLHWx fNN8F0KFOj0gj5XSjnBEyqg1VkK0EaO0gCp/a9Cn+uV0hy1JbbIAieTTcRERBwbtQeFjfH aKMcPPHfkCLnVftrwQxHgTnPeX1kIqwU/Itg1ndN/WB/g73AulxSQL3jnWkNsgUL1oTklw Puz1ZI/3vAiMs6kxaIOYHy3zwrrm1cr+6/GHZiJnuZDX0BpGw2wFqvxCk1RcYQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757990988; a=rsa-sha256; cv=none; b=oeoGY2BqvIp9KxW2vtZQ+M7mIKKY+nx3fh1COCzFUc+5ePEk+STyT2gOj8VcHMRfM+kiVN BbTSIf5gePV//mOoHfJttHxQc6XL37AD6i3ULB64ViXkFlrsw5et49BpP9BouJk3aWgN9w ZuA+9xNHlkyc/mH/zI8BrSLS49XDyb73F8AmA4pE45FV7AN8G3G8r/fki6v2EU2Z9XrwXK xQeObojkFV4b8xHzbu4mD4pMWpdcCaC+KL8iGFk5vsW4VSPtRryQvxxuRSzy2frpQeqtOf kUuHXxBL6ehvQrTA0q+DIWnnWWnWg4JWTMca3xuq5EggPTrNv16gG2WaeGTWYA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQmb05d5qz67h; Tue, 16 Sep 2025 02:49:48 +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 58G2nmI7099915; Tue, 16 Sep 2025 02:49:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G2nm6F099912; Tue, 16 Sep 2025 02:49:48 GMT (envelope-from git) Date: Tue, 16 Sep 2025 02:49:48 GMT Message-Id: <202509160249.58G2nm6F099912@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: 1234bd1b7213 - stable/15 - geom: only set TDP_GEOM for user threads 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/15 X-Git-Reftype: branch X-Git-Commit: 1234bd1b7213c253ad7730ee2cef642d0aab234e Auto-Submitted: auto-generated The branch stable/15 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=1234bd1b7213c253ad7730ee2cef642d0aab234e commit 1234bd1b7213c253ad7730ee2cef642d0aab234e Author: Konstantin Belousov AuthorDate: 2025-09-08 13:46:08 +0000 Commit: Konstantin Belousov CommitDate: 2025-09-16 02:45:12 +0000 geom: only set TDP_GEOM for user threads PR: 289204 (cherry picked from commit b0474e14895908f45c64158b0e558236923b8eb2) --- sys/geom/geom_event.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sys/geom/geom_event.c b/sys/geom/geom_event.c index 341233a6ef47..ffd46db55416 100644 --- a/sys/geom/geom_event.c +++ b/sys/geom/geom_event.c @@ -347,6 +347,7 @@ static void g_post_event_ep_va(g_event_t *func, void *arg, int wuflag, struct g_event *ep, va_list ap) { + struct thread *td; void *p; u_int n; @@ -366,8 +367,12 @@ g_post_event_ep_va(g_event_t *func, void *arg, int wuflag, TAILQ_INSERT_TAIL(&g_events, ep, events); mtx_unlock(&g_eventlock); wakeup(&g_wait_event); - curthread->td_pflags |= TDP_GEOM; - ast_sched(curthread, TDA_GEOM); + + td = curthread; + if ((td->td_pflags & TDP_KTHREAD) == 0) { + td->td_pflags |= TDP_GEOM; + ast_sched(td, TDA_GEOM); + } } void From nobody Tue Sep 16 02:49:49 2025 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 4cQmb21VTQz685nF; Tue, 16 Sep 2025 02:49:50 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQmb16jH0z46vs; Tue, 16 Sep 2025 02:49:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757990990; 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=HqSFYfwEIxHZXcwTymoqCdtuMhRb0xVzP1GnvDEsOMw=; b=krkgTRMLGGB13UqpmzqvdSmDNvhsj7aE+UdtX5AqiJjBNZ0zgViz1G0l8GnL1Gr+Ke9bX4 pVF8ZYIuvjz/FnVfJRg/gxrW8FRXKtG7wo5maUD6ID2sXjja7sasrrCmEyPFdQbPzAqPJQ aH12XpVWhtzj87JZNemVtIshNA7+4WggpQayTrRoaLoo3FD/tGatj8P74swQvDtKlJfsQO JYQyLW3nFopnyR1cS6L+92b9NU1yBDWGDtV0YWU1ViqByI3HmUynbSvNVBQUx9Zdl9pXzf /5MzqSW6lWPtg2+ZPn83fptwJMhoP5rAuaEnCNVbZrJKwHGwnf8XMbzAClM7aA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757990990; 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=HqSFYfwEIxHZXcwTymoqCdtuMhRb0xVzP1GnvDEsOMw=; b=Ab19UMZ/vwrBMmzAHO+gqhz3pkdZ19U8jglg/+mcmdtEweAX78b8zCikymEy+yr9qeX8Sw yruhgpSmi2O1oO/Pc9fPEM5F3LaVg4l0IsIlWs79IkD70IHQeMQTgdhhC+5OfTI21dagaM opaBGsFmVwbuISC/512VA4sNLrD3Vu7CsPbRHxkCOrMETtmQ8wMzWFCDabFol3I3WSGSPG 9LBkhsZ0dojnMvKhcZ5joCu1P9Gh6+FRfKFTQFzKbbDErwNKyn0uKEhmX0oJhC03AfZcHa qF91s2JeB6tjqt6nQPh18kAxoi6agsksEwWqYVAwQsPDR/nq6jmHduw4N23wMw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757990990; a=rsa-sha256; cv=none; b=YLXH5CliE60O0I5ZvHtn3q38Gn85eS0HHiqZDP3zVbmWVllAeNDtPVM9j2SIJZf8kCOUY7 Tu3TvNZI8Pa/jm5aUyARQuO5G4ldMuL4dyCXIZxv66AWuVMPGU/34EKcadPVjNpqmmpZ1Q CiIp9n1pBEDLQHEquNlzS1Ba8kuAGtuz+RgzVfe5PtaYoSkLiFsOkiVVV20vD8lIXcg0EL B2nQgL+LMV36l2Iucnj6u2mBoNV5WxWU0dRBUrHkE4f31qm9lSFWwJbf631yEakmKLL4e8 k5cgmXUzvMb7j4+j1c8Gl1qpjC6hWXxss0jyc1dXO45/ri5mk8or+FeG7KbBAQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQmb169v9z6XP; Tue, 16 Sep 2025 02:49:49 +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 58G2nnbY099949; Tue, 16 Sep 2025 02:49:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G2nnSp099945; Tue, 16 Sep 2025 02:49:49 GMT (envelope-from git) Date: Tue, 16 Sep 2025 02:49:49 GMT Message-Id: <202509160249.58G2nnSp099945@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: c2427a67c7af - stable/15 - kern/kern_event.c: properly spell COMPAT_FREEBSD32 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/15 X-Git-Reftype: branch X-Git-Commit: c2427a67c7af60bd4d07acce0ab4f0c4be2258c2 Auto-Submitted: auto-generated The branch stable/15 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=c2427a67c7af60bd4d07acce0ab4f0c4be2258c2 commit c2427a67c7af60bd4d07acce0ab4f0c4be2258c2 Author: Konstantin Belousov AuthorDate: 2025-09-13 17:42:11 +0000 Commit: Konstantin Belousov CommitDate: 2025-09-16 02:45:13 +0000 kern/kern_event.c: properly spell COMPAT_FREEBSD32 PR: 289504 (cherry picked from commit cab4cf201acf76b415a8f1a59ea4eeeb14b4636c) --- sys/kern/kern_event.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/kern/kern_event.c b/sys/kern/kern_event.c index 57cbfb8a0361..72cbff6c1371 100644 --- a/sys/kern/kern_event.c +++ b/sys/kern/kern_event.c @@ -3127,7 +3127,7 @@ sysctl_kern_proc_kqueue(SYSCTL_HANDLER_ARGS) return (error); td = curthread; -#ifdef FREEBSD_COMPAT32 +#ifdef COMPAT_FREEBSD32 compat32 = SV_CURPROC_FLAG(SV_ILP32); #else compat32 = false; From nobody Tue Sep 16 02:50:23 2025 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 4cQmbg5rWCz685fl; Tue, 16 Sep 2025 02:50:23 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQmbg4zyWz47YV; Tue, 16 Sep 2025 02:50:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757991023; 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=GbvxPjP0SCpOHqPcZ6k9p6TLZ8k02554QHp3uVKM0LI=; b=l0iFJD4bNv6VU5WlBbMD8SZnbDHgGncamAhsO7RQuOXKHQtETdT6sYiIs0sWHaheUNEGK8 2tAswpkajq0EZeL0KPhpXKWnQVpqFL0pX2b+dz/eHjkCwBFk27cEoxoxmPQL0bGZrtA63k b7qgPTHfe0NLkEIzIwsPTEyQ7DOY738b9gUr/1sCzbkKE8AQycOFAZ2Tzo0h5q/P0m4AoB 6uHoqT1g9tyGnt4wGDiDpfzJ5iovT/FCZzbnRXaZw+2Uux4lSmSeJ2fA4kQHOPQZREyCEh 0RDpklXv/YERKg9AAx9KVauoXXT1PFvtJ3Ke1q6x89c3Pgz5DlUYQEh0IhBEHA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757991023; 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=GbvxPjP0SCpOHqPcZ6k9p6TLZ8k02554QHp3uVKM0LI=; b=cArsQEYA+jD15u0utMa8Mn3EpiZd7NhZrIJq+r5o10a2rM6PVgq3Hf1SjNnXTINQfNUhP2 Dpcj1R75RP1hbvOsnl3m3tH7P3eXvb5FIyonQYsKgqeLj/cFPwQR+xsyysNV2HQqeo0ewv xyx5BpsAadsjBnfUR5hN3I3XKvwpA1lflvF1Z2fX6oAyKzimBw2U6Pqu3Bl2WxBRX5fsVI V1susMXlTzj7VY7V1wCmcLzxOlzdmxUNBQMjKzL3rJMdnukkNDuK1dTHqAh7iZ2C7M82b3 ls3OciUvihbUXVyW580ZH7WTFAJK1rienTn+a8fFSpoOCvNHxP6GhxIiSNJMuQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757991023; a=rsa-sha256; cv=none; b=rbSELjsGlJMun9SEMJ43L/UQrNKNZ2V/liYPZ10SVmkMVDz2umhlJI5IgAQGbd+BxjB+4K e2TwFG1YMbpUGHbh1MXWA00QkrrFYs0ogBT9loI87HQMyyzYeNha15pK1qmJ991TOAv7hX gj7i6679bEtN5sReh1BmLchT4lJ/mL0koCS5RCVMjkk0N3VUEpCbVUH/vEnABuVjslreD/ axIt8vGc8aoEjprZkOhKepRgTO2rOgcMAkD6miu78HVsvH8GPnTRObtlVqaJgc0Mjfusc3 SKgpVxpsGr+jPUpL+msIoDesXvQu4unXxAszPv9iizlmpZRw5muGXpcybnxgvg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQmbg4Vj7z69G; Tue, 16 Sep 2025 02:50:23 +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 58G2oNto009039; Tue, 16 Sep 2025 02:50:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G2oN97009036; Tue, 16 Sep 2025 02:50:23 GMT (envelope-from git) Date: Tue, 16 Sep 2025 02:50:23 GMT Message-Id: <202509160250.58G2oN97009036@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: 594982a69714 - stable/14 - kern_thr_exit(): clear kASTs in advance 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: 594982a69714150ccf8616ffbce65fecab70ec03 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=594982a69714150ccf8616ffbce65fecab70ec03 commit 594982a69714150ccf8616ffbce65fecab70ec03 Author: Konstantin Belousov AuthorDate: 2025-09-08 03:43:09 +0000 Commit: Konstantin Belousov CommitDate: 2025-09-16 02:44:24 +0000 kern_thr_exit(): clear kASTs in advance PR: 289204 (cherry picked from commit f51d7d5139a76d225c9f537bd948525ababdef0c) --- sys/kern/kern_thr.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/sys/kern/kern_thr.c b/sys/kern/kern_thr.c index 8ad885b42ebe..1b5f0b1a33ad 100644 --- a/sys/kern/kern_thr.c +++ b/sys/kern/kern_thr.c @@ -339,6 +339,17 @@ kern_thr_exit(struct thread *td) p = td->td_proc; + /* + * Clear kernel ASTs in advance of selecting the last exiting + * thread and acquiring schedulers locks. It is fine to + * clear the ASTs here even if we are not going to exit after + * all. On the other hand, leaving them pending could trigger + * execution in subsystems in a context where they are not + * prepared to handle top kernel actions, even in execution of + * an unrelated thread. + */ + ast_kclear(td); + /* * If all of the threads in a process call this routine to * exit (e.g. all threads call pthread_exit()), exactly one From nobody Tue Sep 16 02:50:24 2025 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 4cQmbj0MY7z685yS; Tue, 16 Sep 2025 02:50:25 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQmbh64C8z47TZ; Tue, 16 Sep 2025 02:50:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757991024; 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=NrInk6fQ4E5tUscgUt3QuLZ7l9dZlow2pLI4LexMH2A=; b=K89m0+BY0vTmhGV0czAcCJMTop8mVTcFuaOLv4CqRiSeiQcooU5GUYNaiiToE1k8nZlq4q X6XhEWYiYDs4ukLl3jAcmDrkw7bPqDkI9DwD7na2dDkJXgjUdx6vZ7hvIk/noLfqKNnRM7 CIM9E3u3+bKPFE6gOzGDH4j3hyVDoYRvT6k0ZxpTC2mxicocguXwP6ZAKEM0TJGZTYRz4j Hnjd9xzhPaZResYkrzNcrzr6xoh38yD6dakswPWtDzA+TtXishJB1yXg0+rFqy1CfuEuB9 Z5wNqVN3K4SCELvPD5TyWh+xG2kHCmoywwv5MA1dVtqrkNnlJB0G2LA29V0Iyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757991024; 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=NrInk6fQ4E5tUscgUt3QuLZ7l9dZlow2pLI4LexMH2A=; b=sZen8KDevFB/PBum4vqHIV8gQooNGCGYkjBjogwphKYonRw4XcgromW73v9pSG2MesjJ2a 5nIbcSHRmD7EupXKV0Mt5Dnlxa/T92ZgN70TbVpwzy4XBk8S7udM4YIjwAvdZrCZmYkzsQ CT/9XicewrARigIvl9a2/BfmzvtjNfQqmZSuQpMv6XbPyOSq6hnnDDp8ua79kgCEPvjkiN Won34dnTdnIioLBYPXr7DTItgWA1wg72wwEu4U0Cnq9FrAyFkjJMBrW1VvuVyDrUdYTNdV V0pdzvW0JrGDzKFUpvWC7U1/rpsUYsfRLZRnJqMzKeX40VH4mbPabhRa9tvPeA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757991024; a=rsa-sha256; cv=none; b=ahIfmcJf4T4U8lMFXViog9uOojpZERNXsgXCar8McDAX1aIt3rClAjGyZiOH1DG3ZY9Tf2 K/M6gxZZ5CVbXNxmXMaI4WCKbkg+xkQ3/r7A3gGyKthrsxhrsqZ3NsAydI/Xj9AhyehPWx l8d/wuvZ1PBB6wWFj6UCjhoQD+yC+ncSMwszSOJnLwqqmWsNI2hddvIYjikhYSmaPPkSJU q45+vg3rin7WS5TMueUDFZeMewlhGJrmkzqe1Zp4real2PEG2JFVsuPhkygAcK4tpmbaQB NPYFGTIqW0iwNQHK2XqFr38VAlzksL9YoqxL/aThhMA1g7GumSVWPfw6rJOTsQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQmbh5SRRz6WT; Tue, 16 Sep 2025 02:50:24 +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 58G2oOPf009072; Tue, 16 Sep 2025 02:50:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G2oO83009069; Tue, 16 Sep 2025 02:50:24 GMT (envelope-from git) Date: Tue, 16 Sep 2025 02:50:24 GMT Message-Id: <202509160250.58G2oO83009069@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: a1dcf2fc8f32 - stable/14 - geom: only set TDP_GEOM for user threads 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: a1dcf2fc8f327c5d492278f14c07380b7170fc68 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=a1dcf2fc8f327c5d492278f14c07380b7170fc68 commit a1dcf2fc8f327c5d492278f14c07380b7170fc68 Author: Konstantin Belousov AuthorDate: 2025-09-08 13:46:08 +0000 Commit: Konstantin Belousov CommitDate: 2025-09-16 02:44:24 +0000 geom: only set TDP_GEOM for user threads PR: 289204 (cherry picked from commit b0474e14895908f45c64158b0e558236923b8eb2) --- sys/geom/geom_event.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sys/geom/geom_event.c b/sys/geom/geom_event.c index 0973b87b36bc..0facaa68a49c 100644 --- a/sys/geom/geom_event.c +++ b/sys/geom/geom_event.c @@ -349,6 +349,7 @@ static void g_post_event_ep_va(g_event_t *func, void *arg, int wuflag, struct g_event *ep, va_list ap) { + struct thread *td; void *p; u_int n; @@ -368,8 +369,12 @@ g_post_event_ep_va(g_event_t *func, void *arg, int wuflag, TAILQ_INSERT_TAIL(&g_events, ep, events); mtx_unlock(&g_eventlock); wakeup(&g_wait_event); - curthread->td_pflags |= TDP_GEOM; - ast_sched(curthread, TDA_GEOM); + + td = curthread; + if ((td->td_pflags & TDP_KTHREAD) == 0) { + td->td_pflags |= TDP_GEOM; + ast_sched(td, TDA_GEOM); + } } void From nobody Tue Sep 16 02:50:25 2025 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 4cQmbk3mPWz685qc; Tue, 16 Sep 2025 02:50:26 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQmbj6SFBz47fL; Tue, 16 Sep 2025 02:50:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757991025; 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=UUpug0XjdLDeApx4qyOkR5UEgH0bTloCYaN1GEohatQ=; b=m7z7g0L4+EpMJE1jOSluMjwGY0yRg83JxhJB4rWwn7cTzFplSvFgk0PDxfn1oNS9JvpbmR R3sWdZH3z8LTsBewzEghUHwJAdhvrV8l/XYy0PbxPRajg5JWvFzzgwXszoYont00RdWh1O 9WcaY+GU189cGhGqjzyTKg1Bj25WaSxIQ4KreLx2/15enbglKdf9zm4jHLaO/XAzRe5jM+ voTxIPYnif2016AFy7zp2lc2X+SfT5+XjxtWDk6A9LEZTL9oVrxA4g3OWu7okFHDTgEudq Se+msu+DV9oPE1QZrWJXxKBnRIHPQUv2jNJR0cbfOlIbGFfL3ibopeF3y16mhw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757991025; 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=UUpug0XjdLDeApx4qyOkR5UEgH0bTloCYaN1GEohatQ=; b=JCaFifirHsmJMGKybgxyAQnOyoUGIkVa3xeuXqyHkdOZwRQvLK2c1T4ufZaCODA1f1wGQH Q3fupU/4AJFm4iVmf8rNyQEbypEaYl6mWGftWBH0r23UOraoxUt/skwQfn/bjfmEzgITas wA503ZkJt/9TzdE9qZRniQ6s66SSnQlCf6j5OAZ01cTrBA4jCB+rQQpG1no+u7u8RxNIUE A2/ctNOI/6CZ7wU/Hal8eKv4/6AHC3CHDtj+QoXp5/PJeDf/VbUzNmYdAQuWNJ3+XY9IVT +pVgwA9Rr6Iu6OeXSa/HS928riCNQdt47zyB0JTN6ZhDSg4/zntfoaSwFud2JQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757991025; a=rsa-sha256; cv=none; b=S0Yf/Tpg+WYJ7cVjKll5CSH4WZ5R6Wcyu84/JNlG51C0ePAQg4SeHMNULn8gxpikAVrl7z 2kbdjG9dcMLYIz+JN9OyUHu8Oblz4MewRzoHAg4dlIyVcREhdhP5i2+iGAq9XJd/nXmzxQ 0G54bWtRbwKUsQDI+21WLPQM6UpuMdpQZfICi60qhjJuAGjsSqaBkHuaHdQ+CUYeeYSYEf 9GrnVJ7h+a5U/+7RHnQ7swYsrS30GwBaQD6IQTI0NPc8jmTuxiQHo5HS9IhbmlUmTY1V6+ xkOD0V9kOvFa2I7BlPiLOTsPfW4lxYTy26BhpYb5MAE1X5yhhiqta+k9/XaecA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQmbj5zkCz69H; Tue, 16 Sep 2025 02:50:25 +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 58G2oP2D009108; Tue, 16 Sep 2025 02:50:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G2oPWJ009105; Tue, 16 Sep 2025 02:50:25 GMT (envelope-from git) Date: Tue, 16 Sep 2025 02:50:25 GMT Message-Id: <202509160250.58G2oPWJ009105@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: 8c40728a46d4 - stable/14 - kern/kern_event.c: properly spell COMPAT_FREEBSD32 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: 8c40728a46d4c2a3a93314deca47252f5c2ebe12 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=8c40728a46d4c2a3a93314deca47252f5c2ebe12 commit 8c40728a46d4c2a3a93314deca47252f5c2ebe12 Author: Konstantin Belousov AuthorDate: 2025-09-13 17:42:11 +0000 Commit: Konstantin Belousov CommitDate: 2025-09-16 02:44:39 +0000 kern/kern_event.c: properly spell COMPAT_FREEBSD32 PR: 289504 (cherry picked from commit cab4cf201acf76b415a8f1a59ea4eeeb14b4636c) --- sys/kern/kern_event.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/kern/kern_event.c b/sys/kern/kern_event.c index eb77a5064113..50d04e1fe253 100644 --- a/sys/kern/kern_event.c +++ b/sys/kern/kern_event.c @@ -3033,7 +3033,7 @@ sysctl_kern_proc_kqueue(SYSCTL_HANDLER_ARGS) return (error); td = curthread; -#ifdef FREEBSD_COMPAT32 +#ifdef COMPAT_FREEBSD32 compat32 = SV_CURPROC_FLAG(SV_ILP32); #else compat32 = false; From nobody Tue Sep 16 05:02:39 2025 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 4cQqXM06p9z68HXN; Tue, 16 Sep 2025 05:02:43 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Received: from omta003.cacentral1.a.cloudfilter.net (omta001.cacentral1.a.cloudfilter.net [3.97.99.32]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Client", Issuer "CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQqXL1nv5z3P7V; Tue, 16 Sep 2025 05:02:42 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=permerror reason="p tag has invalid value: quarantine rua=mailto:p[ostmaster@cschubert.com" header.from=cschubert.com (policy=permerror); spf=pass (mx1.freebsd.org: domain of cy.schubert@cschubert.com designates 3.97.99.32 as permitted sender) smtp.mailfrom=cy.schubert@cschubert.com Received: from shw-obgw-4003a.ext.cloudfilter.net ([10.228.9.183]) by cmsmtp with ESMTPS id y5Nou9c6W9JM2yNpxuSlcD; Tue, 16 Sep 2025 05:02:41 +0000 Received: from spqr.komquats.com ([70.66.136.217]) by cmsmtp with ESMTPSA id yNpvulVfaWbOayNpwu0Hye; Tue, 16 Sep 2025 05:02:41 +0000 X-Auth-User: cschuber X-Authority-Analysis: v=2.4 cv=Q5lx4J2a c=1 sm=1 tr=0 ts=68c8ef71 a=h7br+8Ma+Xn9xscxy5znUg==:117 a=h7br+8Ma+Xn9xscxy5znUg==:17 a=kj9zAlcOel0A:10 a=yJojWOMRYYMA:10 a=6I5d2MoRAAAA:8 a=EkcXrb_YAAAA:8 a=YxBL1-UpAAAA:8 a=fTp3_WuIajQB4k7Q1AAA:9 a=CjuIK1q_8ugA:10 a=LK5xJRSDVpKd5WXXoEvA:22 a=Ia-lj3WSrqcvXOmTRaiG:22 Received: from slippy.cwsent.com (slippy.cwsent.com [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTP id 52190AD8; Mon, 15 Sep 2025 22:02:39 -0700 (PDT) Received: by slippy.cwsent.com (Postfix, from userid 1000) id 4BB672D5; Mon, 15 Sep 2025 22:02:39 -0700 (PDT) X-Mailer: exmh version 2.9.0 11/07/2018 with nmh-1.8+dev Reply-to: Cy Schubert From: Cy Schubert X-os: FreeBSD X-Sender: cy@cwsent.com X-URL: http://www.cschubert.com/ To: Aymeric Wibo cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: e779891327b1 - main - sys/power: Sleep type reporting by PM backends In-reply-to: <202509142159.58ELx5Rg054606@gitrepo.freebsd.org> References: <202509142159.58ELx5Rg054606@gitrepo.freebsd.org> Comments: In-reply-to Aymeric Wibo message dated "Sun, 14 Sep 2025 21:59:05 +0000." 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=us-ascii Date: Mon, 15 Sep 2025 22:02:39 -0700 Message-Id: <20250916050239.4BB672D5@slippy.cwsent.com> X-CMAE-Envelope: MS4xfK+v86YH25JgiBmnJZM/ykcfO0NU7dohbsHoY40X6MAoDK4/oocM5vOHQBGGUvLnZFZu/cnadLJqlXi6o+6Xn6iRV1Oy0PVESyou4UijJKVfCBK0fWKC PLwbsaCuwtq/CEForhLg3bdT8golrH+FgIrJrldts4vmxUt2CzcRL5GvlNFnhUO8wyVh8URbpy/h+QaNjNv2mYlErexI1mQT16TenJHloFsxq7/Xxu9Q54BC c6MJLS2fme2kgGxGW41AHv9gJCrjHvRXxvGhG2NlrJDzpR/pAQdhp7ro3y8o7DpYIC58A+ahDAQueuMU59Tay+oIsL3+dNlzYcBgPNh+cS8= X-Spamd-Bar: -- X-Spamd-Result: default: False [-2.87 / 15.00]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-0.99)[-0.993]; NEURAL_HAM_SHORT(-0.57)[-0.573]; MV_CASE(0.50)[]; RWL_MAILSPIKE_EXCELLENT(-0.40)[3.97.99.32:from]; R_SPF_ALLOW(-0.20)[+ip4:3.97.99.32/31]; RCVD_IN_DNSWL_LOW(-0.10)[3.97.99.32:from]; MIME_GOOD(-0.10)[text/plain]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; TO_DN_SOME(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:16509, ipnet:3.96.0.0/15, country:US]; DMARC_BAD_POLICY(0.00)[cschubert.com : p tag has invalid value: quarantine rua=mailto:p[ostmaster@cschubert.com]; HAS_REPLYTO(0.00)[Cy.Schubert@cschubert.com]; RCPT_COUNT_THREE(0.00)[4]; FROM_EQ_ENVFROM(0.00)[]; FROM_HAS_DN(0.00)[]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MLMMJ_DEST(0.00)[dev-commits-src-main@freebsd.org,dev-commits-src-all@freebsd.org]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; REPLYTO_EQ_FROM(0.00)[] X-Rspamd-Queue-Id: 4cQqXL1nv5z3P7V In message <202509142159.58ELx5Rg054606@gitrepo.freebsd.org>, Aymeric Wibo writ es: > The branch main has been updated by obiwac: > > URL: https://cgit.FreeBSD.org/src/commit/?id=e779891327b1d9b9ab10ba482e59f498 > 790505a7 > > commit e779891327b1d9b9ab10ba482e59f498790505a7 > Author: Aymeric Wibo > AuthorDate: 2025-09-14 21:58:13 +0000 > Commit: Aymeric Wibo > CommitDate: 2025-09-14 21:58:15 +0000 > > sys/power: Sleep type reporting by PM backends > > Allow PM backends to report supported sleep types when registering > through `power_pm_register`. Expose this information through > `kern.power.supported_stype` sysctl, and set defaults for > `power_standby/suspend/hibernate_stype` based on this. > > Implement this in ACPI PM backend. > > Reviewed by: mckusick (mentor), markj > Approved by: mckusick (mentor), markj > Sponsored by: The FreeBSD Foundation > Differential Revision: https://reviews.freebsd.org/D52044 > --- > sys/dev/acpica/acpi.c | 6 ++++-- > sys/kern/subr_power.c | 46 +++++++++++++++++++++++++++++++++++++++++----- > sys/sys/power.h | 3 ++- > 3 files changed, 47 insertions(+), 8 deletions(-) > > diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c > index 8dd879a573cc..702e1ecb5340 100644 > --- a/sys/dev/acpica/acpi.c > +++ b/sys/dev/acpica/acpi.c > @@ -734,7 +734,8 @@ acpi_attach(device_t dev) > goto out; > > /* Register ACPI again to pass the correct argument of pm_func. */ > - power_pm_register(POWER_PM_TYPE_ACPI, acpi_pm_func, sc); > + power_pm_register(POWER_PM_TYPE_ACPI, acpi_pm_func, sc, > + acpi_supported_stypes); > > acpi_platform_osc(dev); > > @@ -4776,7 +4777,8 @@ acpi_pm_register(void *arg) > if (!cold || resource_disabled("acpi", 0)) > return; > > - power_pm_register(POWER_PM_TYPE_ACPI, acpi_pm_func, NULL); > + power_pm_register(POWER_PM_TYPE_ACPI, acpi_pm_func, NULL, > + acpi_supported_stypes); > } > > SYSINIT(power, SI_SUB_KLD, SI_ORDER_ANY, acpi_pm_register, NULL); > diff --git a/sys/kern/subr_power.c b/sys/kern/subr_power.c > index eb5bd03f5018..44ad82860649 100644 > --- a/sys/kern/subr_power.c > +++ b/sys/kern/subr_power.c > @@ -39,13 +39,14 @@ > #include > #include > > -enum power_stype power_standby_stype = POWER_STYPE_STANDBY; > -enum power_stype power_suspend_stype = POWER_STYPE_SUSPEND_TO_IDLE; > -enum power_stype power_hibernate_stype = POWER_STYPE_HIBERNATE; > +enum power_stype power_standby_stype = POWER_STYPE_UNKNOWN; > +enum power_stype power_suspend_stype = POWER_STYPE_UNKNOWN; > +enum power_stype power_hibernate_stype = POWER_STYPE_UNKNOWN; > > static u_int power_pm_type = POWER_PM_TYPE_NONE; > static power_pm_fn_t power_pm_fn = NULL; > static void *power_pm_arg = NULL; > +static bool power_pm_supported[POWER_STYPE_COUNT] = {0}; > static struct task power_pm_task; > > enum power_stype > @@ -70,6 +71,26 @@ power_stype_to_name(enum power_stype stype) > return (power_stype_names[stype]); > } > > +static int > +sysctl_supported_stypes(SYSCTL_HANDLER_ARGS) > +{ > + int error; > + struct sbuf sb; > + enum power_stype stype; > + > + sbuf_new(&sb, NULL, 32, SBUF_AUTOEXTEND); > + for (stype = 0; stype < POWER_STYPE_COUNT; stype++) { > + if (power_pm_supported[stype]) > + sbuf_printf(&sb, "%s ", power_stype_to_name(stype)); > + } > + sbuf_trim(&sb); > + sbuf_finish(&sb); > + error = sysctl_handle_string(oidp, sbuf_data(&sb), sbuf_len(&sb), req); > + sbuf_delete(&sb); > + > + return (error); > +} > + > static int > power_sysctl_stype(SYSCTL_HANDLER_ARGS) > { > @@ -86,7 +107,8 @@ power_sysctl_stype(SYSCTL_HANDLER_ARGS) > new_stype = power_name_to_stype(name); > if (new_stype == POWER_STYPE_UNKNOWN) > return (EINVAL); > - /* TODO Check to see if the new stype is supported. */ > + if (!power_pm_supported[new_stype]) > + return (EOPNOTSUPP); > if (new_stype != old_stype) > *(enum power_stype *)oidp->oid_arg1 = new_stype; > return (0); > @@ -95,6 +117,9 @@ power_sysctl_stype(SYSCTL_HANDLER_ARGS) > static SYSCTL_NODE(_kern, OID_AUTO, power, CTLFLAG_RW, 0, > "Generic power management related sysctls"); > > +SYSCTL_PROC(_kern_power, OID_AUTO, supported_stype, > + CTLTYPE_STRING | CTLFLAG_RD, 0, 0, sysctl_supported_stypes, "A", > + "List supported sleep types"); > SYSCTL_PROC(_kern_power, OID_AUTO, standby, CTLTYPE_STRING | CTLFLAG_RW, > &power_standby_stype, 0, power_sysctl_stype, "A", > "Sleep type to enter on standby"); > @@ -114,7 +139,8 @@ power_pm_deferred_fn(void *arg, int pending) > } > > int > -power_pm_register(u_int pm_type, power_pm_fn_t pm_fn, void *pm_arg) > +power_pm_register(u_int pm_type, power_pm_fn_t pm_fn, void *pm_arg, > + bool pm_supported[static POWER_STYPE_COUNT]) > { > int error; > > @@ -123,6 +149,16 @@ power_pm_register(u_int pm_type, power_pm_fn_t pm_fn, vo > id *pm_arg) > power_pm_type = pm_type; > power_pm_fn = pm_fn; > power_pm_arg = pm_arg; > + memcpy(power_pm_supported, pm_supported, > + sizeof(power_pm_supported)); > + if (power_pm_supported[POWER_STYPE_STANDBY]) > + power_standby_stype = POWER_STYPE_STANDBY; > + if (power_pm_supported[POWER_STYPE_SUSPEND_TO_IDLE]) > + power_suspend_stype = POWER_STYPE_SUSPEND_TO_IDLE; > + else if (power_pm_supported[POWER_STYPE_SUSPEND_TO_MEM]) > + power_suspend_stype = POWER_STYPE_SUSPEND_TO_MEM; > + if (power_pm_supported[POWER_STYPE_HIBERNATE]) > + power_hibernate_stype = POWER_STYPE_HIBERNATE; > error = 0; > TASK_INIT(&power_pm_task, 0, power_pm_deferred_fn, NULL); > } else { > diff --git a/sys/sys/power.h b/sys/sys/power.h > index 44d7fc354423..33ace400bfd2 100644 > --- a/sys/sys/power.h > +++ b/sys/sys/power.h > @@ -91,7 +91,8 @@ extern const char *power_stype_to_name(enum power_stype _ > stype); > > typedef int (*power_pm_fn_t)(u_long _cmd, void* _arg, enum power_stype _styp > e); > extern int power_pm_register(u_int _pm_type, power_pm_fn_t _pm_fn, > - void *_pm_arg); > + void *_pm_arg, > + bool _pm_supported[static POWER_STYPE_COUNT]); > extern u_int power_pm_get_type(void); > extern void power_pm_suspend(int); > > One of this series of ACPI commits has broken power management on my machines. One of which managed to capture a dump from a kernel panic after poweroff(8) was issued. __curthread () at /opt/src/git-src/sys/amd64/include/pcpu_aux.h:57 57 __asm("movq %%gs:%c1,%0" : "=r" (td) (kgdb) #0 __curthread () at /opt/src/git-src/sys/amd64/include/pcpu_aux.h:57 td = #1 doadump (textdump=textdump@entry=1) at /opt/src/git-src/sys/kern/kern_shutdown.c:399 error = 0 coredump = #2 0xffffffff8070d320 in kern_reboot (howto=260) at /opt/src/git-src/sys/kern/kern_shutdown.c:519 once = 1 __pc = 0x0 #3 0xffffffff8070d857 in vpanic (fmt=0xffffffff80b8e00c "%s", ap=ap@entry=0xfffffe008a636960) at /opt/src/git-src/sys/kern/kern_shutdown.c:974 buf = "page fault", '\000' __pc = 0x0 __pc = 0x0 __pc = 0x0 other_cpus = {__bits = {14, 0 }} td = 0xfffff80006607000 bootopt = newpanic = #4 0xffffffff8070d683 in panic (fmt=) at /opt/src/git-src/sys/kern/kern_shutdown.c:887 ap = {{gp_offset = 16, fp_offset = 48, overflow_arg_area = 0xfffffe008a636990, reg_save_area = 0xfffffe008a636930}} #5 0xffffffff80aeb4bc in trap_fatal (frame=, eva=) at /opt/src/git-src/sys/amd64/amd64/trap.c:969 type = handled = #6 0xffffffff80aeb4bc in trap_pfault (frame=0xfffffe008a636a00, usermode=false, signo=, ucode=) __pc = 0x0 __pc = 0x0 __pc = 0x0 td = p = eva = 136 map = ftype = rv = #7 No locals. #8 device_get_softc (dev=dev@entry=0x0) at /opt/src/git-src/sys/kern/subr_bus.c:2141 No locals. #9 0xffffffff80429385 in acpi_wake_sleep_prep (handle=0xfffff80007706e00, stype=POWER_STYPE_POWEROFF) at /opt/src/git-src/sys/dev/acpica/acpi.c:3689 prw = {gpe_handle = 0x0, gpe_bit = 27, lowest_wake = 3, power_res = {{ Type = 0, Integer = {Type = 0, Value = 0}, String = {Type = 0, Length = 0, Pointer = 0x0}, Buffer = {Type = 0, Length = 0, Pointer = 0x0}, Package = {Type = 0, Count = 0, Elements = 0x0}, Reference = {Type = 0, ActualType = 0, Handle = 0x0}, Processor = {Type = 0, ProcId = 0, PblkAddress = 0, PblkLength = 87678488}, PowerResource = { Type = 0, SystemLevel = 0, ResourceOrder = 0}}, {Type = 369, Integer = {Type = 369, Value = 8}, String = {Type = 369, Length = 0, Pointer = 0x8 }, Buffer = {Type = 369, Length = 0, Pointer = 0x8 }, Buffer = {Type = 369, Length = 0, Pointer = 0x8 }, Package = {Type = 369, Count = 0, Elements = 0x8}, Reference = { Type = 369, ActualType = 0, Handle = 0x8}, Processor = { Type = 369, ProcId = 0, PblkAddress = 8, PblkLength = 0}, PowerResource = {Type = 369, SystemLevel = 0, ResourceOrder = 8}}, {Type = 2159484735, Integer = { Type = 2159484735, Value = 0}, String = {Type = 2159484735, Length = 4294967295, Pointer = 0x0}, Buffer = { Type = 2159484735, Length = 4294967295, Pointer = 0x0}, Package = {Type = 2159484735, Count = 4294967295, Elements = 0x0}, Reference = {Type = 2159484735, ActualType = 4294967295, Handle = 0x0}, Processor = { Type = 2159484735, ProcId = 4294967295, PblkAddress = 0, PblkLength = 87678488}, PowerResource = {Type = 2159484735, SystemLevel = 4294967295, ResourceOrder = 0}}, {Type = 458, Integer = {Type = 458, Value = 8}, String = {Type = 458, Length = 0, Pointer = 0x8 }, Buffer = {Type = 458, Length = 0, Pointer = 0x8 }, Package = {Type = 458, Count = 0, Elements = 0x8}, Reference = { Type = 458, ActualType = 0, Handle = 0x8}, Processor = { Type = 458, ProcId = 0, PblkAddress = 8, PblkLength = 0}, PowerResource = {Type = 458, SystemLevel = 0, ResourceOrder = 8}}, {Type = 2159484735, Integer = { Type = 2159484735, Value = 18446741877008067488}, String = { Type = 2159484735, Length = 4294967295, Pointer = 0xfffffe008a636ba0 "\300kc\212"}, Buffer = { Type = 2159484735, Length = 4294967295, Pointer = 0xfffffe008a636ba0 "\300kc\212"}, Package = { Type = 2159484735, Count = 4294967295, Elements = 0xfffffe008a636ba0}, Reference = { Type = 2159484735, ActualType = 4294967295, Handle = 0xfffffe008a636ba0}, Processor = {Type = 2159484735, ProcId = 4294967295, PblkAddress = 18446741877008067488, PblkLength = 2154715683}, PowerResource = {Type = 2159484735, SystemLevel = 4294967295, ResourceOrder = 2321771424}}, { Type = 87678488, Integer = {Type = 87678488, Value = 18446735277723512832}, String = {Type = 87678488, Length = 4294965248, Pointer = 0xfffff80006607000 "\300\321G\204\377\377\377\377\020 "}, Buffer = {Type = 87678488, Length = 4294965248, Pointer = 0xfffff80006607000 "\300\321G\204\377\377\377\377\020 "}, Package = {Type = 87678488, Count = 4294965248, Elements = 0xfffff80006607000}, Reference = {Type = 87678488, ActualType = 4294965248, Handle = 0xfffff80006607000}, Processor = {Type = 87678488, ProcId = 4294965248, PblkAddress = 18446735277723512832, PblkLength = 87678464}, PowerResource = {Type = 87678488, SystemLevel = 4294965248, ResourceOrder = 106983424}}, {Type = 663, Integer = { Type = 663, Value = 18446735277704207896}, String = { Type = 663, Length = 0, Pointer = 0xfffff8000539de18 ""}, Buffer = {Type = 663, Length = 0, Pointer = 0xfffff8000539de18 ""}, Package = {Type = 663, Count = 0, Elements = 0xfffff8000539de18}, Reference = { Type = 663, ActualType = 0, Handle = 0xfffff8000539de18}, Processor = {Type = 663, ProcId = 0, PblkAddress = 18446735277704207896, PblkLength = 2165581152}, PowerResource = {Type = 663, SystemLevel = 0, ResourceOrder = 87678488}}, {Type = 87678464, Integer = { Type = 87678464, Value = 8}, String = {Type = 87678464, Length = 4294965248, Pointer = 0x8 }, Buffer = {Type = 87678464, Length = 4294965248, Pointer = 0x8 }, Package = {Type = 87678464, Count = 4294965248, Elements = 0x8}, Reference = {Type = 87678464, ActualType = 4294965248, Handle = 0x8}, Processor = {Type = 87678464, ProcId = 4294965248, PblkAddress = 8, PblkLength = 2321771456}, PowerResource = {Type = 87678464, SystemLevel = 4294965248, ResourceOrder = 8}}}, power_res_count = 0} dev = 0x0 sc = sstate = #10 acpi_wake_prep (handle=0xfffff80007706e00, level=, context=, status=) at /opt/src/git-src/sys/dev/acpica/acpi.c:3764 stype = POWER_STYPE_POWEROFF #11 0xffffffff803756db in AcpiNsWalkNamespace (Type=Type@entry=6, StartNode=, StartNode@entry=0xfffff800050b3880, MaxDepth=MaxDepth@entry=100, Flags=Flags@entry=1, DescendingCallback=DescendingCallback@entry=0xffffffff80429320 , AscendingCallback=AscendingCallbac k@entry=0x0, Context=0xfffffe008a636ce4, ReturnValue=0x0) at /opt/src/git-src/sys/contrib/dev/acpica/components/namespace/nswalk.c:484 NodePreviouslyVisited = 0 '\000' ParentNode = 0xfffff800050b14c0 ChildNode = 0xfffff80007706e00 ChildType = 6 Level = 2 Status = 0 MutexStatus = #12 0xffffffff80375c45 in AcpiWalkNamespace (Type=Type@entry=6, StartObject=0xfffff800050b3880, MaxDepth=MaxDepth@entry=100, DescendingCallback=0xffffffff80429320 , AscendingCallback=AscendingCallback@entry=0x0, Context=Context@entry=0xfffffe008a636ce4, ReturnValue=) at /opt/src/git-src/sys/contrib/dev/acpica/components/namespace/nsxfeval.c:809 Status = 0 #13 0xffffffff80426384 in acpi_wake_prep_walk (stype=POWER_STYPE_POWEROFF) at /opt/src/git-src/sys/dev/acpica/acpi.c:3777 sb_handle = 0xfffff800050b3880 #14 acpi_shutdown (dev=0xfffff80007716e00) at /opt/src/git-src/sys/dev/acpica/acpi.c:878 No locals. #15 0xffffffff8074c706 in DEVICE_SHUTDOWN (dev=0xfffff80007716e00) at ./device_if.h:262 rc = _m = _cep = _ce = _desc = #16 device_shutdown (dev=0xfffff80007716e00) at /opt/src/git-src/sys/kern/subr_bus.c:2753 No locals. #17 bus_generic_shutdown (dev=) at /opt/src/git-src/sys/kern/subr_bus.c:3563 child = #18 0xffffffff8074c706 in DEVICE_SHUTDOWN (dev=0xfffff800051b8200) at ./device_if.h:262 rc = _m = _cep = _ce = #16 device_shutdown (dev=0xfffff80007716e00) at /opt/src/git-src/sys/kern/subr_bus.c:2753 No locals. #17 bus_generic_shutdown (dev=) at /opt/src/git-src/sys/kern/subr_bus.c:3563 child = #18 0xffffffff8074c706 in DEVICE_SHUTDOWN (dev=0xfffff800051b8200) at ./device_if.h:262 rc = _m = _cep = _ce = _desc = #19 device_shutdown (dev=0xfffff800051b8200) at /opt/src/git-src/sys/kern/subr_bus.c:2753 No locals. #20 bus_generic_shutdown (dev=) at /opt/src/git-src/sys/kern/subr_bus.c:3563 child = #21 0xffffffff80750d06 in DEVICE_SHUTDOWN (dev=0xfffff800051b8500) at ./device_if.h:262 rc = _m = _cep = _ce = _desc = #22 device_shutdown (dev=0xfffff800051b8500) at /opt/src/git-src/sys/kern/subr_bus.c:2753 No locals. #23 root_bus_module_handler (mod=, what=, arg=) at /opt/src/git-src/sys/kern/subr_bus.c:5211 No locals. #24 0xffffffff806e534b in module_shutdown (arg1=, arg2=) at /opt/src/git-src/sys/kern/kern_module.c:101 mod = 0xfffff800051d3b00 #25 0xffffffff8070d3d3 in kern_reboot (howto=16392) at /opt/src/git-src/sys/kern/kern_shutdown.c:527 _ep = _t = 0xfffff800050e9f40 _el = 0xfffff800050e4600 once = 1 __pc = 0x0 #26 0xffffffff8070cd9c in sys_reboot (td=0xfffff80006607000, uap=0xfffff80006607428) at /opt/src/git-src/sys/kern/kern_shutdown.c:308 error = 5 #27 0xffffffff80aebe69 in syscallenter (td=0xfffff80006607000) at /opt/src/git-src/sys/amd64/amd64/../../kern/subr_syscall.c:193 se = 0xffffffff81054310 p = 0xfffffe0081002010 sa = 0xfffff80006607418 error = sy_thr_static = true traced = _audit_entered = #28 amd64_syscall (td=0xfffff80006607000, traced=0) at /opt/src/git-src/sys/amd64/amd64/trap.c:1208 ksi = {ksi_link = {tqe_next = 0xfffffe008a636f30, tqe_prev = 0xffffffff80aeae4d }, ksi_info = { si_signo = -1973195040, si_errno = -512, si_code = -2139594896, si_pid = -1, si_uid = 25088, si_status = -2047, si_addr = 0x800000000000, si_value = {sival_int = -860430388, sival_ptr = 0x326493c1ccb6dfcc, sigval_int = -860430388, sigval_ptr = 0x326493c1ccb6dfcc}, _reason = {_fault = { _trapno = 3}, _timer = {_timerid = 3, _overrun = 0}, _mesgq = { _mqd = 3}, _poll = {_band = 3}, _capsicum = {_syscall = 3}, __spare__ = {__spare1__ = 3, __spare2__ = {106984784, -2048, -1973194752, -512, -2126868952, -1, 106983424}}}}, ksi_flags = -2130704888, ksi_sigq = 0x7} #29 No locals. #30 0x000000000028bb1a in ?? () -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org e**(i*pi)+1=0 From nobody Tue Sep 16 06:57:08 2025 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 4cQt4N2KMkz68Rd8; Tue, 16 Sep 2025 06:57:08 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQt4N183vz3YTM; Tue, 16 Sep 2025 06:57:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758005828; 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=EsiL77LZTTko3dsxzrTqEiMeqZlXIAz4Qc2RgPtOHgk=; b=Mqz+dLVEaIBXVvYOxKTCj/MiygAj6P3K1GIgPmrhDXD9OfNurU/o2hqCgL/BTkzDh2b4HJ Md3+LREHX8td/iZByEYQadFW9R1s4h3U3wDtGrMkWnANMlpFd+tMQBgSU29nP+EYoMKINy fqDR8iUs6gvRWtGfXWQyUBJZbpnJ26X5fktcrxis7es7WRceIQSgsNA2VngaNxengwvPAd vzxw7ka8hrAPHOvn1D3obFi6zPA9k50bk+g/ixjAjimwY4RoOrnOHikZANFTBpoU77S7pm vho/Ln/5SBE3fAdrW3BVPR5W0tr63F6V+cHv0qgwlLQMjvwRPVYg2gHUNGdFQQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758005828; 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=EsiL77LZTTko3dsxzrTqEiMeqZlXIAz4Qc2RgPtOHgk=; b=BixuvDkyGZInoHyrcGUqsCEItpm7R4Qjru1M2ZmNJ8sMuU4RjMcXP3QALJ6hD5Y/3qL60K X8g1qO9QpSP/4y5qSJ2z8uSm10du8GLudLk61I1O0OobneZJztmRtTB/0Ntch/ITvbLRGO ACNjh46MQiiweT8+hc2047gvnTdDKBqdlIxwdXxedZc/Q3PcRsbmR3LPeyFIbBWSTNLk6Q ndXcmEGWbTdqyKvQwsXzKzOdsMb2LL3J11DY6O7I7F9d3LGcCEIdNDd130lzHoap4EGPCJ XjXb0BGiH2kF19xqOwG5ov/7aZyP+Ba9CvsHxyCPcGvHuSTlNNlxTFThQBsUqw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758005828; a=rsa-sha256; cv=none; b=Bg2vS19j6qMT62HiMoNhJs378Thx/+d1U6w9+SjSYah5FYH7GWLCwcS4bTY7vgsfFNwbT5 b4K7w0QsHHOZAcIZMyJmdIHl0LpkiXZQyPf3WV6DYIHcHd5ZS4CZ9biNOStUzGDxJ0CAoA WS2s6jag1XbhKgvEXSMnxq8J0UirDxYtbs/AObE0M+b9Ozagk+Nl4UPHh2jtRZwZXbRbDj eTB1vao7DcI1RUkiW0Xfg3489W2gV+Vqg/Rr3NP/Z/EFU+aB7KVAJL8RL4dr+7mQTtTnH7 WuBc+y6a8q1pEaFDF4gsKOdro4p/hrvQ2wqelEAMMfucpqOuVoMs5iGACOHAXw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQt4N0fYQzTyc; Tue, 16 Sep 2025 06:57:08 +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 58G6v8dJ070908; Tue, 16 Sep 2025 06:57:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G6v843070905; Tue, 16 Sep 2025 06:57:08 GMT (envelope-from git) Date: Tue, 16 Sep 2025 06:57:08 GMT Message-Id: <202509160657.58G6v843070905@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Corvin =?utf-8?Q?K=C3=B6hne?= Subject: git: effcd0ded0ef - main - bhyve: assign a valid INTPIN to NVIDIA GPUs 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: corvink X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: effcd0ded0ef1c92bef29c1e9bbf517c97bb45b8 Auto-Submitted: auto-generated The branch main has been updated by corvink: URL: https://cgit.FreeBSD.org/src/commit/?id=effcd0ded0ef1c92bef29c1e9bbf517c97bb45b8 commit effcd0ded0ef1c92bef29c1e9bbf517c97bb45b8 Author: Corvin Köhne AuthorDate: 2022-03-17 12:11:14 +0000 Commit: Corvin Köhne CommitDate: 2025-09-16 06:55:09 +0000 bhyve: assign a valid INTPIN to NVIDIA GPUs When passing an NVIDIA GPU to a Linux VM, the GPU driver refuses to work and complains about a missing IRQ: [ 77.208984] NVRM: Can't find an IRQ for your NVIDIA card! [ 77.212697] NVRM: Please check your BIOS settings. [ 77.212699] NVRM: [Plug & Play OS] should be set to NO [ 77.212700] NVRM: [Assign IRQ to VGA] should be set to YES [ 77.212702] nvidia: probe of 0000:00:07.0 failed with error -1 By setting a valid INTPIN in the PCI config space those error messages disappear. Additionally, tools like nvidia-smi are able to detect the GPU and the GPU driver seems to work properly. Note that bhyve still doesn't support legacy interrupts. So, the guest shouldn't try to use it even though we're assigning an INTPIN. Reviewed by: jhb Tested by: chuck MFC after: 1 week Sponsored by: Beckhoff Automation GmbH & Co. KG Differential Revision: https://reviews.freebsd.org/D51892 --- usr.sbin/bhyve/amd64/Makefile.inc | 1 + usr.sbin/bhyve/pci_passthru_quirks.c | 48 ++++++++++++++++++++++++++++++++++++ 2 files changed, 49 insertions(+) diff --git a/usr.sbin/bhyve/amd64/Makefile.inc b/usr.sbin/bhyve/amd64/Makefile.inc index 92e53433ff01..50a011ed4bfd 100644 --- a/usr.sbin/bhyve/amd64/Makefile.inc +++ b/usr.sbin/bhyve/amd64/Makefile.inc @@ -13,6 +13,7 @@ SRCS+= \ pci_gvt-d.c \ pci_lpc.c \ pci_passthru.c \ + pci_passthru_quirks.c \ pctestdev.c \ pm.c \ post.c \ diff --git a/usr.sbin/bhyve/pci_passthru_quirks.c b/usr.sbin/bhyve/pci_passthru_quirks.c new file mode 100644 index 000000000000..5ba0e674f311 --- /dev/null +++ b/usr.sbin/bhyve/pci_passthru_quirks.c @@ -0,0 +1,48 @@ +/*- + * SPDX-License-Identifier: BSD-2-Clause + * + * Copyright (c) 2025 Beckhoff Automation GmbH & Co. KG + * Author: Corvin Köhne + */ + +#include + +#include + +#include "pci_passthru.h" + +#define PCI_VENDOR_NVIDIA 0x10DE + +static int +nvidia_gpu_probe(struct pci_devinst *const pi) +{ + struct passthru_softc *sc; + uint16_t vendor; + uint8_t class; + + sc = pi->pi_arg; + + vendor = pci_host_read_config(passthru_get_sel(sc), PCIR_VENDOR, 0x02); + if (vendor != PCI_VENDOR_NVIDIA) + return (ENXIO); + + class = pci_host_read_config(passthru_get_sel(sc), PCIR_CLASS, 0x01); + if (class != PCIC_DISPLAY) + return (ENXIO); + + return (0); +} + +static int +nvidia_gpu_init(struct pci_devinst *const pi, nvlist_t *const nvl __unused) +{ + pci_set_cfgdata8(pi, PCIR_INTPIN, 1); + + return (0); +} + +static struct passthru_dev nvidia_gpu = { + .probe = nvidia_gpu_probe, + .init = nvidia_gpu_init, +}; +PASSTHRU_DEV_SET(nvidia_gpu); From nobody Tue Sep 16 07:39:04 2025 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 4cQv0m4C7tz68VP7; Tue, 16 Sep 2025 07:39:04 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQv0m3JzNz3cFN; Tue, 16 Sep 2025 07:39:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758008344; 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=7R3LsFnlCyrNUYTVSnpjU5vf9teRwx0sS0Vt1BHfSlY=; b=E1d9G20SkaOXyG3VqmJ71ahNwMJeDcPglV72VDCd+qr/p9SHXN6p8JZEmsxLEMAUNLfDeA TOld6Ufr8JryP7Bc5f7Znp72Jzb1CkLeJbfP3+T4vqyUi7DofD9JqtXmxbLpgwkTBjw+ve fHlNMGoHdFaEXG8KxuoN+JrAO7vgWrpWYMCbyvFKi6eozOHADCpgrhgMdMRONEcLsb46wu DHP4Tdh2tN3A2+0b3pRF9S/Q9Xmlen6QVdYy+a+Y8s8XVeCVSBr7rxGuVn/Ef5+UK8fGn8 wJn2m6LsGDMjd+dSQr70IYjHkgU9KFW6IfRITOLmyESclWA5o1pdUcDZyk0Wyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758008344; 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=7R3LsFnlCyrNUYTVSnpjU5vf9teRwx0sS0Vt1BHfSlY=; b=odeE+KSsIZ8f8Tvnz2DrC6+pJPoSFCNfCQZ99fnrIk6IMrMhroFYys7reQU+Fi+2Z1+Mrj 4t1LnouNWGckf9skTwGVRAsnn07PMAx/W8wM/RuSUjs9RKUlcSfb3U6jXyeL7aJDNqgP2z ISf5eCznLHgS+NXB0kmVlc5o61DENIDgDJXnMqjdKYE4FQJLbChr+ds1zY3SKxcg8CCkQv 4GErVNq4izCzvgbhB7P8/fQlDZ5aH8yGdNnIUjkIamlXOteWmjPgEBtBa5nzZaUAfptsVk i8JIJlZTaXjDLRYhKIsvgjB5y9IQPVEhFk/NP4MZykhQI/aQk41FNZAo5FD5mw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758008344; a=rsa-sha256; cv=none; b=i48hmM2+w4srt7oEyCr87txsc2oSzRN9OkEWwDTDXhWxyQDEnQXCsNHSLhDRL5yLC2CnO+ T9CKr9fKMcd4jWjW4Lh9s9qMK+0M2DphAik2MuPnZe32K6tqU8AbHbMNm+y3LFjjaRHwje Al3UMRz3KO1pqAjrla6oUI10LmSW+fuR4CQM02vG+2yvFwXemNiK3Ub+Cw9XxxGy39PxKN bobGygDrcY+riLvF9w/x+/sXuB3ChAhUxnxSgF/VYG22iR7FeAgGTX/usAdA9FyKlL/cje qfl30f+AgnwLwzjVyg+B/W1k1z41WbCvKC7kyuBMpYcd64aodhNqXJ8VXyGtog== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQv0m2jCPzXGq; Tue, 16 Sep 2025 07:39:04 +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 58G7d4C7047491; Tue, 16 Sep 2025 07:39:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G7d4gr047488; Tue, 16 Sep 2025 07:39:04 GMT (envelope-from git) Date: Tue, 16 Sep 2025 07:39:04 GMT Message-Id: <202509160739.58G7d4gr047488@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: "Andrey V. Elsukov" Subject: git: 588a5fad3e8b - main - IPv6: fix off-by-one in pltime and vltime expiration checks 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: ae X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 588a5fad3e8b98955b60707e3e92b8b43566e3f7 Auto-Submitted: auto-generated The branch main has been updated by ae: URL: https://cgit.FreeBSD.org/src/commit/?id=588a5fad3e8b98955b60707e3e92b8b43566e3f7 commit 588a5fad3e8b98955b60707e3e92b8b43566e3f7 Author: Andrey V. Elsukov AuthorDate: 2025-09-16 07:34:55 +0000 Commit: Andrey V. Elsukov CommitDate: 2025-09-16 07:34:55 +0000 IPv6: fix off-by-one in pltime and vltime expiration checks Previously, the macros used '>' instead of '>=' when comparing elapsed time against the preferred and valid lifetimes. This caused any deprecated address to become usable again for one extra second after receiving each Router Advertisement. In that short window, the address could be selected as a source for outgoing connections. Update the checks to use '>=' so that addresses are deprecated or invalid when their lifetime expires. PR: 289177 Reported by: Dmitry Nexus Reviewed by: zlei Submitted by: Marek Zarychta MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52323 --- sys/netinet6/in6.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netinet6/in6.h b/sys/netinet6/in6.h index 1ca846ebf514..67c3ccbb1be8 100644 --- a/sys/netinet6/in6.h +++ b/sys/netinet6/in6.h @@ -358,11 +358,11 @@ extern const struct in6_addr in6addr_linklocal_allv2routers; #define IFA6_IS_DEPRECATED(a) \ ((a)->ia6_lifetime.ia6t_pltime != ND6_INFINITE_LIFETIME && \ - (u_int32_t)((time_uptime - (a)->ia6_updatetime)) > \ + (u_int32_t)((time_uptime - (a)->ia6_updatetime)) >= \ (a)->ia6_lifetime.ia6t_pltime) #define IFA6_IS_INVALID(a) \ ((a)->ia6_lifetime.ia6t_vltime != ND6_INFINITE_LIFETIME && \ - (u_int32_t)((time_uptime - (a)->ia6_updatetime)) > \ + (u_int32_t)((time_uptime - (a)->ia6_updatetime)) >= \ (a)->ia6_lifetime.ia6t_vltime) #endif /* _KERNEL */ From nobody Tue Sep 16 09:21:31 2025 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 4cQxH01FSQz68dTf; Tue, 16 Sep 2025 09:21:32 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQxH00dJpz3pl2; Tue, 16 Sep 2025 09:21:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758014492; 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=MXo2hI+zyCmX5GqBQHo0yWktc1mhm6Bj4J0HE8UpoFw=; b=R/JWqkT6Im/9y0amUHJn9QBlzVbq5fA7Uj2f5FtUN7R4sieoyQ9YBUjJ2yjzaoC9GvlK8x UNLIFuyXEpYpnaUxc5f0uMmUEIe4qi8PDgPSm3PBCE5pC+xJ+15v54lt4r2HzO7oCqQb4F jM5u7At3XgWRiuDTcgudf8ItJnq0hxbB/K5qDShyg0Eo1KFcCgINKFKeaHfM3l/WjSkTKF AJQuvzOGfVrmCF5ZkX2NKeWvX5h2AnTSoSgQBovNS2Tgimevq1e7k2c3cE2zS86RdQDjg6 di93QhbfSgqYTDljn7F18YM2Khn1zGnNV3EfmGPh/nUj3n7470cz84blUfz7zQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758014492; 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=MXo2hI+zyCmX5GqBQHo0yWktc1mhm6Bj4J0HE8UpoFw=; b=dxajms3SsQe7kofEmJCXvT8Ms6uriWXwGLbEjBSEXXXEBRPtEBV5Upq0jmxYTD0o31tplW nRnuNoOkFpmfNvJVWdvrKe3Dzu4ME/g3OYfHgGVc5ZoCXmMK8kB5Fs+w9rBU9PWOI40omI 3N+cSJLmqCU4TQAmfGKS7zBfWAWvHWxSEVjEaD29bOYQsDr7X/C2rb3sNE4q7Xyv4uB/QG KurOArwdVXDPnMiFADhmh5+Z0ggVAGlRBoTCIpWmkbE8V9bIzAv/RoKLdekYwdQItUFzzs Jmss+3ITVNF4RgjGOVDI7IzCIQWtrPbzxOdWv5A3n+5NwSN9cj7ORlpn8MSM2w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758014492; a=rsa-sha256; cv=none; b=n1RwmS3KbVGEs7XdyfUzBXxu17bWiUtYAQfyAdCKleAMkkKh0dYBqx8VvCdpyG8VV3g5JU dYIG/oF0w/Rb3yX35yVen2qxsG+6IVoZrYrO5Gd7nd3tXQk1GMwDN0hrV9MKUkRUQbarzK 3G8+5wDJH4O3D9jHhsKuFvs/TwlmmnvSdt2HRbaYQ56GqCpj3bMHnf4CBh5H4n/Vg9ARaa l+prxPSNibVKzLa0wc8ENXeYZw/btwhjq34M3hQDiE9EE4/Hqg0cLk5/+WXpCPg0OFXgfB wzVioIdnhRch3MaJoPo/4bz6tgprUQaKSXJrSTrKagpDBBL+6iLy5uD5xJuaVg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQxH00CzczbR9; Tue, 16 Sep 2025 09:21:32 +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 58G9LVAd045195; Tue, 16 Sep 2025 09:21:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G9LVUr045192; Tue, 16 Sep 2025 09:21:31 GMT (envelope-from git) Date: Tue, 16 Sep 2025 09:21:31 GMT Message-Id: <202509160921.58G9LVUr045192@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Peter Holm Subject: git: 8af56f7e08c5 - main - stress2: Fix how the reproducer is run. Lingering threads seen before 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: pho X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8af56f7e08c54e8a79054fe0bf65eb6e50a09231 Auto-Submitted: auto-generated The branch main has been updated by pho: URL: https://cgit.FreeBSD.org/src/commit/?id=8af56f7e08c54e8a79054fe0bf65eb6e50a09231 commit 8af56f7e08c54e8a79054fe0bf65eb6e50a09231 Author: Peter Holm AuthorDate: 2025-09-16 09:18:20 +0000 Commit: Peter Holm CommitDate: 2025-09-16 09:18:20 +0000 stress2: Fix how the reproducer is run. Lingering threads seen before --- tools/test/stress2/misc/syzkaller61.sh | 26 ++++++++------------------ 1 file changed, 8 insertions(+), 18 deletions(-) diff --git a/tools/test/stress2/misc/syzkaller61.sh b/tools/test/stress2/misc/syzkaller61.sh index a25ae4cf00d8..d07f12b05b1a 100755 --- a/tools/test/stress2/misc/syzkaller61.sh +++ b/tools/test/stress2/misc/syzkaller61.sh @@ -1,15 +1,7 @@ #!/bin/sh -# Seen: -# [root@mercat1 /usr/src/tools/test/stress2/misc]# pgrep syzkaller61 | xargs procstat -k -# PID TID COMM TDNAME KSTACK -# 13332 106396 syzkaller61 - mi_switch thread_suspend_check ast_suspend ast_handler ast doreti_ast -# 13332 560662 syzkaller61 - mi_switch sleepq_switch sleepq_catch_signals sleepq_wait_sig _sleep umtxq_sleep do_wait __umtx_op_wait_uint_private sys__umtx_op amd64_syscall fast_syscall_common -# 13332 560776 syzkaller61 - mi_switch thread_suspend_switch thread_single fork1 sys_rfork amd64_syscall fast_syscall_common -# 13662 356440 syzkaller61 - mi_switch thread_suspend_check ast_suspend ast_handler ast doreti_ast -# 13662 561098 syzkaller61 - mi_switch sleepq_switch sleepq_catch_signals sleepq_wait_sig _sleep umtxq_sleep do_wait __umtx_op_wait_uint_private sys__umtx_op amd64_syscall fast_syscall_common -# 13662 561160 syzkaller61 - mi_switch thread_suspend_switch thread_single fork1 sys_rfork amd64_syscall fast_syscall_common -# [root@mercat1 /usr/src/tools/test/stress2/misc]# +# "panic: inconsistent boundary count 2" seen. +# Fixed by: 8321d0da2ce2 - main - kern/kern_thread.c: improve assert in thread_single_end() [ `uname -p` != "amd64" ] && exit 0 @@ -276,7 +268,7 @@ void execute_call(int call) { switch (call) { case 0: - NONFAILING(*(uint32_t*)0x20001f00 = 0x16); + NONFAILING(*(uint32_t*)0x20001f00 = 0x16); /* SIGTTOU */ NONFAILING(*(uint32_t*)0x20001f04 = 0); NONFAILING(*(uint32_t*)0x20001f08 = 0); NONFAILING(*(uint32_t*)0x20001f0c = 0); @@ -302,18 +294,16 @@ mycc -o /tmp/syzkaller61 -Wall -Wextra -O0 /tmp/syzkaller61.c -lpthread || (cd ../testcases/swap; ./swap -t 3m -i 10 -l 100 > /dev/null 2>&1) & for i in `jot 300`; do - (cd /tmp; timeout -k 3s 2s ./syzkaller61) & + (cd /tmp; su -m $testuser -c ./syzkaller61) & pids="$pids $!" done sleep 5 -pkill -9 syzkaller61 swap; sleep 1 -pgrep -q syzkaller61 && { pgrep syzkaller61 | xargs ps -lHp; exit 1; } -for pid in $pids; do - wait $pid -done +kill -9 $pids +wait $pids +while pkill -9 syzkaller61; do :; done while pkill swap; do :; done wait rm -rf /tmp/syzkaller61 /tmp/syzkaller61.c /tmp/syzkaller61.core \ /tmp/syzkaller.?????? -exit 0 +exit 0 From nobody Tue Sep 16 09:21:33 2025 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 4cQxH12NQrz68dcg; Tue, 16 Sep 2025 09:21: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cQxH11rqbz3pT0; Tue, 16 Sep 2025 09:21:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758014493; 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=G6XTEwlIYcBL7C/hWJznqhTYaxbyYih/Gw1d+kP9Yps=; b=u5UNXimRWYS6HOQMxRCLZ5X1nl7dFlEHYXueVCqWGe6qZm8ZYPR6DdhbHMIAqUKPgXVzkr 0RpfjXSScJi7Map00osqtzOZqoagxIsiVKptLbEKDtNx5OFyiPTwq57kDbU8WcnK9AdO0n 5WihwEnDkJBX5R7/oquYlMishP2GRFavEtX8FUMnMvTCt/u4AfNS03zsHUmdIa0Cyf/7v/ NZR1REjHMCCwernCrT1ipjj+m1pNJpiMocBWLS729qL4I5GCAJUVQkurUNUz6zHZgpQy// +8brkKJfFCF4TF3lMQTMIRD3FK4J9S6EziZrwfiBgDcp+ItQRE8/gKz2Or/VTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758014493; 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=G6XTEwlIYcBL7C/hWJznqhTYaxbyYih/Gw1d+kP9Yps=; b=I6HDwTmYZNuELGSQfmkzPdXrdCaHtsIq+hjrGxDkW2u99rTYIeIRxMoaC/CGbf73o1flFH eZtcjChRXMjENbYZvI6S3xEM6kgqccVFF75gx9HQnU8z9LuRfpfXsQ9bYbVQBc6/ejOq06 4/5Vi1Qixz8pgxXNaQ6WLWlH+vCCL5UXRJZi6EwCkyAIOz4AtpNIUoGmIGKfgMl1Z1x2q0 ThzsdwpkUh3oNo6FEy0sbI/5FQWEGscGNGIpAVcfrnyU+vJHTk51gUxsQ7ki40NQQ38OEJ HHGOdenO9Qu92mF2Jc1ejrx7YoambgrEicv84HmKtzsSXQaeb50027/Dnev7XQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758014493; a=rsa-sha256; cv=none; b=gJl4RqD+fGJ1ZYHu8uzg+YswoUs83G1+LFPl43cpGFfd/gyDzAwP/VwzxMLY4GoVbhL60G a+HEhxWsvIJawl1fLmByQ9XTF9l7A0Rv71wc04ayRQNXviJ4eQVAf6TGvoTkLjG9IczuCl 3PqvZbBXbI/NxAwwWH/tO8n0+YnsKgF0kBwSUF0TiB8E0jBfisr2tOIk+Nav7ypnCORP1l gvXobRW1aYtNkUvIoFp/hqBvzEbzcbyiPbbXmTWpG5mCFn/N4t4Rj+ZubtrPnEkQWpTnVl +GY5WDYJBSm2DoabAqHz2Lmzy1gotwvUn88sy5VWE1OZvTji9njz9blcusDUyg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cQxH11RJjzbRB; Tue, 16 Sep 2025 09:21:33 +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 58G9LXr2045230; Tue, 16 Sep 2025 09:21:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58G9LXoI045227; Tue, 16 Sep 2025 09:21:33 GMT (envelope-from git) Date: Tue, 16 Sep 2025 09:21:33 GMT Message-Id: <202509160921.58G9LXoI045227@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Peter Holm Subject: git: da20d88599d5 - main - stress2: Added two new fdescfs test scenarios 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: pho X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: da20d88599d52667c9cd422632302cf5e2e19938 Auto-Submitted: auto-generated The branch main has been updated by pho: URL: https://cgit.FreeBSD.org/src/commit/?id=da20d88599d52667c9cd422632302cf5e2e19938 commit da20d88599d52667c9cd422632302cf5e2e19938 Author: Peter Holm AuthorDate: 2025-09-16 09:21:04 +0000 Commit: Peter Holm CommitDate: 2025-09-16 09:21:04 +0000 stress2: Added two new fdescfs test scenarios --- tools/test/stress2/misc/fdescfs2.sh | 44 ++++++++++++++++++++++++++++++++ tools/test/stress2/misc/fdescfs3.sh | 51 +++++++++++++++++++++++++++++++++++++ 2 files changed, 95 insertions(+) diff --git a/tools/test/stress2/misc/fdescfs2.sh b/tools/test/stress2/misc/fdescfs2.sh new file mode 100755 index 000000000000..21b82dcddd5e --- /dev/null +++ b/tools/test/stress2/misc/fdescfs2.sh @@ -0,0 +1,44 @@ +#!/bin/sh + +# +# Copyright (c) 2025 Peter Holm +# +# SPDX-License-Identifier: BSD-2-Clause +# + +# Test scenario description by: Kyle Evans + +# "panic: mtx_lock() of destroyed mutex 0xffffffff83717540 @ /usr/src/sys/fs/fdescfs/fdesc_vnops.c:151" seen + +[ `id -u ` -ne 0 ] && echo "Must be root!" && exit 1 +. ../default.cfg + +set -u + +kldstat | grep -q fdescfs.ko && { kldunload fdescfs.ko && wasloaded=1; } +while true; do + mount | grep -q "on $mntpoint " || + mount -t fdescfs dummy $mntpoint || continue + ls $mntpoint > /dev/null + if mount | grep -q "on $mntpoint "; then + if ! umount $mntpoint; then + umount -f $mntpoint || break + fi + fi +done > /dev/null 2>&1 & + +start=`date +%s` +while [ $((`date +%s` - start)) -lt 10 ]; do + kldstat | grep -q fdescfs.ko && + kldunload fdescfs.ko 2>/dev/null + sleep .1 + kldstat | grep -q fdescfs.ko || + kldload fdescfs.ko +done +kill %1 +wait +mount | grep -q "on $mntpoint " && umount $mntpoint +sleep .1 +set +u +[ $wasloaded ] || kldunload fdescfs.ko +exit 0 diff --git a/tools/test/stress2/misc/fdescfs3.sh b/tools/test/stress2/misc/fdescfs3.sh new file mode 100755 index 000000000000..eb24a6eac085 --- /dev/null +++ b/tools/test/stress2/misc/fdescfs3.sh @@ -0,0 +1,51 @@ +#!/bin/sh + +# +# Copyright (c) 2025 Peter Holm +# +# SPDX-License-Identifier: BSD-2-Clause +# + +[ `id -u ` -ne 0 ] && echo "Must be root!" && exit 1 + +. ../default.cfg + +mounts=15 # Number of parallel scripts +mdstart=$mdstart # Use md unit numbers from this point + +if [ $# -eq 0 ]; then + for i in `jot $mounts`; do + m=$(( i + mdstart - 1 )) + [ ! -d ${mntpoint}$m ] && mkdir ${mntpoint}$m + mount | grep "$mntpoint" | grep -q md$m && umount ${mntpoint}$m + done + ../testcases/swap/swap -t 2m -i 20 & + + # start the parallel tests + touch /tmp/$0 + for i in `jot $mounts`; do + m=$(( i + mdstart - 1 )) + ./$0 $m & + ./$0 find $m > /dev/null 2>&1 & + done + wait +else + if [ $1 = find ]; then + while [ -r /tmp/$0 ]; do + ls -lR ${mntpoint}* + done + else + + # The test: Parallel mount and unmounts + start=`date +%s` + while [ $((`date +%s` - start)) -lt 120 ]; do + m=$1 + mount -t fdescfs null ${mntpoint}$m + while mount | grep -qw $mntpoint$m; do + opt=$([ $((`date '+%s'` % 2)) -eq 0 ] && echo "-f") + umount $opt ${mntpoint}$m > /dev/null 2>&1 + done + done + rm -f /tmp/$0 + fi +fi From nobody Tue Sep 16 11:24:49 2025 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 4cR01F5qJLz68nmn; Tue, 16 Sep 2025 11:24:49 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR01F5H0lz46hG; Tue, 16 Sep 2025 11:24:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758021889; 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=TN1AvspHK7Jl0yfO4vns70pbURgOvEBoJvzRd1sTnUg=; b=BYXmoKFz9/x9kByOXllyqgwLElncASCIypKkEaDbYJoM3uSZcncYFdeA+KTI6b+iPYZKn7 skhHdLxJD77oP/tllw9M5IWsJRl08wiTj3Jb0pnTLNGdPq0f0BzK/oyY4UdzxwVO4XGsy0 wfP0cTLBHXOGsZ9lSzQx8sfSqexELG5xqSZxygqLYol1mcm0yhUkR3+IPeCb3pKj6fAo0j /Z02G7QKacfWxUQmwCYPY/0rjg+2gWDMzw18wTb96nGQ4jadHkMtcqu6B4bHcKvd4u5/Oy i62sbY+OefjC52kW9WUQxq95J4F493rtA4BdcHV2QL+GfsWD6LUpRKnHEAXL+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758021889; 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=TN1AvspHK7Jl0yfO4vns70pbURgOvEBoJvzRd1sTnUg=; b=IaNwVlArFDneMBvD+eWLudYREPf484JTmxPDooxZzG/rBmnUyAa6TUZjFYi1zX3O5Jaytq nM4I94ZhlLmSIXF3HfNYoRFm2cJgzORqhLTEWU8LLcVqdgdsBKSgxiiTz5HajRMw75QgLC hajWzxfm4UcF82L1z6xLzr4kwWxl+mxdbxy6+worrB8RImnrNMJASsa2Ap08iY2zkHsHhd yyNriupKVFfhFqgsCqfQTVjzMHbIT98d8xz1SLbO5LXuB7r4iM9W3gm/OpDdnKbZ1b8/27 cBlz1snBB4rnbXgWn6gpVrd9I4x/WyN/ss00hYL31sseckLw7X8ta4a6boZSdg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758021889; a=rsa-sha256; cv=none; b=QMCyvlHa1QFMZZHFnCOFKLUBw25yR14JmR4dWxMhGoLdId8jp48IRHEOY7OltNWVaJvzjd B2mBT6dhFAHSddJaOWY7QWwcU3sRGYJKAbJNRca4fWralZNyRX/y7M1ho4gAC+9ngz0fKg frKPI1QgUm28DGjagPXGq2JlCfszwko8TaKUVVLGaAG0qIlrMuLAWc86CHSADDlWHJMtGF 3oYxQtr4Ve8uJ/nWE0xiEnnYTlwb5Ou51JeBDnoTLukIH5/HkG8QWAQHrYyrxnNBLS6ls1 8tUVdLlxdQYpdNd4n65wr9SnJu58z6+THIn/kU8tNt0ioasyDNhA6DR9xLLjoQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR01F4bthzfSK; Tue, 16 Sep 2025 11:24:49 +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 58GBOneB079942; Tue, 16 Sep 2025 11:24:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GBOnSx079939; Tue, 16 Sep 2025 11:24:49 GMT (envelope-from git) Date: Tue, 16 Sep 2025 11:24:49 GMT Message-Id: <202509161124.58GBOnSx079939@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 7314f78b240b - main - aarch64: Clarify the initial adjustments to sp for kernel exception entry 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: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7314f78b240bdbf2bcec07e3d5a475e37941bb6b Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=7314f78b240bdbf2bcec07e3d5a475e37941bb6b commit 7314f78b240bdbf2bcec07e3d5a475e37941bb6b Author: John Baldwin AuthorDate: 2025-09-16 11:21:39 +0000 Commit: John Baldwin CommitDate: 2025-09-16 11:21:39 +0000 aarch64: Clarify the initial adjustments to sp for kernel exception entry The first store-pair instruction in save_registers_head decrements the stack pointer to create room for most of the trapframe (and the redzone area for nested exceptions). However, the expression was a bit non-intuitive as it was using an expression without a leading negative sign to adjust the stack pointer. Rewrite the expression so that it is more clearly a negative adjustment to the stack pointer. Suggested by: andrew Reviewed by: andrew Sponsored by: AFRL, DARPA Differential Revision: https://reviews.freebsd.org/D52514 --- sys/arm64/arm64/exception.S | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/arm64/arm64/exception.S b/sys/arm64/arm64/exception.S index 13095def8b00..6e673fbe5a43 100644 --- a/sys/arm64/arm64/exception.S +++ b/sys/arm64/arm64/exception.S @@ -43,9 +43,9 @@ .macro save_registers_head el .if \el == 1 mov x18, sp - stp x0, x1, [sp, #(TF_X - TF_SIZE - 128)]! + stp x0, x1, [sp, #-(TF_SIZE - TF_X + 128)]! .else - stp x0, x1, [sp, #(TF_X - TF_SIZE)]! + stp x0, x1, [sp, #-(TF_SIZE - TF_X)]! .endif stp x2, x3, [sp, #(2 * 8)] stp x4, x5, [sp, #(4 * 8)] From nobody Tue Sep 16 11:24:50 2025 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 4cR01H0CMtz68nwR; Tue, 16 Sep 2025 11:24:51 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR01G6W8mz46mG; Tue, 16 Sep 2025 11:24:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758021890; 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=bEVZC0Mermz2e62a/NuoQD0DB/SH9wcnNo5XRTFLq2g=; b=n1U4CY6R1Ze6JTFMMjhZLCbPlfCQX35Tx5x2/TIIogHy4psVNfpLUFXnApw4h+xBP2w+E9 Xnum/HoiqtTMD1CA3Z0rX/+rph3Hqg4SgFiQDLSHTfnEmAgDzp5qZ/MLZe5meH/M2sWd7U CQz+NLXsBEcnmn/GAlY83ST/EbbgaokEtmdDk6Cpkb4KxkiVWpUlka8vCEafkbpJO56832 KzdDv11oeiNh3btuF/ka6p9rIgXHmJpeA1wEiMtDC581k9pXWSSrGVYo9oI6OKbsEGqIAH GJMHTZ0vTdvtZppmx8GcfYknlQ27ZZw6+UcwGGtQ6heLjg3yxtXoUa/dA8pfzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758021890; 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=bEVZC0Mermz2e62a/NuoQD0DB/SH9wcnNo5XRTFLq2g=; b=t1ujUUAfsN+YqX6J/F15+rzZUwfsi8xpapVN85PMRw5GKgoEPNHkCz2wlcPXNaSVcs/Sze 2b+ZAwmx+zgGXPPDY4UbUSlqbJXDwG0LODsVacIlP9cE0KXDrb6JVpKCn5ycY4fAHsehiP VHZMYbdJrJXUmIDHBFJ88NV10x9CIaloP9FvrJ5BVqRzp6Bzap1A0eXFy6mQEXS/aEwntN Cb81KGsY3qbySxZPsy5NSnkKPZXasJiJCd1xgNxQnNbBkLvwpp/Nm0aVAy/1YZWu5iqwur GPdTAfl/H/tGCEUFDsAVRdqXS6OEt1P6CiH7CGprztURl1lADW9A4YxToNLxtQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758021890; a=rsa-sha256; cv=none; b=OnVutdqjvTh1DFzYHhe+W3Hm5zTJbd8ExhV+/RxHn0hjgpIOw13vZofJiSXiTrH9D213FV xHN2GtgPHfrgarnh5lQiXliCtT801y5zr55BWhvW0qsuRSjPVPgtTQvslDhklZEftdeutC 6jO0dyhjPP5wnZyV5TX23ogyHK9LBPqigSgiajdgIdgE9tDqWWMZRNgAElLo6Gsosrlzud pJQbwPoU8SosHi33rpCXD8itGUKDiLwY7pXgAt/Iao8XWZeuJT9xttkqLzbEkaPxLVJgzN 83WkdMKfNdws/lY4seAmVFgRSKANDfSOkbvk/PZkR3ebym9+Kand4tacaaonPg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR01G5JPczfb5; Tue, 16 Sep 2025 11:24:50 +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 58GBOorG079976; Tue, 16 Sep 2025 11:24:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GBOoWr079973; Tue, 16 Sep 2025 11:24:50 GMT (envelope-from git) Date: Tue, 16 Sep 2025 11:24:50 GMT Message-Id: <202509161124.58GBOoWr079973@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 99213b3c352c - main - aarch64: Save correct value of x18 on trapframe for nested faults 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: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 99213b3c352cdf568ea7cf5b4dddb1879f16a601 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=99213b3c352cdf568ea7cf5b4dddb1879f16a601 commit 99213b3c352cdf568ea7cf5b4dddb1879f16a601 Author: Konrad Witaszczyk AuthorDate: 2025-09-16 11:21:57 +0000 Commit: John Baldwin CommitDate: 2025-09-16 11:23:58 +0000 aarch64: Save correct value of x18 on trapframe for nested faults x18 is overwritten with a temporary copy of the kernel stack pointer when it is saved in the trapframe. This does not matter in terms of function since nested exception return does not restore x18 from the trapframe, but it does mean that examining x18 in a debugger in stack frames above a nested fault outputs the wrong register value. To fix, compute the value of the original stack pointer to save in x18 later after the trapframe has been constructed. Reviewed by: jhb, andrew Sponsored by: AFRL, DARPA Differential Revision: https://reviews.freebsd.org/D52472 --- sys/arm64/arm64/exception.S | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/arm64/arm64/exception.S b/sys/arm64/arm64/exception.S index 6e673fbe5a43..5a4181348a54 100644 --- a/sys/arm64/arm64/exception.S +++ b/sys/arm64/arm64/exception.S @@ -42,7 +42,6 @@ */ .macro save_registers_head el .if \el == 1 - mov x18, sp stp x0, x1, [sp, #-(TF_SIZE - TF_X + 128)]! .else stp x0, x1, [sp, #-(TF_SIZE - TF_X)]! @@ -61,7 +60,9 @@ stp x24, x25, [sp, #(24 * 8)] stp x26, x27, [sp, #(26 * 8)] stp x28, x29, [sp, #(28 * 8)] -.if \el == 0 +.if \el == 1 + add x18, sp, #(TF_SIZE - TF_X + 128) +.else mrs x18, sp_el0 .endif mrs x10, elr_el1 From nobody Tue Sep 16 13:22:30 2025 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 4cR2d22VdKz67Frd; Tue, 16 Sep 2025 13:22:30 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR2d21tn7z3P7m; Tue, 16 Sep 2025 13:22:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758028950; 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=5WP9eZtvK/MxeYCvlts6FEKj6phYKzHAlH+FBOC1Z6k=; b=FT/ICy1w8NOLfFE8i6yBEZZ/FYbh8+ZRX4RRD2hA/kItN+wgypHYjBi+qEo3UnIIoocDB4 oJehSUu3STkKTYpZOiO1wKsv85ugYG0aoD/fWEWyXs/ejBLkwInDANlgX9Owq4kPe2aYg6 fjVrgUGTO2rzcmiqzAp18gZHvG127ceTlA5x6gjvnlQaE8e1JvP1eSbEeTTNdxg5QwJVzm /5d2vG4HYRJDNCN0LrKpGgdUNWl2ZFa+157KVpT2uVyalcl/Mw9oDW1PPbFm+OCWPGCFVK uELXLLVRn+DAba9CTzN6M/ILc36y42LSQzIdUPKECLZCGnjmLwT2FQ57GPm9Yw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758028950; 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=5WP9eZtvK/MxeYCvlts6FEKj6phYKzHAlH+FBOC1Z6k=; b=h3MrHPSrEmqy8pPCnQAZLi5wNHMsZzx9lLjQJE6XTx9E4ESgL9pN2fG52fHInOWPtntZx2 Fh9KnNbzJrUU2M8FWDU4nx/Z85ydf8XcDETcSR/bRdzE9Hhkc0B0JQvOV4iVIYj0f9G35M X+pO5a0W8Kc2FWjD4xkb4PMunZMXITSjiF07xoX2eYXykmojIZ7FRDACKvWj66vtF3gCk8 mXqs3UDPwaznJ6i21cFPMcRyH9e6llX4G64VwgUxLBH/4raJBxHmghqxB0DaWkY6Ua92bf dQgVX0I0pSUSaUtiJ8ErfdXQSWHx0WObB7NZXaN1ut8R0KkuxTt8O4HHlTIm9w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758028950; a=rsa-sha256; cv=none; b=YnFuXp95vA8ibygLqJu1bDs5R2CuCmxPdckA4K4uCTd9Iybh+ctDv0xh2HCjFXFv+VLeYz YPJ5XLHo1osyEuifeOtUcH6zLmQoB6s0APAgAoZwwRqQycadk4aIob6bSvhJJnt5iFxykW HfG8kRn9/y7YZDuMWz1rnmbrcMPV4zKW9LOuNikFoTdMhx3CHnhX317YrE8Si7RZjd454W 8ISYTE2bd2Vswt4dMfczKnRZdHqkry+jzLPb1fIsyh239ciq2UKzoqUcBCLnSam7/RtyA9 B/fRU6i5vWYYV85s62ZLpf4+8KmmS6/7/KctXeIUd3a/RuUu7KOfqt3HQzF+wg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR2d21BrZzjyZ; Tue, 16 Sep 2025 13:22:30 +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 58GDMUw4005212; Tue, 16 Sep 2025 13:22:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDMUiN005209; Tue, 16 Sep 2025 13:22:30 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:22:30 GMT Message-Id: <202509161322.58GDMUiN005209@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mitchell Horne Subject: git: e13b5298ec87 - main - if_re: Add PNP info for module 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: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e13b5298ec87be03da2231bc7b44a6a4b976b850 Auto-Submitted: auto-generated The branch main has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=e13b5298ec87be03da2231bc7b44a6a4b976b850 commit e13b5298ec87be03da2231bc7b44a6a4b976b850 Author: Mitchell Horne AuthorDate: 2025-09-16 13:19:00 +0000 Commit: Mitchell Horne CommitDate: 2025-09-16 13:22:05 +0000 if_re: Add PNP info for module Add PNP info so it the module can be by devmatch(8) and automatically loaded. On non-x86 platforms it is not included in GENERIC. Reviewed by: imp MFC after: 3 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52557 --- sys/dev/re/if_re.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/dev/re/if_re.c b/sys/dev/re/if_re.c index 67864c2de388..d56c975a43d2 100644 --- a/sys/dev/re/if_re.c +++ b/sys/dev/re/if_re.c @@ -353,6 +353,8 @@ static driver_t re_driver = { DRIVER_MODULE(re, pci, re_driver, 0, 0); DRIVER_MODULE(miibus, re, miibus_driver, 0, 0); +MODULE_PNP_INFO("U16:vendor;U16:device;U32:#;D:#", pci, re, re_devs, + nitems(re_devs) - 1); #define EE_SET(x) \ CSR_WRITE_1(sc, RL_EECMD, \ From nobody Tue Sep 16 13:23:15 2025 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 4cR2dx26M3z67FZG; Tue, 16 Sep 2025 13:23:17 +0000 (UTC) (envelope-from des@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR2dx16bkz3PnK; Tue, 16 Sep 2025 13:23:17 +0000 (UTC) (envelope-from des@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758028997; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Cqu72eK4lHrNY8Gl61BnJqVSeu/luEgp9yrfYspqx74=; b=mNx7GDcLTsgat79xSLjtCf1m0P1e7UTGXrZ6rccSj7jdl0PyJhy44sXDO4TOIdd6OQU2KR tEdCZQAc3nI8UkoDKFbMk0MBuImLEfuJ9xI5lpu5hUpPziPUbv8U5IPuoq1hqj/i+9LZh0 Y9fkyl9a57jQoVLmeCc7q9JHP1C6fzcGQkNz0oRu79sKfhCnbjz7LKwDYR/e0wZ3ETLHGL mcn1Gwj0Enf2r7obkUn3kl4ofb4vG6UY/mXPVXpyllOwfzxVIsh0wmje6iXeEv90qvcjVm cH8C9oknqtwdWGHqKipocG8vnMwlPw1Kz+jRstkcbsDpLF4sPpxG7EUyHlwsCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758028997; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Cqu72eK4lHrNY8Gl61BnJqVSeu/luEgp9yrfYspqx74=; b=GpYlS/2wuJsd8nxWqr3jbVVoAOajQi6s4BkMt5exZ1VJGdn8zz1V6ayzhznNSYvXGUsTmR NA/lt3iWApeHEU4GtNYDF4KeF4x88Blz22XIJQYUyvEQWs2TliSLsO1HeDMCw+/9lwenAh 4yMD69hCdvRi46BWjfaHwJNheCwjr7b7wu17mtB4Xdj65F30kP0SXNYQlG1jVOA2KNIT1J 6uzVKYzAA8VA1FKlYEVN7+Hi2oo3qHjgH/GcNvkVf3qynVDr+J2z95Jkta4Ez3S5J/OW/Q 93aZUKr2K0F1Ws4fUFm3EvAbpSkirTqP9BhDp4Qn2Sg4VbaEzYT6hlQgKVuxQw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758028997; a=rsa-sha256; cv=none; b=y1r08g2M4pctaTp68G8uOIfSvDX9ZqZzBGLqBPWZoVnL2wVVyR5FvIIdV3I477f7n642KB AED6gJDdC3IDh7G08edARiTco7c95/Yv8ODkOYuReuRNtc53ZCw1WxWQZ5P0Wq63Ry2syd RKaM7ecMZxvfQGFG8DChvdqic0+1XK5YxewLJr9COMDPQqTIQUz4m5pr3nPBuR/2KdWAK9 yRPrjSayCxwxF2FuJy+a18P6HmGq53Z1DxY/Y3bDQz1YNdjnQVBvF/fauOJNSFxr1kokM2 ugshOSoLaq/BzPYs/NSbdeZvEtavK3lzDgKv5Ttxiwt2Zfy4FAJF9zxbI+Is0w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from ltc.des.dev (unknown [IPv6:2a01:e0a:c54:bed0:922e:16ff:fef1:acef]) (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) (Authenticated sender: des) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cR2dx06NDzNtD; Tue, 16 Sep 2025 13:23:16 +0000 (UTC) (envelope-from des@freebsd.org) Received: by ltc.des.dev (Postfix, from userid 1001) id 58C1384AED; Tue, 16 Sep 2025 15:23:15 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Mark Johnston Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: b2f5dc591ef2 - main - src.opts.mk: Remove REPRODUCIBLE_BUILD from the default list In-Reply-To: <202509081922.588JM1NX027953@gitrepo.freebsd.org> (Mark Johnston's message of "Mon, 8 Sep 2025 19:22:01 GMT") References: <202509081922.588JM1NX027953@gitrepo.freebsd.org> User-Agent: Gnus/5.13 (Gnus v5.13) Date: Tue, 16 Sep 2025 15:23:15 +0200 Message-ID: <86tt12fs58.fsf@ltc.des.dev> 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: quoted-printable Mark Johnston writes: > src.opts.mk: Remove REPRODUCIBLE_BUILD from the default list >=20=20=20=20=20 > It was added to the list in bsd.opts.mk in commit 4f81c42fbd76, so > should have been removed here. >=20=20=20=20=20 > Reported by: cperciva > Fixes: 4f81c42fbd76 ("share/mk: Substitute reproducible pref= ixes in dwarf info") > MFC after: 3 days > Sponsored by: The FreeBSD Foundation > Sponsored by: Klara, Inc. You forgot to regenerate src.conf.5. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@FreeBSD.org From nobody Tue Sep 16 13:38:29 2025 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 4cR2zT4kzZz67GNx; Tue, 16 Sep 2025 13:38:29 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR2zT4Qtjz3S3C; Tue, 16 Sep 2025 13:38:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758029909; 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=LUUypDfdsObtn6aV/ZefBB79oxTNdglc3B5ZttG9+v4=; b=DX0PUKvrB1yVP66gcAN1reA8D9YNLS+bO0xGk3l3IcHu705U6ymV/1bnqm5hf/ry0bSXcw 4L+xLAIPpEsz+2vjpHR1B4TjNd6HkkuQp22JTFLU3m99eKRrlANnyOdRYjCRD1K6y0i242 wCA3BS0fO3o0HwKpiOD6q1/ntMxCt0MKjtLQgri6IoD+xPIsUXHbEphP9oO7LhLDi44p0k xfurxZqWCJ6J1yK4aXVfCL5B3H73x0L27vMr44cWtX94pRKyeTE7P2N7EH+1E0zEN/b/qA d+7Dz/AkL8BCWsmSqO2pgmaPQ3O4J0RGMLEFKaI5GdU8j7vACA9RbjMih17SQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758029909; 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=LUUypDfdsObtn6aV/ZefBB79oxTNdglc3B5ZttG9+v4=; b=OPtvppCEdvfY3+o7MSFvUuygeWnOjtlvsgSDgG/ACwamtT/d9Ph7usdeB/Dm4I51c0y6nn ofOndPTXMyA2PVI+oaGpyg9ECJBW6FJ5W1j9DdjlDDZHXJAbbFueWR8HUokEg/991SJvRS p5vgOmXAUQ7oAKy0QIqO489vET8dY0zhZWIftT9GGTaQtvSPMP982eDfq4SPfJx+q0C+/6 gA5wX2aWa1YiEDi7gDh3tdz6saHx/VOA3IZ+pC2xGJa7Stj/CYBRwLqaef1V/QGhhNzcB3 M5uCGkpo3XmJFAJGHSIECjrCAxAhQQizNrIp8eFuPf/xhtMiwd40t3ayfiDA1w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758029909; a=rsa-sha256; cv=none; b=o0FF1tiLitu5AZWTGdYcgUSneOEBeLZR/vHMbNaIroRhkC6ci+Ju/VdJjscj8QMTCWPkV0 nkOcGpav2VdvF+hOS3dcnXAsVLzibsiEMQsncHOYTU0zt5vBJDqSQP+IfWHvh2Y13bLc87 J94xke52EQBhpYNkvuSqPt16MRY7wbSkDsh7gsyN0K84IKVxyst8Ly2tBnImRQ3pYcOEJY ElRCD65iCvKGtXR0XdIRdoKSm7VsgRnV3nhg1QIz3/nPRX5VJfO9ALQ9rmfWH0ISnkseco 9s7CXAj7H+CxUWkdkKu9qHckza2l4EnFZFjdMVUihi6PyIVOgs52CbODUVr57g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR2zT3yT0zk9k; Tue, 16 Sep 2025 13:38:29 +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 58GDcTaf026096; Tue, 16 Sep 2025 13:38:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDcTlF026093; Tue, 16 Sep 2025 13:38:29 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:38:29 GMT Message-Id: <202509161338.58GDcTlF026093@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 1a7a067da456 - main - stat: Add option to list holes 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: des X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1a7a067da456f8962ef87bfdf75c94cd12988615 Auto-Submitted: auto-generated The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=1a7a067da456f8962ef87bfdf75c94cd12988615 commit 1a7a067da456f8962ef87bfdf75c94cd12988615 Author: Dag-Erling Smørgrav AuthorDate: 2025-09-16 13:37:57 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:38:25 +0000 stat: Add option to list holes Add a new -h option that causes stat to print a list of holes for each file argument. Sponsored by: Klara, Inc. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D52481 --- usr.bin/stat/stat.1 | 45 +++++++++- usr.bin/stat/stat.c | 176 ++++++++++++++++++++++++++++++---------- usr.bin/stat/tests/stat_test.sh | 72 ++++++++++++++++ 3 files changed, 250 insertions(+), 43 deletions(-) diff --git a/usr.bin/stat/stat.1 b/usr.bin/stat/stat.1 index 2996781fafa6..55e64de0767e 100644 --- a/usr.bin/stat/stat.1 +++ b/usr.bin/stat/stat.1 @@ -6,6 +6,8 @@ .\" This code is derived from software contributed to The NetBSD Foundation .\" by Andrew Brown and Jan Schaumann. .\" +.\" Copyright (c) 2025 Klara, Inc. +.\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: @@ -27,7 +29,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd June 22, 2017 +.Dd September 9, 2025 .Dt STAT 1 .Os .Sh NAME @@ -36,7 +38,7 @@ .Nd display file status .Sh SYNOPSIS .Nm -.Op Fl FHLnq +.Op Fl FHhLnq .Op Fl f Ar format | Fl l | r | s | x .Op Fl t Ar timefmt .Op Ar @@ -129,6 +131,45 @@ and use instead of .Xr lstat 2 . This requires root privileges. +.It Fl h +For each file argument, print a line consisting of a comma-separated +list of holes, a space, and the file name. +Each hole is reported as its starting offset as a decimal number +followed by a hyphen and the ending offset (one less than the starting +offset of the data region that follows the hole) as a decimal number. +If the file ends in a hole, the ending offset of the final hole will +be one less than the size of the file. +Otherwise, the final entry in the list (indeed, the only entry in the +list, if the file is not sparse), is a single decimal number +corresponding to the size of the file, representing the virtual hole +at the end of the file. +.Pp +If the argument is a directory, instead of a list of holes, a single +number is printed, corresponding to the minimum hole size for that +directory as reported by +.Xr pathconf 2 , +followed by a space and the directory name. +.Pp +Please note that the only way to retrieve information about the holes +in a file is to open it and walk the list of holes and data regions +using +.Xr lseek 2 . +If the file is being modified by another process at the same time as +.Nm +is inspecting it, the result may be inconsistent. +.Pp +This option cannot be combined with the +.Fl F , +.Fl f , +.Fl H , +.Fl L , +.Fl l , +.Fl r , +.Fl s , +.Fl t , +or +.Fl x +options. .It Fl L Use .Xr stat 2 diff --git a/usr.bin/stat/stat.c b/usr.bin/stat/stat.c index 1fd8288728c1..0ed5d3ae5b53 100644 --- a/usr.bin/stat/stat.c +++ b/usr.bin/stat/stat.c @@ -7,6 +7,8 @@ * This code is derived from software contributed to The NetBSD Foundation * by Andrew Brown. * + * Copyright (c) 2025 Klara, Inc. + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -47,18 +49,19 @@ __RCSID("$NetBSD: stat.c,v 1.33 2011/01/15 22:54:10 njoly Exp $" #endif /* HAVE_CONFIG_H */ #include -#include #include #include #include #include #include +#include #include #include #include #include #include +#include #include #include #include @@ -178,22 +181,24 @@ __RCSID("$NetBSD: stat.c,v 1.33 2011/01/15 22:54:10 njoly Exp $" #define SHOW_filename 'N' #define SHOW_sizerdev 'Z' -void usage(const char *); -void output(const struct stat *, const char *, - const char *, int, int); -int format1(const struct stat *, /* stat info */ +static void usage(const char *); +static void output(const struct stat *, const char *, const char *, int); +static int format1(const struct stat *, /* stat info */ const char *, /* the file name */ const char *, int, /* the format string itself */ char *, size_t, /* a place to put the output */ int, int, int, int, /* the parsed format */ int, int); -int hex2byte(const char [2]); +static int hex2byte(const char [2]); #if HAVE_STRUCT_STAT_ST_FLAGS -char *xfflagstostr(unsigned long); +static char *xfflagstostr(unsigned long); #endif +static int fdlistholes(int, const char *); +static int listholes(const char *); static const char *timefmt; static int linkfail; +static bool nonl; #define addchar(s, c, nl) \ do { \ @@ -205,20 +210,22 @@ int main(int argc, char *argv[]) { struct stat st; - int ch, rc, errs, am_readlink; - int lsF, fmtchar, usestat, nfs_handle, fn, nonl, quiet; - const char *statfmt, *options, *synopsis; char dname[sizeof _PATH_DEV + SPECNAMELEN] = _PATH_DEV; - fhandle_t fhnd; + const char *statfmt, *options, *synopsis; const char *file; + fhandle_t fhnd; + int ch, rc, errs, am_readlink, fn, fmtchar; + bool lsF, holes, usestat, nfs_handle, quiet; am_readlink = 0; - lsF = 0; + errs = 0; + lsF = false; fmtchar = '\0'; - usestat = 0; - nfs_handle = 0; - nonl = 0; - quiet = 0; + holes = false; + usestat = false; + nfs_handle = false; + nonl = false; + quiet = false; linkfail = 0; statfmt = NULL; timefmt = NULL; @@ -231,28 +238,35 @@ main(int argc, char *argv[]) fmtchar = 'f'; quiet = 1; } else { - options = "f:FHlLnqrst:x"; - synopsis = "[-FLnq] [-f format | -l | -r | -s | -x] " + options = "Ff:HhLlnqrst:x"; + synopsis = "[-FHhLnq] [-f format | -l | -r | -s | -x] " "[-t timefmt] [file|handle ...]"; } while ((ch = getopt(argc, argv, options)) != -1) switch (ch) { case 'F': - lsF = 1; + lsF = true; break; case 'H': - nfs_handle = 1; + nfs_handle = true; + break; + case 'h': + holes = true; break; case 'L': - usestat = 1; + usestat = true; break; case 'n': - nonl = 1; + nonl = true; + break; + case 't': + timefmt = optarg; break; case 'q': - quiet = 1; + quiet = true; break; + /* remaining cases are purposefully out of order */ case 'f': if (am_readlink) { statfmt = "%R"; @@ -269,9 +283,6 @@ main(int argc, char *argv[]) fmtchar, ch); fmtchar = ch; break; - case 't': - timefmt = optarg; - break; default: usage(synopsis); } @@ -280,6 +291,28 @@ main(int argc, char *argv[]) argv += optind; fn = 1; + if (holes) { + if (fmtchar || lsF || nfs_handle || usestat || timefmt) + usage(synopsis); + if (argc > 0) { + while (argc-- > 0) { + if (listholes(*argv) != 0) { + if (!quiet) + warn("%s", *argv); + errs++; + } + argv++; + } + } else { + if (fdlistholes(STDIN_FILENO, "stdin") != 0) { + if (!quiet) + warn("stdin"); + errs++; + } + } + exit(errs ? 1 : 0); + } + if (fmtchar == '\0') { if (lsF) fmtchar = 'l'; @@ -318,7 +351,6 @@ main(int argc, char *argv[]) if (timefmt == NULL) timefmt = TIME_FORMAT; - errs = 0; do { if (argc == 0) { if (fdevname_r(STDIN_FILENO, dname + @@ -361,8 +393,7 @@ main(int argc, char *argv[]) errno == ENOENT && (rc = lstat(file, &st)) == -1) errno = ENOENT; - } - else + } else rc = lstat(file, &st); } @@ -371,9 +402,8 @@ main(int argc, char *argv[]) linkfail = 1; if (!quiet) warn("%s", file); - } - else - output(&st, file, statfmt, fn, nonl); + } else + output(&st, file, statfmt, fn); argv++; argc--; @@ -387,7 +417,7 @@ main(int argc, char *argv[]) /* * fflagstostr() wrapper that leaks only once */ -char * +static char * xfflagstostr(unsigned long fflags) { static char *str = NULL; @@ -402,10 +432,9 @@ xfflagstostr(unsigned long fflags) } #endif /* HAVE_STRUCT_STAT_ST_FLAGS */ -void +static void usage(const char *synopsis) { - (void)fprintf(stderr, "usage: %s %s\n", getprogname(), synopsis); exit(1); } @@ -413,9 +442,8 @@ usage(const char *synopsis) /* * Parses a format string. */ -void -output(const struct stat *st, const char *file, - const char *statfmt, int fn, int nonl) +static void +output(const struct stat *st, const char *file, const char *statfmt, int fn) { int flags, size, prec, ofmt, hilo, what; char buf[PATH_MAX + 4 + 1]; @@ -606,7 +634,7 @@ output(const struct stat *st, const char *file, /* * Arranges output according to a single parsed format substring. */ -int +static int format1(const struct stat *st, const char *file, const char *fmt, int flen, @@ -1073,7 +1101,7 @@ format1(const struct stat *st, (void)strcat(lfmt, "ll"); switch (ofmt) { case FMTF_DECIMAL: (void)strcat(lfmt, "d"); break; - case FMTF_OCTAL: (void)strcat(lfmt, "o"); break; + case FMTF_OCTAL: (void)strcat(lfmt, "o"); break; case FMTF_UNSIGNED: (void)strcat(lfmt, "u"); break; case FMTF_HEX: (void)strcat(lfmt, "x"); break; } @@ -1083,9 +1111,75 @@ format1(const struct stat *st, #define hex2nibble(c) (c <= '9' ? c - '0' : toupper(c) - 'A' + 10) -int +static int hex2byte(const char c[2]) { if (!(ishexnumber(c[0]) && ishexnumber(c[1]))) return -1; return (hex2nibble(c[0]) << 4) + hex2nibble(c[1]); } + +static int +fdlistholes(int fd, const char *fn) +{ + struct stat sb; + off_t pos = 0, off; + long l; + + if (fstat(fd, &sb) < 0) + return (-1); + if (S_ISDIR(sb.st_mode)) { + if ((l = fpathconf(fd, _PC_MIN_HOLE_SIZE)) < 0) + return (-1); + printf("%ld", l); + } else if (!S_ISREG(sb.st_mode)) { + errno = ESPIPE; + return (-1); + } else { + for (;;) { + if ((off = lseek(fd, pos, SEEK_HOLE)) < 0) { + if (errno != ENXIO) + return (-1); + /* + * This can only happen if the file was + * truncated while we were scanning it, or + * on the initial seek if the file is + * empty. Report the virtual hole at the + * end of the file at this position. + */ + off = pos; + } + printf("%jd", (intmax_t)off); + pos = off; + if ((off = lseek(fd, pos, SEEK_DATA)) < 0) { + if (errno != ENXIO) + return (-1); + /* + * There are no more data regions in the + * file, or it got truncated. However, we + * may not be at the end yet. + */ + if ((off = lseek(fd, 0, SEEK_END)) > pos) + printf("-%jd", (intmax_t)off - 1); + break; + } + printf("-%jd,", (intmax_t)off - 1); + pos = off; + } + } + printf(" %s", fn); + if (!nonl) + printf("\n"); + return (0); +} + +static int +listholes(const char *fn) +{ + int fd, ret; + + if ((fd = open(fn, O_RDONLY)) < 0) + return (-1); + ret = fdlistholes(fd, fn); + close(fd); + return (ret); +} diff --git a/usr.bin/stat/tests/stat_test.sh b/usr.bin/stat/tests/stat_test.sh index e75fd0c56490..afe698575034 100755 --- a/usr.bin/stat/tests/stat_test.sh +++ b/usr.bin/stat/tests/stat_test.sh @@ -1,6 +1,7 @@ # # Copyright (c) 2017 Dell EMC # All rights reserved. +# Copyright (c) 2025 Klara, Inc. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions @@ -45,6 +46,76 @@ F_flag_body() atf_check -o match:'.* f\|' stat -Fn f } +atf_test_case h_flag cleanup +h_flag_head() +{ + atf_set "descr" "Verify the output format for -h" + atf_set "require.user" "root" +} +h_flag_body() +{ + # POSIX defines a hole as “[a] contiguous region of bytes + # within a file, all having the value of zero” and requires + # that “all seekable files shall have a virtual hole starting + # at the current size of the file” but says “it is up to the + # implementation to define when sparse files can be created + # and with what granularity for the size of holes”. It also + # defines a sparse file as “[a] file that contains more holes + # than just the virtual hole at the end of the file”. That's + # pretty much the extent of its discussion of holes, apart + # from the description of SEEK_HOLE and SEEK_DATA in the lseek + # manual page. In other words, there is no portable way to + # reliably create a hole in a file on any given file system. + # + # On FreeBSD, this test is likely to run on either tmpfs, ufs + # (ffs2), or zfs. Of those three, only tmpfs has predictable + # semantics and supports all possible configurations (the + # minimum hole size on zfs is variable for small files, and + # ufs will not allow a file to end in a hole). + atf_check mkdir mnt + atf_check mount -t tmpfs tmpfs mnt + cd mnt + + # For a directory, prints the minimum hole size, which on + # tmpfs is the system page size. + ps=$(sysctl -n hw.pagesize) + atf_check -o inline:"$((ps)) .\n" stat -h . + atf_check -o inline:"$((ps)) ." stat -hn . + + # For a file, prints a list of holes. + atf_check truncate -s 0 foo + atf_check -o inline:"0 foo" \ + stat -hn foo + atf_check truncate -s "$((ps))" foo + atf_check -o inline:"0-$((ps-1)) foo" \ + stat -hn foo + atf_check dd status=none if=/COPYRIGHT of=foo \ + oseek="$((ps))" bs=1 count=1 + atf_check -o inline:"0-$((ps-1)),$((ps+1)) foo" \ + stat -hn foo + atf_check truncate -s "$((ps*3))" foo + atf_check -o inline:"0-$((ps-1)),$((ps*2))-$((ps*3-1)) foo" \ + stat -hn foo + + # Test multiple files. + atf_check dd status=none if=/COPYRIGHT of=bar + sz=$(stat -f%z bar) + atf_check -o inline:"0-$((ps-1)),$((ps*2))-$((ps*3-1)) foo +$((sz)) bar +" \ + stat -h foo bar + + # For a device, fail. + atf_check -s exit:1 -e match:"/dev/null: Illegal seek" \ + stat -h /dev/null +} +h_flag_cleanup() +{ + if [ -d mnt ]; then + umount mnt || true + fi +} + atf_test_case l_flag l_flag_head() { @@ -233,6 +304,7 @@ atf_init_test_cases() { atf_add_test_case F_flag #atf_add_test_case H_flag + atf_add_test_case h_flag #atf_add_test_case L_flag #atf_add_test_case f_flag atf_add_test_case l_flag From nobody Tue Sep 16 13:38:30 2025 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 4cR2zV6FVjz67GNy; Tue, 16 Sep 2025 13:38:30 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR2zV5Cbzz3SDm; Tue, 16 Sep 2025 13:38:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758029910; 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=J4wUXLQT8sLVCJoEH2uikaMl0Oj+B9U4qROFfUE+Tic=; b=Hy8VlFb/Z3DV3Wmb9rcFDdEml3sHEs82jEtnl2jKNwFqt5kZOtNdT25kZfHjOlAkGCaLYx iUL22S4f4n3yvZ3+N+JC+9fXiUZl1pBu1VHXsz14yIm2MZjxWEq7Yk6vFKOMSJaL+wp6Jk XJNZvhXI4db/2Hub39rA7iUfZGbDcERe/lDdRmS4IjHeL2DXtKDgpDhgzXMkzrveop3P5g w1okqnEG0mXX4GtpjZLfqy24kJ9uRY523MiP7uuzavS5z4jfGsTgvq+7FYa4wlphZWwJer nNYYs793oYnb8WOP2YRtCiBW62XEJr7iV1fO59hbQQdf5iMKGVRKojgnVkt9WA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758029910; 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=J4wUXLQT8sLVCJoEH2uikaMl0Oj+B9U4qROFfUE+Tic=; b=WA55T9dxEzCidFMYzGqbwHl8pQUfN3REOMMtcRoGLToUvGaKO+gMYVf4idaQIusmyrohdc 7eNe36PaCBK1Q308TcE9OBi0wGn6JBoxNkg2clEDRTkmfuWUPzMJlue71OYUrAB68kpV+L c3IgVv8dL+AaxDau4f3Ix7sSJm+6vpaFd0BePlXweTRYqFdvvhY9XTUn01qOcHvPRKGdQF RopezqAnn5FxAZGgFhAAWjLHVPsY36R5O9tgU2X+B1GNmGSzdCn0FLtMI621JiMhBlQPDr 98dpuzL82EkvhiqjnAj/4saRpGibToBnbCIMRWMcjZgKBBtP5265hEvU8QB9gA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758029910; a=rsa-sha256; cv=none; b=SM4yPOPj442OdQ1EVpJUnm16KtUPRGR/1eRChvGKmZXozwNc9mvbZsjNTEH1DDYzNCSbdp gJc09eu9Q2nRjS1EWdZvULd1R/GSTMqDdDG0Az7ZwdTRj+m+Yku+d8Lp+k5ABv7sNqF6jg 1CPmQ1XX+SrfL/LXjcgZEMWZXcdQEYThwZ0ubc8SG4jHaMaWK7aXL0/G+dz5v3/UCrRulS T4jqxoy4hTrYAKbexTqRYIipqAH+eQsURx4PENFUlDNFaaNI0HVBXlPFQH/y9M+gwOz+5r DwVM8/oiNxjlS3rrxJaWFumLJYagoPiX79US/fn+TsWvTognZdJqDQe4Qq4n9A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR2zV4VQJzjYR; Tue, 16 Sep 2025 13:38:30 +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 58GDcUAL026132; Tue, 16 Sep 2025 13:38:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDcUo4026129; Tue, 16 Sep 2025 13:38:30 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:38:30 GMT Message-Id: <202509161338.58GDcUo4026129@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 9b8224b950fb - main - cp: Drop test helper 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: des X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9b8224b950fb74c8674d257a5a4795baa759c35b Auto-Submitted: auto-generated The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=9b8224b950fb74c8674d257a5a4795baa759c35b commit 9b8224b950fb74c8674d257a5a4795baa759c35b Author: Dag-Erling Smørgrav AuthorDate: 2025-09-16 13:38:03 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:38:26 +0000 cp: Drop test helper Now that stat(1) can report whether a file is sparse, we no longer need a helper program for our tests. Sponsored by: Klara, Inc. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D52482 --- ObsoleteFiles.inc | 3 ++ bin/cp/tests/Makefile | 2 -- bin/cp/tests/cp_test.sh | 2 +- bin/cp/tests/sparse.c | 73 ------------------------------------------------- 4 files changed, 4 insertions(+), 76 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index 02a727d631bd..ae83035b5de5 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -51,6 +51,9 @@ # xargs -n1 | sort | uniq -d; # done +# 20250911: This tool is no longer needed +OLD_FILES+=usr/tests/bin/cp/sparse + # 20250826: Remove a misspelled manual OLD_FILES+=usr/share/man/man3/sysdecode_syscallnames.3.gz diff --git a/bin/cp/tests/Makefile b/bin/cp/tests/Makefile index 3fa9ae8f0685..a1917ada8fbf 100644 --- a/bin/cp/tests/Makefile +++ b/bin/cp/tests/Makefile @@ -1,7 +1,5 @@ PACKAGE= tests ATF_TESTS_SH= cp_test -PROGS+= sparse -BINDIR= ${TESTSDIR} .include diff --git a/bin/cp/tests/cp_test.sh b/bin/cp/tests/cp_test.sh index 999993bfad67..fdf50d042f0b 100755 --- a/bin/cp/tests/cp_test.sh +++ b/bin/cp/tests/cp_test.sh @@ -384,7 +384,7 @@ samefile_body() file_is_sparse() { - atf_check ${0%/*}/sparse "$1" + atf_check -o match:"^[0-9]+-[0-9]" stat -h "$1" } files_are_equal() diff --git a/bin/cp/tests/sparse.c b/bin/cp/tests/sparse.c deleted file mode 100644 index 78957581a56c..000000000000 --- a/bin/cp/tests/sparse.c +++ /dev/null @@ -1,73 +0,0 @@ -/*- - * Copyright (c) 2023 Klara, Inc. - * - * SPDX-License-Identifier: BSD-2-Clause - */ - -#include -#include -#include -#include -#include -#include -#include - -static bool verbose; - -/* - * Returns true if the file named by its argument is sparse, i.e. if - * seeking to SEEK_HOLE returns a different value than seeking to - * SEEK_END. - */ -static bool -sparse(const char *filename) -{ - off_t hole, end; - int fd; - - if ((fd = open(filename, O_RDONLY)) < 0 || - (hole = lseek(fd, 0, SEEK_HOLE)) < 0 || - (end = lseek(fd, 0, SEEK_END)) < 0) - err(1, "%s", filename); - close(fd); - if (end > hole) { - if (verbose) - printf("%s: hole at %zu\n", filename, (size_t)hole); - return (true); - } - return (false); -} - -static void -usage(void) -{ - - fprintf(stderr, "usage: sparse [-v] file [...]\n"); - exit(EX_USAGE); -} - -int -main(int argc, char *argv[]) -{ - int opt, rv; - - while ((opt = getopt(argc, argv, "v")) != -1) { - switch (opt) { - case 'v': - verbose = true; - break; - default: - usage(); - break; - } - } - argc -= optind; - argv += optind; - if (argc == 0) - usage(); - rv = EXIT_SUCCESS; - while (argc-- > 0) - if (!sparse(*argv++)) - rv = EXIT_FAILURE; - exit(rv); -} From nobody Tue Sep 16 13:43:29 2025 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 4cR35M5795z67HGJ for ; Tue, 16 Sep 2025 13:43:35 +0000 (UTC) (envelope-from markjdb@gmail.com) Received: from mail-qk1-x735.google.com (mail-qk1-x735.google.com [IPv6:2607:f8b0:4864:20::735]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR35M2cDSz3T72 for ; Tue, 16 Sep 2025 13:43:35 +0000 (UTC) (envelope-from markjdb@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-qk1-x735.google.com with SMTP id af79cd13be357-816ac9f9507so739354285a.1 for ; Tue, 16 Sep 2025 06:43:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1758030213; x=1758635013; darn=freebsd.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:sender :from:to:cc:subject:date:message-id:reply-to; bh=1NoSAlNI8YvxEyU7Vb1APLTEzk71xOhqza1RNENuPAI=; b=VsbOLfRlh9Gs4tC7tFWUShOolBUHq3gf4nXAJeeB8wv/XwlJrIdZhSZ4Thia3Y5sQC 0EoEJWxBstvxHZ+pclmiTKepg8YHY4lj1HrF0jKP73fuxAD2/teokvq4sZSZcS6Yj3QW D3Cbz45qR5Ytsbzuvh/Gx1fxhOjGvR57duh8FfAlhSLUHUQ2NkONwmkizD586nHr0+vr AViHPRtUCY6+OnWuX2Ms7qm9vjyQnEojQ1cXY/eerKGdsWSdUw6uGfLWNRiwBMyQY+c1 7t8Pn++4F2SY5KHz/xYkxEJQBRwvTauY2zXqjfAgP1wzHFEMGtIA5gNUt+GKb9AUNvOF c1iw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1758030213; x=1758635013; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:sender :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=1NoSAlNI8YvxEyU7Vb1APLTEzk71xOhqza1RNENuPAI=; b=MIvre7ip/sEpVjdcfzjNwAdXIjsc0gVG7i8qchWOAD41NzYF2dvbmBux9d/phwc4IO 9y8Ejzmc3SuUHQIWKnCdbK3XvoFzi8tgYm/EPMA0Nxv89eYpLCttXdCXVl9GvFBZJvqW DSwLzMnv5JS208wU6b5KdWfO//KpXfsDNh3eKmO4HHOv/DNR+Pz/ouJnHZRi1jcurc31 z+v6g2pU35Tk4oTdtRPlH7iGNogQJA5obEe4HwHBvf37Jb9q0u7yUHRwJ24Y5sXhsJFh djDBbECo/BoNyk4uLMIBewzGAthEK5GblZf+b4aLGPL0gFSogSnf/C4KdZ1O0Pf9Zto5 toOg== X-Forwarded-Encrypted: i=1; AJvYcCWZficB0gTdpEy4BraT4AWX13vSTUp78DxBkew5sopEZRhAY0RuCS0OGGFpks70HX9dXbkEVr2Ss8HYQzU9bUU+rcP2@freebsd.org X-Gm-Message-State: AOJu0Yx2BXU04HXnQK6qEU/c/TH0ZcfRIjUMZ59t9bWWSjnYM0pc0+lj FkLYYMZUj5fR8bCwSjv69SAhQ+5Uw/LIR96u7zBs/I7diZCvGfqrPq9e X-Gm-Gg: ASbGnctdF1GdOuCAzlqbvDh0Dn7X3FneswgXarPikcodgZZnLFuEtKbKyqrGtwawRin xbdehOrqN/iNNEv4EevjgeS1Nry/fEsXn4GvPa88h2PTQSn+RVB/kam9bVCymxuvhpRchVNxngr rru7jXbmqClIw2augLpd4MURnJitUXb8R+Sjd0LKjxh+7fLI/yBjfDwdS/y6GDpxHm7Pf9L/DWz hXBkvoC3HUC8v8ZYT3EfkGBhPOqKuCHm3qGr1rayrOJx+a2vdm/Lmpuf0FJptgO2quatgLE2ttW eaV26nXGUWkUXiQwxLpsAtb5WgDwMZBX8JX322RQtgJWVfAVCC8yzMz29+4BaCY+p1eU2zXqy9p Rm2kSWHbeSyLY+q6TgXsMH8OUxchiOvuQsoW+ X-Google-Smtp-Source: AGHT+IEfzhpWlZIIiVaTku034CoEC8He1bzL8cz30hs3PU2J66ghWct0OLNKUZOXmSbHjosGtFMSnw== X-Received: by 2002:a05:620a:444d:b0:804:4a23:38e0 with SMTP id af79cd13be357-82b9c180d5emr233296685a.4.1758030213078; Tue, 16 Sep 2025 06:43:33 -0700 (PDT) Received: from nuc (192-0-220-237.cpe.teksavvy.com. [192.0.220.237]) by smtp.gmail.com with ESMTPSA id af79cd13be357-820cf8c8b87sm962649385a.68.2025.09.16.06.43.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Sep 2025 06:43:32 -0700 (PDT) Date: Tue, 16 Sep 2025 09:43:29 -0400 From: Mark Johnston To: Dag-Erling =?iso-8859-1?Q?Sm=F8rgrav?= Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: b2f5dc591ef2 - main - src.opts.mk: Remove REPRODUCIBLE_BUILD from the default list Message-ID: References: <202509081922.588JM1NX027953@gitrepo.freebsd.org> <86tt12fs58.fsf@ltc.des.dev> 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=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <86tt12fs58.fsf@ltc.des.dev> X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4cR35M2cDSz3T72 On Tue, Sep 16, 2025 at 03:23:15PM +0200, Dag-Erling Smrgrav wrote: > Mark Johnston writes: > > src.opts.mk: Remove REPRODUCIBLE_BUILD from the default list > > > > It was added to the list in bsd.opts.mk in commit 4f81c42fbd76, so > > should have been removed here. > > > > Reported by: cperciva > > Fixes: 4f81c42fbd76 ("share/mk: Substitute reproducible prefixes in dwarf info") > > MFC after: 3 days > > Sponsored by: The FreeBSD Foundation > > Sponsored by: Klara, Inc. > > You forgot to regenerate src.conf.5. I didn't change the default, just where it was defined. Regenerating src.conf.5 results in no changes. From nobody Tue Sep 16 13:45:10 2025 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 4cR37B68T8z67GqQ; Tue, 16 Sep 2025 13:45:10 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR37B5VsKz3Tnn; Tue, 16 Sep 2025 13:45:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758030310; 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=LuNWn5MGT2KhKI3o/Qr5b1arMSAPU4cvOCslgUDL4Rg=; b=blTW5JTw8tqh6tXEh4cWFK1YoWibBOUEJlq5fs3M+XMwHXLjXDGh7Z4l+25cKi79WM09+E emA67Zo8PnYuZHlJXFQEYtNf4qk/EEpdRqamXdoyU+LVWuusNR+q7UhwJzdKYZUw3BKjnX YNIfib6AEC2G44CTaDyRJaKIgejtPCqw0ipw+2ZGQNyIr8uqNMUKCIqCladjIkuXeCbZKk f7Msukn4rRK1FdoKJNry4Nh0hpaamUZS+x0RWXYGcWQEFlAzFenOMKOeLyr6IvnbxmgTbz xRzr35KVQiC6AQIjXYNqIQYAAOp2OyV0jbGIposnlNKXxyQhIyTBN6feOE+LWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758030310; 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=LuNWn5MGT2KhKI3o/Qr5b1arMSAPU4cvOCslgUDL4Rg=; b=bIZiqDpRfrMWqWNqYj0d+Q7FGAxpSkedglWlOWOSIf+ecawBDjczAB/dQVGUacYACd6PXB RSR8dYybtVd5SdP9HwgQUeRiFLlHO+QoEJPDn3ZMzvZmZBfaMvwaAIbuLasacB6RjLF1sp 82pO+YoR84gC6YY+CoQiEMTgEityVoGTgDWpubUzcdBlRJAnv8nyHZv9FhcSM4DlzJFeee Tkla9SsbzmNC4qgQTGuaKd0IoQf9eH3hmPhPd2j3yW2rb37KPX5UXH1VGgewTHKDZaK06V Kdpc1ZBwtO/uBddjINhkb3bYB6sCzr+hjQLPbKsFWREr2PT0YbCwmxePnWDGdA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758030310; a=rsa-sha256; cv=none; b=DDxPy+WJMD6nNTiHRrjXOsc2+mXV/ArZWx9Ax8Gxh7gqgLeepgxUAO/ZZrVQXjX3naSDX9 C1la/Dz/uPzZYrvRB7W4IN9ycWiV7zMzS9C6XeJkrL2ghyM0yxZpnsfGf/Tn/LvfpDNhy9 rs00XExA/0KgEjxwFnXdeQg8L5V8Dr+4fUPWP5NTDrdTtblukcez1WXTzrgwgZPVE6NF4g LN1MHi0dd1h+FKKenUbMM4tYtXN+HSCl00gqXEOQ1jgzY+AQ6YwvM4Rlg0M0XxtoiX+v1G dJ6Nybn5V0A7nkwQZ1mmaoB6JD++wrzwsxan6vW2UtvUiBGbKAcqQ9eW0692zA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR37B51w6zkMj; Tue, 16 Sep 2025 13:45:10 +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 58GDjAAa043582; Tue, 16 Sep 2025 13:45:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDjAid043579; Tue, 16 Sep 2025 13:45:10 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:45:10 GMT Message-Id: <202509161345.58GDjAid043579@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: 1c3ca0c733a4 - main - Revert "jail: Optionally allow audit session state to be configured in a jail" 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1c3ca0c733a4e4ba550cedfa8019260fb0cf5707 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=1c3ca0c733a4e4ba550cedfa8019260fb0cf5707 commit 1c3ca0c733a4e4ba550cedfa8019260fb0cf5707 Author: Mark Johnston AuthorDate: 2025-09-16 13:43:47 +0000 Commit: Mark Johnston CommitDate: 2025-09-16 13:44:58 +0000 Revert "jail: Optionally allow audit session state to be configured in a jail" Changing audit system calls to return EPERM instead of ENOSYS when invoked from a jail breaks some userspace applications. Revert for now until a more complete change is reviewed. This reverts commit 246d7e9fc23928be22db38220f5439f5cdee5264. PR: 289645 --- sys/kern/kern_jail.c | 13 +------------ sys/security/audit/audit_syscalls.c | 12 ++++++++++++ sys/sys/jail.h | 3 +-- usr.sbin/jail/jail.8 | 19 ++++--------------- usr.sbin/jail/tests/jail_basic_test.sh | 20 -------------------- 5 files changed, 18 insertions(+), 49 deletions(-) diff --git a/sys/kern/kern_jail.c b/sys/kern/kern_jail.c index 3697d95fe0e5..a75ba89d2a7e 100644 --- a/sys/kern/kern_jail.c +++ b/sys/kern/kern_jail.c @@ -243,9 +243,6 @@ static struct bool_flags pr_flag_allow[NBBY * NBPW] = { {"allow.unprivileged_parent_tampering", "allow.nounprivileged_parent_tampering", PR_ALLOW_UNPRIV_PARENT_TAMPER}, -#ifdef AUDIT - {"allow.setaudit", "allow.nosetaudit", PR_ALLOW_SETAUDIT}, -#endif }; static unsigned pr_allow_all = PR_ALLOW_ALL_STATIC; const size_t pr_flag_allow_size = sizeof(pr_flag_allow); @@ -4292,6 +4289,7 @@ prison_priv_check(struct ucred *cred, int priv) */ case PRIV_KTRACE: +#if 0 /* * Allow jailed processes to configure audit identity and * submit audit records (login, etc). In the future we may @@ -4300,11 +4298,6 @@ prison_priv_check(struct ucred *cred, int priv) */ case PRIV_AUDIT_GETAUDIT: case PRIV_AUDIT_SETAUDIT: - if (cred->cr_prison->pr_allow & PR_ALLOW_SETAUDIT) - return (0); - else - return (EPERM); -#if 0 case PRIV_AUDIT_SUBMIT: #endif @@ -5041,10 +5034,6 @@ SYSCTL_JAIL_PARAM(_allow, settime, CTLTYPE_INT | CTLFLAG_RW, "B", "Jail may set system time"); SYSCTL_JAIL_PARAM(_allow, routing, CTLTYPE_INT | CTLFLAG_RW, "B", "Jail may modify routing table"); -#ifdef AUDIT -SYSCTL_JAIL_PARAM(_allow, setaudit, CTLTYPE_INT | CTLFLAG_RW, - "B", "Jail may set and get audit session state"); -#endif SYSCTL_JAIL_PARAM_SUBNODE(allow, mount, "Jail mount/unmount permission flags"); SYSCTL_JAIL_PARAM(_allow_mount, , CTLTYPE_INT | CTLFLAG_RW, diff --git a/sys/security/audit/audit_syscalls.c b/sys/security/audit/audit_syscalls.c index 262f2c1ae1e3..40b2fb3d1c9f 100644 --- a/sys/security/audit/audit_syscalls.c +++ b/sys/security/audit/audit_syscalls.c @@ -592,6 +592,8 @@ sys_getauid(struct thread *td, struct getauid_args *uap) { int error; + if (jailed(td->td_ucred)) + return (ENOSYS); error = priv_check(td, PRIV_AUDIT_GETAUDIT); if (error) return (error); @@ -607,6 +609,8 @@ sys_setauid(struct thread *td, struct setauid_args *uap) au_id_t id; int error; + if (jailed(td->td_ucred)) + return (ENOSYS); error = copyin(uap->auid, &id, sizeof(id)); if (error) return (error); @@ -646,6 +650,8 @@ sys_getaudit(struct thread *td, struct getaudit_args *uap) int error; cred = td->td_ucred; + if (jailed(cred)) + return (ENOSYS); error = priv_check(td, PRIV_AUDIT_GETAUDIT); if (error) return (error); @@ -668,6 +674,8 @@ sys_setaudit(struct thread *td, struct setaudit_args *uap) struct auditinfo ai; int error; + if (jailed(td->td_ucred)) + return (ENOSYS); error = copyin(uap->auditinfo, &ai, sizeof(ai)); if (error) return (error); @@ -707,6 +715,8 @@ sys_getaudit_addr(struct thread *td, struct getaudit_addr_args *uap) { int error; + if (jailed(td->td_ucred)) + return (ENOSYS); if (uap->length < sizeof(*uap->auditinfo_addr)) return (EOVERFLOW); error = priv_check(td, PRIV_AUDIT_GETAUDIT); @@ -724,6 +734,8 @@ sys_setaudit_addr(struct thread *td, struct setaudit_addr_args *uap) struct auditinfo_addr aia; int error; + if (jailed(td->td_ucred)) + return (ENOSYS); error = copyin(uap->auditinfo_addr, &aia, sizeof(aia)); if (error) return (error); diff --git a/sys/sys/jail.h b/sys/sys/jail.h index e6a13e6719dd..e12e8c3178c9 100644 --- a/sys/sys/jail.h +++ b/sys/sys/jail.h @@ -271,7 +271,6 @@ struct prison_racct { #define PR_ALLOW_SETTIME 0x00100000 #define PR_ALLOW_ROUTING 0x00200000 #define PR_ALLOW_UNPRIV_PARENT_TAMPER 0x00400000 -#define PR_ALLOW_SETAUDIT 0x00800000 /* * PR_ALLOW_PRISON0 are the allow flags that we apply by default to prison0, @@ -279,7 +278,7 @@ struct prison_racct { * build time. PR_ALLOW_ALL_STATIC should contain any bit above that we expect * to be used on the system, while PR_ALLOW_PRISON0 will be some subset of that. */ -#define PR_ALLOW_ALL_STATIC 0x00ff87ff +#define PR_ALLOW_ALL_STATIC 0x007f87ff #define PR_ALLOW_PRISON0 \ (PR_ALLOW_ALL_STATIC & ~(PR_ALLOW_UNPRIV_PARENT_TAMPER)) diff --git a/usr.sbin/jail/jail.8 b/usr.sbin/jail/jail.8 index d44b7f66a64e..421aa9babb4c 100644 --- a/usr.sbin/jail/jail.8 +++ b/usr.sbin/jail/jail.8 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd September 15, 2025 +.Dd August 7, 2025 .Dt JAIL 8 .Os .Sh NAME @@ -702,15 +702,15 @@ The super-user will be disabled automatically if its parent system has it disabled. The super-user is enabled by default. .It Va allow.extattr -Allow privileged processes in the jail to manipulate filesystem extended +Allow privileged process in the jail to manipulate filesystem extended attributes in the system namespace. .It Va allow.adjtime -Allow privileged processes in the jail to slowly adjusting global operating system +Allow privileged process in the jail to slowly adjusting global operating system time. For example through utilities like .Xr ntpd 8 . .It Va allow.settime -Allow privileged processes in the jail to set global operating system data +Allow privileged process in the jail to set global operating system data and time. For example through utilities like .Xr date 1 . @@ -719,17 +719,6 @@ This permission includes also .It Va allow.routing Allow privileged process in the non-VNET jail to modify the system routing table. -.It Va allow.setaudit -Allow privileged processes in the jail to set -.Xr audit 4 -session state using -.Xr setaudit 2 -and related system calls. -This is useful, for example, for allowing a jailed -.Xr sshd 8 -to set the audit user ID for an authenticated session. -However, it gives jailed processes the ability to modify or disable audit -session state, so should be configured with care. .El .El .Pp diff --git a/usr.sbin/jail/tests/jail_basic_test.sh b/usr.sbin/jail/tests/jail_basic_test.sh index c781eed78756..6802da7b049a 100755 --- a/usr.sbin/jail/tests/jail_basic_test.sh +++ b/usr.sbin/jail/tests/jail_basic_test.sh @@ -306,25 +306,6 @@ param_consistency_cleanup() fi } -atf_test_case "setaudit" -setaudit_head() -{ - atf_set descr 'Test that setaudit works in a jail when configured with allow.setaudit' - atf_set require.user root - atf_set require.progs setaudit -} - -setaudit_body() -{ - # Try to modify the audit mask within a jail without - # allow.setaudit configured. - atf_check -s not-exit:0 -o empty -e not-empty jail -c name=setaudit_jail \ - command=setaudit -m fr ls / - # The command should succeed if allow.setaudit is configured. - atf_check -s exit:0 -o ignore -e empty jail -c name=setaudit_jail \ - allow.setaudit command=setaudit -m fr ls / -} - atf_init_test_cases() { atf_add_test_case "basic" @@ -333,5 +314,4 @@ atf_init_test_cases() atf_add_test_case "commands" atf_add_test_case "jid_name_set" atf_add_test_case "param_consistency" - atf_add_test_case "setaudit" } From nobody Tue Sep 16 13:59:05 2025 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 4cR3RF5Wvyz67Jv8; Tue, 16 Sep 2025 13:59:05 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3RF5DMBz3X7x; Tue, 16 Sep 2025 13:59:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031145; 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=zglo4T8vgBbtmA7szeeRh2p8bYd6oTBpkYtP69PvK0U=; b=ZkL6ABhYfZm6MF0miYrNnfI24rbKS1BtY5l8MDfQO85ysqJEH5Upqgdvwx9j2ATOGAmV4M GbVzbyrNce0rBHFKvmpH7l2rylPExueLKR/C5vQYMvknv/ExJxGaJ+1bJv5EQiebttPYwR oM7vh8UcOwmjYgzPtGFOW/KViCGjlBSQ66sgWAm1Sd3KgRq7ucmQBtynjNtenUv4+6sDCV pAjWWgstygH4qp/I4vPfaF8N9js5/JQbLaW1YZlsUni+okrycUYfmcvpZOLxYAeMU67OS6 mIwriiZT5ZeZST4Ca3KprU2Zf0PUzZOmP1vyFAr92oWNZjH5teUAn1+FuN70Lw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031145; 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=zglo4T8vgBbtmA7szeeRh2p8bYd6oTBpkYtP69PvK0U=; b=s5PxX8OKYQmZMIbnCh7sCBXEbqMRsIqJqRZrhCxa+Cirxm646AFcugz8MUU/pAVStUmTGR wNRgwuDTa/KabEWYuPJbTGfBCDTa0mAnadKiE08RgrgIeseUORfnq+kwMZ9SKXgambTwCP v8MU8Jv9/2OftqpMMwNtq3RAV4Jv9/h3dDHr190Ny7p1S+WrNAE00h71hPmbirrPyfywd1 WXM/vjZ/EOfguDInqFUjQRl5JAMl0GCL+YqaGFe2gJd94VuM0oDdEqB8X4z6hYI/Q6P509 2ADrTl2SAXwwLSdgx1EmHfEVa8JRV4DTjdVpDaI44+aYs42m2H45QoDOTMLjJA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031145; a=rsa-sha256; cv=none; b=W1PnAjw0sFXgKxOnYEhJfK1GVMWOEGqiPNWtRHsTBgKgydIBsrXGA+jijXVFAaRfltlOZW wdT+cdkHaQLwNsflM0SdeuFMyQkQYeAHaiXpV48qq1FKxUQejJ5Icc87f0MadiKFH4CkwD SzA/fcRb7LUMe/K/eLr1Z7f2wKIwi/AGb7KuBiZ1V1KU8ZKKWJBGcBCa1D9VjeIGnLRdhe guGARVYF8/C4OEkEKFICwVNidyQTQVUEMpeP5VivLqf8oiZympmXug3WsPcxYxv7/89VA+ /bAM7O5RoHua3Kw4nd/fuqDVc30U03zVuyFr/+zrfMFquuBkaA2ffZ1stxBm5A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3RF4cfczkTC; Tue, 16 Sep 2025 13:59:05 +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 58GDx5Qo064276; Tue, 16 Sep 2025 13:59:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDx5Ot064271; Tue, 16 Sep 2025 13:59:05 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:05 GMT Message-Id: <202509161359.58GDx5Ot064271@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: abe8e3aecea6 - stable/15 - unbound: Update to 1.23.1 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: abe8e3aecea6f33bb0eb578a44834aacdcfaef05 Auto-Submitted: auto-generated The branch stable/15 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=abe8e3aecea6f33bb0eb578a44834aacdcfaef05 commit abe8e3aecea6f33bb0eb578a44834aacdcfaef05 Author: Dag-Erling Smørgrav AuthorDate: 2025-09-07 18:59:20 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:05:52 +0000 unbound: Update to 1.23.1 Release notes at https://nlnetlabs.nl/news/2025/Jul/16/unbound-1.23.1-released/ Since we don't enable ECS, this is mostly a nop for us. Merge commit 'c8864f6ba46ff3271d97b4ae1c3cc6ce01eaf18a' MFC after: 3 days (cherry picked from commit 5a0119491adbea0876d9d6dc0ef3e71f3d64a20b) --- contrib/unbound/config.guess | 17 +- contrib/unbound/config.h.in | 360 +- contrib/unbound/config.sub | 28 +- contrib/unbound/configure | 4467 ++++++++++++--------- contrib/unbound/configure.ac | 5 +- contrib/unbound/doc/README | 2 +- contrib/unbound/doc/example.conf | 300 +- contrib/unbound/doc/example.conf.in | 2 +- contrib/unbound/doc/libunbound.3 | 4 +- contrib/unbound/doc/libunbound.3.in | 4 +- contrib/unbound/doc/unbound-anchor.8 | 14 +- contrib/unbound/doc/unbound-anchor.8.in | 2 +- contrib/unbound/doc/unbound-checkconf.8 | 8 +- contrib/unbound/doc/unbound-checkconf.8.in | 2 +- contrib/unbound/doc/unbound-control.8 | 343 +- contrib/unbound/doc/unbound-control.8.in | 2 +- contrib/unbound/doc/unbound-host.1 | 4 +- contrib/unbound/doc/unbound-host.1.in | 2 +- contrib/unbound/doc/unbound.8 | 8 +- contrib/unbound/doc/unbound.8.in | 4 +- contrib/unbound/doc/unbound.conf.5 | 741 +++- contrib/unbound/doc/unbound.conf.5.in | 2 +- contrib/unbound/edns-subnet/subnetmod.c | 152 +- contrib/unbound/edns-subnet/subnetmod.h | 4 + contrib/unbound/ltmain.sh | 1555 ++++--- contrib/unbound/smallapp/unbound-control-setup.sh | 227 +- lib/libunbound/Makefile | 31 +- lib/libunbound/config.h | 521 ++- 28 files changed, 5633 insertions(+), 3178 deletions(-) diff --git a/contrib/unbound/config.guess b/contrib/unbound/config.guess index 48a684601bd2..a9d01fde4617 100755 --- a/contrib/unbound/config.guess +++ b/contrib/unbound/config.guess @@ -1,10 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2024 Free Software Foundation, Inc. +# Copyright 1992-2025 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale -timestamp='2024-07-27' +timestamp='2025-07-10' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -60,7 +60,7 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2024 Free Software Foundation, Inc. +Copyright 1992-2025 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -1597,8 +1597,11 @@ EOF *:Unleashed:*:*) GUESS=$UNAME_MACHINE-unknown-unleashed$UNAME_RELEASE ;; - *:Ironclad:*:*) - GUESS=$UNAME_MACHINE-unknown-ironclad + x86_64:[Ii]ronclad:*:*|i?86:[Ii]ronclad:*:*) + GUESS=$UNAME_MACHINE-pc-ironclad-mlibc + ;; + *:[Ii]ronclad:*:*) + GUESS=$UNAME_MACHINE-unknown-ironclad-mlibc ;; esac @@ -1808,8 +1811,8 @@ fi exit 1 # Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp nil t) # time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" +# time-stamp-format: "%Y-%02m-%02d" # time-stamp-end: "'" # End: diff --git a/contrib/unbound/config.h.in b/contrib/unbound/config.h.in index f2dc8c8b92b3..584810398b91 100644 --- a/contrib/unbound/config.h.in +++ b/contrib/unbound/config.h.in @@ -48,13 +48,13 @@ internal symbols */ #undef EXPORT_ALL_SYMBOLS -/* Define to 1 if you have the `accept4' function. */ +/* Define to 1 if you have the 'accept4' function. */ #undef HAVE_ACCEPT4 -/* Define to 1 if you have the `arc4random' function. */ +/* Define to 1 if you have the 'arc4random' function. */ #undef HAVE_ARC4RANDOM -/* Define to 1 if you have the `arc4random_uniform' function. */ +/* Define to 1 if you have the 'arc4random_uniform' function. */ #undef HAVE_ARC4RANDOM_UNIFORM /* Define to 1 if you have the header file. */ @@ -78,7 +78,7 @@ /* If we have be64toh */ #undef HAVE_BE64TOH -/* Define to 1 if you have the `BIO_set_callback_ex' function. */ +/* Define to 1 if you have the 'BIO_set_callback_ex' function. */ #undef HAVE_BIO_SET_CALLBACK_EX /* Define to 1 if you have the header file. */ @@ -87,241 +87,241 @@ /* Define to 1 if you have the header file. */ #undef HAVE_BSD_STRING_H -/* Define to 1 if you have the `chown' function. */ +/* Define to 1 if you have the 'chown' function. */ #undef HAVE_CHOWN -/* Define to 1 if you have the `chroot' function. */ +/* Define to 1 if you have the 'chroot' function. */ #undef HAVE_CHROOT -/* Define to 1 if you have the `CRYPTO_cleanup_all_ex_data' function. */ +/* Define to 1 if you have the 'CRYPTO_cleanup_all_ex_data' function. */ #undef HAVE_CRYPTO_CLEANUP_ALL_EX_DATA -/* Define to 1 if you have the `CRYPTO_THREADID_set_callback' function. */ +/* Define to 1 if you have the 'CRYPTO_THREADID_set_callback' function. */ #undef HAVE_CRYPTO_THREADID_SET_CALLBACK -/* Define to 1 if you have the `ctime_r' function. */ +/* Define to 1 if you have the 'ctime_r' function. */ #undef HAVE_CTIME_R -/* Define to 1 if you have the `daemon' function. */ +/* Define to 1 if you have the 'daemon' function. */ #undef HAVE_DAEMON -/* Define to 1 if you have the declaration of `arc4random', and to 0 if you +/* Define to 1 if you have the declaration of 'arc4random', and to 0 if you don't. */ #undef HAVE_DECL_ARC4RANDOM -/* Define to 1 if you have the declaration of `arc4random_uniform', and to 0 +/* Define to 1 if you have the declaration of 'arc4random_uniform', and to 0 if you don't. */ #undef HAVE_DECL_ARC4RANDOM_UNIFORM -/* Define to 1 if you have the declaration of `evsignal_assign', and to 0 if +/* Define to 1 if you have the declaration of 'evsignal_assign', and to 0 if you don't. */ #undef HAVE_DECL_EVSIGNAL_ASSIGN -/* Define to 1 if you have the declaration of `inet_ntop', and to 0 if you +/* Define to 1 if you have the declaration of 'inet_ntop', and to 0 if you don't. */ #undef HAVE_DECL_INET_NTOP -/* Define to 1 if you have the declaration of `inet_pton', and to 0 if you +/* Define to 1 if you have the declaration of 'inet_pton', and to 0 if you don't. */ #undef HAVE_DECL_INET_PTON -/* Define to 1 if you have the declaration of `nghttp2_session_server_new', +/* Define to 1 if you have the declaration of 'nghttp2_session_server_new', and to 0 if you don't. */ #undef HAVE_DECL_NGHTTP2_SESSION_SERVER_NEW -/* Define to 1 if you have the declaration of `ngtcp2_conn_server_new', and to +/* Define to 1 if you have the declaration of 'ngtcp2_conn_server_new', and to 0 if you don't. */ #undef HAVE_DECL_NGTCP2_CONN_SERVER_NEW -/* Define to 1 if you have the declaration of `ngtcp2_crypto_encrypt_cb', and +/* Define to 1 if you have the declaration of 'ngtcp2_crypto_encrypt_cb', and to 0 if you don't. */ #undef HAVE_DECL_NGTCP2_CRYPTO_ENCRYPT_CB -/* Define to 1 if you have the declaration of `NID_ED25519', and to 0 if you +/* Define to 1 if you have the declaration of 'NID_ED25519', and to 0 if you don't. */ #undef HAVE_DECL_NID_ED25519 -/* Define to 1 if you have the declaration of `NID_ED448', and to 0 if you +/* Define to 1 if you have the declaration of 'NID_ED448', and to 0 if you don't. */ #undef HAVE_DECL_NID_ED448 -/* Define to 1 if you have the declaration of `NID_secp384r1', and to 0 if you +/* Define to 1 if you have the declaration of 'NID_secp384r1', and to 0 if you don't. */ #undef HAVE_DECL_NID_SECP384R1 -/* Define to 1 if you have the declaration of `NID_X9_62_prime256v1', and to 0 +/* Define to 1 if you have the declaration of 'NID_X9_62_prime256v1', and to 0 if you don't. */ #undef HAVE_DECL_NID_X9_62_PRIME256V1 -/* Define to 1 if you have the declaration of `reallocarray', and to 0 if you +/* Define to 1 if you have the declaration of 'reallocarray', and to 0 if you don't. */ #undef HAVE_DECL_REALLOCARRAY -/* Define to 1 if you have the declaration of `redisConnect', and to 0 if you +/* Define to 1 if you have the declaration of 'redisConnect', and to 0 if you don't. */ #undef HAVE_DECL_REDISCONNECT -/* Define to 1 if you have the declaration of `sk_SSL_COMP_pop_free', and to 0 +/* Define to 1 if you have the declaration of 'sk_SSL_COMP_pop_free', and to 0 if you don't. */ #undef HAVE_DECL_SK_SSL_COMP_POP_FREE /* Define to 1 if you have the declaration of - `SSL_COMP_get_compression_methods', and to 0 if you don't. */ + 'SSL_COMP_get_compression_methods', and to 0 if you don't. */ #undef HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS -/* Define to 1 if you have the declaration of `SSL_CTX_set_ecdh_auto', and to +/* Define to 1 if you have the declaration of 'SSL_CTX_set_ecdh_auto', and to 0 if you don't. */ #undef HAVE_DECL_SSL_CTX_SET_ECDH_AUTO -/* Define to 1 if you have the declaration of `strlcat', and to 0 if you +/* Define to 1 if you have the declaration of 'strlcat', and to 0 if you don't. */ #undef HAVE_DECL_STRLCAT -/* Define to 1 if you have the declaration of `strlcpy', and to 0 if you +/* Define to 1 if you have the declaration of 'strlcpy', and to 0 if you don't. */ #undef HAVE_DECL_STRLCPY -/* Define to 1 if you have the declaration of `XML_StopParser', and to 0 if +/* Define to 1 if you have the declaration of 'XML_StopParser', and to 0 if you don't. */ #undef HAVE_DECL_XML_STOPPARSER /* Define to 1 if you have the header file. */ #undef HAVE_DLFCN_H -/* Define to 1 if you have the `DSA_SIG_set0' function. */ +/* Define to 1 if you have the 'DSA_SIG_set0' function. */ #undef HAVE_DSA_SIG_SET0 /* Define to 1 if you have the header file. */ #undef HAVE_ENDIAN_H -/* Define to 1 if you have the `endprotoent' function. */ +/* Define to 1 if you have the 'endprotoent' function. */ #undef HAVE_ENDPROTOENT -/* Define to 1 if you have the `endpwent' function. */ +/* Define to 1 if you have the 'endpwent' function. */ #undef HAVE_ENDPWENT -/* Define to 1 if you have the `endservent' function. */ +/* Define to 1 if you have the 'endservent' function. */ #undef HAVE_ENDSERVENT -/* Define to 1 if you have the `ENGINE_cleanup' function. */ +/* Define to 1 if you have the 'ENGINE_cleanup' function. */ #undef HAVE_ENGINE_CLEANUP -/* Define to 1 if you have the `ERR_free_strings' function. */ +/* Define to 1 if you have the 'ERR_free_strings' function. */ #undef HAVE_ERR_FREE_STRINGS -/* Define to 1 if you have the `ERR_load_crypto_strings' function. */ +/* Define to 1 if you have the 'ERR_load_crypto_strings' function. */ #undef HAVE_ERR_LOAD_CRYPTO_STRINGS -/* Define to 1 if you have the `event_assign' function. */ +/* Define to 1 if you have the 'event_assign' function. */ #undef HAVE_EVENT_ASSIGN -/* Define to 1 if you have the `event_base_free' function. */ +/* Define to 1 if you have the 'event_base_free' function. */ #undef HAVE_EVENT_BASE_FREE -/* Define to 1 if you have the `event_base_get_method' function. */ +/* Define to 1 if you have the 'event_base_get_method' function. */ #undef HAVE_EVENT_BASE_GET_METHOD -/* Define to 1 if you have the `event_base_new' function. */ +/* Define to 1 if you have the 'event_base_new' function. */ #undef HAVE_EVENT_BASE_NEW -/* Define to 1 if you have the `event_base_once' function. */ +/* Define to 1 if you have the 'event_base_once' function. */ #undef HAVE_EVENT_BASE_ONCE /* Define to 1 if you have the header file. */ #undef HAVE_EVENT_H -/* Define to 1 if you have the `EVP_aes_256_cbc' function. */ +/* Define to 1 if you have the 'EVP_aes_256_cbc' function. */ #undef HAVE_EVP_AES_256_CBC -/* Define to 1 if you have the `EVP_cleanup' function. */ +/* Define to 1 if you have the 'EVP_cleanup' function. */ #undef HAVE_EVP_CLEANUP -/* Define to 1 if you have the `EVP_default_properties_is_fips_enabled' +/* Define to 1 if you have the 'EVP_default_properties_is_fips_enabled' function. */ #undef HAVE_EVP_DEFAULT_PROPERTIES_IS_FIPS_ENABLED -/* Define to 1 if you have the `EVP_DigestVerify' function. */ +/* Define to 1 if you have the 'EVP_DigestVerify' function. */ #undef HAVE_EVP_DIGESTVERIFY -/* Define to 1 if you have the `EVP_dss1' function. */ +/* Define to 1 if you have the 'EVP_dss1' function. */ #undef HAVE_EVP_DSS1 -/* Define to 1 if you have the `EVP_EncryptInit_ex' function. */ +/* Define to 1 if you have the 'EVP_EncryptInit_ex' function. */ #undef HAVE_EVP_ENCRYPTINIT_EX -/* Define to 1 if you have the `EVP_MAC_CTX_set_params' function. */ +/* Define to 1 if you have the 'EVP_MAC_CTX_set_params' function. */ #undef HAVE_EVP_MAC_CTX_SET_PARAMS -/* Define to 1 if you have the `EVP_MD_CTX_new' function. */ +/* Define to 1 if you have the 'EVP_MD_CTX_new' function. */ #undef HAVE_EVP_MD_CTX_NEW -/* Define to 1 if you have the `EVP_sha1' function. */ +/* Define to 1 if you have the 'EVP_sha1' function. */ #undef HAVE_EVP_SHA1 -/* Define to 1 if you have the `EVP_sha256' function. */ +/* Define to 1 if you have the 'EVP_sha256' function. */ #undef HAVE_EVP_SHA256 -/* Define to 1 if you have the `EVP_sha512' function. */ +/* Define to 1 if you have the 'EVP_sha512' function. */ #undef HAVE_EVP_SHA512 -/* Define to 1 if you have the `ev_default_loop' function. */ +/* Define to 1 if you have the 'ev_default_loop' function. */ #undef HAVE_EV_DEFAULT_LOOP -/* Define to 1 if you have the `ev_loop' function. */ +/* Define to 1 if you have the 'ev_loop' function. */ #undef HAVE_EV_LOOP /* Define to 1 if you have the header file. */ #undef HAVE_EXPAT_H -/* Define to 1 if you have the `explicit_bzero' function. */ +/* Define to 1 if you have the 'explicit_bzero' function. */ #undef HAVE_EXPLICIT_BZERO -/* Define to 1 if you have the `fcntl' function. */ +/* Define to 1 if you have the 'fcntl' function. */ #undef HAVE_FCNTL -/* Define to 1 if you have the `FIPS_mode' function. */ +/* Define to 1 if you have the 'FIPS_mode' function. */ #undef HAVE_FIPS_MODE -/* Define to 1 if you have the `fork' function. */ +/* Define to 1 if you have the 'fork' function. */ #undef HAVE_FORK -/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */ +/* Define to 1 if fseeko (and ftello) are declared in stdio.h. */ #undef HAVE_FSEEKO -/* Define to 1 if you have the `fsync' function. */ +/* Define to 1 if you have the 'fsync' function. */ #undef HAVE_FSYNC /* Whether getaddrinfo is available */ #undef HAVE_GETADDRINFO -/* Define to 1 if you have the `getauxval' function. */ +/* Define to 1 if you have the 'getauxval' function. */ #undef HAVE_GETAUXVAL -/* Define to 1 if you have the `getentropy' function. */ +/* Define to 1 if you have the 'getentropy' function. */ #undef HAVE_GETENTROPY -/* Define to 1 if you have the `getifaddrs' function. */ +/* Define to 1 if you have the 'getifaddrs' function. */ #undef HAVE_GETIFADDRS /* Define to 1 if you have the header file. */ #undef HAVE_GETOPT_H -/* Define to 1 if you have the `getpwnam' function. */ +/* Define to 1 if you have the 'getpwnam' function. */ #undef HAVE_GETPWNAM -/* Define to 1 if you have the `getrlimit' function. */ +/* Define to 1 if you have the 'getrlimit' function. */ #undef HAVE_GETRLIMIT -/* Define to 1 if you have the `gettid' function. */ +/* Define to 1 if you have the 'gettid' function. */ #undef HAVE_GETTID -/* Define to 1 if you have the `glob' function. */ +/* Define to 1 if you have the 'glob' function. */ #undef HAVE_GLOB /* Define to 1 if you have the header file. */ #undef HAVE_GLOB_H -/* Define to 1 if you have the `gmtime_r' function. */ +/* Define to 1 if you have the 'gmtime_r' function. */ #undef HAVE_GMTIME_R /* Define to 1 if you have the header file. */ @@ -330,7 +330,7 @@ /* Define to 1 if you have the header file. */ #undef HAVE_HIREDIS_HIREDIS_H -/* Define to 1 if you have the `HMAC_Init_ex' function. */ +/* Define to 1 if you have the 'HMAC_Init_ex' function. */ #undef HAVE_HMAC_INIT_EX /* If we have htobe64 */ @@ -339,19 +339,19 @@ /* Define to 1 if you have the header file. */ #undef HAVE_IFADDRS_H -/* Define to 1 if you have the `if_nametoindex' function. */ +/* Define to 1 if you have the 'if_nametoindex' function. */ #undef HAVE_IF_NAMETOINDEX -/* Define to 1 if you have the `inet_aton' function. */ +/* Define to 1 if you have the 'inet_aton' function. */ #undef HAVE_INET_ATON -/* Define to 1 if you have the `inet_ntop' function. */ +/* Define to 1 if you have the 'inet_ntop' function. */ #undef HAVE_INET_NTOP -/* Define to 1 if you have the `inet_pton' function. */ +/* Define to 1 if you have the 'inet_pton' function. */ #undef HAVE_INET_PTON -/* Define to 1 if you have the `initgroups' function. */ +/* Define to 1 if you have the 'initgroups' function. */ #undef HAVE_INITGROUPS /* Define to 1 if you have the header file. */ @@ -363,10 +363,10 @@ /* Define to 1 if you have the header file. */ #undef HAVE_IPHLPAPI_H -/* Define to 1 if you have the `isblank' function. */ +/* Define to 1 if you have the 'isblank' function. */ #undef HAVE_ISBLANK -/* Define to 1 if you have the `kill' function. */ +/* Define to 1 if you have the 'kill' function. */ #undef HAVE_KILL /* Use portable libbsd functions */ @@ -384,7 +384,7 @@ /* Define to 1 if you have the header file. */ #undef HAVE_LINUX_NET_TSTAMP_H -/* Define to 1 if you have the `localtime_r' function. */ +/* Define to 1 if you have the 'localtime_r' function. */ #undef HAVE_LOCALTIME_R /* Define to 1 if you have the header file. */ @@ -393,7 +393,7 @@ /* If have GNU libc compatible malloc */ #undef HAVE_MALLOC -/* Define to 1 if you have the `memmove' function. */ +/* Define to 1 if you have the 'memmove' function. */ #undef HAVE_MEMMOVE /* Define to 1 if you have the header file. */ @@ -435,49 +435,49 @@ /* Define this to use ngtcp2. */ #undef HAVE_NGTCP2 -/* Define to 1 if you have the `ngtcp2_ccerr_default' function. */ +/* Define to 1 if you have the 'ngtcp2_ccerr_default' function. */ #undef HAVE_NGTCP2_CCERR_DEFAULT -/* Define to 1 if you have the `ngtcp2_conn_encode_0rtt_transport_params' +/* Define to 1 if you have the 'ngtcp2_conn_encode_0rtt_transport_params' function. */ #undef HAVE_NGTCP2_CONN_ENCODE_0RTT_TRANSPORT_PARAMS -/* Define to 1 if you have the `ngtcp2_conn_get_max_local_streams_uni' +/* Define to 1 if you have the 'ngtcp2_conn_get_max_local_streams_uni' function. */ #undef HAVE_NGTCP2_CONN_GET_MAX_LOCAL_STREAMS_UNI -/* Define to 1 if you have the `ngtcp2_conn_get_num_scid' function. */ +/* Define to 1 if you have the 'ngtcp2_conn_get_num_scid' function. */ #undef HAVE_NGTCP2_CONN_GET_NUM_SCID -/* Define to 1 if you have the `ngtcp2_conn_in_closing_period' function. */ +/* Define to 1 if you have the 'ngtcp2_conn_in_closing_period' function. */ #undef HAVE_NGTCP2_CONN_IN_CLOSING_PERIOD -/* Define to 1 if you have the `ngtcp2_conn_in_draining_period' function. */ +/* Define to 1 if you have the 'ngtcp2_conn_in_draining_period' function. */ #undef HAVE_NGTCP2_CONN_IN_DRAINING_PERIOD /* Define if ngtcp2_conn_shutdown_stream has 4 arguments. */ #undef HAVE_NGTCP2_CONN_SHUTDOWN_STREAM4 -/* Define to 1 if you have the `ngtcp2_conn_tls_early_data_rejected' function. +/* Define to 1 if you have the 'ngtcp2_conn_tls_early_data_rejected' function. */ #undef HAVE_NGTCP2_CONN_TLS_EARLY_DATA_REJECTED -/* Define to 1 if you have the `ngtcp2_crypto_encrypt_cb' function. */ +/* Define to 1 if you have the 'ngtcp2_crypto_encrypt_cb' function. */ #undef HAVE_NGTCP2_CRYPTO_ENCRYPT_CB /* Define to 1 if you have the - `ngtcp2_crypto_quictls_configure_client_context' function. */ + 'ngtcp2_crypto_quictls_configure_client_context' function. */ #undef HAVE_NGTCP2_CRYPTO_QUICTLS_CONFIGURE_CLIENT_CONTEXT /* Define to 1 if you have the - `ngtcp2_crypto_quictls_configure_server_context' function. */ + 'ngtcp2_crypto_quictls_configure_server_context' function. */ #undef HAVE_NGTCP2_CRYPTO_QUICTLS_CONFIGURE_SERVER_CONTEXT /* Define to 1 if you have the - `ngtcp2_crypto_quictls_from_ossl_encryption_level' function. */ + 'ngtcp2_crypto_quictls_from_ossl_encryption_level' function. */ #undef HAVE_NGTCP2_CRYPTO_QUICTLS_FROM_OSSL_ENCRYPTION_LEVEL -/* Define to 1 if the system has the type `ngtcp2_encryption_level'. */ +/* Define to 1 if the system has the type 'ngtcp2_encryption_level'. */ #undef HAVE_NGTCP2_ENCRYPTION_LEVEL /* Define to 1 if you have the header file. @@ -494,13 +494,13 @@ /* Use libnss for crypto */ #undef HAVE_NSS -/* Define to 1 if you have the `OpenSSL_add_all_digests' function. */ +/* Define to 1 if you have the 'OpenSSL_add_all_digests' function. */ #undef HAVE_OPENSSL_ADD_ALL_DIGESTS /* Define to 1 if you have the header file. */ #undef HAVE_OPENSSL_BN_H -/* Define to 1 if you have the `OPENSSL_config' function. */ +/* Define to 1 if you have the 'OPENSSL_config' function. */ #undef HAVE_OPENSSL_CONFIG /* Define to 1 if you have the header file. */ @@ -521,10 +521,10 @@ /* Define to 1 if you have the header file. */ #undef HAVE_OPENSSL_ERR_H -/* Define to 1 if you have the `OPENSSL_init_crypto' function. */ +/* Define to 1 if you have the 'OPENSSL_init_crypto' function. */ #undef HAVE_OPENSSL_INIT_CRYPTO -/* Define to 1 if you have the `OPENSSL_init_ssl' function. */ +/* Define to 1 if you have the 'OPENSSL_init_ssl' function. */ #undef HAVE_OPENSSL_INIT_SSL /* Define to 1 if you have the header file. */ @@ -539,10 +539,10 @@ /* Define to 1 if you have the header file. */ #undef HAVE_OPENSSL_SSL_H -/* Define to 1 if you have the `OSSL_PARAM_BLD_new' function. */ +/* Define to 1 if you have the 'OSSL_PARAM_BLD_new' function. */ #undef HAVE_OSSL_PARAM_BLD_NEW -/* Define to 1 if you have the `poll' function. */ +/* Define to 1 if you have the 'poll' function. */ #undef HAVE_POLL /* Define to 1 if you have the header file. */ @@ -554,10 +554,10 @@ /* Have PTHREAD_PRIO_INHERIT. */ #undef HAVE_PTHREAD_PRIO_INHERIT -/* Define to 1 if the system has the type `pthread_rwlock_t'. */ +/* Define to 1 if the system has the type 'pthread_rwlock_t'. */ #undef HAVE_PTHREAD_RWLOCK_T -/* Define to 1 if the system has the type `pthread_spinlock_t'. */ +/* Define to 1 if the system has the type 'pthread_spinlock_t'. */ #undef HAVE_PTHREAD_SPINLOCK_T /* Define to 1 if you have the header file. */ @@ -566,101 +566,101 @@ /* Define if you have Python libraries and header files. */ #undef HAVE_PYTHON -/* Define to 1 if you have the `random' function. */ +/* Define to 1 if you have the 'random' function. */ #undef HAVE_RANDOM -/* Define to 1 if you have the `RAND_cleanup' function. */ +/* Define to 1 if you have the 'RAND_cleanup' function. */ #undef HAVE_RAND_CLEANUP /* If we have reallocarray(3) */ #undef HAVE_REALLOCARRAY -/* Define to 1 if you have the `recvmsg' function. */ +/* Define to 1 if you have the 'recvmsg' function. */ #undef HAVE_RECVMSG -/* Define to 1 if you have the `sendmsg' function. */ +/* Define to 1 if you have the 'sendmsg' function. */ #undef HAVE_SENDMSG -/* Define to 1 if you have the `setregid' function. */ +/* Define to 1 if you have the 'setregid' function. */ #undef HAVE_SETREGID -/* Define to 1 if you have the `setresgid' function. */ +/* Define to 1 if you have the 'setresgid' function. */ #undef HAVE_SETRESGID -/* Define to 1 if you have the `setresuid' function. */ +/* Define to 1 if you have the 'setresuid' function. */ #undef HAVE_SETRESUID -/* Define to 1 if you have the `setreuid' function. */ +/* Define to 1 if you have the 'setreuid' function. */ #undef HAVE_SETREUID -/* Define to 1 if you have the `setrlimit' function. */ +/* Define to 1 if you have the 'setrlimit' function. */ #undef HAVE_SETRLIMIT -/* Define to 1 if you have the `setsid' function. */ +/* Define to 1 if you have the 'setsid' function. */ #undef HAVE_SETSID -/* Define to 1 if you have the `setusercontext' function. */ +/* Define to 1 if you have the 'setusercontext' function. */ #undef HAVE_SETUSERCONTEXT -/* Define to 1 if you have the `SHA512_Update' function. */ +/* Define to 1 if you have the 'SHA512_Update' function. */ #undef HAVE_SHA512_UPDATE -/* Define to 1 if you have the `shmget' function. */ +/* Define to 1 if you have the 'shmget' function. */ #undef HAVE_SHMGET -/* Define to 1 if you have the `sigprocmask' function. */ +/* Define to 1 if you have the 'sigprocmask' function. */ #undef HAVE_SIGPROCMASK -/* Define to 1 if you have the `sleep' function. */ +/* Define to 1 if you have the 'sleep' function. */ #undef HAVE_SLEEP -/* Define to 1 if you have the `snprintf' function. */ +/* Define to 1 if you have the 'snprintf' function. */ #undef HAVE_SNPRINTF -/* Define to 1 if you have the `socketpair' function. */ +/* Define to 1 if you have the 'socketpair' function. */ #undef HAVE_SOCKETPAIR /* Using Solaris threads */ #undef HAVE_SOLARIS_THREADS -/* Define to 1 if you have the `srandom' function. */ +/* Define to 1 if you have the 'srandom' function. */ #undef HAVE_SRANDOM /* Define if you have the SSL libraries installed. */ #undef HAVE_SSL -/* Define to 1 if you have the `SSL_CTX_set_alpn_protos' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_alpn_protos' function. */ #undef HAVE_SSL_CTX_SET_ALPN_PROTOS -/* Define to 1 if you have the `SSL_CTX_set_alpn_select_cb' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_alpn_select_cb' function. */ #undef HAVE_SSL_CTX_SET_ALPN_SELECT_CB -/* Define to 1 if you have the `SSL_CTX_set_ciphersuites' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_ciphersuites' function. */ #undef HAVE_SSL_CTX_SET_CIPHERSUITES -/* Define to 1 if you have the `SSL_CTX_set_security_level' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_security_level' function. */ #undef HAVE_SSL_CTX_SET_SECURITY_LEVEL -/* Define to 1 if you have the `SSL_CTX_set_tlsext_ticket_key_evp_cb' +/* Define to 1 if you have the 'SSL_CTX_set_tlsext_ticket_key_evp_cb' function. */ #undef HAVE_SSL_CTX_SET_TLSEXT_TICKET_KEY_EVP_CB -/* Define to 1 if you have the `SSL_CTX_set_tmp_ecdh' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_tmp_ecdh' function. */ #undef HAVE_SSL_CTX_SET_TMP_ECDH -/* Define to 1 if you have the `SSL_get0_alpn_selected' function. */ +/* Define to 1 if you have the 'SSL_get0_alpn_selected' function. */ #undef HAVE_SSL_GET0_ALPN_SELECTED -/* Define to 1 if you have the `SSL_get0_peername' function. */ +/* Define to 1 if you have the 'SSL_get0_peername' function. */ #undef HAVE_SSL_GET0_PEERNAME -/* Define to 1 if you have the `SSL_get1_peer_certificate' function. */ +/* Define to 1 if you have the 'SSL_get1_peer_certificate' function. */ #undef HAVE_SSL_GET1_PEER_CERTIFICATE -/* Define to 1 if you have the `SSL_is_quic' function. */ +/* Define to 1 if you have the 'SSL_is_quic' function. */ #undef HAVE_SSL_IS_QUIC -/* Define to 1 if you have the `SSL_set1_host' function. */ +/* Define to 1 if you have the 'SSL_set1_host' function. */ #undef HAVE_SSL_SET1_HOST /* Define to 1 if you have the header file. */ @@ -681,7 +681,7 @@ /* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H -/* Define to 1 if you have the `strftime' function. */ +/* Define to 1 if you have the 'strftime' function. */ #undef HAVE_STRFTIME /* Define to 1 if you have the header file. */ @@ -690,39 +690,39 @@ /* Define to 1 if you have the header file. */ #undef HAVE_STRING_H -/* Define to 1 if you have the `strlcat' function. */ +/* Define to 1 if you have the 'strlcat' function. */ #undef HAVE_STRLCAT -/* Define to 1 if you have the `strlcpy' function. */ +/* Define to 1 if you have the 'strlcpy' function. */ #undef HAVE_STRLCPY -/* Define to 1 if you have the `strptime' function. */ +/* Define to 1 if you have the 'strptime' function. */ #undef HAVE_STRPTIME -/* Define to 1 if you have the `strsep' function. */ +/* Define to 1 if you have the 'strsep' function. */ #undef HAVE_STRSEP -/* Define to 1 if `ipi_spec_dst' is a member of `struct in_pktinfo'. */ +/* Define to 1 if 'ipi_spec_dst' is a member of 'struct in_pktinfo'. */ #undef HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST -/* Define to 1 if `tokenlen' is a member of `struct ngtcp2_pkt_hd'. */ +/* Define to 1 if 'tokenlen' is a member of 'struct ngtcp2_pkt_hd'. */ #undef HAVE_STRUCT_NGTCP2_PKT_HD_TOKENLEN -/* Define to 1 if `max_tx_udp_payload_size' is a member of `struct +/* Define to 1 if 'max_tx_udp_payload_size' is a member of 'struct ngtcp2_settings'. */ #undef HAVE_STRUCT_NGTCP2_SETTINGS_MAX_TX_UDP_PAYLOAD_SIZE -/* Define to 1 if `tokenlen' is a member of `struct ngtcp2_settings'. */ +/* Define to 1 if 'tokenlen' is a member of 'struct ngtcp2_settings'. */ #undef HAVE_STRUCT_NGTCP2_SETTINGS_TOKENLEN -/* Define to 1 if `original_dcid_present' is a member of `struct +/* Define to 1 if 'original_dcid_present' is a member of 'struct ngtcp2_transport_params'. */ #undef HAVE_STRUCT_NGTCP2_TRANSPORT_PARAMS_ORIGINAL_DCID_PRESENT -/* Define to 1 if the system has the type `struct ngtcp2_version_cid'. */ +/* Define to 1 if the system has the type 'struct ngtcp2_version_cid'. */ #undef HAVE_STRUCT_NGTCP2_VERSION_CID -/* Define to 1 if `sun_len' is a member of `struct sockaddr_un'. */ +/* Define to 1 if 'sun_len' is a member of 'struct sockaddr_un'. */ #undef HAVE_STRUCT_SOCKADDR_UN_SUN_LEN /* Define if you have Swig libraries and header files. */ @@ -782,16 +782,16 @@ /* Define to 1 if you have the header file. */ #undef HAVE_TIME_H -/* Define to 1 if you have the `tzset' function. */ +/* Define to 1 if you have the 'tzset' function. */ #undef HAVE_TZSET /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H -/* Define to 1 if you have the `usleep' function. */ +/* Define to 1 if you have the 'usleep' function. */ #undef HAVE_USLEEP -/* Define to 1 if you have the `vfork' function. */ +/* Define to 1 if you have the 'vfork' function. */ #undef HAVE_VFORK /* Define to 1 if you have the header file. */ @@ -809,22 +809,22 @@ /* Define to 1 if you have the header file. */ #undef HAVE_WINSOCK2_H -/* Define to 1 if `fork' works. */ +/* Define to 1 if 'fork' works. */ #undef HAVE_WORKING_FORK -/* Define to 1 if `vfork' works. */ +/* Define to 1 if 'vfork' works. */ #undef HAVE_WORKING_VFORK -/* Define to 1 if you have the `writev' function. */ +/* Define to 1 if you have the 'writev' function. */ #undef HAVE_WRITEV /* Define to 1 if you have the header file. */ #undef HAVE_WS2TCPIP_H -/* Define to 1 if you have the `X509_VERIFY_PARAM_set1_host' function. */ +/* Define to 1 if you have the 'X509_VERIFY_PARAM_set1_host' function. */ #undef HAVE_X509_VERIFY_PARAM_SET1_HOST -/* Define to 1 if you have the `_beginthreadex' function. */ +/* Define to 1 if you have the '_beginthreadex' function. */ #undef HAVE__BEGINTHREADEX /* If HMAC_Init_ex() returns void */ @@ -923,16 +923,16 @@ /* Shared data */ #undef SHARE_DIR -/* The size of `pthread_t', as computed by sizeof. */ +/* The size of 'pthread_t', as computed by sizeof. */ #undef SIZEOF_PTHREAD_T -/* The size of `size_t', as computed by sizeof. */ +/* The size of 'size_t', as computed by sizeof. */ #undef SIZEOF_SIZE_T -/* The size of `time_t', as computed by sizeof. */ +/* The size of 'time_t', as computed by sizeof. */ #undef SIZEOF_TIME_T -/* The size of `unsigned long', as computed by sizeof. */ +/* The size of 'unsigned long', as computed by sizeof. */ #undef SIZEOF_UNSIGNED_LONG /* define if (v)snprintf does not return length needed, (but length used) */ @@ -941,7 +941,7 @@ /* Define to 1 if libsodium supports sodium_set_misuse_handler */ #undef SODIUM_MISUSE_HANDLER -/* Define to 1 if all of the C90 standard headers exist (not just the ones +/* Define to 1 if all of the C89 standard headers exist (not just the ones required in a freestanding environment). This macro is provided for backward compatibility; new code need not use it. */ #undef STDC_HEADERS @@ -1035,7 +1035,7 @@ /* Define this to enable SHA256 and SHA512 support. */ #undef USE_SHA2 -/* Enable extensions on AIX 3, Interix. */ +/* Enable extensions on AIX, Interix, z/OS. */ #ifndef _ALL_SOURCE # undef _ALL_SOURCE #endif @@ -1096,11 +1096,15 @@ #ifndef __STDC_WANT_IEC_60559_DFP_EXT__ # undef __STDC_WANT_IEC_60559_DFP_EXT__ #endif +/* Enable extensions specified by C23 Annex F. */ +#ifndef __STDC_WANT_IEC_60559_EXT__ +# undef __STDC_WANT_IEC_60559_EXT__ +#endif /* Enable extensions specified by ISO/IEC TS 18661-4:2015. */ #ifndef __STDC_WANT_IEC_60559_FUNCS_EXT__ # undef __STDC_WANT_IEC_60559_FUNCS_EXT__ #endif -/* Enable extensions specified by ISO/IEC TS 18661-3:2015. */ +/* Enable extensions specified by C23 Annex H and ISO/IEC TS 18661-3:2015. */ #ifndef __STDC_WANT_IEC_60559_TYPES_EXT__ # undef __STDC_WANT_IEC_60559_TYPES_EXT__ #endif @@ -1141,30 +1145,36 @@ /* Define if you want PyUnbound. */ #undef WITH_PYUNBOUND -/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a - `char[]'. */ +/* Define to 1 if 'lex' declares 'yytext' as a 'char *' by default, not a + 'char[]'. */ #undef YYTEXT_POINTER /* Number of bits in a file offset, on hosts where this is settable. */ #undef _FILE_OFFSET_BITS -/* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */ +/* Define to 1 if necessary to make fseeko visible. */ #undef _LARGEFILE_SOURCE -/* Define for large files, on AIX-style hosts. */ +/* Define to 1 on platforms where this makes off_t a 64-bit type. */ #undef _LARGE_FILES /* Enable for compile on Minix */ #undef _NETBSD_SOURCE +/* Number of bits in time_t, on hosts where this is settable. */ +#undef _TIME_BITS + +/* Define to 1 on platforms where this makes time_t a 64-bit type. */ +#undef __MINGW_USE_VC2005_COMPAT + /* defined to use gcc ansi snprintf and sscanf that understands %lld when compiled for windows. */ #undef __USE_MINGW_ANSI_STDIO -/* Define to empty if `const' does not conform to ANSI C. */ +/* Define to empty if 'const' does not conform to ANSI C. */ #undef const -/* Define to `int' if doesn't define. */ +/* Define as 'int' if doesn't define. */ #undef gid_t /* in_addr_t */ @@ -1173,28 +1183,28 @@ /* in_port_t */ #undef in_port_t -/* Define to `__inline__' or `__inline' if that's what the C compiler +/* Define to '__inline__' or '__inline' if that's what the C compiler calls it, or to nothing if 'inline' is not supported under any name. */ #ifndef __cplusplus #undef inline #endif -/* Define to `short' if does not define. */ +/* Define to 'short' if does not define. */ #undef int16_t -/* Define to `int' if does not define. */ +/* Define to 'int' if does not define. */ #undef int32_t -/* Define to `long long' if does not define. */ +/* Define to 'long long' if does not define. */ #undef int64_t -/* Define to `signed char' if does not define. */ +/* Define to 'signed char' if does not define. */ #undef int8_t *** 17339 LINES SKIPPED *** From nobody Tue Sep 16 13:59:06 2025 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 4cR3RH1GmCz67JpC; Tue, 16 Sep 2025 13:59:07 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3RG69tnz3Wk1; Tue, 16 Sep 2025 13:59:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031146; 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=GybszpMaMs8WWfGE6f7qacGmNFXkkFApX02il75vk5Y=; b=xUz1A4h35N9FU0Ixyfwt9SVtfCPu7sYs0/KNnkriFzmuNXGFOpSLrS3alib2uCGE1D86bq ctI6GW2b561gBHRPqff4VH7WT17JnSY5cgaftYuM/mDkCWQl1leoGvpo5aLd6hv1D7gYGB uZuMsRaLF2xaG1bIv/82xE3TXnHN6nxSW6Yu8RESxnD2R63WgVZbzs9wi5gFrjbAg7SBNp M+7mZwzu1QpyVdzBP9hGKJ6UtcV0jnBDe9AkscLPhKPnzFZ4b0/VD80OLFAOAOTqVrQ2aG ISEqAJ1+jq7Y+7HZvTVioFSF7VpbQ+FlDdCckNyXNdBn2DaPJTVokodlcH2cSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031146; 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=GybszpMaMs8WWfGE6f7qacGmNFXkkFApX02il75vk5Y=; b=HuhkNKk9DE2vtfDpVwcqTP05I8uDPp2EqfHg0PneT15Mq4+cu6ZsF9UI/jMnRwISCfMMYI PFDiP+Qhysa9HYBw2Q/hUhEafDcf9PiTOk722TMKjf5nNMbuEMM5yo2oCqiDA8M2vBEt3q DwCJ/tHIE159AkGB1a6MEy8m+Ae/q9OW8gJjF2LmbPAzE14boiI6xCFpqe1mgQOkBSmElY FfCq7KbkV+8EMcmq/Vkx077x46vGKPyl16dquP7UA0n9XCStS4Vg3xsKP9XgOIxGj6TPIF ptCcM3L+KHwacV441dGTM9JkvM5abKsF0XXjts9eKTfJ1eW0vL7tlEEJ7ACOlw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031146; a=rsa-sha256; cv=none; b=gxSEAObPrYOyz1hFmbKZ3yfPUUcV/VZcOqukyakKTRdHVn/NunRxLMSaZ46l6YQBTZUSYe vTIpRDploHplr6qnCwQoZarGSgmbHnXH7SfH30xK0XBbY6ZCiib0vSlI4TF7HJzTdeshyr peiBelzUbDecRUL7sJasDz5tG3SW5WsckJnK+4AfmO63ZCc77Q41cL2+Gb6AVsQ2QUwyGa W5vCulFy6810B6p6nBB4UZJIQ1WUOR4gQcV1TkOD6DAB3iq1VbcQtWlLbcnLv5ur6FrWNl 1JcRPMXAOYm6tWtVdxam6wOEZSNIgMRDxhqxI7wNI2qj5Zr2nP9ReEXnZS+dNw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3RG5ZgtzkfT; Tue, 16 Sep 2025 13:59:06 +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 58GDx6ub064317; Tue, 16 Sep 2025 13:59:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDx6oI064314; Tue, 16 Sep 2025 13:59:06 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:06 GMT Message-Id: <202509161359.58GDx6oI064314@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 668fbde7df9a - stable/15 - man: Add -l option 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 668fbde7df9af6e78cef7e9f5fa8ec7cb0966119 Auto-Submitted: auto-generated The branch stable/15 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=668fbde7df9af6e78cef7e9f5fa8ec7cb0966119 commit 668fbde7df9af6e78cef7e9f5fa8ec7cb0966119 Author: Ingo Schwarze AuthorDate: 2025-09-07 20:52:09 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:05:52 +0000 man: Add -l option Add a -l option which causes man to interpret all arguments as paths to open directly rather than man pages to search for in MANPATH. See the PR for a detailed rationale. PR: 289245 MFC after: 1 week Reviewed by: ziaee, emaste Differential Revision: https://reviews.freebsd.org/D52385 (cherry picked from commit 14b61b2e931741281d0bfef426e9809f16006504) --- usr.bin/man/man.1 | 24 ++++++++++++++++++------ usr.bin/man/man.sh | 33 ++++++++++++++++++++++++--------- 2 files changed, 42 insertions(+), 15 deletions(-) diff --git a/usr.bin/man/man.1 b/usr.bin/man/man.1 index 820d6a5b33a9..707677ccce06 100644 --- a/usr.bin/man/man.1 +++ b/usr.bin/man/man.1 @@ -33,7 +33,7 @@ .Nd display online manual documentation pages .Sh SYNOPSIS .Nm -.Op Fl adho +.Op Fl adhlo .Op Fl t | w .Op Fl M Ar manpath .Op Fl P Ar pager @@ -144,6 +144,15 @@ Search names and descriptions of all manual pages for an extended regular .Ar expression , emulating basic functionality of .Xr apropos 1 . +.It Fl l +Interpret all arguments as absolute or relative filename(s) +of the manual page(s) to display. +No search is done and the options +.Fl M , +.Fl m , +and +.Fl S +are ignored. .It Fl m Ar arch Ns Op : Ns Ar machine Override the default architecture and machine settings allowing lookup of other platform specific manual pages. @@ -269,12 +278,15 @@ will search the following paths when considering section 4 manual pages in .Pa /usr/share/man/man4 .El .Ss Displaying Specific Manual Files -The +For compatibility reasons, .Nm -utility also supports displaying a specific manual page if passed a path -to the file as long as it contains a +will interpret any argument containing at least one .Ql / -character. +character as an absolute or relative path to a manual page to be +displayed. +This heuristic, made redundant by the more widely supported +.Fl l +option, is now deprecated and may be removed in future releases. .Sh ENVIRONMENT The following environment variables affect the execution of .Nm : @@ -398,7 +410,7 @@ manual page: .Pp Show a manual page in the current working directory: .Pp -.Dl $ man ./man.1 +.Dl $ man -l man.1 .Pp Show the location of manual pages in sections 1 and 8 which contain the word .Ql arm : diff --git a/usr.bin/man/man.sh b/usr.bin/man/man.sh index 18595042da5f..53961ae4997e 100755 --- a/usr.bin/man/man.sh +++ b/usr.bin/man/man.sh @@ -511,13 +511,21 @@ man_display_page_groff() { # Usage: man_find_and_display page # Search through the manpaths looking for the given page. man_find_and_display() { - local found_page locpath p path sect + local found_page has_slash locpath p path sect # Check to see if it's a file. But only if it has a '/' in - # the filename. + # the filename or if -l was specified. case "$1" in - */*) if [ -f "$1" -a -r "$1" ]; then + */*) has_slash=yes + ;; + esac + if [ -n "$has_slash" -o -n "$lflag" ]; then + if [ -f "$1" -a -r "$1" ]; then decho "Found a usable page, displaying that" + if [ -z "$lflag" ]; then + echo "Opening a file directly is deprecated," \ + "use -l instead." >&2 + fi unset use_cat manpage="$1" setup_cattool "$manpage" @@ -531,9 +539,12 @@ man_find_and_display() { man_display_page fi return + elif [ -n "$lflag" ]; then + echo "Cannot read $1" >&2 + ret=1 + return fi - ;; - esac + fi IFS=: for sect in $MANSECT; do @@ -601,7 +612,7 @@ man_parse_opts() { local cmd_arg OPTIND=1 - while getopts 'K:M:P:S:adfhkm:op:tw' cmd_arg; do + while getopts 'K:M:P:S:adfhklm:op:tw' cmd_arg; do case "${cmd_arg}" in K) Kflag=Kflag REGEXP=$OPTARG ;; @@ -613,6 +624,7 @@ man_parse_opts() { f) fflag=fflag ;; h) man_usage 0 ;; k) kflag=kflag ;; + l) lflag=lflag ;; m) mflag=$OPTARG ;; o) oflag=oflag ;; p) MANROFFSEQ=$OPTARG ;; @@ -625,16 +637,19 @@ man_parse_opts() { shift $(( $OPTIND - 1 )) # Check the args for incompatible options. - - case "${Kflag}${fflag}${kflag}${tflag}${wflag}" in + case "${Kflag}${fflag}${kflag}${lflag}${tflag}${wflag}" in Kflagfflag*) echo "Incompatible options: -K and -f"; man_usage ;; Kflag*kflag*) echo "Incompatible options: -K and -k"; man_usage ;; + Kflag*lflag*) echo "Incompatible options: -K and -l"; man_usage ;; Kflag*tflag) echo "Incompatible options: -K and -t"; man_usage ;; fflagkflag*) echo "Incompatible options: -f and -k"; man_usage ;; + fflag*lflag*) echo "Incompatible options: -f and -l"; man_usage ;; fflag*tflag*) echo "Incompatible options: -f and -t"; man_usage ;; fflag*wflag) echo "Incompatible options: -f and -w"; man_usage ;; - *kflagtflag*) echo "Incompatible options: -k and -t"; man_usage ;; + *kflaglflag*) echo "Incompatible options: -k and -l"; man_usage ;; + *kflag*tflag*) echo "Incompatible options: -k and -t"; man_usage ;; *kflag*wflag) echo "Incompatible options: -k and -w"; man_usage ;; + *lflag*wflag) echo "Incompatible options: -l and -w"; man_usage ;; *tflagwflag) echo "Incompatible options: -t and -w"; man_usage ;; esac From nobody Tue Sep 16 13:59:07 2025 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 4cR3RJ1JcSz67Jbg; Tue, 16 Sep 2025 13:59:08 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3RH6j61z3Wy4; Tue, 16 Sep 2025 13:59:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031148; 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=prJpZbeJi9iKnzhLFSOl2wO54BRLK/4zhpH8+D+33DY=; b=thLZRt5vvHAFGNZeEQGtEC3Bxw2qxsg4XUZGucO7BI4LQH2kbcT6JtLIxOtFcbVfnLdVW8 ozXVjQA01XDh/DTu+7sfU6iERETLJMEQnDta6YTyBX+bQd0wGoszgwtxXOVhEcFlIlf+C0 1e1ClwZ4N5tC730X/qx6PLOplcGs9B4s0weffOQoXszP0p4ErUpyGxqtc2SxxowLr4T5sO e/g8Xlu7whd8l5a3DWCSticGpCKTUptUt/UO6tqSEbFGin21ipx6ECFD9y6MMyvzHgykFa 3GupqDSnbX6d6g9kmGkQgHOkP1x1TqALtP21c4d+TTDcdtmlPVdTyRgV7XzGbQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031147; 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=prJpZbeJi9iKnzhLFSOl2wO54BRLK/4zhpH8+D+33DY=; b=RhcHSB1w6FcX9BG6OmFZa/1gFIG4W75hDeriGJ+7P6JSc6ECxoXYnxh/mQmcogxnKBmF/q fIt3odkx2JTfKrgHYMOQ26QkcHvYOCLJa3n67RKMvEVXc9yQEEh6jSg5Q6fUZTipVTRDd8 39tvtp2bsAKmzpnU9QoiNkGRFoMEUQJNL+k+PxJmUSVQPPQnytu2iG6z4SkZ10kAq0ztEa Q0d91QhXsIuYEdH/PV5WY8LXj2V2+H792kKYaDIu9Bo6tPQHTAkhzyuJciO/NmbqU4cwfD x9AwmHgAQZ7+4fMkxRMqyIdkFvO76WS4uLiFrve7xpiUEoisZmISLzgzjm7J5A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031147; a=rsa-sha256; cv=none; b=sHCl0X0UwAyr3fRbbfFJ7SmVa0iecSBkTatsc1P3lCqSa5fx0imgY3kWWc+3TWsAwSLhoj OswL67Vbi0QJQ1cGUDal86Woc0csheQwW55PdwACbeBRpJfCcsYOILy/RPz7tTG8elhV4f 0eXbgGFYEAqF8RkbGRUVK1vtYEpSemMuhV3YfCh4h5zpLOlh1fzIijg6qLxImkYCR8YIWV 3Ye6Z2wWAgmkhbJE3myXcVB/52XuHwBpzG1Z+cGQ4Zud4Elcj6p9aAPZPHCZ7k/4elQXOL jyTBwExhM0IXHRyqdQmbcEqlMk7Xa7mjQZp0DtuP2gxCCpLbpsK0mIE64WfQQw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3RH69HszkR8; Tue, 16 Sep 2025 13:59:07 +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 58GDx771064356; Tue, 16 Sep 2025 13:59:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDx7GH064353; Tue, 16 Sep 2025 13:59:07 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:07 GMT Message-Id: <202509161359.58GDx7GH064353@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 340f2a651313 - stable/15 - src.sys.mk: Support src.conf in SRCTOP 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 340f2a651313c21b302a9137ba4765a6f04cd1cd Auto-Submitted: auto-generated The branch stable/15 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=340f2a651313c21b302a9137ba4765a6f04cd1cd commit 340f2a651313c21b302a9137ba4765a6f04cd1cd Author: Dag-Erling Smørgrav AuthorDate: 2025-09-10 16:57:26 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:27:43 +0000 src.sys.mk: Support src.conf in SRCTOP If SRCCONF is not defined and src.conf exists at the top level of the source tree, use that instead of /etc/src.conf. MFC after: 3 days Reviewed by: kevans, imp Differential Revision: https://reviews.freebsd.org/D52470 (cherry picked from commit dd8c666d8b78f6b9ddb691f0505837fa885ff3b4) UPDATING: mention the src.conf change Fixes: dd8c666d8b78 ("src.sys.mk: Support src.conf in SRCTOP") (cherry picked from commit ab2fea3f9a5a58f0ba90499ad3a8614e3dca0c5f) --- .gitignore | 1 + UPDATING | 5 +++++ share/man/man5/src.conf.5 | 9 ++++++--- share/mk/src.sys.mk | 4 ++++ sys/conf/kern.pre.mk | 4 ++++ tools/build/options/makeman | 7 +++++-- 6 files changed, 25 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 3ed711f301ac..a53a26f16d4f 100644 --- a/.gitignore +++ b/.gitignore @@ -29,3 +29,4 @@ tags .clangd .ccls-cache sys/*/compile +/src.conf diff --git a/UPDATING b/UPDATING index 2837b5aec0a8..ae4f14a24858 100644 --- a/UPDATING +++ b/UPDATING @@ -12,6 +12,11 @@ Items affecting the ports and packages system can be found in /usr/ports/UPDATING. Please read that file before updating system packages and/or ports. +20250916: + If SRCCONF is unset and a file named src.conf is present at + the top of the source tree, it will now be used instead of + /etc/src.conf. + 20250905: __FreeBSD_version 1500064 after branching stable/15 from main. diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index aa6a85754a8c..d251bf0cd9e7 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -1,5 +1,5 @@ .\" DO NOT EDIT-- this file is @generated by tools/build/options/makeman. -.Dd September 5, 2025 +.Dd September 16, 2025 .Dt SRC.CONF 5 .Os .Sh NAME @@ -29,8 +29,11 @@ variables that control the aspects of how the system builds. .Pp The default location of .Nm -is -.Pa /etc/src.conf , +is the top level of the source tree, or +.Pa /etc/src.conf +if no +.Nm +is found in the source tree itself, though an alternative location can be specified in the .Xr make 1 variable diff --git a/share/mk/src.sys.mk b/share/mk/src.sys.mk index 2b9fc255a26d..ec035fb71e54 100644 --- a/share/mk/src.sys.mk +++ b/share/mk/src.sys.mk @@ -6,7 +6,11 @@ .if !defined(_WITHOUT_SRCCONF) # Allow user to configure things that only effect src tree builds. +.if exists(${SRCTOP}/src.conf) +SRCCONF?= ${SRCTOP}/src.conf +.else SRCCONF?= /etc/src.conf +.endif .if !empty(SRCCONF) && \ (exists(${SRCCONF}) || ${SRCCONF} != "/etc/src.conf") && \ !target(_srcconf_included_) diff --git a/sys/conf/kern.pre.mk b/sys/conf/kern.pre.mk index 1fcfd6467e7f..0251486247da 100644 --- a/sys/conf/kern.pre.mk +++ b/sys/conf/kern.pre.mk @@ -8,7 +8,11 @@ # the rest of /usr/src, but they still always process SRCCONF even though # the normal mechanisms to prevent that (compiling out of tree) won't # work. To ensure they do work, we have to duplicate thee few lines here. +.if exists(${SRCTOP}/src.conf) +SRCCONF?= ${SRCTOP}/src.conf +.else SRCCONF?= /etc/src.conf +.endif .if (exists(${SRCCONF}) || ${SRCCONF} != "/etc/src.conf") && !target(_srcconf_included_) .include "${SRCCONF}" _srcconf_included_: diff --git a/tools/build/options/makeman b/tools/build/options/makeman index ddd08443e61c..88ee5884d180 100755 --- a/tools/build/options/makeman +++ b/tools/build/options/makeman @@ -222,8 +222,11 @@ variables that control the aspects of how the system builds. .Pp The default location of .Nm -is -.Pa /etc/src.conf , +is the top level of the source tree, or +.Pa /etc/src.conf +if no +.Nm +is found in the source tree itself, though an alternative location can be specified in the .Xr make 1 variable From nobody Tue Sep 16 13:59:08 2025 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 4cR3RK2TW5z67JfF; Tue, 16 Sep 2025 13:59:09 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3RK0SLQz3WkM; Tue, 16 Sep 2025 13:59:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031149; 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=v8EXMZ0dNRuBpqqNOayElFsGL6MLw21fAY5W0j80XBA=; b=YJA9t0tpy50TiStTlNtoP3wnob7j+MvYiY+AF0tC/RuAHDqT+D06yGFYzj5f86npQxChav rvcRHX9a1J6We13eteVhpaBJzVkW74Gtwd+g6qQ3NpaxKODFdgLqSEY9/3kGOq8m8aAPIV d7rNEQlSbmy+h95nMOPqP/t0CuKNUmpA+oAJz3I/ukyFBM/mIkj05/IwWxmemYpkaZVdXm Jj1xPlL9MX2W19pFjIwgGTT7cB0pbzOUD5ZcelgpFzTnBDsQNwn6wbssYduXkRdgItZ+a1 zgjsHoRSf6mVrdlqw1YLOT922RzgwyrGdLgEPz/LQlh99kPYAd2XhEubWv6TdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031149; 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=v8EXMZ0dNRuBpqqNOayElFsGL6MLw21fAY5W0j80XBA=; b=F7oWnNqL6bhjMlTf5QfEZAAfYys49Q34gyDy4LjFL3S/VSCVg1s81KDzcH5/v4QHW3BpiX 6ePgkzowL0w7Z2nLqsZys0nemDB9PPy8iypJpKMNDnUWE2TjgnqDlJdOaU1w38yKQAEGvl oGE+30ijXtNIzF8DjxecadVBoM67XuYg+BgBp6O1Iv3j9wFGpFl0Qyg8cwAV/Bq6ezfpx/ vhd4XPL0cg57bYW6EjnDqiNMa93Ppb8DX9bo+ohwtIDC7tUX+o1Kwg49FwtgzU1XxaU3/d 1QN6NzooXd9ER7K5Wz0NhhZeYrnw8Vz5Bl9HJZzwwlwt7ZvuwkZZ2Qs96LnV2w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031149; a=rsa-sha256; cv=none; b=AqSwEEhMF6ptdDBrGOcT9mFrF7uR3NNAOC0FsIOHfXQvbELpQL+npJgqqVKxEG05WiKP4z uDPI1okH/qIzuKjFzr/q6sDeU+wcXIh/f13G7Z+kbJXjcql4W9mLgjUwrSPDQIcTU5PBHm H1kpH08lecqqitD8kX/6o6IQDOpPDYXXBfB0LJB1OoZb5ac4Jtgqws+IJgidauMJElBAiZ 3nQIeCUw4auoNC23z6r1fng+RXBNs6WOcONBfD7uLALekpheRbiU39hdn6y4NoHM9FGbR/ PzEgS1SvHYWuLFmgNRZIeegPhesqouzWwJLmi08l9w8YPqLHiPHzJP8DmLCqrw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3RK00pvzkfV; Tue, 16 Sep 2025 13:59:09 +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 58GDx8NI064391; Tue, 16 Sep 2025 13:59:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDx83v064388; Tue, 16 Sep 2025 13:59:08 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:08 GMT Message-Id: <202509161359.58GDx83v064388@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: f6ff04831acf - stable/15 - uptime: Mention libxo support in manual page 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: f6ff04831acf4b3ae693afb96a090e4a0c3803ab Auto-Submitted: auto-generated The branch stable/15 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=f6ff04831acf4b3ae693afb96a090e4a0c3803ab commit f6ff04831acf4b3ae693afb96a090e4a0c3803ab Author: Dag-Erling Smørgrav AuthorDate: 2025-09-11 20:51:48 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:27:45 +0000 uptime: Mention libxo support in manual page MFC after: 3 days Sponsored by: Klara, Inc. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D52489 (cherry picked from commit 55bd607b9930e5f61219007ad0a81801c8cfdbf3) --- usr.bin/w/uptime.1 | 18 ++++++++++++++++-- usr.bin/w/w.1 | 4 ++-- 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/usr.bin/w/uptime.1 b/usr.bin/w/uptime.1 index b93972d3f932..37881793736f 100644 --- a/usr.bin/w/uptime.1 +++ b/usr.bin/w/uptime.1 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 18, 2020 +.Dd September 11, 2025 .Dt UPTIME 1 .Os .Sh NAME @@ -33,6 +33,7 @@ .Nd show how long system has been running .Sh SYNOPSIS .Nm +.Op Fl -libxo .Sh DESCRIPTION The .Nm @@ -40,6 +41,17 @@ utility displays the current time, the length of time the system has been up, the number of users, and the load average of the system over the last 1, 5, and 15 minutes. +.Pp +The following options are available: +.Bl -tag -width indent +.It Fl -libxo +Generate output via +.Xr libxo 3 +in a selection of different human and machine readable formats. +See +.Xr xo_options 7 +for details on command line arguments. +.El .Sh FILES .Bl -tag -width /boot/kernel/kernel .It Pa /boot/kernel/kernel @@ -51,7 +63,9 @@ $ uptime 11:23AM up 3:01, 8 users, load averages: 21.09, 15.43, 12.79 .Ed .Sh SEE ALSO -.Xr w 1 +.Xr w 1 , +.Xr libxo 3 , +.Xr xo_options 7 .Sh HISTORY The .Nm diff --git a/usr.bin/w/w.1 b/usr.bin/w/w.1 index 159eb3370c8c..2dbcffdeda1f 100644 --- a/usr.bin/w/w.1 +++ b/usr.bin/w/w.1 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd July 16, 2025 +.Dd September 11, 2025 .Dt W 1 .Os .Sh NAME @@ -54,7 +54,7 @@ user is on, the host from which the user is logged in, the time the user logged on, the time since the user last typed anything, and the name and arguments of the current process. .Pp -The options are as follows: +The following options are available: .Bl -tag -width indent .It Fl -libxo Generate output via From nobody Tue Sep 16 13:59:13 2025 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 4cR3RP658rz67JpJ; Tue, 16 Sep 2025 13:59:13 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3RP47spz3XC9; Tue, 16 Sep 2025 13:59:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031153; 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=YsjAkt+zPlBfNYhYmxX1t8AtvE4unTNnf6KiaTZepXs=; b=xsyZq61m/1l1kXlHuPOdgQP0vVE23bxy86pQw/QDfiXu6F+ga452eZVLCTWErITjPBJP4J bDMDJGr2yNYwFASb4rVZEFe45vt7OpfMBwFg8DuigHT+0QAaB/+ZF1y1RtAjkI4bS6d73O i3FNhDz60nabxzusJ1osI/4cMYw4+pZeYawRz6J30dABtIyTX/wYqLFeeIZKlI+kFtW0Kk S/kmU56QgV0a9KzmIkghQLw2jQqBgPOx/3+qZLewSggEeqZfwOdfz0hkk1yWO0F6KvMPAc x7731Tn1325Rm6pyE3vrQJ4k3d3poG2X38BMhavZWzJphwU5aXM3RTo171Zc5A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031153; 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=YsjAkt+zPlBfNYhYmxX1t8AtvE4unTNnf6KiaTZepXs=; b=h2w8bD/CYQxA4CJqabRXLc/pF2Eg8lj+D6xgDZ3Cqg8LusrycSTV6zVi4iweEoUyTgX1xx 525lwPukFVOR0l4OIWMaFxyHYEEuGPJoDWlVnicbp4bTYHxIgTP4ItR12Z6MKSFcfNExRa 4tnbIHiq7yY3hkn42XWWtGE3TWrWyQOBbJZ9ojoMLnl/gX2L73KcZPTj1Z4P0R81AUB4jg fXGZAoUsCVHAFuQb0qTWGGc3vPKHRESN2UPmlBStF/4brndcWtvXE3VXikSRdCOsCphT8W rH0TRdKI/dkJrFU3opE3u2GVm4PuN6CQFiGNCWZY5K0mOJthVEFps14h/DVDMA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031153; a=rsa-sha256; cv=none; b=i6F2eNTUhltBGBeBnJkCcVt5MaQeV33Kl0gR1eBhZYFFZ3XgE6KY8w0G+MZse4TkNc2zx2 +EwMu2vebuE8g4n1DFCGYMKp7U2IGYE2+TMLw2baUZw0nKpBJC68cGUO1XueCrsbh8TTcI BTIUJBQCZ33r+Dr00REXw0Yo9kriZvivnt04BkvfS/R+GWsKNtk/secxMJIOeNv+ppIi3g SqaMi5fyRukud3C5StmYXgq+XiQrzkT7IctbmKCI4NsYJQymsaGQNnY1OvP/CtoV35KZY5 gFjeIGe2QJv9abZw+6ruV+MqL3Zbdslag6GrjoA5oHkfwsL/jbfTtOIOwV9Wew== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3RP3Z4QzkRC; Tue, 16 Sep 2025 13:59:13 +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 58GDxDm2064566; Tue, 16 Sep 2025 13:59:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDxDn0064563; Tue, 16 Sep 2025 13:59:13 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:13 GMT Message-Id: <202509161359.58GDxDn0064563@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: bc8b95bb7695 - stable/14 - w: Fix idle time in json output, add login/idle times to json output 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: bc8b95bb7695b372d0d25d261fa8f3d7beed7fc8 Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=bc8b95bb7695b372d0d25d261fa8f3d7beed7fc8 commit bc8b95bb7695b372d0d25d261fa8f3d7beed7fc8 Author: Marius Halden AuthorDate: 2025-08-29 14:36:32 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:03:58 +0000 w: Fix idle time in json output, add login/idle times to json output Currently the idle time will show as `true` part of the time in the json output and quoting depends on what is being printed. Make sure it's always printed correctly and for consistency treated as a string in the json output. Login time delta and since times are currently exposed in the xml output, expose these times in the json output as well. In the json and xml outputs expose the number of seconds idle as a new field or attribute respectively. MFC after: 1 week Sponsored by: Modirum MDPay Event: Oslo Hackathon 202508 Differential Revision: https://reviews.freebsd.org/D52237 (cherry picked from commit 6e6febb54da91bf5e13007c3d8f4a54495273969) --- usr.bin/w/pr_time.c | 26 +++++++++++++++++++------- 1 file changed, 19 insertions(+), 7 deletions(-) diff --git a/usr.bin/w/pr_time.c b/usr.bin/w/pr_time.c index 7be11b777e79..ff2da1bcc3c9 100644 --- a/usr.bin/w/pr_time.c +++ b/usr.bin/w/pr_time.c @@ -82,8 +82,13 @@ pr_attime(time_t *started, time_t *now) (void)wcsftime(buf, sizeof(buf), fmt, &tp); len = wcslen(buf); width = wcswidth(buf, len); - xo_attr("since", "%lu", (unsigned long) *started); - xo_attr("delta", "%lu", (unsigned long) diff); + if (xo_get_style(NULL) == XO_STYLE_XML) { + xo_attr("since", "%lu", (unsigned long)*started); + xo_attr("delta", "%lu", (unsigned long)diff); + } else { + xo_emit("{e:login-time-since/%lu}{e:login-time-delta/%lu}", + (unsigned long)*started, (unsigned long)diff); + } if (len == width) xo_emit("{:login-time/%-7.7ls/%ls}", buf); else if (width < 7) @@ -103,10 +108,16 @@ pr_attime(time_t *started, time_t *now) int pr_idle(time_t idle) { + /* In encoded formats, emit the raw data as well */ + if (xo_get_style(NULL) == XO_STYLE_XML) + xo_attr("seconds", "%lu", (unsigned long) idle); + else + xo_emit("{e:idle-seconds/%lu}", (unsigned long) idle); + /* If idle more than 36 hours, print as a number of days. */ if (idle >= 36 * 3600) { int days = idle / 86400; - xo_emit(" {:idle/%dday%s} ", days, days > 1 ? "s" : " " ); + xo_emit(" {q:idle/%dday%s} ", days, days > 1 ? "s" : " " ); if (days >= 100) return (2); if (days >= 10) @@ -114,16 +125,17 @@ pr_idle(time_t idle) } /* If idle more than an hour, print as HH:MM. */ - else if (idle >= 3600) - xo_emit(" {:idle/%2d:%02d/} ", + else if (idle >= 3600) { + xo_emit(" {q:idle/%2d:%02d} ", (int)(idle / 3600), (int)((idle % 3600) / 60)); + } else if (idle / 60 == 0) - xo_emit(" - "); + xo_emit(" - {q:idle//0}"); /* Else print the minutes idle. */ else - xo_emit(" {:idle/%2d} ", (int)(idle / 60)); + xo_emit(" {q:idle/%2d} ", (int)(idle / 60)); return (0); /* not idle longer than 9 days */ } From nobody Tue Sep 16 13:59:14 2025 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 4cR3RQ6lJPz67Jrq; Tue, 16 Sep 2025 13:59:14 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3RQ6Dypz3X7M; Tue, 16 Sep 2025 13:59:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031154; 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=OyQUTWRCZUjdZTZTmspKwhAmDhpgIyTBtC3bc4VweJs=; b=V3U99ddtrzIAo6cOhbHur1f2/PHUtpuCzO0Ls8rvASDG28qSqpevyLFASXCaCzJbkBxQ3w Pjc8s1iNybypa5UVl4wpI+XldYAWaVXIL0Rgr8CVTUTyFK3qRx+fpVjTG2hHMBH+HAlgrq Ly65o1jVvwGDKCen5CGLnqQl/ASwbvLwmBGv5gQuBhvM2EFuFQAgvRz/rQPKOPg1BPvaC+ rFmrckrItQK3R4Camgsq7JTUX6vi0A4b+zijFBZiu9J9JFphKdR3SW8UJNxmKBICUEz+mX CfEACH/iAHtKpDdiVo42N3CedajCLOO7CwP5ymZszlZZ+on+jFVfX6+nfrNjoQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031154; 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=OyQUTWRCZUjdZTZTmspKwhAmDhpgIyTBtC3bc4VweJs=; b=TNpJ2fqE6d+C0cyBIGxV1CYjcgUJXmRmllwpr4F7ax8RMdnlsuE1U4MMyEWf98BMwZKieg Wf/LivF0ggeoAVqdnV5hUPufTPbRmArkzlkWwLUhMDk3EyvSdmg6uNbgo3BKwA1nztD26+ +S6cBX8adxSvLRnGxQ7hOoEoYn9jshRo0OKU50kRjbf/1gEs5jPKvIFosAWhC+siwk+bBt 59E3f/D3PZYAu48QRztvIpm9wb7ryMcpcCFnglHXoMYhLEGZZvdgqrEapmsk8OfovY/wl8 YlPkPB9oKAJEso5h4QwT1RtKhsjnoZN+CCpApnrw8GW0kBtJvWaUFM4XSlmTew== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031154; a=rsa-sha256; cv=none; b=KNL1wsKTaISqnOEtf+DT3GxziMGmwUjPpHAuXBrswKxks3gM9bltvzoonh1ZEVAqqUw3Cq EYXs55LHtr5i/tOPh72VHJaIE/YlKPVzYsB/V3Ez+SJiP+6RaYv0nPXU8IJHD/ck0X7mF4 7VFuWv19WWV01LxMNqYx+MeBR80Ov4lu/9CoCKFrfTx5wtFtXKyJA9vWRkk7iRuWPR7eQZ cF7t43EdtG3S+CIvb6O7pnLrg5WMo/zFxE401lQWogtZAhNey5qxGcOmZxIO7/ZWUAMusN CgtehU3WLFdipNUoaq8M5rFW/epSWBjuU7BJB6bzxOi201qaD83XSpZFuaw2ug== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3RQ5VKNzkTD; Tue, 16 Sep 2025 13:59:14 +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 58GDxE7U064601; Tue, 16 Sep 2025 13:59:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDxEFc064598; Tue, 16 Sep 2025 13:59:14 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:14 GMT Message-Id: <202509161359.58GDxEFc064598@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: a2058a619c6b - stable/14 - unbound: Update to 1.23.1 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a2058a619c6b60c2f22ae2fa7e91a3e9b99669d9 Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=a2058a619c6b60c2f22ae2fa7e91a3e9b99669d9 commit a2058a619c6b60c2f22ae2fa7e91a3e9b99669d9 Author: Dag-Erling Smørgrav AuthorDate: 2025-09-07 18:59:20 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:05:54 +0000 unbound: Update to 1.23.1 Release notes at https://nlnetlabs.nl/news/2025/Jul/16/unbound-1.23.1-released/ Since we don't enable ECS, this is mostly a nop for us. Merge commit 'c8864f6ba46ff3271d97b4ae1c3cc6ce01eaf18a' MFC after: 3 days (cherry picked from commit 5a0119491adbea0876d9d6dc0ef3e71f3d64a20b) --- contrib/unbound/config.guess | 17 +- contrib/unbound/config.h.in | 360 +- contrib/unbound/config.sub | 28 +- contrib/unbound/configure | 4467 ++++++++++++--------- contrib/unbound/configure.ac | 5 +- contrib/unbound/doc/README | 2 +- contrib/unbound/doc/example.conf | 300 +- contrib/unbound/doc/example.conf.in | 2 +- contrib/unbound/doc/libunbound.3 | 4 +- contrib/unbound/doc/libunbound.3.in | 4 +- contrib/unbound/doc/unbound-anchor.8 | 14 +- contrib/unbound/doc/unbound-anchor.8.in | 2 +- contrib/unbound/doc/unbound-checkconf.8 | 8 +- contrib/unbound/doc/unbound-checkconf.8.in | 2 +- contrib/unbound/doc/unbound-control.8 | 343 +- contrib/unbound/doc/unbound-control.8.in | 2 +- contrib/unbound/doc/unbound-host.1 | 4 +- contrib/unbound/doc/unbound-host.1.in | 2 +- contrib/unbound/doc/unbound.8 | 8 +- contrib/unbound/doc/unbound.8.in | 4 +- contrib/unbound/doc/unbound.conf.5 | 741 +++- contrib/unbound/doc/unbound.conf.5.in | 2 +- contrib/unbound/edns-subnet/subnetmod.c | 152 +- contrib/unbound/edns-subnet/subnetmod.h | 4 + contrib/unbound/ltmain.sh | 1555 ++++--- contrib/unbound/smallapp/unbound-control-setup.sh | 227 +- lib/libunbound/Makefile | 31 +- lib/libunbound/config.h | 521 ++- 28 files changed, 5633 insertions(+), 3178 deletions(-) diff --git a/contrib/unbound/config.guess b/contrib/unbound/config.guess index 48a684601bd2..a9d01fde4617 100755 --- a/contrib/unbound/config.guess +++ b/contrib/unbound/config.guess @@ -1,10 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2024 Free Software Foundation, Inc. +# Copyright 1992-2025 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale -timestamp='2024-07-27' +timestamp='2025-07-10' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -60,7 +60,7 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2024 Free Software Foundation, Inc. +Copyright 1992-2025 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -1597,8 +1597,11 @@ EOF *:Unleashed:*:*) GUESS=$UNAME_MACHINE-unknown-unleashed$UNAME_RELEASE ;; - *:Ironclad:*:*) - GUESS=$UNAME_MACHINE-unknown-ironclad + x86_64:[Ii]ronclad:*:*|i?86:[Ii]ronclad:*:*) + GUESS=$UNAME_MACHINE-pc-ironclad-mlibc + ;; + *:[Ii]ronclad:*:*) + GUESS=$UNAME_MACHINE-unknown-ironclad-mlibc ;; esac @@ -1808,8 +1811,8 @@ fi exit 1 # Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp nil t) # time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" +# time-stamp-format: "%Y-%02m-%02d" # time-stamp-end: "'" # End: diff --git a/contrib/unbound/config.h.in b/contrib/unbound/config.h.in index f2dc8c8b92b3..584810398b91 100644 --- a/contrib/unbound/config.h.in +++ b/contrib/unbound/config.h.in @@ -48,13 +48,13 @@ internal symbols */ #undef EXPORT_ALL_SYMBOLS -/* Define to 1 if you have the `accept4' function. */ +/* Define to 1 if you have the 'accept4' function. */ #undef HAVE_ACCEPT4 -/* Define to 1 if you have the `arc4random' function. */ +/* Define to 1 if you have the 'arc4random' function. */ #undef HAVE_ARC4RANDOM -/* Define to 1 if you have the `arc4random_uniform' function. */ +/* Define to 1 if you have the 'arc4random_uniform' function. */ #undef HAVE_ARC4RANDOM_UNIFORM /* Define to 1 if you have the header file. */ @@ -78,7 +78,7 @@ /* If we have be64toh */ #undef HAVE_BE64TOH -/* Define to 1 if you have the `BIO_set_callback_ex' function. */ +/* Define to 1 if you have the 'BIO_set_callback_ex' function. */ #undef HAVE_BIO_SET_CALLBACK_EX /* Define to 1 if you have the header file. */ @@ -87,241 +87,241 @@ /* Define to 1 if you have the header file. */ #undef HAVE_BSD_STRING_H -/* Define to 1 if you have the `chown' function. */ +/* Define to 1 if you have the 'chown' function. */ #undef HAVE_CHOWN -/* Define to 1 if you have the `chroot' function. */ +/* Define to 1 if you have the 'chroot' function. */ #undef HAVE_CHROOT -/* Define to 1 if you have the `CRYPTO_cleanup_all_ex_data' function. */ +/* Define to 1 if you have the 'CRYPTO_cleanup_all_ex_data' function. */ #undef HAVE_CRYPTO_CLEANUP_ALL_EX_DATA -/* Define to 1 if you have the `CRYPTO_THREADID_set_callback' function. */ +/* Define to 1 if you have the 'CRYPTO_THREADID_set_callback' function. */ #undef HAVE_CRYPTO_THREADID_SET_CALLBACK -/* Define to 1 if you have the `ctime_r' function. */ +/* Define to 1 if you have the 'ctime_r' function. */ #undef HAVE_CTIME_R -/* Define to 1 if you have the `daemon' function. */ +/* Define to 1 if you have the 'daemon' function. */ #undef HAVE_DAEMON -/* Define to 1 if you have the declaration of `arc4random', and to 0 if you +/* Define to 1 if you have the declaration of 'arc4random', and to 0 if you don't. */ #undef HAVE_DECL_ARC4RANDOM -/* Define to 1 if you have the declaration of `arc4random_uniform', and to 0 +/* Define to 1 if you have the declaration of 'arc4random_uniform', and to 0 if you don't. */ #undef HAVE_DECL_ARC4RANDOM_UNIFORM -/* Define to 1 if you have the declaration of `evsignal_assign', and to 0 if +/* Define to 1 if you have the declaration of 'evsignal_assign', and to 0 if you don't. */ #undef HAVE_DECL_EVSIGNAL_ASSIGN -/* Define to 1 if you have the declaration of `inet_ntop', and to 0 if you +/* Define to 1 if you have the declaration of 'inet_ntop', and to 0 if you don't. */ #undef HAVE_DECL_INET_NTOP -/* Define to 1 if you have the declaration of `inet_pton', and to 0 if you +/* Define to 1 if you have the declaration of 'inet_pton', and to 0 if you don't. */ #undef HAVE_DECL_INET_PTON -/* Define to 1 if you have the declaration of `nghttp2_session_server_new', +/* Define to 1 if you have the declaration of 'nghttp2_session_server_new', and to 0 if you don't. */ #undef HAVE_DECL_NGHTTP2_SESSION_SERVER_NEW -/* Define to 1 if you have the declaration of `ngtcp2_conn_server_new', and to +/* Define to 1 if you have the declaration of 'ngtcp2_conn_server_new', and to 0 if you don't. */ #undef HAVE_DECL_NGTCP2_CONN_SERVER_NEW -/* Define to 1 if you have the declaration of `ngtcp2_crypto_encrypt_cb', and +/* Define to 1 if you have the declaration of 'ngtcp2_crypto_encrypt_cb', and to 0 if you don't. */ #undef HAVE_DECL_NGTCP2_CRYPTO_ENCRYPT_CB -/* Define to 1 if you have the declaration of `NID_ED25519', and to 0 if you +/* Define to 1 if you have the declaration of 'NID_ED25519', and to 0 if you don't. */ #undef HAVE_DECL_NID_ED25519 -/* Define to 1 if you have the declaration of `NID_ED448', and to 0 if you +/* Define to 1 if you have the declaration of 'NID_ED448', and to 0 if you don't. */ #undef HAVE_DECL_NID_ED448 -/* Define to 1 if you have the declaration of `NID_secp384r1', and to 0 if you +/* Define to 1 if you have the declaration of 'NID_secp384r1', and to 0 if you don't. */ #undef HAVE_DECL_NID_SECP384R1 -/* Define to 1 if you have the declaration of `NID_X9_62_prime256v1', and to 0 +/* Define to 1 if you have the declaration of 'NID_X9_62_prime256v1', and to 0 if you don't. */ #undef HAVE_DECL_NID_X9_62_PRIME256V1 -/* Define to 1 if you have the declaration of `reallocarray', and to 0 if you +/* Define to 1 if you have the declaration of 'reallocarray', and to 0 if you don't. */ #undef HAVE_DECL_REALLOCARRAY -/* Define to 1 if you have the declaration of `redisConnect', and to 0 if you +/* Define to 1 if you have the declaration of 'redisConnect', and to 0 if you don't. */ #undef HAVE_DECL_REDISCONNECT -/* Define to 1 if you have the declaration of `sk_SSL_COMP_pop_free', and to 0 +/* Define to 1 if you have the declaration of 'sk_SSL_COMP_pop_free', and to 0 if you don't. */ #undef HAVE_DECL_SK_SSL_COMP_POP_FREE /* Define to 1 if you have the declaration of - `SSL_COMP_get_compression_methods', and to 0 if you don't. */ + 'SSL_COMP_get_compression_methods', and to 0 if you don't. */ #undef HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS -/* Define to 1 if you have the declaration of `SSL_CTX_set_ecdh_auto', and to +/* Define to 1 if you have the declaration of 'SSL_CTX_set_ecdh_auto', and to 0 if you don't. */ #undef HAVE_DECL_SSL_CTX_SET_ECDH_AUTO -/* Define to 1 if you have the declaration of `strlcat', and to 0 if you +/* Define to 1 if you have the declaration of 'strlcat', and to 0 if you don't. */ #undef HAVE_DECL_STRLCAT -/* Define to 1 if you have the declaration of `strlcpy', and to 0 if you +/* Define to 1 if you have the declaration of 'strlcpy', and to 0 if you don't. */ #undef HAVE_DECL_STRLCPY -/* Define to 1 if you have the declaration of `XML_StopParser', and to 0 if +/* Define to 1 if you have the declaration of 'XML_StopParser', and to 0 if you don't. */ #undef HAVE_DECL_XML_STOPPARSER /* Define to 1 if you have the header file. */ #undef HAVE_DLFCN_H -/* Define to 1 if you have the `DSA_SIG_set0' function. */ +/* Define to 1 if you have the 'DSA_SIG_set0' function. */ #undef HAVE_DSA_SIG_SET0 /* Define to 1 if you have the header file. */ #undef HAVE_ENDIAN_H -/* Define to 1 if you have the `endprotoent' function. */ +/* Define to 1 if you have the 'endprotoent' function. */ #undef HAVE_ENDPROTOENT -/* Define to 1 if you have the `endpwent' function. */ +/* Define to 1 if you have the 'endpwent' function. */ #undef HAVE_ENDPWENT -/* Define to 1 if you have the `endservent' function. */ +/* Define to 1 if you have the 'endservent' function. */ #undef HAVE_ENDSERVENT -/* Define to 1 if you have the `ENGINE_cleanup' function. */ +/* Define to 1 if you have the 'ENGINE_cleanup' function. */ #undef HAVE_ENGINE_CLEANUP -/* Define to 1 if you have the `ERR_free_strings' function. */ +/* Define to 1 if you have the 'ERR_free_strings' function. */ #undef HAVE_ERR_FREE_STRINGS -/* Define to 1 if you have the `ERR_load_crypto_strings' function. */ +/* Define to 1 if you have the 'ERR_load_crypto_strings' function. */ #undef HAVE_ERR_LOAD_CRYPTO_STRINGS -/* Define to 1 if you have the `event_assign' function. */ +/* Define to 1 if you have the 'event_assign' function. */ #undef HAVE_EVENT_ASSIGN -/* Define to 1 if you have the `event_base_free' function. */ +/* Define to 1 if you have the 'event_base_free' function. */ #undef HAVE_EVENT_BASE_FREE -/* Define to 1 if you have the `event_base_get_method' function. */ +/* Define to 1 if you have the 'event_base_get_method' function. */ #undef HAVE_EVENT_BASE_GET_METHOD -/* Define to 1 if you have the `event_base_new' function. */ +/* Define to 1 if you have the 'event_base_new' function. */ #undef HAVE_EVENT_BASE_NEW -/* Define to 1 if you have the `event_base_once' function. */ +/* Define to 1 if you have the 'event_base_once' function. */ #undef HAVE_EVENT_BASE_ONCE /* Define to 1 if you have the header file. */ #undef HAVE_EVENT_H -/* Define to 1 if you have the `EVP_aes_256_cbc' function. */ +/* Define to 1 if you have the 'EVP_aes_256_cbc' function. */ #undef HAVE_EVP_AES_256_CBC -/* Define to 1 if you have the `EVP_cleanup' function. */ +/* Define to 1 if you have the 'EVP_cleanup' function. */ #undef HAVE_EVP_CLEANUP -/* Define to 1 if you have the `EVP_default_properties_is_fips_enabled' +/* Define to 1 if you have the 'EVP_default_properties_is_fips_enabled' function. */ #undef HAVE_EVP_DEFAULT_PROPERTIES_IS_FIPS_ENABLED -/* Define to 1 if you have the `EVP_DigestVerify' function. */ +/* Define to 1 if you have the 'EVP_DigestVerify' function. */ #undef HAVE_EVP_DIGESTVERIFY -/* Define to 1 if you have the `EVP_dss1' function. */ +/* Define to 1 if you have the 'EVP_dss1' function. */ #undef HAVE_EVP_DSS1 -/* Define to 1 if you have the `EVP_EncryptInit_ex' function. */ +/* Define to 1 if you have the 'EVP_EncryptInit_ex' function. */ #undef HAVE_EVP_ENCRYPTINIT_EX -/* Define to 1 if you have the `EVP_MAC_CTX_set_params' function. */ +/* Define to 1 if you have the 'EVP_MAC_CTX_set_params' function. */ #undef HAVE_EVP_MAC_CTX_SET_PARAMS -/* Define to 1 if you have the `EVP_MD_CTX_new' function. */ +/* Define to 1 if you have the 'EVP_MD_CTX_new' function. */ #undef HAVE_EVP_MD_CTX_NEW -/* Define to 1 if you have the `EVP_sha1' function. */ +/* Define to 1 if you have the 'EVP_sha1' function. */ #undef HAVE_EVP_SHA1 -/* Define to 1 if you have the `EVP_sha256' function. */ +/* Define to 1 if you have the 'EVP_sha256' function. */ #undef HAVE_EVP_SHA256 -/* Define to 1 if you have the `EVP_sha512' function. */ +/* Define to 1 if you have the 'EVP_sha512' function. */ #undef HAVE_EVP_SHA512 -/* Define to 1 if you have the `ev_default_loop' function. */ +/* Define to 1 if you have the 'ev_default_loop' function. */ #undef HAVE_EV_DEFAULT_LOOP -/* Define to 1 if you have the `ev_loop' function. */ +/* Define to 1 if you have the 'ev_loop' function. */ #undef HAVE_EV_LOOP /* Define to 1 if you have the header file. */ #undef HAVE_EXPAT_H -/* Define to 1 if you have the `explicit_bzero' function. */ +/* Define to 1 if you have the 'explicit_bzero' function. */ #undef HAVE_EXPLICIT_BZERO -/* Define to 1 if you have the `fcntl' function. */ +/* Define to 1 if you have the 'fcntl' function. */ #undef HAVE_FCNTL -/* Define to 1 if you have the `FIPS_mode' function. */ +/* Define to 1 if you have the 'FIPS_mode' function. */ #undef HAVE_FIPS_MODE -/* Define to 1 if you have the `fork' function. */ +/* Define to 1 if you have the 'fork' function. */ #undef HAVE_FORK -/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */ +/* Define to 1 if fseeko (and ftello) are declared in stdio.h. */ #undef HAVE_FSEEKO -/* Define to 1 if you have the `fsync' function. */ +/* Define to 1 if you have the 'fsync' function. */ #undef HAVE_FSYNC /* Whether getaddrinfo is available */ #undef HAVE_GETADDRINFO -/* Define to 1 if you have the `getauxval' function. */ +/* Define to 1 if you have the 'getauxval' function. */ #undef HAVE_GETAUXVAL -/* Define to 1 if you have the `getentropy' function. */ +/* Define to 1 if you have the 'getentropy' function. */ #undef HAVE_GETENTROPY -/* Define to 1 if you have the `getifaddrs' function. */ +/* Define to 1 if you have the 'getifaddrs' function. */ #undef HAVE_GETIFADDRS /* Define to 1 if you have the header file. */ #undef HAVE_GETOPT_H -/* Define to 1 if you have the `getpwnam' function. */ +/* Define to 1 if you have the 'getpwnam' function. */ #undef HAVE_GETPWNAM -/* Define to 1 if you have the `getrlimit' function. */ +/* Define to 1 if you have the 'getrlimit' function. */ #undef HAVE_GETRLIMIT -/* Define to 1 if you have the `gettid' function. */ +/* Define to 1 if you have the 'gettid' function. */ #undef HAVE_GETTID -/* Define to 1 if you have the `glob' function. */ +/* Define to 1 if you have the 'glob' function. */ #undef HAVE_GLOB /* Define to 1 if you have the header file. */ #undef HAVE_GLOB_H -/* Define to 1 if you have the `gmtime_r' function. */ +/* Define to 1 if you have the 'gmtime_r' function. */ #undef HAVE_GMTIME_R /* Define to 1 if you have the header file. */ @@ -330,7 +330,7 @@ /* Define to 1 if you have the header file. */ #undef HAVE_HIREDIS_HIREDIS_H -/* Define to 1 if you have the `HMAC_Init_ex' function. */ +/* Define to 1 if you have the 'HMAC_Init_ex' function. */ #undef HAVE_HMAC_INIT_EX /* If we have htobe64 */ @@ -339,19 +339,19 @@ /* Define to 1 if you have the header file. */ #undef HAVE_IFADDRS_H -/* Define to 1 if you have the `if_nametoindex' function. */ +/* Define to 1 if you have the 'if_nametoindex' function. */ #undef HAVE_IF_NAMETOINDEX -/* Define to 1 if you have the `inet_aton' function. */ +/* Define to 1 if you have the 'inet_aton' function. */ #undef HAVE_INET_ATON -/* Define to 1 if you have the `inet_ntop' function. */ +/* Define to 1 if you have the 'inet_ntop' function. */ #undef HAVE_INET_NTOP -/* Define to 1 if you have the `inet_pton' function. */ +/* Define to 1 if you have the 'inet_pton' function. */ #undef HAVE_INET_PTON -/* Define to 1 if you have the `initgroups' function. */ +/* Define to 1 if you have the 'initgroups' function. */ #undef HAVE_INITGROUPS /* Define to 1 if you have the header file. */ @@ -363,10 +363,10 @@ /* Define to 1 if you have the header file. */ #undef HAVE_IPHLPAPI_H -/* Define to 1 if you have the `isblank' function. */ +/* Define to 1 if you have the 'isblank' function. */ #undef HAVE_ISBLANK -/* Define to 1 if you have the `kill' function. */ +/* Define to 1 if you have the 'kill' function. */ #undef HAVE_KILL /* Use portable libbsd functions */ @@ -384,7 +384,7 @@ /* Define to 1 if you have the header file. */ #undef HAVE_LINUX_NET_TSTAMP_H -/* Define to 1 if you have the `localtime_r' function. */ +/* Define to 1 if you have the 'localtime_r' function. */ #undef HAVE_LOCALTIME_R /* Define to 1 if you have the header file. */ @@ -393,7 +393,7 @@ /* If have GNU libc compatible malloc */ #undef HAVE_MALLOC -/* Define to 1 if you have the `memmove' function. */ +/* Define to 1 if you have the 'memmove' function. */ #undef HAVE_MEMMOVE /* Define to 1 if you have the header file. */ @@ -435,49 +435,49 @@ /* Define this to use ngtcp2. */ #undef HAVE_NGTCP2 -/* Define to 1 if you have the `ngtcp2_ccerr_default' function. */ +/* Define to 1 if you have the 'ngtcp2_ccerr_default' function. */ #undef HAVE_NGTCP2_CCERR_DEFAULT -/* Define to 1 if you have the `ngtcp2_conn_encode_0rtt_transport_params' +/* Define to 1 if you have the 'ngtcp2_conn_encode_0rtt_transport_params' function. */ #undef HAVE_NGTCP2_CONN_ENCODE_0RTT_TRANSPORT_PARAMS -/* Define to 1 if you have the `ngtcp2_conn_get_max_local_streams_uni' +/* Define to 1 if you have the 'ngtcp2_conn_get_max_local_streams_uni' function. */ #undef HAVE_NGTCP2_CONN_GET_MAX_LOCAL_STREAMS_UNI -/* Define to 1 if you have the `ngtcp2_conn_get_num_scid' function. */ +/* Define to 1 if you have the 'ngtcp2_conn_get_num_scid' function. */ #undef HAVE_NGTCP2_CONN_GET_NUM_SCID -/* Define to 1 if you have the `ngtcp2_conn_in_closing_period' function. */ +/* Define to 1 if you have the 'ngtcp2_conn_in_closing_period' function. */ #undef HAVE_NGTCP2_CONN_IN_CLOSING_PERIOD -/* Define to 1 if you have the `ngtcp2_conn_in_draining_period' function. */ +/* Define to 1 if you have the 'ngtcp2_conn_in_draining_period' function. */ #undef HAVE_NGTCP2_CONN_IN_DRAINING_PERIOD /* Define if ngtcp2_conn_shutdown_stream has 4 arguments. */ #undef HAVE_NGTCP2_CONN_SHUTDOWN_STREAM4 -/* Define to 1 if you have the `ngtcp2_conn_tls_early_data_rejected' function. +/* Define to 1 if you have the 'ngtcp2_conn_tls_early_data_rejected' function. */ #undef HAVE_NGTCP2_CONN_TLS_EARLY_DATA_REJECTED -/* Define to 1 if you have the `ngtcp2_crypto_encrypt_cb' function. */ +/* Define to 1 if you have the 'ngtcp2_crypto_encrypt_cb' function. */ #undef HAVE_NGTCP2_CRYPTO_ENCRYPT_CB /* Define to 1 if you have the - `ngtcp2_crypto_quictls_configure_client_context' function. */ + 'ngtcp2_crypto_quictls_configure_client_context' function. */ #undef HAVE_NGTCP2_CRYPTO_QUICTLS_CONFIGURE_CLIENT_CONTEXT /* Define to 1 if you have the - `ngtcp2_crypto_quictls_configure_server_context' function. */ + 'ngtcp2_crypto_quictls_configure_server_context' function. */ #undef HAVE_NGTCP2_CRYPTO_QUICTLS_CONFIGURE_SERVER_CONTEXT /* Define to 1 if you have the - `ngtcp2_crypto_quictls_from_ossl_encryption_level' function. */ + 'ngtcp2_crypto_quictls_from_ossl_encryption_level' function. */ #undef HAVE_NGTCP2_CRYPTO_QUICTLS_FROM_OSSL_ENCRYPTION_LEVEL -/* Define to 1 if the system has the type `ngtcp2_encryption_level'. */ +/* Define to 1 if the system has the type 'ngtcp2_encryption_level'. */ #undef HAVE_NGTCP2_ENCRYPTION_LEVEL /* Define to 1 if you have the header file. @@ -494,13 +494,13 @@ /* Use libnss for crypto */ #undef HAVE_NSS -/* Define to 1 if you have the `OpenSSL_add_all_digests' function. */ +/* Define to 1 if you have the 'OpenSSL_add_all_digests' function. */ #undef HAVE_OPENSSL_ADD_ALL_DIGESTS /* Define to 1 if you have the header file. */ #undef HAVE_OPENSSL_BN_H -/* Define to 1 if you have the `OPENSSL_config' function. */ +/* Define to 1 if you have the 'OPENSSL_config' function. */ #undef HAVE_OPENSSL_CONFIG /* Define to 1 if you have the header file. */ @@ -521,10 +521,10 @@ /* Define to 1 if you have the header file. */ #undef HAVE_OPENSSL_ERR_H -/* Define to 1 if you have the `OPENSSL_init_crypto' function. */ +/* Define to 1 if you have the 'OPENSSL_init_crypto' function. */ #undef HAVE_OPENSSL_INIT_CRYPTO -/* Define to 1 if you have the `OPENSSL_init_ssl' function. */ +/* Define to 1 if you have the 'OPENSSL_init_ssl' function. */ #undef HAVE_OPENSSL_INIT_SSL /* Define to 1 if you have the header file. */ @@ -539,10 +539,10 @@ /* Define to 1 if you have the header file. */ #undef HAVE_OPENSSL_SSL_H -/* Define to 1 if you have the `OSSL_PARAM_BLD_new' function. */ +/* Define to 1 if you have the 'OSSL_PARAM_BLD_new' function. */ #undef HAVE_OSSL_PARAM_BLD_NEW -/* Define to 1 if you have the `poll' function. */ +/* Define to 1 if you have the 'poll' function. */ #undef HAVE_POLL /* Define to 1 if you have the header file. */ @@ -554,10 +554,10 @@ /* Have PTHREAD_PRIO_INHERIT. */ #undef HAVE_PTHREAD_PRIO_INHERIT -/* Define to 1 if the system has the type `pthread_rwlock_t'. */ +/* Define to 1 if the system has the type 'pthread_rwlock_t'. */ #undef HAVE_PTHREAD_RWLOCK_T -/* Define to 1 if the system has the type `pthread_spinlock_t'. */ +/* Define to 1 if the system has the type 'pthread_spinlock_t'. */ #undef HAVE_PTHREAD_SPINLOCK_T /* Define to 1 if you have the header file. */ @@ -566,101 +566,101 @@ /* Define if you have Python libraries and header files. */ #undef HAVE_PYTHON -/* Define to 1 if you have the `random' function. */ +/* Define to 1 if you have the 'random' function. */ #undef HAVE_RANDOM -/* Define to 1 if you have the `RAND_cleanup' function. */ +/* Define to 1 if you have the 'RAND_cleanup' function. */ #undef HAVE_RAND_CLEANUP /* If we have reallocarray(3) */ #undef HAVE_REALLOCARRAY -/* Define to 1 if you have the `recvmsg' function. */ +/* Define to 1 if you have the 'recvmsg' function. */ #undef HAVE_RECVMSG -/* Define to 1 if you have the `sendmsg' function. */ +/* Define to 1 if you have the 'sendmsg' function. */ #undef HAVE_SENDMSG -/* Define to 1 if you have the `setregid' function. */ +/* Define to 1 if you have the 'setregid' function. */ #undef HAVE_SETREGID -/* Define to 1 if you have the `setresgid' function. */ +/* Define to 1 if you have the 'setresgid' function. */ #undef HAVE_SETRESGID -/* Define to 1 if you have the `setresuid' function. */ +/* Define to 1 if you have the 'setresuid' function. */ #undef HAVE_SETRESUID -/* Define to 1 if you have the `setreuid' function. */ +/* Define to 1 if you have the 'setreuid' function. */ #undef HAVE_SETREUID -/* Define to 1 if you have the `setrlimit' function. */ +/* Define to 1 if you have the 'setrlimit' function. */ #undef HAVE_SETRLIMIT -/* Define to 1 if you have the `setsid' function. */ +/* Define to 1 if you have the 'setsid' function. */ #undef HAVE_SETSID -/* Define to 1 if you have the `setusercontext' function. */ +/* Define to 1 if you have the 'setusercontext' function. */ #undef HAVE_SETUSERCONTEXT -/* Define to 1 if you have the `SHA512_Update' function. */ +/* Define to 1 if you have the 'SHA512_Update' function. */ #undef HAVE_SHA512_UPDATE -/* Define to 1 if you have the `shmget' function. */ +/* Define to 1 if you have the 'shmget' function. */ #undef HAVE_SHMGET -/* Define to 1 if you have the `sigprocmask' function. */ +/* Define to 1 if you have the 'sigprocmask' function. */ #undef HAVE_SIGPROCMASK -/* Define to 1 if you have the `sleep' function. */ +/* Define to 1 if you have the 'sleep' function. */ #undef HAVE_SLEEP -/* Define to 1 if you have the `snprintf' function. */ +/* Define to 1 if you have the 'snprintf' function. */ #undef HAVE_SNPRINTF -/* Define to 1 if you have the `socketpair' function. */ +/* Define to 1 if you have the 'socketpair' function. */ #undef HAVE_SOCKETPAIR /* Using Solaris threads */ #undef HAVE_SOLARIS_THREADS -/* Define to 1 if you have the `srandom' function. */ +/* Define to 1 if you have the 'srandom' function. */ #undef HAVE_SRANDOM /* Define if you have the SSL libraries installed. */ #undef HAVE_SSL -/* Define to 1 if you have the `SSL_CTX_set_alpn_protos' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_alpn_protos' function. */ #undef HAVE_SSL_CTX_SET_ALPN_PROTOS -/* Define to 1 if you have the `SSL_CTX_set_alpn_select_cb' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_alpn_select_cb' function. */ #undef HAVE_SSL_CTX_SET_ALPN_SELECT_CB -/* Define to 1 if you have the `SSL_CTX_set_ciphersuites' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_ciphersuites' function. */ #undef HAVE_SSL_CTX_SET_CIPHERSUITES -/* Define to 1 if you have the `SSL_CTX_set_security_level' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_security_level' function. */ #undef HAVE_SSL_CTX_SET_SECURITY_LEVEL -/* Define to 1 if you have the `SSL_CTX_set_tlsext_ticket_key_evp_cb' +/* Define to 1 if you have the 'SSL_CTX_set_tlsext_ticket_key_evp_cb' function. */ #undef HAVE_SSL_CTX_SET_TLSEXT_TICKET_KEY_EVP_CB -/* Define to 1 if you have the `SSL_CTX_set_tmp_ecdh' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_tmp_ecdh' function. */ #undef HAVE_SSL_CTX_SET_TMP_ECDH -/* Define to 1 if you have the `SSL_get0_alpn_selected' function. */ +/* Define to 1 if you have the 'SSL_get0_alpn_selected' function. */ #undef HAVE_SSL_GET0_ALPN_SELECTED -/* Define to 1 if you have the `SSL_get0_peername' function. */ +/* Define to 1 if you have the 'SSL_get0_peername' function. */ #undef HAVE_SSL_GET0_PEERNAME -/* Define to 1 if you have the `SSL_get1_peer_certificate' function. */ +/* Define to 1 if you have the 'SSL_get1_peer_certificate' function. */ #undef HAVE_SSL_GET1_PEER_CERTIFICATE -/* Define to 1 if you have the `SSL_is_quic' function. */ +/* Define to 1 if you have the 'SSL_is_quic' function. */ #undef HAVE_SSL_IS_QUIC -/* Define to 1 if you have the `SSL_set1_host' function. */ +/* Define to 1 if you have the 'SSL_set1_host' function. */ #undef HAVE_SSL_SET1_HOST /* Define to 1 if you have the header file. */ @@ -681,7 +681,7 @@ /* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H -/* Define to 1 if you have the `strftime' function. */ +/* Define to 1 if you have the 'strftime' function. */ #undef HAVE_STRFTIME /* Define to 1 if you have the header file. */ @@ -690,39 +690,39 @@ /* Define to 1 if you have the header file. */ #undef HAVE_STRING_H -/* Define to 1 if you have the `strlcat' function. */ +/* Define to 1 if you have the 'strlcat' function. */ #undef HAVE_STRLCAT -/* Define to 1 if you have the `strlcpy' function. */ +/* Define to 1 if you have the 'strlcpy' function. */ #undef HAVE_STRLCPY -/* Define to 1 if you have the `strptime' function. */ +/* Define to 1 if you have the 'strptime' function. */ #undef HAVE_STRPTIME -/* Define to 1 if you have the `strsep' function. */ +/* Define to 1 if you have the 'strsep' function. */ #undef HAVE_STRSEP -/* Define to 1 if `ipi_spec_dst' is a member of `struct in_pktinfo'. */ +/* Define to 1 if 'ipi_spec_dst' is a member of 'struct in_pktinfo'. */ #undef HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST -/* Define to 1 if `tokenlen' is a member of `struct ngtcp2_pkt_hd'. */ +/* Define to 1 if 'tokenlen' is a member of 'struct ngtcp2_pkt_hd'. */ #undef HAVE_STRUCT_NGTCP2_PKT_HD_TOKENLEN -/* Define to 1 if `max_tx_udp_payload_size' is a member of `struct +/* Define to 1 if 'max_tx_udp_payload_size' is a member of 'struct ngtcp2_settings'. */ #undef HAVE_STRUCT_NGTCP2_SETTINGS_MAX_TX_UDP_PAYLOAD_SIZE -/* Define to 1 if `tokenlen' is a member of `struct ngtcp2_settings'. */ +/* Define to 1 if 'tokenlen' is a member of 'struct ngtcp2_settings'. */ #undef HAVE_STRUCT_NGTCP2_SETTINGS_TOKENLEN -/* Define to 1 if `original_dcid_present' is a member of `struct +/* Define to 1 if 'original_dcid_present' is a member of 'struct ngtcp2_transport_params'. */ #undef HAVE_STRUCT_NGTCP2_TRANSPORT_PARAMS_ORIGINAL_DCID_PRESENT -/* Define to 1 if the system has the type `struct ngtcp2_version_cid'. */ +/* Define to 1 if the system has the type 'struct ngtcp2_version_cid'. */ #undef HAVE_STRUCT_NGTCP2_VERSION_CID -/* Define to 1 if `sun_len' is a member of `struct sockaddr_un'. */ +/* Define to 1 if 'sun_len' is a member of 'struct sockaddr_un'. */ #undef HAVE_STRUCT_SOCKADDR_UN_SUN_LEN /* Define if you have Swig libraries and header files. */ @@ -782,16 +782,16 @@ /* Define to 1 if you have the header file. */ #undef HAVE_TIME_H -/* Define to 1 if you have the `tzset' function. */ +/* Define to 1 if you have the 'tzset' function. */ #undef HAVE_TZSET /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H -/* Define to 1 if you have the `usleep' function. */ +/* Define to 1 if you have the 'usleep' function. */ #undef HAVE_USLEEP -/* Define to 1 if you have the `vfork' function. */ +/* Define to 1 if you have the 'vfork' function. */ #undef HAVE_VFORK /* Define to 1 if you have the header file. */ @@ -809,22 +809,22 @@ /* Define to 1 if you have the header file. */ #undef HAVE_WINSOCK2_H -/* Define to 1 if `fork' works. */ +/* Define to 1 if 'fork' works. */ #undef HAVE_WORKING_FORK -/* Define to 1 if `vfork' works. */ +/* Define to 1 if 'vfork' works. */ #undef HAVE_WORKING_VFORK -/* Define to 1 if you have the `writev' function. */ +/* Define to 1 if you have the 'writev' function. */ #undef HAVE_WRITEV /* Define to 1 if you have the header file. */ #undef HAVE_WS2TCPIP_H -/* Define to 1 if you have the `X509_VERIFY_PARAM_set1_host' function. */ +/* Define to 1 if you have the 'X509_VERIFY_PARAM_set1_host' function. */ #undef HAVE_X509_VERIFY_PARAM_SET1_HOST -/* Define to 1 if you have the `_beginthreadex' function. */ +/* Define to 1 if you have the '_beginthreadex' function. */ #undef HAVE__BEGINTHREADEX /* If HMAC_Init_ex() returns void */ @@ -923,16 +923,16 @@ /* Shared data */ #undef SHARE_DIR -/* The size of `pthread_t', as computed by sizeof. */ +/* The size of 'pthread_t', as computed by sizeof. */ #undef SIZEOF_PTHREAD_T -/* The size of `size_t', as computed by sizeof. */ +/* The size of 'size_t', as computed by sizeof. */ #undef SIZEOF_SIZE_T -/* The size of `time_t', as computed by sizeof. */ +/* The size of 'time_t', as computed by sizeof. */ #undef SIZEOF_TIME_T -/* The size of `unsigned long', as computed by sizeof. */ +/* The size of 'unsigned long', as computed by sizeof. */ #undef SIZEOF_UNSIGNED_LONG /* define if (v)snprintf does not return length needed, (but length used) */ @@ -941,7 +941,7 @@ /* Define to 1 if libsodium supports sodium_set_misuse_handler */ #undef SODIUM_MISUSE_HANDLER -/* Define to 1 if all of the C90 standard headers exist (not just the ones +/* Define to 1 if all of the C89 standard headers exist (not just the ones required in a freestanding environment). This macro is provided for backward compatibility; new code need not use it. */ #undef STDC_HEADERS @@ -1035,7 +1035,7 @@ /* Define this to enable SHA256 and SHA512 support. */ #undef USE_SHA2 -/* Enable extensions on AIX 3, Interix. */ +/* Enable extensions on AIX, Interix, z/OS. */ #ifndef _ALL_SOURCE # undef _ALL_SOURCE #endif @@ -1096,11 +1096,15 @@ #ifndef __STDC_WANT_IEC_60559_DFP_EXT__ # undef __STDC_WANT_IEC_60559_DFP_EXT__ #endif +/* Enable extensions specified by C23 Annex F. */ +#ifndef __STDC_WANT_IEC_60559_EXT__ +# undef __STDC_WANT_IEC_60559_EXT__ +#endif /* Enable extensions specified by ISO/IEC TS 18661-4:2015. */ #ifndef __STDC_WANT_IEC_60559_FUNCS_EXT__ # undef __STDC_WANT_IEC_60559_FUNCS_EXT__ #endif -/* Enable extensions specified by ISO/IEC TS 18661-3:2015. */ +/* Enable extensions specified by C23 Annex H and ISO/IEC TS 18661-3:2015. */ #ifndef __STDC_WANT_IEC_60559_TYPES_EXT__ # undef __STDC_WANT_IEC_60559_TYPES_EXT__ #endif @@ -1141,30 +1145,36 @@ /* Define if you want PyUnbound. */ #undef WITH_PYUNBOUND -/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a - `char[]'. */ +/* Define to 1 if 'lex' declares 'yytext' as a 'char *' by default, not a + 'char[]'. */ #undef YYTEXT_POINTER /* Number of bits in a file offset, on hosts where this is settable. */ #undef _FILE_OFFSET_BITS -/* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */ +/* Define to 1 if necessary to make fseeko visible. */ #undef _LARGEFILE_SOURCE -/* Define for large files, on AIX-style hosts. */ +/* Define to 1 on platforms where this makes off_t a 64-bit type. */ #undef _LARGE_FILES /* Enable for compile on Minix */ #undef _NETBSD_SOURCE +/* Number of bits in time_t, on hosts where this is settable. */ +#undef _TIME_BITS + +/* Define to 1 on platforms where this makes time_t a 64-bit type. */ +#undef __MINGW_USE_VC2005_COMPAT + /* defined to use gcc ansi snprintf and sscanf that understands %lld when compiled for windows. */ #undef __USE_MINGW_ANSI_STDIO -/* Define to empty if `const' does not conform to ANSI C. */ +/* Define to empty if 'const' does not conform to ANSI C. */ #undef const -/* Define to `int' if doesn't define. */ +/* Define as 'int' if doesn't define. */ #undef gid_t /* in_addr_t */ @@ -1173,28 +1183,28 @@ /* in_port_t */ #undef in_port_t -/* Define to `__inline__' or `__inline' if that's what the C compiler +/* Define to '__inline__' or '__inline' if that's what the C compiler calls it, or to nothing if 'inline' is not supported under any name. */ #ifndef __cplusplus #undef inline #endif -/* Define to `short' if does not define. */ +/* Define to 'short' if does not define. */ #undef int16_t -/* Define to `int' if does not define. */ +/* Define to 'int' if does not define. */ #undef int32_t -/* Define to `long long' if does not define. */ +/* Define to 'long long' if does not define. */ #undef int64_t -/* Define to `signed char' if does not define. */ +/* Define to 'signed char' if does not define. */ #undef int8_t *** 17339 LINES SKIPPED *** From nobody Tue Sep 16 13:59:15 2025 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 4cR3RS1hTpz67JpK; Tue, 16 Sep 2025 13:59:16 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3RR71wxz3XNZ; Tue, 16 Sep 2025 13:59:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031156; 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=AV3CEq9Bd2qUExN2/u1mTokaYl++BC8u+iDxk4QHFtc=; b=Yq0alSOM3SwHbopq/FkQ1Ij46SewQzUYZox25t/vy8F+qmLj5zHSHryIu10r0BfDs9HiQZ rAwZhKOSYJjjsqiQvdKv09JL7+FxM9Ok9YMc/Nf02ZLCx5Rbz7EvI3Wz30ayhnkUbjXw4n TsBwhYXUuxzrIoOv0ZTWocwwuEZ3L7I8fuopwa8Z8nzAmdiByjDa/MwGc2abxVrw6J6Gi/ Pe8lciuNFQFPvBknDhGqdZpOGiH2vtSVBl8MF4PbJVtBsKMRnnNLGVN+76a2H0vqMgJx0l qzofQoWJxEFKHyqhlL/HdZ7LPiRhuEpJgWaatT6pHgarxj6q2MuE/g2f6Mr+yA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031156; 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=AV3CEq9Bd2qUExN2/u1mTokaYl++BC8u+iDxk4QHFtc=; b=wI3l9gTnkFPG3twwhEENn0yydkJQrDt7luHwfN9q5zZmKAvH4E0EI5BOuLAR/YMs+/IO2Y JQjz0S/rug+IpOpfO1vR9Muao7rNFbtOxJW7RdPDWzVwKFH7wL2qKGP9gbBEh/mInTWjEb KYy25fC2bZjXJ4bSlBdL+G+PNAwOES3MxK5Rs6WNWYIoVSmx2noyrXIxIFf+5wEfv/siIq JHlkhZTiqywpbnsWfpXAT8XtyKcfuGBU8lbT1sEm9Rt2SVeaGFZQoZ7bck6LnTrCZJ8Hm6 euMjIooW7ehHaPploc60x1EVVkzyWa87Lvd6n34u4LXf7D9N1x0fCdG7f/8csg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031156; a=rsa-sha256; cv=none; b=t8cVUUs+LQ83BNNaBnQ/YNcQWaN6AoWHf1ue4Rd6Jrg5ZwZPgEqtzRRhsNTKpbwkjuU+A8 9Q4NejQoavzHt+3uWD2f2qMohCT8VR2gRPszxoQ52fwPyRuJHcyiJ4SNWq6kwCXKE59eKJ YSTbHFbB2I5Nis4JuOKAUYoKhxmFtDGmOXwUMralD6JbfmuzEgH6wYrmR7nuDq4WLTRix0 aJU3rjBO4WT+9Xh5KiVq1aJ8K4/gCewnQfsOzoJOYdXWud9DiDx5zLm/msTo2FQVpzxXzv TzRT4xr+VGIMIeSxNMik8MO58YnOKgVpxLfOYH+4UWdjqY3iinWaw2G2tcdkCA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3RR69cTzkTF; Tue, 16 Sep 2025 13:59:15 +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 58GDxFgN064636; Tue, 16 Sep 2025 13:59:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDxFxu064633; Tue, 16 Sep 2025 13:59:15 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:15 GMT Message-Id: <202509161359.58GDxFxu064633@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 61735a4f685b - stable/14 - man: Add -l option 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 61735a4f685bb1a1d2a787d79e1541ed017a5ca5 Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=61735a4f685bb1a1d2a787d79e1541ed017a5ca5 commit 61735a4f685bb1a1d2a787d79e1541ed017a5ca5 Author: Ingo Schwarze AuthorDate: 2025-09-07 20:52:09 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:05:54 +0000 man: Add -l option Add a -l option which causes man to interpret all arguments as paths to open directly rather than man pages to search for in MANPATH. See the PR for a detailed rationale. PR: 289245 MFC after: 1 week Reviewed by: ziaee, emaste Differential Revision: https://reviews.freebsd.org/D52385 (cherry picked from commit 14b61b2e931741281d0bfef426e9809f16006504) --- usr.bin/man/man.1 | 24 ++++++++++++++++++------ usr.bin/man/man.sh | 33 ++++++++++++++++++++++++--------- 2 files changed, 42 insertions(+), 15 deletions(-) diff --git a/usr.bin/man/man.1 b/usr.bin/man/man.1 index 820d6a5b33a9..707677ccce06 100644 --- a/usr.bin/man/man.1 +++ b/usr.bin/man/man.1 @@ -33,7 +33,7 @@ .Nd display online manual documentation pages .Sh SYNOPSIS .Nm -.Op Fl adho +.Op Fl adhlo .Op Fl t | w .Op Fl M Ar manpath .Op Fl P Ar pager @@ -144,6 +144,15 @@ Search names and descriptions of all manual pages for an extended regular .Ar expression , emulating basic functionality of .Xr apropos 1 . +.It Fl l +Interpret all arguments as absolute or relative filename(s) +of the manual page(s) to display. +No search is done and the options +.Fl M , +.Fl m , +and +.Fl S +are ignored. .It Fl m Ar arch Ns Op : Ns Ar machine Override the default architecture and machine settings allowing lookup of other platform specific manual pages. @@ -269,12 +278,15 @@ will search the following paths when considering section 4 manual pages in .Pa /usr/share/man/man4 .El .Ss Displaying Specific Manual Files -The +For compatibility reasons, .Nm -utility also supports displaying a specific manual page if passed a path -to the file as long as it contains a +will interpret any argument containing at least one .Ql / -character. +character as an absolute or relative path to a manual page to be +displayed. +This heuristic, made redundant by the more widely supported +.Fl l +option, is now deprecated and may be removed in future releases. .Sh ENVIRONMENT The following environment variables affect the execution of .Nm : @@ -398,7 +410,7 @@ manual page: .Pp Show a manual page in the current working directory: .Pp -.Dl $ man ./man.1 +.Dl $ man -l man.1 .Pp Show the location of manual pages in sections 1 and 8 which contain the word .Ql arm : diff --git a/usr.bin/man/man.sh b/usr.bin/man/man.sh index b1cfc6c41752..fe9c388c0df8 100755 --- a/usr.bin/man/man.sh +++ b/usr.bin/man/man.sh @@ -501,13 +501,21 @@ man_display_page_groff() { # Usage: man_find_and_display page # Search through the manpaths looking for the given page. man_find_and_display() { - local found_page locpath p path sect + local found_page has_slash locpath p path sect # Check to see if it's a file. But only if it has a '/' in - # the filename. + # the filename or if -l was specified. case "$1" in - */*) if [ -f "$1" -a -r "$1" ]; then + */*) has_slash=yes + ;; + esac + if [ -n "$has_slash" -o -n "$lflag" ]; then + if [ -f "$1" -a -r "$1" ]; then decho "Found a usable page, displaying that" + if [ -z "$lflag" ]; then + echo "Opening a file directly is deprecated," \ + "use -l instead." >&2 + fi unset use_cat manpage="$1" setup_cattool "$manpage" @@ -516,9 +524,12 @@ man_find_and_display() { man_display_page fi return + elif [ -n "$lflag" ]; then + echo "Cannot read $1" >&2 + ret=1 + return fi - ;; - esac + fi IFS=: for sect in $MANSECT; do @@ -586,7 +597,7 @@ man_parse_opts() { local cmd_arg OPTIND=1 - while getopts 'K:M:P:S:adfhkm:op:tw' cmd_arg; do + while getopts 'K:M:P:S:adfhklm:op:tw' cmd_arg; do case "${cmd_arg}" in K) Kflag=Kflag REGEXP=$OPTARG ;; @@ -598,6 +609,7 @@ man_parse_opts() { f) fflag=fflag ;; h) man_usage 0 ;; k) kflag=kflag ;; + l) lflag=lflag ;; m) mflag=$OPTARG ;; o) oflag=oflag ;; p) MANROFFSEQ=$OPTARG ;; @@ -610,16 +622,19 @@ man_parse_opts() { shift $(( $OPTIND - 1 )) # Check the args for incompatible options. - - case "${Kflag}${fflag}${kflag}${tflag}${wflag}" in + case "${Kflag}${fflag}${kflag}${lflag}${tflag}${wflag}" in Kflagfflag*) echo "Incompatible options: -K and -f"; man_usage ;; Kflag*kflag*) echo "Incompatible options: -K and -k"; man_usage ;; + Kflag*lflag*) echo "Incompatible options: -K and -l"; man_usage ;; Kflag*tflag) echo "Incompatible options: -K and -t"; man_usage ;; fflagkflag*) echo "Incompatible options: -f and -k"; man_usage ;; + fflag*lflag*) echo "Incompatible options: -f and -l"; man_usage ;; fflag*tflag*) echo "Incompatible options: -f and -t"; man_usage ;; fflag*wflag) echo "Incompatible options: -f and -w"; man_usage ;; - *kflagtflag*) echo "Incompatible options: -k and -t"; man_usage ;; + *kflaglflag*) echo "Incompatible options: -k and -l"; man_usage ;; + *kflag*tflag*) echo "Incompatible options: -k and -t"; man_usage ;; *kflag*wflag) echo "Incompatible options: -k and -w"; man_usage ;; + *lflag*wflag) echo "Incompatible options: -l and -w"; man_usage ;; *tflagwflag) echo "Incompatible options: -t and -w"; man_usage ;; esac From nobody Tue Sep 16 13:59:16 2025 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 4cR3RT4PKHz67Jrr; Tue, 16 Sep 2025 13:59:17 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3RT1kCZz3XK5; Tue, 16 Sep 2025 13:59:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031157; 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=EvW2OmLS3FzlGt1e8hctpbssYbfyQkfenZjBDagOwxg=; b=pI68wgy0OSR1nAflwW0rBv1AGpYyQwD8e5XQExjAXglzRnFb71/zZkcjdocnnWto171cjH NxvcBG+4pCJzntE4soGj063HQV0D/q6EeGr8330fDkLM/7NKe3TLQ/7N6cOf+M+nj8/pxP eAG9sF1vPliE95+gGJ2U6Zb1mgJlZ8CodbHgwRxT5PxFmo6dBIfOH3vd9MTvChg+ncDsER eWhJyGy7b7Xr97FQtb2qhOAI4VpY4GnWFtMsyHvvyMf8Og9D0k/nyd8KDwIJKAkvV4caAr Ep1+XBwiU4SmwpHnJUcGLM48ABV9E4MO9xyjOKn9ycGoAGYUIr91aY5UTMA7Sg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031157; 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=EvW2OmLS3FzlGt1e8hctpbssYbfyQkfenZjBDagOwxg=; b=l2saLQ7EA382nk0JQlv+6e/nFRZonM0CW4khSujRbttZBOWx8XiSlhbNdK0xVpnxrO8G/S AgDYnMG6+VMtlw9Lp1hZBPVIyvTihGmT7PBMh5nLEp66p3HdLP4wD9tGL6BHy3zhC93mLy 9PAUX43EvFDB0CnpsgB/n5tPD9/RldHIuPj1XPdxKHc8gpDcOxMhdCBPb05im5nRpNNnMt Xz3hv5s8r51DfNCDlnwfuv7/xR4XagRoczTG60hwM+RkZ9lv9u5JCoFXs5NkoRxrQnTik4 bfmdd+Et2avx/oQEg4jTw0D0ydU7civYCcFqZMI0+I5Qle3tHODUHzu3rYcPgQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031157; a=rsa-sha256; cv=none; b=sv3UB7Ubh6mR07aL0a4FuvRKSBc/f/8aumklAVutW2dST8Wo4D+0aY+h402jF610YPxFzy O8QX3wn2MxKSDes/IfMAF5RIJS8UuJvlh7px/WlAfc7y0teLImdCejil6DIcTmIxurbhZK SlznpbFsDba/YZV7AiSSqnePCS4FHxFiRZYbuA5RvECrolCpAKpcASWOeUO1XYpzFR6/E6 HdTWjoP7a+OOdC5H54fP/xre3Jg2mJqqqBxi4znrpRfbh+dbrfnXp+b6ZYPU/J1si//Zfh cLF3tuEirVZW51RPyp7aBLEdKf9wv7pL19XpVhBIkj6qtVS+SmKQCWpcTUPSvg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3RT0lxlzkRD; Tue, 16 Sep 2025 13:59:17 +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 58GDxGqO064672; Tue, 16 Sep 2025 13:59:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDxGpM064668; Tue, 16 Sep 2025 13:59:16 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:16 GMT Message-Id: <202509161359.58GDxGpM064668@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: a5bf37963aeb - stable/14 - src.sys.mk: Support src.conf in SRCTOP 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a5bf37963aeb6ee2dc2c26cb39a1931ea7558055 Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=a5bf37963aeb6ee2dc2c26cb39a1931ea7558055 commit a5bf37963aeb6ee2dc2c26cb39a1931ea7558055 Author: Dag-Erling Smørgrav AuthorDate: 2025-09-10 16:57:26 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:27:55 +0000 src.sys.mk: Support src.conf in SRCTOP If SRCCONF is not defined and src.conf exists at the top level of the source tree, use that instead of /etc/src.conf. MFC after: 3 days Reviewed by: kevans, imp Differential Revision: https://reviews.freebsd.org/D52470 (cherry picked from commit dd8c666d8b78f6b9ddb691f0505837fa885ff3b4) UPDATING: mention the src.conf change Fixes: dd8c666d8b78 ("src.sys.mk: Support src.conf in SRCTOP") (cherry picked from commit ab2fea3f9a5a58f0ba90499ad3a8614e3dca0c5f) --- .gitignore | 1 + UPDATING | 5 +++++ share/man/man5/src.conf.5 | 9 ++++++--- share/mk/src.sys.mk | 4 ++++ sys/conf/kern.pre.mk | 4 ++++ tools/build/options/makeman | 7 +++++-- 6 files changed, 25 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 785568271794..ffa366fde357 100644 --- a/.gitignore +++ b/.gitignore @@ -28,3 +28,4 @@ tags .cache .clangd .ccls-cache +/src.conf diff --git a/UPDATING b/UPDATING index 965ecac80055..644e17fc55be 100644 --- a/UPDATING +++ b/UPDATING @@ -12,6 +12,11 @@ Items affecting the ports and packages system can be found in /usr/ports/UPDATING. Please read that file before updating system packages and/or ports. +20250916: + If SRCCONF is unset and a file named src.conf is present at + the top of the source tree, it will now be used instead of + /etc/src.conf. + 20250823: Commit 3f61ececacd8 changed the internal KAPI between the NFS modules. As such, they all need to be rebuilt diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index 63fba6d2ac01..24d041d055a4 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -1,5 +1,5 @@ .\" DO NOT EDIT-- this file is @generated by tools/build/options/makeman. -.Dd June 13, 2025 +.Dd September 16, 2025 .Dt SRC.CONF 5 .Os .Sh NAME @@ -29,8 +29,11 @@ variables that control the aspects of how the system builds. .Pp The default location of .Nm -is -.Pa /etc/src.conf , +is the top level of the source tree, or +.Pa /etc/src.conf +if no +.Nm +is found in the source tree itself, though an alternative location can be specified in the .Xr make 1 variable diff --git a/share/mk/src.sys.mk b/share/mk/src.sys.mk index d5c2af0c559d..d563859586b0 100644 --- a/share/mk/src.sys.mk +++ b/share/mk/src.sys.mk @@ -6,7 +6,11 @@ .if !defined(_WITHOUT_SRCCONF) # Allow user to configure things that only effect src tree builds. +.if exists(${SRCTOP}/src.conf) +SRCCONF?= ${SRCTOP}/src.conf +.else SRCCONF?= /etc/src.conf +.endif .if !empty(SRCCONF) && \ (exists(${SRCCONF}) || ${SRCCONF} != "/etc/src.conf") && \ !target(_srcconf_included_) diff --git a/sys/conf/kern.pre.mk b/sys/conf/kern.pre.mk index ff19cd75d3ea..becd11da64c9 100644 --- a/sys/conf/kern.pre.mk +++ b/sys/conf/kern.pre.mk @@ -8,7 +8,11 @@ # the rest of /usr/src, but they still always process SRCCONF even though # the normal mechanisms to prevent that (compiling out of tree) won't # work. To ensure they do work, we have to duplicate thee few lines here. +.if exists(${SRCTOP}/src.conf) +SRCCONF?= ${SRCTOP}/src.conf +.else SRCCONF?= /etc/src.conf +.endif .if (exists(${SRCCONF}) || ${SRCCONF} != "/etc/src.conf") && !target(_srcconf_included_) .include "${SRCCONF}" _srcconf_included_: diff --git a/tools/build/options/makeman b/tools/build/options/makeman index 4e44c78b0278..fb75990cc383 100755 --- a/tools/build/options/makeman +++ b/tools/build/options/makeman @@ -179,8 +179,11 @@ variables that control the aspects of how the system builds. .Pp The default location of .Nm -is -.Pa /etc/src.conf , +is the top level of the source tree, or +.Pa /etc/src.conf +if no +.Nm +is found in the source tree itself, though an alternative location can be specified in the .Xr make 1 variable From nobody Tue Sep 16 13:59:18 2025 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 4cR3RV3FXDz67JvJ; Tue, 16 Sep 2025 13:59:18 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3RV1P1Nz3XLd; Tue, 16 Sep 2025 13:59:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031158; 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=wkZxPaLVgidQzFNNUA++07nMTD6Wnksn98Yi8MBvcmA=; b=lUYU7WjcxF9s7gX5J7QUZxw6mI5kXztvYZRlLG27AwNUXIUW6cK+ommhw3vdOv2RHOPfoS R/47ZKSuR8bgKbHT+lx5YI9i2sv+e5AbMmvyhAEdMjKQ/NWCWNGAtxpkatyF1wePsYu9Qq Y0kPZ5sLSdyuxVX9kBol10xTutNWSRpkAfXZ5P8h+YEcFYqGy3ufPCS92+mGoq0SoCqXbE gf62wPgLOYclNCesOlqrP2uv3dVF2Vw0o68fHFURdPl0pJ49TEVg/cpGcf+07cZj9p09SY TAmTZkk2TwBJrQ6WDUdVYl1QCE14dc3yXR99As4qeywmchFGC52hGNGo7gYQng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031158; 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=wkZxPaLVgidQzFNNUA++07nMTD6Wnksn98Yi8MBvcmA=; b=lprWWKeU+7YxaPT5PnFOw2TEpUfyJSGVTjyxtY2P3CJp9GymVIsCBlxQtIE0i/kMju6MKw R0kyum9OeAIZV7Wp7xQlnzGWkJrvt0dK0i4jeOrGJcY0Ev+pKOAjND1DkKVGky/ujJ0uvd KDiezhOJUWt48CEwnpqoVQJ5E2lSAnIlYlPHIAO6okeAs5oE6oN9YK+9HqwyZyeG5CJObP oWwHZLeFGbUu7q2H2SVBraR07QiTBAXHJkcM455ZpuF8RdoQ5TaX7nnflOzCecHaJHrTh1 IvywLr1KDUfVduExORyAN5y8BQKYidZNxDONfB/sHnEkSt4zRmi5sXa98x7Qxw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031158; a=rsa-sha256; cv=none; b=n/pIgDBpiOCtuCBt1exbY2zPsp0qcLzUtnrJSsubQc1c7iYKXGSbI+AA3vlCB61dZGsECG ZK/1khUgZzxMzgxqojy9tjNayPhBEV6op/NM8mZaRVc8F5aNCCA8Qt5xzUz8Ea3PTpaFMh ycXWEOVnf4IYwuncJpx9SQk7fHY3jCG2QFHNq2g6MBYbM7wvXDhSyywgthmIvQUSa0yc2c eDK4T2LsfG+rSn4+7Pmm2SVAw8JGHDLV6qgvKUFd2EVtUiVD59XaD7dl4cYPmXRm6csgYL oALpVtCeP9RSTrMJ8rdOyyF54OTp1VLLhUYYzKUNGysIKLxTSiZBIdbosBEyjg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3RV10xzzkBm; Tue, 16 Sep 2025 13:59:18 +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 58GDxILG064715; Tue, 16 Sep 2025 13:59:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDxIBA064712; Tue, 16 Sep 2025 13:59:18 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:18 GMT Message-Id: <202509161359.58GDxIBA064712@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 65ce9cefee56 - stable/14 - uptime: Mention libxo support in manual page 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 65ce9cefee56a15c8361ee5d5154064e11d629a7 Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=65ce9cefee56a15c8361ee5d5154064e11d629a7 commit 65ce9cefee56a15c8361ee5d5154064e11d629a7 Author: Dag-Erling Smørgrav AuthorDate: 2025-09-11 20:51:48 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:27:56 +0000 uptime: Mention libxo support in manual page MFC after: 3 days Sponsored by: Klara, Inc. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D52489 (cherry picked from commit 55bd607b9930e5f61219007ad0a81801c8cfdbf3) --- usr.bin/w/uptime.1 | 18 ++++++++++++++++-- usr.bin/w/w.1 | 4 ++-- 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/usr.bin/w/uptime.1 b/usr.bin/w/uptime.1 index 16c16c0b5318..b20e9066a470 100644 --- a/usr.bin/w/uptime.1 +++ b/usr.bin/w/uptime.1 @@ -27,7 +27,7 @@ .\" .\" @(#)uptime.1 8.2 (Berkeley) 4/18/94 .\" -.Dd August 18, 2020 +.Dd September 11, 2025 .Dt UPTIME 1 .Os .Sh NAME @@ -35,6 +35,7 @@ .Nd show how long system has been running .Sh SYNOPSIS .Nm +.Op Fl -libxo .Sh DESCRIPTION The .Nm @@ -42,6 +43,17 @@ utility displays the current time, the length of time the system has been up, the number of users, and the load average of the system over the last 1, 5, and 15 minutes. +.Pp +The following options are available: +.Bl -tag -width indent +.It Fl -libxo +Generate output via +.Xr libxo 3 +in a selection of different human and machine readable formats. +See +.Xr xo_options 7 +for details on command line arguments. +.El .Sh FILES .Bl -tag -width /boot/kernel/kernel .It Pa /boot/kernel/kernel @@ -53,7 +65,9 @@ $ uptime 11:23AM up 3:01, 8 users, load averages: 21.09, 15.43, 12.79 .Ed .Sh SEE ALSO -.Xr w 1 +.Xr w 1 , +.Xr libxo 3 , +.Xr xo_options 7 .Sh HISTORY The .Nm diff --git a/usr.bin/w/w.1 b/usr.bin/w/w.1 index 7f0d83032d4b..584c5d1b7129 100644 --- a/usr.bin/w/w.1 +++ b/usr.bin/w/w.1 @@ -27,7 +27,7 @@ .\" .\" @(#)w.1 8.1 (Berkeley) 6/6/93 .\" -.Dd August 24, 2020 +.Dd September 11, 2025 .Dt W 1 .Os .Sh NAME @@ -56,7 +56,7 @@ user is on, the host from which the user is logged in, the time the user logged on, the time since the user last typed anything, and the name and arguments of the current process. .Pp -The options are as follows: +The following options are available: .Bl -tag -width indent .It Fl -libxo Generate output via From nobody Tue Sep 16 13:59:22 2025 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 4cR3RZ5lP5z67Jbt; Tue, 16 Sep 2025 13:59:22 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3RZ3tbqz3Xd7; Tue, 16 Sep 2025 13:59:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031162; 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=qbGTIGjX+VJK0fzwUaOAYM5Ny300Rqg0gAHXDR/BKwk=; b=o2K6QrNpCLYLjZysRgQrBjqKkQ+iJhmTVm+FFQvvld6NbBLGXlTQVmdsgJZjMbIkBZTvVP SAWij8Xc36++X9YZJQ5YHy9bPiWbrJOMKHswwrEt4x0KjnHJFG+AufpdUmm9Z32UHo/srr 61r/Rq8bske4z79QU5rztUgElKQeTJueTUhurbYHwzmi85+tXH9nDf1hUwVSHYLdEMbk7f Azm2hgmuTTPSVrQ1cpnWMM9IIxo9s1IuNuZa9CTrIPLodmlY0a1lu6KbaEH2stMspVHBBT RJ649UC0R/85RDOaNv1pxde/BQ43kpAk7KRnF4h7pPHRPL47v0+C3GGzUgsdeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031162; 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=qbGTIGjX+VJK0fzwUaOAYM5Ny300Rqg0gAHXDR/BKwk=; b=b4SwT2soHl84YC8q/vIjnf3xYFp4A08Aih8b80saW/LArSckO7Z5x7dJ9ISNAM5wWrKZPr uAiyiH1LZA6YxdMG7uJu6uNbhgOlrAQH0jgnDNZyY/6sasyiXMZXnahYgz1UN5tjEPhx/I ug2iPchXF9L+5UDV1si3zwHL3fYBgI6fBOTu0Rbz2HCg/9FVb8/G6EAXllHkb+KrymKaF4 0OyNjctL52xJNnnLMIODgIYtVhB2DAkLkTZLUoXtMgsyUwn4et2vKW2A25r2EVneGpz+le ASOl+UodadgQhb72VglCMLp81GAHLmV4a8FCUIPPmVep/tg4xohgvfl5Rb9Tzw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031162; a=rsa-sha256; cv=none; b=sUrpsbp2NOVu77SnoSkA/Uc4C4QBvXtgnBHQQQtY2B0TgQ60yY8vC+BzLO251AibQIfB9a RIE/DwCAzDej+BHztHtmlsy+SG3Wu4b71ysxNtnLHwPSW4aVCL7wBjsAbT+tYgl8xOWvIk RqF6ffQS4lIvYdh/E5IfdMNUKjakurW742MSogMvIqBYP1svebJXufWvYTCCx9qt0H1hZI +KFyKDIXMmLET46JU1IfZH6GuVR3ZrConJy1GD6vw8cEmLT5SCCuJgLN9DT8RxEg67W0Ps Z4S4yAIqoJ0xSdn5mBwZFQ+lPoTKONWJs6ESC3DwDUuhpw4BPP+rgn//aAvBdg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3RZ3MzlzkNd; Tue, 16 Sep 2025 13:59:22 +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 58GDxMoS064895; Tue, 16 Sep 2025 13:59:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDxM68064892; Tue, 16 Sep 2025 13:59:22 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:22 GMT Message-Id: <202509161359.58GDxM68064892@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: d703ae86bfa1 - stable/13 - w: Fix idle time in json output, add login/idle times to json output 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d703ae86bfa1283ffbbaac37c884c61e8c1ead1c Auto-Submitted: auto-generated The branch stable/13 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=d703ae86bfa1283ffbbaac37c884c61e8c1ead1c commit d703ae86bfa1283ffbbaac37c884c61e8c1ead1c Author: Marius Halden AuthorDate: 2025-08-29 14:36:32 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:03:57 +0000 w: Fix idle time in json output, add login/idle times to json output Currently the idle time will show as `true` part of the time in the json output and quoting depends on what is being printed. Make sure it's always printed correctly and for consistency treated as a string in the json output. Login time delta and since times are currently exposed in the xml output, expose these times in the json output as well. In the json and xml outputs expose the number of seconds idle as a new field or attribute respectively. MFC after: 1 week Sponsored by: Modirum MDPay Event: Oslo Hackathon 202508 Differential Revision: https://reviews.freebsd.org/D52237 (cherry picked from commit 6e6febb54da91bf5e13007c3d8f4a54495273969) --- usr.bin/w/pr_time.c | 26 +++++++++++++++++++------- 1 file changed, 19 insertions(+), 7 deletions(-) diff --git a/usr.bin/w/pr_time.c b/usr.bin/w/pr_time.c index 7be11b777e79..ff2da1bcc3c9 100644 --- a/usr.bin/w/pr_time.c +++ b/usr.bin/w/pr_time.c @@ -82,8 +82,13 @@ pr_attime(time_t *started, time_t *now) (void)wcsftime(buf, sizeof(buf), fmt, &tp); len = wcslen(buf); width = wcswidth(buf, len); - xo_attr("since", "%lu", (unsigned long) *started); - xo_attr("delta", "%lu", (unsigned long) diff); + if (xo_get_style(NULL) == XO_STYLE_XML) { + xo_attr("since", "%lu", (unsigned long)*started); + xo_attr("delta", "%lu", (unsigned long)diff); + } else { + xo_emit("{e:login-time-since/%lu}{e:login-time-delta/%lu}", + (unsigned long)*started, (unsigned long)diff); + } if (len == width) xo_emit("{:login-time/%-7.7ls/%ls}", buf); else if (width < 7) @@ -103,10 +108,16 @@ pr_attime(time_t *started, time_t *now) int pr_idle(time_t idle) { + /* In encoded formats, emit the raw data as well */ + if (xo_get_style(NULL) == XO_STYLE_XML) + xo_attr("seconds", "%lu", (unsigned long) idle); + else + xo_emit("{e:idle-seconds/%lu}", (unsigned long) idle); + /* If idle more than 36 hours, print as a number of days. */ if (idle >= 36 * 3600) { int days = idle / 86400; - xo_emit(" {:idle/%dday%s} ", days, days > 1 ? "s" : " " ); + xo_emit(" {q:idle/%dday%s} ", days, days > 1 ? "s" : " " ); if (days >= 100) return (2); if (days >= 10) @@ -114,16 +125,17 @@ pr_idle(time_t idle) } /* If idle more than an hour, print as HH:MM. */ - else if (idle >= 3600) - xo_emit(" {:idle/%2d:%02d/} ", + else if (idle >= 3600) { + xo_emit(" {q:idle/%2d:%02d} ", (int)(idle / 3600), (int)((idle % 3600) / 60)); + } else if (idle / 60 == 0) - xo_emit(" - "); + xo_emit(" - {q:idle//0}"); /* Else print the minutes idle. */ else - xo_emit(" {:idle/%2d} ", (int)(idle / 60)); + xo_emit(" {q:idle/%2d} ", (int)(idle / 60)); return (0); /* not idle longer than 9 days */ } From nobody Tue Sep 16 13:59:23 2025 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 4cR3Rc4bDXz67JxW; Tue, 16 Sep 2025 13:59:24 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3Rc1lZbz3XQM; Tue, 16 Sep 2025 13:59:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031164; 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=hFbbz+z7Miqk2/CWK+Uvyuzss9z0moKHe6EU9tP9rD4=; b=jz9RhkwUuvJYuqh/9YKbOd1Yz1jVrJqgFJ1FRO37sLYaefaHwS6Huqfk/MHgY2Pog03996 V8BbaAU1w90bK3JSOAAugIy27GorDKPM6rwDElcov8sdnzVThTkfuqNxFHwn89yfH7rUYG G4GWFePovGKlo5ZNlROXN/YaIV4SOAzbcafW6baParr2WBJadgGXZIuPVNtoROBkZYOMtm 66/FiU5ZphEFapV/D2TrB975Jx+gC5P8snLizrtKqOWVpsMeVeGnSxN9tvRtha40yUHbyr mtrKmsu06QW19O1I8SXeJztFTRaQLe/DF4maWDWyb/zS633sOK6P1h/B7Ub2vg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031164; 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=hFbbz+z7Miqk2/CWK+Uvyuzss9z0moKHe6EU9tP9rD4=; b=ercMfLshfUDv3ljMNzmn/zx7WAdZITkrv2fg0fY9DgAF55LUIheW2Tl8SbtpR8Kxrmmaex 20uw8xn7oNf/QtDF7XqzWoqz5cHc0QJiwU3b/MO6OrcZygzes8OVfxg1zUlSf/YM/QJXLK 0pgEdPZiPsmf/6gUtZ0CtzhEZMayS7Zd0rd9yqC/gvcxnRK5lITwMXWOkBAqt4QbBjlDtP p3zbAxoERLdR3wQa+n3ONM4T+JDsASOOBBafHheNTPFih4TNH8BA0zM8xHLTVhv1qTJ2CB La8FWOySflR8Yd5E5379k28Gz8XmVXkt/8T/AhkVHTaoBBDJ0r8Use0XsJqI+A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031164; a=rsa-sha256; cv=none; b=k7bTu+rr8vGsqNOGnaR5AZCh2Tr5AQ4/QAHwKnRm40a37+9Yl6puTLCdgkyW+POocsvWHA OjEnn1ZzXSp2wCmVbBFJXbkhgDkjEUtg/UvcZkKVmVa17BxVooRTJk1PGFzwJMzmZ7qqtC hGRbqyB0CMwlsYnsSU7BZr3+eqx2Svi3HL4hl6O0nxbt4EV5KTwcrwYPUiOYJb1ojR5rud BLMb6VVEhqrOY1V5pZMUpv+21mFu6uw2Lz3exm0kzcIFMG/36vKEqECeF+awvfehWihetP GURKda9RohjRAzZK1f/pg2eeRZ785KPmEDgN3R5QGWu6A+gSBywEbA6qUqODHA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3Rb5MQkzjZD; Tue, 16 Sep 2025 13:59:23 +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 58GDxNKd064938; Tue, 16 Sep 2025 13:59:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDxNB4064934; Tue, 16 Sep 2025 13:59:23 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:23 GMT Message-Id: <202509161359.58GDxNB4064934@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: c34e79820b38 - stable/13 - unbound: Update to 1.23.1 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: c34e79820b3852c24180cc5f9dcc15ff7dca3b90 Auto-Submitted: auto-generated The branch stable/13 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=c34e79820b3852c24180cc5f9dcc15ff7dca3b90 commit c34e79820b3852c24180cc5f9dcc15ff7dca3b90 Author: Dag-Erling Smørgrav AuthorDate: 2025-09-07 18:59:20 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:55:22 +0000 unbound: Update to 1.23.1 Release notes at https://nlnetlabs.nl/news/2025/Jul/16/unbound-1.23.1-released/ Since we don't enable ECS, this is mostly a nop for us. Merge commit 'c8864f6ba46ff3271d97b4ae1c3cc6ce01eaf18a' MFC after: 3 days (cherry picked from commit 5a0119491adbea0876d9d6dc0ef3e71f3d64a20b) --- contrib/unbound/config.guess | 17 +- contrib/unbound/config.h.in | 360 +- contrib/unbound/config.sub | 28 +- contrib/unbound/configure | 4467 ++++++++++++--------- contrib/unbound/configure.ac | 5 +- contrib/unbound/doc/README | 2 +- contrib/unbound/doc/example.conf | 300 +- contrib/unbound/doc/example.conf.in | 2 +- contrib/unbound/doc/libunbound.3 | 4 +- contrib/unbound/doc/libunbound.3.in | 4 +- contrib/unbound/doc/unbound-anchor.8 | 14 +- contrib/unbound/doc/unbound-anchor.8.in | 2 +- contrib/unbound/doc/unbound-checkconf.8 | 8 +- contrib/unbound/doc/unbound-checkconf.8.in | 2 +- contrib/unbound/doc/unbound-control.8 | 343 +- contrib/unbound/doc/unbound-control.8.in | 2 +- contrib/unbound/doc/unbound-host.1 | 4 +- contrib/unbound/doc/unbound-host.1.in | 2 +- contrib/unbound/doc/unbound.8 | 8 +- contrib/unbound/doc/unbound.8.in | 4 +- contrib/unbound/doc/unbound.conf.5 | 741 +++- contrib/unbound/doc/unbound.conf.5.in | 2 +- contrib/unbound/edns-subnet/subnetmod.c | 152 +- contrib/unbound/edns-subnet/subnetmod.h | 4 + contrib/unbound/ltmain.sh | 1555 ++++--- contrib/unbound/smallapp/unbound-control-setup.sh | 227 +- lib/libunbound/Makefile | 31 +- lib/libunbound/config.h | 503 ++- 28 files changed, 5624 insertions(+), 3169 deletions(-) diff --git a/contrib/unbound/config.guess b/contrib/unbound/config.guess index 48a684601bd2..a9d01fde4617 100755 --- a/contrib/unbound/config.guess +++ b/contrib/unbound/config.guess @@ -1,10 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2024 Free Software Foundation, Inc. +# Copyright 1992-2025 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale -timestamp='2024-07-27' +timestamp='2025-07-10' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -60,7 +60,7 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2024 Free Software Foundation, Inc. +Copyright 1992-2025 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -1597,8 +1597,11 @@ EOF *:Unleashed:*:*) GUESS=$UNAME_MACHINE-unknown-unleashed$UNAME_RELEASE ;; - *:Ironclad:*:*) - GUESS=$UNAME_MACHINE-unknown-ironclad + x86_64:[Ii]ronclad:*:*|i?86:[Ii]ronclad:*:*) + GUESS=$UNAME_MACHINE-pc-ironclad-mlibc + ;; + *:[Ii]ronclad:*:*) + GUESS=$UNAME_MACHINE-unknown-ironclad-mlibc ;; esac @@ -1808,8 +1811,8 @@ fi exit 1 # Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp nil t) # time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" +# time-stamp-format: "%Y-%02m-%02d" # time-stamp-end: "'" # End: diff --git a/contrib/unbound/config.h.in b/contrib/unbound/config.h.in index f2dc8c8b92b3..584810398b91 100644 --- a/contrib/unbound/config.h.in +++ b/contrib/unbound/config.h.in @@ -48,13 +48,13 @@ internal symbols */ #undef EXPORT_ALL_SYMBOLS -/* Define to 1 if you have the `accept4' function. */ +/* Define to 1 if you have the 'accept4' function. */ #undef HAVE_ACCEPT4 -/* Define to 1 if you have the `arc4random' function. */ +/* Define to 1 if you have the 'arc4random' function. */ #undef HAVE_ARC4RANDOM -/* Define to 1 if you have the `arc4random_uniform' function. */ +/* Define to 1 if you have the 'arc4random_uniform' function. */ #undef HAVE_ARC4RANDOM_UNIFORM /* Define to 1 if you have the header file. */ @@ -78,7 +78,7 @@ /* If we have be64toh */ #undef HAVE_BE64TOH -/* Define to 1 if you have the `BIO_set_callback_ex' function. */ +/* Define to 1 if you have the 'BIO_set_callback_ex' function. */ #undef HAVE_BIO_SET_CALLBACK_EX /* Define to 1 if you have the header file. */ @@ -87,241 +87,241 @@ /* Define to 1 if you have the header file. */ #undef HAVE_BSD_STRING_H -/* Define to 1 if you have the `chown' function. */ +/* Define to 1 if you have the 'chown' function. */ #undef HAVE_CHOWN -/* Define to 1 if you have the `chroot' function. */ +/* Define to 1 if you have the 'chroot' function. */ #undef HAVE_CHROOT -/* Define to 1 if you have the `CRYPTO_cleanup_all_ex_data' function. */ +/* Define to 1 if you have the 'CRYPTO_cleanup_all_ex_data' function. */ #undef HAVE_CRYPTO_CLEANUP_ALL_EX_DATA -/* Define to 1 if you have the `CRYPTO_THREADID_set_callback' function. */ +/* Define to 1 if you have the 'CRYPTO_THREADID_set_callback' function. */ #undef HAVE_CRYPTO_THREADID_SET_CALLBACK -/* Define to 1 if you have the `ctime_r' function. */ +/* Define to 1 if you have the 'ctime_r' function. */ #undef HAVE_CTIME_R -/* Define to 1 if you have the `daemon' function. */ +/* Define to 1 if you have the 'daemon' function. */ #undef HAVE_DAEMON -/* Define to 1 if you have the declaration of `arc4random', and to 0 if you +/* Define to 1 if you have the declaration of 'arc4random', and to 0 if you don't. */ #undef HAVE_DECL_ARC4RANDOM -/* Define to 1 if you have the declaration of `arc4random_uniform', and to 0 +/* Define to 1 if you have the declaration of 'arc4random_uniform', and to 0 if you don't. */ #undef HAVE_DECL_ARC4RANDOM_UNIFORM -/* Define to 1 if you have the declaration of `evsignal_assign', and to 0 if +/* Define to 1 if you have the declaration of 'evsignal_assign', and to 0 if you don't. */ #undef HAVE_DECL_EVSIGNAL_ASSIGN -/* Define to 1 if you have the declaration of `inet_ntop', and to 0 if you +/* Define to 1 if you have the declaration of 'inet_ntop', and to 0 if you don't. */ #undef HAVE_DECL_INET_NTOP -/* Define to 1 if you have the declaration of `inet_pton', and to 0 if you +/* Define to 1 if you have the declaration of 'inet_pton', and to 0 if you don't. */ #undef HAVE_DECL_INET_PTON -/* Define to 1 if you have the declaration of `nghttp2_session_server_new', +/* Define to 1 if you have the declaration of 'nghttp2_session_server_new', and to 0 if you don't. */ #undef HAVE_DECL_NGHTTP2_SESSION_SERVER_NEW -/* Define to 1 if you have the declaration of `ngtcp2_conn_server_new', and to +/* Define to 1 if you have the declaration of 'ngtcp2_conn_server_new', and to 0 if you don't. */ #undef HAVE_DECL_NGTCP2_CONN_SERVER_NEW -/* Define to 1 if you have the declaration of `ngtcp2_crypto_encrypt_cb', and +/* Define to 1 if you have the declaration of 'ngtcp2_crypto_encrypt_cb', and to 0 if you don't. */ #undef HAVE_DECL_NGTCP2_CRYPTO_ENCRYPT_CB -/* Define to 1 if you have the declaration of `NID_ED25519', and to 0 if you +/* Define to 1 if you have the declaration of 'NID_ED25519', and to 0 if you don't. */ #undef HAVE_DECL_NID_ED25519 -/* Define to 1 if you have the declaration of `NID_ED448', and to 0 if you +/* Define to 1 if you have the declaration of 'NID_ED448', and to 0 if you don't. */ #undef HAVE_DECL_NID_ED448 -/* Define to 1 if you have the declaration of `NID_secp384r1', and to 0 if you +/* Define to 1 if you have the declaration of 'NID_secp384r1', and to 0 if you don't. */ #undef HAVE_DECL_NID_SECP384R1 -/* Define to 1 if you have the declaration of `NID_X9_62_prime256v1', and to 0 +/* Define to 1 if you have the declaration of 'NID_X9_62_prime256v1', and to 0 if you don't. */ #undef HAVE_DECL_NID_X9_62_PRIME256V1 -/* Define to 1 if you have the declaration of `reallocarray', and to 0 if you +/* Define to 1 if you have the declaration of 'reallocarray', and to 0 if you don't. */ #undef HAVE_DECL_REALLOCARRAY -/* Define to 1 if you have the declaration of `redisConnect', and to 0 if you +/* Define to 1 if you have the declaration of 'redisConnect', and to 0 if you don't. */ #undef HAVE_DECL_REDISCONNECT -/* Define to 1 if you have the declaration of `sk_SSL_COMP_pop_free', and to 0 +/* Define to 1 if you have the declaration of 'sk_SSL_COMP_pop_free', and to 0 if you don't. */ #undef HAVE_DECL_SK_SSL_COMP_POP_FREE /* Define to 1 if you have the declaration of - `SSL_COMP_get_compression_methods', and to 0 if you don't. */ + 'SSL_COMP_get_compression_methods', and to 0 if you don't. */ #undef HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS -/* Define to 1 if you have the declaration of `SSL_CTX_set_ecdh_auto', and to +/* Define to 1 if you have the declaration of 'SSL_CTX_set_ecdh_auto', and to 0 if you don't. */ #undef HAVE_DECL_SSL_CTX_SET_ECDH_AUTO -/* Define to 1 if you have the declaration of `strlcat', and to 0 if you +/* Define to 1 if you have the declaration of 'strlcat', and to 0 if you don't. */ #undef HAVE_DECL_STRLCAT -/* Define to 1 if you have the declaration of `strlcpy', and to 0 if you +/* Define to 1 if you have the declaration of 'strlcpy', and to 0 if you don't. */ #undef HAVE_DECL_STRLCPY -/* Define to 1 if you have the declaration of `XML_StopParser', and to 0 if +/* Define to 1 if you have the declaration of 'XML_StopParser', and to 0 if you don't. */ #undef HAVE_DECL_XML_STOPPARSER /* Define to 1 if you have the header file. */ #undef HAVE_DLFCN_H -/* Define to 1 if you have the `DSA_SIG_set0' function. */ +/* Define to 1 if you have the 'DSA_SIG_set0' function. */ #undef HAVE_DSA_SIG_SET0 /* Define to 1 if you have the header file. */ #undef HAVE_ENDIAN_H -/* Define to 1 if you have the `endprotoent' function. */ +/* Define to 1 if you have the 'endprotoent' function. */ #undef HAVE_ENDPROTOENT -/* Define to 1 if you have the `endpwent' function. */ +/* Define to 1 if you have the 'endpwent' function. */ #undef HAVE_ENDPWENT -/* Define to 1 if you have the `endservent' function. */ +/* Define to 1 if you have the 'endservent' function. */ #undef HAVE_ENDSERVENT -/* Define to 1 if you have the `ENGINE_cleanup' function. */ +/* Define to 1 if you have the 'ENGINE_cleanup' function. */ #undef HAVE_ENGINE_CLEANUP -/* Define to 1 if you have the `ERR_free_strings' function. */ +/* Define to 1 if you have the 'ERR_free_strings' function. */ #undef HAVE_ERR_FREE_STRINGS -/* Define to 1 if you have the `ERR_load_crypto_strings' function. */ +/* Define to 1 if you have the 'ERR_load_crypto_strings' function. */ #undef HAVE_ERR_LOAD_CRYPTO_STRINGS -/* Define to 1 if you have the `event_assign' function. */ +/* Define to 1 if you have the 'event_assign' function. */ #undef HAVE_EVENT_ASSIGN -/* Define to 1 if you have the `event_base_free' function. */ +/* Define to 1 if you have the 'event_base_free' function. */ #undef HAVE_EVENT_BASE_FREE -/* Define to 1 if you have the `event_base_get_method' function. */ +/* Define to 1 if you have the 'event_base_get_method' function. */ #undef HAVE_EVENT_BASE_GET_METHOD -/* Define to 1 if you have the `event_base_new' function. */ +/* Define to 1 if you have the 'event_base_new' function. */ #undef HAVE_EVENT_BASE_NEW -/* Define to 1 if you have the `event_base_once' function. */ +/* Define to 1 if you have the 'event_base_once' function. */ #undef HAVE_EVENT_BASE_ONCE /* Define to 1 if you have the header file. */ #undef HAVE_EVENT_H -/* Define to 1 if you have the `EVP_aes_256_cbc' function. */ +/* Define to 1 if you have the 'EVP_aes_256_cbc' function. */ #undef HAVE_EVP_AES_256_CBC -/* Define to 1 if you have the `EVP_cleanup' function. */ +/* Define to 1 if you have the 'EVP_cleanup' function. */ #undef HAVE_EVP_CLEANUP -/* Define to 1 if you have the `EVP_default_properties_is_fips_enabled' +/* Define to 1 if you have the 'EVP_default_properties_is_fips_enabled' function. */ #undef HAVE_EVP_DEFAULT_PROPERTIES_IS_FIPS_ENABLED -/* Define to 1 if you have the `EVP_DigestVerify' function. */ +/* Define to 1 if you have the 'EVP_DigestVerify' function. */ #undef HAVE_EVP_DIGESTVERIFY -/* Define to 1 if you have the `EVP_dss1' function. */ +/* Define to 1 if you have the 'EVP_dss1' function. */ #undef HAVE_EVP_DSS1 -/* Define to 1 if you have the `EVP_EncryptInit_ex' function. */ +/* Define to 1 if you have the 'EVP_EncryptInit_ex' function. */ #undef HAVE_EVP_ENCRYPTINIT_EX -/* Define to 1 if you have the `EVP_MAC_CTX_set_params' function. */ +/* Define to 1 if you have the 'EVP_MAC_CTX_set_params' function. */ #undef HAVE_EVP_MAC_CTX_SET_PARAMS -/* Define to 1 if you have the `EVP_MD_CTX_new' function. */ +/* Define to 1 if you have the 'EVP_MD_CTX_new' function. */ #undef HAVE_EVP_MD_CTX_NEW -/* Define to 1 if you have the `EVP_sha1' function. */ +/* Define to 1 if you have the 'EVP_sha1' function. */ #undef HAVE_EVP_SHA1 -/* Define to 1 if you have the `EVP_sha256' function. */ +/* Define to 1 if you have the 'EVP_sha256' function. */ #undef HAVE_EVP_SHA256 -/* Define to 1 if you have the `EVP_sha512' function. */ +/* Define to 1 if you have the 'EVP_sha512' function. */ #undef HAVE_EVP_SHA512 -/* Define to 1 if you have the `ev_default_loop' function. */ +/* Define to 1 if you have the 'ev_default_loop' function. */ #undef HAVE_EV_DEFAULT_LOOP -/* Define to 1 if you have the `ev_loop' function. */ +/* Define to 1 if you have the 'ev_loop' function. */ #undef HAVE_EV_LOOP /* Define to 1 if you have the header file. */ #undef HAVE_EXPAT_H -/* Define to 1 if you have the `explicit_bzero' function. */ +/* Define to 1 if you have the 'explicit_bzero' function. */ #undef HAVE_EXPLICIT_BZERO -/* Define to 1 if you have the `fcntl' function. */ +/* Define to 1 if you have the 'fcntl' function. */ #undef HAVE_FCNTL -/* Define to 1 if you have the `FIPS_mode' function. */ +/* Define to 1 if you have the 'FIPS_mode' function. */ #undef HAVE_FIPS_MODE -/* Define to 1 if you have the `fork' function. */ +/* Define to 1 if you have the 'fork' function. */ #undef HAVE_FORK -/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */ +/* Define to 1 if fseeko (and ftello) are declared in stdio.h. */ #undef HAVE_FSEEKO -/* Define to 1 if you have the `fsync' function. */ +/* Define to 1 if you have the 'fsync' function. */ #undef HAVE_FSYNC /* Whether getaddrinfo is available */ #undef HAVE_GETADDRINFO -/* Define to 1 if you have the `getauxval' function. */ +/* Define to 1 if you have the 'getauxval' function. */ #undef HAVE_GETAUXVAL -/* Define to 1 if you have the `getentropy' function. */ +/* Define to 1 if you have the 'getentropy' function. */ #undef HAVE_GETENTROPY -/* Define to 1 if you have the `getifaddrs' function. */ +/* Define to 1 if you have the 'getifaddrs' function. */ #undef HAVE_GETIFADDRS /* Define to 1 if you have the header file. */ #undef HAVE_GETOPT_H -/* Define to 1 if you have the `getpwnam' function. */ +/* Define to 1 if you have the 'getpwnam' function. */ #undef HAVE_GETPWNAM -/* Define to 1 if you have the `getrlimit' function. */ +/* Define to 1 if you have the 'getrlimit' function. */ #undef HAVE_GETRLIMIT -/* Define to 1 if you have the `gettid' function. */ +/* Define to 1 if you have the 'gettid' function. */ #undef HAVE_GETTID -/* Define to 1 if you have the `glob' function. */ +/* Define to 1 if you have the 'glob' function. */ #undef HAVE_GLOB /* Define to 1 if you have the header file. */ #undef HAVE_GLOB_H -/* Define to 1 if you have the `gmtime_r' function. */ +/* Define to 1 if you have the 'gmtime_r' function. */ #undef HAVE_GMTIME_R /* Define to 1 if you have the header file. */ @@ -330,7 +330,7 @@ /* Define to 1 if you have the header file. */ #undef HAVE_HIREDIS_HIREDIS_H -/* Define to 1 if you have the `HMAC_Init_ex' function. */ +/* Define to 1 if you have the 'HMAC_Init_ex' function. */ #undef HAVE_HMAC_INIT_EX /* If we have htobe64 */ @@ -339,19 +339,19 @@ /* Define to 1 if you have the header file. */ #undef HAVE_IFADDRS_H -/* Define to 1 if you have the `if_nametoindex' function. */ +/* Define to 1 if you have the 'if_nametoindex' function. */ #undef HAVE_IF_NAMETOINDEX -/* Define to 1 if you have the `inet_aton' function. */ +/* Define to 1 if you have the 'inet_aton' function. */ #undef HAVE_INET_ATON -/* Define to 1 if you have the `inet_ntop' function. */ +/* Define to 1 if you have the 'inet_ntop' function. */ #undef HAVE_INET_NTOP -/* Define to 1 if you have the `inet_pton' function. */ +/* Define to 1 if you have the 'inet_pton' function. */ #undef HAVE_INET_PTON -/* Define to 1 if you have the `initgroups' function. */ +/* Define to 1 if you have the 'initgroups' function. */ #undef HAVE_INITGROUPS /* Define to 1 if you have the header file. */ @@ -363,10 +363,10 @@ /* Define to 1 if you have the header file. */ #undef HAVE_IPHLPAPI_H -/* Define to 1 if you have the `isblank' function. */ +/* Define to 1 if you have the 'isblank' function. */ #undef HAVE_ISBLANK -/* Define to 1 if you have the `kill' function. */ +/* Define to 1 if you have the 'kill' function. */ #undef HAVE_KILL /* Use portable libbsd functions */ @@ -384,7 +384,7 @@ /* Define to 1 if you have the header file. */ #undef HAVE_LINUX_NET_TSTAMP_H -/* Define to 1 if you have the `localtime_r' function. */ +/* Define to 1 if you have the 'localtime_r' function. */ #undef HAVE_LOCALTIME_R /* Define to 1 if you have the header file. */ @@ -393,7 +393,7 @@ /* If have GNU libc compatible malloc */ #undef HAVE_MALLOC -/* Define to 1 if you have the `memmove' function. */ +/* Define to 1 if you have the 'memmove' function. */ #undef HAVE_MEMMOVE /* Define to 1 if you have the header file. */ @@ -435,49 +435,49 @@ /* Define this to use ngtcp2. */ #undef HAVE_NGTCP2 -/* Define to 1 if you have the `ngtcp2_ccerr_default' function. */ +/* Define to 1 if you have the 'ngtcp2_ccerr_default' function. */ #undef HAVE_NGTCP2_CCERR_DEFAULT -/* Define to 1 if you have the `ngtcp2_conn_encode_0rtt_transport_params' +/* Define to 1 if you have the 'ngtcp2_conn_encode_0rtt_transport_params' function. */ #undef HAVE_NGTCP2_CONN_ENCODE_0RTT_TRANSPORT_PARAMS -/* Define to 1 if you have the `ngtcp2_conn_get_max_local_streams_uni' +/* Define to 1 if you have the 'ngtcp2_conn_get_max_local_streams_uni' function. */ #undef HAVE_NGTCP2_CONN_GET_MAX_LOCAL_STREAMS_UNI -/* Define to 1 if you have the `ngtcp2_conn_get_num_scid' function. */ +/* Define to 1 if you have the 'ngtcp2_conn_get_num_scid' function. */ #undef HAVE_NGTCP2_CONN_GET_NUM_SCID -/* Define to 1 if you have the `ngtcp2_conn_in_closing_period' function. */ +/* Define to 1 if you have the 'ngtcp2_conn_in_closing_period' function. */ #undef HAVE_NGTCP2_CONN_IN_CLOSING_PERIOD -/* Define to 1 if you have the `ngtcp2_conn_in_draining_period' function. */ +/* Define to 1 if you have the 'ngtcp2_conn_in_draining_period' function. */ #undef HAVE_NGTCP2_CONN_IN_DRAINING_PERIOD /* Define if ngtcp2_conn_shutdown_stream has 4 arguments. */ #undef HAVE_NGTCP2_CONN_SHUTDOWN_STREAM4 -/* Define to 1 if you have the `ngtcp2_conn_tls_early_data_rejected' function. +/* Define to 1 if you have the 'ngtcp2_conn_tls_early_data_rejected' function. */ #undef HAVE_NGTCP2_CONN_TLS_EARLY_DATA_REJECTED -/* Define to 1 if you have the `ngtcp2_crypto_encrypt_cb' function. */ +/* Define to 1 if you have the 'ngtcp2_crypto_encrypt_cb' function. */ #undef HAVE_NGTCP2_CRYPTO_ENCRYPT_CB /* Define to 1 if you have the - `ngtcp2_crypto_quictls_configure_client_context' function. */ + 'ngtcp2_crypto_quictls_configure_client_context' function. */ #undef HAVE_NGTCP2_CRYPTO_QUICTLS_CONFIGURE_CLIENT_CONTEXT /* Define to 1 if you have the - `ngtcp2_crypto_quictls_configure_server_context' function. */ + 'ngtcp2_crypto_quictls_configure_server_context' function. */ #undef HAVE_NGTCP2_CRYPTO_QUICTLS_CONFIGURE_SERVER_CONTEXT /* Define to 1 if you have the - `ngtcp2_crypto_quictls_from_ossl_encryption_level' function. */ + 'ngtcp2_crypto_quictls_from_ossl_encryption_level' function. */ #undef HAVE_NGTCP2_CRYPTO_QUICTLS_FROM_OSSL_ENCRYPTION_LEVEL -/* Define to 1 if the system has the type `ngtcp2_encryption_level'. */ +/* Define to 1 if the system has the type 'ngtcp2_encryption_level'. */ #undef HAVE_NGTCP2_ENCRYPTION_LEVEL /* Define to 1 if you have the header file. @@ -494,13 +494,13 @@ /* Use libnss for crypto */ #undef HAVE_NSS -/* Define to 1 if you have the `OpenSSL_add_all_digests' function. */ +/* Define to 1 if you have the 'OpenSSL_add_all_digests' function. */ #undef HAVE_OPENSSL_ADD_ALL_DIGESTS /* Define to 1 if you have the header file. */ #undef HAVE_OPENSSL_BN_H -/* Define to 1 if you have the `OPENSSL_config' function. */ +/* Define to 1 if you have the 'OPENSSL_config' function. */ #undef HAVE_OPENSSL_CONFIG /* Define to 1 if you have the header file. */ @@ -521,10 +521,10 @@ /* Define to 1 if you have the header file. */ #undef HAVE_OPENSSL_ERR_H -/* Define to 1 if you have the `OPENSSL_init_crypto' function. */ +/* Define to 1 if you have the 'OPENSSL_init_crypto' function. */ #undef HAVE_OPENSSL_INIT_CRYPTO -/* Define to 1 if you have the `OPENSSL_init_ssl' function. */ +/* Define to 1 if you have the 'OPENSSL_init_ssl' function. */ #undef HAVE_OPENSSL_INIT_SSL /* Define to 1 if you have the header file. */ @@ -539,10 +539,10 @@ /* Define to 1 if you have the header file. */ #undef HAVE_OPENSSL_SSL_H -/* Define to 1 if you have the `OSSL_PARAM_BLD_new' function. */ +/* Define to 1 if you have the 'OSSL_PARAM_BLD_new' function. */ #undef HAVE_OSSL_PARAM_BLD_NEW -/* Define to 1 if you have the `poll' function. */ +/* Define to 1 if you have the 'poll' function. */ #undef HAVE_POLL /* Define to 1 if you have the header file. */ @@ -554,10 +554,10 @@ /* Have PTHREAD_PRIO_INHERIT. */ #undef HAVE_PTHREAD_PRIO_INHERIT -/* Define to 1 if the system has the type `pthread_rwlock_t'. */ +/* Define to 1 if the system has the type 'pthread_rwlock_t'. */ #undef HAVE_PTHREAD_RWLOCK_T -/* Define to 1 if the system has the type `pthread_spinlock_t'. */ +/* Define to 1 if the system has the type 'pthread_spinlock_t'. */ #undef HAVE_PTHREAD_SPINLOCK_T /* Define to 1 if you have the header file. */ @@ -566,101 +566,101 @@ /* Define if you have Python libraries and header files. */ #undef HAVE_PYTHON -/* Define to 1 if you have the `random' function. */ +/* Define to 1 if you have the 'random' function. */ #undef HAVE_RANDOM -/* Define to 1 if you have the `RAND_cleanup' function. */ +/* Define to 1 if you have the 'RAND_cleanup' function. */ #undef HAVE_RAND_CLEANUP /* If we have reallocarray(3) */ #undef HAVE_REALLOCARRAY -/* Define to 1 if you have the `recvmsg' function. */ +/* Define to 1 if you have the 'recvmsg' function. */ #undef HAVE_RECVMSG -/* Define to 1 if you have the `sendmsg' function. */ +/* Define to 1 if you have the 'sendmsg' function. */ #undef HAVE_SENDMSG -/* Define to 1 if you have the `setregid' function. */ +/* Define to 1 if you have the 'setregid' function. */ #undef HAVE_SETREGID -/* Define to 1 if you have the `setresgid' function. */ +/* Define to 1 if you have the 'setresgid' function. */ #undef HAVE_SETRESGID -/* Define to 1 if you have the `setresuid' function. */ +/* Define to 1 if you have the 'setresuid' function. */ #undef HAVE_SETRESUID -/* Define to 1 if you have the `setreuid' function. */ +/* Define to 1 if you have the 'setreuid' function. */ #undef HAVE_SETREUID -/* Define to 1 if you have the `setrlimit' function. */ +/* Define to 1 if you have the 'setrlimit' function. */ #undef HAVE_SETRLIMIT -/* Define to 1 if you have the `setsid' function. */ +/* Define to 1 if you have the 'setsid' function. */ #undef HAVE_SETSID -/* Define to 1 if you have the `setusercontext' function. */ +/* Define to 1 if you have the 'setusercontext' function. */ #undef HAVE_SETUSERCONTEXT -/* Define to 1 if you have the `SHA512_Update' function. */ +/* Define to 1 if you have the 'SHA512_Update' function. */ #undef HAVE_SHA512_UPDATE -/* Define to 1 if you have the `shmget' function. */ +/* Define to 1 if you have the 'shmget' function. */ #undef HAVE_SHMGET -/* Define to 1 if you have the `sigprocmask' function. */ +/* Define to 1 if you have the 'sigprocmask' function. */ #undef HAVE_SIGPROCMASK -/* Define to 1 if you have the `sleep' function. */ +/* Define to 1 if you have the 'sleep' function. */ #undef HAVE_SLEEP -/* Define to 1 if you have the `snprintf' function. */ +/* Define to 1 if you have the 'snprintf' function. */ #undef HAVE_SNPRINTF -/* Define to 1 if you have the `socketpair' function. */ +/* Define to 1 if you have the 'socketpair' function. */ #undef HAVE_SOCKETPAIR /* Using Solaris threads */ #undef HAVE_SOLARIS_THREADS -/* Define to 1 if you have the `srandom' function. */ +/* Define to 1 if you have the 'srandom' function. */ #undef HAVE_SRANDOM /* Define if you have the SSL libraries installed. */ #undef HAVE_SSL -/* Define to 1 if you have the `SSL_CTX_set_alpn_protos' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_alpn_protos' function. */ #undef HAVE_SSL_CTX_SET_ALPN_PROTOS -/* Define to 1 if you have the `SSL_CTX_set_alpn_select_cb' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_alpn_select_cb' function. */ #undef HAVE_SSL_CTX_SET_ALPN_SELECT_CB -/* Define to 1 if you have the `SSL_CTX_set_ciphersuites' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_ciphersuites' function. */ #undef HAVE_SSL_CTX_SET_CIPHERSUITES -/* Define to 1 if you have the `SSL_CTX_set_security_level' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_security_level' function. */ #undef HAVE_SSL_CTX_SET_SECURITY_LEVEL -/* Define to 1 if you have the `SSL_CTX_set_tlsext_ticket_key_evp_cb' +/* Define to 1 if you have the 'SSL_CTX_set_tlsext_ticket_key_evp_cb' function. */ #undef HAVE_SSL_CTX_SET_TLSEXT_TICKET_KEY_EVP_CB -/* Define to 1 if you have the `SSL_CTX_set_tmp_ecdh' function. */ +/* Define to 1 if you have the 'SSL_CTX_set_tmp_ecdh' function. */ #undef HAVE_SSL_CTX_SET_TMP_ECDH -/* Define to 1 if you have the `SSL_get0_alpn_selected' function. */ +/* Define to 1 if you have the 'SSL_get0_alpn_selected' function. */ #undef HAVE_SSL_GET0_ALPN_SELECTED -/* Define to 1 if you have the `SSL_get0_peername' function. */ +/* Define to 1 if you have the 'SSL_get0_peername' function. */ #undef HAVE_SSL_GET0_PEERNAME -/* Define to 1 if you have the `SSL_get1_peer_certificate' function. */ +/* Define to 1 if you have the 'SSL_get1_peer_certificate' function. */ #undef HAVE_SSL_GET1_PEER_CERTIFICATE -/* Define to 1 if you have the `SSL_is_quic' function. */ +/* Define to 1 if you have the 'SSL_is_quic' function. */ #undef HAVE_SSL_IS_QUIC -/* Define to 1 if you have the `SSL_set1_host' function. */ +/* Define to 1 if you have the 'SSL_set1_host' function. */ #undef HAVE_SSL_SET1_HOST /* Define to 1 if you have the header file. */ @@ -681,7 +681,7 @@ /* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H -/* Define to 1 if you have the `strftime' function. */ +/* Define to 1 if you have the 'strftime' function. */ #undef HAVE_STRFTIME /* Define to 1 if you have the header file. */ @@ -690,39 +690,39 @@ /* Define to 1 if you have the header file. */ #undef HAVE_STRING_H -/* Define to 1 if you have the `strlcat' function. */ +/* Define to 1 if you have the 'strlcat' function. */ #undef HAVE_STRLCAT -/* Define to 1 if you have the `strlcpy' function. */ +/* Define to 1 if you have the 'strlcpy' function. */ #undef HAVE_STRLCPY -/* Define to 1 if you have the `strptime' function. */ +/* Define to 1 if you have the 'strptime' function. */ #undef HAVE_STRPTIME -/* Define to 1 if you have the `strsep' function. */ +/* Define to 1 if you have the 'strsep' function. */ #undef HAVE_STRSEP -/* Define to 1 if `ipi_spec_dst' is a member of `struct in_pktinfo'. */ +/* Define to 1 if 'ipi_spec_dst' is a member of 'struct in_pktinfo'. */ #undef HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST -/* Define to 1 if `tokenlen' is a member of `struct ngtcp2_pkt_hd'. */ +/* Define to 1 if 'tokenlen' is a member of 'struct ngtcp2_pkt_hd'. */ #undef HAVE_STRUCT_NGTCP2_PKT_HD_TOKENLEN -/* Define to 1 if `max_tx_udp_payload_size' is a member of `struct +/* Define to 1 if 'max_tx_udp_payload_size' is a member of 'struct ngtcp2_settings'. */ #undef HAVE_STRUCT_NGTCP2_SETTINGS_MAX_TX_UDP_PAYLOAD_SIZE -/* Define to 1 if `tokenlen' is a member of `struct ngtcp2_settings'. */ +/* Define to 1 if 'tokenlen' is a member of 'struct ngtcp2_settings'. */ #undef HAVE_STRUCT_NGTCP2_SETTINGS_TOKENLEN -/* Define to 1 if `original_dcid_present' is a member of `struct +/* Define to 1 if 'original_dcid_present' is a member of 'struct ngtcp2_transport_params'. */ #undef HAVE_STRUCT_NGTCP2_TRANSPORT_PARAMS_ORIGINAL_DCID_PRESENT -/* Define to 1 if the system has the type `struct ngtcp2_version_cid'. */ +/* Define to 1 if the system has the type 'struct ngtcp2_version_cid'. */ #undef HAVE_STRUCT_NGTCP2_VERSION_CID -/* Define to 1 if `sun_len' is a member of `struct sockaddr_un'. */ +/* Define to 1 if 'sun_len' is a member of 'struct sockaddr_un'. */ #undef HAVE_STRUCT_SOCKADDR_UN_SUN_LEN /* Define if you have Swig libraries and header files. */ @@ -782,16 +782,16 @@ /* Define to 1 if you have the header file. */ #undef HAVE_TIME_H -/* Define to 1 if you have the `tzset' function. */ +/* Define to 1 if you have the 'tzset' function. */ #undef HAVE_TZSET /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H -/* Define to 1 if you have the `usleep' function. */ +/* Define to 1 if you have the 'usleep' function. */ #undef HAVE_USLEEP -/* Define to 1 if you have the `vfork' function. */ +/* Define to 1 if you have the 'vfork' function. */ #undef HAVE_VFORK /* Define to 1 if you have the header file. */ @@ -809,22 +809,22 @@ /* Define to 1 if you have the header file. */ #undef HAVE_WINSOCK2_H -/* Define to 1 if `fork' works. */ +/* Define to 1 if 'fork' works. */ #undef HAVE_WORKING_FORK -/* Define to 1 if `vfork' works. */ +/* Define to 1 if 'vfork' works. */ #undef HAVE_WORKING_VFORK -/* Define to 1 if you have the `writev' function. */ +/* Define to 1 if you have the 'writev' function. */ #undef HAVE_WRITEV /* Define to 1 if you have the header file. */ #undef HAVE_WS2TCPIP_H -/* Define to 1 if you have the `X509_VERIFY_PARAM_set1_host' function. */ +/* Define to 1 if you have the 'X509_VERIFY_PARAM_set1_host' function. */ #undef HAVE_X509_VERIFY_PARAM_SET1_HOST -/* Define to 1 if you have the `_beginthreadex' function. */ +/* Define to 1 if you have the '_beginthreadex' function. */ #undef HAVE__BEGINTHREADEX /* If HMAC_Init_ex() returns void */ @@ -923,16 +923,16 @@ /* Shared data */ #undef SHARE_DIR -/* The size of `pthread_t', as computed by sizeof. */ +/* The size of 'pthread_t', as computed by sizeof. */ #undef SIZEOF_PTHREAD_T -/* The size of `size_t', as computed by sizeof. */ +/* The size of 'size_t', as computed by sizeof. */ #undef SIZEOF_SIZE_T -/* The size of `time_t', as computed by sizeof. */ +/* The size of 'time_t', as computed by sizeof. */ #undef SIZEOF_TIME_T -/* The size of `unsigned long', as computed by sizeof. */ +/* The size of 'unsigned long', as computed by sizeof. */ #undef SIZEOF_UNSIGNED_LONG /* define if (v)snprintf does not return length needed, (but length used) */ @@ -941,7 +941,7 @@ /* Define to 1 if libsodium supports sodium_set_misuse_handler */ #undef SODIUM_MISUSE_HANDLER -/* Define to 1 if all of the C90 standard headers exist (not just the ones +/* Define to 1 if all of the C89 standard headers exist (not just the ones required in a freestanding environment). This macro is provided for backward compatibility; new code need not use it. */ #undef STDC_HEADERS @@ -1035,7 +1035,7 @@ /* Define this to enable SHA256 and SHA512 support. */ #undef USE_SHA2 -/* Enable extensions on AIX 3, Interix. */ +/* Enable extensions on AIX, Interix, z/OS. */ #ifndef _ALL_SOURCE # undef _ALL_SOURCE #endif @@ -1096,11 +1096,15 @@ #ifndef __STDC_WANT_IEC_60559_DFP_EXT__ # undef __STDC_WANT_IEC_60559_DFP_EXT__ #endif +/* Enable extensions specified by C23 Annex F. */ +#ifndef __STDC_WANT_IEC_60559_EXT__ +# undef __STDC_WANT_IEC_60559_EXT__ +#endif /* Enable extensions specified by ISO/IEC TS 18661-4:2015. */ #ifndef __STDC_WANT_IEC_60559_FUNCS_EXT__ # undef __STDC_WANT_IEC_60559_FUNCS_EXT__ #endif -/* Enable extensions specified by ISO/IEC TS 18661-3:2015. */ +/* Enable extensions specified by C23 Annex H and ISO/IEC TS 18661-3:2015. */ #ifndef __STDC_WANT_IEC_60559_TYPES_EXT__ # undef __STDC_WANT_IEC_60559_TYPES_EXT__ #endif @@ -1141,30 +1145,36 @@ /* Define if you want PyUnbound. */ #undef WITH_PYUNBOUND -/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a - `char[]'. */ +/* Define to 1 if 'lex' declares 'yytext' as a 'char *' by default, not a + 'char[]'. */ #undef YYTEXT_POINTER /* Number of bits in a file offset, on hosts where this is settable. */ #undef _FILE_OFFSET_BITS -/* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */ +/* Define to 1 if necessary to make fseeko visible. */ #undef _LARGEFILE_SOURCE -/* Define for large files, on AIX-style hosts. */ +/* Define to 1 on platforms where this makes off_t a 64-bit type. */ #undef _LARGE_FILES /* Enable for compile on Minix */ #undef _NETBSD_SOURCE +/* Number of bits in time_t, on hosts where this is settable. */ +#undef _TIME_BITS + +/* Define to 1 on platforms where this makes time_t a 64-bit type. */ +#undef __MINGW_USE_VC2005_COMPAT + /* defined to use gcc ansi snprintf and sscanf that understands %lld when compiled for windows. */ #undef __USE_MINGW_ANSI_STDIO -/* Define to empty if `const' does not conform to ANSI C. */ +/* Define to empty if 'const' does not conform to ANSI C. */ #undef const -/* Define to `int' if doesn't define. */ +/* Define as 'int' if doesn't define. */ #undef gid_t /* in_addr_t */ @@ -1173,28 +1183,28 @@ /* in_port_t */ #undef in_port_t -/* Define to `__inline__' or `__inline' if that's what the C compiler +/* Define to '__inline__' or '__inline' if that's what the C compiler calls it, or to nothing if 'inline' is not supported under any name. */ #ifndef __cplusplus #undef inline #endif -/* Define to `short' if does not define. */ +/* Define to 'short' if does not define. */ #undef int16_t -/* Define to `int' if does not define. */ +/* Define to 'int' if does not define. */ #undef int32_t -/* Define to `long long' if does not define. */ +/* Define to 'long long' if does not define. */ #undef int64_t -/* Define to `signed char' if does not define. */ +/* Define to 'signed char' if does not define. */ #undef int8_t *** 17319 LINES SKIPPED *** From nobody Tue Sep 16 13:59:24 2025 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 4cR3Rd3rhmz67JvN; Tue, 16 Sep 2025 13:59:25 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3Rc6rTJz3Xjm; Tue, 16 Sep 2025 13:59:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031165; 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=BgMhQ9P+xJvoWVjnSQQUTh/UE4bMypOennYjxN8b/s0=; b=IDaRi5uNM3ZLr57Yu2XYH5xqAQETRHqllaSNLfNEcLfD66UvVKZEa8kEfcRCZIMsH+5dYr uwhRmevS331qwVeX422EcyDmqD+o35/MkKcNFKSRWGwKK0PlRtrkrjmSBgogFVF6DHn7Xq g/kPFbDiknP6F+BBXNi6XQomcExjsF+v/LPMGv5OcloJL7SZP0asFc40RxX+hGwWmoR30j /9nIGftZY6qGHknM49xtq2BAANn2wW/jQ6qs0FGdpgGVntI5SNgcHw5DsahyaVYeBitl40 TScX8BY7f4h60s8WS/j67G1PasPgQI2aQ7Dr+nRScQarxFdBNDLtxt5JcA+Nzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031165; 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=BgMhQ9P+xJvoWVjnSQQUTh/UE4bMypOennYjxN8b/s0=; b=GGF63IO42yCSomm8DhU7Mwck8Tg8h5PTKX+bPluJ4zQ1p7OWqzSuTykKqw3kysH0kMTq26 Pdvxh2ViLOZ4S1QomTs4+WBczTWu2LdyOMPmjGrct+BKPhuAqNxAUJ1pEBRQ0EdI8pncKh 0OqUE9BP3Q6r8vDcpXiQe7OZAuTVCBsva+8uqfMjtwPdGCTXPxgrvMIpUqj8kqgNNVvIIp 8yz7tYobiQxtoW30vY6UpkXjp6njV3kGJYYH+jQAa+xmAxe4NYp2Tv17EKoalBkjBRFhXB ssUSvewHWAHT14nBF1p1KR0l8IFZq8+ajFHmVt1Aprz56prMLdFwMNtMmerPig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031165; a=rsa-sha256; cv=none; b=UGAyO/GDvWIIu8Gd2/oJJFWryioGJIbWsF7Z5carYMgC6lwX6E3bATW7yQa1T4mGYkd6m/ dpzJAWmK2ar6liLC0vtUXL9sZhXbnCNZuObdM3nhOlSpju7KYxs5DkiryvlcsARwx8EJxm h3rOdoOxWNXVwrma6ou/VwX848PVWX17SS8NPEr3KqPSGpULTDkuMqQ7AH8qs4w5Rvx7GQ 2Cibqefn73qexboNYjvy/uwPAHrERRHAELN2/lvCDWaQRb4FxFPZLH+OrvTWTD/g1ZvMni WHaMTMle8B4dChxwW9GLa60ztGWDPolJfl5LKqRM27CxIXpw3MQccU8MgGP9Tw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3Rc6Hg2zjZF; Tue, 16 Sep 2025 13:59:24 +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 58GDxOnY064974; Tue, 16 Sep 2025 13:59:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDxOu1064971; Tue, 16 Sep 2025 13:59:24 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:24 GMT Message-Id: <202509161359.58GDxOu1064971@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: e5c5d8f78ead - stable/13 - man: Add -l option 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: e5c5d8f78eade3a78825caf395c86fb9e7dccc82 Auto-Submitted: auto-generated The branch stable/13 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=e5c5d8f78eade3a78825caf395c86fb9e7dccc82 commit e5c5d8f78eade3a78825caf395c86fb9e7dccc82 Author: Ingo Schwarze AuthorDate: 2025-09-07 20:52:09 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:55:22 +0000 man: Add -l option Add a -l option which causes man to interpret all arguments as paths to open directly rather than man pages to search for in MANPATH. See the PR for a detailed rationale. PR: 289245 MFC after: 1 week Reviewed by: ziaee, emaste Differential Revision: https://reviews.freebsd.org/D52385 (cherry picked from commit 14b61b2e931741281d0bfef426e9809f16006504) --- usr.bin/man/man.1 | 25 ++++++++++++++++++++----- usr.bin/man/man.sh | 31 +++++++++++++++++++++++-------- 2 files changed, 43 insertions(+), 13 deletions(-) diff --git a/usr.bin/man/man.1 b/usr.bin/man/man.1 index 4bab5d78eea2..e524258cfbb4 100644 --- a/usr.bin/man/man.1 +++ b/usr.bin/man/man.1 @@ -31,7 +31,7 @@ .Nd display online manual documentation pages .Sh SYNOPSIS .Nm -.Op Fl adho +.Op Fl adhlo .Op Fl t | w .Op Fl M Ar manpath .Op Fl P Ar pager @@ -133,6 +133,15 @@ Display short help message and exit. .It Fl k Emulate .Xr apropos 1 . +.It Fl l +Interpret all arguments as absolute or relative filename(s) +of the manual page(s) to display. +No search is done and the options +.Fl M , +.Fl m , +and +.Fl S +are ignored. .It Fl m Ar arch Ns Op : Ns Ar machine Override the default architecture and machine settings allowing lookup of other platform specific manual pages. @@ -258,12 +267,15 @@ will search the following paths when considering section 4 manual pages in .Pa /usr/share/man/man4 .El .Ss Displaying Specific Manual Files -The +For compatibility reasons, .Nm -utility also supports displaying a specific manual page if passed a path -to the file as long as it contains a +will interpret any argument containing at least one .Ql / -character. +character as an absolute or relative path to a manual page to be +displayed. +This heuristic, made redundant by the more widely supported +.Fl l +option, is now deprecated and may be removed in future releases. .Sh ENVIRONMENT The following environment variables affect the execution of .Nm : @@ -390,6 +402,9 @@ manual page: $ man -w ls .Ed .Pp +Show a manual page in the current working directory: +.Pp +.Dl $ man -l man.1 .Sh SEE ALSO .Xr apropos 1 , .Xr intro 1 , diff --git a/usr.bin/man/man.sh b/usr.bin/man/man.sh index 33be10cd5bd6..6bb260117078 100755 --- a/usr.bin/man/man.sh +++ b/usr.bin/man/man.sh @@ -495,13 +495,21 @@ man_display_page_groff() { # Usage: man_find_and_display page # Search through the manpaths looking for the given page. man_find_and_display() { - local found_page locpath p path sect + local found_page has_slash locpath p path sect # Check to see if it's a file. But only if it has a '/' in - # the filename. + # the filename or if -l was specified. case "$1" in - */*) if [ -f "$1" -a -r "$1" ]; then + */*) has_slash=yes + ;; + esac + if [ -n "$has_slash" -o -n "$lflag" ]; then + if [ -f "$1" -a -r "$1" ]; then decho "Found a usable page, displaying that" + if [ -z "$lflag" ]; then + echo "Opening a file directly is deprecated," \ + "use -l instead." >&2 + fi unset use_cat manpage="$1" setup_cattool "$manpage" @@ -510,9 +518,12 @@ man_find_and_display() { man_display_page fi return + elif [ -n "$lflag" ]; then + echo "Cannot read $1" >&2 + ret=1 + return fi - ;; - esac + fi IFS=: for sect in $MANSECT; do @@ -580,7 +591,7 @@ man_parse_opts() { local cmd_arg OPTIND=1 - while getopts 'M:P:S:adfhkm:op:tw' cmd_arg; do + while getopts 'M:P:S:adfhklm:op:tw' cmd_arg; do case "${cmd_arg}" in M) MANPATH=$OPTARG ;; P) MANPAGER=$OPTARG ;; @@ -590,6 +601,7 @@ man_parse_opts() { f) fflag=fflag ;; h) man_usage 0 ;; k) kflag=kflag ;; + l) lflag=lflag ;; m) mflag=$OPTARG ;; o) oflag=oflag ;; p) MANROFFSEQ=$OPTARG ;; @@ -602,12 +614,15 @@ man_parse_opts() { shift $(( $OPTIND - 1 )) # Check the args for incompatible options. - case "${fflag}${kflag}${tflag}${wflag}" in + case "${fflag}${kflag}${lflag}${tflag}${wflag}" in fflagkflag*) echo "Incompatible options: -f and -k"; man_usage ;; + fflag*lflag*) echo "Incompatible options: -f and -l"; man_usage ;; fflag*tflag*) echo "Incompatible options: -f and -t"; man_usage ;; fflag*wflag) echo "Incompatible options: -f and -w"; man_usage ;; - *kflagtflag*) echo "Incompatible options: -k and -t"; man_usage ;; + *kflaglflag*) echo "Incompatible options: -k and -l"; man_usage ;; + *kflag*tflag*) echo "Incompatible options: -k and -t"; man_usage ;; *kflag*wflag) echo "Incompatible options: -k and -w"; man_usage ;; + *lflag*wflag) echo "Incompatible options: -l and -w"; man_usage ;; *tflagwflag) echo "Incompatible options: -t and -w"; man_usage ;; esac From nobody Tue Sep 16 13:59:25 2025 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 4cR3Rf46G6z67Jkb; Tue, 16 Sep 2025 13:59:26 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3Rf2qFCz3Xc3; Tue, 16 Sep 2025 13:59:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031166; 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=AmzGOLimnDMp0ZPkSvMODp2/owFiyIv2GkuMB4CKFho=; b=fqgqTobmrYNJYAIhVdUVVwJlI4IuFIbT9KQ9kusEbtqGcyvlGxqSWQgZN0NAlyfSth3np+ J4/EqH+Iz8zR9JaQyTpPsQbi34W4aHiOfSOLsPHRT39nH0kks27pCWnBgqtxmjisQlSSiN x890sF7VDiF8shcW4+Ayw0OuiIBodpq3E48g2zH6/eUYmzVkCQVjwsKCvWebhLcGXP7XBw 3/oZuP27ed5nddKnRYT6iiz7TMkiXu4U/Tu6nflwbzU56swBD8traBtff8gA4dh7Jp+Ad9 zPGjarMQeJp/svGId2741cd23bPcpO4iwqbgUnVpefW8Ig0vsvqnxa2IbZQ6Xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031166; 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=AmzGOLimnDMp0ZPkSvMODp2/owFiyIv2GkuMB4CKFho=; b=pu9p7qvIDLHLc/FWUXdBRFkGNvMogRaAiwtRRcGuMUG7vAxN4T+8HXsePLHGHjVkaerCxO 8r39O0mM6Ds5hmL55es4QHlHJUxvMVwDa7nQLBEPq7w1YZtg6GcolZ3bgVOvnJvHCDnK5I o1VzD2BkI7oRrsIXvX0HPel4W79uSe9wxkeFvUMFUmhwvlWVXQweqTZcqV4xPNI/LumTDH xC+YJQgyh7+4B93FFoX3hd3Zc6WVMoWeny5Pthl4y/Fj0nzrGSbxjcVzntbAqHO+nAzXdK do7p/S9OW0PP5PW0cioW99JV4JX+y0BCyLLhnryPETmZzhAHFcJVj5YASZ7cKg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031166; a=rsa-sha256; cv=none; b=oQ+RT/vwpt1WHSJJSUpsmftIdtm1Lzx11K2eXPn4+fFOTKt43JWXTBhpKsMaOQ/dfVxayN BJvKUPQiq72zsfZWf/7rSGi29+TEMGrO3r9wgdJTvqSSzuN5rqROT8kWLZ2EJOzqE7PHHz pZ782fZ3gcxJMb93wTXMmotY6TStFj6caot633A27cNDnsY2+l0NG1paLUO//PIvMmGcF8 NJ3hs74SwwJIVLABqEX4YKJDcNh7Ny3UDoBUllgXoomPx8uhuTUp2eFYtuKCQJjIGbllbj GzqpAZWeuiXAOW+3rXBFIp/OB+6fUybx7xybri6VSAL5s9WfL1Xtkc3qeOTc2w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3Rf0B8Gzkfq; Tue, 16 Sep 2025 13:59:26 +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 58GDxPTn065010; Tue, 16 Sep 2025 13:59:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDxP5d065008; Tue, 16 Sep 2025 13:59:25 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:25 GMT Message-Id: <202509161359.58GDxP5d065008@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: eafc54027d2e - stable/13 - src.sys.mk: Support src.conf in SRCTOP 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: eafc54027d2ee6feac2114277d3c0f5131c9325f Auto-Submitted: auto-generated The branch stable/13 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=eafc54027d2ee6feac2114277d3c0f5131c9325f commit eafc54027d2ee6feac2114277d3c0f5131c9325f Author: Dag-Erling Smørgrav AuthorDate: 2025-09-10 16:57:26 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:55:22 +0000 src.sys.mk: Support src.conf in SRCTOP If SRCCONF is not defined and src.conf exists at the top level of the source tree, use that instead of /etc/src.conf. MFC after: 3 days Reviewed by: kevans, imp Differential Revision: https://reviews.freebsd.org/D52470 (cherry picked from commit dd8c666d8b78f6b9ddb691f0505837fa885ff3b4) UPDATING: mention the src.conf change Fixes: dd8c666d8b78 ("src.sys.mk: Support src.conf in SRCTOP") (cherry picked from commit ab2fea3f9a5a58f0ba90499ad3a8614e3dca0c5f) --- .gitignore | 1 + UPDATING | 5 +++++ share/man/man5/src.conf.5 | 9 ++++++--- share/mk/src.sys.mk | 4 ++++ sys/conf/kern.pre.mk | 4 ++++ tools/build/options/makeman | 7 +++++-- 6 files changed, 25 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 668b6d90483a..454340511754 100644 --- a/.gitignore +++ b/.gitignore @@ -22,3 +22,4 @@ cscope.in.out cscope.out cscope.po.out tags +/src.conf diff --git a/UPDATING b/UPDATING index a40ddb1d3670..84474463a407 100644 --- a/UPDATING +++ b/UPDATING @@ -17,6 +17,11 @@ and/or ports. has changed. An NFS server that exports any of these file systems will need its clients to unmount and remount the exports. +20250916: + If SRCCONF is unset and a file named src.conf is present at + the top of the source tree, it will now be used instead of + /etc/src.conf. + 20240419: Clang, llvm, lld, lldb, compiler-rt, libc++, libunwind and openmp have been upgraded to 18.1.6. It is important that you run `make delete-old` diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index 181b4fea466d..01721e786aa1 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -1,6 +1,6 @@ .\" DO NOT EDIT-- this file is @generated by tools/build/options/makeman. .\" $FreeBSD$ -.Dd March 8, 2024 +.Dd September 16, 2025 .Dt SRC.CONF 5 .Os .Sh NAME @@ -30,8 +30,11 @@ variables that control the aspects of how the system builds. .Pp The default location of .Nm -is -.Pa /etc/src.conf , +is the top level of the source tree, or +.Pa /etc/src.conf +if no +.Nm +is found in the source tree itself, though an alternative location can be specified in the .Xr make 1 variable diff --git a/share/mk/src.sys.mk b/share/mk/src.sys.mk index d5c2af0c559d..d563859586b0 100644 --- a/share/mk/src.sys.mk +++ b/share/mk/src.sys.mk @@ -6,7 +6,11 @@ .if !defined(_WITHOUT_SRCCONF) # Allow user to configure things that only effect src tree builds. +.if exists(${SRCTOP}/src.conf) +SRCCONF?= ${SRCTOP}/src.conf +.else SRCCONF?= /etc/src.conf +.endif .if !empty(SRCCONF) && \ (exists(${SRCCONF}) || ${SRCCONF} != "/etc/src.conf") && \ !target(_srcconf_included_) diff --git a/sys/conf/kern.pre.mk b/sys/conf/kern.pre.mk index 8728ac269dd6..c0af7ea7313f 100644 --- a/sys/conf/kern.pre.mk +++ b/sys/conf/kern.pre.mk @@ -8,7 +8,11 @@ # the rest of /usr/src, but they still always process SRCCONF even though # the normal mechanisms to prevent that (compiling out of tree) won't # work. To ensure they do work, we have to duplicate thee few lines here. +.if exists(${SRCTOP}/src.conf) +SRCCONF?= ${SRCTOP}/src.conf +.else SRCCONF?= /etc/src.conf +.endif .if (exists(${SRCCONF}) || ${SRCCONF} != "/etc/src.conf") && !target(_srcconf_included_) .include "${SRCCONF}" _srcconf_included_: diff --git a/tools/build/options/makeman b/tools/build/options/makeman index 05a07f592b09..875d8cf16b9d 100755 --- a/tools/build/options/makeman +++ b/tools/build/options/makeman @@ -174,8 +174,11 @@ variables that control the aspects of how the system builds. .Pp The default location of .Nm -is -.Pa /etc/src.conf , +is the top level of the source tree, or +.Pa /etc/src.conf +if no +.Nm +is found in the source tree itself, though an alternative location can be specified in the .Xr make 1 variable From nobody Tue Sep 16 13:59:27 2025 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 4cR3Rg4fj3z67Jkc; Tue, 16 Sep 2025 13:59:27 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3Rg1cZdz3XWP; Tue, 16 Sep 2025 13:59:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031167; 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=ZHLZTZeomVOfpnwBqSJLb5XFLb6m77L30oNzA4/eM9o=; b=hbCTB0Gqn7vl1ymXONTODDmV4BXYeny9SUZe7F42X8SHWKWj5ZfOk0vtjyvwDJnJQQ+/RY IG+z4JLuoo7FFckav4786hTCZM5kGJyu+74/JDZ8oT5Dga/FQgG3t3TWxNiIVpKDqnhMGD Ubha20jIHAdu2CvUdO/i4ic5qL/XwqtqRLGmwDIQ5hkTkPr4iWjEtA8/objFsQfMOkMQxY ZkbubfzLlknpty8Zlpf7zATQyYCUX3vzQYPJymebEjQEssxnMIrWrlq4VF7PBEwtvwf/9+ gtD2d9nGini7vI/Zcrt9xPrpNb47h7lzbilW+INElg/ccAfp32qaqZCO2ICkww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031167; 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=ZHLZTZeomVOfpnwBqSJLb5XFLb6m77L30oNzA4/eM9o=; b=h1wFsMjuKmlRLPtDdtQzJ3jNyVtzhxD0YyZkup6uidCnYJncjGr3IvDBd4mvCCqkyeUBPg uu6njptK1KTDFwA8VTOrnvef9nBHW4sCpQe+qmoQMGw9eQOvbSUfne61cbQwVTLofI6Vdx LJEWBwDJVh2jl8+G+0rcs2qK1xqf4vPJugQujvBbw0o1KlmtI4dlIZmm8QH0AWtiSJBjjz enMZPFK0l0NuLNJ9hObvKY35+IplyAE1g3nHCMwGFQ3NbmFAHnZ+XszI2IjpKzo8DOimR5 uWrmxP8wFCy0Grqd/hUhhnU5E2MxuAqZbfEU0UE2v+fM03q3uSG+mtMJZhl0Cg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031167; a=rsa-sha256; cv=none; b=Jp0Zy2X9I9Kcfu4l4ei4VhZNTQtfk/Lt6kY1ubpvyFi1JTLfLqn7bFAr65Ayn7hKhK7gIV UzEBiPMSS0x7qAhaJXpVyYWNRQxL3ropTgVVIO4uPXfcWe1y1pF/sZ3Uqe7mPAMmdZXeFS XYcvSI+b3XbdIroBZwhCKYkvuA5/3wLZMY+eIzEdPuLgI3grMSyaWUFDYOFe36YhaO1UJn 0QzDwPwUf26AKtX7UNcjPEYI7G8X4xWbP9KEep3vtTTzwxafMLSDC2OmsVrH45xfTTPW2G T7hiYgrkzBbaTugvgx68H7QLuLalwQ+LDbPlBPIL6qczzJrb9FuCQKs5JsyeJA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3Rg0rPBzkfr; Tue, 16 Sep 2025 13:59:27 +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 58GDxRIC065046; Tue, 16 Sep 2025 13:59:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GDxR13065043; Tue, 16 Sep 2025 13:59:27 GMT (envelope-from git) Date: Tue, 16 Sep 2025 13:59:27 GMT Message-Id: <202509161359.58GDxR13065043@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 3ac71c45ffa9 - stable/13 - uptime: Mention libxo support in manual page 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 3ac71c45ffa920d4d79d54813581f92442602cf7 Auto-Submitted: auto-generated The branch stable/13 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=3ac71c45ffa920d4d79d54813581f92442602cf7 commit 3ac71c45ffa920d4d79d54813581f92442602cf7 Author: Dag-Erling Smørgrav AuthorDate: 2025-09-11 20:51:48 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2025-09-16 13:55:23 +0000 uptime: Mention libxo support in manual page MFC after: 3 days Sponsored by: Klara, Inc. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D52489 (cherry picked from commit 55bd607b9930e5f61219007ad0a81801c8cfdbf3) --- usr.bin/w/uptime.1 | 18 ++++++++++++++++-- usr.bin/w/w.1 | 4 ++-- 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/usr.bin/w/uptime.1 b/usr.bin/w/uptime.1 index 16c16c0b5318..b20e9066a470 100644 --- a/usr.bin/w/uptime.1 +++ b/usr.bin/w/uptime.1 @@ -27,7 +27,7 @@ .\" .\" @(#)uptime.1 8.2 (Berkeley) 4/18/94 .\" -.Dd August 18, 2020 +.Dd September 11, 2025 .Dt UPTIME 1 .Os .Sh NAME @@ -35,6 +35,7 @@ .Nd show how long system has been running .Sh SYNOPSIS .Nm +.Op Fl -libxo .Sh DESCRIPTION The .Nm @@ -42,6 +43,17 @@ utility displays the current time, the length of time the system has been up, the number of users, and the load average of the system over the last 1, 5, and 15 minutes. +.Pp +The following options are available: +.Bl -tag -width indent +.It Fl -libxo +Generate output via +.Xr libxo 3 +in a selection of different human and machine readable formats. +See +.Xr xo_options 7 +for details on command line arguments. +.El .Sh FILES .Bl -tag -width /boot/kernel/kernel .It Pa /boot/kernel/kernel @@ -53,7 +65,9 @@ $ uptime 11:23AM up 3:01, 8 users, load averages: 21.09, 15.43, 12.79 .Ed .Sh SEE ALSO -.Xr w 1 +.Xr w 1 , +.Xr libxo 3 , +.Xr xo_options 7 .Sh HISTORY The .Nm diff --git a/usr.bin/w/w.1 b/usr.bin/w/w.1 index 7f0d83032d4b..584c5d1b7129 100644 --- a/usr.bin/w/w.1 +++ b/usr.bin/w/w.1 @@ -27,7 +27,7 @@ .\" .\" @(#)w.1 8.1 (Berkeley) 6/6/93 .\" -.Dd August 24, 2020 +.Dd September 11, 2025 .Dt W 1 .Os .Sh NAME @@ -56,7 +56,7 @@ user is on, the host from which the user is logged in, the time the user logged on, the time since the user last typed anything, and the name and arguments of the current process. .Pp -The options are as follows: +The following options are available: .Bl -tag -width indent .It Fl -libxo Generate output via From nobody Tue Sep 16 14:11:08 2025 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 4cR3j85SCmz67Kh8; Tue, 16 Sep 2025 14:11:08 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR3j84WJkz3c05; Tue, 16 Sep 2025 14:11:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031868; 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=Sk7OlB7M0QoS6+OJ0UPXnysPeIjS0GQgeZb7+BgBPcM=; b=nBXqlncdTeyD93JIZO4FQeyPatp4e3FIYQ7Cfl2v+vp5oHJIZuMBZpvIYziBO4nU5lvyTB Xu6hHZEZoXZ2Ibu/Tp5S6XMQc42Bx4kzBW5XYeu8bxgOoEOFFRDoRjtro9DLqnf5deJG6M 1b7UFOWBmxz6JkvEtEgynkPCIWiKMQIM0EGDJtFNVZ7ZtPT2JMoNXXHHBlAohcX0CW7SxH 54C9fO1jR2eoZpRJguKNFhPppqk/UNJKNywl3Krhm8SMe0tD/7Q6SAMnTGHOE93J00tUCW PrDHpBgELn9IstsJ7B59IYc37UeejercMBU6nZ+BeZwSnjjZ0eaqTWEq4sHcww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758031868; 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=Sk7OlB7M0QoS6+OJ0UPXnysPeIjS0GQgeZb7+BgBPcM=; b=cWWRMCxWib4BlfYNrJPssRfw0JuUDd06oPjXJAmh1c5OdUvgXKqlS25V2Dd3bzd1f4/YQz HReF1sRq/B0xYW6xk7iMrLNJo/JUXBr0XAEkiXEp1nHM8jZAOpwKjgwHrRVb/fIEHWQJqX fc4rreQmMMpXEEPsVP/F016TzAAPjiEBzT0zK3U/SaqJQi9ntCL1udNh7uhOoyMJkMGsnT Sqejs2KfZdjQwhZcieMllJ3gRePqMyIcNumcFWNYcber+2P6HUwv+ncmPc25V+EvvcLeHT 9QHoL11Utn3E3SWjZWSf11Opjqdx6ESYbcI6y/mmRAvsq2nCITCnV3HF+9yjqw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758031868; a=rsa-sha256; cv=none; b=eFlVlIaltN3tDc7hdkdr+fR7LdhiN2zKDo33u4cpE3dL+uWtPwjA3JmAGYTq4OOHRnjmwe UTvqeOKhhATWtjQW5ctOKxJi2Im8GpQFRKxbc2xZ/vBsA6wYZC+vQMW6Oi9GDbpi6suOtl 5oBNS0WjWwtVqV6FYZ5VDCxC+3OY0JZwGCY/l/GcAAIbNzUT2Rzk7vZQJEixJt1z52tIO/ VVBcsfP49hGkboxjK1zcIfhHJEttsOpAUs09bLgi7EqJQSLLr2xxzrS4bmg9g9gCoGfUdv EKEN916ztjeWAaACwGgdEHGMJ2142OnB6sb7SS3gEhLn6YkLxbw+/OGwF3Tdmg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR3j841TYzl5x; Tue, 16 Sep 2025 14:11:08 +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 58GEB8A7095233; Tue, 16 Sep 2025 14:11:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GEB8H8095230; Tue, 16 Sep 2025 14:11:08 GMT (envelope-from git) Date: Tue, 16 Sep 2025 14:11:08 GMT Message-Id: <202509161411.58GEB8H8095230@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mitchell Horne Subject: git: a7340d559ee9 - main - MODULE_PNP_INFO.9: tweak list indent 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: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a7340d559ee942c21ea1a037d1d60a7859dd873b Auto-Submitted: auto-generated The branch main has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=a7340d559ee942c21ea1a037d1d60a7859dd873b commit a7340d559ee942c21ea1a037d1d60a7859dd873b Author: Mitchell Horne AuthorDate: 2025-09-05 16:14:07 +0000 Commit: Mitchell Horne CommitDate: 2025-09-16 14:11:02 +0000 MODULE_PNP_INFO.9: tweak list indent So that it renders as intended. MFC after: 3 days Sponsored by: The FreeBSD Foundation --- share/man/man9/MODULE_PNP_INFO.9 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man9/MODULE_PNP_INFO.9 b/share/man/man9/MODULE_PNP_INFO.9 index 529afd70096d..b1cc935b1aca 100644 --- a/share/man/man9/MODULE_PNP_INFO.9 +++ b/share/man/man9/MODULE_PNP_INFO.9 @@ -65,7 +65,7 @@ The second name is encoded by appending a forward slash and the second name after the first.) .Pp Types are one of the following: -.Bl -tag -width U16 +.Bl -tag -width indent .It Dq Vt U8 .Vt uint8_t element. From nobody Tue Sep 16 15:37:28 2025 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 4cR5cm4ljfz67T99; Tue, 16 Sep 2025 15:37:28 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR5cm42B8z3rlB; Tue, 16 Sep 2025 15:37:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758037048; 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=6HALETDzudEznqI/lx+aUFDG1siB5Sorq4aRk3HEIro=; b=u216YgYk0vOrov7dYymS/9c0v+Lp5v7T+5yLLw+FyA7qYsCaBKloyrqoAxnFFMbSR6JXiQ 0PiPwctoBtDO3CgjD2Ixhl+C9Pz1JYnwggSTdEai4/MlQNreAUGWFe2HIG5ZgO1krd/M1u 10WiM0J26FnKgSThkG2CSg7I9nmmnDA2blGoCW651RQqj/2Ag0kMUTZtnAtYycMVL+Szum mQzeaddz6ka2M6f1+rdODqbldptpgVMEjqg8TJAVfiA8BKwMZvABr4tkEbF/4QwxF6mihm 7extitcDgy5zmEp7B/+oev/CWfSa2pnmwTOshQ+7n6NTsh9LcAwb6CmFkSHsPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758037048; 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=6HALETDzudEznqI/lx+aUFDG1siB5Sorq4aRk3HEIro=; b=ox/9+45B6mrLqMtoD3GZc/wcJgu6G3Df7lo8yfNDqW7MdfQuJJD0szTdpoLKySrPXsE9t7 pPVL9Ex2pKVBv685olffqY4tl9y3GBG28zfP0wyUHpROLLBahGnGtU1aFqeWEbmUA6ZyjS TgIpbe2jn9hm2tgq4/WAT8SdBsXgVug5uOOVx0m+IBz+W9lGLUktSHUWE0gXlH9FM63gms D7CY7OBT6D8WNWQZWk5kQO0ewQPr6NqZW/2AUWcJenJBoAUB17Esbabt6PiQAC1cGRpk6G YWli6mZ574n0n3HlGUqEQuXcyLclwPn6cbpv2X81h/FfFgXv7xMgPRE1KoHD1A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758037048; a=rsa-sha256; cv=none; b=yeupMnkYHCBiabEK7fu93pBsQ2fnq0nQtuCu6EehzyEVjTw+Klop0udXekLU/oDGMaQMfP jJIXvggsB9Xpx8KGo6dzkvWepZU/oo/zc5Nimu/N9nDUJS0LpH7q5/hXPV+kvYg+epGyx1 HIEAPFhA9Z42GlmuCqhpKs84x+080T+7f/AydM7/K29Hd3x0szjZHwYCknaNZRVVMv0TWy IhWz3fuqVcUcCi9AUoYzLdNCZ1SQP3CdecOpKn97jf3/1V/DjcAHhL5IQ8iVVGnBGj6pnV KZ0Hr9JBL9cJVeHQ1OOkpu/7dOBnC76ezw79SULDMVid0s8X2oOY5o99vit7LA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR5cm3JMKznDF; Tue, 16 Sep 2025 15:37:28 +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 58GFbSn5052553; Tue, 16 Sep 2025 15:37:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GFbSjp052550; Tue, 16 Sep 2025 15:37:28 GMT (envelope-from git) Date: Tue, 16 Sep 2025 15:37:28 GMT Message-Id: <202509161537.58GFbSjp052550@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: 67f3c0d6a575 - main - dtraceall: Enable kinst for aarch64 and riscv as well 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 67f3c0d6a575f74a013974b4d4860a36e4fcc8ab Auto-Submitted: auto-generated The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=67f3c0d6a575f74a013974b4d4860a36e4fcc8ab commit 67f3c0d6a575f74a013974b4d4860a36e4fcc8ab Author: Christos Margiolis AuthorDate: 2025-09-16 15:37:19 +0000 Commit: Christos Margiolis CommitDate: 2025-09-16 15:37:19 +0000 dtraceall: Enable kinst for aarch64 and riscv as well aarch64 and riscv are supported since 2023 so it should be safe to enable it by default. MFC after: 2 weeks Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D52575 --- sys/modules/dtrace/dtraceall/dtraceall.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/modules/dtrace/dtraceall/dtraceall.c b/sys/modules/dtrace/dtraceall/dtraceall.c index 851d33a7e518..1978b9ead362 100644 --- a/sys/modules/dtrace/dtraceall/dtraceall.c +++ b/sys/modules/dtrace/dtraceall/dtraceall.c @@ -74,11 +74,11 @@ MODULE_DEPEND(dtraceall, dtnfscl, 1, 1, 1); defined(__i386__) || defined(__powerpc__) || defined(__riscv) MODULE_DEPEND(dtraceall, fbt, 1, 1, 1); #endif -#if defined(__amd64__) || defined(__i386__) || defined(__powerpc__) -MODULE_DEPEND(dtraceall, fasttrap, 1, 1, 1); -#if defined(__amd64__) +#if defined(__amd64__) || defined(__aarch64__) || defined(__riscv) MODULE_DEPEND(dtraceall, kinst, 1, 1, 1); #endif +#if defined(__amd64__) || defined(__i386__) || defined(__powerpc__) +MODULE_DEPEND(dtraceall, fasttrap, 1, 1, 1); #endif MODULE_DEPEND(dtraceall, sdt, 1, 1, 1); MODULE_DEPEND(dtraceall, systrace, 1, 1, 1); From nobody Tue Sep 16 15:48:38 2025 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 4cR5sf6qLbz67Tlb; Tue, 16 Sep 2025 15:48:38 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR5sf6Dpgz3sxv; Tue, 16 Sep 2025 15:48:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758037718; 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=5u2x8Q+D5pmL9NX7nXU+Bg4Gs/lkNMByAjWHfOaBrho=; b=k0q75uZQnjOkGfr7CUVAfCa2CwaQeRIs9Z/w5GGNuVnZq44vvOQaGjrcQ1/IqOecAi6V1h TC7HtZMxTg0mb0lqCBLkxi9VjG4Bl/pHaic4Hh5A8Z4DOJhRE2WEblN/tpF3maf3evyjDq XALYLjSeNCZzFE6Ke2BqwkBkReliMM9EDFQVJ2J/BfwT1gh8MHdK3cm8TiG4n9nsdl93vF gaUeBhDFO/8+Z4NjreT13G23Uml0P1QIC+q5UWfcr0qZTW4CLlyXWJimyvq9qd+t/jXnzj +GrFWp91pyJUmFw+sWL4dITYXbQnMgpUsMuHNPJIshFU7YuQ3uVva1gENAQFSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758037718; 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=5u2x8Q+D5pmL9NX7nXU+Bg4Gs/lkNMByAjWHfOaBrho=; b=d3o+WWeyNus4fydfGXFxqJsAGwjnok1UwJJJ7/OZIEFdK6l7lxJESC8nhRqyeybHNfjWmT a0s2qWc/AzLV0f8xVOGPDH8V1ue9D3HfXf6RwW2mpdldpwrPAtLrpPbOiQa3P/SideFnLg JDwxOHSF3P8aZhBTpVT+IQFMoBuvYNH2eZ48FplslXDus291Gi1sxKYe63K5qvTmGQkwWB 40lMJXhuEp0UdSQaGp2wAmeFMER8ExHFcJb+CR1hSSoiDRHfosPoLR08gi2ZNYoMj5Jg1L 5cj0GKFGNRf349Eq+rFgtxl1m/VM/f33JrcQh3VYKobt+RAltyeJZJiIG3kMcw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758037718; a=rsa-sha256; cv=none; b=gQf3lb8gBAI8EdppdxbRD0JNGhWtgPYbVnHh40Y4PzRy7C8UrEMw7GVk+cSMrjq2TxLrzs 9ytzvEtR+YRfIVrE9aOFvnY6vyntFx9dCSxlkNPkA0Kci9bugNs4vsf9BA8gvm4OOVdFq7 nuiBSTsquD0GYuSSdk+aFfHSGz0Lxy33kj9ibazTYo4+uYiYuDJg2FWlzqN/348+aEOmgt nHCWTM5EuzOpQNBu0it9209F6OK0DbcdoXQv/Q9EsnzmmsW7Qy8M308Rl9S1xoo7NZXilf R0cIxrK06ZuaPng+Rp3aTHDjBPRdKxAfOZ/41htPKc+FYgp2uwl0bqUfXI54Eg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR5sf5mc0znTD; Tue, 16 Sep 2025 15:48:38 +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 58GFmcoE072029; Tue, 16 Sep 2025 15:48:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GFmch7072026; Tue, 16 Sep 2025 15:48:38 GMT (envelope-from git) Date: Tue, 16 Sep 2025 15:48:38 GMT Message-Id: <202509161548.58GFmch7072026@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: 4be491e1b9b3 - main - jail: Optionally allow audit session state to be configured in a jail 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4be491e1b9b3b650494208eb61511f4a45c7db3f Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=4be491e1b9b3b650494208eb61511f4a45c7db3f commit 4be491e1b9b3b650494208eb61511f4a45c7db3f Author: Mark Johnston AuthorDate: 2025-09-15 17:23:50 +0000 Commit: Mark Johnston CommitDate: 2025-09-16 15:48:25 +0000 jail: Optionally allow audit session state to be configured in a jail Currently it is impossible for a privileged, jailed process to set audit session state. This can result in suprising audit event misattribution. For example, suppose a user ssh'es into a jail and restarts a service; normally, sshd sets audit state such that events generated by the SSH session are attributed to the newly authenticated user, but in a jail, the corresponding setaudit(2) call fails, so events are attributed to the user who had started sshd in the jail (typically the user who had started the jail itself by some means). While this behaviour is reasonable, administrators might want to trust the jailed sshd to reset audit state, such that the authenticated user appears in audit logs. Add a jail knob to enable this. Add a simple regression test. This is a reapplication of commit 246d7e9fc23928 following a revert. The audit system calls must preserve the old behaviour of returning ENOSYS if the system call is disallowed within a jail, as some applications depend on that behaviour. Reviewed by: kevans, jamie (previous version) MFC after: 1 week Sponsored by: Modirum MDPay Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D51719 Differential Revision: https://reviews.freebsd.org/D52572 --- sys/kern/kern_jail.c | 13 +++++++++- sys/security/audit/audit_syscalls.c | 47 +++++++++++++++++++++------------- sys/sys/jail.h | 3 ++- usr.sbin/jail/jail.8 | 19 +++++++++++--- usr.sbin/jail/tests/jail_basic_test.sh | 20 +++++++++++++++ 5 files changed, 78 insertions(+), 24 deletions(-) diff --git a/sys/kern/kern_jail.c b/sys/kern/kern_jail.c index a75ba89d2a7e..3697d95fe0e5 100644 --- a/sys/kern/kern_jail.c +++ b/sys/kern/kern_jail.c @@ -243,6 +243,9 @@ static struct bool_flags pr_flag_allow[NBBY * NBPW] = { {"allow.unprivileged_parent_tampering", "allow.nounprivileged_parent_tampering", PR_ALLOW_UNPRIV_PARENT_TAMPER}, +#ifdef AUDIT + {"allow.setaudit", "allow.nosetaudit", PR_ALLOW_SETAUDIT}, +#endif }; static unsigned pr_allow_all = PR_ALLOW_ALL_STATIC; const size_t pr_flag_allow_size = sizeof(pr_flag_allow); @@ -4289,7 +4292,6 @@ prison_priv_check(struct ucred *cred, int priv) */ case PRIV_KTRACE: -#if 0 /* * Allow jailed processes to configure audit identity and * submit audit records (login, etc). In the future we may @@ -4298,6 +4300,11 @@ prison_priv_check(struct ucred *cred, int priv) */ case PRIV_AUDIT_GETAUDIT: case PRIV_AUDIT_SETAUDIT: + if (cred->cr_prison->pr_allow & PR_ALLOW_SETAUDIT) + return (0); + else + return (EPERM); +#if 0 case PRIV_AUDIT_SUBMIT: #endif @@ -5034,6 +5041,10 @@ SYSCTL_JAIL_PARAM(_allow, settime, CTLTYPE_INT | CTLFLAG_RW, "B", "Jail may set system time"); SYSCTL_JAIL_PARAM(_allow, routing, CTLTYPE_INT | CTLFLAG_RW, "B", "Jail may modify routing table"); +#ifdef AUDIT +SYSCTL_JAIL_PARAM(_allow, setaudit, CTLTYPE_INT | CTLFLAG_RW, + "B", "Jail may set and get audit session state"); +#endif SYSCTL_JAIL_PARAM_SUBNODE(allow, mount, "Jail mount/unmount permission flags"); SYSCTL_JAIL_PARAM(_allow_mount, , CTLTYPE_INT | CTLFLAG_RW, diff --git a/sys/security/audit/audit_syscalls.c b/sys/security/audit/audit_syscalls.c index 40b2fb3d1c9f..f50c627b7515 100644 --- a/sys/security/audit/audit_syscalls.c +++ b/sys/security/audit/audit_syscalls.c @@ -54,6 +54,29 @@ #ifdef AUDIT +static int +audit_priv_check_cred(struct ucred *cred, int priv) +{ + int error; + + error = priv_check_cred(cred, priv); + if (error == EPERM && jailed(cred)) { + /* + * The audit system calls historically returned ENOSYS when + * invoked from within a jail, and some userspace applications + * handle that case specially. Thus, convert the error here. + */ + error = ENOSYS; + } + return (error); +} + +static int +audit_priv_check(struct thread *td, int priv) +{ + return (audit_priv_check_cred(td->td_ucred, priv)); +} + /* * System call to allow a user space application to submit a BSM audit record * to the kernel for inclusion in the audit log. This function does little @@ -592,9 +615,7 @@ sys_getauid(struct thread *td, struct getauid_args *uap) { int error; - if (jailed(td->td_ucred)) - return (ENOSYS); - error = priv_check(td, PRIV_AUDIT_GETAUDIT); + error = audit_priv_check(td, PRIV_AUDIT_GETAUDIT); if (error) return (error); return (copyout(&td->td_ucred->cr_audit.ai_auid, uap->auid, @@ -609,8 +630,6 @@ sys_setauid(struct thread *td, struct setauid_args *uap) au_id_t id; int error; - if (jailed(td->td_ucred)) - return (ENOSYS); error = copyin(uap->auid, &id, sizeof(id)); if (error) return (error); @@ -624,7 +643,7 @@ sys_setauid(struct thread *td, struct setauid_args *uap) if (error) goto fail; #endif - error = priv_check_cred(oldcred, PRIV_AUDIT_SETAUDIT); + error = audit_priv_check_cred(oldcred, PRIV_AUDIT_SETAUDIT); if (error) goto fail; newcred->cr_audit.ai_auid = id; @@ -650,9 +669,7 @@ sys_getaudit(struct thread *td, struct getaudit_args *uap) int error; cred = td->td_ucred; - if (jailed(cred)) - return (ENOSYS); - error = priv_check(td, PRIV_AUDIT_GETAUDIT); + error = audit_priv_check(td, PRIV_AUDIT_GETAUDIT); if (error) return (error); if (cred->cr_audit.ai_termid.at_type == AU_IPv6) @@ -674,8 +691,6 @@ sys_setaudit(struct thread *td, struct setaudit_args *uap) struct auditinfo ai; int error; - if (jailed(td->td_ucred)) - return (ENOSYS); error = copyin(uap->auditinfo, &ai, sizeof(ai)); if (error) return (error); @@ -689,7 +704,7 @@ sys_setaudit(struct thread *td, struct setaudit_args *uap) if (error) goto fail; #endif - error = priv_check_cred(oldcred, PRIV_AUDIT_SETAUDIT); + error = audit_priv_check_cred(oldcred, PRIV_AUDIT_SETAUDIT); if (error) goto fail; bzero(&newcred->cr_audit, sizeof(newcred->cr_audit)); @@ -715,11 +730,9 @@ sys_getaudit_addr(struct thread *td, struct getaudit_addr_args *uap) { int error; - if (jailed(td->td_ucred)) - return (ENOSYS); if (uap->length < sizeof(*uap->auditinfo_addr)) return (EOVERFLOW); - error = priv_check(td, PRIV_AUDIT_GETAUDIT); + error = audit_priv_check(td, PRIV_AUDIT_GETAUDIT); if (error) return (error); return (copyout(&td->td_ucred->cr_audit, uap->auditinfo_addr, @@ -734,8 +747,6 @@ sys_setaudit_addr(struct thread *td, struct setaudit_addr_args *uap) struct auditinfo_addr aia; int error; - if (jailed(td->td_ucred)) - return (ENOSYS); error = copyin(uap->auditinfo_addr, &aia, sizeof(aia)); if (error) return (error); @@ -752,7 +763,7 @@ sys_setaudit_addr(struct thread *td, struct setaudit_addr_args *uap) if (error) goto fail; #endif - error = priv_check_cred(oldcred, PRIV_AUDIT_SETAUDIT); + error = audit_priv_check_cred(oldcred, PRIV_AUDIT_SETAUDIT); if (error) goto fail; newcred->cr_audit = aia; diff --git a/sys/sys/jail.h b/sys/sys/jail.h index e12e8c3178c9..e6a13e6719dd 100644 --- a/sys/sys/jail.h +++ b/sys/sys/jail.h @@ -271,6 +271,7 @@ struct prison_racct { #define PR_ALLOW_SETTIME 0x00100000 #define PR_ALLOW_ROUTING 0x00200000 #define PR_ALLOW_UNPRIV_PARENT_TAMPER 0x00400000 +#define PR_ALLOW_SETAUDIT 0x00800000 /* * PR_ALLOW_PRISON0 are the allow flags that we apply by default to prison0, @@ -278,7 +279,7 @@ struct prison_racct { * build time. PR_ALLOW_ALL_STATIC should contain any bit above that we expect * to be used on the system, while PR_ALLOW_PRISON0 will be some subset of that. */ -#define PR_ALLOW_ALL_STATIC 0x007f87ff +#define PR_ALLOW_ALL_STATIC 0x00ff87ff #define PR_ALLOW_PRISON0 \ (PR_ALLOW_ALL_STATIC & ~(PR_ALLOW_UNPRIV_PARENT_TAMPER)) diff --git a/usr.sbin/jail/jail.8 b/usr.sbin/jail/jail.8 index 421aa9babb4c..d44b7f66a64e 100644 --- a/usr.sbin/jail/jail.8 +++ b/usr.sbin/jail/jail.8 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 7, 2025 +.Dd September 15, 2025 .Dt JAIL 8 .Os .Sh NAME @@ -702,15 +702,15 @@ The super-user will be disabled automatically if its parent system has it disabled. The super-user is enabled by default. .It Va allow.extattr -Allow privileged process in the jail to manipulate filesystem extended +Allow privileged processes in the jail to manipulate filesystem extended attributes in the system namespace. .It Va allow.adjtime -Allow privileged process in the jail to slowly adjusting global operating system +Allow privileged processes in the jail to slowly adjusting global operating system time. For example through utilities like .Xr ntpd 8 . .It Va allow.settime -Allow privileged process in the jail to set global operating system data +Allow privileged processes in the jail to set global operating system data and time. For example through utilities like .Xr date 1 . @@ -719,6 +719,17 @@ This permission includes also .It Va allow.routing Allow privileged process in the non-VNET jail to modify the system routing table. +.It Va allow.setaudit +Allow privileged processes in the jail to set +.Xr audit 4 +session state using +.Xr setaudit 2 +and related system calls. +This is useful, for example, for allowing a jailed +.Xr sshd 8 +to set the audit user ID for an authenticated session. +However, it gives jailed processes the ability to modify or disable audit +session state, so should be configured with care. .El .El .Pp diff --git a/usr.sbin/jail/tests/jail_basic_test.sh b/usr.sbin/jail/tests/jail_basic_test.sh index 6802da7b049a..c781eed78756 100755 --- a/usr.sbin/jail/tests/jail_basic_test.sh +++ b/usr.sbin/jail/tests/jail_basic_test.sh @@ -306,6 +306,25 @@ param_consistency_cleanup() fi } +atf_test_case "setaudit" +setaudit_head() +{ + atf_set descr 'Test that setaudit works in a jail when configured with allow.setaudit' + atf_set require.user root + atf_set require.progs setaudit +} + +setaudit_body() +{ + # Try to modify the audit mask within a jail without + # allow.setaudit configured. + atf_check -s not-exit:0 -o empty -e not-empty jail -c name=setaudit_jail \ + command=setaudit -m fr ls / + # The command should succeed if allow.setaudit is configured. + atf_check -s exit:0 -o ignore -e empty jail -c name=setaudit_jail \ + allow.setaudit command=setaudit -m fr ls / +} + atf_init_test_cases() { atf_add_test_case "basic" @@ -314,4 +333,5 @@ atf_init_test_cases() atf_add_test_case "commands" atf_add_test_case "jid_name_set" atf_add_test_case "param_consistency" + atf_add_test_case "setaudit" } From nobody Tue Sep 16 16:00:29 2025 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 4cR67K2zCbz67Vgj; Tue, 16 Sep 2025 16:00:29 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR67K20Bnz3thD; Tue, 16 Sep 2025 16:00:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758038429; 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=enO+HFjDzBwDMPW9t0DZGuWWwUgIyKRR7Nd/OjL3vAU=; b=DFl21TVMGtCmB6bXnAx7WoqSJ9vPAVx/Y/bVaAg+ZXMtB2t7o2j1NA3v6jTaUV7RUrVBsG vAgLK+2BrkUDzaFH4u9dbq+TX28GR8jhQhZ2qgyGga5IMPZkiJ+1WIr/9fL6YyVDHfeM8y dhoPcvXAytX1facE/dAqWWQ/CsZOXZhteWlEGE5Oaq6NrqWmgrdRqJJPho6Zp8uHpOkpiM ojlgsagYF2h0AQebW0q75nfcw8TmlW85YkweFsBVk5IomMKZOGEKPKjCVV9ENafA/QLSWl aY0E988esPa9++VguWlBalPDDDz9OtLQy5PUktEDKKveqMyVOyRp96sh5VwrYA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758038429; 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=enO+HFjDzBwDMPW9t0DZGuWWwUgIyKRR7Nd/OjL3vAU=; b=r+Bx1kkRfXcYycth68F0wcf89Yo7HEnShBzJ+fJURYhFzYux6jRRgsW+TGX3UG+QTBFYG8 FiAdfSn3h414fWNZG0IwBtNyR+ixT1qzaBD346aDfx4hoh7aHseaGLvJ2MlBh1BGEJ31p/ cvA9BQz6CkmcO3aouWreLMW7kjUvpqLQ2Tg/vDQ9X9FbG0lRqnycYXJDw2mMKGMAn538jX ywQEZEsEoMGno0QK7ZNuT/07rmEXAfiSSCMSq78pG0n+0QtsS9f18a3/jYLSLhIS99vFSw Yg0VRqUKqV/uaoiARZzz2Hlf7nY3zM5uSguakMrQTAc3+/xW4/oX8WHDTj8Abg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758038429; a=rsa-sha256; cv=none; b=inZLPF6GfDLfoUVACJZWF1+jPDH7eQNtZBkbFoXPVw0LDzvx9zNWIypUT/2i1svn7GX/Ou gAPaaJKUmI2SC3OvizL3QQdneR+9Zzd6ME3j6BoNRwELXjiLegpuqwr5DRuRTwCYA4SNCd DGr+dm++smoDDw2qDN5pQt/k4XCxc8X0YSsA4ohaCGQC/2djHMkqUe9W19rdekCcLPLyfm jhGcoMz6GCYmMCZP28zLgzk1RQ35sEAY0gOoFSH0v6Qa1yK8BQbNtrc/QkFURI8Ga9ABId Dsni3phlWj5Im0Burq9aBhLDttmY7c3tMIRrmW89zv6wJi9fhKKpFcMkZVJpzQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR67K1WMgznRJ; Tue, 16 Sep 2025 16:00:29 +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 58GG0TEs001386; Tue, 16 Sep 2025 16:00:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GG0T4R001383; Tue, 16 Sep 2025 16:00:29 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:00:29 GMT Message-Id: <202509161600.58GG0T4R001383@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Zhenlei Huang Subject: git: 0418e6690e91 - main - ipfw: Teach ipfw that EtherIP is an upper layer protocol 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0418e6690e91aa6c38dd9af9da43c4c5a9dc1cd2 Auto-Submitted: auto-generated The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=0418e6690e91aa6c38dd9af9da43c4c5a9dc1cd2 commit 0418e6690e91aa6c38dd9af9da43c4c5a9dc1cd2 Author: Zhenlei Huang AuthorDate: 2025-09-16 15:58:24 +0000 Commit: Zhenlei Huang CommitDate: 2025-09-16 15:58:24 +0000 ipfw: Teach ipfw that EtherIP is an upper layer protocol so that we do not discard EtherIP packets ( over IPv6 network ) when net.inet6.ip6.fw.deny_unknown_exthdrs is set to 1 ( which is the default value ). PR: 227450 Reviewed by: ae, #network MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52566 --- sys/netpfil/ipfw/ip_fw2.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sys/netpfil/ipfw/ip_fw2.c b/sys/netpfil/ipfw/ip_fw2.c index 3f810533b7fc..b59d8d08bf80 100644 --- a/sys/netpfil/ipfw/ip_fw2.c +++ b/sys/netpfil/ipfw/ip_fw2.c @@ -67,6 +67,7 @@ #include #include #include +#include #include #include @@ -1757,6 +1758,12 @@ do { \ PULLUP_TO(hlen, ulp, struct ip); break; + case IPPROTO_ETHERIP: /* RFC 3378 */ + PULLUP_LEN(hlen, ulp, + sizeof(struct etherip_header) + + sizeof(struct ether_header)); + break; + case IPPROTO_PFSYNC: PULLUP_TO(hlen, ulp, struct pfsync_header); break; From nobody Tue Sep 16 16:05:34 2025 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 4cR6FB4pVvz67W08; Tue, 16 Sep 2025 16:05: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR6FB4B1Xz3vPL; Tue, 16 Sep 2025 16:05:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758038734; 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=KCEY6CMUeWlFoF94Cna2c9/Vv3MNifG5Fljj2gIBUUs=; b=V06nEyBhiT+CnnS38i5JZM6AqfSvDtKPhMfJ3CQNk228L+z5z+7D3jCeKM3i1GStIsIS8q 4mEf/1CT+1klFz9f9F4wExDHTR/L5iTZbunkGb1ACvsVSLaXGpSaB06NUmjRLNKIQM/GQk TPLXkd/es3EqS+A1rr6RArVM35gQlPE8bGCtLvaYZ0lBR3dmaZoR+G1+u3xH/JrskcjeO7 pTbFHvTjnvrRYB7HTnHbEDkaGyQRwHVlZmINW9BHiAUrak4t5hRFA3Qdf3ZzRdESHpYbVK jPN49JevQAXvJOB+h5Vxa/zg+O5lVdQnhOBtyHCZslLoCmq866WUA3KLK0Ps9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758038734; 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=KCEY6CMUeWlFoF94Cna2c9/Vv3MNifG5Fljj2gIBUUs=; b=eTcAq5L4N1zl7jnkdNq+/Kqn2K9DVKgS0dVpBzi07JVVUz8azheMBJczN7AQyGvIIrLwRY voytRBd8IEbPVkv9LeTNDHcixUhD8Q5DjveK7A2j1TGcCQgvpDbop6z5tRIkck6F88VcNa VoGwI6uGDrOPQ9OqZACB7YAEUA/toX9DdYUK5XdWOr3FfgHzg/dMW/DyP+wSJYE/gkojIT yPrdn3lINLFBWjCbVYh2x25XpEcYHx4mfZqjcR743vpdDIAWzHEG5ivN2XK8PM33nC8hHm Xcu1Pf4BRgN3LEiAGdfCmdz4tZL7bjwdDdIkiwXLqzQF/26U1HLfCu6WbTJhPg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758038734; a=rsa-sha256; cv=none; b=XRk4Pc8/Y3bk+2VaQ7/qkIi03h4CTCzZzyqvyw02MZdDVXJBrdT6h7q2dx7Th6SvoiEoK9 nCUzoCV9D/zbVxhlItM27mdKW5nzxkFK5vZyYGCpmHRXm/WjSmlmYOAiO9EMcKQKoqFg0/ zMEqhv5hkPF0kr69VX47w0FyN+HudJhItGFH7CtFVCcrJ17BRZ3PscYmaN21md7SgUd7Um hjo0jLcQVIKZwDrxESOhH0TALWOWsHj2V1ACSj0/+uEwMhhYRA3Br9vTnh4scGcfGjLB0C yjbIbsj/y+k8rBfkorpw9AKfjtDOZMrOO6BMSsGCgTugm39EOVSaBrMN3MDa3g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR6FB2xpMzngq; Tue, 16 Sep 2025 16:05: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 58GG5YtF009514; Tue, 16 Sep 2025 16:05:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GG5Y8I009511; Tue, 16 Sep 2025 16:05:34 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:05:34 GMT Message-Id: <202509161605.58GG5Y8I009511@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 22cce201da76 - main - vm/vm_fault.c: update and split comments for vm_fault() and vm_fault_trap() 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/main X-Git-Reftype: branch X-Git-Commit: 22cce201da76a1916be5c993201f0478f3048292 Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=22cce201da76a1916be5c993201f0478f3048292 commit 22cce201da76a1916be5c993201f0478f3048292 Author: Konstantin Belousov AuthorDate: 2025-09-16 03:41:55 +0000 Commit: Konstantin Belousov CommitDate: 2025-09-16 16:05:24 +0000 vm/vm_fault.c: update and split comments for vm_fault() and vm_fault_trap() Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differrential revision: https://reviews.freebsd.org/D52567 --- sys/vm/vm_fault.c | 42 ++++++++++++++++++++++++++++++------------ 1 file changed, 30 insertions(+), 12 deletions(-) diff --git a/sys/vm/vm_fault.c b/sys/vm/vm_fault.c index 524aed2be2ff..2e150b368d71 100644 --- a/sys/vm/vm_fault.c +++ b/sys/vm/vm_fault.c @@ -708,21 +708,18 @@ _Static_assert(UCODE_PAGEFLT == T_PAGEFLT, "T_PAGEFLT"); #endif /* - * vm_fault_trap: + * vm_fault_trap: * - * Handle a page fault occurring at the given address, - * requiring the given permissions, in the map specified. - * If successful, the page is inserted into the - * associated physical map. + * Helper for the page fault trap handlers, wrapping vm_fault(). + * Issues ktrace(2) tracepoints for the faults. * - * NOTE: the given address should be truncated to the - * proper page address. + * If a fault cannot be handled successfully by satisfying the + * required mapping, and the faulted instruction cannot be restarted, + * the signal number and si_code values are returned for trapsignal() + * to deliver. * - * KERN_SUCCESS is returned if the page fault is handled; otherwise, - * a standard error specifying why the fault is fatal is returned. - * - * The map in question must be referenced, and remains so. - * Caller may hold no locks. + * Returns Mach error codes, but callers should only check for + * KERN_SUCCESS. */ int vm_fault_trap(vm_map_t map, vm_offset_t vaddr, vm_prot_t fault_type, @@ -1626,6 +1623,27 @@ vm_fault_object(struct faultstate *fs, int *behindp, int *aheadp) return (res); } +/* + * vm_fault: + * + * Handle a page fault occurring at the given address, requiring the + * given permissions, in the map specified. If successful, the page + * is inserted into the associated physical map, and optionally + * referenced and returned in *m_hold. + * + * The given address should be truncated to the proper page address. + * + * KERN_SUCCESS is returned if the page fault is handled; otherwise, a + * Mach error specifying why the fault is fatal is returned. + * + * The map in question must be alive, either being the map for current + * process, or the owner process hold count incremented to prevent + * exit(). + * + * If the thread private TDP_NOFAULTING flag is set, any fault results + * in immediate protection failure. Otherwise the fault is processed, + * and caller may hold no locks. + */ int vm_fault(vm_map_t map, vm_offset_t vaddr, vm_prot_t fault_type, int fault_flags, vm_page_t *m_hold) From nobody Tue Sep 16 16:10:03 2025 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 4cR6LM2cSdz67WqB; Tue, 16 Sep 2025 16:10:03 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR6LM23m8z3vpS; Tue, 16 Sep 2025 16:10:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758039003; 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=uyujhfx7C++/4nOgQZBVsCcxPILkQ6UAYnBKb2Fm7Cs=; b=tlsT+xcubPpSP/ZXGAvPcxtx6xlR9EeoDSYKBecyQFjgiVont/sDQRxMSYk8Rk2kUc3uxj 4HcUI3VuRhHTo2CX23iE6IS6/p0N2F0A+LCBw8r8UeWJC5rmGTgtrwguS8LPH6npLpp6aX WL18PT0TzgfGWIguz3F4H/Ei8VioTf/JQCGXQRtbbiBBl6a9/Mb8Zaf+V5oDAKw9/075vU yvrtjsrqjp8sIDzu8vcp4+erw7/tTGziyj1A23rMPl0d9Caxie1kxC+u0LVukUcUZnUeIH d2HT2qnP5aoD6iXfdiL5wbGGyfo+HAlGeoVPrDsS/YGyFs8knLzhE6/C6Uaq5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758039003; 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=uyujhfx7C++/4nOgQZBVsCcxPILkQ6UAYnBKb2Fm7Cs=; b=ni9BLa5KlqaAOpkcL+38bT23tyjDreD3qe/UZGZvcFlhubqZpAanfYPJptCIHuX5KFPPqE 2W4ULHzv8J3GhZlBOB74Cxv71JuEYVDc2FZvMY6q+YPQ4L6Z9xRgd06MJSH+DIcVWUQfyp kBGQ1WmmtKINJLAJaFL/QmzZy0Wn5QvFhMjuSvd1FQz1Qzgjau84gEzN8Nwbt1aQyNP9XI m9vrwofMVwmnrwppns7EFi7R3Vuj7iwh+v3vy+LtnXTM155EkPLBLGsDk0ZSUO0Zf/3Gqb IQ9hx25X5yjJQfvGrSGCM3GyJk6cZyluG0LtYFq3MsEvlqqB1HbXOmboyrEjwQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758039003; a=rsa-sha256; cv=none; b=Hw4bXgCTWh2v4RMNkIoadF2pUqTgmjXhQQknLxRP1C+eNPsO5KpjMWttZkzROYRBWY6gAx KFEX0JFVBjLjMuedw9lULQ80Lc0jgACXQls2jlD9R2cVySYsNOyNgWQfStqj9jzQuuVlay m8a9ofKwSshpCrer3R4smfv8u0miNdcdCtm/eScbJvyfw0Xr4gDjOZh4/QC27yV73QzwVT I+oGU3Dlq6ERQ5MGfiWeXmKQ49LyAabJDo7LGyUbfShkv8E08/nO5S9mBxPUHYeCj89jNG GaPEcFzMmb960YMplo4u+6bkxhYTMVwFizmvxyYJxP1ZXpN26MdW84uTR7w2gA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR6LM1Z8cznkL; Tue, 16 Sep 2025 16:10:03 +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 58GGA3eP013199; Tue, 16 Sep 2025 16:10:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GGA3Xe013194; Tue, 16 Sep 2025 16:10:03 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:10:03 GMT Message-Id: <202509161610.58GGA3Xe013194@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: 5eb917426e0a - main - release: Enable installing packages as a non-root user 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5eb917426e0aab1e82c7b0e7239724d18bae206a Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=5eb917426e0aab1e82c7b0e7239724d18bae206a commit 5eb917426e0aab1e82c7b0e7239724d18bae206a Author: Mark Johnston AuthorDate: 2025-09-16 16:05:06 +0000 Commit: Mark Johnston CommitDate: 2025-09-16 16:09:55 +0000 release: Enable installing packages as a non-root user Provide variables, PKG_REPOS_DIR and PKG_REPO_NAME, to allow the user to configure the source package repository. Configure pkg to emit added files to a metalog which gets concatenated with the main metalog immediately before we build the root filesystem. Reviewed by: cperciva, emaste MFC after: 3 days Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D52453 --- release/Makefile.vm | 6 ++++++ release/tools/vmimage.subr | 35 ++++++++++++++++++++++++++--------- share/man/man7/release.7 | 15 ++++++++++++++- 3 files changed, 46 insertions(+), 10 deletions(-) diff --git a/release/Makefile.vm b/release/Makefile.vm index 8375650cd9aa..25c37ade1121 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -138,6 +138,9 @@ cw-${_CW:tl}-${_FS}-${_FMT}: ${QEMUTGT} EC2BASEIMG=${.OBJDIR}/${EC2-BASE${_FS:tu}${_FMT:tu}IMAGE} \ ${WITHOUT_QEMU:DWITHOUT_QEMU=true} \ ${NO_ROOT:DNO_ROOT=true} \ + PKG_CMD=${PKG_CMD:Upkg} \ + PKG_REPOS_DIR=${PKG_REPOS_DIR:U${.OBJDIR}/${.TARGET}/etc/pkg} \ + PKG_REPO_NAME=${PKG_REPO_NAME:UFreeBSD-ports} \ PKG_INSTALL_EPOCH=${PKG_INSTALL_EPOCH:U${GITEPOCH}} \ ${.CURDIR}/scripts/mk-vmimage.sh \ -C ${.CURDIR}/tools/vmimage.subr -d ${.OBJDIR}/${.TARGET} \ @@ -191,6 +194,9 @@ vm-image: ${QEMUTGT} QEMUSTATIC=${QEMUSTATIC} \ ${WITHOUT_QEMU:DWITHOUT_QEMU=true} \ ${NO_ROOT:DNO_ROOT=true} \ + PKG_CMD=${PKG_CMD:Upkg} \ + PKG_REPOS_DIR=${PKG_REPOS_DIR:U${.OBJDIR}/${.TARGET}-${FORMAT}-${FS}/etc/pkg} \ + PKG_REPO_NAME=${PKG_REPO_NAME:UFreeBSD-ports} \ PKG_INSTALL_EPOCH=${PKG_INSTALL_EPOCH:U${GITEPOCH}} \ ${.CURDIR}/scripts/mk-vmimage.sh \ -C ${.CURDIR}/tools/vmimage.subr \ diff --git a/release/tools/vmimage.subr b/release/tools/vmimage.subr index 41f889a1e665..b3187efd6526 100644 --- a/release/tools/vmimage.subr +++ b/release/tools/vmimage.subr @@ -163,19 +163,32 @@ vm_extra_enable_services() { } vm_extra_install_packages() { - if [ -n "${WITHOUT_QEMU}" ]; then - return 0 - fi - if [ -z "${VM_EXTRA_PACKAGES}" ]; then return 0 fi - chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ - /usr/sbin/pkg bootstrap -y - for p in ${VM_EXTRA_PACKAGES}; do + if [ -n "${NO_ROOT}" ]; then + for pkg in ${VM_EXTRA_PACKAGES}; do + INSTALL_AS_USER=yes \ + ${PKG_CMD} \ + -o METALOG=${DESTDIR}/METALOG.pkg \ + -o REPOS_DIR=${PKG_REPOS_DIR} \ + -o PKG_DBDIR=${DESTDIR}/var/db/pkg \ + -r ${DESTDIR} \ + install -y -r ${PKG_REPO_NAME} $pkg + done + metalog_add_data ./var/db/pkg/local.sqlite + else + if [ -n "${WITHOUT_QEMU}" ]; then + return 0 + fi + chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ - /usr/sbin/pkg install -y ${p} - done + /usr/sbin/pkg bootstrap -y + for p in ${VM_EXTRA_PACKAGES}; do + chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ + /usr/sbin/pkg install -y ${p} + done + fi return 0 } @@ -219,6 +232,10 @@ vm_extra_pkg_rmcache() { buildfs() { local md tmppool + if [ -f ${DESTDIR}/METALOG.pkg ]; then + cat ${DESTDIR}/METALOG.pkg >> ${DESTDIR}/METALOG + fi + case "${VMFS}" in ufs) cd ${DESTDIR} && ${MAKEFS} ${MAKEFSARGS} -o label=rootfs -o version=2 -o softupdates=1 \ diff --git a/share/man/man7/release.7 b/share/man/man7/release.7 index 36c14afe0bf1..05f80374926f 100644 --- a/share/man/man7/release.7 +++ b/share/man/man7/release.7 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd May 20, 2025 +.Dd September 11, 2025 .Dt RELEASE 7 .Os .Sh NAME @@ -286,6 +286,19 @@ is expected to exist by alternative means. Include base system packages for use with .Xr pkg 8 on the install media, instead of legacy tarball distribution sets. +.It Va PKG_CMD +A path to the +.Xr pkg 8 +executable to use when installing packages in release images as a non-root user. +.It Va PKG_REPOS_DIR +An optional path to a directory containing +.Xr pkg 8 +repository configuration files. +These configuration files will be used when installing packages in release +images as a non-root user. +.It Va PKG_REPO_NAME +The name of the repository configuration to use when installing packages in +release images as a non-root user. .El .Sh EMBEDDED BUILDS The following From nobody Tue Sep 16 16:31:06 2025 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 4cR6pf4YwXz67Z2f; Tue, 16 Sep 2025 16:31: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR6pf3qg8z41hW; Tue, 16 Sep 2025 16:31:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040266; 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=5b7U7tRtMfLbumJT4t2hPVCnplnxST93RNHKKxvdMwM=; b=WEgNLFP8p2JbfCrjuQK93Mf/vchbBcHYHZOsdpT3L9odwIzfHcPC5ihuQI7R++FTyWreCO 07iRBKE4tjqE/e5CVvvevQTqChSGs3EBaIk+i+CbVHuLJkEgwGZjNA2n8uSAXlFz+bME2l HliJ9LLUAyvM+/Ja7i/7SvyEaf14WUUNfBgbeQfnbCDgh/Cj9YyU/WszEdqhDAr1kw5m7j intr34b/KzRCImQdQbGoAHn+LX/87p20ywU7qRu3pp+/d+/LmiyD4j2JCLTGWuf5kKVTqx DnmoTMDJ2v1+cAtz/GIqKP4BZH5a1wEGH4DXTQqR9OroEdumu+bf7ngmVyXyVA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040266; 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=5b7U7tRtMfLbumJT4t2hPVCnplnxST93RNHKKxvdMwM=; b=lXLaWdAdbAhuLhFeSU0g753/2YXKaShFtHE9gYiXo/gQ5KNLZC/LsEBsxHtHYGfMax6bbH R20ht6ryd3TDOeu3o6uzdjjNOydo1Q1/IhuKgtZmijzcC0ZJ5Vc1LocxvWIVN/t2bbBhAZ lCItmGhos84So/bzHbElY6e/mBVent76NiaMYLpVOQyBVkw9X5z+E9vJsOL66j5WiFe34U QcMKZiIsmj5pkifQIH3rFQn34JwYnb8XGtwHbIuyG+MHpzGglf3m+Zi4/j/h++IZLbkXWF FNRbLhVfjzfvo01ooYOaoU3dJes3foShNnV+4lTgtAJf8tIdmKve+1zQ3hVNtg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758040266; a=rsa-sha256; cv=none; b=rF2yM1d/T3stWjUvH6I86SJ8SdYSkFDXtWy/bF6xv5+9T1yqJPL99BeAkWPNTi1reynNQ7 gbo7yqRPIhpS9EQWbyfZmXcf4kQ835jBH9HdBuhaKxt9kv2v4smOdg3MNdh5JA9Xsyy8eR SGCwP21T0whAZvJ8T5FSjxrJqAGtsPq2s5GqPqw0hB+6ddDDABfpCHF/mgTXRtUeix1CzE 895CshnFGIGm0ZqOGY7h2TrOWKNoR7NjyN85NKUs4fQz5KK7ev6Q82dKL5p3XM97k28wTV iGpKerCdFMdIMnjOZcHwyeDzG+uzLEozofnTqg914NEwaLMWrNYfyJnY0nQSug== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR6pf39f0zpVn; Tue, 16 Sep 2025 16:31:06 +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 58GGV61k058617; Tue, 16 Sep 2025 16:31:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GGV6Vr058614; Tue, 16 Sep 2025 16:31:06 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:31:06 GMT Message-Id: <202509161631.58GGV6Vr058614@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: 99012995b4c6 - releng/14.3 - arm64: prevent panic when using syscall mux + large arg call (mmap) 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: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.3 X-Git-Reftype: branch X-Git-Commit: 99012995b4c69ecc352047a41cf76ece50b25134 Auto-Submitted: auto-generated The branch releng/14.3 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=99012995b4c69ecc352047a41cf76ece50b25134 commit 99012995b4c69ecc352047a41cf76ece50b25134 Author: John-Mark Gurney AuthorDate: 2025-08-18 20:25:37 +0000 Commit: Gordon Tetlow CommitDate: 2025-09-14 00:20:46 +0000 arm64: prevent panic when using syscall mux + large arg call (mmap) if the syscall muxes are used, up to two additional arguments may be required. This means that the 8 required for mmap increases up to 10 (for __syscall). Sponsored by: Juniper Networks, Inc. Approved by: so Security: FreeBSD-EN-25:15.arm64 (cherry picked from commit 740b879c6ade531adebeba7cd2f261bbe650797f) (cherry picked from commit 17d87881a363c160e7e8cdb252d0261214c1a50b) --- sys/arm64/arm64/elf32_machdep.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/arm64/arm64/elf32_machdep.c b/sys/arm64/arm64/elf32_machdep.c index de0ee9607ad1..5f35d01f9ac0 100644 --- a/sys/arm64/arm64/elf32_machdep.c +++ b/sys/arm64/arm64/elf32_machdep.c @@ -193,7 +193,7 @@ freebsd32_fetch_syscall_args(struct thread *td) register_t *ap; struct syscall_args *sa; int error, i, nap, narg; - unsigned int args[4]; + unsigned int args[6]; nap = 4; p = td->td_proc; From nobody Tue Sep 16 16:31:07 2025 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 4cR6pg6t1qz67Z4n; Tue, 16 Sep 2025 16:31:07 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR6pg4kDGz41Tl; Tue, 16 Sep 2025 16:31:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040267; 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=ChfOeV1LNxjrrpbf4e6kCOgoFv3Z2AWq8LLY1GOf9LE=; b=BQYRggBSiLp8aP5y0caAUxOURM61qoNUMVPo+vFJePo0UtZDY0rXVS69VneYlTfqDhIEL2 +BkzLe43h8tgHniBXNIii3slm36gaeB7cv2uU298EmJQfwcoy2P24pTXYrpVSLmjkNRF08 YJuzu32esgajvu0iN1LIDWoNp157Riif6tg8oAPTvziWUcZKdKNhjT/FPSvVXDoNAkHqx/ ah/a2O7C32MPlDUhELdZNfB0xxVTjuyy7kMlkkDuEp9DpjaXfWk3OP8cjWGrdjl5Il7Kua F6xuxT3x7j0ir903q9OrqFUe5C3mbfGw7KIWEeZVsQoBI6B4MIK9JVo6Lwz5Tg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040267; 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=ChfOeV1LNxjrrpbf4e6kCOgoFv3Z2AWq8LLY1GOf9LE=; b=cUNzfL0oVupfe4+tsgeu6t2qMzMWfy8QcIzVbeY/VSHU5pWIjniQgh2btaxzKEZ1aOaSmq /Vq+3MU3Lr7aw6UyW1T//rjSQy098w7So8LrOyIemJprBU7Bo+9cMNXKBFskfIny4J22vR xIXsnlxMYkyJqQIPO4as/sXuPbGF9hF9iCvW3vmxm3Y1PPe5zOSMEtc19TQnryuzQJm+gI bu+plBWVVVCxKvKVmeE2jZLPdl0QFQqyZoEMHORYddhYI81Cmf3khnOlzsFa4PcEauIf18 5sWAX2QOr7eF3uDwDWaw2l8ZwG0Ask+xTjTK8F6+FQvUHTSlFUOiGWQG+cBQaQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758040267; a=rsa-sha256; cv=none; b=wnu6QYp0Lt5GsbaAyioSR6lC95J9M/He0Ls4B4sP4sHMwdi0uvE+I1gVkItiWSxvpo9Tci 7SEKVAlUSi8OKxTMn7aK1QlR8Ni8Pnwbr8nq+n8i8o//7vIJbf7E3vD9mTwzVfA8hHygA7 t+ryV5ITgbhCtYbNq4+hdB10A0h3IlndnzEV63SmMEp5ILSvUmMC03ZQ/8IlVj485A/DbS 40ViCEh5+oXEYYkELibRfruj27IpA2+oEftBEJIiXhivSjmlcBlj1DMnP1+EuKC/EGMq14 Tu+xI3EtOumHO1hcuuCexdBL9C486Kh14EIFpfIosOYQYx7mnnDyd933LvF1Ag== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR6pg3qC5znWF; Tue, 16 Sep 2025 16:31:07 +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 58GGV7vB058650; Tue, 16 Sep 2025 16:31:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GGV7R4058647; Tue, 16 Sep 2025 16:31:07 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:31:07 GMT Message-Id: <202509161631.58GGV7R4058647@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: d1e981cbf3bd - releng/14.3 - vfs_syscalls.c: Fix handling of offset args for copy_file_range 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: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.3 X-Git-Reftype: branch X-Git-Commit: d1e981cbf3bdfff5a3fb7a2d21d80c0ed747524d Auto-Submitted: auto-generated The branch releng/14.3 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=d1e981cbf3bdfff5a3fb7a2d21d80c0ed747524d commit d1e981cbf3bdfff5a3fb7a2d21d80c0ed747524d Author: Rick Macklem AuthorDate: 2025-08-09 21:15:07 +0000 Commit: Gordon Tetlow CommitDate: 2025-09-14 00:23:36 +0000 vfs_syscalls.c: Fix handling of offset args for copy_file_range Commit 197997a broke handling of the offset arguments to copy_file_range() when specified non-NULL. The code fails to update the offsets and, as such, a loop like: do { len = copy_file_range(infd, &inpos, outfd, &outpos, SSIZE_MAX, 0); } while (len > 0); becomes an infinite loop, just doing the same copy over and over again. This patch fixes it. The clause "(foffsets_locked || foffsets_set)" in the if is not actually needed for correctness, but I thought it made the code a little more readable and might avoid some static analyzer from throwing a "used before being set" for the savinoff and savoutoff variables. Approved by: so Security: FreeBSD-EN-25:16.vfs (cherry picked from commit 4046ad6bb0ee542a42d89a48a7d6a56564ed7f33) (cherry picked from commit 2fd0083fcc23f4c25860b8890292448720a5961c) --- sys/kern/vfs_syscalls.c | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 02908f76ef85..6756925416a3 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -4908,11 +4908,12 @@ kern_copy_file_range(struct thread *td, int infd, off_t *inoffp, int outfd, size_t retlen; void *rl_rcookie, *rl_wcookie; off_t inoff, outoff, savinoff, savoutoff; - bool foffsets_locked; + bool foffsets_locked, foffsets_set; infp = outfp = NULL; rl_rcookie = rl_wcookie = NULL; foffsets_locked = false; + foffsets_set = false; error = 0; retlen = 0; @@ -4980,6 +4981,8 @@ kern_copy_file_range(struct thread *td, int infd, off_t *inoffp, int outfd, } foffset_lock_pair(infp1, &inoff, outfp1, &outoff, 0); foffsets_locked = true; + } else { + foffsets_set = true; } savinoff = inoff; savoutoff = outoff; @@ -5035,11 +5038,12 @@ out: vn_rangelock_unlock(invp, rl_rcookie); if (rl_wcookie != NULL) vn_rangelock_unlock(outvp, rl_wcookie); + if ((foffsets_locked || foffsets_set) && + (error == EINTR || error == ERESTART)) { + inoff = savinoff; + outoff = savoutoff; + } if (foffsets_locked) { - if (error == EINTR || error == ERESTART) { - inoff = savinoff; - outoff = savoutoff; - } if (inoffp == NULL) foffset_unlock(infp, inoff, 0); else @@ -5048,6 +5052,9 @@ out: foffset_unlock(outfp, outoff, 0); else *outoffp = outoff; + } else if (foffsets_set) { + *inoffp = inoff; + *outoffp = outoff; } if (outfp != NULL) fdrop(outfp, td); From nobody Tue Sep 16 16:31:08 2025 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 4cR6pj1jdpz67ZBy; Tue, 16 Sep 2025 16:31:09 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR6ph5KMQz41d0; Tue, 16 Sep 2025 16:31:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040268; 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=v/gCd88eKnk1GflWbfOmZsykHFKWgK0EOzMXOXuRCdk=; b=VlzyURYF3ukuEEZJG8s79AUM+EkB8Ek02eclhNR9I4KoVrTEzvKiOQxQxucd6mmW2WGR71 SsijmmNdA/M2+6AB0xO/fHD5r6zWym46SG1m98d0YXiRAw8RcgsHoS44ky0RRSIau/Y0a9 2hY1/tIH/dR4cLMhl3bIdmoiNLYXr6FTwDWBxO2tFBoI1Zjhu+MVwkXBpGLvqcfc5GIYo5 PpUWRYeKZdOF300SnwHS3SRF8DWPwDTJ/mxIBhI0xKZK9dggs+1+fIYCg5X3HuzKg/eCdU FDBaqi672otRy+K/FT+zr9YnDupjy1qGWvir9VSXQa9bKsXa4VYkVFGiF4Bv6A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040268; 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=v/gCd88eKnk1GflWbfOmZsykHFKWgK0EOzMXOXuRCdk=; b=Re6WTY3C6GObeqn6hTEtopBa/GcyBHnqYemZZ6ec0t5RbB1tmYDoNIymJ0WI9GJ+yUAyyA myFUprJ0aQ6RMkq+D6uB+5JpW1Ba5vt2Y2L84Rjxq9MoaVApMQDAckVUoDv1dqIcyylncA eUowyfVwtlen9GL4ZnuPqECmYVT+d9N0SYP/EN0V2Ntd2obD0zul2AexLXiMAxwfqnHDJm OJuruwxZUF4AlVEtwbANEqEYULb/Z8z4ho/HMsfN/ehCoCzx0FZu8srDJfZTqMI5z1yvfw l6tjCJCoaPvFWqdgPbz1Zwzn98S/t5io13AOvzeO23scv1OsdW5HXfexy57Cog== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758040268; a=rsa-sha256; cv=none; b=F0eCuOFNu++ElpbNZLs4mu3DNi1xlpNc8YI3jNc5LJC9bWgDOkjeawpmE6uUSROwDer/eS 6d67yvxV8L3CCRK6CgsAJArya1X7dnyclWIYEE1i2J/KDvM8+rMzp/saWqgvOjBFRksvWk uXRPotZPwjKVFR8wpfTBwQVuAu4DaAcwnWLAx2JrhbGLXcGjt5Ifx3lQaT6hi5zc1zW+to UTkL496AySb5MQyX1lZTCRaN8HHskBBSq8T9XT4sOyTpVV13z7QoIeTkgvZQFcV7tRFfRU iV/pVSXBi6o68Q1fsKYpFEQ37vGoiuYO0ohJAg79CwhA32ss8te1Mcw1O7CwLQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR6ph4nwRzpMG; Tue, 16 Sep 2025 16:31:08 +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 58GGV880058684; Tue, 16 Sep 2025 16:31:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GGV8kj058681; Tue, 16 Sep 2025 16:31:08 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:31:08 GMT Message-Id: <202509161631.58GGV8kj058681@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: c07b1838f9c9 - releng/14.3 - bnxt: Fix BASE-T, 40G AOC, 1G-CX, autoneg and unknown media lists 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: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.3 X-Git-Reftype: branch X-Git-Commit: c07b1838f9c9e31696716b188a832ec35003ec2d Auto-Submitted: auto-generated The branch releng/14.3 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=c07b1838f9c9e31696716b188a832ec35003ec2d commit c07b1838f9c9e31696716b188a832ec35003ec2d Author: Kevin Bowling AuthorDate: 2025-06-14 23:46:05 +0000 Commit: Gordon Tetlow CommitDate: 2025-09-14 00:24:43 +0000 bnxt: Fix BASE-T, 40G AOC, 1G-CX, autoneg and unknown media lists This was broken in c63d67e137f3, the early returns prevent building the media lists as expected. The BASE-T parts of the patch were suggested by "cyric@mm.st", while I am adding the additional 40G AOC, 1CX, autoneg and unknown PHY fixes based on code inspection. There may be additional work left here for Broadcom but this is certainly better than the returns. PR: 287395 Reported by: mickael.maillot@gmail.com, cyric@mm.st Tested by: Einar Bjarni Halldórsson Approved by: so Security: FreeBSD-EN-25:17.bnxt (cherry picked from commit 5e6e4f752833acc96f1efc893318d3f6b74b9689) (cherry picked from commit 33f65f12eba10588827a13d232337616f6f4facf) --- sys/dev/bnxt/bnxt_en/if_bnxt.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/sys/dev/bnxt/bnxt_en/if_bnxt.c b/sys/dev/bnxt/bnxt_en/if_bnxt.c index eea956759e9e..169255c9433e 100644 --- a/sys/dev/bnxt/bnxt_en/if_bnxt.c +++ b/sys/dev/bnxt/bnxt_en/if_bnxt.c @@ -4609,34 +4609,34 @@ bnxt_add_media_types(struct bnxt_softc *softc) case HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_40G_ACTIVE_CABLE: media_type = BNXT_MEDIA_AC; - return; + break; case HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_1G_BASECX: media_type = BNXT_MEDIA_BASECX; - return; + break; case HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_1G_BASET: case HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_BASET: case HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_BASETE: media_type = BNXT_MEDIA_BASET; - return; + break; case HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_BASEKX: media_type = BNXT_MEDIA_BASEKX; - return; + break; case HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_SGMIIEXTPHY: media_type = BNXT_MEDIA_BASESGMII; - return; + break; case HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_UNKNOWN: /* Only Autoneg is supported for TYPE_UNKNOWN */ - return; + break; default: /* Only Autoneg is supported for new phy type values */ device_printf(softc->dev, "phy type %d not supported by driver\n", phy_type); - return; + break; } switch (link_info->sig_mode) { From nobody Tue Sep 16 16:31:09 2025 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 4cR6pk4QYfz67ZF8; Tue, 16 Sep 2025 16:31:10 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR6pj6HvTz422x; Tue, 16 Sep 2025 16:31:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040269; 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=buLs5cLoRx8QWcLq9PA8QrM9v5pFxeg0rZNQB2gEkP8=; b=TeD32rLTWNajqxkZOGUDqJ9flFavqYKqeI2tCNRiO2FHbHUAIMkC1ov5pFlySxc3HPKVMo nmcDpVsZUeWhARM+y/3zXtemzewh9pysjl4xMcLVaEe7w6nRLOxbWk2f6y3ILkLqIqwJV/ ODwHRFAlSIjTr9HB02sy0PZlpJBK9FPLpqKcjM04h1wTB+lLxKGpPEm8hy07MsZ+p9+jEg flskFngZm4u4CM4tS7IN8jiyjqF9rZP2ReK+RZSogDEXbGzAi5LCeaEHBS4YL45LQXX1g8 tBj4F+NSVrvJxJNjwjvgECi7RKP9mELOx0/JzYfa9nxeopA6hD1xmgty/QX5rw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040269; 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=buLs5cLoRx8QWcLq9PA8QrM9v5pFxeg0rZNQB2gEkP8=; b=sJDBNwD2uMOky3ZtUz2jl6x4330SOk+SEekc4RYCYTbrHZ1MnrIpMHK13VH0pJB1RhmBiK L7l7uKgTWfyUlwcJAXoYlpOWXvow2/Z31VCK18VPP7qrs4cdYmGqRziRjgscHPRunINV0M jgZ+yEsPDfknlByJOd5oKJqTAVJUxG15EhtSgcqUscxevAHTL6hFKMuPeR+Xg7aLHfTQ06 RJ8SSe+W2ICxOwMuQB2mEs7Z0QflmmwD26dppgXAntWfjhiaqlRNkZphVXooUOWk85qSYb 7lJXJvuRwanRSM39beX6ifBM1EYPKgzXzk0jdZk3VBd2fOjf/9HkjsU0AFshWw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758040269; a=rsa-sha256; cv=none; b=D85sPLpSQL1XShQC52XtfgmNTYWn2SWOYCjv393KTcD16cx8R78H6bekgzicX+PRgZ5xEL peyVaAlhL+UfUYzSz+MBaUY4eEXXS8jZf1G2Zb8K2JkCduy6yh/cv6jaMYqIV+gDOe1xpy Ysh6IHlNUhOZ27dg8ZZ94A4c45dr4yVe6CU2gIyqFzDWgjANWHGWij+FiOSGe6OCnuAiVO UR0fm5pdZ2ius695ovMvRe+B1fKnV8RhxWpurpUo/SnczRVUAp6pWHeyFAcp77Xl8kOLcW FUDnsjW+Qfe4wL5vPa5lWSTSETejq90OSbJjTXh1ps6mcdfSpg+J0DwLkwZsnQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR6pj5plGznp7; Tue, 16 Sep 2025 16:31:09 +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 58GGV9JY058723; Tue, 16 Sep 2025 16:31:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GGV9KM058720; Tue, 16 Sep 2025 16:31:09 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:31:09 GMT Message-Id: <202509161631.58GGV9KM058720@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: ed55d0f2bc69 - releng/14.3 - Add UPDATING entries and bump version. 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: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.3 X-Git-Reftype: branch X-Git-Commit: ed55d0f2bc694315d6b906f18e18c059ecebcc18 Auto-Submitted: auto-generated The branch releng/14.3 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=ed55d0f2bc694315d6b906f18e18c059ecebcc18 commit ed55d0f2bc694315d6b906f18e18c059ecebcc18 Author: Gordon Tetlow AuthorDate: 2025-09-16 16:28:47 +0000 Commit: Gordon Tetlow CommitDate: 2025-09-16 16:28:47 +0000 Add UPDATING entries and bump version. Approved by: so --- UPDATING | 11 +++++++++++ sys/conf/newvers.sh | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/UPDATING b/UPDATING index 13a84a404535..31f8d97d4762 100644 --- a/UPDATING +++ b/UPDATING @@ -12,6 +12,17 @@ Items affecting the ports and packages system can be found in /usr/ports/UPDATING. Please read that file before updating system packages and/or ports. +20250916: + 14.2-RELEASE-p6 EN-25:15.arm64 + EN-25:16.vfs + EN-25:17.bnxt + + Fix arm64 syscall(2) allows unprivileged user to panic kernel. [EN-25:15.arm64] + + Fix copy_file_range(2) failing to set output parameters. [EN-25:16.vfs] + + Fix bnxt(4) failing to set media type in some cases. [EN-25:17.bnxt] + 20250808: 14.3-RELEASE-p2 EN-25:12.efi EN-25:13.wlan_tkip diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh index a8ec74cc1226..59e359d9f452 100644 --- a/sys/conf/newvers.sh +++ b/sys/conf/newvers.sh @@ -53,7 +53,7 @@ TYPE="FreeBSD" REVISION="14.3" -BRANCH="RELEASE-p2" +BRANCH="RELEASE-p3" if [ -n "${BRANCH_OVERRIDE}" ]; then BRANCH=${BRANCH_OVERRIDE} fi From nobody Tue Sep 16 16:31:17 2025 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 4cR6ps4BKvz67Z6L; Tue, 16 Sep 2025 16:31:17 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR6ps3JwCz422J; Tue, 16 Sep 2025 16:31:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040277; 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=zgAXAhUDuEKl5O88t4frYMrS2tu41pn4NNg+uwBNjM8=; b=W4NHb4o9NJY9xOLE4bFHneP8EVE8X2xk5VJYlr1XXIIqkaYZ9mwGTxKUJ0bJqiVqyiEOhd +KvKS89p2/KtFD/30bDoPs2Ft5pYzSiNM1y/bHqZML3GmnwMBShGwcDhs1AoG7wwiruHZx pRrBLGJPPKX7wfPWxJD8tqfUqXmHqWwUGBh/Xm6t8Gqc0vYRcB/jYsYdNMJr9/szf/R3K0 iLlUCt2HPMPPdINthIRZmSuMCe//6K+i6/Fcw0AfTb/11Q0834RPdRXO17KmdZcjyksGYr C1cQp2SQyq5QtGw1UGy/PWJC1UdOBF0ZAOMjbf2KenFuW/fDKicTL76JsMU0sQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040277; 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=zgAXAhUDuEKl5O88t4frYMrS2tu41pn4NNg+uwBNjM8=; b=hu4VllLVuHYktCFqby87Vqq/nh8AlrJExHW0n1U7D0y8spJb8XT9Jhj0i1QgA2EDKh/imx 6/KHZ62+k9RZZ3g5D6JT5MwDUDtE8Fvk5XWlv4kQvfMAFLMn1ptGICpHTyBgpN31DeHLnK fjEDOdChsS+x9Nmmj32u3WrM+Ichc2EhOpBcroXxn7k0gdVUiIpo8B6RSbrIz2tAdA7N28 keu5vASsIWW61Uyh5f1dPHzVTbvi1hQnVZ5QgfhGv4IEZs6NIBbupAOTxw9/wGAMd1S5JG LqSLZxroNSClZcH6eMUZNivgXnIk5Ddbtjy/Hin/DRaTt9rm6eg26O2kpalS2w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758040277; a=rsa-sha256; cv=none; b=qRUlnjMcG8iyy8GK/XQ4T6fCfxvje9MOpbS4LBxFxH2Qx9/3dNkA8QiE5ATJh6yJdh3L3m Q+YZspKuwa7htdS2y/T/DkdyLYpHy3I8/QKxS/SlZ8rqRCSDocrIkIFSQdv8TuDXbGUNE2 243FJ2zg2oPSyGkWsRcq1obJlfa5/Un2lALsuBs9s2O5qRgHO/A9aNpIRiRdIgzO1ANDwJ 4R5nZXH8h0ixmp0kwX4JFKBDBfMRQLSZZtPQU1TEDSUTWvie5gaNDNJHxkAp27PdOlz6TF 9adFefy0vtcKrtmpnlhPI526NRkLbnN1lPptkQOMTlKFQXs74HXEqvOIyqdIzg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR6ps2vMqzpYD; Tue, 16 Sep 2025 16:31:17 +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 58GGVHCM062239; Tue, 16 Sep 2025 16:31:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GGVHXp062236; Tue, 16 Sep 2025 16:31:17 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:31:17 GMT Message-Id: <202509161631.58GGVHXp062236@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: 722746b39e6e - releng/14.2 - arm64: prevent panic when using syscall mux + large arg call (mmap) 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: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.2 X-Git-Reftype: branch X-Git-Commit: 722746b39e6ecaa4eeb36005c9bd69a9bcd68528 Auto-Submitted: auto-generated The branch releng/14.2 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=722746b39e6ecaa4eeb36005c9bd69a9bcd68528 commit 722746b39e6ecaa4eeb36005c9bd69a9bcd68528 Author: John-Mark Gurney AuthorDate: 2025-08-18 20:25:37 +0000 Commit: Gordon Tetlow CommitDate: 2025-09-14 00:21:16 +0000 arm64: prevent panic when using syscall mux + large arg call (mmap) if the syscall muxes are used, up to two additional arguments may be required. This means that the 8 required for mmap increases up to 10 (for __syscall). Sponsored by: Juniper Networks, Inc. Approved by: so Security: FreeBSD-EN-25:15.arm64 (cherry picked from commit 740b879c6ade531adebeba7cd2f261bbe650797f) (cherry picked from commit 17d87881a363c160e7e8cdb252d0261214c1a50b) --- sys/arm64/arm64/elf32_machdep.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/arm64/arm64/elf32_machdep.c b/sys/arm64/arm64/elf32_machdep.c index de0ee9607ad1..5f35d01f9ac0 100644 --- a/sys/arm64/arm64/elf32_machdep.c +++ b/sys/arm64/arm64/elf32_machdep.c @@ -193,7 +193,7 @@ freebsd32_fetch_syscall_args(struct thread *td) register_t *ap; struct syscall_args *sa; int error, i, nap, narg; - unsigned int args[4]; + unsigned int args[6]; nap = 4; p = td->td_proc; From nobody Tue Sep 16 16:31:18 2025 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 4cR6pv0XLzz67Yqh; Tue, 16 Sep 2025 16:31:19 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR6pt4Zzmz42LP; Tue, 16 Sep 2025 16:31:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040278; 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=DprsT7BkUJDTnFr+FpMrUrQtIS5fGLfRSixusxNTn9I=; b=sJns3fnatnkR7jYDx0vyuaJUqRtarvJRrX0SWeFi0GtE56Wo5Hpn3rUpIMg7zs9cn9euPc XNwwIKzhnjGx/I/PbiOHNBgT7zvxKU/femYl/pwU0YR3PmHazB4pw9kwzp3ZiUjeCY4gEm P20vpug2Od8Ba03lOegHy9Y8OP/6+1f7lPjt/Y5P6YpHLoXsITMoaqo+4VOU8VncM+ZRAw WkyTWICFnZb4dTngr4eT4I6rhgFfaxfBm56DAiOo9kGgTvvV3gjwVfZW590zwk2CgBfM2b X6qPNl6tnU6/5VudJvTY6qJMPOOM7DuYe1PZ7bR92NvvGQ7hRmaPaPS2+xoQKg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040278; 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=DprsT7BkUJDTnFr+FpMrUrQtIS5fGLfRSixusxNTn9I=; b=DOA4aURvF5vmTJaAXdt1fJJWu3LlGveuM35SDIy39Fjjrg2nwkEZQT8BvKLWX9gNb1GI9w 3bjitNfIV0Bf8Pwsw0KnVPd1HQsH/Gps/vRCAXfyfxUQrP2SFNnOVBulGsV1EX5HI11cep z0IPVfAoqPh3oqJxU4bLkaVPLMJMNMJ72hG7lzG55gXc6WF6uZYeOexoOkGndqgdUUEsTy j0Ha1GCRb5TPr5YCe5/Mlc2j6el7i6krNLG1v8uQDwVCS6F+fJux2AqTkH/IMcqHFfQz1g p0AD7qfH3RkBJ91cFC8rM+8lGPs6nhNbWnWG7tIxKrNGBjjx7kZQU2ayTpzJIQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758040278; a=rsa-sha256; cv=none; b=ipf0iYOtrl1VozXtsvCK8wYA1oI1x0981peq5wQ2HxDBGWphBFRim1SofkMWjP+Ky89ccB 0R3TDLlJCnEtcniJxl7mPNsmqnNYHb2cTic4muFogfmv7UB4EWCTl0fZg5mBexvJKPJy4d uIh5Qja2byGhEmwvmr9PhJJ6/GbFZ9tYxfBKbCnquWOoTc30q2hZ+CqC5BDmyYaskO5L1e oSuoph/ITjhjEfbBVfx+jK95qvIQ7N7/V9hDF+NZQ/ShkGpnt5WZ4MP7O2PH/uwD5aK8hy Mgk/xxQCPItHpJlgivMYUFyAfsLZ9io9zLbKuI7qhy7LV9svLIRNNWsZNYRZYw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR6pt46N6znpC; Tue, 16 Sep 2025 16:31:18 +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 58GGVIea062506; Tue, 16 Sep 2025 16:31:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GGVIer062503; Tue, 16 Sep 2025 16:31:18 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:31:18 GMT Message-Id: <202509161631.58GGVIer062503@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: f3ffa7eb382a - releng/14.2 - Add UPDATING entries and bump version. 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: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.2 X-Git-Reftype: branch X-Git-Commit: f3ffa7eb382a2b90816f94aa2fb2431688e0c2b8 Auto-Submitted: auto-generated The branch releng/14.2 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=f3ffa7eb382a2b90816f94aa2fb2431688e0c2b8 commit f3ffa7eb382a2b90816f94aa2fb2431688e0c2b8 Author: Gordon Tetlow AuthorDate: 2025-09-16 16:28:35 +0000 Commit: Gordon Tetlow CommitDate: 2025-09-16 16:28:35 +0000 Add UPDATING entries and bump version. Approved by: so --- UPDATING | 5 +++++ sys/conf/newvers.sh | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/UPDATING b/UPDATING index 36f7e4a7b151..5bf203683480 100644 --- a/UPDATING +++ b/UPDATING @@ -12,6 +12,11 @@ Items affecting the ports and packages system can be found in /usr/ports/UPDATING. Please read that file before updating system packages and/or ports. +20250916: + 14.2-RELEASE-p6 EN-25:15.arm64 + + Fix arm64 syscall(2) allows unprivileged user to panic kernel. [EN-25:15.arm64] + 20250808: 14.2-RELEASE-p5 EN-25:14.route SA-25:07.libarchive diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh index 773335879171..18bd593fa59f 100644 --- a/sys/conf/newvers.sh +++ b/sys/conf/newvers.sh @@ -53,7 +53,7 @@ TYPE="FreeBSD" REVISION="14.2" -BRANCH="RELEASE-p5" +BRANCH="RELEASE-p6" if [ -n "${BRANCH_OVERRIDE}" ]; then BRANCH=${BRANCH_OVERRIDE} fi From nobody Tue Sep 16 16:31:26 2025 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 4cR6q3574kz67ZFS; Tue, 16 Sep 2025 16:31:27 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR6q30jG4z42Sh; Tue, 16 Sep 2025 16:31:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040287; 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=YIEfrMrHBE+MggTpYRTces6cI63TCE1b3iJEt2bqfHU=; b=jZKXFvU3HzcVd6D7a9D0K8E9ON3V3zby8zwCgWGoWgN6NDB25dOm/a6dKS7rrIDvolqph6 J45E4kjRFN25dewNEmve72WJnysrM9rTylSWjHGlkG0tHSpQAVZYvPr0Yz+DIT/g8EAlss gGou3qzo5fKoDLlVinjZVnjxGXXMZ986HPKCtmK6XMpC8nu3JUZtQVZnvQqo8wuIeawuoA 79qh4MoO2aV018lEE1i9UtCFiBbAoMYvBFNrHX6QoWYYey0lBeqyLOXR2UA9GYbDSKMIVL wQjOPb8Sl+BAuDSetHl2JsrZWfIj/+7dnx5DpdMy/YBC9PzusLTORRjIKCQpOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040287; 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=YIEfrMrHBE+MggTpYRTces6cI63TCE1b3iJEt2bqfHU=; b=H8C16KT3mqywo4aab7ayNTprQG7P6xOoXfiggiNXVhuXGZCTR1/F/t5E56005YVbO8FeX4 jELg+5rjHv68af6PJP02XzbRw7S2QRrm7LAGqgZKJIJjLh88EcBlhJM8koa6dTa0qx3mOa h7QqKNDUiVqU9wQ/BouayanQZObzEhVYrIb/yE86JdanJzIjb1tHfG1gMZn4lng/3182D1 X3nsncEDWrjmtF3lmsdENtwpvMDIXtvhyJ1g+SOiGGuSlBIwLDOslWBAbeLdBbka+ZKDNP MUUsIoyagg4eZZARkGa/G5rhU4QJnS+L/fkSlX+dtcz1koaKmSFJGkHxkuscow== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758040287; a=rsa-sha256; cv=none; b=LuE+jkv+IAAvt9L9hFpGOtfsYNqmFkrgbYFLIuNFPod6qbs6cx8otubNq0/Js7aZZ5mJOJ qdAyeFNFTmGbjU4Xm93pKL0OubyH0llFWvrmgn1gJXWCDamFQYyuKl5T9x2R+KLHpZTWYd EddyjTy+HF+EqucOfXzgbb+X3vlXY6BFQoZ8W7URvmozBM+Ult5aiCA1zDV4K4WSHSw/av LEtxCizG+swfLf9DTf11kr/DnY2nglG141xFO4oFi7wxT38w4N6BMAHASbttptHNWs329h nt+EKkrKKo6oVPrj1tCqASRQ7hnSnlXGMk3kG5E7dL03lXI4++WZtzZ0L03Cdg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR6q26q23zpSh; Tue, 16 Sep 2025 16:31:26 +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 58GGVQcP062667; Tue, 16 Sep 2025 16:31:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GGVQIP062664; Tue, 16 Sep 2025 16:31:26 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:31:26 GMT Message-Id: <202509161631.58GGVQIP062664@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: 751971e55454 - releng/13.5 - arm64: prevent panic when using syscall mux + large arg call (mmap) 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: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/13.5 X-Git-Reftype: branch X-Git-Commit: 751971e5545451114df20d809ead68bfe1d00915 Auto-Submitted: auto-generated The branch releng/13.5 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=751971e5545451114df20d809ead68bfe1d00915 commit 751971e5545451114df20d809ead68bfe1d00915 Author: John-Mark Gurney AuthorDate: 2025-08-18 20:25:37 +0000 Commit: Gordon Tetlow CommitDate: 2025-09-14 00:22:42 +0000 arm64: prevent panic when using syscall mux + large arg call (mmap) if the syscall muxes are used, up to two additional arguments may be required. This means that the 8 required for mmap increases up to 10 (for __syscall). Sponsored by: Juniper Networks, Inc. Approved by: so Security: FreeBSD-EN-25:15.arm64 (cherry picked from commit 740b879c6ade531adebeba7cd2f261bbe650797f) (cherry picked from commit 98ac13c4baf5deb84010d632cb3b96dacd8c4eb6) --- sys/arm64/arm64/elf32_machdep.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/arm64/arm64/elf32_machdep.c b/sys/arm64/arm64/elf32_machdep.c index 1c580e2b0de3..6392de73acff 100644 --- a/sys/arm64/arm64/elf32_machdep.c +++ b/sys/arm64/arm64/elf32_machdep.c @@ -190,7 +190,7 @@ freebsd32_fetch_syscall_args(struct thread *td) register_t *ap; struct syscall_args *sa; int error, i, nap, narg; - unsigned int args[4]; + unsigned int args[6]; nap = 4; p = td->td_proc; From nobody Tue Sep 16 16:31:27 2025 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 4cR6q42Xl9z67ZFT; Tue, 16 Sep 2025 16:31:28 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR6q40fgrz42Xv; Tue, 16 Sep 2025 16:31:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040288; 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=7fgSJkRidk5+6pj3b8/n3y/yJl2K7OxsqeJJJL263fE=; b=bio0DG8RfihAPF2herjdIUfRaMX6+i/q8PD2bqFRfWQ3Ol/urLKGHKGDkUB7RpgJqYbm+0 yJGdA0ATV73mzLHC+YObjMc+8u6jjpsN+v+Gb/4txJvOwwngVRSCmp9yyVo8vCfvkjVxtm vjpjRf89th+Q3k6XneA/VS1ySYTyKH8NzBLXSR60/TIaYLiuWs9yhwYYU/0YGntNEtz/tH HsilHMQFKid922kgF4Wor2A/iJXXO/7GIteboI6ZD5r++6Fq0CDi5P8iiFGerBTxkY3xOG Jy0sjCkoBKLK+QCUaartTqycmpkgJCeiraqLj0k1RG8dQgsrGWTdvgnB9lUy1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758040288; 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=7fgSJkRidk5+6pj3b8/n3y/yJl2K7OxsqeJJJL263fE=; b=rL/XDcw+oXtHeFC+4AVBSXYyQB3dCasUgRDnLZGAYV42pZUN25xZdYbZjg5c8mrF+IaDCc Jhn64J94u17iyCcwlKEoV2EmR3lPoJDBVJfUAAsOFL9BD7lutPY+dnhlhSC00wkc6gP2lo sfIWUvyTN/TgPTlBJswbkG3FTiSy3xYy5Y16XCVi8vzHAp7W154B15BlzxskSHuBEBT/+z i8EDlv4uyi5xrKik0YqY49K/SaGxW4FgJ9NkF+JBVuka5LmGAwemjFGeih/qp58LifcHwp qQ3xcf+3dNA+4C1uMKZsq7uEYejFAW8fh8C2CWOXZSn3dIQD2F1keyhN4Kh8RQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758040288; a=rsa-sha256; cv=none; b=lrCYawVtzzhrl64YwCdG5aeTMC3TwIFTlBVFkeIAQqRDD+UbDljVmwlEOT59FkfJrPeRu6 dpiI8ctMKFghGYL1JzmY2Bb6GiuhtCT+wCLy+2IUxtF5tdfQHvluzhvIqE7QUTP0HR44Jb jsE4Rc4nfy1b5WifZFUBqlHTof+fpXd2yPncyoWgIg/Y0+8v2hZ9ItrJJKpddWH11cDlmG Y+bT1j4iIPLGfoS9b+Gpl/ADXAU9ZaGylP4O7t3fc418VvoDralvlySAeUNNyV2wkeMQfR 2+PKLE4iAxt2+NBCpb1AyOQ1K4AzXQuoCKWrnTZxYBX/Ov/uN1rtLrh9mM4MBw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR6q401dSzpMw; Tue, 16 Sep 2025 16:31:28 +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 58GGVRO7062707; Tue, 16 Sep 2025 16:31:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GGVRLQ062704; Tue, 16 Sep 2025 16:31:27 GMT (envelope-from git) Date: Tue, 16 Sep 2025 16:31:27 GMT Message-Id: <202509161631.58GGVRLQ062704@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: e8acfa0be301 - releng/13.5 - Add UPDATING entries and bump version. 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: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/13.5 X-Git-Reftype: branch X-Git-Commit: e8acfa0be301a840585d0ab42af9ce5e334a59cc Auto-Submitted: auto-generated The branch releng/13.5 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=e8acfa0be301a840585d0ab42af9ce5e334a59cc commit e8acfa0be301a840585d0ab42af9ce5e334a59cc Author: Gordon Tetlow AuthorDate: 2025-09-16 16:28:16 +0000 Commit: Gordon Tetlow CommitDate: 2025-09-16 16:28:16 +0000 Add UPDATING entries and bump version. Approved by: so --- UPDATING | 5 +++++ sys/conf/newvers.sh | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/UPDATING b/UPDATING index 98ab66444454..741ccf307151 100644 --- a/UPDATING +++ b/UPDATING @@ -12,6 +12,11 @@ Items affecting the ports and packages system can be found in /usr/ports/UPDATING. Please read that file before updating system packages and/or ports. +20250916: + 13.5-RELEASE-p4 EN-25:15.arm64 + + Fix arm64 syscall(2) allows unprivileged user to panic kernel. [EN-25:15.arm64] + 20250808: 13.5-RELEASE-p3 SA-25:07.libarchive diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh index a58cc976112a..82dd69582b28 100644 --- a/sys/conf/newvers.sh +++ b/sys/conf/newvers.sh @@ -53,7 +53,7 @@ TYPE="FreeBSD" REVISION="13.5" -BRANCH="RELEASE-p3" +BRANCH="RELEASE-p4" if [ -n "${BRANCH_OVERRIDE}" ]; then BRANCH=${BRANCH_OVERRIDE} fi From nobody Tue Sep 16 17:04:17 2025 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 4cR7Xy4TTsz67dD5; Tue, 16 Sep 2025 17:04:18 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cR7Xy3C35z47LG; Tue, 16 Sep 2025 17:04:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758042258; 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=dUjAiOLoXp8XCsv0iF2CPEwOz0tE1Kb0/iIMQbMf/uU=; b=xaS7jaDMmqRRJOK6TdRLdFpOHbuA5kSC9lczlYv7zz1s5LWPsg0UCopN3J0KMnWHk+gJ4e Ka362asvotp+KYLhm3XMCrDW/rinU5wI0dnI5P0iZ1bKY+kR7JYGCI3EQj8QbH6/te6T1Y sZbl6hIXmKp4zEO/5AEWd9txuzNqS7kMoI/LF3y7Z2ZH5J3p4h9p8K7HpNDhz4HUHEU629 0kTSn97KQABfDTT3EuXu9qj8j8HRRXtgkpWSyYfkpnMlifZf5UVDsgShw5sFlKYUbsSXgq TnkP+b3US14b6S8I7ncImNfIi2dXqS3Tv1DRjMIAQunIbWrpS0n+QGlmAIhQNA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758042258; 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=dUjAiOLoXp8XCsv0iF2CPEwOz0tE1Kb0/iIMQbMf/uU=; b=jaivu5N9isphK7nxUKIjq8GFJn49iAJ78AykZzYNPqtl1NHiaZNxOxUJQ/W8M0lszn75Fq fbfzkGI/VcZbcRTN8Btn8JW1GTAlRA7SkBiHbej4EpjncCsB+FpBi6uHXXuL+zxVmwgfIH iMeCnSseWpZK/j2ZNzH715b7QRjLgeS6gb69FpVKNrmXcgjxRMofTJIYTmP4SFBabk1rEq bccpXKkFThbFYyN4bBiOTe7u2AuRzoYp4IxlPQxhGIlbM5SKzQwKzY2Ef4N/iwFOl2tnyv e4cFv7rj3miNtf6pHsso9z4z/+8HBgFIB1h/kh1dkGYyjrwqSMADoffXQVYmXg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758042258; a=rsa-sha256; cv=none; b=ZfcbThoMgJtCewE18gX1q6cw2EQRl9TtkZ+GlBOUzkTIiY6GDq/huA7hxWpOFeLo2/vUBS gasvK1+KhzmfBbrq2WRo8k2S10uOLM77LjeGz0bkSZ9PsJQVK8EEpkqorEU7CuVDkKrBvh DWMlUlmn4llY2JUJAGIe65j7X2t1msHC89aBPeAnXt9dwYZUOQBnJlyTxQeXVDp9DcNKJq Hxvzo/dVagaYOtxW1iFusD4WmpeQU57FlsTehGI2/lI6zr9w/Lz9tfOWBAJOhfpRN4f5Ir fAUdB2/DN2UHtpvuX/0Xt6q15XoZhkkGDEkAHsd1LYt0f8NBIc/Q1OBjW/mwyQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cR7Xy0b8hzqJ3; Tue, 16 Sep 2025 17:04:18 +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 58GH4HXC022625; Tue, 16 Sep 2025 17:04:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GH4Hg1022622; Tue, 16 Sep 2025 17:04:17 GMT (envelope-from git) Date: Tue, 16 Sep 2025 17:04:17 GMT Message-Id: <202509161704.58GH4Hg1022622@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 87a78d9618ab - main - packages: remove src from base set 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: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 87a78d9618ab5430b12dd5c54ec61fcaeb8f0655 Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=87a78d9618ab5430b12dd5c54ec61fcaeb8f0655 commit 87a78d9618ab5430b12dd5c54ec61fcaeb8f0655 Author: Isaac Freund AuthorDate: 2025-09-16 15:01:00 +0000 Commit: Ed Maste CommitDate: 2025-09-16 17:02:50 +0000 packages: remove src from base set The FreeBSD-src package is the largest single pkgbase package at 158M currently. Remove it and FreeBSD-src-sys (87M) from the base set as they are not useful to all users. Reviewed by: emaste, ivy Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52573 --- release/packages/sets/src.ucl | 5 +++++ release/packages/ucl/src-all.ucl | 4 ++++ release/packages/ucl/src-sys-all.ucl | 4 ++++ 3 files changed, 13 insertions(+) diff --git a/release/packages/sets/src.ucl b/release/packages/sets/src.ucl new file mode 100644 index 000000000000..eada5dbde641 --- /dev/null +++ b/release/packages/sets/src.ucl @@ -0,0 +1,5 @@ +comment = "System source code" + +desc = < To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 36edc5014f63 - main - packages: remove tests from base set 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: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 36edc5014f633c1f00031f5fc5a291f8cdd46d83 Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=36edc5014f633c1f00031f5fc5a291f8cdd46d83 commit 36edc5014f633c1f00031f5fc5a291f8cdd46d83 Author: Isaac Freund AuthorDate: 2025-09-16 15:01:09 +0000 Commit: Ed Maste CommitDate: 2025-09-16 17:02:50 +0000 packages: remove tests from base set Create a new tests package set to hold the tests, which are not useful to all users and don't belong in the base set. Reviewed by: emaste, ivy Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52574 --- release/packages/generate-ucl.lua | 4 ++++ release/packages/sets/tests.ucl | 5 +++++ release/packages/ucl/tests-all.ucl | 4 ++++ 3 files changed, 13 insertions(+) diff --git a/release/packages/generate-ucl.lua b/release/packages/generate-ucl.lua index 47f0a0e9a6a9..211766067952 100755 --- a/release/packages/generate-ucl.lua +++ b/release/packages/generate-ucl.lua @@ -191,6 +191,10 @@ elseif pkgname:match("%-lib32$") then -- support or you don't. elseif pkgname:match("%-dev$") or pkgname:match("^lib.*%-man$") then set = "devel" +-- Don't separate tests and tests-dbg into 2 sets, if the user wants tests +-- they should be able to debug failures. +elseif set == "tests" then + set = set -- If this is a -dbg package, it goes in -dbg, which means the user can -- install debug symbols only for the sets they have installed. elseif pkgname:match("%-dbg$") then diff --git a/release/packages/sets/tests.ucl b/release/packages/sets/tests.ucl new file mode 100644 index 000000000000..88426a54a807 --- /dev/null +++ b/release/packages/sets/tests.ucl @@ -0,0 +1,5 @@ +comment = "System test suite" + +desc = < To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 79e4dfe2a5f7 - stable/15 - libc: Have memcmp test what the standard requires 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: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 79e4dfe2a5f7079608b92d2d1fe38838e7601323 Auto-Submitted: auto-generated The branch stable/15 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=79e4dfe2a5f7079608b92d2d1fe38838e7601323 commit 79e4dfe2a5f7079608b92d2d1fe38838e7601323 Author: Ed Maste AuthorDate: 2024-11-20 16:47:35 +0000 Commit: Ed Maste CommitDate: 2025-09-16 17:34:32 +0000 libc: Have memcmp test what the standard requires libc's C memcmp currently returns the difference in byte values rather than just -1/0/1 as the AArch64 assembly implementation, many non- FreeBSD implementations, and compiler built-in optimizations do. It is a bug for a user to expect memcmp to return the difference in the byte values as the compiler is free to inline memcmp() with an implementation that does not do this. Change the test to validate only what the standard requires. PR: 289084 Reviewed by: markj, fuz Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52502 (cherry picked from commit e0eaabb80d1724acf88f04acbc2ca13d42270863) --- lib/libc/tests/string/memcmp_test.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/libc/tests/string/memcmp_test.c b/lib/libc/tests/string/memcmp_test.c index 5286a0b994f3..fa2f498ccfaf 100644 --- a/lib/libc/tests/string/memcmp_test.c +++ b/lib/libc/tests/string/memcmp_test.c @@ -41,14 +41,14 @@ #endif /* - * On FreeBSD we demand that memcmp returns the difference between the - * characters at the first site of mismatch. However, ISO/IEC 9899:1990 - * only specifies that a number greater than, equal to, or less than - * zero shall be returned. If a unit test for this less strict - * behaviour is desired, define RES(x) to be (((x) > 0) - ((x) < 0)). + * On FreeBSD we previously demanded that memcmp returns the difference + * between the characters at the first site of mismatch. However, + * ISO/IEC 9899:1990 only specifies that a number greater than, equal + * to, or less than zero shall be returned. If a unit test for the + * more strict behaviour is desired, define RES(x) to be (x). */ #ifndef RES -#define RES(x) (x) +#define RES(x) (((x) > 0) - ((x) < 0)) #endif static int (*memcmp_fn)(const void *, const void *, size_t); From nobody Tue Sep 16 20:41:39 2025 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 4cRDMl73mVz682Bg; Tue, 16 Sep 2025 20:41:39 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRDMl6bpYz3Tk3; Tue, 16 Sep 2025 20:41:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055299; 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=yLHz3E2jhrFt/vs37j3dp32kwyHWBaAVSpjHk5iZT3g=; b=efZuIpWcQs7j840SF361Vy4Tynh1VsrfLaKBYdWKKJ+52n3Cs+GmTrTBbt1VjSxvaaBQAK c1mteD3bSpevDFFUgzrAicPN8gCoMnEvr3xnhq0j4MDhL7SVAhOXMj8AifWc0/XokQFrGJ l3G8PGMHcLtA1r33eTiCymHeqkLuHlhQkuMzEkuzdcI/yAk/1jFus508aqI6SGhaRSqrq/ xtBpOBYg/wmPt/D8IHRa5F52/IUvzTxWpgcc0a5zrvJENyyuOr3G6nonYEn9jwKlsxlv9J tvEYPD07bDj9N8f92NtSLfBugJrf0eU8R4koyK0wiyZ5wWUlb9jRkpUi1+UTwA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055299; 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=yLHz3E2jhrFt/vs37j3dp32kwyHWBaAVSpjHk5iZT3g=; b=oD3UReUJ5N9gONNn+wv9r60BuhXcI2r6+n9Z7CIhlOeEAfPrfEvVKbxMSELU6SciOzO6uS b9iI2XEjp0Tzj0hMshNbxaNNOEA+yoJV3IDFuFaaEawdOHBsNPReqWhfYaCesKW+hn57/h DSqQQigotJWvsS+xRthbRMBtNfhmizNNkPlNXxedPaRN/Fk2ei1p6S/Trw2NRpk05KGzvL PG0FIS6KCwIQy6h5SNtOMfwr+krantEfYNyEVul3MsSkrr0yxLWMDO3/c9IHLHzh00bxLx BTveMJXp1P/ys9E7XNA0NIqLyIHNRAUQ6FNq/G/1fJB4YB6tkeg+B5jhjc5zVA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758055299; a=rsa-sha256; cv=none; b=dRuKU277pknAJRi9aatLsiG9+rctj6FOL3Gknzs6kfsHyIDOQoLaik5A7BbaBWTwed1fUB 6CN06Mx8CabCd6Ojdw1YSYb+r5RX4JE7jiqVpwwN8Nf4BmVbCwGfBmoSrqhVMiRIdil60j W1Q2lxx5GaHApzrPbNvnoIWpZz+/JkI/C2IW6EL/L2Mx7uQvWjwI4LiaL3IpCJIs1cOj2L sYXrRQ2qz57fQHykOr/rRsWXaCoAPVPLs4QVLMuPYuMwGj4qj4ebU7R9Z42NgOiXpZwmC4 eR+7zCWGJnaKG6EVX0iIZxNQJisXNp+mTAuuAN2qmEU4Z97nU3Lm7zemfjC9qQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRDMl5dKCzwk1; Tue, 16 Sep 2025 20:41:39 +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 58GKfdli032630; Tue, 16 Sep 2025 20:41:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GKfdd1032627; Tue, 16 Sep 2025 20:41:39 GMT (envelope-from git) Date: Tue, 16 Sep 2025 20:41:39 GMT Message-Id: <202509162041.58GKfdd1032627@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jilles Tjoelker Subject: git: 779812d66989 - main - init: Use root's home directory in single-user mode 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: jilles X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 779812d66989a9c3aaed09e4573400fc137f92b0 Auto-Submitted: auto-generated The branch main has been updated by jilles: URL: https://cgit.FreeBSD.org/src/commit/?id=779812d66989a9c3aaed09e4573400fc137f92b0 commit 779812d66989a9c3aaed09e4573400fc137f92b0 Author: Jilles Tjoelker AuthorDate: 2025-09-14 21:53:34 +0000 Commit: Jilles Tjoelker CommitDate: 2025-09-16 20:36:41 +0000 init: Use root's home directory in single-user mode When starting single-user mode, use the home directory from user root as current directory and for the HOME environment variable. If the directory does not exist, set HOME=/. Also adjust /root/.profile to stop setting HOME, since it should always have been set now. This is intended to keep shell startup files working in single-user mode after /.profile has been removed. Reviewed by: emaste, ivy, kevans MFC after: 1 week Relnotes: yes Differential Revision: https://reviews.freebsd.org/D52527 --- bin/sh/dot.profile | 2 -- sbin/init/init.c | 14 +++++++++++--- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/bin/sh/dot.profile b/bin/sh/dot.profile index d27a2ae2fdbe..cba9bcf18ad9 100644 --- a/bin/sh/dot.profile +++ b/bin/sh/dot.profile @@ -1,6 +1,4 @@ # -HOME=/root -export HOME PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:~/bin export PATH TERM=${TERM:-xterm} diff --git a/sbin/init/init.c b/sbin/init/init.c index b345c8fa219a..d28501053c7f 100644 --- a/sbin/init/init.c +++ b/sbin/init/init.c @@ -851,9 +851,9 @@ single_user(void) const char *shell; char *argv[2]; struct timeval tv, tn; + struct passwd *pp; #ifdef SECURE struct ttyent *typ; - struct passwd *pp; static const char banner[] = "Enter root password, or ^D to go multi-user\n"; char *clear, *password; @@ -885,6 +885,7 @@ single_user(void) */ open_console(); + pp = getpwnam("root"); #ifdef SECURE /* * Check the root password. @@ -892,7 +893,6 @@ single_user(void) * it's the only tty that can be 'off' and 'secure'. */ typ = getttynam("console"); - pp = getpwnam("root"); if (typ && (typ->ty_status & TTY_SECURE) == 0 && pp && *pp->pw_passwd) { write_stderr(banner); @@ -909,7 +909,6 @@ single_user(void) } } endttyent(); - endpwent(); #endif /* SECURE */ #ifdef DEBUGSHELL @@ -930,6 +929,15 @@ single_user(void) } #endif /* DEBUGSHELL */ + if (pp != NULL && pp->pw_dir != NULL && *pp->pw_dir != '\0' && + chdir(pp->pw_dir) == 0) { + setenv("HOME", pp->pw_dir, 1); + } else { + chdir("/"); + setenv("HOME", "/", 1); + } + endpwent(); + /* * Unblock signals. * We catch all the interesting ones, From nobody Tue Sep 16 20:50:51 2025 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 4cRDZM52mKz683Jx; Tue, 16 Sep 2025 20:50:51 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRDZM3CTpz3VXM; Tue, 16 Sep 2025 20: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=1758055851; 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=o5On6EG8twFjQvGWGUu37bP9jq87Mkg4ke0EZcEOy1k=; b=ErV6zxgTFC55XJCG8WyhYnNdwkC22tY0PB1BKOpw8SK0yawXGZKCd61D9179VTCLKTZOAf HHE8wDO60UbCkQR4ZXc+swgnaN5/5gPfqGWOCoCLjNl//RO8c94PCCBxnF8MLHHP0L3yAP /2g0iKWVwJ0p0CZEKgFQABFNnok71ZPCT6f/9lNnToLkXA/0/KRNY/2dlwvuiJGDE/9bBo OKRYIgCZW1ipHN+SoxYREXqeoQkw0c/8hDj2+Up/Z6JDiHZbzJGWkBRz8vW7wIspNI6h/0 x7wooFYedFuuK5scVuzhk9ixuMPN63sRh0Go5+nrGyKntP/E3/NEu6DiHymb+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055851; 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=o5On6EG8twFjQvGWGUu37bP9jq87Mkg4ke0EZcEOy1k=; b=LG2i6w+EmjkVgOSIHN2ABlkF6nIIPJHmjw7Eql9cVs79rxSGxPjOo1WCAeb6qPZuBApxUh NeHxPre6cmqz3bfBeeolPZiF3P+ChrFB87iMbFN0MrSVkwS/QcpJ4ROAZSMaZ4oBXb06Gk NsnEk6c/CcON53Z9pmiIme3oPWQrkEJ+V6iEDaisWEFxRyXwozRvqr+5LIzmZssj3RAhF/ oncaqVHDZOKkwdmYS6v5vU3TUQ2NyzSefiASP2kKiI9GLW1piLmNhtyLGxKIds3NFgfLBZ 7FEX++HS4V5HakvCJ3E+HoG4BBQW6r/iqsAtszZ7eEF3E7cknDIwYny+BnVRBA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758055851; a=rsa-sha256; cv=none; b=EUKp/t8TlYmxXhHEL3mpif384pxPgDfMG16zZUuLs522SS6JtFSIPnLXHViX/oyYibOv4W YBFvTjPIA+XigJDQjVUwq5gK01ulb6YSTGKr5G2FGmeDFV3yDx+YaM92Ze4lgxJUYXXv5B V0088+S6G/KOY79nIee1UAzW+5622pnKZYtbcE1SPVGGk7CFsT9rhG1oTIHbK9DgoSke1l zmSamZXhQP4YlX9Ei6j7R2e9h0+G9/k3tucMqSFeTJiapQ1hckdlYq/jKmciX6MJW1FFK5 XRr/ZZy9CnLMl4CaZ6viaDYkob3hHX660VMLTVJZhB8/4dQi7tzlkcP28HRDDA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRDZM2VjdzwWf; Tue, 16 Sep 2025 20:50:51 +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 58GKopdc046272; Tue, 16 Sep 2025 20:50:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GKopOR046269; Tue, 16 Sep 2025 20:50:51 GMT (envelope-from git) Date: Tue, 16 Sep 2025 20:50:51 GMT Message-Id: <202509162050.58GKopOR046269@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: bab6b01bcfea - main - release: Make azure cloudware images buildable as non-root 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: bab6b01bcfead662b8b10dc52a18beeb42794505 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=bab6b01bcfead662b8b10dc52a18beeb42794505 commit bab6b01bcfead662b8b10dc52a18beeb42794505 Author: Mark Johnston AuthorDate: 2025-09-16 16:53:13 +0000 Commit: Mark Johnston CommitDate: 2025-09-16 20:50:33 +0000 release: Make azure cloudware images buildable as non-root - Don't chroot to uninstall pkg since we don't install pkg in the first place. - Use pw -R instead of chrooting. - Add metalog entries. Reviewed by: cperciva, emaste MFC after: 3 days Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D52451 --- release/tools/azure.conf | 34 ++++++++++++++++++++-------------- 1 file changed, 20 insertions(+), 14 deletions(-) diff --git a/release/tools/azure.conf b/release/tools/azure.conf index e13b63067fee..7975e1db0822 100644 --- a/release/tools/azure.conf +++ b/release/tools/azure.conf @@ -19,20 +19,25 @@ export NOSWAP=YES export VM_BOOTPARTSOFFSET=1M vm_extra_pre_umount() { - mount -t devfs devfs ${DESTDIR}/dev - - # The firstboot_pkgs rc.d script will download the repository - # catalogue and install or update pkg when the instance first - # launches, so these files would just be replaced anyway; removing - # them from the image allows it to boot faster. - chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ - /usr/sbin/pkg delete -f -y pkg - rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports - rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports-kmods - - chroot ${DESTDIR} ${EMULATOR} pw usermod root -h - - - umount ${DESTDIR}/dev + # Remove the pkg package and repo databases as they will likely + # be out of date by the time the image is used. In unprivileged + # builds this is unnecessary as pkg will not be installed to + # begin with. + if [ -z "${NO_ROOT}" ]; then + mount -t devfs devfs ${DESTDIR}/dev + + # The firstboot_pkgs rc.d script will download the repository + # catalogue and install or update pkg when the instance first + # launches, so these files would just be replaced anyway; removing + # them from the image allows it to boot faster. + chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ + /usr/sbin/pkg delete -f -y pkg + umount ${DESTDIR}/dev + rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports + rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports-kmods + fi + + pw -R ${DESTDIR} usermod root -h - cat << EOF >> ${DESTDIR}/etc/rc.conf ifconfig_hn0="SYNCDHCP" @@ -51,6 +56,7 @@ boot_serial="YES" mlx4en_load="YES" mlx5en_load="YES" EOF + metalog_add_data ./boot/loader.conf return 0 } From nobody Tue Sep 16 20:50:54 2025 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 4cRDZR1nBYz68332; Tue, 16 Sep 2025 20:50:55 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRDZQ69JLz3Vck; Tue, 16 Sep 2025 20:50:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055854; 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=IR6HVpQjUtKn8fFh12dH/c/w7rKLkni+UUskqc3GSYk=; b=pNOdOPF7LZ6MOYHolSLuxnl6/8Swh4Fn4S/FDt8Xlw6xr4RFnEkZugdMSyZfLYgBNP3yf4 c3tChwAhH4TaAOaAMBY83XU58TAN0Nen82iXXkIQuQkUvTyXcLv6jGiztNH9wHQIGllWoD AGpBfpWFl+9MMEBqWoiTrhlETI102oeZHbzoUJQSDgoy3Ck5rYIt5UzagxwSJy3dWOB2R6 ece1pfVUW5HWyee6AuG8JlbXq3ZuJIOGfDwxCr6/qQcMENsn5odNPovLFCdZy382usVnpz BvykVF75N9Icfykx7s3+rJyU1iCHETNYJsVoeSVUH1/v97MChkb9LNGHen4P2A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055854; 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=IR6HVpQjUtKn8fFh12dH/c/w7rKLkni+UUskqc3GSYk=; b=WC1xx04qgQxyuVR4XTyWbc3DZb4Ef6GlMm0klXM7OPgftNOlqbBp4dcpIqtyD3YZHdsp9v 3tBfHGjRA/KkKilup/+/pgJzRpOFkzJ2yzc6nQqiOkZmHwdmmICSgsaYE3zzKWFSRwap2/ /GkyXsliUuvzOmEKx8ex2HM9RRssNew6i+AEvkn6UcYPRBZYSRUPZ/5uG9OeVuG5mStgn9 25wepQCSfdfouN8o3Q42dWdkxP6VYzAaOroPE5FozfNZN54VfljWncpWUW5p3NTf5ZVelw Tl40up9JMX1g0DVD9gXSxqe8XhdvsVyXEqSwEO5jaTkHLK+ihDevmGi0owFW6Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758055854; a=rsa-sha256; cv=none; b=P6iHsVEkb44sqI9d1oQ5bnOrDF+7+bKjAzctr2IOcGGAJKTCmL1a2najIwZJkeTuh0xOsl dAomhp7eMatnoGTmo6Fd3C1pTF22OXmo0OEPLs5NzM7ryIjgljm/AxUbyjm7n582CSQ1az SpASZny2RT0pg7DBr8bGRUXOG1yiS//H5tgws+heRSLE+nF19EsryIOqv7sXZG6ynn/O1o ZAQBeltqeqfEvcAs1keFyo5SkJznlA/eTJCDNbrqFwnyUmthKMAXAhfgGzxzkEQGsBQTns Qb4lVlVgJrQndRz6Rs4mpbJI2xvviWfA4Dkshmu2cDxcRe7fLLLR7j9lBFOldg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRDZQ5bGkzwpX; Tue, 16 Sep 2025 20:50:54 +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 58GKos2w046383; Tue, 16 Sep 2025 20:50:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GKosdh046380; Tue, 16 Sep 2025 20:50:54 GMT (envelope-from git) Date: Tue, 16 Sep 2025 20:50:54 GMT Message-Id: <202509162050.58GKosdh046380@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: f1995d6fc13f - main - release: Prepare GCE cloudware images for building as non-root 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f1995d6fc13fa4a36f83cea3b90f27bce2aca4d9 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=f1995d6fc13fa4a36f83cea3b90f27bce2aca4d9 commit f1995d6fc13fa4a36f83cea3b90f27bce2aca4d9 Author: Mark Johnston AuthorDate: 2025-09-16 16:54:11 +0000 Commit: Mark Johnston CommitDate: 2025-09-16 20:50:33 +0000 release: Prepare GCE cloudware images for building as non-root - Avoid mounting devfs just to list packages and fetch distfiles. - Add metalog entries. Reviewed by: cperciva, emaste MFC after: 3 days Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D52455 --- release/tools/gce.conf | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/release/tools/gce.conf b/release/tools/gce.conf index dc56be30c7ca..a7ccfc27a75c 100644 --- a/release/tools/gce.conf +++ b/release/tools/gce.conf @@ -21,6 +21,7 @@ vm_extra_install_base() { echo 'search google.internal' > ${DESTDIR}/etc/resolv.conf echo 'nameserver 169.254.169.254' >> ${DESTDIR}/etc/resolv.conf echo 'nameserver 8.8.8.8' >> ${DESTDIR}/etc/resolv.conf + metalog_add ./etc/resolv.conf } vm_extra_pre_umount() { @@ -94,25 +95,18 @@ EOF # ports.txz distributions to the target virtual machine disk image # and fetch the sources for the third-party software installed on # the image. - if [ ! -c "${DESTDIR}/dev/null" ]; then - DEVFSISOURS=1 - mkdir -p ${DESTDIR}/dev - mount -t devfs devfs ${DESTDIR}/dev - fi if [ -e "${DESTDIR}/../ftp/src.txz" ]; then tar fxJ ${DESTDIR}/../ftp/src.txz -C ${DESTDIR} fi if [ -e "${DESTDIR}/../ftp/ports.txz" ]; then tar fxJ ${DESTDIR}/../ftp/ports.txz -C ${DESTDIR} - _INSTALLED_PACKAGES=$(chroot ${DESTDIR} pkg info -o -q -a) + _INSTALLED_PACKAGES=$(pkg -r ${DESTDIR} info -o -q -a) for PACKAGE in ${_INSTALLED_PACKAGES}; do - chroot ${DESTDIR} \ - make -C /usr/ports/${PACKAGE} fetch + make -C ${DESTDIR}/usr/ports/${PACKAGE} fetch \ + DISTDIR=${DESTDIR}/usr/ports/distfiles + done fi - if [ "$DEVFSISOURS" = "1" ]; then - umount_loop ${DESTDIR}/dev - fi ## XXX: Verify this is needed. I do not see this requirement ## in the docs, and it impairs the ability to boot-test a copy @@ -128,6 +122,5 @@ vm_emulation_cleanup() { if [ -n "${QEMUSTATIC}" ]; then rm -f ${DESTDIR}/${EMULATOR} fi - umount_loop ${DESTDIR}/dev return 0 } From nobody Tue Sep 16 20:50:53 2025 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 4cRDZQ29gtz6835N; Tue, 16 Sep 2025 20:50:54 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRDZP4m0cz3VZb; Tue, 16 Sep 2025 20:50:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055853; 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=rKmbSSzcCiADa3FkzHr8psdMWCGkwVQSjEHXzkobXv8=; b=BhYBo+Ju2MYepfQREChB4XqejVotz1f0B4LsVmDApCYntldl+BqzHmyX6AlVrCzE/HepjT 6i4r1PE7rDBBbmoBCKeo21wlbApRG71RZLlpgJV6wfo7qtEoZH1iLJWjMxHNu3QJCZQm3O c6pSvpYobPqRLX8ZKJHH0HiCbCBcL7J1kMpthPWk1xUTQH1mKX8GQ+dNHWTxFEu7JEKSp3 XeL/YDXW7be0W+r+ikInaXpZNmIqPu0GPsw2WAZe5sLNRGhR9pUXuXAnUbYcMV6ERTB6m+ wCEmJHz+B2/4PSVNBZ6vNUfq9zsHqMunTYMZIrDTGBLcu5LC99MX6393sEyp3A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055853; 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=rKmbSSzcCiADa3FkzHr8psdMWCGkwVQSjEHXzkobXv8=; b=DV0kJ5+m0yBCOx/DyY9P9/0aOSsTeEZR00nn2GvB0AQ1sN6kGzQRVt6wQrhjWk5zJWOlVj +XmRQ5OKluBbYSRSSN+HTrWvh9h0goRANwdgk+oP9l7HSAyE+X4p8qyZQprWAY7lsEjpiR iGcMMUEWBO241sbnkMQ9GYTMXCFgnQ/JGlnIfqQTnaJvtNRInB+KFw2Fp/8oBgvWYfR9hF AL6vJi2+cRsmRIcC3Oq5L5KaqQ3DYXlG5Iud9ydz0kxAfNCdb7gv1rl/voV8xSGHnfEL6R I8NoTU8OdpcIYcFJg6ECW6ouUatNGv3AanNuYvdyqASK68sIF6js2WFUfFRlbw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758055853; a=rsa-sha256; cv=none; b=IZiPHxkW2sQwXhmiOse6dqeVE4+PLW3uNnl9mhC40KS4fqfKHR9ggMUgR4QhlC/83ZGBiU rlD/7/b2A17+sVj+wxurTH8kpFx/VjwpT6HDF+TmNfEEdLEotS4E52uF/Y2pnIkHS2illN bMYUlvMyLaZEQheNKDajGqz2lcc2QUpQbMn3nOS3SP9sKc9cdh4jdHlOo2grT8LvFqHD4B yIAu/MEoM3F0hvObnXJDWQaNKur0UNnNeTB0x4UPNOTyXb/bEGXyFqdMODEf+Q8nyL7jW8 lA2GnxGyQChspdKshTErSzM3YXeajTH97JeTw4N2q1ye0gnccU1PGpPD0OFaSA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRDZP4KdMzx0x; Tue, 16 Sep 2025 20:50:53 +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 58GKorT2046349; Tue, 16 Sep 2025 20:50:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GKorEs046346; Tue, 16 Sep 2025 20:50:53 GMT (envelope-from git) Date: Tue, 16 Sep 2025 20:50:53 GMT Message-Id: <202509162050.58GKorEs046346@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: 8f5791873a30 - main - release: Prepare oracle cloudware images for non-root builds 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8f5791873a30122f72266cc44309933118d7fe36 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=8f5791873a30122f72266cc44309933118d7fe36 commit 8f5791873a30122f72266cc44309933118d7fe36 Author: Mark Johnston AuthorDate: 2025-09-16 16:53:56 +0000 Commit: Mark Johnston CommitDate: 2025-09-16 20:50:33 +0000 release: Prepare oracle cloudware images for non-root builds - Add metalog entries. - Remove a stray entry in the package list. Reviewed by: cperciva, emaste MFC after: 3 days Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D52454 --- release/tools/oracle.conf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/release/tools/oracle.conf b/release/tools/oracle.conf index 688820be9cbe..ebda3b3d6e61 100644 --- a/release/tools/oracle.conf +++ b/release/tools/oracle.conf @@ -55,6 +55,7 @@ EOF xz_load="YES" zfs_load="YES" EOF + metalog_add_data ./boot/loader.conf cat <<-'EOF' >> ${DESTDIR}/etc/ssh/sshd_config # S11 Configure the SSH service to prevent password-based login @@ -82,10 +83,11 @@ EOF network: renderers: ['freebsd'] EOF + metalog_add_data ./usr/local/etc/cloud/cloud.cfg.d/98_oracle.cfg # Use Oracle Cloud Infrastructure NTP server sed -i '' -E -e 's/^pool.*iburst/server 169.254.169.254 iburst/' \ - ${DESTDIR}/etc/ntp.conf + ${DESTDIR}/etc/ntp.conf return 0 } From nobody Tue Sep 16 20:50:52 2025 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 4cRDZN5h7rz682xT; Tue, 16 Sep 2025 20: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRDZN44kxz3VTY; Tue, 16 Sep 2025 20:50:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055852; 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=lt2yq2ZWFORBpFk5zp8JbmAK5qtENQ/CPVyt8XAvMdQ=; b=tUzJ0yAX/s31qhU1piXGFIBExCmBHIj8fTbxzHehEPwI/vE4rVnSUIHmO/aCb5vxqObmAc rb5SudSSTSVZtlriKLs9FO4UnMScmow+Nh7UEXM4rnQXvWyeOuNtMdI4ZDcANWcjcqZL4M wDehPzguGqZo+WHidqp9q69+FEejKrWW5ts/INh6QQnZ7IlTwFdscN+hlriS5CIsazV1ru ackB0Aopqu7X5+wUL2AFmK41/9Sbyqyj5G0YlFlH7ORgGyFLkF8Zx0zChK0woP9g0t4hQa HwgXhAlX6L121LLkYgh45Of6p1VmtsRpGrfDjL5ki1BJKqS+W8Rl/2w8KYvkug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055852; 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=lt2yq2ZWFORBpFk5zp8JbmAK5qtENQ/CPVyt8XAvMdQ=; b=hHgXsbIG5nNEN1uV5ESufcfOzWsmnDWkGpVQX48q/xzZd1QzY9fyGsLe8oz6DhY7ghqjT3 a7kMlO+Hj9wVL0pgNlsmZs90E73hYByZY2jtOGEYnHPOfl3DHsqN5dEfRwk3PB802tb/dY WFvpV+Vgh57mLrrmNowDli0wQhrGy4f/D6H5GNUee4Xu2vQKiy2sV2gjpaCxYVz9mw9Q3k JyTyJEE/1bzSTy9gcbzoyKYWmRrRu7xymo2V+WA33AdQELoCk5/8P3KJqfBYA2Z9GPx8+r S/0xrNQdtVYXUayUqADXaidIV8DdzRcmQDk5X7OUWA9ck/zaayep/1GeYhksiA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758055852; a=rsa-sha256; cv=none; b=eDVRxbIzfzBT1cApo+kxb80NuOz89o2Actjsno9WjvmHFkSfysF7MbAm9DvfhGH9fIZuWQ 0a9nBKefwohu4OrHiZ/x/R2kMW+bYy0r06y5M9mCWZShDjdDV9bh7yIq4A15FeqNLZkJP6 8sbh0xDH0ERt47fRMPsYwwGLsPJWRQuMY8JxfW+sRNXEiJKw8j12j7D4RE4A+p5pWPVVZt 8zbkvK3jdRfKUhLDYDqFroAIIRKlKWTTEgg9Z59bbkzINDklHRSoZr1sP6xrYpUxxyVF0G vE+d4tWGH4HcO2Xh16hlY5VrqOiIwpm5hP+7/DhUb+4afkYWblyiVJiSkoQUng== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRDZN3hCczwpW; Tue, 16 Sep 2025 20:50:52 +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 58GKoqq0046307; Tue, 16 Sep 2025 20:50:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GKoqwA046304; Tue, 16 Sep 2025 20:50:52 GMT (envelope-from git) Date: Tue, 16 Sep 2025 20:50:52 GMT Message-Id: <202509162050.58GKoqwA046304@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: 8027de008d9f - main - release: Prepare EC2 cloudware images to be buildable as non-root 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8027de008d9f3c5cd5509d586f14846abd0f3db2 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=8027de008d9f3c5cd5509d586f14846abd0f3db2 commit 8027de008d9f3c5cd5509d586f14846abd0f3db2 Author: Mark Johnston AuthorDate: 2025-09-16 16:53:35 +0000 Commit: Mark Johnston CommitDate: 2025-09-16 20:50:33 +0000 release: Prepare EC2 cloudware images to be buildable as non-root - Avoid chrooting to uninstall pkg, as it will not be installed in the first place when in non-root mode. - Add metalog entries. Reviewed by: cperciva MFC after: 3 days Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D52452 --- release/tools/ec2-base.conf | 1 + release/tools/ec2-builder.conf | 5 +++++ release/tools/ec2-cloud-init.conf | 1 + release/tools/ec2-small.conf | 1 + release/tools/ec2.conf | 31 ++++++++++++++++++++----------- 5 files changed, 28 insertions(+), 11 deletions(-) diff --git a/release/tools/ec2-base.conf b/release/tools/ec2-base.conf index 3ed20474a4e8..b6354db3d9d1 100644 --- a/release/tools/ec2-base.conf +++ b/release/tools/ec2-base.conf @@ -28,6 +28,7 @@ vm_extra_pre_umount() { # be "new" disks; there is no "previous boot" when they might have # been seen and used already. touch ${DESTDIR}/var/db/ec2_ephemeral_diskseen + metalog_add_data ./var/db/ec2_ephemeral_diskseen # Configuration common to all EC2 AMIs ec2_common diff --git a/release/tools/ec2-builder.conf b/release/tools/ec2-builder.conf index 7927fc13a74d..993dffc565eb 100644 --- a/release/tools/ec2-builder.conf +++ b/release/tools/ec2-builder.conf @@ -28,6 +28,7 @@ vm_extra_pre_umount() { # be "new" disks; there is no "previous boot" when they might have # been seen and used already. touch ${DESTDIR}/var/db/ec2_ephemeral_diskseen + metalog_add_data ./var/db/ec2_ephemeral_diskseen # Configuration common to all EC2 AMIs ec2_common @@ -37,21 +38,25 @@ vm_extra_pre_umount() { # Grab a copy of the ec2-base disk image, and compress it zstd < ${EC2BASEIMG} > ${DESTDIR}/image.zst + metalog_add_data ./image.zst # Disable fortune so we don't have extra noise at login chmod a-x ${DESTDIR}/usr/bin/fortune # Install the AMI-building script install -m 755 ${WORLDDIR}/release/tools/mkami.sh ${DESTDIR}/bin/mkami + metalog_add_data ./bin/mkami 0755 # Install an /etc/rc which juggles disks around for us install -m 755 ${WORLDDIR}/release/tools/rc.amibuilder ${DESTDIR}/etc + metalog_add_data ./etc/rc.amibuilder 0755 # We want to mount from the UFS disk and juggle disks first cat >> ${DESTDIR}/boot/loader.conf <<-EOF vfs.root.mountfrom="ufs:/dev/gpt/rootfs" init_script="/etc/rc.amibuilder" EOF + metalog_add_data ./boot/loader.conf return 0 } diff --git a/release/tools/ec2-cloud-init.conf b/release/tools/ec2-cloud-init.conf index 048202e252f6..2a15ae5c57d8 100644 --- a/release/tools/ec2-cloud-init.conf +++ b/release/tools/ec2-cloud-init.conf @@ -27,6 +27,7 @@ vm_extra_pre_umount() { doas: - permit nopass ec2-user EOF + metalog_add_data ./usr/local/etc/cloud/cloud.cfg.d/98_ec2.cfg return 0 } diff --git a/release/tools/ec2-small.conf b/release/tools/ec2-small.conf index 858836717f5a..e2a348d6ba8f 100644 --- a/release/tools/ec2-small.conf +++ b/release/tools/ec2-small.conf @@ -33,6 +33,7 @@ vm_extra_pre_umount() { # be "new" disks; there is no "previous boot" when they might have # been seen and used already. touch ${DESTDIR}/var/db/ec2_ephemeral_diskseen + metalog_add_data ./var/db/ec2_ephemeral_diskseen # Configuration common to all EC2 AMIs ec2_common diff --git a/release/tools/ec2.conf b/release/tools/ec2.conf index 704a8f3f0073..335db6cca93a 100644 --- a/release/tools/ec2.conf +++ b/release/tools/ec2.conf @@ -22,17 +22,27 @@ export NOSWAP=YES ec2_common() { # Delete the pkg package and the repo database; they will likely be - # long out of date before the EC2 instance is launched. - mount -t devfs devfs ${DESTDIR}/dev - chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ - /usr/sbin/pkg delete -f -y pkg - umount ${DESTDIR}/dev - rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports - rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports-kmods + # long out of date before the EC2 instance is launched. In + # unprivileged builds this is unnecessary as pkg will not be + # installed to begin with. + if [ -z "${NO_ROOT}" ]; then + mount -t devfs devfs ${DESTDIR}/dev + chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ + /usr/sbin/pkg delete -f -y pkg + umount ${DESTDIR}/dev + rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports + rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports-kmods + fi # Turn off IPv6 Duplicate Address Detection; the EC2 networking # configuration makes it unnecessary. echo 'net.inet6.ip6.dad_count=0' >> ${DESTDIR}/etc/sysctl.conf + metalog_add_data ./etc/sysctl.conf + + # Tell gptboot not to wait 3 seconds for a keypress which will + # never arrive. + printf -- "-n\n" > ${DESTDIR}/boot.config + metalog_add_data ./boot.config # Booting quickly is more important than giving users a chance to # access the boot loader via the serial port. @@ -43,10 +53,6 @@ ec2_common() { # default 2048 bytes of entropy; ask for 64 bytes instead. echo 'entropy_efi_seed_size="64"' >> ${DESTDIR}/boot/loader.conf - # Tell gptboot not to wait 3 seconds for a keypress which will - # never arrive. - printf -- "-n\n" > ${DESTDIR}/boot.config - # The emulated keyboard attached to EC2 instances is inaccessible to # users, and there is no mouse attached at all; disable to keyboard # and the keyboard controller (to which the mouse would attach, if @@ -93,6 +99,7 @@ ec2_common() { # by pressing the "Attention button" a second time, but in the EC2 # environment this delay serves no purpose. echo 'hw.pci.pcie_hp_detach_timeout="0"' >> ${DESTDIR}/boot/loader.conf + metalog_add_data ./boot/loader.conf # Disable KbdInteractiveAuthentication according to EC2 requirements. sed -i '' -e \ @@ -127,6 +134,7 @@ REGION=`fetch -qo- http://169.254.169.254/latest/meta-data/placement/availabilit echo "-nfsv4,minorversion=1,oneopenown ${FS}.efs.${REGION}.amazonaws.com:/" EOF chmod 755 ${DESTDIR}/etc/autofs/special_efs + metalog_add_data ./etc/autofs/special_efs 0755 return 0 } @@ -154,6 +162,7 @@ ec2_base_networking () { /usr/local/sbin/dhclient -6 -nw -N -cf /dev/null $1 EOF chmod 755 ${DESTDIR}/usr/local/libexec/rtsold-M + metalog_add_data ./usr/local/libexec/rtsold-M 0755 return 0 } From nobody Tue Sep 16 20:50:55 2025 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 4cRDZS1r4Jz6835W; Tue, 16 Sep 2025 20:50:56 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRDZS0TX8z3Vcn; Tue, 16 Sep 2025 20:50:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055856; 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=G9fIwXjPI4X4j53hGWeruqRk4r/r7ViDPFl1Jf3GEdE=; b=VkS/gR/YBxSrMbMTHR8w1j/B1AlMOOPWVIvbYDJa0l4r1BLITEeN2f3G6r91MedIYn0+9i Wo/AoV7kxbbyc2jsCetYPrkzTX0NWuBpgM2H3HkGVkFhfgc2jDKyDofDRoPd18a91zp5/4 PemmrVpPHU1do7Z3VZNtDzJwqD84X7pzu9SAUi82Q0kRFaCqE2b8FBkm8xwpfZOQck2+xP EDiYG2rEu2MeXPp046gJJv9ZGY7sHKPbz+r9bpU7xV128jFNjiqyQIz24Nm8J7r0AsuvGx mSKCA/R9MobtsiF2CA+mEPHIUAwZspzj4xsfFp4zQj9dEor4qFBdO16heotKqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758055856; 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=G9fIwXjPI4X4j53hGWeruqRk4r/r7ViDPFl1Jf3GEdE=; b=EP8CUH2+GXEfu6xN+mvRwBYXvo/irYF6fq4khA502R7z1DcLgJofS4ziBGfcI4f1n/xBie M2kWtvMpejCVbKvEV5gGEUDDlERibLDA5ExX2MeRYTIdwpNHsLvzSKiX7pXR2WUxOUwVaR upncLN0Fo7pWb8bnuau1BlrJTJLKsrJt5S91RKQByJ1Wy9Gb/QZnkop393Ez/tudbb5JpR v8NzD6dbpP3MdwTa2LlalXTq2FeUTEiW/49CZD9q10jC6c2AfHWH+UMZ/9bK/bFmDh014F cYVYP2x7fSNAYB/ekx7jCeBOLdCmiEjIn+OCJPFo4Z7CN4CWYIVHrKuMvdI1Nw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758055856; a=rsa-sha256; cv=none; b=Vzsjq+CARDVQs0D91Q9JkGRA+3tYgvCtbrxB+VVWWB+sTT+FKHV4l9IcaVryd46Y+hhaar n3mJBnY4FdQAP3hXI0dC7WZCt+xrs109748NlFMwpiiOs7gHJ8uz1XR4ACMLBkCVRF32vP Kd2nl6b1qy9lFbd/R6+/QUnSejeqnMlIDa6n07yb8ydw6AOm4u8MYEFb1ULGM5SIuW2Ta7 Y9oIOHC16ElZ8Nu5lFe6aYUAQSZXkQ9/w0uv3HoIqFNQ2YZTPCsA62jXDhJgelCbBWJzmp 5q3BsrZTZGNhnz42ClFPVBG0Z3br7gcbnkgX/u0dm5Ccci9yBBa54P/SW9uLog== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRDZR6s80zwmQ; Tue, 16 Sep 2025 20:50:55 +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 58GKotjL046420; Tue, 16 Sep 2025 20:50:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GKotof046417; Tue, 16 Sep 2025 20:50:55 GMT (envelope-from git) Date: Tue, 16 Sep 2025 20:50:55 GMT Message-Id: <202509162050.58GKotof046417@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: 135cb071e068 - main - release: Prepare Vagrant cloudware images for building as non-root 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 135cb071e0683ea947c308a2de404d1185558ea6 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=135cb071e0683ea947c308a2de404d1185558ea6 commit 135cb071e0683ea947c308a2de404d1185558ea6 Author: Mark Johnston AuthorDate: 2025-09-16 16:54:25 +0000 Commit: Mark Johnston CommitDate: 2025-09-16 20:50:33 +0000 release: Prepare Vagrant cloudware images for building as non-root Add metalog entries for various files. This is a bit incomplete as pw(8) doesn't yet have support for emitting metalog entries, which we need since it's used here to create an interactive user. Reviewed by: emaste MFC after: 3 days Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D52456 --- release/tools/vagrant.conf | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/release/tools/vagrant.conf b/release/tools/vagrant.conf index 506174d0ea16..7ab0e1238693 100644 --- a/release/tools/vagrant.conf +++ b/release/tools/vagrant.conf @@ -47,19 +47,22 @@ vagrant_common () { -c 'Vagrant User' -d '/home/vagrant' -s '/bin/csh' # Change root's password to vagrant - echo 'vagrant' | /usr/sbin/pw -R ${DESTDIR} \ - usermod root -h 0 + echo 'vagrant' | /usr/sbin/pw -R ${DESTDIR} usermod root -h 0 # Configure sudo to allow the vagrant user echo 'vagrant ALL=(ALL:ALL) NOPASSWD: ALL' >> ${DESTDIR}/usr/local/etc/sudoers # Configure the vagrant ssh keys mkdir ${DESTDIR}/home/vagrant/.ssh - chmod 700 ${DESTDIR}/home/vagrant/.ssh + echo "ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEA6NF8iallvQVp22WDkTkyrtvp9eWW6A8YVr+kz4TjGYe7gHzIw+niNltGEFHzD8+v1I2YJ6oXevct1YeS0o9HZyN1Q9qgCgzUFtdOKLv6IedplqoPkcmF0aYet2PkEDo3MlTBckFXPITAMzF8dJSIFo9D8HfdOV0IAdx4O7PtixWKn5y2hMNG0zQPyUecp4pzC6kivAIhyfHilFR61RGL+GPXQ2MWZWFYbAGjyiYJnAmCP3NOTd0jMZEnDkbUvxhMmBYSdETk1rRgm+R4LOzFUGaHqHDLKLX+FIPKcF96hrucXzcWyLbIbEgE98OHlnVYCzRdK8jlqm8tehUc9c9WhQ== vagrant insecure public key" > ${DESTDIR}/home/vagrant/.ssh/authorized_keys echo "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIN1YdxBpNlzxDqfJyw/QKow1F+wvG9hXGoqiysfJOn5Y vagrant insecure public key" >> ${DESTDIR}/home/vagrant/.ssh/authorized_keys - chown -R 1001 ${DESTDIR}/home/vagrant/.ssh chmod 600 ${DESTDIR}/home/vagrant/.ssh/authorized_keys + metalog_add_data ./home/vagrant/.ssh/authorized_keys 0600 + + chmod 700 ${DESTDIR}/home/vagrant/.ssh + chown -R 1001 ${DESTDIR}/home/vagrant/.ssh + echo "./home/vagrant/.ssh type=dir uid=1001 gid=1001 mode=0700" >> METALOG # Reboot quickly, Don't wait at the panic screen echo 'debug.trace_on_panic=1' >> ${DESTDIR}/etc/sysctl.conf @@ -68,6 +71,7 @@ vagrant_common () { # The console is not interactive, so we might as well boot quickly. echo 'autoboot_delay="-1"' >> ${DESTDIR}/boot/loader.conf + metalog_add_data ./boot/loader.conf # The first time the VM boots, the installed "first boot" scripts # should be allowed to run: From nobody Tue Sep 16 21:35:08 2025 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 4cRFYS4nZzz6867j; Tue, 16 Sep 2025 21:35:08 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRFYS3y1Qz3cLk; Tue, 16 Sep 2025 21:35:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758058508; 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=bKszHXa26KEjHkJdQrEOj5WZAB3cwniQvKre6ceRo7k=; b=Ebx46YN28rkC+BLdPUsDoo/Zy3YSPiHh7E8iW1rxtiKGvN10AzzUCGu0jhaYcD1Gclxzf0 Kh5vIkUH/iH0H5RpUm/VUqTlGMo9ekRLrN68KOAAOls85DYVUGffYtRM1fKb35v+x0eRoN Ip1B9vkcTNchnQg6/qpB+WneRrPV2pebmeeF3KJBTsLBd4gH2Wl7hYM9LeYN+FYWwP6nmr iMXhqqG26o9vUuNQVJjfKxYAz8rKJJ0HshsBon4xdMjJPOYcChKTu5IRxotOp92ST+80uG p9S6Z9k1lkHk0Pr7Sc7G1mBGeIoy8SiuEFcV/Hg63agfbtW0fkbTW2nk/bSayw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758058508; 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=bKszHXa26KEjHkJdQrEOj5WZAB3cwniQvKre6ceRo7k=; b=KPQWXAYc2MfWyhha0HEMPSEIqOXTFgEDcmb3h+LKWSGB0BdWR+kxZs5C2Fzq8CifGd8i+Q Aioq+WYJFz/Zel2e/xEBf3wI8d+1Tfec/Y/yu6MCD2FOwke9CogTqrBsZcThr4CsA6ceSY JiEm5kUnGhcTnJjN53xip7w+HDCsnSXnLhCYdRZs2zEdG7Fa3fefBCckbFmSZy3aC2euQD AjE/Duh6Egtjx2ESoXSVfzGorvPM12q1DzV1nU5QlHWdNSStNTjK/AFAzIOCrWWA8kn2eM fvPKAxk/tn7i9mDqnnMIAQO4XF/4K9vOuyOWSxX1ySnVjjgJg1edgnl8Eutllg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758058508; a=rsa-sha256; cv=none; b=Ls2us5jtRL5lr+QYLGxbYx2Oq8kA9ohy3QJkUqZoqnynbdQj1FdXuOfIabYH8AeXM18Kva /DB+uMNoi98x4mIGLetGoSfJj2MUhpwjcJAQVyEe/DluNo+w1wg5XfBi496PJAou4/2RFK kxwKbYEL6kJmS2m7Vs1bXUSDI0ZPAa06wpEwgJaItqPTJ9eVLMeKvfrNEVvjmLXPcPguCd IH1VhtJAPFoTxsGjOYRCfqSpSJpTZt2UzUTQ6Ur3XcN0gxgOJBQxd0wD73cR00RLSqo/fU UZ2f8H82544OnUXWIa0CeaxWa0POIJVMK+ra0JWaNQZQ69bY5WA2SrhH1wfqGw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRFYS3950zxxB; Tue, 16 Sep 2025 21:35:08 +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 58GLZ8rc029591; Tue, 16 Sep 2025 21:35:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GLZ8BZ029588; Tue, 16 Sep 2025 21:35:08 GMT (envelope-from git) Date: Tue, 16 Sep 2025 21:35:08 GMT Message-Id: <202509162135.58GLZ8BZ029588@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Michael Tuexen Subject: git: 1bb72d3d6eee - main - tcp: improve compilation of cc and their helper modules 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: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1bb72d3d6eee50232b6d6acbc201f9aaac93e2b5 Auto-Submitted: auto-generated The branch main has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=1bb72d3d6eee50232b6d6acbc201f9aaac93e2b5 commit 1bb72d3d6eee50232b6d6acbc201f9aaac93e2b5 Author: Michael Tuexen AuthorDate: 2025-09-16 21:30:40 +0000 Commit: Michael Tuexen CommitDate: 2025-09-16 21:30:40 +0000 tcp: improve compilation of cc and their helper modules * Allow the congestion control modules CDG, CHD, HD, and vegas also to be compiled into the kernel for IPv6 only kernel configs. * Compile the helper module h_ertt for round trip time estimation only into the kernel, if one of the congestion control module using it (one of CDG, CDH, HD, or vegas) is also compiled into the kernel. Please note the second point implies that TCP TSO is done whenever possible as long as none of the congestion control modules CDG, CHD, HD, or vegas is loaded or compiled into the kernel. Reviewed by: cc MFC after: 3 days Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D52547 --- sys/conf/files | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/sys/conf/files b/sys/conf/files index 9661bafea8f9..db05a1424f00 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -4369,15 +4369,23 @@ netinet/cc/cc.c optional cc_newreno inet | cc_vegas inet | \ cc_chd inet | cc_cdg inet | cc_newreno inet6 | cc_vegas inet6 | \ cc_htcp inet6 | cc_hd inet6 |cc_dctcp inet6 | cc_cubic inet6 | \ cc_chd inet6 | cc_cdg inet6 -netinet/cc/cc_cdg.c optional inet cc_cdg tcp_hhook -netinet/cc/cc_chd.c optional inet cc_chd tcp_hhook +netinet/cc/cc_cdg.c optional inet cc_cdg tcp_hhook | \ + inet6 cc_cdg tcp_hhook +netinet/cc/cc_chd.c optional inet cc_chd tcp_hhook | \ + inet6 cc_chd tcp_hhook netinet/cc/cc_cubic.c optional inet cc_cubic | inet6 cc_cubic netinet/cc/cc_dctcp.c optional inet cc_dctcp | inet6 cc_dctcp -netinet/cc/cc_hd.c optional inet cc_hd tcp_hhook +netinet/cc/cc_hd.c optional inet cc_hd tcp_hhook | \ + inet6 cc_hd tcp_hhook netinet/cc/cc_htcp.c optional inet cc_htcp | inet6 cc_htcp netinet/cc/cc_newreno.c optional inet cc_newreno | inet6 cc_newreno -netinet/cc/cc_vegas.c optional inet cc_vegas tcp_hhook -netinet/khelp/h_ertt.c optional inet tcp_hhook +netinet/cc/cc_vegas.c optional inet cc_vegas tcp_hhook | \ + inet6 cc_vegas tcp_hhook +netinet/khelp/h_ertt.c optional inet tcp_hhook cc_cdg | \ + inet tcp_hhook cc_chd | inet tcp_hhook cc_hd | \ + inet tcp_hhook cc_vegas | inet6 tcp_hhook cc_cdg | \ + inet6 tcp_hhook cc_chd | inet6 tcp_hhook cc_hd | \ + inet6 tcp_hhook cc_vegas netinet/sctp_asconf.c optional inet sctp | inet6 sctp netinet/sctp_auth.c optional inet sctp | inet6 sctp netinet/sctp_bsd_addr.c optional inet sctp | inet6 sctp From nobody Tue Sep 16 21:44:00 2025 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 4cRFlj1B7fz6872k; Tue, 16 Sep 2025 21:44: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRFlj0HtSz3cqp; Tue, 16 Sep 2025 21:44:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758059041; 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=9qsqxeoXk1XI+dXczrKdzeNeXE5b8ngAk6nhOXbZdaU=; b=VIRsL+wbypIMOIYIovraFdhlIsReeqoUOhtWCpkyUNQc+zvgxdaBHjl2l7bUSHUC0cIM5/ g3Rk2FIFQHG9KFGXPKHN5JetyjYWYegRBGxbsAm+tl3Xna3I55F8b/5nWNC+P75Fw8h3Ht HtyXZnJCWWfXuv8r7DMyyWOSexmpy+DtjdaAsOBpjYRibjTQ84LEuQHPDKTp6LJNpvsO03 7UdIyVDvIjpYf9zoRoLJPwFP5vzz5rNyfHGXCAkKRZ3n5qo8rKQUIUJgT84WDPbpTX55CO Zg/1y7Pq7tkm14FB9rEesP+5++ZYHROli5vVUomxHl+vqDT3T0BqWa8kdELdzg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758059041; 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=9qsqxeoXk1XI+dXczrKdzeNeXE5b8ngAk6nhOXbZdaU=; b=VqxnvXY3H0GrRSAjEdHa4rqQBakxmAVYNybgKvse7aTfXGIF/qboirSh2InLHN2cxTFKhk ryijyqFZUDG2BJ0zlFm7qzuWq+z8c1DwWNIqeyJ55ueoGKZob8jU1Zmf3Bk7rbu1G11XpH SNSyqqC699JOCjW6lRbYOnaQ7WhZlgAcUWPTAzwHzDiQa6o4lrshTXb+lg3d3dujOlYVdS 7Gl+SRfRCndqIlYm3XsVm0EW+IgoeKyMQBKeI3kqoXhhGwc+1ZNUyL3WC4KM0A4ZhEsSp3 6DoA9heF3a9E9MWlO2hmw8Gld5i/sNSwmDxvT+l3tIF0VCDp3Zy8nIkesdn0ug== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758059041; a=rsa-sha256; cv=none; b=kIf+ngsoWdJs1+oDgWWBgwpEk9Uo29UAGpOx3GSB7R1GUMH8Ck1egsIJEipBl1QQ1wS+05 aThGMqOengS4mOkieJvhzaZq8CahpWuWcwk64hIWSo9aQApAefv84w2uw2Mh7go6oYYrbX 79uWPYcna/OjKkfyRcCD7LTNwdO3AkRfuVD1WkFoQreYTziTz1mz29WCcA/e9xJ+JtJnaD YNacOYzk8zqqAvEpJJqjB+KIpkLXUzeejcazBelfScQr1RwYUGss+QfqowN9EnCHs3wFAi 95QYwXTwMqwGdc53zysk3jOJ1unkql78RY5OEldTrb67pVZK7Gc1yxdn9QK8yg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRFlh6r0Wzxxq; Tue, 16 Sep 2025 21:44:00 +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 58GLi0Vb048345; Tue, 16 Sep 2025 21:44:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GLi0Kg048342; Tue, 16 Sep 2025 21:44:00 GMT (envelope-from git) Date: Tue, 16 Sep 2025 21:44:00 GMT Message-Id: <202509162144.58GLi0Kg048342@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Michael Tuexen Subject: git: 5da388d93917 - main - vtnet: deprecate loader tunable fixup_needs_csum 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: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5da388d93917f5fa74022960cc65452592f71539 Auto-Submitted: auto-generated The branch main has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=5da388d93917f5fa74022960cc65452592f71539 commit 5da388d93917f5fa74022960cc65452592f71539 Author: Timo Völker AuthorDate: 2025-09-16 21:37:45 +0000 Commit: Michael Tuexen CommitDate: 2025-09-16 21:37:45 +0000 vtnet: deprecate loader tunable fixup_needs_csum If this tunable is enabled and vtnet receives a packet with VIRTIO_NET_HDR_F_NEEDS_CSUM set, vtnet computes the TCP/UDP checksum and writes it in the checksum field. This was somewhat useful when vtnet pretended that such a packet has a correct checksum and set the mbuf flag CSUM_DATA_VALID. But this is not the case anymore. Reviewed by: tuexen MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D52546 --- share/man/man4/vtnet.4 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/share/man/man4/vtnet.4 b/share/man/man4/vtnet.4 index 1df79da5f42e..0594ca70e99a 100644 --- a/share/man/man4/vtnet.4 +++ b/share/man/man4/vtnet.4 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd September 8, 2025 +.Dd September 16, 2025 .Dt VTNET 4 .Os .Sh NAME @@ -84,6 +84,8 @@ field of the structure .Vt struct virtio_net_hdr . It also marks the checksum as being correct in the mbuf packet header. The default value is 0. +This tunable is deprecated and will be removed in +.Fx 16 . .It Va hw.vtnet.tso_disable .It Va hw.vtnet. Ns Ar X Ns Va .tso_disable This tunable disables TCP segmentation offloading. From nobody Tue Sep 16 23:11:06 2025 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 4cRHhC36lSz67mC9; Tue, 16 Sep 2025 23:11:07 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRHhB5xqnz3qgt; Tue, 16 Sep 2025 23:11:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758064266; 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=bwy6QxUwmyOJivih1NkUAtK9562qDE88tP0hT/U7SWg=; b=wZKwRm4yptsIzzmMdDuCaJNlw207ftcWHpw3ZOwvooVxcaNbcBbe2WXCQR0mQRxLuJixkM i91cOa17mdMU0Dxl9AA66JPkVZd06y8L02Rgdx6sseei2enNkYOel3V9+nT+TryM6LqPwV RE7YqeSn6NdC4jMLBJrobw/8PkQdvu1/bQdIioTHXtgVmt7Z/cHVY8JLy+d41bpc4yiXWd saEehMMjxwDBvwrO3z9G5oUp9uDDXE4Ll8BSx05y/12QQte0XI3EBYpPhYHze/Mq70pcR6 /HlABGAkprgbacaETqq91f6q+QYtrmSr/bXD8zLAr8jn84bMGkpPVmLcoiOVWQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758064266; 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=bwy6QxUwmyOJivih1NkUAtK9562qDE88tP0hT/U7SWg=; b=S3pmZus3DU+PDe9tZVlmn4PgQ0e4wh1xb+6Cw0LRDo+U5dQz170pOW35D0BQ5yuH9lsBWk QaoTlFcbUH1vo/jh2EmspI0sKX21P6dk/9j6Ulr9xEV7bI59h/CWR6PvGWelkL9S5N4Gt9 G82vj2hodO/zV09r/Ul067MsEEMmS9lyYIZqM1gmOYECYPgPVM+rRg0VMerW9CDM3eXEs4 0Y5c7BZUeiAJmp0vNhr2FZfYRILPf/wD6gRwTq+myyEJk+hp/PItHegzru6pQqKl9qN7Uo fe6t1ItTwpnx9I53winDDpjEIGM/jHbvgvRnklEKfx2x1vwIjEi2d8WP9bmguQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758064266; a=rsa-sha256; cv=none; b=wfUzSiBrzEcZU311Nl9SmRp29c2pz/a5IEFo6l4l7f/ERl81hExGDGNp8Vl/+X/UCuCiuP 9rD+G5SYq2Ani0R7EBiavYhxAyPa2SgCZpTb1K8OsLLPkyiVgtaMCVnWDOvT1PyY0Iz2bP Mixo43wJ2IKnk/rX0/QAzcU0lRG9BylrQ1lDLdjHSZRqUJkoqPGH0QlJFd6M7q89DFs75T UFeuujcp6qXJk4T+54Ll4wwyqKk1MsrZeCWH5zNJzo5h1CqbIJRp2gPIAvO7so8WqevawW ERbckNXkol0pCn1StcOmBQxjS0QGozrlbyjYrEky7VXcDCSgUt85ooClrxyxyQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRHhB5Gfhz11Xt; Tue, 16 Sep 2025 23:11:06 +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 58GNB6fC009906; Tue, 16 Sep 2025 23:11:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GNB6x6009903; Tue, 16 Sep 2025 23:11:06 GMT (envelope-from git) Date: Tue, 16 Sep 2025 23:11:06 GMT Message-Id: <202509162311.58GNB6x6009903@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: 30ad842dd970 - releng/14.3 - Correct release patch information. 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: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.3 X-Git-Reftype: branch X-Git-Commit: 30ad842dd9704cb36ac4f00e90429b39407ca909 Auto-Submitted: auto-generated The branch releng/14.3 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=30ad842dd9704cb36ac4f00e90429b39407ca909 commit 30ad842dd9704cb36ac4f00e90429b39407ca909 Author: Gordon Tetlow AuthorDate: 2025-09-16 23:10:20 +0000 Commit: Gordon Tetlow CommitDate: 2025-09-16 23:10:20 +0000 Correct release patch information. Pointy hat to: gordon Approved by: so --- UPDATING | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UPDATING b/UPDATING index 31f8d97d4762..f118e838c926 100644 --- a/UPDATING +++ b/UPDATING @@ -13,7 +13,7 @@ Items affecting the ports and packages system can be found in and/or ports. 20250916: - 14.2-RELEASE-p6 EN-25:15.arm64 + 14.3-RELEASE-p3 EN-25:15.arm64 EN-25:16.vfs EN-25:17.bnxt From nobody Tue Sep 16 23:11:55 2025 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 4cRHj82nnYz67mb8; Tue, 16 Sep 2025 23:11:56 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRHj75PMLz3rYZ; Tue, 16 Sep 2025 23:11:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758064315; 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=dLbekfPsqF9Osr3Tol1UBHLVHWJcyxZBVB15uNX+akQ=; b=SNMyPRLWqfEUlzKnZ5YW0jL2/OTKTLu/QYEUNXy9rof4ctm4FDl8JtgmYeWWWrmcNKifuG dMM9JalbLNA06CSgrG6MycHEOB835Cn66+TGu5DPAvDaggV+ZjI1D8WR16yv58I+UiNyHy JKpua27qCrE7rqGjphOObXpCYkl54T2iMMNU3UeYx6f1lNtYMA6AQN2drnmfiq43AwEDFD AsGngIUqQba25HZt5O9+v07NyAXKEBwsTCOnmRkmF2h44yPUSNtT+U/CgJ/8StwkDCYjx8 Xh//+0ye4pdJ1V3Nl1K+WQPnLv4F9o4DlkcISrg9mK7xj9WCVJZZg+2b6nh39g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758064315; 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=dLbekfPsqF9Osr3Tol1UBHLVHWJcyxZBVB15uNX+akQ=; b=rd5lWQXF4gEAERp9ikr+6Vz3+bld7owin/YsBqBAJVGeMy9QPCXO8cKDqZmD/y2tsXM21N ViQi6Duo6+FQL5zGuXqZZHt+Dz1Fr9ZyB0mlUGCFaiX5Qtl73fcYiJUYd8yutlEDZRvO06 PZeOH8gDFNwHkWAiIIQgoB6tgtTZ+RanLtVvDSzHJHbSi7njmwPxjnpTc08JrWlVf2A1ba 5+ksb+5Kr5v6TrNSTVqJIzFU5c3WeGzlLMBL0SkQ8f4CJ2oHfZ2dsxmW0qhrpG9D0UEWyQ nokycaqe8yUu0hDnuoqS24SUKCXsMSih8385AXcKkpJcE67bZOLXtzyXgxRy1w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758064315; a=rsa-sha256; cv=none; b=L32LdIzk1b96ZZHqfycWDT+4P/7a2OGvFioHSz7t402m5iJFn4838feEblk3jOHC8p3siL tXnjl7LxSV8iBJdI7Vn6KMaW7d+q5THYS6+TiKYb4fK1PRQq+RUNzASQUWdaFo05eUsxC1 aNXSdWRafC/4x/rW9dPDGY/VwNeZiuZnLDcrgnPSWu20JaISed+XDfwUS9VnFBeBoxnt/+ 2SfZ6uQLeoIy3oSEaqJVtcjezsqM8U8G6K+dAgogenN0YRzdbvYWb6ATekTDIAAqUlZXuy nk2XGmTN9HMojkqvLFDjKgD3NwzIwABp5NRC7/zDI/ERplwXgTucetrbrdbs2w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRHj73W0xz11Qx; Tue, 16 Sep 2025 23:11:55 +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 58GNBtLf013555; Tue, 16 Sep 2025 23:11:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GNBtiH013552; Tue, 16 Sep 2025 23:11:55 GMT (envelope-from git) Date: Tue, 16 Sep 2025 23:11:55 GMT Message-Id: <202509162311.58GNBtiH013552@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Enji Cooper Subject: git: d18058b7b850 - main - crypto/openssl: apply polish to new vendor import process 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: ngie X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d18058b7b850c78f2ca1be746ab411c0bed5acc9 Auto-Submitted: auto-generated The branch main has been updated by ngie: URL: https://cgit.FreeBSD.org/src/commit/?id=d18058b7b850c78f2ca1be746ab411c0bed5acc9 commit d18058b7b850c78f2ca1be746ab411c0bed5acc9 Author: Enji Cooper AuthorDate: 2025-08-22 00:19:25 +0000 Commit: Enji Cooper CommitDate: 2025-09-16 23:11:48 +0000 crypto/openssl: apply polish to new vendor import process This change does the following 2 things: - Makes the build more repeatable by isolating the environment. This prevents bmake from leaking variables into gmake and makes the overall process a bit more robust. - Add debug printouts to make the process more straightforward to the reader and whoever is executing doing the current vendor import. MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D52420 --- crypto/openssl/BSDmakefile | 73 ++++++++++++++++++++++++++++------------------ 1 file changed, 45 insertions(+), 28 deletions(-) diff --git a/crypto/openssl/BSDmakefile b/crypto/openssl/BSDmakefile index bd2bfe0ea033..514c87ae3a8e 100644 --- a/crypto/openssl/BSDmakefile +++ b/crypto/openssl/BSDmakefile @@ -12,8 +12,10 @@ LCRYPTO_SRC= ${SRCTOP}/crypto/openssl LCRYPTO_DOC= ${LCRYPTO_SRC}/doc CAT?= /bin/cat +GMAKE?= gmake MV?= /bin/mv PERL?= perl +SETENVI= /usr/bin/env -i BN_CONF_H= include/crypto/bn_conf.h BN_CONF_H_ORIG= ${BN_CONF_H}.orig @@ -23,8 +25,11 @@ CONFIGURATION_H_ORIG= ${CONFIGURATION_H}.orig .PHONY: configure patch all .ORDER: configure patch all +LOCALBASE= /usr/local +WRK_ENV= PATH=${LOCALBASE}/bin:/bin:/usr/bin + configure: - @cd ${.CURDIR} && \ + @(cd ${.CURDIR} && ${SETENVI} \ ${PERL} ./Configure \ disable-aria \ disable-egd \ @@ -37,34 +42,45 @@ configure: enable-ktls \ enable-sctp \ --openssldir=etc \ - --prefix=/usr - @cd ${.CURDIR} && gmake configdata.pm - @cd ${LCRYPTO_SRC} && ${PERL} \ - ${LCRYPTO_SRC}/freebsd/dump_version_from_configdata.pl > \ - ${SRCTOP}/secure/lib/libcrypto/Makefile.version + --prefix=/usr) + @echo "Building configdata.pm for later use." + @(cd ${.CURDIR} && \ + ${SETENVI} ${WRK_ENV} ${GMAKE} -j ${.MAKE.JOBS} configdata.pm) -all: patch - # Passing `-j ${.MAKE.JOBS}` doesn't work here for some reason. - @cd ${.CURDIR} && gmake build_all_generated + @echo "Populating Makefile.version with release information" + @(cd ${LCRYPTO_SRC} && ${SETENVI} ${WRK_ENV} ${PERL} \ + ${LCRYPTO_SRC}/freebsd/dump_version_from_configdata.pl > \ + ${SRCTOP}/secure/lib/libcrypto/Makefile.version) - # Clean the pkgconfig files: - # 1. Fix --prefix (not sure why configure --prefix isn't honored properly). +all: patch + @echo "==> Building generated files (headers, manpages, etc)" + @(cd ${.CURDIR} && \ + ${SETENVI} ${WRK_ENV} ${GMAKE} -j ${.MAKE.JOBS} build_all_generated) + + # 1. Fix --prefix. + # a. Not sure why --prefix isn't honored properly, even though it's + # passed to Configure; the files might be getting rebuilt + # post-Configure, somehow. # 2. Remove duplicate path in CFLAGS. # 3. Remove duplicate path in includedir(s). + @echo "==> Fixing pkgconfig files" @find . -name \*.pc -print -exec sed -i '' -E \ -e 's,^prefix=.+,prefix=/usr,' \ -e 's,[[:space:]]+(\-I)?\$\{prefix\}/\./include[[:space:]]*,,g' \ {} + - @cd ${SRCTOP}/secure/lib/libcrypto && \ - ${MAKE} cleanasm && \ - ${MAKE} buildasm + @echo "==> Cleaning / rebuilding ASM" + @(cd ${SRCTOP}/secure/lib/libcrypto && \ + ${SETENVI} ${WRK_ENV} ${MAKE} cleanasm && \ + ${SETENVI} ${WRK_ENV} ${MAKE} buildasm) + @echo "==> Syncing manpages (section 1)" @rsync -a --delete \ --exclude 'Makefile*' --exclude '*.1' \ ${LCRYPTO_DOC}/man/ \ ${SRCTOP}/secure/lib/libcrypto/man + @echo "==> Syncing manpages (sections {3,5,7})" @rsync -a --delete \ --exclude 'Makefile*' --exclude '*.[357]' \ ${LCRYPTO_DOC}/man/man1/ \ @@ -75,25 +91,26 @@ all: patch # depending on the host architecture. patch: configure # Spam arch-specific overrides to config files. + @echo "==> Patching headers" + @(cd ${.CURDIR} && ${SETENVI} ${WRK_ENV} ${GMAKE} ${BN_CONF_H} && \ + ${MV} ${BN_CONF_H} ${BN_CONF_H_ORIG} && \ + ${CAT} ${BN_CONF_H}.orig \ + ${LCRYPTO_SRC}/freebsd/${BN_CONF_H} >> \ + ${BN_CONF_H}) - @cd ${.CURDIR} && gmake ${BN_CONF_H} && \ - ${MV} ${BN_CONF_H} ${BN_CONF_H_ORIG} && \ - ${CAT} ${BN_CONF_H}.orig \ - ${LCRYPTO_SRC}/freebsd/${BN_CONF_H} >> \ - ${BN_CONF_H} - - @cd ${.CURDIR} && \ - ${MV} ${CONFIGURATION_H} ${CONFIGURATION_H_ORIG} && \ - ${CAT} ${CONFIGURATION_H_ORIG} \ - ${LCRYPTO_SRC}/freebsd/${CONFIGURATION_H} >> \ - ${CONFIGURATION_H} + @(cd ${.CURDIR} && \ + ${MV} ${CONFIGURATION_H} ${CONFIGURATION_H_ORIG} && \ + ${CAT} ${CONFIGURATION_H_ORIG} \ + ${LCRYPTO_SRC}/freebsd/${CONFIGURATION_H} >> \ + ${CONFIGURATION_H}) clean: .PHONY - @cd ${.CURDIR} && rm -f ${BN_CONF_H_ORIG} ${CONFIGURATION_H_ORIG} + @(cd ${.CURDIR} && rm -f ${BN_CONF_H_ORIG} ${CONFIGURATION_H_ORIG}) - @cd ${SRCTOP}/secure/lib/libcrypto && ${MAKE} cleanasm + @(cd ${SRCTOP}/secure/lib/libcrypto && \ + ${SETENVI} ${WRK_ENV} ${MAKE} cleanasm) - -@cd ${.CURDIR} && gmake ${.TARGET} + -@(cd ${.CURDIR} && ${GMAKE} ${.TARGET}) .include From nobody Tue Sep 16 23:46:02 2025 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 4cRJSV6lRXz67pRR for ; Tue, 16 Sep 2025 23:46:02 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRJSV5dV1z3xc6; Tue, 16 Sep 2025 23:46:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758066362; 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=QQO2nOVwSYrJiaeoV+RlL51hyvPHLu6OBL0ehdXeUfs=; b=Jsz+cAlhh7VSj4ekeNlsRjUp1yr2JQk4VlaW/R1HdNHv+1u7SQEacFyH8o+e3aozpmAu96 lgk3BnW/lOy3G6/y/rDrz8orfAdaNb7rdTJvXAC0Myf2dAvU90+Ao0itYT/QDI9LmQiIoP G8opNYhJewWzfUSf1gjwle/gp2bBERaHPGMJcMRr08L1V4laTOe2lJ0xPzm/VuMTWmTT6q 1gysmYScoi92zT2N+41sRFIn44tQDP2xKw7fD82hbb9YVqT0QKyMBZ2t6hJ66ho+wAzrb6 xJQz6rK8dbgYG6nrkwrJ+oihS+C+Xqh56tR9eOOft5WZDC69S9h6wzfrdUwR5g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758066362; 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=QQO2nOVwSYrJiaeoV+RlL51hyvPHLu6OBL0ehdXeUfs=; b=M+2kneVQGr/InWNpB8giY4r2kbqndojceKQrZoHAGwQ9L6mjLXRpMtmp8KYxlo99ecSxkH 8m5asqkX10TPm1uH++TuLCasGVjPJva0BiY46rb/fJu7hRjMuBtFGmkhI5LeiXkftKoj9i 728J/SaKZHfpGLWjhn8Lb+Vi0Oct1R7DzVQK/1WX1rFjBy8/O7GTpwshQJaZYBgH4Pl8Av cjG0SBpiSvDFrDlONAHmE0aYir0tsAp+h7hqDSH613NfSdrShFnsEr1dOOwuqglIll3X6R wgsiD/5njwl8MXhYjxAwDo3b5rDmbfHqLDMFeO/KiwU06zOzd27PcCd9LdXazw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758066362; a=rsa-sha256; cv=none; b=IoVb/xAgxBsf5neCZF7bHISFXEw4fFXyuPl4Hhn70X36wlNV6JIbUbyt2WW/HiENbGIf2u R37i2tZd8CQIlgKvtY+OAsoK2vhtya7lhOjj1ZHRVEfcIuoVIq82oZIG/QXKBUEw+sCu1h 6gicyNktbUVBMy1/rSZKeO3y0MygSYLgZSCCQraku52SflH2NvJGnt0t3HmxFpT/vCCXib +OXNKmTWN0lnu0SwIBxOK1mA3d8f3DOn6e1JNwO8s2OFC/3eW2XNR3N4bI2NUsXk4TCdSh ao5LLj5+SRsiSXZE60FB2TcKT996yEu/pVMMJvemMNCcJiafqvN+tdzE7wudmA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRJSV4NGJz12Qh; Tue, 16 Sep 2025 23:46:02 +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 58GNk2Fv073101; Tue, 16 Sep 2025 23:46:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GNk2T8073100; Tue, 16 Sep 2025 23:46:02 GMT (envelope-from git) Date: Tue, 16 Sep 2025 23:46:02 GMT Message-Id: <202509162346.58GNk2T8073100@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Enji Cooper Subject: git: fbc35f82f0ec..aed904c48f33 - vendor/openssl-3.5 - vendor branch updated 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: ngie X-Git-Repository: src X-Git-Refname: refs/heads/vendor/openssl-3.5 X-Git-Reftype: branch X-Git-Commit: aed904c48f330dc76da942a8ee2d6eef9d11f572 X-Git-Oldrev: fbc35f82f0eca4571df0d753da74571e01ace763 X-Git-Newrev: aed904c48f330dc76da942a8ee2d6eef9d11f572 Auto-Submitted: auto-generated The branch vendor/openssl-3.5 has been updated by ngie: URL: https://cgit.FreeBSD.org/src/log/?id=fbc35f82f0ec..aed904c48f33 aed904c48f33 openssl: import 3.5.3 From nobody Tue Sep 16 23:46:02 2025 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 4cRJSV6s7Mz67pTr for ; Tue, 16 Sep 2025 23:46:02 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRJSV5ft6z3xTh; Tue, 16 Sep 2025 23:46:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758066362; 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=Dsx3Ilfj8ALq6+at0jCEUe05ZVWGiCwJTREbXNsdQ+Q=; b=AKsZRw0zk4Hhb0nTxybbzLnfgd3KkfgbB4K3kBlB7pcmB2ERfdbDJaS/CwRPFZuNkoJ0W0 zRB6i+Jx9/Z8HpluT23vUsWrP59jrx3OJVf2kLL5a9f5sFMDnzyl6mQEZj01S3AJxGEqY2 QRH6oAeHmyCSWt+SR5VZuY5ExWN4dIKw8RXppsObqTjGkA1YkY2145VuBHmTVQSjuf85SN vYtUvbPAe0PwCuQ5RD9cc11AwJRFn5M92nYTwFkLgkZmq9Gg/75NzFgz706Cco87lpz7xh bRJ8LoYSyzRE2zr8ZegsmpivxBbuUSz9OJlskbl9S0NiaU0+LOOz04wR5Uj0yA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758066362; 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=Dsx3Ilfj8ALq6+at0jCEUe05ZVWGiCwJTREbXNsdQ+Q=; b=xiNtK0pptr1b+/NYabfIulCocTJKcdbw+H/48YqJWyKRa9IoFQGHPGZ8qOqslQWHS/g+f2 sB7U+2cU7epZbAMKcSHwfcE3v/mze/B4FVYCasDuFXhrAq7trrCZIqZYBOPH+HOmtqErFQ qucPdxiFO7R/DLLLkm2jkN50kCHYVbEUi1tnyfSWcdLAuOui34LoYHFYxkb0bWOZu99mVq k7QfMLSySq02jryJfosqgvLdLtmSpAnqZKeSTxYsk8hoAFTfTs2Z6rK4J118gQB33B5jFG euj5JnRRnN/GMemK6BQDbP5aI7S3GBpdD7Bx08PpD9vIasM41pO4bxESDGxlog== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758066362; a=rsa-sha256; cv=none; b=F7pUj7xNpk+19VnkO1601u5GZ902yonk0mh6XOTx/prsNjVw8H/l8cGB7b+T4GKsQu/ESe YZnG+u2NtvuoJ5XAk9RWUMijR538LtWxYwaUekxFa/brDs6/xZvzSt2IyXm9qvZ/MHZ5PJ 6yc76uyLh1YMXS6XdZsBYR5KghJFECT4F8QiKiVsY9cGU5fvnmcThZwq9dRFeU97UcSdMR 9mnRoLsXdbWWy0h7GS+GcTljZGp0yZlwdTQcKHovIeov/7R9s37vqQuFP33RhqIdGRccau apwmyXMm5YytTx2aZT5Y1/cC/7uRNsLuYVH070dW2W6v6Cz3FMalmZ9yIr3b0g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRJSV4lw8z12TG; Tue, 16 Sep 2025 23:46:02 +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 58GNk2Gm073120; Tue, 16 Sep 2025 23:46:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58GNk2gm073119; Tue, 16 Sep 2025 23:46:02 GMT (envelope-from git) Date: Tue, 16 Sep 2025 23:46:02 GMT Message-Id: <202509162346.58GNk2gm073119@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Enji Cooper Subject: git: bc11b5d30cfa - Create tag vendor/openssl/3.5.3 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: ngie X-Git-Repository: src X-Git-Refname: refs/tags/vendor/openssl/3.5.3 X-Git-Reftype: annotated tag X-Git-Commit: bc11b5d30cfa15b1f7939c13c48d75402767931e Auto-Submitted: auto-generated The annotated tag vendor/openssl/3.5.3 has been created by ngie: URL: https://cgit.FreeBSD.org/src/tag/?h=vendor/openssl/3.5.3 tag vendor/openssl/3.5.3 Tagger: Enji Cooper TaggerDate: 2025-09-16 23:45:32 +0000 OpenSSL: tag vendor import for 3.5.3 commit aed904c48f330dc76da942a8ee2d6eef9d11f572 Author: Enji Cooper AuthorDate: 2025-09-16 23:42:52 +0000 Commit: Enji Cooper CommitDate: 2025-09-16 23:42:52 +0000 openssl: import 3.5.3 This change adds OpenSSL 3.5.3 from upstream [1]. The 3.5.3 artifact was been verified via PGP key [2] and by SHA256 checksum [3]. This is a minor release with a single major bugfix to multithreading support with `OSSL_STORE_CTX`. More information about the release (from a high level) can be found in the release notes [4]. 1. https://github.com/openssl/openssl/releases/download/openssl-3.5.3/openssl-3.5.3.tar.gz 2. https://github.com/openssl/openssl/releases/download/openssl-3.5.3/openssl-3.5.3.tar.gz.asc 3. https://github.com/openssl/openssl/releases/download/openssl-3.5.3/openssl-3.5.3.tar.gz.sha256 4. https://github.com/openssl/openssl/blob/openssl-3.5.3/NEWS.md From nobody Wed Sep 17 00:30:37 2025 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 4cRKRx5MXwz67sn9; Wed, 17 Sep 2025 00:30:37 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRKRx4lKmz45bv; Wed, 17 Sep 2025 00:30:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758069037; 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=eMG3VORSaEysI+IxUltq02jbNJQsgl/qIXCS3E+bw78=; b=LdXBwOuX9MWHKEPM+fgkevcxb1wwMqJNmHWtgnBd5weI31R1pm7WYrrzwRbcYkTXVGKRyU G42bZb6mOuNt4U6TSvsxBM+Wt8tGSjcbkbwD9dKdpagw1NetXArgge6MK1lwY8aDl4ejk8 x9ZwvcwmQ+dLcnQxA23kYduiOPOvg5vfczlHyMm/yxpDaj3Z43vWgnlrplQEF/xXMqdN3T sNZ4faodSv7HkWPge+On0ZTtFNvbGhcPsPFz1uBKFGornaieWl1eBalrz/CMdlIaRUJTeo 11c+owkXUBu8Ikv8ODwjSm0cqAiSmO7OR4UnsXpeOa8fyrZ9UVYsmjJMbUKaig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758069037; 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=eMG3VORSaEysI+IxUltq02jbNJQsgl/qIXCS3E+bw78=; b=nbAwKS82z86yU/SunAyuWhYOwael7GZLnlDZ6HSXRV4DWRwV9sr0zDlp7ifPAseWrkqRMa Bc2TSog8HdPXuv1jEj87dBDSVs+ojJvqqNruy6HBNL5hB1LnwwBnBckBw950KduXndl0fL OiAi743FfcRix8q+054WkshcXgqAqX+v8vDmQ7y6vgHLbPX/rtHAp5RakPpmJX9qWdfBLc Kx3xCvhU1bSZG2D4jrAExrUnrxUJWLlupjl01qDovZWWEj9P7Tjamz8NOnJ5Wb2Wha4Rgo OasMrL1kw7coDfhrhuihPPg4C3iWqdRhpVUBVIlWO5VQAQwIbsuY/n8HEJUFIw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758069037; a=rsa-sha256; cv=none; b=uln878pUXiqPRvP+Q3AcPz0y3fOnPvFREb+GSRw4aalHIbUZ1nKzdDdMdw5JgDASV7KcTN GdFTVSugEWEJ4Lv8S/nZVIyZTTZpkqwywxocg2BtT09x7ksefru5IbQGOYsdUBLAEf2qgZ k+GIsJWTinyraMnzNFb8Oq3iYE6vAHRNDLAYP8m8pCneTlEs0e/K+6QqUEuFIL8pojN1uj MJYBmiq9QhY59tnTJXz+TGvbHw2c3enbvSM9BQ2buwbYi44125j+mcGZ/9XGRGHzo8cdd3 PG/8t4lrjvQcKEh0TorrWj5/77qty0I3r11w5ldov+PE9OcigVzRr9tsPzWdfg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRKRx4LjWz13C3; Wed, 17 Sep 2025 00:30:37 +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 58H0UbrM058279; Wed, 17 Sep 2025 00:30:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58H0UbC3058276; Wed, 17 Sep 2025 00:30:37 GMT (envelope-from git) Date: Wed, 17 Sep 2025 00:30:37 GMT Message-Id: <202509170030.58H0UbC3058276@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jose Luis Duran Subject: git: dea1dd669054 - main - pf tests: Add python3 as a dependency 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: jlduran X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: dea1dd66905462e3b65688928dc4016eeae4ce80 Auto-Submitted: auto-generated The branch main has been updated by jlduran: URL: https://cgit.FreeBSD.org/src/commit/?id=dea1dd66905462e3b65688928dc4016eeae4ce80 commit dea1dd66905462e3b65688928dc4016eeae4ce80 Author: Jose Luis Duran AuthorDate: 2025-09-17 00:26:49 +0000 Commit: Jose Luis Duran CommitDate: 2025-09-17 00:26:49 +0000 pf tests: Add python3 as a dependency These tests use pft_ping.py, which requires python3 and Scapy. Reviewed by: ngie Approved by: emaste (mentor) Fixes: 65c318630123 ("pf: Add prefer-ipv6-nexthop option for route-to pools") MFC after: 10 days Differential Revision: https://reviews.freebsd.org/D52589 --- tests/sys/netpfil/pf/route_to.sh | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/tests/sys/netpfil/pf/route_to.sh b/tests/sys/netpfil/pf/route_to.sh index 872de0dcbb91..13b60c8f80bc 100644 --- a/tests/sys/netpfil/pf/route_to.sh +++ b/tests/sys/netpfil/pf/route_to.sh @@ -968,6 +968,7 @@ table_loop_head() { atf_set descr 'Check that iterating over tables poperly loops' atf_set require.user root + atf_set require.progs python3 scapy } table_loop_body() @@ -1032,6 +1033,7 @@ roundrobin_head() { atf_set descr 'multiple gateways of mixed AF, including prefixes and tables, for IPv6 packets' atf_set require.user root + atf_set require.progs python3 scapy } roundrobin_body() @@ -1094,6 +1096,7 @@ random_table_head() { atf_set descr 'Pool with random flag and a table for IPv6' atf_set require.user root + atf_set require.progs python3 scapy } random_table_body() @@ -1131,6 +1134,7 @@ random_prefix_head() { atf_set descr 'Pool with random flag and a table for IPv4' atf_set require.user root + atf_set require.progs python3 scapy } random_prefix_body() @@ -1167,6 +1171,7 @@ prefer_ipv6_nexthop_single_ipv4_head() { atf_set descr 'prefer-ipv6-nexthop option for a single IPv4 gateway' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_single_ipv4_body() @@ -1219,6 +1224,7 @@ prefer_ipv6_nexthop_single_ipv6_head() { atf_set descr 'prefer-ipv6-nexthop option for a single IPv6 gateway' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_single_ipv6_body() @@ -1269,6 +1275,7 @@ prefer_ipv6_nexthop_mixed_af_roundrobin_ipv4_head() { atf_set descr 'prefer-ipv6-nexthop option for multiple gateways of mixed AF with prefixes and tables, round robin selection, for IPv4 packets' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_mixed_af_roundrobin_ipv4_body() @@ -1337,6 +1344,7 @@ prefer_ipv6_nexthop_mixed_af_roundrobin_ipv6_head() { atf_set descr 'prefer-ipv6-nexthop option for multiple gateways of mixed AF with prefixes and tables, round-robin selection, for IPv6 packets' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_mixed_af_roundrobin_ipv6_body() @@ -1407,6 +1415,7 @@ prefer_ipv6_nexthop_mixed_af_random_table_ipv4_head() { atf_set descr 'prefer-ipv6-nexthop option for a mixed-af table with random selection for IPv4 packets' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_mixed_af_random_table_ipv4_body() @@ -1444,6 +1453,7 @@ prefer_ipv6_nexthop_ipv4_random_table_ipv4_head() { atf_set descr 'prefer-ipv6-nexthop option for an IPv4-only table with random selection for IPv4 packets' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_ipv4_random_table_ipv4_body() @@ -1479,6 +1489,7 @@ prefer_ipv6_nexthop_ipv4_random_table_ipv6_head() { atf_set descr 'prefer-ipv6-nexthop option for an IPv4-only table with random selection for IPv6 packets' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_ipv4_random_table_ipv6_body() @@ -1516,6 +1527,7 @@ prefer_ipv6_nexthop_ipv6_random_prefix_ipv4_head() { atf_set descr 'prefer-ipv6-nexthop option for an IPv6 prefix with random selection for IPv4 packets' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_ipv6_random_prefix_ipv4_body() @@ -1544,6 +1556,7 @@ prefer_ipv6_nexthop_ipv6_random_prefix_ipv6_head() { atf_set descr 'prefer-ipv6-nexthop option for an IPv6 prefix with random selection for IPv6 packets' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_ipv6_random_prefix_ipv6_body() @@ -1572,6 +1585,7 @@ prefer_ipv6_nexthop_ipv4_random_prefix_ipv4_head() { atf_set descr 'prefer-ipv6-nexthop option for an IPv4 prefix with random selection for IPv4 packets' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_ipv4_random_prefix_ipv4_body() @@ -1600,6 +1614,7 @@ prefer_ipv6_nexthop_ipv4_random_prefix_ipv6_head() { atf_set descr 'prefer-ipv6-nexthop option for an IPv4 prefix with random selection for IPv6 packets' atf_set require.user root + atf_set require.progs python3 scapy } prefer_ipv6_nexthop_ipv4_random_prefix_ipv6_body() From nobody Wed Sep 17 01:02:49 2025 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 4cRL956DGyz67w0M; Wed, 17 Sep 2025 01:02:49 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRL955W8Vz3CTJ; Wed, 17 Sep 2025 01:02:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758070969; 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=OvIvCaZGw7t5VF8hncxdWu65/hz6pkmCB1Bh/BUFXhA=; b=gkxPcGzsK+4YcPD4A+rxPnUeW6yKVlQj8jyHr1Zw0lkLiA0lhR4si5262M+8c0BK4Vfzls Cy0ZD+pp+VV5oerohJKf7U3Woh5vOHFvPwT2utQeRYHFYKgFCeGyRcHiVWg3Ydn5hVHved HpMeCXASo/b3qZuNTX07rgSHNprr7h83HCeOP+Nj2xQlSTyWdXCM1bRWmHfh4Of6pZizNw J1M7oLnZ6Jn27VlpA4nzjmfc1fXGZ24mKhKY1NhFuIwKBqUieo66KzWuAyonP2II5gOm6G hbfZkUyHqu9DDjLRLNc2fStk7HwTb1eKmSPV4EE20f439OTU8FcIxgmtjZ99Ng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758070969; 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=OvIvCaZGw7t5VF8hncxdWu65/hz6pkmCB1Bh/BUFXhA=; b=uLXn7xNd1vtukUawhxsPCgiid2N1rZ/1NvmfOM7KqmAPrRZ5NHozeynMYU8UPNqtqO33gV VTFDtGhkRMaHBAQe1M1lTaSxZ2X1umyaQ/oepp0VqdDeK0Y9tCBxBpW/XjqmJqKWDbiuV1 PIcXqLiavuzbkXvhJOqU6p3kOZwNp1Ug31xVkxt9cABAOzANvY/zma0IsBq79OFckhGVs7 /mNHhC6E+alZWVwPzXW2za7SMgYNFNlfO+ALgkDFimudU408BvnpNihc+rg/NCajwPntc+ hp5d2aEQIYUCtVariZtp6y81ZSMzIpNt8le2u1820haUmeAJwxXXtrq7hHz0JQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758070969; a=rsa-sha256; cv=none; b=Fedrmi11uwp8J9fx4CHpKCLvdoDeMRrNRtN7uTrJkmdjYud9H0P7IVWZT2heTsSUm/rrFK HB6QerWnfVHj6z2voKpIR3AZLwMKzdclw/ENEu3luKx/0QYg3C6S/vIJLmP9p9YOpyFkVS 9v8CWVYWboXVjfi9xRfavHL2iXa2OI2p7+y1iTBkuLlrkAc3+g+ghxA1M52rUYLV22YQu9 /JR6BgvutLSjLGMDVFu2tv7h/h6vvA7kRqKgb4K21rtuEcwnKeQavjQy7YVhuidLms9TpN a2vudGtbNy5CdmH819pUZda4U29NXOpj7mgT5QMjR8WPxnfqHl47odKQKUOwOg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRL9554rHz14S0; Wed, 17 Sep 2025 01:02:49 +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 58H12n1V023035; Wed, 17 Sep 2025 01:02:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58H12n6T023032; Wed, 17 Sep 2025 01:02:49 GMT (envelope-from git) Date: Wed, 17 Sep 2025 01:02:49 GMT Message-Id: <202509170102.58H12n6T023032@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: f9d8f808b23f - stable/15 - src.conf.5: Regen 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: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: f9d8f808b23fb9f4ee257e0ed78ddc4fa6882967 Auto-Submitted: auto-generated The branch stable/15 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=f9d8f808b23fb9f4ee257e0ed78ddc4fa6882967 commit f9d8f808b23fb9f4ee257e0ed78ddc4fa6882967 Author: Ed Maste AuthorDate: 2025-09-08 14:57:17 +0000 Commit: Ed Maste CommitDate: 2025-09-17 01:01:05 +0000 src.conf.5: Regen --- share/man/man5/src.conf.5 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index d251bf0cd9e7..648249148817 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -1548,10 +1548,10 @@ Do not apply the Relocation Read-Only (RELRO) vulnerability mitigation. See also the .Va BIND_NOW option. -.It Va WITH_REPRODUCIBLE_BUILD -Exclude build metadata (such as the build time, user, or host) -from the kernel, boot loaders, and uname output, so that builds produce -bit-for-bit identical output. +.It Va WITHOUT_REPRODUCIBLE_BUILD +Include build metadata (such as the build time, user, and host) +in the kernel, boot loaders, and uname output. +Successive builds will not be bit-for-bit identical. .It Va WITHOUT_RESCUE Do not build .Xr rescue 8 . From nobody Wed Sep 17 02:45:45 2025 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 4cRNRs2sFjz684gx; Wed, 17 Sep 2025 02:45:45 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRNRs1w40z3RKc; Wed, 17 Sep 2025 02:45:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758077145; 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=cqNAOQkC7+WJhQyQPGK/19QQ8KrvBBYJGQD8xM71QtQ=; b=VV6zxpDUvdsseJilgoY3kpx3I0ST4vKjClstrp3uFVbO3J+lVHCJulzqrAkujqxqB9Ve5x Wg9DyaEfFJ2Eh2L3NV5hkW4XzgUUzieCt9hkwebIUmTCnpcvRu/obDl5NaUIOUrKEHF0qc fQbrKX6yjXAjYjUwxePEefH+l+YFNlWpzhDWJmRiHWYuielRQ1MGuXEfpaieIqnpVw73Rl j3cWhzF90+yBXxaglzJUlxw0GhbqfiKyeGdKOL7LwzSJDQ3N882/lo2eZ32TeukkHUq/8W 9lfgrB9AA1+Se4M3TBKkrLWGRIicO6xhmOvj+FXmGTSixenTpYeGZ1/Nul2Ghg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758077145; 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=cqNAOQkC7+WJhQyQPGK/19QQ8KrvBBYJGQD8xM71QtQ=; b=MMxibLweR8N7bz/92HN8CK+WUy2vIKJ4Qehtm2Hkpu6/6596dDSO4ZzvlPl28qw+LjQyjd JKciZS3/x9tbVPrIRey+HHTJ7/FZq/8vG3uDI9mH4gb4Y2QHkZySUDQL1lqNsNGaCgwt7J 1baNlLZ16pnRijYlCqvItK2GUIyB0SVWH0m0ilITKHVrHdRl+CT30BxShwDAoFeRNlefbb fD77HXKD2VkaisVprklHMUqLlNSAbigjsAnskyi0/Tda8LZxhE/0ne36StHAff/Lf0Q6jo a5J10b0PJ+cM/cnQm+DE6gh1boRBz88DedDE+4Mmh5OyIb97rsK52+EEG532uA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758077145; a=rsa-sha256; cv=none; b=LfSDbMwBUmwn4NSxzN6WrRCppyG8pIkI92KSW61ykAqvq2GyAeh06sfyfKjXphRBMi2U39 dH8ZUr/PMc+E87oAlfHvVhcdou6m9wp/8w+Pzt+Grdcfa3tBJJRSxWHW5oa6RBNEGmJ4T7 hyCOKknxqRsrIgyTjAeAFsssAgBSpNiMeFOZE/4JK/Z5+XWeQKqXj9l+3D+oa+EvMT6My+ 9vI+qB2iO5ZqSSc2/LaHomFPpI8LvKVGMbbabxDHxBjNXWe0xGoxyCSbtgEpi5nR1pIYBj pBnafTcrizL80gG/MSvjUTMDBsNlOeiv4zqX0A6Gh568nfykgEtYvJG9cWpTyA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRNRs1WNVz16jl; Wed, 17 Sep 2025 02:45:45 +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 58H2jjhU009326; Wed, 17 Sep 2025 02:45:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58H2jjOe009323; Wed, 17 Sep 2025 02:45:45 GMT (envelope-from git) Date: Wed, 17 Sep 2025 02:45:45 GMT Message-Id: <202509170245.58H2jjOe009323@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 37de183f06e4 - stable/15 - release: CLEANDIRS += pkgdb 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 37de183f06e460901eda3418427569e65e74b7a7 Auto-Submitted: auto-generated The branch stable/15 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=37de183f06e460901eda3418427569e65e74b7a7 commit 37de183f06e460901eda3418427569e65e74b7a7 Author: Colin Percival AuthorDate: 2025-09-14 02:04:01 +0000 Commit: Colin Percival CommitDate: 2025-09-17 02:45:26 +0000 release: CLEANDIRS += pkgdb This directory gets created by pkgbase-stage.lua. MFC after: 3 days Sponsored by: https://www.patreon.com/c/cperciva (cherry picked from commit fa9ea99be6fb416cd0528e6a54053363775abe00) --- release/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/Makefile b/release/Makefile index d0177c8aae5f..d67bbb774062 100644 --- a/release/Makefile +++ b/release/Makefile @@ -128,7 +128,7 @@ CLEANFILES+= ${I}.xz .if defined(WITH_DVD) && !empty(WITH_DVD) CLEANFILES+= pkg-stage .endif -CLEANDIRS= dist pkgbase-repo pkgbase-repo-conf ftp disc1 disc1-disc1 disc1-memstick bootonly bootonly-bootonly bootonly-memstick dvd +CLEANDIRS= dist pkgdb pkgbase-repo pkgbase-repo-conf ftp disc1 disc1-disc1 disc1-memstick bootonly bootonly-bootonly bootonly-memstick dvd beforeclean: chflags -R noschg . .include From nobody Wed Sep 17 08:08:49 2025 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 4cRWcd54Dgz68SZ4; Wed, 17 Sep 2025 08:08:49 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRWcd4Ntrz3vpQ; Wed, 17 Sep 2025 08:08:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758096529; 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=oRv27sr61hcEWuJJ2qJ1bXP/b0BJp5aCuOC+QzC7jj0=; b=wxHbAngYDZ4fpsJza34mFPw2tHnDp4MOu47NZCbzy4tatYKRqGJr9p12kdWn1ZPgtrhNTf rEFwVk18Ve1h2NbB9Nl9ZRG3OnZa/C8qkN8TJRlo/kZzcBpfXuh8CT6DsC4Tr1P3jSjf6z WlwSj01J8ENnhQit0OFR6cbRhghKZlKD6CA5W1Arat8WNTnoZvc4b8b8by5NSlD6x46ysm hXp/VnXwauMSWtq6WY2QIxZZKau3MJ0GzUpe4Yswm7eMwQHxhBHtna6ExpoA5zaYPLkNS0 2HNJ7RMEXArN6VMpyCB4veQJxd5VjnyC9j65ziNOCQ9wpiyGcLfFFe4Tc4aTfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758096529; 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=oRv27sr61hcEWuJJ2qJ1bXP/b0BJp5aCuOC+QzC7jj0=; b=TNU0ivFY2RYXfSSLcTyaE5K7SyIO1YEWE4iH7omsBvTIBZIuzIiensPtsjLDVL0qekWLPo uDyhGr0oF7jhxCpkOSIKZjyo9RJYvxjq0C+Xb9IlsVCBg5j7n+7HSArfYwyvACgKzusqzD 6J4uydwJZZ//lvJ2kWM78VhRMPEySsOly1O9aB2oowEEMUzgLjeU1AJcSqwL1U4QRklM5c snpV83ExpNVn/hHOSbp04Ad13Unaztpfn3et4N6kAFLCaN/PhBh/WzAJkpafYhzbgCa1aE AF/W2Y4EUxptuv2+5cix8PlYRIw6nuIart/vDo5m2PPTJB08ljuiaTSn9YuMTw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758096529; a=rsa-sha256; cv=none; b=OQg5rioV2ugVP+Ull+KUwmr+agBpv9/OQ9V3Io3CsC6v5sj6HA0Za4NqhHZhfPXGadRMAL xDNKsrmouTfuLrshPNRfXVVwJP8DQRJY/SyT3Y6Ti6EgRRJdyBThLXfVeq0J/uWX71LpET h1mf/RwteYRbn43yuXL1igtpKNGpnmUXdmVBOBJg8orSc0Y4CNfwjFNNZT092SOohRmzsZ 9p7DNGb9E2PJqzeZ0tfpa9HNNTF7ceuypsksHbRyvIG936BUsIoPC8b+srHk9YuNFJxU7L xRfdcecQK59+JPa+K+vWJSN9AW1Ha+SHw86hThj7G6rhRPCI6BS7ZVaBHL1UPg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRWcd3dSvz2tj; Wed, 17 Sep 2025 08:08:49 +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 58H88nnQ013738; Wed, 17 Sep 2025 08:08:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58H88n84013735; Wed, 17 Sep 2025 08:08:49 GMT (envelope-from git) Date: Wed, 17 Sep 2025 08:08:49 GMT Message-Id: <202509170808.58H88n84013735@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 6e00a34c7613 - stable/15 - ifconfig: also fix removing IPv6 addresses without netlink 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 6e00a34c7613e02994e1caf4539e7c8f76992b95 Auto-Submitted: auto-generated The branch stable/15 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=6e00a34c7613e02994e1caf4539e7c8f76992b95 commit 6e00a34c7613e02994e1caf4539e7c8f76992b95 Author: Kristof Provost AuthorDate: 2025-09-10 14:55:56 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 08:08:16 +0000 ifconfig: also fix removing IPv6 addresses without netlink Reported by: bdrewery MFC after: 1 week See also: da50f49977cc4e6aae55cb2379313599249a8dd2 Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit c8fb5a4d032b28dd97b9fa4a73f85a84d8d35fdd) --- sbin/ifconfig/af_inet6.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/ifconfig/af_inet6.c b/sbin/ifconfig/af_inet6.c index 7986edf490b4..e0f34f0c4d82 100644 --- a/sbin/ifconfig/af_inet6.c +++ b/sbin/ifconfig/af_inet6.c @@ -753,7 +753,7 @@ static struct afswtch af_inet6 = { #ifdef WITHOUT_NETLINK .af_difaddr = SIOCDIFADDR_IN6, .af_aifaddr = SIOCAIFADDR_IN6, - .af_ridreq = &in6_addreq, + .af_ridreq = &in6_ridreq, .af_addreq = &in6_addreq, .af_exec = af_exec_ioctl, #else From nobody Wed Sep 17 08:08:50 2025 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 4cRWcf4hcmz68SZ5; Wed, 17 Sep 2025 08:08:50 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRWcf369dz3w9B; Wed, 17 Sep 2025 08:08:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758096530; 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=wDUEv+M/GsuZLiF6TNFhcDGJZt9UuASzXLzS5gl268Y=; b=DXzn49KpS1OiWb0WHd5quf0O2UKqjVVipIigGDWpJtrHXyKfktcQF6KtZM2+afehMCNBBi Pu18koI95B069MLLv4ywpWWDhikaqB1RHpd61O4+4XKMh//+ONGBW+gBbE0Xb0/ARa13tI mCFBRjYsHhAQUmITFUBFKVOOkm5HquTZX4h6dGc9TUnAlwpreDf05pGt/Jh0YOLScrQrjB K4n4EFmQNJcP5S5aiaYFv30b/S9lHibUrrQq5ungCJi3fWLn9d5+gd503unHEuzmdn4+ti W7Gf58LiIPZHZ42fUJ5Vl2lpCkzj70FoayS6R3J33EgRaFTWZxJw9YGhWT9Cfg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758096530; 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=wDUEv+M/GsuZLiF6TNFhcDGJZt9UuASzXLzS5gl268Y=; b=RteM2nFAPHEtJ47FxQ7cxcoTTm5dG6tS4lHJry8M/d6xE31FH0Wb0u89gnxk/g/+EWf5Nd 36JStKoRTnCU4FiLp0Fq4wVgibj58pvAKXfTkx3vGuibcXUl39UH7QY8cgXVYEgWokHl6j UCvphGMXNgoVzIq+Tn2DlkOpsEzYh3K2FF7cwSPlvscQEBhtx94lbmNzUUnG3wu4fvkFoC M53NABSlgwkeYOLgzLcUxV7xTEhiHCuReU2iGrjINpInALXVSMDgnpgX84qxyjzavEUmKa nxg7bD6ngUwCWtxYcfXjBur3fuQmnh4DVUT+ax16aphuVNdjuSUYIy8XFYqsbA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758096530; a=rsa-sha256; cv=none; b=aAIE8yclOlsK5gk+HykmTfxC7IjSlyudPF2XKIt89EDB3311UwQ94+p2/X4989qxDXGrEX fWK09eNgYafs5CspqM3Nlh4QameQ51iqgxEnO6b5ZT9RE9lG5JrtJk3BEFswFWvvXBcKDC W53BjVDmIm0vmA1fZbB4ndToWHht5Hvdy/YBI9rc+kKrPqqwXMtpcSpNho689+rS1T3BQD +DuDr+IQ7YWb+2PUHMwZE4Ci5fTgRp+9DXcAACXOO1IDSVqjhdUl4OzwaZyFDtaBjpGpCM M9kVbtjRBmWEBBKnJm2btNm2WEUG7wbrEjhq3bV6BQUNNy3mxoSkdV5Vu5DSow== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRWcf2RLRz37g; Wed, 17 Sep 2025 08:08:50 +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 58H88ohc013828; Wed, 17 Sep 2025 08:08:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58H88o66013825; Wed, 17 Sep 2025 08:08:50 GMT (envelope-from git) Date: Wed, 17 Sep 2025 08:08:50 GMT Message-Id: <202509170808.58H88o66013825@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 44d7a8298eae - stable/14 - ifconfig: also fix removing IPv6 addresses without netlink 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 44d7a8298eaee9df45b786176d5d85a37e095c94 Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=44d7a8298eaee9df45b786176d5d85a37e095c94 commit 44d7a8298eaee9df45b786176d5d85a37e095c94 Author: Kristof Provost AuthorDate: 2025-09-10 14:55:56 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 08:08:33 +0000 ifconfig: also fix removing IPv6 addresses without netlink Reported by: bdrewery MFC after: 1 week See also: da50f49977cc4e6aae55cb2379313599249a8dd2 Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit c8fb5a4d032b28dd97b9fa4a73f85a84d8d35fdd) --- sbin/ifconfig/af_inet6.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/ifconfig/af_inet6.c b/sbin/ifconfig/af_inet6.c index 17dc068ee875..7aed391c7bf5 100644 --- a/sbin/ifconfig/af_inet6.c +++ b/sbin/ifconfig/af_inet6.c @@ -753,7 +753,7 @@ static struct afswtch af_inet6 = { #ifdef WITHOUT_NETLINK .af_difaddr = SIOCDIFADDR_IN6, .af_aifaddr = SIOCAIFADDR_IN6, - .af_ridreq = &in6_addreq, + .af_ridreq = &in6_ridreq, .af_addreq = &in6_addreq, .af_exec = af_exec_ioctl, #else From nobody Wed Sep 17 09:15:20 2025 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 4cRY5c0YqFz68X7v for ; Wed, 17 Sep 2025 09:15:32 +0000 (UTC) (envelope-from eduardo@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRY5c01fsz44r8 for ; Wed, 17 Sep 2025 09:15:32 +0000 (UTC) (envelope-from eduardo@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758100532; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=o0H85h62G9nAKEnq/c2hVYQbUAiRHhg5GO2xb0VNm8w=; b=Rwks6U5NY0E/3Npax8S1w6HF1TS1Hy8G+MUEo6jGeXXQQ+s+FVHP0bv09tYKH/8HWUU4fd cNLqtTZ2sd3Drbcrr+OPk20Bg9jSqB7eV5CVb1+Wn0Vp/T6CiLOusGjTQE7vfeTmi4Lxlk oHQDl9q/sw13kq5KUb1vEfMBi7gjqzEMbj83kKjoqTT1S8yL4OzfIvhVX3MchoaWjEqEVM A72bvPvEbRHMUt2R3tkEcxkCdFqPIS6gFt4qPh546l60R046/ZEWu24JNMPk7VTQ0+oAr5 rs2eBi6WnKc6Q4OU21OQKHQvUAojmWGeXPcnC2kMWmYlzpKTAlL2c301ajbM5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758100532; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=o0H85h62G9nAKEnq/c2hVYQbUAiRHhg5GO2xb0VNm8w=; b=CsyGa1NFolrZZEfItsmTPkchcMH3R3RqkxeXVjD3oLkaQRQPr/6WwxicKqq+LnTCzKNG2w YOxld4ECgLO5Gk8ndPAU4UsMsPg+AYg2eRKQHgSgtpVqG6nalDYTHYmKYllQwNHDEA7emI br9Yrfb8hR30XwcgQnt8ctPaQve8O3F8XGX7VB/DhgQL4ukYxGvAWvFbHj+IrYQ3H8hMJh vh9Z8BCOgzb+ukDdgEkvpBFLF/2H6FcGpfUi1eiv/zta1WITURbsR+0eUP96a6lPwAIm6c IWamKo6kySTgExOU55EmwHhN7z1GfyEiR+Y0DFBua6ZvNI0iKzLpUd4fQ6FK2w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758100532; a=rsa-sha256; cv=none; b=Q8Dj+V7WMO14sAQgRdmKjW9xGg8tNdAcBXmU6y85kCi9m6aPKe5VcxbAupm2W8xwA1pbT3 WZxlnzU58wBXYYMDbzOXqJ1ITLMC9RBDCO9DA78YLWkVEo0z1Z9ohWubv4ypUE8g3g0NqB pb8CvmNyokZGe17g8gPzWVCmXHi9Lx9En3lzIvtp4murc7l+yAVJnjivOBgn9fq/38bAP2 GfS7I0vWK+j25mxvpJTq+tVSR2ENr5ZfBv8UTb3pt7QTlZ06hN371v1vsTDcjPPb+w+8yj qxag/HPUSyymtxA+2hDdaPLNMVWplefDSNC3lciJoynJ3hj/k+ic+4HMyJUTfQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from mail-qv1-f43.google.com (mail-qv1-f43.google.com [209.85.219.43]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) (Authenticated sender: eduardo) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cRY5b6Nl8z13wj for ; Wed, 17 Sep 2025 09:15:31 +0000 (UTC) (envelope-from eduardo@freebsd.org) Received: by mail-qv1-f43.google.com with SMTP id 6a1803df08f44-7482cb1d520so4793536d6.2 for ; Wed, 17 Sep 2025 02:15:31 -0700 (PDT) X-Forwarded-Encrypted: i=1; AJvYcCW4ZIBTuKnx2/eBlmTmrAp2PsR1/T7INScQIxLZBDOa8t0PQAmaG5xDDm84SSMJPalbFNGIxYnddEl/CmB1QXIkhTrU@freebsd.org X-Gm-Message-State: AOJu0Yy1LhAoC5euld/iNn7L/w/V/80imwsfjNNNp+T9z6FLo3/d3lC1 dL6q/H9LWfAkVVI9KbDDA8cYFJdjo5D9gmSVHbR37CwDbya839hukFr4PidK/aeeNaW4O/U0H+f QuvK26FFm8OebixM/DQkw7PCCi8c6HK4= X-Google-Smtp-Source: AGHT+IG13M7jQnVToRFUUP3+M6NxwluXFIWP1ChGOSL6BZG0pG6qD+FV7ATicRegDnHxS9Ut0rDh4q3RX7e2GR3zX6g= X-Received: by 2002:ac8:7e8c:0:b0:4b7:94f1:7722 with SMTP id d75a77b69052e-4ba60c82cd6mr11394171cf.0.1758100531311; Wed, 17 Sep 2025 02:15:31 -0700 (PDT) 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 References: <202509142159.58ELx5Rg054606@gitrepo.freebsd.org> <20250916050239.4BB672D5@slippy.cwsent.com> In-Reply-To: <20250916050239.4BB672D5@slippy.cwsent.com> From: Nuno Teixeira Date: Wed, 17 Sep 2025 10:15:20 +0100 X-Gmail-Original-Message-ID: X-Gm-Features: AS18NWBkt-Y3o1WyTD4nOBmEqcSG1CJesuiUXfYDjNz_uzsgDSKm836BsZyPo8E Message-ID: Subject: Re: git: e779891327b1 - main - sys/power: Sleep type reporting by PM backends To: Cy Schubert Cc: Aymeric Wibo , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: multipart/alternative; boundary="000000000000a5fb86063efbad41" --000000000000a5fb86063efbad41 Content-Type: text/plain; charset="UTF-8" Hello Cy, One of this series of ACPI commits has broken power management on my > machines. > One of which managed to capture a dump from a kernel panic after > poweroff(8) > was issued. > I can confirm same crash on reboot on a Intel laptop, after upgrading from main 2025-09-06 -> 2025-09-16. Thanks, --000000000000a5fb86063efbad41 Content-Type: text/html; charset="UTF-8"

Hello Cy,

One of this series of ACPI commits has broken power management on my machines.
One of which managed to capture a dump from a kernel panic after poweroff(8)
was issued.

I can confirm same crash on reboot on a Intel laptop, after upgrading from main 2025-09-06 -> 2025-09-16.

Thanks,
--000000000000a5fb86063efbad41-- From nobody Wed Sep 17 09:27:25 2025 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 4cRYMK4wZJz68YC4; Wed, 17 Sep 2025 09:27:25 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRYMK4MMTz45Mg; Wed, 17 Sep 2025 09:27:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758101245; 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=2kM6zxUYp2kxLV6DsEgvxHPStyl+nattae2VMc5BdOg=; b=g23IeYDFKy0W+lgskxEoP/G5a/Q9qOMeqnqkgcnZuDGQpddzoVbbUVLx4TpgPhoZH2bIZE ygSFahboLHXdoNQj2axQaLvuJuPbDDMab/j6CcfvSOrXGhPQ6YASBebdqy/Gh9W+xaxqLF q1Wzhk9SbD+UHdU4JFsO67MOAM7STFs2RgJm66Jd21vNlpxJLaFAMdDhqTbHnW1mVbhn69 OgnSIyoOgbAfTjRVBBBZDnZ55Sb5egRV02lXEG/UzVhZgZ5eEk0qzlsJZLO7YnEeZj8zoN QRD8ZSB8YCF0LoOcKI6PZjVi2bPeaQc2wUW7ef+tacNb1BUBUAGtNTvYXnihFA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758101245; 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=2kM6zxUYp2kxLV6DsEgvxHPStyl+nattae2VMc5BdOg=; b=TYPUkD6HNPA9HVrUpIa2fZ9bGA8+B30obXuqH5zMLIGpj2oVsXCI1b0aWBHNxZCuVpgHs1 g4DIp1Ki1e9YSE/H+hL5Vr393E6k7UC81IzcX6LfxTBvyXQZIQ7tSrcj43C+R3BRtEOnFd luebV6GC/SPa4mgcx35PhFBhfuBtxU9IMY8Xfe83MtRXOn6t9JVdUaPzISNz/5APYba2ti 8cVoAVTsZxRxeiEe7/IudAUns9XuhKq/FetEDtWkXWra2Zr47Q9e/CC8hsYkUVQPHoLfpF M+hWbPA98dO1E2PLBSoaLTXoUva5VO8dDQBLjyf3MyhbkQa9Qkt+nWV6h0yK2g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758101245; a=rsa-sha256; cv=none; b=IOjbV2jCSYNpr3bRhyhxULyPCrCqEPNtA8m/nKdAq6Zfdybh/vV5jX/Vh0rG5B50qbkx+S grm09+a6Dwc4p581sGKaK7EQq+E0ctorFA5xlLGpkBo0Ej5Xo/d3ZwrfMKy9pE7OL9DrKo mrfv7ZF22I3InEd+koeNfqA85oUfqlpTAPksKgQ4Ct+jXGHE+VI0d7JPrLOJKzJ3lilDvy XJKkk0k4OQpHb98Mx/ucmhSHfu/aK4WRnEcu+gNP0UcVJx8uk8JENdeTIBvD5YJL01xnCu kaAxWN3pdtPfXiFRvv1znE6wk6Fljl3AcmRhKGC/8YjqUmeBqC8GYHl7CiC/zg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRYMK3xKWz4Cn; Wed, 17 Sep 2025 09:27:25 +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 58H9RPMC064604; Wed, 17 Sep 2025 09:27:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58H9RPVk064601; Wed, 17 Sep 2025 09:27:25 GMT (envelope-from git) Date: Wed, 17 Sep 2025 09:27:25 GMT Message-Id: <202509170927.58H9RPVk064601@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: 0caba7093871 - stable/15 - sound: Honor CHN_F_NBIO 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 0caba70938712aab819b6a8761f366ce804b3b22 Auto-Submitted: auto-generated The branch stable/15 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=0caba70938712aab819b6a8761f366ce804b3b22 commit 0caba70938712aab819b6a8761f366ce804b3b22 Author: Damjan Jovanovic AuthorDate: 2025-09-15 17:42:41 +0000 Commit: Christos Margiolis CommitDate: 2025-09-17 09:27:06 +0000 sound: Honor CHN_F_NBIO If the device is opened with O_NONBLOCK, even though we check for it in order to set CHN_F_NBIO, the subsequent chn_reset() calls will clear all flags, except those set in CHN_F_RESET, which does not include CHN_F_NBIO. Add CHN_F_NBIO to CHN_F_RESET. Additionally, because primary channels can be reused, make sure we do not unintentionally keep CHN_F_NBIO set if the channel is re-opened, but without O_NONBLOCK. PR: 289441 MFC after: 2 days Reviewed by: christos, markj Differential Revision: https://reviews.freebsd.org/D52493 (cherry picked from commit e8b5025c3880b04c1c2139fe73b65fbd6deb41d4) --- sys/dev/sound/pcm/channel.h | 2 +- sys/dev/sound/pcm/dsp.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/dev/sound/pcm/channel.h b/sys/dev/sound/pcm/channel.h index fab182b22774..9ad21d219001 100644 --- a/sys/dev/sound/pcm/channel.h +++ b/sys/dev/sound/pcm/channel.h @@ -408,7 +408,7 @@ enum { #define CHN_F_RESET (CHN_F_BUSY | CHN_F_DEAD | \ CHN_F_VIRTUAL | CHN_F_HAS_VCHAN | \ - CHN_F_VCHAN_DYNAMIC | \ + CHN_F_VCHAN_DYNAMIC | CHN_F_NBIO | \ CHN_F_PASSTHROUGH | CHN_F_EXCLUSIVE) #define CHN_F_MMAP_INVALID (CHN_F_DEAD | CHN_F_RUNNING) diff --git a/sys/dev/sound/pcm/dsp.c b/sys/dev/sound/pcm/dsp.c index aa6ad4a59778..da38f52021ae 100644 --- a/sys/dev/sound/pcm/dsp.c +++ b/sys/dev/sound/pcm/dsp.c @@ -299,7 +299,7 @@ dsp_close(void *data) CHN_LOCK(rdch); chn_abort(rdch); /* won't sleep */ rdch->flags &= ~(CHN_F_RUNNING | CHN_F_MMAP | - CHN_F_DEAD | CHN_F_EXCLUSIVE); + CHN_F_DEAD | CHN_F_EXCLUSIVE | CHN_F_NBIO); chn_reset(rdch, 0, 0); chn_release(rdch); if (rdch->flags & CHN_F_VIRTUAL) { @@ -323,7 +323,7 @@ dsp_close(void *data) CHN_LOCK(wrch); chn_flush(wrch); /* may sleep */ wrch->flags &= ~(CHN_F_RUNNING | CHN_F_MMAP | - CHN_F_DEAD | CHN_F_EXCLUSIVE); + CHN_F_DEAD | CHN_F_EXCLUSIVE | CHN_F_NBIO); chn_reset(wrch, 0, 0); chn_release(wrch); if (wrch->flags & CHN_F_VIRTUAL) { From nobody Wed Sep 17 09:27:47 2025 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 4cRYMl3JZ4z68XnQ; Wed, 17 Sep 2025 09:27:47 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRYMl2N4Jz45kb; Wed, 17 Sep 2025 09:27:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758101267; 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=626fU9AlD754Zl3eFVG5Ch2Tffn/ZiMajzGGvXiOEQM=; b=O621bn+/XmkRrzF5KefudnyeCa92JFW5l/YirpQetCbWHaUd7D4hmroYwWGdrjlHKGb3T2 sNXMIsycSvRT80zfHwt48ed+znF/qgZkoC84eQyepOqVX2l/fCp8jmq8Z7gMp8pJcOFUHA 3CH3flogBapU2TuM0zRoZC6HHz1dOeR34ke2p4bXJ3ZM/sj69YsXobG32HkhqIjOsQKFi0 neP590DuqVmiXPScbDj5QYv6BdWu3C+9n5CuDwAL2gg9qgIjFLDxJJqlviSjJFf6ouj3nO anUVOW0SYkl22rs4ZpBTUGY98EItrmxPwHVqCqaj3pncNBj2tnOBXbPEl3W7uA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758101267; 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=626fU9AlD754Zl3eFVG5Ch2Tffn/ZiMajzGGvXiOEQM=; b=b96JYH6kNEUYCb0kfHEdq8/qJtLHC5GDXc6mAWCyrllIKVE4dYQNTyFJ2Wg/YCFsuKoRoc 0y6L6cTPFrTfVtQ1l3NXU5TcPhEW2cAjTV1aBQyjajyXDxrPxlEv1SUo15gotkVmn1Ncj6 F2Xko6kEWGO1u5fLq/DbaVPfwWXiNFFHO77OwdV3+sP8MWFZjDYHSP5EBr+lkXzg27WXI9 6kaKsZbgkf8f9XG25SiTFlWENgGdaPFV0Qrkf6oWy80u1UkjmXLn6EP5FqHdY/zOwQ5wmY K0v1W1UHagIcCvrJbshA0xKz39Dq3/mzb8ozN1aJ+9KC6vvX+jr8DGe3q2zbgQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758101267; a=rsa-sha256; cv=none; b=kCuZD766XHTIniW4SatWYIguHYDBb9aKE4yN1VpOzZwLAzbleR2X/6yNPIcwRtyEVjud4t VFwdyToGsDE9s2PfJyzCh0EUXV3VnvdqLwdF/qbXny1Utn6HbW8dNXdK0RPVYVFcRAjbK7 JWCdtH1O/Vkw3mw9SJKoUBGMLeENl7d9mkh7BCuaWOhlpToKtGGJEuFPbl5yVvznDtD+qN PR5iS45WqxyEMF9XFaKxcOcgnhmkbs4r4qeAdA4Nz6/SMzU4CUR5Qv2Hbf2V41JVtkDukN BI3dXaCtq7Q/+ac/e2iebElPOIl0RFH7/QaW4gojvJs5hsi1EKs9t2EoHhdclQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRYMl1shCz4Cp; Wed, 17 Sep 2025 09:27:47 +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 58H9RlZm064845; Wed, 17 Sep 2025 09:27:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58H9Rli2064842; Wed, 17 Sep 2025 09:27:47 GMT (envelope-from git) Date: Wed, 17 Sep 2025 09:27:47 GMT Message-Id: <202509170927.58H9Rli2064842@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: 123881aead72 - stable/14 - sound: Honor CHN_F_NBIO 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 123881aead724fefa38d4324d2d442ecc79942b2 Auto-Submitted: auto-generated The branch stable/14 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=123881aead724fefa38d4324d2d442ecc79942b2 commit 123881aead724fefa38d4324d2d442ecc79942b2 Author: Damjan Jovanovic AuthorDate: 2025-09-15 17:42:41 +0000 Commit: Christos Margiolis CommitDate: 2025-09-17 09:27:42 +0000 sound: Honor CHN_F_NBIO If the device is opened with O_NONBLOCK, even though we check for it in order to set CHN_F_NBIO, the subsequent chn_reset() calls will clear all flags, except those set in CHN_F_RESET, which does not include CHN_F_NBIO. Add CHN_F_NBIO to CHN_F_RESET. Additionally, because primary channels can be reused, make sure we do not unintentionally keep CHN_F_NBIO set if the channel is re-opened, but without O_NONBLOCK. PR: 289441 MFC after: 2 days Reviewed by: christos, markj Differential Revision: https://reviews.freebsd.org/D52493 (cherry picked from commit e8b5025c3880b04c1c2139fe73b65fbd6deb41d4) --- sys/dev/sound/pcm/channel.h | 2 +- sys/dev/sound/pcm/dsp.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/dev/sound/pcm/channel.h b/sys/dev/sound/pcm/channel.h index fab182b22774..9ad21d219001 100644 --- a/sys/dev/sound/pcm/channel.h +++ b/sys/dev/sound/pcm/channel.h @@ -408,7 +408,7 @@ enum { #define CHN_F_RESET (CHN_F_BUSY | CHN_F_DEAD | \ CHN_F_VIRTUAL | CHN_F_HAS_VCHAN | \ - CHN_F_VCHAN_DYNAMIC | \ + CHN_F_VCHAN_DYNAMIC | CHN_F_NBIO | \ CHN_F_PASSTHROUGH | CHN_F_EXCLUSIVE) #define CHN_F_MMAP_INVALID (CHN_F_DEAD | CHN_F_RUNNING) diff --git a/sys/dev/sound/pcm/dsp.c b/sys/dev/sound/pcm/dsp.c index aa6ad4a59778..da38f52021ae 100644 --- a/sys/dev/sound/pcm/dsp.c +++ b/sys/dev/sound/pcm/dsp.c @@ -299,7 +299,7 @@ dsp_close(void *data) CHN_LOCK(rdch); chn_abort(rdch); /* won't sleep */ rdch->flags &= ~(CHN_F_RUNNING | CHN_F_MMAP | - CHN_F_DEAD | CHN_F_EXCLUSIVE); + CHN_F_DEAD | CHN_F_EXCLUSIVE | CHN_F_NBIO); chn_reset(rdch, 0, 0); chn_release(rdch); if (rdch->flags & CHN_F_VIRTUAL) { @@ -323,7 +323,7 @@ dsp_close(void *data) CHN_LOCK(wrch); chn_flush(wrch); /* may sleep */ wrch->flags &= ~(CHN_F_RUNNING | CHN_F_MMAP | - CHN_F_DEAD | CHN_F_EXCLUSIVE); + CHN_F_DEAD | CHN_F_EXCLUSIVE | CHN_F_NBIO); chn_reset(wrch, 0, 0); chn_release(wrch); if (wrch->flags & CHN_F_VIRTUAL) { From nobody Wed Sep 17 12:18:51 2025 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 4cRd973PPHz67HmS; Wed, 17 Sep 2025 12:18:51 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd972YpQz3V3D; Wed, 17 Sep 2025 12:18:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111531; 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=G8EelqplSGRm0IJezBpJfh2BCM7FOgvMkKyQ9JIcJb0=; b=Hc58rZUh0yu+s49oR4pPS0OEHBhGRPkZNaZQVoDgb6jDundgvKQAaY0tc5FuvLHBIu1b9n bn/pU7PZMyJdw6NNGwFpcyCoqK8Tt5BYVhY8KffXb14aUnFVLqH03CYe2LangK4eQa5sjn zPUs0os9OGg2/ecFjlopDUH7FmzyUhuGK7KcZy1tDkC6dg0h9WruMF33BsDd8MowkcE2YN qT3/kwncc4KSNoo2PgtGgIM2UeOCOYWzQOaUbzkMn7t2b0jOw7POX6fznIz4dr8s+Pkgcy 2dLBKYssymngVUX+9BDXjk40UIt5Z5UVRbJfat7+9JCs9xy+k4P5AiNTAwGYRQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111531; 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=G8EelqplSGRm0IJezBpJfh2BCM7FOgvMkKyQ9JIcJb0=; b=N7iOeIpVN+HxKyyYWFRPszPVYUwl3Pk/Afbrbf72yNQLEGJ2mW3JnK+xsv4Q1OYcIGSVEb r8IvaMqCDwH8E/Fd03by4995RflRtg/rvSUOnOiwAdIQVYiYhXfaUgSv3xLXSLaytkhyrC IOy5Ykx73QvHLtqN+VL5A+wxfsb+/6inoLXSR403WTwGUicl1aDYThr0VU4g6ezL9tzyct jLGtjNAkbdCGDvxA/Fm3HoN1HfO1ORcJU65UueJ0Cr4VJbP6EIO0f1oacoE53NYmuJmQdE +bODmfA89RQYSCwFOQzNtaq2Mg3yMX9LHnBz5SJC1MLNBA7GUU8qDZz0Fnmuzg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111531; a=rsa-sha256; cv=none; b=ZSti1xjRGBgneKXp8Hh++eTfRMPvDzauOAoiyJVQhvW/pWnTJi1zvi15V1nPz3BLHXM7oW Eze0PJkX4PZO+Yw8iNcQ2PTO3dHnOU593WM42F9/N6fBt8mvdqhwYsObgAaC6Jj/sZRiOb am+44Of2Yyph2bryWvbjl4+UUGHt5ziL/b2I+mtFdjkzZoC6BFCSLlb3Gu0DDtLwh6evTn 5b6E+npskL9uPinK8b2hbExqTfFpPobI2wlpCG9B9Gt365BboFsT8rb58Tnhim7UZxFzK3 gONNWeDH4B4RiLIq7QUKbflDtJmIMmgoR/8YO2ltiN5jH2WS63+pWhvOW8IL1A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9725JPz8wP; Wed, 17 Sep 2025 12:18:51 +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 58HCIpRj085300; Wed, 17 Sep 2025 12:18:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCIpGA085297; Wed, 17 Sep 2025 12:18:51 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:18:51 GMT Message-Id: <202509171218.58HCIpGA085297@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 580d2d429598 - main - libc: compat.h: Remove a superfluous blank line at end 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 580d2d429598e6eb3549f9ea7490d10e19904f7c Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=580d2d429598e6eb3549f9ea7490d10e19904f7c commit 580d2d429598e6eb3549f9ea7490d10e19904f7c Author: Olivier Certner AuthorDate: 2025-09-15 16:54:23 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:15:54 +0000 libc: compat.h: Remove a superfluous blank line at end No functional change (intended). MFC after: 5 days Sponsored by: The FreeBSD Foundation --- lib/libc/include/compat.h | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/libc/include/compat.h b/lib/libc/include/compat.h index 97f22607ddd7..630ffe7daae3 100644 --- a/lib/libc/include/compat.h +++ b/lib/libc/include/compat.h @@ -80,4 +80,3 @@ __sym_compat(setgroups, freebsd14_setgroups, FBSD_1.0); #undef __weak_reference #endif /* __LIBC_COMPAT_H__ */ - From nobody Wed Sep 17 12:18:52 2025 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 4cRd985tFNz67HMh; Wed, 17 Sep 2025 12:18: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd983W2hz3VN9; Wed, 17 Sep 2025 12:18:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111532; 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=WD1hlqbrTboPPgKAKMMMHGhYP90O62vdp+cEVJVt4vI=; b=Lshb5VdetzudgxfYkXM95VRXawpRpjjtBjVdhCxPB/t/XY/XsweP4VdR5r79NE5BZgmUkT NpfAQwpiwbgBRBhK+BJg8TbVsG12GT3CZg5mnx1vz5ie8oeb+vsTBDIkigp1OH9BRYbA+s zKt2foBrPFukWs4AweUvIt58KSUp/E9/a1ffLT/0QoAXu6s1MG+XORbTq9djvs7wbXPl9U 6nofKgHAB+tSjtnOTl+eRNqHIQhyEwkpCZd9jrK4q2M+MZZREhSpqK/yruXAlLzwLdy6LV BD/eKq6RkZ7GiLcrg2gIvIr6ELXcJ7c07tJNKWD6mWYTkxu2yTlEkNIe8OH+Vg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111532; 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=WD1hlqbrTboPPgKAKMMMHGhYP90O62vdp+cEVJVt4vI=; b=uoAijrZTvsl7rKTC+RpWad006tiyIXIErkm2pxI2ADGgqlf+IkczMRrOHg7srqaanKe/GG JvuhXf4aoozSBFwNP66g9HAf7E+6wWODy+Z5cJbwTkhGgs9m5u+d1Q81qd7qjxglVabmar zY4aJaGNMZiaIQE2eoeDyiLmWFcdzTYLSfjh9TODoL5nByIu3f1C8vuQhdig6DTJO0E14Y Ezdj0GMCQ02jDBTE/NIVeWu7mVt4Tm9Rp/tlMC6/1OsuvwNZTjPlb0dCD6b2HMFLF/GPxJ cJ8dI3yEMDDNLBygtmMInqq52r3i1C0q/PBXJ6qCJcEdCT+DUliydr7x6f6ywg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111532; a=rsa-sha256; cv=none; b=x7ERsHtXmBbMKHeca6CNOuy+R0Z7F9jpiPxdMf58151TOx8MphqSTlHekpL1yayF8Vd1V8 YQwt0M0zHP9HABcC9me8mY6cFOFjgfOZNiMEe20mQe4g37cl3WtMMvvfpaKDJ48Icotmkn gcowQaOcsn8c7kfgfmxjEqpb3m46O1o6gMkAa/55czLMkqFjSQav2SLrOCbaTuXxCiooYS 1chWReDdiegVpveFTtDNsZT/zU1YnBqUus9is9yzmffQk1fyPNNhUng9WcPITMi4NINHQn kWYMb9+Xyxw5sBGYtpl8nKsWmhP20vdf/0WBMFWPnlRROuOcbhNV4Hhiiytcfw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9830Pfz9hK; Wed, 17 Sep 2025 12:18:52 +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 58HCIqlw085343; Wed, 17 Sep 2025 12:18:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCIqZ2085340; Wed, 17 Sep 2025 12:18:52 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:18:52 GMT Message-Id: <202509171218.58HCIqZ2085340@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: e4cc7f993057 - main - dtrace: Fix effective GID shown by 'curpsinfo' 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e4cc7f9930573daeb7f1056d008e424aa4c3fd33 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=e4cc7f9930573daeb7f1056d008e424aa4c3fd33 commit e4cc7f9930573daeb7f1056d008e424aa4c3fd33 Author: Olivier Certner AuthorDate: 2025-08-28 13:46:18 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:00 +0000 dtrace: Fix effective GID shown by 'curpsinfo' Reviewed by: emaste Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52274 --- cddl/lib/libdtrace/psinfo.d | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cddl/lib/libdtrace/psinfo.d b/cddl/lib/libdtrace/psinfo.d index c0cd5b121064..8dc27e812965 100644 --- a/cddl/lib/libdtrace/psinfo.d +++ b/cddl/lib/libdtrace/psinfo.d @@ -55,7 +55,7 @@ translator psinfo_t < struct proc *T > { pr_uid = T->p_ucred->cr_ruid; pr_euid = T->p_ucred->cr_uid; pr_gid = T->p_ucred->cr_rgid; - pr_egid = T->p_ucred->cr_groups[0]; + pr_egid = T->p_ucred->cr_gid; pr_addr = 0; pr_psargs = (T->p_args == 0) ? "" : memstr(T->p_args->ar_args, ' ', T->p_args->ar_length); From nobody Wed Sep 17 12:18:53 2025 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 4cRd9B0TQrz67Hpp; Wed, 17 Sep 2025 12:18:54 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd994glNz3V1W; Wed, 17 Sep 2025 12:18:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111533; 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=aH6da3mA+o1QaJlKkJHv1zaJzIcKs+UMKbPGmHleVls=; b=gC8Igdt4kqecQxTO3AcWlVGjRE1xhlXkdbwgfQIOBRxbFdW1rSJaoFeJhrEGgXVoex918+ 55M7Bi9jqgngvOPDL3EobTkkvvh4gimCNCcjPEqaZF45tUVzj/GUfe4iESKWIjdrJJ6Zdm eAe1pShl0VSmlE0bV4t3BIZ37rSwiv4p+HrllwLpwFDtMQoWgXSs3F/HKaEJmucOD6qxbP e7yejUVvUxOQuwFPQeBwcCDFp2diyZgonUsFH5ByxVGzV7KcFWIy0z70249++0Uzma4SYD bpB3Vd+AJUwbPV6drbzOcxf8oPKdzbrzUIl53vRNhONkJ53kbdfNJYgQibW7kA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111533; 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=aH6da3mA+o1QaJlKkJHv1zaJzIcKs+UMKbPGmHleVls=; b=l6B46kCQUxG8OLHgTk4mKUbk9F52Y/UDfEADJlDszFTSzPpWfFd7eBPrtdAj967vmBRGWt +PzBQkguGkMHBqF6WnZK6zYd/L076hStgFczt1dSf6XeS1UDXCRLCR8DqoGsF1TipaFew+ OB0hx5gdEL2MIdruhMCbIGBbaVwnE7re5UDFIZrdokKzb66xdFETSLT5kpBJYC0g/8CFL7 mzakrs7u0V5T1MJn9s54qvRGRHlz6/MJZMSqmBpeWKobQMQFetamwFjqXQ3Q/YHQC93Fbl 03XDTg8xiSLj2K8jEbYhfPSAFN+cDs9pnJxbm8FOMQYIk7KH4rnwmwBOYytPMg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111533; a=rsa-sha256; cv=none; b=Gqi0qXOP0/jx1RZmvXzDe9RH4YIMRU/zuBEw7a+Za6QhSIftOkMECr3GxpfCtBvPIfbEOn 91WIhdSawp3zOWrJ7JcGQEGZFX8cYR9SO7aIJTQgZHhfzg7Fds5skK/que9U8/0f+Cru9j qqUji+bFFbNzyvUogUKt35fH9FN9Fftc7600R2FRzHy5tO0hthOQ53u4Yduu7zC4r8bdX9 Vu5gsooIzd0t/tylU3sFlggpMxzcazuMIVnXu5uXRrOsaLkd85y+QLJmzmrp3dWLmuMMpz CBN7TuJFXHvAsGwsOn8ma/uJxUBd0j2dbLv3srvzEHTD9rLTPTosE8DUruPN+A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd994GP5z9hL; Wed, 17 Sep 2025 12:18:53 +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 58HCIrQt085382; Wed, 17 Sep 2025 12:18:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCIrSn085379; Wed, 17 Sep 2025 12:18:53 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:18:53 GMT Message-Id: <202509171218.58HCIrSn085379@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 11cbb7d122ac - main - libprocstat: procstat_getgroups_kvm(): Output again the effective GID 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 11cbb7d122ac0219c214ad52c4d6f7cbb9d60ac1 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=11cbb7d122ac0219c214ad52c4d6f7cbb9d60ac1 commit 11cbb7d122ac0219c214ad52c4d6f7cbb9d60ac1 Author: Olivier Certner AuthorDate: 2025-08-28 14:49:07 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:00 +0000 libprocstat: procstat_getgroups_kvm(): Output again the effective GID In particular, fixes 'procstat -s -M' (for processes with more than 16 groups). Reviewed by: kib Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52275 --- lib/libprocstat/libprocstat.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/libprocstat/libprocstat.c b/lib/libprocstat/libprocstat.c index 1651cbc6820f..df77cabcd36b 100644 --- a/lib/libprocstat/libprocstat.c +++ b/lib/libprocstat/libprocstat.c @@ -1973,6 +1973,7 @@ procstat_getgroups_kvm(kvm_t *kd, struct kinfo_proc *kp, unsigned int *cntp) struct ucred ucred; gid_t *groups; size_t len; + unsigned int ngroups; assert(kd != NULL); assert(kp != NULL); @@ -1990,19 +1991,22 @@ procstat_getgroups_kvm(kvm_t *kd, struct kinfo_proc *kp, unsigned int *cntp) proc.p_ucred, kp->ki_pid); return (NULL); } - len = ucred.cr_ngroups * sizeof(gid_t); + ngroups = 1 + ucred.cr_ngroups; + len = ngroups * sizeof(gid_t); groups = malloc(len); if (groups == NULL) { warn("malloc(%zu)", len); return (NULL); } - if (!kvm_read_all(kd, (unsigned long)ucred.cr_groups, groups, len)) { + groups[0] = ucred.cr_gid; + if (!kvm_read_all(kd, (unsigned long)ucred.cr_groups, groups + 1, + len - sizeof(gid_t))) { warnx("can't read groups at %p for pid %d", ucred.cr_groups, kp->ki_pid); free(groups); return (NULL); } - *cntp = ucred.cr_ngroups; + *cntp = ngroups; return (groups); } From nobody Wed Sep 17 12:18:54 2025 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 4cRd9C1mHwz67HhW; Wed, 17 Sep 2025 12:18:55 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9B69Qrz3V3k; Wed, 17 Sep 2025 12:18:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111534; 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=3cF6ymYqE9a1Xsg1HE66tI6gN45wwh9XoqQ4Xz3XJTc=; b=wWQnBwNCtUQcJygXbUu/61+QYAcoLZ7jqEwCT63W2ZJAotSDtB/2rvE0686f0Mo2cimyT2 FQpncJvZCuVg98fQu0GEdGUcm3HD/BjI0lVFwDhFwo2ctJZD8kdGLqPpliqwTGlvEbwWTC xYY1RAd6EHnukuvJrU52Nz3xHgDtIv7q0XsEolNvfhsoyO6HsH2YP7k1LhELu3eJ8ipg0q LtWE6w8G65EH/xHLIb+g2t5k3of+aGTufpSFtXXPvU/kTgwqjA+fHS2pQJSzFUXDsIuMcO mjmaFewEaHobJM5wT+YhWTC0rQyw3giSpEWUD4mS32kS+oOjGWgb1A/JsengBg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111534; 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=3cF6ymYqE9a1Xsg1HE66tI6gN45wwh9XoqQ4Xz3XJTc=; b=uXQAqGI7GlAy2XfT28Xixm1Cm51nDmrJ75Cj7DeBPkGSmgUehZlIusytV3v0Qcl+4MpEsS kB7AVBpjBxXGFyLpq0B3GjWsQgjcbUfiSjzjygya0aLJ4ap21ccNyreQqNdv8Ix54jJH78 wcjVrIFDF03wAu5ONkd9k/9ie/5JtYSuSCqI4Ezd3cAIvJBsocV1jAtnQ64AypjBgOCTU/ 3Sgh6YpIQTlMRZMXDBTuNxmKrH82Q5AfFBVXd2KeBUIJTVtlUKoJmqf2SbB1E6zXDwkDhv 3lqFvQk6m4mCWaBF+sCrwVYKYAsicDMipCN4FqRfywptBFWisksEVFhSebdDkw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111534; a=rsa-sha256; cv=none; b=chb3l8pZgLi8FPUX1PXGji/XEo1dMeqNwMi5IcE5VOKVRlRzNrAi7SuMv0EPwwmycmISbo gpX/In0XilQXaC0/IDEHxRvpzkoofzA6TSFtFLTUQCoWKxldXMkxZg/6jf3kBR30vfsPuD CZJvTq4HssxjhBy68g+w+E+lBcSG8S7fQeagsWblraW6bZtwqeOJBAvucJfmNInnWGZQqf yAGfdpVoySdXDxj/6YVegSZH22NZtNHrUuf1u9rfo5m/DqnPAMTXSJ/po8bZ4prpyQ4f7u B4PwzqAyTJYzP02R0754qLsFny0kdr7FtHDZ6ADf45kC16JWeML3CR8/H61ysQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9B4vSMz8wQ; Wed, 17 Sep 2025 12:18:54 +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 58HCIsUX085416; Wed, 17 Sep 2025 12:18:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCIs8O085413; Wed, 17 Sep 2025 12:18:54 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:18:54 GMT Message-Id: <202509171218.58HCIs8O085413@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: c5e920e49c0c - main - unix: SCM_CREDS: Restore passing the effective GID 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c5e920e49c0cf068da3962688cc60ab514ea1252 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=c5e920e49c0cf068da3962688cc60ab514ea1252 commit c5e920e49c0cf068da3962688cc60ab514ea1252 Author: Olivier Certner AuthorDate: 2025-08-26 17:01:03 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:00 +0000 unix: SCM_CREDS: Restore passing the effective GID cmcred_groups[0] in 'struct cmsgcred' must be the effective GID. Note that the code in unp_addsockcred() filling up 'struct sockcred'/'struct sockcred2' (LOCAL_CREDS/LOCAL_CREDS_PERSISTENT options) was in fact "wrong" before 'cr_gid' was moved out of cr_groups[], in the sense that it would transmit the effective GID twice, both separately as 'sc_egid' and as the first element of 'sc_groups'. It is now exact, so is left unchanged, which causes a difference in output (the effective GID is no more in 'sc_groups', unless it is also a supplementary group) that is unlikely to affect applications in practice. Reviewed by: glebius Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52262 --- sys/kern/uipc_usrreq.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/sys/kern/uipc_usrreq.c b/sys/kern/uipc_usrreq.c index 6138e543fae7..340d84666459 100644 --- a/sys/kern/uipc_usrreq.c +++ b/sys/kern/uipc_usrreq.c @@ -3667,11 +3667,14 @@ unp_internalize(struct mbuf *control, struct mchain *mc, struct thread *td) cmcred->cmcred_uid = td->td_ucred->cr_ruid; cmcred->cmcred_gid = td->td_ucred->cr_rgid; cmcred->cmcred_euid = td->td_ucred->cr_uid; - cmcred->cmcred_ngroups = MIN(td->td_ucred->cr_ngroups, + _Static_assert(CMGROUP_MAX >= 1, + "Room needed for the effective GID."); + cmcred->cmcred_ngroups = MIN(td->td_ucred->cr_ngroups + 1, CMGROUP_MAX); - for (i = 0; i < cmcred->cmcred_ngroups; i++) + cmcred->cmcred_groups[0] = td->td_ucred->cr_gid; + for (i = 1; i < cmcred->cmcred_ngroups; i++) cmcred->cmcred_groups[i] = - td->td_ucred->cr_groups[i]; + td->td_ucred->cr_groups[i - 1]; break; case SCM_RIGHTS: From nobody Wed Sep 17 12:18:55 2025 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 4cRd9D23fcz67HMp; Wed, 17 Sep 2025 12:18:56 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9C6YCNz3VG0; Wed, 17 Sep 2025 12:18:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111535; 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=F3WP15UudDvkVRhB9maTj1fkiTZNbikL+QsNm0gvzp0=; b=AUjVY2w05CMtJMuAyHlzQ3tlqASZzoamcf+CdhWfgw58mzpg0M33vLPqhiqu8rPe2ERdso yO7kNR4eCveSf6qe4+CEfGWdS+ztXti+LpoBZ/CiJJYIfzPqqX4MLW4ZCu1s+nz2aGXsEY vAiC1YBXXLpOHFDXaCm3U8FW+3uAK2rZoifEk3U3Y+eUx3RTJPkXvgY3XIRU6PGPwL31fb g8MZvo0HNBK+sQWZMB33NaqGaZMSgCJ5t/BK401UAGoPwf0d+dp5/ThAfnVJ3+8cKf6zYd BdETdBY4fY7QSYFnqVdFcIa7skrr9dEdL3GllgY4seaL+QdKQV1VRUHU8PuXfQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111535; 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=F3WP15UudDvkVRhB9maTj1fkiTZNbikL+QsNm0gvzp0=; b=JDEwIV8RSF/2l5aTZdbLg2+hKixFGMbZL4WjlUChFcpSNjC6tYq0eHuD4PKIiZKnUrIKty Uk/xrUZ4tSfbdZIugZGGqF0tEV8lrHCjooCTN1QQPIsmTOxIUdSHYau+vlRjpXzRN5E+A1 WYk0ryCMF8aA3Av7/EPNQ48zCKV9nMnT3LEp4rppR4UfbBf1Yo0t0mo+hydwLcYaSiEFSp HlL39MPI0iUDo55q2NGi0RR1jWUJOTjKQWiWWx/77TWRynVPUUEaLRYkFnTs7uem6TIGG0 wmUMYB5P/Chvdfz2sSfZ5JEtvRPPXgxoBxqbIaU9stMlr44qXeO1H7YAXaE8rA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111535; a=rsa-sha256; cv=none; b=LPQyzCph48+2jW7Zuj7XppCOXmiEb3wXtxVmy0XJC+mMIxU0WpXBFvdf8f1jtUTlnQs6En pY9b8iTrnFd3/6aXrmmJhRhxLwWbgBOrTJdrQ0xfpvsgA/JBt1NjAUBqn39MWu9XuVZfGo XmQoT0/03r2seGo0tlEHg+OWQ6Qu2JYMvcZ/tmnj6XaD52xf9umamDQpX8UClzxEnotVhi X+MusElYzBEk2hZUZJ9N6y5o0NsggwrQya3K7NiyiWDWv/I5UpVz9j0k9/+/X9RkJZKQ8O 7BWdMPsrlVTihDf5M2zRTU1QePTOZP2eVZapryiFmMKppea+seIXTNn/+4PQLA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9C68c0z9jx; Wed, 17 Sep 2025 12:18:55 +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 58HCItbA085451; Wed, 17 Sep 2025 12:18:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCItZU085448; Wed, 17 Sep 2025 12:18:55 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:18:55 GMT Message-Id: <202509171218.58HCItZU085448@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: d22592cd6fd2 - main - fuse: Fix GID when sending FUSE_INTERRUPT to a FUSE daemon 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d22592cd6fd2d39432add376dad460a66488a846 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=d22592cd6fd2d39432add376dad460a66488a846 commit d22592cd6fd2d39432add376dad460a66488a846 Author: Olivier Certner AuthorDate: 2025-08-26 12:39:16 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:01 +0000 fuse: Fix GID when sending FUSE_INTERRUPT to a FUSE daemon Due to the partial-only changes of commit 46c07316f906 ("kern: adopt the cr_gid macro for cr_groups[0] more widely"), subsequent commit be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") caused a mismatch between filling cr_groups[0] in 'reused_creds' in fuse_interrupt_send() and reading 'cr_gid' from it in fuse_setup_ihead(), with the consequence that the kernel would send a FUSE_INTERRUPT message to the FUSE deamon with an uninitialized GID in its header (which, besides being wrong, would disclose 4 bytes from its stack). Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52255 --- sys/fs/fuse/fuse_ipc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/sys/fs/fuse/fuse_ipc.c b/sys/fs/fuse/fuse_ipc.c index a751c09159ff..7f754ab7f1d4 100644 --- a/sys/fs/fuse/fuse_ipc.c +++ b/sys/fs/fuse/fuse_ipc.c @@ -193,7 +193,6 @@ fuse_interrupt_send(struct fuse_ticket *otick, int err) struct fuse_data *data = otick->tk_data; struct fuse_ticket *tick, *xtick; struct ucred reused_creds; - gid_t reused_groups[1]; if (otick->irq_unique == 0) { /* @@ -237,8 +236,7 @@ fuse_interrupt_send(struct fuse_ticket *otick, int err) */ ftick_hdr = fticket_in_header(otick); reused_creds.cr_uid = ftick_hdr->uid; - reused_groups[0] = ftick_hdr->gid; - reused_creds.cr_groups = reused_groups; + reused_creds.cr_gid = ftick_hdr->gid; fdisp_init(&fdi, sizeof(*fii)); fdisp_make_pid(&fdi, FUSE_INTERRUPT, data, ftick_hdr->nodeid, ftick_hdr->pid, &reused_creds); From nobody Wed Sep 17 12:18:56 2025 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 4cRd9F4TWHz67Hcd; Wed, 17 Sep 2025 12:18:57 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9F0fL9z3VLg; Wed, 17 Sep 2025 12:18:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111537; 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=U3YccrcxqXmIK9tgvg/TXyV5HghQsNGmHJZF3nXAwWA=; b=Yon3ubBu9bynOzY1v/P1g9fgcyzAGhGWLvZgQV1cGAi1BDJDZb8ymsSuajEYrqYdDgkQTa gJ2FPvrPzeSaLvOPi8jEJrxoi/Z408Z82EmT1nzb1N9TucnxVHVgDsrfi8be6P9g1R1Rx0 hw/n2XYQC2Xf8fyUceijxngOvewLBWOR3NTffktfJJFaouGqImoDHmGg5p3meeh2iXypWz CvY3l9qmSbc5EZPDtO+++OGZ20I3V5KIMUskiY+8hhb6YHm8C32Ipk0hAplN4w+jX3HYm6 z9bP1AySmJclYmInMh6WiP+BJV9XYx6lQ0UkoBWuh0cWinuQGsmKDoV2xPhsdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111537; 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=U3YccrcxqXmIK9tgvg/TXyV5HghQsNGmHJZF3nXAwWA=; b=xbuoas4j53Jzyh5GgRVHKP182vdjZLQ9q/R2NKLDAUrL23cJbMvQ89cKca+oOzaPlPjCie JDn/qdXWTnmgPK9nRtMzx77k1I/WmrrJ23k8xvX1whAUpgV9ZUGm/mby0D3NdoH5QroCns y+t/9jf/NIcpUJOYvRodAoxp4je236N/qiJwc/F+2IvmKEmq24I7a7MOj17G+X71A0KTLP X6fRNG3AuQvFRDp9Jus8Lae4K/bIYbWa4gq5qa/Ar/JoVDY5CV27YDTfWNy4muD+val82+ d2giQDsb+MHHnkpgeBAy6YTsfmXNY80AHb5VZ/E1a057jIXPOI/Rbt8DosvFXQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111537; a=rsa-sha256; cv=none; b=cV9XmeAJjHwQ9UC3LtWiKw0kfKLYPVy6GWBihmi/46oIEryE8q7LEEt8+D0ebyOvHeS/Gm ABU0Jmdh9GILo4OJ+ussk+WxpKe0nqDc/dTWnv1nDFBXJUJ4DcZPXYj8Tyg7HL01/7kci2 d2oC2aGsnKHWzeGnSY5KL7LKHqi6lS2Q0F/xfLe7uV+FYhWh4pXzaKz0HeAjbNmK5AChCm XhF3liYUnra4cIYXxXsPQNLGPMx9Y0BM0AyWWKdZgIw2/tpjG4Ol/Tw2etWy+QMu0qaqtw +d6wsQ1aGBU7RO9XR5MfNrMU+Q9nTCaqduX9gajPkqp0ur3W9DxSNxcJAZinqw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9F00Y8z9G4; Wed, 17 Sep 2025 12:18:56 +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 58HCIuJN085486; Wed, 17 Sep 2025 12:18:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCIuad085483; Wed, 17 Sep 2025 12:18:56 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:18:56 GMT Message-Id: <202509171218.58HCIuad085483@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 5fa6ca8b8aff - main - nfsd: nfsd_excred(): Remove an obsolete comment 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5fa6ca8b8affc8d948687c4ede7aeed297ae2dc0 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=5fa6ca8b8affc8d948687c4ede7aeed297ae2dc0 commit 5fa6ca8b8affc8d948687c4ede7aeed297ae2dc0 Author: Olivier Certner AuthorDate: 2025-08-27 13:40:42 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:01 +0000 nfsd: nfsd_excred(): Remove an obsolete comment This comment has been obsoleted by commit be1f7435ef21 ("kern: start tracking cr_gid outside of cr_groups[]."). No functional change. MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52264 --- sys/fs/nfsserver/nfs_nfsdport.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/sys/fs/nfsserver/nfs_nfsdport.c b/sys/fs/nfsserver/nfs_nfsdport.c index 7040c4afb797..5ba86314ead1 100644 --- a/sys/fs/nfsserver/nfs_nfsdport.c +++ b/sys/fs/nfsserver/nfs_nfsdport.c @@ -3478,11 +3478,6 @@ nfsd_excred(struct nfsrv_descript *nd, struct nfsexstuff *exp, (nd->nd_flag & ND_AUTHNONE) != 0) { nd->nd_cred->cr_uid = credanon->cr_uid; nd->nd_cred->cr_gid = credanon->cr_gid; - /* - * 'credanon' is already a 'struct ucred' that was built - * internally with calls to crsetgroups_and_egid(), so - * we don't need a fallback here. - */ crsetgroups(nd->nd_cred, credanon->cr_ngroups, credanon->cr_groups); } else if ((nd->nd_flag & ND_GSS) == 0) { From nobody Wed Sep 17 12:18:58 2025 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 4cRd9G4LQzz67Hhg; Wed, 17 Sep 2025 12:18:58 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9G1JvQz3VPb; Wed, 17 Sep 2025 12:18:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111538; 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=F7C+2P9AFIQjj5xwwfSmeDQ5qpe3OZY7JruBXQ6zqEE=; b=VFMxrrn5QlaFPZaSBZw84KPODZelGXXviNwEG4fhOTKYCn7x33+iMEik+qxfVMUoLAnxp4 /sEoL8Iy7KUZSOZz567Z0Qtn/QTTTnGAV85Sa3mYYHm5djQ/8aX10MP+Wvy2RT3HWFeb32 x2nty1u7MLV3Cbj29/2+9zFjX32GcQWnPewuuKFeC17J26nJuatyncCN8uaC3LW+Kqm01+ JJ/GiCHYw5u6DTRgYMENvWW5iL6eO+JL0VxCtJe9BtEXkpyQInV+8PBmTrjHF8iTdnns99 ZNTAT8wroIdJs84tBsw6MzFlicYzcEEWH9kxPcYamLyxE1GGWjGMGNsMCBP0xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111538; 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=F7C+2P9AFIQjj5xwwfSmeDQ5qpe3OZY7JruBXQ6zqEE=; b=XMElTIyri8LSMa90OZ44PQPgHJ7WLaGp7O23CcRJpzHYIBNaldVjL9kmhAGstp0sVfr1BO pSiquqj9ExZsnUbx8FwHkoIziV62GAkGI8nM/njMFZnY978WH110YvYtp6E+Uv/YZeKlsQ FLYkMSHZr8ZXUrXvS6XtuSjXDSNK2TcX9vxQ66RrXOXqXtc4/cpR/ILWTXiUlFx6A1u58x Q8Auyz2zZIkEx481TIRjX8G/E/3sMecKcLmw0XPSdriSJT3P8LCqfEPaxUR9yyI5c7p+rv sWZHprT/2ux2Ok6xRPGmxvi6G7mrMSbryIwQ+sLkwU4qdlvYg1P7XElQ3AEWvA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111538; a=rsa-sha256; cv=none; b=cRZaIYRXofm8iS5LTwYlzTpBvdvDvdH9eV1dBG4ovxkInHmJ/hPK4YhMuxW7OBrvciPCyy LqnDk7Zh+0FM16K0J6hlDKduR93xkr0h/0onl/VNbx/RDr7TeWnPdUsC6d1KJl5acZ2F17 eWhT9sFtaiWNCZEEuEh8M7WC4zUHwLjZxMgCX0UcZHWz5SCvZow7UIirl+xtxduyDAf7xG 6GSolK6XVVe1oPWzNIm8MQcOBkwBRYcXK74DQU2bhCB0tP4TnsKQlmg6waN/+Mdw0Wno+c z/lwJosxYnowLjafgSymCUNDveJ5FgEvOeKlP4XVclXPxoUZ+MM0JuU064SKBQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9G0wG7z8wR; Wed, 17 Sep 2025 12:18:58 +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 58HCIwkf085520; Wed, 17 Sep 2025 12:18:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCIwMx085517; Wed, 17 Sep 2025 12:18:58 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:18:58 GMT Message-Id: <202509171218.58HCIwMx085517@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: a61e7b5c98f8 - main - cred: 'kern.ngroups' tunable: Rework the comment on the initial value 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a61e7b5c98f840b4a7777d718218d0f63569c52a Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=a61e7b5c98f840b4a7777d718218d0f63569c52a commit a61e7b5c98f840b4a7777d718218d0f63569c52a Author: Olivier Certner AuthorDate: 2025-08-27 13:50:59 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:01 +0000 cred: 'kern.ngroups' tunable: Rework the comment on the initial value Remove the parts about the effective GID being stored as the first element of the groups array, as this is generally not the case now after commit be1f7435ef21 ("kern: start tracking cr_gid outside of cr_groups[]") (some credentials export structures still have the old layout, and need to do the 'ngroups_max + 1' computation, but given the computation needed to obtain a size in bytes, this detail is not really important here). Remove the part about 32-bit machines, avoiding another modification when support for them is removed. No functional change. MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52265 --- sys/kern/subr_param.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/sys/kern/subr_param.c b/sys/kern/subr_param.c index 471640c290a7..a67e5fa6cbff 100644 --- a/sys/kern/subr_param.c +++ b/sys/kern/subr_param.c @@ -235,14 +235,11 @@ init_param1(void) * specification for , paragraph "Runtime Increasable * Values"). * - * On the other hand, INT_MAX would result in an overflow for the common - * 'ngroups_max + 1' computation (to obtain the size of the internal - * groups array, its first element being reserved for the effective - * GID). Also, the number of allocated bytes for the group array must - * not overflow on 32-bit machines. For all these reasons, we limit the - * number of supplementary groups to some very high number that we - * expect will never be reached in all practical uses and ensures we - * avoid the problems just exposed, even if 'gid_t' was to be enlarged + * On the other hand, a too high value would result in an overflow when + * computing the number of bytes to allocate for the groups array. We + * thus limit the number of supplementary groups to some very high + * number that we expect will never be reached in all practical uses, + * avoiding the problem just exposed even if 'gid_t' were to be enlarged * by a magnitude. */ ngroups_max = NGROUPS_MAX; From nobody Wed Sep 17 12:18:59 2025 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 4cRd9H5Vjrz67Hjq; Wed, 17 Sep 2025 12:18:59 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9H2NmBz3VYr; Wed, 17 Sep 2025 12:18:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111539; 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=Mlml3Kw6TPQDgNasxCSXuZ1fuWjkgs0e4UO0VZ1TbyU=; b=MjgUd6mlJnaIh2QyUjtUCV4Dvq8bd6Y8kXfked55x9l1LmEaAGQycCj21UD3uQchL+HLgi 2OLxsjg2ZSF4bkwssiZm9ZCETHQ23LSqtexmqiqH57F0jh58Hrv1iKKtY/3gty8rKSUx8f /+BnzzhIFechkFlyW45/7RFxabr6O98UUFxMqvRilwos0wHqLQcUeav1Bv1u3XuN86PsT7 IdgvnHWhRw6HpoOQ6SVapCyqibAuAPrLQfteiTTDaDVmcQ1IGUGh41EyYS9bz9GVWBDecs pHoVDzGpm5zh/jbP3VSvWjf89SGnJPMbNHzvNMcOfvEC9MuHrxNt6M7WdXL5FA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111539; 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=Mlml3Kw6TPQDgNasxCSXuZ1fuWjkgs0e4UO0VZ1TbyU=; b=ylMSwJToPmh+uPfu5+TE4GU8vztDfq0fDDW7q/TuLx6G2A3CsizXQs2qxF966z3IzVRr8y 7qREtJCOyo8dHkIJyFycwxa2axi1imw0W1PQhmkKtmVqL9fwKz9GLQCd0HbGwOWnLTISnw g914QWOcAfkhForq5QFbDyMvGYz2zTSJT+/FaBAlziRYBAzCTX55Y8mZw+EcKSn93sft1Z XocwMyoSx3JeHt+BAIK84NphXVd+72srRq82q+hMUmkm5OwKOByso5sXAwvw1Om2R/x6vQ chLF5KDPco/BvWI2tG1/Tp2V2RFVWfc653G+Vxl/Q1+RRiLapIqZwvqBDuvTYg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111539; a=rsa-sha256; cv=none; b=juQ1uOGZmlPQvw3CS6LJM+UjNXR6k9tisKNRDCn14TqaEzI/RPVyxx8Ow9NaafudOrSOfc r3yGTnBzsSfFmEOJcKuWn28kTvlWPq6SPrxwEoRRNuaCagbDgz5tyh1za9r2pR4z1otuEh ROZNTGcr9146iKHIN9pl7Az2QSrBwiaOGUwBMMEiKfHS4M/SYsoOFaopfcKxCoPDtTNEfI CTDakxpCkHPzhwkNIfpN0U1ZCED3tNwQdpTlCG7J1MIePfJstgpTREuQ2KR01NTY4dmQzf bCxrXhNu1U3Qk/Fxs3MB2ceHd5fxzzEFqZgO3+++hgA2DqH1wAmGZTaL2UIgrA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9H1yQCz9Lp; Wed, 17 Sep 2025 12:18:59 +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 58HCIxYS085560; Wed, 17 Sep 2025 12:18:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCIxWI085557; Wed, 17 Sep 2025 12:18:59 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:18:59 GMT Message-Id: <202509171218.58HCIxWI085557@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 9397b2ef741c - main - cred: Update some comments after 'cr_gid' is no more cr_groups[0] 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9397b2ef741c57c8b2f0fdf796cc86267ecf2213 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=9397b2ef741c57c8b2f0fdf796cc86267ecf2213 commit 9397b2ef741c57c8b2f0fdf796cc86267ecf2213 Author: Olivier Certner AuthorDate: 2025-08-27 14:07:03 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:01 +0000 cred: Update some comments after 'cr_gid' is no more cr_groups[0] While here, fix style of some already-updated comments. Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52266 --- sys/kern/kern_prot.c | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/sys/kern/kern_prot.c b/sys/kern/kern_prot.c index 0ca42d640767..3333a168a754 100644 --- a/sys/kern/kern_prot.c +++ b/sys/kern/kern_prot.c @@ -1803,12 +1803,6 @@ groupmember(gid_t gid, const struct ucred *cred) bool realgroupmember(gid_t gid, const struct ucred *cred) { - /* - * Although the equality test on 'cr_rgid' below doesn't access - * 'cr_groups', we check for the latter's length here as we assume that, - * if 'cr_ngroups' is 0, the passed 'struct ucred' is invalid, and - * 'cr_rgid' may not have been filled. - */ groups_check_positive_len(cred->cr_ngroups); if (gid == cred->cr_rgid) @@ -2921,8 +2915,8 @@ crextend(struct ucred *cr, int n) * Normalizes a set of groups to be applied to a 'struct ucred'. * * Normalization ensures that the supplementary groups are sorted in ascending - * order and do not contain duplicates. This allows group_is_supplementary - * to do a binary search. + * order and do not contain duplicates. This allows group_is_supplementary() to + * do a binary search. */ static void groups_normalize(int *ngrp, gid_t *groups) @@ -2985,9 +2979,9 @@ crsetgroups_internal(struct ucred *cr, int ngrp, const gid_t *groups) * Copy groups in to a credential after expanding it if required. * * May sleep in order to allocate memory (except if, e.g., crextend() was called - * before with 'ngrp' or greater). Truncates the list to ngroups_max if + * before with 'ngrp' or greater). Truncates the list to 'ngroups_max' if * it is too large. Array 'groups' doesn't need to be sorted. 'ngrp' must be - * strictly positive. + * positive. */ void crsetgroups(struct ucred *cr, int ngrp, const gid_t *groups) @@ -3018,8 +3012,8 @@ crsetgroups(struct ucred *cr, int ngrp, const gid_t *groups) * Same as crsetgroups() but sets the effective GID as well. * * This function ensures that an effective GID is always present in credentials. - * An empty array will only set the effective GID to the default_egid, while a - * non-empty array will peel off groups[0] to set as the effective GID and use + * An empty array will only set the effective GID to 'default_egid', while + * a non-empty array will peel off groups[0] to set as the effective GID and use * the remainder, if any, as supplementary groups. */ void From nobody Wed Sep 17 12:19:00 2025 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 4cRd9J6D3Jz67Hq0; Wed, 17 Sep 2025 12:19:00 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9J3hGZz3VpH; Wed, 17 Sep 2025 12:19:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111540; 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=vWCOIrvzffqPyP+DjJyHGnhBfHbmFoC7DIGGFgAVka4=; b=dlVVtXGnYpCnrRpLEvz+YZS77XtXKTFDT0cINTpga4saF2u95hNoDgUY+h2t9Pyj++eHFk X2WHbXbgrALpGQ0569GRsFdbKnum8p6ZitLhPg3kXzZweIYIcXaDMpUICDgQZrv6ZrvYy+ 72BNGmK0cq61MSzb5OM0UwYG642RY9MVoa4qfl/sjfilZrFZ0dtLtHEICArDUqKBun5muH zyUbrYvRfN6eKf897JTpCr5EknhdBT0f4UrQ0uJ0yNXjcYI2FzYkYFeVmrosQ4HQlGVh4K sXHGT8+WmNDCfuRl463G8wikIHUEMYeGCSq6UatkWVMZo+D5M6jOi7qMFSOLJQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111540; 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=vWCOIrvzffqPyP+DjJyHGnhBfHbmFoC7DIGGFgAVka4=; b=ORgfcVAxqfoMPMzpp20KQzR2ca0qKVkHR+c3N8z/0ywYELdJ4XMv2jgcfRENEhIgEO9p47 ZfrPwQUOKkL/InKeud71GHGoxAfp53qK8HJvcdr/+9pSmGizCyJ8ruaolmb/YvV1fadhJg XgPzGPNfhx7i7CXPmo567xfiEoetNNgqktXJ8JpLWmZe5ZjxplsGJdZyyL5tC8xQxyn4PT wmc9xceyMNC0eCISMZg3pMs728PWFf0QbzVxRURLXsOYLMYHVYlKE5L3u0zb0pnklUDTHq +M0dHR3M1doyMFl9TR8ymdSnUFYrTF/88j5t63OiOvH9mXpuwpqHovTzAM5a1Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111540; a=rsa-sha256; cv=none; b=qzxL+uJ1mdExAtgMyREGQBKKVIc+J0NnRMH5lJOONqOKLMy/F+HjUYba6dToZX4FTNpkg/ P1xuSrwwbU6N7B1RXfhYDad4Gl/WAVZHY1shDq6U+WfkqRF0a5xnZgjNL47Lcc4EhswBO8 iYSraXqScLijE3jt5kQ7G0856w3QZn9ZjaBjHomXKDR+6t9Xlp3ZXMSGEy4IAKxbIfabVT n26sRCia73hONu5lO0wxBRqKv1EhN10eLLk4RM6hMwHwz+EqQm/w5Oa0V9iqsGLAuhIKdJ s+9bPSp5MHuBqRGo/ymsT3jOcCViCO9MrhxMgIjmtJUAsVIcf+Hng9uBtqejpA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9J33j1z8yl; Wed, 17 Sep 2025 12:19:00 +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 58HCJ0Kr085601; Wed, 17 Sep 2025 12:19:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJ0vl085598; Wed, 17 Sep 2025 12:19:00 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:00 GMT Message-Id: <202509171219.58HCJ0vl085598@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 30193fce433c - main - cred: Remove obsolete comment after getgroups() not returning the eGID 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 30193fce433cdad465904b6efe3814bf234ea74e Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=30193fce433cdad465904b6efe3814bf234ea74e commit 30193fce433cdad465904b6efe3814bf234ea74e Author: Olivier Certner AuthorDate: 2025-08-29 16:35:56 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:02 +0000 cred: Remove obsolete comment after getgroups() not returning the eGID No functional change. Fixes: 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52267 --- sys/kern/kern_prot.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/sys/kern/kern_prot.c b/sys/kern/kern_prot.c index 3333a168a754..591994e92e7d 100644 --- a/sys/kern/kern_prot.c +++ b/sys/kern/kern_prot.c @@ -291,11 +291,6 @@ sys_getgid(struct thread *td, struct getgid_args *uap) return (0); } -/* - * Get effective group ID. The "egid" is groups[0], and could be obtained - * via getgroups. This syscall exists because it is somewhat painful to do - * correctly in a library function. - */ #ifndef _SYS_SYSPROTO_H_ struct getegid_args { int dummy; From nobody Wed Sep 17 12:19:01 2025 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 4cRd9K6Rtsz67HkW; Wed, 17 Sep 2025 12:19: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9K4PHbz3VZV; Wed, 17 Sep 2025 12:19:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111541; 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=i5NOZCmyjCRVCP+YjQ/8UfXa2pso0Zyj3uQIn82n0Ck=; b=qA4J2gBNdUFpyOfNvfZcJ2fog8ibg0N5433KxRDEslVMxaJTX41xk9aLfBB68QkJhk1IZx VCTI6JuoFOf0YYpE1zxP2y2dDMEQdvku2is5eyEvwUwUS4d4t0sVTa2HuDf8+A81JQ9zCO jieOFZKKNcVxxfBAxtxOSZSJDhsmmP879Fkoq2brWXiIbn+C9BqVAeLyFgSayvNsOvsJYt UUhuk5qBdLdkPVhQYPPxdGB/+MMOopH0BYhhArJ4qsENmjnGuKpqMjXWHgOtxBnF9OGY4p BX3XlPp6u6Sgip0Mm85BDB4NyvE1ZS3w86bLSKQDNfwLd6mPA0YDQ78xnOGDlw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111541; 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=i5NOZCmyjCRVCP+YjQ/8UfXa2pso0Zyj3uQIn82n0Ck=; b=jtYHvKn1ctEJHCR+AFg1/ZTuT/qXwdloyI9eSLwhwhXfDf0/pMCT0mbK8J98/9WHOqw0kx 0oJjr3AobOSSf478UNqQgIjH61lLZOhkwVucsRmp1Vh26xjwxucZrN6oKxYSJXB5Hbgjod sm2DZmS5LyzGfPJ8Yns3N7Mkjp4sel6hPwt526fmn2eoDLSzaisf84hkF2ShwscENH2XFW NWtpt6DiNNape2uJhI4xzmJJvJuq/VsVL7qaJNLLMq+pTS1L2CEd/WEa3HfE3/MXRxaV2t nZztF5Yawn09Lh5dTL1iGL3ukTIbebzVCdjGhDdsmtSJJHRIKC4V3rPzwLtRzQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111541; a=rsa-sha256; cv=none; b=uuWBmDpxSiaaIWjgTe1yMpKRpMp6khwgmqIWMxnagvg4WWaOM77rmZ9hrouQOIE/wcctUW i4Kd5N4mMUG4I2Ylhh/ucsT05ObJQX6cMXluFIEbB7YyDtlD0gA7bnrKXrHrd8tJpY1Sdw wgb0O5uYRLfsBOFXVtFqcEjVWd0ewKvs8tKvbMar4EkSqBcdBXc+mKo4X8U0tz3GtKMs5V kLCIhvcywmq4Xw4mm6hC9pGYUcQ2fGBsMkmLx2wvmVilq21ElSQksxp8RQO5wyrypUo0yU Am4PIOuOnKwThPuKo63SKpqdYt7/nI0zOhN/hxJGKbSWZm/BcgTn1hN1ZCPdzw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9K3l2Tz9hM; Wed, 17 Sep 2025 12:19:01 +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 58HCJ1cw085635; Wed, 17 Sep 2025 12:19:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJ1BT085632; Wed, 17 Sep 2025 12:19:01 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:01 GMT Message-Id: <202509171219.58HCJ1BT085632@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: fa1cbb02d120 - main - cred: Restore proper checking of effective groups in some security policies 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: fa1cbb02d12055db0584882d586658be643f0949 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=fa1cbb02d12055db0584882d586658be643f0949 commit fa1cbb02d12055db0584882d586658be643f0949 Author: Olivier Certner AuthorDate: 2025-08-27 14:28:15 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:02 +0000 cred: Restore proper checking of effective groups in some security policies The removal of 'cr_gid' from cr_groups[] as cr_groups[0] made cr_canseeothergids() skip considering the subject's first supplementary group, causing the 'security.bsd.see_other_gids' policy to be too restrictive, and cr_xids_subset() miss a check on the effective GID, relaxing the "can debug" and "can export KTLS keys" checks. Fix these policies. Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52268 --- sys/kern/kern_prot.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/kern/kern_prot.c b/sys/kern/kern_prot.c index 591994e92e7d..6485254d300d 100644 --- a/sys/kern/kern_prot.c +++ b/sys/kern/kern_prot.c @@ -1889,7 +1889,7 @@ cr_canseeothergids(struct ucred *u1, struct ucred *u2) if (realgroupmember(u1->cr_rgid, u2)) return (0); - for (int i = 1; i < u1->cr_ngroups; i++) + for (int i = 0; i < u1->cr_ngroups; i++) if (realgroupmember(u1->cr_groups[i], u2)) return (0); @@ -2265,6 +2265,7 @@ cr_xids_subset(struct ucred *active_cred, struct ucred *obj_cred) } } grpsubset = grpsubset && + groupmember(obj_cred->cr_gid, active_cred) && groupmember(obj_cred->cr_rgid, active_cred) && groupmember(obj_cred->cr_svgid, active_cred); From nobody Wed Sep 17 12:19:02 2025 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 4cRd9M11slz67Hkc; Wed, 17 Sep 2025 12:19:03 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9L5Vdjz3Vcb; Wed, 17 Sep 2025 12:19:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111542; 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=/PyDjLi9ezqN+IE5K322iZOoZI4KFDr8D+XN12gQP0k=; b=SZVIro5WYE806neuSgj2Ex/uij1BkSB0I8w9HffNyD3t5Iur+9C9DnOAeArH+wZgNOWU0v HZ/GkRlsk/bHmnHwSrA9QbYuZgWEBKPdtVMVrI8C6cwzSAheTWvVOb5KTk+Mqe8cS+1uhb gN44lVVLzYYphQjO1RL8d9+g87by0b1Sj0vM4lNqh+Y1XSqeIyjIfJzY9ZuXM3mhFeMAPH iQzpwAgKSDqbx9iEbHcoErYDOKqCLoMlx8LZ/aoapYwn6S71F8Y4MXVViGTD4lG09y7Ypw cErxZ3036FfMolceSaMk6wHdvwED7pEpwPx5OxJYvoMuCexvNt/ljQb05+n+pw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111542; 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=/PyDjLi9ezqN+IE5K322iZOoZI4KFDr8D+XN12gQP0k=; b=wF8xxX1XbnDWolTulhe807XRVt5Q2g9b7syXI/rs46OgLx+QIeUun2O6zPqhm0D7KQjLxu A38oGyc8DCopy7kxBmXj6BtUvHoyGpvQyJFBWaFP8D60te+LRGuQRJgpiWNdHL4CZv2feZ v+xGRjw8UGKPNlIqNh3VbYpnyJxv3WD0ur+nSWqtxJv22P/drjo9hGAM+i5RYVFijlVC9D eMTyefUhtPxq2+i92w1rM9skpSw8o0qBVfQXqTYpH0DXX25vTif4NL48QP7kfPXFdA1Rbh bb2j39vUoozrtf9s8uCF5p03yO48eeB0OVbHmC2CErVKg0s423/01XCoLy78Hg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111542; a=rsa-sha256; cv=none; b=m25Wwh1vzTj1km82W2nZ3MiAscwiH0foE2Yg6YLPytTso5UMny6XJT05YkHg9YszDayTvQ c76o03hdNd8LDxlGtv3NoZplW/URJV/hu3gbKfiMxVHHgiWt3FR1Yz1I604jQcGb755SjZ XjIZGgwyTl/X63COI83uaKPxgikEiCAB8m9vDSQEJ1b1wZoDz71dDisgxqv/hoRDRZz+2Y 6PcgQtLD5s6+7CFJzTTISUp3rgMD5AKE1bjjs90HchAX1lU7TGa9agL2vRy6x1HTVWS6dk vTyF9ZYA+BPIX8jxs0pNepp6H6WV0JibvzWuJEwwZ7Zq7MfXdXOqhSQNRcfiQA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9L4hGjz8wS; Wed, 17 Sep 2025 12:19:02 +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 58HCJ2In085673; Wed, 17 Sep 2025 12:19:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJ2XU085669; Wed, 17 Sep 2025 12:19:02 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:02 GMT Message-Id: <202509171219.58HCJ2XU085669@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 0abeb8d8d8df - main - cred: 'struct ucred': Rework comment on 'cr_gid'/cr_groups[] 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0abeb8d8d8df1842b0c2d2276c958b0150579a1c Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=0abeb8d8d8df1842b0c2d2276c958b0150579a1c commit 0abeb8d8d8df1842b0c2d2276c958b0150579a1c Author: Olivier Certner AuthorDate: 2025-08-27 14:33:24 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:02 +0000 cred: 'struct ucred': Rework comment on 'cr_gid'/cr_groups[] Make it more straightforward for consumers. Also, recommend using cr_sgroups[] for supplementary groups, as this can generally alleviate index problems and will help us spot and change consumers if/when 'struct ucred' is evolved incompatibly (and cr_sgroups[] suppressed). MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52269 --- sys/sys/ucred.h | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/sys/sys/ucred.h b/sys/sys/ucred.h index 9c1d8545af34..254f58841993 100644 --- a/sys/sys/ucred.h +++ b/sys/sys/ucred.h @@ -112,15 +112,21 @@ struct xucred { short cr_ngroups; /* number of groups (incl. cr_gid). */ union { /* - * Special little hack to avoid needing a cr_gid macro, which - * would cause problems if one were to use it with struct ucred - * which also has a cr_groups member. + * The effective GID has been the first element of cr_groups[] + * for historical reasons. It should be accessed using the + * 'cr_gid' identifier. Supplementary groups should be accessed + * using cr_sgroups[]. Note that 'cr_ngroups' currently + * includes the effective GID. + * + * XXXOC: On the next API change (requires versioning), please + * replace this union with a true unaliased field 'cr_gid' and + * make sure that cr_groups[]/'cr_ngroups' only account for + * supplementary groups. */ struct { gid_t cr_gid; /* effective group id */ gid_t cr_sgroups[XU_NGROUPS - 1]; }; - gid_t cr_groups[XU_NGROUPS]; /* groups */ }; union { From nobody Wed Sep 17 12:19:03 2025 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 4cRd9N1gD0z67Hk5; Wed, 17 Sep 2025 12:19:04 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9M5pP9z3VTm; Wed, 17 Sep 2025 12:19:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111543; 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=ZKeppte6CTIakUWG4HFaTCo4vr6N7z6KnARJ3xM+zbw=; b=nYG5eg/T1p/2ZXwg4tHA3c7h6mDxkBQ1tuHphu8KWg7iQPSGbAzxbYECZLWB0uuL7AoDsq c4jmpxNBXzS8h79pGbF+HGpIiEoT2hIUIEl0Dj2cIqf3xI+lH1joYjjLCCUlfbpDJomfmT xtZPHGR7g59OOniwQzHUkbMPeuSY1XXjZhcpAhU1/kQMpbJwCOdliN5kBgIBXLRtiH7AM7 8p2Wu9CxDeCYKa8I6zx1VXxlmfn4UQq4AQJ97EojpnVQ246z9GwnCLXi/d5XcXiagm+Xkq g1AuCWX5Dj0nMQWy/376oSQpEyO+wYWDYRr6fvK8RwxFb8bAGuy95cDGrCEBBQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111543; 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=ZKeppte6CTIakUWG4HFaTCo4vr6N7z6KnARJ3xM+zbw=; b=kcw3KUcsWw0yvtXGew0nMNxS68LUAFO2VBto6uMncof479Orn69AEU3FoYLG+Chqhnyuuk aGUCQZhkncSHA1dp1goAKkC/V9cx91r6IeVRS4iSarxNcPlOci4QU3fS8SKTn75ahy/By6 UugQ1CEZ2XHHbCcVNRfrES2sRt4Sq74WgcMHTdFae0f9J8ro8+siAZpKNCfszNi96bv66C hTl3fO+aIn/VO7B0Yh+pWPIehhxtzuI/4OXyTmBl9LmtA7AYQM9vBNVOPmBjwVuDmHszcS ky3OCowidaHBTycbGFH2FJEoqf8WvBb44gIOp0L6q8w9y5sKd5r9bQM2rKKO8A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111543; a=rsa-sha256; cv=none; b=bOqONhBP/yrVz3stMF0gS+O//zhAe77TlvHktfpkcmlmwAAHtoqRfrI1GZEEOA1/BkkWaa wa4FLOWOqI6KKIDSO2c5/pBg4GGxwST4ZjF5QoU0jATZavHrFvmRGalbY4OF++IshYkdln Ijsxrg3ivXbhkFwXHcr0TOyzKQ4YhnRfiGpk4X3AvNmZGSp+oB1huueskviT29SD/foBjH ffcFk7AAfQAnxX6SpPh5ltXlU+sjRuFVtmyDkqDggqmW1Lf8cxjoH5xnchzKRgh/ew+uVG 7A203DES+vwIHW2Fwlrl1skw4w3R+OD6jFB4nqStAEIga6zDYaqpdpVXSt5Tjw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9M5HHhz8ym; Wed, 17 Sep 2025 12:19:03 +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 58HCJ3ZE085715; Wed, 17 Sep 2025 12:19:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJ3Ki085712; Wed, 17 Sep 2025 12:19:03 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:03 GMT Message-Id: <202509171219.58HCJ3Ki085712@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: ab7186a48634 - main - MAC/bsdextended: Restore matching subjects' effective GID 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ab7186a486347216fde099498471cf847828565c Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=ab7186a486347216fde099498471cf847828565c commit ab7186a486347216fde099498471cf847828565c Author: Olivier Certner AuthorDate: 2025-08-27 14:56:21 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:03 +0000 MAC/bsdextended: Restore matching subjects' effective GID Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52270 --- sys/security/mac_bsdextended/mac_bsdextended.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/security/mac_bsdextended/mac_bsdextended.c b/sys/security/mac_bsdextended/mac_bsdextended.c index 8a6549214380..bf95c008e2f2 100644 --- a/sys/security/mac_bsdextended/mac_bsdextended.c +++ b/sys/security/mac_bsdextended/mac_bsdextended.c @@ -246,7 +246,9 @@ ugidfw_rulecheck(struct mac_bsdextended_rule *rule, } if (rule->mbr_subject.mbs_flags & MBS_GID_DEFINED) { - match = ((cred->cr_rgid <= rule->mbr_subject.mbs_gid_max && + match = ((cred->cr_gid <= rule->mbr_subject.mbs_gid_max && + cred->cr_gid >= rule->mbr_subject.mbs_gid_min) || + (cred->cr_rgid <= rule->mbr_subject.mbs_gid_max && cred->cr_rgid >= rule->mbr_subject.mbs_gid_min) || (cred->cr_svgid <= rule->mbr_subject.mbs_gid_max && cred->cr_svgid >= rule->mbr_subject.mbs_gid_min)); From nobody Wed Sep 17 12:19:04 2025 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 4cRd9P3Xqgz67HYC; Wed, 17 Sep 2025 12:19:05 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9N6hRvz3VV7; Wed, 17 Sep 2025 12:19:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111544; 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=4QbtC8363H0wcUtBXMX/X9aoCgTYnMIcfsbPtsP5zRo=; b=S4wODkSRP2j6gcA80Uo7y+dm2VqX0cMDRzVgdtzzZzw4pvISDxl7YojhSPpNjnAVzU7/Tm L4GNIaO4vPu1vwWxSKtTS+B3h636X1FrjvWrs8hYkgWUs07q4NWvY32JeQEjN9OHogG4VN BP16Ln5HjNVdLv0CgmUg8/XBH7eP3uab7yTSyQL7v2uYSadoTM553ULBpnCRA1i/lnWBMb nM65eVsN/P+/lmwraMJ+6JRfe3jVSwoI1scmGF+11nBWUpGA89e6YR5Uz+0u4GES5xx1Kx bG+ZcypP52AUtb+Tj05cKmyTX1jM1JxlvMvzqnZhhHr8LfzFmiSKPCAmElX/xA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111544; 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=4QbtC8363H0wcUtBXMX/X9aoCgTYnMIcfsbPtsP5zRo=; b=ebF0czRQEbgWK0t7pLoc5zlAkIwrXXZeKl+vCwANqStDJz5l7hcoRJ3uiQVul7m9Y6NEA2 7BMXSITnwqu0qUrCTLqWwZbc3QXdRO/ERdzxTcVU4TQCFq/V99pRyUqGCS+vXzpKle+IPy m1+dMXebNMiBB9dBASSlQczpBHA2+Wvdz7+87Vk7vAniLXIqyazAs54zZeMdof+nkCZ6gI vEMgDhkvFTtaYXFEVlH5hQzOmnpaD5VDYcp/vCjf17uRfpII69rGSGCHD1v7XhpGlSDGrx rU4LgDRLKQzaVrrMXN5ZSHVespqctN0OPT11ZQDqOoX43NnNdwOhCVP+bhAWQw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111544; a=rsa-sha256; cv=none; b=QRxcrSiHzV4pSM+r3cHCAKWYeYR4F7BlOjSSWpx7B1Mo6hOZNxVSd8DHdmnzT00pwUn1mu e445w6gbn9jzmvFmgEk+R84CgX5024Kjod64/br2/BpLzer7X79eWB2SNKf+Lwi42rgpO4 X4BeSHmtcXL9K1WXP7fZbXaZOfG4mLQtaFOqXvAfdHxEuH7cF+C8YbSx/Ogiq36iOYnybL HXMHHQ89iOAtmhPNbYSnGj0/EokQjO9xAyczy5TWu6DGounsGNZ4h1LkvMBYKG6RsIqXVf V3zGaopXEb/kkvnSRRE5PtdeRrCuE/dMBLX1gEFkosc7cHB3xHpw4NhF0Rplkw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9N6Drhz8yn; Wed, 17 Sep 2025 12:19:04 +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 58HCJ4ck085754; Wed, 17 Sep 2025 12:19:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJ46s085751; Wed, 17 Sep 2025 12:19:04 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:04 GMT Message-Id: <202509171219.58HCJ46s085751@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: d39756f23fe2 - main - MAC/do: Restore matching the first supplementary group 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d39756f23fe223d14ff00b1392ba39e94d5eadbc Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=d39756f23fe223d14ff00b1392ba39e94d5eadbc commit d39756f23fe223d14ff00b1392ba39e94d5eadbc Author: Olivier Certner AuthorDate: 2025-08-27 15:22:26 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:03 +0000 MAC/do: Restore matching the first supplementary group As 'cr_gid' was in fact stored in cr_groups[0], rule_grant_supplementary_groups() would loop only on further elements of cr_groups[]. Now that cr_groups[0] is not 'cr_gid' anymore, but some supplementary group, take it into account. Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52271 --- sys/security/mac_do/mac_do.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/security/mac_do/mac_do.c b/sys/security/mac_do/mac_do.c index 7a5ac2e01f75..6f3e63d06198 100644 --- a/sys/security/mac_do/mac_do.c +++ b/sys/security/mac_do/mac_do.c @@ -1650,7 +1650,7 @@ rule_grant_supplementary_groups(const struct rule *const rule, const bool current_has_supp = (gid_flags & MDF_CURRENT) != 0 && (gid_flags & MDF_SUPP_MASK) != 0; id_nb_t rule_idx = 0; - int old_idx = 1, new_idx = 1; + int old_idx = 0, new_idx = 0; if ((gid_flags & MDF_ANY_SUPP) != 0 && (gid_flags & MDF_MAY_REJ_SUPP) == 0) From nobody Wed Sep 17 12:19:05 2025 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 4cRd9Q0xPYz67Hkl; Wed, 17 Sep 2025 12:19: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9Q08Vwz3Vkb; Wed, 17 Sep 2025 12:19:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111546; 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=cAghK0+HcRNoaVtvwc5F/57nLOemNvnMRWc4vqlQG98=; b=ZUOpaW/V/8xFG/gDc9u3vs+UeaKwTMHpN4ldDG13W6PJe++wXwh+pxkioTQqYO791MlrfV Py0JYyBTaXTLcTy1wV3XWCfQcv4RBpyMJGNjucNJGGZGfEZK0jAr4oAsdZwooDYiJr13Vp RxGhMoFFIpI1dkcSRttDvnqqY3D/BjDsA5LiS9kAqr9ScZ6FmbSyuvxKD6BtKQ5RlBeGZc 4adRnSvJwTXz94J1obwTvoW0bRTLlv+Fmsg1V6Eck/NbVgwe2J9Ifn+1CJQtJRH1DUsuB4 HPlpNIfqkzLMoG/0UlNCYpwcGeNvl29iJ0DDk1mHRbU0osMMR/oWdo4LUBYvxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111546; 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=cAghK0+HcRNoaVtvwc5F/57nLOemNvnMRWc4vqlQG98=; b=QjmrdFpkGBQVKXrPTq8OqOVSAf/D9aa9zSTWEvFVtGUcFyIAkWmBDreEwwiC5zIMeK5yEf c+eUrYYxisH4ceyZLw2KWwxZluWcLuvOs4xsPTae70UII+mbNppbSzCHG7G0iLZM3S9AXD Wiqos3a9/nAdmJzUlBLEB+zUwegpqD6a+fVZPl1ZbVksrMYOYijFbpJ4NHOHwpsSApIhtA tEO010oWmWfZqWb2B6dFrtnASTEPR2j6YAgXZRhef5ZoLQDLxpT7SIx9CoOft9Xb1W7S3/ +1aDjqMzGcavrTRKIe2j8umGCbXa5Q+ORRPNkLDKZurXRcKQCWKcA4bO+C8W8w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111546; a=rsa-sha256; cv=none; b=hT96nsg0meaCK3mUPB+nLwveE+wWXGlbfa5iejlkV2W7Ia+57jWr7VzxYiHkHUjWgjV3ik bLTGPJm4wdXeQsBnm5hl7YGN1Y+rYHp9yyc70U3ES5BKHqNbvVCK7/u4kebw+wFoPx8HAD JJBMtrvY/OLCv4yhJYBdIQglx59V87p2+8zyDCR41xeFf0c0Jtno4rivFdzaw7yOLXyW+J z+6iS1VrAS9vcDLyWVgolPjFHD3lbbLM+SrDRY73bUosFSrKZM6Ay6wo5h4fTEg/ymgL7I gIWOjKWNZcUp6PziZgl/KVvzouE52pt3asvB1PDrHIAwn9aAnkUB7jS7tclHgg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9P6rzvz9G5; Wed, 17 Sep 2025 12:19:05 +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 58HCJ5G4085787; Wed, 17 Sep 2025 12:19:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJ5g1085784; Wed, 17 Sep 2025 12:19:05 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:05 GMT Message-Id: <202509171219.58HCJ5g1085784@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: f75d0dc53392 - main - cr_canseeothergids(): Make the logic easier to grasp 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f75d0dc533923345c653dcdcd5ebd1e53377a7c5 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=f75d0dc533923345c653dcdcd5ebd1e53377a7c5 commit f75d0dc533923345c653dcdcd5ebd1e53377a7c5 Author: Olivier Certner AuthorDate: 2025-08-27 16:53:14 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:03 +0000 cr_canseeothergids(): Make the logic easier to grasp Invert the initial test on whether the policy is in force so that, if there are no restrictions, the function bails out early, allowing to de-indent the rest of the code and have it finish with a non-zero (deny) 'return'. No functional change (intended). MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52272 --- sys/kern/kern_prot.c | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/sys/kern/kern_prot.c b/sys/kern/kern_prot.c index 6485254d300d..a4c5bcc52529 100644 --- a/sys/kern/kern_prot.c +++ b/sys/kern/kern_prot.c @@ -1885,19 +1885,22 @@ SYSCTL_INT(_security_bsd, OID_AUTO, see_other_gids, CTLFLAG_RW, static int cr_canseeothergids(struct ucred *u1, struct ucred *u2) { - if (!see_other_gids) { - if (realgroupmember(u1->cr_rgid, u2)) - return (0); + if (see_other_gids) + return (0); - for (int i = 0; i < u1->cr_ngroups; i++) - if (realgroupmember(u1->cr_groups[i], u2)) - return (0); + /* Restriction in force. */ - if (priv_check_cred(u1, PRIV_SEEOTHERGIDS) != 0) - return (ESRCH); - } + if (realgroupmember(u1->cr_rgid, u2)) + return (0); - return (0); + for (int i = 0; i < u1->cr_ngroups; i++) + if (realgroupmember(u1->cr_groups[i], u2)) + return (0); + + if (priv_check_cred(u1, PRIV_SEEOTHERGIDS) == 0) + return (0); + + return (ESRCH); } /* From nobody Wed Sep 17 12:19:07 2025 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 4cRd9R4wrtz67Hn0; Wed, 17 Sep 2025 12:19:07 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9R1SCzz3VVP; Wed, 17 Sep 2025 12:19:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111547; 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=o7CAb+ogG+3H7yztK1f86DJeBD3UUUveqIOvrGHZg+E=; b=bfOkE6LAt8FP+tw30iyKtOtpgx/w1vtP8YafwamwqAG3EzHJROEchPSFLhyFYbtn0nnP+/ 9czE9HgETzymP3TIGt8JBSw1jIzObrLI5yzraQTIyU0HLRm7i0jtH/r1und0eAiZtRgxoo P7O51btH4t0X1vcgGn2SvQc60y1PjoUIIX0wuV9QIk4qhg4lyy502IhmpDD40MpbBGdlXi TlkM7QHumyhr4XZFgaTVfDVSgwzsAKrYL2GGlUFwdBa0Gsn3AVn376fitzlkuMQpyzEngd H9La/6Mbo0cmwIheOWw74HzYNih4YTw6clL5jeolJAdQSUBzxK06SAHR3fCL3g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111547; 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=o7CAb+ogG+3H7yztK1f86DJeBD3UUUveqIOvrGHZg+E=; b=urX4h5LsHsVvUY5e3769lt+i8vx6tN4ngFBtQLOXElqF6X4plbjo1hXCpDJ7d28foLJWG6 gkN5U7HAdbjsWbsj+bVcz5tS3/Aw8f0hI+I6/8sydyLmuH30A4q0GexN2CnHi/GNbxXLf9 I9Ozpd6FZjFWAr1GCc8LRNRseX7vK12DmjirN2OZbbl5kRv9a46/2+AaJw2qaxuLTz7Y/S 6m4CehX9VH7QPGm+htSpQ+i9eH2dxPiQF7utvrI+1a9dh07vvvTbFRa6PPdIa8aGXU1C9F qkDItTfjjXfHkHzzaec31vTAh08yZ2nwwpZvUPuf+4u7QgsCGdrGGgM6/ArZ0g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111547; a=rsa-sha256; cv=none; b=yDiTRvAxyCCDuQUxNZXytH7IcKnVYr8sHo51+glOQdhwmgOk3KjEFzeT0JsjLDutEOYZTV fi3EoMeZgogTmgEg0T90d0AEakjAdQS1VwKE5iEvSFRThiIELMJhYayY6sp3SETmzcsTju R1RpNzzBMX2ly8Hjvg0VG2/Eozdt8cneNSf/uD7N7xWxD9b5ZxYRLqFTeDDUPBBEaZCkak FC45vxzSHgBA8hwU/Q0sYB4+IE4O7d+FtquhYaxs9GyPgh5IN/Auo4C146wpxwgCyg6n6I dREVqYcHr4E+Ff5FNHjBBDW7QUOHUmBImdgB0PuZiwHWnGhAjde5glt4puKHdg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9R10Dsz9hN; Wed, 17 Sep 2025 12:19:07 +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 58HCJ7d2085820; Wed, 17 Sep 2025 12:19:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJ7qn085817; Wed, 17 Sep 2025 12:19:07 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:07 GMT Message-Id: <202509171219.58HCJ7qn085817@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: a207833f4fed - main - linux: Simplify further getgroups() after 'cr_gid' not in cr_groups[] 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a207833f4fed5431cac853c082fa34dc8f33cba6 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=a207833f4fed5431cac853c082fa34dc8f33cba6 commit a207833f4fed5431cac853c082fa34dc8f33cba6 Author: Olivier Certner AuthorDate: 2025-08-28 15:29:33 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:04 +0000 linux: Simplify further getgroups() after 'cr_gid' not in cr_groups[] No functional change (intended). While here, fix/improve style a bit and in setgroups(). MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52276 --- sys/compat/linux/linux_misc.c | 36 ++++++++++++++++-------------------- sys/compat/linux/linux_uid16.c | 36 ++++++++++++++++-------------------- 2 files changed, 32 insertions(+), 40 deletions(-) diff --git a/sys/compat/linux/linux_misc.c b/sys/compat/linux/linux_misc.c index 5e32353c6b8e..755eae057406 100644 --- a/sys/compat/linux/linux_misc.c +++ b/sys/compat/linux/linux_misc.c @@ -1028,18 +1028,19 @@ linux_nice(struct thread *td, struct linux_nice_args *args) int linux_setgroups(struct thread *td, struct linux_setgroups_args *args) { + const int ngrp = args->gidsetsize; struct ucred *newcred, *oldcred; l_gid_t *linux_gidset; - int ngrp, error; + int error; struct proc *p; - ngrp = args->gidsetsize; if (ngrp < 0 || ngrp >= ngroups_max) return (EINVAL); linux_gidset = malloc(ngrp * sizeof(*linux_gidset), M_LINUX, M_WAITOK); error = copyin(args->grouplist, linux_gidset, ngrp * sizeof(l_gid_t)); if (error) goto out; + newcred = crget(); crextend(newcred, ngrp); p = td->td_proc; @@ -1071,34 +1072,29 @@ out: int linux_getgroups(struct thread *td, struct linux_getgroups_args *args) { - struct ucred *cred; + const struct ucred *const cred = td->td_ucred; l_gid_t *linux_gidset; - gid_t *bsd_gidset; - int bsd_gidsetsz, ngrp, error; + int ngrp, error; - cred = td->td_ucred; - bsd_gidset = cred->cr_groups; - bsd_gidsetsz = cred->cr_ngroups; + ngrp = args->gidsetsize; - if ((ngrp = args->gidsetsize) == 0) { - td->td_retval[0] = bsd_gidsetsz; + if (ngrp == 0) { + td->td_retval[0] = cred->cr_ngroups; return (0); } - - if (ngrp < bsd_gidsetsz) + if (ngrp < cred->cr_ngroups) return (EINVAL); - ngrp = 0; - linux_gidset = malloc(bsd_gidsetsz * sizeof(*linux_gidset), - M_LINUX, M_WAITOK); - while (ngrp < bsd_gidsetsz) { - linux_gidset[ngrp] = bsd_gidset[ngrp]; - ngrp++; - } + ngrp = cred->cr_ngroups; + + linux_gidset = malloc(ngrp * sizeof(*linux_gidset), M_LINUX, M_WAITOK); + for (int i = 0; i < ngrp; ++i) + linux_gidset[i] = cred->cr_groups[i]; error = copyout(linux_gidset, args->grouplist, ngrp * sizeof(l_gid_t)); free(linux_gidset, M_LINUX); - if (error) + + if (error != 0) return (error); td->td_retval[0] = ngrp; diff --git a/sys/compat/linux/linux_uid16.c b/sys/compat/linux/linux_uid16.c index 1d9a19916412..07430f5b399b 100644 --- a/sys/compat/linux/linux_uid16.c +++ b/sys/compat/linux/linux_uid16.c @@ -85,12 +85,12 @@ linux_lchown16(struct thread *td, struct linux_lchown16_args *args) int linux_setgroups16(struct thread *td, struct linux_setgroups16_args *args) { + const int ngrp = args->gidsetsize; struct ucred *newcred, *oldcred; l_gid16_t *linux_gidset; - int ngrp, error; + int error; struct proc *p; - ngrp = args->gidsetsize; if (ngrp < 0 || ngrp >= ngroups_max) return (EINVAL); linux_gidset = malloc(ngrp * sizeof(*linux_gidset), M_LINUX, M_WAITOK); @@ -100,6 +100,7 @@ linux_setgroups16(struct thread *td, struct linux_setgroups16_args *args) free(linux_gidset, M_LINUX); return (error); } + newcred = crget(); p = td->td_proc; PROC_LOCK(p); @@ -133,34 +134,29 @@ out: int linux_getgroups16(struct thread *td, struct linux_getgroups16_args *args) { - struct ucred *cred; + const struct ucred *const cred = td->td_ucred; l_gid16_t *linux_gidset; - gid_t *bsd_gidset; - int bsd_gidsetsz, ngrp, error; + int ngrp, error; - cred = td->td_ucred; - bsd_gidset = cred->cr_groups; - bsd_gidsetsz = cred->cr_ngroups; + ngrp = args->gidsetsize; - if ((ngrp = args->gidsetsize) == 0) { - td->td_retval[0] = bsd_gidsetsz; + if (ngrp == 0) { + td->td_retval[0] = cred->cr_ngroups; return (0); } - - if (ngrp < bsd_gidsetsz) + if (ngrp < cred->cr_ngroups) return (EINVAL); - ngrp = 0; - linux_gidset = malloc(bsd_gidsetsz * sizeof(*linux_gidset), - M_LINUX, M_WAITOK); - while (ngrp < bsd_gidsetsz) { - linux_gidset[ngrp] = bsd_gidset[ngrp]; - ngrp++; - } + ngrp = cred->cr_ngroups; + + linux_gidset = malloc(ngrp * sizeof(*linux_gidset), M_LINUX, M_WAITOK); + for (int i = 0; i < ngrp; ++i) + linux_gidset[i] = cred->cr_groups[i]; error = copyout(linux_gidset, args->gidset, ngrp * sizeof(l_gid16_t)); free(linux_gidset, M_LINUX); - if (error) { + + if (error != 0) { LIN_SDT_PROBE1(uid16, linux_getgroups16, copyout_error, error); return (error); } From nobody Wed Sep 17 12:19:08 2025 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 4cRd9S5M1rz67HkF; Wed, 17 Sep 2025 12:19:08 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9S2DTrz3Vrh; Wed, 17 Sep 2025 12:19:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111548; 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=g+8ZM7+z4UGZ0z7HOu7C87IvlIyYzBWY/qwIEuNCEVM=; b=U9ILsUf/kCzl+gbhyQ45s3qmowCQaDh45sapuySgWM0OKgQWkVc1XWOCnsDBN/mBFoox90 VOy/Rf4FixjdTlI80bBj5ZpXZbqpcxbYNOnZJzSyc6g5e+tNvcY9gRmq1JsS/Cj/MAQjYx Je2/mnaNZfh547NkG6ZKLsNppoJJTdh+cvqB63veOiCcgpHiCWG8dYCxfu6tt07cRzLcBO XeN4Ka3mhYG8WioMq9ibYnlb2/u7NN1jEjVX9ky+tVi2BBk16rHV79KQDurhWztzIRKdCD YUvOqPk5vaTof84ZKWTN75JJMvChG54u4MZavrV2GOXUhevPX9REq0Wk/8QbXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111548; 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=g+8ZM7+z4UGZ0z7HOu7C87IvlIyYzBWY/qwIEuNCEVM=; b=JQuFvospFhoIEmSEiqQFmYOaPozFmXVpKBmmWX8GrB4ooxD7nshj0GtX7ZZtAPOptt5OMG VlC4suqxG667qeMSdpkoa4ghJHEc/Y/AMTH7eVQw8SNM8jP92W6qWLQAlH6MWsnM2B8Bjp gu30U8WzyZ/3C3Uauz3aqPSXbi2GH6IhZ0f8A+yj/InNPTJKMSTTl3caaecq/O7SLPO5KM ebX0VMd0PgTKNR3G5KKhpXk1/U7kjxWka4OFO8BinwmMytBtILt0fDfSu8wej2Ui442nWK 1RCD3lrnIwRAYvYCxhFhIlW/+t5TeyKda2UTYCZf4UinMO2U4UqtgxzP1g+WTw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111548; a=rsa-sha256; cv=none; b=c0Oke3dJ8zkbCoBcmQG9mksOkHx2qGZnw4AALppeMt2cVDErxialY58YE6Opmu71/P34DE WS50pc8XCIOo4TWpDWL4sCCl0fbcS+PB63B8LiEhJIh60n1POAd2nEEalBY2Tkm2nlmJnB Pi/8Q/RFDcxcu1wgcVCwxO4PYTwxDZvYt5W96LVw2BinfC4PsYmlXXZtb3zU6h/egvHqn1 lg5NIUm5Zcg6OUDM1J4ywW6eG95m5S3M4vWAm86asuzKEGC/qSb/mGeBQkmZvgbMT4BPI/ aRz5mBuug2jiLrsJ4cQI+IfuBpoab7+JiFu+SmyJapF+MGstQWBYnv/Y6/vECA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9S1fqkz8yp; Wed, 17 Sep 2025 12:19:08 +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 58HCJ8qa085853; Wed, 17 Sep 2025 12:19:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJ8Ow085850; Wed, 17 Sep 2025 12:19:08 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:08 GMT Message-Id: <202509171219.58HCJ8Ow085850@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: bbdea7c9f4ae - main - linux: setgroups(): Fix the group number's upper limit 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: bbdea7c9f4aeae26b35f842382df0203fcda24a5 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=bbdea7c9f4aeae26b35f842382df0203fcda24a5 commit bbdea7c9f4aeae26b35f842382df0203fcda24a5 Author: Olivier Certner AuthorDate: 2025-08-28 16:58:53 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:04 +0000 linux: setgroups(): Fix the group number's upper limit 'ngroups_max' is the maximum number of supplementary groups the system will accept, and this has not changed. Fixes: 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52277 --- sys/compat/linux/linux_misc.c | 2 +- sys/compat/linux/linux_uid16.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/compat/linux/linux_misc.c b/sys/compat/linux/linux_misc.c index 755eae057406..fb86de6e7302 100644 --- a/sys/compat/linux/linux_misc.c +++ b/sys/compat/linux/linux_misc.c @@ -1034,7 +1034,7 @@ linux_setgroups(struct thread *td, struct linux_setgroups_args *args) int error; struct proc *p; - if (ngrp < 0 || ngrp >= ngroups_max) + if (ngrp < 0 || ngrp > ngroups_max) return (EINVAL); linux_gidset = malloc(ngrp * sizeof(*linux_gidset), M_LINUX, M_WAITOK); error = copyin(args->grouplist, linux_gidset, ngrp * sizeof(l_gid_t)); diff --git a/sys/compat/linux/linux_uid16.c b/sys/compat/linux/linux_uid16.c index 07430f5b399b..dd681f971746 100644 --- a/sys/compat/linux/linux_uid16.c +++ b/sys/compat/linux/linux_uid16.c @@ -91,7 +91,7 @@ linux_setgroups16(struct thread *td, struct linux_setgroups16_args *args) int error; struct proc *p; - if (ngrp < 0 || ngrp >= ngroups_max) + if (ngrp < 0 || ngrp > ngroups_max) return (EINVAL); linux_gidset = malloc(ngrp * sizeof(*linux_gidset), M_LINUX, M_WAITOK); error = copyin(args->gidset, linux_gidset, ngrp * sizeof(l_gid16_t)); From nobody Wed Sep 17 12:19:09 2025 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 4cRd9T6MqMz67Hl3; Wed, 17 Sep 2025 12:19:09 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9T3Sbtz3Vdt; Wed, 17 Sep 2025 12:19:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111549; 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=vLg0ANXy9KTRAw4l5YoIz6EYh7USzf8XhKDplkgqfUI=; b=UAeC8W5Rx0Etsttnuc+51kxctjeGvX0GprhkDFC5/BmxnMUSNa22jsFcrP+3uDh6arjL3f d6Sf6LjfLJbhKoKFgrZwdBE7UFz9sMg8kkPt5WU8ipl/sXk7cgjurlEHP3xh9WpiW6WIlr 4rl2pggJWV6vHxdOjf0PjdAeJIo2HPcA7zP7TjraJBk9zWiXPGqkxAdwqNxbpA62ta8Kpl /qVXCzavJJ7M5rdoEIoFC/ksuIb2lMsSQgzSlHYvsilvteBLINyze2dPmPD19oApKQJmFh TMzillAYOGgGg6Vi/j3/3ohHIuJBqZHaXuAictT9nnmiQQ7zcIegTy/YRFkQ1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111549; 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=vLg0ANXy9KTRAw4l5YoIz6EYh7USzf8XhKDplkgqfUI=; b=AjeCHyubd6T+v+35rVMWfTSgYaYy37SkxfyHyj8kU82tyLKMtF8O0D/IA47L/jyu8S2kJ3 UhNXyLffjMlC1kbsmr5a3TDllpjDnX9BNcc2IN4ChavsO2ICJe0g6S5LIVajHeQ4OgJGRv r52OWqkKXZtI9FAEcOlHjyHdya1+95QuzdzSwKmTQDTzUsoRyUudDJZjQ0ASpDgB1tOvfr CaYDh1LgjU+yyPCvJl9CNWyv02cQZ3WVhlsd62aS3jd7N/7Hjt/r7aQ+xNilXrzsoXE763 5xtiEMKPYz7pk6qrEUlwg9J+w0OZCnSQ7uomPBooDDHXksJSEDlyimLtu3qWlw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111549; a=rsa-sha256; cv=none; b=N4ASfc3puxsAYlHaWAkjIeXRD5pgFJedsMqDIzLAtdcLVJXKzUa/D6faLzTerhSHDvd7H5 sV5vhS46dnADqowrFiwHW/ZM97YsU6Z/M36YQZoMBRA61EcCW/Ppf17L7XXg729qZb2doK 1oiAB+CVfJI/HHdaNBTf5DVN++CNsu1bH6s7pTFoz2dQJGFmJ6JVBbSXugz8d/x6642CNm X+QPm3E/yZgs3uN3zRLj0kddBe4TOt1JMI/b1Gt5UN+IGNrBvNHDP0QdbhJ1Z3HEohfEvu 0PAVcTu7Jv5VHejwKdM8QzDjZ5Z8jWi6sW2pCy5Z5B2Hu8Ty6j/rk2btpp46Vg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9T2zVzz8yq; Wed, 17 Sep 2025 12:19:09 +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 58HCJ9Pd085885; Wed, 17 Sep 2025 12:19:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJ9eO085882; Wed, 17 Sep 2025 12:19:09 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:09 GMT Message-Id: <202509171219.58HCJ9eO085882@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: b7a87d7c0dd1 - main - linux: setgroups(): Avoid allocation under the process lock 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b7a87d7c0dd19016e82f5d33f2c5ec90479c31fe Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=b7a87d7c0dd19016e82f5d33f2c5ec90479c31fe commit b7a87d7c0dd19016e82f5d33f2c5ec90479c31fe Author: Olivier Certner AuthorDate: 2025-08-28 15:47:38 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:04 +0000 linux: setgroups(): Avoid allocation under the process lock This was missed in commit 838d9858251e ("Rework the credential code to support larger values of NGROUPS (...)"). No functional change (intended). MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52278 --- sys/compat/linux/linux_misc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sys/compat/linux/linux_misc.c b/sys/compat/linux/linux_misc.c index fb86de6e7302..0925ffb64480 100644 --- a/sys/compat/linux/linux_misc.c +++ b/sys/compat/linux/linux_misc.c @@ -1045,8 +1045,7 @@ linux_setgroups(struct thread *td, struct linux_setgroups_args *args) crextend(newcred, ngrp); p = td->td_proc; PROC_LOCK(p); - oldcred = p->p_ucred; - crcopy(newcred, oldcred); + oldcred = crcopysafe(p, newcred); if ((error = priv_check_cred(oldcred, PRIV_CRED_SETGROUPS)) != 0) { PROC_UNLOCK(p); From nobody Wed Sep 17 12:19:10 2025 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 4cRd9W1FpNz67Hn9; Wed, 17 Sep 2025 12:19:11 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9V4Zmjz3W1P; Wed, 17 Sep 2025 12:19:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111550; 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=JoWA9LS9i4hQ6/DdMoLGyFjIP5WHLUEveviNtOrLJVc=; b=KqjxYCpwCz0XX77uTtWRhykr4oWbDpAm4ev9K9cCzIN/avQujT3CEt7+shjwn+lJSPToe/ StD7Ymoe4x5WtrKTLmPZGH1dW9uUcWpz38X2i856LL9JhquX411Q5V4wIxUKFLRizqqk5n Yq0toEc5+QqU/sM6c0dYrAYcxq00V2eLjBf1IUVLdGpIyLY8uaYWorIrYQzClLjlg9Rpil Vh5XJGiFe4SkuKzlImRehgYUel9ujtT9DIwFdFQC1funmhxpe0TaOcq1btHFMrFfMPJ3Gi RNYofQSeM5o/J2cpX0kDN/CLCO2YHdAh+ceYNALOOsqu/7FdEvGszTj/UCHLCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111550; 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=JoWA9LS9i4hQ6/DdMoLGyFjIP5WHLUEveviNtOrLJVc=; b=ROo46mpPweGG5+tRkL0x+Wd1x68zyizIekAYw+eC1QleirfMv1VaeifloX50iJOTTzeHcf lDgQdjfRYvvgA/dwz+1l1P6Ef0Cfyaz9eAMF1IVtLT11F7C2r2M/psz+569VS8/vbki/mk UkXtdJB/urgFBVAh25H3uFQ31kFbu2StY31oFITKas1znVH+/iBcssE9HcV7g/eAT7pnBr s5CNPeyDVdJWn03he63Yk0gCUDRZedHZuO1HNhaaeZs/OPHEjXRy6z+d/251lodmqh+ZCF fhvPjHNpOlcsaqBIO9bx31DtbthOJYeySfKLxLPDbx87tiyx0L1G+DzZ1zv/NQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111550; a=rsa-sha256; cv=none; b=UXay9GinYj6wvlgtLHMLKvQYf3w3YZug773ZEb5CWbnazWOmaTnqeoOknwShlC0NYDZ6tL l8bzF0YxiPkFHGRDbSZkF5/v7xN9aIsOFpwjyFs6/VulKcpP5BvrOZ/QX6DG2hFnUGEpf6 STigrv81dz06tGoO2YMKrdw8CwLFCa6kRcQkn5S8qoQv/hDE3W7fsTvfT7J/7dgfc289lI HyP8YfRrDhJrx2U9hW//OMg2KdgbkSiuMmmog/uxpxJI0NV8ZmwzM9exiZNjuFVgVuLT8i dCRdO1NoDWWAAfQq494b4xpTW5e3004iN7l5gnCHuTmMbNCVPj8wc8Nuoa9MmA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9V42cJz9Lq; Wed, 17 Sep 2025 12:19:10 +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 58HCJAwq085925; Wed, 17 Sep 2025 12:19:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJAdv085922; Wed, 17 Sep 2025 12:19:10 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:10 GMT Message-Id: <202509171219.58HCJAdv085922@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: b1326edddb30 - main - linux: setgroups16(): Pre-extend the groups array 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b1326edddb302a28fc9418ab60df6210513cc07c Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=b1326edddb302a28fc9418ab60df6210513cc07c commit b1326edddb302a28fc9418ab60df6210513cc07c Author: Olivier Certner AuthorDate: 2025-08-28 16:27:30 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:05 +0000 linux: setgroups16(): Pre-extend the groups array For the size we know we will need in the end. No functional change (intended). MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52279 --- sys/compat/linux/linux_uid16.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/compat/linux/linux_uid16.c b/sys/compat/linux/linux_uid16.c index dd681f971746..8ac093e004d0 100644 --- a/sys/compat/linux/linux_uid16.c +++ b/sys/compat/linux/linux_uid16.c @@ -102,6 +102,7 @@ linux_setgroups16(struct thread *td, struct linux_setgroups16_args *args) } newcred = crget(); + crextend(newcred, ngrp); p = td->td_proc; PROC_LOCK(p); oldcred = crcopysafe(p, newcred); From nobody Wed Sep 17 12:19:11 2025 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 4cRd9X0zbpz67HsY; Wed, 17 Sep 2025 12:19:12 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9W5XpGz3W60; Wed, 17 Sep 2025 12:19:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111551; 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=EGsqyloQozuUdMOCFGGBKlvpbY944sDuUAZzGYMowCE=; b=mnUHZ8DmBjTiUF+YWmG9blCxE4hZ74xtMrpPMc1PkHvmG9gKdKRac4d8NAGkEJBwARvz1q P81+Ww/YK/0bMHwtsLgFeOYV+JiSyLmfqdZDh6HxxxKp13Qs46+IlqxYccWFK114szgLWK 7piDkGENgG96N3W48duCw39Nu1aCyolFUVDXfDdWZvhRRfClTTkARtm7oQfYazBwm3mFgj uL9JlvH+25/IR3s9rMaOwNIBsp2FswMdhVJXuvpnqDIQ0AUYQ7wDvuorG57N2/MRwW2l93 vQ0i3ZzyRa3klJiXokRqF1b6ednOL4VT+nrcto2mo5oD/sgOd9fDLYg0C382ag== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111551; 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=EGsqyloQozuUdMOCFGGBKlvpbY944sDuUAZzGYMowCE=; b=JQwpq/TZAlLhUxniCQ3iyC0DtDNtt3uw4rXCTzmMO0TyLxWn4SUUpm/S2i2612G9xcBxA/ 13TejpLZgsj8+uXnkyovnPOT+SpaUh7YoaC3VNY/O3fNlJEhvqrYPKysrFpP0HnpN2Pier HVNH9Xba0jG2SqFZmdTmcCXcQKjtVAvRqnAulIveSeam3E6YXC4cwjpvDqVjhPvC27LGE0 KKJg8U/aRuq+wRXjZPOXE5Ww78xdec9sL+z2VQ+eV7uav9MGmQJagwim6HE0Tf6UiaYx4D 6D2Cwn8eYaaSq05lGa/gURGeYZy406vwoDTiqxEL2e4QiMnuCjfZmTAwR50+ig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111551; a=rsa-sha256; cv=none; b=oRWUgyh9ZXsZa4U811GJeOTY94LqgdtqcdLwQVFT6s4G/PVuBlDh1bEMu1+5uZ7BtZGQqE 2iSibbKgDcFMdCZufIaWi0PbbI1TWDd/mSlF4rPVcg4I/imcF4bOP0RCnMEsZXeZzyZHHN wy+ZQPk0HrhUZCVLtX+9empSdi2+uDdOkFVNmRKGu55bDSkMO9mThztX/Z7aQ4EooQHwhb Sg1HwfiTpmD28cQFov9ZoFVaiys+36oH8KL+qnGRq9Giu4vESbNVVBpJ37Z4kvGSRzYQZT IP7FUitI1DBDNRo/D4qFlcjrHK0PId7gvAIm2kydJ88WwtaQG4PGjxwrW7O65A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9W4lNsz9Lr; Wed, 17 Sep 2025 12:19:11 +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 58HCJBR7085957; Wed, 17 Sep 2025 12:19:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJBun085954; Wed, 17 Sep 2025 12:19:11 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:11 GMT Message-Id: <202509171219.58HCJBun085954@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 10b789d7e148 - main - linux: getsockopt(): Simplify exporting groups a bit 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 10b789d7e14862c77f77f07e8af84d73d73012c6 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=10b789d7e14862c77f77f07e8af84d73d73012c6 commit 10b789d7e14862c77f77f07e8af84d73d73012c6 Author: Olivier Certner AuthorDate: 2025-08-29 08:26:59 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:05 +0000 linux: getsockopt(): Simplify exporting groups a bit No functional change (intended). Go through conversion to a 'l_gid_t' before copying out in order to cope with differing group types (except for not representable values, of course). This is what is done, e.g., for getgroups() in 'linux_misc.c'. As Linux's group type is the same as ours on all architectures, we could as well just stop bothering and copy out our memory representation, eliminating the loop here. Whatever the choice, though, it has to be consistent here and there. Introduce 'out' of type 'l_gid_t' to avoid performing "by hand" array arithmetics when copying out. MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52280 --- sys/compat/linux/linux_socket.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sys/compat/linux/linux_socket.c b/sys/compat/linux/linux_socket.c index 539d153431c4..0e07b0a60ced 100644 --- a/sys/compat/linux/linux_socket.c +++ b/sys/compat/linux/linux_socket.c @@ -2179,6 +2179,7 @@ static int linux_getsockopt_so_peergroups(struct thread *td, struct linux_getsockopt_args *args) { + l_gid_t *out = PTRIN(args->optval); struct xucred xu; socklen_t xulen, len; int error, i; @@ -2197,13 +2198,12 @@ linux_getsockopt_so_peergroups(struct thread *td, return (error); } - /* - * "- 1" to skip the primary group. - */ + /* "- 1" to skip the primary group. */ for (i = 0; i < xu.cr_ngroups - 1; i++) { - error = copyout(xu.cr_groups + i + 1, - (void *)(args->optval + i * sizeof(l_gid_t)), - sizeof(l_gid_t)); + /* Copy to cope with a possible type discrepancy. */ + const l_gid_t g = xu.cr_groups[i + 1]; + + error = copyout(&g, out + i, sizeof(l_gid_t)); if (error != 0) return (error); } From nobody Wed Sep 17 12:19:12 2025 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 4cRd9Y1X9cz67Hl7; Wed, 17 Sep 2025 12:19:13 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9X6sC3z3W3s; Wed, 17 Sep 2025 12:19:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111553; 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=BFbND0ROnMWoODz6bd8YdVPma3aJ3Ia2L06mWr0wwt0=; b=pLp7XQnZfhgIFQ+YgyqUoVnFBS/5xs+RMjSoV/6dV8ubgzvvtVCyxKpRIGE62ET+lqQPdO OmhW/MUqTddMyb/VPZ5Kp3uO+qND5YCMm1AjJDbdd3mPrFD6jO6RUu6YHtkMQ0HvloBYOy 7IxUQMvWKcjXsaqkyCx47iAfxCCNxBy0+QbEHNQR+B6482PB+AaSXN2CvIgfhHQo+8Ws2U 2w7IDQn2CK/HU1TrxHPjHEM7quRFeM7o9qZn9FpIHBZ+NN+/CjoGo0JjS+geQUBUVgIaDY BnoKkttpg3y2LDwMVB8qJ2c0hPZ6uJnckYnC1wMwi44+b5ZrIRMDI+GwdA5sRg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111553; 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=BFbND0ROnMWoODz6bd8YdVPma3aJ3Ia2L06mWr0wwt0=; b=EZdskRPxxA7iRVQ46oS+tFppg+AVAqwK1ytVz9CQ8+uzxOT+2f0GZTvCI+ILgVaVl5eZx7 mpO2hwILN+RZs5fIW2gQIjudHa0+5MTW+j9yT92EoiZAm7jW46N9ZJkTiLtu/vSOrzg77c 1qV+Jn058QgoJcmA6YuCeEZshwBoxtHxhuQ5IslYDLLH1qFbz1t+YMVGdc7NaIKDJxY+72 1cMGDIap0j8oZvA71T1F5w97DFzE/ckTohZkD8+1BleDnq/jePwPtx2cF7cPdiVCeyjhCH l4GcHXzv3umCyXUIcnYCsUGvQcZXQhpLWPouuQLqBqx3MtUgzmqZaburTlardg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111553; a=rsa-sha256; cv=none; b=Zn2qqe0WM/ndCTFB+EJGrE0LDw+ZixXEXmNO+cYJZDxptVUfNyczAQFNYEhLixQ2gXtWT1 dFbV/lx7HJ4xdV1HTMGxhBYkc4M8L/xckBNO5rs8kufwlr+aCDVbWrATL9YLW9gpbhsZte 6kfEArP902spTs+7oYmoHo8cHbq2uW2/OkxxV03RUyNm9avnQN1SXLQ/NttJF8tiwSp7Bf SBZpKdJ8eGybVxC3BvoTWoSPqpCKaZAi8htAXSSSBMbPYX2IfHwsYQqM6uH2vtyPf07ZFX /krVDAoM65XcKmxA+sUqLMxhsa37AW8Xx052hnevQp0tva6FBFTS2d/tV8vqwA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9X5tF3z9jy; Wed, 17 Sep 2025 12:19:12 +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 58HCJCrg085989; Wed, 17 Sep 2025 12:19:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJCsr085986; Wed, 17 Sep 2025 12:19:12 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:12 GMT Message-Id: <202509171219.58HCJCsr085986@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 59049f4b47ea - main - hastd: Remove some now useless assertion 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 59049f4b47ea8924ffae7c3c7b9e8c00a79285e0 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=59049f4b47ea8924ffae7c3c7b9e8c00a79285e0 commit 59049f4b47ea8924ffae7c3c7b9e8c00a79285e0 Author: Olivier Certner AuthorDate: 2025-08-29 08:21:38 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:05 +0000 hastd: Remove some now useless assertion It is in fact redundant with the previous one, as the set of supplementary groups is expected to be empty. MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52281 --- sbin/hastd/subr.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/sbin/hastd/subr.c b/sbin/hastd/subr.c index add1280e960b..084ea50dae7c 100644 --- a/sbin/hastd/subr.c +++ b/sbin/hastd/subr.c @@ -156,7 +156,6 @@ drop_privs(const struct hast_resource *res) struct passwd *pw; uid_t ruid, euid, suid; gid_t rgid, egid, sgid; - gid_t gidset[1]; bool capsicum, jailed; /* @@ -285,7 +284,6 @@ drop_privs(const struct hast_resource *res) PJDLOG_VERIFY(egid == pw->pw_gid); PJDLOG_VERIFY(sgid == pw->pw_gid); PJDLOG_VERIFY(getgroups(0, NULL) == 0); - PJDLOG_VERIFY(getgroups(1, gidset) == 0); pjdlog_debug(1, "Privileges successfully dropped using %s%s+setgid+setuid.", From nobody Wed Sep 17 12:19:13 2025 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 4cRd9Z3gmdz67Hdy; Wed, 17 Sep 2025 12:19:14 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9Z0Q2jz3Vt9; Wed, 17 Sep 2025 12:19:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111554; 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=7TVqo877zx5suwP1K9ZqbuKhIevoCu++ddLAMR9S2Hc=; b=mfCOvPNhGVKWLeEAxdM+WKteRQ+S6z7XCb9KBv50PVj6Iv7StQucQfcJf8yqOQdLxP4FOL zXSotAMn3+cAzyQhkYr5r388lN1KejfPGQwHLy+Dw8vxR2VOly0YLHGE4YdWw28BHDn9Sm tRNJTMFVSnt0FK5R9q/KX0j/NUvheFdkO/g5ViiXh8GG4b8T62cFC/W+yV/MZA3W8972xG wBeYM08KbOsaCb6SIhBkPF7jC7cf01hzT62QXhLWoEdUy/1TWPpOD9A/45REzNVceW9G2L oaAuPu802fZP7iN58zdXHZ/HUaPWjb5PRyHnysuUrNMKRXzw8WPTRwqdUBMZKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111554; 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=7TVqo877zx5suwP1K9ZqbuKhIevoCu++ddLAMR9S2Hc=; b=fmrUmzdSMMWzjwlJXVMo4kMYLZObII2EtSltkBfPccvJr7b+wzDCHu2euxULg6mVi3KJP3 3lbnDuc2VYFNYSK7XNcuNKWjsUCSKOiDbhSKuwUKDlnp4dZO+v5UEX9DGXXNaGjfToRAkp Vu9BTQDyEjif65ojwv1BHbVqRSpvWeM6c9xOUKSDkWBRrGW8fc4sIDD/c2E/TU8RHnDgfN f32MdSXwOGqF/CoPJA1cmz8G4vuByiO4K1Yio/gjNQXRGCdKwGnHZBdiWFZ66Ir1cXRZ53 R858ygtTrg1rPFUNEVO0p65m1t4Du3B/0+SM6P/dZobXINmRfhQRK22aqUu+pQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111554; a=rsa-sha256; cv=none; b=e0RGGDo6XRCg9GnJEngoSkKtREnowEukI2UphVlsPsmV85/H6PIRMM5pfxpMmlecITG/iC iTo8346p8RKBJxIvYuSekJbqwzJ2rvaLZ5A8ivywLW09tZPnydqTV7SAenIa2GKsmSTCWX 3CMg0BrAI4LcVJkWaW4XuaIbc2BJUlfOitA+TJ/85p2iy6VeR6qzLNgQpGrlR7TC8IIG4e 0SjKjoeXCMedykPDSxQ7PcC0q6nkAsWdkiw9oUjVjiWBl11DYNBG3qNcvu1RCWcKj9YyYd DjdR2qJBC1By3Kr2EV8mY470H1idAanKbIxA3DiaGSlQOTXShVHPEvyGPdp9Qg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9Y74w7z9hP; Wed, 17 Sep 2025 12:19:13 +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 58HCJD7F086021; Wed, 17 Sep 2025 12:19:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJDsX086018; Wed, 17 Sep 2025 12:19:13 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:13 GMT Message-Id: <202509171219.58HCJDsX086018@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 696cfb27ca4e - main - syscalls: Old setgroups(2)/getgroups(2): Remove superfluous STD type 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 696cfb27ca4e60ebd49c45355a8a9c4945f84f98 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=696cfb27ca4e60ebd49c45355a8a9c4945f84f98 commit 696cfb27ca4e60ebd49c45355a8a9c4945f84f98 Author: Olivier Certner AuthorDate: 2025-09-12 12:27:43 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:06 +0000 syscalls: Old setgroups(2)/getgroups(2): Remove superfluous STD type An examination of the scripts under 'sys/tools/syscalls' indicates that keeping STD as a type in the presence of COMPATxx does not make any difference, and regenerating system call files with STD removed does indeed not show any difference. Moreover, this practice is inconsistent with the rest of the file. Thus, remove the superfluous STD type for the two above-mentioned system calls. While here, re-order the remaining types for getgroups() to be consistent with other such occurences (COMPATxx before CAPENABLED). Reviewed by: kevans, emaste MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52499 --- sys/kern/syscalls.master | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/kern/syscalls.master b/sys/kern/syscalls.master index 911f9093824b..967af1f5313c 100644 --- a/sys/kern/syscalls.master +++ b/sys/kern/syscalls.master @@ -552,13 +552,13 @@ _Out_writes_bytes_(len/PAGE_SIZE) char *vec ); } -79 AUE_GETGROUPS STD|CAPENABLED|COMPAT14 { +79 AUE_GETGROUPS COMPAT14|CAPENABLED { int getgroups( int gidsetsize, _Out_writes_opt_(gidsetsize) gid_t *gidset ); } -80 AUE_SETGROUPS STD|COMPAT14 { +80 AUE_SETGROUPS COMPAT14 { int setgroups( int gidsetsize, _In_reads_(gidsetsize) const gid_t *gidset From nobody Wed Sep 17 12:19:16 2025 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 4cRd9c5BjBz67Hsh; Wed, 17 Sep 2025 12:19:16 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9c2TFqz3Vyr; Wed, 17 Sep 2025 12:19:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111556; 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=qcBbuHgzZRET/YtftAoERB2dRdsOlhdN6okMRzBSAsE=; b=QrYizEhm4uhWL2YO3zevNAhoV3xS2fO3xJft0V+m959Lm0+TyWSq49plmjf16f6eGJgAro J1nGrrT9XUi9/zCmxHLaRKWbRFrAfiuaVquT/vLniQILLh7ya1XVgF4R7fTvey4EcuvUSh +lwT0laCsmFXSFDRK9vz7Ar6MPsRyQ+/+1TcdQHgAOitsTF4+eaS1EGJsWfXuHFGiuQdWL 4fLoD5l0l8R80ECaClkwSpZplpeyff5fmd16q/daLnUr3IogcIuAP48EUmBWSKV13CYpZ5 81+FHkMfEMs1GJ4LpyEcagp4trkT2KQALcTITYdD3bRzPy4jZmhS5f9QBOBl3A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111556; 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=qcBbuHgzZRET/YtftAoERB2dRdsOlhdN6okMRzBSAsE=; b=WTEI0mL9X0p2Rly5S+t66xpN8DLKeWUOeFjPcTgQeDBkgKFKpp2Mkcx8Ddraaeknzbgf/u vlRfYanjWc5F4tHeXwp8TEt67iierS7+XQoBPMrhsryCdsd5RhGuh4trrefhxGZfsJNv6l 7xlfKdeS+1Kuk8I3lMDsI+B4itzSSbRXi7BdqffdTKyYvhY8FaWdUVRD4QNSWA8UnnJgJW 97ufv6wOcIRFZCXXljkjajkoliNeDh23NVpJ3mENy/ImvOhb/BjIXEB3JHnf9n2WeeQNQm sG2SUmk3VTZGRuWtJdjQ1ASAfzbcvt7Q489pvN5uJ0F+ez6qAMb5lTrAUXkhMw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111556; a=rsa-sha256; cv=none; b=E+IGoiAgIvViy27XSUkFPIbSh1mCMjDZBPeVsdGS6GxjhKlY49afYswwQl9pbtGDg7xMHz IUiW8+YB763Ct9C0xWcPyTZVEI9YMq5c2D70B39h0Gf7wQ0C8LdtJR8oYWKYtisvM70ut6 blI52I7xmOWdOsFBnW+JVXdzqPcyAmQHC1SCgeQktxd8D/lVVI0Rm7bzVqKFNH1eLNqAmg V57d/+LoG13YfXjj8a3Y2TdwTmhgrp+tPT7ZovDIqSMITsbB50vmdhmwcCpibEh4gzSYqx pfVTWSRExFoVohhC5aVpHtLjBEqfsEtPyOC50rTNtr+FjhJnSl7FbTn7MxJncA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9c236Mz9Ls; Wed, 17 Sep 2025 12:19:16 +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 58HCJGB3086092; Wed, 17 Sep 2025 12:19:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJGuA086088; Wed, 17 Sep 2025 12:19:16 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:16 GMT Message-Id: <202509171219.58HCJGuA086088@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 9dc1ac869196 - main - initgroups(3): Add a pre-FreeBSD-15-compatible version 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9dc1ac8691966480ff8bd9c37dd405b981b41dd5 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=9dc1ac8691966480ff8bd9c37dd405b981b41dd5 commit 9dc1ac8691966480ff8bd9c37dd405b981b41dd5 Author: Olivier Certner AuthorDate: 2025-08-29 14:19:33 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:06 +0000 initgroups(3): Add a pre-FreeBSD-15-compatible version After commit 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms"), initgroups() does not set the effective GID anymore and uses all passed groups as the supplementary group list. This effectively breaks backwards compatibility with programs/libraries compiled on a FreeBSD 14 or earlier system. Restore compatibility by creating a new version of the 'initgroups' symbol that designates the current implementation and providing a pre-FreeBSD-15-compatible version under the symbol's previously exported version. The new version calls the new setgroups(2) system call, while the compatible one calls the original one (called freebsd14_setgroups()). Update the manual page with some history and comparison with other current open-source systems. Add a "SECURITY CONSIDERATIONS" section highlighting some security properties of this approach and the reasons we adopt it. While here, revamp the manual page, in particular to use the exact POSIX terminology where possible. Note for MFC to stable/14: Only the manual page update is to be MFCed, and the text changed to reflect the old behavior and inform readers of the new upcoming behavior in 15. Reviewed by: kib Fixes: 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms") MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52282 --- lib/libc/gen/Symbol.map | 2 +- lib/libc/gen/gen-compat.h | 2 + lib/libc/gen/initgroups.3 | 101 +++++++++++++++++++++++++++++++++++++++------- lib/libc/gen/initgroups.c | 44 +++++++++++++++----- 4 files changed, 124 insertions(+), 25 deletions(-) diff --git a/lib/libc/gen/Symbol.map b/lib/libc/gen/Symbol.map index 26f638568efc..494b65bc5cc1 100644 --- a/lib/libc/gen/Symbol.map +++ b/lib/libc/gen/Symbol.map @@ -193,7 +193,6 @@ FBSD_1.0 { __isinff; __isinfl; isatty; - initgroups; jrand48; lcong48; ldexp; @@ -462,6 +461,7 @@ FBSD_1.8 { fdscandir_b; fts_open_b; glob_b; + initgroups; inotify_add_watch; inotify_init; inotify_init1; diff --git a/lib/libc/gen/gen-compat.h b/lib/libc/gen/gen-compat.h index 08e80ede6b6e..dac8f54b45a2 100644 --- a/lib/libc/gen/gen-compat.h +++ b/lib/libc/gen/gen-compat.h @@ -52,4 +52,6 @@ int freebsd11_getmntinfo(struct freebsd11_statfs **, int); char *freebsd11_devname(__uint32_t dev, __mode_t type); char *freebsd11_devname_r(__uint32_t dev, __mode_t type, char *buf, int len); +int freebsd14_setgroups(int gidsize, const __gid_t *gidset); + #endif /* _GEN_COMPAT_H_ */ diff --git a/lib/libc/gen/initgroups.3 b/lib/libc/gen/initgroups.3 index 03bd07494fc9..4f538fb180ec 100644 --- a/lib/libc/gen/initgroups.3 +++ b/lib/libc/gen/initgroups.3 @@ -1,5 +1,13 @@ +.\"- +.\" SPDX-License-Identifier: BSD-3-Clause +.\" .\" Copyright (c) 1983, 1991, 1993 .\" The Regents of the University of California. All rights reserved. +.\" Copyright (c) 2025 The FreeBSD Foundation +.\" +.\" Portions of this documentation were written by Olivier Certner +.\" at Kumacom SARL under sponsorship from the FreeBSD +.\" Foundation. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions @@ -25,12 +33,12 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd October 26, 2014 +.Dd September 17, 2025 .Dt INITGROUPS 3 .Os .Sh NAME .Nm initgroups -.Nd initialize group access list +.Nd initialize supplementary groups as per the group database .Sh LIBRARY .Lb libc .Sh SYNOPSIS @@ -40,19 +48,18 @@ .Sh DESCRIPTION The .Fn initgroups -function -uses the -.Xr getgrouplist 3 -function to calculate the group access list for the user -specified in +function initializes the current process' supplementary groups as prescribed by +its arguments and the system's group database. +.Pp +It first uses the +.Fn getgrouplist +function to compute a list of groups containing the passed +.Fa basegid , +which typically is the user's initial numerical group ID from the password +database, and the supplementary groups in the group database for the user named .Fa name . -This group list is then setup for the current process using -.Xr setgroups 2 . -The -.Fa basegid -is automatically included in the groups list. -Typically this value is given as -the group number from the password file. +It then installs this list as the current process' supplementary groups using +.Fn setgroups . .Sh RETURN VALUES .Rv -std initgroups .Sh ERRORS @@ -60,7 +67,7 @@ The .Fn initgroups function may fail and set .Va errno -for any of the errors specified for the library function +to any of the errors specified for the library function .Xr setgroups 2 . It may also return: .Bl -tag -width Er @@ -77,3 +84,67 @@ The .Fn initgroups function appeared in .Bx 4.2 . +.Pp +The +.Fn initgroups +function changed semantics in +.Fx 15 , +following that of +.Xr setgroups 2 +in the same release. +Before that, it would also set the effective group ID to +.Fa basegid , +and would not include the latter in the supplementary groups except before +.Fx 8 . +Its current behavior in these respects is known to be compatible with that of +the following systems up to the specified versions that are current at time of +this writing: +.Bl -dash -width "-" -compact +.It +Linux (up to 6.6) with the GNU libc (up to 2.42) +.It +.Nx 1.1 and greater (up to 10) +.It +.Ox (up to 7.7) +.It +Systems based on illumos (up to August 2025 sources) +.El +.Sh SECURITY CONSIDERATIONS +As +.Fa basegid +is typically the user's initial numerical group ID, to which the current +process' effective group ID is generally initialized, processes using functions +to change their effective group ID +.Pq via Xr setgid 2 or similar +or that are spawned from executables with the set-group-ID mode bit set will not +be able to relinquish the access rights deriving from being a member of +.Fa basegid , +as these functions do not change the supplementary groups. +.Pp +This behavior is generally desirable in order to paper over the difference of +treatment between the effective group and supplementary ones in this situation, +as they are all in the end indiscriminately used in traditional UNIX +discretionary access checks. +It blends well with the practice of allocating each user its own private group, +as processes launched from a set-group-ID executable keep the same user and +consistently stay also in the same user's group. +Finally, it was also chosen for compatibility with other systems +.Po +see the +.Sx HISTORY +section +.Pc . +.Pp +This convention of including +.Fa basegid +in the supplementary groups is however only enforced by the +.Fn initgroups +function, and not by the +.Xr setgroups 2 +system call, so applications expressly wanting to include in the supplementary +groups only those specified by the group database can themselves call +.Fn getgrouplist +and then +.Fn setgroups +on the result with the first element skipped +.Pq see Xr getgrouplist 3 . diff --git a/lib/libc/gen/initgroups.c b/lib/libc/gen/initgroups.c index 55f17a94fa8e..a1a7d92250e2 100644 --- a/lib/libc/gen/initgroups.c +++ b/lib/libc/gen/initgroups.c @@ -3,6 +3,11 @@ * * Copyright (c) 1983, 1993 * The Regents of the University of California. All rights reserved. + * Copyright (c) 2025 The FreeBSD Foundation + * + * Portions of this software were developed by Olivier Certner + * at Kumacom SARL under sponsorship from the FreeBSD + * Foundation. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -29,22 +34,28 @@ * SUCH DAMAGE. */ -#include +/* For __sym_compat(). */ +#include #include #include #include -int -initgroups(const char *uname, gid_t agroup) +/* For freebsd14_setgroups(). */ +#include "gen-compat.h" + +static int +initgroups_impl(const char *uname, gid_t agroup, + int (*setgroups)(int, const gid_t *)) { - int ngroups, ret; - long ngroups_max; gid_t *groups; + long ngroups_max; + int ngroups, ret; /* - * Provide space for one group more than possible to allow - * setgroups to fail and set errno. + * Provide space for one group more than possible to allow setgroups() + * to fail and set 'errno' in case we get back more than {NGROUPS_MAX} + + * 1 groups. */ ngroups_max = sysconf(_SC_NGROUPS_MAX) + 2; groups = malloc(sizeof(*groups) * ngroups_max); @@ -52,8 +63,23 @@ initgroups(const char *uname, gid_t agroup) return (-1); /* malloc() set 'errno'. */ ngroups = (int)ngroups_max; - getgrouplist(uname, agroup, groups, &ngroups); - ret = setgroups(ngroups, groups); + (void)getgrouplist(uname, agroup, groups, &ngroups); + ret = (*setgroups)(ngroups, groups); + free(groups); return (ret); /* setgroups() set 'errno'. */ } + +int +initgroups(const char *uname, gid_t agroup) +{ + return (initgroups_impl(uname, agroup, setgroups)); +} + +int +freebsd14_initgroups(const char *uname, gid_t agroup) +{ + return (initgroups_impl(uname, agroup, freebsd14_setgroups)); +} + +__sym_compat(initgroups, freebsd14_initgroups, FBSD_1.0); From nobody Wed Sep 17 12:19:15 2025 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 4cRd9b60PZz67Hwg; Wed, 17 Sep 2025 12:19:15 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9b1Wllz3W98; Wed, 17 Sep 2025 12:19:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111555; 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=1wpl+NUW4cCp3kpMmoIGsBE2uXCXCSy04aKH4xNAnww=; b=LlRBrme24hJH6Tk9WPd4QjotxToC3bv5ZzNZ6kZaXYWSZ9HLZ0BMKUSAErhAGU41kcOLyr DtYOu0ei4x7IGNM5Z97smNqOU3UAUHZS75lq5odwzcznsrEu/p53rwfBFYw/pcR+1Sf6u+ NiZpmelMz6VV+8mrsIa2ml4S8ynKvJGfH5Xl9UZXzHiVCgFI3Sn4tneHj5PSRetwKi37ZN S2ybwNVy34zR9ZL6c4vnCTkEzYP/89Wo9dzk1EjYcq+qmIaovesDKNRCfTsZO44RTo9gk3 So0ebadpkQzJINX5E1zTItySGYZwYpp03BHfA3xGPeLFwjIL0ComYHFIJFMGEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111555; 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=1wpl+NUW4cCp3kpMmoIGsBE2uXCXCSy04aKH4xNAnww=; b=GqTbyDlJUFB/p2GcNfjlNwnveVterawn9/qOg80WW2w1Byo05fmQqEsWGNRsszg0LTt5Nc ImSqsBEHCRQISWcPVPOqDt2UrQrAzIwQ+I44JcV81t87XWHoZuUb8HsnQy580h6LCfcOE6 DO4cM7W6yMGxvVsSMj5mm13nsflHeQYCFzWKk/+82qbz1D4tAUYQcGvcjIkXdY9fc3WzMP 4xSeH5YY2oRd9i1XiZnO7Jf4+VhTtA8uWwCk5FbLaF6fDfcxv3oWltGMiUZfIfUGxB9m9i usaisveKm3Pv2DXG5okRcEXMjAEgkzwz7YIzClz0pVt87E7T0X/pRTV2aNubmQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111555; a=rsa-sha256; cv=none; b=rqdbfE+Ymdg2VhmZoyVY2M0d33Ag856G4NdT1+HJLew/tPOHODK6GYc5RPUh8xcbFCwL7n RS1rU7+Ow499BhGh8yJTn78LIJfSjEL97wx5w0Sg+tQg23ukP6bYXds7+CgT9Bu0qJK0Z8 mqImiQesnq/DhBbmO5uctnq0pirUaAZucFBwuj+Buob4ZL8S6Esgu//2iTXQji+yliMpYU XlbxKEc4QaY55jXgPW/lnKirrUbt61eMPV05WkXrMvD1FlMp7Q4i4Luqg4BL1N76KUzYbo UlgZs7PXr3x+kTYR62kxar3hPlKlXQlZgIQptlMXBl+/xDUmoCQjTGJ5MhO8yQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9b10n1z9G6; Wed, 17 Sep 2025 12:19:15 +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 58HCJF2e086053; Wed, 17 Sep 2025 12:19:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJF90086050; Wed, 17 Sep 2025 12:19:15 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:15 GMT Message-Id: <202509171219.58HCJF90086050@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 0b018cfd81d8 - main - initgroups(3): Fix return value on allocation failure 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0b018cfd81d8fdd64af3fe94c6989a82c0d3afa9 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=0b018cfd81d8fdd64af3fe94c6989a82c0d3afa9 commit 0b018cfd81d8fdd64af3fe94c6989a82c0d3afa9 Author: Olivier Certner AuthorDate: 2025-09-16 15:52:20 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:06 +0000 initgroups(3): Fix return value on allocation failure We must not return ENOMEM, but rather -1 with 'errno' set to ENOMEM, as described in the manual page and as other implementations are doing. A malloc() failure actually already sets ENOMEM for us. Add comments indicating which function set 'errno' each time we return. While here, improve style and remove useless headers. Reviewed by: kib, emaste Fixes: 54404cfb13d4 ("In preparation for raising NGROUPS and NGROUPS_MAX, ...") MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52580 --- lib/libc/gen/initgroups.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/lib/libc/gen/initgroups.c b/lib/libc/gen/initgroups.c index b6697dd7ed8f..55f17a94fa8e 100644 --- a/lib/libc/gen/initgroups.c +++ b/lib/libc/gen/initgroups.c @@ -31,11 +31,7 @@ #include -#include "namespace.h" -#include -#include "un-namespace.h" #include -#include #include #include @@ -51,12 +47,13 @@ initgroups(const char *uname, gid_t agroup) * setgroups to fail and set errno. */ ngroups_max = sysconf(_SC_NGROUPS_MAX) + 2; - if ((groups = malloc(sizeof(*groups) * ngroups_max)) == NULL) - return (ENOMEM); + groups = malloc(sizeof(*groups) * ngroups_max); + if (groups == NULL) + return (-1); /* malloc() set 'errno'. */ ngroups = (int)ngroups_max; getgrouplist(uname, agroup, groups, &ngroups); ret = setgroups(ngroups, groups); free(groups); - return (ret); + return (ret); /* setgroups() set 'errno'. */ } From nobody Wed Sep 17 12:19:17 2025 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 4cRd9f25Ftz67Hwv; Wed, 17 Sep 2025 12:19:18 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9d3bm0z3W07; Wed, 17 Sep 2025 12:19:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111557; 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=w7qiQRjTMl5Qoqas796/9+iypYsP/ygYByK8gcgv0N4=; b=wU2S67zRW8SAkYwjgRorzSPp503TuOkektJA+Ni+CNLFykfeqA2Tdtd5P5Oaqqlr+qhVTY FClRmfzSf30J2yvvm7TyVTochTcms0GpzSVsb9LZo5HZ4zY7XIvlNitXucgFXTxOthiwJg Td8yfvm76IUWEiXckOME+Mv0/Ygx/k1Ak/sBP0AW60qvmUStfVW6NAfBgvntj5ekVFFP/9 3MwN7V1OVM8rXImN5kpQ9O6Q10HF5XtY9+ZxiC0+l/I242vLXyYMYu+NfIS2XKMhjgHL0b akNp/9MNP5mS/FqgC3NMFgctlbZkXDNkb78tufSa+JYAvxlt9gGAPAM1ZARpcQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111557; 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=w7qiQRjTMl5Qoqas796/9+iypYsP/ygYByK8gcgv0N4=; b=H6cqOJxZcO4GFtb3E1tHoP+0jmkzDSqQzHNwJBPSUy+Gstbw+WqeV5ih98ND91VdgItx9p 0aG0YyvnhvMN5B7W06g2Buu+e7oxbk8tW9xOcVlxtTRIIoVUUsPbBLyP6h1oJv5GVdOPfE Epa9HXXoss1+4s3WS4dY2H1cZGR0N5er4kE60U40zpKuRvYlodeYGbP2bLZj35mYFWtDK5 o/jH5TPhinD67dpv2IO7lXm0LN2st+nTRctGl64WXMeyj6haJg3wrROLoRUunLtq2OoIRP 5B9w0K9A0ozID5523S93e9jj9izmciQmBqmM1UjPkMN2yFrXtY904Oe1/hAFiQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111557; a=rsa-sha256; cv=none; b=mM8CGMRijXUU3dgmb1MncISszT7eD482M4nSQqLCWP+RvJgdpRQgfInHI2PshUu+6iIMi3 qu6ef6otfjE91LcNLmFBduy6JfuvNb922PDSQcP8pM2jB7va9zfhDVPFyCzhk2hzxS/Hwt mq16o5o3lF1TV7/T3WMzMFYX6AE3boqVDf7O4tvdH7n7jWhDvwurE2chT15Q6C4GI2qwY1 IFXwxc2qD4LgyBjV3bNKTX7tpwnByINGMceSU7Nm6u97noFiT2bTUAI71HuwobaDrODNZG QDg+an8XGkpEKTa9KWpy0KNvrM8pYKaqelI6PTnoctsaE4aHogAvxDYjVLBgxw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9d2kgqz9Jj; Wed, 17 Sep 2025 12:19:17 +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 58HCJHpv086124; Wed, 17 Sep 2025 12:19:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJHHb086121; Wed, 17 Sep 2025 12:19:17 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:17 GMT Message-Id: <202509171219.58HCJHHb086121@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 9294eb44eecb - main - getgrouplist.3: Rework, use more appropriate terminology 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9294eb44eecb71f573f29ff84ce1bd3aa93c077c Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=9294eb44eecb71f573f29ff84ce1bd3aa93c077c commit 9294eb44eecb71f573f29ff84ce1bd3aa93c077c Author: Olivier Certner AuthorDate: 2025-08-29 14:53:52 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:07 +0000 getgrouplist.3: Rework, use more appropriate terminology Bring up to date with NSS by substituting "file" with "database". Describe more precisely which database is accessed, i.e., only the group database, which value should be used and where it lands in the result. Prefer a terminology referring to POSIX terms, i.e., use "effective group list" instead of "group access list". Reviewed by: gbe MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52283 --- lib/libc/gen/getgrouplist.3 | 29 +++++++++++++++++++---------- 1 file changed, 19 insertions(+), 10 deletions(-) diff --git a/lib/libc/gen/getgrouplist.3 b/lib/libc/gen/getgrouplist.3 index e9a980f99751..e3939fc2481a 100644 --- a/lib/libc/gen/getgrouplist.3 +++ b/lib/libc/gen/getgrouplist.3 @@ -1,5 +1,13 @@ +.\"- +.\" SPDX-License-Identifier: BSD-3-Clause +.\" .\" Copyright (c) 1991, 1993 .\" The Regents of the University of California. All rights reserved. +.\" Copyright (c) 2025 The FreeBSD Foundation +.\" +.\" Portions of this documentation were written by Olivier Certner +.\" at Kumacom SARL under sponsorship from the FreeBSD +.\" Foundation. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions @@ -25,12 +33,12 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd October 26, 2014 +.Dd August 29, 2025 .Dt GETGROUPLIST 3 .Os .Sh NAME .Nm getgrouplist -.Nd calculate group access list +.Nd produce a user's effective group list .Sh LIBRARY .Lb libc .Sh SYNOPSIS @@ -40,16 +48,16 @@ .Sh DESCRIPTION The .Fn getgrouplist -function reads through the group file and calculates -the group access list for the user specified in -.Fa name . -The +function reads through the group database to retrieve the supplementary groups +for the user specified in +.Fa name , +and returns the effective group list, whose first group is the value of +.Fa basegid +and the others are the retrieved supplementary groups. .Fa basegid -is automatically included in the groups list. -Typically this value is given as -the group number from the password file. +typically is the user's group number from the password database. .Pp -The resulting group list is returned in the array pointed to by +The effective group list is returned in the array pointed to by .Fa groups . The caller specifies the size of the .Fa groups @@ -70,6 +78,7 @@ Here, the group array will be filled with as many groups as will fit. group membership list .El .Sh SEE ALSO +.Xr setcred 2 , .Xr setgroups 2 , .Xr initgroups 3 .Sh HISTORY From nobody Wed Sep 17 12:19:18 2025 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 4cRd9g27Twz67Hnk; Wed, 17 Sep 2025 12:19:19 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9f4HXXz3WGF; Wed, 17 Sep 2025 12:19:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111558; 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=bfmwp3DTh9Gcp7JnoXlAiUogyYF+a4u2zEbWbItomvc=; b=knotl7VJuyUlCTXLFe6rsJN3DTi9WpnnWLUqYTMBOIQAICva0PuQsm+vXxBvOraZ/NJ2Z1 CRC4VFAEl4t0e1qJlKh0sHr3Ql1+Ylvu0H6U5/GO9JnBJA+XkEJTqj0jvTLHBcKPlqD8Mp vcis2qmBpbTl0HlN5Tg2GJ24fQEhemFuxhWnyQVoYv/36WhJZHt0JNxeyBolFEB45Lrgn8 LS2GeoFOvm5wkkRj6qfoqyRONlyo1RALytsKYa0YlL/4gUTsvVqt0OHGOCraHOnwD+IDVS Ek7EWPiMUw/crVjHICiRBNioihFTtA1AkyqsXgup8t7r7M+kTklRl0ptV9u2oA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111558; 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=bfmwp3DTh9Gcp7JnoXlAiUogyYF+a4u2zEbWbItomvc=; b=YB14YWBr+1uBhohluG0Nhn0N8reA8ULRVHsPFM0098NSvE8fygu+cYft0XJeVnWXx5Ea3S RPq9DxL1V3uEeREtUUDd8c/c6bLp0ypwuC0fO3fkJvVqQ80A5PaZaRilPp71MwslMvc47X Q7yxvxXfdwtlOqR7RF58eKt3LV+x6WIogH/lThEK/zjOuV7/lBpGK2ALlyWd1aMK0zXS/M GcAD/PvgXd4YqlGcImJDASyXa2CgqKma9nmRgwn3qSdwy1T5WbBFm0Njc40d3MnzReUdP/ 2RzXGk46eboZPDbTAhmwaKRrWjfvn5uZByLLFMPLmn0KEpRFgCGKYZGegEWkuA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111558; a=rsa-sha256; cv=none; b=V0uUkx3QUerDspBYgmXTOUBhkII9/26swX5JNsoulssgOmgF1jfRi/I07gEeX6XvwBaWnr /VjKEez3zkozSIigAecQgoifjTZ5QJrgFUMn+NgbvICZAeNWmJ9gWeAxfyhbaTVfk++tsv YLkweuMTTZ14hyNSPbYftESHD/YfIIGE8d4za+7ANsviKlPYEH0rH1BqfN7JYhe6P+sClV jpH1Um3ddEGuxAzdhLI8RoAq/uVQuKCt5tiJqOHtTXutSdm8XzIOGd5ifclzLcGDbcMZZw k9A9xLSVdH9kkZsuQlOEGsoNHzdAPiEusW8AZEC15lmfnWjikp62XJDbWY0VTQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9f3YLmz9Jk; Wed, 17 Sep 2025 12:19:18 +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 58HCJI8T086158; Wed, 17 Sep 2025 12:19:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJI1N086154; Wed, 17 Sep 2025 12:19:18 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:18 GMT Message-Id: <202509171219.58HCJI1N086154@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 6d22cd6b5f8b - main - setgroups.2: Add SECURITY CONSIDERATIONS, fix the groups limit, rework 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6d22cd6b5f8b5604f1fe9e70930b1506f990e31e Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=6d22cd6b5f8b5604f1fe9e70930b1506f990e31e commit 6d22cd6b5f8b5604f1fe9e70930b1506f990e31e Author: Olivier Certner AuthorDate: 2025-08-29 15:10:22 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:07 +0000 setgroups.2: Add SECURITY CONSIDERATIONS, fix the groups limit, rework Add a new SECURITY CONSIDERATIONS section describing in details what the new behavior is after commit 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms"), what setgroups(2) does not do anymore, and how programs using it are affected. Fix the groups limit after commit 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms"). Prefer a terminology referring to POSIX terms, i.e., use "effective group list" instead of "group access list". While here, fix some style. Note for MFC to stable/14: The content will have to be revised as the new behavior is not in place. The latter should still be mentioned as upcoming in 15. Fixes: 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms") MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52284 --- lib/libsys/setgroups.2 | 99 ++++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 83 insertions(+), 16 deletions(-) diff --git a/lib/libsys/setgroups.2 b/lib/libsys/setgroups.2 index 451f63ba1266..0ec99507cfb0 100644 --- a/lib/libsys/setgroups.2 +++ b/lib/libsys/setgroups.2 @@ -1,5 +1,13 @@ +.\"- +.\" SPDX-License-Identifier: BSD-3-Clause +.\" .\" Copyright (c) 1983, 1991, 1993, 1994 .\" The Regents of the University of California. All rights reserved. +.\" Copyright (c) 2025 The FreeBSD Foundation +.\" +.\" Portions of this documentation were written by Olivier Certner +.\" at Kumacom SARL under sponsorship from the FreeBSD +.\" Foundation. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions @@ -25,12 +33,12 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 1, 2025 +.Dd September 17, 2025 .Dt SETGROUPS 2 .Os .Sh NAME .Nm setgroups -.Nd set group access list +.Nd set the calling process' supplementary groups .Sh LIBRARY .Lb libc .Sh SYNOPSIS @@ -41,21 +49,21 @@ .Sh DESCRIPTION The .Fn setgroups -system call -sets the supplementary group list of the current user process -according to the array -.Fa gidset . +system call sets the calling process' supplementary groups according to the +.Fa gidset +array. The .Fa ngroups -argument -indicates the number of entries in the array and must be no -more than +argument indicates the number of entries in the array and must be no more than .Dv {NGROUPS_MAX} . +.Pp The .Fa ngroups -argument may be set to 0 to clear the supplementary group list. +argument may be set to zero to clear all supplementary groups, in which case +.Fa gidset +is ignored. .Pp -Only the super-user may set a new supplementary group list. +Only the super-user may install a new supplementary groups set. .Sh RETURN VALUES .Rv -std setgroups .Sh ERRORS @@ -69,16 +77,16 @@ The caller is not the super-user. The number specified in the .Fa ngroups argument is larger than the -.Dv {NGROUPS_MAX}+1 +.Dv {NGROUPS_MAX} limit. .It Bq Er EFAULT -The address specified for +Part of the groups array starting at .Fa gidset -is outside the process -address space. +is outside the process address space. .El .Sh SEE ALSO .Xr getgroups 2 , +.Xr setcred 2 , .Xr initgroups 3 .Sh HISTORY The @@ -92,4 +100,63 @@ the .Fn setgroups system call would set the effective group ID for the process to the first element of -.Fa gidset . +.Fa gidset , +and only the other elements as supplementary groups. +Despite treating the first element as the effective group ID to set, it accepted +an empty +.Fa gidset +.Po +.Fa ngroups +being zero +.Pc +as a stance requiring to drop all supplementary groups, leaving the effective +group ID unchanged. +.Sh SECURITY CONSIDERATIONS +The +.Fn setgroups +system call sets the process' supplementary groups to those contained in the +.Fa gidset +array. +In particular, as evoked in +.Sx HISTORY , +it does not anymore treat the first element of +.Fa gidset +separately. +Formerly, it would set it as the effective group ID while only the others were +used as supplementary groups. +.Pp +Programs solely relying on +.Fn setgroups +to change the effective group ID must be modified, e.g., to also call +.Xr setegid 2 +or to instead use +.Xr setcred 2 , +else they will unwillingly keep their effective group ID. +.Pp +Programs using +.Fn setgroups +with the effective group ID as the first element of array +.Fa gidset +and not duplicating it in the rest of the array, which includes those using +.Fn initgroups , +now insert this group ID in the supplementary groups set. +This is in general desirable, as explained in the +.Xr initgroups 3 +manual page, and has the consequence that subsequent process' effective group +ID's changes do not remove membership of the original effective group ID, since +these changes do not affect the supplementary groups. +Applications that expressly do not want that must be modified to stop passing +the effective group ID as the first element to +.Fn setgroups . +.Pp +To clear all the calling process' supplementary groups, always use the statement +.Bd -literal -offset indent +setgroups(0, NULL); +.Ed +.Pp +which works also on older FreeBSD version +.Po +see the +.Sx HISTORY +section +.Pc . From nobody Wed Sep 17 12:19:19 2025 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 4cRd9g5w5Dz67HZ1; Wed, 17 Sep 2025 12:19:19 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9g56nkz3WJ8; Wed, 17 Sep 2025 12:19:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111559; 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=4VfLVyAJi29/xOo6J6m8obfFP3DFqS3aGFfa0OspLTQ=; b=MyG1KVHfr8yikCgboGsDlw7narx/BJcghpYp5/s8O/UtrtN1hL2d2VQioBCrCMm1lVBtJt vPZHSPE6+53ktGHKWXTXyiG+Qf48Jh8oIwlYTR/IGFQqEjEfyzkhIdpXA6vZ20UiebdNU7 EaPhxo0qxElhzm9T3WXiYA9+mPCx/MdRtX5CZJ26JFsgtOnLHX6VnrwRVXKq0DmcRncBy3 XFFhh6aYc1E3f0MGmFkUXsB8AsPzsySFJykA9sDKimB3VtnWRROl/XNpsCFp97RUB5V0dr zkcnSKKRbWI0AB/84o/kWxJhZ/TFjb2W0WBSqTazUGXv/eNQ4yJariUFpxSsjQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111559; 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=4VfLVyAJi29/xOo6J6m8obfFP3DFqS3aGFfa0OspLTQ=; b=vMe7ULstI5koADtpNfq7CrUrG+O2Mfudgg804Gf9XeAnbSCwgc+LEZGNZyPewaxuJRcpVr X835j1rkIyiO9J3EswJpH2FAkbKqDKqpLoQ4vfiRp/3d3myXc2VsoHifGrQSJiLyOXiwJS MJREKOAEzUSY9JGBiWPn1QkIdjgG9dEsb+X827iLyVeZ22twooYAJgUgkVzFIF1j03kdiu Rjc14LLUipZ4PF0kqk3ZnwaweaWBPufPbWfKP58SvVvxlaAwDx+g6K045+IsQZohlt8lCD OMqBmTafzntblKtp00w/4hCEtzdT8jLavlcJzqlP0sStE5Dk0Y9QBtrvLJJyDQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111559; a=rsa-sha256; cv=none; b=OD4y96OnwdrbEbGfI+xAnsvH+GadXMhzZdD2kRbTeHSujrYaF9OUu7wwh0a6Ses48nMzD+ MGHOKyvs/AivHOa8WyAR3JS/S03t6maW694EsARa6tw0iDi+0vRv2CYQqeZirLO7YLdWco PfxEvc4bw/C2qoAjeTaCJ++gQjLxsffysa4ett7cZ2atHZBsieWXN7a8oFrb4ckKNGX6L8 78ctAGXYf75BqMWIwqQz7jMngGOCk+LnZU+4gydj7zfMDlFXYEnUbyjaMNCsbqMwAiarLi CYMCHJ+b01Mmr7DVKLLIe4Zy8nl5jHu6skMmnLSvsnHYTW+ms9yOAyiJjnsP9A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9g4dVZz9hQ; Wed, 17 Sep 2025 12:19:19 +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 58HCJJ4C086191; Wed, 17 Sep 2025 12:19:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJJOh086188; Wed, 17 Sep 2025 12:19:19 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:19 GMT Message-Id: <202509171219.58HCJJOh086188@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 66b54c48b2ae - main - setcred.2: Remove now obsolete mention of setgroups(2)'s different behavior 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 66b54c48b2ae1c1759134cad5daa6fc27b679918 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=66b54c48b2ae1c1759134cad5daa6fc27b679918 commit 66b54c48b2ae1c1759134cad5daa6fc27b679918 Author: Olivier Certner AuthorDate: 2025-08-29 15:12:59 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:07 +0000 setcred.2: Remove now obsolete mention of setgroups(2)'s different behavior Reviewed by: gbe Fixes: 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms") MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52285 --- lib/libsys/setcred.2 | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/lib/libsys/setcred.2 b/lib/libsys/setcred.2 index 86f61ddfdb30..f5d1f15b631b 100644 --- a/lib/libsys/setcred.2 +++ b/lib/libsys/setcred.2 @@ -6,7 +6,7 @@ .\" This documentation was written by Olivier Certner .\" at Kumacom SARL under sponsorship from the FreeBSD Foundation. .\" -.Dd December 19, 2024 +.Dd August 29, 2025 .Dt SETCRED 2 .Os .Sh NAME @@ -119,11 +119,6 @@ It must be less than or equal to An array of IDs to set the supplementary groups to, if flag .Dv SETCREDF_SUPP_GROUPS is specified. -Note that all groups in this array will be set as supplementary groups only, in -contrast to -.Xr setgroups 2 -which treats the first element specially as the new effective group, not adding -it to supplementary groups. .It Fa sc_label A pointer to a valid MAC label structure, e.g., built with the .Xr mac_from_text 3 From nobody Wed Sep 17 12:19:20 2025 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 4cRd9j0zJTz67HlY; Wed, 17 Sep 2025 12:19:21 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9h6HhFz3W7V; Wed, 17 Sep 2025 12:19:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111560; 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=PoIYu/seOYm/edXC8Hv+X4tEgI+BoR5gQY3XBItZRMs=; b=B58xU3mVNIsGw9MLZH4qZdIpbLfayVvJPw+MygoN7UXoVA1LximVuGI6Jwqfo4ghNhmuht IXivK0jwUS6N41mEcu4pYWmE/KdfJ/k9AC5OoYSy80mLrZC4R34MS6ctibWvLb9wmQ9943 n4GII1WHILRzDkdIWTiboV/RGB28NwLsK9wpIVwMgoTNOor2TNs1Brz7sLkeB+J8XmlFGT 7L7XkGV6nzvD3BS9Tqrxu3zy8j8chkcjigEZN3H65J0QxXh1uPH+2Zi6yxuro6bQrt0fXm 1V7Hv8Kosb68y48GaZXUIg2bjmh5F1tc6926YGfyeMH8H8ag25iHr7+s5xefxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111560; 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=PoIYu/seOYm/edXC8Hv+X4tEgI+BoR5gQY3XBItZRMs=; b=Sb2wJcGRN0q0pWjwx9wj3NfMPjJfWHpewpasHKw97iHANFYx5tzo6j2xEAD8ktU9BFZjBs Vh8FR1NK8Fe+2tzKc/3ZhTorDmzKcHRmbWqygXzw4su7RyVEBhlSxgPPCBwquzYkgNDHlG 1d3L+JTOBNimwDCgfVr1vvkzagJpQ9k/3/kifIkbgiDYLAeoAAj2zSMbuUSAzSFPUCC75F aasn9D7aHbZcoVJNrejFj+LfeRfdCy65j2ov2uYuNdAvDXsgM10rGypFQ4Wb9dYJMB86uy 6JeO5y3tJjCCl+cpl0zB+EAJ6bMawGNRzykRi1ZetZLg5bvxVR0YmCDRiuTcFg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111560; a=rsa-sha256; cv=none; b=fcuno5i8yViXdIXYT3zJomSTLCG1uEQYtBLPCloX9FqCUU2Gb67FoGiOZnJ5zRGFkg0A2C 1DA/P7sCRJmUAiO7OggB/BCKUscRJ+gA18t7+jBPAJ4EzA/hzv9hp9coy84Z91i3IVK9Kb 0wW5Pi/lDf/sVKPXLPzQGNpmrYBhNztbOwz7Qs0CBK5hv0Mgy4+0bediu3adennz4nambj eOpJBFeYm+Jwkz408YSZPrJJBzhTO7+8pPnduVLmIJqbL1N5XRvU+5eJwuQhgm3OGIPSeD n/8t5Bf+oRPuY1MeikHls4BEH580p1+inyDyXt7b4/PiXP3zlGvE8Skm3d1Wtg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9h5r5Pz9k0; Wed, 17 Sep 2025 12:19:20 +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 58HCJKN5086224; Wed, 17 Sep 2025 12:19:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJKhn086221; Wed, 17 Sep 2025 12:19:20 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:20 GMT Message-Id: <202509171219.58HCJKhn086221@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 4be38acc826f - main - getgroups.2: Clarify, mention ascending order, add SECURITY CONSIDERATIONS 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4be38acc826f260e4c7d3ebbb9de534db449782e Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=4be38acc826f260e4c7d3ebbb9de534db449782e commit 4be38acc826f260e4c7d3ebbb9de534db449782e Author: Olivier Certner AuthorDate: 2025-08-29 22:43:10 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:08 +0000 getgroups.2: Clarify, mention ascending order, add SECURITY CONSIDERATIONS Clarify and be more precise about the behavior of getgroups(2), in particular with respect to 'gidsetlen'. Prefer a terminology referring to POSIX terms, i.e., use "supplementary groups" instead of "group access list". Say that getgroups(2) reports the supplementary groups in strictly ascending order and returns the cardinal of the set they form (and mention this has been the case since FreeBSD 14.3). Add a new SECURITY CONSIDERATIONS section contrasting the new behavior after commit 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms") with the historical one. While here, fix some style. Note for MFC to stable/14: The content will have to be revised as the new behavior is not in place. The latter should be mentioned as upcoming in 15. Reviewed by: gbe (older version) MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52286 --- lib/libsys/getgroups.2 | 94 +++++++++++++++++++++++++++++++++++++------------- 1 file changed, 70 insertions(+), 24 deletions(-) diff --git a/lib/libsys/getgroups.2 b/lib/libsys/getgroups.2 index 37c8fbad7215..4881a65d532e 100644 --- a/lib/libsys/getgroups.2 +++ b/lib/libsys/getgroups.2 @@ -1,5 +1,13 @@ +.\"- +.\" SPDX-License-Identifier: BSD-3-Clause +.\" .\" Copyright (c) 1983, 1991, 1993 .\" The Regents of the University of California. All rights reserved. +.\" Copyright (c) 2025 The FreeBSD Foundation +.\" +.\" Portions of this documentation were written by Olivier Certner +.\" at Kumacom SARL under sponsorship from the FreeBSD +.\" Foundation. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions @@ -25,12 +33,12 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 1, 2025 +.Dd September 17, 2025 .Dt GETGROUPS 2 .Os .Sh NAME .Nm getgroups -.Nd get group access list +.Nd get the calling process' supplementary groups .Sh LIBRARY .Lb libc .Sh SYNOPSIS @@ -40,36 +48,39 @@ .Sh DESCRIPTION The .Fn getgroups -system call -gets the current supplementary groups of the user process and stores it in the -array -.Fa gidset . -The +system call gets the calling process' supplementary groups and stores them in +the +.Fa gidset +array in strictly ascending order. +The value of .Fa gidsetlen -argument -indicates the number of entries that may be placed in +indicates the maximum number of entries that may be placed in .Fa gidset . -The -.Fn getgroups -system call -returns the actual number of groups returned in -.Fa gidset . -As many as {NGROUPS_MAX} values may be returned. +.Pp If .Fa gidsetlen is zero, .Fn getgroups -returns the number of supplementary group IDs associated with -the calling process without modifying the array pointed to by +returns the cardinal of the calling process' supplementary groups set and +ignores argument .Fa gidset . .Pp +No more than +.Dv {NGROUPS_MAX} +values may ever be returned. The value of .Dv {NGROUPS_MAX} should be obtained using .Xr sysconf 3 to avoid hard-coding it into the executable. .Sh RETURN VALUES -A successful call returns the number of groups in the group set. +On success, the +.Fn getgroups +system call returns the cardinal of the supplementary groups set. +It always succeeds if argument +.Fa gidsetlen +is zero. +.Pp A value of -1 indicates that an error occurred, and the error code is stored in the global variable .Va errno . @@ -81,12 +92,12 @@ are: .It Bq Er EINVAL The argument .Fa gidsetlen -is smaller than the number of groups in the group set. +is smaller than the number of supplementary groups +.Pq but not zero . .It Bq Er EFAULT -The argument +An invalid address was encountered while reading from the .Fa gidset -specifies -an invalid address. +array. .El .Sh SEE ALSO .Xr setgroups 2 , @@ -96,16 +107,51 @@ an invalid address. The .Fn getgroups system call conforms to -.St -p1003.1-2008 . +.St -p1003.1-2008 +with the additional properties that supplementary groups are reported in +strictly ascending order and the returned size coincides with the cardinal of +the set. .Sh HISTORY The .Fn getgroups system call appeared in .Bx 4.2 . .Pp +Since +.Fx 14.3 , +the +.Fn getgroups +system call has treated the supplementary groups as a set, reporting them in +strictly ascending order and returning the cardinal of the set. +.Pp Before .Fx 15.0 , the .Fn getgroups -system call always returned the effective group ID for the process as the first +system call would additionally return the effective group ID as the first element of the array, before the supplementary groups. +.Sh SECURITY CONSIDERATIONS +The +.Fn getgroups +system call gets the supplementary groups set in the +.Fa gidset +array. +In particular, as evoked in +.Sx HISTORY , +it does not anymore retrieve the effective GID in the first slot of +.Fa gidset . +Programs should not make any assumption about which group is placed in the first +slot of +.Fa gidset +other than it being the supplementary group with smallest GID. +.Pp +The effective GID is present in the supplementary groups set if and only if it +was explicitly set as a supplementary group. +The function +.Fn initgroups +enforces that, while the +.Fn setgroups +system call does not. +Please consult the +.Xr initgroups 3 +manual page for the rationale. From nobody Wed Sep 17 12:19:21 2025 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 4cRd9l1gnwz67HZC; Wed, 17 Sep 2025 12:19:23 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9j72f3z3WH6; Wed, 17 Sep 2025 12:19:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111562; 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=gFhuQ5gDrHEXSwDnmILdSEZ2fHvjgnPfFSTDC5OpEGI=; b=Wz2ABbE7/BB7ye+95E0MVCLc2BuUlz+Bd43Z8jdr92DjlqUDR+ON+jmPN4XCT0JX8xpV+3 SXf0uji74wjXWCrwfFNb4qnBrwlDLI0CpYiqDjcm3t6lDS6tKSqMkaDB/G6JorBgLHKBAe o7kwdWRdLh74Xd3xwqojxXDOtR5NhACvX0sGWYY7/9++q9ox7CwbWTfvdf+8Bw6V/YDX2k y9GqTmnExVhPHWmocSABbdjpmXq4Vtn5fy9w3Pql3wxCbSc+1Cjyd25QhM1j1xqIV2ePUI Yo6PvaSGsE4Im9uuj6MhPR7mL1pWD/22FHgZITZeWfLMbOpLHeG7apm9MCOYpw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111562; 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=gFhuQ5gDrHEXSwDnmILdSEZ2fHvjgnPfFSTDC5OpEGI=; b=dxKzzhtMoBjZREqa//Hg9y+y0TmvxWol+ITVOxh7DQ6KTnhVE1eIyR6aOVB2lH5fsCxGtr uM3oOjxSTjtb0zmmNHWJvQjhg2JoQasZLXJxPVU+ZNqciOzwFNpvL1wIoQs6WydEKsCGiR Mf5koNKqIT1JPxSBWt9wx2LpE0qPzvdDSx8frbmQwBV/kQRH5LaJtT3UNJgfo3xem+wX3X RO7o/Bcma3uy53ZjPT7xjXwKHqtT6pY/JlllyRcnUbmFajn3bGFemEAbd8shJA40EPcjPq LUJ8hZzfcdPpdLf7hsWSyhJWnFgn80ZmECMgNDmWIp11cOUns0xYI36Gj/bFCg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111562; a=rsa-sha256; cv=none; b=e3GCv7peS5IyTaNGWH3WKeM692gXqOv8y4fA7LE/lgsUdWLaKql6VydJZIsjFVi1QPCbPQ MSGF8lB6aLP12e4+7FtYstjA+tGOHN66d7g9pVtFVpUMtINDaKyuxVmIcEGH/s7qbgb16O 8uW5PQviy8lDXw0qKgm2KpBZlLQrOhuvAxekG0lqwEooNKKFmlY9E5aHgBNXJkksCfHvHk nyCd4Ublp7fmprmbQsdLDl9Ml1vaKeOajuvCTBi2i8gDz49GyfzqNcJWnovVEtftis/Sda QYjzUJZ2W5BOmC/D7s2UsaGfkRvhIT5qnwo6uLISFAzuuW4bUl2F63Ele+ti2g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9j6VQrz9G7; Wed, 17 Sep 2025 12:19:21 +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 58HCJLXx086263; Wed, 17 Sep 2025 12:19:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJLoC086260; Wed, 17 Sep 2025 12:19:21 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:21 GMT Message-Id: <202509171219.58HCJLoC086260@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 313d769e995c - main - group.5: Add a reference to setcred(2) 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 313d769e995c4fa4c5e3ae2470af16a8fbeaa3c1 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=313d769e995c4fa4c5e3ae2470af16a8fbeaa3c1 commit 313d769e995c4fa4c5e3ae2470af16a8fbeaa3c1 Author: Olivier Certner AuthorDate: 2025-08-29 15:13:17 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:08 +0000 group.5: Add a reference to setcred(2) Reviewed by: gbe MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52287 --- share/man/man5/group.5 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/share/man/man5/group.5 b/share/man/man5/group.5 index 044164a3c955..8f7c59c59d52 100644 --- a/share/man/man5/group.5 +++ b/share/man/man5/group.5 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd February 8, 2013 +.Dd August 29, 2025 .Dt GROUP 5 .Os .Sh NAME @@ -145,6 +145,7 @@ may still have this limit. .Sh SEE ALSO .Xr newgrp 1 , .Xr passwd 1 , +.Xr setcred 2 , .Xr setgroups 2 , .Xr crypt 3 , .Xr getgrent 3 , From nobody Wed Sep 17 12:19:22 2025 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 4cRd9l4s65z67Hp5; Wed, 17 Sep 2025 12:19:23 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9l0kBgz3WDZ; Wed, 17 Sep 2025 12:19:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111563; 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=EkiVm8zqhAFk2iBKhB8cwDkE+NoSMfDYs7Q0h+iio3M=; b=BMds/5PPWs9rDjU9uih/MsnewoU+EFmk4aEOuN+KmtWX1gKzdnAK/cqu7EH1V9Wdq+G2cg ekqDtNkmATucF7R0c5TVdgRR4OlB/+xUGDDt8WrXCn9YHaDn60V5HdWSW8pY8aNsIWg7ex vET724d2knucceAgkJ/kSZl2cmPc2ABQn8PLs9UEUujdMIvc0yo6kYcNpF+qHlhto1T+tq bI1hXGmeK2G67D1ZLKHYgvdPo8n6Nk05C+q2FfxToHdw5nLrvhj+P/HCXO1m8SMphTvNuH F5eWDERcY8w875fl4poJSaW5gGCoaxAHZk7QWkjjWSoHGAGTAcg1Ea1R4i+wcQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111563; 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=EkiVm8zqhAFk2iBKhB8cwDkE+NoSMfDYs7Q0h+iio3M=; b=gSkRXzYDge4YCchBs0d96aaHSwwrCVrcAStessT/iOoYDA4b6bDWDNOom4C673VLi4zsnO /2iKrtKrSNLszPrDxVmH09H72wHiGf/G3nprFAvPTWoy4f1mOUcj9RUzof9lAfmFHEHSBQ GAhzY6P5dxhh8jRxjFfQkg4HU/MikoKA2UoLZNHTieFItR+8FoSvIJA737fwNqtjl6vliy xEEeFenhdOGZxNsGPAupOhX7D2nNbn2YP9Qsxj+wM6J1394OghfuPCm73wqoMglXlsz21o xoI3cmTIKr4OAmBK5YC9OPSsfw83E0GzZBpv7yccZg17L+269tBpprZsf0aHvw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111563; a=rsa-sha256; cv=none; b=FH6L2j1X7OXdwmpcoz1xi08+B/IrTFgPIVBKqn8o8RjQz1MB40W2mjWSE1pg3xcMfi55Yp rehzPEMmtXdqekHkSgV9qHauwaZ/HnLDnzzRu8+f5KPMz2r3mp4pOlrTLmGN/imUrab9eW S2EGJ6P9NVOV0MIwIB2IYjJ9JMV9Qei39CYGdjs5UZycHhwZzxUcJaJ3X4r/6HWmPBbP6d XpPouWzHf5JPIxMvGNUrMSVyu1Qz3FR29h1ElD8JW2AEsv4rkQRfzNgAlPn8HJGA/+l6lT o/bRN2X5wVBuEIQ0Bb1MrRpl3s5kMrnxj+HfFvcmPfwsJImesJwhNKR6lNOofQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9l09LHz9Lt; Wed, 17 Sep 2025 12:19:23 +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 58HCJM2e086296; Wed, 17 Sep 2025 12:19:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJMEM086293; Wed, 17 Sep 2025 12:19:22 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:22 GMT Message-Id: <202509171219.58HCJMEM086293@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 6b26d0a335b6 - main - ucred.9: crsetgroups_and_egid(): Clarify differences with crsetgroups() 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6b26d0a335b6222744e2778753086e16389b6029 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=6b26d0a335b6222744e2778753086e16389b6029 commit 6b26d0a335b6222744e2778753086e16389b6029 Author: Olivier Certner AuthorDate: 2025-08-29 15:17:36 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:08 +0000 ucred.9: crsetgroups_and_egid(): Clarify differences with crsetgroups() MFC after: 5 days MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52288 --- share/man/man9/ucred.9 | 28 +++++++++++++--------------- 1 file changed, 13 insertions(+), 15 deletions(-) diff --git a/share/man/man9/ucred.9 b/share/man/man9/ucred.9 index 38759bddb5b0..453df386ff18 100644 --- a/share/man/man9/ucred.9 +++ b/share/man/man9/ucred.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.Dd July 29, 2025 +.Dd August 29, 2025 .Dt UCRED 9 .Os .Sh NAME @@ -113,28 +113,26 @@ The actual copying is performed by .Pp The .Fn crsetgroups -and -.Fn crsetgroups_and_egid -functions set the +function sets the .Va cr_groups and .Va cr_ngroups -variables and allocates space as needed. -They also truncate the group list to the current maximum number of -groups. -No other mechanism should be used to modify the -.Va cr_groups -array. -Note that +variables representing the supplementary groups, allocating space as needed. +It also truncates the group list to the current maximum number of groups. +The .Fn crsetgroups_and_egid -will interpret the first element of +function is similar, but interprets separately the first group of .Va groups -as the new effective GID and the rest of the array as the supplementary groups, -and +as the effective GID to set, only setting the subsequent groups as supplementary +ones. +It will use .Va default_egid -will be used as the new effective GID only if +as the new effective GID if .Va groups is empty. +No other mechanism should be used to modify the +.Va cr_groups +array. .Pp The .Fn cru2x From nobody Wed Sep 17 12:19:24 2025 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 4cRd9m49Qzz67HfM; Wed, 17 Sep 2025 12:19:24 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9m1cnlz3WM8; Wed, 17 Sep 2025 12:19:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111564; 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=yfktoQ9WbHYmYHa75BUnJvacqhayFIcz5rl7d1Plvpk=; b=SY1Dhy1v58GDD/cvolvQhb0s8HnLtlWuP8/Wanrjyum0+hzqjApLG7udLCQB1U2VHm3SWq 2rVwvyq1XFmfKXfxvDEUHCA0/Dhw0/icphS5ktQqphumJFd1Pze3IsXbdtNHMNhqKHpOvO PasQwDfBCmK3h4aTdFSvREDk9gXEOI8LFMw1OVDOGwa+lhIM0qrzI3OKhclHqUyO0X7xt/ tjuEtXokkjieOTag4Xh4UJuMbMVIbqzbcrLGObaLo5/9d9KF496mQxmL5kGQn8bBxVIEP5 KxA49T2NnijKuUSRseOdJ3r9QZ8J28z9J+N11IG0JuySu3w6z8xY3I0Lo/DVAg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111564; 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=yfktoQ9WbHYmYHa75BUnJvacqhayFIcz5rl7d1Plvpk=; b=I4MtC1WPnAh+jqCPtIbjiaX2m1mf08jhIWivOogrv7j0epCY90178/O+LVGt+I54tQIvQF X7TelwiL31mm2wrxFihxEIVHMkiblj1A3Km+xuvBLlFOE0zA5/+gVbkUCfg3OpCpob5d7M QVgfHqA35MQAUss5MMjjJmpLoNAGCeSm7PexgHKgp1bAwSsU9FQTLoSrAKjlJBEegBGxgt tK2+D9ZRXb4jOFrNZroDYmSzKcCZ7IeBogydSESC776ljKMDSy1lpfqgIM5SU8Sn3rkPI7 weY6nhvrMWRjY5nobwB0KfIWYvOEioKzFXSPuy3GxFFFozWwK6orW+zuNEiFfA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111564; a=rsa-sha256; cv=none; b=sQ58PDPAy4Md4NAFaPPiLjAq8HyfCsmib9CLYN4tWz6tiAN5S9Q7R4Z97+lQ8Je5ZnQKFi /rsX0YbZ3JlqKQarukhWccAXx2kTk33FSvxBeGRKVoJIUAAWhXexVwwSXGXTNJLlUI1cwU NvVkSdOgnu67WB6H4r7DB7Wh8MIJyJFfR0TitIXxSDW/mvVZcrqyjjTtj0XLKH1cOlAPAu 6cM8wn0nQL2HdsxsU6pHZjQwFyh1eqAQWrclF4bYWjNRsXOpRzlPeM6Zgyb4QshVrGKIPe xBoDDDXU4eJkDhd90ZOz0PG9eg5faVFB4scU83x7BNA6lUVJ12suyglt3i1Z6g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9m19YTz9Lv; Wed, 17 Sep 2025 12:19:24 +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 58HCJOYp086329; Wed, 17 Sep 2025 12:19:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJOHY086326; Wed, 17 Sep 2025 12:19:24 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:24 GMT Message-Id: <202509171219.58HCJOHY086326@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: ff7252cdafbd - main - tools/regression/priv: Don't call setgroups() with the effective GID 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ff7252cdafbd9dab104a5e7b33b8bb84117a8789 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=ff7252cdafbd9dab104a5e7b33b8bb84117a8789 commit ff7252cdafbd9dab104a5e7b33b8bb84117a8789 Author: Olivier Certner AuthorDate: 2025-08-29 17:00:07 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:08 +0000 tools/regression/priv: Don't call setgroups() with the effective GID The 'setgroups(0, NULL);' stance works the same on all versions of FreeBSD, getting rid of all supplementary groups. The replaced code would force the effective GID to also be a supplementary group. Fixes: 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms") MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52289 --- tools/regression/priv/main.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tools/regression/priv/main.c b/tools/regression/priv/main.c index dbcb5759f6b9..979e6ed65284 100644 --- a/tools/regression/priv/main.c +++ b/tools/regression/priv/main.c @@ -423,12 +423,10 @@ setup_file(const char *test, char *fpathp, uid_t uid, gid_t gid, mode_t mode) static void set_creds(const char *test, uid_t uid, gid_t gid) { - gid_t gids[1] = { gid }; - if (setgid(gid) < 0) err(-1, "test %s: setegid(%d)", test, gid); - if (setgroups(sizeof(gids)/sizeof(gid_t), gids) < 0) - err(-1, "test %s: setgroups(%d)", test, gid); + if (setgroups(0, NULL) < 0) + err(-1, "test %s: setgroups(NULL)", test); if (setuid(uid) < 0) err(-1, "test %s: seteuid(%d)", test, uid); } From nobody Wed Sep 17 12:19:25 2025 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 4cRd9n5JqWz67Ht5; Wed, 17 Sep 2025 12:19:25 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRd9n2h8Yz3WKZ; Wed, 17 Sep 2025 12:19:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111565; 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=gQoMVt+EfjnUmLlQ094mb2B1v/UBlIvjbxL/T8mTODA=; b=DmPt+Djw1qoggcu5GjBvzJvvBM0G9JrPq5HzIOQKOkqbRxFnCiRIngtL6wq8WLAfQKFBwh 3SC5B0oJrSwzP1C8TzIxPi+wnwHeW6C3+Xfgy06up/GMLVLZJNNp+ogwro89Cn6e5DIkDh DCu6s0k/lMlR+QL7ewB++ualZlBcUcf+LePwEPtrO3PNU8EZU5eQZ84+BKtrZR1zy/7k3+ 63ojqVj3lbfDCxb7SLuZFZQNqI4QKKer07jV/NoKZkSpp1cAExPqL1SUuW+hn9o/czHvIP Jr284C3TFWT+JZ+QXiZ6l5hXVy9kia4I5A+7gX9XVOkeun3KkkNnbaSwKi4gJA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758111565; 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=gQoMVt+EfjnUmLlQ094mb2B1v/UBlIvjbxL/T8mTODA=; b=yICnfwSicVNWRgWkJVgNtqoUpwsxAvk3LaZ5r5XxLScovGmQOh19es3AaIDXlIVTHr2shc uev2n1n7vkChl0QU6eDF1035mH3+Q9JNm9lJyDgHqCpPAbjs762NVatwGzl8BupfeXPayP ROiiekbXASQwC+e3FDYasUbZhgNRm6h5N2+EDm5Q3RhGOgOk6eb/3HPapXIcZ+2Ldw8UsD T/z7AUzSNC4fGd/8/YhKlPMnZB5VzCh6eG92TRym9clm7DclyhBIqzxqBG0roYYpS1QLBe tlNAP50TJ3bin2LjmUbgBO1QsPGO1noT64KYY2Q1qKu0AX6tuTvvi11G5MmOfQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758111565; a=rsa-sha256; cv=none; b=ahEVzihxnYlc0148qSMm7qdvqumgcWgEiDT5rwWrR//IrnQh+e+t2iF/tT8sUW3InzrWPU x+0bOCaFCtp5KZLCKzqMg8iTbHT1SRjc5oD5SIQosdeVv/pzVyc4JH3PQVhhRsN56qAir1 54/fPz2DBOJ92tGPPDqgVzJYP+iqZfQbMHNGBNRD3RBGwNryDzy8dPjDCkW71OlRrRAz3T C7lpgkMQOwR+B+X0DzivtnarQTMbJnaC8szWKXviQXY8tgStBrrSwswgKnwUdVKSaJMTQM nT90q7/dVaTtUceVxvw+7k5JZzJK1Ng+2RjKS63AnifJdtJ5vhbwAqcfKLCqZw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRd9n2GsZz8wT; Wed, 17 Sep 2025 12:19:25 +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 58HCJPUl086362; Wed, 17 Sep 2025 12:19:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HCJPLe086359; Wed, 17 Sep 2025 12:19:25 GMT (envelope-from git) Date: Wed, 17 Sep 2025 12:19:25 GMT Message-Id: <202509171219.58HCJPLe086359@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: de4832289625 - main - stress2: Fix removal of supplementary groups 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: de4832289625f3c1cea4200d8eb7b4c753b90648 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=de4832289625f3c1cea4200d8eb7b4c753b90648 commit de4832289625f3c1cea4200d8eb7b4c753b90648 Author: Olivier Certner AuthorDate: 2025-08-29 17:01:27 +0000 Commit: Olivier Certner CommitDate: 2025-09-17 12:16:09 +0000 stress2: Fix removal of supplementary groups To this end, call setgroups(0, NULL) instead of passing the effective GID. This stance is fully compatible with older versions of FreeBSD. Fixes: 9da2fe96ff2e ("kern: fix setgroups(2) and getgroups(2) to match other platforms") MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52290 --- tools/test/stress2/misc/fdatasync.sh | 2 +- tools/test/stress2/misc/fdatasync2.sh | 2 +- tools/test/stress2/misc/fifo2.sh | 2 +- tools/test/stress2/misc/ftruncate.sh | 2 +- tools/test/stress2/misc/ftruncate2.sh | 2 +- tools/test/stress2/misc/kevent7.sh | 2 +- tools/test/stress2/misc/killpg.sh | 2 +- tools/test/stress2/misc/killpg2.sh | 2 +- tools/test/stress2/misc/killpg3.sh | 2 +- tools/test/stress2/misc/maxproc.sh | 2 +- tools/test/stress2/misc/mlockall3.sh | 2 +- tools/test/stress2/misc/mlockall7.sh | 2 +- tools/test/stress2/misc/mountu.sh | 2 +- tools/test/stress2/misc/msync.sh | 2 +- tools/test/stress2/misc/pread.sh | 2 +- tools/test/stress2/misc/sched.sh | 2 +- tools/test/stress2/misc/sigreturn3.sh | 2 +- tools/test/stress2/misc/sigreturn4.sh | 2 +- tools/test/stress2/misc/syscall4.sh | 2 +- tools/test/stress2/misc/tmpfs16.sh | 2 +- 20 files changed, 20 insertions(+), 20 deletions(-) diff --git a/tools/test/stress2/misc/fdatasync.sh b/tools/test/stress2/misc/fdatasync.sh index f17e2826ad94..9abd31e5bd94 100755 --- a/tools/test/stress2/misc/fdatasync.sh +++ b/tools/test/stress2/misc/fdatasync.sh @@ -178,7 +178,7 @@ main(int argc, char **argv) if ((pw = getpwnam("nobody")) == NULL) err(1, "failed to resolve nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/fdatasync2.sh b/tools/test/stress2/misc/fdatasync2.sh index 6011eba53698..42ade0cedbd3 100755 --- a/tools/test/stress2/misc/fdatasync2.sh +++ b/tools/test/stress2/misc/fdatasync2.sh @@ -177,7 +177,7 @@ main(int argc, char **argv) if ((pw = getpwnam("nobody")) == NULL) err(1, "failed to resolve nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/fifo2.sh b/tools/test/stress2/misc/fifo2.sh index 4a7b986931d9..e84506cbfb01 100755 --- a/tools/test/stress2/misc/fifo2.sh +++ b/tools/test/stress2/misc/fifo2.sh @@ -167,7 +167,7 @@ main(void) if ((pw = getpwnam("nobody")) == NULL) err(1, "no such user: nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/ftruncate.sh b/tools/test/stress2/misc/ftruncate.sh index ddec85b6745a..f9aa1869756f 100755 --- a/tools/test/stress2/misc/ftruncate.sh +++ b/tools/test/stress2/misc/ftruncate.sh @@ -170,7 +170,7 @@ main(int argc, char **argv) if ((pw = getpwnam("nobody")) == NULL) err(1, "failed to resolve nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/ftruncate2.sh b/tools/test/stress2/misc/ftruncate2.sh index 35db3a4c5f8d..94d9b6ca810f 100755 --- a/tools/test/stress2/misc/ftruncate2.sh +++ b/tools/test/stress2/misc/ftruncate2.sh @@ -185,7 +185,7 @@ main(int argc, char **argv) if ((pw = getpwnam("nobody")) == NULL) err(1, "failed to resolve nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/kevent7.sh b/tools/test/stress2/misc/kevent7.sh index 8b58c35551f7..4c7718c6ae5f 100755 --- a/tools/test/stress2/misc/kevent7.sh +++ b/tools/test/stress2/misc/kevent7.sh @@ -236,7 +236,7 @@ main(void) if ((pw = getpwnam("nobody")) == NULL) err(1, "no such user: nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/killpg.sh b/tools/test/stress2/misc/killpg.sh index c6af55a3d593..ea99f5e0d0fd 100755 --- a/tools/test/stress2/misc/killpg.sh +++ b/tools/test/stress2/misc/killpg.sh @@ -113,7 +113,7 @@ killer(void) if ((pw = getpwnam("nobody")) == NULL) err(1, "no such user: nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/killpg2.sh b/tools/test/stress2/misc/killpg2.sh index 5e986f059637..cf186d686dfd 100755 --- a/tools/test/stress2/misc/killpg2.sh +++ b/tools/test/stress2/misc/killpg2.sh @@ -77,7 +77,7 @@ looper(void) if ((pw = getpwnam("TUSER")) == NULL) err(1, "no such user: TUSER"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"TUSER\""); diff --git a/tools/test/stress2/misc/killpg3.sh b/tools/test/stress2/misc/killpg3.sh index 304b3e320f2f..4fcb4fa7a643 100755 --- a/tools/test/stress2/misc/killpg3.sh +++ b/tools/test/stress2/misc/killpg3.sh @@ -109,7 +109,7 @@ looper(void) if ((pw = getpwnam("TUSER")) == NULL) err(1, "no such user: TUSER"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"TUSER\""); diff --git a/tools/test/stress2/misc/maxproc.sh b/tools/test/stress2/misc/maxproc.sh index 0574def8a605..3241e275375e 100755 --- a/tools/test/stress2/misc/maxproc.sh +++ b/tools/test/stress2/misc/maxproc.sh @@ -103,7 +103,7 @@ t1(int priv) err(1, "no such user: nobody"); if (priv == 0) { - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/mlockall3.sh b/tools/test/stress2/misc/mlockall3.sh index 0ff1e24eaa7f..aa53e75166a5 100755 --- a/tools/test/stress2/misc/mlockall3.sh +++ b/tools/test/stress2/misc/mlockall3.sh @@ -130,7 +130,7 @@ main(void) if ((pw = getpwnam("nobody")) == NULL) err(1, "no such user: nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/mlockall7.sh b/tools/test/stress2/misc/mlockall7.sh index 987e312f19e7..5a927043cb56 100755 --- a/tools/test/stress2/misc/mlockall7.sh +++ b/tools/test/stress2/misc/mlockall7.sh @@ -179,7 +179,7 @@ testing(unsigned long maxl) maxlock = maxl; if ((pw = getpwnam("nobody")) == NULL) err(1, "failed to resolve nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/mountu.sh b/tools/test/stress2/misc/mountu.sh index abd3c744d160..95043e634ef1 100755 --- a/tools/test/stress2/misc/mountu.sh +++ b/tools/test/stress2/misc/mountu.sh @@ -241,7 +241,7 @@ main(int argc __unused, char **argv) if ((pw = getpwnam("nobody")) == NULL) err(1, "no such user: nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/msync.sh b/tools/test/stress2/misc/msync.sh index 326c7e723774..df05875afb45 100755 --- a/tools/test/stress2/misc/msync.sh +++ b/tools/test/stress2/misc/msync.sh @@ -166,7 +166,7 @@ main(void) if ((pw = getpwnam("nobody")) == NULL) err(1, "no such user: nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/pread.sh b/tools/test/stress2/misc/pread.sh index 24ee2efb696a..985d3f643df1 100755 --- a/tools/test/stress2/misc/pread.sh +++ b/tools/test/stress2/misc/pread.sh @@ -170,7 +170,7 @@ main(int argc __unused, char **argv) if ((pw = getpwnam("nobody")) == NULL) err(1, "no such user: nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/sched.sh b/tools/test/stress2/misc/sched.sh index 1a1db70eb38a..8b33d7b16094 100755 --- a/tools/test/stress2/misc/sched.sh +++ b/tools/test/stress2/misc/sched.sh @@ -107,7 +107,7 @@ work(void) if ((pw = getpwnam("nobody")) == NULL) err(1, "no such user: nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/sigreturn3.sh b/tools/test/stress2/misc/sigreturn3.sh index a2d865b73847..6795c4fd0846 100755 --- a/tools/test/stress2/misc/sigreturn3.sh +++ b/tools/test/stress2/misc/sigreturn3.sh @@ -121,7 +121,7 @@ main(int argc, char **argv) fprintf(stderr, "Running syscall4 as root for %s.\n", argv[1]); else { - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/sigreturn4.sh b/tools/test/stress2/misc/sigreturn4.sh index c77140de0518..90ee16777e03 100755 --- a/tools/test/stress2/misc/sigreturn4.sh +++ b/tools/test/stress2/misc/sigreturn4.sh @@ -147,7 +147,7 @@ main(int argc, char **argv) fprintf(stderr, "Running sigreturn4 as root for %s.\n", argv[1]); else { - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/syscall4.sh b/tools/test/stress2/misc/syscall4.sh index 3937d45c0303..92150c782ac1 100755 --- a/tools/test/stress2/misc/syscall4.sh +++ b/tools/test/stress2/misc/syscall4.sh @@ -318,7 +318,7 @@ main(int argc, char **argv) fprintf(stderr, "Running syscall4 as root for %s.\n", argv[1]); else { - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); diff --git a/tools/test/stress2/misc/tmpfs16.sh b/tools/test/stress2/misc/tmpfs16.sh index 8cc3c3596a4e..683817ce6497 100755 --- a/tools/test/stress2/misc/tmpfs16.sh +++ b/tools/test/stress2/misc/tmpfs16.sh @@ -181,7 +181,7 @@ main(int argc, char **argv) if ((pw = getpwnam("nobody")) == NULL) err(1, "failed to resolve nobody"); - if (setgroups(1, &pw->pw_gid) || + if (setgroups(0, NULL) || setegid(pw->pw_gid) || setgid(pw->pw_gid) || seteuid(pw->pw_uid) || setuid(pw->pw_uid)) err(1, "Can't drop privileges to \"nobody\""); From nobody Wed Sep 17 13:36:51 2025 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 4cRfv74pQ1z67PbZ; Wed, 17 Sep 2025 13:36:51 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRfv745fqz3tBB; Wed, 17 Sep 2025 13:36:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758116211; 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=N7OCZkaGwVEyDrlb1nHj1TjzOVPCXDeJZ2igblGqKOQ=; b=JioWZqwps2wIb07rZYnVOUsjXeFjsH/+hBBPJ0BaRPdod5p5jgft6b3lC7iesb5nlHlZEy xWk8M30j/Ow6l5CqcFF0WNM7Fa3Ho5oJ6cdWReQfc7S6IMhc5EveZCRlJv4URL6tAIWkIH FZ5t1wcIp2dZwShvZAwMmkILqX8k9OQr9/OyUO0N30QW88cOJxVMw1OcWNBHBWRRrGUKqC Hm1kP6sMRKIIJ6shNpif5iubcFlFduEDvj7LR1N38IjgLwfevMlVrAXKwR6q7vxuj/VYW/ veiPNNB6Yc7yH87LXDjohQjTEK1b60NCt5nGAbHVwosQA26UZZAiu1XACRI6Ug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758116211; 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=N7OCZkaGwVEyDrlb1nHj1TjzOVPCXDeJZ2igblGqKOQ=; b=KRlBB4G9Sas7lCjhlZh3m7MMJNHc1NRCRRTJRsRzMhEixq3TIBgxwTrB+HVkCGtykeqVjF 9ojM1b+MFu/QJY/7KdTpCI8vsvoHGiYnYwNf6fAT57ZwWNGPKTZPOkKEY7I9CSsStxJrbm YlckJ9DG4wfBvDfjr+UGiuCTs22uehirnXt4JuOYjkJRmSm1rpNR9ZTEmIhHAsiy4pdXjT Phvy1rt/Rap115Ld+A9JGhFDQ1rsmKzOsv2q8AHissoFUTtlxj1uJWg6l3Cbe8qeOYObrJ x5/5r07PgoKCTDPAOm2FI/SI7VwZ45hbWrXYT9qETo931BIu4BZzQ9//cpzOgA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758116211; a=rsa-sha256; cv=none; b=RuJQexcnY8MwpMGPU82xoPH2Y6xGjNUSn86kjuuhs9lO69PaK65nyH5of/PcCvSDQ1Ii5W UedWcZjaOSXjE6eJj/YrpejxMpBGHMz+rIZ3y1iGIoevz+RRoy5Kf51tKfaWupyofQ12Av TRmHxk8wh0PldBh5Od8mIYefITpfDHdNhEd9cfZk6uiIDmHqmZ6A6w1XlEMJ/s3MIHsHPr 2E7ZRsqnPMaovCDG/SYD+/4jUQtbcm//Dv3yNo5fqy0tfIPPfJphRsggDj6DcrWTXwSHej C/lPqYNMrB6ARShC6AW2x/jh90cA9wi2NyxqLs2/LhxBdJ+BPNuzgUKQkQEQ/g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRfv73LTSzC2q; Wed, 17 Sep 2025 13:36:51 +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 58HDapiw034933; Wed, 17 Sep 2025 13:36:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HDapag034930; Wed, 17 Sep 2025 13:36:51 GMT (envelope-from git) Date: Wed, 17 Sep 2025 13:36:51 GMT Message-Id: <202509171336.58HDapag034930@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 220584471931 - stable/14 - bsdinstall: Remove support for ZFS + MBR disk layouts 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: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 220584471931fef807a6f59ce0397cfd6ac0f6fe Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=220584471931fef807a6f59ce0397cfd6ac0f6fe commit 220584471931fef807a6f59ce0397cfd6ac0f6fe Author: Ed Maste AuthorDate: 2025-06-25 01:19:12 +0000 Commit: Ed Maste CommitDate: 2025-09-17 13:35:55 +0000 bsdinstall: Remove support for ZFS + MBR disk layouts It hasn't worked for some time -- as reported in review D40816 "Installing FreeBSD with Auto ZFS + MBR has been broken ever since the move to OpenZFS with FreeBSD 13." It relied on the partition table and ZFS data overlapping in a very fragile way and is not a good idea. Reviewed by: jhb Relnotes: Yes Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D51028 (cherry picked from commit ee110941e35c4354baa2e5b6fd64d3025cff4b7e) --- usr.sbin/bsdinstall/scripts/zfsboot | 141 ++---------------------------------- 1 file changed, 8 insertions(+), 133 deletions(-) diff --git a/usr.sbin/bsdinstall/scripts/zfsboot b/usr.sbin/bsdinstall/scripts/zfsboot index 94eec0e20faa..8e3df4631abf 100755 --- a/usr.sbin/bsdinstall/scripts/zfsboot +++ b/usr.sbin/bsdinstall/scripts/zfsboot @@ -86,7 +86,7 @@ f_include $BSDCFG_SHARE/variable.subr # # Create a separate boot pool? -# NB: Automatically set when using geli(8) or MBR +# NB: Automatically set when using geli(8) # : ${ZFSBOOT_BOOT_POOL=} @@ -96,12 +96,12 @@ f_include $BSDCFG_SHARE/variable.subr : ${ZFSBOOT_BOOT_POOL_CREATE_OPTIONS:=} # -# Default name for boot pool when enabled (e.g., geli(8) or MBR) +# Default name for boot pool when enabled (e.g., geli(8)) # : ${ZFSBOOT_BOOT_POOL_NAME:=bootpool} # -# Default size for boot pool when enabled (e.g., geli(8) or MBR) +# Default size for boot pool when enabled (e.g., geli(8)) # : ${ZFSBOOT_BOOT_POOL_SIZE:=2g} @@ -790,7 +790,7 @@ zfs_create_diskpart() # Check for unknown partition scheme before proceeding further case "$ZFSBOOT_PARTITION_SCHEME" in - ""|MBR|GPT*) : known good ;; + ""|GPT*) : known good ;; *) f_dprintf "$funcname: %s is an unsupported partition scheme" \ "$ZFSBOOT_PARTITION_SCHEME" @@ -825,14 +825,11 @@ zfs_create_diskpart() # # Lay down the desired type of partition scheme # - local setsize mbrindex align_small align_big + local setsize align_small align_big # # If user has requested 4 K alignment, add these params to the # gpart add calls. With GPT, we align large partitions to 1 M for - # improved performance on SSDs. MBR does not always play well with gaps - # between partitions, so all alignment is only 4k for that case. - # With MBR, we align the BSD partition that contains the MBR, otherwise - # the system fails to boot. + # improved performance on SSDs. # if [ "$ZFSBOOT_FORCE_4K_SECTORS" ]; then align_small="-a 4k" @@ -974,90 +971,6 @@ zfs_create_diskpart() /dev/$disk$targetpart ;; - MBR) f_dprintf "$funcname: Creating MBR layout..." - # - # Enable boot pool if encryption is desired - # - [ "$ZFSBOOT_GELI_ENCRYPTION" ] && ZFSBOOT_BOOT_POOL=1 - # - # 1. Create MBR layout (no labels) - # - f_eval_catch $funcname gpart "$GPART_CREATE" mbr $disk || - return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ - $disk || return $FAILURE - - # - # 2. Add freebsd slice with all available space - # - f_eval_catch $funcname gpart "$GPART_ADD_ALIGN" \ - "$align_small" freebsd $disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_SET_ACTIVE" 1 $disk || - return $FAILURE - # Pedantically nuke any old labels - f_eval_catch -d $funcname zpool "$ZPOOL_LABELCLEAR_F" \ - /dev/${disk}s1 - # Pedantically nuke any old scheme - f_eval_catch -d $funcname gpart "$GPART_DESTROY_F" ${disk}s1 - - # - # 3. Write BSD scheme to the freebsd slice - # - f_eval_catch $funcname gpart "$GPART_CREATE" BSD ${disk}s1 || - return $FAILURE - - # NB: ZFS pools will use s1a (no labels) - bootpart=s1a swappart=s1b targetpart=s1d mbrindex=4 - - # - # Always prepare a boot pool on MBR - # Do not align this partition, there must not be a gap - # - ZFSBOOT_BOOT_POOL=1 - f_eval_catch $funcname gpart \ - "$GPART_ADD_ALIGN_INDEX_WITH_SIZE" \ - "" 1 freebsd-zfs ${bootsize}b ${disk}s1 || - return $FAILURE - # Pedantically nuke any old labels - f_eval_catch -d $funcname zpool "$ZPOOL_LABELCLEAR_F" \ - /dev/$disk$bootpart - if [ "$ZFSBOOT_GELI_ENCRYPTION" ]; then - # Pedantically detach targetpart for later - f_eval_catch -d $funcname geli \ - "$GELI_DETACH_F" \ - /dev/$disk$targetpart - fi - - # - # 4. Add freebsd-swap partition - # - if [ ${swapsize:-0} -gt 0 ]; then - f_eval_catch $funcname gpart \ - "$GPART_ADD_ALIGN_INDEX_WITH_SIZE" \ - "$align_small" 2 freebsd-swap \ - ${swapsize}b ${disk}s1 || return $FAILURE - # Pedantically nuke any old labels on the swap - f_eval_catch -d $funcname zpool "$ZPOOL_LABELCLEAR_F" \ - /dev/${disk}s1b - fi - - # - # 5. Add freebsd-zfs partition for zroot - # - if [ "$ZFSBOOT_POOL_SIZE" ]; then - f_eval_catch $funcname gpart "$GPART_ADD_ALIGN_INDEX_WITH_SIZE" \ - "$align_small" $mbrindex freebsd-zfs $ZFSBOOT_POOL_SIZE ${disk}s1 || return $FAILURE - else - f_eval_catch $funcname gpart "$GPART_ADD_ALIGN_INDEX" \ - "$align_small" $mbrindex freebsd-zfs ${disk}s1 || return $FAILURE - fi - f_eval_catch -d $funcname zpool "$ZPOOL_LABELCLEAR_F" \ - /dev/$disk$targetpart # Pedantic - f_eval_catch $funcname dd "$DD_WITH_OPTIONS" \ - /boot/zfsboot /dev/${disk}s1 count=1 || - return $FAILURE - ;; - esac # $ZFSBOOT_PARTITION_SCHEME # Update fstab(5) @@ -1102,7 +1015,7 @@ zfs_create_boot() local zroot_vdevtype="$2" local zroot_vdevs= # Calculated below local swap_devs= # Calculated below - local boot_vdevs= # Used for geli(8) and/or MBR layouts + local boot_vdevs= # Used for geli(8) layouts shift 2 # poolname vdev_type local disks="$*" disk local isswapmirror @@ -1191,7 +1104,6 @@ zfs_create_boot() f_dprintf "$funcname: With 4K sectors..." f_eval_catch $funcname sysctl "$SYSCTL_ZFS_MIN_ASHIFT_12" \ || return $FAILURE - sysctl kern.geom.part.mbr.enforce_chs=0 fi local n=0 for disk in $disks; do @@ -1415,40 +1327,6 @@ zfs_create_boot() "bootfs=\"$zroot_name/$zroot_bootfs\"" "$zroot_name" || return $FAILURE - # MBR boot loader touch-up - if [ "$ZFSBOOT_PARTITION_SCHEME" = "MBR" ]; then - # Export the pool(s) - f_dprintf "$funcname: Temporarily exporting ZFS pool(s)..." - f_eval_catch $funcname zpool "$ZPOOL_EXPORT" "$zroot_name" || - return $FAILURE - if [ "$ZFSBOOT_BOOT_POOL" ]; then - f_eval_catch $funcname zpool "$ZPOOL_EXPORT" \ - "$bootpool_name" || return $FAILURE - fi - - f_dprintf "$funcname: Updating MBR boot loader on disks..." - # Stick the ZFS boot loader in the "convenient hole" after - # the ZFS internal metadata - for disk in $disks; do - f_eval_catch $funcname dd "$DD_WITH_OPTIONS" \ - /boot/zfsboot /dev/$disk$bootpart \ - "skip=1 seek=1024" || return $FAILURE - done - - # Re-import the ZFS pool(s) - f_dprintf "$funcname: Re-importing ZFS pool(s)..." - f_eval_catch $funcname zpool "$ZPOOL_IMPORT_WITH_OPTIONS" \ - "-o altroot=\"$BSDINSTALL_CHROOT\"" \ - "$zroot_name" || return $FAILURE - if [ "$ZFSBOOT_BOOT_POOL" ]; then - # Import the bootpool, but do not mount it yet - f_eval_catch $funcname zpool \ - "$ZPOOL_IMPORT_WITH_OPTIONS" \ - "-o altroot=\"$BSDINSTALL_CHROOT\" -N" \ - "$bootpool_name" || return $FAILURE - fi - fi - # Remount bootpool and create symlink(s) if [ "$ZFSBOOT_BOOT_POOL" ]; then f_eval_catch $funcname zfs "$ZFS_MOUNT" "$bootpool_name" || @@ -1793,7 +1671,7 @@ while :; do fi ;; ?" $msg_partition_scheme") - # Toggle between GPT (BIOS), GPT (UEFI) and MBR + # Toggle between partition schemes if [ "$ZFSBOOT_PARTITION_SCHEME" = "GPT" -a \ "$ZFSBOOT_BOOT_TYPE" = "BIOS" ] then @@ -1805,9 +1683,6 @@ while :; do ZFSBOOT_PARTITION_SCHEME="GPT" ZFSBOOT_BOOT_TYPE="BIOS+UEFI" elif [ "$ZFSBOOT_PARTITION_SCHEME" = "GPT" ]; then - ZFSBOOT_PARTITION_SCHEME="MBR" - ZFSBOOT_BOOT_TYPE="BIOS" - elif [ "$ZFSBOOT_PARTITION_SCHEME" = "MBR" ]; then ZFSBOOT_PARTITION_SCHEME="GPT + Active" ZFSBOOT_BOOT_TYPE="BIOS" elif [ "$ZFSBOOT_PARTITION_SCHEME" = "GPT + Active" ]; then From nobody Wed Sep 17 14:12:38 2025 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 4cRghQ6xzpz67SNr; Wed, 17 Sep 2025 14:12:38 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRghQ69mNz41pY; Wed, 17 Sep 2025 14:12:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118358; 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=adN4EcbRP++RJPJ0lTv7GEj9u9JPQU931+EuU+hfF0g=; b=CTJ/FGehMsQA7MO73SQIoHf6mnFcjFtrtgmohQ0eiQFpMeWTqWtCPcyH4YvdOLGguW7i8F dCf/v4IoKJz+2ifGYAXWSsiqWK34g0vZE2vgruziW0qjtkNCGynCOqhCfdhM8HQro+9vVM uHEbuizdAvgyN1fN4RXGaC1M+voKr16PvmpmQSmoTbuO4Khkdf0t60FrvtPocUnTJC/UiE BssN7ZeB+bWTnMY4g9kmtJXIMQ6Vf5S0TlUq5+gdqcYaOLPzsObdpt/TA++JLBdz1INJsU osjVt7u3HgDVKCTmpuUK5vT8NsXl/2SJGgBKVTvwONAh5Mx0WgGjkuN4JQ6fsQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118358; 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=adN4EcbRP++RJPJ0lTv7GEj9u9JPQU931+EuU+hfF0g=; b=gn2fgP4UXZ/mwQ7J92AQcRf7BjrUqw7pYBPggPt8sFTdeabkVYVq5jBlQv1esKBtdMVVD/ Isg3wzxtBpqsnwExBZRL74yuaFie+/fQbhbOr0TMdz70G687JXT4JNS4HLFgAR+xBaPrJ5 z72w6loYcGvlW2OUc9JP6XdL5zxJ24WhkHee2hEraWfs5WbTyDyFOgDzQIWY+8DwF1/+Oe I0yO6sfWOZdG3b3IjV0Li3PAG9yA+K9YV90itVOhmdllTWOqIxh10XjbDHkwBcvFSqjeQQ Kj6HisS0sR9jy7E5Gaxi8qmmH8biNeZBfyDgJxehBkD3lN1NexakpAPahIYkvw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118358; a=rsa-sha256; cv=none; b=EyQ4Ow/3Bzx2538j4pODLFPraq9NLKOljJbyB3AOdjm2xorEnbQE3J8Jh18Q/H682hnGhr +ptfP5baDFpnsu+F0pbcdAyCXCt9Z9f5oNYj6CvLtPeltfcbAoNzcaMc2jTZr98AsKJ26A WnJrf2lVIE45HGYd+zmdhdAX4Oebi8ze0Cqu0P11/axKnyI1tau/KvSE3fHxRMjkVw15eK l36cQCMZ+3MqtCt60AlCiQ0ElY12N1frK0T1AZ15IHkqMxCwtuaya5PXy7xGiFj7uug5xI lCELDnkzPpHg8A5u0NCjblX0yLls5FmQhVctLO35EK6BNyINSe88Ti2XD0ZDiA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRghQ5Tc8zTJ2; Wed, 17 Sep 2025 14:12:38 +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 58HECc8j009143; Wed, 17 Sep 2025 14:12:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HECcKD009140; Wed, 17 Sep 2025 14:12:38 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:12:38 GMT Message-Id: <202509171412.58HECcKD009140@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: 3d14cc82d7a8 - main - sdp(3): Change bdaddr parameter type in sdp_register_service() 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 3d14cc82d7a8c11cd164a6ba668d20b939c576fe Auto-Submitted: auto-generated The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=3d14cc82d7a8c11cd164a6ba668d20b939c576fe commit 3d14cc82d7a8c11cd164a6ba668d20b939c576fe Author: Christos Margiolis AuthorDate: 2025-09-17 14:12:03 +0000 Commit: Christos Margiolis CommitDate: 2025-09-17 14:12:03 +0000 sdp(3): Change bdaddr parameter type in sdp_register_service() Fixes compiler error when the caller passes a const bdaddr_t * paramemeter (e.g., NG_HCI_BDADDR_ANY). Sponsored by: The FreeBSD Foundation MFC after: 1 day Reviewed by: markj, emaste Differential Revision: https://reviews.freebsd.org/D52582 --- lib/libsdp/sdp.3 | 4 ++-- lib/libsdp/sdp.h | 2 +- lib/libsdp/service.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/libsdp/sdp.3 b/lib/libsdp/sdp.3 index dcd9077798ea..015f9cd8fb44 100644 --- a/lib/libsdp/sdp.3 +++ b/lib/libsdp/sdp.3 @@ -24,7 +24,7 @@ .\" .\" $Id: sdp.3,v 1.1 2003/09/07 20:34:19 max Exp $ .\" -.Dd April 30, 2018 +.Dd September 16, 2025 .Dt SDP 3 .Os .Sh NAME @@ -87,7 +87,7 @@ .Fn sdp_uuid2desc "uint16_t uuid" .Ft int32_t .Fo sdp_register_service -.Fa "void *xss" "uint16_t uuid" "bdaddr_p const bdaddr" "uint8_t const *data" +.Fa "void *xss" "uint16_t uuid" "const bdaddr_t *bdaddr" "uint8_t const *data" .Fa "uint32_t datalen" "uint32_t *handle" .Fc .Ft int32_t diff --git a/lib/libsdp/sdp.h b/lib/libsdp/sdp.h index faad36aefca6..0c9474a70eff 100644 --- a/lib/libsdp/sdp.h +++ b/lib/libsdp/sdp.h @@ -702,7 +702,7 @@ typedef struct sdp_panu_profile sdp_panu_profile_t; typedef struct sdp_panu_profile * sdp_panu_profile_p; int32_t sdp_register_service (void *xss, uint16_t uuid, - bdaddr_p const bdaddr, uint8_t const *data, + const bdaddr_t *bdaddr, uint8_t const *data, uint32_t datalen, uint32_t *handle); int32_t sdp_unregister_service (void *xss, uint32_t handle); int32_t sdp_change_service (void *xss, uint32_t handle, diff --git a/lib/libsdp/service.c b/lib/libsdp/service.c index 9f07d1ba86ba..2cce6c133600 100644 --- a/lib/libsdp/service.c +++ b/lib/libsdp/service.c @@ -45,7 +45,7 @@ static int32_t sdp_receive_error_pdu(sdp_session_p ss); int32_t -sdp_register_service(void *xss, uint16_t uuid, bdaddr_p const bdaddr, +sdp_register_service(void *xss, uint16_t uuid, const bdaddr_t *bdaddr, uint8_t const *data, uint32_t datalen, uint32_t *handle) { sdp_session_p ss = (sdp_session_p) xss; From nobody Wed Sep 17 14:15:39 2025 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 4cRglv4Qfxz67ScB; Wed, 17 Sep 2025 14:15:39 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRglv4C4Wz4485; Wed, 17 Sep 2025 14:15:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118539; 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=OPKAj5onG4oumD/QL70yfix6Lq3aV99Lywa8FvvhtEw=; b=wYDx2nLTQ4i7fJwiT/G2aWsc0uCn0wqmyNJ9+HUCCTpte4xNM4Vp8y0bfR1pHPG1k3VqJm 572m1y/D4lQI+QDB3hGMiKi4+PnIM+zTSwnGRWYjyPGOyxTmMp6CBng08aigE2nfvKcuvO fkzzvM7WllJA+FJ9Q9MY5B4Z/WZfXu93rBZ7AZHnCbgFo87klySQ3VvEDCyTuTL6jGMqJO oA834ROnsWPjjTl80TBwEm5O3cYXRMXgJ399ARnMnKRq06SFB2A3NVeppuqvKnLF4/cUev wBCoQG7+SNleptMYjf7xi6tWE9dBxpNlVGQJ6is73MJFubzwP7tqaij6Dq+Tvg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118539; 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=OPKAj5onG4oumD/QL70yfix6Lq3aV99Lywa8FvvhtEw=; b=FNWTtbF2zC2hQAwn15eUNObsoyATymsjkECROJ7JBCtuddpms2zZVVs/IqtGeBc0m1hv15 Ud0aUwzDbZNMv5iiXmgbjQX8dHAZh8ZZltgR1wqfUz5OnqKuzVNyjXjOZnfIwJwW2YIDIV 88QqcQisHJtMMzYbvd2gWjlsQ0SjStEiMtWzjlDl6uSaIbw3AVB7ryyWztZSOB4+S/K6Ho fve21D06IymWUk1ngMXYgPYOeYsf9G6B3oFuFQyu85vHr23rRMAfaFM9gYe2xWN+7mq0XX MJXhDBEyfO0UHDcoSo8F/FkdX7xhJ7Ml0yHvHHViwS0tHr+8LR4wHqUJIUgE0g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118539; a=rsa-sha256; cv=none; b=aQlcEcrCwq1P7Lee28o8R3N35svcUKdjwrSCkvU8hnVfzY5Va3zBpJPjGxOsqEidmbloVN +qosTHFWRkq6n44QagJLaK3PzbIlSngd6I5uslbRBEa6vbB7HotzFqsnfo0o2Imua6tF0N cUCAEvgX61FefT+fyYvOxUCoHcNvQz2qqhYZxHRx9kK5KCg0k/Lk5JTd+d/waVtMuS8fsv 9U0j+H5i/i7ZyVAA53MkiL+Le4eFggue8M+rgV0OApogIumqspNLouvAp9ZI9u0msjhh/f tMFWsTJrY5mJg61hy5gh9sJXJZXuqzmZSYLcrfnGiIuNw8jZDbqx+u6p8X/kaA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRglv3SPNzTZs; Wed, 17 Sep 2025 14:15:39 +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 58HEFdER010143; Wed, 17 Sep 2025 14:15:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEFdN0010140; Wed, 17 Sep 2025 14:15:39 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:15:39 GMT Message-Id: <202509171415.58HEFdN0010140@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 9dfc5e03da50 - main - pfctl: allow tables to be defined inside anchors 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9dfc5e03da50d12f02c2b481139acf9f089d504f Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=9dfc5e03da50d12f02c2b481139acf9f089d504f commit 9dfc5e03da50d12f02c2b481139acf9f089d504f Author: Kristof Provost AuthorDate: 2025-08-22 11:34:39 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 14:15:13 +0000 pfctl: allow tables to be defined inside anchors This change allows user to define table inside the anchor like that: anchor foo { table { 192.168.1.1 } pass in from to } Without this diff one must either create table in main ruleset (root) or use 'pfctl -a foo -t bar -T add 192.168.1.1' This glitch is hard to notice. Not many human admins try to attach tables to non-global anchors. Deamons which configure pf(4) automatically at run time such as relayd(8) and spamd(8) create tables attached to thair anchors (for example 'relayd/*') but the deamons use way similar to pfctl(8) to add and manage those tables. The reason why I'd like to seal this gap is that my long term goal is to turn global `pfr_ktable` in pf(4) into member of pf_anchor. So each ruleset will get its own tree of tables. feedback and OK bluhm@ Obtained from: OpenBSD, sashan , 30269bc362 Sponsored by: Rubicon Communications, LLC ("Netgate") --- sbin/pfctl/parse.y | 104 ++++++++++++++++++++++++++++++++++++++++++-- sbin/pfctl/pfctl.c | 52 +++++++++++++++++++--- sbin/pfctl/pfctl.h | 41 +++++++++++++++++ sbin/pfctl/pfctl_optimize.c | 3 +- sbin/pfctl/pfctl_parser.h | 12 ++++- sbin/pfctl/pfctl_radix.c | 15 +++++++ sbin/pfctl/pfctl_table.c | 51 +++++++++++++++++----- 7 files changed, 256 insertions(+), 22 deletions(-) diff --git a/sbin/pfctl/parse.y b/sbin/pfctl/parse.y index 46e9f60fe48e..0628b387b4b3 100644 --- a/sbin/pfctl/parse.y +++ b/sbin/pfctl/parse.y @@ -420,6 +420,8 @@ int rt_tableid_max(void); void mv_rules(struct pfctl_ruleset *, struct pfctl_ruleset *); void mv_eth_rules(struct pfctl_eth_ruleset *, struct pfctl_eth_ruleset *); +void mv_tables(struct pfctl *, struct pfr_ktablehead *, + struct pfctl_anchor *, struct pfctl_anchor *); void decide_address_family(struct node_host *, sa_family_t *); void remove_invalid_hosts(struct node_host **, sa_family_t *); int invalid_redirect(struct node_host *, sa_family_t); @@ -949,6 +951,7 @@ anchorname : STRING { pfa_anchorlist : /* empty */ | pfa_anchorlist '\n' + | pfa_anchorlist tabledef '\n' | pfa_anchorlist pfrule '\n' | pfa_anchorlist anchorrule '\n' | pfa_anchorlist include '\n' @@ -974,7 +977,7 @@ pfa_anchor : '{' snprintf(ta, PF_ANCHOR_NAME_SIZE, "_%d", pf->bn); rs = pf_find_or_create_ruleset(ta); if (rs == NULL) - err(1, "pfa_anchor: pf_find_or_create_ruleset"); + err(1, "pfa_anchor: pf_find_or_create_ruleset (%s)", ta); pf->astack[pf->asd] = rs->anchor; pf->anchor = rs->anchor; } '\n' pfa_anchorlist '}' @@ -1026,6 +1029,7 @@ anchorrule : ANCHOR anchorname dir quick interface af proto fromto } mv_rules(&pf->alast->ruleset, &r.anchor->ruleset); + mv_tables(pf, &pfr_ktables, r.anchor, pf->alast); } pf_remove_if_empty_ruleset(&pf->alast->ruleset); pf->alast = r.anchor; @@ -5456,6 +5460,7 @@ process_tabledef(char *name, struct table_opts *opts, int popts) { struct pfr_buffer ab; struct node_tinit *ti; + struct pfr_uktable *ukt; unsigned long maxcount; size_t s = sizeof(maxcount); @@ -5488,9 +5493,23 @@ process_tabledef(char *name, struct table_opts *opts, int popts) else if (pf->opts & PF_OPT_VERBOSE) fprintf(stderr, "%s:%d: skipping duplicate table checks" " for <%s>\n", file->name, yylval.lineno, name); + /* + * postpone definition of non-root tables to moment + * when path is fully resolved. + */ + if (pf->asd > 0) { + ukt = calloc(1, sizeof(struct pfr_uktable)); + if (ukt == NULL) { + DBGPRINT( + "%s:%d: not enough memory for <%s>\n", file->name, + yylval.lineno, name); + goto _error; + } + } else + ukt = NULL; if (!(pf->opts & PF_OPT_NOACTION) && pfctl_define_table(name, opts->flags, opts->init_addr, - pf->anchor->path, &ab, pf->anchor->ruleset.tticket)) { + pf->anchor->path, &ab, pf->anchor->ruleset.tticket, ukt)) { if (sysctlbyname("net.pf.request_maxcount", &maxcount, &s, NULL, 0) == -1) @@ -5506,6 +5525,28 @@ process_tabledef(char *name, struct table_opts *opts, int popts) goto _error; } + + if (ukt != NULL) { + ukt->pfrukt_init_addr = opts->init_addr; + if (RB_INSERT(pfr_ktablehead, &pfr_ktables, + &ukt->pfrukt_kt) != NULL) { + /* + * I think this should not happen, because + * pfctl_define_table() above does the same check + * effectively. + */ + DBGPRINT( + "%s:%d table %s already exists in %s\n", + file->name, yylval.lineno, + ukt->pfrukt_name, pf->anchor->path); + free(ukt); + goto _error; + } + DBGPRINT("%s %s@%s inserted to tree\n", + __func__, ukt->pfrukt_name, pf->anchor->path); + } else + DBGPRINT("%s ukt is null\n", __func__); + pf->tdirty = 1; pfr_buf_clear(&ab); return (0); @@ -7276,6 +7317,61 @@ mv_eth_rules(struct pfctl_eth_ruleset *src, struct pfctl_eth_ruleset *dst) src->anchor->match = 0; } +void +mv_tables(struct pfctl *pf, struct pfr_ktablehead *ktables, + struct pfctl_anchor *a, struct pfctl_anchor *alast) +{ + struct pfr_ktable *kt, *kt_safe; + char new_path[PF_ANCHOR_MAXPATH]; + char *path_cut; + int sz; + struct pfr_uktable *ukt; + SLIST_HEAD(, pfr_uktable) ukt_list; + + /* + * Here we need to rename anchor path from temporal names such as + * _1/_2/foo to _1/bar/foo etc. + * + * This also means we need to remove and insert table to ktables + * tree as anchor path is being updated. + */ + SLIST_INIT(&ukt_list); + DBGPRINT("%s [ %s ] (%s)\n", __func__, a->path, alast->path); + RB_FOREACH_SAFE(kt, pfr_ktablehead, ktables, kt_safe) { + path_cut = strstr(kt->pfrkt_anchor, alast->path); + if (path_cut != NULL) { + path_cut += strlen(alast->path); + if (*path_cut) + sz = snprintf(new_path, sizeof (new_path), + "%s%s", a->path, path_cut); + else + sz = snprintf(new_path, sizeof (new_path), + "%s", a->path); + if (sz >= sizeof (new_path)) + errx(1, "new path is too long for %s@%s\n", + kt->pfrkt_name, kt->pfrkt_anchor); + + DBGPRINT("%s %s@%s -> %s@%s\n", __func__, + kt->pfrkt_name, kt->pfrkt_anchor, + kt->pfrkt_name, new_path); + RB_REMOVE(pfr_ktablehead, ktables, kt); + strlcpy(kt->pfrkt_anchor, new_path, + sizeof(kt->pfrkt_anchor)); + SLIST_INSERT_HEAD(&ukt_list, (struct pfr_uktable *)kt, + pfrukt_entry); + } + } + + while ((ukt = SLIST_FIRST(&ukt_list)) != NULL) { + SLIST_REMOVE_HEAD(&ukt_list, pfrukt_entry); + if (RB_INSERT(pfr_ktablehead, ktables, + (struct pfr_ktable *)ukt) != NULL) + errx(1, "%s@%s exists already\n", + ukt->pfrukt_name, + ukt->pfrukt_anchor); + } +} + void decide_address_family(struct node_host *n, sa_family_t *af) { @@ -7485,7 +7581,7 @@ parseport(char *port, struct range *r, int extensions) } int -pfctl_load_anchors(int dev, struct pfctl *pf, struct pfr_buffer *trans) +pfctl_load_anchors(int dev, struct pfctl *pf) { struct loadanchors *la; @@ -7494,7 +7590,7 @@ pfctl_load_anchors(int dev, struct pfctl *pf, struct pfr_buffer *trans) fprintf(stderr, "\nLoading anchor %s from %s\n", la->anchorname, la->filename); if (pfctl_rules(dev, la->filename, pf->opts, pf->optimize, - la->anchorname, trans) == -1) + la->anchorname, pf->trans) == -1) return (-1); } diff --git a/sbin/pfctl/pfctl.c b/sbin/pfctl/pfctl.c index 2c12387ee388..601b7651e40b 100644 --- a/sbin/pfctl/pfctl.c +++ b/sbin/pfctl/pfctl.c @@ -2065,6 +2065,41 @@ pfctl_load_eth_rule(struct pfctl *pf, char *path, struct pfctl_eth_rule *r, return (0); } +static int +pfctl_load_tables(struct pfctl *pf, char *path, struct pfctl_anchor *a, + int rs_num) +{ + struct pfr_ktable *kt, *ktw; + struct pfr_uktable *ukt; + char anchor_path[PF_ANCHOR_MAXPATH]; + int e; + + RB_FOREACH_SAFE(kt, pfr_ktablehead, &pfr_ktables, ktw) { + if (strcmp(kt->pfrkt_anchor, a->path) != 0) + continue; + + if (path != NULL && *path) { + strlcpy(anchor_path, kt->pfrkt_anchor, + sizeof(anchor_path)); + snprintf(kt->pfrkt_anchor, PF_ANCHOR_MAXPATH, "%s/%s", + path, anchor_path); + } + ukt = (struct pfr_uktable *)kt; + e = pfr_ina_define(&ukt->pfrukt_t, ukt->pfrukt_addrs.pfrb_caddr, + ukt->pfrukt_addrs.pfrb_size, NULL, NULL, + pf->anchor->ruleset.tticket, + ukt->pfrukt_init_addr ? PFR_FLAG_ADDRSTOO : 0); + if (e != 0) + err(1, "%s pfr_ina_define() %s@%s", __func__, + kt->pfrkt_name, kt->pfrkt_anchor); + RB_REMOVE(pfr_ktablehead, &pfr_ktables, kt); + pfr_buf_clear(&ukt->pfrukt_addrs); + free(ukt); + } + + return (0); +} + int pfctl_load_ruleset(struct pfctl *pf, char *path, struct pfctl_ruleset *rs, int rs_num, int depth) @@ -2113,6 +2148,8 @@ pfctl_load_ruleset(struct pfctl *pf, char *path, struct pfctl_ruleset *rs, if ((error = pfctl_load_ruleset(pf, path, &r->anchor->ruleset, rs_num, depth + 1))) goto error; + if ((error = pfctl_load_tables(pf, path, r->anchor, rs_num))) + goto error; } else if (pf->opts & PF_OPT_VERBOSE) printf("\n"); free(r); @@ -2135,15 +2172,17 @@ pfctl_load_rule(struct pfctl *pf, char *path, struct pfctl_rule *r, int depth) { u_int8_t rs_num = pf_get_ruleset_number(r->action); char *name; - u_int32_t ticket; char anchor[PF_ANCHOR_NAME_SIZE]; int len = strlen(path); int error; bool was_present; /* set up anchor before adding to path for anchor_call */ - if ((pf->opts & PF_OPT_NOACTION) == 0) - ticket = pfctl_get_ticket(pf->trans, rs_num, path); + if ((pf->opts & PF_OPT_NOACTION) == 0) { + if (pf->trans == NULL) + errx(1, "pfctl_load_rule: no transaction"); + pf->anchor->ruleset.tticket = pfctl_get_ticket(pf->trans, rs_num, path); + } if (strlcpy(anchor, path, sizeof(anchor)) >= sizeof(anchor)) errx(1, "pfctl_load_rule: strlcpy"); @@ -2175,7 +2214,7 @@ pfctl_load_rule(struct pfctl *pf, char *path, struct pfctl_rule *r, int depth) return (1); if (pfctl_add_pool(pf, &r->route, PF_RT)) return (1); - error = pfctl_add_rule_h(pf->h, r, anchor, name, ticket, + error = pfctl_add_rule_h(pf->h, r, anchor, name, pf->anchor->ruleset.tticket, pf->paddr.ticket); switch (error) { case 0: @@ -2245,6 +2284,8 @@ pfctl_rules(int dev, char *filename, int opts, int optimize, RB_INIT(&pf_anchors); memset(&pf_main_anchor, 0, sizeof(pf_main_anchor)); pf_init_ruleset(&pf_main_anchor.ruleset); + memset(&pf, 0, sizeof(pf)); + memset(&trs, 0, sizeof(trs)); pf_main_anchor.ruleset.anchor = &pf_main_anchor; memset(&pf_eth_main_anchor, 0, sizeof(pf_eth_main_anchor)); @@ -2254,6 +2295,7 @@ pfctl_rules(int dev, char *filename, int opts, int optimize, if (trans == NULL) { bzero(&buf, sizeof(buf)); buf.pfrb_type = PFRB_TRANS; + pf.trans = &buf; t = &buf; osize = 0; } else { @@ -2364,7 +2406,7 @@ pfctl_rules(int dev, char *filename, int opts, int optimize, if (trans == NULL) { /* process "load anchor" directives */ - if (pfctl_load_anchors(dev, &pf, t) == -1) + if (pfctl_load_anchors(dev, &pf) == -1) ERRX("load anchors"); if ((opts & PF_OPT_NOACTION) == 0) { diff --git a/sbin/pfctl/pfctl.h b/sbin/pfctl/pfctl.h index 37e06e93dde6..136f51ea08f9 100644 --- a/sbin/pfctl/pfctl.h +++ b/sbin/pfctl/pfctl.h @@ -36,6 +36,12 @@ #include +#ifdef PFCTL_DEBUG +#define DBGPRINT(...) fprintf(stderr, __VA_ARGS__) +#else +#define DBGPRINT(...) (void)(0) +#endif + extern struct pfctl_handle *pfh; struct pfctl; @@ -55,6 +61,41 @@ struct pfr_buffer { (var) != NULL; \ (var) = pfr_buf_next((buf), (var))) +RB_HEAD(pfr_ktablehead, pfr_ktable); +struct pfr_ktable { + struct pfr_tstats pfrkt_ts; + RB_ENTRY(pfr_ktable) pfrkt_tree; + SLIST_ENTRY(pfr_ktable) pfrkt_workq; + struct radix_node_head *pfrkt_ip4; + struct radix_node_head *pfrkt_ip6; + struct pfr_ktable *pfrkt_shadow; + struct pfr_ktable *pfrkt_root; + struct pf_kruleset *pfrkt_rs; + long pfrkt_larg; + int pfrkt_nflags; +}; +#define pfrkt_t pfrkt_ts.pfrts_t +#define pfrkt_name pfrkt_t.pfrt_name +#define pfrkt_anchor pfrkt_t.pfrt_anchor +#define pfrkt_ruleset pfrkt_t.pfrt_ruleset +#define pfrkt_flags pfrkt_t.pfrt_flags +#define pfrkt_cnt pfrkt_kts.pfrkts_cnt +#define pfrkt_refcnt pfrkt_kts.pfrkts_refcnt +#define pfrkt_tzero pfrkt_kts.pfrkts_tzero + +struct pfr_uktable { + struct pfr_ktable pfrukt_kt; + struct pfr_buffer pfrukt_addrs; + int pfrukt_init_addr; + SLIST_ENTRY(pfr_uktable) pfrukt_entry; +}; + +#define pfrukt_t pfrukt_kt.pfrkt_ts.pfrts_t +#define pfrukt_name pfrukt_kt.pfrkt_t.pfrt_name +#define pfrukt_anchor pfrukt_kt.pfrkt_t.pfrt_anchor + +extern struct pfr_ktablehead pfr_ktables; + struct pfr_anchoritem { SLIST_ENTRY(pfr_anchoritem) pfra_sle; char *pfra_anchorname; diff --git a/sbin/pfctl/pfctl_optimize.c b/sbin/pfctl/pfctl_optimize.c index 1d2a60555f19..2d16bbd22b39 100644 --- a/sbin/pfctl/pfctl_optimize.c +++ b/sbin/pfctl/pfctl_optimize.c @@ -1331,7 +1331,8 @@ again: if (pfctl_define_table(tbl->pt_name, PFR_TFLAG_CONST, 1, - pf->astack[0]->path, tbl->pt_buf, pf->astack[0]->ruleset.tticket)) { + pf->astack[0]->path, tbl->pt_buf, pf->astack[0]->ruleset.tticket, + NULL)) { warn("failed to create table %s in %s", tbl->pt_name, pf->astack[0]->name); return (1); diff --git a/sbin/pfctl/pfctl_parser.h b/sbin/pfctl/pfctl_parser.h index 58d3abc36691..e96ff0195e03 100644 --- a/sbin/pfctl/pfctl_parser.h +++ b/sbin/pfctl/pfctl_parser.h @@ -36,6 +36,8 @@ #include +#include + #define PF_OSFP_FILE "/etc/pf.os" #define PF_OPT_DISABLE 0x00001 @@ -90,6 +92,7 @@ struct pfctl { struct pfioc_queue *pqueue; struct pfr_buffer *trans; struct pfctl_anchor *anchor, *alast; + struct pfr_ktablehead pfr_ktlast; int eth_nr; struct pfctl_eth_anchor *eanchor, *ealast; struct pfctl_eth_anchor *eastack[PFCTL_ANCHOR_STACK_DEPTH]; @@ -277,6 +280,8 @@ struct pf_opt_rule { TAILQ_HEAD(pf_opt_queue, pf_opt_rule); +struct pfr_uktable; + void copy_satopfaddr(struct pf_addr *, struct sockaddr *); int pfctl_rules(int, char *, int, int, char *, struct pfr_buffer *); @@ -303,7 +308,7 @@ int pfctl_cfg_syncookies(struct pfctl *, uint8_t, struct pfctl_watermarks *); int parse_config(char *, struct pfctl *); int parse_flags(char *); -int pfctl_load_anchors(int, struct pfctl *, struct pfr_buffer *); +int pfctl_load_anchors(int, struct pfctl *); void print_pool(struct pfctl_pool *, u_int16_t, u_int16_t, int); void print_src_node(struct pfctl_src_node *, int); @@ -324,7 +329,7 @@ void print_queue(const struct pf_altq *, unsigned, struct node_queue_bw *, int, struct node_queue_opt *); int pfctl_define_table(char *, int, int, const char *, struct pfr_buffer *, - u_int32_t); + u_int32_t, struct pfr_uktable *); void pfctl_clear_fingerprints(int, int); int pfctl_file_fingerprints(int, int, const char *); @@ -380,5 +385,8 @@ struct node_host *host(const char *, int); int append_addr(struct pfr_buffer *, char *, int, int); int append_addr_host(struct pfr_buffer *, struct node_host *, int, int); +int pfr_ktable_compare(struct pfr_ktable *, + struct pfr_ktable *); +RB_PROTOTYPE(pfr_ktablehead, pfr_ktable, pfrkt_tree, pfr_ktable_compare); #endif /* _PFCTL_PARSER_H_ */ diff --git a/sbin/pfctl/pfctl_radix.c b/sbin/pfctl/pfctl_radix.c index 398c5e998330..98f907738d95 100644 --- a/sbin/pfctl/pfctl_radix.c +++ b/sbin/pfctl/pfctl_radix.c @@ -48,6 +48,7 @@ #include #include "pfctl.h" +#include "pfctl_parser.h" #define BUF_SIZE 256 @@ -55,6 +56,19 @@ extern int dev; static int pfr_next_token(char buf[BUF_SIZE], FILE *); +struct pfr_ktablehead pfr_ktables = { 0 }; +RB_GENERATE(pfr_ktablehead, pfr_ktable, pfrkt_tree, pfr_ktable_compare); + +int +pfr_ktable_compare(struct pfr_ktable *p, struct pfr_ktable *q) +{ + int d; + + if ((d = strncmp(p->pfrkt_name, q->pfrkt_name, PF_TABLE_NAME_SIZE))) + return (d); + return (strcmp(p->pfrkt_anchor, q->pfrkt_anchor)); +} + static void pfr_report_error(struct pfr_table *tbl, struct pfioc_table *io, const char *err) @@ -256,6 +270,7 @@ pfr_ina_define(struct pfr_table *tbl, struct pfr_addr *addr, int size, struct pfioc_table io; if (tbl == NULL || size < 0 || (size && addr == NULL)) { + DBGPRINT("%s %p %d %p\n", __func__, tbl, size, addr); errno = EINVAL; return (-1); } diff --git a/sbin/pfctl/pfctl_table.c b/sbin/pfctl/pfctl_table.c index 745ab84b3159..4955e1791fd7 100644 --- a/sbin/pfctl/pfctl_table.c +++ b/sbin/pfctl/pfctl_table.c @@ -570,19 +570,50 @@ print_astats(struct pfr_astats *as, int dns) int pfctl_define_table(char *name, int flags, int addrs, const char *anchor, - struct pfr_buffer *ab, u_int32_t ticket) + struct pfr_buffer *ab, u_int32_t ticket, struct pfr_uktable *ukt) { - struct pfr_table tbl; + struct pfr_table tbl_buf; + struct pfr_table *tbl; + + if (ukt == NULL) { + bzero(&tbl_buf, sizeof(tbl_buf)); + tbl = &tbl_buf; + } else { + if (ab->pfrb_size != 0) { + /* + * copy IP addresses which come with table from + * temporal buffer to buffer attached to table. + */ + ukt->pfrukt_addrs = *ab; + ab->pfrb_size = 0; + ab->pfrb_msize = 0; + ab->pfrb_caddr = NULL; + } else + memset(&ukt->pfrukt_addrs, 0, + sizeof(struct pfr_buffer)); + + tbl = &ukt->pfrukt_t; + } - bzero(&tbl, sizeof(tbl)); - if (strlcpy(tbl.pfrt_name, name, sizeof(tbl.pfrt_name)) >= - sizeof(tbl.pfrt_name) || strlcpy(tbl.pfrt_anchor, anchor, - sizeof(tbl.pfrt_anchor)) >= sizeof(tbl.pfrt_anchor)) - errx(1, "pfctl_define_table: strlcpy"); - tbl.pfrt_flags = flags; + if (strlcpy(tbl->pfrt_name, name, sizeof(tbl->pfrt_name)) >= + sizeof(tbl->pfrt_name) || + strlcpy(tbl->pfrt_anchor, anchor, sizeof(tbl->pfrt_anchor)) >= + sizeof(tbl->pfrt_anchor)) + errx(1, "%s: strlcpy", __func__); + tbl->pfrt_flags = flags; + DBGPRINT("%s %s@%s [%x]\n", __func__, tbl->pfrt_name, tbl->pfrt_anchor, + tbl->pfrt_flags); + + /* + * non-root anchors processed by parse.y are loaded to kernel later. + * Here we load tables, which are either created for root anchor + * or by 'pfctl -t ... -T ...' command. + */ + if (ukt != NULL) + return (0); - return pfr_ina_define(&tbl, ab->pfrb_caddr, ab->pfrb_size, NULL, - NULL, ticket, addrs ? PFR_FLAG_ADDRSTOO : 0); + return (pfr_ina_define(tbl, ab->pfrb_caddr, ab->pfrb_size, NULL, NULL, + ticket, addrs ? PFR_FLAG_ADDRSTOO : 0)); } void From nobody Wed Sep 17 14:15:40 2025 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 4cRglw66Ymz67SjQ; Wed, 17 Sep 2025 14:15:40 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRglw4n3wz448C; Wed, 17 Sep 2025 14:15:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118540; 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=7kpNpPo9G5Ln7iEvamLirM3DYLY/WZS03wRq3gDGLYo=; b=MYXTvKozqDd7bQ62gRTHNzuH4CZc0ipm3FMgeRzQqaJKuKTDYjb7PFk5TRQGw0ckrn5rRC Vv9QTvoz07R3FFPFwirhUOlI8lYJHVwvVsszdvyK3VcHAS1u8Z67ZUbYMUN8ihkQQNFX6Q 71fk9EiZwGVMzj10T9IaLWTcA2RC7g2lTW4lyX0qgPSLeD5PYuZyLtAgabetjBWGfm++uq x6YfWy8eQ9mebf7DrF/kPQ3ZMW7W6GQkcWqmkUqjl4nnhunH47YqC0f+Sjn3uLH6I6rTBi Hf/LRceM1n5WP5T+mndJDxOxBnCtoOXHR/InCMEDheCIF1wsAgYOuwuqN1PExw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118540; 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=7kpNpPo9G5Ln7iEvamLirM3DYLY/WZS03wRq3gDGLYo=; b=czdT4aoyiZ7rKro+TtIPciLPQBEePwEVdWCyRhacBGTFtrcIIv6ncI9aH3od54oWrzurff 1b3XSA1dIZwpb18Ah9B2jroGxyGrLu9Z1CFg48i0iko5j0wgm5Q1kivLtU+URp/PcDa5Zt Pn5nxq3bO0OMrKw37wlXKGeWvQmtlIhEJvFW1c+XQmyX58Q+eVN+fNMJMjraajC/AgmlQh Z5ziBq0S40E+UvnoI4VpwD0JscslN2UAVRHJc6wdObIyXQZ01JFrLy3dJTGMdt98PjWSpM 81ERdEph/SNfR7CiDlrGqTsHbjceJtHf5s9QcaB1H+wGcKQTwgNLg2g5EMaG/w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118540; a=rsa-sha256; cv=none; b=Uqyh3O+rec0Jn03M2Epvqo0w2Lis5XXy3vE84sNwB5TVme2wQiALKV0g4FWaRy/0cWTgH/ NM5ZKDgTY78CUcyVwtIBdVLzQI8/fEsrOb+hJVJ+GbaV/qzc2quaG1aI21Z51LgMQnHzYo uQRPNymP2pXr6dolEUj3OSfMhEofQ+GQS5foLwC72GzUT6cCYupjKSqy5USdrvXmHm0FPB M8DQ75/Ek0+qNCcPUp/olsySZvNipzkLAqGsj0AWrEsbpfHZHnbBc6Vz9HVpXpDlXa/HCX tt97+RrVhZUV0cXWgkJlbIaZ94lmJTlTth9kTKANa6CTOBLMNzH6MxgEgdBqPw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRglw4GXjzTTJ; Wed, 17 Sep 2025 14:15:40 +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 58HEFekI010177; Wed, 17 Sep 2025 14:15:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEFeG2010174; Wed, 17 Sep 2025 14:15:40 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:15:40 GMT Message-Id: <202509171415.58HEFeG2010174@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 26c373aa367c - main - pf tests: declare a table inside an anchor 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 26c373aa367c71394f0734af368974cafcf878d0 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=26c373aa367c71394f0734af368974cafcf878d0 commit 26c373aa367c71394f0734af368974cafcf878d0 Author: Kristof Provost AuthorDate: 2025-08-22 15:34:29 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 14:15:14 +0000 pf tests: declare a table inside an anchor Sponsored by: Rubicon Communications, LLC ("Netgate") --- tests/sys/netpfil/pf/table.sh | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/tests/sys/netpfil/pf/table.sh b/tests/sys/netpfil/pf/table.sh index 26fc5bf6cda2..69fe12fc9804 100644 --- a/tests/sys/netpfil/pf/table.sh +++ b/tests/sys/netpfil/pf/table.sh @@ -710,6 +710,43 @@ show_recursive_cleanup() pft_cleanup } +atf_test_case "in_anchor" "cleanup" +in_anchor_head() +{ + atf_set descr 'Test declaring tables in anchors' + atf_set require.user root +} + +in_anchor_body() +{ + pft_init + + epair_send=$(vnet_mkepair) + ifconfig ${epair_send}a 192.0.2.1/24 up + + vnet_mkjail alcatraz ${epair_send}b + jexec alcatraz ifconfig ${epair_send}b 192.0.2.2/24 up + + jexec alcatraz pfctl -e + + pft_set_rules alcatraz \ + "block all" \ + "anchor \"foo\" {\n + table counters { 192.0.2.1 }\n + pass in from \n + }\n" + + atf_check -s exit:0 -o ignore ping -c 3 192.0.2.2 + + jexec alcatraz pfctl -sr -a "*" -vv + jexec alcatraz pfctl -sT -a "*" -vv +} + +in_anchor_cleanup() +{ + pft_cleanup +} + atf_init_test_cases() { atf_add_test_case "v4_counters" @@ -727,4 +764,5 @@ atf_init_test_cases() atf_add_test_case "flush" atf_add_test_case "large" atf_add_test_case "show_recursive" + atf_add_test_case "in_anchor" } From nobody Wed Sep 17 14:15:41 2025 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 4cRglx6Z7lz67SQt; Wed, 17 Sep 2025 14:15:41 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRglx53Lqz44Jq; Wed, 17 Sep 2025 14:15:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118541; 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=GlycE29InmmlL9sx49ZL06zm0ZGXgmoEWn8api7I+xk=; b=lov8VPtB+IydRV4BVTTRsy7Vfv/ptRfGKj+no6ZzP0lkAPn4jr1orDGuzoNqBpavYbePpH 6PqiCGfbP+ldfmYhMGhGBOm7eaXIgw7x60wlp6i0bAwqXhqLXnhAMBc8qQf/vm5OvQ5j/K EGA+2ZI/1Z0hHkJjvGOWftMNagb83sAN+SJ+YtFGc+m5vgDGm3xDHzLec1HEkVsdgkd0SE H1QFJFVKkiOWBN4oPwTDhgfVCn3tp7c7hkMcWM04yXpeNAGxvQ4eFIG6zSy/0qV3QsAoWO EU/tPdOgMfTqqVKJFAsRtq0Mc/7n+W6Bo+N9wWhGOyOx+w4HcpdP78jAiK90Ig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118541; 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=GlycE29InmmlL9sx49ZL06zm0ZGXgmoEWn8api7I+xk=; b=P9gFa6FWxeWIyUJKeFqlDqk5rfuh1RY9cvcPEq5sRsVUUTyn0NXxw+1JQwDFEKgrtSFlnt FDt+xVgfTMNK3trB1NOgDVSdHvntgl6A2qno+PXww7+XkR220o+29okIJHUsICyLLuyNcs NLtoFr7Dd9BHw52uoc/VYp+eKF4CSv43cDCL1zAQF8mCF6O9B8tNpjR7q2DCJmEjnxHk2A 4FeaNQmyiE60m6Gbgsz2Z2n8vXCPqO23hd4kXePAR1fbY2YDnR5XYGfPDQWbMzykGMwMI3 phoqlayfJWlJqjVgb5JqqhQub4+ShQ7WdU972rpBaYfY5gxjrMgzO8f266yhAg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118541; a=rsa-sha256; cv=none; b=o7rtRFwADAMlcZtAhx45P8rexAAqLv1bVFxTPpgExL8gHD1X6hgnl6Zwx6v+yRWn98S0Zw JhW3QS8JacMxa/pMJiHWTlb6csL0AHoc5XG919+zONA3HyqXbZjbnT/2wZlY1E90pvvon4 3MI/L/K0SSLWEUlRTlbXXTCrPprWe9czXicbqKi2cjto9olWDgA5/49beeRGuVhtUisdmy ZvoDsciXsyrHOupUjiKA+POC2OLLUl+wIzO5d4LIZmNVABpnNJ2PDZbRm7FMepsVlhqWnw tI8i1T5zsn70M7T+6LFY7cLmAKMe82gmHLVysvdMwV1eAW1dS0AX8YHleVh1eQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRglx4Y5QzDGY; Wed, 17 Sep 2025 14:15:41 +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 58HEFf1q010218; Wed, 17 Sep 2025 14:15:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEFfCI010215; Wed, 17 Sep 2025 14:15:41 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:15:41 GMT Message-Id: <202509171415.58HEFfCI010215@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 05e99f5d1751 - main - pfctl.8: omit preceding flag from command/modifier lists to get tags 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 05e99f5d175117fb095ee62352903d5157cb1796 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=05e99f5d175117fb095ee62352903d5157cb1796 commit 05e99f5d175117fb095ee62352903d5157cb1796 Author: Kristof Provost AuthorDate: 2025-08-25 09:21:49 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 14:15:14 +0000 pfctl.8: omit preceding flag from command/modifier lists to get tags reads odd to repeat, e.g. -F, when listing all its modifiers. as a consequence, automatic tagging wouldn't work, e.g. no "zero" tag would exist to jump to that -F modifier's definition. also add manual tags for -R and -T as get explained together with -s and -t, respectively, where only the first flag gets tagged. Obtained from: OpenBSD, kn , e08605c7f2 Sponsored by: Rubicon Communications, LLC ("Netgate") --- sbin/pfctl/pfctl.8 | 92 +++++++++++++++++++++++++++--------------------------- 1 file changed, 46 insertions(+), 46 deletions(-) diff --git a/sbin/pfctl/pfctl.8 b/sbin/pfctl/pfctl.8 index 5a74a8fd3444..8e152f90d616 100644 --- a/sbin/pfctl/pfctl.8 +++ b/sbin/pfctl/pfctl.8 @@ -24,7 +24,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd August 5, 2025 +.Dd August 25, 2025 .Dt PFCTL 8 .Os .Sh NAME @@ -211,31 +211,31 @@ Flush the filter parameters specified by .Ar modifier (may be abbreviated): .Pp -.Bl -tag -width xxxxxxxxxxxx -compact -.It Fl F Cm nat +.Bl -tag -width xxxxxxxxx -compact +.It Cm nat Flush the NAT rules. -.It Fl F Cm queue +.It Cm queue Flush the queue rules. -.It Fl F Cm ethernet +.It Cm ethernet Flush the Ethernet filter rules. -.It Fl F Cm rules +.It Cm rules Flush the filter rules. -.It Fl F Cm states +.It Cm states Flush the state table (NAT and filter). -.It Fl F Cm Sources +.It Cm Sources Flush the source tracking table. -.It Fl F Cm info +.It Cm info Flush the filter information (statistics that are not bound to rules). -.It Fl F Cm Tables +.It Cm Tables Flush the tables. -.It Fl F Cm osfp +.It Cm osfp Flush the passive operating system fingerprints. -.It Fl F Cm Reset +.It Cm Reset Reset limits, timeouts and other options back to default settings. See the OPTIONS section in .Xr pf.conf 5 for details. -.It Fl F Cm all +.It Cm all Flush all of the above. .El .Pp @@ -401,13 +401,13 @@ Other rules and options are ignored. .It Fl o Ar level Control the ruleset optimizer, overriding any rule file settings. .Pp -.Bl -tag -width xxxxxxxxxxxx -compact -.It Fl o Cm none +.Bl -tag -width xxxxxxxxx -compact +.It Cm none Disable the ruleset optimizer. -.It Fl o Cm basic +.It Cm basic Enable basic ruleset optimizations. This is the default behaviour. -.It Fl o Cm profile +.It Cm profile Enable basic ruleset optimizations with profiling. .El .Pp @@ -437,10 +437,10 @@ Show the filter parameters specified by .Ar modifier (may be abbreviated): .Pp -.Bl -tag -width xxxxxxxxxxxxx -compact -.It Fl s Cm nat +.Bl -tag -width xxxxxxxxxxx -compact +.It Cm nat Show the currently loaded NAT rules. -.It Fl s Cm queue +.It Cm queue Show the currently loaded queue rules. When used together with .Fl v , @@ -450,13 +450,13 @@ When used together with .Nm will loop and show updated queue statistics every five seconds, including measured bandwidth and packets per second. -.It Fl s Cm ether +.It Cm ether Show the currently loaded Ethernet rules. When used together with .Fl v , the per-rule statistics (number of evaluations, packets, and bytes) are also shown. -.It Fl s Cm rules +.It Cm rules Show the currently loaded filter rules. When used together with .Fl v , @@ -469,7 +469,7 @@ will skip evaluation of rules where possible. Packets passed statefully are counted in the rule that created the state (even though the rule is not evaluated more than once for the entire connection). -.It Fl s Cm Anchors +.It Cm Anchors Show the currently loaded anchors directly attached to the main ruleset. If .Fl a Ar anchor @@ -480,11 +480,11 @@ If .Fl v is specified, all anchors attached under the target anchor will be displayed recursively. -.It Fl s Cm states +.It Cm states Show the contents of the state table. -.It Fl s Cm Sources +.It Cm Sources Show the contents of the source tracking table. -.It Fl s Cm info +.It Cm info Show filter information (statistics and counters). When used together with .Fl v , @@ -492,21 +492,21 @@ source tracking statistics, the firewall's 32-bit hostid number and the main ruleset's MD5 checksum for use with .Xr pfsync 4 are also shown. -.It Fl s Cm Running +.It Cm Running Show the running status and provide a non-zero exit status when disabled. -.It Fl s Cm labels +.It Cm labels Show per-rule statistics (label, evaluations, packets total, bytes total, packets in, bytes in, packets out, bytes out, state creations) of filter rules with labels, useful for accounting. -.It Fl s Cm timeouts +.It Cm timeouts Show the current global timeouts. -.It Fl s Cm memory +.It Cm memory Show the current pool memory hard limits. -.It Fl s Cm Tables +.It Cm Tables Show the list of tables. -.It Fl s Cm osfp +.It Cm osfp Show the list of operating system fingerprints. -.It Fl s Cm Interfaces +.It Cm Interfaces Show the list of interfaces and interface groups available to PF. When used together with .Fl v , @@ -516,7 +516,7 @@ When used together with interface statistics are also shown. .Fl i can be used to select an interface or a group of interfaces. -.It Fl s Cm all +.It Cm all Show all of the above, except for the lists of interfaces and operating system fingerprints. .El @@ -571,38 +571,38 @@ Specify the .Ar table . Commands include: .Pp -.Bl -tag -width "-T expire number" -compact -.It Fl T Cm add +.Bl -tag -width "expire number" -compact +.It Cm add Add one or more addresses to a table. Automatically create a persistent table if it does not exist. -.It Fl T Cm delete +.It Cm delete Delete one or more addresses from a table. -.It Fl T Cm expire Ar number +.It Cm expire Ar number Delete addresses which had their statistics cleared more than .Ar number seconds ago. For entries which have never had their statistics cleared, .Ar number refers to the time they were added to the table. -.It Fl T Cm flush +.It Cm flush Flush all addresses in a table. -.It Fl T Cm kill +.It Cm kill Kill a table. -.It Fl T Cm replace +.It Cm replace Replace the addresses of the table. Automatically create a persistent table if it does not exist. -.It Fl T Cm show +.It Cm show Show the content (addresses) of a table. -.It Fl T Cm test +.It Cm test Test if the given addresses match a table. -.It Fl T Cm zero Op Ar address ... +.It Cm zero Op Ar address ... Clear all the statistics of a table, or only for specified addresses. -.It Fl T Cm reset +.It Cm reset Clear statistics only for addresses with non-zero statistics. Addresses with counter values at zero and their .Dq Cleared timestamp are left untouched. -.It Fl T Cm load +.It Cm load Load only the table definitions from .Xr pf.conf 5 . This is used in conjunction with the From nobody Wed Sep 17 14:15:42 2025 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 4cRglz09tlz67SfB; Wed, 17 Sep 2025 14:15:43 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRgly5vXWz44Gr; Wed, 17 Sep 2025 14:15:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118542; 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=AcOWyyfhH+4mTrX2T6D7iwtaA01TIn/zhEAA6/QcOdI=; b=UbiqV+iL9535WiSrmnTR4Wurfa4RGHxkDU6gAtY74kMnfUtMWYK94Gg+NS/NpfiSCS0EUn w86eCq/Z0bZtnoZEH6sLLw5nl+K1GFhdH775TBzcQv1T3brZ18+XeHaWSCPoLeAyFl4KUE ZFqAArb+ulG24ffSELpIrRl6ktHckNvHNzbT7RnTBupeBEZG7PKuetgJiw8Nli3VuLG1mZ GDE3OTzC/bZilWR/hT4QOkNzi5U6CKWR1HCtDQfJ5u4TGDEeVWR0qyWURN3vR3O4eU1g5z 3fQqKv3u7LXy0icyaBZzAf/IcLwNMDkVbt5ilOkoeRS+sZ4nrt7AnumJwo8vIw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118542; 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=AcOWyyfhH+4mTrX2T6D7iwtaA01TIn/zhEAA6/QcOdI=; b=ZhwKaaRAxuqiaBWtg0SlXTmoaX8lvQGqqKKXaIkHUV7mmRZxmPUcnYobkwQHBAdp7ARJL1 zxOMToECagtOKB1dunJti/NZFf9PeMQFL65ijFKMTu3T/1TtJPnW5liTPxZ3/wTylfASBe V4pOpB5qc7fGiMzz1AjS2cXqfwi78fMHrBZLE5f4cnqmosNfbrk+h+qouuxFMlOBAz5KNd 7bZhuLHlZiAFgFltJeg+8oT4UShi1bYH12+yUAtD79zI12GLBvN3/iszF8lCaVWw6SWRdy 3avmnEiVws14/CVX6Q6TIP4WDPQbhuaErWbpJ0yVqqkvdVB79UXMBO6TZRX7gA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118542; a=rsa-sha256; cv=none; b=RE8WM2J5DZmyvgQHU7x8oG4XEiuXx8aK/fBXG9M37b0lb1wWL+6atajtK50nrh1YTyfRLN SZkwopUwRKP9ygpFlX47d3EoWDZs44LiY4Q4YYfRmjJD9X90ChttKIhxzoSFnmdsUHqF/J jpxhBnATcJFsKFeViCDtTD0N+ku0FO9bqhOvZbLnOeyV2fa2Grqogy22JUWGcDkDdjl6Il 72gt9Sv3ZIhjDZEUK6LbAgm0KBclRxweaCIyjCCPvEpkpoUvt6mAtBLpx1NZBIU4XJggz1 Uqw79hWvMsF0FUZaZzc7wGiv8YvjsZSxJOm+SIgWqepv/hWME2RoXQN6B+TZ9A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRgly5WDlzTYQ; Wed, 17 Sep 2025 14:15:42 +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 58HEFgH8010252; Wed, 17 Sep 2025 14:15:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEFg3Z010249; Wed, 17 Sep 2025 14:15:42 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:15:42 GMT Message-Id: <202509171415.58HEFg3Z010249@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 1066515eb521 - main - pf: Count m_gethdr() failures in PFRES_MEMORY counter 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1066515eb5219904c76f6f142e65ccf57eee6c53 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=1066515eb5219904c76f6f142e65ccf57eee6c53 commit 1066515eb5219904c76f6f142e65ccf57eee6c53 Author: Kristof Provost AuthorDate: 2025-08-25 09:36:23 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 14:15:14 +0000 pf: Count m_gethdr() failures in PFRES_MEMORY counter This requires passing the reason pointer down into pf_build_tcp(). ok bluhm@ Obtained from: OpenBSD, sf , 03c532ca70 Sponsored by: Rubicon Communications, LLC ("Netgate") --- sys/net/pfvar.h | 9 ++++---- sys/netpfil/pf/pf.c | 49 ++++++++++++++++++++++++++---------------- sys/netpfil/pf/pf_syncookies.c | 8 +++---- 3 files changed, 39 insertions(+), 27 deletions(-) diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index e0fda082fefe..8b102f198de8 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -2543,22 +2543,23 @@ struct mbuf *pf_build_tcp(const struct pf_krule *, sa_family_t, const struct pf_addr *, const struct pf_addr *, u_int16_t, u_int16_t, u_int32_t, u_int32_t, u_int8_t, u_int16_t, u_int16_t, u_int8_t, int, - u_int16_t, u_int16_t, u_int, int); + u_int16_t, u_int16_t, u_int, int, u_short *); void pf_send_tcp(const struct pf_krule *, sa_family_t, const struct pf_addr *, const struct pf_addr *, u_int16_t, u_int16_t, u_int32_t, u_int32_t, u_int8_t, u_int16_t, u_int16_t, u_int8_t, int, - u_int16_t, u_int16_t, int); + u_int16_t, u_int16_t, int, u_short *); void pf_syncookies_init(void); void pf_syncookies_cleanup(void); int pf_get_syncookies(struct pfioc_nv *); int pf_set_syncookies(struct pfioc_nv *); int pf_synflood_check(struct pf_pdesc *); -void pf_syncookie_send(struct pf_pdesc *); +void pf_syncookie_send(struct pf_pdesc *, u_short *); bool pf_syncookie_check(struct pf_pdesc *); u_int8_t pf_syncookie_validate(struct pf_pdesc *); -struct mbuf * pf_syncookie_recreate_syn(struct pf_pdesc *); +struct mbuf * pf_syncookie_recreate_syn(struct pf_pdesc *, + u_short *); VNET_DECLARE(struct pf_kstatus, pf_status); #define V_pf_status VNET(pf_status) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 5889bb9d68e6..aade1d9ace37 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -2834,7 +2834,7 @@ pf_remove_state(struct pf_kstate *s) s->key[PF_SK_WIRE]->port[0], s->src.seqhi, s->src.seqlo + 1, TH_RST|TH_ACK, 0, 0, 0, M_SKIP_FIREWALL, s->tag, 0, - s->act.rtableid); + s->act.rtableid, NULL); } LIST_REMOVE(s, entry); @@ -4080,7 +4080,7 @@ pf_build_tcp(const struct pf_krule *r, sa_family_t af, u_int16_t sport, u_int16_t dport, u_int32_t seq, u_int32_t ack, u_int8_t tcp_flags, u_int16_t win, u_int16_t mss, u_int8_t ttl, int mbuf_flags, u_int16_t mtag_tag, u_int16_t mtag_flags, u_int sack, - int rtableid) + int rtableid, u_short *reason) { struct mbuf *m; int len, tlen; @@ -4120,13 +4120,16 @@ pf_build_tcp(const struct pf_krule *r, sa_family_t af, } m = m_gethdr(M_NOWAIT, MT_DATA); - if (m == NULL) + if (m == NULL) { + REASON_SET(reason, PFRES_MEMORY); return (NULL); + } #ifdef MAC mac_netinet_firewall_send(m); #endif if ((pf_mtag = pf_get_mtag(m)) == NULL) { + REASON_SET(reason, PFRES_MEMORY); m_freem(m); return (NULL); } @@ -4346,13 +4349,14 @@ pf_send_tcp(const struct pf_krule *r, sa_family_t af, const struct pf_addr *saddr, const struct pf_addr *daddr, u_int16_t sport, u_int16_t dport, u_int32_t seq, u_int32_t ack, u_int8_t tcp_flags, u_int16_t win, u_int16_t mss, u_int8_t ttl, - int mbuf_flags, u_int16_t mtag_tag, u_int16_t mtag_flags, int rtableid) + int mbuf_flags, u_int16_t mtag_tag, u_int16_t mtag_flags, int rtableid, + u_short *reason) { struct pf_send_entry *pfse; struct mbuf *m; m = pf_build_tcp(r, af, saddr, daddr, sport, dport, seq, ack, tcp_flags, - win, mss, ttl, mbuf_flags, mtag_tag, mtag_flags, 0, rtableid); + win, mss, ttl, mbuf_flags, mtag_tag, mtag_flags, 0, rtableid, reason); if (m == NULL) return; @@ -4360,6 +4364,7 @@ pf_send_tcp(const struct pf_krule *r, sa_family_t af, pfse = malloc(sizeof(*pfse), M_PFTEMP, M_NOWAIT); if (pfse == NULL) { m_freem(m); + REASON_SET(reason, PFRES_MEMORY); return; } @@ -4421,9 +4426,10 @@ pf_return(struct pf_krule *r, struct pf_krule *nr, struct pf_pdesc *pd, if (tcp_get_flags(th) & TH_FIN) ack++; pf_send_tcp(r, pd->af, pd->dst, - pd->src, th->th_dport, th->th_sport, - ntohl(th->th_ack), ack, TH_RST|TH_ACK, 0, 0, - r->return_ttl, M_SKIP_FIREWALL, 0, 0, rtableid); + pd->src, th->th_dport, th->th_sport, + ntohl(th->th_ack), ack, TH_RST|TH_ACK, 0, 0, + r->return_ttl, M_SKIP_FIREWALL, 0, 0, rtableid, + reason); } } else if (pd->proto == IPPROTO_SCTP && (r->rule_flag & PFRULE_RETURN)) { @@ -4474,7 +4480,8 @@ pf_icmp_to_bandlim(uint8_t type) static void pf_send_challenge_ack(struct pf_pdesc *pd, struct pf_kstate *s, - struct pf_state_peer *src, struct pf_state_peer *dst) + struct pf_state_peer *src, struct pf_state_peer *dst, + u_short *reason) { /* * We are sending challenge ACK as a response to SYN packet, which @@ -4488,7 +4495,7 @@ pf_send_challenge_ack(struct pf_pdesc *pd, struct pf_kstate *s, pf_send_tcp(s->rule, pd->af, pd->dst, pd->src, pd->hdr.tcp.th_dport, pd->hdr.tcp.th_sport, dst->seqlo, src->seqlo, TH_ACK, 0, 0, s->rule->return_ttl, 0, 0, 0, - s->rule->rtableid); + s->rule->rtableid, reason); } static void @@ -6320,7 +6327,7 @@ pf_create_state(struct pf_krule *r, struct pf_test_ctx *ctx, pf_send_tcp(r, pd->af, pd->dst, pd->src, th->th_dport, th->th_sport, s->src.seqhi, ntohl(th->th_seq) + 1, TH_SYN|TH_ACK, 0, s->src.mss, 0, M_SKIP_FIREWALL, 0, 0, - pd->act.rtableid); + pd->act.rtableid, &ctx->reason); REASON_SET(&ctx->reason, PFRES_SYNPROXY); return (PF_SYNPROXY_DROP); } @@ -6910,7 +6917,7 @@ pf_tcp_track_full(struct pf_kstate *state, struct pf_pdesc *pd, th->th_sport, ntohl(th->th_ack), 0, TH_RST, 0, 0, state->rule->return_ttl, M_SKIP_FIREWALL, - 0, 0, state->act.rtableid); + 0, 0, state->act.rtableid, reason); src->seqlo = 0; src->seqhi = 1; src->max_win = 1; @@ -7035,7 +7042,8 @@ pf_synproxy(struct pf_pdesc *pd, struct pf_kstate *state, u_short *reason) pd->src, th->th_dport, th->th_sport, state->src.seqhi, ntohl(th->th_seq) + 1, TH_SYN|TH_ACK, 0, state->src.mss, 0, - M_SKIP_FIREWALL, 0, 0, state->act.rtableid); + M_SKIP_FIREWALL, 0, 0, state->act.rtableid, + reason); REASON_SET(reason, PFRES_SYNPROXY); return (PF_SYNPROXY_DROP); } else if ((tcp_get_flags(th) & (TH_ACK|TH_RST|TH_FIN)) != TH_ACK || @@ -7068,7 +7076,8 @@ pf_synproxy(struct pf_pdesc *pd, struct pf_kstate *state, u_short *reason) state->dst.seqhi, 0, TH_SYN, 0, state->src.mss, 0, state->orig_kif->pfik_ifp == V_loif ? M_LOOP : 0, - state->tag, 0, state->act.rtableid); + state->tag, 0, state->act.rtableid, + reason); REASON_SET(reason, PFRES_SYNPROXY); return (PF_SYNPROXY_DROP); } else if (((tcp_get_flags(th) & (TH_SYN|TH_ACK)) != @@ -7083,13 +7092,15 @@ pf_synproxy(struct pf_pdesc *pd, struct pf_kstate *state, u_short *reason) pd->src, th->th_dport, th->th_sport, ntohl(th->th_ack), ntohl(th->th_seq) + 1, TH_ACK, state->src.max_win, 0, 0, 0, - state->tag, 0, state->act.rtableid); + state->tag, 0, state->act.rtableid, + reason); pf_send_tcp(state->rule, pd->af, &sk->addr[pd->sidx], &sk->addr[pd->didx], sk->port[pd->sidx], sk->port[pd->didx], state->src.seqhi + 1, state->src.seqlo + 1, TH_ACK, state->dst.max_win, 0, 0, - M_SKIP_FIREWALL, 0, 0, state->act.rtableid); + M_SKIP_FIREWALL, 0, 0, state->act.rtableid, + reason); state->src.seqdiff = state->dst.seqhi - state->src.seqlo; state->dst.seqdiff = state->src.seqhi - @@ -7189,7 +7200,7 @@ pf_test_state(struct pf_kstate **state, struct pf_pdesc *pd, u_short *reason) * ACK enables all parties (firewall and peers) * to get in sync again. */ - pf_send_challenge_ack(pd, *state, src, dst); + pf_send_challenge_ack(pd, *state, src, dst, reason); return (PF_DROP); } } @@ -10899,7 +10910,7 @@ pf_test(sa_family_t af, int dir, int pflags, struct ifnet *ifp, struct mbuf **m0 /* Respond to SYN with a syncookie. */ if ((tcp_get_flags(&pd.hdr.tcp) & (TH_SYN|TH_ACK|TH_RST)) == TH_SYN && pd.dir == PF_IN && pf_synflood_check(&pd)) { - pf_syncookie_send(&pd); + pf_syncookie_send(&pd, &reason); action = PF_DROP; break; } @@ -10923,7 +10934,7 @@ pf_test(sa_family_t af, int dir, int pflags, struct ifnet *ifp, struct mbuf **m0 pd.dir == PF_IN) { struct mbuf *msyn; - msyn = pf_syncookie_recreate_syn(&pd); + msyn = pf_syncookie_recreate_syn(&pd, &reason); if (msyn == NULL) { action = PF_DROP; break; diff --git a/sys/netpfil/pf/pf_syncookies.c b/sys/netpfil/pf/pf_syncookies.c index 4a935bc65767..d11551ffb6ae 100644 --- a/sys/netpfil/pf/pf_syncookies.c +++ b/sys/netpfil/pf/pf_syncookies.c @@ -287,7 +287,7 @@ pf_synflood_check(struct pf_pdesc *pd) } void -pf_syncookie_send(struct pf_pdesc *pd) +pf_syncookie_send(struct pf_pdesc *pd, u_short *reason) { uint16_t mss; uint32_t iss; @@ -297,7 +297,7 @@ pf_syncookie_send(struct pf_pdesc *pd) pf_send_tcp(NULL, pd->af, pd->dst, pd->src, *pd->dport, *pd->sport, iss, ntohl(pd->hdr.tcp.th_seq) + 1, TH_SYN|TH_ACK, 0, mss, 0, M_SKIP_FIREWALL | (pd->m->m_flags & M_LOOP), 0, 0, - pd->act.rtableid); + pd->act.rtableid, reason); counter_u64_add(V_pf_status.lcounters[KLCNT_SYNCOOKIES_SENT], 1); /* XXX Maybe only in adaptive mode? */ atomic_add_64(&V_pf_status.syncookies_inflight[V_pf_syncookie_status.oddeven], @@ -495,7 +495,7 @@ pf_syncookie_generate(struct pf_pdesc *pd, uint16_t mss) } struct mbuf * -pf_syncookie_recreate_syn(struct pf_pdesc *pd) +pf_syncookie_recreate_syn(struct pf_pdesc *pd, u_short *reason) { uint8_t wscale; uint16_t mss; @@ -516,5 +516,5 @@ pf_syncookie_recreate_syn(struct pf_pdesc *pd) return (pf_build_tcp(NULL, pd->af, pd->src, pd->dst, *pd->sport, *pd->dport, seq, 0, TH_SYN, wscale, mss, pd->ttl, (pd->m->m_flags & M_LOOP), 0, PF_MTAG_FLAG_SYNCOOKIE_RECREATED, - cookie.flags.sack_ok, pd->act.rtableid)); + cookie.flags.sack_ok, pd->act.rtableid, reason)); } From nobody Wed Sep 17 14:15:43 2025 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 4cRgm01g5zz67SQv; Wed, 17 Sep 2025 14:15:44 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRglz6yXPz44Mg; Wed, 17 Sep 2025 14:15:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118544; 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=1x+KYgFyZweRVUkuoE0cRSLkVqQEKpyCMJ1BrkWsuxM=; b=XABpMy0o2ZSP3tbMy6QsH2rERyn4HDvcnGncbljWWniIQdZ4Da+htC+COmexWhQqucQQop keXNfYG3HRecXcDjk5Y1MiMzrrzlYHMjhS+rJrcd0RMd+E1YrJd4ITpeSoYoPicEk373KA NFUAs0GCKKezwThvrQUymcPLmA0rPAC+RDGoc6917I0hUAnRvZyJef8KTYJpwoZhsnmXla oK6kMCKXtu+lOfrCkswvX6mhb/atblrTX5z9YFc5/8NmLvKiKDkv54jp4ZCPCEMvAev4Tc acYV1vW+DMSJHpoa95sjWK67Y9h4DgMKYooFERplw0771XeZViRI+JummztXkw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118544; 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=1x+KYgFyZweRVUkuoE0cRSLkVqQEKpyCMJ1BrkWsuxM=; b=FvCbCJ9HImTOmHNfssdH0WugpSx+Y1ayOZnYpuH9kYeiuGnAT2SKWn2BEE2ckCpGyNm3Mj kV7aFhcrN2RLOsQTCGP1RmloduUNMPyiZGsURYeUbBl/iTSdcmweQG1ru4SzUlLZxijj2U f+/6LpDiFGmtPnJE6SWPAfyzYOX6iJxvkcFWspeQLsZybU4CNkWC2EYZE0AQ/HH0uk0Lmw tUmg3WLtu/JnM0Jsd2yTopVSQyZVKkie1TSRQAhWQQSyQP9kdgTifldeQQSyAh1t+N9/+4 aGEiUxO/USdBiZGIPZNGF0JFeAgWORWvtL7qvMSCwpMKSljQG8GnrHfxz/igGQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118544; a=rsa-sha256; cv=none; b=oYP8TESR4TCCGLnY5PIHElwnY3u+c8jKHrt0d13werIDaOXHj62uL3ARJrzpndVeGtbi4u Bn9noY7kp7Au1yVnZbMVqjtK/dEzVRmIPPjFemYc52u8ky/Ub02I5SmjMNTEABEG+Sa1Rm R4ZyUbfOL60bLejZS79WCyKC92p6Mqc4EgPqJt2EH4+g6vpxL9LRZlreq2IO7oA8fZgVoo G//n1svVKomJomI0562U1B/J7ZFUgG+JihZuEC8nYkaJJxx5SguyMLAR7v0PLzoPSXCYx8 RQSaP5nehoG9Vn/ovYA1EBJuZYuGt3gWa9xQKtxOwD710cpGspWNOEuF+GXXDw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRglz6TTnzTZt; Wed, 17 Sep 2025 14:15:43 +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 58HEFhvL010285; Wed, 17 Sep 2025 14:15:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEFh9g010282; Wed, 17 Sep 2025 14:15:43 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:15:43 GMT Message-Id: <202509171415.58HEFh9g010282@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 9d9bc7f462bd - main - pf: set limits before rules 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9d9bc7f462bd152d87ab8f1767cad19bab09bf8b Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=9d9bc7f462bd152d87ab8f1767cad19bab09bf8b commit 9d9bc7f462bd152d87ab8f1767cad19bab09bf8b Author: Kristof Provost AuthorDate: 2025-08-25 13:43:10 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 14:15:15 +0000 pf: set limits before rules The current way to adjust pf(4) limits in pf.conf(5) is inconvenient. For example when ruleset uses more than 512 anchors (the current default limit) one would typically add 'set limit anchor 1024' to adjust the limit so the 'pf.conf(5)' gets processed. Unfortunately it does not work because limit gets changed with DIOCXCOMMIT which is too late. The pf.conf(5) fails to load the anchors to transaction, because the old lower limit is still in place. To fix it we must set the limit as soon as we parse 'set limit ...' option. The issue has been reported and fix tested by rafal _dot_ ramocki _von_ eo.pl OK @bluhm Obtained from: OpenBSD, sashan , 85baac7751 Sponsored by: Rubicon Communications, LLC ("Netgate") --- sbin/pfctl/pfctl.c | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 57 insertions(+), 3 deletions(-) diff --git a/sbin/pfctl/pfctl.c b/sbin/pfctl/pfctl.c index 601b7651e40b..b29d992b1cda 100644 --- a/sbin/pfctl/pfctl.c +++ b/sbin/pfctl/pfctl.c @@ -110,6 +110,8 @@ int pfctl_show_status(int, int); int pfctl_show_running(int); int pfctl_show_timeouts(int, int); int pfctl_show_limits(int, int); +void pfctl_read_limits(struct pfctl_handle *); +void pfctl_restore_limits(void); void pfctl_debug(int, u_int32_t, int); int pfctl_test_altqsupport(int, int); int pfctl_show_anchors(int, int, char *); @@ -189,6 +191,8 @@ static const struct { { NULL, 0 } }; +static unsigned int limit_curr[PF_LIMIT_MAX]; + struct pf_hint { const char *name; int timeout; @@ -1780,6 +1784,31 @@ pfctl_show_limits(int dev, int opts) return (0); } +void +pfctl_read_limits(struct pfctl_handle *h) +{ + int i; + + for (i = 0; pf_limits[i].name; i++) { + if (pfctl_get_limit(h, i, &limit_curr[i])) + err(1, "DIOCGETLIMIT"); + } +} + +void +pfctl_restore_limits(void) +{ + int i; + + if (pfh == NULL) + return; + + for (i = 0; pf_limits[i].name; i++) { + if (pfctl_set_limit(pfh, i, limit_curr[i])) + warn("DIOCSETLIMIT (%s)", pf_limits[i].name); + } +} + void pfctl_show_creators(int opts) { @@ -2487,8 +2516,14 @@ pfctl_init_options(struct pfctl *pf) pf->limit[PF_LIMIT_STATES] = PFSTATE_HIWAT; pf->limit[PF_LIMIT_FRAGS] = PFFRAG_FRENT_HIWAT; - pf->limit[PF_LIMIT_SRC_NODES] = PFSNODE_HIWAT; - pf->limit[PF_LIMIT_TABLE_ENTRIES] = PFR_KENTRY_HIWAT; + + pf->limit[PF_LIMIT_SRC_NODES] = (limit_curr[PF_LIMIT_SRC_NODES] == 0) ? + PFSNODE_HIWAT : limit_curr[PF_LIMIT_SRC_NODES]; + pf->limit[PF_LIMIT_TABLE_ENTRIES] = + (limit_curr[PF_LIMIT_TABLE_ENTRIES] == 0) ? + PFR_KENTRY_HIWAT : limit_curr[PF_LIMIT_TABLE_ENTRIES]; + pf->limit[PF_LIMIT_ANCHORS] = (limit_curr[PF_LIMIT_ANCHORS] == 0) ? + PF_ANCHOR_HIWAT : limit_curr[PF_LIMIT_ANCHORS]; pf->debug = PF_DEBUG_URGENT; pf->reassemble = 0; @@ -2589,6 +2624,9 @@ pfctl_apply_limit(struct pfctl *pf, const char *opt, unsigned int limit) if (pf->opts & PF_OPT_VERBOSE) printf("set limit %s %d\n", opt, limit); + if ((pf->opts & PF_OPT_NOACTION) == 0) + pfctl_load_options(pf); + return (0); } @@ -3452,6 +3490,11 @@ main(int argc, char *argv[]) if (pfh == NULL) err(1, "Failed to open netlink"); + if ((opts & PF_OPT_NOACTION) == 0) { + pfctl_read_limits(pfh); + atexit(pfctl_restore_limits); + } + if (opts & PF_OPT_DISABLE) if (pfctl_disable(dev, opts)) exit_val = 1; @@ -3695,7 +3738,18 @@ main(int argc, char *argv[]) } } - exit(exit_val); + /* + * prevent pfctl_restore_limits() exit handler from restoring + * pf(4) options settings on successful exit. + */ + if (exit_val == 0) { + close(dev); + dev = -1; + pfctl_close(pfh); + pfh = NULL; + } + + return (exit_val); } char * From nobody Wed Sep 17 14:15:46 2025 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 4cRgm240Gtz67SZF; Wed, 17 Sep 2025 14:15:46 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRgm21vvTz44YX; Wed, 17 Sep 2025 14:15:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118546; 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=1ARxn3zjXhPQ+q8Kqa6rQKgbZl/rhxzHl0MZR1hcxWQ=; b=OcF788h226kCzeRae7zVotnUfHXcTVNuGzwCkAbeM7uTnSjljGbDarhD20RHJeyesSugLq RAy+3rLWL324W3J76/Rz7ZN5b/oBCDQxd4ehLBp5QC0iDW7wijZcvPfCYZP5extdvYnrJK yHUtnI5XNwkaEDjDs03Xgk7+cYjYGvB8YcIRP2wXiT7QEpjw1jhFA7RSC+frwTHO7XQbBe x/BuMTlEpocOgn4DQzkRBFz4ZBNIQqmzkmixN4pA2KLdQP1/mAH0WszkpVXF/72KVw89a4 McqRKpJ4u9q2RLVG2XVuiOaf/VWJE06WzF1y8wpriKQoh5VtbfY+K7EPv6zJmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118546; 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=1ARxn3zjXhPQ+q8Kqa6rQKgbZl/rhxzHl0MZR1hcxWQ=; b=ukKbDICj4qpOIu1ApmDR0pu4995a+P/cuR8Ey6JjrGfFzUG5iF3IMHxRbdOjPkYSNNqDNm hAoxG++fyz5VKt6f5FlpaiQUj0nTCsUngZjg1IX4WC78yjkdZFr18fXbdyN4K6VVH+u/N2 NU1es6bpVOPXmDqa1iDTdB8YI4Wzn3bfhHlV1mM6kL08HJNw/9D+68QwzTtCrr2eR9eO+a nXV0DBywkhsTnwdYvIfPX79ZnSjwKU5ECQZyuAVj/e56fCWfmY4AkbTWICG7pZ5WJ6ENEc 8D+bKyKwvCiNMk0+AKY6LNaUaIcq1eUCciUcC1riJpF27GYghRuxc8FXo3fxXQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118546; a=rsa-sha256; cv=none; b=pUFuibj/EaMhF+Ao2XQ6JR9kS4tifMPPi1VO61O1CXjLIUHA9EAI5fgOmdeJbIISeRliCD ixOHrnFQFkJHc0QPHZ5+pbXpHA9yLeSV7h2Ff1zfB5ycnGOCEB6FP4TV8/4tOV274PTyZR pdAyR5gVPfB9u//Sv66CyOvUjt2n5lXp5jiPkdxIa7r9EsyAwm6AM3p4Wa2+aO2Q4Gw82X r65hXyO7/p2sPDIqg4WuzfNX4BOQjAeNHJjr/d4MIvU14ajdMY9Rflb2qjHZwsHJWfQXiO dxRnGHsspC9yIKYp3qdZIa1HeCnhZT0yVUo8Wt8nZKGMGOU9ocCDFobPFIkYhQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRgm20wYZzTJ3; Wed, 17 Sep 2025 14:15:46 +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 58HEFkPb010358; Wed, 17 Sep 2025 14:15:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEFkFC010352; Wed, 17 Sep 2025 14:15:46 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:15:46 GMT Message-Id: <202509171415.58HEFkFC010352@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: fc63421de9f6 - main - pf: allows TCP RST packets in the backwards window if ACK matches 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: fc63421de9f69ed67aad7bae29712fca2f570693 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=fc63421de9f69ed67aad7bae29712fca2f570693 commit fc63421de9f69ed67aad7bae29712fca2f570693 Author: Kristof Provost AuthorDate: 2025-08-25 13:49:22 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 14:15:15 +0000 pf: allows TCP RST packets in the backwards window if ACK matches TCP reset packets are generated for the sequence numbers that have been acknowledged. Our pf(4) is quite strict regarding sequence numbers of reset packets to avoid evil connection drops. It expected exact match and did not allow a sequence window for resets. As pf tracks neither gaps in the sequence space nor the acknowledged data, it does not know where exactly the reset is expected by the TCP stack. Problem was that legit reset packets before a gap but not at the highest sequence numbers were blocked by pf. Solution is to fix pf_tcp_track_full(). Now it allows sequence number windows if the packet has ACK+RST flags set and the acknowlege number matches perfectly. This still prevents reset number guessing by an attacker. Curiously the TCP stack behaves correctly and accepts only resets before the gap. pf only allowed resets after the final data. So any reset was ignored by the system. When the other side processed the challenge ACK, the situation could be fixed. bug reported and fix tested by Lucas Aubard with Johan Mazel, Gilles Guette and Pierre Chifflier; OK sashan@ Obtained from: OpenBSD, bluhm , 12e4c257ea Sponsored by: Rubicon Communications, LLC ("Netgate") --- sys/netpfil/pf/pf.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index aade1d9ace37..2705df61a1f7 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -6775,8 +6775,12 @@ pf_tcp_track_full(struct pf_kstate *state, struct pf_pdesc *pd, (ackskew <= (MAXACKWINDOW << sws)) && /* Acking not more than one window forward */ ((tcp_get_flags(th) & TH_RST) == 0 || orig_seq == src->seqlo || - (orig_seq == src->seqlo + 1) || (orig_seq + 1 == src->seqlo))) { + (orig_seq == src->seqlo + 1) || (orig_seq + 1 == src->seqlo) || /* Require an exact/+1 sequence match on resets when possible */ + (SEQ_GEQ(orig_seq, src->seqlo - (dst->max_win << dws)) && + SEQ_LEQ(orig_seq, src->seqlo + 1) && ackskew == 0 && + (th->th_flags & (TH_ACK|TH_RST)) == (TH_ACK|TH_RST)))) { + /* Allow resets to match sequence window if ack is perfect match */ if (dst->scrub || src->scrub) { if (pf_normalize_tcp_stateful(pd, reason, th, From nobody Wed Sep 17 14:15:44 2025 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 4cRgm13lSkz67Sq5; Wed, 17 Sep 2025 14:15:45 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRgm10t7Lz44Sf; Wed, 17 Sep 2025 14:15:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118545; 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=lC6nlhrL9wRGtem5cPBTKiM28r2y8YVOV2FMsrJIMK8=; b=T02pX1ILGp4ZOfFCdOhy2TesiUWZRm4V9zPqCcaAI1x+JsNIKzQjJhKPK1Z7Qv5ZO2NOiM ZJX7+G1N+fafQFzbtCSenyBCWpl/ZKPZ4lL2g3XrjcwyJoCuWyWAf/UjUF/ENzA9VfcCEf T63NRC8hielSNunEH6bHs3h8zvZ9qQXe57uyF1jI+ig1C94Xpb+yXvn1KHB11Vwh1g5VXV G4hNGZ00/dqaIR/IQLpoV+lQfUE6KnrsXpqAliCLPEVRDI4qpmzTWxQnlXjV8Ffl5Pb44o 08wm+nDC43VErWrCph2fmp4bYVqFtcHhNIWsfM81l8cgBUijblRdI8NzWyxKHg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118545; 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=lC6nlhrL9wRGtem5cPBTKiM28r2y8YVOV2FMsrJIMK8=; b=cbdbpID1xKjwAisTU2HrSeUDYYH1cH5WbbwiQ5p+fHvVp9DL/qD5Pyc/ZqSWRaoKBzgm7F fR0gFMwAMlRVWbpyl69FDrlMsBCAsFICgYE1O1VQR7ZxML5a2Na4bDMf7GIVIXzZoZAea0 SSowOqwu5SErVa4kMjWlghWO36meT7KNDt0b1TwKAwgY0YXvZSHoSmXWcLidp9HmAcFU+s HqRieMmT3tkB99KaVHKpdt2SoZ/CtnpUuDoQabtZaV3hPjU46aKpLua6uTInLv1YWZFgup 9SCUY9aT4zoP1pu25QhjGXskSweGRlzGeaUI3PBOlehqrb9BG/tL09p4rtD+Uw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118545; a=rsa-sha256; cv=none; b=N4K5eJRTt1yz9AKRGXBZ7CcJ+VNrSb5jsV4xC/vrOLJ8/UkzBw0zxCnuCXAX4beyIxHhnW O3Cjqr7VDCUz3cQDldGlnPo4WDX4wYgZ7Y7MZi/qnn7hqqOYbT5492yT989HT/hmNck8Oo Hydcl55G66nk3DpFKfmEz0+Nn6JLuKi9li4iP0wnokSUOCUQ7py92/c1r/pIoiUwlKZyEG QPHiVBg0Qt8+s6s9I20NFOUjQ673VDSvPLVNymY2Ij5VmVLwLCg7dTiCPZAnzPeVzjnDZC /z8j/3EX5mOFO2cYKmAg4H6zfyFN3rjMSa5jb/A1FwhkFrtGPMTr7+StCKAkEg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRgm10LRXzDGZ; Wed, 17 Sep 2025 14:15:45 +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 58HEFirn010318; Wed, 17 Sep 2025 14:15:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEFi4n010315; Wed, 17 Sep 2025 14:15:44 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:15:44 GMT Message-Id: <202509171415.58HEFi4n010315@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 7eb30b26aa12 - main - pf tests: test set limit 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7eb30b26aa12cf1b80b6a784ccbd0b6f648f4529 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=7eb30b26aa12cf1b80b6a784ccbd0b6f648f4529 commit 7eb30b26aa12cf1b80b6a784ccbd0b6f648f4529 Author: Kristof Provost AuthorDate: 2025-08-25 13:44:11 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 14:15:15 +0000 pf tests: test set limit Verify that 'set limit anchors' now has the expected effect. Sponsored by: Rubicon Communications, LLC ("Netgate") --- tests/sys/netpfil/pf/limits.sh | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/tests/sys/netpfil/pf/limits.sh b/tests/sys/netpfil/pf/limits.sh index 69f0b6af2ccf..a0d6b891ee19 100644 --- a/tests/sys/netpfil/pf/limits.sh +++ b/tests/sys/netpfil/pf/limits.sh @@ -112,8 +112,43 @@ zero_cleanup() pft_cleanup } +atf_test_case "anchors" "cleanup" +anchors_head() +{ + atf_set descr 'Test increasing maximum number of anchors' + atf_set require.user root +} + +anchors_body() +{ + pft_init + + vnet_mkjail alcatraz + + jexec alcatraz pfctl -e + + pft_set_rules alcatraz \ + "set limit anchors 1" + + pft_set_rules alcatraz \ + "set limit anchors 2" \ + "pass" \ + "anchor \"foo\" {\n + pass in\n + }" \ + "anchor \"bar\" {\n + pass out\n + }" +} + +anchors_cleanup() +{ + pft_cleanup +} + atf_init_test_cases() { atf_add_test_case "basic" atf_add_test_case "zero" + atf_add_test_case "anchors" } From nobody Wed Sep 17 14:15:47 2025 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 4cRgm40Y61z67ScM; Wed, 17 Sep 2025 14:15:48 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRgm3220cz44T9; Wed, 17 Sep 2025 14:15:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118547; 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=k9DpblS3SvO5nhBpRR7L9kkWujj/bQbYy7HjSzWKpyQ=; b=TGpiUpnzQOnHTSGBevCSe2zF5Y8C8LzdWwpvNZwfNm/ZGu4lBFpsIQ7DzSDCaevqw7sSMZ HKXL4Lnb7qTsGboxMf06PFV9d+zCeztMc+FO4+9y8mZvSz2H/fdUuyQ/Z5/QWFg3Oyp70P i66RM0aheK2eLrXIeDoYdvGNGUnVo5IsDlgGXJ8KHG8gmCbttRuWL4uugC35Qq3IpHwIJl 0fO9JrjhoemsqhkJIuMqCRntY1xSM8eRvumh0HuQukOzHGLHKQ01ggUuVNl9GlW5i8tpP4 OZ/5E2xE0vi1vytYU/UHW8dmRaGaF0EfLAHNbKTw0apGE0qmDpg2GI1XbOxrEA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118547; 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=k9DpblS3SvO5nhBpRR7L9kkWujj/bQbYy7HjSzWKpyQ=; b=b2zHaP/r/19vjZmuLu/0HD4JBAtH/k6AZ97orP0vWfq6H7lSWP83f6WcQoUMp2OoggDndh JgZZ0vmOl47NkGnlm1q9yfKw3vEMfBFWWx5LSIfYJS/gkC6BcxzHKZQZLXIMsve3fWpPI1 PXXmSa8hodATcCWDHNZ5kamAdKbg11b8YGvdbGfzEBiqkzDDMiDco0V9vBhTv4rmJrxcT2 SsGXEgbeuHBbAQJptqJ3ffuoCUpkFywIiV8KHMDEPI3/StCWsjvq5j+9DMI4QgYVvCD4LD eXLRdrGxuxEVSEW0756YBiE3k19zMV0MPdNKbOq+IBfvZt+2zdYL+mcRakKbAw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118547; a=rsa-sha256; cv=none; b=fQrFtZQwv5SQPWDSRDmjQo47o/fbdO4Iwo9TJW+wq1fm/+3xEt3lUg7rF1uQpStwmmMiyK Ge72HdChPFJv+9XIAW5cy7AIR6/fcSuRcUsPqxQu5ofzendCywVwfYzvftVegq3W1D0V8o GXKZ1Bh+YJ/SykkFXh6LK85V9fuunx5uMWhN1iFZksoz2oIPozqvSyM6C1VslDQ0G8c4p5 zDEMgMCoHEpyS6muVq8/PUsLLbGwDibWyRnPZNBAJJjvtgoK+GU8VSGnLsYbPfe8IKYZXe ID4er7DirQHxsd1PgcNF2bA1HAfyYVuHbAklrnvFqNvizIyxZFb30gUp0wetWg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRgm31c8DzDY1; Wed, 17 Sep 2025 14:15:47 +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 58HEFllP010395; Wed, 17 Sep 2025 14:15:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEFleU010392; Wed, 17 Sep 2025 14:15:47 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:15:47 GMT Message-Id: <202509171415.58HEFleU010392@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: c016bd00294d - main - pfctl.8: -z honours -a (reset rule stats per anchor) 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c016bd00294df7be6b3b3dbc661ac7b952831475 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=c016bd00294df7be6b3b3dbc661ac7b952831475 commit c016bd00294df7be6b3b3dbc661ac7b952831475 Author: Kristof Provost AuthorDate: 2025-08-25 14:46:33 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 14:15:15 +0000 pfctl.8: -z honours -a (reset rule stats per anchor) OK sashan henning deraadt Obtained from: OpenBSD, kn , 1ddc001403 Sponsored by: Rubicon Communications, LLC ("Netgate") --- sbin/pfctl/pfctl.8 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sbin/pfctl/pfctl.8 b/sbin/pfctl/pfctl.8 index 8e152f90d616..f1a2bbef6236 100644 --- a/sbin/pfctl/pfctl.8 +++ b/sbin/pfctl/pfctl.8 @@ -115,8 +115,9 @@ Apply flags .Fl f , .Fl F , .Fl s , +.Fl T , and -.Fl T +.Fl z only to the rules in the specified .Ar anchor . In addition to the main ruleset, From nobody Wed Sep 17 14:15:48 2025 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 4cRgm46klPz67SND; Wed, 17 Sep 2025 14:15:48 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRgm42mwCz44LP; Wed, 17 Sep 2025 14:15:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118548; 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=eAJnzUyVC/Wuhw1YWabZMvhhmDMbdH6qcaLIagnWnrc=; b=vMjc0eESjt9abH/pfu3EpV01Ht1qSTRMdQSeaZGjDMz1zyRrIXYk6A/rVj6urfip4duSO0 kga1tc0xYxrRmEgbJSdh5X+uMLyP14V7bC1CuTPg658akU5r1XS6raGQVPNU3w8+3lbrf4 f+M0UtYGetfnG0faJwolKGqNJv9kSBjnZ5YNfdcypN/tqDPicXvaWGUdzOFIYJ+46xrC8K qA3NZg3gEaexBJmcou7/tZtZTHyZT2ZhH41D1gWDyfOGbs+9HHkD0NeUM+8CHdSH0COVvi LmVw+Q4IVTgZmZXHEI8C5Ebz73y1YqhMGyEpBoRmCCkvjFvgW7S+uqpU7cS66w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118548; 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=eAJnzUyVC/Wuhw1YWabZMvhhmDMbdH6qcaLIagnWnrc=; b=RUtqAxoR6F77F3kVkjeKQNsl/LcRW3l0/Vo2JTM04YNugMHzn+Og0EMyGvg+DPkwlY4gti pCzWv1AMDWfso2Ofvw+C6DkpIHpW7tfPt1TiXU0nI44TFOwdEimCdF0TqxSqvzkGyRv5UT vF7UroQ4bxfCNACDbDpV+ZtrNTIoRdRRtxmrvA+4Cj9x+C+iYaxh3OdFQkMGKf2PYLrch6 A6QMT2kp7UwrrU5mAL9TJoYhlArh0yjfnf+cxs2OkkwCKbnPRGG6c+yR51n66/YzX+lbs+ R/jsSMyUL60oS3/Fr+aW14CtTA2i63JXpqP/xbt5D7kgbqr3pP94vTa/x+DOTA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118548; a=rsa-sha256; cv=none; b=Zayo/YkeiLwAACm6FJEYhmohRnGGKLG+xOhOidsz4eMNPAblWLQfiEinWr9R4pEuoEt9Ob VHr8ZgP2o3bHxQL/pN7xE3Mn9cbaVG1D6OX0gNpuiw0wMmmVu3S4lgJUKhUZn7IMCDnmeB 6aNXiCcade8sQOAln8WdVfPeCJ2J1CVuO+QAzmonJi60XEdQhd7WKWb3fhwAFDTZ/lOnvS shc4gjLPdmumQIbVRKYqIXbslzE2XNfXkvRBbo9BstBLTklR/lWZSyu8D9bdHh1PdvpE2P jZp1At6X7N5zN9Ud7I93AE5Yco56MsSE3Ofl460VrmnpK/b/x/iwpt67D8DwMg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRgm42D3fzTJ4; Wed, 17 Sep 2025 14:15:48 +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 58HEFmGt010430; Wed, 17 Sep 2025 14:15:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEFmp5010427; Wed, 17 Sep 2025 14:15:48 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:15:48 GMT Message-Id: <202509171415.58HEFmp5010427@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 3c3322d7ee97 - main - pf.conf.5: rephrase macro section 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 3c3322d7ee974673f6b8f7a490153f3558e71118 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=3c3322d7ee974673f6b8f7a490153f3558e71118 commit 3c3322d7ee974673f6b8f7a490153f3558e71118 Author: Kristof Provost AuthorDate: 2025-08-25 15:08:36 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 14:15:16 +0000 pf.conf.5: rephrase macro section In the manual pages for configuration files based on parse.y, describe the syntax of both defining and using macros, rather than exclusively relying on examples, which some of the pages do not even provide. In those pages containing tables of content, also clarify that the "Macros" section contains *definitions* of variables. Both changes were already committed to vm.conf(5) earlier. OK florian@, and deraadt also requests keeping these manuals in sync. Obtained from: OpenBSD, schwarze , 20aba01e82 Sponsored by: Rubicon Communications, LLC ("Netgate") --- share/man/man5/pf.conf.5 | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/share/man/man5/pf.conf.5 b/share/man/man5/pf.conf.5 index edaa160dddf2..02114b3eaf3c 100644 --- a/share/man/man5/pf.conf.5 +++ b/share/man/man5/pf.conf.5 @@ -27,7 +27,7 @@ .\" ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd August 20, 2025 +.Dd August 25, 2025 .Dt PF.CONF 5 .Os .Sh NAME @@ -92,14 +92,20 @@ keyword, for example: include "/etc/pf/sub.filter.conf" .Ed .Sh MACROS -Macros can be defined that will later be expanded in context. -Macro names must start with a letter, and may contain letters, digits -and underscores. -Macro names may not be reserved words (for example +A macro is defined with a command of the form +.Ar name Ns = Ns Ar value . +The macro +.Ar name +can contain letters, digits, and underscores and cannot be a reserved word +(for example, .Ar pass , .Ar in , +or .Ar out ) . -Macros are not expanded inside quotes. +Within unquoted arguments, the string +.Pf $ Ar name +is later expanded to +.Ar value . Ranges of network addresses used in macros that will be expanded in lists later on must be quoted with additional simple quotes. .Pp From nobody Wed Sep 17 14:15:49 2025 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 4cRgm570v6z67Sq9; Wed, 17 Sep 2025 14:15:49 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRgm53J2nz44TX; Wed, 17 Sep 2025 14:15:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118549; 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=ftiUiGcyP83PHIERnw6tNsYeB76Wd7gILboepUDAPpk=; b=BIjYt8yuRnozEDqRr7v+8yByZVuQdRp8SP6W2vlPcJmTVjwiw9L3HeYZKXehm4HGUnE/qF 0IiKJ5XJFgQnjr9pIieVuPBNjKCX1FjOvjh5JGa3jxdVuOXe8i9g8Fuj6lckDqIV3582B7 G367RAx/BucA3QYEonugzDtJEQ18UQgtZmKC+oromzAY5vvJTxH41KY5MDIeezOozpd2RZ 7vtEa/GIYS+Xo2x7aJIWmG0p+8JnsMXctXj+tEssSD539mZHlbuiGJYcwASEAmUDbGufx5 P0ISXEul4S8Xs2sLsK1gE6xEhEw9xM2tY0cQzhJ68HPYW4DBiAlH2NAmAaXViw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118549; 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=ftiUiGcyP83PHIERnw6tNsYeB76Wd7gILboepUDAPpk=; b=e7O2heb2MvwN8K78h0lUK1lbRN2vn2vCnnw6Wmq11eI6ZfMY3TyYD8lYE+cG+uMeisFkle mbRDQXzQkMiVE1PL9ifYuSydr86hX/+cgYUZuc+AdFfSAkdvTWyURGwDOwy1mr+Ha8xVXX u1pDw/fYaYi3PZscLUCJcim6l/K6YdlY0/S40mYpkRKt4qyO0VUEs8g78rt5Fi9xSHIrLm eMhcRtWu1zoV9DkY1gppMGC+IRU7PaTJn6KlO9iF/uqPUFfpyhr0O4GwsAtQf0DDt3EQy2 V2O791I29ciB3oNVeTHtT5f7gfgki1fNRgltHsFI6CRXi9Cc2FkMd74U7qBhbg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118549; a=rsa-sha256; cv=none; b=fYSLxf/HP0s7r8V/Sf4igPh8WMTRJJNfurl0AwVHSFn8ZcKnZRvOvbJOeV0uQ7Ttqah/IW AGRM7Gfjooru8lUJIMezJcUw76EPMdpaxnpIZiwvn1S5LpXXz9KL5VRSBYke0SlbiWC9o3 2odo9Kv7H7v81Ucj59tupekPd7wOdKkyOShpkOgz0i9xPmWhpCZhtKhNxqyuf9ijFrghux geyyApYFVpuv/HrYUJj6MK1iVpIZSzv0qVosFDeD93rIHtJUlSnbS+Y9UnYd2xR8duzP+M WNHjXHvKTDljPERP0bkHrU1KWTfk8Jte3tL6g85/HKODdOlNtMMDoOpucVfD4A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRgm52tsZzTJ5; Wed, 17 Sep 2025 14:15:49 +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 58HEFnjS010464; Wed, 17 Sep 2025 14:15:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEFnUQ010461; Wed, 17 Sep 2025 14:15:49 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:15:49 GMT Message-Id: <202509171415.58HEFnUQ010461@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: e63534edbcd0 - main - pf: fix rules_counter:keepcounters test 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e63534edbcd050215bc109cd89a31ba30c5ea850 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=e63534edbcd050215bc109cd89a31ba30c5ea850 commit e63534edbcd050215bc109cd89a31ba30c5ea850 Author: Kristof Provost AuthorDate: 2025-09-17 08:12:11 +0000 Commit: Kristof Provost CommitDate: 2025-09-17 14:15:16 +0000 pf: fix rules_counter:keepcounters test The previous pf_krule_global leak fix was a bit too aggressive and cleaned up the inactive tree pointer before we needed it to preserve counters. Only clean up anchors that are entirely unused. Clean up pf_main_ruleset on pf shutdown. PR: 289299 MFC after: 1 week Fixes: 275ff85b25 ("pf: fix struct pf_krule_global leak") Sponsored by: Rubicon Communications, LLC ("Netgate") --- sys/netpfil/pf/pf_ioctl.c | 5 +++++ sys/netpfil/pf/pf_ruleset.c | 12 ++++++------ 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/sys/netpfil/pf/pf_ioctl.c b/sys/netpfil/pf/pf_ioctl.c index 5bfbb2c83f0e..bd506c092da2 100644 --- a/sys/netpfil/pf/pf_ioctl.c +++ b/sys/netpfil/pf/pf_ioctl.c @@ -6551,6 +6551,11 @@ shutdown_pf(void) pf_kill_srcnodes(NULL); + for (int i = 0; i < PF_RULESET_MAX; i++) { + pf_rule_tree_free(pf_main_ruleset.rules[i].active.tree); + pf_rule_tree_free(pf_main_ruleset.rules[i].inactive.tree); + } + /* status does not use malloced mem so no need to cleanup */ /* fingerprints and interfaces have their own cleanup code */ } while(0); diff --git a/sys/netpfil/pf/pf_ruleset.c b/sys/netpfil/pf/pf_ruleset.c index 1711e690f6bb..4e16eaa76f9d 100644 --- a/sys/netpfil/pf/pf_ruleset.c +++ b/sys/netpfil/pf/pf_ruleset.c @@ -336,12 +336,6 @@ pf_remove_if_empty_kruleset(struct pf_kruleset *ruleset) int i; while (ruleset != NULL) { - for (int i = 0; i < PF_RULESET_MAX; i++) { - pf_rule_tree_free(ruleset->rules[i].active.tree); - ruleset->rules[i].active.tree = NULL; - pf_rule_tree_free(ruleset->rules[i].inactive.tree); - ruleset->rules[i].inactive.tree = NULL; - } if (ruleset == &pf_main_ruleset || !RB_EMPTY(&ruleset->anchor->children) || ruleset->anchor->refcnt > 0 || ruleset->tables > 0 || @@ -352,6 +346,12 @@ pf_remove_if_empty_kruleset(struct pf_kruleset *ruleset) !TAILQ_EMPTY(ruleset->rules[i].inactive.ptr) || ruleset->rules[i].inactive.open) return; + for (int i = 0; i < PF_RULESET_MAX; i++) { + pf_rule_tree_free(ruleset->rules[i].active.tree); + ruleset->rules[i].active.tree = NULL; + pf_rule_tree_free(ruleset->rules[i].inactive.tree); + ruleset->rules[i].inactive.tree = NULL; + } RB_REMOVE(pf_kanchor_global, &V_pf_anchors, ruleset->anchor); if ((parent = ruleset->anchor->parent) != NULL) RB_REMOVE(pf_kanchor_node, &parent->children, From nobody Wed Sep 17 14:20:21 2025 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 4cRgsL1Pvxz67T8C; Wed, 17 Sep 2025 14:20:22 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRgsL0JTjz47Xv; Wed, 17 Sep 2025 14:20:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118822; 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=2qGuQCDBpZF/UD7xmpzTdtZKR/rfPlArgfAKVcRL20Y=; b=o4LcAHj/STiRiILKxOkbhQI5Nz/uE7867O5jNS4GVBTnDgULcdc+JHR1iYl3xCm72++MEu 1LVgrsoNIO4mQlWj6nC0cPtm1aCWyTeMaTN691ZNoIzLQrIgbr3urDZbRtb2yZzvEFgt/G g+UZnbnXwL5YJ9JFuABN7j4zemK+dJN0HcfiT8jkHHqKZ8MzUAcOYMfS9s406GKZY9zVVo 7FEHR6AEXUkdgZmUpFhHNsSsJRvGoVg+HHterDpuPSbWpL2QVnDUV2sOfGGZPT7dwTG4vo O2BoHCCoAqR32dt2XscCunbMgA1oPSROV6Zw2+EfBfWnY/1L4tfKTnzIdsFKng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758118822; 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=2qGuQCDBpZF/UD7xmpzTdtZKR/rfPlArgfAKVcRL20Y=; b=ZZuC+0C+v+uBp6T9f6zNRT+xZDfriZk05xL9Og6orDBg/7GszSFHSY5fLQZHUjqZFpSFIH BrH99OLdKNpflF93jkYykbVSQ8IOFCUS3aiaDONVp+uTEmqe+SVdos1xylZ9wk0hCJUu3a +mLWpfwjz0630iC38bat85Ef0AopLyGFseg+9vdVKjlIsT86pF8m8UAWgKjZokltaBD2Jt 3Wdu7xG9BHdasNMRX5Jm+N3YI06kF6e87ZIWjr7SYNvxKASznSoLp3MsDG1tTMFMD3Wq2o h3KHvu4/gbXTY4g6McOk58eDNWusLteR5GrHKSG4KS8HvUG+I+vw9BnE00kD/Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758118822; a=rsa-sha256; cv=none; b=eSiH5SQHeZ1rl00Eo7ZO3MjaHSkRgQK9Xl8DeOPKZESPlMpeH/xWV/KkqJ9YxpN+qtRu2v wjvaqU1lUCr7Cpf3CPA+BveyKmN/nyiZB1meG7LODE0M1y7NJKOz4TD2SWK/PYHH8sFdST lJy0jp7o635sPhgjjXwVA+GyMfbCBUqnSmV7309xrN8OfL9LGxL03xOYU1zVRMHwlOkgZ4 +rdwz3qjVXESBXWWx3n6oAe6xQOUFc7p3DvWHY+U/a4p6wIVFR8lVgKT2/QNoahV3saEEO xksqPAELATEEor44y+Hm33x0QkFDE5D3zT0kmE5mI9in/9Yb1Jeu5r1qzsD5bA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRgsK6VfWzDGc; Wed, 17 Sep 2025 14:20:21 +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 58HEKLc6020910; Wed, 17 Sep 2025 14:20:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HEKL19020907; Wed, 17 Sep 2025 14:20:21 GMT (envelope-from git) Date: Wed, 17 Sep 2025 14:20:21 GMT Message-Id: <202509171420.58HEKL19020907@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ahmad Khalifa Subject: git: 2b0f8c6907b9 - main - rk_tsadc: use tsadc_temp_to_raw for shutdown_temp 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: vexeduxr X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2b0f8c6907b96a8e150a1250e56d25a7a5d202d8 Auto-Submitted: auto-generated The branch main has been updated by vexeduxr: URL: https://cgit.FreeBSD.org/src/commit/?id=2b0f8c6907b96a8e150a1250e56d25a7a5d202d8 commit 2b0f8c6907b96a8e150a1250e56d25a7a5d202d8 Author: Evgenii Ivanov AuthorDate: 2025-09-17 14:07:26 +0000 Commit: Ahmad Khalifa CommitDate: 2025-09-17 14:16:36 +0000 rk_tsadc: use tsadc_temp_to_raw for shutdown_temp Use tsadc_temp_to_raw instead of tsadc_raw_to_temp, otherwise rk3566/68 get stuck in a kernel reboot cycle. https://forums.freebsd.org/threads/running-freebsd-on-radxa-rock-3c-rk3566-board.89389/post-624890 Submitted by: covacat Reviewed by: mmel MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D52309 --- sys/arm64/rockchip/rk_tsadc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/arm64/rockchip/rk_tsadc.c b/sys/arm64/rockchip/rk_tsadc.c index e6cbad36f697..d83b09480a0c 100644 --- a/sys/arm64/rockchip/rk_tsadc.c +++ b/sys/arm64/rockchip/rk_tsadc.c @@ -484,7 +484,7 @@ tsadc_init_tsensor(struct tsadc_softc *sc, struct tsensor *sensor) WR4(sc, TSADC_INT_EN, val); /* Shutdown temperature */ - val = tsadc_raw_to_temp(sc, sc->shutdown_temp); + val = tsadc_temp_to_raw(sc, sc->shutdown_temp); WR4(sc, TSADC_COMP_SHUT(sensor->channel), val); val = RD4(sc, TSADC_AUTO_CON); val |= TSADC_AUTO_SRC_EN(sensor->channel); From nobody Wed Sep 17 15:01:23 2025 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 4cRhmj67mkz67XJr; Wed, 17 Sep 2025 15:01:25 +0000 (UTC) (envelope-from des@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRhmj2vCwz3N3L; Wed, 17 Sep 2025 15:01:25 +0000 (UTC) (envelope-from des@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758121285; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=tKlnl4xlZmQ9st2GpLWsoIp3TfJ6apZDNCXZBgsctzk=; b=WoobLF7jxPoSFwedJzSR3EBXG4UlfXOefUSb2u2BSE3xevEhr31ulLZdXaeY3BvUEawB07 VnObDMYUbVcBWkARULFzXKuYUNT0XvXamCALlPjp6Va6ji92MLthGsBQaTLQ57xqcnPOK1 OCsoyqZxiEK/q5953SCRtqjd1lNKS0EDDKY69vMDwtN6KdY2on+e+NelGbnbOoTg5I22uh pqHOwGpCkXBQJBdFDs901SGznWuCL5gqgTEMXjuPz5hPLllieJnnbz1Hv83YTCL+O9JQ/3 4lZhSkuB6D4/KyZWHIySCAd5B7qARskXhx9o8gjKO2AoI5r+4yiKEG0/0THKMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758121285; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=tKlnl4xlZmQ9st2GpLWsoIp3TfJ6apZDNCXZBgsctzk=; b=sa9tARPInUkbaCXfH5i9NnP3NQwICTyvt2yfT0swFERHdjfbB5m9bx27VEaLHX5fqUpFxD YoqepllD+jT7Lh68DlYL1AiVoxHHlCEHTpOzrmDYSM/X4V/ox91OlzoV23mFE0kQp+5WHb Rmkqw66RRNZvPDswF7QbDh8T/bkcIFPk1L6hfWK5w5box7H1UQyFwryYvxQ1G29C6y0tVW hoRwJKNt2TnWoDrTJjAR45xuUmH80alavGBGdmb8/swp7zOO2wRBqd4/blLeH69uIghpia Ei3BgRMqk/Z3kUGgz8zXBCxa7w0OgfJQxNa3n3DMTGWGPXdIaFCdnU2xUI92NA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758121285; a=rsa-sha256; cv=none; b=Mlw5fQihC2Z5otOzHeyMievW1FRaOQ9osH6Sd3l/vQIONH88pLbAyS/AKXzZMm0UeglwSR k9nAbKbYaD+0H/FXQersTgFU4OTQ14OGGwIH3YCiHAbqcLojEAPA/X7Jw9x/hAR+T7I0LJ EJNI8ViT+w43yc277LfFamdSVsBKrYCJ5NNc4HKltcsVAdggg0pnhDpVadUPsbGZfoVgAM kQermVWd04ri/NM6jvzR03FnB1qlaZwD1w1ZnAmkSA0uTN8gZ1GPi6cHkrmAq6BNlecycs 1z07m3zGhkMgeJO3bI9ZC4bojQMs6ZlT904e/BpS90bMmqFpqUQTsD2H3/GSXQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from ltc.des.dev (88-177-82-251.subs.proxad.net [88.177.82.251]) (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) (Authenticated sender: des) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cRhmj1SgDz1C4n; Wed, 17 Sep 2025 15:01:25 +0000 (UTC) (envelope-from des@freebsd.org) Received: by ltc.des.dev (Postfix, from userid 1001) id 812D388583; Wed, 17 Sep 2025 17:01:23 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Mark Johnston Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: b2f5dc591ef2 - main - src.opts.mk: Remove REPRODUCIBLE_BUILD from the default list In-Reply-To: (Mark Johnston's message of "Tue, 16 Sep 2025 09:43:29 -0400") References: <202509081922.588JM1NX027953@gitrepo.freebsd.org> <86tt12fs58.fsf@ltc.des.dev> User-Agent: Gnus/5.13 (Gnus v5.13) Date: Wed, 17 Sep 2025 17:01:23 +0200 Message-ID: <86plbpf7i4.fsf@ltc.des.dev> 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: quoted-printable Mark Johnston writes: > Dag-Erling Sm=C3=B8rgrav writes: > > You forgot to regenerate src.conf.5. > I didn't change the default, just where it was defined. Regenerating > src.conf.5 results in no changes. Sorry, I didn't check main, but it does make a difference in stable/15: diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index d251bf0cd9e7..34be396b8e01 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -1,5 +1,5 @@ .\" DO NOT EDIT-- this file is @generated by tools/build/options/makeman. -.Dd September 16, 2025 +.Dd September 17, 2025 .Dt SRC.CONF 5 .Os .Sh NAME @@ -1548,10 +1548,10 @@ Do not apply the Relocation Read-Only (RELRO) vulne= rability mitigation. See also the .Va BIND_NOW option. -.It Va WITH_REPRODUCIBLE_BUILD -Exclude build metadata (such as the build time, user, or host) -from the kernel, boot loaders, and uname output, so that builds produce -bit-for-bit identical output. +.It Va WITHOUT_REPRODUCIBLE_BUILD +Include build metadata (such as the build time, user, and host) +in the kernel, boot loaders, and uname output. +Successive builds will not be bit-for-bit identical. .It Va WITHOUT_RESCUE Do not build .Xr rescue 8 . DES --=20 Dag-Erling Sm=C3=B8rgrav - des@FreeBSD.org From nobody Wed Sep 17 15:07:37 2025 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 4cRhvy6hY5z67Xpp for ; Wed, 17 Sep 2025 15:07:42 +0000 (UTC) (envelope-from markjdb@gmail.com) Received: from mail-qt1-x82e.google.com (mail-qt1-x82e.google.com [IPv6:2607:f8b0:4864:20::82e]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRhvy4rVMz3Nr1 for ; Wed, 17 Sep 2025 15:07:42 +0000 (UTC) (envelope-from markjdb@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-qt1-x82e.google.com with SMTP id d75a77b69052e-4b34a3a6f64so57927121cf.3 for ; Wed, 17 Sep 2025 08:07:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1758121661; x=1758726461; darn=freebsd.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:sender :from:to:cc:subject:date:message-id:reply-to; bh=0wn9/xxLTctLhq0OPwKnow9cDLyDaz+yiTCKrWGd62E=; b=OBu37fzZ6AtAAl3WMpRNUbPwwZwmHKMSTu3OA1ffnSTI805LXD642Y4/7gBGkvJ0N7 KTh912Jcszf/Wf/2bJ806JlP0YqFUxtKvoFgeYm442E2wFQ4FAbLRCeOpyVfw61OrQzr x0c1CNGsIE4O0IackgZ08vH6Oersvrv3qx8rutiFXKkfswTdFNxl97eywIehH/fblH/a 7ULEUo9LjlkYTzyHgobHO21nGH5NXsBHrev5JAQAndzAHLCkri/crV3q7EKugpALTDGY CwtvQIFjKnlyJKMKiHFxfJMBn6Z2U9aaExSZFUQlU/ExH/iP5pxGjedOqFrK+u75z5id ognQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1758121661; x=1758726461; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:sender :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=0wn9/xxLTctLhq0OPwKnow9cDLyDaz+yiTCKrWGd62E=; b=RLiARNaivy1+9U6ceJxX/UAiGBZ7qmCx/acaIcZNFHTKPCYgLTswQsGQrwDBAcA4Co ui6OB2j4zz2BHLyfyxUwxdPjXectC8lQRZFDNhrm8dDToxvIe8FcfIFbp3naIGN2bzyi gbtMUEgaYo1DSKHc6rTLFR6d2S6HwdSWAkq2WCcgFQycFrnrTaleBpfh3W3/jE8/3O24 M3ch8sXyWax8ubjqtpxuZkhM6uXVOdKe/YxZS4Kbp7H7Tkin0taofWmvGvdNLsEp8yau fgmfELvwRMLdEeezCI/Ekx2LgfvpYrbr1MxJpGI4lIdkBK0JwvuhIzlMP9iF24BvmBCk YTDg== X-Forwarded-Encrypted: i=1; AJvYcCV6R3F2ktls6aE54puJoB59qcIzwZA6s6MoiJiXWwayfEOXB3GEFz7N8gLWyjSDVUGvdZP6j++uVh1r6Qa02soidV6Z@freebsd.org X-Gm-Message-State: AOJu0YykgjWoxrpIm+XVCbg6Xpdx3/NYiGlGuZcRp8flOyCmYb/dOrzx O/RLPAoNS0mic7UAs5xhsSlqjPzlX3t7yKQDbVW9CaE5qn4y0yrMW8p1 X-Gm-Gg: ASbGncudSQZqmubva3ouWGYAYmjYVmZDsqxFEXOvYr86woRNRKK9wKQw9SBwzN3MA9S 0eyuba+UKoYakY4JBuNQv354kNKrkLMX8RRSeTF/0vev3QKJcUvql6X97RCJRVK9nDW5rsrzAOH E3juOsfysb64TBVKCIeSPnC+0p6i7gZzxdmKJhuHiDi7lAnaJ0W8rstZ87/oHTF22O8ANhAF11i 6nFWxlgjMgKdWvSJ4tlqnEl3pfBms8dL2nBwL3p9gbOHVaVkavC1+mVDsPjBOot42qySH9/H4Gh Tc2iEsIRauBA+qcV9G+EYs/2V0ukZbZdVnFg0+VyUnVsyQ23huInyT21seWGjLez9uGa32rOA/C VNW/Lj11fu4GaipKXJdQbeYLxAlaisyRpsI6K X-Google-Smtp-Source: AGHT+IFoAxZKPQ/GIWadh3IF6AJWsrFuig7Q4Or97Y77+ap97+nSKWDRGFnwR1Urcv+C+GowJ+GRUA== X-Received: by 2002:a05:622a:1393:b0:4b7:9b01:ba3f with SMTP id d75a77b69052e-4ba6a201c46mr28108631cf.45.1758121660371; Wed, 17 Sep 2025 08:07:40 -0700 (PDT) Received: from nuc (192-0-220-237.cpe.teksavvy.com. [192.0.220.237]) by smtp.gmail.com with ESMTPSA id d75a77b69052e-4b639dab2ecsm100783101cf.30.2025.09.17.08.07.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Sep 2025 08:07:39 -0700 (PDT) Date: Wed, 17 Sep 2025 11:07:37 -0400 From: Mark Johnston To: Dag-Erling =?iso-8859-1?Q?Sm=F8rgrav?= Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: b2f5dc591ef2 - main - src.opts.mk: Remove REPRODUCIBLE_BUILD from the default list Message-ID: References: <202509081922.588JM1NX027953@gitrepo.freebsd.org> <86tt12fs58.fsf@ltc.des.dev> <86plbpf7i4.fsf@ltc.des.dev> 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=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <86plbpf7i4.fsf@ltc.des.dev> X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4cRhvy4rVMz3Nr1 On Wed, Sep 17, 2025 at 05:01:23PM +0200, Dag-Erling Smrgrav wrote: > Mark Johnston writes: > > Dag-Erling Smrgrav writes: > > > You forgot to regenerate src.conf.5. > > I didn't change the default, just where it was defined. Regenerating > > src.conf.5 results in no changes. > > Sorry, I didn't check main, but it does make a difference in stable/15: This was addressed by Ed already in commit f9d8f808b23fb9f4ee257e0ed78ddc4fa6882967. From nobody Wed Sep 17 15:32:07 2025 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 4cRjS814Byz67bKT for ; Wed, 17 Sep 2025 15:32:08 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRjS80c6fz3TMq; Wed, 17 Sep 2025 15:32:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758123128; 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=4Zks5T2VEsHOrD0oiieEQK9fg5++wdk8WwncqLRBwqg=; b=wXgcF2NxexgNvdqMy10QlGOlhDmrdp68udERe6w0CqGDnEnnwg9ae4TLhSQYfbm4d3JcOl PUk6tTLIIBJnuUlJIZgzuCNTmiZFr4GmUtC1DFdsDow4re0c3FZkuBjY14Uh9SGPzIvX9r zL0Gg63x2hg1x7812DtAU40B6Z+gZ/8oWijI0jTzxVFysvhuYKmMnEziGy/8ZDTonhIGbn 3aIh8LRmybwtc5iAIuJ0xhKsrg1R9b1hfzpr8od4u1Td8dxh1DTaAPQjJ2Zx2SDoyD/YDt Vs8X+0rSo05O7RcYCrF4FQV4dR2I76jorvPCY0yhZLLs/kOdYOMtwbvt5+LqVA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758123128; 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=4Zks5T2VEsHOrD0oiieEQK9fg5++wdk8WwncqLRBwqg=; b=wyQEwLo4GtFMCL2TDrAqWMCthXG4aaP2b2PqdRYj5q7202Q3vPevpm4HmLLTGp3SZxGxX/ uKBTjBo6cU7DTUVknuxoceYWAZkyhSgYN82zDB7tKH+3+XjdEUBaj8YP6oynA16DRfx2rH JgiqDmCJInpRxnFL9LYQd6vOOiiyxKEgz9hLxfrco1i2VFehc6PAWIPMlU+UGCiTsb4l6l sAN4ftUToMtMwv0eGHVj/KWV6eQKqONKzTxM6+H2+qbirsEqvX0mjWMcclc+BqmYV/jBIV eAWg3VCK5q4oGGfeeR9YimjuLWJQz+u+xExezQlPqOd59/rOhudaHtt03DmKvQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758123128; a=rsa-sha256; cv=none; b=HmDmRT8HB1UIdv/nuwMxceAmzQYjYr23EZ38mN1JTfx726TGn4wzEghapg/5GGoMtSj2CZ V3oAcW2E8JOeuzhDdGt8aVGPON/++ppmnQAbqHbzqlm31IjWdpQJUdiZvdVgPgzFGMHDV1 pTxCu5Ic5hHmc1GQmsZXqHk6y0ZQFOuhrJHuGHFiaL1xmrijR9T596tpLwVBDTs62f2OdF 5tCEhmGUQGnIYg8xjK18+6ZiLmTiz//YfS1QW8zt5WB3ut+9he9YW/m0WscMFK/yL6ewdG 12FAgyBQMDKPqfZ66o4ZzOWeYTJlhqSjj6kXOjgRJBiE3sesUitXiWgopsIrXA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRjS80Bw3zXZs; Wed, 17 Sep 2025 15:32:08 +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 58HFW7NI057202; Wed, 17 Sep 2025 15:32:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HFW7EJ057199; Wed, 17 Sep 2025 15:32:07 GMT (envelope-from git) Date: Wed, 17 Sep 2025 15:32:07 GMT Message-Id: <202509171532.58HFW7EJ057199@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Joseph Mingrone Subject: git: fcae5e2ef7fd - internal/admin - Release obiwac from mentorship 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: jrm X-Git-Repository: src X-Git-Refname: refs/internal/admin X-Git-Reftype: branch X-Git-Commit: fcae5e2ef7fd04669633a077ad7a13c79aec2616 Auto-Submitted: auto-generated The branch internal/admin has been updated by jrm: URL: https://cgit.FreeBSD.org/src/commit/?id=fcae5e2ef7fd04669633a077ad7a13c79aec2616 commit fcae5e2ef7fd04669633a077ad7a13c79aec2616 Author: Joseph Mingrone AuthorDate: 2025-09-17 15:21:29 +0000 Commit: Joseph Mingrone CommitDate: 2025-09-17 15:27:26 +0000 Release obiwac from mentorship Approved by: srcmgr --- mentors | 1 - 1 file changed, 1 deletion(-) diff --git a/mentors b/mentors index 4998ff23ccda..1437f8631d5d 100644 --- a/mentors +++ b/mentors @@ -17,7 +17,6 @@ def oshogbo jlduran emaste kgalazka erj Co-mentor: kbowling khorben philip -obiwac mckusick Co-mentor: jrm oh manu osamaabb cperciva Co-mentor: akiyano ram ken Co-mentor: mav From nobody Wed Sep 17 15:39:30 2025 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 4cRjcg1h1jz67bVQ; Wed, 17 Sep 2025 15:39:31 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRjcg0kKZz3Wjj; Wed, 17 Sep 2025 15:39:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758123571; 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=kbN+J9NgQoalz5f/07AAf5G/hyMMGNhFBELoal4p7kE=; b=evdnap3a9o7ycm5TcqI3uzWvNiXcVH24o5xdsrufDstmQh9H1c3X1ayTJunHaDIIMi8hsf j1h43dJ3gU3EnY4tB4ewUM1sziUtWyCVPEhbb6dtS8LPISYueyvu5teaEuaaRRmuNL0H8S ZYwO7qjhMScxiIIAGJMTl5G+k/XyGeXtnVwVrXqcDGnyoi4jjEsPkGG7dpJGxsCu6j/vGO JYoi7YKbXnVHya7uG1qULHk7vFF/eyn+R2kCTKvk3WszzSQzYm5GOsiIUf4qIp7vPxcwip U95d+VZSCQMVpcbNPzzG5W2+bIwQEH4F9zSHdjkrqYzibb/osXQq+LLGQHe5rA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758123571; 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=kbN+J9NgQoalz5f/07AAf5G/hyMMGNhFBELoal4p7kE=; b=JgGq/I4kbL2ZBOnzgTN8fchanxONUgP6DynnldT9i82T+BIZWUzwUnAjUNtXihEmJr8d6n aT5mrewroDsWaF4cWre5LsLTFCGHHJOObkMJGwCLHHce7AFTINZsO8VyoEq2baFgvwqgde zu39FXH5orEs1xwqsOOHZNOVbJ3JMkld6kP4pyTyvbUKZ27IaPswsv3itziUoZeXFKSDoT UfhMCY4zD2nGBWHmX/UDPvWh+8Ww8IToEbTuPoY8tgQGxcJjtF7Vn40XWB7tb1pera+bVI qx14gT1LpuDgFwJLfxzL5d9tl0fyqAvmzUP9//3rTJ9SI/eVho4ew7ZoqYKtiA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758123571; a=rsa-sha256; cv=none; b=Tmqot6UJCba9dc6T1CT3OwMV5quTrVdPWr0zBKGgQg7sU2LKqgUMplrF7bIoNqnjCnsWgH rXPGzWWqOAvTJ5BmoR4Tw4KOImH+K+/LzwFbR0cg/jnkp9IpgqNEomKbqwx6y/qSuJBuFL 3KDnBxFBewObESLrKPcZc6TMUA/iUsj2pSpCB3YTXJeYQN0KnQGzBFVM9D4RmWjoBlQluV EQJZ2/yVFQU3ZUnbjL+jKa5NFgrY1RRY+f0vhBBfJFWexzwF4Cx/0j5y2S4OsYHi+WyBWh IcOtXt8A4VtSNtyMCbc7HfpSJZWyq5d32VZWfdRDqunnDSjxj/7+cJmuE4F+KA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRjcg039bzXZy; Wed, 17 Sep 2025 15:39:31 +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 58HFdUd5062076; Wed, 17 Sep 2025 15:39:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HFdUA9062073; Wed, 17 Sep 2025 15:39:30 GMT (envelope-from git) Date: Wed, 17 Sep 2025 15:39:30 GMT Message-Id: <202509171539.58HFdUA9062073@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alexander Ziaee Subject: git: 3049b2f5115b - main - vnet.9: Rename vnet.9/vimage.9 to VNET.9/VIMAGE.9 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: ziaee X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 3049b2f5115b3b4aed202274e866f360fa2560d1 Auto-Submitted: auto-generated The branch main has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=3049b2f5115b3b4aed202274e866f360fa2560d1 commit 3049b2f5115b3b4aed202274e866f360fa2560d1 Author: Quentin Thébault AuthorDate: 2025-09-16 02:38:18 +0000 Commit: Alexander Ziaee CommitDate: 2025-09-17 15:31:37 +0000 vnet.9: Rename vnet.9/vimage.9 to VNET.9/VIMAGE.9 Fix crossreferences to VNET(9) by correcting it's capitalization. MFC after: 3 days Reviewed by: enji, ziaee Closes: https://github.com/freebsd/freebsd-src/pull/1848 --- contrib/kyua/doc/kyuafile.5.in | 2 +- share/man/man9/Makefile | 4 ++-- share/man/man9/{vnet.9 => VNET.9} | 0 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/contrib/kyua/doc/kyuafile.5.in b/contrib/kyua/doc/kyuafile.5.in index 43f00816d407..a9106e95d790 100644 --- a/contrib/kyua/doc/kyuafile.5.in +++ b/contrib/kyua/doc/kyuafile.5.in @@ -485,7 +485,7 @@ plain_test_program{name='the_test', .Ss FreeBSD jail execution environment The following example configures the test to be run within a temporary jail with -.Xr vnet 9 +.Xr VNET 9 support and the permission to create raw sockets: .Bd -literal -offset indent syntax(2) diff --git a/share/man/man9/Makefile b/share/man/man9/Makefile index 30f41073bcbf..fe764e7c4ed7 100644 --- a/share/man/man9/Makefile +++ b/share/man/man9/Makefile @@ -417,7 +417,7 @@ MAN= accept_filter.9 \ vn_deallocate.9 \ vn_fullpath.9 \ vn_isdisk.9 \ - vnet.9 \ + VNET.9 \ vnode.9 \ vnode_pager_setsize.9 \ vnode_pager_purge_range.9 \ @@ -2474,7 +2474,7 @@ MLINKS+=VOP_OPENCLOSE.9 VOP_CLOSE.9 \ MLINKS+=VOP_RDWR.9 VOP_READ.9 \ VOP_RDWR.9 VOP_WRITE.9 MLINKS+=VOP_REMOVE.9 VOP_RMDIR.9 -MLINKS+=vnet.9 vimage.9 +MLINKS+=VNET.9 VIMAGE.9 MLINKS+=vref.9 VREF.9 \ vref.9 vrefl.9 MLINKS+=vrele.9 vput.9 \ diff --git a/share/man/man9/vnet.9 b/share/man/man9/VNET.9 similarity index 100% rename from share/man/man9/vnet.9 rename to share/man/man9/VNET.9 From nobody Wed Sep 17 15:58:31 2025 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 4cRk2c0Y80z67cbG; Wed, 17 Sep 2025 15:58:32 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRk2b6yYmz3bXt; Wed, 17 Sep 2025 15:58:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758124712; 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=LGdUwJ8Wo2yxeyTkB0gi59rS+CRLYnr6qJUX2+qCoPk=; b=jeOXP4PZ/KoMSnQZdcIvvQ7tM5tgi1UFVyqJrN1BsXf92sYKFMLnifBttXJu9epVP2Jf56 Ch6lZYXanWYMUDdJz4Sc+Peq62T07E/z/oWM47G8YHf2NW1oUrzKOlooNjvWgULV7LVNFu CNp7F2Mghsrl62A37zKEG529FOF3rCh3u1GWZVnsYkDZgjwyKU6GZABI0Y9JFhRVyiSQ7g 6I1eyk0vpATH8o/jhdKPq/SVHhbNQW31r6536eTToCDaa7rojgiK4R4ozSA3Gmz9115FPg zEYbsYtZlI5qdwAfuguYfGNknnS2c9fqgjqyK5mgtQkc70r9kXbi8/Pd1SbGKg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758124712; 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=LGdUwJ8Wo2yxeyTkB0gi59rS+CRLYnr6qJUX2+qCoPk=; b=m25gPDIV+t5+kYLpGp7YpBXeO5jUnIZc0RDmtN1wlnqZGQGCP5EKVYCTlN+WBfsNtdzXjJ /VbZV6lidST+XJc4AWMzbwLcgrwT+fv+FUqNpAuoN9HXB2oazrl6aWtuebqMwF0eWwjBTn x+S3V2xlAoX6O23vD0tCCyat1zt1i0Nu7/+T3qMTCqBDoot9HpamNnM0LyzutXjFj7Ff/H xoDw3nA74Bn7LSTZpmCXF/Q3NABQc4rRdQItkvvI6sJhFOaFP9H3tHbee4F8bA3aLByq95 CL/T3cgrwXO1voDPoBD4MmaMg79xLQ0UopTFpqa2/ej5vbYV2yBSJZ49yLD91A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758124712; a=rsa-sha256; cv=none; b=I4xuUVVhhEHAQ/fNgi+lB1uzlMt06mSRmTv7xR6MIKVhaFgwIKx3nptrT8FKxRi0J5CKLi 4ScR1TlbbFAxwmlxZNmMySVA6ydtVPwWKDCbiZjAnWywSMl+ymebkUHH0tviAovhxERDUT O5sTRcJDgK0YQZlkJbhZB2+9RlgVnD8zouRg7JbrCX63KRFadDhsSrF6Yi+TEuVwrsiTSA RJYhhChmN7RLUgPwnuX6nbY0gQ6s1YqqkF46lYdbkh4tQSXyzMpQV6BrJpSSN6+DS0AhbR mY9lTdcOxO4mtdxXPeJlH9K2N9fTcV/sR4W72FZtLddxqdBzrSDKB+8LGlPcyw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRk2b65MmzYmk; Wed, 17 Sep 2025 15:58:31 +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 58HFwVXg098832; Wed, 17 Sep 2025 15:58:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HFwV8R098829; Wed, 17 Sep 2025 15:58:31 GMT (envelope-from git) Date: Wed, 17 Sep 2025 15:58:31 GMT Message-Id: <202509171558.58HFwV8R098829@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alexander Ziaee Subject: git: 08d41d8803d9 - main - ObsoleteFiles: Remove the miscapitalized vnet.9 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: ziaee X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 08d41d8803d9dd49b709518e8f2ce292b59e9828 Auto-Submitted: auto-generated The branch main has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=08d41d8803d9dd49b709518e8f2ce292b59e9828 commit 08d41d8803d9dd49b709518e8f2ce292b59e9828 Author: Alexander Ziaee AuthorDate: 2025-09-17 15:54:13 +0000 Commit: Alexander Ziaee CommitDate: 2025-09-17 15:54:13 +0000 ObsoleteFiles: Remove the miscapitalized vnet.9 MFC after: 3 days Fixes: 3049b2f5115b (vnet.9: Rename vnet.9/vimage.9) --- ObsoleteFiles.inc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index ae83035b5de5..76e2027d9af2 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -51,6 +51,9 @@ # xargs -n1 | sort | uniq -d; # done +# 20250917: Remove a miscapitalized manual +OLD_FILES+=usr/share/man/man9/vnet.9.gz + # 20250911: This tool is no longer needed OLD_FILES+=usr/tests/bin/cp/sparse From nobody Wed Sep 17 16:50:20 2025 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 4cRlBN2rp0z67j6b; Wed, 17 Sep 2025 16:50:20 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRlBN2FDSz3h0H; Wed, 17 Sep 2025 16:50:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758127820; 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=fVIUpQmdxIMWrOQfeR9t9ppMCeKHWtUlTrg1OF5KJwA=; b=oBJt9zOJmlfnSODfZA0nGNoHmNCBboQ8nO8cwrQRpOLo8rzLX+VuCMm38wq69yDBaTHWXm O/Z4OkX83lqmEUoK6KDatmCAdzhRXPE+u8FEs8MgoWxs8Ao9mOIT28JH2UbL3aIL6gIbcN 2Nx42T0IEZBqXWLe60wOLgoy6RAz7u9ihdIWk+KRKnevns2aswz4xSP2oFVN2lOn2uPWBT Z+v1d791/0Mpl8HdSVy5RaSArl/WRJpA6HyxGnyR7/gH31344K4TL1i5vPH4noQ7OK0hQY Fiyf6yt3GSulqnvR9UYwbmYCVFAAKlpApt6pRigvDVulURSsoWjbjVpb6PSoUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758127820; 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=fVIUpQmdxIMWrOQfeR9t9ppMCeKHWtUlTrg1OF5KJwA=; b=eJI3YMqQ+LI2+/QobqYAyyQ52LixXIuLmjPaJ4yToh9O96HrGudl8BFJbYnuBIlGRcjdvg pEGDu+Wl/gNg2wM9fVDCGbX3ne5ddzQ2ybn2VN8OS9JlJa7qcmmUVXZKQuK2ZxaXd4KbrB awXwMCMpG7vB2h5RfHuOKkqdMquYZOUEEqHlgp+DmPBlbNTWHIaAhmtxVQuTTKKazxLF7A S/KrfGnxgxr2L6xzqu75qdeDFVydIQ/mHvACI4Cw/97kc3tyDN1lKH905ouM56iDvG6JaH WsWs32VCHPxft1hDDZSZkBiMfEn1TlNgvb/VkGRUfpJQ7A7D14wQes3pJeoImA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758127820; a=rsa-sha256; cv=none; b=Nz/IgRuO8bUPLvq5pbUPYRzbSfxnSGz2jYfmFK8lnY2L1GAprfsnQ24Jy0u3OwNyA3Bcd8 L10TiE3D16rjxv+ztPrSMEncjxq2oZsyoKPDQY0C9he8sFub1n6Wj/Gcoy5CCk6Ys8SSOi S8KMwyCU8pPXkMohezuBMTT6eCS3Vy30bhpMscvAbrcrq4C4KoG5q5Bhj2WdhfiF36hQY6 M3iWaIEedHfRnMGkzOr3FdLQJ4HtzDKjfpA+wohFUl3ol0NxNFLKnlhP9cNu2xkx02wLMs Z6SxZWhe5CQWA3ItM3pC/jJSAcLYff3g+uTZ2nVbPkrK7j1loBIOVNlD/aGgAg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRlBN1ddbzbGq; Wed, 17 Sep 2025 16:50:20 +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 58HGoKWB003068; Wed, 17 Sep 2025 16:50:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HGoKrr003065; Wed, 17 Sep 2025 16:50:20 GMT (envelope-from git) Date: Wed, 17 Sep 2025 16:50:20 GMT Message-Id: <202509171650.58HGoKrr003065@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Zhenlei Huang Subject: git: 2d85bc89294b - main - witness: Record the first acquired file and line for recursable locks 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2d85bc89294baa04daf509e81ec3880bff79cc10 Auto-Submitted: auto-generated The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=2d85bc89294baa04daf509e81ec3880bff79cc10 commit 2d85bc89294baa04daf509e81ec3880bff79cc10 Author: Zhenlei Huang AuthorDate: 2025-09-17 16:48:54 +0000 Commit: Zhenlei Huang CommitDate: 2025-09-17 16:48:54 +0000 witness: Record the first acquired file and line for recursable locks and the last acquired file and line to witness object. For recursable locks, unfortunately current implementation records only the recurse count and the last acquired file and line, but does not restore the previous acquired file and line on unlock. Hence it is possible to report false acquired file and line, and that may mislead developers and make the report by users a little harder to analyse. Since subsequent recurse locks do not affect how witness order check, record the first acquired file and line so that the logic is much clear. Reported by: bz Reviewed by: kib (previous version), markj See also: https://lists.freebsd.org/archives/freebsd-current/2025-June/007944.html MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D52496 --- sys/kern/subr_witness.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/sys/kern/subr_witness.c b/sys/kern/subr_witness.c index a65c3ca128d9..c937f6a82757 100644 --- a/sys/kern/subr_witness.c +++ b/sys/kern/subr_witness.c @@ -1515,6 +1515,10 @@ witness_lock(struct lock_object *lock, int flags, const char *file, int line) else lock_list = PCPU_PTR(spinlocks); + /* Update per-witness last file and line acquire. */ + w->w_file = file; + w->w_line = line; + /* Check to see if we are recursing on a lock we already own. */ instance = find_instance(*lock_list, lock); if (instance != NULL) { @@ -1522,15 +1526,9 @@ witness_lock(struct lock_object *lock, int flags, const char *file, int line) CTR4(KTR_WITNESS, "%s: pid %d recursed on %s r=%d", __func__, td->td_proc->p_pid, lock->lo_name, instance->li_flags & LI_RECURSEMASK); - instance->li_file = file; - instance->li_line = line; return; } - /* Update per-witness last file and line acquire. */ - w->w_file = file; - w->w_line = line; - /* Find the next open lock instance in the list and fill it. */ lle = *lock_list; if (lle == NULL || lle->ll_count == LOCK_NCHILDREN) { From nobody Wed Sep 17 17:01:02 2025 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 4cRlQl0lJYz67jq9; Wed, 17 Sep 2025 17:01:03 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRlQl0Vrkz3l2H; Wed, 17 Sep 2025 17:01:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758128463; 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=fqhvkA3tc5Yo8zGIHdBECvL7Tejcd1NtMf4MOobnu8k=; b=g/NL+z2/SLaPYaCqBjVv9JMW3kLqv8AOg6QveuDjaIIRwBEjbtxDFA7aYQ/vol4ajvNQgx fndruc3IkG7Fpjphr1wJZUjSqXliq3YVOnJe5PyzakLIS9JDR6eBNv69NYZL9LNYU/WCYz gsSkF/zE2CtV4+jBWHlm1F1P/ctvYVZiKPARjszPMJc/SwfQhOyYmhYfzZLstQg/uBypq/ EtKaNau/+0HyXb4BUblwkUv9YzskbyBGXjQcJxaMQyzzIjc3PZT/AXvNFN+IOdOJvWx1Lx jsJ1FD7Sk0kRpJY9JFCQuLZC6Gbu8zZPshEzcAO9CESy3RSzUyy9kndGdzfMFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758128463; 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=fqhvkA3tc5Yo8zGIHdBECvL7Tejcd1NtMf4MOobnu8k=; b=Pn3BeJYHPUinGKEpGYaMH7FoVXDnDNAA8T/iT7HVKdM4jzLRp0Or4gEgku22MgyDl/4ktJ TtFAPldFNJL8RPlr3leftWzwT1A2xglCPl2k2Jjtv3Vq4J2DkWXWwA4jmi4ohIaygVdZab AlANU+224aO0pw3CAr3W7R4x2KUrMER4CvlvpwfBXaEm31eOilDKytccXj0tG1KVvc0KYs KVKzrbapLrJnIo7Wc0UoLZT/lPLP5X3IT0LDBX1dGHOymHG0HZmJSBu9umUVRG5RS999qY miTaJNLLbCEXkuUSyUYQBSbkRXmGBKSFAbBp9PjWLcU1sXsgZzr4G5xMpWmxJg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758128463; a=rsa-sha256; cv=none; b=LQzijtcnRAQi/PGlMzaTRUuOfA1z09ZCuOjDMEaC0S5SvWUr4LUQHLk41s6HBNGs9eh0Jk O5Uh+pR5mv6jtsYI1owP8ZoJxSb24slkcsf7i9Ye225i9lDVWs4zgRR54uwKz/FoPErqyJ swrmyKntN7a0zdJyTd/YZ0FiItbzcoMKMOfrnnfkGSITz7KQ0fdeO2R878oRuU8c3j3zvj 8t7yr+deiLzfQ6C0vuh6Ma6e5DPbtU4zVAt4Q3uGUkZh94m8cPRECwA3Izs0K0VAyYwsfP AuEduhbZHh9K8oTE1pC1s8pSTOSv+LbMjX362fbvPw36wpVqOAJFl64M7NdZsQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRlQl05cHzb3X; Wed, 17 Sep 2025 17:01:03 +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 58HH12CM022704; Wed, 17 Sep 2025 17:01:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HH12GL022701; Wed, 17 Sep 2025 17:01:02 GMT (envelope-from git) Date: Wed, 17 Sep 2025 17:01:02 GMT Message-Id: <202509171701.58HH12GL022701@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Stefan =?utf-8?Q?E=C3=9Fer?= Subject: git: 4c178fe36e01 - stable/15 - contrib/bc upgrade to version 7.1.0 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: se X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 4c178fe36e01f84f3c65f6953cbe8dbe5b3fc908 Auto-Submitted: auto-generated The branch stable/15 has been updated by se: URL: https://cgit.FreeBSD.org/src/commit/?id=4c178fe36e01f84f3c65f6953cbe8dbe5b3fc908 commit 4c178fe36e01f84f3c65f6953cbe8dbe5b3fc908 Author: Stefan Eßer AuthorDate: 2025-09-11 14:16:39 +0000 Commit: Stefan Eßer CommitDate: 2025-09-17 16:25:56 +0000 contrib/bc upgrade to version 7.1.0 This update fixes a few bugs: - Improper response to double SIGINT with editline. - Not letting libedit handle terminal size changes. - A dc crash from improperly handling an error. - A duplicate check for reference arrays. - Build failures with GCC 15. Merge commit '682da5a0fdb2c38ecc3951047a882471d62aa1d1' (cherry picked from commit fdc4a7c8012b214986cfa2e2fb6d99731f004b1b) usr.bin/gh-bc: fix invocation of test scripts The “all.sh” script in version 7.1.0 accepts one less parameter for selecting the tests to be run. (cherry picked from commit 1a6ffcb27ddcfdc66c2ea58d6789b3d527f68ba9) usr.bin/gh-bc: update for version 7.1.0 Add extra defines required for bc-7.1.0 to the Makefiles. (cherry picked from commit 2d06844521ecd9e1298b53f13c18ffbfa97b1e28) --- contrib/bc/LICENSE.md | 4 +- contrib/bc/MAINTENANCE-TERMS.md | 80 + contrib/bc/Makefile.in | 285 +- contrib/bc/NEWS.md | 23 + contrib/bc/NOTICE.md | 2 +- contrib/bc/README.md | 21 +- contrib/bc/VERSION.txt | 1 + contrib/bc/build.gaml | 402 + contrib/bc/build.pkg.rig | 2345 ++++++ contrib/bc/build.rig | 575 ++ contrib/bc/compile_flags.txt | 3 + contrib/bc/configure.sh | 477 +- contrib/bc/gen/bc_help.txt | 4 +- contrib/bc/gen/dc_help.txt | 4 +- contrib/bc/gen/lib.bc | 2 +- contrib/bc/gen/lib2.bc | 115 +- contrib/bc/gen/strgen.c | 4 +- contrib/bc/gen/strgen.sh | 4 +- contrib/bc/include/args.h | 2 +- contrib/bc/include/bc.h | 8 +- contrib/bc/include/bcl.h | 2 +- contrib/bc/include/dc.h | 2 +- contrib/bc/include/file.h | 2 +- contrib/bc/include/history.h | 26 +- contrib/bc/include/lang.h | 6 +- contrib/bc/include/lex.h | 2 +- contrib/bc/include/library.h | 2 +- contrib/bc/include/num.h | 2 +- contrib/bc/include/opt.h | 2 +- contrib/bc/include/ossfuzz.h | 2 +- contrib/bc/include/parse.h | 2 +- contrib/bc/include/program.h | 16 +- contrib/bc/include/rand.h | 2 +- contrib/bc/include/read.h | 2 +- contrib/bc/include/status.h | 7 +- contrib/bc/include/vector.h | 2 +- contrib/bc/include/version.h | 42 - contrib/bc/include/vm.h | 3 +- contrib/bc/locales/de_DE.ISO8859-1.msg | 2 +- contrib/bc/locales/de_DE.UTF-8.msg | 2 +- contrib/bc/locales/en_US.msg | 2 +- contrib/bc/locales/es_ES.ISO8859-1.msg | 2 +- contrib/bc/locales/es_ES.UTF-8.msg | 2 +- contrib/bc/locales/fr_FR.ISO8859-1.msg | 2 +- contrib/bc/locales/fr_FR.UTF-8.msg | 2 +- contrib/bc/locales/ja_JP.UTF-8.msg | 2 +- contrib/bc/locales/ja_JP.eucJP.msg | 2 +- contrib/bc/locales/nl_NL.ISO8859-1.msg | 2 +- contrib/bc/locales/nl_NL.UTF-8.msg | 2 +- contrib/bc/locales/pl_PL.ISO8859-2.msg | 2 +- contrib/bc/locales/pl_PL.UTF-8.msg | 2 +- contrib/bc/locales/pt_PT.ISO8859-1.msg | 2 +- contrib/bc/locales/pt_PT.UTF-8.msg | 2 +- contrib/bc/locales/ru_RU.CP1251.msg | 2 +- contrib/bc/locales/ru_RU.CP866.msg | 2 +- contrib/bc/locales/ru_RU.ISO8859-5.msg | 2 +- contrib/bc/locales/ru_RU.KOI8-R.msg | 2 +- contrib/bc/locales/ru_RU.UTF-8.msg | 2 +- contrib/bc/locales/zh_CN.GB18030.msg | 2 +- contrib/bc/locales/zh_CN.GB2312.msg | 2 +- contrib/bc/locales/zh_CN.GBK.msg | 2 +- contrib/bc/locales/zh_CN.UTF-8.msg | 2 +- contrib/bc/locales/zh_CN.eucCN.msg | 2 +- contrib/bc/manuals/bc/A.1 | 15 +- contrib/bc/manuals/bc/A.1.md | 14 +- contrib/bc/manuals/bc/E.1 | 4 +- contrib/bc/manuals/bc/E.1.md | 4 +- contrib/bc/manuals/bc/EH.1 | 4 +- contrib/bc/manuals/bc/EH.1.md | 4 +- contrib/bc/manuals/bc/EHN.1 | 4 +- contrib/bc/manuals/bc/EHN.1.md | 4 +- contrib/bc/manuals/bc/EN.1 | 4 +- contrib/bc/manuals/bc/EN.1.md | 4 +- contrib/bc/manuals/bc/H.1 | 15 +- contrib/bc/manuals/bc/H.1.md | 14 +- contrib/bc/manuals/bc/HN.1 | 15 +- contrib/bc/manuals/bc/HN.1.md | 14 +- contrib/bc/manuals/bc/N.1 | 15 +- contrib/bc/manuals/bc/N.1.md | 14 +- contrib/bc/manuals/bcl.3 | 4 +- contrib/bc/manuals/bcl.3.md | 4 +- contrib/bc/manuals/build.md | 6 +- contrib/bc/manuals/dc/A.1 | 4 +- contrib/bc/manuals/dc/A.1.md | 4 +- contrib/bc/manuals/dc/E.1 | 4 +- contrib/bc/manuals/dc/E.1.md | 4 +- contrib/bc/manuals/dc/EH.1 | 4 +- contrib/bc/manuals/dc/EH.1.md | 4 +- contrib/bc/manuals/dc/EHN.1 | 4 +- contrib/bc/manuals/dc/EHN.1.md | 4 +- contrib/bc/manuals/dc/EN.1 | 4 +- contrib/bc/manuals/dc/EN.1.md | 4 +- contrib/bc/manuals/dc/H.1 | 4 +- contrib/bc/manuals/dc/H.1.md | 4 +- contrib/bc/manuals/dc/HN.1 | 4 +- contrib/bc/manuals/dc/HN.1.md | 4 +- contrib/bc/manuals/dc/N.1 | 4 +- contrib/bc/manuals/dc/N.1.md | 4 +- contrib/bc/project/README.md | 32 + contrib/bc/project/gitea.db | Bin 0 -> 86016 bytes contrib/bc/project/github_issues.json | 3667 ++++++++++ contrib/bc/project/github_prs.json | 7729 ++++++++++++++++++++ contrib/bc/project/issue10.md | 104 + contrib/bc/scripts/exec-install.sh | 2 +- contrib/bc/scripts/format.sh | 2 +- contrib/bc/scripts/functions.sh | 2 +- contrib/bc/scripts/karatsuba.py | 2 +- contrib/bc/scripts/link.sh | 2 +- contrib/bc/scripts/lint.sh | 2 +- contrib/bc/scripts/locale_install.sh | 2 +- contrib/bc/scripts/locale_uninstall.sh | 2 +- contrib/bc/scripts/os.c | 2 +- contrib/bc/scripts/release.pkg.yao | 1410 ++++ contrib/bc/scripts/sqrt_frac_guess.bc | 2 +- contrib/bc/scripts/sqrt_int_guess.bc | 2 +- contrib/bc/scripts/sqrt_random.bc | 2 +- contrib/bc/scripts/sqrt_random.sh | 2 +- contrib/bc/src/args.c | 2 +- contrib/bc/src/bc.c | 2 +- contrib/bc/src/bc_fuzzer.c | 3 +- contrib/bc/src/bc_lex.c | 2 +- contrib/bc/src/bc_parse.c | 2 +- contrib/bc/src/data.c | 142 +- contrib/bc/src/dc.c | 2 +- contrib/bc/src/dc_fuzzer.c | 3 +- contrib/bc/src/dc_lex.c | 2 +- contrib/bc/src/dc_parse.c | 2 +- contrib/bc/src/file.c | 5 +- contrib/bc/src/history.c | 16 +- contrib/bc/src/lang.c | 7 +- contrib/bc/src/lex.c | 2 +- contrib/bc/src/library.c | 2 +- contrib/bc/src/main.c | 3 +- contrib/bc/src/num.c | 3 +- contrib/bc/src/opt.c | 2 +- contrib/bc/src/parse.c | 2 +- contrib/bc/src/program.c | 67 +- contrib/bc/src/rand.c | 2 +- contrib/bc/src/read.c | 23 +- contrib/bc/src/vector.c | 2 +- contrib/bc/src/vm.c | 35 +- contrib/bc/tests/all.sh | 42 +- contrib/bc/tests/bc/all.txt | 131 +- contrib/bc/tests/bc/errors/39.txt | 1 + contrib/bc/tests/bc/lib2.txt | 477 -- contrib/bc/tests/bc/lib2_a2.txt | 18 + contrib/bc/tests/bc/lib2_a2_results.txt | 18 + contrib/bc/tests/bc/lib2_bytes.txt | 46 + contrib/bc/tests/bc/lib2_bytes_results.txt | 46 + contrib/bc/tests/bc/lib2_ceil.txt | 24 + contrib/bc/tests/bc/lib2_ceil_results.txt | 24 + contrib/bc/tests/bc/lib2_d2r.txt | 16 + contrib/bc/tests/bc/lib2_d2r_results.txt | 16 + contrib/bc/tests/bc/lib2_fac.txt | 6 + contrib/bc/tests/bc/lib2_fac_results.txt | 6 + contrib/bc/tests/bc/lib2_gcd.txt | 7 + contrib/bc/tests/bc/lib2_gcd_results.txt | 7 + contrib/bc/tests/bc/lib2_log.txt | 32 + contrib/bc/tests/bc/lib2_log_results.txt | 32 + contrib/bc/tests/bc/lib2_p.txt | 4 + contrib/bc/tests/bc/lib2_p_results.txt | 5 + contrib/bc/tests/bc/lib2_perm.txt | 9 + contrib/bc/tests/bc/lib2_perm_results.txt | 8 + contrib/bc/tests/bc/lib2_pi.txt | 5 + contrib/bc/tests/bc/lib2_pi_results.txt | 6 + contrib/bc/tests/bc/lib2_r.txt | 23 + contrib/bc/tests/bc/lib2_r2d.txt | 17 + contrib/bc/tests/bc/lib2_r2d_results.txt | 16 + contrib/bc/tests/bc/lib2_r_results.txt | 23 + contrib/bc/tests/bc/lib2_rand.txt | 11 + contrib/bc/tests/bc/lib2_rand_results.txt | 7 + contrib/bc/tests/bc/lib2_root.txt | 13 + contrib/bc/tests/bc/lib2_root_results.txt | 13 + contrib/bc/tests/bc/lib2_tan.txt | 30 + contrib/bc/tests/bc/lib2_tan_results.txt | 29 + contrib/bc/tests/bc/lib2_uint.txt | 218 + .../bc/{lib2_results.txt => lib2_uint_results.txt} | 256 - .../bc/tests/bc/scripts/{add.bc => add_00100.bc} | 2 +- contrib/bc/tests/bc/scripts/add_00200.bc | 17 + contrib/bc/tests/bc/scripts/add_00300.bc | 17 + contrib/bc/tests/bc/scripts/add_00400.bc | 17 + contrib/bc/tests/bc/scripts/add_00500.bc | 17 + contrib/bc/tests/bc/scripts/add_00600.bc | 17 + contrib/bc/tests/bc/scripts/add_00700.bc | 17 + contrib/bc/tests/bc/scripts/add_00800.bc | 17 + contrib/bc/tests/bc/scripts/add_00900.bc | 17 + contrib/bc/tests/bc/scripts/add_01000.bc | 17 + contrib/bc/tests/bc/scripts/add_01100.bc | 17 + contrib/bc/tests/bc/scripts/add_01200.bc | 17 + contrib/bc/tests/bc/scripts/add_01300.bc | 17 + contrib/bc/tests/bc/scripts/add_01400.bc | 17 + contrib/bc/tests/bc/scripts/add_01500.bc | 17 + contrib/bc/tests/bc/scripts/add_01600.bc | 17 + contrib/bc/tests/bc/scripts/add_01700.bc | 17 + contrib/bc/tests/bc/scripts/add_01800.bc | 17 + contrib/bc/tests/bc/scripts/add_01900.bc | 17 + contrib/bc/tests/bc/scripts/add_02000.bc | 17 + contrib/bc/tests/bc/scripts/add_02100.bc | 17 + contrib/bc/tests/bc/scripts/add_02200.bc | 17 + contrib/bc/tests/bc/scripts/add_02300.bc | 17 + contrib/bc/tests/bc/scripts/add_02400.bc | 17 + contrib/bc/tests/bc/scripts/add_02500.bc | 17 + contrib/bc/tests/bc/scripts/add_02600.bc | 17 + contrib/bc/tests/bc/scripts/add_02700.bc | 17 + contrib/bc/tests/bc/scripts/add_02800.bc | 17 + contrib/bc/tests/bc/scripts/add_02900.bc | 17 + contrib/bc/tests/bc/scripts/add_03000.bc | 17 + contrib/bc/tests/bc/scripts/add_03100.bc | 17 + contrib/bc/tests/bc/scripts/add_03200.bc | 17 + contrib/bc/tests/bc/scripts/add_03300.bc | 17 + contrib/bc/tests/bc/scripts/add_03400.bc | 17 + contrib/bc/tests/bc/scripts/add_03500.bc | 17 + contrib/bc/tests/bc/scripts/add_03600.bc | 17 + contrib/bc/tests/bc/scripts/add_03700.bc | 17 + contrib/bc/tests/bc/scripts/add_03800.bc | 17 + contrib/bc/tests/bc/scripts/add_03900.bc | 17 + contrib/bc/tests/bc/scripts/add_04000.bc | 17 + contrib/bc/tests/bc/scripts/add_04100.bc | 17 + contrib/bc/tests/bc/scripts/add_04200.bc | 17 + contrib/bc/tests/bc/scripts/add_04300.bc | 17 + contrib/bc/tests/bc/scripts/add_04400.bc | 17 + contrib/bc/tests/bc/scripts/add_04500.bc | 17 + contrib/bc/tests/bc/scripts/add_04600.bc | 17 + contrib/bc/tests/bc/scripts/add_04700.bc | 17 + contrib/bc/tests/bc/scripts/add_04800.bc | 17 + contrib/bc/tests/bc/scripts/add_04900.bc | 17 + contrib/bc/tests/bc/scripts/add_05000.bc | 17 + contrib/bc/tests/bc/scripts/add_05100.bc | 17 + contrib/bc/tests/bc/scripts/add_05200.bc | 17 + contrib/bc/tests/bc/scripts/add_05300.bc | 17 + contrib/bc/tests/bc/scripts/add_05400.bc | 17 + contrib/bc/tests/bc/scripts/add_05500.bc | 17 + contrib/bc/tests/bc/scripts/add_05600.bc | 17 + contrib/bc/tests/bc/scripts/add_05700.bc | 17 + contrib/bc/tests/bc/scripts/add_05800.bc | 17 + contrib/bc/tests/bc/scripts/add_05900.bc | 17 + contrib/bc/tests/bc/scripts/add_06000.bc | 17 + contrib/bc/tests/bc/scripts/add_06100.bc | 17 + contrib/bc/tests/bc/scripts/add_06200.bc | 17 + contrib/bc/tests/bc/scripts/add_06300.bc | 17 + contrib/bc/tests/bc/scripts/add_06400.bc | 17 + contrib/bc/tests/bc/scripts/add_06500.bc | 17 + contrib/bc/tests/bc/scripts/add_06600.bc | 17 + contrib/bc/tests/bc/scripts/add_06700.bc | 17 + contrib/bc/tests/bc/scripts/add_06800.bc | 17 + contrib/bc/tests/bc/scripts/add_06900.bc | 17 + contrib/bc/tests/bc/scripts/add_07000.bc | 17 + contrib/bc/tests/bc/scripts/add_07100.bc | 17 + contrib/bc/tests/bc/scripts/add_07200.bc | 17 + contrib/bc/tests/bc/scripts/add_07300.bc | 17 + contrib/bc/tests/bc/scripts/add_07400.bc | 17 + contrib/bc/tests/bc/scripts/add_07500.bc | 17 + contrib/bc/tests/bc/scripts/add_07600.bc | 17 + contrib/bc/tests/bc/scripts/add_07700.bc | 17 + contrib/bc/tests/bc/scripts/add_07800.bc | 17 + contrib/bc/tests/bc/scripts/add_07900.bc | 17 + contrib/bc/tests/bc/scripts/add_08000.bc | 17 + contrib/bc/tests/bc/scripts/add_08100.bc | 17 + contrib/bc/tests/bc/scripts/add_08200.bc | 17 + contrib/bc/tests/bc/scripts/add_08300.bc | 17 + contrib/bc/tests/bc/scripts/add_08400.bc | 17 + contrib/bc/tests/bc/scripts/add_08500.bc | 17 + contrib/bc/tests/bc/scripts/add_08600.bc | 17 + contrib/bc/tests/bc/scripts/add_08700.bc | 17 + contrib/bc/tests/bc/scripts/add_08800.bc | 17 + contrib/bc/tests/bc/scripts/add_08900.bc | 17 + contrib/bc/tests/bc/scripts/add_09000.bc | 17 + contrib/bc/tests/bc/scripts/add_09100.bc | 17 + contrib/bc/tests/bc/scripts/add_09200.bc | 17 + contrib/bc/tests/bc/scripts/add_09300.bc | 17 + contrib/bc/tests/bc/scripts/add_09400.bc | 17 + contrib/bc/tests/bc/scripts/add_09500.bc | 17 + contrib/bc/tests/bc/scripts/add_09600.bc | 17 + contrib/bc/tests/bc/scripts/add_09700.bc | 17 + contrib/bc/tests/bc/scripts/add_09800.bc | 17 + contrib/bc/tests/bc/scripts/add_09900.bc | 17 + contrib/bc/tests/bc/scripts/add_10000.bc | 17 + contrib/bc/tests/bc/scripts/all.txt | 406 +- .../bc/scripts/{divide.bc => divide_00100.bc} | 2 +- contrib/bc/tests/bc/scripts/divide_00200.bc | 23 + contrib/bc/tests/bc/scripts/divide_00300.bc | 23 + contrib/bc/tests/bc/scripts/divide_00400.bc | 23 + contrib/bc/tests/bc/scripts/divide_00500.bc | 23 + contrib/bc/tests/bc/scripts/divide_00600.bc | 23 + contrib/bc/tests/bc/scripts/divide_00700.bc | 23 + contrib/bc/tests/bc/scripts/divide_00800.bc | 23 + contrib/bc/tests/bc/scripts/divide_00900.bc | 23 + contrib/bc/tests/bc/scripts/divide_01000.bc | 23 + contrib/bc/tests/bc/scripts/divide_01100.bc | 23 + contrib/bc/tests/bc/scripts/divide_01200.bc | 23 + contrib/bc/tests/bc/scripts/divide_01300.bc | 23 + contrib/bc/tests/bc/scripts/divide_01400.bc | 23 + contrib/bc/tests/bc/scripts/divide_01500.bc | 23 + contrib/bc/tests/bc/scripts/divide_01600.bc | 23 + contrib/bc/tests/bc/scripts/divide_01700.bc | 23 + contrib/bc/tests/bc/scripts/divide_01800.bc | 23 + contrib/bc/tests/bc/scripts/divide_01900.bc | 23 + contrib/bc/tests/bc/scripts/divide_02000.bc | 23 + contrib/bc/tests/bc/scripts/divide_02100.bc | 23 + contrib/bc/tests/bc/scripts/divide_02200.bc | 23 + contrib/bc/tests/bc/scripts/divide_02300.bc | 23 + contrib/bc/tests/bc/scripts/divide_02400.bc | 23 + contrib/bc/tests/bc/scripts/divide_02500.bc | 23 + contrib/bc/tests/bc/scripts/divide_02600.bc | 23 + contrib/bc/tests/bc/scripts/divide_02700.bc | 23 + contrib/bc/tests/bc/scripts/divide_02800.bc | 23 + contrib/bc/tests/bc/scripts/divide_02900.bc | 23 + contrib/bc/tests/bc/scripts/divide_03000.bc | 23 + contrib/bc/tests/bc/scripts/divide_03100.bc | 23 + contrib/bc/tests/bc/scripts/divide_03200.bc | 23 + contrib/bc/tests/bc/scripts/divide_03300.bc | 23 + contrib/bc/tests/bc/scripts/divide_03400.bc | 23 + contrib/bc/tests/bc/scripts/divide_03500.bc | 23 + contrib/bc/tests/bc/scripts/divide_03600.bc | 23 + contrib/bc/tests/bc/scripts/divide_03700.bc | 23 + contrib/bc/tests/bc/scripts/divide_03800.bc | 23 + contrib/bc/tests/bc/scripts/divide_03900.bc | 23 + contrib/bc/tests/bc/scripts/divide_04000.bc | 23 + contrib/bc/tests/bc/scripts/divide_04100.bc | 23 + contrib/bc/tests/bc/scripts/divide_04200.bc | 23 + contrib/bc/tests/bc/scripts/divide_04300.bc | 23 + contrib/bc/tests/bc/scripts/divide_04400.bc | 23 + contrib/bc/tests/bc/scripts/divide_04500.bc | 23 + contrib/bc/tests/bc/scripts/divide_04600.bc | 23 + contrib/bc/tests/bc/scripts/divide_04700.bc | 23 + contrib/bc/tests/bc/scripts/divide_04800.bc | 23 + contrib/bc/tests/bc/scripts/divide_04900.bc | 23 + contrib/bc/tests/bc/scripts/divide_05000.bc | 23 + contrib/bc/tests/bc/scripts/divide_05100.bc | 23 + contrib/bc/tests/bc/scripts/divide_05200.bc | 23 + contrib/bc/tests/bc/scripts/divide_05300.bc | 23 + contrib/bc/tests/bc/scripts/divide_05400.bc | 23 + contrib/bc/tests/bc/scripts/divide_05500.bc | 23 + contrib/bc/tests/bc/scripts/divide_05600.bc | 23 + contrib/bc/tests/bc/scripts/divide_05700.bc | 23 + contrib/bc/tests/bc/scripts/divide_05800.bc | 23 + contrib/bc/tests/bc/scripts/divide_05900.bc | 23 + contrib/bc/tests/bc/scripts/divide_06000.bc | 23 + contrib/bc/tests/bc/scripts/divide_06100.bc | 23 + contrib/bc/tests/bc/scripts/divide_06200.bc | 23 + contrib/bc/tests/bc/scripts/divide_06300.bc | 23 + contrib/bc/tests/bc/scripts/divide_06400.bc | 23 + contrib/bc/tests/bc/scripts/divide_06500.bc | 23 + contrib/bc/tests/bc/scripts/divide_06600.bc | 23 + contrib/bc/tests/bc/scripts/divide_06700.bc | 23 + contrib/bc/tests/bc/scripts/divide_06800.bc | 23 + contrib/bc/tests/bc/scripts/divide_06900.bc | 23 + contrib/bc/tests/bc/scripts/divide_07000.bc | 23 + contrib/bc/tests/bc/scripts/divide_07100.bc | 23 + contrib/bc/tests/bc/scripts/divide_07200.bc | 23 + contrib/bc/tests/bc/scripts/divide_07300.bc | 23 + contrib/bc/tests/bc/scripts/divide_07400.bc | 23 + contrib/bc/tests/bc/scripts/divide_07500.bc | 23 + contrib/bc/tests/bc/scripts/divide_07600.bc | 23 + contrib/bc/tests/bc/scripts/divide_07700.bc | 23 + contrib/bc/tests/bc/scripts/divide_07800.bc | 23 + contrib/bc/tests/bc/scripts/divide_07900.bc | 23 + contrib/bc/tests/bc/scripts/divide_08000.bc | 23 + contrib/bc/tests/bc/scripts/divide_08100.bc | 23 + contrib/bc/tests/bc/scripts/divide_08200.bc | 23 + contrib/bc/tests/bc/scripts/divide_08300.bc | 23 + contrib/bc/tests/bc/scripts/divide_08400.bc | 23 + contrib/bc/tests/bc/scripts/divide_08500.bc | 23 + contrib/bc/tests/bc/scripts/divide_08600.bc | 23 + contrib/bc/tests/bc/scripts/divide_08700.bc | 23 + contrib/bc/tests/bc/scripts/divide_08800.bc | 23 + contrib/bc/tests/bc/scripts/divide_08900.bc | 23 + contrib/bc/tests/bc/scripts/divide_09000.bc | 23 + contrib/bc/tests/bc/scripts/divide_09100.bc | 23 + contrib/bc/tests/bc/scripts/divide_09200.bc | 23 + contrib/bc/tests/bc/scripts/divide_09300.bc | 23 + contrib/bc/tests/bc/scripts/divide_09400.bc | 23 + contrib/bc/tests/bc/scripts/divide_09500.bc | 23 + contrib/bc/tests/bc/scripts/divide_09600.bc | 23 + contrib/bc/tests/bc/scripts/divide_09700.bc | 23 + contrib/bc/tests/bc/scripts/divide_09800.bc | 23 + contrib/bc/tests/bc/scripts/divide_09900.bc | 23 + contrib/bc/tests/bc/scripts/divide_10000.bc | 23 + .../bc/scripts/{multiply.bc => multiply_00100.bc} | 2 +- contrib/bc/tests/bc/scripts/multiply_00200.bc | 20 + contrib/bc/tests/bc/scripts/multiply_00300.bc | 20 + contrib/bc/tests/bc/scripts/multiply_00400.bc | 20 + contrib/bc/tests/bc/scripts/multiply_00500.bc | 20 + contrib/bc/tests/bc/scripts/multiply_00600.bc | 20 + contrib/bc/tests/bc/scripts/multiply_00700.bc | 20 + contrib/bc/tests/bc/scripts/multiply_00800.bc | 20 + contrib/bc/tests/bc/scripts/multiply_00900.bc | 20 + contrib/bc/tests/bc/scripts/multiply_01000.bc | 20 + contrib/bc/tests/bc/scripts/multiply_01100.bc | 20 + contrib/bc/tests/bc/scripts/multiply_01200.bc | 20 + contrib/bc/tests/bc/scripts/multiply_01300.bc | 20 + contrib/bc/tests/bc/scripts/multiply_01400.bc | 20 + contrib/bc/tests/bc/scripts/multiply_01500.bc | 20 + contrib/bc/tests/bc/scripts/multiply_01600.bc | 20 + contrib/bc/tests/bc/scripts/multiply_01700.bc | 20 + contrib/bc/tests/bc/scripts/multiply_01800.bc | 20 + contrib/bc/tests/bc/scripts/multiply_01900.bc | 20 + contrib/bc/tests/bc/scripts/multiply_02000.bc | 20 + contrib/bc/tests/bc/scripts/multiply_02100.bc | 20 + contrib/bc/tests/bc/scripts/multiply_02200.bc | 20 + contrib/bc/tests/bc/scripts/multiply_02300.bc | 20 + contrib/bc/tests/bc/scripts/multiply_02400.bc | 20 + contrib/bc/tests/bc/scripts/multiply_02500.bc | 20 + contrib/bc/tests/bc/scripts/multiply_02600.bc | 20 + contrib/bc/tests/bc/scripts/multiply_02700.bc | 20 + contrib/bc/tests/bc/scripts/multiply_02800.bc | 20 + contrib/bc/tests/bc/scripts/multiply_02900.bc | 20 + contrib/bc/tests/bc/scripts/multiply_03000.bc | 20 + contrib/bc/tests/bc/scripts/multiply_03100.bc | 20 + contrib/bc/tests/bc/scripts/multiply_03200.bc | 20 + contrib/bc/tests/bc/scripts/multiply_03300.bc | 20 + contrib/bc/tests/bc/scripts/multiply_03400.bc | 20 + contrib/bc/tests/bc/scripts/multiply_03500.bc | 20 + contrib/bc/tests/bc/scripts/multiply_03600.bc | 20 + contrib/bc/tests/bc/scripts/multiply_03700.bc | 20 + contrib/bc/tests/bc/scripts/multiply_03800.bc | 20 + contrib/bc/tests/bc/scripts/multiply_03900.bc | 20 + contrib/bc/tests/bc/scripts/multiply_04000.bc | 20 + contrib/bc/tests/bc/scripts/multiply_04100.bc | 20 + contrib/bc/tests/bc/scripts/multiply_04200.bc | 20 + contrib/bc/tests/bc/scripts/multiply_04300.bc | 20 + contrib/bc/tests/bc/scripts/multiply_04400.bc | 20 + contrib/bc/tests/bc/scripts/multiply_04500.bc | 20 + contrib/bc/tests/bc/scripts/multiply_04600.bc | 20 + contrib/bc/tests/bc/scripts/multiply_04700.bc | 20 + contrib/bc/tests/bc/scripts/multiply_04800.bc | 20 + contrib/bc/tests/bc/scripts/multiply_04900.bc | 20 + contrib/bc/tests/bc/scripts/multiply_05000.bc | 20 + contrib/bc/tests/bc/scripts/multiply_05100.bc | 20 + contrib/bc/tests/bc/scripts/multiply_05200.bc | 20 + contrib/bc/tests/bc/scripts/multiply_05300.bc | 20 + contrib/bc/tests/bc/scripts/multiply_05400.bc | 20 + contrib/bc/tests/bc/scripts/multiply_05500.bc | 20 + contrib/bc/tests/bc/scripts/multiply_05600.bc | 20 + contrib/bc/tests/bc/scripts/multiply_05700.bc | 20 + contrib/bc/tests/bc/scripts/multiply_05800.bc | 20 + contrib/bc/tests/bc/scripts/multiply_05900.bc | 20 + contrib/bc/tests/bc/scripts/multiply_06000.bc | 20 + contrib/bc/tests/bc/scripts/multiply_06100.bc | 20 + contrib/bc/tests/bc/scripts/multiply_06200.bc | 20 + contrib/bc/tests/bc/scripts/multiply_06300.bc | 20 + contrib/bc/tests/bc/scripts/multiply_06400.bc | 20 + contrib/bc/tests/bc/scripts/multiply_06500.bc | 20 + contrib/bc/tests/bc/scripts/multiply_06600.bc | 20 + contrib/bc/tests/bc/scripts/multiply_06700.bc | 20 + contrib/bc/tests/bc/scripts/multiply_06800.bc | 20 + contrib/bc/tests/bc/scripts/multiply_06900.bc | 20 + contrib/bc/tests/bc/scripts/multiply_07000.bc | 20 + contrib/bc/tests/bc/scripts/multiply_07100.bc | 20 + contrib/bc/tests/bc/scripts/multiply_07200.bc | 20 + contrib/bc/tests/bc/scripts/multiply_07300.bc | 20 + contrib/bc/tests/bc/scripts/multiply_07400.bc | 20 + contrib/bc/tests/bc/scripts/multiply_07500.bc | 20 + contrib/bc/tests/bc/scripts/multiply_07600.bc | 20 + contrib/bc/tests/bc/scripts/multiply_07700.bc | 20 + contrib/bc/tests/bc/scripts/multiply_07800.bc | 20 + contrib/bc/tests/bc/scripts/multiply_07900.bc | 20 + contrib/bc/tests/bc/scripts/multiply_08000.bc | 20 + contrib/bc/tests/bc/scripts/multiply_08100.bc | 20 + contrib/bc/tests/bc/scripts/multiply_08200.bc | 20 + contrib/bc/tests/bc/scripts/multiply_08300.bc | 20 + contrib/bc/tests/bc/scripts/multiply_08400.bc | 20 + contrib/bc/tests/bc/scripts/multiply_08500.bc | 20 + contrib/bc/tests/bc/scripts/multiply_08600.bc | 20 + contrib/bc/tests/bc/scripts/multiply_08700.bc | 20 + contrib/bc/tests/bc/scripts/multiply_08800.bc | 20 + contrib/bc/tests/bc/scripts/multiply_08900.bc | 20 + contrib/bc/tests/bc/scripts/multiply_09000.bc | 20 + contrib/bc/tests/bc/scripts/multiply_09100.bc | 20 + contrib/bc/tests/bc/scripts/multiply_09200.bc | 20 + contrib/bc/tests/bc/scripts/multiply_09300.bc | 20 + contrib/bc/tests/bc/scripts/multiply_09400.bc | 20 + contrib/bc/tests/bc/scripts/multiply_09500.bc | 20 + contrib/bc/tests/bc/scripts/multiply_09600.bc | 20 + contrib/bc/tests/bc/scripts/multiply_09700.bc | 20 + contrib/bc/tests/bc/scripts/multiply_09800.bc | 20 + contrib/bc/tests/bc/scripts/multiply_09900.bc | 20 + contrib/bc/tests/bc/scripts/multiply_10000.bc | 20 + contrib/bc/tests/bc/scripts/parse.bc | 20 - contrib/bc/tests/bc/scripts/parse_02.bc | 19 + contrib/bc/tests/bc/scripts/parse_03.bc | 19 + contrib/bc/tests/bc/scripts/parse_04.bc | 19 + contrib/bc/tests/bc/scripts/parse_05.bc | 19 + contrib/bc/tests/bc/scripts/parse_06.bc | 19 + contrib/bc/tests/bc/scripts/parse_07.bc | 19 + contrib/bc/tests/bc/scripts/parse_08.bc | 19 + contrib/bc/tests/bc/scripts/parse_09.bc | 19 + contrib/bc/tests/bc/scripts/parse_11.bc | 19 + contrib/bc/tests/bc/scripts/parse_12.bc | 19 + contrib/bc/tests/bc/scripts/parse_13.bc | 19 + contrib/bc/tests/bc/scripts/parse_14.bc | 19 + contrib/bc/tests/bc/scripts/parse_15.bc | 19 + contrib/bc/tests/bc/scripts/parse_16.bc | 19 + contrib/bc/tests/bc/scripts/print.bc | 25 - contrib/bc/tests/bc/scripts/print_002.bc | 22 + contrib/bc/tests/bc/scripts/print_003.bc | 22 + contrib/bc/tests/bc/scripts/print_004.bc | 22 + contrib/bc/tests/bc/scripts/print_005.bc | 22 + contrib/bc/tests/bc/scripts/print_006.bc | 22 + contrib/bc/tests/bc/scripts/print_007.bc | 22 + contrib/bc/tests/bc/scripts/print_008.bc | 22 + contrib/bc/tests/bc/scripts/print_009.bc | 22 + contrib/bc/tests/bc/scripts/print_011.bc | 22 + contrib/bc/tests/bc/scripts/print_012.bc | 22 + contrib/bc/tests/bc/scripts/print_013.bc | 22 + contrib/bc/tests/bc/scripts/print_014.bc | 22 + contrib/bc/tests/bc/scripts/print_015.bc | 22 + contrib/bc/tests/bc/scripts/print_016.bc | 22 + contrib/bc/tests/bc/scripts/print_017.bc | 22 + contrib/bc/tests/bc/scripts/print_018.bc | 22 + contrib/bc/tests/bc/scripts/print_019.bc | 22 + contrib/bc/tests/bc/scripts/print_020.bc | 22 + contrib/bc/tests/bc/scripts/print_021.bc | 22 + contrib/bc/tests/bc/scripts/print_022.bc | 22 + contrib/bc/tests/bc/scripts/print_023.bc | 22 + contrib/bc/tests/bc/scripts/print_024.bc | 22 + contrib/bc/tests/bc/scripts/print_025.bc | 22 + contrib/bc/tests/bc/scripts/print_026.bc | 22 + contrib/bc/tests/bc/scripts/print_027.bc | 22 + contrib/bc/tests/bc/scripts/print_028.bc | 22 + contrib/bc/tests/bc/scripts/print_029.bc | 22 + contrib/bc/tests/bc/scripts/print_030.bc | 22 + contrib/bc/tests/bc/scripts/print_031.bc | 22 + contrib/bc/tests/bc/scripts/print_032.bc | 22 + contrib/bc/tests/bc/scripts/print_033.bc | 22 + contrib/bc/tests/bc/scripts/print_034.bc | 22 + contrib/bc/tests/bc/scripts/print_035.bc | 22 + contrib/bc/tests/bc/scripts/print_036.bc | 22 + contrib/bc/tests/bc/scripts/print_037.bc | 22 + contrib/bc/tests/bc/scripts/print_038.bc | 22 + contrib/bc/tests/bc/scripts/print_039.bc | 22 + contrib/bc/tests/bc/scripts/print_040.bc | 22 + contrib/bc/tests/bc/scripts/print_041.bc | 22 + contrib/bc/tests/bc/scripts/print_042.bc | 22 + contrib/bc/tests/bc/scripts/print_043.bc | 22 + contrib/bc/tests/bc/scripts/print_044.bc | 22 + contrib/bc/tests/bc/scripts/print_045.bc | 22 + contrib/bc/tests/bc/scripts/print_046.bc | 22 + contrib/bc/tests/bc/scripts/print_047.bc | 22 + contrib/bc/tests/bc/scripts/print_048.bc | 22 + contrib/bc/tests/bc/scripts/print_049.bc | 22 + contrib/bc/tests/bc/scripts/print_050.bc | 22 + contrib/bc/tests/bc/scripts/print_051.bc | 22 + contrib/bc/tests/bc/scripts/print_052.bc | 22 + contrib/bc/tests/bc/scripts/print_053.bc | 22 + contrib/bc/tests/bc/scripts/print_054.bc | 22 + contrib/bc/tests/bc/scripts/print_055.bc | 22 + contrib/bc/tests/bc/scripts/print_056.bc | 22 + contrib/bc/tests/bc/scripts/print_057.bc | 22 + contrib/bc/tests/bc/scripts/print_058.bc | 22 + contrib/bc/tests/bc/scripts/print_059.bc | 22 + contrib/bc/tests/bc/scripts/print_060.bc | 22 + contrib/bc/tests/bc/scripts/print_061.bc | 22 + contrib/bc/tests/bc/scripts/print_062.bc | 22 + contrib/bc/tests/bc/scripts/print_063.bc | 22 + contrib/bc/tests/bc/scripts/print_064.bc | 22 + contrib/bc/tests/bc/scripts/print_065.bc | 22 + contrib/bc/tests/bc/scripts/print_066.bc | 22 + contrib/bc/tests/bc/scripts/print_067.bc | 22 + contrib/bc/tests/bc/scripts/print_068.bc | 22 + contrib/bc/tests/bc/scripts/print_069.bc | 22 + contrib/bc/tests/bc/scripts/print_070.bc | 22 + contrib/bc/tests/bc/scripts/print_071.bc | 22 + contrib/bc/tests/bc/scripts/print_072.bc | 22 + contrib/bc/tests/bc/scripts/print_073.bc | 22 + contrib/bc/tests/bc/scripts/print_074.bc | 22 + contrib/bc/tests/bc/scripts/print_075.bc | 22 + contrib/bc/tests/bc/scripts/print_076.bc | 22 + contrib/bc/tests/bc/scripts/print_077.bc | 22 + contrib/bc/tests/bc/scripts/print_078.bc | 22 + contrib/bc/tests/bc/scripts/print_079.bc | 22 + contrib/bc/tests/bc/scripts/print_080.bc | 22 + contrib/bc/tests/bc/scripts/print_081.bc | 22 + contrib/bc/tests/bc/scripts/print_082.bc | 22 + contrib/bc/tests/bc/scripts/print_083.bc | 22 + contrib/bc/tests/bc/scripts/print_084.bc | 22 + contrib/bc/tests/bc/scripts/print_085.bc | 22 + contrib/bc/tests/bc/scripts/print_086.bc | 22 + contrib/bc/tests/bc/scripts/print_087.bc | 22 + contrib/bc/tests/bc/scripts/print_088.bc | 22 + contrib/bc/tests/bc/scripts/print_089.bc | 22 + contrib/bc/tests/bc/scripts/print_090.bc | 22 + contrib/bc/tests/bc/scripts/print_091.bc | 22 + contrib/bc/tests/bc/scripts/print_092.bc | 22 + contrib/bc/tests/bc/scripts/print_093.bc | 22 + contrib/bc/tests/bc/scripts/print_094.bc | 22 + contrib/bc/tests/bc/scripts/print_095.bc | 22 + contrib/bc/tests/bc/scripts/print_096.bc | 22 + contrib/bc/tests/bc/scripts/print_097.bc | 22 + contrib/bc/tests/bc/scripts/print_098.bc | 22 + contrib/bc/tests/bc/scripts/print_099.bc | 22 + contrib/bc/tests/bc/scripts/print_100.bc | 22 + .../bc/scripts/{subtract.bc => subtract_00100.bc} | 2 +- contrib/bc/tests/bc/scripts/subtract_00200.bc | 17 + contrib/bc/tests/bc/scripts/subtract_00300.bc | 17 + contrib/bc/tests/bc/scripts/subtract_00400.bc | 17 + contrib/bc/tests/bc/scripts/subtract_00500.bc | 17 + contrib/bc/tests/bc/scripts/subtract_00600.bc | 17 + contrib/bc/tests/bc/scripts/subtract_00700.bc | 17 + contrib/bc/tests/bc/scripts/subtract_00800.bc | 17 + contrib/bc/tests/bc/scripts/subtract_00900.bc | 17 + contrib/bc/tests/bc/scripts/subtract_01000.bc | 17 + contrib/bc/tests/bc/scripts/subtract_01100.bc | 17 + contrib/bc/tests/bc/scripts/subtract_01200.bc | 17 + contrib/bc/tests/bc/scripts/subtract_01300.bc | 17 + contrib/bc/tests/bc/scripts/subtract_01400.bc | 17 + contrib/bc/tests/bc/scripts/subtract_01500.bc | 17 + contrib/bc/tests/bc/scripts/subtract_01600.bc | 17 + contrib/bc/tests/bc/scripts/subtract_01700.bc | 17 + contrib/bc/tests/bc/scripts/subtract_01800.bc | 17 + contrib/bc/tests/bc/scripts/subtract_01900.bc | 17 + contrib/bc/tests/bc/scripts/subtract_02000.bc | 17 + contrib/bc/tests/bc/scripts/subtract_02100.bc | 17 + contrib/bc/tests/bc/scripts/subtract_02200.bc | 17 + contrib/bc/tests/bc/scripts/subtract_02300.bc | 17 + contrib/bc/tests/bc/scripts/subtract_02400.bc | 17 + contrib/bc/tests/bc/scripts/subtract_02500.bc | 17 + contrib/bc/tests/bc/scripts/subtract_02600.bc | 17 + contrib/bc/tests/bc/scripts/subtract_02700.bc | 17 + contrib/bc/tests/bc/scripts/subtract_02800.bc | 17 + contrib/bc/tests/bc/scripts/subtract_02900.bc | 17 + contrib/bc/tests/bc/scripts/subtract_03000.bc | 17 + contrib/bc/tests/bc/scripts/subtract_03100.bc | 17 + contrib/bc/tests/bc/scripts/subtract_03200.bc | 17 + contrib/bc/tests/bc/scripts/subtract_03300.bc | 17 + contrib/bc/tests/bc/scripts/subtract_03400.bc | 17 + contrib/bc/tests/bc/scripts/subtract_03500.bc | 17 + contrib/bc/tests/bc/scripts/subtract_03600.bc | 17 + contrib/bc/tests/bc/scripts/subtract_03700.bc | 17 + contrib/bc/tests/bc/scripts/subtract_03800.bc | 17 + contrib/bc/tests/bc/scripts/subtract_03900.bc | 17 + contrib/bc/tests/bc/scripts/subtract_04000.bc | 17 + contrib/bc/tests/bc/scripts/subtract_04100.bc | 17 + contrib/bc/tests/bc/scripts/subtract_04200.bc | 17 + contrib/bc/tests/bc/scripts/subtract_04300.bc | 17 + contrib/bc/tests/bc/scripts/subtract_04400.bc | 17 + contrib/bc/tests/bc/scripts/subtract_04500.bc | 17 + contrib/bc/tests/bc/scripts/subtract_04600.bc | 17 + contrib/bc/tests/bc/scripts/subtract_04700.bc | 17 + contrib/bc/tests/bc/scripts/subtract_04800.bc | 17 + contrib/bc/tests/bc/scripts/subtract_04900.bc | 17 + contrib/bc/tests/bc/scripts/subtract_05000.bc | 17 + contrib/bc/tests/bc/scripts/subtract_05100.bc | 17 + contrib/bc/tests/bc/scripts/subtract_05200.bc | 17 + contrib/bc/tests/bc/scripts/subtract_05300.bc | 17 + contrib/bc/tests/bc/scripts/subtract_05400.bc | 17 + contrib/bc/tests/bc/scripts/subtract_05500.bc | 17 + contrib/bc/tests/bc/scripts/subtract_05600.bc | 17 + contrib/bc/tests/bc/scripts/subtract_05700.bc | 17 + contrib/bc/tests/bc/scripts/subtract_05800.bc | 17 + contrib/bc/tests/bc/scripts/subtract_05900.bc | 17 + contrib/bc/tests/bc/scripts/subtract_06000.bc | 17 + contrib/bc/tests/bc/scripts/subtract_06100.bc | 17 + contrib/bc/tests/bc/scripts/subtract_06200.bc | 17 + contrib/bc/tests/bc/scripts/subtract_06300.bc | 17 + contrib/bc/tests/bc/scripts/subtract_06400.bc | 17 + contrib/bc/tests/bc/scripts/subtract_06500.bc | 17 + contrib/bc/tests/bc/scripts/subtract_06600.bc | 17 + contrib/bc/tests/bc/scripts/subtract_06700.bc | 17 + contrib/bc/tests/bc/scripts/subtract_06800.bc | 17 + contrib/bc/tests/bc/scripts/subtract_06900.bc | 17 + contrib/bc/tests/bc/scripts/subtract_07000.bc | 17 + contrib/bc/tests/bc/scripts/subtract_07100.bc | 17 + contrib/bc/tests/bc/scripts/subtract_07200.bc | 17 + contrib/bc/tests/bc/scripts/subtract_07300.bc | 17 + contrib/bc/tests/bc/scripts/subtract_07400.bc | 17 + contrib/bc/tests/bc/scripts/subtract_07500.bc | 17 + contrib/bc/tests/bc/scripts/subtract_07600.bc | 17 + contrib/bc/tests/bc/scripts/subtract_07700.bc | 17 + contrib/bc/tests/bc/scripts/subtract_07800.bc | 17 + contrib/bc/tests/bc/scripts/subtract_07900.bc | 17 + contrib/bc/tests/bc/scripts/subtract_08000.bc | 17 + contrib/bc/tests/bc/scripts/subtract_08100.bc | 17 + contrib/bc/tests/bc/scripts/subtract_08200.bc | 17 + contrib/bc/tests/bc/scripts/subtract_08300.bc | 17 + contrib/bc/tests/bc/scripts/subtract_08400.bc | 17 + contrib/bc/tests/bc/scripts/subtract_08500.bc | 17 + contrib/bc/tests/bc/scripts/subtract_08600.bc | 17 + contrib/bc/tests/bc/scripts/subtract_08700.bc | 17 + contrib/bc/tests/bc/scripts/subtract_08800.bc | 17 + contrib/bc/tests/bc/scripts/subtract_08900.bc | 17 + contrib/bc/tests/bc/scripts/subtract_09000.bc | 17 + contrib/bc/tests/bc/scripts/subtract_09100.bc | 17 + contrib/bc/tests/bc/scripts/subtract_09200.bc | 17 + contrib/bc/tests/bc/scripts/subtract_09300.bc | 17 + contrib/bc/tests/bc/scripts/subtract_09400.bc | 17 + contrib/bc/tests/bc/scripts/subtract_09500.bc | 17 + contrib/bc/tests/bc/scripts/subtract_09600.bc | 17 + contrib/bc/tests/bc/scripts/subtract_09700.bc | 17 + contrib/bc/tests/bc/scripts/subtract_09800.bc | 17 + contrib/bc/tests/bc/scripts/subtract_09900.bc | 17 + contrib/bc/tests/bc/scripts/subtract_10000.bc | 17 + contrib/bc/tests/bc/timeconst.sh | 5 +- contrib/bc/tests/bcl.c | 2 +- contrib/bc/tests/dc/scripts/easter.dc | 49 + contrib/bc/tests/dc/scripts/easter.sh | 93 - contrib/bc/tests/dc/scripts/easter.txt | 5 + contrib/bc/tests/dc/scripts/prime.dc | 2 +- contrib/bc/tests/error.sh | 4 +- contrib/bc/tests/errors.sh | 4 +- contrib/bc/tests/extra_required.txt | 17 +- contrib/bc/tests/history.py | 4 +- contrib/bc/tests/history.sh | 2 +- contrib/bc/tests/other.sh | 593 -- contrib/bc/tests/read.sh | 166 - contrib/bc/tests/script.sh | 25 +- contrib/bc/tests/scripts.sh | 17 +- contrib/bc/tests/stdin.sh | 2 +- contrib/bc/tests/test.sh | 24 +- contrib/bc/vs/bc.vcxproj | 1 - contrib/bc/vs/bc.vcxproj.filters | 3 - contrib/bc/vs/bcl.vcxproj | 1 - contrib/bc/vs/bcl.vcxproj.filters | 3 - usr.bin/gh-bc/Makefile | 6 +- usr.bin/gh-bc/tests/Makefile | 9 +- 715 files changed, 28229 insertions(+), 3016 deletions(-) diff --git a/contrib/bc/LICENSE.md b/contrib/bc/LICENSE.md index c8f6758e6d4b..e5d44dee6dab 100644 --- a/contrib/bc/LICENSE.md +++ b/contrib/bc/LICENSE.md @@ -1,6 +1,6 @@ # License -Copyright (c) 2018-2024 Gavin D. Howard +Copyright (c) 2018-2025 Gavin D. Howard Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: @@ -60,7 +60,7 @@ The files `src/rand.c` and `include/rand.h` are under the following copyrights and license: Copyright (c) 2014-2017 Melissa O'Neill and PCG Project contributors
-Copyright (c) 2018-2024 Gavin D. Howard +Copyright (c) 2018-2025 Gavin D. Howard Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in diff --git a/contrib/bc/MAINTENANCE-TERMS.md b/contrib/bc/MAINTENANCE-TERMS.md new file mode 100644 index 000000000000..ef24202cc6c2 --- /dev/null +++ b/contrib/bc/MAINTENANCE-TERMS.md @@ -0,0 +1,80 @@ +# Maintenance Terms + +> Last Updated: 27 June 2025 + +The code, text, and other materials in this repository are provided as-is under +the terms of the repository's [`LICENSE.md`][0] file, as a gift to the commons +and the common good. In providing this software as-is, its author(s) admit no +further obligations from anyone using the software for any reason, particularly +with respect to: + +* Releases, +* Response time, +* Change review and integration, +* Disclosure schedules, +* Discretionary, proprietary or otherwise secretive communications, and +* Any other non-contractual obligations or conventions, regardless of their + presumed urgency or severity. + +Should anyone wish to make a contract with me (Gavin Howard) to ensure that work +he or she deems critical gets done, the terms are as follows: + +* Compute time will be charged at \$25/hr. +* My time will be charged at \$100/hr. +* All issues deemed critical by either me or the requester, that also change the + source code (anything in `gen`, `include`, or `src`) will require at least two + weeks of fuzzing without error. + * If errors are found, those hours will still be charged on top of the final + two weeks. +* All changes will require running the [release script][2] on Linux (GCC), Linux + (Clang), FreeBSD, OpenBSD, macOS, Windows. +* Any hours spent on bugs or code that have been, or are suspected to have been, + generated by "AI" will be charged double rates. + +Compute time includes, but is not limited to: + +* Fuzzing. +* Running my [release script][2]. +* Running tests and my [release script][2] on macOS. + +My time includes, but is not limited to: + +* Code review. +* Reading bug reports. +* Design. +* Coding. +* Any compute time that interferes with my ability to do any other work: + * Fuzzing makes my computer unusable, so fuzzing for the 8-12 hours of the + day that I could be working will be charged at \$100/hr. + * Same with running my [release script][2] because I run two instances on my + machine and two in VMs at the same time. + * Running my [release script][2] or any other compute time on Windows + because Windows blocks me from doing my main work on Linux. + * Any other instances of blocking compute time. + +All amounts will be billed by, and paid to, [Yzena, LLC][2]. Invoices will be +provided, including line items for what each hour was spent on. + +It is suggested that the following amounts be budgeted: + +* At least \$3000 for a non-critical issue or change. + + The release script takes about 10 hours, and I would need to run it once on + Linux (and others at the same time) and once on Windows, which is 20 hours. + Most of that won't be at the \$100/hr rate, but some probably will be. Then + an extra \$1000 for other work. + +* At least \$15,000 for a critical issue or change. + + The \$3000 above is the start, which leaves \$12,000. Fuzzing is expected to + cost \$11,400 (6 days a week, 8 hours a day, at \$100, the rest at \$25), and + rounded up to \$12,000 for good measure. + +--- + +This document is inspired by [Mike Hoye's Maintenance Terms][1]. + +[0]: LICENSE.md +[1]: https://github.com/mhoye/maintenance-terms +[2]: scripts/release.sh +[3]: https://yzena.com/ diff --git a/contrib/bc/Makefile.in b/contrib/bc/Makefile.in index c63dc242e79a..f8b120c1328e 100644 --- a/contrib/bc/Makefile.in +++ b/contrib/bc/Makefile.in @@ -1,7 +1,7 @@ # # SPDX-License-Identifier: BSD-2-Clause # -# Copyright (c) 2018-2024 Gavin D. Howard and contributors. +# Copyright (c) 2018-2025 Gavin D. Howard and contributors. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: @@ -38,6 +38,8 @@ GENDIR = $(ROOTDIR)/gen BUILDDIR = %%BUILDDIR%% +VERSION = %%VERSION%% + SRC = %%SRC%% OBJ = %%OBJ%% GCDA = %%GCDA%% @@ -99,17 +101,16 @@ BC_FUZZER_C = $(BIN)/$(BC)_fuzzer_C DC_FUZZER = $(BIN)/$(DC)_fuzzer_c DC_FUZZER_C = $(BIN)/$(DC)_fuzzer_C -BC_TEST_OUTPUTS = tests/bc_outputs BC_FUZZ_OUTPUTS = tests/fuzzing/bc_outputs1 tests/fuzzing/bc_outputs2 tests/fuzzing/bc_outputs3 -DC_TEST_OUTPUTS = tests/dc_outputs DC_FUZZ_OUTPUTS = tests/fuzzing/dc_outputs LIB = libbcl LIB_NAME = $(LIB).a LIBBC = $(BIN)/$(LIB_NAME) BCL = bcl -BCL_TEST = $(BIN)/$(BCL) -BCL_TEST_C = $(TESTSDIR)/$(BCL).c + +GENERATE_TESTS = %%GENERATE_TESTS%% +PROBLEMATIC_TESTS = %%PROBLEMATIC_TESTS%% MANUALS = manuals BC_MANPAGE_NAME = $(EXEC_PREFIX)$(BC)$(EXEC_SUFFIX).1 @@ -152,11 +153,11 @@ BC_ENABLE_EXTRA_MATH = %%EXTRA_MATH%% BC_ENABLE_NLS = %%NLS%% BC_EXCLUDE_EXTRA_MATH = %%EXCLUDE_EXTRA_MATH%% -BC_ENABLE_AFL = %%FUZZ%% -BC_ENABLE_OSSFUZZ = %%OSSFUZZ%% -BC_ENABLE_MEMCHECK = %%MEMCHECK%% +BC_ENABLE_AFL = 0 +BC_ENABLE_OSSFUZZ = 0 +BC_ENABLE_MEMCHECK = 0 -LIB_FUZZING_ENGINE = %%LIB_FUZZING_ENGINE%% +LIB_FUZZING_ENGINE = 0 BC_DEFAULT_BANNER = %%BC_DEFAULT_BANNER%% BC_DEFAULT_SIGINT_RESET = %%BC_DEFAULT_SIGINT_RESET%% @@ -189,10 +190,6 @@ KARATSUBA = $(SCRIPTSDIR)/karatsuba.py LOCALE_INSTALL = $(SCRIPTSDIR)/locale_install.sh LOCALE_UNINSTALL = $(SCRIPTSDIR)/locale_uninstall.sh -VALGRIND_ARGS = --error-exitcode=100 --leak-check=full --show-leak-kinds=all --errors-for-leak-kinds=all - -TEST_STARS = *********************************************************************** - BC_NUM_KARATSUBA_LEN = %%KARATSUBA_LEN%% BC_DEFS0 = -DBC_DEFAULT_BANNER=$(BC_DEFAULT_BANNER) @@ -218,7 +215,7 @@ CPPFLAGS6 = $(CPPFLAGS5) -DBC_ENABLE_NLS=$(BC_ENABLE_NLS) CPPFLAGS7 = $(CPPFLAGS6) -D$(BC_ENABLE_EXTRA_MATH_NAME)=$(BC_ENABLE_EXTRA_MATH) CPPFLAGS8 = $(CPPFLAGS7) -DBC_ENABLE_HISTORY=$(BC_ENABLE_HISTORY) -DBC_ENABLE_LIBRARY=$(BC_ENABLE_LIBRARY) CPPFLAGS9 = $(CPPFLAGS8) -DBC_ENABLE_MEMCHECK=$(BC_ENABLE_MEMCHECK) -DBC_ENABLE_AFL=$(BC_ENABLE_AFL) -CPPFLAGS = $(CPPFLAGS9) -DBC_ENABLE_OSSFUZZ=$(BC_ENABLE_OSSFUZZ) +CPPFLAGS = -DVERSION=$(VERSION) $(CPPFLAGS9) -DBC_ENABLE_OSSFUZZ=$(BC_ENABLE_OSSFUZZ) CFLAGS = $(CPPFLAGS) $(BC_DEFS) $(DC_DEFS) %%CPPFLAGS%% %%CFLAGS%% LDFLAGS = %%LDFLAGS%% @@ -293,236 +290,10 @@ help: @printf ' check alias for `make test`\n' @printf ' clean removes all build files\n' @printf ' clean_config removes all build files as well as the generated Makefile\n' - @printf ' clean_tests removes all build files, the generated Makefile,\n' - @printf ' and generated tests\n' @printf ' install installs binaries to "%s%s"\n' "$(DESTDIR)" "$(BINDIR)" @printf ' and (if enabled) manpages to "%s%s"\n' "$(DESTDIR)" "$(MAN1DIR)" - @printf ' karatsuba runs the karatsuba script (requires Python 3)\n' - @printf ' karatsuba_test runs the karatsuba script while running tests\n' - @printf ' (requires Python 3)\n' @printf ' uninstall uninstalls binaries from "%s%s"\n' "$(DESTDIR)" "$(BINDIR)" @printf ' and (if enabled) manpages from "%s%s"\n' "$(DESTDIR)" "$(MAN1DIR)" - @printf ' test runs the test suite\n' - @printf ' test_bc runs the bc test suite, if bc has been built\n' - @printf ' test_dc runs the dc test suite, if dc has been built\n' - @printf ' time_test runs the test suite, displaying times for some things\n' - @printf ' time_test_bc runs the bc test suite, displaying times for some things\n' - @printf ' time_test_dc runs the dc test suite, displaying times for some things\n' - @printf ' timeconst runs the test on the Linux timeconst.bc script,\n' - @printf ' if it exists and bc has been built\n' - -run_all_tests: bc_all_tests timeconst_all_tests dc_all_tests - -run_all_tests_np: bc_all_tests_np timeconst_all_tests dc_all_tests_np - -bc_all_tests: - %%BC_ALL_TESTS%% - -bc_all_tests_np: - %%BC_ALL_TESTS_NP%% - -timeconst_all_tests: - %%TIMECONST_ALL_TESTS%% - -dc_all_tests: - %%DC_ALL_TESTS%% - -dc_all_tests_np: - %%DC_ALL_TESTS_NP%% - -history_all_tests: - %%HISTORY_TESTS%% - -check: test - -test: %%TESTS%% *** 37561 LINES SKIPPED *** From nobody Wed Sep 17 18:38:57 2025 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 4cRnbn3mhTz67rTF; Wed, 17 Sep 2025 18:39:01 +0000 (UTC) (envelope-from flo@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRnbn361mz3wcQ; Wed, 17 Sep 2025 18:39:01 +0000 (UTC) (envelope-from flo@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758134341; 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: in-reply-to:in-reply-to:references:references:autocrypt:autocrypt; bh=AfrcE9xm1KOzEoURRkilib3cgY0wQr/M/h359r8WI/A=; b=KGhXBVK8CpKOtrOGbYaWGkLLsh+zrc1imIPvZELn0xiW6eZm9PPLfUgbgraTFAqSGK6bAo iRtMtso3ME8eD7q7ALq0IgWQI+189SpA0+zO+pMCw6RLTG675Dnh8Bso6rmSobVTn1mmQM aQcGGG4zuewwbMB7eP0R4V+y9Z1MbVtlmVgruagZa/YQ7Cd2NqBLjetinECrZTHcoXNm6k bUYhUvg5BSVQB/Z8L28Zv8db+DIj1xc2agKbZ+q60kboeNzGVfB8issZEXKRNnezpjzBN7 bZnGKSkCI+B2vUCqYxZt65OE7fOErgcGXTVLfUdHNDgr6Z0e5s+lnhWFqKCQzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758134341; 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: in-reply-to:in-reply-to:references:references:autocrypt:autocrypt; bh=AfrcE9xm1KOzEoURRkilib3cgY0wQr/M/h359r8WI/A=; b=nMHJy5hYZAuLb0TBBnllfjmASkuY3rbrEZ5bauIMdLOMn3F2W1KdrL5dGntZKX4ildpMA4 4AxOKu/7TvTU7SnHxftLQKbtGXiKDHpnV9f6d5CZPD1P/F7hZTOEESGZDsOmfSNtIJL8JP 51+6x74xarsTclDI4CYG4Wk/oAsPFSgaAcFavPNEbZCGPhzAJzysvKpOeC3OGXv8e97nmr JZ7pbzgpAhnW2+z3abWh0W3Hb9WTX5GPQygrUWm9RtGQ/BRE4Jt5cKptmRbv2XUCKK50t+ n4I3H5/6c1JSX2Bg19WStgAal7VotL22yXLeA1Y2rElNuawMvV5vTXl8SghmMg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758134341; a=rsa-sha256; cv=none; b=x/WAAjSCOGjqPk6ls2iHX8eqUn01tFStLz7PXHFxZvQk1zbwpu5QOYMBpcBKtYNUNZQXVZ 55R+KMZMBxIh/CFe9RwT94xn2ezugum/tHAD1Eq2kdDc59RzhRL+MVPQSJ14WttGUcXu0g cqZ7o3GqUTfL8S/erg504iH6RsUArM9VqZjEoO2htixVg3vP9hl3TcnXUg/BJl2PnBgVw7 ZRjpt2dya8B+FQA8cBqhfvPwQHR8aixKBHb9FJB/5Tnv1B4BkUR5hFpxkX3/OHGtUJgt9u kYTs5Klnu9vD8b7L3pkG5hrX/mb/PeA36sbBJWcQocPcTXpWsDRmaN8q9Hhrag== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from [IPV6:2a0d:3344:15ac:6900::19e7] (unknown [IPv6:2a0d:3344:15ac:6900::19e7]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: flo/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cRnbm5PKyz3F6; Wed, 17 Sep 2025 18:39:00 +0000 (UTC) (envelope-from flo@FreeBSD.org) Message-ID: <4fd761a0-b7ba-45b6-8e9e-e6b696a241a0@FreeBSD.org> Date: Wed, 17 Sep 2025 20:38:57 +0200 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 User-Agent: Mozilla Thunderbird Subject: Re: git: 9d9bc7f462bd - main - pf: set limits before rules Content-Language: en-US To: Kristof Provost , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org References: <202509171415.58HEFh9g010282@gitrepo.freebsd.org> From: Florian Smeets Autocrypt: addr=flo@FreeBSD.org; keydata= xsFNBFpyBwsBEADLq0c46orEtbMn4SptX+VJxR1wB4YwaErZme1bqF4nZHIhlRNET22HsHdQ doagaB4uACq0Rj5kHcu614ZnnNkLPyCxWQATx+cbdiFO4/hfT8tAvKnBtiy3awKJ5uGCNO2E zJwXW6KwdDA8XPRySqN8m1yPl+dW0Cls+/vO/QL/6+YLMupmEpSvFxRzAZTQuKyX4+xl+dYI d24JiPd1yfCuDNOY3+OZ3QBMT00u/699N8lUWRtiTwaQMwAOww8r/26YM6/SgcgFuLH2E/CV plY0sDvfoISlAj8agxdomNXfPjCMQ6w5yGZmA+huFpPCVBTi3on/SWgbQO7dLVpN4BNPuScP osCb/dsOg0S74zCClsIU3gdUGh9rwJY00/Ebid6V0R3c1Czwbg8LQedzlGDuXYXmzp6W2ujg r1cqbUD6lUWikUv2IMdCbb8MxYhHLi3GYUs5Xpi+W7vM6T45KbuMr7O/1SjtcGOlNeDvGNgj cDk20fOgPPZ+M6i9vX5Q2oI9HoYaeTiYNwILkBLVP/L40kTo5EkiQOt4OW6BMbylqXPOaQMW uGVbmhCJQpbx8Vo80s2yiBBVWkLkWQIcIm3KZlLldJqKEFpQBWLBE1eFFqboYgAWzFn73CaV 5tihobijMmmOV3a8cI1fI4kREyl3g+8bW+O0u3m3tuzVOpDpjwARAQABzSBGbG9yaWFuIFNt ZWV0cyA8ZmxvQEZyZWVCU0Qub3JnPsLBlAQTAQoAPgIbAwULCQgHAwUVCgkICwUWAwIBAAIe AQIXgBYhBOyzaLh5CL+2kU1yae9bpNzVqfPABQJlmq1gBQkO64zlAAoJEO9bpNzVqfPAU3YQ ALit2AZO3MDHjKG7qT/43hSOnN3BoxRgRFz63N+bFR+tJlTE7k0SA8iephy97UKbf55wfQB4 v07q7kp1VckuJvorsU0ygCA2AnjNPRnGG3VyRfaJKBp22sGICDiMVe/c/SvCy/877A/tFVZj Z2rxTWNlT6i3In3YFae48OxCL8FfUFF+37tGmwj5PWi3lIpOKeuZLW0KHebXKCqpzIRcnjHO E7moQILrFsXvmay9JVYclNrDNIaePWuVlFNgFYMsF9+ixn3f7lTgprIyljS2F1fxpcBIR/Kj JFsjXl73IyZr3PxCBq8mpCi6ukD/58UFCvB9VRXUkAqm8k0eoBe61RlRoXrZlSmIq8qT0K97 tqFLpFVRylHnZEsjhxI6Drox+910LyF9rAZDS1GgDpyAd2qE7AgijcpFjpeYB480ZGgnRtEp 3v8MbGNhne7Og07hT1yB9DUoiM9gLxapLSujp2X6QWRONaLvv0Kz7BuCOHbMaol4YpjABd/4 3i5jnAsTBkBm6jsmEPhK69Vxsrkqs7E7OZOBnVdCR5HGZNq6Nss+dRXFHxGTyk+98ADLWl6M tQxZE8jYyxPzow5wNgkOoGrpTgQp0lDefI9pQhZFW77HZaBbbaffBAfISXWONmut7GVjb0oN xhW/OA/oQSiWYIP7c4JOWZ+apAZQtqNxYCWbzsFNBFpyBwsBEADR6zpub8nSv4o9c5A8i2c2 6IJOc4zIeqAK93B+KBmyRzy5chWUwlQWFMA+JIejVdbCrmTnl/2soMlYNUci7pZ87HOmI1zi MZaoakMBiPJPLLACKTEn9Nve/NQjRdhwuNgqyXh7VzTjQzTo7DLqMc4Gvcy0AoeIy05RP01C aOilQAVgVUbU1Ydme+6SrTe49jTxQR76eytFh31fk2J5bII4VANAAmZ1HR0tmEcwYQs80Hpb ncQc+eEvcW1KtZn2X1cfAGwBlxds8aOvJ77wACZ+PB4gUt3TIQhmCQ3WXY2ukHVBT4npopzs cJFMwqpisZvgI+1ErntUm2WaicZjCNXheDq5PwSSSO+GfxZyYGEeFJBIg9yfylKHEAiB93Wg dfvwl5YffSG+wD/kBripN75zR4e1QatxPlQIjOS1NAZoFvnHUTx5IsDO7A2tlZ1d1ar1e0Jq DCpxxc1AejZ/LhPompKeSfNT6+vJAzqu5C1t1JxpoNT1Km7Jwmk4piW9yQGFszlv/QmHD5Ww HSKovsB+zDqHi/jwPfQN5Fv/PNaxpnjmBc867DVS7XmvgCX17aeCzeYDlSDyKaLwjUlV1xCo Je2uL41Bs1Qc6x+z80/pOF1BEMDQgAnxmcRBMbZ8tfW477pmdK7/gBAB77Fkilx1FScyDY6n fVIqGhGyhgD5TwARAQABwsF8BBgBCgAmAhsMFiEE7LNouHkIv7aRTXJp71uk3NWp88AFAmWa rWAFCQ7rjOUACgkQ71uk3NWp88AgbBAAtHmL+mDSRzHYBgG9thI9cDr7M86uvtrAz1xjE8gl DEzqu+/XHNcg3KyoIjDzuipoPrpt73lLv+k67sfLY8YcaCq0WfP5BfJXOZcdpKzxQyaKI5h5 RDQsjEzpSESdDO2YCQypA9KRMJtI/VIJqxZglOp/Vh4aaF1t5Bi2NDNyAMHs8kToNRn56W51 72Lp9sJh9zrpA6DhJLhSWCc9tlzUWQUIdv0Y7Z5U5epfRuWTjYGSSc4kmve2eVBLIN+RMrRH kyVXIoj9AVwVoGMBPtHEYejBImOdV/oanW1EN0VNbQDAuRxhgrUfZR4KQY9GU7QcV5zn1zVh w0JLMIEqxFB9Q0TnMewTSXb482DM7cL6I3iYDoEjPkQOoYP3t9Y6bfF9h02LjVK5xNZ2qJ2r KNxGjV2BNk0NLfRBncVkX6BJWeQ1KBTEymd/8rD0vQprG9Uzqzth77sZoW6/983y1yMlsuer a6qqdH37m310/Gr3TQTCcGY3D8T27MUcLZXtw+MrbctKg8xe4CjHePODrQRrVuAuEIbHlOcs iQVw9UriY2SqHYsKgbVlIDdSZH3qbRrpLpQfjcJlQvWK4b2I1wQ69BDOjreN5IOYxhXRzgIX 86nrZ3CioiVFVBw4PoKMXo2pjbDavPMXZ8dUA7A6rmQPFHQ3S4HfIgxsh005YKJD2Zc= In-Reply-To: <202509171415.58HEFh9g010282@gitrepo.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 17.09.25 16:15, Kristof Provost wrote: > The branch main has been updated by kp: > > URL: https://cgit.FreeBSD.org/src/commit/?id=9d9bc7f462bd152d87ab8f1767cad19bab09bf8b > > commit 9d9bc7f462bd152d87ab8f1767cad19bab09bf8b > Author: Kristof Provost > AuthorDate: 2025-08-25 13:43:10 +0000 > Commit: Kristof Provost > CommitDate: 2025-09-17 14:15:15 +0000 > > pf: set limits before rules > Nice, I ran into this issue recently that the ruleset would not load on boot because we load large tables. I set a higher PFR_KENTRY_HIWAT as a workaround. Are you planning to merge this to stable/15? Maybe get this into 15.0? Thanks Florian From nobody Wed Sep 17 18:58:46 2025 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 4cRp2l6W7kz67t3F; Wed, 17 Sep 2025 18:58:55 +0000 (UTC) (envelope-from kp@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRp2l615nz412N; Wed, 17 Sep 2025 18:58:55 +0000 (UTC) (envelope-from kp@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758135535; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=HhTqykRNumS8O70ogjC25dZ3dOhb8VNljI3mw0rIJP0=; b=R19UX6tZsYmg2cPbo9bHYNOjs2KM5+Ux24WkmfVrc0BJSiXz2gGglNhcrM/fXpOjXlh1WI SxXd61Q/axgwtVhSCUrD1M5zQOBD9VaM3Xt5w6YTDP4SnTysw2G6vKvGoKQ/MSz5aW8ClK kjvS790jL+QUAB1+zEnyBiqi8U8oEgajakWE2EBzxcGG4qQDDjTuFYNvy4XEM6XxJJ96jW /YkqbK2ZI4t4IkBiaz1mGsY52Nkt0lOKakRTQyHrzrp7hdgtAwkmT+vh6VoqNThaMQ2Say joKxek1+iDuU2/gQIiHOGO9nzR1sNUZjE33FKAJiGOkr+DKGDWyhQ/xAT4Kinw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758135535; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=HhTqykRNumS8O70ogjC25dZ3dOhb8VNljI3mw0rIJP0=; b=FURKoBnXQ0QYo7VOo+x7AEvzEchDq7RQ5TD+6j/DdZN8Qxq7cJ+V1pBrAFXjniR7tliC6D JXlrWpifrQoS0ZMLx5eSK5SNK2zmRTkhujn+/iYio0c6/HI3lK1slrm8nr9UMt2KLMi6N6 Lm/rF9NK/hsXd9mo0MQezwoinIg5oArlzu6NnOR6RYcJXAkrVOvTohbJlyac4OcUnG3r2J vhE/VF3PO34Y9h/n4ZrvbKnJ2sd1QjDFkW5ZoW36BPAfu14r1G0IeLrGKHD45bu5V3hTsn OwkY/QIW5Ne93YFBMo2qkWGrqRxC5AJjTqnJov1qJfz3wYLOEuJBL//sYIo+xg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758135535; a=rsa-sha256; cv=none; b=t0vDtKYz7mXYwmGky7frvC+r9sXgaRfaaro6eShJq3teU18yuaze1ljHAhAdYbm7pghV8U 2lbSAzPdfZI44zpDTuMACpW6Ep5uEYO1naEaX8NhnbMm+7QS+XFl3pdFMUh8vabsY1vifF Uur6lKg9dBzQQxFkabco6L9/jS8XcISGveWrTGFT7FRG9b09Zp02x0qDog1WVvwS4Q2VIj qPtqpxRbXZ6lFVFuh+I9rPIrP8ID99Iz+5VfK0oMRBtTPkM87j18NqL/bsuuYtXjiF+paz ZnJyTSpeKiMZnUAtgw25cWaUeVolcuLSsOwKDy62q2lzcKrpm2mWo7nT0sx0gg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from venus.codepro.be (venus.codepro.be [5.9.86.228]) (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 (2048 bits) client-digest SHA256) (Client CN "mx1.codepro.be", Issuer "R11" (verified OK)) (Authenticated sender: kp) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cRp2l4f3gz3FS; Wed, 17 Sep 2025 18:58:55 +0000 (UTC) (envelope-from kp@FreeBSD.org) Received: by venus.codepro.be (Postfix, authenticated sender kp) id E6D313FFE9; Wed, 17 Sep 2025 20:58:52 +0200 (CEST) From: Kristof Provost To: Florian Smeets Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 9d9bc7f462bd - main - pf: set limits before rules Date: Wed, 17 Sep 2025 20:58:46 +0200 X-Mailer: MailMate (2.0r6272) Message-ID: In-Reply-To: <4fd761a0-b7ba-45b6-8e9e-e6b696a241a0@FreeBSD.org> References: <202509171415.58HEFh9g010282@gitrepo.freebsd.org> <4fd761a0-b7ba-45b6-8e9e-e6b696a241a0@FreeBSD.org> 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: multipart/alternative; boundary="=_MailMate_167B5297-EE7A-4906-AC78-1BE99182FDCB_=" --=_MailMate_167B5297-EE7A-4906-AC78-1BE99182FDCB_= Content-Type: text/plain; charset=UTF-8; format=flowed; markup=markdown Content-Transfer-Encoding: quoted-printable On 17 Sep 2025, at 20:38, Florian Smeets wrote: > On 17.09.25 16:15, Kristof Provost wrote: >> The branch main has been updated by kp: >> >> URL: = >> https://cgit.FreeBSD.org/src/commit/?id=3D9d9bc7f462bd152d87ab8f1767ca= d19bab09bf8b >> >> commit 9d9bc7f462bd152d87ab8f1767cad19bab09bf8b >> Author: Kristof Provost >> AuthorDate: 2025-08-25 13:43:10 +0000 >> Commit: Kristof Provost >> CommitDate: 2025-09-17 14:15:15 +0000 >> >> pf: set limits before rules >> > > Nice, I ran into this issue recently that the ruleset would not load = > on boot because we load large tables. > > I set a higher PFR_KENTRY_HIWAT as a workaround. > > Are you planning to merge this to stable/15? Maybe get this into 15.0? > I have no plans to MFC this, no. There=E2=80=99s a fairly large series of patches that to lesser or greate= r = extent build on each other making MFC-ing more effort and higher risk = than it=E2=80=99d otherwise be. I=E2=80=99m certainly not MFC-ing changes other than clear bug fixes to = stable/15 at this point in the release cycle. Colin doesn=E2=80=99t need = more = headaches. =E2=80=94 Kristof --=_MailMate_167B5297-EE7A-4906-AC78-1BE99182FDCB_= Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

On 17 Sep 2025, at 20:38, Florian Smeets wrote:

On 17.09.25 16:15, Kristof Provost wrote:

The branch main has been updated by kp:

URL: https://cgit.FreeBSD.org/src/co= mmit/?id=3D9d9bc7f462bd152d87ab8f1767cad19bab09bf8b

commit 9d9bc7f462bd152d87ab8f1767cad19bab09bf8b
Author: Kristof Provost kp@FreeBSD.= org
AuthorDate: 2025-08-25 13:43:10 +0000
Commit: Kristof Provost kp@FreeBSD.= org
CommitDate: 2025-09-17 14:15:15 +0000

 p=
f: set limits before rules

Nice, I ran into this issue recently that the ruleset wou= ld not load on boot because we load large tables.

I set a higher PFR_KENTRY_HIWAT as a workaround.

Are you planning to merge this to stable/15? Maybe get th= is into 15.0?

I have no plans to MFC this, no.

There=E2=80=99s a fairly large series of patches that to = lesser or greater extent build on each other making MFC-ing more effort a= nd higher risk than it=E2=80=99d otherwise be.
I=E2=80=99m certainly not MFC-ing changes other than clear bug fixes to s= table/15 at this point in the release cycle. Colin doesn=E2=80=99t need m= ore headaches.

=E2=80=94
Kristof

--=_MailMate_167B5297-EE7A-4906-AC78-1BE99182FDCB_=-- From nobody Wed Sep 17 19:34:17 2025 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 4cRpqZ0vsyz67wN9; Wed, 17 Sep 2025 19:34:18 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRpqY5spXz49rV; Wed, 17 Sep 2025 19:34:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137657; 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=y44u378TNKHeJ2JPpOV/sU6WrGWbBq3NHu+7DFQIZCI=; b=o5k1lH7Vd0eMOfdOMuKHk8+fsziDDrisMFKo0tlxI5RcrJm9xHFYm9E7DnHx4a+K0AXWtU pWrujPwfAMtOJHfetyla5Vq0ycwJmkObUZgtOLD2+4Y3Ck6xYqkS0Hh+YAy3Nev7p2XmEr vYpOS6g+xWTPxxWNaA6oRZ3t+3t70WJvGPWu+qB4VSevh///mql8gxJoNPTaOatGzu/LVI SgOvwPT9/PJN2/b53OM25ZO87Qt8l+ENFMKscbp4J12Y8JBTvE3YcwKvhNs+EIeiFYe5gU rCYV5W+QXV4OLe1rVC2QSDezkVVcosSyey1obG740BdKYNvVZVtnbdirAcpDAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137657; 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=y44u378TNKHeJ2JPpOV/sU6WrGWbBq3NHu+7DFQIZCI=; b=br7FGYwN3MViNzkkw36y7qyPq9RugissG+q9pUAp7G00IwkQ/hyqJKo/r8VTsIqPWut3mJ tVk62dWp1zaJS5qbJrEEJNlt8sf4NZBwVyctKpcaoT6boFLsIessDXp3jx+KAbovQkAbBf f9owietLTjme99DiFguowAqlNWy0zw9exJp9QWawYjEUV97h2Im0g0hw0GdELoKN3grIjT ZuAvSkkdiMt+3za+5XA+fULx4+L7O9oRdYNU8b9CPutThH5ZiGNTCiRM4P8sxTZ8H9HyTQ TaQaxYFBxaYmy3ug0eb5OUiQBzHYC0kQX3bzKRyJj+xs1RE/uOPMPEEf6b77GQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137657; a=rsa-sha256; cv=none; b=TPtxwibHwK1ZRWXxeb9GFRVf457ADXq7fJ4T52sBdN3faAedgm0q+mxLIXH53M86C0yTn3 gTsgCvdUdT8siyZNTsH+3WY1SXqCRL49aPZLyJ/AIbL1Ku1BgMO8NKGhWddNa061Hz7dj/ eCmgkOHi2lHKNesAaQCSlf4L8m2m/3rWtOKNbYYtIngC1IcBtM/Ux/a2azC5c+dcj9uMHF pcss6sU5tjzY22QAHuF2LimkTTL1MfAgTONIyxjd2qV2J8uIPR4HBSQNctVyy2FyC0V0qf umqoub+eSczs+itTVaexiVlkuqdRPhSewALlDaRxLa04wQw4VY+ojUafcy5MHQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRpqY59wfzg8M; Wed, 17 Sep 2025 19:34:17 +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 58HJYHxA014060; Wed, 17 Sep 2025 19:34:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJYHBH014057; Wed, 17 Sep 2025 19:34:17 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:34:17 GMT Message-Id: <202509171934.58HJYHBH014057@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 7a7f44d61815 - stable/15 - nuageinit: Remove duplicate description of users.{user}.groups 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 7a7f44d61815928be4103800de300dca07e0c4d7 Auto-Submitted: auto-generated The branch stable/15 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=7a7f44d61815928be4103800de300dca07e0c4d7 commit 7a7f44d61815928be4103800de300dca07e0c4d7 Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-09-11 16:47:07 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:33:56 +0000 nuageinit: Remove duplicate description of users.{user}.groups Reviewed by: bapt@ Approved by: bapt@ Differential Revision: https://reviews.freebsd.org/D52436 (cherry picked from commit 9f3330f5224ea2384a1c7d79a5b1f2784f7c14b6) --- libexec/nuageinit/nuageinit.7 | 2 -- 1 file changed, 2 deletions(-) diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index f27b8bc06042..bfa028fe3fa3 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -296,8 +296,6 @@ The encrypted password for the user. .It Ic plain_text_passwd The password in plain text for the user. Ignored if an encrypted password is already provided. -.It Ic groups -The list of other groups the user should belong to. .It Ic locked Boolean to determine if the user account should be locked. .It Ic sudo From nobody Wed Sep 17 19:34:18 2025 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 4cRpqb0GFKz67wll; Wed, 17 Sep 2025 19:34:19 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRpqZ64b4z49rX; Wed, 17 Sep 2025 19:34:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137658; 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=+cSwhbrh/try63qaLapVdRpTUVJYqh5RCRPapRXj9Ts=; b=nplBedDdnBv/YWWU4TcHGQcJ2ym+WJ1W5eNWuNU+VBdBvzZ54R23MmuNDfrap7Vqv/OjZV 5C+qCEU5qafEjnzEs8eays3ZVxn3EqvmQM1B7hgx5f0jrE5+gbMeBiJdb4sRnvasEr6bQ9 G5Tjghzhg9aabMfhfWXHOMnXA2fxYEMac0sd44T9W+4iYsvSwivPev4k5WiYk/qnV3tNGu G/nOZCTloT/c+nmqnfDv7nkpofpGUyyzZfBurFXn/eXdfjHlVxt5H1vlyBUUeXCn+r+BaL OBnaClzoMIHadz4jhA7uwFc4+h8FwtdE/FoEmJnfMTOvz7jS2SQvZCxmdjSCTw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137658; 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=+cSwhbrh/try63qaLapVdRpTUVJYqh5RCRPapRXj9Ts=; b=EfGNlI9OUml1ozjDYYGEMNTDc+1UqJpkO5R1Db41kf8fBfp/wK4eihspcLV9PaPpeO5PLT 8tYCIO5DwuIiIQPMD+tHmhHa3HPxhoCz0ucCn9PH8hDKNbsrBBY2Yilu5zSKC7OvcSg4l2 xWM+PPaIrzB2R+uSuulrkBDQtJ2RLw7jAGJgddTOCG57W7Yblj0YLeaf9DuwW8i9vKTE0w P/oB9AiIn5EnrDQpo6FbGr+MBTb+HE/lYdDvtlBBdma2QvBUBDDgJUvpFxlwo/vFkw3Y10 hm09W7/YeXahLYYVHKdGbkHDV61ySbKV+hcd0G3ltUbenwFvYgouwLsgng0RhQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137658; a=rsa-sha256; cv=none; b=gJZEjtHQEnG8hA2XeOo9FwlHDGAqx7MQNgjmRVj6TZxsu4ALcxENigWZszeX8dPc9EqIR0 b5fYlIJJZ9b+lR6EV+7rjxg9Z4PgSNqq9C3vWFN9P6jMb6esddialnIVtAxC7WolQ1Ijcf 8o08Wd8q+VZeUAbpX4fgecEus/erE8mU8SSJFkP0DU3qBZvYgZu1Ye7goj+MqGMzDy+8qd MOrvw6XIfakcy/ZuS5e/Rk2LVpogVFO7eomLxS1ot6HNt7YT7DzNxERQIJCqxbZ4WTXjn4 +LCydkQLISVt9jt+Yh7pZlL4ZAgHoqH8ffWNrej2wQMhxzwOgQfu75v8S/2gxg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRpqZ5Ymszgfw; Wed, 17 Sep 2025 19:34:18 +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 58HJYIqb014093; Wed, 17 Sep 2025 19:34:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJYIwY014090; Wed, 17 Sep 2025 19:34:18 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:34:18 GMT Message-Id: <202509171934.58HJYIwY014090@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: a00410fa19e9 - stable/15 - nuageinit: chmod sudoers directory instead of chmod (again) sudoers file 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: a00410fa19e987a47deac1a61c115549a90b6ea5 Auto-Submitted: auto-generated The branch stable/15 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=a00410fa19e987a47deac1a61c115549a90b6ea5 commit a00410fa19e987a47deac1a61c115549a90b6ea5 Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-09-11 16:49:56 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:33:56 +0000 nuageinit: chmod sudoers directory instead of chmod (again) sudoers file * Set mode of sudoers to 0440. Reviewed by: bapt@, jlduran@ Approved by: bapt@, jlduran@ Differential Revision: https://reviews.freebsd.org/D52438 (cherry picked from commit a5cc9b7b96dcba4d3ee98f2eb58c3f389590ddf0) --- libexec/nuageinit/nuage.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libexec/nuageinit/nuage.lua b/libexec/nuageinit/nuage.lua index 48f54b120615..22140dd06fe5 100644 --- a/libexec/nuageinit/nuage.lua +++ b/libexec/nuageinit/nuage.lua @@ -311,10 +311,10 @@ local function addsudo(pwd) end f:close() if chmodsudoers then - chmod(sudoers, "0640") + chmod(sudoers, "0440") end if chmodsudoersd then - chmod(sudoers, "0740") + chmod(sudoers_dir, "0750") end end From nobody Wed Sep 17 19:34:19 2025 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 4cRpqc2Ks4z67wnm; Wed, 17 Sep 2025 19:34:20 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRpqb6qzTz4BQb; Wed, 17 Sep 2025 19:34:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137660; 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=YloFoES+ZsXRCGKH9TLg8kjUT/AMlxxgiz11mcMvZLw=; b=TG4ttIarxLaLzL0nBMu6kvJfmC7YhwfwmTLm51l1X2kEo2pv5YsHYEgJMXPw6l1Mk7qycs Bx56VlC922ndeiKozC8jdjxbTME/uLNL5/o5bghy5Hn9aOWh6TSh9oKVP6X/unGSjvDtUu 46XHwlQTLnXQPbXbLa9Dq8w+SCIY05/y8PjTaCS6539kny98KeE2W+nJ1QAnxsNMet7DbJ 3PKBoJ7eNwbZ95qIhYip55pmTGU7ra0rYM3k46aeHbGNKkv5AWHiUjUZLUh/JPTqI4WTtE bCbnj7RE1/t2cK/H1alNGylmuDCkLv0oqWpcSFQG1VnolFoqZPtfUCra0/Oaew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137660; 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=YloFoES+ZsXRCGKH9TLg8kjUT/AMlxxgiz11mcMvZLw=; b=E6RhKcLGv89h4ckCjKVSvMlmuc919Y2rTexntHI9O3t+oIVgdkV2lOTI9fqO4iKosV4g5M KYorts1dcEe5LX7roiOknoGICBCESCN4ZkRvw32RotbocdKHZ156cUvM9KHNciycELGWqG Y1djKHeS/rO1SBC6BUMu9/yO5ddDx3kPe91GVNeLAVYTqLHC4AuM3tpgzxz6B0uSZepOmq gYlNvYzUfjasGA0bbJmA0iBTGYnpCubpLu5knS/K8QksCA2Ca8N6dEBa0bddLc1Qu4Iip1 GfBcl1fB+nBN7j/OucwKSk4rEaXNZH0dbqbJXjdONkYaxB+xAOMvtMbDgfc13g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137660; a=rsa-sha256; cv=none; b=Q0JJ9Fz0o/eu+/dGIdXBfdbajAS5W/EE4YGNMSXxly9Fd/wMyS+A7X5LMn/0RC1jYceKso eHRRx0ThLDsy/Ojuug4/jM+JXJsgKX+G+kZl33CtsHFhwRB2grpNlvHOxurAS16BBZ6SAM 9wKeh3khxnldG/jkmXA/2ULvJv5Cd9LCkHnZXrIinfwsDBywe+ZzRWicN1aT1TdaEPd9MR Iq/SeCQ3glLPCpWEVfEo2uiCxds/7kCYo6EFdGBJJc789gbOuGubRsd6PTNwgEaD64xDPG DDwLO1OnrG7JZ3wkbwpgLtCJmq5tQxBTck9SOwI6BC3+NmCuqu3m5SbhskRmiQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRpqb69r4zg3t; Wed, 17 Sep 2025 19:34:19 +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 58HJYJ6Z014132; Wed, 17 Sep 2025 19:34:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJYJD2014129; Wed, 17 Sep 2025 19:34:19 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:34:19 GMT Message-Id: <202509171934.58HJYJD2014129@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: dd293fbc084b - stable/15 - nuageinit: Add me to copyright list 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: dd293fbc084bca9cda1305ac0ae5a6a0d2dbd17a Auto-Submitted: auto-generated The branch stable/15 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=dd293fbc084bca9cda1305ac0ae5a6a0d2dbd17a commit dd293fbc084bca9cda1305ac0ae5a6a0d2dbd17a Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-09-11 17:00:41 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:33:57 +0000 nuageinit: Add me to copyright list Approved by: bapt@ (cherry picked from commit 18555060dcae4cad8f2f8968142fc02a2571377b) --- libexec/nuageinit/nuage.lua | 1 + libexec/nuageinit/nuageinit | 1 + libexec/nuageinit/nuageinit.7 | 1 + libexec/nuageinit/tests/nuage.sh | 1 + libexec/nuageinit/tests/nuageinit.sh | 1 + libexec/nuageinit/tests/utils.sh | 1 + 6 files changed, 6 insertions(+) diff --git a/libexec/nuageinit/nuage.lua b/libexec/nuageinit/nuage.lua index 22140dd06fe5..b042698f97e7 100644 --- a/libexec/nuageinit/nuage.lua +++ b/libexec/nuageinit/nuage.lua @@ -2,6 +2,7 @@ -- SPDX-License-Identifier: BSD-2-Clause -- -- Copyright(c) 2022-2025 Baptiste Daroussin +-- Copyright(c) 2025 Jesús Daniel Colmenares Oviedo local unistd = require("posix.unistd") local sys_stat = require("posix.sys.stat") diff --git a/libexec/nuageinit/nuageinit b/libexec/nuageinit/nuageinit index 70b27cb33d87..c94eb822ba0f 100755 --- a/libexec/nuageinit/nuageinit +++ b/libexec/nuageinit/nuageinit @@ -3,6 +3,7 @@ -- SPDX-License-Identifier: BSD-2-Clause-FreeBSD -- -- Copyright(c) 2022-2025 Baptiste Daroussin +-- Copyright(c) 2025 Jesús Daniel Colmenares Oviedo local nuage = require("nuage") local ucl = require("ucl") diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index bfa028fe3fa3..fd82eb84574d 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -1,6 +1,7 @@ .\" SPDX-License-Identifier: BSD-2-Clause .\" .\" Copyright (c) 2025 Baptiste Daroussin +.\" Copyright (c) 2025 Jesús Daniel Colmenares Oviedo .\" .Dd June 26, 2025 .Dt NUAGEINIT 7 diff --git a/libexec/nuageinit/tests/nuage.sh b/libexec/nuageinit/tests/nuage.sh index b709d25532ff..57d83b62928a 100644 --- a/libexec/nuageinit/tests/nuage.sh +++ b/libexec/nuageinit/tests/nuage.sh @@ -1,5 +1,6 @@ #- # Copyright (c) 2022-2025 Baptiste Daroussin +# Copyright (c) 2025 Jesús Daniel Colmenares Oviedo # # SPDX-License-Identifier: BSD-2-Clause # diff --git a/libexec/nuageinit/tests/nuageinit.sh b/libexec/nuageinit/tests/nuageinit.sh index 98593f7d75b0..619df019cc4f 100644 --- a/libexec/nuageinit/tests/nuageinit.sh +++ b/libexec/nuageinit/tests/nuageinit.sh @@ -1,5 +1,6 @@ #- # Copyright (c) 2022-2025 Baptiste Daroussin +# Copyright (c) 2025 Jesús Daniel Colmenares Oviedo # # SPDX-License-Identifier: BSD-2-Clause # diff --git a/libexec/nuageinit/tests/utils.sh b/libexec/nuageinit/tests/utils.sh index 26f117d81d60..76cd7e045473 100644 --- a/libexec/nuageinit/tests/utils.sh +++ b/libexec/nuageinit/tests/utils.sh @@ -1,5 +1,6 @@ #- # Copyright (c) 2022 Baptiste Daroussin +# Copyright (c) 2025 Jesús Daniel Colmenares Oviedo # # SPDX-License-Identifier: BSD-2-Clause # From nobody Wed Sep 17 19:34:20 2025 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 4cRpqd3lj1z67wk1; Wed, 17 Sep 2025 19:34:21 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRpqd22N2z4Bdh; Wed, 17 Sep 2025 19:34:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137661; 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=4/b6bLE/y3QPGegxu77yxJlwY3R1Feh3WKkFxoldIUs=; b=YWSFRcEaknHsimUUymosyvzOPZtBLDAk1qefyWL3Gsjbqcum9fTFgMm7HQ/7QTHreWrYIt U5hF8rs0ooMZzDqlhWDKbgA/4ltDvAeDJeWFcKxzJE+tBpyQ3kRPO5s2XLRz2AAIPvkHEE jt3PknDccOc2UbgjaApMDuSl+T83Zt/BSsmauzl3PuQaz2W4HRLSjep5vU5HOpWJYJYaTf UZv1NpE7HvdZekMcHTaRRmHQBU030IALc3zKSr0GXlhmrxfcG8CUWPfaaulhFmOgNGu5LG j7f/W1p/+yESua9JJxWhgHsCHzhalv5wBBOs1fU0Z4wtECpRR6/2EWG6Ph0Bng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137661; 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=4/b6bLE/y3QPGegxu77yxJlwY3R1Feh3WKkFxoldIUs=; b=wJa0ZfBnsMVUO31nClKKAvl34LdS9yDU7kZZ8JCWRcYBCTX6xSNi+u7T1PjXviO59eEJS2 OYtZyN4UAwgjTTbV32FZ05mKOod92n/6t0T9ExAtIun4g5s/kzuWdDmnQwtzWx2bUCFRzg luvcLyOs4GgW3y2KQfh/kx5hoziyESUzH2Os/AnFJNXU9kRTlSw++728TMqQ7x39MVSZCn 9H4GfMiy57guX0GlQ/Voiq2c2GrTxi2uyMafesQMsruABf0k8yUrFbjfnETt1FECyOqftI nlfUDcqi7Smq761CmCZm7KxyPZHG2JNiD02KGQEgxfM5ue9bZLC3HXy6SIiPGg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137661; a=rsa-sha256; cv=none; b=dLOsRP8IZoEEfnuXo1Uabh3rTh75RdKLqH1M9hVn+Edc4gLiPbedT7hcifJX1gPZftUxz6 eKVzS7kBGzEeBeSpTcZrvyzwCIe+Pcumhw5AwxX+hlfGLSUu33nO0E0LWyX4mk0iyKZ40a VM77XGjRQo4+kIWry+luMybe5vTrOKU2RMTNUcojPH+HpWzsO2vevWHSngoCDOE6rwsxmo SeN8x5e0GPPbJ0s6IPxChKI+qVlKvvGmPbIEfkews2R3jKZKOEDR9IjDN+5xEWLMyf05/s o7oSQwL9iL0X/1LmDGIGy3CY1qF6DvUYES3Cg3uMX8usE4+uwr7Ic6JaJO0T8w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRpqd00tVzg3v; Wed, 17 Sep 2025 19:34:21 +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 58HJYKE9014168; Wed, 17 Sep 2025 19:34:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJYKqw014165; Wed, 17 Sep 2025 19:34:20 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:34:20 GMT Message-Id: <202509171934.58HJYKqw014165@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 4a01ddbcd66e - stable/15 - nuageinit: Allow the use of network parameters from network-config 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 4a01ddbcd66eeabd821e6cfba45f9f2825450ef2 Auto-Submitted: auto-generated The branch stable/15 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=4a01ddbcd66eeabd821e6cfba45f9f2825450ef2 commit 4a01ddbcd66eeabd821e6cfba45f9f2825450ef2 Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-09-11 16:52:30 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:33:57 +0000 nuageinit: Allow the use of network parameters from network-config To better comply with the cloud-init specification, we need to support the configuration of network-related parameters from the network-config file, which is common in most deployments. Reviewed by: bapt@ Approved by: bapt@ Differential Revision: https://reviews.freebsd.org/D52419 (cherry picked from commit 95230b248f6412c2d1c416c1e9795c3192cdf750) --- libexec/nuageinit/nuageinit | 31 ++++++++++++++++++++++++++++++- libexec/nuageinit/nuageinit.7 | 7 +++++++ 2 files changed, 37 insertions(+), 1 deletion(-) diff --git a/libexec/nuageinit/nuageinit b/libexec/nuageinit/nuageinit index c94eb822ba0f..5541f6d0f164 100755 --- a/libexec/nuageinit/nuageinit +++ b/libexec/nuageinit/nuageinit @@ -583,6 +583,26 @@ local function config2_network(p) routing:close() end +local function parse_network_config() + local nc_file = ni_path .. "/network-config" + local nc_file_attr = lfs.attributes(nc_file) + if nc_file_attr == nil then + return + end + local f, err = io.open(nc_file) + if err then + nuage.err("error parsing nocloud network-config: " .. err) + end + local obj = yaml.load(f:read("*a")) + f:close() + if not obj then + nuage.err("error parsing nocloud network-config") + end + local netobj = {} + netobj["network"] = obj + return netobj +end + if citype == "config-2" then local parser = ucl.parser() local res, err = parser:parse_file(ni_path .. "/meta_data.json") @@ -679,7 +699,16 @@ if line == "#cloud-config" then end for i = 1, #calls_table do - calls_table[i](obj) + if citype == "nocloud" and calls_table[i] == network_config then + netobj = parse_network_config() + if netobj == nil then + network_config(obj) + else + network_config(netobj) + end + else + calls_table[i](obj) + end end elseif line:sub(1, 2) == "#!" then -- delay for execution at rc.local time -- diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index fd82eb84574d..e5da5cf342e1 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -183,6 +183,13 @@ configuration in .Pa /etc/ssh/sshd_config .It Ic network Network configuration parameters. +.Pp +Specifying the following parameters from a file named +.Pa network-config +takes precedence over their specification from the +.Ic network +parameter of +.Pa user-data Ns . .Bl -tag -width "ethernets" .It Ic ethernets Mapping representing a generic configuration for existing network interfaces. From nobody Wed Sep 17 19:34:21 2025 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 4cRpqf4jpBz67wnq; Wed, 17 Sep 2025 19:34:22 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRpqf16pTz4B7r; Wed, 17 Sep 2025 19:34:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137662; 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=uZBXQzqk0Vh2cA6bpxsm9MyUDqBv614P+Kd4077wx7Y=; b=vc4BYlVUx/TjLmUZNttYe6jvcZeUh7sjqciAQyRU4EOhim+JnHfvlbB7mcYWdhFu55J5i4 dplL353/WXC2ntn+rXl1meMaZWker1ZJeL60b7kIMhkocDxL1CqAXCPEt3vDiQw1Z5HMzl OREt9ANXikyo97meVjIiabv6iYrvocUO9Ce16LOqKCTD2bI4xAEsuuUDTjVn3XWNK6HHdv kUoHLcsbMksjyB5v+XtNxjAMX0XM2NmcwnoWAl0Ktj9zmLRN/wx3EbCEywL+xo4NIjzum+ CtKL2uPyhW3P777ypP7LksUnb5wqH3XsBZlrb9eQNPcpDo2c83/Z7b7wmcfLwg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137662; 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=uZBXQzqk0Vh2cA6bpxsm9MyUDqBv614P+Kd4077wx7Y=; b=nVYb7+jfFBA1dToGNWn8PH+1aNvySws3CdrI2HHfEKB/Q8WiLNmmJ6m/8rKYNI577j4mND XoC93IXSn98e1Y6h9xQMB3vR7p0AbB+lvxPn1UcNBEZ8B/gUjz1TFeFRDfe/hsKrrS6msj Q8OmO7EsMniR7GZSyffMNV5hMfmATRF1gMzs0XpdRhoBbVErZIwQTQ9qEuC7vDQQQFIDQZ z8EJJ9krAhGYogAOiI7OS4abQeUbt2YZsBuGX0N0WPhKBL7POC4ynfkQ+lRGlrCDDtWG+J Jsiz1YUuXdHn3rjiKtPOiw2gsWWl+EhFakFwQ0E5EaUtWf6E5fZpoEAURcvy3A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137662; a=rsa-sha256; cv=none; b=lb/JvE3bmGrzrqDjcheoJuj/Pup5OTbkEvK1MHIzOhB1NcsDc7PA7DJ/f9EwgEY4kZWK6c aaV/LweUfz3XyQ9yNNj7eOeCQkFnz2heQ0oFTp784P+yNYcjBs8+L+kLKWuhgvtV67cYcW qd8M39gAyctoZEFTMaA2SE/pQhM5f5HGWlSgtcep1jFL19Nk80RT/mJAVg+rRjOPgqVOZP A6VHksM6F66R6UBLFNMQIOJOamwd0XuD2mIm1fNIgUySlNFFPKMKh/KyKkBqV3WpC76LeI lrHHnVubNEa5QWwAfadApo6kmXJIySBugGtQvJCxzdlVx/tHkbejb2OrEMRI9g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRpqf0ZrDzgQX; Wed, 17 Sep 2025 19:34:22 +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 58HJYLJT014202; Wed, 17 Sep 2025 19:34:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJYLfV014199; Wed, 17 Sep 2025 19:34:21 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:34:21 GMT Message-Id: <202509171934.58HJYLfV014199@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 24e5700d4707 - stable/15 - nuageinit: Add doas support 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 24e5700d470718f5c729cc69a62d67bd1ca8a8f4 Auto-Submitted: auto-generated The branch stable/15 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=24e5700d470718f5c729cc69a62d67bd1ca8a8f4 commit 24e5700d470718f5c729cc69a62d67bd1ca8a8f4 Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-09-11 16:54:24 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:33:57 +0000 nuageinit: Add doas support * Set mode of etc directory to 0755. * Use user.localbase sysctl instead of /usr/local. * Add test case for doas. * Set ${LOCALBASE} instead of /usr/local in nuageinit(7) man page. Reviewed by: bapt@ Approved by: bapt@ Differential Revision: https://reviews.freebsd.org/D52437 (cherry picked from commit 9a829e865697e623a046800545be7781a117125e) --- libexec/nuageinit/nuage.lua | 62 +++++++++++++++++++++++++++++++++++- libexec/nuageinit/nuageinit | 3 ++ libexec/nuageinit/nuageinit.7 | 9 +++++- libexec/nuageinit/tests/nuageinit.sh | 12 ++++++- 4 files changed, 83 insertions(+), 3 deletions(-) diff --git a/libexec/nuageinit/nuage.lua b/libexec/nuageinit/nuage.lua index b042698f97e7..ef3cfd994fe1 100644 --- a/libexec/nuageinit/nuage.lua +++ b/libexec/nuageinit/nuage.lua @@ -8,6 +8,17 @@ local unistd = require("posix.unistd") local sys_stat = require("posix.sys.stat") local lfs = require("lfs") +local function getlocalbase() + local f = io.popen("sysctl -in user.localbase 2> /dev/null") + local localbase = f:read("*l") + f:close() + if localbase == nil or localbase:len() == 0 then + -- fallback + localbase = "/usr/local" + end + return localbase +end + local function decode_base64(input) local b = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' input = string.gsub(input, '[^'..b..'=]', '') @@ -277,11 +288,59 @@ local function addsshkey(homedir, key) end end +local function adddoas(pwd) + local chmodetcdir = false + local chmoddoasconf = false + local root = os.getenv("NUAGE_FAKE_ROOTDIR") + local localbase = getlocalbase() + local etcdir = localbase .. "/etc" + if root then + etcdir= root .. etcdir + end + local doasconf = etcdir .. "/doas.conf" + local doasconf_attr = lfs.attributes(doasconf) + if doasconf_attr == nil then + chmoddoasconf = true + local dirattrs = lfs.attributes(etcdir) + if dirattrs == nil then + local r, err = mkdir_p(etcdir) + if not r then + return nil, err .. " (creating " .. etcdir .. ")" + end + chmodetcdir = true + end + end + local f = io.open(doasconf, "a") + if not f then + warnmsg("impossible to open " .. doasconf) + return + end + if type(pwd.doas) == "string" then + local rule = pwd.doas + rule = rule:gsub("%%u", pwd.name) + f:write(rule .. "\n") + elseif type(pwd.doas) == "table" then + for _, str in ipairs(pwd.doas) do + local rule = str + rule = rule:gsub("%%u", pwd.name) + f:write(rule .. "\n") + end + end + f:close() + if chmoddoasconf then + chmod(doasconf, "0640") + end + if chmodetcdir then + chmod(etcdir, "0755") + end +end + local function addsudo(pwd) local chmodsudoersd = false local chmodsudoers = false local root = os.getenv("NUAGE_FAKE_ROOTDIR") - local sudoers_dir = "/usr/local/etc/sudoers.d" + local localbase = getlocalbase() + local sudoers_dir = localbase .. "/etc/sudoers.d" if root then sudoers_dir= root .. sudoers_dir end @@ -585,6 +644,7 @@ local n = { update_packages = update_packages, upgrade_packages = upgrade_packages, addsudo = addsudo, + adddoas = adddoas, addfile = addfile } diff --git a/libexec/nuageinit/nuageinit b/libexec/nuageinit/nuageinit index 5541f6d0f164..29340a3d91ea 100755 --- a/libexec/nuageinit/nuageinit +++ b/libexec/nuageinit/nuageinit @@ -140,6 +140,9 @@ local function users(obj) if u.sudo then nuage.addsudo(u) end + if u.doas then + nuage.adddoas(u) + end else nuage.warn("invalid type : " .. type(u) .. " for users entry number " .. n) end diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index e5da5cf342e1..b527c984970c 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -308,7 +308,14 @@ Ignored if an encrypted password is already provided. Boolean to determine if the user account should be locked. .It Ic sudo A string or an array of strings which should be appended to -.Pa /usr/local/etc/sudoers.d/90-nuageinit-users +.Pa ${LOCALBASE}/etc/sudoers.d/90-nuageinit-users +.It Ic doas +A string or an array of strings which should be appended to +.Pa ${LOCALBASE}/etc/doas.conf +.Pp +Instead of hardcoding the username, you can use +.Sy %u Ns , +which will be replaced by the current username. .El .Pp A special case exist: if the entry is a simple string with the value diff --git a/libexec/nuageinit/tests/nuageinit.sh b/libexec/nuageinit/tests/nuageinit.sh index 619df019cc4f..2b7c5226c97a 100644 --- a/libexec/nuageinit/tests/nuageinit.sh +++ b/libexec/nuageinit/tests/nuageinit.sh @@ -120,12 +120,16 @@ users: gecos: Foo B. Bar primary_group: foobar sudo: ALL=(ALL) NOPASSWD:ALL + doas: permit persist %u as root groups: users passwd: $6$j212wezy$7H/1LT4f9/N3wpgNunhsIqtMj62OKiS3nyNwuizouQc3u7MbYCarYeAHWYPYb2FT.lbioDm2RrkJPb9BZMN1O/ - name: bla sudo: - "ALL=(ALL) NOPASSWD:/usr/sbin/pw" - "ALL=(ALL) ALL" + doas: + - "deny %u as foobar" + - "permit persist %u as root cmd whoami" EOF atf_check /usr/libexec/nuageinit "${PWD}"/media/nuageinit nocloud atf_check /usr/libexec/nuageinit "${PWD}"/media/nuageinit postnet @@ -148,7 +152,13 @@ EOF sed -i "" "s/freebsd:.*:1001/freebsd:freebsd:1001/" "${PWD}"/etc/master.passwd atf_check -o file:expectedpasswd cat "${PWD}"/etc/master.passwd atf_check -o file:expectedgroup cat "${PWD}"/etc/group - atf_check -o inline:"foobar ALL=(ALL) NOPASSWD:ALL\nbla ALL=(ALL) NOPASSWD:/usr/sbin/pw\nbla ALL=(ALL) ALL\n" cat ${PWD}/usr/local/etc/sudoers.d/90-nuageinit-users + localbase=`sysctl -ni user.localbase 2> /dev/null` + if [ -z "${localbase}" ]; then + # fallback + localbase="/usr/local" + fi + atf_check -o inline:"foobar ALL=(ALL) NOPASSWD:ALL\nbla ALL=(ALL) NOPASSWD:/usr/sbin/pw\nbla ALL=(ALL) ALL\n" cat "${PWD}/${localbase}/etc/sudoers.d/90-nuageinit-users" + atf_check -o inline:"permit persist foobar as root\ndeny bla as foobar\npermit persist bla as root cmd whoami\n" cat "${PWD}/${localbase}/etc/doas.conf" } nocloud_network_head() From nobody Wed Sep 17 19:35:00 2025 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 4cRprP1d8jz67wtN; Wed, 17 Sep 2025 19:35: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRprN6fQrz4DFd; Wed, 17 Sep 2025 19:35:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137700; 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=drPHsTUoFf/G2LHXhSS4RWuyT6f26z2jVXWJ1JHgPfc=; b=C4wrPPD+gAp+Xmj9foK58sAIq3MgxjyNDaEeptlfIEpNSxABY7ZRLOalEtvK0cDT8vHbIp pEB6+hsPeEaJg2I97FsNMyQuief+4hzWWpVW/RuThnNnCSJ3DlLYs+TfOadUX58Ep9epac iu0f4LFzSRnT8SQB+4x8QJFUqqExKzfr1fmxky/+Zl7sVA1NPae/XszfEx8fdEFsHCbBIa NKLbxzgRDNOJJeUW5P/jjkyrvD5cO6/CzgKYs7jo6Lxc2vBP13StS/+hFMKiQhMNmzymWZ 7uVjKscJiYEbdzeYmJSlec4YiPk19wCG/loNMiTL/khAvLr2UjM1sdu33V5XoQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137700; 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=drPHsTUoFf/G2LHXhSS4RWuyT6f26z2jVXWJ1JHgPfc=; b=XF2bET3m3SK2bBe4CBIUGiDVeHqxQ0QZT95P0HQcclNdGkbaq/SUPDf70GFEtiQBOnY9x9 OLTnU5uzpSR62DDQzt5O9rDap4vL068IIFW/misvPp0OP4UnGD5wfHKOYkcZxCxKG6JnLU w/ZVbR9WkOrodnUirWUtIqamJGAAyl2vj8fKcM3DezH/ldCYA3Ou4W5b5BMMyCUZpsVIXc vMh+BT/qQZnUn9oAF/SNITio1iUZjNu7AWtTJphpISy2qyNl0E7KmBtnL99g4zIpnCSkvn /Ejblq8xp0gUJWtk8ouQetbHXnVn7ySRkZndG72wJ+NeqR6ttC2Bb6ADCQYxrA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137700; a=rsa-sha256; cv=none; b=EgHoZOYwAZ3h3EbqP0UgmcdrJYlj9QpnTaup3HywTwwqfeSZ3H+QBwJYHXAEn/AJAH6sv6 O+/JtCrwsZ1K4MQeS/Afo2qOSq3qRxeGFVQOQgA4GYVzZ7vqA0vQK84FBGWcYe0XO3Awf7 hsu4iRgNvFwFEn6imUkGgLvfCv1yFXZs2ZgZF27/hIkDVZMYBhWvk7H5Z1JvbNCgVVN6Ms P3+1VPGeFU2txkx6mtQOV96PgEYOYqCHH/cYWrRXX6woX5Vz5X6LQhel8AIxtpKfGV1L4B f30Puzk7x48FSIYDjbbIGWDI9gBZxny++nNwiRS0Uzid1fn3YcWxh8qXRlt7Cw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRprN6FD1zg3w; Wed, 17 Sep 2025 19:35:00 +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 58HJZ0e2014576; Wed, 17 Sep 2025 19:35:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJZ0PZ014573; Wed, 17 Sep 2025 19:35:00 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:35:00 GMT Message-Id: <202509171935.58HJZ0PZ014573@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: ab41f840e701 - stable/15 - pkg(7): Add support for pkg+ prefix to bootstrap pubkey 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: ab41f840e701caa4557166bd466396062adc2e88 Auto-Submitted: auto-generated The branch stable/15 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=ab41f840e701caa4557166bd466396062adc2e88 commit ab41f840e701caa4557166bd466396062adc2e88 Author: Seyed Pouria Mousavizadeh Tehrani AuthorDate: 2025-09-11 07:01:54 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:34:46 +0000 pkg(7): Add support for pkg+ prefix to bootstrap pubkey MFC After: 1 day Sponsored by: Amn Afzar Hoopad Inc Differencial Revision: https://reviews.freebsd.org/D52418 (cherry picked from commit 08b8843137b8be3f71608400907cb38bcda14965) --- usr.sbin/pkg/pkg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/pkg/pkg.c b/usr.sbin/pkg/pkg.c index 7899fbaeaf09..7b0a67e69a4c 100644 --- a/usr.sbin/pkg/pkg.c +++ b/usr.sbin/pkg/pkg.c @@ -889,7 +889,7 @@ bootstrap_pkg(bool force, const char *fetchOpts, struct repository *repo) getenv("TMPDIR") ? getenv("TMPDIR") : _PATH_TMP, bootstrap_name); snprintf(url, MAXPATHLEN, "%s/Latest/%s.pubkeysig", - repo->url, bootstrap_name); + packagesite, bootstrap_name); if ((fd_sig = fetch_to_fd(repo, url, tmpsig, fetchOpts)) == -1) { fprintf(stderr, "Signature for pkg not " From nobody Wed Sep 17 19:35:01 2025 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 4cRprQ2sFDz67wrN; Wed, 17 Sep 2025 19:35:02 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRprQ0fyXz4D6K; Wed, 17 Sep 2025 19:35:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137702; 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=sax5acQ9RE6ES2G35Wv9pOUufojtN3FzWLpIqtk8JAo=; b=uz1hMGv99CfF42CSIoIbfeaelwvjt8FnO7DFRMVLLB84vD90Br3a3az8blKalVYOsHRGJX +/Ed3bwm5+e9C/siwEdU1pqEPz46xHBmpAS8DGswIGQFaiJ0pBJu8treYZDUvA7FqF/nPj ABGJprgi+Z39dnzxTvEG61/9O+DIZNY5rMMbWRprQQK+KTxJZd8Kxj5BA8KDv8ed2ZSM9f pKVG+sJ0Z2WQrLybAeVib9lovjYp7X9CvezL274+4kLkZDJYEO48mA1XevDeZbe97uMp+5 XpqwBEy6Fl4RwooYvgFhag1zSM2fy1hQy2JV1YBuO3GIRLo14TMcl4Akl14kXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137702; 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=sax5acQ9RE6ES2G35Wv9pOUufojtN3FzWLpIqtk8JAo=; b=R84z5ThPB3EFv7qTWJRfD57cqPh9/UV2ywq1+kMeBMsd5buR5mGgbybXnh7bS+KmIoxZRA xZ6kH5B7mQU63GGjPcfwinpJ6ckH0hWTiRbArl+lTdkLZcMmR8ahsHjapRC1TX3P2xElq+ 8lT0ZfHSmNlnZhBTNXRKCvRL7Fyhbladg+ylVsUyknWlTAVTs3wMQuACggLbaURxhkmDeE IOvEPdmHpKLGv39eB/O6ovlqdLx07mBK3iyBQS1j2Sl2sim0hzNBK3Qeoi6CdcPVN7hdis 81cimHFehirIekS5UAk6dD3j9QIe3Yvp1QU1rY+QtydfjtEyorJ4PQ3MQhNEoQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137702; a=rsa-sha256; cv=none; b=V5fAYXQvS4nLpdhWLnci4H8LHTBg0lsBZnlryIl8qez/pZ9movS2b4cuxd7nE8j1camQBB NDaOSwOpQoDJiJW/ucBFDdgtkDbjO5npA7f6RAEn0aJBRV/cPYOtKSfw04oJkhsMYfit8Y nvQyxRvLTfp+kptkGa80vOQ37LEJn+LPIVZg1pFQZD8QP28WouwNqHhDshcO+qqDHUYZ7L QwrL5X/x++9OqNsmBozXYypWmdKfM42D8UWNAKzu2Okt/m/M73Zf+iYegHI7B60yiQKHJz kGM2aDLSfx0IlsbZvWW68jh71oPS4bb3r33zsOPjGF3gPZnB35OFN8DMSJ/Edg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRprQ0Czpzg3x; Wed, 17 Sep 2025 19:35:02 +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 58HJZ18E014614; Wed, 17 Sep 2025 19:35:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJZ1eI014611; Wed, 17 Sep 2025 19:35:01 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:35:01 GMT Message-Id: <202509171935.58HJZ1eI014611@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: c3f0a93e70c6 - stable/15 - pci_vendors: update to 2025-07-11 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: c3f0a93e70c6011015c6ebe5ddf1c99de57392e3 Auto-Submitted: auto-generated The branch stable/15 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=c3f0a93e70c6011015c6ebe5ddf1c99de57392e3 commit c3f0a93e70c6011015c6ebe5ddf1c99de57392e3 Author: Baptiste Daroussin AuthorDate: 2025-09-11 07:53:32 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:34:47 +0000 pci_vendors: update to 2025-07-11 (cherry picked from commit 2e72bd422956f831ec7e54255bd12fb721887f4a) --- share/misc/pci_vendors | 1005 +++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 914 insertions(+), 91 deletions(-) diff --git a/share/misc/pci_vendors b/share/misc/pci_vendors index 6dfe12dfc8ad..6fb8865340a0 100644 --- a/share/misc/pci_vendors +++ b/share/misc/pci_vendors @@ -1,8 +1,8 @@ # # List of PCI ID's # -# Version: 2025.03.09 -# Date: 2025-03-09 03:15:02 +# Version: 2025.07.11 +# Date: 2025-07-11 03:15:02 # # Maintained by Albert Pool, Martin Mares, and other volunteers from # the PCI ID Project at https://pci-ids.ucw.cz/. @@ -114,6 +114,8 @@ 0b70 NVMe DC SSD [Yorktown controller] 2b59 NVMe DC SSD [Atomos Prime] 025e 0008 NVMe DC SSD U.2-SFF 15mm [D7-PS1010] + 025e 000c NVMe DC SSD E1.S 9.5mm [D7-PS1010] + 025e 000d NVMe DC SSD E1.S 15mm [D7-PS1010] 025e 0019 NVMe DC SSD E3.S-1T 7.5mm [D7-PS1010] 025e 0108 NVMe DC SSD U.2-SFF 15mm [D7-PS1030] 025e 0119 NVMe DC SSD E3.S-1T 7.5mm [D7-PS1030] @@ -154,6 +156,14 @@ 0202 GP202 0721 Sapphire, Inc. 0731 Jingjia Microelectronics Co Ltd + 1100 JM1100 + 0731 1101 JM1100-C + 0731 1102 JM1100-II + 0731 1103 JM1100-I + 0731 1104 JM1100-M + 0731 1105 JM1100-Y + 0731 1106 JM1100-EI + 0731 1107 JM1100-EM 7200 JM7200 Series GPU 0731 7201 JM7201 0731 7202 JM7202 @@ -191,6 +201,9 @@ 0731 930b JH930-M 0731 930c JH930 930b JH930-M + f011 JM1100-IV + f111 JM1100-MV + ff11 JM1100-YV 0777 Ubiquiti Networks, Inc. 0795 Wired Inc. 6663 Butane II (MPEG2 encoder board) @@ -642,7 +655,7 @@ 1bd4 000e 6G SAS2008IR 1bd4 000f 6G SAS2008IT SA5248 1bd4 0010 6G SAS2008IR SA5248 - 4c52 96c8 LRSA96C8 8-Port SATA3(6Gb/s)Exchange Adapter (with Raid) + 4c52 96c8 LRSA96C8 8-Port SATA3 (6Gb/s) Exchange Adapter (with RAID) 8086 350f RMS2LL040 RAID Controller 8086 3700 SSD 910 Series 0073 MegaRAID SAS 2008 [Falcon] @@ -775,6 +788,9 @@ 1000 30a0 SAS9300-8e 1000 30e0 SAS9300-8i 1000 3130 SAS 9300-16i + 1000 3170 SAS9302-16e +# IBM SAS3008 HBA controller + 1014 0457 9302-8i [N2215] 1028 1f45 HBA330 Adapter 1028 1f46 12Gbps HBA 1028 1f53 HBA330 Mini @@ -869,6 +885,9 @@ 1000 5030 eHBA 9700-16e 24G SAS/PCIe Storage Adapter 1028 22d2 PERC H975i Front 1028 22d3 PERC H975i Adapter + 1028 23cb PERC H975i Front + 1028 23cd PERC H975i Adapter + 1028 2446 PERC H976i Front 1d49 020b ThinkSystem 460-16e SAS/SATA PCIe Gen5 24Gb HBA 00b5 Fusion-MPT 24G SAS/PCIe SAS50xx/SAS51xx # 9760W 32 internal port RAID controller @@ -883,6 +902,11 @@ 1000 5021 eHBA 9700W-16i 24G SAS/PCIe Storage Adapter # 9700 16 external port Storage controller 1000 5030 eHBA 9700-16e 24G SAS/PCIe Storage Adapter + 1028 22d2 PERC H975i Front - Virtual + 1028 22d3 PERC H975i Adapter - Virtual + 1028 23cb PERC H975i Front - Virtual + 1028 23cd PERC H975i Adapter - Virtual + 1028 2446 PERC H976i Front - Virtual # Broadcom next-gen MPT PCIe switch 00b8 Fusion-MPT Switch SAS50xx/SAS51xx 00be SAS3504 Fusion-MPT Tri-Mode RAID On Chip (ROC) @@ -1293,12 +1317,12 @@ 15ff Fenghuang [Zhongshan Subor Z+] 1607 Arden 1636 Renoir [Radeon Vega Series / Radeon Vega Mobile Series] - 1637 Renoir Radeon High Definition Audio Controller + 1637 Renoir/Cezanne HDMI/DP Audio Controller 1638 Cezanne [Radeon Vega Series / Radeon Vega Mobile Series] 1043 16c2 Radeon Vega 8 # Used in the Steam Deck LCD 163f VanGogh [AMD Custom GPU 0405] - 1640 Rembrandt Radeon High Definition Audio Controller + 1640 Radeon High Definition Audio Controller [Rembrandt/Strix] 164c Lucienne 164d Rembrandt 164e Raphael @@ -1306,8 +1330,9 @@ 1681 Rembrandt [Radeon 680M] 1714 BeaverCreek HDMI Audio [Radeon HD 6500D and 6400G-6600G series] 103c 168b ProBook 4535s - 1900 Phoenix3 - 1901 Phoenix4 + 1900 HawkPoint1 + 1901 HawkPoint2 + 1902 Krackan2 3150 RV380/M24 [Mobility Radeon X600] 103c 0934 nx8220 3151 RV380 GL [FireMV 2400] @@ -3054,6 +3079,7 @@ 1458 22ed Radeon RX 560 148c 2381 Radeon RX 560 1682 9560 Radeon RX 560 + 1849 5037 PHANTOM G R RX550 2G/M/ASRK 1da2 e348 Radeon RX 560 1da2 e367 Radeon RX 550 640SP 6800 Wimbledon XT [Radeon HD 7970M] @@ -3284,6 +3310,7 @@ 1002 6b76 AMD Radeon RX Vega 56 8GB # ROG-STRIX-RXVEGA64-O8G-GAMING 1043 04c4 Radeon RX Vega 64 + 1043 0555 ROG STRIX RX Vega 56 8GB 1458 230c Radeon RX VEGA 56 GAMING OC 8G 1da2 e376 Radeon RX VEGA 56 Pulse 8GB OC HBM2 6880 Lexington [Radeon HD 6550M] @@ -3993,6 +4020,7 @@ 1da2 e410 Sapphire NITRO+ RX 5700 XT 1da2 e411 Navi 10 [Radeon RX 5600 OEM/5600 XT / 5700/5700 XT]Navi 10 [Radeon RX 5600 OEM/5600 XT / 5700/5700 XT] 7340 Navi 14 [Radeon RX 5500/5500M / Pro 5500M] + 106b 0210 Radeon Pro 5300M 7341 Navi 14 [Radeon Pro W5500] 7347 Navi 14 [Radeon Pro W5500M] 734f Navi 14 [Radeon Pro W5300M] @@ -4085,6 +4113,7 @@ 7461 Navi 32 [AMD Radeon PRO V710] 7470 Navi 32 [Radeon PRO W7700] 747e Navi 32 [Radeon RX 7700 XT / 7800 XT] + 148c 2427 RX 7800 XT [Hellhound / Red Devil] 7480 Navi 33 [Radeon RX 7600/7600 XT/7600M XT/7600S/7700S / PRO W7600] 1849 5313 RX 7600 Challenger OC 7481 Navi 33 [Radeon Graphics] @@ -4093,14 +4122,20 @@ 7489 Navi 33 [Radeon Pro W7500] 748b Navi 33 [Radeon Graphics] 7499 Navi 33 [Radeon RX 7400/7300/Pro W7400] + 749f Navi 33 [Radeon RX 7500] 74a0 Aqua Vanjaram [Instinct MI300A] 74a1 Aqua Vanjaram [Instinct MI300X] 74a2 Aqua Vanjaram [Instinct MI308X] 74a5 Aqua Vanjaram [Instinct MI325X] 74a9 Aqua Vanjaram [Instinct MI300X HF] 74b5 Aqua Vanjaram [Instinct MI300X VF] + 74b9 Aqua Vanjaram [Instinct MI325X VF] 74bd Aqua Vanjaram [Instinct MI300X HF] - 7550 Navi 48 [RX 9070/9070 XT] + 7550 Navi 48 [Radeon RX 9070/9070 XT/9070 GRE] + 148c 2435 Reaper Radeon RX 9070 XT 16GB GDDR6 (RX9070XT 16G-A) + 1da2 e490 Navi 48 XTX [Sapphire Pulse Radeon RX 9070 XT] + 7551 Navi 48 [Radeon AI PRO R9700] + 7590 Navi 44 [Radeon RX 9060 XT] 7833 RS350 Host Bridge 7834 RS350 [Radeon 9100 PRO/XT IGP] 7835 RS350M [Mobility Radeon 9000 IGP] @@ -4505,6 +4540,7 @@ ab28 Navi 21/23 HDMI/DP Audio Controller ab30 Navi 31 HDMI/DP Audio ab38 Navi 10 HDMI Audio + ab40 Navi 48 HDMI/DP Audio Controller ac00 Theater 506 World-Wide Analog Decoder ac01 Theater 506 World-Wide Analog Decoder ac02 TV Wonder HD 600 PCIe @@ -4948,6 +4984,7 @@ 1014 04fc PCIe3 x8 12Gb Quad SAS RAID+ Adapter(580A) 04ed Internal Shared Memory (ISM) virtual PCI device 0611 4769 Cryptographic Adapter + 06a2 4770 Cryptographic Adapter 06a7 Spyre Accelerator 06a8 Spyre Accelerator Virtual Function 3022 QLA3022 Network Adapter @@ -5295,6 +5332,8 @@ 1514 Family 14h Processor Root Port 1515 Family 14h Processor Root Port 1516 Family 14h Processor Root Port + 151c USB4 Router 0 + 151d USB4 Router 1 1530 Family 16h Processor Function 0 1531 Family 16h Processor Function 1 1532 Family 16h Processor Function 2 @@ -5364,6 +5403,12 @@ 1583 Family 16h (Models 30h-3fh) Processor Function 3 1584 Family 16h (Models 30h-3fh) Processor Function 4 1585 Family 16h (Models 30h-3fh) Processor Function 5 + 1587 Strix Halo USB 3.1 xHCI + 1588 Strix Halo USB 3.1 xHCI + 1589 Strix Halo USB 3.1 xHCI + 158b Strix Halo USB 3.1 xHCI + 158d Strix Halo USB4 Host Router + 158e Strix Halo USB4 Host Router 1590 Amur/Nolan HT Configuration 1591 Amur/Nolan Address Maps 1592 Amur/Nolan DRAM Configuration @@ -5410,7 +5455,7 @@ 15dc Raven/Raven2 Internal PCIe GPP Bridge 0 to Bus B ea50 ce19 mCOM10-L1900 15de Raven/Raven2/FireFlight HD Audio Controller - 15df Family 17h (Models 10h-1fh) Platform Security Processor + 15df Raven/Raven2/FireFlight/Renoir/Cezanne Platform Security Processor 1043 876b PRIME Motherboard 17aa 5124 ThinkPad E595 ea50 ce19 mCOM10-L1900 @@ -5424,7 +5469,7 @@ 1043 876b PRIME Motherboard 17aa 5124 ThinkPad E595 ea50 ce19 mCOM10-L1900 - 15e2 ACP/ACP3X/ACP6x Audio Coprocessor + 15e2 Audio Coprocessor 17aa 5124 ThinkPad E595 ea50 ce19 mCOM10-L1900 15e3 Family 17h/19h/1ah HD Audio Controller @@ -5653,9 +5698,11 @@ 43c8 400 Series Chipset SATA Controller 43d5 400 Series Chipset USB 3.1 xHCI Compliant Host Controller 43e9 500 Series Chipset Switch Upstream Port + 43ea 500 Series Chipset Switch Downstream Port 43eb 500 Series Chipset SATA Controller # or ASM106X Serial ATA Controller 1b21 1062 ASM1062 Serial ATA Controller + 43ec A520 Series Chipset USB 3.1 XHCI Controller 43ee 500 Series Chipset USB 3.1 XHCI Controller # maybe 1b21 1142 ASM1042A USB 3.0 Host Controller @@ -5663,6 +5710,7 @@ 43f5 600 Series Chipset PCIe Switch Downstream Port 43f6 600 Series Chipset SATA Controller 43f7 600 Series Chipset USB 3.2 Controller + 43fc 800 Series Chipset USB 3.x XHCI Controller 43fd 800 Series Chipset USB 3.x XHCI Controller 57a3 Matisse PCIe GPP Bridge 57a4 Matisse PCIe GPP Bridge @@ -5998,6 +6046,7 @@ 1028 1f24 PERC S300 Controller # NV-RAM Adapter used in Dell DR appliances 0073 NV-RAM Adapter + 0c46 PERC S160 RAID controller 1028 PCIe Bridge riser 2600 ENT NVMe RT1 1028 215e ENT NVMe RT1 RI 3.84TB @@ -7225,6 +7274,7 @@ 8004 DTL-H2500 [Playstation development board] 8009 CXD1947Q i.LINK Controller 800c DTL-H800 [PS1 sound development board] + 800d DVBK-2000(E) DV Still Image Capture Board 8039 CXD3222 i.LINK Controller 8047 PS2 TOOL MRP 8056 Rockwell HCF 56K modem @@ -7796,6 +7846,7 @@ 103c 1939 QMH2672 16Gb Dual Port Fibre Channel Adapter 103c 8002 3830C 16G Fibre Channel Host Bus Adapter 1077 0241 QLE2670 16Gb Single Port Fibre Channel Adapter + 1077 0249 QLE2672 16Gb Dual Port Fibre Channel Adapter 2071 ISP2714-based 16/32Gb Fibre Channel to PCIe Adapter 1077 0283 QLE2764 Quad Port 32Gb Fibre Channel to PCIe Adapter 1077 029e QLE2694 Quad Port 16Gb Fibre Channel to PCIe Adapter @@ -7864,6 +7915,8 @@ 1077 0167 QME2572 Dual Port FC8 HBA Mezzanine 1590 00fc StoreFabric 84Q 8Gb Quad Port Fibre Channel Host Bus Adapter 2971 ISP2684 + 2981 32G SFP28 EP2744 Apatter + 1bd4 00b0 32G SFP28 EP2744 Apatter 3022 ISP4022-based Ethernet NIC 3032 ISP4032-based Ethernet IPv6 NIC 4010 ISP4010-based iSCSI TOE HBA @@ -9404,13 +9457,16 @@ 8664 PEX 8664 64-lane, 16-Port PCI Express Gen 2 (5.0 GT/s) Switch 8680 PEX 8680 80-lane, 20-Port PCI Express Gen 2 (5.0 GT/s) Multi-Root Switch 8696 PEX 8696 96-lane, 24-Port PCI Express Gen 2 (5.0 GT/s) Multi-Root Switch + 8714 PEX 8714 12-Lane, 5-Port PCI Express Gen 3 (8 GT/s) Switch 8717 PEX 8717 16-lane, 8-Port PCI Express Gen 3 (8.0 GT/s) Switch with DMA 8718 PEX 8718 16-Lane, 5-Port PCI Express Gen 3 (8.0 GT/s) Switch + 8723 PEX 8723 24-Lane, 6-Port PCI Express Gen 3 (8 GT/s) Switch 8724 PEX 8724 24-Lane, 6-Port PCI Express Gen 3 (8 GT/s) Switch, 19 x 19mm FCBGA 4c52 9234 LRNV9324 2-port Built-in 8643 NVMe Exchange Adapter 4c52 9524 LRNV9524 2-port M.2 NVMe SSD Exchange Adapter 8725 PEX 8725 24-Lane, 10-Port PCI Express Gen 3 (8.0 GT/s) Multi-Root Switch with DMA 8732 PEX 8732 32-lane, 8-Port PCI Express Gen 3 (8.0 GT/s) Switch + 8733 PEX 8733 32-Lane, 19-Port PCI Express Gen 3 (8 GT/s) Switch 8734 PEX 8734 32-lane, 8-Port PCI Express Gen 3 (8.0GT/s) Switch 8747 PEX 8747 48-Lane, 5-Port PCI Express Gen 3 (8.0 GT/s) Switch 4c52 9347 LRNV9347L 2-port Built-in 8643 NVMe Switching Adapter @@ -9418,6 +9474,9 @@ 8748 PEX 8748 48-Lane, 12-Port PCI Express Gen 3 (8 GT/s) Switch, 27 x 27mm FCBGA 8749 PEX 8749 48-Lane, 18-Port PCI Express Gen 3 (8.0 GT/s) Multi-Root Switch with DMA 4c52 9349 LRNV9349 8-port SFF-8643 NVMe SSD Exchange Adapter + 8764 PEX 8764 64-Lane, 16-Port PCI Express Gen 3 (8 GT/s) Switch + 8780 PEX 8780 80-Lane, 20-Port PCI Express Gen 3 (8 GT/s) Switch + 8796 PEX8796 96-Lane, 24-Port PCIe Gen 3 (8.0 GT/s) Switch 87a0 PEX PCI Express Switch NT0 Port Link Interface 87a1 PEX PCI Express Switch NT1 Port Link Interface 87b0 PEX PCI Express Switch NT0 Port Virtual Interface @@ -9576,11 +9635,15 @@ 1517 000f ECDR-GC314-PMC Receiver 1885 0700 Tsunami FPGA PMC with Altera Stratix S40 1885 0701 Tsunami FPGA PMC with Altera Stratix S30 + 9712 PEX9712 12-Lane, 5-Port PCIe Gen 3 (8.0 GT/s) ExpressFabric Switch 9733 PEX 9733 33-lane, 9-port PCI Express Gen 3 (8.0 GT/s) Switch 1d49 0001 ThinkSystem 1610-4P NVMe Switch Adapter 1d49 0002 ThinkSystem 810-4P NVMe Switch Adapter 9749 PEX 9749 49-lane, 13-port PCI Express Gen 3 (8.0 GT/s) Switch 1d49 0004 ThinkSystem 1610-8P NVMe Switch Adapter + 9765 PEX9765 65-Lane, 17-Port PCIe Gen 3 (8.0 GT/s) ExpressFabric Switch + 9781 PEX9781 81-Lane, 21-Port PCIe Gen 3 (8.0 GT/s) ExpressFabric Switch + 9797 PEX9781 97-Lane, 25-Port PCIe Gen 3 (8.0 GT/s) ExpressFabric Switch a100 Blackmagic Design DeckLink bb04 B&B 3PCIOSD1A Isolated PCI Serial c001 CronyxOmega-PCI (8-port RS232) @@ -11982,6 +12045,8 @@ 0fa0 GK11x [GK11x_FPGA] 0fa5 GK11x 0fa7 GK11x [Tegra on x86 (PEATRANS)] + 0fae Tegra X1 PCIe x4 Root Complex + 0faf Tegra X1 PCIe x1 Root Complex 0fb0 GM200 High Definition Audio 0fb8 GP108 High Definition Audio Controller 0fb9 GP107GL High Definition Audio Controller @@ -12178,6 +12243,8 @@ 10c3 GT218 [GeForce 8400 GS Rev. 3] 10c5 GT218 [GeForce 405] 10d8 GT218 [NVS 300] + 10e5 Parker PCIe x4 Root Complex + 10e6 Parker PCIe x1 Root Complex 10ef GP102 HDMI Audio Controller 10f0 GP104 High Definition Audio Controller 10f1 GP106 High Definition Audio Controller @@ -12860,7 +12927,7 @@ 1aed TU116 USB Type-C UCSI Controller 1aef GA102 High Definition Audio Controller 1af1 GA100 [A100 NVSwitch] - 1b00 GP102 [TITAN X] + 1b00 GP102 [TITAN X Pascal] 1b01 GP102 [GeForce GTX 1080 Ti 10GB] 1b02 GP102 [TITAN Xp] 1b04 GP102 @@ -13184,11 +13251,16 @@ 228e GA106 High Definition Audio Controller 2291 GA107 High Definition Audio Controller 2296 Tegra PCIe Endpoint Virtual Network + 229a Orin PCIe x8 Root Complex + 229c Orin PCIe x4/x8 Endpoint/Root Complex + 229e Orin PCIe x1 Root Complex 22a3 GH100 [H100 NVSwitch] 22ba AD102 High Definition Audio Controller 22bc AD104 High Definition Audio Controller 22bd AD106M High Definition Audio Controller 22be AD107 High Definition Audio Controller + 22d8 THOR Processor PCI Express Root Port + 22e6 THOR Processor PCI Express x16 Controller 2302 GH100 230e GH100 [H20 NVL16] 2313 GH100 [H100 CNX] @@ -13376,31 +13448,53 @@ 28f8 AD107GLM [RTX 2000 Ada Generation Embedded GPU] 2900 GB100 [Reserved Dev ID A] 2901 GB100 [B200] - 2920 GB100 [TS4] + 2920 GB100 [TS4 / B100] + 2924 GB100 + 2925 GB100 + 293d GB100 2940 GB100 [Reserved Dev ID B] 2941 GB100 [HGX GB200] + 297e GB100 2980 GB102 [Reserved Dev ID A] 29bc GB102 [B100] 29c0 GB102 [Reserved Dev ID B] + 29f1 GB102 + 2b00 TA1090SA [THOR] 2b85 GB202 [GeForce RTX 5090] 2b87 GB202 [GeForce RTX 5090 D] + 2bb1 GB202GL [RTX PRO 6000 Blackwell Workstation Edition] + 2bb3 GB202GL [RTX PRO 5000 Blackwell] + 2bb4 GB202GL [RTX PRO 6000 Blackwell Max-Q Workstation Edition] + 2bb5 GB202GL [RTX PRO 6000 Blackwell Server Edition] 2c02 GB203 [GeForce RTX 5080] 2c05 GB203 [GeForce RTX 5070 Ti] 2c18 GB203M / GN22 [GeForce RTX 5090 Max-Q / Mobile] 2c19 GB203M / GN22 [GeForce RTX 5080 Max-Q / Mobile] 2c2c GB6-256(N22W-ES-A1) + 2c31 GB203GL [RTX PRO 4500 Blackwell] + 2c34 GB203GL [RTX PRO 4000 Blackwell] + 2c38 GB203GLM [RTX PRO 5000 Blackwell Generation Laptop GPU] + 2c39 GB203GLM [RTX PRO 4000 Blackwell Generation Laptop GPU] 2c58 GB203M / GN22-X11 [GeForce RTX 5090 Max-Q / Mobile] 2c59 GB203M / GN22-X9 [GeForce RTX 5080 Max-Q / Mobile] - 2d18 AD108M [GeForce RTX 5070 Max-Q / Mobile] - 2d19 AD108M [GeForce RTX 5060 Max-Q / Mobile] + 2d04 GB206 [GeForce RTX 5060 Ti] + 2d05 GB206 [GeForce RTX 5060] + 2d18 GB206M [GeForce RTX 5070 Max-Q / Mobile] + 2d19 GB206M [GeForce RTX 5060 Max-Q / Mobile] 2d2c GB6-128 (N22Y-ES-A1) - 2d58 AD108M [GeForce RTX 5070 Max-Q / Mobile] - 2d59 AD108M [GeForce RTX 5060 Max-Q / Mobile] - 2d98 AD108M [GeForce RTX 5050 Max-Q / Mobile] - 2dd8 AD108M [GeForce RTX 5050 Max-Q / Mobile] - 2f04 GN22 [GeForce RTX 5070] - 2f18 AD108M [GeForce RTX 5070 Ti Max-Q / Mobile] - 2f58 AD108M [GeForce RTX 5070 Ti Max-Q / Mobile] + 2d39 GB206GLM [RTX PRO 2000 Blackwell Generation Laptop GPU] + 2d58 GB206M [GeForce RTX 5070 Max-Q / Mobile] + 2d59 GB206M [GeForce RTX 5060 Max-Q / Mobile] + 2d83 GB207 [GeForce RTX 5050] + 2d98 GB207M [GeForce RTX 5050 Max-Q / Mobile] + 2db8 GB207GLM [RTX PRO 1000 Blackwell Generation Laptop GPU] + 2db9 GB207GLM [RTX PRO 500 Blackwell Generation Laptop GPU] + 2dd8 GB207M [GeForce RTX 5050 Max-Q / Mobile] + 2e2a GB20B + 2f04 GB205 [GeForce RTX 5070] + 2f18 GB205M [GeForce RTX 5070 Ti Mobile] + 2f38 GB205GLM [RTX PRO 3000 Blackwell Generation Laptop GPU] + 2f58 GB205M [GeForce RTX 5070 Ti Mobile] 31c0 GB110 3340 GB120 10df Emulex Corporation @@ -13554,6 +13648,7 @@ 0860 CA91C860 [QSpan] 0862 CA91C862A [QSpan-II] 8111 Tsi381 PCIe to PCI Bridge + 8113 89HPEB383 PCIe-to-PCI Bridge 8260 CA91L8200B [Dual PCI PowerSpan II] 8261 CA91L8260B [Single PCI PowerSpan II] a108 Tsi109 Host Bridge for Dual PowerPC @@ -13623,6 +13718,7 @@ 5227 RTS5227 PCI Express Card Reader 17aa 220e ThinkPad T440p 17aa 2214 ThinkPad X240 + 5228 RTS5288 PCIe SD UHS-I Card Reader controller 5229 RTS5229 PCI Express Card Reader 1025 0813 Aspire R7-571 103c 194e ProBook 455 G1 Notebook @@ -13646,7 +13742,8 @@ 1028 0c06 Precision 3580 17aa 224f ThinkPad X1 Carbon 5th Gen 5260 RTS5260 PCI Express Card Reader - 5261 RTS5261 PCI Express Card Reader + 5261 RTS5261 PCIe SD Express Card Reader controller + 5264 RTS5264 PCIe SD UHS-II & SD Express Card Reader controller 5286 RTS5286 PCI Express Card Reader 5287 RTL8411B PCI Express Card Reader 1025 1094 Acer Aspire E5-575G @@ -13658,6 +13755,7 @@ 5763 RTS5763DL NVMe SSD Controller (DRAM-less) 5765 RTS5765DL NVMe SSD Controller (DRAM-less) 5770 RTS5770DL NVMe SSD Controller (DRAM-less) + 5771 RTS5771 NVMe SSD Controller (DRAM-less) 5772 RTS5772DL NVMe SSD Controller (DRAM-less) 8029 RTL-8029(AS) 10b8 2011 EZ-Card (SMC1208) @@ -13856,6 +13954,7 @@ 103c 831b Realtek RTL8822BE 802.11ac 2x2 Wi-Fi + Bluetooth 4.2 Combo Adapter (MU-MIMO supported) 17aa 5124 ThinkPad E595 17aa b023 ThinkPad E595 + b851 RTL8851BE PCIe 802.11ax Wireless Network Controller b852 RTL8852BE PCIe 802.11ax Wireless Network Controller b85b RTL8852BE PCIe 802.11ax Wireless Network Controller [1T1R] c821 RTL8821CE 802.11ac PCIe Wireless Network Adapter @@ -14078,6 +14177,8 @@ 000b EMU20k2 [Sound Blaster X-Fi Titanium Series] 1102 0041 SB0880 [SoundBlaster X-Fi Titanium PCI-e] 1102 0062 SB1270 [SoundBlaster X-Fi Titanium HD] + 0010 CA0132 Sound Core3D [Sound Blaster AE-7] + 1102 0081 Sound Blaster AE-7 0012 CA0132 Sound Core3D [Sound Blaster Recon3D / Z-Series / Sound BlasterX AE-5 Plus] 1102 0010 SB1570 SB Audigy Fx 1102 0191 CA0132 Sound Core3D - CA0113 [ Sound BlasterX AE-5 Plus] @@ -14252,7 +14353,7 @@ 0585 VT82C585VP [Apollo VP1/VPX] 0586 VT82C586/A/B PCI-to-ISA [Apollo VP] 1106 0000 MVP3 ISA Bridge - 0591 VT8237A SATA 2-Port Controller + 0591 VT8237A Integrated SATA RAID Controller 0595 VT82C595 [Apollo VP2] 0596 VT82C596 ISA [Mobile South] 1106 0000 VT82C596/A/B PCI to ISA Bridge @@ -14610,6 +14711,7 @@ 3372 VT8237S PCI to ISA Bridge 337a VT8237A PCI to PCI Bridge 337b VT8237A Host Bridge + 3401 VT6325 Firewire Controller 3402 VT8261 PCI to ISA Bridge 3403 VT6315 Series Firewire Controller 1043 8374 M5A88-V EVO @@ -14622,7 +14724,11 @@ 3456 VX11 Standard Host Bridge 345b VX11 Miscellaneous Bus 3483 VL805/806 xHCI USB 3.0 Controller + 365a VT3365 Card Reader Host Controller + 365b VT3365 SDIO Host Controller 3a01 VX11 Graphics [Chrome 645/640] + 401a VT6325 Card Reader Host Controller + 401b VT6325 SDIO PCI-E Host Controller 4149 VIA VT6420 (ATA133) Controller 4204 K8M800 Host Bridge 4208 PT890 Host Bridge @@ -14657,17 +14763,18 @@ 5324 CX700M2/VX700/VX800/820-Series Serial ATA & EIDE-Controller 5327 P4M890 I/O APIC Interrupt Controller 5336 K8M890CE I/O APIC Interrupt Controller + 5337 VT8237A Integrated SATA Controller 5340 PT900 I/O APIC Interrupt Controller 5351 VT3351 I/O APIC Interrupt Controller 5353 VX800/VX820 APIC and Central Traffic Control 5364 CN896/VN896/P4M900 I/O APIC Interrupt Controller - 5372 VT8237/8251 Serial ATA Controller + 5372 VT8237S SATA Controller 5409 VX855/VX875 APIC and Central Traffic Control 5410 VX900 Series APIC and Central Traffic Control 5419 VN1000 I/O APIC Interrupt Controller 6100 VT85C100A [Rhine II] 6122 VN1000 Graphics [Chrome 520 IGP] - 6287 SATA RAID Controller + 6287 VT8251 AHCI SATA Controller 6290 K8M890CE Host Bridge 6327 P4M890 Security Device 6353 VX800/VX820 Scratch Registers @@ -14699,6 +14806,7 @@ 7351 VT3351 Host Bridge 7353 VX800/VX820 North-South Module Interface Control 7364 CN896/VN896/P4M900 Host Bridge + 7372 VT8237S SATA RAID Controller 7409 VX855/VX875 North-South Module Interface Control 7410 VX900 Series North-South Module Interface Control 19da a179 ZBOX nano VD01 @@ -14730,8 +14838,10 @@ 9000 VT8261 IDE Controller [StorX IDE Controller - 9000] 9001 VX900 Series Serial-ATA Controller 9040 VT8261 SATA Controller [StorX RAID Controller - 9040] + 9041 VX900/VX11 SATA Controller [StorX RAID Controller - 9041] 9082 Standard AHCI 1.0 SATA Controller - 9140 HDMI Audio Device + 9140 VX11 Graphics [Chrome 645/640] HDMI Audio Device + 9170 VX900 Graphics [Chrome9 HD] HDMI Audio Device 9201 USB3.0 Controller 9380 Ncore Coprocessor for Centaur CNS 9530 VX800/820/900/VT8261 Series Secure Digital Memory Card Controller @@ -15943,6 +16053,7 @@ 0115 XG4 NVMe SSD Controller 0116 XG5 NVMe SSD Controller 1179 0001 XG5 NVMe SSD Controller + 0119 XD5 NVMe SSD Controller 011a XG6 NVMe SSD Controller 0404 DVD Decoder card 0406 Tecra Video Capture device @@ -16144,7 +16255,7 @@ 103c 30cc Pavilion dv6700 103c 30cf Pavilion dv9668eg Laptop 17aa 20c5 ThinkPad R61 - 17aa 20c7 ThinkPad R61 + 17aa 20c7 ThinkPad R61/T400 0841 R5C841 CardBus/SD/SDIO/MMC/MS/MSPro/xD/IEEE1394 0843 R5C843 MMC Host Controller 1025 0121 Aspire 5920G @@ -16592,6 +16703,8 @@ 11bc Network Peripherals Inc 0001 NP-PCI 11bd Pinnacle Systems Inc. + 0015 FireWire Controller + 0023 Studio 700 002e PCTV 40i 0040 Royal TS Function 1 11bd 0044 PCTV 2000i Dual DVB-T Pro PCI Tuner 1 @@ -16893,6 +17006,10 @@ 11f7 Scientific Atlanta # née PMC-Sierra Inc. 11f8 Microchip Technology + 4036 PM40036 Switchtec PFX 36xG4 Fanout PCIe Switch + 4052 PM40052 Switchtec PFX 52xG4 Fanout PCIe Switch + 4084 PM40084 Switchtec PFX 84xG4 Fanout PCIe Switch + 4128 PM41028 Switchtec PSX 28xG4 Programmable PCIe Switch 5000 PM50100 Switchtec PFX 100xG5 Fanout PCIe Switch 5028 PM50028 Switchtec PFX 28xG5 Fanout PCIe Switch 5036 PM50036 Switchtec PFX 36xG5 Fanout PCIe Switch @@ -17220,6 +17337,8 @@ 1233 Bus-Tech, Inc. # nee Risq Modular Systems, Inc. 1235 SMART Modular Technologies + c241 CXA-4F1W + 1028 2382 4-DIMM Add In Card 1236 Sigma Designs Corporation 0000 RealMagic64/GX 6401 REALmagic 64/GX (SD 6425) @@ -17476,6 +17595,7 @@ 2261 SM2261XT x2 NVMe SSD Controller (DRAM-less) 2262 SM2262/SM2262EN SSD Controller 2263 SM2263EN/SM2263XT (DRAM-less) NVMe SSD Controllers + 2268 SM2268XT (DRAM-less) NVMe SSD Controller 2269 SM2269XT (DRAM-less) NVMe SSD Controller 8366 SM8366 NVMe SSD Controller [MonTitan] 1270 Olympus Optical Co., Ltd. @@ -18454,6 +18574,7 @@ 5416 2550 NVMe SSD (DRAM-less) 5425 2500 NVMe SSD (DRAM-less) 5427 2650 NVMe SSD (DRAM-less) + 5428 4600 NVMe SSD 5429 2600 NVMe SSD (DRAM-less) 6001 2100AI NVMe SSD [Nitro] 1345 Arescom Inc @@ -18528,6 +18649,8 @@ 0b22 UP-200 Powered 2 port RS-232 card 0b23 UP-200 Powered 2 port RS-232 card 0ba1 UC-101 1 + 1 port RS-232 card + 0ba2 UC-101 1 + 1 port RS-232 card + 0ba3 UC-101 1 + 1 port RS-232 card 0bc1 UC-203 1 + 1 port RS-232 + LPT card 0bc2 UC-203 1 + 1 port RS-232 + LPT card 0be1 UC-146 LPT card @@ -18539,6 +18662,8 @@ 0c22 UP-880 Powered 2 port RS-232 card 0c23 UP-880 Powered 2 port RS-232 card 0c41 UC-368 4 port RS-422/485 Opto Isolated card + 0c42 UC-368 4 port RS-422/485 Opto Isolated card + 0c43 UC-368 4 port RS-422/485 Opto Isolated card 0ca1 UC-253 2 port RS-232 card 0d21 UC-260 4 port RS-232 card 0d41 UC-836 4 port RS-232 card @@ -18578,6 +18703,10 @@ 401d PX-475 1 port RS-232 + LPT card (Serial port) 401e PX-803 Powered 1 + 1 port RS-232 card 401f PX-475 1 port RS-232 + LPT card (LPT port) + 4020 XC-157 LPT ExpressCard + 4021 XC-475 1 port RS-232 + LPT ExpressCard (Serial port) + 4022 XC-475 1 port RS-232 + LPT ExpressCard (LPT port) + 4026 XC-235 1 port RS-232 ExpressCard 4027 IX-100 1 port RS-232 card 4028 IX-200 2 port RS-232 card 4029 IX-400 4 port RS-232 card @@ -20294,6 +20423,8 @@ a80d NVMe SSD Controller PM9C1a (DRAM-less) a80e NVMe SSD Controller PM9D3a a80f BM9C1 QLC NVME SSD (DRAM-less) + a810 NVMe SSD 9100 PRO [PM9E1] + a811 BM9H1 NVME SSD (DRAM-less) a820 NVMe SSD Controller 171X 1028 1f95 Express Flash NVMe XS1715 SSD 400GB 1028 1f96 Express Flash NVMe XS1715 SSD 800GB @@ -20469,6 +20600,7 @@ 1458 Gigabyte Technology Co., Ltd 1002 Aourus Radeon RX6900XT Xtreme Waterforce WB 16G 22e8 Ellesmere [Radeon RX 480] + 2425 Radeon RX 9070 GAMING OC 16G 3483 USB 3.0 Controller (VIA VL80x-based xHCI Controller) 1459 DOOIN Electronics 145a Escalate Networks Inc @@ -20657,6 +20789,7 @@ 14c3 MEDIATEK Corp. 0608 MT7921K (RZ608) Wi-Fi 6E 80MHz 0616 MT7922 802.11ax PCI Express Wireless Network Adapter + 0717 MT7925 (RZ717) Wi-Fi 7 160MHz 4d75 T700 5G Modem [5G Solution 5000] 7603 MT7603E 802.11bgn PCI Express Wireless Network Adapter 7612 MT7612E 802.11acbgn PCI Express Wireless Network Adapter @@ -22155,6 +22288,7 @@ 9300 Universal Exhaust Gas Oxygen Sensor Simulator 9310 Digital Programmable Resistor 9320 Arria 10 FPGA Card + 9330 Cyclone V FPGA Card 9350 Analog Input Card 1543 SILICON Laboratories 3052 Intel 537 [Winmodem] @@ -22417,6 +22551,15 @@ 0290 SagittaZ 0292 Arcus3 Flash Recovery 0293 Arcus3 RMA + 0294 Ophy 2.1 (SagittaZ) +# Sagitta + 0296 OPHY2.6 +# Sagitta + 0298 OPHY3.0 +# Sagitta + 029a OPHY3.1 +# Sagitta + 029c OPHY3.5 02a0 Quantum-6 in Flash Recovery Mode 02a1 Quantum-6 RMA 02a2 Spectrum-7 in Flash Recovery Mode @@ -22503,6 +22646,7 @@ # NIC-ETH540F-3S-2P OCP3.0 2x10G Card 193d 1084 NIC-ETH540F-3S-2P 1e81 0c10 25GbE dual-port SFP28, PCIe3.0 x8 [3SC10] + 1f3f 0c10 25GbE dual-port SFP28, PCIe3.0 x8, 3SC10 1016 MT27710 Family [ConnectX-4 Lx Virtual Function] 1017 MT27800 Family [ConnectX-5] 117c 00b1 FastFrame N311 Single-port 10Gb Ethernet Adapter @@ -22529,6 +22673,7 @@ 193d 1035 NIC-ETH641F-LP-2P SFP28 2x25GbE PCIe Network Adapter 1bd4 00ac O252MCX6Lx 1bd4 00ae S252MCX6Lx + 1f3f 0c11 25GbE dual-port SFP28, PCIe4.0 x8, 3SC1125GbE dual-port SFP28, PCIe4.0 x8, 3SC11 1ff9 00ad ENFM6251-SP2 1ff9 00af ENPM6251-SP2 1020 MT28860 @@ -22688,7 +22833,7 @@ 5014 WD PC SN540 / Green SN350 NVMe SSD 1 TB (DRAM-less) 5015 PC SN740 NVMe SSD (DRAM-less) 5016 WD PC SN740 NVMe SSD 512GB (DRAM-less) - 5017 WD Black SN770 / PC SN740 256GB / PC SN560 (DRAM-less) NVMe SSD + 5017 WD SN560/SN740/SN770/SN5000 NVMe SSD 5019 WD Green SN350 240GB (DRAM-less) / SN560E NVMe SSD 501a SanDisk Ultra 3D / WD Blue SN570 NVMe SSD (DRAM-less) 501d WD Blue SN550 NVMe SSD 2TB (DRAM-less) @@ -22699,12 +22844,16 @@ 5028 WD CH SN560 NVMe SSD 5030 WD Black SN850X NVMe SSD 5034 WD PC SN5000S M.2 2230 NVMe SSD (DRAM-less) + 5035 WD PC SN5000S M.2 2242 NVMe SSD (DRAM-less) 5036 WD PC SN5000S M.2 2280 NVMe SSD (DRAM-less) 5041 WD Blue SN580 NVMe SSD (DRAM-less) 5042 WD Black SN770M NVMe SSD (DRAM-less) + 5044 WD PC SN7100S NVMe SSD (DRAM-less) 5045 WD_BLACK SN7100 NVMe SSD (DRAM-less) 5046 SanDisk Extreme NVMe SSD (DRAM-less) 5049 SN8000S NVMe SSD + 504a WD Blue SN5000 NVMe SSD (DRAM-less) + 5050 WD PC SN8050S / WD_BLACK SN8100 NVMe SSD 15b8 ADDI-DATA GmbH 1001 APCI1516 SP controller (16 digi outputs) 1003 APCI1032 SP controller (32 digi inputs w/ opto coupler) @@ -23843,6 +23992,8 @@ 010c SM8350 PCIe Root Complex [Snapdragon 888] 010e SC8280XP PCI Express Root Port 0110 SM8475 PCIe Root Complex [Snapdragon 8+ Gen 1] + 0111 SC8380XP PCIe Root Complex [Snapdragon X / X Plus / X Elite] + 0113 SM8550/SM8650 PCIe Root Complex [Snapdragon 8 Gen 2/Gen 3] 0300 MDM9x35 LTE Modem [Snapdragon X7] 0301 MDM9x45 LTE Modem [Snapdragon X12] 0302 MDM9x55 LTE Modem [Snapdragon X16] @@ -23851,6 +24002,7 @@ 0400 Datacenter Technologies QDF2432 PCI Express Root Port 0401 Datacenter Technologies QDF2400 PCI Express Root Port 1000 QCS405 PCIe Root Complex + 1003 IPQ6018 PCIe Root Complex 1101 QCA6390 Wireless Network Adapter 1103 QCNFA765 Wireless Network Adapter 1104 QCN6024/9024/9074 Wireless Network Adapter @@ -24714,6 +24866,14 @@ 0441 T4240 without security 0446 T4160 with security 0447 T4160 without security + 0820 T1040 with security + 0821 T1040 without security + 0824 T1042 with security + 0825 T1042 without security + 0828 T1020 with security + 0829 T1020 without security + 082c T1022 with security + 082d T1022 without security 0830 T2080 with security 0831 T2080 without security 0838 T2081 with security @@ -24851,15 +25011,18 @@ 5016 E16 PCIe4 NVMe Controller 5018 E18 PCIe4 NVMe Controller 5019 PS5019-E19 PCIe4 NVMe Controller (DRAM-less) + 5020 PS5020-E20 (X1) PCIe4 NVMe Controller 5021 PS5021-E21 PCIe4 NVMe Controller (DRAM-less) 5026 PS5026-E26 PCIe5 NVMe Controller 5027 PS5027-E27T PCIe4 NVMe Controller (DRAM-less) 5031 PS5031-E31T PCIe5 NVMe Controller + 5302 PS5302-X2 PCIe5 NVMe Controller 1989 Montilio Inc. 0001 RapidFile Bridge 8001 RapidFile 198a Nallatech Ltd. 1993 Innominate Security Technologies AG +1998 Toyou Feiji Electronics Co., Ltd. 1999 A-Logics a900 AM-7209 Video Processor 199a Pulse-LINK, Inc. @@ -25015,6 +25178,8 @@ a126 HiSilicon SDI NVMe Storage Controller a127 HiSilicon SDI Accelerator a12a HiSilicon Add-on PCI-PCI Bridge + a12d HiSilicon Embedded PMU + a12e HiSilicon Embedded PCIe PTT a220 HNS GE Network Controller a221 HNS GE/10GE/25GE Network Controller 19e5 0454 TM280 @@ -25102,6 +25267,12 @@ 1a3b AzureWave 1112 AR9285 Wireless Network Adapter (PCI-Express) 1a3e Micro-Research Finland Oy + 132c MTCA Event Receiver 300 + 152c CompactPCI Event Receiver 300 + 172c PCI Express Event Receiver 300 + 192c CompactPCI Event Receiver TG 300 + 232c MTCA Event Master 300 + 252c CompactPCI Event Generator 300 1a41 Tilera Corp. 0001 TILE64 processor 0002 TILEPro processor @@ -25323,19 +25494,83 @@ 1005 Virtio RNG 1009 Virtio filesystem 1041 Virtio 1.0 network device + 1af4 1100 QEMU 1042 Virtio 1.0 block device + 1af4 1100 QEMU 1043 Virtio 1.0 console + 1af4 1100 QEMU 1044 Virtio 1.0 RNG - 1045 Virtio 1.0 memory balloon + 1af4 1100 QEMU + 1045 Virtio 1.0 balloon + 1af4 1100 QEMU + 1046 Virtio 1.0 ioMemory + 1af4 1100 QEMU + 1047 Virtio 1.0 remote processor messaging + 1af4 1100 QEMU 1048 Virtio 1.0 SCSI - 1049 Virtio 1.0 filesystem + 1af4 1100 QEMU + 1049 Virtio 9P transport + 1af4 1100 QEMU + 104a Virtio 1.0 WLAN MAC + 1af4 1100 QEMU + 104b Virtio 1.0 remoteproc serial link + 1af4 1100 QEMU + 104d Virtio 1.0 memory balloon + 1af4 1100 QEMU 1050 Virtio 1.0 GPU + 1af4 1100 QEMU + 1051 Virtio 1.0 clock/timer + 1af4 1100 QEMU 1052 Virtio 1.0 input + 1af4 1100 QEMU 1053 Virtio 1.0 socket - 1058 virtio-mem - 105a Virtio file system - 1110 Inter-VM shared memory - 1af4 1100 QEMU Virtual Machine + 1af4 1100 QEMU + 1054 Virtio 1.0 crypto + 1af4 1100 QEMU + 1055 Virtio 1.0 signal distribution device + 1af4 1100 QEMU + 1056 Virtio 1.0 pstore device + 1af4 1100 QEMU + 1057 Virtio 1.0 IOMMU + 1af4 1100 QEMU + 1058 Virtio 1.0 mem + 1af4 1100 QEMU + 1059 Virtio 1.0 sound + 1af4 1100 QEMU + 105a Virtio 1.0 file system + 1af4 1100 QEMU + 105b Virtio 1.0 pmem + 1af4 1100 QEMU + 105c Virtio 1.0 rpmb + 1af4 1100 QEMU + 105d Virtio 1.0 mac80211-hwsim + 1af4 1100 QEMU + 105e Virtio 1.0 video encoder + 1af4 1100 QEMU + 105f Virtio 1.0 video decoder + 1af4 1100 QEMU + 1060 Virtio 1.0 SCMI + 1af4 1100 QEMU + 1061 Virtio 1.0 nitro secure module + 1af4 1100 QEMU + 1062 Virtio 1.0 I2C adapter + 1af4 1100 QEMU + 1063 Virtio 1.0 watchdog + 1af4 1100 QEMU + 1064 Virtio 1.0 can + 1af4 1100 QEMU + 1065 Virtio 1.0 dmabuf + 1af4 1100 QEMU + 1066 Virtio 1.0 parameter server + 1af4 1100 QEMU + 1067 Virtio 1.0 audio policy + 1af4 1100 QEMU + 1068 Virtio 1.0 Bluetooth + 1af4 1100 QEMU + 1069 Virtio 1.0 GPIO + 1af4 1100 QEMU + 1110 QEMU Inter-VM shared memory device + 1af4 1100 QEMU 1af5 Netezza Corp. 1afa J & W Electronics Co., Ltd. 1b00 Montage Technology Co., Ltd. @@ -25427,6 +25662,7 @@ 000b QEMU PCIe Expander bridge 000c QEMU PCIe Root port 000d QEMU XHCI Host Controller + 000e QEMU PCIe-to-PCI bridge 0010 QEMU NVM Express Controller 0011 QEMU PVPanic device 0013 QEMU UFS Host Controller @@ -25475,16 +25711,20 @@ 1028 2196 ROR-N1 1028 2286 BOSS-N1 DC-MHS 1028 2287 BOSS-N1 Modular DC-MHS + 1028 23b0 eBOSS-N1 DC-MHS 1b4b 2241 Santa Cruz NVMe Host Adapter 1b96 4000 WD_BLACK AN1500 NVMe SSD 1d49 0306 ThinkSystem M.2 NVMe 2-Bay RAID Enablement Kit 1d49 0307 ThinkSystem 7mm NVMe 2-Bay Rear RAID Enablement Kit + 207d 0800 TrustRAID B310n + 207d 0801 TrustRAID B260s 4c52 9541 LRNV9541 2-port M.2 NVMe Raid Adapter 2b42 88W8997 2.4/5 GHz Dual-Band 2x2 Wi-Fi® 5 (802.11ac) + Bluetooth® 5.3 Solution 2b43 NXP 88W9098 Wi-Fi 6 (ax) MAC #1 2b44 NXP 88W9098 Wi-Fi 6 (ax) MAC #2 2b45 NXP 88W9098 Bluetooth 5.3 9120 88SE9120 SATA 6Gb/s Controller + 9122 88SE912x SATA 6Gb/s Controller [AHCI mode] 9123 88SE9123 PCIe SATA 6.0 Gb/s controller dc93 600e DC-6xxe series SATA 6G controller 9125 88SE9125 PCIe SATA 6.0 Gb/s controller @@ -25493,14 +25733,19 @@ 9130 88SE9128 PCIe SATA 6 Gb/s RAID controller with HyperDuo 1043 8438 P8P67 Deluxe Motherboard 9170 88SE9170 PCIe 2.0 x1 2-port SATA 6 Gb/s Controller + 9171 88SE9171 PCIe 2.0 x1 1-port SATA 6 Gb/s Controller 9172 88SE9172 SATA 6Gb/s Controller 9178 88SE9170 PCIe SATA 6Gb/s Controller - 917a 88SE9172 SATA III 6Gb/s RAID Controller + 917a 88SE9172 SATA III 6Gb/s Controller [IDE mode] 9182 88SE9182 PCIe 2.0 x2 2-port SATA 6 Gb/s Controller 9183 88SS9183 PCIe SSD Controller + 9186 88SE9186 6Gb/s SATA 6Gb/s Controller [AHCI mode] + 918a 88SE9182 PCIe SATA 6 Gb/s controller [IDE mode] 9192 88SE9172 SATA III 6Gb/s RAID Controller 91a0 88SE912x SATA 6Gb/s Controller [IDE mode] + 91a3 88SE9128 PCIe SATA 6 Gb/s controller [IDE mode] 91a4 88SE912x IDE Controller + 91b0 88SE9172 SATA 6 Gb/s controller [IDE mode] 9215 88SE9215 PCIe 2.0 x1 4-port SATA 6 Gb/s Controller 9220 88SE9220 PCIe 2.0 x2 2-port SATA 6 Gb/s RAID Controller 9230 88SE9230 PCIe 2.0 x2 4-port SATA 6 Gb/s RAID Controller @@ -25560,6 +25805,7 @@ 1009 FL1009 USB 3.0 Host Controller 1100 FL1100 USB 3.0 Host Controller 16b8 6e31 Allegro Pro USB 3.0 PCIe + 1400 USB 3.0 Host Controller 1b74 OpenVox Communication Co. Ltd. 0115 D115P/D115E Single-port E1/T1 card d130 D130P/D130E Single-port E1/T1 card (3rd GEN) @@ -25721,6 +25967,9 @@ 5021 FireCuda 520 SSD # 1TB 5026 FireCuda 540 SSD + 5027 LaCie Rugged SSD Pro5 + 5100 PCIe Gen3 SSD + 5101 PCIe Gen5 SSD 1bb3 Bluecherry 4304 BC-04120A MPEG4 4 port video encoder / decoder 4309 BC-08240A MPEG4 4 port video encoder / decoder @@ -25782,6 +26031,8 @@ 100c NS8510G1Uxxx, NS8610G1Uxxx NVME SSD 100e NS8500G2Uxxxx, NS8600G2Uxxxx NVME SSD 100f NS6500G2UXXXX,NS6600G2UXXXX NVME SSD *** 1453 LINES SKIPPED *** From nobody Wed Sep 17 19:35:03 2025 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 4cRprR3lPcz67wrR; Wed, 17 Sep 2025 19:35:03 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRprR1VfXz4DFk; Wed, 17 Sep 2025 19:35:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137703; 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=x/v6NXpWk/PA9H8R+mD5Dd1r1JQxBaAduhkWqHLbOTo=; b=P3LL/nG7p5LvTROV0SZ6CEGKGuTsHHviDt4H4YvuOXGjNvFtO7s1Ax1nT80j4tAoxy0BCI jFSfTol+wJBu8Ds7meLGNMHWcFE8KqcYo2Queya3cmV/7A/AbROJcgwi9TDBvvdo9SfZV+ O2H5RL9Oiroi1N11S5NwCgn/TpvkeoU0YIwLnqHLApzOgZe8JYKZdnnlv+1+fhpE/44OuH 5V5RyGMFjdOSt6IVREaBgowHVA/AcWF2wiIBGOIphy7FFq7mj/WcluRrTRzN4YongZaVD7 qLrhJzA6FjtOA5P1UKrfYakmKrbeOvKRuC1k9MseiaI+t8feYv4evQ8pG0exmQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137703; 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=x/v6NXpWk/PA9H8R+mD5Dd1r1JQxBaAduhkWqHLbOTo=; b=G/QoDDO8J+UwW3CYh4/vCT9VHol/KI5qk2bljVjm3bNG0q0QKJ0l05xmS6setPfBIhUha2 qzXdLg72A0vQskcJgQzTVvZ23Y7lkgfuYuhMV9xjC2qnGct9Vzvm1YdeoI3yTuUHNdcrbl aFol1ClmVmb850Yo6//5/RzN21LeItYfE29AgipO74Ta7GUxB2vpZYpK7b+DYM/tTzfA7w 03I9jIy+vl7zCdSAeHnJDcFqvqBusxGWscl0jqlbCk4Tdk1/4rDaHsl1yvL6hMoiZIA3T0 EJhLu+0K7C3m0k2Rr3/Pz7ZRTXqP2tqSNU7MQUw852hrJpC0NRTmIddJz2NpTA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137703; a=rsa-sha256; cv=none; b=qGQiJ+a28BolnHQ6hJ4hR9WcZYtN/4fQzm47tiWfnhYEntufpVOa9D/CE8ig4pr8Da1A3G UfvWmmoPHOz/0fZP5e0CoBXVe76Mf26O96lJtcPPXSTpYqwnnkx4f6r/P+75zGkSZTD6XK GfThSM2wc+OD2QsNGL2PZ9tFnbRv1UAJ1+E/yQDTkuSBHWYpNASeqSU3CZiEDKuNZk6mb8 658u3VVWzON7XzGS8ywYYNSM78tCq6Wub+30Ky1AKf0nB4AgdREp6890bdITls129T0o74 jR8qwe/3Z+axze59r+K64ohONEzmrZv/afVThcgSx5Z2LIwjFxj/Ydo1j6+uzw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRprR1648zgQZ; Wed, 17 Sep 2025 19:35:03 +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 58HJZ3ux014649; Wed, 17 Sep 2025 19:35:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJZ3rv014646; Wed, 17 Sep 2025 19:35:03 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:35:03 GMT Message-Id: <202509171935.58HJZ3rv014646@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 3767aeec35c9 - stable/15 - usb_vendors: update to 2025-07-26 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 3767aeec35c92780ac635a5b4ccdf8d7b4c661cd Auto-Submitted: auto-generated The branch stable/15 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=3767aeec35c92780ac635a5b4ccdf8d7b4c661cd commit 3767aeec35c92780ac635a5b4ccdf8d7b4c661cd Author: Baptiste Daroussin AuthorDate: 2025-09-11 07:54:17 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:34:47 +0000 usb_vendors: update to 2025-07-26 (cherry picked from commit 70afc95fc6ecec6edabf5b1e8b060bb0b29ebd55) --- share/misc/usb_vendors | 57 +++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 54 insertions(+), 3 deletions(-) diff --git a/share/misc/usb_vendors b/share/misc/usb_vendors index 3e72fe4045e6..1878f503b676 100644 --- a/share/misc/usb_vendors +++ b/share/misc/usb_vendors @@ -9,8 +9,8 @@ # The latest version can be obtained from # http://www.linux-usb.org/usb.ids # -# Version: 2025.04.01 -# Date: 2025-04-01 20:34:02 +# Version: 2025.07.26 +# Date: 2025-07-26 20:34:01 # # Vendors, devices and interfaces. Please keep sorted. @@ -59,6 +59,8 @@ 0112 Card Reader 017c MLK 145f Trust Deskset +019c mek + 0042 mek_42 0200 TP-Link 0201 MA180 UMTS Modem 0204 Chipsbank Microelectronics Co., Ltd @@ -69,6 +71,9 @@ 0231 Sonuus Limited 02ad HUMAX Co., Ltd. 138c PVR Mass Storage +0300 Ajazz + 1010 Akp153E Desktop Controller + 1020 AKP153R Desktop Controller 0303 Mini Automation Controller 0324 OCZ Technology Inc bc06 OCZ ATV USB 2.0 Flash Drive @@ -95,7 +100,7 @@ 0015 ATAPI Enclosure 2123 SiPix StyleCam Deluxe 8004 Aox 99001 -03e9 Thesys Microelectronics +03e9 Melexis (formerly Thesys Microelectronics) 03ea Data Broadcasting Corp. 03eb Atmel Corp. 0902 4-Port Hub @@ -257,6 +262,8 @@ 0423 HS-COMBO Cardreader 042a LaserJet M1132 MFP 0441 Prime [NW280AA, G8X92AA] + 046b Dock G5 + 0483 Engage Go 10 Tablet 0504 DeskJet 885c 0505 ScanJet 2100c 0507 DVD+RW @@ -266,6 +273,7 @@ 0517 LaserJet 1000 051d Bluetooth Interface 052a LaserJet M1212nf MFP + 0583 Engage Go 10 Tablet 0601 ScanJet 6300c 0604 DeskJet 840c 0605 ScanJet 2200c @@ -275,6 +283,7 @@ 0624 Bluetooth Dongle 0641 X1200 Optical Mouse 0653 DeskJet 3700 series + 0683 Engage Go 10 Tablet 0701 ScanJet 5300c/5370c 0704 DeskJet 825c 0705 ScanJet 4400c @@ -325,6 +334,7 @@ 1102 PhotoSmart 240 series 1104 DeskJet 959c 1105 ScanJet 5470c/5490c + 110c Pocket Media Drive 1111 OfficeJet v60 1116 Jornada 568 Pocket PC 1117 LaserJet 1300n @@ -1013,6 +1023,7 @@ 3000 Optical dual-touch panel 3001 Optical Touch Screen 3008 Optical Touch Screen + 4033 HD Webcam a060 HD Webcam 0409 NEC Corp. 0011 PC98 Series Layout Keyboard Mouse @@ -1029,6 +1040,7 @@ 004e SuperScript 1400 Series 004f Wireless Keyboard with One-touch start buttons 0050 7-port hub + 0056 uPD720133 IDE bridge 0058 HighSpeed Hub 0059 HighSpeed Hub 005a HighSpeed Hub @@ -1486,6 +1498,7 @@ 4095 Live! Cam Sync HD [VF0770] 4097 Live! Cam Chat HD [VF0700/VF0790] 4099 Creative VF0800 [RealSense Camera SR300] + 40a3 Live! Cam V3 2K [VF-0900] 4100 Nomad Jukebox 2 4101 Nomad Jukebox 3 4102 NOMAD MuVo^2 @@ -1959,6 +1972,7 @@ 010d 3500-4500 series 010f 6500 series 0142 X3650 (Printer, Scanner, Copier) + 01bd S800 Series Scanner 01fa S310 series 020e RICOH Aficio SP 4410SF 4303 Xerox WorkCentre Pro 412 @@ -1982,6 +1996,7 @@ 9a10 34UC88-B 9a11 34UC88-B 9a39 27UP850 - WK.AEUDCSN - External Monitor 4K + 9a57 UltraGear Monitor 9c01 LGE Sync 043f RadiSys Corp. 0440 Eizo Nanao Corp. @@ -2007,6 +2022,7 @@ 044d Siemens Nixdorf AG 044e Alps Electric Co., Ltd 1104 Japanese Keyboard + 1218 Electric Touchpad 2002 MD-5500 Printer 2014 Bluetooth Device 3001 UGTZ4 Bluetooth @@ -2737,6 +2753,8 @@ 0180 Strait 3.0 01a4 MC 2.1 Mouse 01a6 MX BOARD 2.0S FL RGB DE Keyboard + 0201 Smart Board 1150 + 0202 Smart Terminal 1150 b090 Keyboard b091 Mouse c099 Stream Keyboard TKL @@ -2851,6 +2869,7 @@ 08dd QuickCam for Notebooks 08e0 QuickCam Express 08e1 Labtec Webcam + 08e4 C505e HD Webcam 08e5 C920 PRO HD Webcam 08f0 QuickCam Messenger 08f1 QuickCam Express @@ -3002,6 +3021,7 @@ c08e G MX518 Gaming Mouse (MU0053) c092 G102/G203 LIGHTSYNC Gaming Mouse c093 M500s Optical Mouse + c09d G102 LIGHTSYNC Gaming Mouse c101 UltraX Media Remote c110 Harmony 785/880/885 Remote c111 Harmony 525 Remote @@ -3060,6 +3080,7 @@ c24d G710 Gaming Keyboard c24e G500s Laser Gaming Mouse c24f G29 Driving Force Racing Wheel [PS3] + c251 GamePanel for Dell XPS M1730 c260 G29 Driving Force Racing Wheel [PS4] c262 G920 Driving Force Racing Wheel c281 WingMan Force @@ -3073,6 +3094,7 @@ c295 Momo Force Steering Wheel c298 Driving Force Pro c299 G25 Racing Wheel + c29a Driving Force GT c29b G27 Racing Wheel c29c Speed Force Wireless Wheel for Wii c2a0 Wingman Force Feedback Mouse @@ -3110,6 +3132,7 @@ c335 G910 Orion Spectrum Mechanical Keyboard c336 G213 Prodigy Gaming Keyboard c33a G413 Gaming Keyboard + c33e G915 Mechanical Keyboard c33f G815 Mechanical Keyboard c401 TrackMan Marble Wheel c402 Marble Mouse (2-button) @@ -3359,6 +3382,7 @@ 047c Dell Computer Corp. ffff UPS Tower 500W LV 047d Kensington + 00f2 VeriMark Desktop 1001 Mouse*in*a*Box 1002 Expert Mouse Pro 1003 Orbit TrackBall @@ -3558,6 +3582,7 @@ 0485 Nokia Monitors 0486 ASUS Computers, Inc. 0185 EeePC T91MT HID Touch Panel + 573c Xreal Light Microcontroller 0487 Stewart Connector 0488 Cirque Corp. 0489 Foxconn / Hon Hai @@ -3663,6 +3688,7 @@ 1033 DGX-505 1037 PSR-E403 103c MOTIF-RACK ES + 1045 MM6 1054 S90XS Keyboard/Music Synthesizer 160f P-105 1613 Clavinova CLP535 @@ -3892,9 +3918,11 @@ 106d S750 Printer 106e S820D 1070 S530D + 1071 Sony MPR-501 1072 I850 Printer 1073 I550 Printer 1074 S330 Printer + 1075 Sony MPR-505 1076 i70 1077 i950 107a S830D @@ -4053,6 +4081,7 @@ 178a PIXMA MG3600 Series 178d PIXMA MG6853 180b PIXMA MG3000 series + 183b PIXMA MG3110 Series 1856 PIXMA TS6250 1900 CanoScan LiDE 90 1901 CanoScan 8800F @@ -4060,6 +4089,7 @@ 1905 CanoScan LiDE 200 1906 CanoScan 5600F 1907 CanoScan LiDE 700F + 1908 CanoScan 9000F 1909 CanoScan LiDE 110 190a CanoScan LiDE 210 190d CanoScan 9000F Mark II @@ -4621,6 +4651,7 @@ 0434 D610 0436 D810 043f D5600 + 0455 Z50II 0f03 PD-10 Wireless Printer Adapter 4000 Coolscan LS 40 ED 4001 LS 50 ED/Coolscan V ED @@ -4907,11 +4938,19 @@ 0891 Stylus Office BX535WD 0892 Stylus Office BX935FWD 0893 EP-774A + 08d1 L220/L360 Series 0e03 Thermal Receipt Printer [TM-T20] + 0e31 Thermal Receipt Printer [TM-L100] 1114 XP-440 [Expression Home Small-in-One Printer] 1115 ES-0133 [Expression Home XP-342] 1129 ET-4750 [WorkForce ET-4750 EcoTank All-in-One] 1168 Workforce WF-7820/7840 Series + 1186 ET-2820 Series [ET-2820 EcoTank All-in-One] + 118a ET-2810/L3250 Series [EcoTank ET-2810/L3250] + 118b ET-2850/L4260 Series [EcoTank ET-2850/L4260] + 11b0 XP-4200 Series [Expression Home XP-4200] + 11b9 ET-2830/L3550 Series [EcoTank ET-2830/L3550] + 11c8 ET-2860/L3270 Series [EcoTank ET-2860/L3270] 04b9 Rainbow Technologies, Inc. 0300 SafeNet USB SuperPro/UltraPro 1000 iKey 1000 Token @@ -4996,6 +5035,9 @@ 1303 i3 Micro Module 1304 i3 Module 1305 i3 Multi Sensing Module + 1400 Javelin Module Recovery + 1401 Javelin Module + 1500 Gas sensor demo board 04c1 U.S. Robotics (3Com) 0020 56K Voice Pro 0022 56K Voice Pro @@ -5034,7 +5076,9 @@ 11f3 fi-6130Z 125a PalmSecure Sensor Device - MP 132e fi-7160 + 1526 PalmSecure-F Pro 159f ScanSnap iX1500 + 15ff Fi-8170 Document Scanner [Ricoh fi-8170: High Performance Desktop Scanner - PFU] 200f Sigma DP2 (Mass Storage) 2010 Sigma DP2 (PictBridge) 201d SATA 3.0 6Gbit/s Adaptor [GROOVY] @@ -5067,6 +5111,7 @@ 300f Atheros AR3012 Bluetooth 3014 Qualcomm Atheros Bluetooth 3015 Qualcomm Atheros QCA9377 Bluetooth + 3802 MediaTek Bluetooth MT7921 7022 HP HD Webcam 7025 HP HD Webcam 7046 TOSHIBA Web Camera - HD @@ -15333,6 +15378,12 @@ 0e23 Liou Yuane Enterprise Co., Ltd 0e25 VinChip Systems, Inc. 0e26 J-Phone East Co., Ltd +0e2c Materialise Motion NV + 0012 footscan pressure plate (0.5m) + 0013 footscan pressure plate (1.0m) + 0018 footscan 2D interface box + 0020 footscan pressure plate (1.5m) + 002d footscan heavy duty pressure plate (1.0m) 0e2e Brady Worldwide, Inc. 000b BMP 51 000c BMP 61 From nobody Wed Sep 17 19:37:15 2025 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 4cRpv00zwtz67wpf; Wed, 17 Sep 2025 19:37:16 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRpv00Gyfz4DqT; Wed, 17 Sep 2025 19:37:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137836; 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=9DP/e1DT/62ihFXl8qmJq9SmFzxPwxY2SRfccOVI3O4=; b=fi64YYiUj4DVo8rQTRmeZW0VtnjXoomV1d7fHvDngncK/U+T+22qdQ0U9dQNA2aejmm+Oj vzrNLYuKadDrLkcxTPSzSM/MqJjpL9u0K55iUN6RrIkIOvyTxVOaxdTyenjEaz77pnwo+W ozSfYuG1mNITSQQo9lrFfSzUGS04srZ7gu4KRIr2E8kzMAeTDMTU6mkwp4fT9f7Neq9OZ6 OEhnMvAFTRhzXTPNZIOLbrmjbgNI5xbgkiNvXFOdyTzUG1Vt0DQqyK6mHyXyQdTisBitmr xMZi0TzZj6qfJ5OM9vbCMShKjHCdoiuyKlbbE87EHnftmr5N3Dm9B+qtldzchg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137836; 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=9DP/e1DT/62ihFXl8qmJq9SmFzxPwxY2SRfccOVI3O4=; b=TYE8NO3iygY/DSfpXID1scZ3f2tbEnyD4sieHRh1vCE7TWR1pqdQekt07QT6hDnbytthgA RLATjOqzM9crK8Y5RunfnYDPSXQDdcY23nnw+xmiEwmlIgD8WHZjvAlffsDUS5NGMfkz+a af1qqsGgCIodj/vYF7dh3AqiXmTrV5a28L2iA+zG8xxXaFZ6nzrBjXusfNkWkD/fGO9K5H JpbHXOaGjTPLpDh04IWl6e0CwIQX5xr40jr7qRve9BWQaLxVJTY7WCxBXE14yymzBJZILg uS2Os2Cr8L8YYaKAp15NQBWR2Nj7etZAKSUpdiSpQXuH3vs6uL/qjD8cOn/rSw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137836; a=rsa-sha256; cv=none; b=PsU1R4Yt0EVfv6dsvu1ckOm4CDxvrAC0xc6W5EsaQDahQACtyhLp7btcGxAiUXJ1TssgFZ 23gG2DOrtY+VoO1GjV72hmveMQFUXFENSMamhENz7BxfE2IA5rfCp/gnz7T++zUMavKp9Z KPpdikrp31bLDpV0WbhENe7ykUQmUB/wTiB5sg8dGfJClselqWjlTD3cuUmsiTEB9yNaSk m4LRi18fEXC4t7QdDLquMcMlkJfKRrFKeVyZlO7h53XjTyPlOqNKwOGY/+48c1y0gzO7Ow 7Yds6Ep8pyVoh8I80mXLq2kRqdtYDri4ONoTdUeaoBfFFXv/o7pp4tq8ARs1cA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRptz6jQgzgg0; Wed, 17 Sep 2025 19:37:15 +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 58HJbFa1015438; Wed, 17 Sep 2025 19:37:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJbFq0015435; Wed, 17 Sep 2025 19:37:15 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:37:15 GMT Message-Id: <202509171937.58HJbFq0015435@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 673f8232146a - stable/14 - pkg(7): Add support for pkg+ prefix to bootstrap pubkey 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 673f8232146a0c9beb481988b06eeae6f08d934d Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=673f8232146a0c9beb481988b06eeae6f08d934d commit 673f8232146a0c9beb481988b06eeae6f08d934d Author: Seyed Pouria Mousavizadeh Tehrani AuthorDate: 2025-09-11 07:01:54 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:36:30 +0000 pkg(7): Add support for pkg+ prefix to bootstrap pubkey MFC After: 1 day Sponsored by: Amn Afzar Hoopad Inc Differencial Revision: https://reviews.freebsd.org/D52418 (cherry picked from commit 08b8843137b8be3f71608400907cb38bcda14965) --- usr.sbin/pkg/pkg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/pkg/pkg.c b/usr.sbin/pkg/pkg.c index 9617fcacf4a6..1ff0961fb39e 100644 --- a/usr.sbin/pkg/pkg.c +++ b/usr.sbin/pkg/pkg.c @@ -901,7 +901,7 @@ bootstrap_pkg(bool force, const char *fetchOpts, struct repository *repo) getenv("TMPDIR") ? getenv("TMPDIR") : _PATH_TMP, bootstrap_name); snprintf(url, MAXPATHLEN, "%s/Latest/%s.pubkeysig", - repo->url, bootstrap_name); + packagesite, bootstrap_name); if ((fd_sig = fetch_to_fd(repo, url, tmpsig, fetchOpts)) == -1) { fprintf(stderr, "Signature for pkg not " From nobody Wed Sep 17 19:37:16 2025 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 4cRpv10KrVz67x0m; Wed, 17 Sep 2025 19:37:17 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRpv06zQvz4DqX; Wed, 17 Sep 2025 19:37:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137836; 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=zF6LVjK4tmW9LCemD/MxesIu4FXaER1bYofeBOidtCs=; b=LnSHaRwYVcWM/c8JO3GJug4oURa8uRKeQ3DLzRwVpg0jqcpqXFREWN9gNlS2BgXOjCAjZ7 tagZrC2gk/v11n6CpyJgE5kFY5MojJlutEeCOSa/q2eBKcvxxq9ZfrfYl9Kj6l0sV3Lniz zlsdjxm3KV/fpDOrZtJcTVGWF95slTnCQddvFkuBGRMic0fkSrv0/ZQPpAGsJ1Wfd1shPj CqJ+wdban6gzAI+msvcMTmNDbLx//AtrkxYHMj4Ztsfb+Q44B8vnyQvMRRSg/kXdf4LGbJ VWYWf8ivf4qxot0kGfC30Pdi4lqBntOQnAiT2IqEdx+zzJR7/Y5+Vy4ga9QvNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137836; 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=zF6LVjK4tmW9LCemD/MxesIu4FXaER1bYofeBOidtCs=; b=DmqEpetwkTWtLPP+uvh4xElZpdRNO/FKofxUGaj5KvOqnrdabbyhvH4tDqkCS/G+ncJz4B LM+Zx7aBeCouHsYTvYCOVBlyhxT6Ty33yP6Ux9pNJW2Hxb3tgL16IT+EkLiXzOZmTxSUN5 v0CJgIh8eWuosC3V/Uzr8PJq2UL7K0N0PnPBkOKQ6zP5FeQbJcQl2eC90cbO6TdpPz1BQa jITxo1T6e/cCYcfPbgqZuc/X9zXCE8i2WZC6DI/bxHNPLgr+fLLR36kr7iJ/w9FUsCp76G lQOlaGZQttrFUmRxi4b4vFy0Yfqt+tShNQyAnGdBKCqIQbjtoEy2FDS99lHgIA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137836; a=rsa-sha256; cv=none; b=A9cN39wbzOs78fMLbD/Faj3rREBvcqJ+jr1X2Fm+wwRq4lk90+fHZNwHSQzcHdXVlvKytg uXpH1FHpBVHdDjlF9mjQWNcOa6Sqt0xv1s9Yhkqelbd+3bHEEPx1p/QNfUEIfs60PRrDun /T6NFHxjmdc4k+vVEzFlinvl3JbxQrT/cMBO6ExSHEQ2TU/qItWOjDyWFuvyN6tJMF3EOL lGCHkwPeAhXCzbmWShsPLs1MSII8j0DHOP1Tfmx8ulAQZqEVypjMX6VI044cqsrwQeF+Mc RcJISUyCqnm2cG8bceS2kEv0qZRv/MRYYvw/kuwg/qZ8JZcq6Cv/zPWWCBbWTQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRpv06Yx6zgB8; Wed, 17 Sep 2025 19:37:16 +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 58HJbGxZ015470; Wed, 17 Sep 2025 19:37:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJbGwQ015467; Wed, 17 Sep 2025 19:37:16 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:37:16 GMT Message-Id: <202509171937.58HJbGwQ015467@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 30e3f9665eb0 - stable/14 - pci_vendors: update to 2025-07-11 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 30e3f9665eb033f923f81703cd7c6feeabe327c4 Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=30e3f9665eb033f923f81703cd7c6feeabe327c4 commit 30e3f9665eb033f923f81703cd7c6feeabe327c4 Author: Baptiste Daroussin AuthorDate: 2025-09-11 07:53:32 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:36:30 +0000 pci_vendors: update to 2025-07-11 (cherry picked from commit 2e72bd422956f831ec7e54255bd12fb721887f4a) --- share/misc/pci_vendors | 1005 +++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 914 insertions(+), 91 deletions(-) diff --git a/share/misc/pci_vendors b/share/misc/pci_vendors index 6dfe12dfc8ad..6fb8865340a0 100644 --- a/share/misc/pci_vendors +++ b/share/misc/pci_vendors @@ -1,8 +1,8 @@ # # List of PCI ID's # -# Version: 2025.03.09 -# Date: 2025-03-09 03:15:02 +# Version: 2025.07.11 +# Date: 2025-07-11 03:15:02 # # Maintained by Albert Pool, Martin Mares, and other volunteers from # the PCI ID Project at https://pci-ids.ucw.cz/. @@ -114,6 +114,8 @@ 0b70 NVMe DC SSD [Yorktown controller] 2b59 NVMe DC SSD [Atomos Prime] 025e 0008 NVMe DC SSD U.2-SFF 15mm [D7-PS1010] + 025e 000c NVMe DC SSD E1.S 9.5mm [D7-PS1010] + 025e 000d NVMe DC SSD E1.S 15mm [D7-PS1010] 025e 0019 NVMe DC SSD E3.S-1T 7.5mm [D7-PS1010] 025e 0108 NVMe DC SSD U.2-SFF 15mm [D7-PS1030] 025e 0119 NVMe DC SSD E3.S-1T 7.5mm [D7-PS1030] @@ -154,6 +156,14 @@ 0202 GP202 0721 Sapphire, Inc. 0731 Jingjia Microelectronics Co Ltd + 1100 JM1100 + 0731 1101 JM1100-C + 0731 1102 JM1100-II + 0731 1103 JM1100-I + 0731 1104 JM1100-M + 0731 1105 JM1100-Y + 0731 1106 JM1100-EI + 0731 1107 JM1100-EM 7200 JM7200 Series GPU 0731 7201 JM7201 0731 7202 JM7202 @@ -191,6 +201,9 @@ 0731 930b JH930-M 0731 930c JH930 930b JH930-M + f011 JM1100-IV + f111 JM1100-MV + ff11 JM1100-YV 0777 Ubiquiti Networks, Inc. 0795 Wired Inc. 6663 Butane II (MPEG2 encoder board) @@ -642,7 +655,7 @@ 1bd4 000e 6G SAS2008IR 1bd4 000f 6G SAS2008IT SA5248 1bd4 0010 6G SAS2008IR SA5248 - 4c52 96c8 LRSA96C8 8-Port SATA3(6Gb/s)Exchange Adapter (with Raid) + 4c52 96c8 LRSA96C8 8-Port SATA3 (6Gb/s) Exchange Adapter (with RAID) 8086 350f RMS2LL040 RAID Controller 8086 3700 SSD 910 Series 0073 MegaRAID SAS 2008 [Falcon] @@ -775,6 +788,9 @@ 1000 30a0 SAS9300-8e 1000 30e0 SAS9300-8i 1000 3130 SAS 9300-16i + 1000 3170 SAS9302-16e +# IBM SAS3008 HBA controller + 1014 0457 9302-8i [N2215] 1028 1f45 HBA330 Adapter 1028 1f46 12Gbps HBA 1028 1f53 HBA330 Mini @@ -869,6 +885,9 @@ 1000 5030 eHBA 9700-16e 24G SAS/PCIe Storage Adapter 1028 22d2 PERC H975i Front 1028 22d3 PERC H975i Adapter + 1028 23cb PERC H975i Front + 1028 23cd PERC H975i Adapter + 1028 2446 PERC H976i Front 1d49 020b ThinkSystem 460-16e SAS/SATA PCIe Gen5 24Gb HBA 00b5 Fusion-MPT 24G SAS/PCIe SAS50xx/SAS51xx # 9760W 32 internal port RAID controller @@ -883,6 +902,11 @@ 1000 5021 eHBA 9700W-16i 24G SAS/PCIe Storage Adapter # 9700 16 external port Storage controller 1000 5030 eHBA 9700-16e 24G SAS/PCIe Storage Adapter + 1028 22d2 PERC H975i Front - Virtual + 1028 22d3 PERC H975i Adapter - Virtual + 1028 23cb PERC H975i Front - Virtual + 1028 23cd PERC H975i Adapter - Virtual + 1028 2446 PERC H976i Front - Virtual # Broadcom next-gen MPT PCIe switch 00b8 Fusion-MPT Switch SAS50xx/SAS51xx 00be SAS3504 Fusion-MPT Tri-Mode RAID On Chip (ROC) @@ -1293,12 +1317,12 @@ 15ff Fenghuang [Zhongshan Subor Z+] 1607 Arden 1636 Renoir [Radeon Vega Series / Radeon Vega Mobile Series] - 1637 Renoir Radeon High Definition Audio Controller + 1637 Renoir/Cezanne HDMI/DP Audio Controller 1638 Cezanne [Radeon Vega Series / Radeon Vega Mobile Series] 1043 16c2 Radeon Vega 8 # Used in the Steam Deck LCD 163f VanGogh [AMD Custom GPU 0405] - 1640 Rembrandt Radeon High Definition Audio Controller + 1640 Radeon High Definition Audio Controller [Rembrandt/Strix] 164c Lucienne 164d Rembrandt 164e Raphael @@ -1306,8 +1330,9 @@ 1681 Rembrandt [Radeon 680M] 1714 BeaverCreek HDMI Audio [Radeon HD 6500D and 6400G-6600G series] 103c 168b ProBook 4535s - 1900 Phoenix3 - 1901 Phoenix4 + 1900 HawkPoint1 + 1901 HawkPoint2 + 1902 Krackan2 3150 RV380/M24 [Mobility Radeon X600] 103c 0934 nx8220 3151 RV380 GL [FireMV 2400] @@ -3054,6 +3079,7 @@ 1458 22ed Radeon RX 560 148c 2381 Radeon RX 560 1682 9560 Radeon RX 560 + 1849 5037 PHANTOM G R RX550 2G/M/ASRK 1da2 e348 Radeon RX 560 1da2 e367 Radeon RX 550 640SP 6800 Wimbledon XT [Radeon HD 7970M] @@ -3284,6 +3310,7 @@ 1002 6b76 AMD Radeon RX Vega 56 8GB # ROG-STRIX-RXVEGA64-O8G-GAMING 1043 04c4 Radeon RX Vega 64 + 1043 0555 ROG STRIX RX Vega 56 8GB 1458 230c Radeon RX VEGA 56 GAMING OC 8G 1da2 e376 Radeon RX VEGA 56 Pulse 8GB OC HBM2 6880 Lexington [Radeon HD 6550M] @@ -3993,6 +4020,7 @@ 1da2 e410 Sapphire NITRO+ RX 5700 XT 1da2 e411 Navi 10 [Radeon RX 5600 OEM/5600 XT / 5700/5700 XT]Navi 10 [Radeon RX 5600 OEM/5600 XT / 5700/5700 XT] 7340 Navi 14 [Radeon RX 5500/5500M / Pro 5500M] + 106b 0210 Radeon Pro 5300M 7341 Navi 14 [Radeon Pro W5500] 7347 Navi 14 [Radeon Pro W5500M] 734f Navi 14 [Radeon Pro W5300M] @@ -4085,6 +4113,7 @@ 7461 Navi 32 [AMD Radeon PRO V710] 7470 Navi 32 [Radeon PRO W7700] 747e Navi 32 [Radeon RX 7700 XT / 7800 XT] + 148c 2427 RX 7800 XT [Hellhound / Red Devil] 7480 Navi 33 [Radeon RX 7600/7600 XT/7600M XT/7600S/7700S / PRO W7600] 1849 5313 RX 7600 Challenger OC 7481 Navi 33 [Radeon Graphics] @@ -4093,14 +4122,20 @@ 7489 Navi 33 [Radeon Pro W7500] 748b Navi 33 [Radeon Graphics] 7499 Navi 33 [Radeon RX 7400/7300/Pro W7400] + 749f Navi 33 [Radeon RX 7500] 74a0 Aqua Vanjaram [Instinct MI300A] 74a1 Aqua Vanjaram [Instinct MI300X] 74a2 Aqua Vanjaram [Instinct MI308X] 74a5 Aqua Vanjaram [Instinct MI325X] 74a9 Aqua Vanjaram [Instinct MI300X HF] 74b5 Aqua Vanjaram [Instinct MI300X VF] + 74b9 Aqua Vanjaram [Instinct MI325X VF] 74bd Aqua Vanjaram [Instinct MI300X HF] - 7550 Navi 48 [RX 9070/9070 XT] + 7550 Navi 48 [Radeon RX 9070/9070 XT/9070 GRE] + 148c 2435 Reaper Radeon RX 9070 XT 16GB GDDR6 (RX9070XT 16G-A) + 1da2 e490 Navi 48 XTX [Sapphire Pulse Radeon RX 9070 XT] + 7551 Navi 48 [Radeon AI PRO R9700] + 7590 Navi 44 [Radeon RX 9060 XT] 7833 RS350 Host Bridge 7834 RS350 [Radeon 9100 PRO/XT IGP] 7835 RS350M [Mobility Radeon 9000 IGP] @@ -4505,6 +4540,7 @@ ab28 Navi 21/23 HDMI/DP Audio Controller ab30 Navi 31 HDMI/DP Audio ab38 Navi 10 HDMI Audio + ab40 Navi 48 HDMI/DP Audio Controller ac00 Theater 506 World-Wide Analog Decoder ac01 Theater 506 World-Wide Analog Decoder ac02 TV Wonder HD 600 PCIe @@ -4948,6 +4984,7 @@ 1014 04fc PCIe3 x8 12Gb Quad SAS RAID+ Adapter(580A) 04ed Internal Shared Memory (ISM) virtual PCI device 0611 4769 Cryptographic Adapter + 06a2 4770 Cryptographic Adapter 06a7 Spyre Accelerator 06a8 Spyre Accelerator Virtual Function 3022 QLA3022 Network Adapter @@ -5295,6 +5332,8 @@ 1514 Family 14h Processor Root Port 1515 Family 14h Processor Root Port 1516 Family 14h Processor Root Port + 151c USB4 Router 0 + 151d USB4 Router 1 1530 Family 16h Processor Function 0 1531 Family 16h Processor Function 1 1532 Family 16h Processor Function 2 @@ -5364,6 +5403,12 @@ 1583 Family 16h (Models 30h-3fh) Processor Function 3 1584 Family 16h (Models 30h-3fh) Processor Function 4 1585 Family 16h (Models 30h-3fh) Processor Function 5 + 1587 Strix Halo USB 3.1 xHCI + 1588 Strix Halo USB 3.1 xHCI + 1589 Strix Halo USB 3.1 xHCI + 158b Strix Halo USB 3.1 xHCI + 158d Strix Halo USB4 Host Router + 158e Strix Halo USB4 Host Router 1590 Amur/Nolan HT Configuration 1591 Amur/Nolan Address Maps 1592 Amur/Nolan DRAM Configuration @@ -5410,7 +5455,7 @@ 15dc Raven/Raven2 Internal PCIe GPP Bridge 0 to Bus B ea50 ce19 mCOM10-L1900 15de Raven/Raven2/FireFlight HD Audio Controller - 15df Family 17h (Models 10h-1fh) Platform Security Processor + 15df Raven/Raven2/FireFlight/Renoir/Cezanne Platform Security Processor 1043 876b PRIME Motherboard 17aa 5124 ThinkPad E595 ea50 ce19 mCOM10-L1900 @@ -5424,7 +5469,7 @@ 1043 876b PRIME Motherboard 17aa 5124 ThinkPad E595 ea50 ce19 mCOM10-L1900 - 15e2 ACP/ACP3X/ACP6x Audio Coprocessor + 15e2 Audio Coprocessor 17aa 5124 ThinkPad E595 ea50 ce19 mCOM10-L1900 15e3 Family 17h/19h/1ah HD Audio Controller @@ -5653,9 +5698,11 @@ 43c8 400 Series Chipset SATA Controller 43d5 400 Series Chipset USB 3.1 xHCI Compliant Host Controller 43e9 500 Series Chipset Switch Upstream Port + 43ea 500 Series Chipset Switch Downstream Port 43eb 500 Series Chipset SATA Controller # or ASM106X Serial ATA Controller 1b21 1062 ASM1062 Serial ATA Controller + 43ec A520 Series Chipset USB 3.1 XHCI Controller 43ee 500 Series Chipset USB 3.1 XHCI Controller # maybe 1b21 1142 ASM1042A USB 3.0 Host Controller @@ -5663,6 +5710,7 @@ 43f5 600 Series Chipset PCIe Switch Downstream Port 43f6 600 Series Chipset SATA Controller 43f7 600 Series Chipset USB 3.2 Controller + 43fc 800 Series Chipset USB 3.x XHCI Controller 43fd 800 Series Chipset USB 3.x XHCI Controller 57a3 Matisse PCIe GPP Bridge 57a4 Matisse PCIe GPP Bridge @@ -5998,6 +6046,7 @@ 1028 1f24 PERC S300 Controller # NV-RAM Adapter used in Dell DR appliances 0073 NV-RAM Adapter + 0c46 PERC S160 RAID controller 1028 PCIe Bridge riser 2600 ENT NVMe RT1 1028 215e ENT NVMe RT1 RI 3.84TB @@ -7225,6 +7274,7 @@ 8004 DTL-H2500 [Playstation development board] 8009 CXD1947Q i.LINK Controller 800c DTL-H800 [PS1 sound development board] + 800d DVBK-2000(E) DV Still Image Capture Board 8039 CXD3222 i.LINK Controller 8047 PS2 TOOL MRP 8056 Rockwell HCF 56K modem @@ -7796,6 +7846,7 @@ 103c 1939 QMH2672 16Gb Dual Port Fibre Channel Adapter 103c 8002 3830C 16G Fibre Channel Host Bus Adapter 1077 0241 QLE2670 16Gb Single Port Fibre Channel Adapter + 1077 0249 QLE2672 16Gb Dual Port Fibre Channel Adapter 2071 ISP2714-based 16/32Gb Fibre Channel to PCIe Adapter 1077 0283 QLE2764 Quad Port 32Gb Fibre Channel to PCIe Adapter 1077 029e QLE2694 Quad Port 16Gb Fibre Channel to PCIe Adapter @@ -7864,6 +7915,8 @@ 1077 0167 QME2572 Dual Port FC8 HBA Mezzanine 1590 00fc StoreFabric 84Q 8Gb Quad Port Fibre Channel Host Bus Adapter 2971 ISP2684 + 2981 32G SFP28 EP2744 Apatter + 1bd4 00b0 32G SFP28 EP2744 Apatter 3022 ISP4022-based Ethernet NIC 3032 ISP4032-based Ethernet IPv6 NIC 4010 ISP4010-based iSCSI TOE HBA @@ -9404,13 +9457,16 @@ 8664 PEX 8664 64-lane, 16-Port PCI Express Gen 2 (5.0 GT/s) Switch 8680 PEX 8680 80-lane, 20-Port PCI Express Gen 2 (5.0 GT/s) Multi-Root Switch 8696 PEX 8696 96-lane, 24-Port PCI Express Gen 2 (5.0 GT/s) Multi-Root Switch + 8714 PEX 8714 12-Lane, 5-Port PCI Express Gen 3 (8 GT/s) Switch 8717 PEX 8717 16-lane, 8-Port PCI Express Gen 3 (8.0 GT/s) Switch with DMA 8718 PEX 8718 16-Lane, 5-Port PCI Express Gen 3 (8.0 GT/s) Switch + 8723 PEX 8723 24-Lane, 6-Port PCI Express Gen 3 (8 GT/s) Switch 8724 PEX 8724 24-Lane, 6-Port PCI Express Gen 3 (8 GT/s) Switch, 19 x 19mm FCBGA 4c52 9234 LRNV9324 2-port Built-in 8643 NVMe Exchange Adapter 4c52 9524 LRNV9524 2-port M.2 NVMe SSD Exchange Adapter 8725 PEX 8725 24-Lane, 10-Port PCI Express Gen 3 (8.0 GT/s) Multi-Root Switch with DMA 8732 PEX 8732 32-lane, 8-Port PCI Express Gen 3 (8.0 GT/s) Switch + 8733 PEX 8733 32-Lane, 19-Port PCI Express Gen 3 (8 GT/s) Switch 8734 PEX 8734 32-lane, 8-Port PCI Express Gen 3 (8.0GT/s) Switch 8747 PEX 8747 48-Lane, 5-Port PCI Express Gen 3 (8.0 GT/s) Switch 4c52 9347 LRNV9347L 2-port Built-in 8643 NVMe Switching Adapter @@ -9418,6 +9474,9 @@ 8748 PEX 8748 48-Lane, 12-Port PCI Express Gen 3 (8 GT/s) Switch, 27 x 27mm FCBGA 8749 PEX 8749 48-Lane, 18-Port PCI Express Gen 3 (8.0 GT/s) Multi-Root Switch with DMA 4c52 9349 LRNV9349 8-port SFF-8643 NVMe SSD Exchange Adapter + 8764 PEX 8764 64-Lane, 16-Port PCI Express Gen 3 (8 GT/s) Switch + 8780 PEX 8780 80-Lane, 20-Port PCI Express Gen 3 (8 GT/s) Switch + 8796 PEX8796 96-Lane, 24-Port PCIe Gen 3 (8.0 GT/s) Switch 87a0 PEX PCI Express Switch NT0 Port Link Interface 87a1 PEX PCI Express Switch NT1 Port Link Interface 87b0 PEX PCI Express Switch NT0 Port Virtual Interface @@ -9576,11 +9635,15 @@ 1517 000f ECDR-GC314-PMC Receiver 1885 0700 Tsunami FPGA PMC with Altera Stratix S40 1885 0701 Tsunami FPGA PMC with Altera Stratix S30 + 9712 PEX9712 12-Lane, 5-Port PCIe Gen 3 (8.0 GT/s) ExpressFabric Switch 9733 PEX 9733 33-lane, 9-port PCI Express Gen 3 (8.0 GT/s) Switch 1d49 0001 ThinkSystem 1610-4P NVMe Switch Adapter 1d49 0002 ThinkSystem 810-4P NVMe Switch Adapter 9749 PEX 9749 49-lane, 13-port PCI Express Gen 3 (8.0 GT/s) Switch 1d49 0004 ThinkSystem 1610-8P NVMe Switch Adapter + 9765 PEX9765 65-Lane, 17-Port PCIe Gen 3 (8.0 GT/s) ExpressFabric Switch + 9781 PEX9781 81-Lane, 21-Port PCIe Gen 3 (8.0 GT/s) ExpressFabric Switch + 9797 PEX9781 97-Lane, 25-Port PCIe Gen 3 (8.0 GT/s) ExpressFabric Switch a100 Blackmagic Design DeckLink bb04 B&B 3PCIOSD1A Isolated PCI Serial c001 CronyxOmega-PCI (8-port RS232) @@ -11982,6 +12045,8 @@ 0fa0 GK11x [GK11x_FPGA] 0fa5 GK11x 0fa7 GK11x [Tegra on x86 (PEATRANS)] + 0fae Tegra X1 PCIe x4 Root Complex + 0faf Tegra X1 PCIe x1 Root Complex 0fb0 GM200 High Definition Audio 0fb8 GP108 High Definition Audio Controller 0fb9 GP107GL High Definition Audio Controller @@ -12178,6 +12243,8 @@ 10c3 GT218 [GeForce 8400 GS Rev. 3] 10c5 GT218 [GeForce 405] 10d8 GT218 [NVS 300] + 10e5 Parker PCIe x4 Root Complex + 10e6 Parker PCIe x1 Root Complex 10ef GP102 HDMI Audio Controller 10f0 GP104 High Definition Audio Controller 10f1 GP106 High Definition Audio Controller @@ -12860,7 +12927,7 @@ 1aed TU116 USB Type-C UCSI Controller 1aef GA102 High Definition Audio Controller 1af1 GA100 [A100 NVSwitch] - 1b00 GP102 [TITAN X] + 1b00 GP102 [TITAN X Pascal] 1b01 GP102 [GeForce GTX 1080 Ti 10GB] 1b02 GP102 [TITAN Xp] 1b04 GP102 @@ -13184,11 +13251,16 @@ 228e GA106 High Definition Audio Controller 2291 GA107 High Definition Audio Controller 2296 Tegra PCIe Endpoint Virtual Network + 229a Orin PCIe x8 Root Complex + 229c Orin PCIe x4/x8 Endpoint/Root Complex + 229e Orin PCIe x1 Root Complex 22a3 GH100 [H100 NVSwitch] 22ba AD102 High Definition Audio Controller 22bc AD104 High Definition Audio Controller 22bd AD106M High Definition Audio Controller 22be AD107 High Definition Audio Controller + 22d8 THOR Processor PCI Express Root Port + 22e6 THOR Processor PCI Express x16 Controller 2302 GH100 230e GH100 [H20 NVL16] 2313 GH100 [H100 CNX] @@ -13376,31 +13448,53 @@ 28f8 AD107GLM [RTX 2000 Ada Generation Embedded GPU] 2900 GB100 [Reserved Dev ID A] 2901 GB100 [B200] - 2920 GB100 [TS4] + 2920 GB100 [TS4 / B100] + 2924 GB100 + 2925 GB100 + 293d GB100 2940 GB100 [Reserved Dev ID B] 2941 GB100 [HGX GB200] + 297e GB100 2980 GB102 [Reserved Dev ID A] 29bc GB102 [B100] 29c0 GB102 [Reserved Dev ID B] + 29f1 GB102 + 2b00 TA1090SA [THOR] 2b85 GB202 [GeForce RTX 5090] 2b87 GB202 [GeForce RTX 5090 D] + 2bb1 GB202GL [RTX PRO 6000 Blackwell Workstation Edition] + 2bb3 GB202GL [RTX PRO 5000 Blackwell] + 2bb4 GB202GL [RTX PRO 6000 Blackwell Max-Q Workstation Edition] + 2bb5 GB202GL [RTX PRO 6000 Blackwell Server Edition] 2c02 GB203 [GeForce RTX 5080] 2c05 GB203 [GeForce RTX 5070 Ti] 2c18 GB203M / GN22 [GeForce RTX 5090 Max-Q / Mobile] 2c19 GB203M / GN22 [GeForce RTX 5080 Max-Q / Mobile] 2c2c GB6-256(N22W-ES-A1) + 2c31 GB203GL [RTX PRO 4500 Blackwell] + 2c34 GB203GL [RTX PRO 4000 Blackwell] + 2c38 GB203GLM [RTX PRO 5000 Blackwell Generation Laptop GPU] + 2c39 GB203GLM [RTX PRO 4000 Blackwell Generation Laptop GPU] 2c58 GB203M / GN22-X11 [GeForce RTX 5090 Max-Q / Mobile] 2c59 GB203M / GN22-X9 [GeForce RTX 5080 Max-Q / Mobile] - 2d18 AD108M [GeForce RTX 5070 Max-Q / Mobile] - 2d19 AD108M [GeForce RTX 5060 Max-Q / Mobile] + 2d04 GB206 [GeForce RTX 5060 Ti] + 2d05 GB206 [GeForce RTX 5060] + 2d18 GB206M [GeForce RTX 5070 Max-Q / Mobile] + 2d19 GB206M [GeForce RTX 5060 Max-Q / Mobile] 2d2c GB6-128 (N22Y-ES-A1) - 2d58 AD108M [GeForce RTX 5070 Max-Q / Mobile] - 2d59 AD108M [GeForce RTX 5060 Max-Q / Mobile] - 2d98 AD108M [GeForce RTX 5050 Max-Q / Mobile] - 2dd8 AD108M [GeForce RTX 5050 Max-Q / Mobile] - 2f04 GN22 [GeForce RTX 5070] - 2f18 AD108M [GeForce RTX 5070 Ti Max-Q / Mobile] - 2f58 AD108M [GeForce RTX 5070 Ti Max-Q / Mobile] + 2d39 GB206GLM [RTX PRO 2000 Blackwell Generation Laptop GPU] + 2d58 GB206M [GeForce RTX 5070 Max-Q / Mobile] + 2d59 GB206M [GeForce RTX 5060 Max-Q / Mobile] + 2d83 GB207 [GeForce RTX 5050] + 2d98 GB207M [GeForce RTX 5050 Max-Q / Mobile] + 2db8 GB207GLM [RTX PRO 1000 Blackwell Generation Laptop GPU] + 2db9 GB207GLM [RTX PRO 500 Blackwell Generation Laptop GPU] + 2dd8 GB207M [GeForce RTX 5050 Max-Q / Mobile] + 2e2a GB20B + 2f04 GB205 [GeForce RTX 5070] + 2f18 GB205M [GeForce RTX 5070 Ti Mobile] + 2f38 GB205GLM [RTX PRO 3000 Blackwell Generation Laptop GPU] + 2f58 GB205M [GeForce RTX 5070 Ti Mobile] 31c0 GB110 3340 GB120 10df Emulex Corporation @@ -13554,6 +13648,7 @@ 0860 CA91C860 [QSpan] 0862 CA91C862A [QSpan-II] 8111 Tsi381 PCIe to PCI Bridge + 8113 89HPEB383 PCIe-to-PCI Bridge 8260 CA91L8200B [Dual PCI PowerSpan II] 8261 CA91L8260B [Single PCI PowerSpan II] a108 Tsi109 Host Bridge for Dual PowerPC @@ -13623,6 +13718,7 @@ 5227 RTS5227 PCI Express Card Reader 17aa 220e ThinkPad T440p 17aa 2214 ThinkPad X240 + 5228 RTS5288 PCIe SD UHS-I Card Reader controller 5229 RTS5229 PCI Express Card Reader 1025 0813 Aspire R7-571 103c 194e ProBook 455 G1 Notebook @@ -13646,7 +13742,8 @@ 1028 0c06 Precision 3580 17aa 224f ThinkPad X1 Carbon 5th Gen 5260 RTS5260 PCI Express Card Reader - 5261 RTS5261 PCI Express Card Reader + 5261 RTS5261 PCIe SD Express Card Reader controller + 5264 RTS5264 PCIe SD UHS-II & SD Express Card Reader controller 5286 RTS5286 PCI Express Card Reader 5287 RTL8411B PCI Express Card Reader 1025 1094 Acer Aspire E5-575G @@ -13658,6 +13755,7 @@ 5763 RTS5763DL NVMe SSD Controller (DRAM-less) 5765 RTS5765DL NVMe SSD Controller (DRAM-less) 5770 RTS5770DL NVMe SSD Controller (DRAM-less) + 5771 RTS5771 NVMe SSD Controller (DRAM-less) 5772 RTS5772DL NVMe SSD Controller (DRAM-less) 8029 RTL-8029(AS) 10b8 2011 EZ-Card (SMC1208) @@ -13856,6 +13954,7 @@ 103c 831b Realtek RTL8822BE 802.11ac 2x2 Wi-Fi + Bluetooth 4.2 Combo Adapter (MU-MIMO supported) 17aa 5124 ThinkPad E595 17aa b023 ThinkPad E595 + b851 RTL8851BE PCIe 802.11ax Wireless Network Controller b852 RTL8852BE PCIe 802.11ax Wireless Network Controller b85b RTL8852BE PCIe 802.11ax Wireless Network Controller [1T1R] c821 RTL8821CE 802.11ac PCIe Wireless Network Adapter @@ -14078,6 +14177,8 @@ 000b EMU20k2 [Sound Blaster X-Fi Titanium Series] 1102 0041 SB0880 [SoundBlaster X-Fi Titanium PCI-e] 1102 0062 SB1270 [SoundBlaster X-Fi Titanium HD] + 0010 CA0132 Sound Core3D [Sound Blaster AE-7] + 1102 0081 Sound Blaster AE-7 0012 CA0132 Sound Core3D [Sound Blaster Recon3D / Z-Series / Sound BlasterX AE-5 Plus] 1102 0010 SB1570 SB Audigy Fx 1102 0191 CA0132 Sound Core3D - CA0113 [ Sound BlasterX AE-5 Plus] @@ -14252,7 +14353,7 @@ 0585 VT82C585VP [Apollo VP1/VPX] 0586 VT82C586/A/B PCI-to-ISA [Apollo VP] 1106 0000 MVP3 ISA Bridge - 0591 VT8237A SATA 2-Port Controller + 0591 VT8237A Integrated SATA RAID Controller 0595 VT82C595 [Apollo VP2] 0596 VT82C596 ISA [Mobile South] 1106 0000 VT82C596/A/B PCI to ISA Bridge @@ -14610,6 +14711,7 @@ 3372 VT8237S PCI to ISA Bridge 337a VT8237A PCI to PCI Bridge 337b VT8237A Host Bridge + 3401 VT6325 Firewire Controller 3402 VT8261 PCI to ISA Bridge 3403 VT6315 Series Firewire Controller 1043 8374 M5A88-V EVO @@ -14622,7 +14724,11 @@ 3456 VX11 Standard Host Bridge 345b VX11 Miscellaneous Bus 3483 VL805/806 xHCI USB 3.0 Controller + 365a VT3365 Card Reader Host Controller + 365b VT3365 SDIO Host Controller 3a01 VX11 Graphics [Chrome 645/640] + 401a VT6325 Card Reader Host Controller + 401b VT6325 SDIO PCI-E Host Controller 4149 VIA VT6420 (ATA133) Controller 4204 K8M800 Host Bridge 4208 PT890 Host Bridge @@ -14657,17 +14763,18 @@ 5324 CX700M2/VX700/VX800/820-Series Serial ATA & EIDE-Controller 5327 P4M890 I/O APIC Interrupt Controller 5336 K8M890CE I/O APIC Interrupt Controller + 5337 VT8237A Integrated SATA Controller 5340 PT900 I/O APIC Interrupt Controller 5351 VT3351 I/O APIC Interrupt Controller 5353 VX800/VX820 APIC and Central Traffic Control 5364 CN896/VN896/P4M900 I/O APIC Interrupt Controller - 5372 VT8237/8251 Serial ATA Controller + 5372 VT8237S SATA Controller 5409 VX855/VX875 APIC and Central Traffic Control 5410 VX900 Series APIC and Central Traffic Control 5419 VN1000 I/O APIC Interrupt Controller 6100 VT85C100A [Rhine II] 6122 VN1000 Graphics [Chrome 520 IGP] - 6287 SATA RAID Controller + 6287 VT8251 AHCI SATA Controller 6290 K8M890CE Host Bridge 6327 P4M890 Security Device 6353 VX800/VX820 Scratch Registers @@ -14699,6 +14806,7 @@ 7351 VT3351 Host Bridge 7353 VX800/VX820 North-South Module Interface Control 7364 CN896/VN896/P4M900 Host Bridge + 7372 VT8237S SATA RAID Controller 7409 VX855/VX875 North-South Module Interface Control 7410 VX900 Series North-South Module Interface Control 19da a179 ZBOX nano VD01 @@ -14730,8 +14838,10 @@ 9000 VT8261 IDE Controller [StorX IDE Controller - 9000] 9001 VX900 Series Serial-ATA Controller 9040 VT8261 SATA Controller [StorX RAID Controller - 9040] + 9041 VX900/VX11 SATA Controller [StorX RAID Controller - 9041] 9082 Standard AHCI 1.0 SATA Controller - 9140 HDMI Audio Device + 9140 VX11 Graphics [Chrome 645/640] HDMI Audio Device + 9170 VX900 Graphics [Chrome9 HD] HDMI Audio Device 9201 USB3.0 Controller 9380 Ncore Coprocessor for Centaur CNS 9530 VX800/820/900/VT8261 Series Secure Digital Memory Card Controller @@ -15943,6 +16053,7 @@ 0115 XG4 NVMe SSD Controller 0116 XG5 NVMe SSD Controller 1179 0001 XG5 NVMe SSD Controller + 0119 XD5 NVMe SSD Controller 011a XG6 NVMe SSD Controller 0404 DVD Decoder card 0406 Tecra Video Capture device @@ -16144,7 +16255,7 @@ 103c 30cc Pavilion dv6700 103c 30cf Pavilion dv9668eg Laptop 17aa 20c5 ThinkPad R61 - 17aa 20c7 ThinkPad R61 + 17aa 20c7 ThinkPad R61/T400 0841 R5C841 CardBus/SD/SDIO/MMC/MS/MSPro/xD/IEEE1394 0843 R5C843 MMC Host Controller 1025 0121 Aspire 5920G @@ -16592,6 +16703,8 @@ 11bc Network Peripherals Inc 0001 NP-PCI 11bd Pinnacle Systems Inc. + 0015 FireWire Controller + 0023 Studio 700 002e PCTV 40i 0040 Royal TS Function 1 11bd 0044 PCTV 2000i Dual DVB-T Pro PCI Tuner 1 @@ -16893,6 +17006,10 @@ 11f7 Scientific Atlanta # née PMC-Sierra Inc. 11f8 Microchip Technology + 4036 PM40036 Switchtec PFX 36xG4 Fanout PCIe Switch + 4052 PM40052 Switchtec PFX 52xG4 Fanout PCIe Switch + 4084 PM40084 Switchtec PFX 84xG4 Fanout PCIe Switch + 4128 PM41028 Switchtec PSX 28xG4 Programmable PCIe Switch 5000 PM50100 Switchtec PFX 100xG5 Fanout PCIe Switch 5028 PM50028 Switchtec PFX 28xG5 Fanout PCIe Switch 5036 PM50036 Switchtec PFX 36xG5 Fanout PCIe Switch @@ -17220,6 +17337,8 @@ 1233 Bus-Tech, Inc. # nee Risq Modular Systems, Inc. 1235 SMART Modular Technologies + c241 CXA-4F1W + 1028 2382 4-DIMM Add In Card 1236 Sigma Designs Corporation 0000 RealMagic64/GX 6401 REALmagic 64/GX (SD 6425) @@ -17476,6 +17595,7 @@ 2261 SM2261XT x2 NVMe SSD Controller (DRAM-less) 2262 SM2262/SM2262EN SSD Controller 2263 SM2263EN/SM2263XT (DRAM-less) NVMe SSD Controllers + 2268 SM2268XT (DRAM-less) NVMe SSD Controller 2269 SM2269XT (DRAM-less) NVMe SSD Controller 8366 SM8366 NVMe SSD Controller [MonTitan] 1270 Olympus Optical Co., Ltd. @@ -18454,6 +18574,7 @@ 5416 2550 NVMe SSD (DRAM-less) 5425 2500 NVMe SSD (DRAM-less) 5427 2650 NVMe SSD (DRAM-less) + 5428 4600 NVMe SSD 5429 2600 NVMe SSD (DRAM-less) 6001 2100AI NVMe SSD [Nitro] 1345 Arescom Inc @@ -18528,6 +18649,8 @@ 0b22 UP-200 Powered 2 port RS-232 card 0b23 UP-200 Powered 2 port RS-232 card 0ba1 UC-101 1 + 1 port RS-232 card + 0ba2 UC-101 1 + 1 port RS-232 card + 0ba3 UC-101 1 + 1 port RS-232 card 0bc1 UC-203 1 + 1 port RS-232 + LPT card 0bc2 UC-203 1 + 1 port RS-232 + LPT card 0be1 UC-146 LPT card @@ -18539,6 +18662,8 @@ 0c22 UP-880 Powered 2 port RS-232 card 0c23 UP-880 Powered 2 port RS-232 card 0c41 UC-368 4 port RS-422/485 Opto Isolated card + 0c42 UC-368 4 port RS-422/485 Opto Isolated card + 0c43 UC-368 4 port RS-422/485 Opto Isolated card 0ca1 UC-253 2 port RS-232 card 0d21 UC-260 4 port RS-232 card 0d41 UC-836 4 port RS-232 card @@ -18578,6 +18703,10 @@ 401d PX-475 1 port RS-232 + LPT card (Serial port) 401e PX-803 Powered 1 + 1 port RS-232 card 401f PX-475 1 port RS-232 + LPT card (LPT port) + 4020 XC-157 LPT ExpressCard + 4021 XC-475 1 port RS-232 + LPT ExpressCard (Serial port) + 4022 XC-475 1 port RS-232 + LPT ExpressCard (LPT port) + 4026 XC-235 1 port RS-232 ExpressCard 4027 IX-100 1 port RS-232 card 4028 IX-200 2 port RS-232 card 4029 IX-400 4 port RS-232 card @@ -20294,6 +20423,8 @@ a80d NVMe SSD Controller PM9C1a (DRAM-less) a80e NVMe SSD Controller PM9D3a a80f BM9C1 QLC NVME SSD (DRAM-less) + a810 NVMe SSD 9100 PRO [PM9E1] + a811 BM9H1 NVME SSD (DRAM-less) a820 NVMe SSD Controller 171X 1028 1f95 Express Flash NVMe XS1715 SSD 400GB 1028 1f96 Express Flash NVMe XS1715 SSD 800GB @@ -20469,6 +20600,7 @@ 1458 Gigabyte Technology Co., Ltd 1002 Aourus Radeon RX6900XT Xtreme Waterforce WB 16G 22e8 Ellesmere [Radeon RX 480] + 2425 Radeon RX 9070 GAMING OC 16G 3483 USB 3.0 Controller (VIA VL80x-based xHCI Controller) 1459 DOOIN Electronics 145a Escalate Networks Inc @@ -20657,6 +20789,7 @@ 14c3 MEDIATEK Corp. 0608 MT7921K (RZ608) Wi-Fi 6E 80MHz 0616 MT7922 802.11ax PCI Express Wireless Network Adapter + 0717 MT7925 (RZ717) Wi-Fi 7 160MHz 4d75 T700 5G Modem [5G Solution 5000] 7603 MT7603E 802.11bgn PCI Express Wireless Network Adapter 7612 MT7612E 802.11acbgn PCI Express Wireless Network Adapter @@ -22155,6 +22288,7 @@ 9300 Universal Exhaust Gas Oxygen Sensor Simulator 9310 Digital Programmable Resistor 9320 Arria 10 FPGA Card + 9330 Cyclone V FPGA Card 9350 Analog Input Card 1543 SILICON Laboratories 3052 Intel 537 [Winmodem] @@ -22417,6 +22551,15 @@ 0290 SagittaZ 0292 Arcus3 Flash Recovery 0293 Arcus3 RMA + 0294 Ophy 2.1 (SagittaZ) +# Sagitta + 0296 OPHY2.6 +# Sagitta + 0298 OPHY3.0 +# Sagitta + 029a OPHY3.1 +# Sagitta + 029c OPHY3.5 02a0 Quantum-6 in Flash Recovery Mode 02a1 Quantum-6 RMA 02a2 Spectrum-7 in Flash Recovery Mode @@ -22503,6 +22646,7 @@ # NIC-ETH540F-3S-2P OCP3.0 2x10G Card 193d 1084 NIC-ETH540F-3S-2P 1e81 0c10 25GbE dual-port SFP28, PCIe3.0 x8 [3SC10] + 1f3f 0c10 25GbE dual-port SFP28, PCIe3.0 x8, 3SC10 1016 MT27710 Family [ConnectX-4 Lx Virtual Function] 1017 MT27800 Family [ConnectX-5] 117c 00b1 FastFrame N311 Single-port 10Gb Ethernet Adapter @@ -22529,6 +22673,7 @@ 193d 1035 NIC-ETH641F-LP-2P SFP28 2x25GbE PCIe Network Adapter 1bd4 00ac O252MCX6Lx 1bd4 00ae S252MCX6Lx + 1f3f 0c11 25GbE dual-port SFP28, PCIe4.0 x8, 3SC1125GbE dual-port SFP28, PCIe4.0 x8, 3SC11 1ff9 00ad ENFM6251-SP2 1ff9 00af ENPM6251-SP2 1020 MT28860 @@ -22688,7 +22833,7 @@ 5014 WD PC SN540 / Green SN350 NVMe SSD 1 TB (DRAM-less) 5015 PC SN740 NVMe SSD (DRAM-less) 5016 WD PC SN740 NVMe SSD 512GB (DRAM-less) - 5017 WD Black SN770 / PC SN740 256GB / PC SN560 (DRAM-less) NVMe SSD + 5017 WD SN560/SN740/SN770/SN5000 NVMe SSD 5019 WD Green SN350 240GB (DRAM-less) / SN560E NVMe SSD 501a SanDisk Ultra 3D / WD Blue SN570 NVMe SSD (DRAM-less) 501d WD Blue SN550 NVMe SSD 2TB (DRAM-less) @@ -22699,12 +22844,16 @@ 5028 WD CH SN560 NVMe SSD 5030 WD Black SN850X NVMe SSD 5034 WD PC SN5000S M.2 2230 NVMe SSD (DRAM-less) + 5035 WD PC SN5000S M.2 2242 NVMe SSD (DRAM-less) 5036 WD PC SN5000S M.2 2280 NVMe SSD (DRAM-less) 5041 WD Blue SN580 NVMe SSD (DRAM-less) 5042 WD Black SN770M NVMe SSD (DRAM-less) + 5044 WD PC SN7100S NVMe SSD (DRAM-less) 5045 WD_BLACK SN7100 NVMe SSD (DRAM-less) 5046 SanDisk Extreme NVMe SSD (DRAM-less) 5049 SN8000S NVMe SSD + 504a WD Blue SN5000 NVMe SSD (DRAM-less) + 5050 WD PC SN8050S / WD_BLACK SN8100 NVMe SSD 15b8 ADDI-DATA GmbH 1001 APCI1516 SP controller (16 digi outputs) 1003 APCI1032 SP controller (32 digi inputs w/ opto coupler) @@ -23843,6 +23992,8 @@ 010c SM8350 PCIe Root Complex [Snapdragon 888] 010e SC8280XP PCI Express Root Port 0110 SM8475 PCIe Root Complex [Snapdragon 8+ Gen 1] + 0111 SC8380XP PCIe Root Complex [Snapdragon X / X Plus / X Elite] + 0113 SM8550/SM8650 PCIe Root Complex [Snapdragon 8 Gen 2/Gen 3] 0300 MDM9x35 LTE Modem [Snapdragon X7] 0301 MDM9x45 LTE Modem [Snapdragon X12] 0302 MDM9x55 LTE Modem [Snapdragon X16] @@ -23851,6 +24002,7 @@ 0400 Datacenter Technologies QDF2432 PCI Express Root Port 0401 Datacenter Technologies QDF2400 PCI Express Root Port 1000 QCS405 PCIe Root Complex + 1003 IPQ6018 PCIe Root Complex 1101 QCA6390 Wireless Network Adapter 1103 QCNFA765 Wireless Network Adapter 1104 QCN6024/9024/9074 Wireless Network Adapter @@ -24714,6 +24866,14 @@ 0441 T4240 without security 0446 T4160 with security 0447 T4160 without security + 0820 T1040 with security + 0821 T1040 without security + 0824 T1042 with security + 0825 T1042 without security + 0828 T1020 with security + 0829 T1020 without security + 082c T1022 with security + 082d T1022 without security 0830 T2080 with security 0831 T2080 without security 0838 T2081 with security @@ -24851,15 +25011,18 @@ 5016 E16 PCIe4 NVMe Controller 5018 E18 PCIe4 NVMe Controller 5019 PS5019-E19 PCIe4 NVMe Controller (DRAM-less) + 5020 PS5020-E20 (X1) PCIe4 NVMe Controller 5021 PS5021-E21 PCIe4 NVMe Controller (DRAM-less) 5026 PS5026-E26 PCIe5 NVMe Controller 5027 PS5027-E27T PCIe4 NVMe Controller (DRAM-less) 5031 PS5031-E31T PCIe5 NVMe Controller + 5302 PS5302-X2 PCIe5 NVMe Controller 1989 Montilio Inc. 0001 RapidFile Bridge 8001 RapidFile 198a Nallatech Ltd. 1993 Innominate Security Technologies AG +1998 Toyou Feiji Electronics Co., Ltd. 1999 A-Logics a900 AM-7209 Video Processor 199a Pulse-LINK, Inc. @@ -25015,6 +25178,8 @@ a126 HiSilicon SDI NVMe Storage Controller a127 HiSilicon SDI Accelerator a12a HiSilicon Add-on PCI-PCI Bridge + a12d HiSilicon Embedded PMU + a12e HiSilicon Embedded PCIe PTT a220 HNS GE Network Controller a221 HNS GE/10GE/25GE Network Controller 19e5 0454 TM280 @@ -25102,6 +25267,12 @@ 1a3b AzureWave 1112 AR9285 Wireless Network Adapter (PCI-Express) 1a3e Micro-Research Finland Oy + 132c MTCA Event Receiver 300 + 152c CompactPCI Event Receiver 300 + 172c PCI Express Event Receiver 300 + 192c CompactPCI Event Receiver TG 300 + 232c MTCA Event Master 300 + 252c CompactPCI Event Generator 300 1a41 Tilera Corp. 0001 TILE64 processor 0002 TILEPro processor @@ -25323,19 +25494,83 @@ 1005 Virtio RNG 1009 Virtio filesystem 1041 Virtio 1.0 network device + 1af4 1100 QEMU 1042 Virtio 1.0 block device + 1af4 1100 QEMU 1043 Virtio 1.0 console + 1af4 1100 QEMU 1044 Virtio 1.0 RNG - 1045 Virtio 1.0 memory balloon + 1af4 1100 QEMU + 1045 Virtio 1.0 balloon + 1af4 1100 QEMU + 1046 Virtio 1.0 ioMemory + 1af4 1100 QEMU + 1047 Virtio 1.0 remote processor messaging + 1af4 1100 QEMU 1048 Virtio 1.0 SCSI - 1049 Virtio 1.0 filesystem + 1af4 1100 QEMU + 1049 Virtio 9P transport + 1af4 1100 QEMU + 104a Virtio 1.0 WLAN MAC + 1af4 1100 QEMU + 104b Virtio 1.0 remoteproc serial link + 1af4 1100 QEMU + 104d Virtio 1.0 memory balloon + 1af4 1100 QEMU 1050 Virtio 1.0 GPU + 1af4 1100 QEMU + 1051 Virtio 1.0 clock/timer + 1af4 1100 QEMU 1052 Virtio 1.0 input + 1af4 1100 QEMU 1053 Virtio 1.0 socket - 1058 virtio-mem - 105a Virtio file system - 1110 Inter-VM shared memory - 1af4 1100 QEMU Virtual Machine + 1af4 1100 QEMU + 1054 Virtio 1.0 crypto + 1af4 1100 QEMU + 1055 Virtio 1.0 signal distribution device + 1af4 1100 QEMU + 1056 Virtio 1.0 pstore device + 1af4 1100 QEMU + 1057 Virtio 1.0 IOMMU + 1af4 1100 QEMU + 1058 Virtio 1.0 mem + 1af4 1100 QEMU + 1059 Virtio 1.0 sound + 1af4 1100 QEMU + 105a Virtio 1.0 file system + 1af4 1100 QEMU + 105b Virtio 1.0 pmem + 1af4 1100 QEMU + 105c Virtio 1.0 rpmb + 1af4 1100 QEMU + 105d Virtio 1.0 mac80211-hwsim + 1af4 1100 QEMU + 105e Virtio 1.0 video encoder + 1af4 1100 QEMU + 105f Virtio 1.0 video decoder + 1af4 1100 QEMU + 1060 Virtio 1.0 SCMI + 1af4 1100 QEMU + 1061 Virtio 1.0 nitro secure module + 1af4 1100 QEMU + 1062 Virtio 1.0 I2C adapter + 1af4 1100 QEMU + 1063 Virtio 1.0 watchdog + 1af4 1100 QEMU + 1064 Virtio 1.0 can + 1af4 1100 QEMU + 1065 Virtio 1.0 dmabuf + 1af4 1100 QEMU + 1066 Virtio 1.0 parameter server + 1af4 1100 QEMU + 1067 Virtio 1.0 audio policy + 1af4 1100 QEMU + 1068 Virtio 1.0 Bluetooth + 1af4 1100 QEMU + 1069 Virtio 1.0 GPIO + 1af4 1100 QEMU + 1110 QEMU Inter-VM shared memory device + 1af4 1100 QEMU 1af5 Netezza Corp. 1afa J & W Electronics Co., Ltd. 1b00 Montage Technology Co., Ltd. @@ -25427,6 +25662,7 @@ 000b QEMU PCIe Expander bridge 000c QEMU PCIe Root port 000d QEMU XHCI Host Controller + 000e QEMU PCIe-to-PCI bridge 0010 QEMU NVM Express Controller 0011 QEMU PVPanic device 0013 QEMU UFS Host Controller @@ -25475,16 +25711,20 @@ 1028 2196 ROR-N1 1028 2286 BOSS-N1 DC-MHS 1028 2287 BOSS-N1 Modular DC-MHS + 1028 23b0 eBOSS-N1 DC-MHS 1b4b 2241 Santa Cruz NVMe Host Adapter 1b96 4000 WD_BLACK AN1500 NVMe SSD 1d49 0306 ThinkSystem M.2 NVMe 2-Bay RAID Enablement Kit 1d49 0307 ThinkSystem 7mm NVMe 2-Bay Rear RAID Enablement Kit + 207d 0800 TrustRAID B310n + 207d 0801 TrustRAID B260s 4c52 9541 LRNV9541 2-port M.2 NVMe Raid Adapter 2b42 88W8997 2.4/5 GHz Dual-Band 2x2 Wi-Fi® 5 (802.11ac) + Bluetooth® 5.3 Solution 2b43 NXP 88W9098 Wi-Fi 6 (ax) MAC #1 2b44 NXP 88W9098 Wi-Fi 6 (ax) MAC #2 2b45 NXP 88W9098 Bluetooth 5.3 9120 88SE9120 SATA 6Gb/s Controller + 9122 88SE912x SATA 6Gb/s Controller [AHCI mode] 9123 88SE9123 PCIe SATA 6.0 Gb/s controller dc93 600e DC-6xxe series SATA 6G controller 9125 88SE9125 PCIe SATA 6.0 Gb/s controller @@ -25493,14 +25733,19 @@ 9130 88SE9128 PCIe SATA 6 Gb/s RAID controller with HyperDuo 1043 8438 P8P67 Deluxe Motherboard 9170 88SE9170 PCIe 2.0 x1 2-port SATA 6 Gb/s Controller + 9171 88SE9171 PCIe 2.0 x1 1-port SATA 6 Gb/s Controller 9172 88SE9172 SATA 6Gb/s Controller 9178 88SE9170 PCIe SATA 6Gb/s Controller - 917a 88SE9172 SATA III 6Gb/s RAID Controller + 917a 88SE9172 SATA III 6Gb/s Controller [IDE mode] 9182 88SE9182 PCIe 2.0 x2 2-port SATA 6 Gb/s Controller 9183 88SS9183 PCIe SSD Controller + 9186 88SE9186 6Gb/s SATA 6Gb/s Controller [AHCI mode] + 918a 88SE9182 PCIe SATA 6 Gb/s controller [IDE mode] 9192 88SE9172 SATA III 6Gb/s RAID Controller 91a0 88SE912x SATA 6Gb/s Controller [IDE mode] + 91a3 88SE9128 PCIe SATA 6 Gb/s controller [IDE mode] 91a4 88SE912x IDE Controller + 91b0 88SE9172 SATA 6 Gb/s controller [IDE mode] 9215 88SE9215 PCIe 2.0 x1 4-port SATA 6 Gb/s Controller 9220 88SE9220 PCIe 2.0 x2 2-port SATA 6 Gb/s RAID Controller 9230 88SE9230 PCIe 2.0 x2 4-port SATA 6 Gb/s RAID Controller @@ -25560,6 +25805,7 @@ 1009 FL1009 USB 3.0 Host Controller 1100 FL1100 USB 3.0 Host Controller 16b8 6e31 Allegro Pro USB 3.0 PCIe + 1400 USB 3.0 Host Controller 1b74 OpenVox Communication Co. Ltd. 0115 D115P/D115E Single-port E1/T1 card d130 D130P/D130E Single-port E1/T1 card (3rd GEN) @@ -25721,6 +25967,9 @@ 5021 FireCuda 520 SSD # 1TB 5026 FireCuda 540 SSD + 5027 LaCie Rugged SSD Pro5 + 5100 PCIe Gen3 SSD + 5101 PCIe Gen5 SSD 1bb3 Bluecherry 4304 BC-04120A MPEG4 4 port video encoder / decoder 4309 BC-08240A MPEG4 4 port video encoder / decoder @@ -25782,6 +26031,8 @@ 100c NS8510G1Uxxx, NS8610G1Uxxx NVME SSD 100e NS8500G2Uxxxx, NS8600G2Uxxxx NVME SSD 100f NS6500G2UXXXX,NS6600G2UXXXX NVME SSD *** 1453 LINES SKIPPED *** From nobody Wed Sep 17 19:37:17 2025 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 4cRpv26RWHz67wmK; Wed, 17 Sep 2025 19:37:18 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRpv21RjNz4F0G; Wed, 17 Sep 2025 19:37:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137838; 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=asa12NtUUIORoBIznPaD9OsHSqyDSKi5MtqqaJ6UkaE=; b=MERIoAIZQHj5p33f2P/T1CyD2DFKQ2lWIOAkkaha0kAErbka10Nm7Df0nactPJIwRJGk4t 34Ia16cSCaA5WvaSGl8NYThWeVgQ8ANoxGuL/K/bS5LWxRDVrA9syjdv9IVn6zJY2cOLbx VIAThrCR1z1H1Jv55wL0wzTWxt1oWZrvcpxnK2UXFetZkK66A9n3sR96Aj5UwjXb4yG72N fG+dGJm2Q4VqOU4fpnchaiLDvmpVKk/IT5EV4j6AK2Oq4g2RBNkzwaUW9TSAaqu+CwSXDQ cDM8FUpyS+uZQQVfWM0ICaDaoMxeik4/Uqt4NOrandWtayHFk4aU9PpRu9oA1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137838; 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=asa12NtUUIORoBIznPaD9OsHSqyDSKi5MtqqaJ6UkaE=; b=lGohdObKWXmHvgV/2kuBWg7Kz1WnCSzHn/uKV/IE2mwqjd9XceghIrf/dsZ/1T0j4m5851 INX4pJdydQLZVfhxaQJHDAUXdwRLVsPQmPsMHQRTug8aFkY/U1jZKv7aCK5TpobdnJLW+i tX/Pazp3e6LUe1KWlF8JB1rnlq0hDZMtT/rrTcekJObOLEpyYFrhYwU7ckIPD1lam+bV5L PYjC4dDHN7fO09z++1gfLhNeHaP78VCFW51O5dfemEwNxrJPhG/NOtzs6udunZ4XXjvooe 6+P5HAk0O2RrPGduhTRXBShDO/lKXQHGyBYHZzyWqa6hjb3Mvq8mX4XiO3f7tQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137838; a=rsa-sha256; cv=none; b=H+YFHi7CT/MQJ0xGPL78KfLEWqrVk6mTRBdFlpJfVdcSAy06cTQzVx9flyW2sfwh2wMRvC Sk+3VuRp6En/M5rNdrfKjcqzCpC8niWLNsLBzVJo6b3JJFSiFrXbWGhoFplpPwcY86cJYj IQqk8Q0X2JfeeHRHxKnIs1GQOkcvk6btoe0aICrhrOATEkpLZYTVJS6FOwQcgM/yjBaLft cmJbmW3575E7ShoTNlVRjQV3+FV/tgCKPL5ogV3C7JjFMFHo7bwEeQXCqT3SVRWN39CI0u qm+1VDpZ874HFsp7L53z46ivOKzBmqC2RRMRwcL8WMcFFlVag++m82e1ZPvuNQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRpv20ms5zg8N; Wed, 17 Sep 2025 19:37:18 +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 58HJbInC015509; Wed, 17 Sep 2025 19:37:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJbHod015506; Wed, 17 Sep 2025 19:37:17 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:37:17 GMT Message-Id: <202509171937.58HJbHod015506@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: c73d38aef140 - stable/14 - usb_vendors: update to 2025-07-26 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c73d38aef1407362b8987e6badcb7fb555a12774 Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=c73d38aef1407362b8987e6badcb7fb555a12774 commit c73d38aef1407362b8987e6badcb7fb555a12774 Author: Baptiste Daroussin AuthorDate: 2025-09-11 07:54:17 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:36:30 +0000 usb_vendors: update to 2025-07-26 (cherry picked from commit 70afc95fc6ecec6edabf5b1e8b060bb0b29ebd55) --- share/misc/usb_vendors | 57 +++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 54 insertions(+), 3 deletions(-) diff --git a/share/misc/usb_vendors b/share/misc/usb_vendors index 3e72fe4045e6..1878f503b676 100644 --- a/share/misc/usb_vendors +++ b/share/misc/usb_vendors @@ -9,8 +9,8 @@ # The latest version can be obtained from # http://www.linux-usb.org/usb.ids # -# Version: 2025.04.01 -# Date: 2025-04-01 20:34:02 +# Version: 2025.07.26 +# Date: 2025-07-26 20:34:01 # # Vendors, devices and interfaces. Please keep sorted. @@ -59,6 +59,8 @@ 0112 Card Reader 017c MLK 145f Trust Deskset +019c mek + 0042 mek_42 0200 TP-Link 0201 MA180 UMTS Modem 0204 Chipsbank Microelectronics Co., Ltd @@ -69,6 +71,9 @@ 0231 Sonuus Limited 02ad HUMAX Co., Ltd. 138c PVR Mass Storage +0300 Ajazz + 1010 Akp153E Desktop Controller + 1020 AKP153R Desktop Controller 0303 Mini Automation Controller 0324 OCZ Technology Inc bc06 OCZ ATV USB 2.0 Flash Drive @@ -95,7 +100,7 @@ 0015 ATAPI Enclosure 2123 SiPix StyleCam Deluxe 8004 Aox 99001 -03e9 Thesys Microelectronics +03e9 Melexis (formerly Thesys Microelectronics) 03ea Data Broadcasting Corp. 03eb Atmel Corp. 0902 4-Port Hub @@ -257,6 +262,8 @@ 0423 HS-COMBO Cardreader 042a LaserJet M1132 MFP 0441 Prime [NW280AA, G8X92AA] + 046b Dock G5 + 0483 Engage Go 10 Tablet 0504 DeskJet 885c 0505 ScanJet 2100c 0507 DVD+RW @@ -266,6 +273,7 @@ 0517 LaserJet 1000 051d Bluetooth Interface 052a LaserJet M1212nf MFP + 0583 Engage Go 10 Tablet 0601 ScanJet 6300c 0604 DeskJet 840c 0605 ScanJet 2200c @@ -275,6 +283,7 @@ 0624 Bluetooth Dongle 0641 X1200 Optical Mouse 0653 DeskJet 3700 series + 0683 Engage Go 10 Tablet 0701 ScanJet 5300c/5370c 0704 DeskJet 825c 0705 ScanJet 4400c @@ -325,6 +334,7 @@ 1102 PhotoSmart 240 series 1104 DeskJet 959c 1105 ScanJet 5470c/5490c + 110c Pocket Media Drive 1111 OfficeJet v60 1116 Jornada 568 Pocket PC 1117 LaserJet 1300n @@ -1013,6 +1023,7 @@ 3000 Optical dual-touch panel 3001 Optical Touch Screen 3008 Optical Touch Screen + 4033 HD Webcam a060 HD Webcam 0409 NEC Corp. 0011 PC98 Series Layout Keyboard Mouse @@ -1029,6 +1040,7 @@ 004e SuperScript 1400 Series 004f Wireless Keyboard with One-touch start buttons 0050 7-port hub + 0056 uPD720133 IDE bridge 0058 HighSpeed Hub 0059 HighSpeed Hub 005a HighSpeed Hub @@ -1486,6 +1498,7 @@ 4095 Live! Cam Sync HD [VF0770] 4097 Live! Cam Chat HD [VF0700/VF0790] 4099 Creative VF0800 [RealSense Camera SR300] + 40a3 Live! Cam V3 2K [VF-0900] 4100 Nomad Jukebox 2 4101 Nomad Jukebox 3 4102 NOMAD MuVo^2 @@ -1959,6 +1972,7 @@ 010d 3500-4500 series 010f 6500 series 0142 X3650 (Printer, Scanner, Copier) + 01bd S800 Series Scanner 01fa S310 series 020e RICOH Aficio SP 4410SF 4303 Xerox WorkCentre Pro 412 @@ -1982,6 +1996,7 @@ 9a10 34UC88-B 9a11 34UC88-B 9a39 27UP850 - WK.AEUDCSN - External Monitor 4K + 9a57 UltraGear Monitor 9c01 LGE Sync 043f RadiSys Corp. 0440 Eizo Nanao Corp. @@ -2007,6 +2022,7 @@ 044d Siemens Nixdorf AG 044e Alps Electric Co., Ltd 1104 Japanese Keyboard + 1218 Electric Touchpad 2002 MD-5500 Printer 2014 Bluetooth Device 3001 UGTZ4 Bluetooth @@ -2737,6 +2753,8 @@ 0180 Strait 3.0 01a4 MC 2.1 Mouse 01a6 MX BOARD 2.0S FL RGB DE Keyboard + 0201 Smart Board 1150 + 0202 Smart Terminal 1150 b090 Keyboard b091 Mouse c099 Stream Keyboard TKL @@ -2851,6 +2869,7 @@ 08dd QuickCam for Notebooks 08e0 QuickCam Express 08e1 Labtec Webcam + 08e4 C505e HD Webcam 08e5 C920 PRO HD Webcam 08f0 QuickCam Messenger 08f1 QuickCam Express @@ -3002,6 +3021,7 @@ c08e G MX518 Gaming Mouse (MU0053) c092 G102/G203 LIGHTSYNC Gaming Mouse c093 M500s Optical Mouse + c09d G102 LIGHTSYNC Gaming Mouse c101 UltraX Media Remote c110 Harmony 785/880/885 Remote c111 Harmony 525 Remote @@ -3060,6 +3080,7 @@ c24d G710 Gaming Keyboard c24e G500s Laser Gaming Mouse c24f G29 Driving Force Racing Wheel [PS3] + c251 GamePanel for Dell XPS M1730 c260 G29 Driving Force Racing Wheel [PS4] c262 G920 Driving Force Racing Wheel c281 WingMan Force @@ -3073,6 +3094,7 @@ c295 Momo Force Steering Wheel c298 Driving Force Pro c299 G25 Racing Wheel + c29a Driving Force GT c29b G27 Racing Wheel c29c Speed Force Wireless Wheel for Wii c2a0 Wingman Force Feedback Mouse @@ -3110,6 +3132,7 @@ c335 G910 Orion Spectrum Mechanical Keyboard c336 G213 Prodigy Gaming Keyboard c33a G413 Gaming Keyboard + c33e G915 Mechanical Keyboard c33f G815 Mechanical Keyboard c401 TrackMan Marble Wheel c402 Marble Mouse (2-button) @@ -3359,6 +3382,7 @@ 047c Dell Computer Corp. ffff UPS Tower 500W LV 047d Kensington + 00f2 VeriMark Desktop 1001 Mouse*in*a*Box 1002 Expert Mouse Pro 1003 Orbit TrackBall @@ -3558,6 +3582,7 @@ 0485 Nokia Monitors 0486 ASUS Computers, Inc. 0185 EeePC T91MT HID Touch Panel + 573c Xreal Light Microcontroller 0487 Stewart Connector 0488 Cirque Corp. 0489 Foxconn / Hon Hai @@ -3663,6 +3688,7 @@ 1033 DGX-505 1037 PSR-E403 103c MOTIF-RACK ES + 1045 MM6 1054 S90XS Keyboard/Music Synthesizer 160f P-105 1613 Clavinova CLP535 @@ -3892,9 +3918,11 @@ 106d S750 Printer 106e S820D 1070 S530D + 1071 Sony MPR-501 1072 I850 Printer 1073 I550 Printer 1074 S330 Printer + 1075 Sony MPR-505 1076 i70 1077 i950 107a S830D @@ -4053,6 +4081,7 @@ 178a PIXMA MG3600 Series 178d PIXMA MG6853 180b PIXMA MG3000 series + 183b PIXMA MG3110 Series 1856 PIXMA TS6250 1900 CanoScan LiDE 90 1901 CanoScan 8800F @@ -4060,6 +4089,7 @@ 1905 CanoScan LiDE 200 1906 CanoScan 5600F 1907 CanoScan LiDE 700F + 1908 CanoScan 9000F 1909 CanoScan LiDE 110 190a CanoScan LiDE 210 190d CanoScan 9000F Mark II @@ -4621,6 +4651,7 @@ 0434 D610 0436 D810 043f D5600 + 0455 Z50II 0f03 PD-10 Wireless Printer Adapter 4000 Coolscan LS 40 ED 4001 LS 50 ED/Coolscan V ED @@ -4907,11 +4938,19 @@ 0891 Stylus Office BX535WD 0892 Stylus Office BX935FWD 0893 EP-774A + 08d1 L220/L360 Series 0e03 Thermal Receipt Printer [TM-T20] + 0e31 Thermal Receipt Printer [TM-L100] 1114 XP-440 [Expression Home Small-in-One Printer] 1115 ES-0133 [Expression Home XP-342] 1129 ET-4750 [WorkForce ET-4750 EcoTank All-in-One] 1168 Workforce WF-7820/7840 Series + 1186 ET-2820 Series [ET-2820 EcoTank All-in-One] + 118a ET-2810/L3250 Series [EcoTank ET-2810/L3250] + 118b ET-2850/L4260 Series [EcoTank ET-2850/L4260] + 11b0 XP-4200 Series [Expression Home XP-4200] + 11b9 ET-2830/L3550 Series [EcoTank ET-2830/L3550] + 11c8 ET-2860/L3270 Series [EcoTank ET-2860/L3270] 04b9 Rainbow Technologies, Inc. 0300 SafeNet USB SuperPro/UltraPro 1000 iKey 1000 Token @@ -4996,6 +5035,9 @@ 1303 i3 Micro Module 1304 i3 Module 1305 i3 Multi Sensing Module + 1400 Javelin Module Recovery + 1401 Javelin Module + 1500 Gas sensor demo board 04c1 U.S. Robotics (3Com) 0020 56K Voice Pro 0022 56K Voice Pro @@ -5034,7 +5076,9 @@ 11f3 fi-6130Z 125a PalmSecure Sensor Device - MP 132e fi-7160 + 1526 PalmSecure-F Pro 159f ScanSnap iX1500 + 15ff Fi-8170 Document Scanner [Ricoh fi-8170: High Performance Desktop Scanner - PFU] 200f Sigma DP2 (Mass Storage) 2010 Sigma DP2 (PictBridge) 201d SATA 3.0 6Gbit/s Adaptor [GROOVY] @@ -5067,6 +5111,7 @@ 300f Atheros AR3012 Bluetooth 3014 Qualcomm Atheros Bluetooth 3015 Qualcomm Atheros QCA9377 Bluetooth + 3802 MediaTek Bluetooth MT7921 7022 HP HD Webcam 7025 HP HD Webcam 7046 TOSHIBA Web Camera - HD @@ -15333,6 +15378,12 @@ 0e23 Liou Yuane Enterprise Co., Ltd 0e25 VinChip Systems, Inc. 0e26 J-Phone East Co., Ltd +0e2c Materialise Motion NV + 0012 footscan pressure plate (0.5m) + 0013 footscan pressure plate (1.0m) + 0018 footscan 2D interface box + 0020 footscan pressure plate (1.5m) + 002d footscan heavy duty pressure plate (1.0m) 0e2e Brady Worldwide, Inc. 000b BMP 51 000c BMP 61 From nobody Wed Sep 17 19:38:17 2025 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 4cRpw95n4Sz67wpm; Wed, 17 Sep 2025 19:38:17 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRpw94WYMz4Fm2; Wed, 17 Sep 2025 19:38:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137897; 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=CuXULzuRj/PfvoNifVYrj3cwCUsNRn5K34Jp2GcPSQI=; b=Jg3P1FOrn388NY8yjI+U4J3qX5cMVg06fGdiTCR0V02z6VNxrgQFNCCNBxLc/uAu2zEmqQ p4pf2NEo4Dbu8zm86cyzsiRrijQRrbfIwQKUSGZhNzbcbeOMB1RFSrBkarHzkd+e9IoVnN 6Hl2jku/WdoIMlTWEcRGG+T39Km1P+aXKJCu55uFnf2zhkpqAOUfbrVJEAY9ygtbv2zZ1i upqS1fKIV3ko5bqL4LMF6M5q8DU/aHw7zWNjB8xga6Wr4kwsLrhlex+yGPqwOvpQa5fCeO /qVe/TkRVOStBoce8IWpgdsokpZFtHz81rNKQDnPmisrR7ddMjTj0pG3TFNMMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137897; 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=CuXULzuRj/PfvoNifVYrj3cwCUsNRn5K34Jp2GcPSQI=; b=Gsin8eg/o+5Jn7itVHhNerqaZL4r2tK/0L7dXFYAtRVZkzZSwnP0v5jhYWRNB5aQ2fPU0K HBw3pjIbjQRe+J6AaXSL7Wf0szs03HhfEwIJ6nhD918l6X995+HJiege2HSmYAr3NetL0H U1Zm1Xvfuo7ptrU+HaiYO9CBKCjhZ9kNcK4z07Rkhx4881EVEZUEa3wvgaAxvr/btON14Q h8FZh0aB9ngkFdsZZukNT96WW9QWgKka0DdEHl5tAxc3I6msZtk/VCJe7KUQbqpFm0GgK0 nAK1CPYuH+FBHpRtwRg/A65kIjmaT2XUehW6Pt2iC11zFf2lUM8lK6cEHoIXLQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137897; a=rsa-sha256; cv=none; b=G4CEZCxP7pMNVbN4KUuyIwpU9O7cWvh9JXNxzyQIQDU1Vj3LaL2gIwjokFmZLx72HqvVkb Da238c8pI4EJguE8MsOyCbfZuf8Ds3J5scs5FLH7CeuvV5dCpeDr7mtPcuu+b4trzWXQYF HcL8VCFQO35884P03dQa3TPB9KiUqugdhugc8qllnkA3yWt4RMCuQ6b3Lc6pmYXg3nEgzH r/V8tt1QpIAQL2ojSJ25yM1az0r+jniFLsB1f/9A9WurOG0POY6Y3BzUmeXoIMPnn5F+4I v5mr69uR3kXEohfJal3/2PjrEesNKjBG6AoT5uJkFrnghYilJMBXUpmhcv2z8A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRpw945wVzgSq; Wed, 17 Sep 2025 19:38:17 +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 58HJcHMh016062; Wed, 17 Sep 2025 19:38:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJcHuk016059; Wed, 17 Sep 2025 19:38:17 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:38:17 GMT Message-Id: <202509171938.58HJcHuk016059@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 65f42f894b1b - stable/14 - mac_do(4): fix typo 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 65f42f894b1b7541e43984c7b18c7fd6f05461ee Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=65f42f894b1b7541e43984c7b18c7fd6f05461ee commit 65f42f894b1b7541e43984c7b18c7fd6f05461ee Author: Baptiste Daroussin AuthorDate: 2025-06-27 11:29:34 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:37:20 +0000 mac_do(4): fix typo Reported by: des (cherry picked from commit d0c8733997079a54828ad2222517427d9447dbaf) --- share/man/man4/mac_do.4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man4/mac_do.4 b/share/man/man4/mac_do.4 index fb165dfe5a1a..4dcb54c89673 100644 --- a/share/man/man4/mac_do.4 +++ b/share/man/man4/mac_do.4 @@ -44,7 +44,7 @@ It supports per-jail configuration. .Pp Currently, the .Nm -policy module only produces effects to processes spwaned from the +policy module only produces effects to processes spawned from the .Pa /usr/bin/mdo executable, please see .Xr mdo 1 From nobody Wed Sep 17 19:38:18 2025 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 4cRpwB5yxxz67ws3; Wed, 17 Sep 2025 19:38:18 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRpwB59vzz4FjQ; Wed, 17 Sep 2025 19:38:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137898; 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=gA8HWYFyZ5Smu29+St6/iypxnZFZD2dsNnURT4lst5c=; b=sx0rIbToKvSPHg2g8QAI1j30FaWfBA9B2VqYwH7VH3+OOjWEG5xgt6hgvBrXK45fmHMzVP XbxryVV+sluiVVf2LOl9tPSdSmvfV9LFZUPwSqtpQDaZVRjUWYmVcFuP+EEbutam5fXDy+ HGzmUaTSx53JnzHJyqYepybBK7LFJBBHtXV5sTqmINhT+UXRDDSwoTNg0tTKSnKFzSzPhL G2T+cCyQj2bSgmqHQg7xKcpKMssgDrTZJrRDepJeHl6VWaaTyvmWwhxK0oaNtySLskNNRj s2jy7tilCqdeqUKU/xRwpGI3rCNlsKpvZnUuTlVvZdNT17s50yBTj1UBvguNxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758137898; 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=gA8HWYFyZ5Smu29+St6/iypxnZFZD2dsNnURT4lst5c=; b=l2SNwqExw2cNTiw4mBHxLlGIXJlZEXoLZiYkYCR4wvImyDNToThc2oe5jVclxAJbBubL+5 QS/qr/wjVGK2u+NX9MbOMF6dcx8IrVUxXHihSaKk2t2kCwlVnxL1vKI8omUi3SrDRheSt5 59ze6/uMidmdT/PKSgYqsGSvcAWrTD3GKYv1ffWBUrXOcZyagdqn9ployQZdKVqyhrS3+p aT/5y5jvqRZejqrVOa1gk2HMWtDpv7FRrxXu65R7uYV0v1olvizrivm9GfxZXDfvn6SxGV n+0uL66nmSQNGPbLmpCk8yewRJmUsTx7RhsGGamH1+cHUWPlRL1yj9twzhHcog== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758137898; a=rsa-sha256; cv=none; b=WoNBF9sVZP61AxBqd3rwKZn44u7TzbrXfnXvKQ32lyoSlRBDYfZHWk/pnY4qckhcd1ECjY ko7uoNEXoAXbHhhmpVVNlNgS+m9LfcQe5djocGukEZ47DZkaUi7Dv9hc5XFlxTPduMlzOc 7uAOmY/VPw1YNI4hELr3p5MJl2nVrVHOd5NPfmt+Qdgpuk6jbyOw2PG+YbofMtledwfrV5 ZVvxfy/SKAExnzB335DkmuM9bOQFf7hGhRRy+/fvHe1exgXJy3vzb/+hraD19i5ueRriXp ZZFmFUs3EW3QUvHeF8OLWC4e+4yDrSi8sqN4DyMcR97CumOOnv5ZMEJhbuQZxg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRpwB4nhXzgg1; Wed, 17 Sep 2025 19:38:18 +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 58HJcIC8016094; Wed, 17 Sep 2025 19:38:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJcI3n016091; Wed, 17 Sep 2025 19:38:18 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:38:18 GMT Message-Id: <202509171938.58HJcI3n016091@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 08e259e39236 - stable/14 - timeout(1): add license header to unit test 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 08e259e3923696b6a93e11cb32f53bab7a24db00 Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=08e259e3923696b6a93e11cb32f53bab7a24db00 commit 08e259e3923696b6a93e11cb32f53bab7a24db00 Author: Baptiste Daroussin AuthorDate: 2025-09-03 09:52:46 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:38:02 +0000 timeout(1): add license header to unit test Requested by: kevans (cherry picked from commit 245f2abf94889d3fd69360c4f49532074ff25fbf) --- bin/timeout/tests/timeout_test.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bin/timeout/tests/timeout_test.sh b/bin/timeout/tests/timeout_test.sh index b1bf69968e84..88dbaa808043 100644 --- a/bin/timeout/tests/timeout_test.sh +++ b/bin/timeout/tests/timeout_test.sh @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: BSD-2-Clause +# Copyright (c) 2014 Baptiste Daroussin atf_test_case nominal nominal_head() From nobody Wed Sep 17 19:42:20 2025 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 4cRq0r4w5Mz67xNS; Wed, 17 Sep 2025 19:42:20 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRq0r4ZFTz4GY4; Wed, 17 Sep 2025 19:42:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138140; 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=B0lNd5WDG13hCrEVh2WnVp4rPF1+5k+iMf2V8CivmbE=; b=vK6hmw+uB/112PiUI0LutCcXQ6Zg5m5MLn4GdS95BkpO9ID05HE0VEVaW2xE4JBr72HQJn xhzKB4Uj1yav7IcXWwzmsiK6anUOzuFCl9NPYD5AS0/apDwtwagE+uUasFtDGiRgeAccjz hn6VaE2gRCMxbJ+Pw4unUUfgN7ex6qHSp/Jy+k+Yv9K/NcrCgAcaHfG1O/O4n0B4w2cXeX EolB4b1gfCSitB58TQbRESZ7b6tBquXehliZWLjS+cJS1kAazCsNwp09QFJ/nV8XnR6Syj MA+x5UqDrltOMxjHEYffWtmH4p5i7BNvRI48Sf7zWLPXeU2cmFYKk6SW1ln58g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138140; 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=B0lNd5WDG13hCrEVh2WnVp4rPF1+5k+iMf2V8CivmbE=; b=ZPw8REEq/7YU4CH72dTsqU1lr86HoYDTpBmQGSMfyFK7qUzvGE+Nvibo8aSJMO2HuXhd9Y LnvnJFFa5BWv3qxaoMBASTT1y84fgTpfzriiMwPJpVvUsDe8ZJd+kCniMbk4hX1+RJhYUH NLwXE2FR/O3LPDE98UqphOsz94SdpP+8DS0Zb6YbeLr580XsIDs+M5Pjit8pmNdeKQD8v+ uD1SkN4tewgvwjJSlcj1cfr07GWQSHFhNhFcruVcTg3Q9lxtY44BRTdVTE9gKIlV4waM3h GQDF9nqELjIxcsEv2qGAZsXnE74/4vsqn6AU5wb1QOyl29yB9DVLHgdcto15Pw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758138140; a=rsa-sha256; cv=none; b=pJMxKLAr6f8r+Jq1bBkGrbW43nxIv5RVS5J7U/5OsNvZ+AM7BN8UkifBdv5wpILjFIvv8k s7V2ct85VdjDPbbVqnw60KGHceXQF0WtnuzH4G8peXvNlnOOJTFIX5m83ZgGA+UBiVsoG1 FjKA0jHAuWqKlYJRrJrGnbhKSokckh9mRqflx+2vgJGSYsS1rCS2MzbGahstZW5Lp6jeM+ SiOkWYoYKExYuftxEKATd49G9/65Zj+9vTx5elsp5JkiURWdtD+bU4tWApZEL8ICRamlpU sVBvQ10vIvXqFgS6jc+rivM0sB5tSwrD3h9nwoobbqL/6BVj5vts8aLR6w1cTg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRq0r42Cgzggm; Wed, 17 Sep 2025 19:42:20 +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 58HJgKIW032004; Wed, 17 Sep 2025 19:42:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJgKSe032001; Wed, 17 Sep 2025 19:42:20 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:42:20 GMT Message-Id: <202509171942.58HJgKSe032001@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 3a680e954469 - stable/14 - nuageinit: Improvements for nuageinit 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 3a680e9544696c8ea434a7ed60dbaae693e5af7f Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=3a680e9544696c8ea434a7ed60dbaae693e5af7f commit 3a680e9544696c8ea434a7ed60dbaae693e5af7f Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-08-22 18:14:18 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:39:23 +0000 nuageinit: Improvements for nuageinit - Fix 'pkg update' usage: - The function 'nuage:run_pkg_cmd(...)' adds the flag '-y', which does not make sense with some commands such as 'pkg update', causing an error when updating the repository catalogs. - Fix typo 'ssh-authorized-keys -> ssh_authorized_keys' in 'nuageinit(7)' man page. - Document 'ssh_authorized_keys' parameter. - Use device configuration ID when no 'match' rule is specified: - This is the default behavior of cloud-init when no match rule is specified, so the device is configured anyway (even if it does not exist). This greatly simplifies things, since in many cases 'if_vtnet(4)' is used, so there is no need to perform a comparison with the MAC address. - Document 'network' parameter: - Add example to 'EXAMPLES' section. - Set 'gateway[46]' only when 'addresses' is specified: - To comply with the cloud-init specification, 'gateway4' and 'gateway6' must only take effect when 'addresses' (or static configuration) is specified. - Use a separate function to check 'match' rules: - This way, we can easily add new logic to new types of rules. - Implement 'network.ethernets.{id}.match.name' parameter: - But unlike cloud-init, which works with glob expressions (although it depends on the network backend), this implementation takes advantage of Lua pattern-matching expressions. Also note that previously we were only concerned with one interface matching, however, to be cloud-init-compliant, we need to configure the matching interfaces (one or more). - Set default router only once. - Implement 'network.ethernets.{id}.wakeonlan' parameter. - Implement 'network.ethernets.{id}.set-name' parameter. - Implement 'network.ethernets.{id}.match.driver' parameter: - Rename 'get_ifaces(...)' function as 'get_ifaces_by_mac(...)'. - Add get_ifaces_by_driver(...) function. - Implement 'network.ethernets.{id}.mtu' parameter. - Implement 'nameservers' parameter. - Use 'resolvconf(8)' to manipulate 'resolv.conf(5)'. - Use 'tzsetup(8)' to set time zone. Reviewed by: bapt@ Approved by: bapt@ Differential Revision: https://reviews.freebsd.org/D51643 (cherry picked from commit ba5df7a2d03cd5624b1825ca8d4c39dcaace7796) --- libexec/nuageinit/nuage.lua | 20 ++- libexec/nuageinit/nuageinit | 238 ++++++++++++++++++++++++++++---- libexec/nuageinit/nuageinit.7 | 92 +++++++++++- libexec/nuageinit/tests/Makefile | 1 + libexec/nuageinit/tests/nuage.sh | 9 ++ libexec/nuageinit/tests/nuageinit.sh | 4 +- libexec/nuageinit/tests/settimezone.lua | 5 + 7 files changed, 335 insertions(+), 34 deletions(-) diff --git a/libexec/nuageinit/nuage.lua b/libexec/nuageinit/nuage.lua index 493ae11d6ca7..48f54b120615 100644 --- a/libexec/nuageinit/nuage.lua +++ b/libexec/nuageinit/nuage.lua @@ -451,6 +451,23 @@ local function chpasswd(obj) end end +local function settimezone(timezone) + if timezone == nil then + return + end + local root = os.getenv("NUAGE_FAKE_ROOTDIR") + if not root then + root = "/" + end + + f, _, rc = os.execute("tzsetup -s -C " .. root .. " " .. timezone) + + if not f then + warnmsg("Impossible to configure time zone ( rc = " .. rc .. " )") + return + end +end + local function pkg_bootstrap() if os.getenv("NUAGE_RUN_TESTS") then return true @@ -480,7 +497,7 @@ local function install_package(package) end local function run_pkg_cmd(subcmd) - local cmd = "pkg " .. subcmd .. " -y" + local cmd = "env ASSUME_ALWAYS_YES=yes pkg " .. subcmd if os.getenv("NUAGE_RUN_TESTS") then print(cmd) return true @@ -556,6 +573,7 @@ local n = { dirname = dirname, mkdir_p = mkdir_p, sethostname = sethostname, + settimezone = settimezone, adduser = adduser, addgroup = addgroup, addsshkey = addsshkey, diff --git a/libexec/nuageinit/nuageinit b/libexec/nuageinit/nuageinit index 0fcdc7274db3..70b27cb33d87 100755 --- a/libexec/nuageinit/nuageinit +++ b/libexec/nuageinit/nuageinit @@ -46,7 +46,15 @@ local function open_config(name) return openat("/etc/rc.conf.d", name) end -local function get_ifaces() +local function open_resolv_conf() + return openat("/etc", "resolv.conf") +end + +local function open_resolvconf_conf() + return openat("/etc", "resolvconf.conf") +end + +local function get_ifaces_by_mac() local parser = ucl.parser() -- grab ifaces local ns = io.popen("netstat -i --libxo json") @@ -77,6 +85,10 @@ local function sethostname(obj) end end +local function settimezone(obj) + nuage.settimezone(obj.timezone) +end + local function groups(obj) if obj.groups == nil then return end @@ -171,6 +183,59 @@ local function ssh_authorized_keys(obj) end end +local function nameservers(interface, obj) + local resolvconf_conf_handler = open_resolvconf_conf() + + if obj.search then + local with_space = false + + resolvconf_conf_handler:write('search_domains="') + + for _, d in ipairs(obj.search) do + if with_space then + resolvconf_conf_handler:write(" " .. d) + else + resolvconf_conf_handler:write(d) + with_space = true + end + end + + resolvconf_conf_handler:write('"\n') + end + + if obj.addresses then + local with_space = false + + resolvconf_conf_handler:write('name_servers="') + + for _, a in ipairs(obj.addresses) do + if with_space then + resolvconf_conf_handler:write(" " .. a) + else + resolvconf_conf_handler:write(a) + with_space = true + end + end + + resolvconf_conf_handler:write('"\n') + end + + resolvconf_conf_handler:close() + + local resolv_conf = root .. "/etc/resolv.conf" + + resolv_conf_attr = lfs.attributes(resolv_conf) + + if resolv_conf_attr == nil then + resolv_conf_handler = open_resolv_conf() + resolv_conf_handler:close() + end + + if not os.execute("resolvconf -a " .. interface .. " < " .. resolv_conf) then + nuage.warn("Failed to execute resolvconf(8)") + end +end + local function install_packages(packages) if not nuage.pkg_bootstrap() then nuage.warn("Failed to bootstrap pkg, skip installing packages") @@ -187,6 +252,85 @@ local function install_packages(packages) end end +local function list_ifaces() + local proc = io.popen("ifconfig -l") + local raw_ifaces = proc:read("*a") + proc:close() + local ifaces = {} + for i in raw_ifaces:gmatch("[^%s]+") do + table.insert(ifaces, i) + end + return ifaces +end + +local function get_ifaces_by_driver() + local proc = io.popen("ifconfig -D") + local drivers = {} + local last_interface = nil + for line in proc:lines() do + local interface = line:match("^([%S]+): ") + + if interface then + last_interface = interface + end + + local driver = line:match("^[%s]+drivername: ([%S]+)$") + + if driver then + drivers[driver] = last_interface + end + end + proc:close() + + return drivers +end + +local function match_rules(rules) + -- To comply with the cloud-init specification, all rules must match and a table + -- with the matching interfaces must be returned. This changes the way we initially + -- thought about our implementation, since at first we only needed one interface, + -- but cloud-init performs actions on a group of matching interfaces. + local interfaces = {} + if rules.macaddress then + local ifaces = get_ifaces_by_mac() + local interface = ifaces[rules.macaddress] + if not interface then + nuage.warn("not interface matching by MAC address: " .. rules.macaddress) + return + end + interfaces[interface] = 1 + end + if rules.name then + local match = false + for _, i in pairs(list_ifaces()) do + if i:match(rules.name) then + match = true + interfaces[i] = 1 + end + end + if not match then + nuage.warn("not interface matching by name: " .. rules.name) + return + end + end + if rules.driver then + local match = false + local drivers = get_ifaces_by_driver() + for d in pairs(drivers) do + if d:match(rules.driver) then + match = true + interface = drivers[d] + interfaces[interface] = 1 + end + end + if not match then + nuage.warn("not interface matching by driver: " .. rules.driver) + return + end + end + return interfaces +end + local function write_files(files, defer) if not files then return @@ -210,41 +354,76 @@ end local function network_config(obj) if obj.network == nil then return end - local ifaces = get_ifaces() local network = open_config("network") local routing = open_config("routing") local ipv6 = {} - for _, v in pairs(obj.network.ethernets) do - if not v.match then - goto next + local set_defaultrouter = true + local set_defaultrouter6 = true + local set_nameservers = true + for i, v in pairs(obj.network.ethernets) do + local interfaces = {} + if v.match then + interfaces = match_rules(v.match) + + if next(interfaces) == nil then + goto next + end + else + interfaces[i] = 1 end - if not v.match.macaddress then - goto next + local extra_opts = "" + if v.wakeonlan then + extra_opts = extra_opts .. " wol" end - if not ifaces[v.match.macaddress] then - nuage.warn("not interface matching: " .. v.match.macaddress) - goto next + if v.mtu then + if type(v.mtu) == "number" then + mtu = tostring(v.mtu) + else + mtu = v.mtu + end + if mtu:match("%d") then + extra_opts = extra_opts .. " mtu " .. mtu + else + nuage.warn("MTU is not set because the specified value is invalid: " .. mtu) + end end - local interface = ifaces[v.match.macaddress] - if v.dhcp4 then - network:write("ifconfig_" .. interface .. '="DHCP"\n') - elseif v.addresses then - for _, a in pairs(v.addresses) do - if a:match("^(%d+)%.(%d+)%.(%d+)%.(%d+)") then - network:write("ifconfig_" .. interface .. '="inet ' .. a .. '"\n') - else - network:write("ifconfig_" .. interface .. '_ipv6="inet6 ' .. a .. '"\n') - ipv6[#ipv6 + 1] = interface + for interface in pairs(interfaces) do + if v.match and v.match.macaddress and v["set-name"] then + local ifaces = get_ifaces_by_mac() + local matched = ifaces[v.match.macaddress] + if matched and matched == interface then + network:write("ifconfig_" .. interface .. '_name=' .. v["set-name"] .. '\n') + interface = v["set-name"] + end + end + if v.dhcp4 then + network:write("ifconfig_" .. interface .. '="DHCP"' .. extra_opts .. '\n') + elseif v.addresses then + for _, a in pairs(v.addresses) do + if a:match("^(%d+)%.(%d+)%.(%d+)%.(%d+)") then + network:write("ifconfig_" .. interface .. '="inet ' .. a .. extra_opts .. '"\n') + else + network:write("ifconfig_" .. interface .. '_ipv6="inet6 ' .. a .. extra_opts .. '"\n') + ipv6[#ipv6 + 1] = interface + end + end + if set_nameservers and v.nameservers then + set_nameservers = false + nameservers(interface, v.nameservers) + end + if set_defaultrouter and v.gateway4 then + set_defaultrouter = false + routing:write('defaultrouter="' .. v.gateway4 .. '"\n') + end + if v.gateway6 then + if set_defaultrouter6 then + set_defaultrouter6 = false + routing:write('ipv6_defaultrouter="' .. v.gateway6 .. '"\n') + end + routing:write("ipv6_route_" .. interface .. '="' .. v.gateway6) + routing:write(" -prefixlen 128 -interface " .. interface .. '"\n') end end - end - if v.gateway4 then - routing:write('defaultrouter="' .. v.gateway4 .. '"\n') - end - if v.gateway6 then - routing:write('ipv6_defaultrouter="' .. v.gateway6 .. '"\n') - routing:write("ipv6_route_" .. interface .. '="' .. v.gateway6) - routing:write(" -prefixlen 128 -interface " .. interface .. '"\n') end ::next:: end @@ -316,7 +495,7 @@ local function config2_network(p) end local obj = parser:get_object() - local ifaces = get_ifaces() + local ifaces = get_ifaces_by_mac() if not ifaces then nuage.warn("no network interfaces found") return @@ -468,6 +647,7 @@ f:close() if line == "#cloud-config" then local pre_network_calls = { sethostname, + settimezone, groups, create_default_user, ssh_keys, diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index 327ce160e151..604d8a2221ca 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -143,6 +143,11 @@ Specify a fully qualified domain name for the instance. Specify the hostname of the instance if .Qq Ic fqdn is not set. +.It Ic timezone +Sets the system timezone based on the value provided. +.Pp +See also +.Xr tzfile 3 Ns . .It Ic groups An array of strings or objects to be created: .Bl -bullet @@ -176,6 +181,81 @@ boolean which determines the value of the configuration in .Pa /etc/ssh/sshd_config .It Ic network +Network configuration parameters. +.Bl -tag -width "ethernets" +.It Ic ethernets +Mapping representing a generic configuration for existing network interfaces. +.Pp +Each key is an interface name that is only used when no +.Sy match +rule is specified. +If +.Sy match +rules are specified, an arbitrary name can be used +.Po e.g.: id0 Pc Ns . +.Bl -tag -width "nameservers" +.It Ic match +This selects a subset of available physical devices by various hardware properties. +The following configuration will then apply to all matching devices, as soon as +they appear. All specified properties must match. The following properties for +creating matches are supported: +.Bl -tag -width "macaddress" +.It Ic macaddress +.No Device's MAC address in the form Sy xx:xx:xx:xx:xx:xx Ns . +Letters should be lowercase. +.It Ic name +Current interface name. Lua pattern-matching expressions are supported. +.It Ic driver +Interface driver name and unit number of the interface. Lua pattern-natching expressions +are supported. +.El +.It Ic set-name +When matching on unique properties such as MAC, match rules can be written so that they +match only one device. Then this property can be used to give that device a more +specific/desirable/nicer name than the default. +.Pp +While multiple properties can be used in a match, +.Sy macaddress +is required for nuageinit to perform the rename. +.It Ic mtu +The MTU key represents a device's Maximum Transmission Unit, the largest size packet +or frame. +.It Ic wakeonlan +Enable wake on LAN. Off by default. +.It Ic dhcp4 +Configure the interface to use DHCP. +.Pp +This takes precedence over +.Sy addresses +when both are specified. +.It Ic addresses +List of strings representing IPv4 or IPv6 addresses. +.It Ic gateway4 +Set default gateway for IPv4, for manual address configuration. This requires setting +.Sy addresses +too. +.Pp +Since only one default router can be configured at a time, this parameter is applied +when processing the first entry, and any others are silently ignored. +.It Ic gateway6 +Set default gateway for IPv6, for manual address configuration. This requires setting +.Sy addresses +too. +.Pp +Since only one default router can be configured at a time, this parameter is applied +when processing the first entry, and any others are silently ignored. +.It Ic nameservers +Set DNS servers and search domains, for manual address configuration. +.Pp +There are two supported fields: +.Bl -tag -width "addresses" +.It Ic search +Search list for host-name lookup. +.It Ic addresses +List of IPv4 or IPv6 name server addresses that the resolver should query. +.El +.El +.El .It Ic runcmd An array of commands to be run at the end of the boot process .It Ic packages @@ -186,7 +266,7 @@ Update the remote package metadata. Upgrade the packages installed to their latest version. .It Ic users Specify a list of users to be created: -.Bl -tag -width "plain_text_passwd" +.Bl -tag -width "ssh_authorized_keys" .It Ic name Name of the user. .It Ic gecos @@ -201,6 +281,8 @@ The list of other groups the user should belong to. A boolean which determines if the home directory should be created or not. .It Ic shell The shell that should be used for the user. +.It Ic ssh_authorized_keys +List of SSH keys for the user. .It Ic passwd The encrypted password for the user. .It Ic plain_text_passwd @@ -287,7 +369,7 @@ users: - name: user gecos: Foo B. Bar sudo: ALL=(ALL) NOPASSWD:ALL - ssh-authorized-keys: + ssh_authorized_keys: - ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAr... packages: - neovim @@ -303,6 +385,12 @@ ssh_keys: ... -----END OPENSSH PRIVATE KEY----- ed25519_public: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIK+MH4E8KO32N5CXRvXVqvyZVl0+6ue4DobdhU0FqFd+ +network: + ethernets: + vtnet0: + addresses: + - 192.168.8.2/24 + gateway4: 192.168.8.1 .Ed .Sh SEE ALSO .Xr kenv 2 , diff --git a/libexec/nuageinit/tests/Makefile b/libexec/nuageinit/tests/Makefile index 0b813dbd98be..0f5b10bc7280 100644 --- a/libexec/nuageinit/tests/Makefile +++ b/libexec/nuageinit/tests/Makefile @@ -8,6 +8,7 @@ ${PACKAGE}FILES+= adduser.lua ${PACKAGE}FILES+= dirname.lua ${PACKAGE}FILES+= err.lua ${PACKAGE}FILES+= sethostname.lua +${PACKAGE}FILES+= settimezone.lua ${PACKAGE}FILES+= warn.lua ${PACKAGE}FILES+= addfile.lua diff --git a/libexec/nuageinit/tests/nuage.sh b/libexec/nuageinit/tests/nuage.sh index 91260fc33a2f..4409b1ff5853 100644 --- a/libexec/nuageinit/tests/nuage.sh +++ b/libexec/nuageinit/tests/nuage.sh @@ -7,11 +7,20 @@ export NUAGE_FAKE_ROOTDIR="$PWD" atf_test_case sethostname +atf_test_case settimezone atf_test_case addsshkey atf_test_case adduser atf_test_case addgroup atf_test_case addfile +settimezone_body() +{ + atf_check /usr/libexec/flua $(atf_get_srcdir)/settimezone.lua + if [ ! -f etc/localtime ]; then + atf_fail "localtime not written" + fi +} + sethostname_body() { atf_check /usr/libexec/flua $(atf_get_srcdir)/sethostname.lua diff --git a/libexec/nuageinit/tests/nuageinit.sh b/libexec/nuageinit/tests/nuageinit.sh index 849f1c258b62..98593f7d75b0 100644 --- a/libexec/nuageinit/tests/nuageinit.sh +++ b/libexec/nuageinit/tests/nuageinit.sh @@ -815,7 +815,7 @@ config2_userdata_update_packages_body() package_update: true EOF chmod 755 "${PWD}"/media/nuageinit/user_data - atf_check -o inline:"pkg update -y\n" /usr/libexec/nuageinit "${PWD}"/media/nuageinit postnet + atf_check -o inline:"env ASSUME_ALWAYS_YES=yes pkg update\n" /usr/libexec/nuageinit "${PWD}"/media/nuageinit postnet } config2_userdata_upgrade_packages_body() @@ -829,7 +829,7 @@ config2_userdata_upgrade_packages_body() package_upgrade: true EOF chmod 755 "${PWD}"/media/nuageinit/user_data - atf_check -o inline:"pkg upgrade -y\n" /usr/libexec/nuageinit "${PWD}"/media/nuageinit postnet + atf_check -o inline:"env ASSUME_ALWAYS_YES=yes pkg upgrade\n" /usr/libexec/nuageinit "${PWD}"/media/nuageinit postnet } config2_userdata_shebang_body() diff --git a/libexec/nuageinit/tests/settimezone.lua b/libexec/nuageinit/tests/settimezone.lua new file mode 100644 index 000000000000..a8cacf09f4e7 --- /dev/null +++ b/libexec/nuageinit/tests/settimezone.lua @@ -0,0 +1,5 @@ +#!/usr/libexec/flua + +local n = require("nuage") + +n.settimezone("UTC") From nobody Wed Sep 17 19:42:21 2025 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 4cRq0t0byVz67wvk; Wed, 17 Sep 2025 19:42:22 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRq0s5QYvz4Gq5; Wed, 17 Sep 2025 19:42:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138141; 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=TfBaHF/j4nEl5zJF/dsJ3zg3aqKBkQgmXPpn3RM/qhA=; b=TebREKr//Xf0wbsAsN2yaBJnKL41F06Mp881K9e1WSgTJt4vh6gFuXWYzQZRXURsM2WzIt 8qRnVIvjOJkx9eimbQQBJb+vmrvlkPx4wShA9dV7vb4yEOvlgiVTv3u9C/rGjikiIxjoWx +dPKO6rKKy2J5a33A9Pe2CpwKiMuzGGBnpDAhdjmP8bIYlUWcYyVVByOaVMRi8KE6zo2la tfgtZBdXy8l1DRmGCaPKiIpX9EG2nX30/x11WoPFXzCErMwEklnRPQZLj4B2THG19KQoS+ +8zhZHy6YdNqQQLXNSmZ/OFkIoUSKZH/vjVu5Ez3z5/4F3huxmxuNjcPbOw4zA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138141; 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=TfBaHF/j4nEl5zJF/dsJ3zg3aqKBkQgmXPpn3RM/qhA=; b=QpXE1RYpP0DH+r5cg0oJRx8SkFVOuOPxJ+muOtCLH0vBcF0AFCK75J7Vt6nJA4th4AvxJY umGGz3ki42nTPsXIoNOkNx44x07mijbEkys1cG8/S7sj1Qa0gTlA2Bq89Da+YQfuavlpdC JDoDTL90ZeEoLpRXBnATiTTIHrX7mVAWBJ6PrQHxM4lVn4iP5DJhRsVtNdN6Rm9ge0zgFv pJPa0tqiu0oD5t6IXs+WBDnV3kNlS1s9OHyPR5hHFXhwAyfqo7EDf9pmbopt1NFGXA0kDs D3Ole8WNQNdvpnwNym4Tdk/GRwwSMis96dyBrhqMR0EfOun2ldNJsP029txc5w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758138141; a=rsa-sha256; cv=none; b=tfPMFmy4AtTfxxGqPHlguLxwfNctTl9WYj+j1puWmVe1/xZHDa/YI4Ez9tZLwj6P/jtlds 3NmW/q0x8R7sVeAbHc9GmtANEEiOGTaoS65nIHQZCsnwWQMo1/u4HQS5Qr6RWapiuKoKil xTaMLudpONhOfOe/XtDdnBGV7ItM5e3jutyoXvOJw9rjgDgrtEf8O/lzKLkBaGx2KxUPf/ MtFaYWjof5cp+tBJTKDp1m/mTHHNPDDI5idT0pnMJB3Ibr3R4QJ5tjLffXTSLOz1cAoNaL O8K0pklrmVlQUVzL/Uwe83A24wp3ZJYk3EPWXaNpZxP/VHYEWSO/1V3LPSQkTA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRq0s4t1Dzg8t; Wed, 17 Sep 2025 19:42:21 +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 58HJgL2u032037; Wed, 17 Sep 2025 19:42:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJgLK8032034; Wed, 17 Sep 2025 19:42:21 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:42:21 GMT Message-Id: <202509171942.58HJgLK8032034@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 918e1973ff27 - stable/14 - nuageinit: Remove duplicate description of users.{user}.groups 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 918e1973ff277512aac4f58e67bd9b1bfa913ec8 Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=918e1973ff277512aac4f58e67bd9b1bfa913ec8 commit 918e1973ff277512aac4f58e67bd9b1bfa913ec8 Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-09-11 16:47:07 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:39:23 +0000 nuageinit: Remove duplicate description of users.{user}.groups Reviewed by: bapt@ Approved by: bapt@ Differential Revision: https://reviews.freebsd.org/D52436 (cherry picked from commit 9f3330f5224ea2384a1c7d79a5b1f2784f7c14b6) --- libexec/nuageinit/nuageinit.7 | 2 -- 1 file changed, 2 deletions(-) diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index 604d8a2221ca..85504116de30 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -288,8 +288,6 @@ The encrypted password for the user. .It Ic plain_text_passwd The password in plain text for the user. Ignored if an encrypted password is already provided. -.It Ic groups -The list of other groups the user should belong to. .It Ic locked Boolean to determine if the user account should be locked. .It Ic sudo From nobody Wed Sep 17 19:42:22 2025 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 4cRq0v1sSVz67xNY; Wed, 17 Sep 2025 19:42:23 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRq0t6MKGz4Gb6; Wed, 17 Sep 2025 19:42:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138142; 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=JipEyRdKeislH+pA/Mmie+CcW/eWcsOe5G3HcPCNIrU=; b=I75Z8HD9nQu7eLxqbChgMWIztZ/BnRSwPImLjdjy2oNsOzT9Ei7b1apINtUJ2JMrBUltYu CRtIPm0bSg7LB9nLUuS+cN701IuRHZzdQVT++53fEt2ix62/FrUgBVegIZox6xOIUdhq3G PxQT6MHEyq1nXLz3xsF8LlY02Z3HuzmvxKyxrSe0aZwSo+7/X/werxmr4gvJbk35d2d1la wlxGRQu0bA4njUzuCPdVckft6q/FF64BjxwTqTwRg7BGEWsjBLiUq/FaIi+sGrQXeJzW3U QCiRTTIgN7o20pa6YiCcJiFG0vdYtbeTeZAZQlHe+wvhQYSlk49BjY/NR5MJqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138142; 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=JipEyRdKeislH+pA/Mmie+CcW/eWcsOe5G3HcPCNIrU=; b=BfFwHbA6CRV3rEXjX4CZzfnxYmJ46whmiE59SLrFUQBXlgLRztyEyBuQbpLXd5eFVhD3sc cBWndEP64gWIZbJ1jUPpnFCZyh4cOvSKerM3cg3d8BuNOJdE1fdsqCFzIZNH/k3p2XAPvi X0jhlE2aI2aOX2RXFxf5VLBNF44mWyIsALcUvuL9Af9MjyseWNw6+8zx45QvL3R+hwj0jv CzIjGYtFtBoF3Fjj4yHWFxrunTlnre7lDkgt5I+zNYpw6ZAU+dF5s7r24d2f/CZoeEPS6E FZcQZbI1LEiahycWpP5tSrmD0kIlkRg4x1dZi2SBt+Z3Ujq8UITQD9BQ0dyRDg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758138142; a=rsa-sha256; cv=none; b=HuBI2zyO0BR9VOZKeHmfUMGSzwR7yR+fGKOfCCxq1k07NlNK5wRGNrj5RKMM9sQ7z4lVCr iw4mX6eE1OmP9b8oiD41d76uCoK8sTjS8gfl/EkakThnMefTDlbEW2FfUWL5Qds6alzIdr w9nj9Ro5164Ea4/vBf8fPn2UdRJOfsJhY5dCO3mmuGVURq6EKGWDdXoUvpQAZB6iKiBNAP EtiC8nlycZGq/0uQoHKk5J0siBBosHEH8nipiDhID6y59miMLgKOZmDxXa860f121Al1kt K4LhaUgJ7oJFnAw95P+C+r7hHG/hrMSXeiKYklV0kiPtjpCw8FQBMhr+G54ktg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRq0t5smpzggq; Wed, 17 Sep 2025 19:42:22 +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 58HJgMwI032077; Wed, 17 Sep 2025 19:42:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJgMFb032074; Wed, 17 Sep 2025 19:42:22 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:42:22 GMT Message-Id: <202509171942.58HJgMFb032074@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: 5d8efb8f2578 - stable/14 - nuageinit: chmod sudoers directory instead of chmod (again) sudoers file 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5d8efb8f2578a1d94ef81c5157df1754f5dd13ab Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=5d8efb8f2578a1d94ef81c5157df1754f5dd13ab commit 5d8efb8f2578a1d94ef81c5157df1754f5dd13ab Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-09-11 16:49:56 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:39:23 +0000 nuageinit: chmod sudoers directory instead of chmod (again) sudoers file * Set mode of sudoers to 0440. Reviewed by: bapt@, jlduran@ Approved by: bapt@, jlduran@ Differential Revision: https://reviews.freebsd.org/D52438 (cherry picked from commit a5cc9b7b96dcba4d3ee98f2eb58c3f389590ddf0) --- libexec/nuageinit/nuage.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libexec/nuageinit/nuage.lua b/libexec/nuageinit/nuage.lua index 48f54b120615..22140dd06fe5 100644 --- a/libexec/nuageinit/nuage.lua +++ b/libexec/nuageinit/nuage.lua @@ -311,10 +311,10 @@ local function addsudo(pwd) end f:close() if chmodsudoers then - chmod(sudoers, "0640") + chmod(sudoers, "0440") end if chmodsudoersd then - chmod(sudoers, "0740") + chmod(sudoers_dir, "0750") end end From nobody Wed Sep 17 19:42:23 2025 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 4cRq0w4FHrz67x94; Wed, 17 Sep 2025 19:42:24 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRq0v70wrz4GYQ; Wed, 17 Sep 2025 19:42:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138144; 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=mFQFVynAgBe6VQr99iHcN9xF5DCFDaxsEcXCER8pnKw=; b=JOqZBTTboecQqRHQNjfetk6TpAITOQubBJ9XpKRXprLV7YWg7We8AveHrj2FLli8v5pEwT oZcDJHWpXPYShjidO7CXZfTZyyjaKEMgMIcNVcugBvFV0/ITO7if0+3O0Vu6igYhmPQgCa R2XlW0NMtG+LnfVH0bhCq/ynvq2htuvM3AVqtKoQ437NediaQBPbyY+SAW7WeW3OpS6opm Sv2uY1rqbFj3DvtzkAWFbn29TK67v8Rk1U58k/HLlu+1mKzs1hSIVXgeunZpvgmHzjJjdj DLUvV0QBmc5OAxTZvMGDtf/aoeMaQH5u1/QsgmRGgjfcnbNpSVDF5XK/Q6LLEA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138144; 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=mFQFVynAgBe6VQr99iHcN9xF5DCFDaxsEcXCER8pnKw=; b=Z7ySgcczHrWOTH6yH8WrJghinxL+A78WRlEiopZC2RoZy6Lt7waVsPnRsSzc8t0CFRnpuO njVoTCsyBQwbZvjIVCbqAi75v4ZtGqgSL2gQYGq1O2kVD4SFfxSCPND8z9AunVgvx3fl1h JsroOcy7tXmLJBfNruCNnhI+wFZ6yRW+ZBhb32Wr5g4oFZeBNRCuDGLitkuFS68Bay/PZy /YjRqak72ETw8ilBmezoCV0roTMxZtwRFx4aIkrTtyAzvgufC5sB2fp5erwhpUGnl5M/1m z7vbT7PGf2olu23qx1EJ/lfNgbQZfHeQZ1J8RLcVJN0NkwCMtZGeA075SL352Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758138144; a=rsa-sha256; cv=none; b=Nqq1fw8CF9K95sIJx05/V8plBDzgNJ9vY53RE+hiwe+34ehCVdIDYwLYNKnboTRVOQXBN4 EA2e8nYKRANbk2rnjgPJMunmRsWbgflnpw72LaSsArR2MMvneGQs04aEOm2v0QyYWx2u4U qf/8WWTqKLFe8m3kGUWc8JbH/NZZpRZ7vfX98+7510bFUb2ihyU74g7bv9B0DF7B8jOjdf N5sO5UrieLqi2H/4/HUsFal5hxOTkzk5xuwmP7vjHYYk/AZezKbFB8emvbV+34WatwT+LJ tN4U+Jv2/47ppOFq8tf15jzskgRRtTGQAPfwyTMghSvuIh5/BqOFyd4pWeCPRw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRq0v6WBnzgvL; Wed, 17 Sep 2025 19:42:23 +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 58HJgNQh032111; Wed, 17 Sep 2025 19:42:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJgNK8032108; Wed, 17 Sep 2025 19:42:23 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:42:23 GMT Message-Id: <202509171942.58HJgNK8032108@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: d9843a40f8b1 - stable/14 - nuageinit: Add me to copyright list 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d9843a40f8b15b8be1594615b609fe3e7b828b9d Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=d9843a40f8b15b8be1594615b609fe3e7b828b9d commit d9843a40f8b15b8be1594615b609fe3e7b828b9d Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-09-11 17:00:41 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:39:24 +0000 nuageinit: Add me to copyright list Approved by: bapt@ (cherry picked from commit 18555060dcae4cad8f2f8968142fc02a2571377b) --- libexec/nuageinit/nuage.lua | 1 + libexec/nuageinit/nuageinit | 1 + libexec/nuageinit/nuageinit.7 | 1 + libexec/nuageinit/tests/nuage.sh | 1 + libexec/nuageinit/tests/nuageinit.sh | 1 + libexec/nuageinit/tests/utils.sh | 1 + 6 files changed, 6 insertions(+) diff --git a/libexec/nuageinit/nuage.lua b/libexec/nuageinit/nuage.lua index 22140dd06fe5..b042698f97e7 100644 --- a/libexec/nuageinit/nuage.lua +++ b/libexec/nuageinit/nuage.lua @@ -2,6 +2,7 @@ -- SPDX-License-Identifier: BSD-2-Clause -- -- Copyright(c) 2022-2025 Baptiste Daroussin +-- Copyright(c) 2025 Jesús Daniel Colmenares Oviedo local unistd = require("posix.unistd") local sys_stat = require("posix.sys.stat") diff --git a/libexec/nuageinit/nuageinit b/libexec/nuageinit/nuageinit index 70b27cb33d87..c94eb822ba0f 100755 --- a/libexec/nuageinit/nuageinit +++ b/libexec/nuageinit/nuageinit @@ -3,6 +3,7 @@ -- SPDX-License-Identifier: BSD-2-Clause-FreeBSD -- -- Copyright(c) 2022-2025 Baptiste Daroussin +-- Copyright(c) 2025 Jesús Daniel Colmenares Oviedo local nuage = require("nuage") local ucl = require("ucl") diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index 85504116de30..f02829618f44 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -1,6 +1,7 @@ .\" SPDX-License-Identifier: BSD-2-Clause .\" .\" Copyright (c) 2025 Baptiste Daroussin +.\" Copyright (c) 2025 Jesús Daniel Colmenares Oviedo .\" .Dd June 26, 2025 .Dt NUAGEINIT 7 diff --git a/libexec/nuageinit/tests/nuage.sh b/libexec/nuageinit/tests/nuage.sh index 4409b1ff5853..e286360922db 100644 --- a/libexec/nuageinit/tests/nuage.sh +++ b/libexec/nuageinit/tests/nuage.sh @@ -1,5 +1,6 @@ #- # Copyright (c) 2022-2025 Baptiste Daroussin +# Copyright (c) 2025 Jesús Daniel Colmenares Oviedo # # SPDX-License-Identifier: BSD-2-Clause # diff --git a/libexec/nuageinit/tests/nuageinit.sh b/libexec/nuageinit/tests/nuageinit.sh index 98593f7d75b0..619df019cc4f 100644 --- a/libexec/nuageinit/tests/nuageinit.sh +++ b/libexec/nuageinit/tests/nuageinit.sh @@ -1,5 +1,6 @@ #- # Copyright (c) 2022-2025 Baptiste Daroussin +# Copyright (c) 2025 Jesús Daniel Colmenares Oviedo # # SPDX-License-Identifier: BSD-2-Clause # diff --git a/libexec/nuageinit/tests/utils.sh b/libexec/nuageinit/tests/utils.sh index 26f117d81d60..76cd7e045473 100644 --- a/libexec/nuageinit/tests/utils.sh +++ b/libexec/nuageinit/tests/utils.sh @@ -1,5 +1,6 @@ #- # Copyright (c) 2022 Baptiste Daroussin +# Copyright (c) 2025 Jesús Daniel Colmenares Oviedo # # SPDX-License-Identifier: BSD-2-Clause # From nobody Wed Sep 17 19:42:24 2025 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 4cRq0x3nDHz67xNZ; Wed, 17 Sep 2025 19:42:25 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRq0x1Gx8z4GnN; Wed, 17 Sep 2025 19:42:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138145; 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=MfuZ35f4zVM1bUkJph7NITkaxO+QnD5yfoP+KDhzmOs=; b=Kam33lw4mEVs0fysFnYeL5CIDzJGl06RZpNHC8xMD2mvKt3KrbOUxsLVI5gtxdhrPN7sJx wzqH8H/+RPsdRLOjCiEYS7OMhtKCnkqYBzgV/7Se+wgJ0cXMNCjfTep8wkUIndnxyG26lJ kDmcPHDMzFutz+yBngJ1jV/SaTKW7RESPyBjb6jDRr6UBpCs5fIzYnF/pb/H+Ah85z1cGY kxEV1NDx3cPvRpEa6WivYPcaCa5VoN2PZ4uls0nYllnkEsILZrNEcb3pSbcqWLRmMBY5Xv M+9rBpzX751oApEaqJxktGIxEpuwawoCz87Ch9fZVyrUhAmIBpad/txMGlf9YQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138145; 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=MfuZ35f4zVM1bUkJph7NITkaxO+QnD5yfoP+KDhzmOs=; b=f5S/SLjpqlxSqlajzwVbaEqH8euv+pg2uOWl2c8vA2bvEvJYgiJSCSRoYIeZ1eyfBmyQdZ bSqc5bniK2fQ+yRL7IirkPUfhqp8Cr1cuh1m0cxto8IIqQMZEHoPmV0hxpC36DE4sUUsEG insNKuF5F7iatCizlsVdlZ0Yz4uq9NOXP3Dd/s4IaA8vZ1uXayRqrzI+cj9BeCteC1lGlo 5EIuI8dxJe6iB30Zuv1pj5L81U3A8FTI7fr8uahxQz5/obll0r1ejgcnoznbKPfaOuCx5w vBQkRCXS2e3xKHP39Khz4vnvfbBZrQflU4HuKNT0SpMcI8NOyoKfcQ2Fd+kAiQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758138145; a=rsa-sha256; cv=none; b=ETBGZ53/GYw1EnqXCvdG36lBs/EN3fJvI7KohM61p2EbgVnbzpPyi4klnfi4iuOfXw/GzZ i0zCnP1NAgYIpQCLoJcGgTMWuNQdWqmAaxCL+Ika2tQWHlIDvINe1NubVQV+auGZfvGmh7 5qN1X45Y0mu9Q6r42Ae+6LBOphp2gdaxum2A9c2Mc6NNmyGsObeGBNSbpL6urCHknmiIlo QJ6XbLSBYGOz+FFxkjiY2cGu1/L9xYb62hF/SbgAuZNMAq52spQsGQyxsUdkG+k2W3Zcwa m8jkJTj1+yuPo92/azRFC0TfixIsNeaWt1tZ9XrTRIo8a3tBJ/S30x+5QJRE1w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRq0x0f7wzg8x; Wed, 17 Sep 2025 19:42:25 +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 58HJgOnQ032145; Wed, 17 Sep 2025 19:42:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJgOlb032142; Wed, 17 Sep 2025 19:42:24 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:42:24 GMT Message-Id: <202509171942.58HJgOlb032142@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: bf187f6ac5b1 - stable/14 - nuageinit: Allow the use of network parameters from network-config 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: bf187f6ac5b198d51b3db80c8876fc70ce75b162 Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=bf187f6ac5b198d51b3db80c8876fc70ce75b162 commit bf187f6ac5b198d51b3db80c8876fc70ce75b162 Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-09-11 16:52:30 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:39:24 +0000 nuageinit: Allow the use of network parameters from network-config To better comply with the cloud-init specification, we need to support the configuration of network-related parameters from the network-config file, which is common in most deployments. Reviewed by: bapt@ Approved by: bapt@ Differential Revision: https://reviews.freebsd.org/D52419 (cherry picked from commit 95230b248f6412c2d1c416c1e9795c3192cdf750) --- libexec/nuageinit/nuageinit | 31 ++++++++++++++++++++++++++++++- libexec/nuageinit/nuageinit.7 | 7 +++++++ 2 files changed, 37 insertions(+), 1 deletion(-) diff --git a/libexec/nuageinit/nuageinit b/libexec/nuageinit/nuageinit index c94eb822ba0f..5541f6d0f164 100755 --- a/libexec/nuageinit/nuageinit +++ b/libexec/nuageinit/nuageinit @@ -583,6 +583,26 @@ local function config2_network(p) routing:close() end +local function parse_network_config() + local nc_file = ni_path .. "/network-config" + local nc_file_attr = lfs.attributes(nc_file) + if nc_file_attr == nil then + return + end + local f, err = io.open(nc_file) + if err then + nuage.err("error parsing nocloud network-config: " .. err) + end + local obj = yaml.load(f:read("*a")) + f:close() + if not obj then + nuage.err("error parsing nocloud network-config") + end + local netobj = {} + netobj["network"] = obj + return netobj +end + if citype == "config-2" then local parser = ucl.parser() local res, err = parser:parse_file(ni_path .. "/meta_data.json") @@ -679,7 +699,16 @@ if line == "#cloud-config" then end for i = 1, #calls_table do - calls_table[i](obj) + if citype == "nocloud" and calls_table[i] == network_config then + netobj = parse_network_config() + if netobj == nil then + network_config(obj) + else + network_config(netobj) + end + else + calls_table[i](obj) + end end elseif line:sub(1, 2) == "#!" then -- delay for execution at rc.local time -- diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index f02829618f44..8d9aac3d3809 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -183,6 +183,13 @@ configuration in .Pa /etc/ssh/sshd_config .It Ic network Network configuration parameters. +.Pp +Specifying the following parameters from a file named +.Pa network-config +takes precedence over their specification from the +.Ic network +parameter of +.Pa user-data Ns . .Bl -tag -width "ethernets" .It Ic ethernets Mapping representing a generic configuration for existing network interfaces. From nobody Wed Sep 17 19:42:26 2025 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 4cRq0y4C42z67xJK; Wed, 17 Sep 2025 19:42:26 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRq0y223gz4GYh; Wed, 17 Sep 2025 19:42:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138146; 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=moOf/piqOQn1EU2BnCZPckYH7Rmr7VFHt7QBWm++d7Y=; b=KthkUYSa7c1Nj8R3CxzbTs18wRYjrIiSeHbDaPYbtDCsShmKRxg0XLJbdoeutgJVSzsu65 fk+egUqVMlN5bWXqznKan2ib6+9V6iJLqREwv8+7YJyIubWzMKM3AVkA6OJWb6ffr5Sr0E 4RxpIyYuEqmfOMCMrjZmlul5yANYlaXKFjrsBMyOcaTx6Gee7k3gNf4Ojln9O0yajQ9/DB qzcVAjq6+57b3RXIGgzTG3AavAL1FaFjwhSTucdSqfk69zrVuviI8gdYSCGy6QNMoj58Jq FP3FWUx8MJiF1xnhbD9u1JOGz9hsKlo/JSQhOZ2lAgLIwB4PwfwwbQVOrcKaeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138146; 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=moOf/piqOQn1EU2BnCZPckYH7Rmr7VFHt7QBWm++d7Y=; b=LjoBgfj1JYYXttCWL2+G9cd1NJHgHCUeqav+DzazdHDcAjYo7KooRCcCZB5h7BSut5swvs hJIqsHG7r/LuJCtJtAxKofYufMAe6Eh3g5C+kowWOiW0MxCPIk5vBNFk0JlKH6LAEMwybx xwmztcH/0/JJCUoUob31NeXDRDarB2oIo45F05ztIprwh0c5A8TwQbT1BC5UaaAwJvtThV XUAOK2+UVsON12Rx2J8fUY+4mXJ2m46qd20pyuz3NSJlb4t4yerN3Kwx59GpR7OyDLe+vV mT4QfZTqR9PB032K4EecFSzAwlM5aaz0XJHi3JT7m8vjqZ4UP9D/zPZZaR5Ilw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758138146; a=rsa-sha256; cv=none; b=U6oYHrVFIhU9KLYncSmjf6UnuKZ87LuiAQXugrjhrpS9XgDc+8wUdVcoBS7tlLiUYp5dA6 xvh5G2II+DBJnWJWOcAuvuhZgrmdG5IMpAirJaC0dHy9FadzccqX5dXBo2nDPRQg+ddyBF +iw6pPMcgSNi9OEnlWtH3YeTaRYC//8bJ0J7Ue0Hhf1lJpGvryHb5N8aGDFB6bH1sm1XEi Wz10gE0pw6GbBTblc1rbieq0TvnWYKmd8ebR6WJ045lB1fVmy4Fdb6UE2VpFMXoFrLFCdq TazgdzrQ4TVUiC4ejNP79HKVgZ2JhwkEbUlDsaZlP6WBmqBTiheUNRhM7uwJzw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRq0y1Xd7zggr; Wed, 17 Sep 2025 19:42:26 +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 58HJgQT4032178; Wed, 17 Sep 2025 19:42:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJgQ6X032175; Wed, 17 Sep 2025 19:42:26 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:42:26 GMT Message-Id: <202509171942.58HJgQ6X032175@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: ea186b76c675 - stable/14 - nuageinit.7: grammar fixes 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ea186b76c675ac05e4ece3eddd2d301a80e9547d Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=ea186b76c675ac05e4ece3eddd2d301a80e9547d commit ea186b76c675ac05e4ece3eddd2d301a80e9547d Author: Maxim Konovalov AuthorDate: 2025-08-22 18:57:03 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:40:59 +0000 nuageinit.7: grammar fixes (cherry picked from commit 95b0be1118b1a24ceb1b59ecd936aaa155d828bd) --- libexec/nuageinit/nuageinit.7 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index 8d9aac3d3809..dac5527b75b7 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -299,7 +299,7 @@ Ignored if an encrypted password is already provided. .It Ic locked Boolean to determine if the user account should be locked. .It Ic sudo -A string or an array of strings which which should be appended to +A string or an array of strings which should be appended to .Pa /usr/local/etc/sudoers.d/90-nuageinit-users .El .Pp @@ -339,7 +339,7 @@ It accepts the following keys for each objects: The content to be written to the file. If this key is not existing then an empty file will be created. .It Ic encoding -Specifiy the encoding used for content. +Specify the encoding used for content. If not specified, then plain text is considered. Only .Ar b64 From nobody Wed Sep 17 19:42:27 2025 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 4cRq0z5bYYz67x2g; Wed, 17 Sep 2025 19:42:27 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRq0z2q6qz4GR6; Wed, 17 Sep 2025 19:42:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138147; 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=qFSFvaOEa2fbR9jZLMmMwdI4KWukH8XSm33PfLHCx9s=; b=I4CjgOWyptfmZtw+0zli74OeELEdrCj1wSdeAkSAk1C6wZvSWqVDCOzl3P+BkICtWnvZ5g /+bIV2jifkrl44oFj+FNaTpTD4Fh62l/1ysTRIPPwePSTjz2kR78PqiHlWLNnW6zob2xCx oQUK7xtqRZOJgL7ivwo1YXbvcu8/YHh1XfHoXfyslVZkZ5t1z30p6CoGLJ4F9yIjML145d lVmOLm2ePeCe1UnATsxoxsd7qZpOXea8n7XDzONTounzniTzw9U4JmS1ZNq13eieDwacZ0 xVlRZXAStUluDiWLsJ1mqIeZEo2B7v4TbZkxV/YCIfTxvfU7KZneb7ZWNKYVdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138147; 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=qFSFvaOEa2fbR9jZLMmMwdI4KWukH8XSm33PfLHCx9s=; b=K4zwykzWNo2HpPZXvXLulVhDqRryA2AV3bFVMDSXN6BtYJOeA1aHkDY7ULfk5BDwSU2AbC x22M/9ci3gg4cBdkG9uFb4qFxZeNgk8QsqxfrVmqE//lkESY+MzuYSagTAfN2drIOIuScw djdd+d7SXNMRclDz0aV1DDUUVSkaFutXAC7IhyynXJuFFQrnja0UwxtFlavv/TNr9IRnlG TselXh+MuF7TaKpmEuO4QGi+XC7Fk3AttvOxz+QRMauKKKlw1yC+POUgdNckrjn9FTGgg6 LWlqPVr4bTlokbo/Ja4yXFStLG29Y54S+NyLfcAOGfImVo38SVqlr613578FPA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758138147; a=rsa-sha256; cv=none; b=EJY34T2zYTNRGAIgRd0rFi5PjoV36yB89XPO00mRCc/UeSBkYsr0th6+carXpwIm6bShEM Hstg4nbGGtC0q2DRiJVJz130ZgveprUHWVwhfKZKVfaMRrFQ90xcQtXMlo+qCRx6huQDpv Nus40AtpliW/mpC7KDh4qfqJjnuGPsXtDLzMcQD9jhkMh0Q49IwzbBWMegIvxkRNz3WlIu puLBuq5UDlDZjGwS12qZLfwcuGeKdRyGLk1UzbXCpq3z3wusJEDp/tIp71lVMJI4+JqfSv OSQ3y+RphevpdnW4tRjVcc4QOPvKPvgRTNuMj92o+y5pFgDPUeJExloYStd+tg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRq0z2KzZzgBb; Wed, 17 Sep 2025 19:42:27 +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 58HJgRBF032916; Wed, 17 Sep 2025 19:42:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJgRFo032905; Wed, 17 Sep 2025 19:42:27 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:42:27 GMT Message-Id: <202509171942.58HJgRFo032905@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: f0588c1cd8d9 - stable/14 - nuageinit.7: put each sentence on a new line 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: f0588c1cd8d92f692f18debaf66a90c95e037022 Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=f0588c1cd8d92f692f18debaf66a90c95e037022 commit f0588c1cd8d92f692f18debaf66a90c95e037022 Author: Maxim Konovalov AuthorDate: 2025-08-22 19:06:45 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:40:59 +0000 nuageinit.7: put each sentence on a new line (cherry picked from commit a7f19968ae5d5e7e5feba85d04698050fcaf784f) --- libexec/nuageinit/nuageinit.7 | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index dac5527b75b7..e5da5cf342e1 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -205,21 +205,26 @@ rules are specified, an arbitrary name can be used .It Ic match This selects a subset of available physical devices by various hardware properties. The following configuration will then apply to all matching devices, as soon as -they appear. All specified properties must match. The following properties for +they appear. +All specified properties must match. +The following properties for creating matches are supported: .Bl -tag -width "macaddress" .It Ic macaddress .No Device's MAC address in the form Sy xx:xx:xx:xx:xx:xx Ns . Letters should be lowercase. .It Ic name -Current interface name. Lua pattern-matching expressions are supported. +Current interface name. +Lua pattern-matching expressions are supported. .It Ic driver -Interface driver name and unit number of the interface. Lua pattern-natching expressions +Interface driver name and unit number of the interface. +Lua pattern-natching expressions are supported. .El .It Ic set-name When matching on unique properties such as MAC, match rules can be written so that they -match only one device. Then this property can be used to give that device a more +match only one device. +Then this property can be used to give that device a more specific/desirable/nicer name than the default. .Pp While multiple properties can be used in a match, @@ -229,7 +234,8 @@ is required for nuageinit to perform the rename. The MTU key represents a device's Maximum Transmission Unit, the largest size packet or frame. .It Ic wakeonlan -Enable wake on LAN. Off by default. +Enable wake on LAN. +Off by default. .It Ic dhcp4 Configure the interface to use DHCP. .Pp @@ -239,14 +245,16 @@ when both are specified. .It Ic addresses List of strings representing IPv4 or IPv6 addresses. .It Ic gateway4 -Set default gateway for IPv4, for manual address configuration. This requires setting +Set default gateway for IPv4, for manual address configuration. +This requires setting .Sy addresses too. .Pp Since only one default router can be configured at a time, this parameter is applied when processing the first entry, and any others are silently ignored. .It Ic gateway6 -Set default gateway for IPv6, for manual address configuration. This requires setting +Set default gateway for IPv6, for manual address configuration. +This requires setting .Sy addresses too. .Pp From nobody Wed Sep 17 19:42:28 2025 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 4cRq106Pmjz67xNh; Wed, 17 Sep 2025 19:42:28 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRq103qSfz4GZ5; Wed, 17 Sep 2025 19:42:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138148; 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=fSUG0k92Gwu4Sh3s4M8IIqsBDe+taH8KA6ayQpKSggU=; b=GDWG801F5SlEcTeiA7D4nj007iBPZyyzJAuyYhLqAnAx8XVS63gY2YkZOqhbgr0qzcPvIm oeJccle7pChq8KvRoNJ6x0ebSJwGjRiu3uun/WIZQxVKxir+kwY6g//Q26heXrYqIEqhDu zict2KfNNDKX4O3GP4d2tD7Rf+CFzQQoipuX5Qpa66xntb406kmCnZPDLS4swQDwHh1oVR jb/LyquIFWM6XMBLY8OJQvtJTxRh10KKDZzXX+U519DT7Ly7l9wjCALs4/WhK9ikDtKSbd AI6u6JIW4BIfp3kRiwGOIT7e7Qf051aXs6XC94ohB9JaU48INlgEHhpWCJp93Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758138148; 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=fSUG0k92Gwu4Sh3s4M8IIqsBDe+taH8KA6ayQpKSggU=; b=M9lrd2ZhX1Ws6Vz8A3q4CZNQTq/U00s4uYeDpAQJdgtamsFnT/+aPONi9Gxutz94YHFpBm 0YcSCaNpX21mvnnhhdr7fcv/L277PoBTRaqhqzcULBM5jQDcP9KcneGa6fHWUC91Z1GKUm L8cz0Mmmgf7yBN3rB88E04QeLId6xChXWXxTaZUUIqFnLuZlWyZp8A/eLc4IyQH6lLU/2L nUdIcDGhWB7C4zz35Lz1RAH//N/mhMRd+HPKX2Nk7H4F9a07c5zFZJVnfb/WAe2tIz1ldM vIPGyx9ASRxivUxzkRHOOGU95je81eiDet/nuPIqr4tIsduek0DNhlaNYGsrSg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758138148; a=rsa-sha256; cv=none; b=Uf0JILq6WC5LEYm4IwACAhC0MnQuvh05z54MVwKxcjqE4iJ+d4yV8DD+m1h+DVkNFfUBeq vdYBeUGZ4Cc9mnVnxyrd9relm2rhpbqd2BMa5oCfHr3sGCgfT7ERpXWu3DpDNRUcmFGH83 Yt9znUOaE2lop8j3LkTz+hAqQP6VEsUl3aLlR978pFN9Yk9gkugAVdqTxBMyYLvEWhWGkU WGTPgch8QMDHBs2QF2RIZJbFGqf2DOS9jRegDKD/uZDw3KfXjXRK08WFOphJFW9/jz2oDW ppaVAJR5beWtR2DEoILahSniiFD9kpuDYDQHRTin1udQzveL/fstLPbIhP1DvQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRq103FqZzggt; Wed, 17 Sep 2025 19:42:28 +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 58HJgSW3033552; Wed, 17 Sep 2025 19:42:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HJgS7H033549; Wed, 17 Sep 2025 19:42:28 GMT (envelope-from git) Date: Wed, 17 Sep 2025 19:42:28 GMT Message-Id: <202509171942.58HJgS7H033549@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Baptiste Daroussin Subject: git: cbd62452bff6 - stable/14 - nuageinit: Add doas support 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: cbd62452bff6bc8837c9cffeaa4c9f43b99995ce Auto-Submitted: auto-generated The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=cbd62452bff6bc8837c9cffeaa4c9f43b99995ce commit cbd62452bff6bc8837c9cffeaa4c9f43b99995ce Author: Jesús Daniel Colmenares Oviedo AuthorDate: 2025-09-11 16:54:24 +0000 Commit: Baptiste Daroussin CommitDate: 2025-09-17 19:42:03 +0000 nuageinit: Add doas support * Set mode of etc directory to 0755. * Use user.localbase sysctl instead of /usr/local. * Add test case for doas. * Set ${LOCALBASE} instead of /usr/local in nuageinit(7) man page. Reviewed by: bapt@ Approved by: bapt@ Differential Revision: https://reviews.freebsd.org/D52437 (cherry picked from commit 9a829e865697e623a046800545be7781a117125e) --- libexec/nuageinit/nuage.lua | 62 +++++++++++++++++++++++++++++++++++- libexec/nuageinit/nuageinit | 3 ++ libexec/nuageinit/nuageinit.7 | 9 +++++- libexec/nuageinit/tests/nuageinit.sh | 12 ++++++- 4 files changed, 83 insertions(+), 3 deletions(-) diff --git a/libexec/nuageinit/nuage.lua b/libexec/nuageinit/nuage.lua index b042698f97e7..ef3cfd994fe1 100644 --- a/libexec/nuageinit/nuage.lua +++ b/libexec/nuageinit/nuage.lua @@ -8,6 +8,17 @@ local unistd = require("posix.unistd") local sys_stat = require("posix.sys.stat") local lfs = require("lfs") +local function getlocalbase() + local f = io.popen("sysctl -in user.localbase 2> /dev/null") + local localbase = f:read("*l") + f:close() + if localbase == nil or localbase:len() == 0 then + -- fallback + localbase = "/usr/local" + end + return localbase +end + local function decode_base64(input) local b = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' input = string.gsub(input, '[^'..b..'=]', '') @@ -277,11 +288,59 @@ local function addsshkey(homedir, key) end end +local function adddoas(pwd) + local chmodetcdir = false + local chmoddoasconf = false + local root = os.getenv("NUAGE_FAKE_ROOTDIR") + local localbase = getlocalbase() + local etcdir = localbase .. "/etc" + if root then + etcdir= root .. etcdir + end + local doasconf = etcdir .. "/doas.conf" + local doasconf_attr = lfs.attributes(doasconf) + if doasconf_attr == nil then + chmoddoasconf = true + local dirattrs = lfs.attributes(etcdir) + if dirattrs == nil then + local r, err = mkdir_p(etcdir) + if not r then + return nil, err .. " (creating " .. etcdir .. ")" + end + chmodetcdir = true + end + end + local f = io.open(doasconf, "a") + if not f then + warnmsg("impossible to open " .. doasconf) + return + end + if type(pwd.doas) == "string" then + local rule = pwd.doas + rule = rule:gsub("%%u", pwd.name) + f:write(rule .. "\n") + elseif type(pwd.doas) == "table" then + for _, str in ipairs(pwd.doas) do + local rule = str + rule = rule:gsub("%%u", pwd.name) + f:write(rule .. "\n") + end + end + f:close() + if chmoddoasconf then + chmod(doasconf, "0640") + end + if chmodetcdir then + chmod(etcdir, "0755") + end +end + local function addsudo(pwd) local chmodsudoersd = false local chmodsudoers = false local root = os.getenv("NUAGE_FAKE_ROOTDIR") - local sudoers_dir = "/usr/local/etc/sudoers.d" + local localbase = getlocalbase() + local sudoers_dir = localbase .. "/etc/sudoers.d" if root then sudoers_dir= root .. sudoers_dir end @@ -585,6 +644,7 @@ local n = { update_packages = update_packages, upgrade_packages = upgrade_packages, addsudo = addsudo, + adddoas = adddoas, addfile = addfile } diff --git a/libexec/nuageinit/nuageinit b/libexec/nuageinit/nuageinit index 5541f6d0f164..29340a3d91ea 100755 --- a/libexec/nuageinit/nuageinit +++ b/libexec/nuageinit/nuageinit @@ -140,6 +140,9 @@ local function users(obj) if u.sudo then nuage.addsudo(u) end + if u.doas then + nuage.adddoas(u) + end else nuage.warn("invalid type : " .. type(u) .. " for users entry number " .. n) end diff --git a/libexec/nuageinit/nuageinit.7 b/libexec/nuageinit/nuageinit.7 index e5da5cf342e1..b527c984970c 100644 --- a/libexec/nuageinit/nuageinit.7 +++ b/libexec/nuageinit/nuageinit.7 @@ -308,7 +308,14 @@ Ignored if an encrypted password is already provided. Boolean to determine if the user account should be locked. .It Ic sudo A string or an array of strings which should be appended to -.Pa /usr/local/etc/sudoers.d/90-nuageinit-users +.Pa ${LOCALBASE}/etc/sudoers.d/90-nuageinit-users +.It Ic doas +A string or an array of strings which should be appended to +.Pa ${LOCALBASE}/etc/doas.conf +.Pp +Instead of hardcoding the username, you can use +.Sy %u Ns , +which will be replaced by the current username. .El .Pp A special case exist: if the entry is a simple string with the value diff --git a/libexec/nuageinit/tests/nuageinit.sh b/libexec/nuageinit/tests/nuageinit.sh index 619df019cc4f..2b7c5226c97a 100644 --- a/libexec/nuageinit/tests/nuageinit.sh +++ b/libexec/nuageinit/tests/nuageinit.sh @@ -120,12 +120,16 @@ users: gecos: Foo B. Bar primary_group: foobar sudo: ALL=(ALL) NOPASSWD:ALL + doas: permit persist %u as root groups: users passwd: $6$j212wezy$7H/1LT4f9/N3wpgNunhsIqtMj62OKiS3nyNwuizouQc3u7MbYCarYeAHWYPYb2FT.lbioDm2RrkJPb9BZMN1O/ - name: bla sudo: - "ALL=(ALL) NOPASSWD:/usr/sbin/pw" - "ALL=(ALL) ALL" + doas: + - "deny %u as foobar" + - "permit persist %u as root cmd whoami" EOF atf_check /usr/libexec/nuageinit "${PWD}"/media/nuageinit nocloud atf_check /usr/libexec/nuageinit "${PWD}"/media/nuageinit postnet @@ -148,7 +152,13 @@ EOF sed -i "" "s/freebsd:.*:1001/freebsd:freebsd:1001/" "${PWD}"/etc/master.passwd atf_check -o file:expectedpasswd cat "${PWD}"/etc/master.passwd atf_check -o file:expectedgroup cat "${PWD}"/etc/group - atf_check -o inline:"foobar ALL=(ALL) NOPASSWD:ALL\nbla ALL=(ALL) NOPASSWD:/usr/sbin/pw\nbla ALL=(ALL) ALL\n" cat ${PWD}/usr/local/etc/sudoers.d/90-nuageinit-users + localbase=`sysctl -ni user.localbase 2> /dev/null` + if [ -z "${localbase}" ]; then + # fallback + localbase="/usr/local" + fi + atf_check -o inline:"foobar ALL=(ALL) NOPASSWD:ALL\nbla ALL=(ALL) NOPASSWD:/usr/sbin/pw\nbla ALL=(ALL) ALL\n" cat "${PWD}/${localbase}/etc/sudoers.d/90-nuageinit-users" + atf_check -o inline:"permit persist foobar as root\ndeny bla as foobar\npermit persist bla as root cmd whoami\n" cat "${PWD}/${localbase}/etc/doas.conf" } nocloud_network_head() From nobody Wed Sep 17 20:30:01 2025 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 4cRr3s6z6wz681vj; Wed, 17 Sep 2025 20:30: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRr3s6DBlz3Cf5; Wed, 17 Sep 2025 20:30:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758141001; 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=uPneM/7h1OB6LwXSqX+zSnCGPSjzX+P4ayvlDWf8c48=; b=XP0ynsekWaFq06unf8djGxFAVlQQCZojqew5awqnUg1ZrET+euDNxFR4cROKbP7NvpweTh d3KrOBvVSHhZIyAUC3LRn/Oc1lWMiG1NdHpdQDXgeBbf/q1LUWxsvRycXcXxvn6/mGU3ZD OJMuGnVb7OU8J0MQxzbJlcvwgYaT2BSPZwgV/OJ4PRRQX9sQ7yybi/kGasoN1Kn/F19ri2 kv4ll8wiQTGfrvpSuFJY3d4mnKCWSn1ldNIpj56ZCmWXAt7mzJMJ0ghfVZCUwlne5E/AVL wbUNvpAXHxmDjlnqbjh2Mo1WIEvyrZdk4++w+T6aQ0sLOCnE9c68kaRCA+5bzg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758141001; 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=uPneM/7h1OB6LwXSqX+zSnCGPSjzX+P4ayvlDWf8c48=; b=qJl5I9SIUnKFTGYVDWMmr+0IfUGFxWAC0vovc0ZxmbOvDBkv0caEuwb+rVY9fDbMd7D1BR SWE126PYH9QX5cotXhjPjtpP9Tg4AAZF1pfCR2jCtCzMFkRTW6eiO2p03iStklRe3fGT4N GF9VynDvAilRsDFxHvFyduxahe99pyF1V7IVrsmVtX3w6S/WuVaSQoQrcZRI3uv6TrdfLM 0kpMXYYvivZdKf4GagpCmm2YMxRXBRr2P95Ahnx/u5pDywajT2xp2Xo/ffmep7o7It0OQw /X8lmubueI7gsJpu0EDP0mPTwc+IVVfg1bIp5+Q2lTkk9YrrtT0dfC5CHToBmQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758141001; a=rsa-sha256; cv=none; b=TwimLGVHMTUWwpBw2vL/Y6uTMiOLLgNLd9rgXc+rdZ3f/ZVhMWNb8cVdmBvnTWeK+MUCeg 1F6pSJZZxIKxw6A9MdXUgR1YNMANtzETk0QjKgxyWf5lJAN9L+FDp+FTCLQ0yn7+Tar7o6 t1y6udu09EdG1EDFBFDM9rzcqSAKdTSIgvcPDblqVYblmqstb5F4JSMIWSM1oiizfz8Owc uzjO43F0/AuLhV+cFZJMfnT/49jL+153e5+wrLKI3N48/+acv72eDytlvsdrW6+3dPWNK0 K/4wAq+5SjmEDKXYjVF1cipI38Hf+xooGAMQZc3n48yffTQcAiaLslCpvvO4eA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRr3s5VD0zhqM; Wed, 17 Sep 2025 20:30:01 +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 58HKU1i8013418; Wed, 17 Sep 2025 20:30:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HKU1rF013412; Wed, 17 Sep 2025 20:30:01 GMT (envelope-from git) Date: Wed, 17 Sep 2025 20:30:01 GMT Message-Id: <202509172030.58HKU1rF013412@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Osipov Subject: git: 221a5fb331e1 - stable/15 - bsdinstall: Drop outdated comments about ZFS dataset compression 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: michaelo X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 221a5fb331e104a1becb67090ef8ee843cbce1d7 Auto-Submitted: auto-generated The branch stable/15 has been updated by michaelo: URL: https://cgit.FreeBSD.org/src/commit/?id=221a5fb331e104a1becb67090ef8ee843cbce1d7 commit 221a5fb331e104a1becb67090ef8ee843cbce1d7 Author: Michael Osipov AuthorDate: 2025-08-31 10:10:48 +0000 Commit: Michael Osipov CommitDate: 2025-09-17 20:29:50 +0000 bsdinstall: Drop outdated comments about ZFS dataset compression All datasets on zroot pool are compressed by default since FreeBSD 11.0 [1], no need to mention that on some specific datasets these days. [1] 47206692f2cca020891d1eec5028e02c3e6f56c5 Reviewed by: jrm (mentor), ziaee MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D52304 (cherry picked from commit f304c5bb8be65df83b86f8a50e1c7982b266262d) --- usr.sbin/bsdinstall/bsdinstall.8 | 4 ++-- usr.sbin/bsdinstall/scripts/zfsboot | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/usr.sbin/bsdinstall/bsdinstall.8 b/usr.sbin/bsdinstall/bsdinstall.8 index 181abdcf9d05..5ccbaef87835 100644 --- a/usr.sbin/bsdinstall/bsdinstall.8 +++ b/usr.sbin/bsdinstall/bsdinstall.8 @@ -693,7 +693,7 @@ is: # Home directories separated so they are common to all BEs /home mountpoint=/home -# Compress /tmp, allow exec but not setuid +# Create /tmp and allow exec but not setuid /tmp mountpoint=/tmp,exec=on,setuid=off # Do not mount /usr so that 'base' files go to the BEROOT @@ -702,7 +702,7 @@ is: # Ports tree /usr/ports setuid=off -# Source tree (compressed) +# Source tree /usr/src # Create /var and friends diff --git a/usr.sbin/bsdinstall/scripts/zfsboot b/usr.sbin/bsdinstall/scripts/zfsboot index a3c1e2ddb89f..aa05faa7d3dd 100755 --- a/usr.sbin/bsdinstall/scripts/zfsboot +++ b/usr.sbin/bsdinstall/scripts/zfsboot @@ -152,7 +152,7 @@ f_isset ZFSBOOT_DATASETS || ZFSBOOT_DATASETS=" # Home directories separated so they are common to all BEs /home mountpoint=/home - # Compress /tmp, allow exec but not setuid + # Create /tmp and allow exec but not setuid /tmp mountpoint=/tmp,exec=on,setuid=off # Don't mount /usr so that 'base' files go to the BEROOT @@ -161,7 +161,7 @@ f_isset ZFSBOOT_DATASETS || ZFSBOOT_DATASETS=" # Ports tree /usr/ports setuid=off - # Source tree (compressed) + # Source tree /usr/src # Create /var and friends From nobody Wed Sep 17 20:32:40 2025 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 4cRr6w4wJPz682HX; Wed, 17 Sep 2025 20:32:40 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRr6w4JYGz3D75; Wed, 17 Sep 2025 20:32:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758141160; 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=LzhoueesvvBw2tRLN6AIpsvI3+ptlJBTmog7H7za8BY=; b=w90VJntEaG21zGVeD0SxgXe4OkYO/ljgOVRHVd0mvhchR4TLoTTwvZJSg1BerLrZE9QVRb wFY0iKdGmi2S3pELvIg3YDd/0u2iMff2ApORn3s16RGvfI4MFSl9xEzyefUEUfzHErn3mH RGMYg4XmaadGjTcG+GwXXTqPUmVk234ohZ3pTy5OMD9ZzrBRfXQFrvFWzD44uEj0j+q+Jt lMX6OY+VnbjETHnCmMo+vRg4pILnavthZBNu+VU4sc6VXtfB9UHRQ7KithOK5fRaXV5TTF EQo7CD/bbb38d6gOaIk62fNOcluLybUn7Zp4uI3KaLoavOT0n6+FclPEIpSBuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758141160; 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=LzhoueesvvBw2tRLN6AIpsvI3+ptlJBTmog7H7za8BY=; b=WWmjfhAi8Uke/pEPjjul4ooVkAI0N/xQOynDQAKaXKXgRQLj/3tA0NEqGUDrCzFTSN82t1 1ekcz/pGE0fhOzD9aH+2TAulpFgN3lOrjjCPRKtCb1NtSCE2tGjdkeDNv4o5lpmm/QNu85 izxp+ML6hr9DlC/8lmnHNWDiv9MMoTVR+axDXyjudz85+ZmvtnbMhTfZ9t8rfQOAfxU+wu 2sdTwmiiz4EyxkThyDdMmSKB13YxOqkHpaFY+ZicZiTOXrG008LbXPVhgQp3iKsU53X87E nAiZir/shmN9ED8LZgRSRIxY/1XbUWbRkAGKQYnAbBcXtpQTTDxnCX51dNYEDQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758141160; a=rsa-sha256; cv=none; b=i8Dz4ymblTjh3ZaiwDJCJ82e/NEYeiJVq6oaSTyyC5U94n9iOuJ38YpxCKpoUK7S/5yn11 7sv+myBy7HEGXxCPUlaVlwZ2T018/V+VJ29YvNEou63c7PYLre3BcNTIthXrBLnGrqK0/3 I5yu85G/mL7aWmJdaRhY2SsvyXIJkrcJNl1yYvnBOiZDxOOCkCGagV3jRL9uJv/SZRWKxv nJYpi1BEvmTkgNK3WqndqqdbPZ8SohCLvELBV1LcqPGoGp0ZscpZah9OllwZYFKVuWZzms WWxotTcAdba4O3IMLx3chOYQ/5jjdERQUP/b2yNLi6mykWuyjuiqwldyk8R2Fw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRr6w3vm2zhKf; Wed, 17 Sep 2025 20:32:40 +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 58HKWe5G028139; Wed, 17 Sep 2025 20:32:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HKWecn028136; Wed, 17 Sep 2025 20:32:40 GMT (envelope-from git) Date: Wed, 17 Sep 2025 20:32:40 GMT Message-Id: <202509172032.58HKWecn028136@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Lexi Winter Subject: git: 9b7bddfd082d - main - packages: Add minimal-jail set 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9b7bddfd082d1df2b4c97e7ec974d1d67e98a1de Auto-Submitted: auto-generated The branch main has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=9b7bddfd082d1df2b4c97e7ec974d1d67e98a1de commit 9b7bddfd082d1df2b4c97e7ec974d1d67e98a1de Author: Lexi Winter AuthorDate: 2025-09-17 20:11:20 +0000 Commit: Lexi Winter CommitDate: 2025-09-17 20:11:20 +0000 packages: Add minimal-jail set This is minimal, but without bootloader, hardware and networking support that's typically not required in jails. This requires extending the 'set' annotation to be a comma-separated list, so that packages can be in multiple sets. MFC after: 3 seconds Reviewed by: bapt Differential Revision: https://reviews.freebsd.org/D52591 --- release/packages/create-sets.sh | 10 ++++++---- release/packages/generate-ucl.lua | 31 ++++++++++++++++++------------ release/packages/sets/minimal-jail-dbg.ucl | 6 ++++++ release/packages/sets/minimal-jail.ucl | 6 ++++++ release/packages/ucl/at-all.ucl | 2 +- release/packages/ucl/caroot-all.ucl | 2 +- release/packages/ucl/certctl-all.ucl | 2 +- release/packages/ucl/clibs-all.ucl | 2 +- release/packages/ucl/cron-all.ucl | 2 +- release/packages/ucl/fetch-all.ucl | 2 +- release/packages/ucl/inetd-all.ucl | 2 +- release/packages/ucl/locales-all.ucl | 2 +- release/packages/ucl/newsyslog-all.ucl | 2 +- release/packages/ucl/periodic-all.ucl | 2 +- release/packages/ucl/pkg-bootstrap-all.ucl | 2 +- release/packages/ucl/rc-all.ucl | 2 +- release/packages/ucl/runtime-all.ucl | 2 +- release/packages/ucl/syslogd-all.ucl | 2 +- release/packages/ucl/utilities-all.ucl | 2 +- release/packages/ucl/vi-all.ucl | 2 +- release/packages/ucl/zoneinfo-all.ucl | 2 +- 21 files changed, 54 insertions(+), 33 deletions(-) diff --git a/release/packages/create-sets.sh b/release/packages/create-sets.sh index 6c034834672e..8c564ecfeb92 100755 --- a/release/packages/create-sets.sh +++ b/release/packages/create-sets.sh @@ -25,10 +25,12 @@ for pkg in "$repodir"/*.pkg; do set -- $(pkg query -F "$pkg" '%At %n %Av' | grep '^set ') pkgname="$2" - set="$3" - SETS="$SETS $set" - setvar="$(echo "$set" | tr - _)" - eval PKGS_${setvar}=\"\$PKGS_${setvar} $pkgname\" + sets="$(echo "$3" | tr , ' ')" + for set in $sets; do + SETS="$SETS $set" + setvar="$(echo "$set" | tr - _)" + eval PKGS_${setvar}=\"\$PKGS_${setvar} $pkgname\" + done done for set in $(echo $SETS | tr ' ' '\n' | sort | uniq); do diff --git a/release/packages/generate-ucl.lua b/release/packages/generate-ucl.lua index 211766067952..ea3743894740 100755 --- a/release/packages/generate-ucl.lua +++ b/release/packages/generate-ucl.lua @@ -166,12 +166,14 @@ if add_gen_dep(pkgname, pkggenname) then end -- --- Handle the 'set' annotation. +-- Handle the 'set' annotation, a comma-separated list of sets which this +-- package should be placed in. If it's not specified, the package goes +-- in the default set which is base. -- -- Ensure we have an annotations table to work with. obj["annotations"] = obj["annotations"] or {} -- If no set is provided, use the default set which is "base". -set = obj["annotations"]["set"] or "base" +sets = obj["annotations"]["set"] or "base" -- For subpackages, we may need to rewrite the set name. This is done a little -- differently from the normal pkg suffix processing, because we don't need sets -- to be as a granular as the base packages. @@ -181,27 +183,32 @@ set = obj["annotations"]["set"] or "base" -- However, lib32 debug symbols still go into their own package since they're -- quite large. if pkgname:match("%-dbg%-lib32$") then - set = "lib32-dbg" + sets = "lib32-dbg" elseif pkgname:match("%-lib32$") then - set = "lib32" + sets = "lib32" -- If this is a -dev package, put it in a single set called "devel" which -- contains all development files. Also include lib*-man packages, which -- contain manpages for libraries. Having a separate -dev for every -- set is not necessary, because generally you either want development -- support or you don't. elseif pkgname:match("%-dev$") or pkgname:match("^lib.*%-man$") then - set = "devel" + sets = "devel" -- Don't separate tests and tests-dbg into 2 sets, if the user wants tests -- they should be able to debug failures. -elseif set == "tests" then - set = set --- If this is a -dbg package, it goes in -dbg, which means the user can --- install debug symbols only for the sets they have installed. +elseif sets == "tests" then + sets = sets +-- If this is a -dbg package, put it in the -dbg subpackage of each set, +-- which means the user can install debug symbols only for the sets they +-- have installed. elseif pkgname:match("%-dbg$") then - set = set .. "-dbg" + local newsets = {} + for set in sets:gmatch("[^,]+") do + newsets[#newsets + 1] = set .. "-dbg" + end + sets = table.concat(newsets, ",") end --- Put our new set back into the package. -obj["annotations"]["set"] = set +-- Put our new sets back into the package. +obj["annotations"]["set"] = sets -- If PKG_NAME_PREFIX is provided, rewrite the names of dependency packages. -- We can't do this in UCL since variable substitution doesn't work in array diff --git a/release/packages/sets/minimal-jail-dbg.ucl b/release/packages/sets/minimal-jail-dbg.ucl new file mode 100644 index 000000000000..3f7df227d3a9 --- /dev/null +++ b/release/packages/sets/minimal-jail-dbg.ucl @@ -0,0 +1,6 @@ +comment = "Basic multi-user jail debugging symbols (metapackage)" + +desc = < To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Lexi Winter Subject: git: 9537aa02f404 - main - packages: Mark all sets as vital 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9537aa02f40454ba8243e8c877695876d3e4c150 Auto-Submitted: auto-generated The branch main has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=9537aa02f40454ba8243e8c877695876d3e4c150 commit 9537aa02f40454ba8243e8c877695876d3e4c150 Author: Lexi Winter AuthorDate: 2025-09-17 20:12:21 +0000 Commit: Lexi Winter CommitDate: 2025-09-17 20:14:18 +0000 packages: Mark all sets as vital At least "minimal" must be vital, because it's required for a functional system. For example, we might create new packages in the future which are required for the multi-user system and are part of the minimal set, so it's important that users don't remove set-minimal to ensure they get those new packages. For the other sets, it's debatable whether they should be vital or not, but let's start out with the assumption that if the user installed a set, they should have to have to explicit request it be removed. This means if, for example, they install set-devel, then remove lldb, pkg won't remove set-devel and cause the next "pkg autoremove" to remove everything else that was in set-devel. We might want to adjust this later (or possibly adjust the behaviour of pkg(8) itself) based on user feedback. While here, fix a typo in the description of the devel set. Suggested by: bapt MFC after: 3 seconds Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D52562 --- release/packages/sets/base.ucl | 2 ++ release/packages/sets/devel-dbg.ucl | 2 +- release/packages/sets/devel.ucl | 4 +++- release/packages/sets/lib32.ucl | 2 ++ release/packages/sets/minimal-jail.ucl | 2 ++ release/packages/sets/minimal.ucl | 2 ++ release/packages/sets/src.ucl | 2 ++ release/packages/sets/tests.ucl | 2 ++ 8 files changed, 16 insertions(+), 2 deletions(-) diff --git a/release/packages/sets/base.ucl b/release/packages/sets/base.ucl index 42dd2095f808..2d94ff4f4f2e 100644 --- a/release/packages/sets/base.ucl +++ b/release/packages/sets/base.ucl @@ -1,5 +1,7 @@ comment = "Base system (metapackage)" +vital = true + desc = < To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Lexi Winter Subject: git: a2783fb75401 - main - packages: Move kernel-man to the minimal set 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a2783fb75401c85f5ae815a1349fbad8e7ab7b3c Auto-Submitted: auto-generated The branch main has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=a2783fb75401c85f5ae815a1349fbad8e7ab7b3c commit a2783fb75401c85f5ae815a1349fbad8e7ab7b3c Author: Lexi Winter AuthorDate: 2025-09-17 20:13:04 +0000 Commit: Lexi Winter CommitDate: 2025-09-17 20:14:18 +0000 packages: Move kernel-man to the minimal set Currently this is in the "kernels" set, which doesn't make sense because it's not a kernel. Move it to the "minimal" set, on the basis that minimal already includes a bunch of manpages, and a user who installs with minimal expects that e.g. "man ix" will work. MFC after: 3 seconds Reported by: des Reviewed by: bapt Differential Revision: https://reviews.freebsd.org/D52560 --- release/packages/ucl/kernel-man.ucl | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/release/packages/ucl/kernel-man.ucl b/release/packages/ucl/kernel-man.ucl index 9d70baf2c3af..e4c376379fe3 100644 --- a/release/packages/ucl/kernel-man.ucl +++ b/release/packages/ucl/kernel-man.ucl @@ -1,5 +1,10 @@ comment = "Kernel manual pages" + desc = <; Wed, 17 Sep 2025 20:38:04 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg1-x52c.google.com (mail-pg1-x52c.google.com [IPv6:2607:f8b0:4864:20::52c]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRrF75WMXz3FSw for ; Wed, 17 Sep 2025 20:38:03 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pg1-x52c.google.com with SMTP id 41be03b00d2f7-b4f7053cc38so157162a12.2 for ; Wed, 17 Sep 2025 13:38:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1758141481; x=1758746281; darn=freebsd.org; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=f3TOhOmbVcoqy8ppro6HcNbPTeB0T20UkHF+7tFnYuk=; b=jubKNfsmpD7xFIlvNlGybZ50oVT1RdqpzdyCSzbnhoTuJnDKWyuSJj/Yf8m0NSk+Kx 3eNltReqm/k0FRckA7W/arOqyD9Xgh4aQ62gZlauG5AMhOFpHJ2YFFBpaCkklBjPK3n3 oCkpgkmC5e6KiiSsBYxDcCfHMPgtfwnSy4TC7UvNA8nqRZE3Tn3trwC6MhUvn4J4gf2e 8DYQ1aeeseAZdBWHIkIAbMiEeunjYKU4AYSviX7NMfRN1DeyKDXYmvn/s2driU9FT0Wc B8AFojWXaXV2F2uoOBEw3uuW99DGjJLb12iBCqRhqogzOfr0Uqipk2MgoYmNmeQF5CRl m4uA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1758141481; x=1758746281; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=f3TOhOmbVcoqy8ppro6HcNbPTeB0T20UkHF+7tFnYuk=; b=ThsDMrtx9BIr4qbDUKMGZSEcGtjS9hRFxLFv7I9XHR6H1KucIGAmfJ21mhqcU/Fey6 2e6bMAdIk+hHX7NL9iPxVExYVqiPabmY4FyXlQen8EyjQ6d84DcD4ZRpvFOdTPSVucM2 GN5ylnFuycSK9SihNet/fWsELBTV45u01i/iBCkSMexaQglkLOSqVoVvQq8O+CVUWZJe wOfQXo8WNeGvfno86nqisYyAc6B1epub1lzzQNJ9WLDn3t1tkNyskz7ScoW4ZIMFPjib jCSo/cMXTvWh6YsJ3yTTpVyokxs7yUwae00XQ2NyJWWhkuCbKYk+WlxIC6zdvwp5TWbc FEvA== X-Forwarded-Encrypted: i=1; AJvYcCVE1VZIE6uyPCck4Wyi71NpilLPfMg/S6f9MxJTSmu2ze5cU8GKjgct4mLbFwa0QpEGRPjqzWtkR/HQMzD7Wsxk9j8q@freebsd.org X-Gm-Message-State: AOJu0YzJS+3rjN5VWxsmsIajlZVMDVmxFo3NTsRZyzMLnWUxBm2C0/4o shtiFB3+Wryyf9iGaCJMBo61nGNLGuRwpwSmGFen1iSltrHLQ5DehIno X-Gm-Gg: ASbGnctIan/9Y36eVcANNre5/TZX3qAfOYetaxA4Y9QovQd2UUFiw6onLJfm9C7nBPs 9UPFcpRc6zwMW2uV0uTS0qio5DlHP3vWSY1GTvB2er4be0UnEvWKA8JG89iK90bygn1xFFG5eoC Q1hpTyq94ssSuI9fpbpBqXUkDsJG3owYbz+l25IbqovKAft7tvTf+bAPg0r92NM6jPuVdhpWosW VRmcTy3vClxmG7PsiEDMmUWSBFc/l9QVsza4MAgnLH3aexunB6VMzg+mpjdomWiMYM9x3YZr7tU amj7CNP8Lr7XQbXyN12AVHUnL0RqpijLvMaXLLmRJLeLm7J7cnaLp33b7Awp1PegvBkbw0lVPkO 67lwTfevnfC7poEzHnpQ0a6w/nF0laprfoDS4AtstS70= X-Google-Smtp-Source: AGHT+IGphT5Hnxeek6gqMcmhhnnK7Mo1hpr41aUkrKZknFZfY5MJDj6zs0Vc3LPfF8IVyjWxGuvj6g== X-Received: by 2002:a17:902:ef0f:b0:24c:965a:f97e with SMTP id d9443c01a7336-26811ba541dmr49779705ad.2.1758141480999; Wed, 17 Sep 2025 13:38:00 -0700 (PDT) Received: from smtpclient.apple ([185.153.179.181]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-269802df74asm4276415ad.94.2025.09.17.13.38.00 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 17 Sep 2025 13:38:00 -0700 (PDT) Content-Type: text/plain; charset=utf-8 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 (Mac OS X Mail 16.0 \(3826.700.81\)) Subject: Re: git: 9537aa02f404 - main - packages: Mark all sets as vital From: "Enji Cooper (yaneurabeya)" In-Reply-To: <202509172032.58HKWfxp028171@gitrepo.freebsd.org> Date: Wed, 17 Sep 2025 13:37:49 -0700 Cc: "src-committers@freebsd.org" , "dev-commits-src-all@freebsd.org" , "dev-commits-src-main@freebsd.org" Content-Transfer-Encoding: quoted-printable Message-Id: References: <202509172032.58HKWfxp028171@gitrepo.freebsd.org> To: Lexi Winter X-Mailer: Apple Mail (2.3826.700.81) X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4cRrF75WMXz3FSw > On Sep 17, 2025, at 1:32=E2=80=AFPM, Lexi Winter = wrote: >=20 > The branch main has been updated by ivy: >=20 > URL: = https://cgit.FreeBSD.org/src/commit/?id=3D9537aa02f40454ba8243e8c877695876= d3e4c150 >=20 > commit 9537aa02f40454ba8243e8c877695876d3e4c150 > Author: Lexi Winter > AuthorDate: 2025-09-17 20:12:21 +0000 > Commit: Lexi Winter > CommitDate: 2025-09-17 20:14:18 +0000 =E2=80=A6 > diff --git a/release/packages/sets/src.ucl = b/release/packages/sets/src.ucl > index eada5dbde641..7ab94eb420df 100644 > --- a/release/packages/sets/src.ucl > +++ b/release/packages/sets/src.ucl > @@ -1,5 +1,7 @@ > comment =3D "System source code" >=20 > +vital =3D yes > + > desc =3D < This metapackage installs source code for the base system and kernel. > EOD > diff --git a/release/packages/sets/tests.ucl = b/release/packages/sets/tests.ucl > index 88426a54a807..07b463fb7d69 100644 > --- a/release/packages/sets/tests.ucl > +++ b/release/packages/sets/tests.ucl > @@ -1,5 +1,7 @@ > comment =3D "System test suite" >=20 > +vital =3D yes > + > desc =3D < This metapackage installs the system test suite. > EOD Hi Lexi! I actually wouldn=E2=80=99t consider `src` or `tests` to be = vital (many users don=E2=80=99t install them on their systems). Is there = a reason why they should be considered vital that I=E2=80=99m not aware = of? I=E2=80=99ve not been paying a ton of attention to work being done = in the pkg-base space, so I might have missed some important points. Thank you! -Enji= From nobody Wed Sep 17 20:48:27 2025 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 4cRrTG3mCCz683Hj; Wed, 17 Sep 2025 20:48:34 +0000 (UTC) (envelope-from ivy@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRrTG3Czdz3GSH; Wed, 17 Sep 2025 20:48:34 +0000 (UTC) (envelope-from ivy@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758142114; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=tOYLYKZ0YqbAW9ep2bkVWe52EKPXTcNeL9ttiYcWE5k=; b=IJOmrluocJ26CsxIVmZlMCP8DxJQuYTGjta/xmcj8AMdWcOx2RCKHVn1Gh8dpoxm4tOq3f gRKv2hTb6Nf5K1Y8/earPruTxYjkpOH/WCZ1R6Swza1JoC/utpaa0FFbbHJzYlq93jnwD0 FFC6zl52QvVyYYXZhHGo2FMw5sVnuM9PrSkb82cNzVdK2kLZq3IuE8IeaspWdOd3Y3sMvH bFXVku6vlJAgYcpdFa80Acg79PlNEJ7mPrxZh9TCzuYp5A13x8xR6BuNCrUdzAEoBr6zZz wERKIMvUbaLmAQbm5uI55DsHZPaD08DABIQCTYFPMVyK6T27eYXymLgjO+vIPg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758142114; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=tOYLYKZ0YqbAW9ep2bkVWe52EKPXTcNeL9ttiYcWE5k=; b=ZDcjvp5aqDwu/TaAuyYpd+oLNtQkWViLGGzCXAkqusS0tzG2F9KzNwv2/6RjFcR7ROoMBm 1XLNxSU38Fk/X8zJSd+Vukmbb4uoxW/y1RkfwJusDhIYRO3CoRxntJl82DnAj+rJDEo4Zh vmeYDoEIYf00jMMB+wUV+l3LwTU0GXocwBR48NW2q1GeWUfLXsaBb4ll5fXNav2Y14JvQC VhWTxFhVMhngBf4527qzervGXX87Xm9jrURYY4pAVjq8yQCRc7vIRrki3iEFpUHqUp737c /RIGR0ggjebD4MxSvPpYVRkTDAVUs8MpU5fCyu5VQE3PiWYGiasUeF9gM6eDZA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758142114; a=rsa-sha256; cv=none; b=AsjjItvhXQhiYIkGbDRMMEec3bpuKTvFYZdXufy08GFsXJD1wpfD7tv7pFAFT1Veps2kLC WgqUqmJTXGQFKLzyW0UkBmmfHKrJ5C2m6DjaPV8clro9j5DJgPmtZDJDKpNzzKr4W8wPS5 FID3KD4ZdHlNCiuTHAC12I8jXtZjWQuN6vDOBvtXZfD8qQJN+9xlTjGOGyPMH1kuIA5WWJ QeCLCW1UVm0TTTkvfg8LxTQ79qgFGfUtoB5478AwBOLKhie4nQ7CPqHZyWJwOlKwUw/bcb Cy1mY7LBFzwmu01Zm9B9Htx5S1hpfhaozRccuveRJVwjhRJr8tOb1IDc0r7RZw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from amaryllis.le-fay.org (amaryllis.le-fay.org [IPv6:2a00:1098:6b:400::9]) (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) (Authenticated sender: ivy/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cRrTF6KCSz4yl; Wed, 17 Sep 2025 20:48:33 +0000 (UTC) (envelope-from ivy@freebsd.org) Date: Wed, 17 Sep 2025 21:48:27 +0100 From: Lexi Winter To: "Enji Cooper (yaneurabeya)" Cc: "src-committers@freebsd.org" , "dev-commits-src-all@freebsd.org" , "dev-commits-src-main@freebsd.org" Subject: Re: git: 9537aa02f404 - main - packages: Mark all sets as vital Message-ID: Mail-Followup-To: "Enji Cooper (yaneurabeya)" , "src-committers@freebsd.org" , "dev-commits-src-all@freebsd.org" , "dev-commits-src-main@freebsd.org" References: <202509172032.58HKWfxp028171@gitrepo.freebsd.org> 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: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="Bc92YJQSj8SFyY8D" Content-Disposition: inline In-Reply-To: --Bc92YJQSj8SFyY8D Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Enji Cooper (yaneurabeya) wrote in : > On Sep 17, 2025, at 1:32=E2=80=AFPM, Lexi Winter wrote: > > packages: Mark all sets as vital > > I actually wouldn=E2=80=99t consider `src` or `tests` to be vital (many > users don=E2=80=99t install them on their systems). Is there a reason > why they should be considered vital that I=E2=80=99m not aware of? I=E2= =80=99ve > not been paying a ton of attention to work being done in the > pkg-base space, so I might have missed some important points. "vital" doesn't mean they have to be installed, it only means that once they are installed, they can only be removed explicitly (using -f): # pkg remove freebsd-set-tests Checking integrity... done (0 conflicting) The following package(s) are locked or vital and may not be removed: FreeBSD-set-tests originally i only marked "minimal" and "base" as vital, but based on review feedback, we decided to mark all the sets as vital for now. the reason is to avoid something like this: # pkg install freebsd-set-devel # pkg remove freebsd-lldb # this also removes freebsd-set-devel ... 6 months later ... # pkg autoremove (now all the other packages installed by freebsd-set-devel are also removed.) marking the sets as vital means that users have to explicitly opt-in to removing the set if they remove a dependency of the set, which avoids this exciting behaviour. there is a pkg(8) issue that means this doesn't work quite as well as it should do: https://github.com/freebsd/pkg/issues/2517, however, i still feel this is better than the alternative. --Bc92YJQSj8SFyY8D Content-Type: application/pgp-signature; name=signature.asc -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQSyjTg96lp3RifySyn1nT63mIK/YAUCaMselwAKCRD1nT63mIK/ YPdJAQDBRdXunLGF/S7gdBiV/XNSnobevl4Hqp1Y1R6JobVu5AD/YJjPm59sgEka trIC2qtMmNcI21Azdg4Ohz4+EYRIJwU= =3Lrd -----END PGP SIGNATURE----- --Bc92YJQSj8SFyY8D-- From nobody Wed Sep 17 20:50:14 2025 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 4cRrX90mSCz683CH; Wed, 17 Sep 2025 20:51:05 +0000 (UTC) (envelope-from madpilot@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRrX86ML9z3GvJ; Wed, 17 Sep 2025 20:51:04 +0000 (UTC) (envelope-from madpilot@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758142264; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:autocrypt:autocrypt; bh=mzSjqgZvSE4IVLkDWFRFow24GrEJ4LTdNvEVt+KJriY=; b=WTDy8pq2RtMYX2KeLUFM+kWCSah8wloV9N+ntH/jhJWGRX2wflGOo/zobqXImHX8l8tmje KWR5hIv/eIRDat3Lkchd/hyCoJeznlajVaPfXBLU9B3bfBXU/O933AoBKlGSt1FpqQ/vsQ JVCqqcUQIH2zBsPp2eQT+R0HubxVvNFZNc4IfC8x8lu9/zbOzVJeHpcSFiqK8/QzzhWIIa pSQvf9xfRjuHKiHltFLkcDbqh/oEcP89pByBp1Ah+rfxtZZ+/clUQq929iUuOm6X/SDyt5 nUiHd+Ib4lXsjDDRnepjdob7e9HvS6l7jzOQyTGNo8EfKy6Tv9/eQ8Y1qFRQWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758142264; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:autocrypt:autocrypt; bh=mzSjqgZvSE4IVLkDWFRFow24GrEJ4LTdNvEVt+KJriY=; b=CrqNcuJNeCR8hG1V2E5aqSIARHd2YJqj2IQxxelVVtppQWaRBhaVrXGp3pGy3H0qKbyb9t Aq1WuAd1tC2LW8k/f+rDNytTanKUK3Av0q2PWSJiVGqwyotMdBsaEoUSlBmnQmUES5C7a/ ZCwR109vd4XNX3d2MyZAuxbua2ULsKcnCKgX0hdqwUY182n76p0COK6VrIX3XZj6/PadIw awV4tgXDlMukoloaGAOACf7Sn3ahee19ynoxJ0DP3HaAyrgd4L/6/9g0pPar0erlR1m+AO gnW4PeSdYpKMcAV2sUJuRkyBpxmxJC2i9LbhmhNl6XvDUExCUHMtjpq+hKvIng== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758142264; a=rsa-sha256; cv=none; b=J01uFo63iGkHAhUZGC6UXrFdJbmfn3VUa61yv6QG91nTdkwuv/QfpWZBSd0FA/sqyZxnN/ lbThDHeVMar/O58fX7S2WNxZoOg08PeTbitPClHWcjI9So8MDlYxfPAv5CQLa3b7eN+aZv I18bP12FjS6TLO8waHzkuk53S2vjdhB0i2RGW8ncVPOuG0cxBzb409l2SOpRNs1N5YU0Eo to31Eb5/E7+f79nQGBmBBiY7VxHreTvF7GffNIReCQ+OCAR6/qxTxoUKfQc+7NNyIN0/cd wWzIDZrQraDgq5Vtd3grES3qV6pB86DwEFeQ6NZvMAbwjwRRfx7uPPd+dbgGsA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from [IPV6:2a01:e11:2002:4280:ab9b:8bf1:ec36:413a] (unknown [IPv6:2a01:e11:2002:4280:ab9b:8bf1:ec36:413a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: madpilot/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cRrX80tQJz6Nd; Wed, 17 Sep 2025 20:51:04 +0000 (UTC) (envelope-from madpilot@FreeBSD.org) Message-ID: <47a0213b-010e-47e4-8285-dcf426f59c08@FreeBSD.org> Date: Wed, 17 Sep 2025 22:50:14 +0200 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 User-Agent: Mozilla Thunderbird Subject: Re: git: e779891327b1 - main - sys/power: Sleep type reporting by PM backends To: Nuno Teixeira , Cy Schubert Cc: Aymeric Wibo , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org References: <202509142159.58ELx5Rg054606@gitrepo.freebsd.org> <20250916050239.4BB672D5@slippy.cwsent.com> Content-Language: en-US From: Guido Falsi Autocrypt: addr=madpilot@FreeBSD.org; keydata= xsBNBE+G+l0BCADi/WBQ0aRJfnE7LBPsM0G3m/m3Yx7OPu4iYFvS84xawmRHtCNjWIntsxuX fptkmEo3Rsw816WUrek8dxoUAYdHd+EcpBcnnDzfDH5LW/TZ4gbrFezrHPdRp7wdxi23GN80 qPwHEwXuF0X4Wy5V0OO8B6VT/nA0ADYnBDhXS52HGIJ/GCUjgqJn+phDTdCFLvrSFdmgx4Wl c0W5Z1p5cmDF9l8L/hc959AeyNf7I9dXnjekGM9gVv7UDUYzCifR3U8T0fnfdMmS8NeI9NC+ wuREpRO4lKOkTnj9TtQJRiptlhcHQiAlG1cFqs7EQo57Tqq6cxD1FycZJLuC32bGbgalABEB AAHNIkd1aWRvIEZhbHNpIDxtYWRwaWxvdEBGcmVlQlNELm9yZz7CwHgEEwECACIFAk+G+3MC GwMGCwkIBwMCBhUIAgkKCwQWAgMBAh4BAheAAAoJEBrmhg5Wy9KT2uIIAIrawQ89TnqEhi2C OEQAhx3uqWZuNoS6NyiSgsRCmtSnT2GOgH4Ucbr/I37SkV1B3K6HkoL6lwN8Gjf5KOgLqmTi E1W3RTwS7l8PSvdnjM9i7g351R4mTijtxawB/JcQf/Kge3Yqr1V4g6H+wQXHUStmHThbupuN trzRphvR/e5ekT0FTyVfPmpcbm68i2bwZnKUex/TNIECBykYh8b+SYMLhENf2ayRjCIWS2Ad 7tnTKhMtnS5jtW6qjBy4RoTpQD6oR1xIgkTRlQ49roVCUfdHb+Y/kh+U9G1IcoNy4vkg9IfP dwpSfnP+a8j0AZ1hMnOLZ1fYoQrs+4gVLy8Fs7TOwU0EUxB7QQEQAKFhrDceoPdK/IHDSmoj 6SQYisvM7VdhcleS7E9DoEAVt7yMbf6HbbMVTTY6ckvwTWQssywLBXNVqxgc4WLJjzfUhgef +WE75M3+WFYlOVQLGZY/zEVgma1raYnOHNAOzeHLDmEXjbZP6vGAeDyBbGfQPpE7qGYZ7ube T3XwQO+PklcCrvOPj2ZPcAxGNS2xVU/LzONqCrJqLMJSIcCdsbiSP4G5PnDFHtMokaTY6OEr 8OEQfOAerhcHUa/z7Uu8YtmaqKH+QGkE/WEgaRqSiTnv0JOTD+DxehaqvoKPPZ++2NpCZMHB 2i6A/xifmQwEiIjEXtcueBRzkNUQkxhqZyS13SrhocL9ydtaVPBzZatAEjUDDEJmAMLVFs45 qfyhMiNapHJo2n3MW/E5omqCvEkDdWX/en3P7CK2TemeaDghMsgkNKax/z0wNo5UZCkOPOz0 xpNiUilOVbkuezZZNg65741qee2lfXhQIaZ66yT7hphc/N/z3PIAtLeze4u1VR2EXAuZ2sWA dlKCNTlJMsaU/x70BV11Wd/ypnVzM68dfdQIIAj1iMFAD/lXGlEUmKXg5Ov2VQDlTntQoanC YrAg+8CttPzjrydgLZFq3hrtQmfc0se5yv1WHS69+BsUOG09RvvawUDZxUjW19kyeN9THaNR gow3kSuArUp6zSmJABEBAAHCwF8EGAEIAAkFAlMQe0ECGwwACgkQGuaGDlbL0pMN5wgA4bCk X/qwEVC06ToeR6C2putmSWQMgpDaqrv65Hubo+QGmg2P4ewTYQQ4g6oYWS03qHxqVVWhKz7F jfrV+dH8qbCLfSgIcvdBha7ayGZVrsiuMLKGbw36fcmkZPpSDOfHcP0XH8Z+u9CWj0xUkTxA lZ/7i6gYSUpG2JWNtdmE/X8VVEyXusCLwy0K0BI60A/4dRTIX3C4QKrJ3ZbUXegz70ynjHf+ lQMZ9IZKASoRMuS5FozPQh6abvmwZEPdf5I9riUElzvHrqJ8Bx0t3Pujdoth+yNHpnBxrtO8 LkQdrQ58P0SwcaIX33T2U9pG8bhu5YVR88FQ8OQ0cEsPBpDncg== In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 9/17/25 11:15, Nuno Teixeira wrote: > > Hello Cy, > > One of this series of ACPI commits has broken power management on my > machines. > One of which managed to capture a dump from a kernel panic after > poweroff(8) > was issued. > > > I can confirm same crash on reboot on a Intel laptop, after upgrading > from main 2025-09-06 -> 2025-09-16. > Hi, A me too. Just noticed this while investigating why my machines with head (laptop and two desktops) were not switching off anymore. So looks like I'm also experiencing this. All machines behave the same, the almost turns off, monitor turns off, but power light stays on. I'm testing reverting commits to see if it goes back to working. -- Guido Falsi From nobody Wed Sep 17 21:17:25 2025 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 4cRs6Z1Vnnz6851X; Wed, 17 Sep 2025 21:17:26 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRs6Z0pg2z3MsF; Wed, 17 Sep 2025 21:17:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758143846; 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=DiFHSSBspET7u/Ut+346bRI9iKorAS5nU/1lFFFPqDM=; b=f7EkhORbL83eIuPrKZo/xGtbodiWHywO0PpZvANA+M7kktCbkIF6H33u1SxrPODi5l8AcA szMbq+CdnpyysnRJJVgMxFX7j91M2mvWc2NaY/W9xOhx0TsRSNIloxtvRzdhuhFANtIWA1 sTYOfCkEkjYrIV8DdkYBrrDbfYPr22sDWpwnakhs6LEsjMtAx5ucUns71orCNS6lwUCpMa ovRsGZ57UAOYKoXtFj7MNPrhtyGtDR8f1oO2hpIk9LLdUrRa2x7qSlt+zGJvVR/mDPQtcy CZMK7vAOaa3GyR1hhjbvyoKMOw7h4wRzVwqZqrQ2nKR/X4NTgd8AHRmhy8Zo3g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758143846; 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=DiFHSSBspET7u/Ut+346bRI9iKorAS5nU/1lFFFPqDM=; b=rWM1IF2xn66ZqXi/FofF2Z+QfOMoTyX1OxxRuIF1luTDkYRznxYJkqVpt18ohr7LMujEMb +L7krG1lVoUfUhg6fbNNlcIjM4rxwtvZWpDwWuX2EvEDxJCdgbG6Nr8sNR169pqBArxn+C thMeq2vw6FHaPK0sEEAd/nZWWMOsAzSknlTb64PgaYHBLwsi/57E+RMjovAjK9wgaqjJ/F NYIWYfNvG+8yH7K4BLxt0MCn1lYaaz1AQaYeQOr6NEYzOHhfudp0azr8VPrInBoijlGFue 7sC4Vbv0hh06iDIfDi7ZxPZMWogaZTTgva1buPROfdirPOS9yt5d+wDcFkoy7g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758143846; a=rsa-sha256; cv=none; b=J+VPyv/p06e2CcrtNrtZms1yo40xb17DwJX7p0CpGqTYqSneEdPm/nVJCiEzxn1kA0CMPA 40XYuuh2DxkDXaWk9GZZxLaVBGD0B0ELbYnMSOLbF49QMRiLTDAwEmszdg5XRtQWa6Hi1Z 3aKYMDuHwJTiEqBl6dec9nf+P48cegkbR0yCTVKQg17eXonnqAo4mMLivoEZZxoZAVYPUF devTXUkiq+ti+u+tXXRVDFjDInb9vsoZchR9eSbbDWYPH/bve33XZBmGoXacCOENP35Um7 CfNfdCabaAX0wLDT7bD8rgaJ3QkplKEA67pPjXShgOODA76WdF9yR9MaVQVegA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRs6Z04DPzk7L; Wed, 17 Sep 2025 21:17:26 +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 58HLHPrK005347; Wed, 17 Sep 2025 21:17:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HLHPHP005344; Wed, 17 Sep 2025 21:17:25 GMT (envelope-from git) Date: Wed, 17 Sep 2025 21:17:25 GMT Message-Id: <202509172117.58HLHPHP005344@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dave Cottlehuber Subject: git: 728ec0c094ce - main - release: Add images for almost all packages, with & without toolchain 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: dch X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 728ec0c094ce473ae17ebd1adb05f0959bf3a68e Auto-Submitted: auto-generated The branch main has been updated by dch: URL: https://cgit.FreeBSD.org/src/commit/?id=728ec0c094ce473ae17ebd1adb05f0959bf3a68e commit 728ec0c094ce473ae17ebd1adb05f0959bf3a68e Author: Dave Cottlehuber AuthorDate: 2025-09-17 21:16:37 +0000 Commit: Dave Cottlehuber CommitDate: 2025-09-17 21:16:37 +0000 release: Add images for almost all packages, with & without toolchain Contains almost everything of use in a container except: - *lib32 - *dev - *dbg - *src - anything expecting hardware such as device config tools Differential Revision: https://reviews.freebsd.org/D51471 Reviewed by: dfr, emaste Approved by: cperciva MFC after: 1 day Sponsored by: SkunkWerks, GmbH --- release/Makefile.oci | 8 ++-- release/scripts/make-oci-image.sh | 2 +- release/tools/oci-image-notoolchain.conf | 68 ++++++++++++++++++++++++++++++++ release/tools/oci-image-toolchain.conf | 16 ++++++++ 4 files changed, 90 insertions(+), 4 deletions(-) diff --git a/release/Makefile.oci b/release/Makefile.oci index a6f998002f92..16c475937d15 100644 --- a/release/Makefile.oci +++ b/release/Makefile.oci @@ -3,7 +3,7 @@ # .if defined(WITH_OCIIMAGES) && !empty(WITH_OCIIMAGES) -OCI_IMAGES= static dynamic runtime +OCI_IMAGES= static dynamic runtime notoolchain toolchain .endif oci-install: @@ -16,8 +16,10 @@ oci-install: OCI_TARGETS= OCI_DEPS_static= -OCI_DEPS_dynamic= container-image-static.txz -OCI_DEPS_runtime= container-image-dynamic.txz +OCI_DEPS_dynamic=container-image-static.txz +OCI_DEPS_runtime=container-image-dynamic.txz +OCI_DEPS_notoolchain=container-image-runtime.txz +OCI_DEPS_toolchain=container-image-notoolchain.txz .for _IMG in ${OCI_IMAGES} OCI_TARGETS+= container-image-${_IMG}.txz diff --git a/release/scripts/make-oci-image.sh b/release/scripts/make-oci-image.sh index 8a620e9d8973..6e5ad69741f7 100644 --- a/release/scripts/make-oci-image.sh +++ b/release/scripts/make-oci-image.sh @@ -47,7 +47,7 @@ install_packages() { # metadata for what was installed). This trims more than 40Mb from the # resulting image. env IGNORE_OSVERSION=yes ABI=${abi} pkg --rootdir ${rootdir} --repo-conf-dir ${workdir}/repos \ - install -yq "$@" || exit $? + install -yq -g "$@" || exit $? rm -rf ${rootdir}/var/db/pkg/repos } diff --git a/release/tools/oci-image-notoolchain.conf b/release/tools/oci-image-notoolchain.conf new file mode 100644 index 000000000000..e251281a7357 --- /dev/null +++ b/release/tools/oci-image-notoolchain.conf @@ -0,0 +1,68 @@ +#! /bin/sh + +# Build OCI container image with almost all packages suitable for jails, excluding compiler + +OCI_BASE_IMAGE=runtime + +oci_image_build() { + set_cmd ${workdir} /bin/sh + install_packages ${abi} ${workdir} \ + FreeBSD-acct \ + FreeBSD-at \ + FreeBSD-audit \ + FreeBSD-autofs \ + FreeBSD-blocklist \ + FreeBSD-bsnmp \ + FreeBSD-caroot \ + FreeBSD-certctl \ + FreeBSD-clibs \ + FreeBSD-console-tools \ + FreeBSD-cron \ + FreeBSD-csh \ + FreeBSD-dma \ + FreeBSD-ee \ + FreeBSD-fd \ + FreeBSD-fetch \ + FreeBSD-ftp \ + FreeBSD-ftpd \ + FreeBSD-inetd \ + FreeBSD-ipf \ + FreeBSD-ipfw \ + FreeBSD-iscsi \ + FreeBSD-jail \ + FreeBSD-kerberos \ + FreeBSD-kerberos-lib \ + FreeBSD-libarchive \ + FreeBSD-libcompiler_rt-dev \ + FreeBSD-libexecinfo \ + FreeBSD-libucl \ + FreeBSD-locales \ + FreeBSD-lp \ + FreeBSD-mtree \ + FreeBSD-natd \ + FreeBSD-netmap \ + FreeBSD-newsyslog \ + FreeBSD-nfs \ + FreeBSD-nuageinit \ + FreeBSD-openssl \ + FreeBSD-periodic \ + FreeBSD-pf \ + FreeBSD-pkg-bootstrap \ + FreeBSD-quotacheck \ + FreeBSD-rc \ + FreeBSD-rcmds \ + FreeBSD-rescue \ + FreeBSD-resolvconf \ + FreeBSD-runtime \ + FreeBSD-ssh \ + FreeBSD-syslogd \ + FreeBSD-tcpd \ + FreeBSD-telnet \ + FreeBSD-ufs \ + FreeBSD-unbound \ + FreeBSD-utilities \ + FreeBSD-vi \ + FreeBSD-yp \ + FreeBSD-zfs \ + FreeBSD-zoneinfo +} diff --git a/release/tools/oci-image-toolchain.conf b/release/tools/oci-image-toolchain.conf new file mode 100644 index 000000000000..b3b7eed8e8d1 --- /dev/null +++ b/release/tools/oci-image-toolchain.conf @@ -0,0 +1,16 @@ +#! /bin/sh + +# Build Open Container Initiative (OCI) container image with almost all of FreeBSD base.txz + +OCI_BASE_IMAGE=notoolchain + +oci_image_build() { + set_cmd ${workdir} /bin/sh + install_packages ${abi} ${workdir} \ + FreeBSD-clang \ + FreeBSD-ctf-tools \ + FreeBSD-lld \ + FreeBSD-lldb \ + FreeBSD-toolchain \ + FreeBSD-*-dev +} From nobody Wed Sep 17 21:38:05 2025 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 4cRsZP4mQQz686x9; Wed, 17 Sep 2025 21:38:05 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRsZP4Fjrz3Rw1; Wed, 17 Sep 2025 21:38:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758145085; 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=Lxwp+/Qd375hf3RQCIiyE/dSzR9UBnGX4fHz8gGhGw4=; b=xSUcfgRu0zO7T3OVBPifoAK3ElEVVWvbLGAiKn+dIka9joeg5RZWzqr9ZNT5yiI2qAlNKQ PV+o3fqQppVMRSOE2HIiTaiLfUrWje0S0R02JNqBH4hCpKae/+rLDNtKms5WUcvZ/A56sp t2ccpKwf3f8tjrWOcJz8/7baFc8gXu/VHlyMINpy9dylCzsAlz6v9hws6ao2eKvvHU8jZo QeVEB1HnfZoUFsRx+OL+tIJoGdu5b6zFG63FBpQ6HW/RFKhYsmIZlpWOdcDpz3g+qdMsmT 3YvguDVmXS+qRceQvoXiekas2ZJEWPsm78jkNE75xh3FQcshlurVluVy/KJNdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758145085; 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=Lxwp+/Qd375hf3RQCIiyE/dSzR9UBnGX4fHz8gGhGw4=; b=sI2n3DeMAbmMt8h8HQZnBO+IUTvOcxRREH02iFgVkyVxMLoA7cQ0PLTKh/+LtvKiKcGsi9 Sx3toukRsdLuzdhrDnsCaCnnmoILlf5X1NXeEVY8H+m3SgVe32r1qDSuUY0zLC8K/y7v+1 lVqbJ+pOmNK7itlMEEIiZxx4w6ixgnf8n8OsOPUzsWlHV7bBS5t3eaJnd2Bbtubdem+Stq sg1OJkz8/RowHIj1PVqROwQLb/v8SMbD4J9pONXw8oDix8SjJZb9TgpJhWFIC61MoUcie8 ZRSwMekJsYIFB8Klz3z5TNi9/q69tcUgxM7YM4qqxPtQB4IVU+SOJDIaV46ZXg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758145085; a=rsa-sha256; cv=none; b=bF3CC0guclaw/nnc7T5ngGGR/0HljJkGij+WzDE7QzaAazsEw9TVhp5Lmqvv7D5/8x3+0y g/0+Q/MGMARqsvnGuQOv8/LGyULX2lTxDQSP6n5SF1lGT2LFOXQjedCFKmQGLgpd5DkWeh T6BExPDBnZU/3cSFG0wBuQUMZk4varqbK6uSML2Bcb1+nVaDyeziLxSqgHkkRDQ9/V+cXx Z06YKP5RZYBDmGRm+9W/yNqNPTxGMqphvPcNmA5qC4swRbQje9LeOXJ3447f1PSPFuR2JS OyJabucxMmHlJ3ikCLTJ870MaKs5Dkj851xM2hM0Wrzac4lY8O4Z551FjBlRBg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRsZP3YhTzk6W; Wed, 17 Sep 2025 21:38:05 +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 58HLc5Bv042811; Wed, 17 Sep 2025 21:38:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HLc5VS042808; Wed, 17 Sep 2025 21:38:05 GMT (envelope-from git) Date: Wed, 17 Sep 2025 21:38:05 GMT Message-Id: <202509172138.58HLc5VS042808@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bryan Drewery Subject: git: cddb9806b50b - main - syslogd: Make some code more clear. 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: bdrewery X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: cddb9806b50b49722140d7b30c09643376feeaed Auto-Submitted: auto-generated The branch main has been updated by bdrewery: URL: https://cgit.FreeBSD.org/src/commit/?id=cddb9806b50b49722140d7b30c09643376feeaed commit cddb9806b50b49722140d7b30c09643376feeaed Author: Bryan Drewery AuthorDate: 2025-09-17 21:23:19 +0000 Commit: Bryan Drewery CommitDate: 2025-09-17 21:28:18 +0000 syslogd: Make some code more clear. This moves some math to where it logically makes more sense for skipping over the ": " separator in the message formatted "app[PID]: MSG". No functional change. Fixes: 18bcf5a0 ("Restore local kernel "prog" filtering") Sponsored by: Dell Inc. --- usr.sbin/syslogd/syslogd.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/usr.sbin/syslogd/syslogd.c b/usr.sbin/syslogd/syslogd.c index 81bbbbe66be8..e06464c0e749 100644 --- a/usr.sbin/syslogd/syslogd.c +++ b/usr.sbin/syslogd/syslogd.c @@ -1185,13 +1185,15 @@ parsemsg_rfc3164_app_name_procid(char **msg, const char **app_name, /* Split strings from input. */ app_name_begin[app_name_length] = '\0'; - m += app_name_length + 1; + m += app_name_length; if (procid_begin != NULL) { procid_begin[procid_length] = '\0'; + /* Skip "[PID]". */ m += procid_length + 2; } - *msg = m + 1; + /* Skip separator ": ". */ + *msg = m + 2; *app_name = app_name_begin; *procid = procid_begin; return; From nobody Wed Sep 17 22:08:32 2025 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 4cRtFZ4yQzz688cL; Wed, 17 Sep 2025 22:08:34 +0000 (UTC) (envelope-from madpilot@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRtFZ3yyCz3YRY; Wed, 17 Sep 2025 22:08:34 +0000 (UTC) (envelope-from madpilot@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758146914; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:autocrypt:autocrypt; bh=Fnv1sIYeHsuHBMnJes3U187PXl+g4glLWhnb2xhaIpM=; b=l8f4fhKwxIivVYBns7YoGtnHB4U02fwGLO/zvyuynJCHjleF0V3QZokViaqXXkYeG28q6S EAjA9dWzLGZ65NXyhTn60kNC8sEJntgdDm9L3joI1//eK/20DDmBFbooS+LAnmZizVo/Fd HcOpbVS1bhl3DYDT1ghmVX3CVJb+SFIXwyk3clcyzsvBG16SZqcRKWZGzRCYRbNvSgWNy7 Wo/gfZ8d+D/1j8NIunHLBXajbvLLb15PqoyMS0n4i29uXDC/cMiNlWwqr3pwLJHKzw23qL bvdxHboxeqVv0TaUjPlFqhwvN0yfA+T8fU2A5aqjG/B0biO0HdvwpwPJC1bVyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758146914; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:autocrypt:autocrypt; bh=Fnv1sIYeHsuHBMnJes3U187PXl+g4glLWhnb2xhaIpM=; b=tbc8mAx3jO1MQ0kvLbn0SWsJXA6ADeuRJlN8OYK8YOV8nqvAqpTCnsv3xwQuhP6tP+2NX5 m5Y0m5hJGYZkRBPOcvl41jcXsWhPGYmP/k4n+QfgF+PMWvSNN+bic2Lwu86qFNDhooHIa/ XUy7kyFN+QXqk5jfafHMsh5C3Sra+YE1Wlb73v5XwG15fUR54lgELXHjWT/HfhWnCjxwS2 yYP733qF5nLppJ8RHo3OypFg/vGIBGiDrN4+RobRk5bu7WZeXu9orBV/E/IeDIsQp4KY1m FTj4wwNxJYV1JdZW367jz5/uUxQv0+PyPuKEFjAAmfY0zJ48lBT1VqKZ+xWaxg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758146914; a=rsa-sha256; cv=none; b=kBPic/B39zMQ+pXRrMsZdIJsdln0qf7vcRdXoM4PaMW8Zq0WezgtvDE/SYJ4Iy1GexfhzU 0QMnrq3KJMejK+8+5WH8iTg3fSHAr+QG3SxdQ1owQdvJbrfItWw3iLkvZ1Vfo50YFaKko0 OXaamrn6lVjUNPPHcKViGSDFEYEKWMRn4WIWArIEME8T7tmB7IgI90b3B519k7mblmjLYv m+oDAP7YojIy+Q1tIzjMDJH2Oi1PWkkEuo/rIOurJVZCCGCRfxvK30wv2nf7xqLA9lVrTE ccLsxtu35oHfy7U3tfUB9ZTkHh8Tzp+wIdFIl206VkT0syYjA24WaC3kKSegJg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from [IPV6:2a01:e11:2002:4280:ab9b:8bf1:ec36:413a] (unknown [IPv6:2a01:e11:2002:4280:ab9b:8bf1:ec36:413a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: madpilot/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cRtFY5T6Mz7wf; Wed, 17 Sep 2025 22:08:33 +0000 (UTC) (envelope-from madpilot@FreeBSD.org) Message-ID: <9dc5eff9-3612-4bb8-be96-637bb4257a5f@FreeBSD.org> Date: Thu, 18 Sep 2025 00:08:32 +0200 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 User-Agent: Mozilla Thunderbird Subject: Re: git: e779891327b1 - main - sys/power: Sleep type reporting by PM backends From: Guido Falsi To: Nuno Teixeira , Cy Schubert Cc: Aymeric Wibo , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org References: <202509142159.58ELx5Rg054606@gitrepo.freebsd.org> <20250916050239.4BB672D5@slippy.cwsent.com> <47a0213b-010e-47e4-8285-dcf426f59c08@FreeBSD.org> Content-Language: en-US Autocrypt: addr=madpilot@FreeBSD.org; keydata= xsBNBE+G+l0BCADi/WBQ0aRJfnE7LBPsM0G3m/m3Yx7OPu4iYFvS84xawmRHtCNjWIntsxuX fptkmEo3Rsw816WUrek8dxoUAYdHd+EcpBcnnDzfDH5LW/TZ4gbrFezrHPdRp7wdxi23GN80 qPwHEwXuF0X4Wy5V0OO8B6VT/nA0ADYnBDhXS52HGIJ/GCUjgqJn+phDTdCFLvrSFdmgx4Wl c0W5Z1p5cmDF9l8L/hc959AeyNf7I9dXnjekGM9gVv7UDUYzCifR3U8T0fnfdMmS8NeI9NC+ wuREpRO4lKOkTnj9TtQJRiptlhcHQiAlG1cFqs7EQo57Tqq6cxD1FycZJLuC32bGbgalABEB AAHNIkd1aWRvIEZhbHNpIDxtYWRwaWxvdEBGcmVlQlNELm9yZz7CwHgEEwECACIFAk+G+3MC GwMGCwkIBwMCBhUIAgkKCwQWAgMBAh4BAheAAAoJEBrmhg5Wy9KT2uIIAIrawQ89TnqEhi2C OEQAhx3uqWZuNoS6NyiSgsRCmtSnT2GOgH4Ucbr/I37SkV1B3K6HkoL6lwN8Gjf5KOgLqmTi E1W3RTwS7l8PSvdnjM9i7g351R4mTijtxawB/JcQf/Kge3Yqr1V4g6H+wQXHUStmHThbupuN trzRphvR/e5ekT0FTyVfPmpcbm68i2bwZnKUex/TNIECBykYh8b+SYMLhENf2ayRjCIWS2Ad 7tnTKhMtnS5jtW6qjBy4RoTpQD6oR1xIgkTRlQ49roVCUfdHb+Y/kh+U9G1IcoNy4vkg9IfP dwpSfnP+a8j0AZ1hMnOLZ1fYoQrs+4gVLy8Fs7TOwU0EUxB7QQEQAKFhrDceoPdK/IHDSmoj 6SQYisvM7VdhcleS7E9DoEAVt7yMbf6HbbMVTTY6ckvwTWQssywLBXNVqxgc4WLJjzfUhgef +WE75M3+WFYlOVQLGZY/zEVgma1raYnOHNAOzeHLDmEXjbZP6vGAeDyBbGfQPpE7qGYZ7ube T3XwQO+PklcCrvOPj2ZPcAxGNS2xVU/LzONqCrJqLMJSIcCdsbiSP4G5PnDFHtMokaTY6OEr 8OEQfOAerhcHUa/z7Uu8YtmaqKH+QGkE/WEgaRqSiTnv0JOTD+DxehaqvoKPPZ++2NpCZMHB 2i6A/xifmQwEiIjEXtcueBRzkNUQkxhqZyS13SrhocL9ydtaVPBzZatAEjUDDEJmAMLVFs45 qfyhMiNapHJo2n3MW/E5omqCvEkDdWX/en3P7CK2TemeaDghMsgkNKax/z0wNo5UZCkOPOz0 xpNiUilOVbkuezZZNg65741qee2lfXhQIaZ66yT7hphc/N/z3PIAtLeze4u1VR2EXAuZ2sWA dlKCNTlJMsaU/x70BV11Wd/ypnVzM68dfdQIIAj1iMFAD/lXGlEUmKXg5Ov2VQDlTntQoanC YrAg+8CttPzjrydgLZFq3hrtQmfc0se5yv1WHS69+BsUOG09RvvawUDZxUjW19kyeN9THaNR gow3kSuArUp6zSmJABEBAAHCwF8EGAEIAAkFAlMQe0ECGwwACgkQGuaGDlbL0pMN5wgA4bCk X/qwEVC06ToeR6C2putmSWQMgpDaqrv65Hubo+QGmg2P4ewTYQQ4g6oYWS03qHxqVVWhKz7F jfrV+dH8qbCLfSgIcvdBha7ayGZVrsiuMLKGbw36fcmkZPpSDOfHcP0XH8Z+u9CWj0xUkTxA lZ/7i6gYSUpG2JWNtdmE/X8VVEyXusCLwy0K0BI60A/4dRTIX3C4QKrJ3ZbUXegz70ynjHf+ lQMZ9IZKASoRMuS5FozPQh6abvmwZEPdf5I9riUElzvHrqJ8Bx0t3Pujdoth+yNHpnBxrtO8 LkQdrQ58P0SwcaIX33T2U9pG8bhu5YVR88FQ8OQ0cEsPBpDncg== In-Reply-To: <47a0213b-010e-47e4-8285-dcf426f59c08@FreeBSD.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 9/17/25 22:50, Guido Falsi wrote: > On 9/17/25 11:15, Nuno Teixeira wrote: >> >> Hello Cy, >> >>     One of this series of ACPI commits has broken power management on my >>     machines. >>     One of which managed to capture a dump from a kernel panic after >>     poweroff(8) >>     was issued. >> >> >> I can confirm same crash on reboot on a Intel laptop, after upgrading >> from main 2025-09-06 -> 2025-09-16. >> > > Hi, > > A me too. > > Just noticed this while investigating why my machines with head (laptop > and two desktops) were not switching off anymore. > > So looks like I'm also experiencing this. > > All machines behave the same, the almost turns off, monitor turns off, > but power light stays on. > > I'm testing reverting commits to see if it goes back to working. > I can confirm reverting this commit and the previous one "fixes" it. -- Guido Falsi From nobody Wed Sep 17 22:39:24 2025 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 4cRtx84N5yz68Byp; Wed, 17 Sep 2025 22:39:24 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRtx83Wnwz3ctw; Wed, 17 Sep 2025 22:39:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758148764; 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=05ggCgrSCh0Ho3ty3cICYuP9HiOOjLdqGBOHpbO5GeY=; b=Kc+RIi6ORnQ89XiS+2LQ/Fm9pG5CRztXQuIHzc+BMGJVcFoH+Ru6a0U//jpzEV6z87przW HgP65aGDBiD3ukrVHHOn4Vl9GK+PqcGktHoeEjwub4hehxS5uv1go2Wg78E1YaMxcCyw5v BBD3Fu8wmMaJ+Y/uUTJNpzsus0lWpTkAyn+ps3dWZQgIPfNjK8pdyAMwGni/I7o2Wib1Yh q6vF/Tn/ehHiHLuW6YsbMv+J4b+UuE/JU74NYVAtnjvvtJQ/Zp18vqEjQVgSMU2JyoYpK6 BvJy58TZWVNqRThqoMME/oGzKt9X6FG6RwtoDmSWPXM0Tx2asqT9+AqjFeR25g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758148764; 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=05ggCgrSCh0Ho3ty3cICYuP9HiOOjLdqGBOHpbO5GeY=; b=XkZ+jXkny5WSz1NwVU0CcqYoPSnlMLlZLHEIGC1EU1DuVGEuD++1waI/1QgAbZJ4AxO1T2 LbsGyZpRTXErWZZTRgc6aKD8NbI8W7uGbK+PWB7AiUzszoqtnDOIjnnPls2riseYrL7DrP hDYyZIU+pIiiJwKEbx8+XOc2dZBSmq3IJ8hQcYidp/c4R2bpzk1ijoA9czauHoINN5uC9a VadJ/+DiD4Aji24jaVcwxvF9FoYbBXMAm+KDFLv1E7kxZXRXtW3o3x+SwnWN55DXC7+dTK gNx1qYwft5i3bVDn0qj2j7GxOsl9n2yIx1l4XNZ/LllU7ddBrv2O6jWf08iljQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758148764; a=rsa-sha256; cv=none; b=MFo6QgfccOD4lxUkxGdRE6AjjQJweqZWRLO4kDhnUM6isrl61I60G1lPa9vsu+kWgXO38M zarRKhoJpI4PlimWi2WYTWeak56/5/8mgO4wwEKPz3fes0BmJuTYHDW8jL0dkzoGYKjCIc lxBtXf31YpbxXmV4LVR9Ji02Mjc1KDSBUe90lCFEiREixm5PScRd1KJDqXDQlaJpl3jow5 vrRVU7YvDFs579bTcrghfFvrIPYC8v6PbHqZLZtUiTDKhGaJA2Sbd5YuO3fegDgPGRcmf/ f151YZ+6RWZ1O38U5PSgvPZaGFrOiIryJEmnwTX19aPlPUyferG3P0DZj2dFTQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRtx82cxmzlFD; Wed, 17 Sep 2025 22:39:24 +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 58HMdOx9055927; Wed, 17 Sep 2025 22:39:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HMdOK9055924; Wed, 17 Sep 2025 22:39:24 GMT (envelope-from git) Date: Wed, 17 Sep 2025 22:39:24 GMT Message-Id: <202509172239.58HMdOK9055924@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Colin Percival Subject: git: 6b5adf33873a - main - Include a pkg package in the pkgbase repo 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6b5adf33873a309523dc4e585ff08d70bb6c6f2f Auto-Submitted: auto-generated The branch main has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=6b5adf33873a309523dc4e585ff08d70bb6c6f2f commit 6b5adf33873a309523dc4e585ff08d70bb6c6f2f Author: Colin Percival AuthorDate: 2025-09-17 22:34:25 +0000 Commit: Colin Percival CommitDate: 2025-09-17 22:34:25 +0000 Include a pkg package in the pkgbase repo It is essential that users be able to install the FreeBSD base system from release media and have all the bits needed to update the FreeBSD base system without touching the ports tree or pkg.freebsd.org. To that end, resurrect (and heavily rewrite) the make-pkg-package.sh script and hook it into the create-packages target; if /usr/ports exists when building pkgbase packages, we'll also (cross)build pkg and include it in the repository. Scripting for actually installing this package as part of the FreeBSD installation process to come later, but I wanted this in the tree in time to test it in this week's snapshots. MFC after: 1 day Sponsored by: https://www.patreon.com/cperciva --- Makefile.inc1 | 6 ++++-- release/scripts/make-pkg-package.sh | 28 ++++++++++++---------------- 2 files changed, 16 insertions(+), 18 deletions(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index 97a0b00cc517..65631c2e8eb8 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -2039,12 +2039,14 @@ update-packages: .PHONY ${_+_}${MAKE} -C ${.CURDIR} ${PKGMAKEARGS} real-update-packages package-pkg: .PHONY +.if exists(${PORTSDIR}) rm -rf /tmp/ports.${TARGET} || : - env ${WMAKEENV:Q} SRCDIR=${.CURDIR} PORTSDIR=${PORTSDIR} REVISION=${_REVISION} \ + env ${WMAKEENV} SRCDIR=${.CURDIR} PORTSDIR=${PORTSDIR} REVISION=${_REVISION} \ PKG_CMD=${PKG_CMD} PKG_VERSION=${PKG_VERSION} REPODIR=${REPODIR} \ WSTAGEDIR=${WSTAGEDIR} \ OSVERSION="${SRCRELDATE}" \ sh ${.CURDIR}/release/scripts/make-pkg-package.sh +.endif real-packages: stage-packages create-packages sign-packages .PHONY @@ -2127,7 +2129,7 @@ create-packages-source: _pkgbootstrap _repodir .PHONY SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH} \ create-source-packages -create-packages: .PHONY create-packages-world create-packages-kernel create-packages-source create-packages-sets +create-packages: .PHONY create-packages-world create-packages-kernel create-packages-source package-pkg create-packages-sets create-source-src-package: _pkgbootstrap .PHONY rm -f ${SSTAGEDIR}/src.plist 2>/dev/null || : diff --git a/release/scripts/make-pkg-package.sh b/release/scripts/make-pkg-package.sh index 68172c47f326..a0ac0fc16305 100755 --- a/release/scripts/make-pkg-package.sh +++ b/release/scripts/make-pkg-package.sh @@ -1,26 +1,22 @@ #!/bin/sh -# -# -# Simulate the build environment. -eval $(make -C ${SRCDIR} TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} buildenvvars) +# Simulate the build environment. Note that we need to unset some variables +# which are set in the src tree since they have different (unwanted) effects +# in the ports tree. +SRC_PKG_VERSION=${PKG_VERSION} +PKG_ABI=$(${PKG_CMD} -o ABI_FILE=${WSTAGEDIR}/bin/sh config ABI) +unset PKG_VERSION +unset MAKEFLAGS +unset PKGBASE export WRKDIRPREFIX=/tmp/ports.${TARGET} -export WSTAGEDIR=${WSTAGEDIR} -export REPODIR=${REPODIR} -export PKG_CMD=${PKG_CMD} -export PKG_VERSION=${PKG_VERSION} -export OSVERSION=${OSVERSION} export WRKDIR=$(make -C ${PORTSDIR}/ports-mgmt/pkg -V WRKDIR) make -C ${PORTSDIR}/ports-mgmt/pkg TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \ CONFIGURE_ARGS="--host=$(uname -m)-portbld-freebsd${REVISION}" \ - stage create-manifest + BATCH=YES stage create-manifest -${PKG_CMD} -o ABI_FILE=${WSTAGEDIR}/bin/sh \ - create -v -m ${WRKDIR}/.metadir/ \ +${PKG_CMD} -o ABI=${PKG_ABI} \ + create -v -m ${WRKDIR}/.metadir.pkg/ \ -r ${WRKDIR}/stage \ -p ${WRKDIR}/.PLIST.mktmp \ - -o ${REPODIR}/$(${PKG_CMD} -o ABI_FILE=${WSTAGEDIR}/bin/sh config ABI)/${PKG_VERSION} -mkdir -p ${REPODIR}/$(${PKG_CMD} -o ABI_FILE=${WSTAGEDIR}/bin/sh config ABI)/${PKG_VERSION}/Latest/ -cd ${REPODIR}/$(${PKG_CMD} -o ABI_FILE=${WSTAGEDIR}/bin/sh config ABI)/${PKG_VERSION}/Latest/ && \ - ln -s ../pkg-*.txz + -o ${REPODIR}/${PKG_ABI}/${SRC_PKG_VERSION} From nobody Wed Sep 17 22:43:49 2025 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 4cRv2F73SKz68CLM; Wed, 17 Sep 2025 22:43:49 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRv2F5wF3z3dlk; Wed, 17 Sep 2025 22:43:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758149029; 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=/qgZsBQrFKdqeKOlhb1ngNoW551+YJA6xkf1k6jtu5w=; b=bcDUNB0xpZ9qvQkSERp7Yd6YseOc0Qtm5LkHfX55spu3nTu6NVyhRy7WBwGOBWIXjmitL3 lEDPnwn+ArL5kwbd6ozdtxEV19Mlw78voz83R7aCGI4kTWj4bS8/7Mr7/pnytS8jvq3kO+ +bCT8cSLuHafVqeqbmKcFu3lCKH5FKMbkomZAxGN9d7SVz8BywJJZMlOw5s4J2ws7uiw/X Es7AO8guKyxZiztyZfGM0U+pClNGXLALt1LEuVKDTrZzT6DFL2UQ0obJKdxVP4dJfZfjOz VUs6UqrZnro7K2hUB61kEB7nV+IFgOT2WLjYYhMGocG/d9y8SD//NHnviLpeZg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758149029; 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=/qgZsBQrFKdqeKOlhb1ngNoW551+YJA6xkf1k6jtu5w=; b=kYE15reHaqMqxp8XOBIImGKfaGhpAhYDMkFTpm3CfSwaKQezj/w19sceKISrxnzs+cHt2z +Z9qdEdeysN+ilyKqhB2scP//Hu6hqoiKk9kYl9rrT85LkUh9WUkKZ/L3hgEBEQkaXM4rU 19D5PelDJR+Y8Cklczh6SV1oGztSbq5+ddQkC8312jmxqZDNvpSE7dkP03rS4J4zzZzLHp JOkphnRFX3og6zoa59VvyyjankzfkSqIF3qAVBAd/Wyqxs6TXvIi5UYOU8jNE1KdbcvEJO BLjjieis4HWDbC9i/fr4a2PrDwG7/jpGJcVG23uzQgqZihcRgksdxZUgcj4P5A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758149029; a=rsa-sha256; cv=none; b=IPeqSQDbVkK+Ok8XGUoWkyDd/xXCTluRzhru3FDVxhI1zDwzzkl0PLtBu53XstIqMWwicd Ofi1kzLplArntiHaKtHO6hDjI0z4nF9wTydr0Z0Gi80dhMAWslFp8eT8w0uCI+ekSh5SpN gF4uNdDvPMpIzru6HeiPMa15DNitXaJL0dn6MJS+tndQVQ99EXdSbHRIHqzU7lwVH1O2bi 5/eDd2P0tz4FqnmeqstfVvmAVZPcMpKfNmAvCFEygmdP1Z5+5XL9DhuRTjAfx5oi2yYhOC UwowCoETL24EDD/BMl2o8xNBW1PKWDIGX9HsGArMibL941Eg4Z+o0AIo9Skuiw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRv2F5G4Vzm1K; Wed, 17 Sep 2025 22:43:49 +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 58HMhn1V073227; Wed, 17 Sep 2025 22:43:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58HMhnnD073224; Wed, 17 Sep 2025 22:43:49 GMT (envelope-from git) Date: Wed, 17 Sep 2025 22:43:49 GMT Message-Id: <202509172243.58HMhnnD073224@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mateusz Guzik Subject: git: ea1652bc01c4 - main - vfs: remove a stale comment about unlock + unref relationship in vput 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: mjg X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ea1652bc01c4093eb4a8c6971c69a410883df189 Auto-Submitted: auto-generated The branch main has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=ea1652bc01c4093eb4a8c6971c69a410883df189 commit ea1652bc01c4093eb4a8c6971c69a410883df189 Author: Mateusz Guzik AuthorDate: 2025-09-17 22:40:24 +0000 Commit: Mateusz Guzik CommitDate: 2025-09-17 22:43:34 +0000 vfs: remove a stale comment about unlock + unref relationship in vput It does not hold since introduction of vnode state tracking, which validates unlock only happens after the target vnode is sorted out (fully constructed or aborted). See 829f0bcb5fe24bb5 ("vfs: add the concept of vnode state transitions"). --- sys/kern/vfs_subr.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index f86bda2aa6f0..fe299ecc9c56 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -3567,11 +3567,6 @@ enum vput_op { VRELE, VPUT, VUNREF }; * exclusive lock on the vnode, while it is legal to call here with only a * shared lock (or no locks). If locking the vnode in an expected manner fails, * inactive processing gets deferred to the syncer. - * - * XXX Some filesystems pass in an exclusively locked vnode and strongly depend - * on the lock being held all the way until VOP_INACTIVE. This in particular - * happens with UFS which adds half-constructed vnodes to the hash, where they - * can be found by other code. */ static void vput_final(struct vnode *vp, enum vput_op func) From nobody Thu Sep 18 00:45:52 2025 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 4cRxl470Vtz68Lg2 for ; Thu, 18 Sep 2025 00:45: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cRxl46GC2z3pLQ; Thu, 18 Sep 2025 00:45:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758156352; 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=imFJbso1C+UwDPbzKg2NIvhfv0usrYjJl+Rtq+BJyo0=; b=n2VGsLRNFOMJYzWgAvlQbVu9UWaaFPDL1Y8CCql7MHPhuYexpceqV8G+BBZTx7RLCMZXlt eaSPm7IllEwhunthtpfw/v6bVyy8iO3Gpj/0HqGcXQzj6wM2BAZSl799qp4hixhHaeDP8L /eTLrn3usPYsyftcnmaZeJrqPFH+bkpQvcSNNG0t3iKoQEDCLVnfwbAiNUg66gEsO/hV6O 0YF0hYHltj6+njCsbZJSJixzgqTiivdcy0axbKEtyrQPg7zq2SU6VdYd+PrpkPWs3kHjnF ZCc6o8RKBDQYGqOjpoJE44WcWUPzU4gD0k85HqA8jb+DX66289UCmbo2aAD0dg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758156352; 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=imFJbso1C+UwDPbzKg2NIvhfv0usrYjJl+Rtq+BJyo0=; b=WYnKr1E5p/CQW733BhbvvjZMVwY4V2gWfk4K1YSWg1DlH+okbcyo/QHnsM6JtzThzHsnhS TXVEn3MObCCfPvOeSPAnrY+ZQy65Jgb0ZudurMuWdS0ZCH2U5uMzBFf+Q5ctBKNupO9EVF 40pDNz+zf1ejMvbTuGMfoUamCmacWujWOxCShvxZPqb6WCMh0vPa6ZJwMyaqZ63EhV5s12 GNnOF2mtM87Qr4/0frqhetm8tZJHCib0nuSDSeO0/DlgMZxPjxObG5YtJe/QMpuIb/UmCS l6FJdgtxLNtGsL4EUVsokCp0KtcmBW+qp1+mlQq03OLR5pHi7e50oQyBsVZ6rQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758156352; a=rsa-sha256; cv=none; b=abE2w8dI2kp0ukcxYSnQ13G3nNwQVsqbwlD2uOmRkqR4+Yr8zEq4iiEQMri8rmiO+XMacS cOGWYjVI+Chlll2WYN3VPmT90j1fIA7lDbnBLrGW5sAUK+pwqR/wzvlMN5mp44wPzIHPpS ZHCarlb5qUZIxUCb3nU/ZS+z59F+WkgnvfOep5kTrLSr4mWE7y2Mpkj/uBEuGmdWunvD8s FXgc471mJXRTa7To1K24FBar4ZpeefIVM5hmDYseCQNNDIe+9S9W0uggm7NxEiKYlYUp8Z mMKkvK3HSvkURRPkea8ix9qi5xP4/oT1QWoZ01J7tEXCRRjtnTm82c1UO0Rqyg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cRxl45VHJzqF8; Thu, 18 Sep 2025 00:45:52 +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 58I0jqFM099144; Thu, 18 Sep 2025 00:45:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I0jqix099141; Thu, 18 Sep 2025 00:45:52 GMT (envelope-from git) Date: Thu, 18 Sep 2025 00:45:52 GMT Message-Id: <202509180045.58I0jqix099141@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Warner Losh Subject: git: a696127209c5 - internal/admin - Add Jaeyoon Choi 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: imp X-Git-Repository: src X-Git-Refname: refs/internal/admin X-Git-Reftype: branch X-Git-Commit: a696127209c56a5a9e94d6a95553598c0b7e726f Auto-Submitted: auto-generated The branch internal/admin has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=a696127209c56a5a9e94d6a95553598c0b7e726f commit a696127209c56a5a9e94d6a95553598c0b7e726f Author: Warner Losh AuthorDate: 2025-09-18 00:43:58 +0000 Commit: Warner Losh CommitDate: 2025-09-18 00:45:27 +0000 Add Jaeyoon Choi Jaeyoon will be maintaining the UFS (flash) stack. I'll be his mentor. Approved by: srcmgr Sponsored by: Netflix --- access | 1 + mentors | 1 + 2 files changed, 2 insertions(+) diff --git a/access b/access index e3787c4cc7fc..116e3ff71b7a 100644 --- a/access +++ b/access @@ -76,6 +76,7 @@ hrs igoro imp ivy +jaeyoon jah jamie jfree diff --git a/mentors b/mentors index 1437f8631d5d..58b146a9b025 100644 --- a/mentors +++ b/mentors @@ -14,6 +14,7 @@ aokblast lwhsu Co-mentor: markj brd allanjude Co-mentor: bapt bryanv grehan def oshogbo +jaeyoon imp jlduran emaste kgalazka erj Co-mentor: kbowling khorben philip From nobody Thu Sep 18 04:25:49 2025 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 4cS2cs3YnGz67gDp; Thu, 18 Sep 2025 04:25:49 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS2cs33KQz3GS0; Thu, 18 Sep 2025 04:25:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758169549; 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=69iJaI0QSAnU/8RbUGfWcRHanIwEgMCscPOc1+msPRs=; b=bto26Br1DbljQg9Aqu2SH6JWMVpxvi+VOFcBXbFoKra6gTAjJY/hpWqdoqlFWYIpSu5p6u 42dvBwtc+keGhqWPFmDzxx0mYiaMD//SdCqObkwrsoam1NZf+CalOMA9Y/WW541gri2FH6 FBgGtd/ieqU4BTQJXti6/CZaXP0BhZNIJUll+hNf6ucU4uNC2r7LB4uON5ILV8S6WMZYF6 kIsTs364M4SUkqTqAC0BFTTtk0crCWoT4w/lbIqnJZRxtGPC2b1lcDTnOZbYj6W5zesk5B gqBzLZf/QlhZK4Sj+EwRDxfQJWR/9tN1/o99GTbhpwfLPkiOXqgjP0Si0RyKKg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758169549; 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=69iJaI0QSAnU/8RbUGfWcRHanIwEgMCscPOc1+msPRs=; b=URKgJ/01LfJJ4yI/+pRDuzgrxhTtGvQvmaq37dG3V9jzy9byy2jy/JytRQu53kegfSa65Z OILekdDHqG83O4BWabnq9g3Zb3rzm7cIEyBtK9Y4eiqaMKt300jRzFqZgR7pPb25im65eZ QKeOAm9Usa33bELw9kv1S0co8SxE831fz4FMBXSYUvlVvTUHAr1ZVwtKArGRFweGDDuYeB IaFEEb16Qf1baWYc0nCGvxTfl11WD7lISBm7sLeSYaChfjAIxa861KlzXqigmHbep+F+1j o+2xJbjP/pFpo9rynCtLwYnDI4pU+Ac6Z0GBKbmA70fKgV+7VNy03aDU6fCOag== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758169549; a=rsa-sha256; cv=none; b=uh8MChlq9sK7ShhnfpjPGfSIsQb1K0v/OuCAEY8zFJXtE9E0zvFucbwQdL5x08q0CTbHqq DkcJdOx28U+8n2rA62ADfmvGDk8eeIz4O5Cd7/t/gOGTV0touT7SxPzl03GNsozgSkwJ+h nU2f7HIx5pJLj24ivqP4kqNXWWr+kXYSKyg9BqRRO+oiQLbdtfWAT6UIFDJIaXtBFWkYlj UMpizPN13bIv8DBOzm7JDOUHoJjAGO6kpDuqvxupj6dbKWobIUp/xaI7+jFKow+FQjxePr CbOymqRI5k1hGmxHLLJwreLSTRymANqTzOd2IeGGP8rIhc1TXKhFsTiE5ztvBg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS2cs2QDLzwts; Thu, 18 Sep 2025 04:25:49 +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 58I4PnJL013272; Thu, 18 Sep 2025 04:25:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I4Pn2H013269; Thu, 18 Sep 2025 04:25:49 GMT (envelope-from git) Date: Thu, 18 Sep 2025 04:25:49 GMT Message-Id: <202509180425.58I4Pn2H013269@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Colin Percival Subject: git: 98d74493619e - main - Bootstrap pkg before building a pkg package 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 98d74493619ee0e1587bffed79ce8e9573c3fc8b Auto-Submitted: auto-generated The branch main has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=98d74493619ee0e1587bffed79ce8e9573c3fc8b commit 98d74493619ee0e1587bffed79ce8e9573c3fc8b Author: Colin Percival AuthorDate: 2025-09-18 04:22:50 +0000 Commit: Colin Percival CommitDate: 2025-09-18 04:22:50 +0000 Bootstrap pkg before building a pkg package At sufficiently high levels of build parallelism we can try to create the pkg before any of the other pkgbase-creation steps have taken care of the bootstrap. Fixes: 6b5adf33873a ("Include a pkg package in the pkgbase repo") MFC after: 12 hours Sponsored by: https://www.patreon.com/cperciva --- Makefile.inc1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index 65631c2e8eb8..cd0385ea32ac 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -2038,7 +2038,7 @@ packages: .PHONY update-packages: .PHONY ${_+_}${MAKE} -C ${.CURDIR} ${PKGMAKEARGS} real-update-packages -package-pkg: .PHONY +package-pkg: _pkgbootstrap _repodir .PHONY .if exists(${PORTSDIR}) rm -rf /tmp/ports.${TARGET} || : env ${WMAKEENV} SRCDIR=${.CURDIR} PORTSDIR=${PORTSDIR} REVISION=${_REVISION} \ From nobody Thu Sep 18 04:41:53 2025 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 4cS2zP3B1Vz67grC; Thu, 18 Sep 2025 04:41:53 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS2zP2BLYz3Gms; Thu, 18 Sep 2025 04:41:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758170513; 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=fVUrI9bk2fF8RK099BPveDnhHSkCYM+tYlCkQhau+pg=; b=cwTziDHa94pMuM9Rb3xznbC6j3gvmNZhxcx8EDW6/0OyrjSZKILEh0knPhJslwj1oXiFKV XJX/Ur5bQ5LChn/7HbH47akpb1yUN9J44rHVv7mzHKuOKqaVwkO51chcI0PcrTlHf9nOge 7WyLx89/6FV5zbazON/BuU6ruuMDUYjuDZuDDvCuXfl/G4yZmmfrcZHxQYGX1xsZ2kMb/q xRubMJAZ8dQUmO0LDJhoxE4UX0fIZPViPui2eOZJJNtY129zWedIECwmsvjS9i0jkzEdwZ pSqERJcLlwoNr5ZsROFZ3Syhl4OSkhZXGCC97m98VVr1w1zG8rBErslKK3WdMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758170513; 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=fVUrI9bk2fF8RK099BPveDnhHSkCYM+tYlCkQhau+pg=; b=Yq2KzKCI2lgfZrCa5/vrlOaHoHXme/5MLJaW68fPu1yGgFxcDUEWudfdZggT8iJ35unlc0 8zET0HshgCf0MEomHaTkimgGxoCweE/q+/xKzsuKhlqlpU/+QVwMKCL39lG6yEMEAmQu8r iBUr9vpcKutE0GpL9rhOnRc1r8XhGF7hLHQTjOen5XxT6dkEESwmw3POt5/n6KrjnynjrX LngSz6ug9KeFPqeU7oX0n7HGf0NDav0YSFL3u3LsildvLjBz44pxsyryx5bbPZ+m0iliZj AX4oZj944rnn04fzdybROufm7p65dRUd1AITpw84fZGzBpHaVJZL/z6URVWzNA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758170513; a=rsa-sha256; cv=none; b=sJbrW5mPCY6fxlwbphrqZUWp2owNbymCUYZpUvoo14tUpT3tOuSMzVwbdmnbqe8hAyGWCU 18Z1dL2SOkxAnixkCThj1iH64oPc8ZdlbcV1ytmeZt5gUnPvwEFxejOYdQ6jOLcaI6AU0l WgPJYFDrnXvloMBhKJfs1b6yHuoQKhyinfVHJPepnXbr3EuZRwTaroLx0vK9yP2jJBfQru YZuaYpNMT05XnXP3wSN29XhkitjHjg7YUxeyzYw+J6BrRis8x6nf+o+0qahW4vKzis9AWS cf7IFGwt8LTK6WKVYRGHvMCu8avx5LfUI71S5xBsAVtF3NYNlQtqBUhu77g44Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS2zP1Z8DzwM6; Thu, 18 Sep 2025 04:41:53 +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 58I4frax045498; Thu, 18 Sep 2025 04:41:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I4frIh045484; Thu, 18 Sep 2025 04:41:53 GMT (envelope-from git) Date: Thu, 18 Sep 2025 04:41:53 GMT Message-Id: <202509180441.58I4frIh045484@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Colin Percival Subject: git: b9afd7f6a5b1 - main - release: Allow powerpc GENERIC64(le)? kernels 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b9afd7f6a5b1cf1a6cbcef7a55aede7e71a0babc Auto-Submitted: auto-generated The branch main has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=b9afd7f6a5b1cf1a6cbcef7a55aede7e71a0babc commit b9afd7f6a5b1cf1a6cbcef7a55aede7e71a0babc Author: Colin Percival AuthorDate: 2025-09-15 02:44:07 +0000 Commit: Colin Percival CommitDate: 2025-09-18 04:40:43 +0000 release: Allow powerpc GENERIC64(le)? kernels The pkgbase-stage.lua script asserts that it has exactly one "kernel", but only accepts GENERIC as a "kernel". Use a slightly more permissive regex in order to capture kernels with names which start "GENERIC". Reviwed by: ivy MFC after: 12 hours Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D52544 --- release/scripts/pkgbase-stage.lua | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/release/scripts/pkgbase-stage.lua b/release/scripts/pkgbase-stage.lua index a12ec372d1a9..0cd4cbb5c438 100755 --- a/release/scripts/pkgbase-stage.lua +++ b/release/scripts/pkgbase-stage.lua @@ -50,10 +50,12 @@ local function select_packages(pkg, media, all_libcompats) package ~= "FreeBSD-kernel-man" then -- Kernels other than FreeBSD-kernel-generic are ignored - if package == "FreeBSD-kernel-generic" then - table.insert(components["kernel"], package) - elseif package == "FreeBSD-kernel-generic-dbg" then + -- Note that on powerpc64 and powerpc64le the names are + -- slightly different. + if package:match("^FreeBSD%-kernel%-generic.*%-dbg") then table.insert(components["kernel_dbg"], package) + elseif package:match("^FreeBSD%-kernel%-generic.*") then + table.insert(components["kernel"], package) end elseif package:match(".*%-dbg$") then table.insert(components["base_dbg"], package) From nobody Thu Sep 18 04:41:54 2025 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 4cS2zQ4ttWz67hXl; Thu, 18 Sep 2025 04:41:54 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS2zQ2yfVz3HP6; Thu, 18 Sep 2025 04:41:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758170514; 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=rdo6+ON5x8DLNrBWDRzfLmheYxQxKtm7roD6CL4OuKc=; b=Pi2Ytype2/Tlb5LscwrZn8SG5sv9jpFdYBQRuaWUGdykDUo8Sbkj1cmlblPtw+pW7LRhXR MtyLHhHvMXjCP0232s54y/7/3/M52S1tuAa9pEpwD8KDybWXHGeuxXz57ox5UfqmgNaDBC I/ii2Iw/ibAfTLQbaHxGs0k7leEWboPze2tW0reiM7V/4+cssjl/z/qSF0oKf7K9sXGbDj Vu4mRTzqgI9q7yEOI1d5ZF0F3EQeHhKHaDpvUhDk/5OjIf3WntnSfLsIBLWcc3QzWaDTUS pYG/ordrtyVWIqe0NCxAEwm0TWhWSnn+Q/4iJhO/vbM/7JhQqMZA30Wid4eqfg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758170514; 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=rdo6+ON5x8DLNrBWDRzfLmheYxQxKtm7roD6CL4OuKc=; b=Yv0EHDBRyEN2ap9AuvAHgzcwlUFlvRYRR/difPo3X7uq6BCA5I2TKADbIq5JoRaiIZcweU R0/fQo5DasKb95sWyfTDwzyhLZBZbp6vOJqyUbaqB8Ed1UoHdxfIaSPNyzuV7kF42v+Jq4 goCfGAl5dpeMK/ysZEPC2k/aR+O0Ny1GTPX7DeXxuW7x2QqiILMFlQqHgXfvbMYn4NaD2y cqDoe89+5LbcQfWhd9MC99uaIJcPeICGxEO2jRBwJYdEaT56kKjkywRWWT0K5h38WIiWdy g0WTWXCXg86I+TcnrrSbnH3AMM3uCPcAV7E5hWmXS5I6L14TnT/kxQ9YZ1nYJA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758170514; a=rsa-sha256; cv=none; b=Tv1qnB4tL/OqbeI/oRwq218KaOwcY+YV/XclZaUkJy6CucPM9F8Fq4HwEgj1rB0OZvfwT+ ON2PeK+Pdro5jnHTzNbM2vFKu2A14zRMvkMl9CXlgvzqIYSPVdPIElpj1Ss+MJXy0kVwVI sKm0LAPXgi95TsLZvJ2cEZPuP2sbS37nLv4TwoFNQuQxvBWqSlfx98r+GtYC2JZ9DhsTGY go2tVHkLxHqYH2z1voIrpSFKXDuadQU+O59Y+R/BS5JIl3oPF6CPROrQNyr1NAG1fKIMkW JR+gLOvdmmgDOMubKk7Og3AG7JzYKP3nild8GM2bDsHqn99Tu2AFGfm4LQ8qKQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS2zQ2V2DzwNp; Thu, 18 Sep 2025 04:41:54 +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 58I4fsPv045795; Thu, 18 Sep 2025 04:41:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I4fsxH045792; Thu, 18 Sep 2025 04:41:54 GMT (envelope-from git) Date: Thu, 18 Sep 2025 04:41:54 GMT Message-Id: <202509180441.58I4fsxH045792@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Colin Percival Subject: git: 35b81af1eee6 - main - release: Make PKGBASE the default 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 35b81af1eee699509bae2bbe12fdc770d9cee40a Auto-Submitted: auto-generated The branch main has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=35b81af1eee699509bae2bbe12fdc770d9cee40a commit 35b81af1eee699509bae2bbe12fdc770d9cee40a Author: Colin Percival AuthorDate: 2025-09-15 00:37:20 +0000 Commit: Colin Percival CommitDate: 2025-09-18 04:40:48 +0000 release: Make PKGBASE the default Replace the PKGBASE option by a NOPKGBASE option. Check for both whether the option is defined and whether it is empty, since when running from release.sh we always define NOPKGBASE. MFC after: 12 hours Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D52536 --- release/Makefile | 12 ++++++------ release/release.sh | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/release/Makefile b/release/Makefile index 41bca6dceebc..e48527de160d 100644 --- a/release/Makefile +++ b/release/Makefile @@ -22,7 +22,7 @@ # WORLDDIR: location of src tree -- must have built world and default kernel # (by default, the directory above this one) # NODISTSETS: if set, do not include dist sets or MANIFEST -# PKGBASE: if set, include pkgbase packages rather than dist tarballs in +# NOPKGBASE: if set, include dist tarballs rather than pkgbase packages in # disc1 and dvd1 installation media # PORTSDIR: location of ports tree to distribute (default: /usr/ports) # XTRADIR: xtra-bits-dir argument for /mkisoimages.sh @@ -188,7 +188,7 @@ bootonly: packagesystem dvd: packagesystem .endif -.if defined(PKGBASE) +.if !defined(NOPKGBASE) || empty(NOPKGBASE) PKGBASE_REPO= pkgbase-repo PKG_ABI= $$(${PKG_CMD} -o ABI_FILE=${.TARGET}/usr/bin/uname config ABI) .endif @@ -207,7 +207,7 @@ disc1: ${PKGBASE_REPO} MK_TOOLCHAIN=no \ MK_RESCUE=no MK_DICT=no \ MK_KERNEL_SYMBOLS=no MK_TESTS=no MK_DEBUG_FILES=no) -.if defined(PKGBASE) +.if !defined(NOPKGBASE) || empty(NOPKGBASE) # Create offline pkgbase repo on release media mkdir -p ${.TARGET}/usr/freebsd-packages/repos/ ${.CURDIR}/scripts/pkgbase-stage.lua disc \ @@ -226,7 +226,7 @@ disc1: ${PKGBASE_REPO} echo "./usr/freebsd-dist type=dir uname=root gname=wheel mode=0755" >> ${.TARGET}/METALOG cp MANIFEST ${.TARGET}/usr/freebsd-dist echo "./usr/freebsd-dist/MANIFEST type=file uname=root gname=wheel mode=0644" >> ${.TARGET}/METALOG -.if !defined(PKGBASE) +.if defined(NOPKGBASE) && !empty(NOPKGBASE) # Copy distfiles for dist in $$(ls *.txz | grep -v container | grep -vE -- '(${base ${_ALL_libcompats}:L:ts|})-dbg'); do \ cp $${dist} ${.TARGET}/usr/freebsd-dist; \ @@ -303,7 +303,7 @@ dvd: ${PKGBASE_REPO} ( cd ${WORLDDIR} && ${IMAKE} installworld installkernel distribution \ DESTDIR=${.OBJDIR}/${.TARGET} MK_RESCUE=no MK_KERNEL_SYMBOLS=no \ MK_TESTS=no MK_DEBUG_FILES=no) -.if defined(PKGBASE) +.if !defined(NOPKGBASE) || empty(NOPKGBASE) # Create offline pkgbase repo on release media mkdir -p ${.TARGET}/usr/freebsd-packages/repos/ ${.CURDIR}/scripts/pkgbase-stage.lua dvd \ @@ -322,7 +322,7 @@ dvd: ${PKGBASE_REPO} echo "./usr/freebsd-dist type=dir uname=root gname=wheel mode=0755" >> ${.TARGET}/METALOG cp MANIFEST ${.TARGET}/usr/freebsd-dist echo "./usr/freebsd-dist/MANIFEST type=file uname=root gname=wheel mode=0644" >> ${.TARGET}/METALOG -.if !defined(PKGBASE) +.if defined(NOPKGBASE) && !empty(NOPKGBASE) # Copy distfiles mkdir -p ${.TARGET}/usr/freebsd-dist for dist in $$(ls *.txz | grep -v container); do \ diff --git a/release/release.sh b/release/release.sh index eed02f0f36d3..f4786685e612 100755 --- a/release/release.sh +++ b/release/release.sh @@ -199,7 +199,7 @@ env_check() { KERNCONF=\"${KERNEL}\" ${CONF_FILES} ${SRCPORTS} \ WITH_DVD=${WITH_DVD} WITH_VMIMAGES=${WITH_VMIMAGES} \ WITH_CLOUDWARE=${WITH_CLOUDWARE} WITH_OCIIMAGES=${WITH_OCIIMAGES} \ - XZ_THREADS=${XZ_THREADS} PKGBASE=${PKGBASE}" + XZ_THREADS=${XZ_THREADS} NOPKGBASE=${NOPKGBASE}" return 0 } # env_check() From nobody Thu Sep 18 04:41:55 2025 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 4cS2zS3gnRz67hMC; Thu, 18 Sep 2025 04:41:56 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS2zR5zhpz3H7d; Thu, 18 Sep 2025 04:41:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758170515; 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=8YrNtrpbw1qcdVSacANmav0ZoEPIQceYTOpsf7QW++c=; b=HlFBJ3obiaNAlQrFd6O2AQ6+YWIBB22nJo4mLZWFY8acNMBMlT/xJrKHCzIGaQJi8nNGeS w/ED3NXJNmDOtVpYxV00eurO0PSD3ze0pFWZ7gXGoCUBDIzQO/QFJQhf9TnzAmVA8JTi9X 22pfwMD4qw7+FnBG7HGbu3TmCgXatKyj9/x5lntCQjvlhgg2rxAUKwygU16U7XZ6wuqNrl PuW0zVN3sHM4FfzwapYdmO9JVh3T15e91TxPcFGeoKPFYXOSyVpwS/6PGc4seVoiw3AOFz /NVQzkoMiHHYxnaC/6/reMOUXAFGO3c9FzT4+dDd3MmQN56qLdbaEqyrxFxilw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758170515; 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=8YrNtrpbw1qcdVSacANmav0ZoEPIQceYTOpsf7QW++c=; b=Xg2J7HuOrZ2Tio66k2zqLvrr9vxiuisQmamUau2B3ppLUoaIoel2CtU0ifEeuEPr7z28Zg wV2Eapw3HJoEsEDnJmA5x60Tg+kmvK5UbKxbNmKum33A1N+A4mWeEIA4yOXsMwK9tZvvEy NHyga2nyQ1Y00CD1HW09CZlJaMzMr9AvE1oC6dbDj2ODpNR0xCN0D68fojzt08Tjsq3JP1 JHWvQ8Jf4A7S/oxagxMAFeFEcJUNMk89tGoFe9suC1vGcJQGguAcosZ+sCvN5I8DLpbofJ M0qIB7nLgpEvIeEKmnUWFFEVNCW7jkHIDVaE3x3hp7Cz2PygXNhCypTB/OhQyA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758170515; a=rsa-sha256; cv=none; b=otwYa5waOcrdqPAvszMG9v/+HdIWSb0Bh6l7R0lhB8hc33GeCiyZCKZ7MnFEeawZamcYhb p/xLgmxZMBLfLVw19hxXzyFZUgzUXnzEEzePJ90LrlubQ0BD0UefrK/Dlo7n/nM3otANhP YxH2kW1N0B2nNjlkesgIQCPJIiApoUAxlXBhIFv0OGmG15R+xD6nA7pJS7fj+ghtsUhq0V /qhA75UGN9v22wzZQAKwQUqxo8bbqrFR2BpFCngOut2sgc9HaiL6FMQt+HZnqBaq3z2FjU MRmCGU0Cp45WwgPlBfkAZyDwIcr5JywcviRefX8+NfTvjHa3qHrbLZZlCNbj2g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS2zR3TPBzwNq; Thu, 18 Sep 2025 04:41:55 +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 58I4fthX045829; Thu, 18 Sep 2025 04:41:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I4ftxK045826; Thu, 18 Sep 2025 04:41:55 GMT (envelope-from git) Date: Thu, 18 Sep 2025 04:41:55 GMT Message-Id: <202509180441.58I4ftxK045826@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Colin Percival Subject: git: 7c0bc6c703ee - main - release: Always dist sets on dvd1 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7c0bc6c703eeaea737d0dbc21996764967e4dc97 Auto-Submitted: auto-generated The branch main has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=7c0bc6c703eeaea737d0dbc21996764967e4dc97 commit 7c0bc6c703eeaea737d0dbc21996764967e4dc97 Author: Colin Percival AuthorDate: 2025-09-15 00:39:42 +0000 Commit: Colin Percival CommitDate: 2025-09-18 04:40:55 +0000 release: Always dist sets on dvd1 In the !NOPKGBASE && !NODISTSETS case, we only want the pkgbase repo on disc1; but we want both packaging formats on dvd in order to allow for offline installs in both methods and also tools which ingest the dist sets from the dvd image. MFC after: 12 hours Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D52537 --- release/Makefile | 2 -- 1 file changed, 2 deletions(-) diff --git a/release/Makefile b/release/Makefile index e48527de160d..bc04a7974744 100644 --- a/release/Makefile +++ b/release/Makefile @@ -322,7 +322,6 @@ dvd: ${PKGBASE_REPO} echo "./usr/freebsd-dist type=dir uname=root gname=wheel mode=0755" >> ${.TARGET}/METALOG cp MANIFEST ${.TARGET}/usr/freebsd-dist echo "./usr/freebsd-dist/MANIFEST type=file uname=root gname=wheel mode=0644" >> ${.TARGET}/METALOG -.if defined(NOPKGBASE) && !empty(NOPKGBASE) # Copy distfiles mkdir -p ${.TARGET}/usr/freebsd-dist for dist in $$(ls *.txz | grep -v container); do \ @@ -330,7 +329,6 @@ dvd: ${PKGBASE_REPO} echo "./usr/freebsd-dist/$${dist} type=file uname=root gname=wheel mode=0644" >> ${.TARGET}/METALOG; \ done .endif -.endif .if ${.MAKE.OS} == "FreeBSD" && (!defined(NOPKG) || empty(NOPKG)) # Install packages onto release media. ${PKG_INSTALL} pkg || true From nobody Thu Sep 18 04:59:32 2025 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 4cS3Mq06TRz67jQ1; Thu, 18 Sep 2025 04:59:35 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Received: from omta004.cacentral1.a.cloudfilter.net (omta002.cacentral1.a.cloudfilter.net [3.97.99.33]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Client", Issuer "CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS3Mp4p6tz3JlZ; Thu, 18 Sep 2025 04:59:34 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Authentication-Results: mx1.freebsd.org; none Received: from shw-obgw-4001a.ext.cloudfilter.net ([10.228.9.142]) by cmsmtp with ESMTPS id yrk8umK655Mqyz6k2uiJFU; Thu, 18 Sep 2025 04:59:34 +0000 Received: from spqr.komquats.com ([70.66.136.217]) by cmsmtp with ESMTPSA id z6k0ukCrnWX70z6k1ucQaO; Thu, 18 Sep 2025 04:59:34 +0000 X-Auth-User: cschuber X-Authority-Analysis: v=2.4 cv=d71WygjE c=1 sm=1 tr=0 ts=68cb91b6 a=h7br+8Ma+Xn9xscxy5znUg==:117 a=h7br+8Ma+Xn9xscxy5znUg==:17 a=IkcTkHD0fZMA:10 a=yJojWOMRYYMA:10 a=6I5d2MoRAAAA:8 a=EkcXrb_YAAAA:8 a=YxBL1-UpAAAA:8 a=eENHx-uKDWjIgJi07goA:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=LK5xJRSDVpKd5WXXoEvA:22 a=Ia-lj3WSrqcvXOmTRaiG:22 Received: from slippy.cwsent.com (slippy.cwsent.com [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTP id 9201A50E; Wed, 17 Sep 2025 21:59:32 -0700 (PDT) Received: by slippy.cwsent.com (Postfix, from userid 1000) id 901123CE; Wed, 17 Sep 2025 21:59:32 -0700 (PDT) X-Mailer: exmh version 2.9.0 11/07/2018 with nmh-1.8+dev Reply-to: Cy Schubert From: Cy Schubert X-os: FreeBSD X-Sender: cy@cwsent.com X-URL: http://www.cschubert.com/ To: Guido Falsi cc: Nuno Teixeira , Cy Schubert , Aymeric Wibo , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: e779891327b1 - main - sys/power: Sleep type reporting by PM backends In-reply-to: <9dc5eff9-3612-4bb8-be96-637bb4257a5f@FreeBSD.org> References: <202509142159.58ELx5Rg054606@gitrepo.freebsd.org> <20250916050239.4BB672D5@slippy.cwsent.com> <47a0213b-010e-47e4-8285-dcf426f59c08@FreeBSD.org> <9dc5eff9-3612-4bb8-be96-637bb4257a5f@FreeBSD.org> Comments: In-reply-to Guido Falsi message dated "Thu, 18 Sep 2025 00:08:32 +0200." 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 Date: Wed, 17 Sep 2025 21:59:32 -0700 Message-Id: <20250918045932.901123CE@slippy.cwsent.com> X-CMAE-Envelope: MS4xfE0+Ri/Y8D7NtlCxPDbOnMZgLm6/gCLz8u2oIKyUELEZvW35UmqOyH0IgrJm1Ua47OZ362cgke/H2okDdp4B01RslU4xHUdy3oE3Z8rRypl/7AFUgHjk oh46C5Z2QaPrfmMUEjJr/kcsJeb8tYKjLtmclugCPyK8tp8ir42SSZn0N5DopdYMXjXaCeWyjczfYpfeHYsCCX/QX+53yH0qHDc2hgYk0stvm0KsfqpwHEZg OH3aDBq2WXavDDDKUIkOnXiS7/3/2M20RPyUjQn0DeITaPjzFajL4pgRHtTmJh3dbIVaDCCy3/ys8q2lKmQZxyKxOkjHwxxblRVoIYEUGsOKSCAJ9CAA+fd1 9rjrWWCwPVDmo7stJt39RvA1xlToneUI0QgNtbgAmz1RDOqJrks= X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4cS3Mp4p6tz3JlZ In message <9dc5eff9-3612-4bb8-be96-637bb4257a5f@FreeBSD.org>, Guido Falsi writ es: > On 9/17/25 22:50, Guido Falsi wrote: > > On 9/17/25 11:15, Nuno Teixeira wrote: > >> > >> Hello Cy, > >> > >>     One of this series of ACPI commits has broken power management on m > y > >>     machines. > >>     One of which managed to capture a dump from a kernel panic after > >>     poweroff(8) > >>     was issued. > >> > >> > >> I can confirm same crash on reboot on a Intel laptop, after upgrading > >> from main 2025-09-06 -> 2025-09-16. > >> > > > > Hi, > > > > A me too. > > > > Just noticed this while investigating why my machines with head (laptop > > and two desktops) were not switching off anymore. > > > > So looks like I'm also experiencing this. > > > > All machines behave the same, the almost turns off, monitor turns off, > > but power light stays on. > > > > I'm testing reverting commits to see if it goes back to working. > > > > I can confirm reverting this commit and the previous one "fixes" it. > > -- > Guido Falsi The two reviews to fix this breakage don't address the problem completely. I am formally requesting the revert of the four ACPI commits that have caused this regression. Revert them, please. -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org e**(i*pi)+1=0 From nobody Thu Sep 18 08:51:55 2025 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 4cS8Wv3Fh7z681fj; Thu, 18 Sep 2025 08:51:55 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8Wv2mqCz3hng; Thu, 18 Sep 2025 08:51:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185515; 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=QoRaSZ3lrpj0Clu2UK95Vug5AWBkF4X6dyeeFMboAi0=; b=ZCiiAPcvpMGup2PMYnO43qU97MkMitSfcWpEnRMCZSrStj8ESfGx+iLlsxXRrVcEpUs+KA E/zWq3dgO2vW2IjQBNwA5AjgOkTivsYqlSAaH3/ghDdNenzb09muqvCWNQMxrSBpdcVPYE qYqTNhYbdUnSV6uzHaYRTigKxCr2FXAmr5wMuBexKnTQxMzHNAzRXy+/9NXT6XPBrJTIEB wgJetyt6F8WkFMWRN4K+P9mvwHX2kRCisa/MQZpXXEhr9Lar+RvyblumjGviWe0UAKR9Pi 3TbWx65ilg2tRPxMc+2+UEf3iogogE94rXvsutbZ8qfzAQ3F6UmErrmWgbs9Kw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185515; 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=QoRaSZ3lrpj0Clu2UK95Vug5AWBkF4X6dyeeFMboAi0=; b=yW92uqqRIUfsYVUWcp9vC6clUexOlk1hwP1Ryc2dXXnfZxNBxneZmr2nOfewTHo9DmEoGQ cASEXGh0T23gR8OqFWa4UPhgcdG6FL/j5OrEmonrwmDqBobOeuTtxfFZ52OC95sRjaB+p/ I5Nd++hCwQuBDhDQCf9Dj1p0S48ggRskhylr88qGLuFpUBKNerRGj6nvfYNaof0cpPozTF cKuvVuYcGhXlPlSytbkE9qtqGIiKBlI8NpzWbRnISOJlxb5a0Jw2NGNdZS0kFnvboVY9Aa JrmWihshTBEbJJj4ocbHWIS9oscsdVR5Z5dJgtkiwSNZRsP1zYMOjDkttRB5Dg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185515; a=rsa-sha256; cv=none; b=vzTOfKGByPV4V7lQZuB5nay8OsSBT8J3OW7hOMUxEhbCOp8C9g30wc0DKl0PgEhOEBn9KD /Edw5sdzwU60hr1HRJN58yHGnScbFDfXCUQCZbXsmHqvRA9MFVrHawpIMyabr2AjSyms/Z Ho/9fFUhOVWR7Af3TZOtn70K4T4TstdcuHxn58eDDNs4A6lzafiMyhtC4kjbbCRRI3Ub+E x2i7I9SYle0sjKviHf6vFob0jffSb7880eyiii4c9qhRph2p2bk8+lubDbNagBlo3euJjM Z6t3NOdk/GULOY4T92a1+zH6D22NiEQJvJHWyiRYXTlRW5baFTxG0jZr3yRwzQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8Wv2D0fz147l; Thu, 18 Sep 2025 08:51:55 +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 58I8pt36017254; Thu, 18 Sep 2025 08:51:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8ptMG017251; Thu, 18 Sep 2025 08:51:55 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:51:55 GMT Message-Id: <202509180851.58I8ptMG017251@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 960dbe036d85 - stable/15 - ddb ps: Print again the effective GID, separately 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 960dbe036d853dee08f3d5220c970bb6964baf2f Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=960dbe036d853dee08f3d5220c970bb6964baf2f commit 960dbe036d853dee08f3d5220c970bb6964baf2f Author: Olivier Certner AuthorDate: 2025-08-26 08:56:54 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:22 +0000 ddb ps: Print again the effective GID, separately Following commit be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]"), cr_groups[] doesn't contain the effective GID anymore. Fix the 'show proc' DDB command to show it again, and make it stand out with respect to the supplementary ones. Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52251 (cherry picked from commit de974a0f1b73e79466c25f3c85fe727004576fea) --- sys/ddb/db_ps.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/sys/ddb/db_ps.c b/sys/ddb/db_ps.c index 733c440f5ee3..a26cf8161294 100644 --- a/sys/ddb/db_ps.c +++ b/sys/ddb/db_ps.c @@ -459,12 +459,11 @@ DB_SHOW_COMMAND(proc, db_show_proc) db_printf("??? (%#x)\n", p->p_state); } if (p->p_ucred != NULL) { - db_printf(" uid: %d gids: ", p->p_ucred->cr_uid); - for (i = 0; i < p->p_ucred->cr_ngroups; i++) { - db_printf("%d", p->p_ucred->cr_groups[i]); - if (i < (p->p_ucred->cr_ngroups - 1)) - db_printf(", "); - } + db_printf(" uid: %d gid: %d supp gids: ", + p->p_ucred->cr_uid, p->p_ucred->cr_gid); + for (i = 0; i < p->p_ucred->cr_ngroups; i++) + db_printf(i == 0 ? "%d" : ", %d", + p->p_ucred->cr_groups[i]); db_printf("\n"); } if (p->p_pptr != NULL) From nobody Thu Sep 18 08:51:56 2025 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 4cS8Ww4KgKz6826K; Thu, 18 Sep 2025 08:51:56 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8Ww3hn2z3hth; Thu, 18 Sep 2025 08:51:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185516; 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=PG46uyKlSiGj1bBZH4aPyLcUw2H3icS4AlRNz2OnPyU=; b=CLUH4ZAzneFVZgRWw+56tawpbHlwYnWQF2Qn533iSmrU3pEigxyVEBIXPl6SwE9O/Tzkpy HKpZNZQ6CkYG31O2QO87c8c4G8BnGh5T+yWRmuXhIiGGl+TaqjDV35Hszo48EZtabjd5iN x1ni9Peobfym8XWYnPHnEmuDlWv4tWDsDG61PGtRf5GUpuGrL6e7cLDc4JVehZMAgFv85l mpJQ8pjeJbAWZk1Li7+AQOjLBl76xMhm+G+PhMA1UfiQd8bdLYY9uqJKiC/Zp8HNdVkJwS TrET4vDzMDOBxBcMQbq95lYQJcsdfGGwLfzZYx2xvTpeLB2IwkcDL/oJfVWobA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185516; 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=PG46uyKlSiGj1bBZH4aPyLcUw2H3icS4AlRNz2OnPyU=; b=EjYzYFYCRy0HAJIHXSKNWY/vDMaKVCZn4Fnl+PiSlUDv4hJgme0hDLoNle5pFDQhn91vfV I92kqWvQN1NgIyEFtFQLRqnCaXogAHJWN9i/FeYHzAl7BXROoiSLLBVkzjzcGF2p1csYFg noVi5mUmF0yfoBBdasc89o5ElHtOGLvFhDVED2n9MW+X1J3u6PlmqywvUgos3ESr8SQy0K giJTPsiYF/BG6X8pLm1XDN0XgC69WelaxEkQThmU8PeOpLSuKMfwjBkkKVyVpWGKYfUDki 793fRJ2QjfNHS900E8+HaEGpLNCOwScQMZ5ejC5nK9MFsGoXeGRAE+Cc6pJqpw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185516; a=rsa-sha256; cv=none; b=FK0qJPizrODKNV8JGSY01JyLX04g36lNcjMZGBKBxyVeUFszZqTco7GIFACvkPIScQcUZr L9Dk0bkjdROe+5fZ7InwAfgICtsZikqKxQq67IPpB1G2ahioN8nF3kmOopA8h+ZvmN9Nfz qIkMjhTkJvMDU5A6koqlQDacd/gDSMDzvVkbBxezKOJaISIhdjrnQ5674EEnomR1kWdC/z RHlCNV7tV0iJgnHtqgxNj2Oj4DTJrPob8JJwaaKQ4rcWnaOTpunu5UKQWMF9VAGyES+uyz 1aklL1cFRFyZZhOmuusXmX1ZAu1LyeHMjn1PlkTwsDegQESq0PW8cpfCqzyEjA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8Ww3B4Gz149Y; Thu, 18 Sep 2025 08:51:56 +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 58I8pusn017294; Thu, 18 Sep 2025 08:51:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8puVE017291; Thu, 18 Sep 2025 08:51:56 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:51:56 GMT Message-Id: <202509180851.58I8puVE017291@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 018b8acde021 - stable/15 - hwpmc: On attach, ensure owner is a target effective GID's member 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 018b8acde0218956dca99e49d384b072c7e43ca4 Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=018b8acde0218956dca99e49d384b072c7e43ca4 commit 018b8acde0218956dca99e49d384b072c7e43ca4 Author: Olivier Certner AuthorDate: 2025-08-26 09:43:38 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:28 +0000 hwpmc: On attach, ensure owner is a target effective GID's member This restores a check that existed prior to commit be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]"). While here, improve pmc_can_attach()'s style by changing the type of 'decline_attach' to 'bool', fixing tests on it, adding missing parentheses to 'return' statements, and by changing its return value type to 'bool'. Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52252 (cherry picked from commit 1c3c698ba4c40485ebbbd157cb49172cfa7de9b2) --- sys/dev/hwpmc/hwpmc_mod.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/sys/dev/hwpmc/hwpmc_mod.c b/sys/dev/hwpmc/hwpmc_mod.c index 9b85c989dc96..15c782b91b69 100644 --- a/sys/dev/hwpmc/hwpmc_mod.c +++ b/sys/dev/hwpmc/hwpmc_mod.c @@ -210,7 +210,7 @@ static int pmc_attach_one_process(struct proc *p, struct pmc *pm); static bool pmc_can_allocate_row(int ri, enum pmc_mode mode); static bool pmc_can_allocate_rowindex(struct proc *p, unsigned int ri, int cpu); -static int pmc_can_attach(struct pmc *pm, struct proc *p); +static bool pmc_can_attach(struct pmc *pm, struct proc *p); static void pmc_capture_user_callchain(int cpu, int soft, struct trapframe *tf); static void pmc_cleanup(void); @@ -1029,19 +1029,19 @@ pmc_unlink_target_process(struct pmc *pm, struct pmc_process *pp) * Check if PMC 'pm' may be attached to target process 't'. */ -static int +static bool pmc_can_attach(struct pmc *pm, struct proc *t) { struct proc *o; /* pmc owner */ struct ucred *oc, *tc; /* owner, target credentials */ - int decline_attach, i; + bool decline_attach; /* * A PMC's owner can always attach that PMC to itself. */ if ((o = pm->pm_owner->po_owner) == t) - return 0; + return (false); PROC_LOCK(o); oc = o->p_ucred; @@ -1066,18 +1066,17 @@ pmc_can_attach(struct pmc *pm, struct proc *t) * Every one of the target's group ids, must be in the owner's * group list. */ - for (i = 0; !decline_attach && i < tc->cr_ngroups; i++) + for (int i = 0; !decline_attach && i < tc->cr_ngroups; i++) decline_attach = !groupmember(tc->cr_groups[i], oc); - - /* check the read and saved gids too */ - if (decline_attach == 0) - decline_attach = !groupmember(tc->cr_rgid, oc) || + if (!decline_attach) + decline_attach = !groupmember(tc->cr_gid, oc) || + !groupmember(tc->cr_rgid, oc) || !groupmember(tc->cr_svgid, oc); crfree(tc); crfree(oc); - return !decline_attach; + return (!decline_attach); } /* @@ -1412,7 +1411,7 @@ pmc_process_exec(struct thread *td, struct pmckern_procexec *pk) */ for (ri = 0; ri < md->pmd_npmc; ri++) { if ((pm = pp->pp_pmcs[ri].pp_pmc) != NULL) { - if (pmc_can_attach(pm, td->td_proc) != 0) { + if (pmc_can_attach(pm, td->td_proc)) { pmc_detach_one_process(td->td_proc, pm, PMC_FLAG_NONE); } From nobody Thu Sep 18 08:51:57 2025 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 4cS8Wx6ngWz6826L; Thu, 18 Sep 2025 08:51:57 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8Wx4t8pz3hjK; Thu, 18 Sep 2025 08:51:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185517; 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=Xi2Dp1iM+xN7GZ8ia9aTaRclcGgI2yPw1zeFMDbyGeM=; b=T2lEYW1y2qbUPQ/z4Djl3zukfXG07uvp8NxmIF0ZHajqHDfHjwWMEAndE7zNETt12gggfp DOCyItXiu/wgevigsqrC/7GmdUzPurQJV2jl1kvY6+QF6LSvFSRErT8i8RDpPHA9ryanf5 f6p/NYx1/+olDYtPPAkF3ngcRqcyZTJ/MRfWggEJ2SMPG1cSKMcweAfEXGZSRFo7IdJhFd lz3UXAklhATNXtEyyIlM8UU2emt0zZocteF2dKytRy02c4i4ST6/JyrBoC3nke7xqxTyw9 yORmKWuBzzuKyIOkeRn2eylZWMG+/0AYhUSZsqClWe5bJhYZqMvTU6GFE6EaqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185517; 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=Xi2Dp1iM+xN7GZ8ia9aTaRclcGgI2yPw1zeFMDbyGeM=; b=Md7SyE9serKo4I2NjaydCQcedfz2pgB0XSnMdNV76Pz2Q7NcQhF1c7rZmjbHX0rCDnyYHj A6sOE1pxTZ03YBnlcwy/Qy2K4Tt11DZ0TE4Yd18DXEnZTCvaFfu8eDlDl5IJb5itOren2L V0nRM8Nh+UnoiIIaRCcApTPUIAxP+4uDWK1bv7t7YLTfQb/RR+tz2tYD1gZ21oL+2aKkqV VxY1uriq7FxgLrtQWQggSoMSzmD83XiP111aCK4DdJf+PQQfNXSfLY6CfKByiyNQg0i9gx WFOORSJf/X7MSVMg2YfMrnorkLnay1MHymql95fpxE1W9neM207f6EHR0/z8Uw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185517; a=rsa-sha256; cv=none; b=TRJdTrAMEE0jUv/Z7jMrqlUQNnj33Qb5y2iTVLC8ifQqGb4o+EGxBGc3950SMHrF3CidLk P3zxargoXJsWAG2clSMtkWxWoy+S8PFsQlKu19z2xLFS+uJI2LLjSUW2eqUTnJ9qhT/ADj h7Rlqf7nAhvYly3WSx2k/CzwDAgbjOCe7rLR5mBbj/EDiQivuUqtykxi70ruHle3kYfVAY qGMkGaDfNMa0x8sZk4prxEpUOdzOsZ2bWqm44+Vd9VUZVKVlrlpPhopB5XQcQcbWKzskM1 46bsAH+54x+AbkfTRcrrOgoG/5b/5zESoscVZH1upu68gxFpHqx9VGNyjeRvKw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8Wx47mkz147s; Thu, 18 Sep 2025 08:51:57 +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 58I8pvBW017334; Thu, 18 Sep 2025 08:51:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8pvXG017331; Thu, 18 Sep 2025 08:51:57 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:51:57 GMT Message-Id: <202509180851.58I8pvXG017331@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 30ea55ff5eea - stable/15 - hwpmc: On attach, fix allowing a PMC's owner to attach it to itself 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 30ea55ff5eea80ee9b1e021b151b16c799fb288d Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=30ea55ff5eea80ee9b1e021b151b16c799fb288d commit 30ea55ff5eea80ee9b1e021b151b16c799fb288d Author: Olivier Certner AuthorDate: 2025-09-09 12:48:05 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:28 +0000 hwpmc: On attach, fix allowing a PMC's owner to attach it to itself The returned value in this case was wrong, and would basically prevent some PMC's owner process to attach that PMC to itself although the security checks underneath would have allowed it. Now that this early return has been fixed, its block basically becomes a performance short-circuit which has no effect from a functional standpoint. Fixes: ebccf1e3a6b1 ("Bring a working snapshot of hwpmc(4), ...") MFC after: 9 days Sponsored by: The FreeBSD Foundation (cherry picked from commit 1c40b15971f09c0c0676ae476b88b32166eae8ac) --- sys/dev/hwpmc/hwpmc_mod.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/hwpmc/hwpmc_mod.c b/sys/dev/hwpmc/hwpmc_mod.c index 15c782b91b69..a6a6ae68996c 100644 --- a/sys/dev/hwpmc/hwpmc_mod.c +++ b/sys/dev/hwpmc/hwpmc_mod.c @@ -1041,7 +1041,7 @@ pmc_can_attach(struct pmc *pm, struct proc *t) */ if ((o = pm->pm_owner->po_owner) == t) - return (false); + return (true); PROC_LOCK(o); oc = o->p_ucred; From nobody Thu Sep 18 08:51:58 2025 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 4cS8Wz2Fv7z681ss; Thu, 18 Sep 2025 08:51:59 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8Wy5qvzz3hjc; Thu, 18 Sep 2025 08:51:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185518; 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=Yr+U3vqsq2wdmdq//B4HNScZbW7Lbr6Qqu8IL9FM5is=; b=NGHvyFyxGPbvCpQ6IX0LmURQ9GD1CsYB1BwfJ62vDtXAQjy6iOrHsKxo62XmUvFLWyVD4O rqoYGDyXxGqSplCAK0tjdFAx/PbMIwnVgRw7vNeGE5U2P5bSCW4+QzEfvXOLq9Mcz3e/T5 PJY9b4wWdZldYslPRbLgzjKzaae/LCNJeHzY4Ni3VP9jHP/U6lhVRLSJRwpYQMG+Unv0uy Tgxc42KqrMv2C/LEiM2/0g3lYEqEhscg55dOXO+/1jemfmRfFFSeTcxKV98ql88btmblzK NdO8KYuR8hM8/jQWjJX48DJP+PzJ6FuES5Iv0H1USPuT7x9KbGLh43lcmjhaQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185518; 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=Yr+U3vqsq2wdmdq//B4HNScZbW7Lbr6Qqu8IL9FM5is=; b=x+0PBgYHW0JCEsb9hxMGh64kQgSJe8HTlO6li/zo1Yux+uZrBgLUbRAmuQ/HlSBi89SIXZ U5Kr69vUj8gfqG5NJeW23kYyRSu4eCfhvrXjPfKRK33leJpHRnN23jFA3jvXufN9Om6E4b /GrFJn2GstmG4+8PWKHIEwsi8oRU+PKZPmlWALZgbhbH4/lxGtt729Y3s2JVjB3FWcAY6v fK8q7qcFL90W3zISFqKL1SJJQDt5QdpmU0OKFNIXz2khg35ct0ryI3koaS6/tGmwO5zEr2 hrW1FcGU4in/ZqooQ9kmGGhiBt6nYrEQ/ifOO2DrTnmU7a8gfwVfR7/n8VaQ9A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185518; a=rsa-sha256; cv=none; b=x0arkgXQU4rMLqkHfiGPMx/pwmEqtEXtM6YWzHQTFf68+WsCkOd87DGYRNenDShyrHAMSQ v8zdXL5XDZBDdPtNNETT07LdTPrWVDlNMFOaPlFLIb8U2gd8nFt31YuTbtHPTmMcCJT60+ 6CDtcKL7PkQrFiWXfxUGNT3R/wumiK+ElAtKad5EMgxHme8h9kbwPoL11OM31L11eI+b+/ 3J+lbZ2MgarEUyP3Y4pQGDMUoBs3UnQposvR8dttgstp81c0ucFjgRstbMfkbLJGn3r0wi IoxOzRTtxr33b5vGdixyq/s5B0ppkdvYQ9ykNiWIK05pmynbJbXO1oXneE5XRw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8Wy55ndz14L4; Thu, 18 Sep 2025 08:51:58 +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 58I8pwhZ017369; Thu, 18 Sep 2025 08:51:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8pwTZ017366; Thu, 18 Sep 2025 08:51:58 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:51:58 GMT Message-Id: <202509180851.58I8pwTZ017366@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 97a56375caa5 - stable/15 - hwt: On attach, ensure owner is a target effective GID's member 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 97a56375caa55b5e147117463224e6ddfc12c61e Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=97a56375caa55b5e147117463224e6ddfc12c61e commit 97a56375caa55b5e147117463224e6ddfc12c61e Author: Olivier Certner AuthorDate: 2025-08-26 10:05:15 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:29 +0000 hwt: On attach, ensure owner is a target effective GID's member This restores a check that existed prior to commit be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]"). Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52253 (cherry picked from commit d9e11f01ef076749e58614c03168e89f161dd978) --- sys/dev/hwt/hwt_ioctl.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/sys/dev/hwt/hwt_ioctl.c b/sys/dev/hwt/hwt_ioctl.c index 592db4931bb4..184c7e72f986 100644 --- a/sys/dev/hwt/hwt_ioctl.c +++ b/sys/dev/hwt/hwt_ioctl.c @@ -112,12 +112,11 @@ hwt_priv_check(struct proc *o, struct proc *t) error = EPERM; goto done; } - - /* Check the read and saved GIDs too. */ - if (!groupmember(tc->cr_rgid, oc) || + if (!groupmember(tc->cr_gid, oc) || + !groupmember(tc->cr_rgid, oc) || !groupmember(tc->cr_svgid, oc)) { - error = EPERM; - goto done; + error = EPERM; + goto done; } done: From nobody Thu Sep 18 08:51:59 2025 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 4cS8X03lLhz681fq; Thu, 18 Sep 2025 08:52:00 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8Wz6BTjz3hm1; Thu, 18 Sep 2025 08:51:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185519; 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=n9LLqXq9/UfjqvhBDw6paIYwB9Q2DohngxXjMAsPj6Y=; b=hVWPNbH760oee9ynS7d/jwxSZ55R9xRsY6noxyKnYaUG2j5VIF3O2yvVvXfSE9cPffP8mF zDfQezX4Z4zZOqqPmkjVYoRJASiegV7JaxLS7W+Qg2SI1MTNfqoqwMHVmIqhqW7z+N0LLg bc+ODs35QsAge1LdZRo7haTtONFMVnzN0Rzdh92l6rBz95IrgJs+MnKsMOmWL4t9kWi+RK iiQdNLLQremJtq4c6nlo6GB/dKFGXu+CUKmUo30g4qT8LIhB2P0ITqLxSWmtZo2SPNHYmF tpwokd2Sr7BbRIGrjhi4X6wN3GGGeMS9ILEv8rNOADkNX564Qw5BihBsJTuj4A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185519; 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=n9LLqXq9/UfjqvhBDw6paIYwB9Q2DohngxXjMAsPj6Y=; b=pVXxHcTTdrIndgTH36OYRp/vOmIiSFES22vnMMnT6EIBlGBtu/xEQJUqOLFR4lVyFjH1PV qsScBcKtd82aQGH7s2vVamLo+pyGENm2yDTjnpvZIsqk4ODVAGPoZNYj5/9ElMSRr2w52+ TK0j0nYxzZISM8soz67QnhSEl5steLkT2wiqB5eF7lyi1BwPmqZXfUD8pApvW/L3RKpAh/ pi0JWKWz0szEVCUkuDkT9fymHLmlB0yECtToH5VIDC+y31NAncschYjBxZus2TfI1OlES3 vdHlm/tFTRP817fC7TumXkupfbyjdDM2my2Ew1xieuCpjb6h9ivM3KmvaPXMhw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185519; a=rsa-sha256; cv=none; b=hYvqRIolEU97Ysq+E/vqPB5gZ0CfAuL2dMcpimp7T4/RBdUAymv+t6+QdesopJ7K91BaS4 Z2iIX0Ops3x3n/H7xofxcPYioEdW9nrSin+1gIA6XgUtsePu0Ew4rXWhfR0a+Jpfs8lfOZ XoVWXjCCqgTy2UYuFfmptLq+zq9drzrxWocnw5Z3lJNbfwqFyUm5L8T6y9CTZk4T+xoKqv fZ0i0x7gNw1iqjjoGaxB1AutjiYRDb+E5AaBV1+ySIe7Anz93QZjWNTFpM9C0WfxW1OtXg rIgHkc49BQj6iF0HAJbSpfc9v2P722pJA83WuJwt1K+5B7CsHjfLf/p/5JtteQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8Wz5jhwz14bG; Thu, 18 Sep 2025 08:51:59 +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 58I8pxEr017404; Thu, 18 Sep 2025 08:51:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8pxTl017401; Thu, 18 Sep 2025 08:51:59 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:51:59 GMT Message-Id: <202509180851.58I8pxTl017401@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: a5e6ecb88986 - stable/15 - nfs: newnfs_setroot(): Remove an obsolete comment 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: a5e6ecb88986399a0d06f41404e6dc16bc11f698 Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=a5e6ecb88986399a0d06f41404e6dc16bc11f698 commit a5e6ecb88986399a0d06f41404e6dc16bc11f698 Author: Olivier Certner AuthorDate: 2025-08-26 10:26:36 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:29 +0000 nfs: newnfs_setroot(): Remove an obsolete comment This comment is obsolete, as: 1. This code is FreeBSD-specific and is not shared with other BSDs. 2. With our recent changes in commit be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]"), all of NetBSD, OpenBSD and FreeBSD have the effective GID in a separate field (DragonFlyBSD remains to this day an outlier). MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52254 (cherry picked from commit 67f8bd5986a42a173ef9082abfcd523b1a3ac056) --- sys/fs/nfs/nfs_commonport.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/sys/fs/nfs/nfs_commonport.c b/sys/fs/nfs/nfs_commonport.c index e5fdb395c9f7..862780741ee7 100644 --- a/sys/fs/nfs/nfs_commonport.c +++ b/sys/fs/nfs/nfs_commonport.c @@ -371,8 +371,6 @@ nfsrv_atroot(struct vnode *vp, uint64_t *retp) /* * Set the credentials to refer to root. - * If only the various BSDen could agree on whether cr_gid is a separate - * field or cr_groups[0]... */ void newnfs_setroot(struct ucred *cred) From nobody Thu Sep 18 08:52:00 2025 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 4cS8X14yQyz681ql; Thu, 18 Sep 2025 08:52: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8X10FtPz3hk4; Thu, 18 Sep 2025 08:52:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185521; 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=sosBVUzu/+trNvjB/XDwTRjnD/9deaXr/rYk3QEnttk=; b=wrStvp7zFA8Lsj1+AuF42igUd3cUKfAd9M1iernooqGT5iCDtv3SHNcADz6sTg9akK5v+k ZUvcTGBnAaEsd4bFCVyiclsKz5eOwsnkN2BEgNXlnmr0PxNVolGzOPzGnnzstUUH+uvxoM L64DaOx88riF/QFsJFDZMCKLpCvtH1WyxmQHz6QVBcxTdxVCWWOLqKo14IbXLXdtFP78GH akQqHznaWsnTjkeZxqiLD9v/G00zmiljl5PIy+PW30d/PjwRD5mEX08b6lURR2YCfLkQZq uUducgjhb21z1/FRBXMJVzFdroQ/IhNK1rzpjyP+JKcXvVQipYo72DKz9vbOXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185521; 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=sosBVUzu/+trNvjB/XDwTRjnD/9deaXr/rYk3QEnttk=; b=jRBhtn/p5nBcYedDs7sR8ui94cxzcWBwo7OskYTtHN0xqRwb2Zp6eocKqy5eGUKmWj0oCe B0w3EdaIjAJ92Pwxp2kAqeDb6tk6/9PW4CT7LWudG8kcQcCCK31//jlmFFnPirWAF0ZmDT l4vB+2bJV7S3U1ICHCgZWJl8TirqNCwCbTK5lqKdVvkeWO7rOnhbOH52cIOl686Cnjk+B6 ygCIsngZoqBo945vLX6UhhD89NII4k/LUvAgrDvGA5p5BSLKQbG6jQTgDSHhPCeuhnYQmJ HmNkOfcKKDygpCqsLhq9oHJ08YvGtEXVyGg0uOt6YvRn3GAyf7qpHpUb5Vf5og== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185521; a=rsa-sha256; cv=none; b=ZGQ9J+lJjgWtw8JQtOn35gdNi2pdCkWZIcECVoTU+rHlxVniGQrWVDHt5nzEM6z9qHjFxQ sr0w8vt1tlyffGjgnmgdeJy8+jWuLRQuDBi1pSmVwqzbEhAxuHztzrbMlOZIr8AKStSWPL iOg+XkfRdJFhnlh0eLoZ0vN8qLeoOLIwQN5RSSBkA3HqMNbeZC2VqhCWAy/IY8wX6aA6W0 hoB2bb5XaoNnpTFR8bMYOM2Xpla/MFSSZ7m6O3vfXMftsn2Jyuck+G0jqjhiWLEorNvlw+ KLA1M1x50Bi7Q+QZhFPRhN/2g4Rpd1DRv6HbRMm9vr3ZiPN1x6ymA2S8xdp4Qw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8X06fk5z145s; Thu, 18 Sep 2025 08:52:00 +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 58I8q0f4017444; Thu, 18 Sep 2025 08:52:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8q08Y017441; Thu, 18 Sep 2025 08:52:00 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:52:00 GMT Message-Id: <202509180852.58I8q08Y017441@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 702888ce72ed - stable/15 - nfscl: Restore sending the effective GID to the server 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 702888ce72edac87bb3299c9df5d573d7e9a1df7 Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=702888ce72edac87bb3299c9df5d573d7e9a1df7 commit 702888ce72edac87bb3299c9df5d573d7e9a1df7 Author: Olivier Certner AuthorDate: 2025-08-26 12:55:41 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:29 +0000 nfscl: Restore sending the effective GID to the server Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52256 (cherry picked from commit 71db32347665753a3384e36dcf89c9e3a8af6529) --- sys/fs/nfsclient/nfs_clport.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sys/fs/nfsclient/nfs_clport.c b/sys/fs/nfsclient/nfs_clport.c index e9f1dc23ddbe..77e71d4153c9 100644 --- a/sys/fs/nfsclient/nfs_clport.c +++ b/sys/fs/nfsclient/nfs_clport.c @@ -1098,9 +1098,10 @@ newnfs_copyincred(struct ucred *cr, struct nfscred *nfscr) KASSERT(cr->cr_ngroups >= 0, ("newnfs_copyincred: negative cr_ngroups")); nfscr->nfsc_uid = cr->cr_uid; - nfscr->nfsc_ngroups = MIN(cr->cr_ngroups, NFS_MAXGRPS + 1); - for (i = 0; i < nfscr->nfsc_ngroups; i++) - nfscr->nfsc_groups[i] = cr->cr_groups[i]; + nfscr->nfsc_ngroups = MIN(cr->cr_ngroups + 1, NFS_MAXGRPS + 1); + nfscr->nfsc_groups[0] = cr->cr_gid; + for (i = 1; i < nfscr->nfsc_ngroups; i++) + nfscr->nfsc_groups[i] = cr->cr_groups[i - 1]; } /* From nobody Thu Sep 18 08:52:03 2025 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 4cS8X33qTtz681t1; Thu, 18 Sep 2025 08:52:03 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8X31gsyz3hmY; Thu, 18 Sep 2025 08:52:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185523; 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=E27WHRf2aHlK7yHXr0dYa2XPuJVNlAXhkNHLyg6L/f4=; b=yzxEtyhz7PtqWN/d3w+adeqIKpLHCbkAENi1QPXjdus1IEKVQO5EJRFTdb0tN2XAfRHpf3 3xl1SSnFp9TKh90RJ01p2+FUOGoyEX0Khzzy0HxnMhILmf2W6DNvYwr4V4rvsJpecYXUOI IsRz2nA3c9JnuD1vKwTbSRcyBQrdqIzmefz58c8gUmzr9yA84+DJiTOopvCk/7ZoFVFOiW IZ42UllODEhAnQe/GXSkRv7hVeLgzxTz+iLObEyNWhHgw/TymyMyJHxujBXqfWf0M/VStk AJJjLbW0fw/mH8AAh5n5hWzdKO4SU6MoBpuojIesg05fBYeL99mlIUwuJSbqsg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185523; 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=E27WHRf2aHlK7yHXr0dYa2XPuJVNlAXhkNHLyg6L/f4=; b=jCeO0UylOkvrVFxwvKUI92qWVbuo2PsBgTlnYdNcGGcDFToPrRk/fj49Np+A3dP0CY1DSm KvBoobibqzxVTWOpF2RXasxqr+wLl6AJxJkxE5gpeR0bRpRkpICC1sZxynBPE6dKF8aqlv 4q5EKks/kcZtQoh31d8K8117d3ms1Fr3R6qEHAdRnDAzS/ItWWsW/yEmz1FcdoInlrI0jq Bb8QW2VkqoCdNvAqqKj+Efonq50P9gua2gxyJNh5HdYvINueoouWQjXkP2h8FcLuj+ddDA o3ZHVpRK2L39nZsBsfqi7TI1ibpsxNozMHsx5NlNJLLN6RkHvAo5Nt0ywWU+3A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185523; a=rsa-sha256; cv=none; b=XQr0jqqtz1eYYAEnGeNac2W3N+rFTgdGrDzF2+hoKNSiXjaeaGS2Ko/ssPLUcKejqnt+Ge 2Kt7T13FJS52CkRlUsA00mbJ5DEHV5R5iM63r6z6Hzdv+Vn2Psvyg9+32ik0ykSb/VyIBQ qcEYtTNAzdr9hKPAW3CTBpSgi+6UtXqFJArPYMxCpy8H0a/Fs4LOCJp9tYHjkAOpl5yLYC 2rPSzlFlk5Lv2pWCxx92fpelScEM/XwzcH88Ngj5VUh0mgIFghPNfjNqIMXDBoN+rJqz48 r5BNjKhkjFB7apOsFhxeES7otfjNuYcngtmQR+xOmw6/51C3NmqhT0kCtgY6sg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8X30zM7z14M0; Thu, 18 Sep 2025 08:52:03 +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 58I8q3jT018820; Thu, 18 Sep 2025 08:52:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8q385018817; Thu, 18 Sep 2025 08:52:03 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:52:03 GMT Message-Id: <202509180852.58I8q385018817@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 96a2fc56439e - stable/15 - imgact_elf: procstat groups: Restore sending the effective GID 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 96a2fc56439ebd58622c484944ada9f2d4f2f468 Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=96a2fc56439ebd58622c484944ada9f2d4f2f468 commit 96a2fc56439ebd58622c484944ada9f2d4f2f468 Author: Olivier Certner AuthorDate: 2025-08-26 13:41:49 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:30 +0000 imgact_elf: procstat groups: Restore sending the effective GID Fixes 'procstat -s' run on a core file when the number of groups in effect at the moment of core dump exceeds KI_NGROUPS (16). Reviewed by: kib Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52258 (cherry picked from commit 5568b4441dff078733a76835312a6ce1ccb50a17) --- sys/kern/imgact_elf.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/kern/imgact_elf.c b/sys/kern/imgact_elf.c index 5a53fac50f2c..1bc2491a1a12 100644 --- a/sys/kern/imgact_elf.c +++ b/sys/kern/imgact_elf.c @@ -2610,11 +2610,13 @@ note_procstat_groups(void *arg, struct sbuf *sb, size_t *sizep) int structsize; p = arg; - size = sizeof(structsize) + p->p_ucred->cr_ngroups * sizeof(gid_t); + size = sizeof(structsize) + + (1 + p->p_ucred->cr_ngroups) * sizeof(gid_t); if (sb != NULL) { KASSERT(*sizep == size, ("invalid size")); structsize = sizeof(gid_t); sbuf_bcat(sb, &structsize, sizeof(structsize)); + sbuf_bcat(sb, &p->p_ucred->cr_gid, sizeof(gid_t)); sbuf_bcat(sb, p->p_ucred->cr_groups, p->p_ucred->cr_ngroups * sizeof(gid_t)); } From nobody Thu Sep 18 08:52:01 2025 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 4cS8X259wrz681qn; Thu, 18 Sep 2025 08:52:02 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8X20H6pz3j5N; Thu, 18 Sep 2025 08:52:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185522; 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=mVGJKNRUs19np/IAzsFRf/MB+dbCaIO3PTuwqCVXao8=; b=Wb2U/XvYBXUxnwlacQlsCkjMh9Cik7XBiGf8rY2dcKJBWc/DYNFuiUNeXsQLR5VJM3KX0S uv6KLzAYpaj4t3thpuUSRm8zXpvqrmY5FwOIWgBMkIay3g0EtcBHW3pMExZ3mTlOZosO2T 7dsmrJkdT/G6weqmoQ+gOypICyd9Wq6X8T+/pJrLuBEyS7bjbiixXQAtWwJVve7BmVmlvz e0uAdMg1eQgBqGmp/aD8xPtV1R3tF8r48vZ+jQLJq95aKlkFpB1Eh2bPzjvHDslAR3WNhY nTgqENfiMH49dvhwSsNbdwbIl6YpI/XK7OUGqGc//BviTAlveUozghx2TCVyow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185522; 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=mVGJKNRUs19np/IAzsFRf/MB+dbCaIO3PTuwqCVXao8=; b=rr/nEAcWoMz5OL9DthAvyv8k45y19rEcJ0UIHAla0V5XLrGW7mUq2RFYmC5uV6aUidlpWO E2jPvR9oVn98sJhaPCzX5sOFD44RM18eyzvpsMNw2Hc1mzOj2PfpUY25v9jMVDuwXL5o1u rOZitYDsxtecoxt/PfGWKZnNMQicmgMs0N3OZSdLfGGimNsZmW0g9H9TmuHgWUUyZ2pzU4 wm/knj9rwERFcXJ5Y1c+Mgy5/TnA8hrr6xqVmR/QIVOiJEJGffDjGjivDSgqISYQySqPkz ky6jxygra+74y3Oh6DEkPd1PtZm/JNzM9FqYAGAJEQwmoIJxfjoJq+FjRhu2pA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185522; a=rsa-sha256; cv=none; b=yRJfnednoscfA+dqRdQZyFWOtv/hKUaBgnVXrqkGuZeUYfS9JuhspArHYvDJ6TB+TxUt5j t/vH6s0E0cLm4PPrm3WnSaJuoNMPMmQzP7Jc1n+asbaC8/m7T3nKzcMnkPRpr4HGhE8WCu v6AXDUYWDr03tnoY4yt/XnzTNU+5vqNdX3l2qLle920rxAGgqI5Z+iFIhLbj2zR4br/oXV C2m0Yokcl531KWTu0LZxxgAgCuK3v36UvScBZGTWOfD1NYed3vMv+zANnSJ5nmWyrN94py p82bDSTvCt5JL057E0+2gOBuF5p/6/eXzZvDR59NLxSYiwdzPmJSQk8fjdfJ0A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8X16w7sz14bJ; Thu, 18 Sep 2025 08:52:01 +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 58I8q1OJ018256; Thu, 18 Sep 2025 08:52:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8q1wY018245; Thu, 18 Sep 2025 08:52:01 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:52:01 GMT Message-Id: <202509180852.58I8q1wY018245@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 79c1160fb9f2 - stable/15 - procfs: Restore printing the effective GID in 'status' 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 79c1160fb9f264ea13a96d521b2b41dc97fc6931 Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=79c1160fb9f264ea13a96d521b2b41dc97fc6931 commit 79c1160fb9f264ea13a96d521b2b41dc97fc6931 Author: Olivier Certner AuthorDate: 2025-08-26 13:03:19 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:29 +0000 procfs: Restore printing the effective GID in 'status' Reviewed by: kib Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52257 (cherry picked from commit d859d4c57eda8ad277611466b840637234712e42) --- sys/fs/procfs/procfs_status.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/sys/fs/procfs/procfs_status.c b/sys/fs/procfs/procfs_status.c index 38070e0946bb..49c084d02ff8 100644 --- a/sys/fs/procfs/procfs_status.c +++ b/sys/fs/procfs/procfs_status.c @@ -141,13 +141,9 @@ procfs_doprocstatus(PFS_FILL_ARGS) (u_long)cr->cr_uid, (u_long)cr->cr_ruid, (u_long)cr->cr_rgid); - - /* egid (cr->cr_svgid) is equal to cr_ngroups[0] - see also getegid(2) in /sys/kern/kern_prot.c */ - - for (i = 0; i < cr->cr_ngroups; i++) { + sbuf_printf(sb, ",%lu", (u_long)cr->cr_gid); + for (i = 0; i < cr->cr_ngroups; i++) sbuf_printf(sb, ",%lu", (u_long)cr->cr_groups[i]); - } if (jailed(cr)) { mtx_lock(&cr->cr_prison->pr_mtx); From nobody Thu Sep 18 08:52:04 2025 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 4cS8X45JLkz681lc; Thu, 18 Sep 2025 08:52:04 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8X42Lvdz3j6M; Thu, 18 Sep 2025 08:52:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185524; 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=U58z8+1hLNa4QGwTnF1DJmiXU+MPpnAYxsF664dh5mo=; b=pujvvdSxnEdkv77RUSKCkEQ0XMz3Iv91ffJT9H0XjezyNsKYvfUR5tSOMUBbSand4/xqxM Svg2fZ3HvuvKacmFWZPSHEe2tHaUNzG7ukXc4LRgqshx6ldJFk6ziGw0Rrp90CwZ65A/P0 ijNVLYEXMKT7tVCIJksFr5tLmu6PFKxsS8/MdU2ZtDhLXC92BCo/qysjZeff2NMAjxvqV2 k6ACpF3W7d5r24uhm8A0HFLzh7XZUbdiKcxDMpHck5//Bkfk+mOYeFzq6m5ifVSgpjX9+f HlavvffvCcvVSalqGqlDPv/MH32Ey2zitz2l4LpOEjyTM9YxFuLSOlDbbS5P1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185524; 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=U58z8+1hLNa4QGwTnF1DJmiXU+MPpnAYxsF664dh5mo=; b=IeenQ3zo1UOKl6fGURWWwjKF9LPjB3I6v7MfUpPjm//QaWHEa9N5Ttwg62bczcol7n/MMS UmTPKHKLnWgANruyVYeD8JIFoQ11ev/A9wN9GyswsfAkvg41N02tBoT7u+wJn/CGBC86nF ffj/xWawWy8ONPtOQ4dv08clEZs0oFrO65cqCaxwtf0oh8yPraYcnR0iBxlTY7e75JlLLn cZvzSI2WQ7qzJ9vZUBIwFRGeIQw+a+M7cktzBZSbawUo2+EzamsHMxeuf+sYEleb9vQuS2 t6gNMIV1lyo46ric629qmHTUK928GraGidwQKjjhS0RdQY5bso4afJfrFHPlgw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185524; a=rsa-sha256; cv=none; b=mAXxkPWx2AAqzWNVp8ojnWS8OjcEogcWnOY4qaGS/TOlZK6cX+vhrLdNmR7OBacHgfMdwb 90H44zo17cLz5smh4qN0BPGd+/WFbYFzT/KIUUBw+aCc0r7tCcWrdrqCNZNU24OMmxVjwq wfm6r+U0tZ8ULaIlP/+nWlHc3hQatxBXXNIBrWhTPKb0j8bAY/iRU/Ui67pv3w/f9RM/8D Of66ZH1s7n4srh5bUF5yisViIaK7EccgsuXbXH6zKWR0W/J0R72QRkFs62cbKZnCK5Vxd1 uhuFix/NcgSjiYhICoFbJUQ7Ffk4IJ8Q0xPDHtiE+JDCgOK6Vsrh22naYwEEpA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8X41wtyz14YW; Thu, 18 Sep 2025 08:52:04 +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 58I8q4b4018859; Thu, 18 Sep 2025 08:52:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8q4oX018856; Thu, 18 Sep 2025 08:52:04 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:52:04 GMT Message-Id: <202509180852.58I8q4oX018856@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 74d3fdf040c0 - stable/15 - kinfo_proc: Restore outputting the effective GID 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 74d3fdf040c07116533fca2551a473e959d76c27 Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=74d3fdf040c07116533fca2551a473e959d76c27 commit 74d3fdf040c07116533fca2551a473e959d76c27 Author: Olivier Certner AuthorDate: 2025-08-26 13:53:06 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:30 +0000 kinfo_proc: Restore outputting the effective GID In particular, fixes 'procstat -s' on a live system or a core file (only if there are less than 16 groups). Reviewed by: kib Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52259 (cherry picked from commit 63a40ca813a9995e8e2dee0142297d9c38106c05) --- sys/kern/kern_proc.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/sys/kern/kern_proc.c b/sys/kern/kern_proc.c index 379fbda619c0..c2855034fabf 100644 --- a/sys/kern/kern_proc.c +++ b/sys/kern/kern_proc.c @@ -1112,13 +1112,14 @@ fill_kinfo_proc_only(struct proc *p, struct kinfo_proc *kp) if (cred->cr_flags & CRED_FLAG_CAPMODE) kp->ki_cr_flags |= KI_CRF_CAPABILITY_MODE; /* XXX bde doesn't like KI_NGROUPS */ - if (cred->cr_ngroups > KI_NGROUPS) { + if (1 + cred->cr_ngroups > KI_NGROUPS) { kp->ki_ngroups = KI_NGROUPS; kp->ki_cr_flags |= KI_CRF_GRP_OVERFLOW; } else - kp->ki_ngroups = cred->cr_ngroups; - bcopy(cred->cr_groups, kp->ki_groups, - kp->ki_ngroups * sizeof(gid_t)); + kp->ki_ngroups = 1 + cred->cr_ngroups; + kp->ki_groups[0] = cred->cr_gid; + bcopy(cred->cr_groups, kp->ki_groups + 1, + (kp->ki_ngroups - 1) * sizeof(gid_t)); kp->ki_rgid = cred->cr_rgid; kp->ki_svgid = cred->cr_svgid; /* If jailed(cred), emulate the old P_JAILED flag. */ From nobody Thu Sep 18 08:52:06 2025 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 4cS8X65sP9z681L1; Thu, 18 Sep 2025 08:52: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8X640nFz3j4R; Thu, 18 Sep 2025 08:52:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185526; 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=4/D+o65MezwdysvKWPa+f8gIMWNZ+VWVfQLYIRyM6tI=; b=uGHiwdq4zi3HWR8QyHuCpGwL4LqjtFE5xuHyypBus+7t3qHmWlD1uINtqKGVgHrRHtQp/U q3bS72YaCls8k8jV3cbpATrm1Bv9liIZAMvLVfnCoZluH8R+BUj4g2DrmODfTRuu8W0F59 9EfUWzBSnAVo2+tkz1JrB5Ru65mWGoixWWgjA4zEhFJVVUNDRd1gRBpRCi0bW2rSs/gMHV klBlTg2ZPUt4Oi/3YWyAN2vHwF2fVfFsIRnQAoCREzETSM4MT/LVVqpNjg0Y3FiJW2B3+h 3QPnjTggodRlqy6K0icg0/fN4T2uSP5EsMEKoWvYI/6zu6S4tJauhgc8N2Ql+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185526; 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=4/D+o65MezwdysvKWPa+f8gIMWNZ+VWVfQLYIRyM6tI=; b=XqhigjaeGwrbnHzbetm2tCmJKatdwktaQmw2svebt9l54AS34rwoGDRS9NNxQrUgVNHP+M dlnLItXBQtxJd3mHyJcKocce7mOggpIR7Kui+gSYJ2x7TLRom2EUtlYdqmvMHetsJ5yRP7 uARHvVk3eWUIFXtsEsxGh9NQK7Ip/30c6FEtHq5mFb6dqe8fctb08SAZpKxmCYLCBYMdWT jEqn5rdML49sOduQ3OsED7zjLg+/ULXYmUDaKwGHiExEf+1ABw3Bt/j8TvyaKmuMzDVaRb WijPhZYMb5IWiKfXExB5bpzEWX8hrhYzI3b6V1Z0rgoxqpF0aALyNGtoOsEVlg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185526; a=rsa-sha256; cv=none; b=amwRs90KLzz4RbXf1/2PWFmjNCDo9f8sGzYCi8RW0dJ5DRbExpJB+WoN7e4UPcOBe3BcLp zbKZRFpfIl1arUXbr72wtjvliHasta+1TIXJY/CUVbyCHmB+MSfkCex4imIbXhOXZVysW/ 84/fQZEYq7SgNhg7lPzOr8lDsiJ1IORJFVmvoOL6/omordbvsEDpCEGrNV5o3KLYDNXspi KSnwQEQBjWn2kBDWVzry+KCWqydsevsk8AzylVpBozKF6TBBe4KX51vdaLthaRFcuzu3GE /1PTUSZ93oOnh4T0eBku3/tppLzDJ/w9PvID41Su0l43dwOZmZJS+E3J4xwgNA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8X63btxz14bP; Thu, 18 Sep 2025 08:52:06 +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 58I8q6F6018928; Thu, 18 Sep 2025 08:52:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8q6hg018925; Thu, 18 Sep 2025 08:52:06 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:52:06 GMT Message-Id: <202509180852.58I8q6hg018925@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 32606eb5c4dd - stable/15 - 'kern.proc.groups' sysctl knob: Restore outputting the effective GID 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 32606eb5c4ddedc1ad9cf40625ca3f69de19bc24 Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=32606eb5c4ddedc1ad9cf40625ca3f69de19bc24 commit 32606eb5c4ddedc1ad9cf40625ca3f69de19bc24 Author: Olivier Certner AuthorDate: 2025-08-26 15:54:47 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:31 +0000 'kern.proc.groups' sysctl knob: Restore outputting the effective GID In particular, fixes 'procstat -s' on a live system (for processes with more than 16 groups). Reviewed by: kib, emaste Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52261 (cherry picked from commit faf7e99375910fadb1b409a756be5477b561a517) --- sys/kern/kern_proc.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/kern/kern_proc.c b/sys/kern/kern_proc.c index c2855034fabf..6e56664d12ce 100644 --- a/sys/kern/kern_proc.c +++ b/sys/kern/kern_proc.c @@ -2944,8 +2944,11 @@ sysctl_kern_proc_groups(SYSCTL_HANDLER_ARGS) cred = crhold(p->p_ucred); PROC_UNLOCK(p); - error = SYSCTL_OUT(req, cred->cr_groups, - cred->cr_ngroups * sizeof(gid_t)); + error = SYSCTL_OUT(req, &cred->cr_gid, sizeof(gid_t)); + if (error == 0) + error = SYSCTL_OUT(req, cred->cr_groups, + cred->cr_ngroups * sizeof(gid_t)); + crfree(cred); return (error); } From nobody Thu Sep 18 08:52:05 2025 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 4cS8X601SSz681qt; Thu, 18 Sep 2025 08:52: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8X53RkTz3jHQ; Thu, 18 Sep 2025 08:52:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185525; 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=6AwYvFwkkA017zmrk5/NcaXeME1Jf6JFL1rdhtX3YAg=; b=dy6Hxd9BiguFzcADplmgLX2byPoN4KASkl+A5mn33Rxe183KFIz8gW0AH8ZQUJHKeE8YFe jtBKe2cdVU1auFNX1SUPBheVJA6KrNBFztlreIrr2+FhPyuduer54vd+xKeMfT8tRMfLM2 YDs7WvyppMsEBhOFUhZ4h9bsCAyvXs8ttvkOr6imFcPBm/s48hCDTHxvYP0kOW0SNRnqPb dU4BBStzDun8Yx/gbPHepBYr4cqrn2ywgkZSqQkQafZq7P47URvWD1dYMUI+twKAmte6Tb g693MZzrYdwC3W815jIIfpzei62qeyrhzHGiCfOeRoQPz+qBPHyfbDOLW84y7w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185525; 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=6AwYvFwkkA017zmrk5/NcaXeME1Jf6JFL1rdhtX3YAg=; b=S2w2xVJHkVSZXHujNq4gKuZkj3wsTySBQDksnviCwXWNJAA9PsyE4sbkOAMvme8oMpVmz5 KBD7C2QWUAkpQK2/qeY01twpy7tnmQVpRPbWstw/HMsfXaqynfckRxSb2KGnDNQOO+Jl+b 7yae57gk/duVblKwaiD0PKsOGy32+poJYx1ieqOLcYTA1v3jTZe49BO5wHaELg3YKFKXGC KHtp9LGCQRbjNuIW6FEMDymaYByh9qBv1LNqefVevOwl9PVh7vyRef9RKP4IocNk2TzoMs f6J+zPG4Ce91BVxS4v6NLMbtCKIuegM3w+TV9B7rL05dbfiks1juZheBGp10Ig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185525; a=rsa-sha256; cv=none; b=sPXZLhF/5XJKoE/iXGykUGhrx7AAB5fpZXtlfpnjQ8eG4TM5IOeV5hoxtbtQzfnOdCX9D/ 6c0hBbyKbuFyzlTKITM9qNuQ1GUNnzrIiRNbONVQiFch6nHrJqIOYVySP1ThJOySaVCuxr l8qL6MLCBCwVpYlETt5q3rCtfDQyoBMkOxATYA75Mi6+MRYiOXxECDxkRRDxtPOPvvJeXp diAQlHhIJjHzl1UfaFIEUDypxE/QLzcupoMUYGUEmZ75QCfhT8kRiZ4s41gxDnXa6sc4XQ RzOuyJZHjV3zNg11SR2wK3iGmkRVVp5kz5Ok0hDU0Poka5TKSM9b9NCwKhTRWQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8X52x0Vz14L6; Thu, 18 Sep 2025 08:52:05 +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 58I8q59r018893; Thu, 18 Sep 2025 08:52:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8q5LT018889; Thu, 18 Sep 2025 08:52:05 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:52:05 GMT Message-Id: <202509180852.58I8q5LT018889@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 53a9f161903d - stable/15 - kvm_proclist(): Restore outputting the effective GID 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 53a9f161903d1cc9e0dc11be79a5c84735ab33da Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=53a9f161903d1cc9e0dc11be79a5c84735ab33da commit 53a9f161903d1cc9e0dc11be79a5c84735ab33da Author: Olivier Certner AuthorDate: 2025-08-28 14:19:43 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:30 +0000 kvm_proclist(): Restore outputting the effective GID In particular, fixes 'procstat -s -M' (only if there are less than 16 groups). Reviewed by: kib, emaste Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52260 (cherry picked from commit 7676df2faeb6dcbf20456574dcd2a7f4ab8fff8a) --- lib/libkvm/kvm_proc.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/lib/libkvm/kvm_proc.c b/lib/libkvm/kvm_proc.c index b2b7c6ecce56..fed483978e62 100644 --- a/lib/libkvm/kvm_proc.c +++ b/lib/libkvm/kvm_proc.c @@ -150,13 +150,14 @@ kvm_proclist(kvm_t *kd, int what, int arg, struct proc *p, kp->ki_cr_flags = 0; if (ucred.cr_flags & CRED_FLAG_CAPMODE) kp->ki_cr_flags |= KI_CRF_CAPABILITY_MODE; - if (ucred.cr_ngroups > KI_NGROUPS) { + if (1 + ucred.cr_ngroups > KI_NGROUPS) { kp->ki_ngroups = KI_NGROUPS; kp->ki_cr_flags |= KI_CRF_GRP_OVERFLOW; } else - kp->ki_ngroups = ucred.cr_ngroups; - kvm_read(kd, (u_long)ucred.cr_groups, kp->ki_groups, - kp->ki_ngroups * sizeof(gid_t)); + kp->ki_ngroups = 1 + ucred.cr_ngroups; + kp->ki_groups[0] = ucred.cr_gid; + kvm_read(kd, (u_long)ucred.cr_groups, kp->ki_groups + 1, + (kp->ki_ngroups - 1) * sizeof(gid_t)); if (ucred.cr_prison != NULL) { if (KREAD(kd, (u_long)ucred.cr_prison, &pr)) { _kvm_err(kd, kd->program, From nobody Thu Sep 18 08:52:07 2025 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 4cS8X854ZBz681fy; Thu, 18 Sep 2025 08:52:08 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8X74r6Nz3jLQ; Thu, 18 Sep 2025 08:52:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185527; 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=kQBVYg3GR8Fxe6+pLxR2KQ57/93jZJ5dRiKvw4WXjOw=; b=Jb/YyU6UxGouX2aY4p51uDeul2bM1TNMihonU5mfrIPdKd5x7LCdJMdXXribyg8vCPOOC3 ARruQvbixDk2oapCd5unAA3NBm8xPt13lRjXk3Ee4cmpAlWZfO4EeeU0VLO9oIVKkpnHWj izUbWW387y12O2gukxYe37/oRqWasqLSvWQSwhPVBVkzn38fB85tM4XkWjBZPNFLaS+qr6 5tIgf1R3Q+7fNsEQ/glyEal33vSBkTPj/l9MgxpnmTpHAamUoItog3/nbC98/knqDuw63p 1QPWpMHiF3I3F1NYzdkRNR6qhi+9XWWCQpWzmLi/LetjAuGUl8r9kGm4DmxQOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185527; 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=kQBVYg3GR8Fxe6+pLxR2KQ57/93jZJ5dRiKvw4WXjOw=; b=soEce6qSgI+qJss+JGLi8v6sBveuhE3MBfod/bTeTkC7LpAb/qMLeFnnXtT/2wvJFRqbDs taN8oy+xkfQQHxg+KcK6MttbM7AOXznyCF6gEBaodYfM+2RpOFK1c4FIfQJWC5Yfij7PG7 +fupzGhZCjypThSjoK3Mc1PG92TB7EiCA5Opqq8CykhVvpK/8vo5zLWKj/na0vx/qoEX3g THgRp+7FQaY84UuDtptrgBp0TuSnuSkvCHMDdtIpMsyUAiQvkhwJwzs/HV09XV3DLiH7J5 KKpvMX7QB6kZpMIOBmUAzb3YjjvAvxvX2fimEAw4KFfLIZY0Y40slXo1I144+g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185527; a=rsa-sha256; cv=none; b=icgZABbOBgC1b+IsZVWD8TWp+601hS1iCu+lVAKEsgbOB1ayP/9jrj8lVSCpAh2IGmDifx 8fs+ELCF2RsOYnKit7YbJ0E2jOYl87R6amvvEGMP1kWtNTOi/eabwDVSd+OWNmm0HPD8Lp MSITgltceUvDaovG7xnsCzCiz3CTHbOQJaDZDUDIxsB9NgUqf+MCcf+y2rUfsMGX07mzVm c8jGTw3oJw+aFq+JYippkN8oPXtBTc69oXRt8fWwFkFVRU4daZr2wHrAGjgIOafj23oCCK umHyc4jKkjCaUa973Y4qm8wIuaMEysWd1KKUd3266qhezTsOoenD3rd2L/LiMg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8X74PtCz14L8; Thu, 18 Sep 2025 08:52:07 +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 58I8q7cc018961; Thu, 18 Sep 2025 08:52:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8q7MU018958; Thu, 18 Sep 2025 08:52:07 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:52:07 GMT Message-Id: <202509180852.58I8q7MU018958@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: b5bd97460110 - stable/15 - getgrouplist(3): Remove superfluous headers, bogus comment and whitespace 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: b5bd97460110f1536228c9d2e8f25ebef0972a30 Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=b5bd97460110f1536228c9d2e8f25ebef0972a30 commit b5bd97460110f1536228c9d2e8f25ebef0972a30 Author: Olivier Certner AuthorDate: 2025-09-12 12:29:59 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:31 +0000 getgrouplist(3): Remove superfluous headers, bogus comment and whitespace No functional change (intended). Fixes: a59d6a872459 ("Implementing 'fallback' nsswitch source.") MFC after: 3 days Sponsored by: The FreeBSD Foundation (cherry picked from commit d3f8ed6066fdea329ed695925fc726e84d50abc3) --- lib/libc/gen/getgrouplist.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/lib/libc/gen/getgrouplist.c b/lib/libc/gen/getgrouplist.c index 5bd06bc5121f..cb23b9b2316d 100644 --- a/lib/libc/gen/getgrouplist.c +++ b/lib/libc/gen/getgrouplist.c @@ -29,14 +29,8 @@ * SUCH DAMAGE. */ -/* - * get credential - */ #include -#include -#include -#include #include extern int __getgroupmembership(const char *, gid_t, gid_t *, int, int *); @@ -46,4 +40,3 @@ __ssp_real(getgrouplist)(const char *uname, gid_t agroup, gid_t *groups, int *gr { return __getgroupmembership(uname, agroup, groups, *grpcnt, grpcnt); } - From nobody Thu Sep 18 08:52:08 2025 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 4cS8X90YNxz6826b; Thu, 18 Sep 2025 08:52:09 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8X85hHCz3jNy; Thu, 18 Sep 2025 08:52:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185528; 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=OWwOsT6dl7/EVYXycw5+QgC0evPQypRKnN3yFJpdVAw=; b=sOSJ3gCOEZDjrebNoEM2/2Kk0TItBohQ6ht0dxqpgf1c9ePLv+c5unLlXecCHzGnA7U1Yr eOtfgcuV0/7WPi2vl9szwH4/amAol6pnXRXOp08tKq78WsjlYzYFcdZit0y3Fn71grek2g 7sFlv7Kxml1B8JzMQn5GobGLDRJ81l+4mlLxGn043RHs5aesBbqOpndMj9cpcSXsm7fu8y Jzdk9f7SUps2+anbp5n/KgKzJnTaCwhM4dRJOBnHvjHfqdDbgZsNcvLEbJi88AQsYvb1bY ZpTTpsuiKUpd/c927wn1KSAN3PvHlHMu2NBiMuBnZBvcMjsJSDwPKjiPLTzmpg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185528; 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=OWwOsT6dl7/EVYXycw5+QgC0evPQypRKnN3yFJpdVAw=; b=MdMdW976dIl5b0TBldH7YXbUThUYn9TBGix5lTYmxmW0oMrg/vJYe7G2E+9rRT015HceS7 JeZJF0hbm1hweIxu8j5xfdpS4aHmcUlmOPOSKOqJjreXxnTEpvp2wxEsiYPwn/qXzr8A4y 8sfH+/1c1bsfIgGConw9UPc9/nIb+VAlbcJ5rO1LSoGv80ans3Ls2lvB1bxd/QvcUsYJR7 CowVk4WoccUVgqJR574aQUbq91cSIQvIGaC16pVwU7xRWeTgrIumnAweLoK4AVNAjJxV8H NlpXF+oUogfMEMuvTVVdLdt5OhqX3raONh9wr45LSu4oaiebW0u0q+A5rtIldw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185528; a=rsa-sha256; cv=none; b=RLFBdrdLI3syJnlsncxqICgCTZQqKIQBr/MhULLO4FZvL59Ha1v+WBPjwxhvMyY73uAd4g z4mMnFXqww2VGMg+WLVscNN7lLqCY3L7OSFDpa/gnliv+62udNQbqAZsXshiSEl7ysyiS1 GKQiI5a4ZW6SFuMRNM/nG6Ys/UxTcBC3CTtGMq6vBgoWiPkiLAmz3LsAhldMKIXPuuZ/fF BUdIEIc5CBMZ24BClYAYPB5vUneaDe2s/dKG0DqvMfR3QjKu8TU4omkPSoVMw1koICO3vN Ou0Nc9M6Mmwl9x9xqgk88Ew1jNb1DbonEZJuv7H/lfBdFpIo6ZXqDx+7iremVA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8X855Vgz147y; Thu, 18 Sep 2025 08:52:08 +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 58I8q8bJ018993; Thu, 18 Sep 2025 08:52:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8q80t018990; Thu, 18 Sep 2025 08:52:08 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:52:08 GMT Message-Id: <202509180852.58I8q80t018990@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 2e71d105249d - stable/15 - libc: fix the _FORTIFY_SOURCE build of getgrouplist(3) 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 2e71d105249deeb1daed328fff993e79bb26be1c Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=2e71d105249deeb1daed328fff993e79bb26be1c commit 2e71d105249deeb1daed328fff993e79bb26be1c Author: Kyle Evans AuthorDate: 2025-09-13 22:19:46 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:31 +0000 libc: fix the _FORTIFY_SOURCE build of getgrouplist(3) We need to get our prototype normally, but WARNS in libc is way too low to surface that. Additionally, _FORTIFY_SOURCE needs to include by way of to actually export an implementation of getgrouplist(3). The version defined in the .c gets named __ssp_real_getgrouplist() and the actual implementation comes from the redirect stub in , which basically gets optimized away in the built object because our __builtin_object_size() check is trivially false when we cannot resolve any object sizes in this translation unit. This could be argued as a design flaw in _FORTIFY_SOURCE, but we should grab for our prototype anyways so let's kick the can down the road instead of re-thinking it for 15.0. Reported by: Shawn Webb (HardenedBSD) Fixes: d3f8ed6066 ("getgrouplist(3): Remove superfluous [...]") MFC after: 3 days (cherry picked from commit 91ea7e2ce2b5b2ff4702c3092cfe944862d58172) --- lib/libc/gen/getgrouplist.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/libc/gen/getgrouplist.c b/lib/libc/gen/getgrouplist.c index cb23b9b2316d..9c57b7031336 100644 --- a/lib/libc/gen/getgrouplist.c +++ b/lib/libc/gen/getgrouplist.c @@ -31,6 +31,7 @@ #include +#include #include extern int __getgroupmembership(const char *, gid_t, gid_t *, int, int *); From nobody Thu Sep 18 08:52:09 2025 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 4cS8XB66gSz6827J; Thu, 18 Sep 2025 08:52:10 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS8XB2Ngxz3jSm; Thu, 18 Sep 2025 08:52:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185530; 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=GMDHZmIWFkdR6xPMffYXRZebAn2MagcHagJNwwyoPTE=; b=PfDMg5K9MhgAmIzyCbC7aS0knDlGHMZGZ2TcUoxU5ePRS0XQeXV/SXP0S8kpMGxcjH3LKY FyxzlDJbxa8Q/GddJFravaaV/WKn4zPX9zDHBKzivjpahiEwyWy/+9oiXK8UmSA5HSL1yx adT+KCaNqQ0Ba2yFDT9twJrdiLeQ0lAovkizwJnFIGyQosW20GPaxnNqF1vbtwKQa6wD6D 6aSRi0YW8+wRGt3HUq5pSn8/z4HYqWrcasoRFpQWlrjVNcnl/6tcQWgS9T41mI9mW28oSg IqqgUIQJh2EEr/TvGiUSldDgjC+OLSdUjE0gJqhGr3sqoK0edNKAZ3EDBlWvug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758185530; 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=GMDHZmIWFkdR6xPMffYXRZebAn2MagcHagJNwwyoPTE=; b=nhna+OnVFc9pk3OvNw3rUejOWjlZy9F+4ZBOreuoTkObWTrTZTFL/loU8h8oddQD0xpPgu Khg9tP6bMR/mVGJiAgMQ86RwXh42LldKP/ZtTmqBU/qWIRVe7+lrx4kP2FzL0crFGZvgGN aJ5H7X41RXPbY/Bxs6rzO2YD3kGlEFzicrW3RdRw3CllTMGbYm540l8NhWcSrSuJ3H0MCc nd21Dm5rpyZaCc7cPQBipO1DbYpirEycI18Qn06sCy2iONzVCNA7iJ5mmw+TLxo22cJh9u o8MQMaw5OtY8m3IxoWPpcgXoqPOp5MLwRfaqN2bE79YM5Wc8lEFg7G3k0lQNzQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758185530; a=rsa-sha256; cv=none; b=EZ/QUvjMOHwrNjfVoMHqzSXN1bkF2DaJFKAMvg2OPBCKW4IrdpTNAryBzEYphzMjoZ3cuL BRavNDVYzutNr3PefAO5/0GCmfZmmGxpoYrvWIgZmWjlG6yFmipsQ4gKz3MVN0cFHrFXbB pogNAOPnQwJ0gigrz46gjZ277oTV9bSX4/K9A6XFQRttytxXJ8dkuuxkWDbXb0ixLcazBx ednfF4dOhZ3EpAPJsx8YbA5jw7meFeam9HEZbOyOnYG9j99/22/JdrmLy2DoFP3frgj1uN wJuAnDjZLI11woeFF2PIWm40BXb5wRAGG0U4D5xCPAqN8acbb5+DF2G9BYtf7Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS8X96Q4lz1481; Thu, 18 Sep 2025 08:52:09 +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 58I8q9Bl019031; Thu, 18 Sep 2025 08:52:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I8q9ln019028; Thu, 18 Sep 2025 08:52:09 GMT (envelope-from git) Date: Thu, 18 Sep 2025 08:52:09 GMT Message-Id: <202509180852.58I8q9ln019028@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 7140f620a569 - stable/15 - jail.2: Mention EPERM is returned on open directories 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 7140f620a5695b023e76e482dab50133479f0a0b Auto-Submitted: auto-generated The branch stable/15 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=7140f620a5695b023e76e482dab50133479f0a0b commit 7140f620a5695b023e76e482dab50133479f0a0b Author: Olivier Certner AuthorDate: 2025-09-01 09:31:23 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 08:50:31 +0000 jail.2: Mention EPERM is returned on open directories The manual page does not directly mention this reason for getting EPERM, instead referring the reader to chroot(2). We have had some questions about it recently, in part due to a bug (fixed), and this case is not an obvious permission/problem, so let's be more explicit. PR: 280809 Reviewed by: jamie MFC after: 3 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52319 (cherry picked from commit ef2f36be8fce8cf7a62ce7d33ab1c4a181fac3e2) --- lib/libsys/jail.2 | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/libsys/jail.2 b/lib/libsys/jail.2 index d3f871608c1d..ee4e5b03d38e 100644 --- a/lib/libsys/jail.2 +++ b/lib/libsys/jail.2 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd September 9, 2025 +.Dd September 15, 2025 .Dt JAIL 2 .Os .Sh NAME @@ -555,6 +555,9 @@ and call .Xr chroot 2 internally, so they can fail for all the same reasons. +In particular, they return the +.Bq Er EPERM +error when the process to join a jail has open directories. Please consult the .Xr chroot 2 manual page for details. From nobody Thu Sep 18 09:26:32 2025 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 4cS9Hr2KqKz684CP; Thu, 18 Sep 2025 09:26:32 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS9Hr1jF0z3rhl; Thu, 18 Sep 2025 09:26:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758187592; 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=kHBOedBsg196l0spi7Bm0qsWciXkP3fHGMeutPunKio=; b=MTN4oDjEF63yoNGh4A7bHVkls8JZdHOfPggQ0MQlzfFnrr/LVw+qshD2km1jD+DdfNP1ew oWd/IuKNRv5R5duCZu7cMvS8cx7pbHW1jtTQJXfYex3UczmkyAjs9UFbZ0WjgvFv239Jff dzfFwpmJE/aTj8ZZaKXiU3zyljncnuJGoTAMlo0jgMr35FoyfrLAkiYuZiexK7pIWp2R7g eOS9bnzsuQHdjDeDNomQ/2RpMHj3y05RePX5brgZiO7Ur+bWZxDj4RlxuWtOV0bs9z17S/ 8O0aJXIRMagQ0da8VJRdPXzIHZ7j4Rqfc9x3Cyveqh2U02qGTewlwZL4B9BPEA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758187592; 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=kHBOedBsg196l0spi7Bm0qsWciXkP3fHGMeutPunKio=; b=sFOu8zx/wRg/yHcEgSUUvjXlzEvU2P2W4HOBeivMbximBWESaMmhVVzU5AQheL9snlpZgt qMTfMR21aH5NMaRJSP8THxt9tU+JS4/5hhc/hpoRx6pWve6TYITzT6X7uUo84Wd562xhg0 83gBOqicPXp1OQkC7CsqJIEbXc3G1TfU128N8osuwwGFn6uK4zmHpPIYE9OPQNujQHRkEM rDOGNC4bRiiHBK8/ULvYOjO2X67ayYe8ZzX+u0EJ4MIAEq2I+22D3uXXDmHnZqHAcQdmUo J5HKgTwCnGkQs3mKZogUYzVhFoXGqd0UJ2chTMkBZcGYNaFWdWLgXfVo+d8Adg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758187592; a=rsa-sha256; cv=none; b=J4AzEqp7d9H5Hto3F9DGRvxPDlOTYaDgDG/urjkY/bPOX8WhsKR/D8kffTMesXiUNrR0vz lVnMefNskraF858+clz+FTWdFCgPKyn1BR6dAzLjH7fw133fGdBiWhhFEmVBBQd6EPxzZq Olt2xfNdAJY3mrcLw4CRkE5QaKc2l1knrrWgpoprYIezkHSG3IXJ1w/pTcpLPLuMjKTmeY awSrsW16k7U4JHNMkoRo4h0oXaX0ycQlHRc/SuisMmDHYkrIvTZ1N3B80+PXUUkWSE3YnE MXJTOZdkDf85rFnfwtCWeJ8pg1HmHPwRJDVN+B/zYlTac6UngOEqDgCXPDg9mw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS9Hr1DJ8z15KH; Thu, 18 Sep 2025 09:26:32 +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 58I9QWkw076355; Thu, 18 Sep 2025 09:26:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I9QW1g076352; Thu, 18 Sep 2025 09:26:32 GMT (envelope-from git) Date: Thu, 18 Sep 2025 09:26:32 GMT Message-Id: <202509180926.58I9QW1g076352@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Lexi Winter Subject: git: 9065390ddc7b - main - packages: Remove the tests-dev package 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9065390ddc7b1ce2613777f6a947200950a5ac71 Auto-Submitted: auto-generated The branch main has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=9065390ddc7b1ce2613777f6a947200950a5ac71 commit 9065390ddc7b1ce2613777f6a947200950a5ac71 Author: Lexi Winter AuthorDate: 2025-09-18 09:13:41 +0000 Commit: Lexi Winter CommitDate: 2025-09-18 09:26:12 +0000 packages: Remove the tests-dev package We don't want a tests-dev package, because this means set-devel depends on tests-dev, which transitively depends on tests, which means you can't install set-devel without also getting tests. The only real "dev" files in tests-dev are from ATF (libprivateatf), so move that to its own package and add a dependency from tests. Also move Kyua to its own package, since this might be useful for running tests even when the user doesn't want the whole set of base tests installed. Add a dependency from -tests to both -atf and -kyua, and a dependency on -set-base, since the tests won't work without the full base system installed. The remaining "dev" files in tests are actually test artifacts, not real development libraries. Add a new NO_DEV_PACKAGE option to bsd.lib.mk, which causes dev files to be installed in the base package instead of creating a -dev package, and set this option for everything that installs test libraries. While here, add a slightly more informative description for the tests package. MFC after: 3 seconds Reviewed by: bapt, emaste Differential Revision: https://reviews.freebsd.org/D52597 --- UPDATING | 8 ++++++++ lib/atf/Makefile.inc | 2 ++ lib/atf/libatf-c++/Makefile | 1 - lib/atf/libatf-c++/tests/Makefile | 2 -- lib/atf/libatf-c/Makefile | 1 - lib/atf/libatf-c/tests/Makefile | 2 -- lib/libc/tests/tls/dso/Makefile | 1 + lib/libc/tests/tls_dso/Makefile | 1 + lib/libxo/tests/encoder/Makefile | 1 + libexec/atf/Makefile.inc | 2 ++ libexec/atf/atf-check/Makefile | 1 - libexec/atf/atf-pytest-wrapper/Makefile | 1 - libexec/atf/atf-sh/Makefile | 1 - libexec/rtld-elf/tests/Makefile.inc | 1 + release/packages/ucl/atf-all.ucl | 8 ++++++++ release/packages/ucl/kyua-all.ucl | 20 ++++++++++++++++++++ release/packages/ucl/tests-all.ucl | 27 +++++++++++++++++++++++++-- share/mk/bsd.lib.mk | 11 +++++++++++ share/mk/bsd.test.mk | 3 +++ usr.bin/kyua/Makefile | 2 +- 20 files changed, 84 insertions(+), 12 deletions(-) diff --git a/UPDATING b/UPDATING index 999babfb6d7d..d40818111554 100644 --- a/UPDATING +++ b/UPDATING @@ -27,6 +27,14 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 16.x IS SLOW: world, or to merely disable the most expensive debugging functionality at runtime, run "ln -s 'abort:false,junk:false' /etc/malloc.conf".) +20250918: + Kyua has been moved to the FreeBSD-kyua package, and ATF has been moved + to the FreeBSD-atf* packages. If you have FreeBSD-tests installed, + these packages will be installed automatically, otherwise you should + manually install them if you need these tools. + + This only affects pkgbase users. + 20250912: If SRCCONF is unset and a file named src.conf is present at the top of the source tree, it will now be used instead of diff --git a/lib/atf/Makefile.inc b/lib/atf/Makefile.inc index f8f329842eb4..bebed0280596 100644 --- a/lib/atf/Makefile.inc +++ b/lib/atf/Makefile.inc @@ -24,6 +24,8 @@ # SUCH DAMAGE. # +PACKAGE= atf +LIB_PACKAGE= CFLAGS+= -DHAVE_CONFIG_H WARNS?= 3 diff --git a/lib/atf/libatf-c++/Makefile b/lib/atf/libatf-c++/Makefile index 985a79b7dc03..4f4f7f12ec05 100644 --- a/lib/atf/libatf-c++/Makefile +++ b/lib/atf/libatf-c++/Makefile @@ -27,7 +27,6 @@ .include .include -PACKAGE= tests LIB_CXX= atf-c++ PRIVATELIB= true SHLIB_MAJOR= 2 diff --git a/lib/atf/libatf-c++/tests/Makefile b/lib/atf/libatf-c++/tests/Makefile index dc052c19df67..839c6902d6b1 100644 --- a/lib/atf/libatf-c++/tests/Makefile +++ b/lib/atf/libatf-c++/tests/Makefile @@ -1,7 +1,5 @@ .include -PACKAGE= tests - TESTS_SUBDIRS= detail ATF= ${SRCTOP}/contrib/atf diff --git a/lib/atf/libatf-c/Makefile b/lib/atf/libatf-c/Makefile index 4cfee2ed824f..c0890abc7640 100644 --- a/lib/atf/libatf-c/Makefile +++ b/lib/atf/libatf-c/Makefile @@ -27,7 +27,6 @@ .include .include -PACKAGE= tests LIB= atf-c PRIVATELIB= true SHLIB_MAJOR= 1 diff --git a/lib/atf/libatf-c/tests/Makefile b/lib/atf/libatf-c/tests/Makefile index c81c18a91f00..5647e7b9fcbe 100644 --- a/lib/atf/libatf-c/tests/Makefile +++ b/lib/atf/libatf-c/tests/Makefile @@ -1,7 +1,5 @@ .include -PACKAGE= tests - TESTS_SUBDIRS= detail ATF= ${SRCTOP}/contrib/atf diff --git a/lib/libc/tests/tls/dso/Makefile b/lib/libc/tests/tls/dso/Makefile index 5efd8b29a6bd..783534ff7aae 100644 --- a/lib/libc/tests/tls/dso/Makefile +++ b/lib/libc/tests/tls/dso/Makefile @@ -6,6 +6,7 @@ SRCS= h_tls_dlopen.c MAN= PACKAGE= tests +NO_DEV_PACKAGE= LIBDIR= ${TESTSBASE}/lib/libc/tls SHLIB_MAJOR= 1 diff --git a/lib/libc/tests/tls_dso/Makefile b/lib/libc/tests/tls_dso/Makefile index 89296c643695..7cb8f98b431e 100644 --- a/lib/libc/tests/tls_dso/Makefile +++ b/lib/libc/tests/tls_dso/Makefile @@ -7,6 +7,7 @@ LIBDIR= ${TESTSBASE}/lib/libc/tls SHLIBDIR= ${TESTSBASE}/lib/libc/tls SHLIB_MAJOR= 1 PACKAGE= tests +NO_DEV_PACKAGE= WITHOUT_STATIC= WITHOUT_PROFILE= diff --git a/lib/libxo/tests/encoder/Makefile b/lib/libxo/tests/encoder/Makefile index 7522328b0818..02634b971ace 100644 --- a/lib/libxo/tests/encoder/Makefile +++ b/lib/libxo/tests/encoder/Makefile @@ -1,4 +1,5 @@ PACKAGE= tests +NO_DEV_PACKAGE= LIBXOSRC= ${SRCTOP}/contrib/libxo diff --git a/libexec/atf/Makefile.inc b/libexec/atf/Makefile.inc index 42c507a6f772..e40827fa0b69 100644 --- a/libexec/atf/Makefile.inc +++ b/libexec/atf/Makefile.inc @@ -24,6 +24,8 @@ # SUCH DAMAGE. # +PACKAGE= atf +LIB_PACKAGE= CFLAGS+= -DHAVE_CONFIG_H WARNS?= 3 diff --git a/libexec/atf/atf-check/Makefile b/libexec/atf/atf-check/Makefile index 87d7a7cfdada..cf598e384c86 100644 --- a/libexec/atf/atf-check/Makefile +++ b/libexec/atf/atf-check/Makefile @@ -30,7 +30,6 @@ ATF= ${SRCTOP}/contrib/atf .PATH: ${ATF}/atf-sh -PACKAGE= tests PROG_CXX= atf-check SRCS= atf-check.cpp MAN= atf-check.1 diff --git a/libexec/atf/atf-pytest-wrapper/Makefile b/libexec/atf/atf-pytest-wrapper/Makefile index 80b5e411ec4e..75b1bc3e1004 100644 --- a/libexec/atf/atf-pytest-wrapper/Makefile +++ b/libexec/atf/atf-pytest-wrapper/Makefile @@ -1,7 +1,6 @@ .include .include -PACKAGE= tests PROG_CXX= atf_pytest_wrapper SRCS= atf_pytest_wrapper.cpp MAN= diff --git a/libexec/atf/atf-sh/Makefile b/libexec/atf/atf-sh/Makefile index 2e821684d8a8..afd848581f36 100644 --- a/libexec/atf/atf-sh/Makefile +++ b/libexec/atf/atf-sh/Makefile @@ -30,7 +30,6 @@ ATF= ${SRCTOP}/contrib/atf .PATH: ${ATF}/atf-sh -PACKAGE= tests PROG_CXX= atf-sh SRCS= atf-sh.cpp MAN= atf-sh.1 atf-sh.3 diff --git a/libexec/rtld-elf/tests/Makefile.inc b/libexec/rtld-elf/tests/Makefile.inc index 01cf83634239..3bd0b8590cdc 100644 --- a/libexec/rtld-elf/tests/Makefile.inc +++ b/libexec/rtld-elf/tests/Makefile.inc @@ -1,2 +1,3 @@ PACKAGE?= tests +NO_DEV_PACKAGE= TESTSDIR?= ${TESTSBASE}/libexec/rtld-elf diff --git a/release/packages/ucl/atf-all.ucl b/release/packages/ucl/atf-all.ucl new file mode 100644 index 000000000000..de8cd55eeb9f --- /dev/null +++ b/release/packages/ucl/atf-all.ucl @@ -0,0 +1,8 @@ +comment = "Automated Testing Framework" + +desc = < .if ${MK_MAN} != "no" && !defined(LIBRARIES_ONLY) diff --git a/share/mk/bsd.test.mk b/share/mk/bsd.test.mk index a2e15c840e02..9f20e5835369 100644 --- a/share/mk/bsd.test.mk +++ b/share/mk/bsd.test.mk @@ -16,6 +16,9 @@ LOCALBASE?= /usr/local TESTSDIR?= ${TESTSBASE}/${RELDIR:H} PACKAGE?= tests +# Prevent creating a -dev package for tests. Sometimes tests include static +# libraries or other artifacts which are not actually "development" files. +NO_DEV_PACKAGE= FILESGROUPS+= ${PACKAGE}FILES ${PACKAGE}FILESPACKAGE= ${PACKAGE} diff --git a/usr.bin/kyua/Makefile b/usr.bin/kyua/Makefile index daefedbf8bca..178a1d083b79 100644 --- a/usr.bin/kyua/Makefile +++ b/usr.bin/kyua/Makefile @@ -10,7 +10,7 @@ KYUA_VERSION= 0.13 KYUA_SRCDIR= ${SRCTOP}/contrib/kyua .PATH: ${KYUA_SRCDIR} -PACKAGE= tests +PACKAGE= kyua PROG_CXX= kyua SRCS= main.cpp LIBADD= lutok sqlite3 util From nobody Thu Sep 18 09:26:33 2025 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 4cS9Hs2nXxz68496; Thu, 18 Sep 2025 09:26: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS9Hs20gDz3rsy; Thu, 18 Sep 2025 09:26:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758187593; 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=7/UaIzRjUohxN/lokxXpG476/zRZfSyDN6zJ0GE1yzc=; b=GBHHAJACAY0uPfygSN0f8MgtOXu2A5+xYeOKIJ+bzHYenm8C54lMNXtnM1+vmeUxi6IGEL AaEnd+w55q8Dc8tgAWnnU9Gd+9FQA7VOz+FlAv3Oxi87yyBz86tgC+VIuVbymrsl/Mg+gI XNDeNn6M8R8CtX2E8vzAPup4iKHvvg0Huru/fEJ0892B630YJrvfcy+dKLEkZ6grLdwQQV TQTkqsCO20x13jq0zSmvU+nokhl1j0yqnq9i5bA36uGXsk2msOTa3CYUSAgf1etpFPPqgV O4FYlZwrdr7myIvYMPXSLLMIxTUmmEsbH0EK8KpkoShDRgCMRT7jJry7oTNZWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758187593; 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=7/UaIzRjUohxN/lokxXpG476/zRZfSyDN6zJ0GE1yzc=; b=XEUR5WhtKXr/65OpNw3k4/gTi5m0hactemcQYEo38sAONfhHbpSuSIVF5OQl+/wKNWfxSW yIJ41SznfgGFH4tN7rlzv9U/AMTcwe4ZgEHOrFB5GhlSMt3Shx5lpNceZYD5sacYBxfV3P 92T6QXLTzSlqAVm7QmfM1jXxaFLZPCvWji1IAetDR78EzTCVjE6mP10ndQdfZsdBA5/0SJ NpjshLtnxVlmkhrwlgKCJDDjh9dB8amoKqtH2YCCysYZOCcH5PL5hSbcxnayCER11OaUtC LM01BK1fDnlmROWdN2egYXXTsSjCbBLrzUF7h0uCT4KAOmfytc14LXWwwXcI6g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758187593; a=rsa-sha256; cv=none; b=n3CEtFuBmHOr4Mn1Rujbfm2KbDb7bsuHq2Ea3lWCJHMOFntOWdGDZfWY+JQNlFaEaIrXG5 2/uLolbHPdxGj7asVtInmsyGyKi+fglJ7ySuQnv+1ZGQGZpd04ztOv5ywq+jMwZ8zLsNqv uRFNuReJMAIcXDYwBd9Sgqi/x/Imb1Aom1ZjatZYlTjeQSBgR1//4jUUZRryrHzAeQye/O Jvepi4TIAZqvdvmgV+YJyKcx4gGo1VLfTRovjGF9CSBmC/t6Xs/O+lj2WqkRa8l+C1rNMv 33KnptCAbzbKKewtfpKAHbboLPdHZqDQC+IEgB01Awyo+cdl6wc3Ie0sRCAKzg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS9Hs1TjHz14kS; Thu, 18 Sep 2025 09:26:33 +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 58I9QXpU076389; Thu, 18 Sep 2025 09:26:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I9QXXu076386; Thu, 18 Sep 2025 09:26:33 GMT (envelope-from git) Date: Thu, 18 Sep 2025 09:26:33 GMT Message-Id: <202509180926.58I9QXXu076386@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Lexi Winter Subject: git: ea5e50c2985b - main - packages: Add a mandoc package 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ea5e50c2985bea029e7b30ecee773a59fe22cd68 Auto-Submitted: auto-generated The branch main has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=ea5e50c2985bea029e7b30ecee773a59fe22cd68 commit ea5e50c2985bea029e7b30ecee773a59fe22cd68 Author: Lexi Winter AuthorDate: 2025-09-18 09:14:45 +0000 Commit: Lexi Winter CommitDate: 2025-09-18 09:26:12 +0000 packages: Add a mandoc package Move mandoc to its own package so users can install it independently of -utilities. Put the package in the minimal set, since we also ship manpages in minimal and "man" is a basic Unix utility. Add a pkg-triggers(5) hook to run makewhatis when new manpages are installed, so that apropos(1) works. This depends on a new pkg(8) feature expected to be in in the upcoming 2.3.2 release; in the mean time, this is a no-op (i.e., having an older pkg doesn't break anything, it just won't run the trigger). MFC after: 3 seconds Reviewed by: bapt Differential Revision: https://reviews.freebsd.org/D52564 --- UPDATING | 4 ++++ release/packages/ucl/mandoc-all.ucl | 11 +++++++++++ usr.bin/man/Makefile | 2 ++ usr.bin/mandoc/Makefile | 6 ++++++ usr.bin/mandoc/mandoc.ucl | 18 ++++++++++++++++++ 5 files changed, 41 insertions(+) diff --git a/UPDATING b/UPDATING index d40818111554..82ae24814e02 100644 --- a/UPDATING +++ b/UPDATING @@ -28,6 +28,10 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 16.x IS SLOW: at runtime, run "ln -s 'abort:false,junk:false' /etc/malloc.conf".) 20250918: + mandoc (including /usr/bin/man) has been moved to a new package, + FreeBSD-mandoc. If you have the minimal set installed, this package + will be installed automatically, otherwise you may want to install it. + Kyua has been moved to the FreeBSD-kyua package, and ATF has been moved to the FreeBSD-atf* packages. If you have FreeBSD-tests installed, these packages will be installed automatically, otherwise you should diff --git a/release/packages/ucl/mandoc-all.ucl b/release/packages/ucl/mandoc-all.ucl new file mode 100644 index 000000000000..9c43e9f7a46c --- /dev/null +++ b/release/packages/ucl/mandoc-all.ucl @@ -0,0 +1,11 @@ +comment = "Online manual page reader" + +desc = < To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Aymeric Wibo Subject: git: 25cddb1dfec6 - main - Revert "acpi: Fix build when `ACPI_DEBUG_OUTPUT` defined" 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: obiwac X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 25cddb1dfec6cfd874961ed08dcc9c76ec533df1 Auto-Submitted: auto-generated The branch main has been updated by obiwac: URL: https://cgit.FreeBSD.org/src/commit/?id=25cddb1dfec6cfd874961ed08dcc9c76ec533df1 commit 25cddb1dfec6cfd874961ed08dcc9c76ec533df1 Author: Aymeric Wibo AuthorDate: 2025-09-18 09:45:12 +0000 Commit: Aymeric Wibo CommitDate: 2025-09-18 09:48:55 +0000 Revert "acpi: Fix build when `ACPI_DEBUG_OUTPUT` defined" This reverts commit 4894f5ba394306a75dbed9ed4377ab0eae75aede. PR: 289634 --- sys/dev/acpica/acpi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index 175bfe835e6f..702e1ecb5340 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -3425,7 +3425,7 @@ acpi_EnterSleepState(struct acpi_softc *sc, enum power_stype stype) enum acpi_sleep_state slp_state; int sleep_result; - ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, stype); + ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, state); if (stype <= POWER_STYPE_AWAKE || stype >= POWER_STYPE_COUNT) return_ACPI_STATUS (AE_BAD_PARAMETER); @@ -3939,7 +3939,7 @@ acpi_system_eventhandler_sleep(void *arg, enum power_stype stype) struct acpi_softc *sc = (struct acpi_softc *)arg; int ret; - ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, stype); + ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, state); /* Check if button action is disabled or unknown. */ if (stype == ACPI_STATE_UNKNOWN) From nobody Thu Sep 18 09:49:58 2025 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 4cS9pv1c3Cz685y1; Thu, 18 Sep 2025 09:49:59 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS9pv0mz6z3wLW; Thu, 18 Sep 2025 09:49:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758188999; 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=j0wSKxeiIndBBDmG50Dt9DHAlTM2NF7AtU/PnhzCwe0=; b=ns0oSXdpmTKqEJDXQMNG1mmKOTHquptH3+gqkNhGOWzUb04mB0IHgxMQ2KbyS66v5wFaa6 4bdsS3wtMBBelRoQ8nUJQmlmog0cmMj+6qPskXtPNyiImKbgdd1w2Uq9juXe7K2Uhq69Qv iAb6ZPorz32TyfEhsQpyU1pNDAsByt6ZeFNDh6aGSWXFKgA8pKVMfl3cpc0QpNuDVk5Of3 sU6MAQ1dUVg4GbU7mDSRbhCpU1NXkuWvg2NOV9kzrxiqacBMfa2vdbaodlbB8lT9y/RZTY Rpmj3RtcSBRoMClvgjx+9oZiFbHfXQb4y1IBAVHPEuNtSuOnZsPk5wnR+srrlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758188999; 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=j0wSKxeiIndBBDmG50Dt9DHAlTM2NF7AtU/PnhzCwe0=; b=vA9TfkXv1DAXtEZefe3DbHV4l/phbjRvkp72chUwzvZEAf02F3A/XcqDCg7io6xsN8UTmX tSywK43jijYO/nhU2o7IRqXCAs4IZjtgubCcBFPTqtysdIQetF4X6T9Pwk7RrGobL6iDFo CzEgOLV8dMdnhtaig9WMycuweakWXzY4S5TIn9k/I5sQ1gZ1cc/JuhR9VqqYDX+muzQAOq s3NPwxo++CyYvSwld3J9QVcGGgpehWec4u+4AwQqpDBns7+FxCELUuYsq6fIuOu2euIaQD GQ9f1VQmVF6pCK8Sd0bGagx6HlTQ794O3qCKNs0LciD6YMEYBmv7PWLnOritOA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758188999; a=rsa-sha256; cv=none; b=Osxlv60+B03ckaZycD2FCMvnFlFGDuE4FEqZV50RVRbJBwke93wb6OHDbaZnnvnYI3Q82I UaIydV7OhHKQ08+gMTJN+c9TQ9ql4FOGpzk0p40UEEdPg2wvZLHi3FRePRAVXs4thCp8+c auWZz9tCss9XRLfY1LRAsQzoso8RyLXlUj+Jymt9HwFkD6ARphCondy/XaRy9ULgHvUuDm y4HCQkR4vOkHEOaSNQC/7IrxDAAX6o/zXWvRid9k+iiQGClo8IVFjZm2B77IJdotXaVieh voCpOM+U2A1JCR65nS9H10odcuks7wXKhQupsUOB7WuE4czloE9J21Az1bw9bg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS9pv04JPz15vx; Thu, 18 Sep 2025 09:49:59 +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 58I9nwAD017079; Thu, 18 Sep 2025 09:49:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I9nwwU017076; Thu, 18 Sep 2025 09:49:58 GMT (envelope-from git) Date: Thu, 18 Sep 2025 09:49:58 GMT Message-Id: <202509180949.58I9nwwU017076@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Aymeric Wibo Subject: git: 87e2b532ec9e - main - Revert "sys/power: Sleep type reporting by PM backends" 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: obiwac X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 87e2b532ec9e9504ac743931ffae528679a1f4c0 Auto-Submitted: auto-generated The branch main has been updated by obiwac: URL: https://cgit.FreeBSD.org/src/commit/?id=87e2b532ec9e9504ac743931ffae528679a1f4c0 commit 87e2b532ec9e9504ac743931ffae528679a1f4c0 Author: Aymeric Wibo AuthorDate: 2025-09-18 09:45:27 +0000 Commit: Aymeric Wibo CommitDate: 2025-09-18 09:49:17 +0000 Revert "sys/power: Sleep type reporting by PM backends" This reverts commit e779891327b1d9b9ab10ba482e59f498790505a7. PR: 289634 --- sys/dev/acpica/acpi.c | 6 ++---- sys/kern/subr_power.c | 46 +++++----------------------------------------- sys/sys/power.h | 3 +-- 3 files changed, 8 insertions(+), 47 deletions(-) diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index 702e1ecb5340..8dd879a573cc 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -734,8 +734,7 @@ acpi_attach(device_t dev) goto out; /* Register ACPI again to pass the correct argument of pm_func. */ - power_pm_register(POWER_PM_TYPE_ACPI, acpi_pm_func, sc, - acpi_supported_stypes); + power_pm_register(POWER_PM_TYPE_ACPI, acpi_pm_func, sc); acpi_platform_osc(dev); @@ -4777,8 +4776,7 @@ acpi_pm_register(void *arg) if (!cold || resource_disabled("acpi", 0)) return; - power_pm_register(POWER_PM_TYPE_ACPI, acpi_pm_func, NULL, - acpi_supported_stypes); + power_pm_register(POWER_PM_TYPE_ACPI, acpi_pm_func, NULL); } SYSINIT(power, SI_SUB_KLD, SI_ORDER_ANY, acpi_pm_register, NULL); diff --git a/sys/kern/subr_power.c b/sys/kern/subr_power.c index 44ad82860649..eb5bd03f5018 100644 --- a/sys/kern/subr_power.c +++ b/sys/kern/subr_power.c @@ -39,14 +39,13 @@ #include #include -enum power_stype power_standby_stype = POWER_STYPE_UNKNOWN; -enum power_stype power_suspend_stype = POWER_STYPE_UNKNOWN; -enum power_stype power_hibernate_stype = POWER_STYPE_UNKNOWN; +enum power_stype power_standby_stype = POWER_STYPE_STANDBY; +enum power_stype power_suspend_stype = POWER_STYPE_SUSPEND_TO_IDLE; +enum power_stype power_hibernate_stype = POWER_STYPE_HIBERNATE; static u_int power_pm_type = POWER_PM_TYPE_NONE; static power_pm_fn_t power_pm_fn = NULL; static void *power_pm_arg = NULL; -static bool power_pm_supported[POWER_STYPE_COUNT] = {0}; static struct task power_pm_task; enum power_stype @@ -71,26 +70,6 @@ power_stype_to_name(enum power_stype stype) return (power_stype_names[stype]); } -static int -sysctl_supported_stypes(SYSCTL_HANDLER_ARGS) -{ - int error; - struct sbuf sb; - enum power_stype stype; - - sbuf_new(&sb, NULL, 32, SBUF_AUTOEXTEND); - for (stype = 0; stype < POWER_STYPE_COUNT; stype++) { - if (power_pm_supported[stype]) - sbuf_printf(&sb, "%s ", power_stype_to_name(stype)); - } - sbuf_trim(&sb); - sbuf_finish(&sb); - error = sysctl_handle_string(oidp, sbuf_data(&sb), sbuf_len(&sb), req); - sbuf_delete(&sb); - - return (error); -} - static int power_sysctl_stype(SYSCTL_HANDLER_ARGS) { @@ -107,8 +86,7 @@ power_sysctl_stype(SYSCTL_HANDLER_ARGS) new_stype = power_name_to_stype(name); if (new_stype == POWER_STYPE_UNKNOWN) return (EINVAL); - if (!power_pm_supported[new_stype]) - return (EOPNOTSUPP); + /* TODO Check to see if the new stype is supported. */ if (new_stype != old_stype) *(enum power_stype *)oidp->oid_arg1 = new_stype; return (0); @@ -117,9 +95,6 @@ power_sysctl_stype(SYSCTL_HANDLER_ARGS) static SYSCTL_NODE(_kern, OID_AUTO, power, CTLFLAG_RW, 0, "Generic power management related sysctls"); -SYSCTL_PROC(_kern_power, OID_AUTO, supported_stype, - CTLTYPE_STRING | CTLFLAG_RD, 0, 0, sysctl_supported_stypes, "A", - "List supported sleep types"); SYSCTL_PROC(_kern_power, OID_AUTO, standby, CTLTYPE_STRING | CTLFLAG_RW, &power_standby_stype, 0, power_sysctl_stype, "A", "Sleep type to enter on standby"); @@ -139,8 +114,7 @@ power_pm_deferred_fn(void *arg, int pending) } int -power_pm_register(u_int pm_type, power_pm_fn_t pm_fn, void *pm_arg, - bool pm_supported[static POWER_STYPE_COUNT]) +power_pm_register(u_int pm_type, power_pm_fn_t pm_fn, void *pm_arg) { int error; @@ -149,16 +123,6 @@ power_pm_register(u_int pm_type, power_pm_fn_t pm_fn, void *pm_arg, power_pm_type = pm_type; power_pm_fn = pm_fn; power_pm_arg = pm_arg; - memcpy(power_pm_supported, pm_supported, - sizeof(power_pm_supported)); - if (power_pm_supported[POWER_STYPE_STANDBY]) - power_standby_stype = POWER_STYPE_STANDBY; - if (power_pm_supported[POWER_STYPE_SUSPEND_TO_IDLE]) - power_suspend_stype = POWER_STYPE_SUSPEND_TO_IDLE; - else if (power_pm_supported[POWER_STYPE_SUSPEND_TO_MEM]) - power_suspend_stype = POWER_STYPE_SUSPEND_TO_MEM; - if (power_pm_supported[POWER_STYPE_HIBERNATE]) - power_hibernate_stype = POWER_STYPE_HIBERNATE; error = 0; TASK_INIT(&power_pm_task, 0, power_pm_deferred_fn, NULL); } else { diff --git a/sys/sys/power.h b/sys/sys/power.h index 33ace400bfd2..44d7fc354423 100644 --- a/sys/sys/power.h +++ b/sys/sys/power.h @@ -91,8 +91,7 @@ extern const char *power_stype_to_name(enum power_stype _stype); typedef int (*power_pm_fn_t)(u_long _cmd, void* _arg, enum power_stype _stype); extern int power_pm_register(u_int _pm_type, power_pm_fn_t _pm_fn, - void *_pm_arg, - bool _pm_supported[static POWER_STYPE_COUNT]); + void *_pm_arg); extern u_int power_pm_get_type(void); extern void power_pm_suspend(int); From nobody Thu Sep 18 09:50:00 2025 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 4cS9pw5NjJz685y4; Thu, 18 Sep 2025 09:50:00 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cS9pw1bhjz3wLp; Thu, 18 Sep 2025 09:50:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189000; 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=auxZHv5FlXACza9MEPOfvqupJofLGudVWLhMworndbg=; b=hURBNjMxiyir0U6AZefCEyrBBhUlGu7oVAekvFM0vH9MxRXZHgRm2pHUbW+Iar2FaAkGuF vxaSvqKaWTSmZ1C/of8c/wUO6rXAC1ewb/DLmkVL2mI6uwsNsk568sIw0o75/yCoxxFoaP f4v2kWCUPamjxH1FvbgdB4j8nofHU6XvEKaE+P/62MiXLjAqAy32S7c1C8D9NI5ZpDUx6/ p8bjnVvZ//9pyiNDR1dwBwdvLqDKNiuRyGScOL+tT/yCUYQ3k60zWrBrWNlhJ97bf715aL 7TRKnz/u9MniRktKl7WZyYkx0Uqs28MNIsYjiRBoe1RDVoTEHJiXXxhEBYlJ/g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189000; 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=auxZHv5FlXACza9MEPOfvqupJofLGudVWLhMworndbg=; b=qx7F2wWp1xr6mvFymDaEQOMrkZ9JzvNvG5grDBaUbCrKnfeSSSYA8I7h+F1uvF6lwtMgMf eZMYyZdZ56xtVPrrB4BQUTd2EWtZR/HmzG/heVPpdWC/p8t7Vpu5HHWirGyhNJXVweWBEg FK5MD/PBmme+Y04JSUbMcY1MoYQcfW+TwXNqa4RG+WNQky9/7OTzaG+GrNQLTqV/zzV5Hy YdU7MJMD0/4ohKaU7eg8YKBdgbyPCZmVuz4qYRTz47hFNwaP2WChCxoFsjE9ROBp/uwHYH 77zTjpOAgprv2YeS6ryE5u/My5SP7F6S9aqipD5xQ/L5fSkwe8B6bqqf16qiQQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758189000; a=rsa-sha256; cv=none; b=xQRkggC9+jBxAL3AP/Tb1I9n8OPoy3j+REecQj1lJ7OJ35ya3brB033CXTgzBMzYn/I0Wo JmJMJyfAnuBHauSHHeprHAcFpAYMRF3lcKtmrVm308Jy4wY5uEmaJgGLZrYPatioAhF35h u8i5uckIkwk1XrqNiN9XM7xqDbwU5n5fZutw5BKRVSzIEik9TKrwe3vripGG0YTsLLb4N/ zOtVv/4Z5wmZM2YlawLyDgowbBHWbbQVbmehYPg2YnsIDvZiUtL9gokLSvZPOLxyEvp3Iw q+OMxLfV+wZgA8frhkWVsh5REvd86Vn2PIROAmH08Xli/cPqsZgprSWdBIyE7w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cS9pw0q8qz157Q; Thu, 18 Sep 2025 09:50:00 +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 58I9o0mb017140; Thu, 18 Sep 2025 09:50:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I9o0rE017137; Thu, 18 Sep 2025 09:50:00 GMT (envelope-from git) Date: Thu, 18 Sep 2025 09:50:00 GMT Message-Id: <202509180950.58I9o0rE017137@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Aymeric Wibo Subject: git: 506b36c4fdde - main - Revert "acpi: Use sleep types defined in sys/power.h" 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: obiwac X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 506b36c4fdde0b402cc730b41a9d9d20130e1bca Auto-Submitted: auto-generated The branch main has been updated by obiwac: URL: https://cgit.FreeBSD.org/src/commit/?id=506b36c4fdde0b402cc730b41a9d9d20130e1bca commit 506b36c4fdde0b402cc730b41a9d9d20130e1bca Author: Aymeric Wibo AuthorDate: 2025-09-18 09:45:36 +0000 Commit: Aymeric Wibo CommitDate: 2025-09-18 09:49:31 +0000 Revert "acpi: Use sleep types defined in sys/power.h" This reverts commit ce5e22b28ef6caff3ffd228ac188114b08c0da02. PR: 289634 --- sys/dev/acpica/acpi.c | 368 +++++++++++++++++----------------------------- sys/dev/acpica/acpi_lid.c | 4 +- sys/dev/acpica/acpivar.h | 15 +- sys/x86/acpica/acpi_apm.c | 25 ++-- 4 files changed, 158 insertions(+), 254 deletions(-) diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index 8dd879a573cc..574d3aacbcde 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -111,9 +111,8 @@ struct callout acpi_sleep_timer; /* Bitmap of device quirks. */ int acpi_quirks; -/* Supported sleep states and types. */ -static bool acpi_supported_stypes[POWER_STYPE_COUNT]; -static bool acpi_supported_sstates[ACPI_S_STATE_COUNT]; +/* Supported sleep states. */ +static BOOLEAN acpi_sleep_states[ACPI_S_STATE_COUNT]; static void acpi_lookup(void *arg, const char *name, device_t *dev); static int acpi_modevent(struct module *mod, int event, void *junk); @@ -170,27 +169,21 @@ static ACPI_STATUS acpi_probe_child(ACPI_HANDLE handle, UINT32 level, void *context, void **status); static void acpi_sleep_enable(void *arg); static ACPI_STATUS acpi_sleep_disable(struct acpi_softc *sc); -static ACPI_STATUS acpi_EnterSleepState(struct acpi_softc *sc, - enum power_stype stype); +static ACPI_STATUS acpi_EnterSleepState(struct acpi_softc *sc, int state); static void acpi_shutdown_final(void *arg, int howto); static void acpi_enable_fixed_events(struct acpi_softc *sc); static void acpi_resync_clock(struct acpi_softc *sc); -static int acpi_wake_sleep_prep(ACPI_HANDLE handle, - enum power_stype stype); -static int acpi_wake_run_prep(ACPI_HANDLE handle, enum power_stype stype); -static int acpi_wake_prep_walk(enum power_stype stype); +static int acpi_wake_sleep_prep(ACPI_HANDLE handle, int sstate); +static int acpi_wake_run_prep(ACPI_HANDLE handle, int sstate); +static int acpi_wake_prep_walk(int sstate); static int acpi_wake_sysctl_walk(device_t dev); static int acpi_wake_set_sysctl(SYSCTL_HANDLER_ARGS); +static void acpi_system_eventhandler_sleep(void *arg, int state); +static void acpi_system_eventhandler_wakeup(void *arg, int state); +static int acpi_sname2sstate(const char *sname); +static const char *acpi_sstate2sname(int sstate); static int acpi_supported_sleep_state_sysctl(SYSCTL_HANDLER_ARGS); -static void acpi_system_eventhandler_sleep(void *arg, - enum power_stype stype); -static void acpi_system_eventhandler_wakeup(void *arg, - enum power_stype stype); -static enum power_stype acpi_sstate_to_stype(int sstate); -static int acpi_sname_to_sstate(const char *sname); -static const char *acpi_sstate_to_sname(int sstate); static int acpi_sleep_state_sysctl(SYSCTL_HANDLER_ARGS); -static int acpi_stype_sysctl(SYSCTL_HANDLER_ARGS); static int acpi_debug_objects_sysctl(SYSCTL_HANDLER_ARGS); static int acpi_stype_to_sstate(struct acpi_softc *sc, enum power_stype stype); static int acpi_pm_func(u_long cmd, void *arg, enum power_stype stype); @@ -484,7 +477,6 @@ acpi_attach(device_t dev) UINT32 flags; UINT8 TypeA, TypeB; char *env; - enum power_stype stype; ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); @@ -597,30 +589,31 @@ acpi_attach(device_t dev) SYSCTL_ADD_PROC(&sc->acpi_sysctl_ctx, SYSCTL_CHILDREN(sc->acpi_sysctl_tree), OID_AUTO, "power_button_state", CTLTYPE_STRING | CTLFLAG_RW | CTLFLAG_MPSAFE, - &sc->acpi_power_button_stype, 0, acpi_stype_sysctl, "A", + &sc->acpi_power_button_sx, 0, acpi_sleep_state_sysctl, "A", "Power button ACPI sleep state."); SYSCTL_ADD_PROC(&sc->acpi_sysctl_ctx, SYSCTL_CHILDREN(sc->acpi_sysctl_tree), OID_AUTO, "sleep_button_state", CTLTYPE_STRING | CTLFLAG_RW | CTLFLAG_MPSAFE, - &sc->acpi_sleep_button_stype, 0, acpi_stype_sysctl, "A", + &sc->acpi_sleep_button_sx, 0, acpi_sleep_state_sysctl, "A", "Sleep button ACPI sleep state."); SYSCTL_ADD_PROC(&sc->acpi_sysctl_ctx, SYSCTL_CHILDREN(sc->acpi_sysctl_tree), OID_AUTO, "lid_switch_state", CTLTYPE_STRING | CTLFLAG_RW | CTLFLAG_MPSAFE, - &sc->acpi_lid_switch_stype, 0, acpi_stype_sysctl, "A", - "Lid ACPI sleep state. Set to s2idle or s2mem if you want to suspend " - "your laptop when close the lid."); + &sc->acpi_lid_switch_sx, 0, acpi_sleep_state_sysctl, "A", + "Lid ACPI sleep state. Set to S3 if you want to suspend your laptop when close the Lid."); SYSCTL_ADD_PROC(&sc->acpi_sysctl_ctx, SYSCTL_CHILDREN(sc->acpi_sysctl_tree), OID_AUTO, "standby_state", CTLTYPE_STRING | CTLFLAG_RW | CTLFLAG_MPSAFE, - &sc->acpi_standby_sx, 0, acpi_sleep_state_sysctl, "A", - "ACPI Sx state to use when going standby (S1 or S2)."); + &sc->acpi_standby_sx, 0, acpi_sleep_state_sysctl, "A", ""); + SYSCTL_ADD_PROC(&sc->acpi_sysctl_ctx, SYSCTL_CHILDREN(sc->acpi_sysctl_tree), + OID_AUTO, "suspend_state", + CTLTYPE_STRING | CTLFLAG_RW | CTLFLAG_MPSAFE, + &sc->acpi_suspend_sx, 0, acpi_sleep_state_sysctl, "A", ""); SYSCTL_ADD_INT(&sc->acpi_sysctl_ctx, SYSCTL_CHILDREN(sc->acpi_sysctl_tree), OID_AUTO, "sleep_delay", CTLFLAG_RW, &sc->acpi_sleep_delay, 0, "sleep delay in seconds"); SYSCTL_ADD_INT(&sc->acpi_sysctl_ctx, SYSCTL_CHILDREN(sc->acpi_sysctl_tree), - OID_AUTO, "s4bios", CTLFLAG_RW, &sc->acpi_s4bios, 0, - "Use S4BIOS when hibernating."); + OID_AUTO, "s4bios", CTLFLAG_RW, &sc->acpi_s4bios, 0, "S4BIOS mode"); SYSCTL_ADD_INT(&sc->acpi_sysctl_ctx, SYSCTL_CHILDREN(sc->acpi_sysctl_tree), OID_AUTO, "verbose", CTLFLAG_RW, &sc->acpi_verbose, 0, "verbose mode"); SYSCTL_ADD_INT(&sc->acpi_sysctl_ctx, SYSCTL_CHILDREN(sc->acpi_sysctl_tree), @@ -666,38 +659,31 @@ acpi_attach(device_t dev) sc->acpi_s4bios = 1; #endif - /* - * Probe all supported ACPI sleep states. Awake (S0) is always supported. - */ - acpi_supported_sstates[ACPI_STATE_S0] = TRUE; - acpi_supported_stypes[POWER_STYPE_AWAKE] = true; - for (state = ACPI_STATE_S1; state <= ACPI_STATE_S5; state++) + /* Probe all supported sleep states. */ + acpi_sleep_states[ACPI_STATE_S0] = TRUE; + for (state = ACPI_STATE_S1; state < ACPI_S_STATE_COUNT; state++) if (ACPI_SUCCESS(AcpiEvaluateObject(ACPI_ROOT_OBJECT, __DECONST(char *, AcpiGbl_SleepStateNames[state]), NULL, NULL)) && - ACPI_SUCCESS(AcpiGetSleepTypeData(state, &TypeA, &TypeB))) { - acpi_supported_sstates[state] = TRUE; - acpi_supported_stypes[acpi_sstate_to_stype(state)] = true; - } + ACPI_SUCCESS(AcpiGetSleepTypeData(state, &TypeA, &TypeB))) + acpi_sleep_states[state] = TRUE; /* - * Dispatch the default sleep type to devices. The lid switch is set + * Dispatch the default sleep state to devices. The lid switch is set * to UNKNOWN by default to avoid surprising users. */ - sc->acpi_power_button_stype = acpi_supported_stypes[POWER_STYPE_POWEROFF] ? - POWER_STYPE_POWEROFF : POWER_STYPE_UNKNOWN; - sc->acpi_lid_switch_stype = POWER_STYPE_UNKNOWN; - - sc->acpi_standby_sx = ACPI_STATE_UNKNOWN; - if (acpi_supported_sstates[ACPI_STATE_S1]) - sc->acpi_standby_sx = ACPI_STATE_S1; - else if (acpi_supported_sstates[ACPI_STATE_S2]) - sc->acpi_standby_sx = ACPI_STATE_S2; - - /* Pick the first valid sleep type for the sleep button default. */ - sc->acpi_sleep_button_stype = POWER_STYPE_UNKNOWN; - for (stype = POWER_STYPE_STANDBY; stype <= POWER_STYPE_HIBERNATE; stype++) - if (acpi_supported_stypes[stype]) { - sc->acpi_sleep_button_stype = stype; + sc->acpi_power_button_sx = acpi_sleep_states[ACPI_STATE_S5] ? + ACPI_STATE_S5 : ACPI_STATE_UNKNOWN; + sc->acpi_lid_switch_sx = ACPI_STATE_UNKNOWN; + sc->acpi_standby_sx = acpi_sleep_states[ACPI_STATE_S1] ? + ACPI_STATE_S1 : ACPI_STATE_UNKNOWN; + sc->acpi_suspend_sx = acpi_sleep_states[ACPI_STATE_S3] ? + ACPI_STATE_S3 : ACPI_STATE_UNKNOWN; + + /* Pick the first valid sleep state for the sleep button default. */ + sc->acpi_sleep_button_sx = ACPI_STATE_UNKNOWN; + for (state = ACPI_STATE_S1; state <= ACPI_STATE_S4; state++) + if (acpi_sleep_states[state]) { + sc->acpi_sleep_button_sx = state; break; } @@ -722,7 +708,7 @@ acpi_attach(device_t dev) /* Flag our initial states. */ sc->acpi_enabled = TRUE; - sc->acpi_stype = POWER_STYPE_AWAKE; + sc->acpi_sstate = ACPI_STATE_S0; sc->acpi_sleep_disabled = TRUE; /* Create the control device */ @@ -782,36 +768,6 @@ acpi_stype_to_sstate(struct acpi_softc *sc, enum power_stype stype) return (ACPI_STATE_UNKNOWN); } -/* - * XXX It would be nice if we didn't need this function, but we'd need - * acpi_EnterSleepState and acpi_ReqSleepState to take in actual ACPI S-states, - * which won't be possible at the moment because suspend-to-idle (which is not - * an ACPI S-state nor maps to one) will be implemented here. - * - * In the future, we should make generic a lot of the logic in these functions - * to enable suspend-to-idle on non-ACPI builds, and then make - * acpi_EnterSleepState and acpi_ReqSleepState truly take in ACPI S-states - * again. - */ -static enum power_stype -acpi_sstate_to_stype(int sstate) -{ - switch (sstate) { - case ACPI_STATE_S0: - return (POWER_STYPE_AWAKE); - case ACPI_STATE_S1: - case ACPI_STATE_S2: - return (POWER_STYPE_STANDBY); - case ACPI_STATE_S3: - return (POWER_STYPE_SUSPEND_TO_MEM); - case ACPI_STATE_S4: - return (POWER_STYPE_HIBERNATE); - case ACPI_STATE_S5: - return (POWER_STYPE_POWEROFF); - } - return (POWER_STYPE_UNKNOWN); -} - static void acpi_set_power_children(device_t dev, int state) { @@ -2107,7 +2063,7 @@ acpi_device_pwr_for_sleep(device_t bus, device_t dev, int *dstate) * Note illegal _S0D is evaluated because some systems expect this. */ sc = device_get_softc(bus); - snprintf(sxd, sizeof(sxd), "_S%dD", acpi_stype_to_sstate(sc, sc->acpi_stype)); + snprintf(sxd, sizeof(sxd), "_S%dD", sc->acpi_sstate); status = acpi_GetInteger(handle, sxd, dstate); if (ACPI_FAILURE(status) && status != AE_NOT_FOUND) { device_printf(dev, "failed to get %s on %s: %s\n", sxd, @@ -3205,9 +3161,9 @@ acpi_sleep_force_task(void *context) { struct acpi_softc *sc = (struct acpi_softc *)context; - if (ACPI_FAILURE(acpi_EnterSleepState(sc, sc->acpi_next_stype))) - device_printf(sc->acpi_dev, "force sleep state %s failed\n", - power_stype_to_name(sc->acpi_next_stype)); + if (ACPI_FAILURE(acpi_EnterSleepState(sc, sc->acpi_next_sstate))) + device_printf(sc->acpi_dev, "force sleep state S%d failed\n", + sc->acpi_next_sstate); } static void @@ -3234,24 +3190,24 @@ acpi_sleep_force(void *arg) * acks are in. */ int -acpi_ReqSleepState(struct acpi_softc *sc, enum power_stype stype) +acpi_ReqSleepState(struct acpi_softc *sc, int state) { #if defined(__amd64__) || defined(__i386__) struct apm_clone_data *clone; ACPI_STATUS status; - if (stype < POWER_STYPE_AWAKE || stype >= POWER_STYPE_COUNT) + if (state < ACPI_STATE_S1 || state > ACPI_S_STATES_MAX) return (EINVAL); - if (!acpi_supported_stypes[stype]) + if (!acpi_sleep_states[state]) return (EOPNOTSUPP); /* * If a reboot/shutdown/suspend request is already in progress or * suspend is blocked due to an upcoming shutdown, just return. */ - if (rebooting || sc->acpi_next_stype != POWER_STYPE_AWAKE || - suspend_blocked) + if (rebooting || sc->acpi_next_sstate != 0 || suspend_blocked) { return (0); + } /* Wait until sleep is enabled. */ while (sc->acpi_sleep_disabled) { @@ -3260,12 +3216,12 @@ acpi_ReqSleepState(struct acpi_softc *sc, enum power_stype stype) ACPI_LOCK(acpi); - sc->acpi_next_stype = stype; + sc->acpi_next_sstate = state; /* S5 (soft-off) should be entered directly with no waiting. */ - if (stype == POWER_STYPE_POWEROFF) { + if (state == ACPI_STATE_S5) { ACPI_UNLOCK(acpi); - status = acpi_EnterSleepState(sc, stype); + status = acpi_EnterSleepState(sc, state); return (ACPI_SUCCESS(status) ? 0 : ENXIO); } @@ -3281,7 +3237,7 @@ acpi_ReqSleepState(struct acpi_softc *sc, enum power_stype stype) /* If devd(8) is not running, immediately enter the sleep state. */ if (!devctl_process_running()) { ACPI_UNLOCK(acpi); - status = acpi_EnterSleepState(sc, stype); + status = acpi_EnterSleepState(sc, state); return (ACPI_SUCCESS(status) ? 0 : ENXIO); } @@ -3296,7 +3252,7 @@ acpi_ReqSleepState(struct acpi_softc *sc, enum power_stype stype) ACPI_UNLOCK(acpi); /* Now notify devd(8) also. */ - acpi_UserNotify("Suspend", ACPI_ROOT_OBJECT, stype); + acpi_UserNotify("Suspend", ACPI_ROOT_OBJECT, state); return (0); #else @@ -3319,17 +3275,17 @@ acpi_AckSleepState(struct apm_clone_data *clone, int error) struct acpi_softc *sc; int ret, sleeping; - /* If no pending sleep type, return an error. */ + /* If no pending sleep state, return an error. */ ACPI_LOCK(acpi); sc = clone->acpi_sc; - if (sc->acpi_next_stype == POWER_STYPE_AWAKE) { + if (sc->acpi_next_sstate == 0) { ACPI_UNLOCK(acpi); return (ENXIO); } /* Caller wants to abort suspend process. */ if (error) { - sc->acpi_next_stype = POWER_STYPE_AWAKE; + sc->acpi_next_sstate = 0; callout_stop(&sc->susp_force_to); device_printf(sc->acpi_dev, "listener on %s cancelled the pending suspend\n", @@ -3359,7 +3315,7 @@ acpi_AckSleepState(struct apm_clone_data *clone, int error) ACPI_UNLOCK(acpi); ret = 0; if (sleeping) { - if (ACPI_FAILURE(acpi_EnterSleepState(sc, sc->acpi_next_stype))) + if (ACPI_FAILURE(acpi_EnterSleepState(sc, sc->acpi_next_sstate))) ret = ENODEV; } return (ret); @@ -3416,7 +3372,7 @@ enum acpi_sleep_state { * Currently we support S1-S5 but S4 is only S4BIOS */ static ACPI_STATUS -acpi_EnterSleepState(struct acpi_softc *sc, enum power_stype stype) +acpi_EnterSleepState(struct acpi_softc *sc, int state) { register_t intr; ACPI_STATUS status; @@ -3426,11 +3382,11 @@ acpi_EnterSleepState(struct acpi_softc *sc, enum power_stype stype) ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, state); - if (stype <= POWER_STYPE_AWAKE || stype >= POWER_STYPE_COUNT) + if (state < ACPI_STATE_S1 || state > ACPI_S_STATES_MAX) return_ACPI_STATUS (AE_BAD_PARAMETER); - if (!acpi_supported_stypes[stype]) { - device_printf(sc->acpi_dev, "Sleep type %s not supported on this " - "platform\n", power_stype_to_name(stype)); + if (!acpi_sleep_states[state]) { + device_printf(sc->acpi_dev, "Sleep state S%d not supported by BIOS\n", + state); return (AE_SUPPORT); } @@ -3442,7 +3398,7 @@ acpi_EnterSleepState(struct acpi_softc *sc, enum power_stype stype) return (status); } - if (stype == POWER_STYPE_POWEROFF) { + if (state == ACPI_STATE_S5) { /* * Shut down cleanly and power off. This will call us back through the * shutdown handlers. @@ -3470,16 +3426,16 @@ acpi_EnterSleepState(struct acpi_softc *sc, enum power_stype stype) #endif /* - * Be sure to hold bus topology lock across DEVICE_SUSPEND/RESUME. + * Be sure to hold Giant across DEVICE_SUSPEND/RESUME */ bus_topo_lock(); slp_state = ACPI_SS_NONE; - sc->acpi_stype = stype; + sc->acpi_sstate = state; /* Enable any GPEs as appropriate and requested by the user. */ - acpi_wake_prep_walk(stype); + acpi_wake_prep_walk(state); slp_state = ACPI_SS_GPE_SET; /* @@ -3496,7 +3452,7 @@ acpi_EnterSleepState(struct acpi_softc *sc, enum power_stype stype) } slp_state = ACPI_SS_DEV_SUSPEND; - status = AcpiEnterSleepStatePrep(stype); + status = AcpiEnterSleepStatePrep(state); if (ACPI_FAILURE(status)) { device_printf(sc->acpi_dev, "AcpiEnterSleepStatePrep failed - %s\n", AcpiFormatException(status)); @@ -3509,9 +3465,9 @@ acpi_EnterSleepState(struct acpi_softc *sc, enum power_stype stype) suspendclock(); intr = intr_disable(); - if (stype != POWER_STYPE_STANDBY) { - sleep_result = acpi_sleep_machdep(sc, stype); - acpi_wakeup_machdep(sc, stype, sleep_result, 0); + if (state != ACPI_STATE_S1) { + sleep_result = acpi_sleep_machdep(sc, state); + acpi_wakeup_machdep(sc, state, sleep_result, 0); /* * XXX According to ACPI specification SCI_EN bit should be restored @@ -3522,10 +3478,10 @@ acpi_EnterSleepState(struct acpi_softc *sc, enum power_stype stype) * This hack is picked up from Linux, which claims that it follows * Windows behavior. */ - if (sleep_result == 1 && stype != POWER_STYPE_HIBERNATE) + if (sleep_result == 1 && state != ACPI_STATE_S4) AcpiWriteBitRegister(ACPI_BITREG_SCI_ENABLE, ACPI_ENABLE_EVENT); - if (sleep_result == 1 && stype == POWER_STYPE_SUSPEND_TO_MEM) { + if (sleep_result == 1 && state == ACPI_STATE_S3) { /* * Prevent mis-interpretation of the wakeup by power button * as a request for power off. @@ -3551,20 +3507,20 @@ acpi_EnterSleepState(struct acpi_softc *sc, enum power_stype stype) intr_restore(intr); /* call acpi_wakeup_machdep() again with interrupt enabled */ - acpi_wakeup_machdep(sc, stype, sleep_result, 1); + acpi_wakeup_machdep(sc, state, sleep_result, 1); - AcpiLeaveSleepStatePrep(stype); + AcpiLeaveSleepStatePrep(state); if (sleep_result == -1) goto backout; - /* Re-enable ACPI hardware on wakeup from hibernate. */ - if (stype == POWER_STYPE_HIBERNATE) + /* Re-enable ACPI hardware on wakeup from sleep state 4. */ + if (state == ACPI_STATE_S4) AcpiEnable(); } else { - status = AcpiEnterSleepState(stype); + status = AcpiEnterSleepState(state); intr_restore(intr); - AcpiLeaveSleepStatePrep(stype); + AcpiLeaveSleepStatePrep(state); if (ACPI_FAILURE(status)) { device_printf(sc->acpi_dev, "AcpiEnterSleepState failed - %s\n", AcpiFormatException(status)); @@ -3581,13 +3537,13 @@ backout: if (slp_state >= ACPI_SS_SLP_PREP) resumeclock(); if (slp_state >= ACPI_SS_GPE_SET) { - acpi_wake_prep_walk(stype); - sc->acpi_stype = POWER_STYPE_AWAKE; + acpi_wake_prep_walk(state); + sc->acpi_sstate = ACPI_STATE_S0; } if (slp_state >= ACPI_SS_DEV_SUSPEND) DEVICE_RESUME(root_bus); if (slp_state >= ACPI_SS_SLP_PREP) - AcpiLeaveSleepState(stype); + AcpiLeaveSleepState(state); if (slp_state >= ACPI_SS_SLEPT) { #if defined(__i386__) || defined(__amd64__) /* NB: we are still using ACPI timecounter at this point. */ @@ -3596,7 +3552,7 @@ backout: acpi_resync_clock(sc); acpi_enable_fixed_events(sc); } - sc->acpi_next_stype = POWER_STYPE_AWAKE; + sc->acpi_next_sstate = 0; bus_topo_unlock(); @@ -3622,7 +3578,7 @@ backout: /* Run /etc/rc.resume after we are back. */ if (devctl_process_running()) - acpi_UserNotify("Resume", ACPI_ROOT_OBJECT, stype); + acpi_UserNotify("Resume", ACPI_ROOT_OBJECT, state); return_ACPI_STATUS (status); } @@ -3673,21 +3629,16 @@ acpi_wake_set_enable(device_t dev, int enable) } static int -acpi_wake_sleep_prep(ACPI_HANDLE handle, enum power_stype stype) +acpi_wake_sleep_prep(ACPI_HANDLE handle, int sstate) { - int sstate; struct acpi_prw_data prw; device_t dev; - struct acpi_softc *sc; /* Check that this is a wake-capable device and get its GPE. */ if (acpi_parse_prw(handle, &prw) != 0) return (ENXIO); dev = acpi_get_device(handle); - sc = device_get_softc(dev); - sstate = acpi_stype_to_sstate(sc, stype); - /* * The destination sleep state must be less than (i.e., higher power) * or equal to the value specified by _PRW. If this GPE cannot be @@ -3698,26 +3649,24 @@ acpi_wake_sleep_prep(ACPI_HANDLE handle, enum power_stype stype) if (sstate > prw.lowest_wake) { AcpiSetGpeWakeMask(prw.gpe_handle, prw.gpe_bit, ACPI_GPE_DISABLE); if (bootverbose) - device_printf(dev, "wake_prep disabled wake for %s (%s)\n", - acpi_name(handle), power_stype_to_name(stype)); + device_printf(dev, "wake_prep disabled wake for %s (S%d)\n", + acpi_name(handle), sstate); } else if (dev && (acpi_get_flags(dev) & ACPI_FLAG_WAKE_ENABLED) != 0) { acpi_pwr_wake_enable(handle, 1); acpi_SetInteger(handle, "_PSW", 1); if (bootverbose) - device_printf(dev, "wake_prep enabled for %s (%s)\n", - acpi_name(handle), power_stype_to_name(stype)); + device_printf(dev, "wake_prep enabled for %s (S%d)\n", + acpi_name(handle), sstate); } return (0); } static int -acpi_wake_run_prep(ACPI_HANDLE handle, enum power_stype stype) +acpi_wake_run_prep(ACPI_HANDLE handle, int sstate) { - int sstate; struct acpi_prw_data prw; device_t dev; - struct acpi_softc *sc; /* * Check that this is a wake-capable device and get its GPE. Return @@ -3729,9 +3678,6 @@ acpi_wake_run_prep(ACPI_HANDLE handle, enum power_stype stype) if (dev == NULL || (acpi_get_flags(dev) & ACPI_FLAG_WAKE_ENABLED) == 0) return (0); - sc = device_get_softc(dev); - sstate = acpi_stype_to_sstate(sc, stype); - /* * If this GPE couldn't be enabled for the previous sleep state, it was * disabled before going to sleep so re-enable it. If it was enabled, @@ -3755,26 +3701,26 @@ acpi_wake_run_prep(ACPI_HANDLE handle, enum power_stype stype) static ACPI_STATUS acpi_wake_prep(ACPI_HANDLE handle, UINT32 level, void *context, void **status) { - enum power_stype stype; + int sstate; /* If suspending, run the sleep prep function, otherwise wake. */ - stype = *(enum power_stype *)context; + sstate = *(int *)context; if (AcpiGbl_SystemAwakeAndRunning) - acpi_wake_sleep_prep(handle, stype); + acpi_wake_sleep_prep(handle, sstate); else - acpi_wake_run_prep(handle, stype); + acpi_wake_run_prep(handle, sstate); return (AE_OK); } /* Walk the tree rooted at acpi0 to prep devices for suspend/resume. */ static int -acpi_wake_prep_walk(enum power_stype stype) +acpi_wake_prep_walk(int sstate) { ACPI_HANDLE sb_handle; if (ACPI_SUCCESS(AcpiGetHandle(ACPI_ROOT_OBJECT, "\\_SB_", &sb_handle))) AcpiWalkNamespace(ACPI_TYPE_DEVICE, sb_handle, 100, - acpi_wake_prep, NULL, &stype, NULL); + acpi_wake_prep, NULL, &sstate, NULL); return (0); } @@ -3933,7 +3879,7 @@ out: /* System Event Handlers (registered by EVENTHANDLER_REGISTER) */ static void -acpi_system_eventhandler_sleep(void *arg, enum power_stype stype) +acpi_system_eventhandler_sleep(void *arg, int state) { struct acpi_softc *sc = (struct acpi_softc *)arg; int ret; @@ -3941,27 +3887,23 @@ acpi_system_eventhandler_sleep(void *arg, enum power_stype stype) ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, state); /* Check if button action is disabled or unknown. */ - if (stype == ACPI_STATE_UNKNOWN) + if (state == ACPI_STATE_UNKNOWN) return; - /* - * Request that the system prepare to enter the given suspend state. We can - * totally pass an ACPI S-state to an enum power_stype. - */ - ret = acpi_ReqSleepState(sc, stype); + /* Request that the system prepare to enter the given suspend state. */ + ret = acpi_ReqSleepState(sc, state); if (ret != 0) device_printf(sc->acpi_dev, - "request to enter state %s failed (err %d)\n", - power_stype_to_name(stype), ret); + "request to enter state S%d failed (err %d)\n", state, ret); return_VOID; } static void -acpi_system_eventhandler_wakeup(void *arg, enum power_stype stype) +acpi_system_eventhandler_wakeup(void *arg, int state) { - ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, stype); + ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, state); /* Currently, nothing to do for wakeup. */ @@ -3975,14 +3917,14 @@ static void acpi_invoke_sleep_eventhandler(void *context) { - EVENTHANDLER_INVOKE(acpi_sleep_event, *(enum power_stype *)context); + EVENTHANDLER_INVOKE(acpi_sleep_event, *(int *)context); } static void acpi_invoke_wake_eventhandler(void *context) { - EVENTHANDLER_INVOKE(acpi_wakeup_event, *(enum power_stype *)context); + EVENTHANDLER_INVOKE(acpi_wakeup_event, *(int *)context); } UINT32 @@ -3998,7 +3940,7 @@ acpi_event_power_button_sleep(void *context) #if defined(__amd64__) || defined(__i386__) if (ACPI_FAILURE(AcpiOsExecute(OSL_NOTIFY_HANDLER, - acpi_invoke_sleep_eventhandler, &sc->acpi_power_button_stype))) + acpi_invoke_sleep_eventhandler, &sc->acpi_power_button_sx))) return_VALUE (ACPI_INTERRUPT_NOT_HANDLED); #else shutdown_nice(RB_POWEROFF); @@ -4015,7 +3957,7 @@ acpi_event_power_button_wake(void *context) ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); if (ACPI_FAILURE(AcpiOsExecute(OSL_NOTIFY_HANDLER, - acpi_invoke_wake_eventhandler, &sc->acpi_power_button_stype))) + acpi_invoke_wake_eventhandler, &sc->acpi_power_button_sx))) return_VALUE (ACPI_INTERRUPT_NOT_HANDLED); return_VALUE (ACPI_INTERRUPT_HANDLED); } @@ -4028,7 +3970,7 @@ acpi_event_sleep_button_sleep(void *context) ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); if (ACPI_FAILURE(AcpiOsExecute(OSL_NOTIFY_HANDLER, - acpi_invoke_sleep_eventhandler, &sc->acpi_sleep_button_stype))) + acpi_invoke_sleep_eventhandler, &sc->acpi_sleep_button_sx))) return_VALUE (ACPI_INTERRUPT_NOT_HANDLED); return_VALUE (ACPI_INTERRUPT_HANDLED); } @@ -4041,7 +3983,7 @@ acpi_event_sleep_button_wake(void *context) ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); if (ACPI_FAILURE(AcpiOsExecute(OSL_NOTIFY_HANDLER, - acpi_invoke_wake_eventhandler, &sc->acpi_sleep_button_stype))) + acpi_invoke_wake_eventhandler, &sc->acpi_sleep_button_sx))) return_VALUE (ACPI_INTERRUPT_NOT_HANDLED); return_VALUE (ACPI_INTERRUPT_HANDLED); } @@ -4237,8 +4179,7 @@ acpiioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flag, struct thread *t { struct acpi_softc *sc; struct acpi_ioctl_hook *hp; - int error; - int sstate; + int error, state; error = 0; hp = NULL; @@ -4268,9 +4209,9 @@ acpiioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flag, struct thread *t /* Core system ioctls. */ switch (cmd) { case ACPIIO_REQSLPSTATE: - sstate = *(int *)addr; - if (sstate != ACPI_STATE_S5) - return (acpi_ReqSleepState(sc, acpi_sstate_to_stype(sstate))); + state = *(int *)addr; + if (state != ACPI_STATE_S5) + return (acpi_ReqSleepState(sc, state)); device_printf(sc->acpi_dev, "power off via acpi ioctl not supported\n"); error = EOPNOTSUPP; break; @@ -4279,12 +4220,12 @@ acpiioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flag, struct thread *t error = acpi_AckSleepState(sc->acpi_clone, error); break; case ACPIIO_SETSLPSTATE: /* DEPRECATED */ - sstate = *(int *)addr; - if (sstate < ACPI_STATE_S0 || sstate > ACPI_STATE_S5) + state = *(int *)addr; + if (state < ACPI_STATE_S0 || state > ACPI_S_STATES_MAX) return (EINVAL); - if (!acpi_supported_sstates[sstate]) + if (!acpi_sleep_states[state]) return (EOPNOTSUPP); - if (ACPI_FAILURE(acpi_SetSleepState(sc, acpi_sstate_to_stype(sstate)))) + if (ACPI_FAILURE(acpi_SetSleepState(sc, state))) error = ENXIO; break; default: @@ -4296,7 +4237,7 @@ acpiioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flag, struct thread *t } static int -acpi_sname_to_sstate(const char *sname) +acpi_sname2sstate(const char *sname) { int sstate; @@ -4311,15 +4252,14 @@ acpi_sname_to_sstate(const char *sname) } static const char * -acpi_sstate_to_sname(int state) +acpi_sstate2sname(int sstate) { - static const char *snames[ACPI_S_STATE_COUNT] = {"S0", "S1", "S2", "S3", - "S4", "S5"}; + static const char *snames[] = { "S0", "S1", "S2", "S3", "S4", "S5" }; - if (state == ACPI_STATE_UNKNOWN) + if (sstate >= ACPI_STATE_S0 && sstate <= ACPI_STATE_S5) + return (snames[sstate]); + else if (sstate == ACPI_STATE_UNKNOWN) return ("NONE"); - if (state >= ACPI_STATE_S0 && state < ACPI_S_STATE_COUNT) - return (snames[state]); return (NULL); } @@ -4332,8 +4272,8 @@ acpi_supported_sleep_state_sysctl(SYSCTL_HANDLER_ARGS) sbuf_new(&sb, NULL, 32, SBUF_AUTOEXTEND); for (state = ACPI_STATE_S1; state < ACPI_S_STATE_COUNT; state++) - if (acpi_supported_sstates[state]) - sbuf_printf(&sb, "%s ", acpi_sstate_to_sname(state)); + if (acpi_sleep_states[state]) + sbuf_printf(&sb, "%s ", acpi_sstate2sname(state)); sbuf_trim(&sb); sbuf_finish(&sb); error = sysctl_handle_string(oidp, sbuf_data(&sb), sbuf_len(&sb), req); @@ -4341,64 +4281,27 @@ acpi_supported_sleep_state_sysctl(SYSCTL_HANDLER_ARGS) return (error); } - static int acpi_sleep_state_sysctl(SYSCTL_HANDLER_ARGS) { char sleep_state[10]; - int error; - int new_sstate, old_sstate; + int error, new_state, old_state; - old_sstate = *(int *)oidp->oid_arg1; - strlcpy(sleep_state, acpi_sstate_to_sname(old_sstate), sizeof(sleep_state)); + old_state = *(int *)oidp->oid_arg1; + strlcpy(sleep_state, acpi_sstate2sname(old_state), sizeof(sleep_state)); error = sysctl_handle_string(oidp, sleep_state, sizeof(sleep_state), req); if (error == 0 && req->newptr != NULL) { - new_sstate = acpi_sname_to_sstate(sleep_state); - if (new_sstate < 0) + new_state = acpi_sname2sstate(sleep_state); + if (new_state < ACPI_STATE_S1) return (EINVAL); - if (new_sstate < ACPI_S_STATE_COUNT && - !acpi_supported_sstates[new_sstate]) + if (new_state < ACPI_S_STATE_COUNT && !acpi_sleep_states[new_state]) return (EOPNOTSUPP); - if (new_sstate != old_sstate) - *(int *)oidp->oid_arg1 = new_sstate; + if (new_state != old_state) + *(int *)oidp->oid_arg1 = new_state; } return (error); } -static int -acpi_stype_sysctl(SYSCTL_HANDLER_ARGS) -{ - char name[10]; - int err; - int sstate; - enum power_stype new_stype, old_stype; - - old_stype = *(enum power_stype *)oidp->oid_arg1; - strlcpy(name, power_stype_to_name(old_stype), sizeof(name)); - err = sysctl_handle_string(oidp, name, sizeof(name), req); - if (err != 0 || req->newptr == NULL) - return (err); - - new_stype = power_name_to_stype(name); - if (new_stype == POWER_STYPE_UNKNOWN) { - sstate = acpi_sname_to_sstate(name); - if (sstate < 0) - return (EINVAL); - printf("warning: this sysctl expects a sleep type, but an ACPI S-state has " - "been passed to it. This functionality is deprecated; see acpi(4).\n"); - MPASS(sstate < ACPI_S_STATE_COUNT); - if (acpi_supported_sstates[sstate] == false) - return (EOPNOTSUPP); - new_stype = acpi_sstate_to_stype(sstate); - } - - if (acpi_supported_stypes[new_stype] == false) - return (EOPNOTSUPP); - if (new_stype != old_stype) - *(enum power_stype *)oidp->oid_arg1 = new_stype; - return (0); -} - /* Inform devctl(4) when we receive a Notify. */ void acpi_UserNotify(const char *subsystem, ACPI_HANDLE h, uint8_t notify) @@ -4747,7 +4650,7 @@ acpi_reset_interfaces(device_t dev) static int acpi_pm_func(u_long cmd, void *arg, enum power_stype stype) { - int error; + int error, sstate; struct acpi_softc *sc; error = 0; @@ -4758,7 +4661,8 @@ acpi_pm_func(u_long cmd, void *arg, enum power_stype stype) error = EINVAL; goto out; } - if (ACPI_FAILURE(acpi_EnterSleepState(sc, stype))) + sstate = acpi_stype_to_sstate(sc, stype); + if (ACPI_FAILURE(acpi_EnterSleepState(sc, sstate))) error = ENXIO; break; default: diff --git a/sys/dev/acpica/acpi_lid.c b/sys/dev/acpica/acpi_lid.c index fb8755d9f0fe..142791f7282a 100644 --- a/sys/dev/acpica/acpi_lid.c +++ b/sys/dev/acpica/acpi_lid.c @@ -235,9 +235,9 @@ acpi_lid_notify_status_changed(void *arg) sc->lid_status ? "opened" : "closed"); if (sc->lid_status == 0) - EVENTHANDLER_INVOKE(acpi_sleep_event, acpi_sc->acpi_lid_switch_stype); + EVENTHANDLER_INVOKE(acpi_sleep_event, acpi_sc->acpi_lid_switch_sx); else - EVENTHANDLER_INVOKE(acpi_wakeup_event, acpi_sc->acpi_lid_switch_stype); + EVENTHANDLER_INVOKE(acpi_wakeup_event, acpi_sc->acpi_lid_switch_sx); out: ACPI_SERIAL_END(lid); diff --git a/sys/dev/acpica/acpivar.h b/sys/dev/acpica/acpivar.h index 4c789dd3e9f2..fac32d832598 100644 --- a/sys/dev/acpica/acpivar.h +++ b/sys/dev/acpica/acpivar.h @@ -54,19 +54,20 @@ struct acpi_softc { struct cdev *acpi_dev_t; int acpi_enabled; - enum power_stype acpi_stype; + int acpi_sstate; int acpi_sleep_disabled; struct sysctl_ctx_list acpi_sysctl_ctx; struct sysctl_oid *acpi_sysctl_tree; - enum power_stype acpi_power_button_stype; - enum power_stype acpi_sleep_button_stype; - enum power_stype acpi_lid_switch_stype; + int acpi_power_button_sx; + int acpi_sleep_button_sx; + int acpi_lid_switch_sx; int acpi_standby_sx; - int acpi_s4bios; + int acpi_suspend_sx; int acpi_sleep_delay; + int acpi_s4bios; int acpi_do_disable; int acpi_verbose; int acpi_handle_reboot; @@ -74,7 +75,7 @@ struct acpi_softc { vm_offset_t acpi_wakeaddr; vm_paddr_t acpi_wakephys; - enum power_stype acpi_next_stype; /* Next suspend sleep type. */ + int acpi_next_sstate; /* Next suspend Sx state. */ struct apm_clone_data *acpi_clone; /* Pseudo-dev for devd(8). */ STAILQ_HEAD(,apm_clone_data) apm_cdevs; /* All apm/apmctl/acpi cdevs. */ struct callout susp_force_to; /* Force suspend if no acks. */ @@ -411,7 +412,7 @@ ACPI_STATUS acpi_EvaluateOSC(ACPI_HANDLE handle, uint8_t *uuid, uint32_t *caps_out, bool query); ACPI_STATUS acpi_OverrideInterruptLevel(UINT32 InterruptNumber); ACPI_STATUS acpi_SetIntrModel(int model); -int acpi_ReqSleepState(struct acpi_softc *sc, enum power_stype stype); +int acpi_ReqSleepState(struct acpi_softc *sc, int state); int acpi_AckSleepState(struct apm_clone_data *clone, int error); ACPI_STATUS acpi_SetSleepState(struct acpi_softc *sc, int state); int acpi_wake_set_enable(device_t dev, int enable); diff --git a/sys/x86/acpica/acpi_apm.c b/sys/x86/acpica/acpi_apm.c index 8e5785cf0ed6..be161cd6171b 100644 --- a/sys/x86/acpica/acpi_apm.c +++ b/sys/x86/acpica/acpi_apm.c @@ -235,7 +235,7 @@ apmdtor(void *data) acpi_sc = clone->acpi_sc; /* We are about to lose a reference so check if suspend should occur */ - if (acpi_sc->acpi_next_stype != POWER_STYPE_AWAKE && + if (acpi_sc->acpi_next_sstate != 0 && clone->notify_status != APM_EV_ACKED) acpi_AckSleepState(clone, 0); @@ -283,10 +283,10 @@ apmioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flag, struct thread *td case APMIO_SUSPEND: if ((flag & FWRITE) == 0) return (EPERM); - if (acpi_sc->acpi_next_stype == POWER_STYPE_AWAKE) { - if (power_suspend_stype != POWER_STYPE_POWEROFF) { + if (acpi_sc->acpi_next_sstate == 0) { + if (acpi_sc->acpi_suspend_sx != ACPI_STATE_S5) { error = acpi_ReqSleepState(acpi_sc, - power_suspend_stype); + acpi_sc->acpi_suspend_sx); } else { printf( "power off via apm suspend not supported\n"); @@ -298,10 +298,10 @@ apmioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flag, struct thread *td case APMIO_STANDBY: if ((flag & FWRITE) == 0) return (EPERM); - if (acpi_sc->acpi_next_stype == POWER_STYPE_AWAKE) { - if (power_standby_stype != POWER_STYPE_POWEROFF) { + if (acpi_sc->acpi_next_sstate == 0) { + if (acpi_sc->acpi_standby_sx != ACPI_STATE_S5) { error = acpi_ReqSleepState(acpi_sc, - power_standby_stype); + acpi_sc->acpi_standby_sx); } else { printf( "power off via apm standby not supported\n"); @@ -313,11 +313,10 @@ apmioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flag, struct thread *td case APMIO_NEXTEVENT: printf("apm nextevent start\n"); ACPI_LOCK(acpi); - if (acpi_sc->acpi_next_stype != POWER_STYPE_AWAKE && - clone->notify_status == APM_EV_NONE) { + if (acpi_sc->acpi_next_sstate != 0 && clone->notify_status == + APM_EV_NONE) { ev_info = (struct apm_event_info *)addr; - /* XXX Check this. */ - if (acpi_sc->acpi_next_stype == POWER_STYPE_STANDBY) + if (acpi_sc->acpi_next_sstate <= ACPI_STATE_S3) ev_info->type = PMEV_STANDBYREQ; else ev_info->type = PMEV_SUSPENDREQ; @@ -393,7 +392,7 @@ apmpoll(struct cdev *dev, int events, struct thread *td) revents = 0; devfs_get_cdevpriv((void **)&clone); ACPI_LOCK(acpi); - if (clone->acpi_sc->acpi_next_stype != POWER_STYPE_AWAKE) *** 13 LINES SKIPPED *** From nobody Thu Sep 18 09:58:12 2025 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 4cSB0P2bPVz686bw; Thu, 18 Sep 2025 09:58:13 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSB0P1t0Nz40nW; Thu, 18 Sep 2025 09:58:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189493; 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=j1TL1uGhAyAjCGufOJRNpclzq8m9AFCgXyhoZkWjfrQ=; b=Z7sEuJzZ44ks2SLlNjFJ0U8GZgFZRnjw1OgVt4EAZzgrWfzkm2YfUNETq3YVwVfWdVfsCp ydQBqoUSLAIZegqF4TIoRyLea195s6jKnAyhvJJClg+v3m7IpbQE7O8FNvins0CU7oLzhW Y23eFRfKSJ1x89wWbuxhm4ONeelScU4RPMtQhGTv7phyWzCh2oZyt4iT1+mKf8YTCTTlNh Z5b20GA3PGVudsK66g5sQCc5J5LoVFS1rvcNC2NUGgGva/OCxTAQGPcu6snODueY3XYrS5 ix4zv0VWABzBa/gqn936Vm0CMzie6Y5NUgMkMvZOIW+lHe24/m1jpM2m6I+wgw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189493; 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=j1TL1uGhAyAjCGufOJRNpclzq8m9AFCgXyhoZkWjfrQ=; b=cuftgcXuvo33ialU2XTajy6fM/Xphpz9rWg7KaTkzpPIm1kQ4a/+Nu90ZAiNuZBihn62H8 Xv3VqpvjsAnFHZXE/YxNU2thpKCZzHb6HpWu13RSZy/6oe9MpQNnoW6MeiJk908cT5Y0oP JqDubtsgwMJ9qAdRjQaKu0T1eG+63wvP8zagZXUFdM7d84o0wwnsfGokjJP14RNirYJuN4 FGk32Je3GcJb+1yR3EGBgydWv8TGQJNlS3CaKx5Elm8p9hv/sDEdD+5mqjfJBrqno24cFD eBk1YOTJb90YeF9hoTO8C+bnbNaugp9g9w8iI8gOMh5niwNZuP32A38E9Ry1cw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758189493; a=rsa-sha256; cv=none; b=RqmyDcGUGcRFmm+Q17ThTW9rjhSSOzmx2m0v/SQfIjtiI6EWQIpuhupQiPffJNSx8+sBnG XQteAmzPNtB1/H7nwSZTVtWrKLFdQyyysq5/whGYnvmm1ELQZ+GP5iKik5xHqRQZVPLt60 EcXfHDWLc4otBLk3cO1XfzE6XaCT9FgdmAfMGzPqVD9nLzADxaBZBbHZm+Q4NRt3c0x+9A g0Ni1wY2YafKBhCnrX+BOv08dc8RWI2jofGkmmzW0eTQY1OQHRSfqKRmf5ylv8bSLsYKmO 0JEp+/7tUDI6SbXWqMoseg7+7kE5C/9Giw3migJW0hxQSKfIs2JyEkXHgVaKtA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSB0P0ytwz160R; Thu, 18 Sep 2025 09:58:13 +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 58I9wCEq034778; Thu, 18 Sep 2025 09:58:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I9wCan034775; Thu, 18 Sep 2025 09:58:12 GMT (envelope-from git) Date: Thu, 18 Sep 2025 09:58:12 GMT Message-Id: <202509180958.58I9wCan034775@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: 8813774cebc9 - stable/15 - ng_hci: Cast NG_HCI_BDADDR_ANY to const bdaddr_t * 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 8813774cebc975d7c031beb9b162007bde959f3c Auto-Submitted: auto-generated The branch stable/15 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=8813774cebc975d7c031beb9b162007bde959f3c commit 8813774cebc975d7c031beb9b162007bde959f3c Author: Christos Margiolis AuthorDate: 2025-09-15 13:09:42 +0000 Commit: Christos Margiolis CommitDate: 2025-09-18 09:57:07 +0000 ng_hci: Cast NG_HCI_BDADDR_ANY to const bdaddr_t * This is needed to address some compiler errors cleanly, where consumer functions want this address to be a const pointer. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D52310 (cherry picked from commit 680f9acc3657efcea07d8ac0954645b6eaf8dac8) --- sys/netgraph/bluetooth/include/ng_hci.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netgraph/bluetooth/include/ng_hci.h b/sys/netgraph/bluetooth/include/ng_hci.h index 44a14e62f4ed..ce3291770740 100644 --- a/sys/netgraph/bluetooth/include/ng_hci.h +++ b/sys/netgraph/bluetooth/include/ng_hci.h @@ -448,7 +448,7 @@ typedef struct { typedef bdaddr_t * bdaddr_p; /* Any BD_ADDR. Note: This is actually 7 bytes (count '\0' terminator) */ -#define NG_HCI_BDADDR_ANY ((bdaddr_p) "\000\000\000\000\000\000") +#define NG_HCI_BDADDR_ANY (&(const bdaddr_t){"\000\000\000\000\000\000"}) /* HCI status return parameter */ typedef struct { From nobody Thu Sep 18 09:58:14 2025 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 4cSB0Q3XdTz686WW; Thu, 18 Sep 2025 09:58:14 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSB0Q1fcXz4106; Thu, 18 Sep 2025 09:58:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189494; 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=zSNRakvx30xOz/ZJoKprIjs8zgKBFgfAvkNExCbHiMc=; b=ah7OCKc6zxpouFiunOub4eL+GdSjlBS7eH0OTYClPVWH7pIrey+ZFrGV7kGHXK0oKXAs7g T9Z+Cvp+cFco2iE5bVy5i/NNnqGAJXliMgtUrmsTb47oUzELYElTRfS5thIFGQIjLe4tDf dkGVWPSI+1vcuyKVTb/bj8DoWB3GbkO6mi7HiXfBGJ7oiJmi8f8o+R85Jyrdm5+nriHE9+ iKRxjEMdfMnXBzIVvJjsI8XQL4FNyIlQVZtPUcynLXqPsSVkpya2mWJ+sZBxISCRDAq3NG YK0gmSAiBWmXQkfOvF2r9l6j9VNXoui+KFeqEUlvr68DSK8u0EFLYYKnlY4P8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189494; 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=zSNRakvx30xOz/ZJoKprIjs8zgKBFgfAvkNExCbHiMc=; b=WV/8Bhv1jnpqalWR6eEo+4N83nYPb1UPFEeef1iRug63d56cZEXg4DSXWh9c0FgUb/oVp9 p6dszwrIDHHQOxVkWvolpHRwBJ3v3l8p3uYA3ifvJ+/cFX+BrYyohu9GCQ2SmACTCqF/bK QmfmvpJwyjsAb6RzwZ9X/XgvWBqfgRqBzeAH0jdBIvoTu2zCii/uEygPbZKC6Qe77RyXIu uA0LAj+r95JkTWlJ1ZGigLSOxD8kw8abNbKyC6MFWRbnr875iRn534x8JBKC0aebN+KfNi HKVrWdM4IFpKy0LstQAE+IT5doCDEItrsIYCXMquis2DsSdfSUIvZtyeJyG0aQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758189494; a=rsa-sha256; cv=none; b=ZndZS0ium20LksgLyOWm6UxgjKHmZMX9U1jtnKSEqgyAXphjlrpRbWk8ecJrE281Egfpwr dy2FWKUDnBLcVfSdSWhyMCYRLCEWJKHEVl4n6vlVzM0tsgfsWoS87p9W8X8DpkPpwpsOuY ib2odOO3xI6rQDKhee7God9nvCKg4q72Q2exbo4UlHMb2l3Rm6gZC8hnESOlDVPT4eQrSY gBXi/S1MsTEmQCQ0R2EE5d3sLFOUb04+hHREkUgScb/4JkRdmQvFvm7wNDyiWUnrw2AKm7 zCI4/VM9r/n5DHsM5B790e/GOCWhIxHcvAwM/D1OGO08yiDo3zoXXChNhtrDVw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSB0Q16lKz164W; Thu, 18 Sep 2025 09:58:14 +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 58I9wELB034810; Thu, 18 Sep 2025 09:58:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I9wEk6034807; Thu, 18 Sep 2025 09:58:14 GMT (envelope-from git) Date: Thu, 18 Sep 2025 09:58:14 GMT Message-Id: <202509180958.58I9wEk6034807@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: 3ed893431075 - stable/15 - ng_btsocket_rfcomm: Mark a couple buffers as const in a helper function 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 3ed89343107518daeebdbe1d5a554d59ac9c958e Auto-Submitted: auto-generated The branch stable/15 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=3ed89343107518daeebdbe1d5a554d59ac9c958e commit 3ed89343107518daeebdbe1d5a554d59ac9c958e Author: Mark Johnston AuthorDate: 2025-09-15 13:57:19 +0000 Commit: Christos Margiolis CommitDate: 2025-09-18 09:57:07 +0000 ng_btsocket_rfcomm: Mark a couple buffers as const in a helper function Fixes: 680f9acc3657 ("ng_hci: Cast NG_HCI_BDADDR_ANY to const bdaddr_t *") (cherry picked from commit 18fd3f8ec5c50da21515757af24421a078a4a468) --- sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c b/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c index 6c0a6fda1fb1..73a0897857b2 100644 --- a/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c +++ b/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c @@ -113,7 +113,7 @@ static void ng_btsocket_rfcomm_connect_cfm static int ng_btsocket_rfcomm_session_create (ng_btsocket_rfcomm_session_p *sp, struct socket *l2so, - bdaddr_p src, bdaddr_p dst, struct thread *td); + const bdaddr_t *src, const bdaddr_t *dst, struct thread *td); static int ng_btsocket_rfcomm_session_accept (ng_btsocket_rfcomm_session_p s0); static int ng_btsocket_rfcomm_session_connect @@ -1250,7 +1250,7 @@ ng_btsocket_rfcomm_connect_cfm(ng_btsocket_rfcomm_session_p s) static int ng_btsocket_rfcomm_session_create(ng_btsocket_rfcomm_session_p *sp, - struct socket *l2so, bdaddr_p src, bdaddr_p dst, + struct socket *l2so, const bdaddr_t *src, const bdaddr_t *dst, struct thread *td) { ng_btsocket_rfcomm_session_p s = NULL; From nobody Thu Sep 18 09:58:15 2025 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 4cSB0R57dhz686Sk; Thu, 18 Sep 2025 09:58:15 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSB0R2Ddyz40r5; Thu, 18 Sep 2025 09:58:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189495; 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=BUyqw1clfKXIbO7+dPA7YAMd8h/og+cNA1/mCP5mLk0=; b=dM9LXXlOHgRi9RUatXglNAPE41gvo/GYy/gca0vnmR3ffi6l75CN/XaSKNhr3zcSVcUVFw 8U4SnkYk3LHmXdQ+XObtS3l+FodavnkNq106IQnrlq0sa3z5CHuHis4prRBPR7wx9cb8CM 1zss5Qghp51Ri4qGKnbb04fFbZ68WxPzMUCD0hqJaUy2ll9Pt/A+UHUU58l6th5lZjdyr/ yFzjsNNdOpRL2rhfACgsXlmI6fDGf7wzM8Xb3P/pkYPoe6vzHd0Vos2TOqiFIwCo2Dt7c0 gtJAEi796m+tXtWOWT0CZPJOHAKlT8B2qqdw364P4sasDBFERZuGxUki+Xw+rQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189495; 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=BUyqw1clfKXIbO7+dPA7YAMd8h/og+cNA1/mCP5mLk0=; b=AYGRN/wK1P4xFbvaS58r4I0TalshbjVz8CR92CtS8jmz8sD4OPJ5ZVjsBC3WvkcY+3tA+A Ov1sMbE82py6v+HaOTQyM+8qfVwcGJJJ9gwlG/00pegcblAfoLNJK0k214U0VJ0f58euXj MmaI6813pPuNAgXl6wvg5akKrb38c41f3T+hHiHcETgil0VjFtGmQ39DoV0sxlwRMWcqw7 W3G9mKmktiAdRtSwbFEo0iDvZ3vA1a1T4wpvOvOFaWG5rK1l5htbGAlH5kFeEY/t97yuLV wyVWCDLjkdJYdj3RourFeviqWiReGUsnC5A0R/Li7TFZQx52U7BUVomwgKbkXQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758189495; a=rsa-sha256; cv=none; b=ImqwSNbZbholJMguoVvogDJGrxhGqPunNqt4px0S5hZB/bhWQB28R/dlMP2opCnVGDaGfd fF46uhS3AQnb96FkR8RGdz9iZFocyiXQus7pTu15wMMw3U6hb/GrfYHfPLr/VqUL3nLK0D SafAuK+n8SGiS9HwpYmy87dKbkz1VUNWt1vsT6KGcOgFFdth1oJiP6/iMmXkcknOG1Bozr cSNHeWvWz/JPmJuXwv/nUO1AdNWedk8YEdjcDElvN+/tOeZ31HUswK1MPyAL87HP/t/5iI 0EtGpNxWBmMYMViN6p6Wim6M9K/NRUpZzN/h4OrOCQRCUtxqX+NzdyGHAvv/FA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSB0R1p7nz164X; Thu, 18 Sep 2025 09:58:15 +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 58I9wFYu034842; Thu, 18 Sep 2025 09:58:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I9wFuC034839; Thu, 18 Sep 2025 09:58:15 GMT (envelope-from git) Date: Thu, 18 Sep 2025 09:58:15 GMT Message-Id: <202509180958.58I9wFuC034839@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: 3501e2597e9e - stable/15 - sdp(3): Change bdaddr parameter type in sdp_register_service() 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 3501e2597e9e241b57832941912452c48df05e56 Auto-Submitted: auto-generated The branch stable/15 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=3501e2597e9e241b57832941912452c48df05e56 commit 3501e2597e9e241b57832941912452c48df05e56 Author: Christos Margiolis AuthorDate: 2025-09-17 14:12:03 +0000 Commit: Christos Margiolis CommitDate: 2025-09-18 09:57:22 +0000 sdp(3): Change bdaddr parameter type in sdp_register_service() Fixes compiler error when the caller passes a const bdaddr_t * paramemeter (e.g., NG_HCI_BDADDR_ANY). Sponsored by: The FreeBSD Foundation MFC after: 1 day Reviewed by: markj, emaste Differential Revision: https://reviews.freebsd.org/D52582 (cherry picked from commit 3d14cc82d7a8c11cd164a6ba668d20b939c576fe) --- lib/libsdp/sdp.3 | 4 ++-- lib/libsdp/sdp.h | 2 +- lib/libsdp/service.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/libsdp/sdp.3 b/lib/libsdp/sdp.3 index dcd9077798ea..015f9cd8fb44 100644 --- a/lib/libsdp/sdp.3 +++ b/lib/libsdp/sdp.3 @@ -24,7 +24,7 @@ .\" .\" $Id: sdp.3,v 1.1 2003/09/07 20:34:19 max Exp $ .\" -.Dd April 30, 2018 +.Dd September 16, 2025 .Dt SDP 3 .Os .Sh NAME @@ -87,7 +87,7 @@ .Fn sdp_uuid2desc "uint16_t uuid" .Ft int32_t .Fo sdp_register_service -.Fa "void *xss" "uint16_t uuid" "bdaddr_p const bdaddr" "uint8_t const *data" +.Fa "void *xss" "uint16_t uuid" "const bdaddr_t *bdaddr" "uint8_t const *data" .Fa "uint32_t datalen" "uint32_t *handle" .Fc .Ft int32_t diff --git a/lib/libsdp/sdp.h b/lib/libsdp/sdp.h index faad36aefca6..0c9474a70eff 100644 --- a/lib/libsdp/sdp.h +++ b/lib/libsdp/sdp.h @@ -702,7 +702,7 @@ typedef struct sdp_panu_profile sdp_panu_profile_t; typedef struct sdp_panu_profile * sdp_panu_profile_p; int32_t sdp_register_service (void *xss, uint16_t uuid, - bdaddr_p const bdaddr, uint8_t const *data, + const bdaddr_t *bdaddr, uint8_t const *data, uint32_t datalen, uint32_t *handle); int32_t sdp_unregister_service (void *xss, uint32_t handle); int32_t sdp_change_service (void *xss, uint32_t handle, diff --git a/lib/libsdp/service.c b/lib/libsdp/service.c index 9f07d1ba86ba..2cce6c133600 100644 --- a/lib/libsdp/service.c +++ b/lib/libsdp/service.c @@ -45,7 +45,7 @@ static int32_t sdp_receive_error_pdu(sdp_session_p ss); int32_t -sdp_register_service(void *xss, uint16_t uuid, bdaddr_p const bdaddr, +sdp_register_service(void *xss, uint16_t uuid, const bdaddr_t *bdaddr, uint8_t const *data, uint32_t datalen, uint32_t *handle) { sdp_session_p ss = (sdp_session_p) xss; From nobody Thu Sep 18 09:59:12 2025 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 4cSB1Y0twGz686Yj; Thu, 18 Sep 2025 09:59:13 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSB1Y09zyz41X4; Thu, 18 Sep 2025 09:59:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189553; 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=8lAjHDfrWpzhkSYm6e8f5VeAexmxUVHwI33M+Z7uUOo=; b=ADkeGSEfMAIDLZqz7R25M1EMH1cOjZVvUpjvrVNDUUbW3ubarY/QdqyTj7EnC7c9Y6R9Xo 1mGtnJyvZO50r29FOI6my9R8Ofh8E3boox8nNrcnis9N+ZHO+64ffliA8x8QcO+xttP1S9 x6GR5v58Vh6+FsTFC0SAjC1LuR78YNWfYdAQ9aoYIPDBHwA3nFjG2HA+rOvvn7mZr9u1Ug KFrfWqjX0zFS9kNaUzGnpdXhnu8M2UsxvSmCdJ3ymo/tHSfmkYA8ghNEhwurYF5RLIhVBh BY3zrXMg9nu2v4z30+KojxjQaqezncn12KKo6AS/L7gevsbHYhwOCMIBMApjVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189553; 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=8lAjHDfrWpzhkSYm6e8f5VeAexmxUVHwI33M+Z7uUOo=; b=fvyXyjkt3U/GXuv518slNMfxHpzpe0Ntzl0tB1Q2phpQUacMzbJ9nM+8hVqfDdj5NNt5iv lJmeU9TiL3a3YVx7PVbl1pREHC1rIRnnA/S6WpuIJhttbaPDfBmSdz3/bXbMcrZtI0Epkv C/k0L3X+xSBA5Bt8S4i/ZDaRUkRDExcQ6tTLws7JGWnojG0Ly2le4KBn21N0zgEg6Av6HX 2T95lk+1Cx/Z61D4fiA42QeYZ5vrq4z4UrfF8IIiX9eJY+ZX7uMOM/4LlUR5h/veqEHddi RN9ryTnAwdXZHDx6unTp87vUmxs+2y8y4WqIBeyUBGdDm7d9+gOkv0rR/aK3aQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758189553; a=rsa-sha256; cv=none; b=cl9Ikq5RYxxZSwx/i/78YkNl1hg+QcW3lz/ZwHgf5Os6grIGL6Y0WTHQONKsnWsmrnMjsP uX7pRfY/uH1HTrQWrNhrCvGDzNQj4Xw21clenJuXJn1WoJzlJluB45H8tStAYqCJg3MNvi 288jES0pf8frOamlj1HXhOvNWuSh2YgeBqw2UR6QQzAGFdEHgmw2AH8qE5YAAiRDwuW3M+ WnacH8QiZQEL8Oja2Qs/RGy4REh8fsF0S1L0RaAlZI0XV0NQ7WEKd/VeOKFFzLu0byKYFA kdka7YiSV/7KGwUxXofm3VVY1i4rwmHuJVtuEIesARjog/SOjPI68e5+mnjXUQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSB1X6YKLz16FN; Thu, 18 Sep 2025 09:59:12 +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 58I9xCfm035273; Thu, 18 Sep 2025 09:59:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I9xCu9035270; Thu, 18 Sep 2025 09:59:12 GMT (envelope-from git) Date: Thu, 18 Sep 2025 09:59:12 GMT Message-Id: <202509180959.58I9xCu9035270@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: 064006b78c90 - stable/14 - ng_hci: Cast NG_HCI_BDADDR_ANY to const bdaddr_t * 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 064006b78c90b52813a5a93341a4c52452114ca9 Auto-Submitted: auto-generated The branch stable/14 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=064006b78c90b52813a5a93341a4c52452114ca9 commit 064006b78c90b52813a5a93341a4c52452114ca9 Author: Christos Margiolis AuthorDate: 2025-09-15 13:09:42 +0000 Commit: Christos Margiolis CommitDate: 2025-09-18 09:59:03 +0000 ng_hci: Cast NG_HCI_BDADDR_ANY to const bdaddr_t * This is needed to address some compiler errors cleanly, where consumer functions want this address to be a const pointer. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D52310 (cherry picked from commit 680f9acc3657efcea07d8ac0954645b6eaf8dac8) --- sys/netgraph/bluetooth/include/ng_hci.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netgraph/bluetooth/include/ng_hci.h b/sys/netgraph/bluetooth/include/ng_hci.h index 44a14e62f4ed..ce3291770740 100644 --- a/sys/netgraph/bluetooth/include/ng_hci.h +++ b/sys/netgraph/bluetooth/include/ng_hci.h @@ -448,7 +448,7 @@ typedef struct { typedef bdaddr_t * bdaddr_p; /* Any BD_ADDR. Note: This is actually 7 bytes (count '\0' terminator) */ -#define NG_HCI_BDADDR_ANY ((bdaddr_p) "\000\000\000\000\000\000") +#define NG_HCI_BDADDR_ANY (&(const bdaddr_t){"\000\000\000\000\000\000"}) /* HCI status return parameter */ typedef struct { From nobody Thu Sep 18 09:59:13 2025 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 4cSB1Z2DyCz686M0; Thu, 18 Sep 2025 09:59:14 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSB1Z0lhKz41jM; Thu, 18 Sep 2025 09:59:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189554; 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=NI7eunK/LgmG7H6pyQI6+gLg/ICY8XP+dlT9SQmBBbc=; b=QR+CKLUyYEBts8xd83dZsz5OYnf/CXq2TJuseKB4iP88uMlqhblooCKZi/Em1fF8hyHaFW 5xKmQaaaQKpwZWXCtnalLmqqrkYAHEe3wt1chW0bV04OovgzRq+pg+bYlI5zlLwz+ogo3d JEmQDQD8/6OFfFkbDXMKfCQ18b+DlgI3E+Rgchvie6f86g6ZeY6rxUtLABGh07h0+JiC/F wHyqza+QLT2ivzV65gT4uizkoFyHtGSsdTubxGnJKtb+DWX40/BDSv8GHl4fq/X3fyETTY 0111Pv/USrWBXJdli1KQfP8KwS8eID/xih06pKfXOiW5QZSDv1T7kVz+pfkvNA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189554; 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=NI7eunK/LgmG7H6pyQI6+gLg/ICY8XP+dlT9SQmBBbc=; b=FguGx7ppZ3ai6zHFTKC/Y+Azfstzw2fw43Wo9nah3LfG1V7tQfNoTi70hrnSwrB5a6ooe5 TBrAja3cJ2yIdtSns9/V+sljstoTCBktYyWXNcPrp3GHyDcP42JuZYrlNG0W+WGQKvWC4/ XntLdISMs9lVcJhTxFZ5S3CsMJVS7Y8QtxOA+TpVzJ/xEQVzEjtwAQfDvsKCv4ddu11NaG Uw5Ln9eE5mbf2q1tzudv1G0LE/79+rJOlo1WFwI/4bPMP0LpcnmxGc3fiPWKfhjRQQGCcn 5qvocGuIN7ZgiKpnd4QMWrAkdaNzO0sLueZMGvvIJOOnjHBxXiWuLNZJYlhJ2w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758189554; a=rsa-sha256; cv=none; b=ii9TQTm0yKD1Fz7aWXb3sd0ndoxTyUsLIOyDjhdah6S/5j7tv2zoeuKxRmlnJ1fSc9mnkd W1WRAF/pVXXkahhlSlr2PoZ76SevGWo0huWp+y9xG89s0ZDsNIcHVywteCvKtRDwuENCZL 3KlTtQziVeYdB/1Kg1IwIle+UFozCkQIH+VlZfULmvz2fWA1hkWBKET1P6Yo+GRKLFm0R5 r74vbkGFiFYcrWReKGbmp8/UUFJ4mvt9KREnXJV5Z4kvzZNWhh+vDUDOeMfUCAMJkKHmUI fdIQY/chB6GxzUhuxjGJ2ZM7IrRcWj9MqoOiYqAtu64Q04NKplfRSizdyRwXSA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSB1Z0CRTz15f9; Thu, 18 Sep 2025 09:59:14 +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 58I9xDjU035305; Thu, 18 Sep 2025 09:59:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I9xDuD035302; Thu, 18 Sep 2025 09:59:13 GMT (envelope-from git) Date: Thu, 18 Sep 2025 09:59:13 GMT Message-Id: <202509180959.58I9xDuD035302@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: e4fcd203f252 - stable/14 - ng_btsocket_rfcomm: Mark a couple buffers as const in a helper function 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e4fcd203f2525fa98a03fa631cf1cc36bf438e41 Auto-Submitted: auto-generated The branch stable/14 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=e4fcd203f2525fa98a03fa631cf1cc36bf438e41 commit e4fcd203f2525fa98a03fa631cf1cc36bf438e41 Author: Mark Johnston AuthorDate: 2025-09-15 13:57:19 +0000 Commit: Christos Margiolis CommitDate: 2025-09-18 09:59:03 +0000 ng_btsocket_rfcomm: Mark a couple buffers as const in a helper function Fixes: 680f9acc3657 ("ng_hci: Cast NG_HCI_BDADDR_ANY to const bdaddr_t *") (cherry picked from commit 18fd3f8ec5c50da21515757af24421a078a4a468) --- sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c b/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c index 00225f8240e9..0013bb08bc17 100644 --- a/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c +++ b/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c @@ -113,7 +113,7 @@ static void ng_btsocket_rfcomm_connect_cfm static int ng_btsocket_rfcomm_session_create (ng_btsocket_rfcomm_session_p *sp, struct socket *l2so, - bdaddr_p src, bdaddr_p dst, struct thread *td); + const bdaddr_t *src, const bdaddr_t *dst, struct thread *td); static int ng_btsocket_rfcomm_session_accept (ng_btsocket_rfcomm_session_p s0); static int ng_btsocket_rfcomm_session_connect @@ -1261,7 +1261,7 @@ ng_btsocket_rfcomm_connect_cfm(ng_btsocket_rfcomm_session_p s) static int ng_btsocket_rfcomm_session_create(ng_btsocket_rfcomm_session_p *sp, - struct socket *l2so, bdaddr_p src, bdaddr_p dst, + struct socket *l2so, const bdaddr_t *src, const bdaddr_t *dst, struct thread *td) { ng_btsocket_rfcomm_session_p s = NULL; From nobody Thu Sep 18 09:59:14 2025 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 4cSB1b2GYyz686PS; Thu, 18 Sep 2025 09:59:15 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSB1b19Blz41Zb; Thu, 18 Sep 2025 09:59:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189555; 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=/DdAFiukQmriS3aKt8dgSNklCQr1aMT1JhpoNxvmFcY=; b=tqNW8IlNl5F3o+zEUp6gyzXcZ+lZSfzEHu+h3aPH2bSvE8X310U1ZMWnVeimZiYj7J5nAp B9kRm0/7KVmWOECFN6RIUMV9bymkjneTmmtwttXdzVVnBUtnVy3RZrVUo6jDGP68wv0dxZ yTuA33kkiRobom15lg5/2rxHCQwq+mQ8x81xYD6vFcYeNPK4zstkorigOTYXkVeGe6AfDY v55aWBMqIdICMCppV86ac3/Oq9rL9SQ/rrv+OZEENsT/4ovGjDbfVUEISN3BnzivQQquMP MagimBwHlUdc3sQnVfBRdndQD/s/lWXDo9kWLvpi/xaxcif8l2IVSwPM391kxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758189555; 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=/DdAFiukQmriS3aKt8dgSNklCQr1aMT1JhpoNxvmFcY=; b=ritEXXcvSchINvTCoXSD07Am59qNVZufJDw7fRgHgjTd2tqb6n+UGIy0jJTe4GJXraP8vt CW5pQbwoaJVACeIeLN6w7pukZVKNMBOIZWYBivmhGIPXtERkZmv8QNilkKhEaTVtNexlzt Xp11zl3uqRX5ABkhHaR6b+6Emn18cBFa58VZN9vu5cb1VdXZ0oo4vjWnwi1UhdjP1C6KUQ KXUTsHRMoTCo3ISlKkiaj62T8XFMKNNvUY4yYpIkbWq8NMybNtIvMYxdbXMw217YrUCpny BNme8mlTHYrHA1enSRgMExwiNGtiNbPpuPv6zd5zWI6ycB6PU/FCt6FuBC2+/g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758189555; a=rsa-sha256; cv=none; b=ixAfb0DKybLJ0cmX8lA65mMwVBFRDvxDppHGtkN7sryQjnvdds+r7yIqDRkD0gTEZhYiDr mUmXmoAktxiQWcA7YdtI35zgXCwjaLimVCOqMl5JNFYKvejYfWloVdpfZ8ETDQY95kVhoT ZQgzjgPr8HrGtfGB6qv8y9NDXkzU092vL1W3LCFIspK9s3jWZOVcjJP956zzQgFaKc+STS vEh7lSWgxdK6FCcTE3lAGWbz8h/d38SUgCXyign4m8TC3MhKuWRQ/KKFfwwzoLQ4ZLtuyb 6jNHH7qV9ynw050Y3E2OQB0TJEa0m6XSchyRGVyAikYqxqRFKRIHsK0hcIaVnA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSB1b0f9fz1630; Thu, 18 Sep 2025 09:59:15 +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 58I9xEKP035344; Thu, 18 Sep 2025 09:59:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58I9xE76035341; Thu, 18 Sep 2025 09:59:14 GMT (envelope-from git) Date: Thu, 18 Sep 2025 09:59:14 GMT Message-Id: <202509180959.58I9xE76035341@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Christos Margiolis Subject: git: eabd561d3a2a - stable/14 - sdp(3): Change bdaddr parameter type in sdp_register_service() 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: christos X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: eabd561d3a2a7542e5817e493ccef25dfd247eed Auto-Submitted: auto-generated The branch stable/14 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=eabd561d3a2a7542e5817e493ccef25dfd247eed commit eabd561d3a2a7542e5817e493ccef25dfd247eed Author: Christos Margiolis AuthorDate: 2025-09-17 14:12:03 +0000 Commit: Christos Margiolis CommitDate: 2025-09-18 09:59:05 +0000 sdp(3): Change bdaddr parameter type in sdp_register_service() Fixes compiler error when the caller passes a const bdaddr_t * paramemeter (e.g., NG_HCI_BDADDR_ANY). Sponsored by: The FreeBSD Foundation MFC after: 1 day Reviewed by: markj, emaste Differential Revision: https://reviews.freebsd.org/D52582 (cherry picked from commit 3d14cc82d7a8c11cd164a6ba668d20b939c576fe) --- lib/libsdp/sdp.3 | 4 ++-- lib/libsdp/sdp.h | 2 +- lib/libsdp/service.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/libsdp/sdp.3 b/lib/libsdp/sdp.3 index dcd9077798ea..015f9cd8fb44 100644 --- a/lib/libsdp/sdp.3 +++ b/lib/libsdp/sdp.3 @@ -24,7 +24,7 @@ .\" .\" $Id: sdp.3,v 1.1 2003/09/07 20:34:19 max Exp $ .\" -.Dd April 30, 2018 +.Dd September 16, 2025 .Dt SDP 3 .Os .Sh NAME @@ -87,7 +87,7 @@ .Fn sdp_uuid2desc "uint16_t uuid" .Ft int32_t .Fo sdp_register_service -.Fa "void *xss" "uint16_t uuid" "bdaddr_p const bdaddr" "uint8_t const *data" +.Fa "void *xss" "uint16_t uuid" "const bdaddr_t *bdaddr" "uint8_t const *data" .Fa "uint32_t datalen" "uint32_t *handle" .Fc .Ft int32_t diff --git a/lib/libsdp/sdp.h b/lib/libsdp/sdp.h index faad36aefca6..0c9474a70eff 100644 --- a/lib/libsdp/sdp.h +++ b/lib/libsdp/sdp.h @@ -702,7 +702,7 @@ typedef struct sdp_panu_profile sdp_panu_profile_t; typedef struct sdp_panu_profile * sdp_panu_profile_p; int32_t sdp_register_service (void *xss, uint16_t uuid, - bdaddr_p const bdaddr, uint8_t const *data, + const bdaddr_t *bdaddr, uint8_t const *data, uint32_t datalen, uint32_t *handle); int32_t sdp_unregister_service (void *xss, uint32_t handle); int32_t sdp_change_service (void *xss, uint32_t handle, diff --git a/lib/libsdp/service.c b/lib/libsdp/service.c index 9f07d1ba86ba..2cce6c133600 100644 --- a/lib/libsdp/service.c +++ b/lib/libsdp/service.c @@ -45,7 +45,7 @@ static int32_t sdp_receive_error_pdu(sdp_session_p ss); int32_t -sdp_register_service(void *xss, uint16_t uuid, bdaddr_p const bdaddr, +sdp_register_service(void *xss, uint16_t uuid, const bdaddr_t *bdaddr, uint8_t const *data, uint32_t datalen, uint32_t *handle) { sdp_session_p ss = (sdp_session_p) xss; From nobody Thu Sep 18 10:13:41 2025 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 4cSBLF4Jn6z687st; Thu, 18 Sep 2025 10:13:41 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSBLF3Zl0z46tQ; Thu, 18 Sep 2025 10:13:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758190421; 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=IgqlMVbFmcO3e8sITmkdNzmP05VZSQ79rTwPE8fFfhk=; b=Za/POngC1cyo2gj3fHjjGh4YSGG2z1KDP+qx1KHz5dOH846qedL9FEnQqfhPsyxG6cAt2O Z/1wy99brJrb7AEVgKLdcphQ81st4GX3ALunpTR82Z6Qo+jAFMQP9Gixb+LuBDDciHAfdy Y7OLxHZS3ku3WFSuDEPXIvz9LtGtdeWZBhHMJGA5KxvAW19r5VwVgIx7lXVtTgRGxNO5cP ghSJezbhUUVwuIboc+aInw4KzpTmarUWiwbDVaNb+XVHl4YlVCGJTiz/AuTSiHIyv4Uzmr YnPRVBuzBw1WKZthbqWxpidDNVxYwFiXloJbWtcdFPAiQPHjZgxON9YOqHUiSA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758190421; 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=IgqlMVbFmcO3e8sITmkdNzmP05VZSQ79rTwPE8fFfhk=; b=Y2mWi6n/eXJ3Qr4drWU4QWiNSLL9lbWPjNeBAN+G9Apa96nNuDQx/YFFP3LBMAc9QdYOKq w7fIvcpaWPzxSdVUg+i1kjn6lCAlAXPsKqnPUUN166te3n7D3XtYzwC5ionSy6EHIHumuE EejYN4pCuW+clJCceFkmfuIpTgJTarZWwd3OZ5+KMJ6pcO7CMyCRKobRfAUfa7tOqh/uND xnKBxs8WT04EeByGrIO0DF/pY4fka4pvGEm5tzbujp4rFcfJU8BD/v6RwPG4w23zbpBGs7 Q21R5GTK2VeJBH4MDJ/NUZrjvu/fB9ldZDM1RotPxEqPNZjvxkyBrsQW60Obwg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758190421; a=rsa-sha256; cv=none; b=wPLc/GTmnMA8WG0832BmNo0kh2NcEHMAn1anUQuzJiH8TEptDxDOeoK8/b8T/zW82TQ4UH aZftXL2VFtz6V8rNW0EWix8/KNebfxQwrjZKA873Aro/idyejFELMeT1myh0N5m8I/GiZX sj03Zu4jfiYJ9hkI8mQmB7YTJ7fySrc1DhaFUkLp8LYul+DSolW7Gkl+8CL6UzvyhY17iu B/LBBN/+PaCXKY/EBB29156As2yEqCtymtv9VoUAdizzBZZtfBNcaBMNhO6b5/bkW2qWjX h521fG90FvIxgdrPPnliS9jre+tHEAr8rEjA5yd+zqFys8MsZTKLrj6+1wi+1g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSBLF37tSz16R8; Thu, 18 Sep 2025 10:13:41 +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 58IADfhM072638; Thu, 18 Sep 2025 10:13:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IADfsj072635; Thu, 18 Sep 2025 10:13:41 GMT (envelope-from git) Date: Thu, 18 Sep 2025 10:13:41 GMT Message-Id: <202509181013.58IADfsj072635@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 59a73e9a1fe3 - stable/14 - hwpmc: On attach, ensure owner is a target effective GID's member 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 59a73e9a1fe33517393a18ff958ef8d05f550a56 Auto-Submitted: auto-generated The branch stable/14 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=59a73e9a1fe33517393a18ff958ef8d05f550a56 commit 59a73e9a1fe33517393a18ff958ef8d05f550a56 Author: Olivier Certner AuthorDate: 2025-08-26 09:43:38 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 10:13:05 +0000 hwpmc: On attach, ensure owner is a target effective GID's member This restores a check that existed prior to commit be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]"). While here, improve pmc_can_attach()'s style by changing the type of 'decline_attach' to 'bool', fixing tests on it, adding missing parentheses to 'return' statements, and by changing its return value type to 'bool'. Fixes: be1f7435ef218b1d ("kern: start tracking cr_gid outside of cr_groups[]") MFC after: 9 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52252 (cherry picked from commit 1c3c698ba4c40485ebbbd157cb49172cfa7de9b2) MFC to 14 does not fix any bug, but just applies some style changes needed by next MFC. In pmc_can_attach(): Start index of the loop on groups was changed to 1 in order to avoid a (harmless) duplicated groupmember() call with 'tc->cr_gid', which in 14 is still an alias of 'tc->cr_groups[0]'. We chose to MFC the addition of that latter call to minimize differences with what is in -CURRENT and 15. --- sys/dev/hwpmc/hwpmc_mod.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/sys/dev/hwpmc/hwpmc_mod.c b/sys/dev/hwpmc/hwpmc_mod.c index 5dd8bc67d60a..21f416510d5e 100644 --- a/sys/dev/hwpmc/hwpmc_mod.c +++ b/sys/dev/hwpmc/hwpmc_mod.c @@ -211,7 +211,7 @@ static int pmc_attach_one_process(struct proc *p, struct pmc *pm); static bool pmc_can_allocate_row(int ri, enum pmc_mode mode); static bool pmc_can_allocate_rowindex(struct proc *p, unsigned int ri, int cpu); -static int pmc_can_attach(struct pmc *pm, struct proc *p); +static bool pmc_can_attach(struct pmc *pm, struct proc *p); static void pmc_capture_user_callchain(int cpu, int soft, struct trapframe *tf); static void pmc_cleanup(void); @@ -1030,19 +1030,19 @@ pmc_unlink_target_process(struct pmc *pm, struct pmc_process *pp) * Check if PMC 'pm' may be attached to target process 't'. */ -static int +static bool pmc_can_attach(struct pmc *pm, struct proc *t) { struct proc *o; /* pmc owner */ struct ucred *oc, *tc; /* owner, target credentials */ - int decline_attach, i; + bool decline_attach; /* * A PMC's owner can always attach that PMC to itself. */ if ((o = pm->pm_owner->po_owner) == t) - return 0; + return (false); PROC_LOCK(o); oc = o->p_ucred; @@ -1067,18 +1067,17 @@ pmc_can_attach(struct pmc *pm, struct proc *t) * Every one of the target's group ids, must be in the owner's * group list. */ - for (i = 0; !decline_attach && i < tc->cr_ngroups; i++) + for (int i = 1; !decline_attach && i < tc->cr_ngroups; i++) decline_attach = !groupmember(tc->cr_groups[i], oc); - - /* check the read and saved gids too */ - if (decline_attach == 0) - decline_attach = !groupmember(tc->cr_rgid, oc) || + if (!decline_attach) + decline_attach = !groupmember(tc->cr_gid, oc) || + !groupmember(tc->cr_rgid, oc) || !groupmember(tc->cr_svgid, oc); crfree(tc); crfree(oc); - return !decline_attach; + return (!decline_attach); } /* @@ -1413,7 +1412,7 @@ pmc_process_exec(struct thread *td, struct pmckern_procexec *pk) */ for (ri = 0; ri < md->pmd_npmc; ri++) { if ((pm = pp->pp_pmcs[ri].pp_pmc) != NULL) { - if (pmc_can_attach(pm, td->td_proc) != 0) { + if (pmc_can_attach(pm, td->td_proc)) { pmc_detach_one_process(td->td_proc, pm, PMC_FLAG_NONE); } From nobody Thu Sep 18 10:13:42 2025 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 4cSBLG6MDlz687R6; Thu, 18 Sep 2025 10:13:42 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSBLG4VBPz474C; Thu, 18 Sep 2025 10:13:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758190422; 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=TrmAXJ6f1yFkPO/CoxXSJBvMEWdQlyPqDReVq2wwa+k=; b=vuD7q/h6zZ+QvWaRE4AZH9bNZ/kIN7qfldUS+V5y4pZuvZuZr3ofLA5Jrygtil4EWVzIkG zFlrEzIkx/taJ16aPqrb+Vc651Wxc/Wvt1/MMRSGWtIluvzf6te+n3fOrYqG+rdZ6AGVsu LPA5ViOD8VArBiN+H8Fw5vJCXwTBOT10RsBFg5Xis0s6s7mCoOed1vu75RI0YN83m/IMu9 2/VxaLgR0/vYNdwH+wuUQHvlvQfoSjsKNqy9XjBExgOFsrphfGd/D7qfwKG7ZjrGrE1Rud Y80nIJCkzgi3223QJxYN1VIopHGB1qu6ZzaltH6erQcNpTc4F9YpC80cLlsEfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758190422; 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=TrmAXJ6f1yFkPO/CoxXSJBvMEWdQlyPqDReVq2wwa+k=; b=pc15kX+tc/y2pJSFu9bG2h1LiKCbhg93Ifc+GAiEcK/+cj1reAP5KM2uDnGr6TECrhvaPF PsiCdhnsuVPWpd10K50IKKZxYqiqkhKQrP2EEAoNQyDOum9Q7UC/9x3eykRc087rr+7Lkp vSkm5/kuUGGWyj+km0ELwcxQUWM5uaWOAttxcUpcdfsS/0EA+K6noOZ9+7eOaReYr2TWOt 94mEthqR63v6/dP+7LYZ1yxtn2CBb9rB3RwRQeCHLwJ51T+hHq96WKlHXbWNZcyLd+kvOz oOdrFlr8y6mDBnMRqaOqpik0ZJPZlHztzbld1lopGYFl+FF+r4/MzSdgnLtN0Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758190422; a=rsa-sha256; cv=none; b=IDdpeGpBxnyZ5LYYjVmSZ4FjkmeAnuz1MHKKIozwyfo+kXs0GzzugTTdN87Rlzx+DIgI9k ZVYCVg/VRkhSApCNrC5vpR1c7iuC5O/tdMgmd6AA6/6BcilT2vYnlrFYdoJjKFsTQu5Zi1 psPl/oRA5C0XGUjnFRcBb+4mipPSUgJL6gGph6ZRdlg+r5Y6d+6sgoDN+0JQdj6mf3+vfC SMgu4npT/cloy+unRqueNwePkNU1Kxx6BHDBhOph27GM6gkDD3COtkSlDhK+8t6UzZLiSo wA9LDUn7CFNlKYc6CiJRw/pTkCezuVvUsfiDyIBNDFXddgCs/y0BN6TMSwyI+w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSBLG3rSjz16Yw; Thu, 18 Sep 2025 10:13:42 +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 58IADgWg072674; Thu, 18 Sep 2025 10:13:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IADgxe072671; Thu, 18 Sep 2025 10:13:42 GMT (envelope-from git) Date: Thu, 18 Sep 2025 10:13:42 GMT Message-Id: <202509181013.58IADgxe072671@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 009268dbfdd5 - stable/14 - hwpmc: On attach, fix allowing a PMC's owner to attach it to itself 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 009268dbfdd5fe487117654f75ae3850a2c1a7d9 Auto-Submitted: auto-generated The branch stable/14 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=009268dbfdd5fe487117654f75ae3850a2c1a7d9 commit 009268dbfdd5fe487117654f75ae3850a2c1a7d9 Author: Olivier Certner AuthorDate: 2025-09-09 12:48:05 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 10:13:10 +0000 hwpmc: On attach, fix allowing a PMC's owner to attach it to itself The returned value in this case was wrong, and would basically prevent some PMC's owner process to attach that PMC to itself although the security checks underneath would have allowed it. Now that this early return has been fixed, its block basically becomes a performance short-circuit which has no effect from a functional standpoint. Fixes: ebccf1e3a6b1 ("Bring a working snapshot of hwpmc(4), ...") MFC after: 9 days Sponsored by: The FreeBSD Foundation (cherry picked from commit 1c40b15971f09c0c0676ae476b88b32166eae8ac) --- sys/dev/hwpmc/hwpmc_mod.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/hwpmc/hwpmc_mod.c b/sys/dev/hwpmc/hwpmc_mod.c index 21f416510d5e..54fcc2dafb4f 100644 --- a/sys/dev/hwpmc/hwpmc_mod.c +++ b/sys/dev/hwpmc/hwpmc_mod.c @@ -1042,7 +1042,7 @@ pmc_can_attach(struct pmc *pm, struct proc *t) */ if ((o = pm->pm_owner->po_owner) == t) - return (false); + return (true); PROC_LOCK(o); oc = o->p_ucred; From nobody Thu Sep 18 10:13:43 2025 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 4cSBLJ4SGXz687WV; Thu, 18 Sep 2025 10:13:44 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSBLH548mz47Ch; Thu, 18 Sep 2025 10:13:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758190423; 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=xh28t6WKCpsuYdsToJlVEp2vmfEnV62FxA3T0/V6KFU=; b=YPxFBnhLPVtWWQ+SBkpcR7Ujm48hCAkrGAFb/T8Jbwa49CxJH3+f2IKjcLA+e+Paiyobeh 0WuMY4qPxx07BbDeMg4YxWeRroLqUq+KI3zj2D/FJvBYekLpBS4fg8HJyO1nKDLGaHdyIe sXCh/8iy9lR3RoN8suwNoHnrQoTXiUxkADGruVVQrHKRCsKB9pVXP/7tge/WOFEQj9aIo/ Xli/S3IXV8lAQh6Neb1BR6d+4EraYjrXPGbvAuOZutZbCdbL/ap3u/wQn2IMKqqb+JsLNE Kb1u+2NVUSwCrYsGHyyJ0qRQWtWGCxwqekqk4f4AvxG8oAWSyK59JOpFTR353g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758190423; 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=xh28t6WKCpsuYdsToJlVEp2vmfEnV62FxA3T0/V6KFU=; b=x4jmsfWNyluFRsvnJYU7+vO30qPnO9++6zfjaVCo6anwD4xeBsqksNGuLRDp8Q2OiQ8i6p nZAuru3zq5TKvZZDEIONVJQMXmM0SNlw6YULOpkgabC/WhRuowq36LVeRxZMPy/W8PhMtk YQy96Aie+v9utJN8OGMT6fJvUbzd3N07FHqpR+K2130kHjU2MpZ1JKrVE7Zl05XKhgBvU4 r0cQUROYR+PU+dC/g8Zc+u75OYXoB1ajQhoPmLL0OcLIVQOiyn9VsAE0eLzb0pXU35ZpSI RQstcGzUmJEmAfzmtEgb4aKjKpsLPFH54tkMlykfeTH2vTgoewJSx+AjixnmKw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758190423; a=rsa-sha256; cv=none; b=IVELJ0tbPZQp7NjOH5y7ZmTqXTlOhOZAmQD0nGFda3TShozav/d4Qfq5jgRLcQOG6hRLwX 8nk6x5lhm1eHC6eX7KpYKtDTZBpYO1P+HVym8km1KFdFXAXDU1ao5WvTXx7Zczt4Lb3OvA VvugGnewqg0YuQgA6NqQokRKF4BtUh3MLIfVxJutZ/st/MjY7eWczXeu/sEsGM4zuDq5D1 KZYiTZqO/KgRw0uNmB5aNiRJYrFiIMx17Lq+wya43oy+nGAWKAsM+0STBaDrJ/nEKoUTbE KOxEHaYoUP7rd7TRzEZcVgpDhITfm6SSqSAQYKytajGMXcNWuQoq+VH5/b2+/Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSBLH47HQz16dB; Thu, 18 Sep 2025 10:13:43 +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 58IADhXB072708; Thu, 18 Sep 2025 10:13:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IADhOb072705; Thu, 18 Sep 2025 10:13:43 GMT (envelope-from git) Date: Thu, 18 Sep 2025 10:13:43 GMT Message-Id: <202509181013.58IADhOb072705@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: 7220f36f6cf9 - stable/14 - getgrouplist(3): Remove superfluous headers, bogus comment and whitespace 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7220f36f6cf9d72bef0f274d4134fad0d86f6052 Auto-Submitted: auto-generated The branch stable/14 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=7220f36f6cf9d72bef0f274d4134fad0d86f6052 commit 7220f36f6cf9d72bef0f274d4134fad0d86f6052 Author: Olivier Certner AuthorDate: 2025-09-12 12:29:59 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 10:13:10 +0000 getgrouplist(3): Remove superfluous headers, bogus comment and whitespace No functional change (intended). Fixes: a59d6a872459 ("Implementing 'fallback' nsswitch source.") MFC after: 3 days Sponsored by: The FreeBSD Foundation (cherry picked from commit d3f8ed6066fdea329ed695925fc726e84d50abc3) --- lib/libc/gen/getgrouplist.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/lib/libc/gen/getgrouplist.c b/lib/libc/gen/getgrouplist.c index 6dddea5c3847..90626cef3c83 100644 --- a/lib/libc/gen/getgrouplist.c +++ b/lib/libc/gen/getgrouplist.c @@ -31,15 +31,8 @@ #include __SCCSID("@(#)getgrouplist.c 8.2 (Berkeley) 12/8/94"); -/* - * get credential - */ #include -#include -#include -#include - extern int __getgroupmembership(const char *, gid_t, gid_t *, int, int *); int @@ -47,4 +40,3 @@ getgrouplist(const char *uname, gid_t agroup, gid_t *groups, int *grpcnt) { return __getgroupmembership(uname, agroup, groups, *grpcnt, grpcnt); } - From nobody Thu Sep 18 10:13:44 2025 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 4cSBLK26tCz687Nk; Thu, 18 Sep 2025 10:13:45 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSBLJ5Yh6z472y; Thu, 18 Sep 2025 10:13:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758190424; 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=RIo6PSgDap0eWp1Ef1xfsioOA7EpqX8VHmXxojTJUg8=; b=ZDTlZYTp9GnILq50JCDd91fjNpecjRvc9EWuNRFOrVvHr/Sf0fG4sCIrshldGLZlP8QedG D/aMYAXZs5byO22aHrSN05SgDaYR78cG8rEmMWk/ftFRUC7WwiMptK4y/sDbh7C3XolFgG kj8o5BKehDWlXs8n6iYjU7a6CfPjel9LRs9EQUCWggBi4L/ytEZdwsr4yPThQTIxFTclOE GY5IprDXab73i2Nome4fLc5w/0yzOKhtwGIODzE88PI17HE/CdplrtYqYhad+xPvb7wTPx qdKI2LmWK1zQrFiFdIYgHKU3VM551JmwA3KDHUL7QufqytDI2K4H9US1OqLveg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758190424; 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=RIo6PSgDap0eWp1Ef1xfsioOA7EpqX8VHmXxojTJUg8=; b=I9W6l/cwXhFe0nMKzMkKa0FfLca4DW5qC+h+YutImEqv84y/LfAruWwnroAHvdTezJo/Pn s7bawpwvQlW6K+DAYgGeJrWh58sowNSIvuvTDCgPZm3nWN1jF5IxFJhKz3ehRyKIgJWl8z aGYPb6Rk/jwjK+tV9Qr5unKduDdIOCLlaEAzcR4o/hzlZLu8wlA+Qmu5eerKMe98wqC50p MQ5UlAbYPkDVyvI+Jzoiy0MxPKCsUovN30pOVNyKyyh9NGhESAHyP/SMoIO9aJV/5AQZGK TfRp2R4BvlU9Tk5kPaqRhb73zU5rLPb972ox6gHhtYiajn9B5RTtxx+RDXS2jA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758190424; a=rsa-sha256; cv=none; b=xw1vYNMh0OmcvaF2xNJBI7a+rRBRy5rvWNokUU7NI5ZED8NRP1SsGo5JilvleGrwaLidTT QT5PnsvU/Ruy8j1V5zlEFQ4tQOqRROduN55e8/+KjhfblXild2MJ3yMAQ0s7VavwGWw6fB u+mkI8IcOQYMuybzWmjy+APbCsxzKBV1zoVDCe5peRFXStD58vUoHjNrtl1sQ4bSBkB7vO Y5OsgC6aoNAIrxPrNQUuOwpm5od9QM6b2q5TQewZZD+Rk4qbtuXI4/tWDXQzfYolf2qhkX jhRppNyI/riIfxIAdsXbNttsfUQ3je/oWs5YoYCQju6fRO64BUh1m8tel4CQ+Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSBLJ51rQz16dC; Thu, 18 Sep 2025 10:13:44 +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 58IADiv4072747; Thu, 18 Sep 2025 10:13:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IADiAB072744; Thu, 18 Sep 2025 10:13:44 GMT (envelope-from git) Date: Thu, 18 Sep 2025 10:13:44 GMT Message-Id: <202509181013.58IADiAB072744@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Olivier Certner Subject: git: d1142d54fa21 - stable/14 - libc: fix the _FORTIFY_SOURCE build of getgrouplist(3) 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d1142d54fa2153fdba3947f0cf03e8a2ce4f0e75 Auto-Submitted: auto-generated The branch stable/14 has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=d1142d54fa2153fdba3947f0cf03e8a2ce4f0e75 commit d1142d54fa2153fdba3947f0cf03e8a2ce4f0e75 Author: Kyle Evans AuthorDate: 2025-09-13 22:19:46 +0000 Commit: Olivier Certner CommitDate: 2025-09-18 10:13:11 +0000 libc: fix the _FORTIFY_SOURCE build of getgrouplist(3) We need to get our prototype normally, but WARNS in libc is way too low to surface that. Additionally, _FORTIFY_SOURCE needs to include by way of to actually export an implementation of getgrouplist(3). The version defined in the .c gets named __ssp_real_getgrouplist() and the actual implementation comes from the redirect stub in , which basically gets optimized away in the built object because our __builtin_object_size() check is trivially false when we cannot resolve any object sizes in this translation unit. This could be argued as a design flaw in _FORTIFY_SOURCE, but we should grab for our prototype anyways so let's kick the can down the road instead of re-thinking it for 15.0. Reported by: Shawn Webb (HardenedBSD) Fixes: d3f8ed6066 ("getgrouplist(3): Remove superfluous [...]") MFC after: 3 days (cherry picked from commit 91ea7e2ce2b5b2ff4702c3092cfe944862d58172) This is (partly) MFCed just for the sake of re-introducing the include to have a prototype. There is no _FORTIFY_SOURCE support for getgrouplist(3) in 14. --- lib/libc/gen/getgrouplist.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/libc/gen/getgrouplist.c b/lib/libc/gen/getgrouplist.c index 90626cef3c83..fb4945beb2b2 100644 --- a/lib/libc/gen/getgrouplist.c +++ b/lib/libc/gen/getgrouplist.c @@ -33,6 +33,8 @@ __SCCSID("@(#)getgrouplist.c 8.2 (Berkeley) 12/8/94"); #include +#include + extern int __getgroupmembership(const char *, gid_t, gid_t *, int, int *); int From nobody Thu Sep 18 12:54:21 2025 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 4cSFvd4npqz68KnY; Thu, 18 Sep 2025 12:54:21 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSFvd42xKz3YMt; Thu, 18 Sep 2025 12:54:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758200061; 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=q2ktGA0u6Ah3prv8yYsQIyU5/2LJ0mOx0B1ZjnI28B0=; b=vBvWbUOXhIWjPJPZXD81rCg9H/CDTvRgEAuL7ADqVcsO5xqUcUU8xxD/6j1OifoCiYFfub Dd910AN5qSTnrSFtkYZSiPeteRsWe+DOvMgS1j2W31SSFwz76x52Nvnh8M8HfpqaIm2REJ bDsOELgns6YBOaaylQC/MQEfBAZuQ0lcwv8T4kynznG8Rn7tf25Wk3rpbyQp7eJJrWJ+4v rlP9qwejCXq9SCf1shUzd1rcwWpiPW8DS2/jauGc2Wu9NTphIXULAOGPWK3BKrP8X/Htby Us6wkA35IsHFkBlmUoAyCf6cDpG0kfM6FXi60C6u94ibuNdFU+pwWKQSDHw1gQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758200061; 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=q2ktGA0u6Ah3prv8yYsQIyU5/2LJ0mOx0B1ZjnI28B0=; b=mBXvVnJ1fT7/VCv11lIDhKlbkQbJ3+D04C6ReDbO0IwkbenSCf4ngerGTt5aw03kBugJCh o/hVzLuhLtCSoqouEH+jLr/VPvYmgCVjvFRttvfz/JvNVtE4B+0SRjizTtDGX2l1VZ3Hre 9kp8rU9JZUoQxt1u9SlxZMr/ol9oj6fnBPzro53scf6ZHCkzToNya7cdJrMynm234LeYrV XLYwPJ/DEQd5KQAW6zdLpfWpRdfxRQ6xy5a2+738nvy1QxoNZC/Nge0AWMiI6ikS2R3fSu wZdBtqr/d5OXyXD+bvTz9xX+evXPdnrbBaClzQrGjIBFzil4YSb2RRaQf1QqFQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758200061; a=rsa-sha256; cv=none; b=G1E/vKa2nMm4fhyFfDEVSezwTaPta+h+PXN91olOiXFBYPMFNz4OaXvWyy66fzmXnffVfx txfIBWZxndsfJA6/0/7AuBGBIUEmnHEgnSl+ysGluo0/nfKOEdsvI+3h82AXbL5IsYaQ5c w4T6xhN00EgltnNKdE244VCNGPUsWZh/Z1tnwx/nFtPxWPrzI8M5cjIV9Uc+kvwbtHsX8o rAURtcxvf+3xCET0sBxaVVbbbqR14cNX2Ku3YS/kEHTYly705NAew+PHrDe7NcF9SMT58X 5dO1+TaJqYluBOO2mFliQlyKjIYRRZsBtEgSu/mWX2JljoLGExWhT/nOmxUmWg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSFvd3DHKz1BnQ; Thu, 18 Sep 2025 12:54:21 +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 58ICsL6E072793; Thu, 18 Sep 2025 12:54:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58ICsLmc072790; Thu, 18 Sep 2025 12:54:21 GMT (envelope-from git) Date: Thu, 18 Sep 2025 12:54:21 GMT Message-Id: <202509181254.58ICsLmc072790@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Tom Jones Subject: git: 46e6e9173875 - stable/15 - udbc: Add usb debug host mode driver 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: thj X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 46e6e91738757e3090423ce5e0dc700d4e24da7b Auto-Submitted: auto-generated The branch stable/15 has been updated by thj: URL: https://cgit.FreeBSD.org/src/commit/?id=46e6e91738757e3090423ce5e0dc700d4e24da7b commit 46e6e91738757e3090423ce5e0dc700d4e24da7b Author: Tom Jones AuthorDate: 2025-07-08 08:04:00 +0000 Commit: Tom Jones CommitDate: 2025-09-18 12:53:13 +0000 udbc: Add usb debug host mode driver xhci offers a debugging interface which uses a special usb 3 cable with the D+, D- and VBUS pairs disconnected. This interface allows a target device to configure its xhci controller as a debugging channel which can then be used to provide a serial link between the target and a debug host. This change extracts the udbc host mode driver from hrs@'s xhci debug implementation. Reviewed by: bcr (man page) MFC after: Before 15-ALPHA3 builds Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D51299 (cherry picked from commit d566b6a70bcbc329e8c690464043401fa8bdd49f) --- share/man/man4/udbc.4 | 132 ++++++++++++++ sys/dev/usb/serial/udbc.c | 404 ++++++++++++++++++++++++++++++++++++++++++ sys/modules/usb/Makefile | 7 +- sys/modules/usb/udbc/Makefile | 9 + 4 files changed, 548 insertions(+), 4 deletions(-) diff --git a/share/man/man4/udbc.4 b/share/man/man4/udbc.4 new file mode 100644 index 000000000000..c8fa02ec18f1 --- /dev/null +++ b/share/man/man4/udbc.4 @@ -0,0 +1,132 @@ +.\" +.\" Copyright (c) 2025 The FreeBSD Foundation +.\" +.\" This documentation was written by Tom Jones under +.\" sponsorship from the FreeBSD Foundation. +.\" +.\" SPDX-License-Identifier: BSD-2-Clause +.\" +.\" +.Dd September 3, 2025 +.Dt UDBC 4 +.Os +.Sh NAME +.Nm udbc +.Nd USB Debug Class device driver +.Sh SYNOPSIS +.Cd "device usb" +.Cd "device ucom" +.Cd "device udbc" +.Pp +In +.Xr rc.conf 5 : +.Cd kld_list="udbc" +.Sh DESCRIPTION +The +.Nm +driver provides support for USB Debug Class devices whose +interface class is Diagnostic Class and the subclass is DbC.GP. +.Pp +The USB Debug Class is defined in the USB 3.1 Device Class +Specification for Debug Devices. +This is designed to provide a general-purpose communication channel +for debugging. +It has also been widely implemented in USB xHCs +.Pq USB eXtensible Host Controllers , +which can be found on many commodity computers, +as an optional feature. +Once this feature is enabled on a USB xHC, one of the USB ports will +behave as a USB Debug Class device, +not a host port, +when a USB debug cable is connected. +The supported class in USB xHCs is typically DbC.GP, +while the specification defines several types of Debug Class devices. +The DbC.GP uses IN and OUT endpoint pairs and realizes a single +bidirectional serial communication channel. +On most systems, +including +.Fx , +the DbC.GP is seen as a simple serial device. +.Pp +Most systems with USB xHC can be configured to provide DbC.GP access. +The +.Nm +is a driver that connects to DbC.GP-supported devices, +offering +.Xr tty 4 +devices to connect to them via the +.Xr ucom 4 +device driver. +.Sh HARDWARE CONFIGURATION +A native DbC.GP device can be attached using the +.Nm +driver in a straightforward way. +.Pp +A USB xHC DbC.GP device on a target system needs a special hardware +configuration because all of the ports are supposed to be a USB Host. +There is one method to expose DbC.GP is to use a USB 3.1 A-to-A cable +.Pq section 5.5.2 in USB 3.1 Legacy Cable and Connector Specification . +When this cable is connected to a USB 3.1 port on the target system, +the DbC-enabled USB xHC automatically switches the port as a USB Device. +The +.Nm +driver can find a DbC.GP device on that port. +.Pp +Note that a USB xHC with USB 3.2 support +.Pq USB Type-C connectors +is not compatible with the USB 3.1 A-to-A cable. +Connecting a USB 3.2 C-to-C cable or A-to-C cable does not automatically work, +either, +because it needs role configuration of the port, which is not supported on +.Fx +yet. +.Sh FILES +.Bl -tag -width "/dev/ttyU*.*.init" -compact +.It Pa /dev/ttyU*.* +for callin ports +.It Pa /dev/ttyU*.*.init +.It Pa /dev/ttyU*.*.lock +corresponding callin initial-state and lock-state devices +.Pp +.It Pa /dev/cuaU*.* +for callout ports +.It Pa /dev/cuaU*.*.init +.It Pa /dev/cuaU*.*.lock +corresponding callout initial-state and lock-state devices +.El +.Sh SEE ALSO +.Xr tty 4 , +.Xr ucom 4 , +.Xr usb 4 , +.Xr xhci 4 +.Sh STANDARDS +.Rs +.%T eXtensible Host Controller Interface for Universal Serial Bus (XHCI) +.%U https://www.intel.com/content/dam/www/public/us/en/documents/technical-specifications/extensible-host-controler-interface-usb-xhci.pdf +.Re +.Rs +.%T USB 3.1 Device Class Specification for Debug Devices +.%U https://www.usb.org/sites/default/files/documents/usb_debug_class_rev_1_0_final_0.pdf +.Re +.Rs +.%T USB 3.1 Legacy Cable and Connector Specification +.%U https://www.usb.org/document-library/usb-31-legacy-cable-and-connector-revision-10 +.Re +.Sh HISTORY +The +.Nm +driver first appeared +.Fx +15.0. +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was written by +.An Hiroki Sato Aq Mt hrs@FreeBSD.org . +.Sh BUGS +According to the XHCI specification the host side of USB Debug should work with +any USB 3.0 port, +whether connected directly to a controller or with a hub in between. +Testing on some controllers has encountered issues when using a hub rather than +a directly connected port on the controller. diff --git a/sys/dev/usb/serial/udbc.c b/sys/dev/usb/serial/udbc.c new file mode 100644 index 000000000000..d7ca6b25bf32 --- /dev/null +++ b/sys/dev/usb/serial/udbc.c @@ -0,0 +1,404 @@ +/*- + * SPDX-License-Identifier: BSD-2-Clause-NetBSD + * + * Copyright (c) 2000 The NetBSD Foundation, Inc. + * Copyright (c) 2016-2024 Hiroki Sato + * All rights reserved. + * + * This code is derived from software contributed to The NetBSD Foundation + * by Lennart Augustsson (lennart@augustsson.net). + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED + * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include + +#include "usbdevs.h" + +#define USB_DEBUG_VAR udbc_debug +#include +#include +#include + +static SYSCTL_NODE(_hw_usb, OID_AUTO, udbc, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, + "USB DbC Client"); + +#ifdef USB_DEBUG +static int udbc_debug = 0; +SYSCTL_INT(_hw_usb_udbc, OID_AUTO, debug, CTLFLAG_RWTUN, &udbc_debug, 0, + "Debug level"); +#endif + +#define UDBC_CONFIG_INDEX 0 + +#define UDBC_IBUFSIZE 1024 +#define UDBC_OBUFSIZE 1024 + +enum { + UDBC_BULK_DT_WR, + UDBC_BULK_DT_RD, + UDBC_N_TRANSFER, /* n of EP */ +}; + +struct udbc_softc { + struct ucom_super_softc sc_super_ucom; + struct ucom_softc sc_ucom; + + struct usb_device *sc_udev; + struct usb_xfer *sc_xfer[UDBC_N_TRANSFER]; + device_t sc_dev; + struct mtx sc_mtx; + + uint32_t sc_unit; +}; + +/* prototypes */ + +static device_probe_t udbc_probe; +static device_attach_t udbc_attach; +static device_detach_t udbc_detach; +static void udbc_free_softc(struct udbc_softc *); + +static usb_callback_t udbc_write_callback; +static usb_callback_t udbc_read_callback; + +static void udbc_free(struct ucom_softc *); +static void udbc_cfg_open(struct ucom_softc *); +static void udbc_cfg_close(struct ucom_softc *); +static int udbc_pre_param(struct ucom_softc *, struct termios *); +static int udbc_ioctl(struct ucom_softc *, uint32_t, caddr_t, int, + struct thread *); +static void udbc_start_read(struct ucom_softc *); +static void udbc_stop_read(struct ucom_softc *); +static void udbc_start_write(struct ucom_softc *); +static void udbc_stop_write(struct ucom_softc *); +static void udbc_poll(struct ucom_softc *ucom); + +static const struct usb_config udbc_config[UDBC_N_TRANSFER] = { + [UDBC_BULK_DT_WR] = { + .type = UE_BULK, + .endpoint = UE_ADDR_ANY, + .direction = UE_DIR_OUT, + .bufsize = UDBC_OBUFSIZE, + .flags = {.pipe_bof = 1,}, + .callback = &udbc_write_callback, + }, + + [UDBC_BULK_DT_RD] = { + .type = UE_BULK, + .endpoint = UE_ADDR_ANY, + .direction = UE_DIR_IN, + .bufsize = UDBC_IBUFSIZE, + .flags = {.pipe_bof = 1,.short_xfer_ok = 1,}, + .callback = &udbc_read_callback, + }, +}; + +static const struct ucom_callback udbc_callback = { + .ucom_cfg_open = &udbc_cfg_open, + .ucom_cfg_close = &udbc_cfg_close, + .ucom_pre_param = &udbc_pre_param, + .ucom_ioctl = &udbc_ioctl, + .ucom_start_read = &udbc_start_read, + .ucom_stop_read = &udbc_stop_read, + .ucom_start_write = &udbc_start_write, + .ucom_stop_write = &udbc_stop_write, + .ucom_poll = &udbc_poll, + .ucom_free = &udbc_free, +}; + +static device_method_t udbc_methods[] = { + /* Device interface */ + DEVMETHOD(device_probe, udbc_probe), + DEVMETHOD(device_attach, udbc_attach), + DEVMETHOD(device_detach, udbc_detach), + DEVMETHOD_END +}; + +static int +udbc_probe(device_t dev) +{ + struct usb_attach_arg *uaa = device_get_ivars(dev); + + if (uaa->usb_mode != USB_MODE_HOST) + return (ENXIO); + if (uaa->info.bConfigIndex != UDBC_CONFIG_INDEX) + return (ENXIO); + if (uaa->info.bInterfaceClass != UICLASS_DIAGNOSTIC) + return (ENXIO); + if (uaa->info.bDeviceProtocol != 0x00) /* GNU GDB == 1 */ + return (ENXIO); + + return (BUS_PROBE_SPECIFIC); +} + +static int +udbc_attach(device_t dev) +{ + struct usb_attach_arg *uaa = device_get_ivars(dev); + struct udbc_softc *sc = device_get_softc(dev); + int error; + + DPRINTF("\n"); + + sc->sc_udev = uaa->device; + sc->sc_dev = dev; + sc->sc_unit = device_get_unit(dev); + + device_set_usb_desc(dev); + mtx_init(&sc->sc_mtx, "udbc", NULL, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); + + sc->sc_ucom.sc_portno = 0; + + error = usbd_transfer_setup(uaa->device, &uaa->info.bIfaceIndex, + sc->sc_xfer, udbc_config, UDBC_N_TRANSFER, sc, &sc->sc_mtx); + + if (error) { + device_printf(dev, + "allocating USB transfers failed\n"); + goto detach; + } + /* clear stall at first run */ + mtx_lock(&sc->sc_mtx); + usbd_xfer_set_stall(sc->sc_xfer[UDBC_BULK_DT_WR]); + usbd_xfer_set_stall(sc->sc_xfer[UDBC_BULK_DT_RD]); + mtx_unlock(&sc->sc_mtx); + + error = ucom_attach(&sc->sc_super_ucom, &sc->sc_ucom, 1, sc, + &udbc_callback, &sc->sc_mtx); + if (error) + goto detach; + ucom_set_pnpinfo_usb(&sc->sc_super_ucom, dev); + + return (0); /* success */ + +detach: + udbc_detach(dev); + return (ENXIO); +} + +static int +udbc_detach(device_t dev) +{ + struct udbc_softc *sc = device_get_softc(dev); + + ucom_detach(&sc->sc_super_ucom, &sc->sc_ucom); + usbd_transfer_unsetup(sc->sc_xfer, UDBC_N_TRANSFER); + + device_claim_softc(dev); + + udbc_free_softc(sc); + + return (0); +} + +UCOM_UNLOAD_DRAIN(udbc); + +static void +udbc_free_softc(struct udbc_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +udbc_free(struct ucom_softc *ucom) +{ + udbc_free_softc(ucom->sc_parent); +} + +static void +udbc_cfg_open(struct ucom_softc *ucom) +{ + /* + * This do-nothing open routine exists for the sole purpose of this + * DPRINTF() so that you can see the point at which open gets called + * when debugging is enabled. + */ + DPRINTF("\n"); +} + +static void +udbc_cfg_close(struct ucom_softc *ucom) +{ + /* + * This do-nothing close routine exists for the sole purpose of this + * DPRINTF() so that you can see the point at which close gets called + * when debugging is enabled. + */ + DPRINTF("\n"); +} + +static void +udbc_write_callback(struct usb_xfer *xfer, usb_error_t error) +{ + struct udbc_softc *sc = usbd_xfer_softc(xfer); + struct usb_page_cache *pc; + uint32_t buflen; + + DPRINTFN(3, "\n"); + + switch (USB_GET_STATE(xfer)) { + default: /* Error */ + if (error != USB_ERR_CANCELLED) { + /* try to clear stall first */ + usbd_xfer_set_stall(xfer); + } + /* FALLTHROUGH */ + case USB_ST_SETUP: + case USB_ST_TRANSFERRED: + pc = usbd_xfer_get_frame(xfer, 0); + if (ucom_get_data(&sc->sc_ucom, pc, 0, UDBC_OBUFSIZE, + &buflen) == 0) + break; + if (buflen != 0) { + usbd_xfer_set_frame_len(xfer, 0, buflen); + usbd_transfer_submit(xfer); + } + break; + } +} + +static void +udbc_read_callback(struct usb_xfer *xfer, usb_error_t error) +{ + struct udbc_softc *sc = usbd_xfer_softc(xfer); + struct usb_page_cache *pc; + int buflen; + + DPRINTFN(3, "\n"); + + usbd_xfer_status(xfer, &buflen, NULL, NULL, NULL); + + switch (USB_GET_STATE(xfer)) { + case USB_ST_TRANSFERRED: + pc = usbd_xfer_get_frame(xfer, 0); + ucom_put_data(&sc->sc_ucom, pc, 0, buflen); + /* FALLTHROUGH */ + case USB_ST_SETUP: +tr_setup: + usbd_xfer_set_frame_len(xfer, 0, usbd_xfer_max_len(xfer)); + usbd_transfer_submit(xfer); + return; + + default: /* Error */ + if (error != USB_ERR_CANCELLED) { + /* try to clear stall first */ + usbd_xfer_set_stall(xfer); + goto tr_setup; + } + return; + } +} + +static int +udbc_pre_param(struct ucom_softc *ucom, struct termios *t) +{ + DPRINTF("\n"); + + return (0); +} + +static int +udbc_ioctl(struct ucom_softc *ucom, uint32_t cmd, caddr_t data, int flag, + struct thread *td) +{ + return (ENOIOCTL); +} + +static void +udbc_start_read(struct ucom_softc *ucom) +{ + struct udbc_softc *sc = ucom->sc_parent; + + usbd_transfer_start(sc->sc_xfer[UDBC_BULK_DT_RD]); +} + +static void +udbc_stop_read(struct ucom_softc *ucom) +{ + struct udbc_softc *sc = ucom->sc_parent; + + usbd_transfer_stop(sc->sc_xfer[UDBC_BULK_DT_RD]); +} + +static void +udbc_start_write(struct ucom_softc *ucom) +{ + struct udbc_softc *sc = ucom->sc_parent; + + usbd_transfer_start(sc->sc_xfer[UDBC_BULK_DT_WR]); +} + +static void +udbc_stop_write(struct ucom_softc *ucom) +{ + struct udbc_softc *sc = ucom->sc_parent; + + usbd_transfer_stop(sc->sc_xfer[UDBC_BULK_DT_WR]); +} + +static void +udbc_poll(struct ucom_softc *ucom) +{ + struct udbc_softc *sc = ucom->sc_parent; + + usbd_transfer_poll(sc->sc_xfer, UDBC_N_TRANSFER); +} + +static driver_t udbc_driver = { + .name = "udbc", + .methods = udbc_methods, + .size = sizeof(struct udbc_softc), +}; + +DRIVER_MODULE(udbc, uhub, udbc_driver, NULL, NULL); +MODULE_DEPEND(udbc, ucom, 1, 1, 1); +MODULE_DEPEND(udbc, usb, 1, 1, 1); +MODULE_VERSION(udbc, 1); diff --git a/sys/modules/usb/Makefile b/sys/modules/usb/Makefile index 1290b878fa37..d9b1c8635b30 100644 --- a/sys/modules/usb/Makefile +++ b/sys/modules/usb/Makefile @@ -46,10 +46,9 @@ SUBDIR = usb SUBDIR += ${_dwc_otg} ehci ${_musb} ohci uhci xhci ${_uss820dci} \ ${_atmegadci} ${_avr32dci} ${_rsu} ${_rsufw} ${_bcm2838_xhci} SUBDIR += mtw ${_rum} ${_run} ${_runfw} ${_uath} upgt usie ural ${_zyd} ${_urtw} -SUBDIR += atp cfumass uhid uhid_snes ukbd ums udbp uep wmt wsp ugold uled \ - usbhid -SUBDIR += ucom u3g uark ubsa ubser uchcom ucycom ufoma uftdi ugensa uipaq ulpt \ - umb umct umcs umodem umoscom uplcom uslcom uvisor uvscom +SUBDIR += atp cfumass uhid uhid_snes ukbd ums udbp uep wmt wsp ugold uled usbhid +SUBDIR += ucom u3g uark ubsa ubser uchcom ucycom udbc ufoma uftdi ugensa uipaq +SUBDIR += ulpt umb umct umcs umodem umoscom uplcom uslcom uvisor uvscom SUBDIR += i2ctinyusb SUBDIR += cp2112 SUBDIR += udl diff --git a/sys/modules/usb/udbc/Makefile b/sys/modules/usb/udbc/Makefile new file mode 100644 index 000000000000..9996b2e391fb --- /dev/null +++ b/sys/modules/usb/udbc/Makefile @@ -0,0 +1,9 @@ +S= ${SRCTOP}/sys + +.PATH: $S/dev/usb/serial + +KMOD= udbc +SRCS= opt_bus.h opt_usb.h device_if.h bus_if.h usb_if.h usbdevs.h \ + udbc.c + +.include From nobody Thu Sep 18 12:54:22 2025 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 4cSFvf5X8Wz68Kjd; Thu, 18 Sep 2025 12:54:22 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSFvf4fBPz3Y14; Thu, 18 Sep 2025 12:54:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758200062; 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=rMiVpT+6XWWnHfICsiHfPuQAw3johSmYiVBJCv2q2QU=; b=k4w3vHbkGA/clPwfhVWKYe5aOEupo3teeGHvH4Z24DiTPeK4GeVUKZarn/PL+HCxRulZls F+24XexmPD6Ubnj4vhHbgBC/bKrub9sxDHNVfMJeVHFBytMyyWrTnPwlk3IjxahSfPxdTa aKmKpRWG+3xpQYonMCueHbfYqZW7vN27E2H52KnNFtb/px2LPo4+EgawrNDMSWJ43DNJQ9 NsDo25Fe6jZ6wo+kN8+DRdE6f4H2sThTp5jzYFTP0domZNbld9pZJHT813R06GC5FBwjY3 fB3xD2DYTgkS1f/BuNIc4sR7rovnJnpv0EBqCwEBI/BE4ByqPbnSqZUud0kjpQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758200062; 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=rMiVpT+6XWWnHfICsiHfPuQAw3johSmYiVBJCv2q2QU=; b=JvFFcnq/bNx/jJyXG8Pc2jVB11esBCRVGll9Lnvb3fPssnVhe0lG31A1wOzM67D2OTHJ2D RU9EwToUakMX2JI2QwhjYg+WGjDieCiMeOpmJdv9q1ogPn/rdAeDFUvCNnmOTdQbZNz/Ho fj3tCOYT6+KAVk8YnA8mnxMyEAKUFjEvlReFl0X+iaJ3EWcRrlZYCfbL0tpvwcf12P/7iD ZXCs/QREr6+nphKWMO9UlP8vRjtDPp6gXrO9Qd19wI833YF5hYJ+68G3Zeyj9ycUfWw/hy nHDPsIHzDMXs7gNJuhVSejqumlsy4ku68A534cphb1k1HNBCO+vfIBg5COEOZQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758200062; a=rsa-sha256; cv=none; b=ajUTaIBryl124bLIxUti+yVVMTT6tTzxVX9a12eyVXslBRqGyqLhlTmlHxRQ7ZvHacvk4k Hys98XNBW3WpLJrtq/cufiZ1byX13wl7Ea4lCP3OmXUNZVxhOnyMPYg+RECbqYc7OgbO60 M/PtIVz4RBFjEAO1fAsyBNQrlFDy0dJ+Ra93wmDMC7AaynEG3lbTW4Vn78wulfCBHcCxDm sy/7NkHQUtn0oaZl1CQK2VWcwhfKvzsnWi0dDDSAt/nJ9BbqOiztJ2AHMUyGDI+vJiiZa+ UxQvhlViQM/YADFxrdMsVheUrsML8liqfwe/WDB7VzX+1AlwktKcrv28tKDBnA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSFvf481Nz1Bbb; Thu, 18 Sep 2025 12:54:22 +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 58ICsM3I072826; Thu, 18 Sep 2025 12:54:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58ICsM9C072823; Thu, 18 Sep 2025 12:54:22 GMT (envelope-from git) Date: Thu, 18 Sep 2025 12:54:22 GMT Message-Id: <202509181254.58ICsM9C072823@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Tom Jones Subject: git: e8d181eeb204 - stable/15 - udbc(4): connect to build 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: thj X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: e8d181eeb204f06b6a66841baa2c78bd64ae378f Auto-Submitted: auto-generated The branch stable/15 has been updated by thj: URL: https://cgit.FreeBSD.org/src/commit/?id=e8d181eeb204f06b6a66841baa2c78bd64ae378f commit e8d181eeb204f06b6a66841baa2c78bd64ae378f Author: Li-Wen Hsu AuthorDate: 2025-09-15 18:34:43 +0000 Commit: Tom Jones CommitDate: 2025-09-18 12:53:13 +0000 udbc(4): connect to build Reviewed by: thj MFC with: d566b6a70bcbc329e8c690464043401fa8bdd49f Sponsored by: The FreeBSD Foundation (cherry picked from commit a75c3c2c633dfa29b628f692fc7274cab1920640) --- share/man/man4/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/share/man/man4/Makefile b/share/man/man4/Makefile index 1d708cfda019..c454a696f112 100644 --- a/share/man/man4/Makefile +++ b/share/man/man4/Makefile @@ -1065,6 +1065,7 @@ MAN+= \ ucom.4 \ ucycom.4 \ udav.4 \ + udbc.4 \ udbp.4 \ udl.4 \ uep.4 \ From nobody Thu Sep 18 13:01:27 2025 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 4cSG3q6Zwdz68LHW; Thu, 18 Sep 2025 13:01:27 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSG3q5sBCz3b3m; Thu, 18 Sep 2025 13:01:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758200487; 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=Gs/IE/VUzGJXzZE+Xwwx4ahAUklmXyUemf2F1TljXZE=; b=eTLAwEJcnWbomP05jCbffLd7sruWsjwIxgRFXp6b8vB01GzZvHXMcL6jBykS+RQHhhswdm cI2eRMuurSP/SIDInktBYVTZeF+LQ1Gs0qyZ4unZxbmN32zAxrJHyb4TybVnpzvfrtxpqR S4pRCsViWqGhdfT5PEIDP0/MLOfEcEPiDDYmBmopH4tJm7+ieyyYo60uw+YPuwN4Di2yC7 1E+TO03f+Aw+QmJtlu5HIGbUt1KuOQQNtS85ysGclrIVsF25a1Av9pDgzX2h4pw0fab+AA FIhWo4zVGkF49H0fnxrISXb921uiaxpjJeVcC95caeoznf+S+WNXMN4KNwqUrQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758200487; 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=Gs/IE/VUzGJXzZE+Xwwx4ahAUklmXyUemf2F1TljXZE=; b=FaFPTzHGIuOiGjO/WTwixTSpi/4d0mistfJ3MUl7W1ac9jnuDUl1JZqvGnmTJYG16ftwFF 6q9f1O2YWOvmI2xInTwYoxmxlbBsr6V11o6UpRRFUQ5bPaYfePFJlNYuvfBpxy4M5xHgjX jTEGu46xkzVElMPSx8UVemYlvi2TUniHs1GrdJD7nBZeoPUzbST9GrCQ9KA3affwNHlhnM Plaz6YYHmrNB/8mU+bc1/8/wGdE1wJ1B+OclXoEO94jbUIAYJDSQ4X6yVsCcfm6y8AG0PK f5QL0Q+hgxIG6BqA4jz04Oc9bZ2C5DJOdt+sWW7o12ozkWfY4gB3YPVnjAB4Gg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758200487; a=rsa-sha256; cv=none; b=nkRok+K53KSCu+fo211YIJ5DgQdcXYgcXJQjwhsCBdREMjKb6GMy+udiiDrSi3WGGJg+hu sQT43FU4HDwZXt2Cjb3W7DvMsfCoDpBMGoL+2t2+FM/8v23RYk5CvBcG1bOk55ATziQY0y vvh9B5yKer4nBHT+st9CLc3RMU8XfKm2NwyNY3km0wYkmcsqFAXlT6cv+PxabQciHbtLBY rnvgoetLpr8ZxfNWWq7v58xBX8KTm5q0fFfGCvdrm/1wOcjet5YKRtt0FPesMAXUtphadr zduFsvAxFf6KzqRA5hHPlq3N5EPgfgKjd6h6NU8dLS9o3V5UnKyJawXHdx4Wrg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSG3q5RpJz1BHq; Thu, 18 Sep 2025 13:01:27 +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 58ID1R5h090556; Thu, 18 Sep 2025 13:01:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58ID1RCH090554; Thu, 18 Sep 2025 13:01:27 GMT (envelope-from git) Date: Thu, 18 Sep 2025 13:01:27 GMT Message-Id: <202509181301.58ID1RCH090554@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: df997faca841 - main - atf_pytest: fix xfail detection from pytest report 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: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: df997faca8411bdf8008c25de5db3ed719019d21 Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=df997faca8411bdf8008c25de5db3ed719019d21 commit df997faca8411bdf8008c25de5db3ed719019d21 Author: Siva Mahadevan AuthorDate: 2025-09-17 20:34:58 +0000 Commit: Ed Maste CommitDate: 2025-09-18 13:01:14 +0000 atf_pytest: fix xfail detection from pytest report The location of the 'wasxfail' attribute was moved from the 'reason' attribute back to the parent 'report'. This fixes an issue where xfails are wrongly reported to ATF as skipped tests. Signed-off-by: Siva Mahadevan Pull-request: https://github.com/freebsd/freebsd-src/pull/1849 Sponsored by: The FreeBSD Foundation --- tests/atf_python/atf_pytest.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/atf_python/atf_pytest.py b/tests/atf_python/atf_pytest.py index 19b5f88fa200..02ed502ace67 100644 --- a/tests/atf_python/atf_pytest.py +++ b/tests/atf_python/atf_pytest.py @@ -256,7 +256,7 @@ class ATFHandler(object): # Record failure & override "skipped" state self.set_report_state(test_name, state, reason) elif state == "skipped": - if hasattr(reason, "wasxfail"): + if hasattr(report, "wasxfail"): # xfail() called in the test body state = "expected_failure" else: @@ -264,7 +264,7 @@ class ATFHandler(object): pass self.set_report_state(test_name, state, reason) elif state == "passed": - if hasattr(reason, "wasxfail"): + if hasattr(report, "wasxfail"): # the test was expected to fail but didn't # mark as hard failure state = "failed" From nobody Thu Sep 18 14:35:32 2025 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 4cSJ8N2hCLz67Tpx; Thu, 18 Sep 2025 14:35:32 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSJ8N20Pqz3rsV; Thu, 18 Sep 2025 14:35:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758206132; 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=83otVyIY/8Jp7wB+OAtu+b+uCe8GBQDJ8E1r7S4FiI8=; b=M0Pwi9j1POXQnSKRQNu951zUbnV66Qtw4OtCYCYClvemn8qyb8ibyqWnACYvEhHHPG0mjI r6BhofBm5YA4wXwc+ajLsQ93gL0QQGHJOfg1LMAMT7DTUxtFoR28khJ/KOp3oti8XHZssN gC0isCqhooKuCdUIK1xRiVJhw9x1UQ2U38asUCiJ7u8o9fLY7tpNte0JZCDoJeU3GPQJMk XSbP13WSa+2h9OHs1O90aa2e/SCZHrrRkR66dRiVqlnj7eVgdO6SZV9as3E1oorgiaBB2+ +YJ5vVHH7kVhcxxnMkzdRGSaBY3bDDLKKHQp717MaFW9gm5lT8WlJqEWV2/fnw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758206132; 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=83otVyIY/8Jp7wB+OAtu+b+uCe8GBQDJ8E1r7S4FiI8=; b=FP2ciyIb0lj0c8YogKPdaGpZIXh7xcXkV8uk89WoJcW8Yhzkd3P4bPssv3oItQoYyIBW4j 0auQfSscp4uevjpyvcARtvNsBJmgBYHpxCV4ewdcxV2fDER9AfULI8/ecVwLN9+xex+iEP MQdBD9Rr4ztK7t5cJ7bINq3Ww5EQAlq/mUEoD0hqMIK0SJbnGAKNtO44QEraZkMh2ELNsn Njunk+zItjOWAnDD0NZ2CmP1fKj11fetryhIxM7IqzBc+PmlnOfLph+9wGnWnUwlXB+rEI xWjGyLCPV5w5BZo1RnMj1Ve5nZoEP2uDXcHJ67Kxde3gbI2lu0wVEFciMmhrPA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758206132; a=rsa-sha256; cv=none; b=ZJ9GLzq5TxuHH792qcrHpnP7qlMznC2TpjXlZtuhPBOzTUysqKOq1mefl63d3TEUDNV0Au nyInjuy99/z6par6PL7SMSLXidjaR1tG1e28U4SYhE41YttV9E8bAWeplrkqNUd+Zvpm7c gExOKZviB0jDrVNaDnIbj7cmWB3FDCsqwWsbl3fSEbimrgt0YlszMJJvOtChAxeR7hVE/j QaQONC6BT+nLEN8RtuHFemxHfhUrnXL3Wa1zPRPasYzxCrKCE3a+Z/HCyICWPK4CT7+wFl lyTsQGqJsz/PRDGh5W1qLgloQazwEoVPgPT5SHzGYhJ8UJ9fF7fJwderzNNOsA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSJ8N1PLqztp; Thu, 18 Sep 2025 14:35:32 +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 58IEZWJM061323; Thu, 18 Sep 2025 14:35:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IEZW8g061320; Thu, 18 Sep 2025 14:35:32 GMT (envelope-from git) Date: Thu, 18 Sep 2025 14:35:32 GMT Message-Id: <202509181435.58IEZW8g061320@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jaeyoon Choi Subject: git: 380e4a8233c8 - main - committers-src: add myself (jaeyoon@) 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: jaeyoon X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 380e4a8233c8e17877b0bcdfb8003b3e9638071b Auto-Submitted: auto-generated The branch main has been updated by jaeyoon: URL: https://cgit.FreeBSD.org/src/commit/?id=380e4a8233c8e17877b0bcdfb8003b3e9638071b commit 380e4a8233c8e17877b0bcdfb8003b3e9638071b Author: Jaeyoon Choi AuthorDate: 2025-09-18 14:31:07 +0000 Commit: Jaeyoon Choi CommitDate: 2025-09-18 14:34:52 +0000 committers-src: add myself (jaeyoon@) Add myself (jaeyoon@) as a new src committer with imp@ as my mentor. Reviewed by: imp (mentor) Approved by: imp (mentor) Differential Revision: https://reviews.freebsd.org/D52570 --- share/misc/committers-src.dot | 2 ++ 1 file changed, 2 insertions(+) diff --git a/share/misc/committers-src.dot b/share/misc/committers-src.dot index 73d142b875f2..6035dd031216 100644 --- a/share/misc/committers-src.dot +++ b/share/misc/committers-src.dot @@ -211,6 +211,7 @@ igoro [label="Igor Ostapenko\nigoro@FreeBSD.org\n2024/08/22"] imp [label="Warner Losh\nimp@FreeBSD.org\n1996/09/20"] ivoras [label="Ivan Voras\nivoras@FreeBSD.org\n2008/06/10"] ivy [label="Lexi Winter\nivy@FreeBSD.org\n2025/04/18"] +jaeyoon [label="Jaeyoon Choi\njaeyoon@FreeBSD.org\n2025/09/09"] jah [label="Jason A. Harmening\njah@FreeBSD.org\n2015/03/08"] jamie [label="Jamie Gritton\njamie@FreeBSD.org\n2009/01/28"] jasone [label="Jason Evans\njasone@FreeBSD.org\n1999/03/03"] @@ -642,6 +643,7 @@ imp -> toshi imp -> tsoome imp -> uch imp -> vexeduxr +imp -> jaeyoon jake -> bms jake -> gordon From nobody Thu Sep 18 14:42:04 2025 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 4cSJHw3Sqzz67Tr7; Thu, 18 Sep 2025 14:42:04 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSJHw2rk2z3s6J; Thu, 18 Sep 2025 14:42:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758206524; 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=P0S+VvjU3P5YYEdyc2qgdstKcU5beesa6IKj0CysRgc=; b=R+Ec3YpRBV2uMR9BVEx1tlFJJqFmx6aRl9ypMqGaEW8clITtIVtC/cPpJ4L1DEmSxiLHCr L2TALN4IazLp1OdaFVf+cNv1M80ubNZn/WEUQczs7b4a0iCsQNjsEBAXARMCW3VuACphcg Y3pka3sV5KfWfQeH5WkUpTzJayqlpb8le2jNyElE0RrFIkOdSvYk/0Jtovf6NOpfbON9L6 deFgdpvnm8adnNbc2eP2pRXsty2FffuzlM6xY2zjQB4Yu/uQM+POsLfsCdbh4uHKkNdk0M TA1rDib3dHeQ34X2iAiV3N4xuLC37JNxMrU7ahbj1fHdKg5rs3UGNyXqFDuf1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758206524; 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=P0S+VvjU3P5YYEdyc2qgdstKcU5beesa6IKj0CysRgc=; b=q9tQ6NcRmPxpo3pyU1VtBfAuOOQjsfwX6/3QqoP3TGXlPTbWLHfBh6M8gWliI70yXKdDF4 +H+Ab9ehrgtPa7/Nbnqf8eeHWVQftNUVXZCz0RzKBYqQErANDsP6x55HcfNEXtAJIa1lkB jaXCpRlMjQAMMrbKcLTDxOF92tCOb79LVIGrYaorXN0mmSfUVsS0ZQr8yWsgxHlVhmAsbR M5upo1sy6JKCPGAukBRjG1S09hoBW4DnQTvaKvz2G+at9gogL11VPK5k4mk0bLZ5xmLzI0 CfAEwpcbie6P1QgzXjo3umK3BKIG+qnSYyCubs3c1FHA7ilIQAJS5/rk5oitiw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758206524; a=rsa-sha256; cv=none; b=o09smn/3mIHR6O7vO0BrTajdiVJ1EP6EPbr+MDV0H89Uv/PoocxYoyjA7dYu41q5ChYCbg BWxzvelzDxBr1fF3zNMZpPgdM+iPnsyW8/VVvBwgWWwWf2+EwJP3M7XiTtOE9KtqJnSDtl tCNrpELZZqD8WvDYVEvuxJi/i4J3jNqlJYRXnsatzfMmFCTvRvq7NILtc/6a/hphw227ZY VkU5kFZERde5wufkWSo8skmKApUx/7Xp0+RfWeZZ2rGa3+UwsTqmfd+J+2Woq+vGNrvikb AGz3s6CKekqFp/3KJh/+NxrVg6JWcDUH49KD/jcoEF9yYELDLuXhaMIwzquZVg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSJHw2QxLzvL; Thu, 18 Sep 2025 14:42:04 +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 58IEg4el077835; Thu, 18 Sep 2025 14:42:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IEg4UQ077832; Thu, 18 Sep 2025 14:42:04 GMT (envelope-from git) Date: Thu, 18 Sep 2025 14:42:04 GMT Message-Id: <202509181442.58IEg4UQ077832@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jaeyoon Choi Subject: git: 6b841d70960a - main - ufshci: revisit controller reset path and add I/O timeout handling 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: jaeyoon X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6b841d70960a3a0ec4e43392683053878c403f9c Auto-Submitted: auto-generated The branch main has been updated by jaeyoon: URL: https://cgit.FreeBSD.org/src/commit/?id=6b841d70960a3a0ec4e43392683053878c403f9c commit 6b841d70960a3a0ec4e43392683053878c403f9c Author: Jaeyoon Choi AuthorDate: 2025-09-18 14:37:08 +0000 Commit: Jaeyoon Choi CommitDate: 2025-09-18 14:41:47 +0000 ufshci: revisit controller reset path and add I/O timeout handling This patch revisits the controller reset path and introduces timeout handling for I/O commands. To support controller reset during driver operation, the controller’s construct, destruct, enable, and disable functions are clearly separated in ufshci_ctrlr.c. ufshci_ctrlr_hw_reset() function is added to leverage enable/disable. After initialization, ufshci_ctrlr_reset_task() is also introduced to ensure controller resets are performed via the task queue. Timeout handling is designed in five steps. This patch implements Step 1 and Step 5, while the remaining steps will be added later. The timeout mechanism follows the same shared timeout model used in the NVMe driver. Test: Intentionally delayed UPIU I/O in QEMU to trigger a timeout and verify timeout handling. Sponsored by: Samsung Electronics Reviewed by: imp (mentor) Differential Revision: https://reviews.freebsd.org/D52440 --- sys/dev/ufshci/ufshci_ctrlr.c | 399 +++++++++++++++++++++++--------------- sys/dev/ufshci/ufshci_ctrlr_cmd.c | 2 +- sys/dev/ufshci/ufshci_dev.c | 1 - sys/dev/ufshci/ufshci_pci.c | 3 +- sys/dev/ufshci/ufshci_private.h | 41 +++- sys/dev/ufshci/ufshci_req_queue.c | 292 ++++++++++++++++++++++++++-- sys/dev/ufshci/ufshci_req_sdb.c | 77 +++++++- sys/dev/ufshci/ufshci_sim.c | 1 - 8 files changed, 633 insertions(+), 183 deletions(-) diff --git a/sys/dev/ufshci/ufshci_ctrlr.c b/sys/dev/ufshci/ufshci_ctrlr.c index 36be94b8b8b7..35663b480cfa 100644 --- a/sys/dev/ufshci/ufshci_ctrlr.c +++ b/sys/dev/ufshci/ufshci_ctrlr.c @@ -12,8 +12,108 @@ #include "ufshci_private.h" #include "ufshci_reg.h" +static void +ufshci_ctrlr_fail(struct ufshci_controller *ctrlr) +{ + ctrlr->is_failed = true; + + ufshci_req_queue_fail(ctrlr, + ctrlr->task_mgmt_req_queue.qops.get_hw_queue( + &ctrlr->task_mgmt_req_queue)); + ufshci_req_queue_fail(ctrlr, + ctrlr->transfer_req_queue.qops.get_hw_queue( + &ctrlr->transfer_req_queue)); +} + +static void +ufshci_ctrlr_start(struct ufshci_controller *ctrlr, bool resetting) +{ + TSENTER(); + + /* + * If `resetting` is true, we are on the reset path. + * Re-enable request queues here because ufshci_ctrlr_reset_task() + * disables them during reset. + */ + if (resetting) { + if (ufshci_utmr_req_queue_enable(ctrlr) != 0) { + ufshci_ctrlr_fail(ctrlr); + return; + } + if (ufshci_utr_req_queue_enable(ctrlr) != 0) { + ufshci_ctrlr_fail(ctrlr); + return; + } + } + + if (ufshci_ctrlr_send_nop(ctrlr) != 0) { + ufshci_ctrlr_fail(ctrlr); + return; + } + + /* Initialize UFS target drvice */ + if (ufshci_dev_init(ctrlr) != 0) { + ufshci_ctrlr_fail(ctrlr); + return; + } + + /* Initialize Reference Clock */ + if (ufshci_dev_init_reference_clock(ctrlr) != 0) { + ufshci_ctrlr_fail(ctrlr); + return; + } + + /* Initialize unipro */ + if (ufshci_dev_init_unipro(ctrlr) != 0) { + ufshci_ctrlr_fail(ctrlr); + return; + } + + /* + * Initialize UIC Power Mode + * QEMU UFS devices do not support unipro and power mode. + */ + if (!(ctrlr->quirks & UFSHCI_QUIRK_IGNORE_UIC_POWER_MODE) && + ufshci_dev_init_uic_power_mode(ctrlr) != 0) { + ufshci_ctrlr_fail(ctrlr); + return; + } + + /* Initialize UFS Power Mode */ + if (ufshci_dev_init_ufs_power_mode(ctrlr) != 0) { + ufshci_ctrlr_fail(ctrlr); + return; + } + + /* Read Controller Descriptor (Device, Geometry) */ + if (ufshci_dev_get_descriptor(ctrlr) != 0) { + ufshci_ctrlr_fail(ctrlr); + return; + } + + if (ufshci_dev_config_write_booster(ctrlr)) { + ufshci_ctrlr_fail(ctrlr); + return; + } + + /* TODO: Configure Write Protect */ + + /* TODO: Configure Background Operations */ + + /* + * If the reset is due to a timeout, it is already attached to the SIM + * and does not need to be attached again. + */ + if (!resetting && ufshci_sim_attach(ctrlr) != 0) { + ufshci_ctrlr_fail(ctrlr); + return; + } + + TSEXIT(); +} + static int -ufshci_ctrlr_enable_host_ctrlr(struct ufshci_controller *ctrlr) +ufshci_ctrlr_disable_host_ctrlr(struct ufshci_controller *ctrlr) { int timeout = ticks + MSEC_2_TICKS(ctrlr->device_init_timeout_in_ms); sbintime_t delta_t = SBT_1US; @@ -27,6 +127,35 @@ ufshci_ctrlr_enable_host_ctrlr(struct ufshci_controller *ctrlr) ufshci_mmio_write_4(ctrlr, hce, hce); } + /* Wait for the HCE flag to change */ + while (1) { + hce = ufshci_mmio_read_4(ctrlr, hce); + if (!UFSHCIV(UFSHCI_HCE_REG_HCE, hce)) + break; + if (timeout - ticks < 0) { + ufshci_printf(ctrlr, + "host controller failed to disable " + "within %d ms\n", + ctrlr->device_init_timeout_in_ms); + return (ENXIO); + } + + pause_sbt("ufshci_disable_hce", delta_t, 0, C_PREL(1)); + delta_t = min(SBT_1MS, delta_t * 3 / 2); + } + + return (0); +} + +static int +ufshci_ctrlr_enable_host_ctrlr(struct ufshci_controller *ctrlr) +{ + int timeout = ticks + MSEC_2_TICKS(ctrlr->device_init_timeout_in_ms); + sbintime_t delta_t = SBT_1US; + uint32_t hce; + + hce = ufshci_mmio_read_4(ctrlr, hce); + /* Enable UFS host controller */ hce |= UFSHCIM(UFSHCI_HCE_REG_HCE); ufshci_mmio_write_4(ctrlr, hce, hce); @@ -36,7 +165,7 @@ ufshci_ctrlr_enable_host_ctrlr(struct ufshci_controller *ctrlr) * unstable, so we need to read the HCE value after some time after * initialization is complete. */ - pause_sbt("ufshci_hce", ustosbt(100), 0, C_PREL(1)); + pause_sbt("ufshci_enable_hce", ustosbt(100), 0, C_PREL(1)); /* Wait for the HCE flag to change */ while (1) { @@ -51,17 +180,103 @@ ufshci_ctrlr_enable_host_ctrlr(struct ufshci_controller *ctrlr) return (ENXIO); } - pause_sbt("ufshci_hce", delta_t, 0, C_PREL(1)); + pause_sbt("ufshci_enable_hce", delta_t, 0, C_PREL(1)); delta_t = min(SBT_1MS, delta_t * 3 / 2); } return (0); } +static int +ufshci_ctrlr_disable(struct ufshci_controller *ctrlr) +{ + int error; + + /* Disable all interrupts */ + ufshci_mmio_write_4(ctrlr, ie, 0); + + error = ufshci_ctrlr_disable_host_ctrlr(ctrlr); + return (error); +} + +static int +ufshci_ctrlr_enable(struct ufshci_controller *ctrlr) +{ + uint32_t ie, hcs; + int error; + + error = ufshci_ctrlr_enable_host_ctrlr(ctrlr); + if (error) + return (error); + + /* Send DME_LINKSTARTUP command to start the link startup procedure */ + error = ufshci_uic_send_dme_link_startup(ctrlr); + if (error) + return (error); + + /* + * The device_present(UFSHCI_HCS_REG_DP) bit becomes true if the host + * controller has successfully received a Link Startup UIC command + * response and the UFS device has found a physical link to the + * controller. + */ + hcs = ufshci_mmio_read_4(ctrlr, hcs); + if (!UFSHCIV(UFSHCI_HCS_REG_DP, hcs)) { + ufshci_printf(ctrlr, "UFS device not found\n"); + return (ENXIO); + } + + /* Enable additional interrupts by programming the IE register. */ + ie = ufshci_mmio_read_4(ctrlr, ie); + ie |= UFSHCIM(UFSHCI_IE_REG_UTRCE); /* UTR Completion */ + ie |= UFSHCIM(UFSHCI_IE_REG_UEE); /* UIC Error */ + ie |= UFSHCIM(UFSHCI_IE_REG_UTMRCE); /* UTMR Completion */ + ie |= UFSHCIM(UFSHCI_IE_REG_DFEE); /* Device Fatal Error */ + ie |= UFSHCIM(UFSHCI_IE_REG_UTPEE); /* UTP Error */ + ie |= UFSHCIM(UFSHCI_IE_REG_HCFEE); /* Host Ctrlr Fatal Error */ + ie |= UFSHCIM(UFSHCI_IE_REG_SBFEE); /* System Bus Fatal Error */ + ie |= UFSHCIM(UFSHCI_IE_REG_CEFEE); /* Crypto Engine Fatal Error */ + ufshci_mmio_write_4(ctrlr, ie, ie); + + /* TODO: Initialize interrupt Aggregation Control Register (UTRIACR) */ + + return (0); +} + +static int +ufshci_ctrlr_hw_reset(struct ufshci_controller *ctrlr) +{ + int error; + + error = ufshci_ctrlr_disable(ctrlr); + if (error) + return (error); + + error = ufshci_ctrlr_enable(ctrlr); + return (error); +} + +static void +ufshci_ctrlr_reset_task(void *arg, int pending) +{ + struct ufshci_controller *ctrlr = arg; + int error; + + /* Release resources */ + ufshci_utmr_req_queue_disable(ctrlr); + ufshci_utr_req_queue_disable(ctrlr); + + error = ufshci_ctrlr_hw_reset(ctrlr); + if (error) + return (ufshci_ctrlr_fail(ctrlr)); + + ufshci_ctrlr_start(ctrlr, true); +} + int ufshci_ctrlr_construct(struct ufshci_controller *ctrlr, device_t dev) { - uint32_t ver, cap, hcs, ie, ahit; + uint32_t ver, cap, ahit; uint32_t timeout_period, retry_count; int error; @@ -114,16 +329,15 @@ ufshci_ctrlr_construct(struct ufshci_controller *ctrlr, device_t dev) TUNABLE_INT_FETCH("hw.ufshci.retry_count", &retry_count); ctrlr->retry_count = retry_count; - /* Disable all interrupts */ - ufshci_mmio_write_4(ctrlr, ie, 0); - - /* Enable Host Controller */ - error = ufshci_ctrlr_enable_host_ctrlr(ctrlr); - if (error) - return (error); + ctrlr->enable_aborts = 1; + if (ctrlr->quirks & UFSHCI_QUIRK_NOT_SUPPORT_ABORT_TASK) + ctrlr->enable_aborts = 0; + else + TUNABLE_INT_FETCH("hw.ufshci.enable_aborts", + &ctrlr->enable_aborts); - /* Send DME_LINKSTARTUP command to start the link startup procedure */ - error = ufshci_uic_send_dme_link_startup(ctrlr); + /* Reset the UFSHCI controller */ + error = ufshci_ctrlr_hw_reset(ctrlr); if (error) return (error); @@ -134,18 +348,6 @@ ufshci_ctrlr_construct(struct ufshci_controller *ctrlr, device_t dev) ahit = 0; ufshci_mmio_write_4(ctrlr, ahit, ahit); - /* - * The device_present(UFSHCI_HCS_REG_DP) bit becomes true if the host - * controller has successfully received a Link Startup UIC command - * response and the UFS device has found a physical link to the - * controller. - */ - hcs = ufshci_mmio_read_4(ctrlr, hcs); - if (!UFSHCIV(UFSHCI_HCS_REG_DP, hcs)) { - ufshci_printf(ctrlr, "UFS device not found\n"); - return (ENXIO); - } - /* Allocate and initialize UTP Task Management Request List. */ error = ufshci_utmr_req_queue_construct(ctrlr); if (error) @@ -156,27 +358,21 @@ ufshci_ctrlr_construct(struct ufshci_controller *ctrlr, device_t dev) if (error) return (error); - /* Enable additional interrupts by programming the IE register. */ - ie = ufshci_mmio_read_4(ctrlr, ie); - ie |= UFSHCIM(UFSHCI_IE_REG_UTRCE); /* UTR Completion */ - ie |= UFSHCIM(UFSHCI_IE_REG_UEE); /* UIC Error */ - ie |= UFSHCIM(UFSHCI_IE_REG_UTMRCE); /* UTMR Completion */ - ie |= UFSHCIM(UFSHCI_IE_REG_DFEE); /* Device Fatal Error */ - ie |= UFSHCIM(UFSHCI_IE_REG_UTPEE); /* UTP Error */ - ie |= UFSHCIM(UFSHCI_IE_REG_HCFEE); /* Host Ctrlr Fatal Error */ - ie |= UFSHCIM(UFSHCI_IE_REG_SBFEE); /* System Bus Fatal Error */ - ie |= UFSHCIM(UFSHCI_IE_REG_CEFEE); /* Crypto Engine Fatal Error */ - ufshci_mmio_write_4(ctrlr, ie, ie); - - /* TODO: Initialize interrupt Aggregation Control Register (UTRIACR) */ - /* TODO: Separate IO and Admin slot */ + /* * max_hw_pend_io is the number of slots in the transfer_req_queue. * Reduce num_entries by one to reserve an admin slot. */ ctrlr->max_hw_pend_io = ctrlr->transfer_req_queue.num_entries - 1; + /* Create a thread for the taskqueue. */ + ctrlr->taskqueue = taskqueue_create("ufshci_taskq", M_WAITOK, + taskqueue_thread_enqueue, &ctrlr->taskqueue); + taskqueue_start_threads(&ctrlr->taskqueue, 1, PI_DISK, "ufshci taskq"); + + TASK_INIT(&ctrlr->reset_task, 0, ufshci_ctrlr_reset_task, ctrlr); + return (0); } @@ -208,50 +404,21 @@ ufshci_ctrlr_destruct(struct ufshci_controller *ctrlr, device_t dev) bus_release_resource(dev, SYS_RES_MEMORY, ctrlr->resource_id, ctrlr->resource); nores: + KASSERT(!mtx_owned(&ctrlr->uic_cmd_lock), + ("destroying uic_cmd_lock while still owned")); mtx_destroy(&ctrlr->uic_cmd_lock); + + KASSERT(!mtx_owned(&ctrlr->sc_mtx), + ("destroying sc_mtx while still owned")); mtx_destroy(&ctrlr->sc_mtx); return; } -int +void ufshci_ctrlr_reset(struct ufshci_controller *ctrlr) { - uint32_t ie; - int error; - - /* Backup and disable all interrupts */ - ie = ufshci_mmio_read_4(ctrlr, ie); - ufshci_mmio_write_4(ctrlr, ie, 0); - - /* Release resources */ - ufshci_utmr_req_queue_destroy(ctrlr); - ufshci_utr_req_queue_destroy(ctrlr); - - /* Reset Host Controller */ - error = ufshci_ctrlr_enable_host_ctrlr(ctrlr); - if (error) - return (error); - - /* Send DME_LINKSTARTUP command to start the link startup procedure */ - error = ufshci_uic_send_dme_link_startup(ctrlr); - if (error) - return (error); - - /* Enable interrupts */ - ufshci_mmio_write_4(ctrlr, ie, ie); - - /* Allocate and initialize UTP Task Management Request List. */ - error = ufshci_utmr_req_queue_construct(ctrlr); - if (error) - return (error); - - /* Allocate and initialize UTP Transfer Request List or SQ/CQ. */ - error = ufshci_utr_req_queue_construct(ctrlr); - if (error) - return (error); - - return (0); + taskqueue_enqueue(ctrlr->taskqueue, &ctrlr->reset_task); } int @@ -295,84 +462,6 @@ ufshci_ctrlr_send_nop(struct ufshci_controller *ctrlr) return (0); } -static void -ufshci_ctrlr_fail(struct ufshci_controller *ctrlr, bool admin_also) -{ - printf("ufshci(4): ufshci_ctrlr_fail\n"); - - ctrlr->is_failed = true; - - /* TODO: task_mgmt_req_queue should be handled as fail */ - - ufshci_req_queue_fail(ctrlr, - &ctrlr->transfer_req_queue.hwq[UFSHCI_SDB_Q]); -} - -static void -ufshci_ctrlr_start(struct ufshci_controller *ctrlr) -{ - TSENTER(); - - if (ufshci_ctrlr_send_nop(ctrlr) != 0) { - ufshci_ctrlr_fail(ctrlr, false); - return; - } - - /* Initialize UFS target drvice */ - if (ufshci_dev_init(ctrlr) != 0) { - ufshci_ctrlr_fail(ctrlr, false); - return; - } - - /* Initialize Reference Clock */ - if (ufshci_dev_init_reference_clock(ctrlr) != 0) { - ufshci_ctrlr_fail(ctrlr, false); - return; - } - - /* Initialize unipro */ - if (ufshci_dev_init_unipro(ctrlr) != 0) { - ufshci_ctrlr_fail(ctrlr, false); - return; - } - - /* - * Initialize UIC Power Mode - * QEMU UFS devices do not support unipro and power mode. - */ - if (!(ctrlr->quirks & UFSHCI_QUIRK_IGNORE_UIC_POWER_MODE) && - ufshci_dev_init_uic_power_mode(ctrlr) != 0) { - ufshci_ctrlr_fail(ctrlr, false); - return; - } - - /* Initialize UFS Power Mode */ - if (ufshci_dev_init_ufs_power_mode(ctrlr) != 0) { - ufshci_ctrlr_fail(ctrlr, false); - return; - } - - /* Read Controller Descriptor (Device, Geometry) */ - if (ufshci_dev_get_descriptor(ctrlr) != 0) { - ufshci_ctrlr_fail(ctrlr, false); - return; - } - - if (ufshci_dev_config_write_booster(ctrlr)) { - ufshci_ctrlr_fail(ctrlr, false); - return; - } - - /* TODO: Configure Background Operations */ - - if (ufshci_sim_attach(ctrlr) != 0) { - ufshci_ctrlr_fail(ctrlr, false); - return; - } - - TSEXIT(); -} - void ufshci_ctrlr_start_config_hook(void *arg) { @@ -382,9 +471,9 @@ ufshci_ctrlr_start_config_hook(void *arg) if (ufshci_utmr_req_queue_enable(ctrlr) == 0 && ufshci_utr_req_queue_enable(ctrlr) == 0) - ufshci_ctrlr_start(ctrlr); + ufshci_ctrlr_start(ctrlr, false); else - ufshci_ctrlr_fail(ctrlr, false); + ufshci_ctrlr_fail(ctrlr); ufshci_sysctl_initialize_ctrlr(ctrlr); config_intrhook_disestablish(&ctrlr->config_hook); diff --git a/sys/dev/ufshci/ufshci_ctrlr_cmd.c b/sys/dev/ufshci/ufshci_ctrlr_cmd.c index 71d163d998af..253f31a93c2e 100644 --- a/sys/dev/ufshci/ufshci_ctrlr_cmd.c +++ b/sys/dev/ufshci/ufshci_ctrlr_cmd.c @@ -15,7 +15,7 @@ ufshci_ctrlr_cmd_send_task_mgmt_request(struct ufshci_controller *ctrlr, struct ufshci_request *req; struct ufshci_task_mgmt_request_upiu *upiu; - req = ufshci_allocate_request_vaddr(NULL, 0, M_WAITOK, cb_fn, cb_arg); + req = ufshci_allocate_request_vaddr(NULL, 0, M_NOWAIT, cb_fn, cb_arg); req->request_size = sizeof(struct ufshci_task_mgmt_request_upiu); req->response_size = sizeof(struct ufshci_task_mgmt_response_upiu); diff --git a/sys/dev/ufshci/ufshci_dev.c b/sys/dev/ufshci/ufshci_dev.c index dd196b1d638b..975468e5156f 100644 --- a/sys/dev/ufshci/ufshci_dev.c +++ b/sys/dev/ufshci/ufshci_dev.c @@ -774,4 +774,3 @@ out: ufshci_dev_disable_write_booster(ctrlr); return (error); } - diff --git a/sys/dev/ufshci/ufshci_pci.c b/sys/dev/ufshci/ufshci_pci.c index d64b7526f713..992026fd4f4d 100644 --- a/sys/dev/ufshci/ufshci_pci.c +++ b/sys/dev/ufshci/ufshci_pci.c @@ -49,7 +49,8 @@ static struct _pcsid { uint32_t ref_clk; uint32_t quirks; } pci_ids[] = { { 0x131b36, "QEMU UFS Host Controller", UFSHCI_REF_CLK_19_2MHz, - UFSHCI_QUIRK_IGNORE_UIC_POWER_MODE }, + UFSHCI_QUIRK_IGNORE_UIC_POWER_MODE | + UFSHCI_QUIRK_NOT_SUPPORT_ABORT_TASK }, { 0x98fa8086, "Intel Lakefield UFS Host Controller", UFSHCI_REF_CLK_19_2MHz, UFSHCI_QUIRK_LONG_PEER_PA_TACTIVATE | diff --git a/sys/dev/ufshci/ufshci_private.h b/sys/dev/ufshci/ufshci_private.h index 2e033f84c373..ec388c06e248 100644 --- a/sys/dev/ufshci/ufshci_private.h +++ b/sys/dev/ufshci/ufshci_private.h @@ -68,7 +68,6 @@ struct ufshci_request { bool is_admin; int32_t retries; bool payload_valid; - bool timeout; bool spare[2]; /* Future use */ STAILQ_ENTRY(ufshci_request) stailq; }; @@ -82,6 +81,7 @@ enum ufshci_slot_state { }; struct ufshci_tracker { + TAILQ_ENTRY(ufshci_tracker) tailq; struct ufshci_request *req; struct ufshci_req_queue *req_queue; struct ufshci_hw_queue *hwq; @@ -121,6 +121,8 @@ struct ufshci_qops { struct ufshci_req_queue *req_queue); int (*enable)(struct ufshci_controller *ctrlr, struct ufshci_req_queue *req_queue); + void (*disable)(struct ufshci_controller *ctrlr, + struct ufshci_req_queue *req_queue); int (*reserve_slot)(struct ufshci_req_queue *req_queue, struct ufshci_tracker **tr); int (*reserve_admin_slot)(struct ufshci_req_queue *req_queue, @@ -137,16 +139,27 @@ struct ufshci_qops { #define UFSHCI_SDB_Q 0 /* Queue number for a single doorbell queue */ +enum ufshci_recovery { + RECOVERY_NONE = 0, /* Normal operations */ + RECOVERY_WAITING, /* waiting for the reset to complete */ +}; + /* * Generic queue container used by both SDB (fixed 32-slot bitmap) and MCQ * (ring buffer) modes. Fields are shared; some such as sq_head, sq_tail and * cq_head are not used in SDB but used in MCQ. */ struct ufshci_hw_queue { + struct ufshci_controller *ctrlr; + struct ufshci_req_queue *req_queue; uint32_t id; int domain; int cpu; + struct callout timer; /* recovery lock */ + bool timer_armed; /* recovery lock */ + enum ufshci_recovery recovery_state; /* recovery lock */ + union { struct ufshci_utp_xfer_req_desc *utrd; struct ufshci_utp_task_mgmt_req_desc *utmrd; @@ -161,6 +174,9 @@ struct ufshci_hw_queue { uint32_t num_entries; uint32_t num_trackers; + TAILQ_HEAD(, ufshci_tracker) free_tr; + TAILQ_HEAD(, ufshci_tracker) outstanding_tr; + /* * A Request List using the single doorbell method uses a dedicated * ufshci_tracker, one per slot. @@ -177,7 +193,13 @@ struct ufshci_hw_queue { int64_t num_retries; int64_t num_failures; + /* + * Each lock may be acquired independently. + * When both are required, acquire them in this order to avoid + * deadlocks. (recovery_lock -> qlock) + */ struct mtx_padalign qlock; + struct mtx_padalign recovery_lock; }; struct ufshci_req_queue { @@ -242,6 +264,9 @@ struct ufshci_controller { 4 /* Need to wait 1250us after power mode change */ #define UFSHCI_QUIRK_CHANGE_LANE_AND_GEAR_SEPARATELY \ 8 /* Need to change the number of lanes before changing HS-GEAR. */ +#define UFSHCI_QUIRK_NOT_SUPPORT_ABORT_TASK \ + 16 /* QEMU does not support Task Management Request */ + uint32_t ref_clk; struct cam_sim *ufshci_sim; @@ -264,6 +289,9 @@ struct ufshci_controller { /* Fields for tracking progress during controller initialization. */ struct intr_config_hook config_hook; + struct task reset_task; + struct taskqueue *taskqueue; + /* For shared legacy interrupt. */ int rid; struct resource *res; @@ -272,6 +300,8 @@ struct ufshci_controller { uint32_t major_version; uint32_t minor_version; + uint32_t enable_aborts; + uint32_t num_io_queues; uint32_t max_hw_pend_io; @@ -345,7 +375,7 @@ void ufshci_sim_detach(struct ufshci_controller *ctrlr); /* Controller */ int ufshci_ctrlr_construct(struct ufshci_controller *ctrlr, device_t dev); void ufshci_ctrlr_destruct(struct ufshci_controller *ctrlr, device_t dev); -int ufshci_ctrlr_reset(struct ufshci_controller *ctrlr); +void ufshci_ctrlr_reset(struct ufshci_controller *ctrlr); /* ctrlr defined as void * to allow use with config_intrhook. */ void ufshci_ctrlr_start_config_hook(void *arg); void ufshci_ctrlr_poll(struct ufshci_controller *ctrlr); @@ -388,7 +418,9 @@ int ufshci_utmr_req_queue_construct(struct ufshci_controller *ctrlr); int ufshci_utr_req_queue_construct(struct ufshci_controller *ctrlr); void ufshci_utmr_req_queue_destroy(struct ufshci_controller *ctrlr); void ufshci_utr_req_queue_destroy(struct ufshci_controller *ctrlr); +void ufshci_utmr_req_queue_disable(struct ufshci_controller *ctrlr); int ufshci_utmr_req_queue_enable(struct ufshci_controller *ctrlr); +void ufshci_utr_req_queue_disable(struct ufshci_controller *ctrlr); int ufshci_utr_req_queue_enable(struct ufshci_controller *ctrlr); void ufshci_req_queue_fail(struct ufshci_controller *ctrlr, struct ufshci_hw_queue *hwq); @@ -404,6 +436,8 @@ void ufshci_req_sdb_destroy(struct ufshci_controller *ctrlr, struct ufshci_req_queue *req_queue); struct ufshci_hw_queue *ufshci_req_sdb_get_hw_queue( struct ufshci_req_queue *req_queue); +void ufshci_req_sdb_disable(struct ufshci_controller *ctrlr, + struct ufshci_req_queue *req_queue); int ufshci_req_sdb_enable(struct ufshci_controller *ctrlr, struct ufshci_req_queue *req_queue); int ufshci_req_sdb_reserve_slot(struct ufshci_req_queue *req_queue, @@ -489,13 +523,12 @@ _ufshci_allocate_request(const int how, ufshci_cb_fn_t cb_fn, void *cb_arg) struct ufshci_request *req; KASSERT(how == M_WAITOK || how == M_NOWAIT, - ("nvme_allocate_request: invalid how %d", how)); + ("ufshci_allocate_request: invalid how %d", how)); req = malloc(sizeof(*req), M_UFSHCI, how | M_ZERO); if (req != NULL) { req->cb_fn = cb_fn; req->cb_arg = cb_arg; - req->timeout = true; } return (req); } diff --git a/sys/dev/ufshci/ufshci_req_queue.c b/sys/dev/ufshci/ufshci_req_queue.c index bb6efa6d2ccc..7aa164d00bec 100644 --- a/sys/dev/ufshci/ufshci_req_queue.c +++ b/sys/dev/ufshci/ufshci_req_queue.c @@ -24,6 +24,7 @@ static const struct ufshci_qops sdb_utmr_qops = { .destroy = ufshci_req_sdb_destroy, .get_hw_queue = ufshci_req_sdb_get_hw_queue, .enable = ufshci_req_sdb_enable, + .disable = ufshci_req_sdb_disable, .reserve_slot = ufshci_req_sdb_reserve_slot, .reserve_admin_slot = ufshci_req_sdb_reserve_slot, .ring_doorbell = ufshci_req_sdb_utmr_ring_doorbell, @@ -38,6 +39,7 @@ static const struct ufshci_qops sdb_utr_qops = { .destroy = ufshci_req_sdb_destroy, .get_hw_queue = ufshci_req_sdb_get_hw_queue, .enable = ufshci_req_sdb_enable, + .disable = ufshci_req_sdb_disable, .reserve_slot = ufshci_req_sdb_reserve_slot, .reserve_admin_slot = ufshci_req_sdb_reserve_slot, .ring_doorbell = ufshci_req_sdb_utr_ring_doorbell, @@ -74,6 +76,13 @@ ufshci_utmr_req_queue_destroy(struct ufshci_controller *ctrlr) &ctrlr->task_mgmt_req_queue); } +void +ufshci_utmr_req_queue_disable(struct ufshci_controller *ctrlr) +{ + ctrlr->task_mgmt_req_queue.qops.disable(ctrlr, + &ctrlr->task_mgmt_req_queue); +} + int ufshci_utmr_req_queue_enable(struct ufshci_controller *ctrlr) { @@ -109,6 +118,13 @@ ufshci_utr_req_queue_destroy(struct ufshci_controller *ctrlr) &ctrlr->transfer_req_queue); } +void +ufshci_utr_req_queue_disable(struct ufshci_controller *ctrlr) +{ + ctrlr->transfer_req_queue.qops.disable(ctrlr, + &ctrlr->transfer_req_queue); +} + int ufshci_utr_req_queue_enable(struct ufshci_controller *ctrlr) { @@ -226,31 +242,30 @@ void ufshci_req_queue_complete_tracker(struct ufshci_tracker *tr) { struct ufshci_req_queue *req_queue = tr->req_queue; + struct ufshci_hw_queue *hwq = tr->hwq; struct ufshci_request *req = tr->req; struct ufshci_completion cpl; uint8_t ocs; bool retry, error, retriable; - mtx_assert(&tr->hwq->qlock, MA_NOTOWNED); + mtx_assert(&hwq->qlock, MA_NOTOWNED); /* Copy the response from the Request Descriptor or UTP Command * Descriptor. */ + cpl.size = tr->response_size; if (req_queue->is_task_mgmt) { - cpl.size = tr->response_size; memcpy(&cpl.response_upiu, - (void *)tr->hwq->utmrd[tr->slot_num].response_upiu, - cpl.size); + (void *)hwq->utmrd[tr->slot_num].response_upiu, cpl.size); - ocs = tr->hwq->utmrd[tr->slot_num].overall_command_status; + ocs = hwq->utmrd[tr->slot_num].overall_command_status; } else { bus_dmamap_sync(req_queue->dma_tag_ucd, req_queue->ucdmem_map, BUS_DMASYNC_POSTREAD | BUS_DMASYNC_POSTWRITE); - cpl.size = tr->response_size; memcpy(&cpl.response_upiu, (void *)tr->ucd->response_upiu, cpl.size); - ocs = tr->hwq->utrd[tr->slot_num].overall_command_status; + ocs = hwq->utrd[tr->slot_num].overall_command_status; } error = ufshci_req_queue_response_is_error(req_queue, ocs, @@ -262,9 +277,9 @@ ufshci_req_queue_complete_tracker(struct ufshci_tracker *tr) retry = error && retriable && req->retries < req_queue->ctrlr->retry_count; if (retry) - tr->hwq->num_retries++; + hwq->num_retries++; if (error && req->retries >= req_queue->ctrlr->retry_count && retriable) - tr->hwq->num_failures++; + hwq->num_failures++; KASSERT(tr->req, ("there is no request assigned to the tracker\n")); KASSERT(cpl.response_upiu.header.task_tag == @@ -282,7 +297,7 @@ ufshci_req_queue_complete_tracker(struct ufshci_tracker *tr) req->cb_fn(req->cb_arg, &cpl, error); } - mtx_lock(&tr->hwq->qlock); + mtx_lock(&hwq->qlock); /* Clear the UTRL Completion Notification register */ req_queue->qops.clear_cpl_ntf(req_queue->ctrlr, tr); @@ -301,6 +316,9 @@ ufshci_req_queue_complete_tracker(struct ufshci_tracker *tr) ufshci_free_request(req); tr->req = NULL; tr->slot_state = UFSHCI_SLOT_STATE_FREE; + + TAILQ_REMOVE(&hwq->outstanding_tr, tr, tailq); + TAILQ_INSERT_HEAD(&hwq->free_tr, tr, tailq); } mtx_unlock(&tr->hwq->qlock); @@ -309,7 +327,16 @@ ufshci_req_queue_complete_tracker(struct ufshci_tracker *tr) bool ufshci_req_queue_process_completions(struct ufshci_req_queue *req_queue) { - return (req_queue->qops.process_cpl(req_queue)); + struct ufshci_hw_queue *hwq; + bool done; + + hwq = req_queue->qops.get_hw_queue(req_queue); + + mtx_lock(&hwq->recovery_lock); + done = req_queue->qops.process_cpl(req_queue); + mtx_unlock(&hwq->recovery_lock); + + return (done); } static void @@ -427,6 +454,225 @@ ufshci_req_queue_fill_utr_descriptor(struct ufshci_utp_xfer_req_desc *desc, desc->prdt_length = prdt_entry_cnt; } +static void +ufshci_req_queue_timeout_recovery(struct ufshci_controller *ctrlr, + struct ufshci_hw_queue *hwq) +{ + /* TODO: Step 2. Logical unit reset */ + /* TODO: Step 3. Target device reset */ + /* TODO: Step 4. Bus reset */ + + /* + * Step 5. All previous commands were timeout. + * Recovery failed, reset the host controller. + */ + ufshci_printf(ctrlr, + "Recovery step 5: Resetting controller due to a timeout.\n"); + hwq->recovery_state = RECOVERY_WAITING; + + ufshci_ctrlr_reset(ctrlr); +} + +static void +ufshci_abort_complete(void *arg, const struct ufshci_completion *status, + bool error) +{ + struct ufshci_tracker *tr = arg; + + /* + * We still need to check the active tracker array, to cover race where + * I/O timed out at same time controller was completing the I/O. An + * abort request always is on the Task Management Request queue, but + * affects either an Task Management Request or an I/O (UTRL) queue, so + * take the appropriate queue lock for the original command's queue, + * since we'll need it to avoid races with the completion code and to + * complete the command manually. + */ + mtx_lock(&tr->hwq->qlock); + if (tr->slot_state != UFSHCI_SLOT_STATE_FREE) { + mtx_unlock(&tr->hwq->qlock); + /* + * An I/O has timed out, and the controller was unable to abort + * it for some reason. And we've not processed a completion for + * it yet. Construct a fake completion status, and then complete + * the I/O's tracker manually. + */ + ufshci_printf(tr->hwq->ctrlr, + "abort task request failed, aborting task manually\n"); + ufshci_req_queue_manual_complete_tracker(tr, + UFSHCI_DESC_ABORTED, UFSHCI_RESPONSE_CODE_GENERAL_FAILURE); + + if ((status->response_upiu.task_mgmt_response_upiu + .output_param1 == + UFSHCI_TASK_MGMT_SERVICE_RESPONSE_FUNCTION_COMPLETE) || + (status->response_upiu.task_mgmt_response_upiu + .output_param1 == + UFSHCI_TASK_MGMT_SERVICE_RESPONSE_FUNCTION_SUCCEEDED)) { + ufshci_printf(tr->hwq->ctrlr, + "Warning: the abort task request completed \ + successfully, but the original task is still incomplete."); + return; + } + + /* Abort Task failed. Perform recovery steps 2-5 */ + ufshci_req_queue_timeout_recovery(tr->hwq->ctrlr, tr->hwq); + } else { + mtx_unlock(&tr->hwq->qlock); + } +} + +static void +ufshci_req_queue_timeout(void *arg) +{ + struct ufshci_hw_queue *hwq = arg; + struct ufshci_controller *ctrlr = hwq->ctrlr; + struct ufshci_tracker *tr; + sbintime_t now; + bool idle = true; + bool fast; + + mtx_assert(&hwq->recovery_lock, MA_OWNED); + + /* + * If the controller is failed, then stop polling. This ensures that any + * failure processing that races with the hwq timeout will fail safely. + */ + if (ctrlr->is_failed) { + ufshci_printf(ctrlr, + "Failed controller, stopping watchdog timeout.\n"); + hwq->timer_armed = false; + return; + } + + /* + * Shutdown condition: We set hwq->timer_armed to false in + * ufshci_req_sdb_destroy before calling callout_drain. When we call + * that, this routine might get called one last time. Exit w/o setting a + * timeout. None of the watchdog stuff needs to be done since we're + * destroying the hwq. + */ + if (!hwq->timer_armed) { + ufshci_printf(ctrlr, + "Timeout fired during ufshci_utr_req_queue_destroy\n"); + return; + } + + switch (hwq->recovery_state) { + case RECOVERY_NONE: + /* + * See if there's any recovery needed. First, do a fast check to + * see if anything could have timed out. If not, then skip + * everything else. + */ + fast = false; + mtx_lock(&hwq->qlock); + now = getsbinuptime(); *** 337 LINES SKIPPED *** From nobody Thu Sep 18 15:13:35 2025 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 4cSK0H2d7Rz67XlH; Thu, 18 Sep 2025 15:13:35 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSK0H1r7Fz3vDK; Thu, 18 Sep 2025 15:13:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758208415; 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=M80XppdJu3BB6TYqw1AKcfJl5MK1GI3JQn/69vjpWIo=; b=iuYVlrf+AYP+5/41IIgAmIJHb2jNnAFIbdaMTDAebit6sYswoPATN77BBJ8ds5EDj/hGFf EXc6niK+W9h5Eg69RsMvLWe3N4RG4Nj+PyWJshX+mz46rUwhv2YatSk13zv5WTtrSedHbx UHtP03l4CHZnMgFzzf9oigjPszESJUrLpDnfDwbsdqs7YLpgO+M/RE2LdJhdpSchJwFbFw qkno031IYGyw7QzRxlJ/yW/hSzkwQS1htPNGwlgG8ZLfatUE2YzkSCfzal31TBLPIiIBN3 wQEkbz4TZ09n/BS6xsNyVKgwf/zDxc/kej27b1uqN1v2LKrTqCaeHUkF3fa1NQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758208415; 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=M80XppdJu3BB6TYqw1AKcfJl5MK1GI3JQn/69vjpWIo=; b=wDW14fPSIv8q21FksNu+HWx4g3DYf/j7KowCsCpfc7/b8tkfj96VJQviz55UgVJss7ZaTM oTJlvztV+JfjWwqBDKOqQFFzaVbNgJv73J087yrXc3/dIrodwUwwSJ7yeBTwQYynGyHA3S VaGQYhlG9eJmqbdkxKRjqooChDyJ8Gea069Hca2gNPktEXxSVLu/a7faxIU5FbzCxI3xn5 1C56wsG1Pi4nqUIOYw7rBL6LQj09u96ytdLV2bYXrtV0gulFcZUVz6DEK5R5PAY7vClypx jUy4mGyB2i6qASIau8n4KdMk/RzW6hvyTGoNDVOOCiGwIPbz6zB3y6TTTjkezQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758208415; a=rsa-sha256; cv=none; b=UgyJ9RLjh6nRsAJ/OIfcBy79pAztKteG79ePzMdxRrO/KNis3CDl07t0PAcFobKuzAvrKV 5qNng+ffF4Xat5FNErtCMvL9JLfM1glVhG+ZCxvvTKwOG7l7D3skBU6ewR8r6vUWiIPGnZ gNKSMgAsdIkzNL4ZAEASqOO2+yDw1khwb/n73GUNasYNoeTNfpfTdPegOImz4R0TR6GLX8 yfRcJmUiM8na/NfSUVfyQyJHOUwzcUEkSXgDK4ojRjNSm3RyGkDIZTnUwOGmn7uZf7SE8r pRLNquOO1kzXxJlTjA+JWqCKBX+nZEgZkZvaPrwq1SrI45jx3oM3iz7SyCGmpA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSK0H19tqz29Z; Thu, 18 Sep 2025 15:13:35 +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 58IFDZLv036155; Thu, 18 Sep 2025 15:13:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IFDZt1036152; Thu, 18 Sep 2025 15:13:35 GMT (envelope-from git) Date: Thu, 18 Sep 2025 15:13:35 GMT Message-Id: <202509181513.58IFDZt1036152@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: 6683dcf61b3d - main - cpuctl: run amd_ucode_wrmsr only on one CPU and report if it failed 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: glebius X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6683dcf61b3d0dfa8639c9e501eefb7709922ddf Auto-Submitted: auto-generated The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=6683dcf61b3d0dfa8639c9e501eefb7709922ddf commit 6683dcf61b3d0dfa8639c9e501eefb7709922ddf Author: Gleb Smirnoff AuthorDate: 2025-09-18 15:10:59 +0000 Commit: Gleb Smirnoff CommitDate: 2025-09-18 15:10:59 +0000 cpuctl: run amd_ucode_wrmsr only on one CPU and report if it failed The CPUCTL_UPDATE is supposed to be applied only to the CPU the ioctl(2) was performed on. This is true for Intel CPUs, but for AMD the SMP rendezvouz of amd_ucode_wrmsr() effectively executed it on all CPUs. Also, the update failure was not reported. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D52466 --- sys/dev/cpuctl/cpuctl.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/sys/dev/cpuctl/cpuctl.c b/sys/dev/cpuctl/cpuctl.c index 9253b17a259d..b0ab3467df69 100644 --- a/sys/dev/cpuctl/cpuctl.c +++ b/sys/dev/cpuctl/cpuctl.c @@ -402,19 +402,20 @@ out: * its workings. */ static void -amd_ucode_wrmsr(void *ucode_ptr) +amd_ucode_wrmsr(void *arg) { + struct ucode_update_data *d = arg; uint32_t tmp[4]; - wrmsr_safe(MSR_K8_UCODE_UPDATE, (uintptr_t)ucode_ptr); + if (PCPU_GET(cpuid) == d->cpu) + d->ret = wrmsr_safe(MSR_K8_UCODE_UPDATE, (uintptr_t)d->ptr); do_cpuid(0, tmp); } static int update_amd(int cpu, cpuctl_update_args_t *args, struct thread *td) { - void *ptr; - int ret; + struct ucode_update_data d = { .cpu = cpu }; if (args->size == 0 || args->data == NULL) { DPRINTF("[cpuctl,%d]: zero-sized firmware image", __LINE__); @@ -430,18 +431,17 @@ update_amd(int cpu, cpuctl_update_args_t *args, struct thread *td) * malloc(9) always returns the pointer aligned at least on * the size of the allocation. */ - ptr = malloc(args->size + 16, M_CPUCTL, M_ZERO | M_WAITOK); - if (copyin(args->data, ptr, args->size) != 0) { + d.ptr = malloc(args->size + 16, M_CPUCTL, M_ZERO | M_WAITOK); + if (copyin(args->data, d.ptr, args->size) != 0) { DPRINTF("[cpuctl,%d]: copyin %p->%p of %zd bytes failed", __LINE__, args->data, ptr, args->size); - ret = EFAULT; + d.ret = EFAULT; goto fail; } - smp_rendezvous(NULL, amd_ucode_wrmsr, NULL, ptr); - ret = 0; + smp_rendezvous(NULL, amd_ucode_wrmsr, NULL, &d); fail: - free(ptr, M_CPUCTL); - return (ret); + free(d.ptr, M_CPUCTL); + return (d.ret); } static int From nobody Thu Sep 18 15:13:36 2025 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 4cSK0J4nLTz67XGC; Thu, 18 Sep 2025 15:13:36 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSK0J29cLz3vNg; Thu, 18 Sep 2025 15:13:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758208416; 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=ip9D5hNz2kD2bAUF6gmeLiUH4lAfkSA7AozZffoGOLI=; b=eV0JRS0GkfHr07JSStFlfbwIiM3+wcnpj5wnOPslLlrKzOJucSshsH3I+GZMDRjFXzP7CB /rLopxY5n6fmGtY+ihh/pLl53AEPlLzTzAqWOGku1whHrGTZp/1RtgCnnB2b6bl9db06Ve xnWZxHcwEGsyzVxcGeuSw4OULXSQYzUwYWuyL6sv6Z99YSH+Twyf5rN2X5UF2RvgHyzQDF OUzoqZaV5i5Y5dM9bScD5VU0kzxPBuDqHqxCgblHg9yCAXPzH6brzVCb35MX45C3lPqqfi PyTOCSchU+wCuLSMF+FyIbMbh0hogtUfZHzuVrOqXh0w4eXpqSCXU02p2hOsIQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758208416; 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=ip9D5hNz2kD2bAUF6gmeLiUH4lAfkSA7AozZffoGOLI=; b=sww7oy2aN6/MYVkZmR/EOm48GWZ5dhGcCDPLkCofFMQ1YTqSlmaP79ruHV6yZgwCHes2Ft j7MTWy3ZxKLuRRvbQ7Tb9gdU0qsOGr3G5MAwFWCrbOw7tHiKCL929hjoPRwyyXMWuDJvLT PvgwdLc2nUk2dmUK8/9CxvHoLMwZtnSE2zTQe5gGTy7Tf6zW2SHshAlEie0xwRYSLcFoj0 pN33J3nX53HWHl/T5ZrHk/SSoe3T2yNoMfJDs9La+0BnlVsNzfSL65j17csL7XvICHP77r zNXK4lYknC+FL/CeOT4kbJC8q6J4iYPeW7n5T3i7Z8qhBqiRmVIo70CHCe+gEw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758208416; a=rsa-sha256; cv=none; b=NOQFEKkhp6ZKs8I06nbSjkjeOXKH/PC2ug4hKtSA8mm9RmWh9E0SVniPgqz7kTbrbFuxg0 BuSZbRONyR4ny+HEyhs9ImvlABZ63IGgWR7ldAjqsEfkXUX6s/ukxzwAc886mrd682iMuO u71TtgkdH7vt475i6vNoQ4YSEgIwFBt9Q+y/RtJA5hJ3GU90YV8Vwte4g24uW1b+m7gbPb UzY+4I99dXqTlekMOG9bxMKzPTpsnEew6VnxE7dpVrjSQpg3eAhe/ZkUC6Z0sPXdee7ZnM K31NQuxoXmMAA12o0B29O4DR5Wh57HRUtlK5EraoJg8EsdJ4QQqSvmbeRA/Cuw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSK0J1hT7z29b; Thu, 18 Sep 2025 15:13:36 +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 58IFDa6f036192; Thu, 18 Sep 2025 15:13:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IFDaNd036188; Thu, 18 Sep 2025 15:13:36 GMT (envelope-from git) Date: Thu, 18 Sep 2025 15:13:36 GMT Message-Id: <202509181513.58IFDaNd036188@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: 83804499b724 - main - cpucontrol: return selected revision from ucode_amd_find() 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: glebius X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 83804499b72405475027e670690d4cdbada46090 Auto-Submitted: auto-generated The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=83804499b72405475027e670690d4cdbada46090 commit 83804499b72405475027e670690d4cdbada46090 Author: Gleb Smirnoff AuthorDate: 2025-09-18 15:11:03 +0000 Commit: Gleb Smirnoff CommitDate: 2025-09-18 15:11:03 +0000 cpucontrol: return selected revision from ucode_amd_find() This fixes two printing bugs in cpucontrol(1). First, the utility will now print "updating from rev X to rev Y", instead of incorrect "updating to revision X", where X is actually the old revision. This also matches what Intel updater prints. Second, the utility won't incorrectly warn that the update failed after reading the new revision post update. Reviewed by: kib, markj Differential Revision: https://reviews.freebsd.org/D52506 --- sys/x86/include/ucode.h | 2 +- sys/x86/x86/ucode.c | 3 ++- sys/x86/x86/ucode_subr.c | 10 +++++----- usr.sbin/cpucontrol/amd10h.c | 11 ++++++----- 4 files changed, 14 insertions(+), 12 deletions(-) diff --git a/sys/x86/include/ucode.h b/sys/x86/include/ucode.h index 0338d48a0832..75b9ff3afbd0 100644 --- a/sys/x86/include/ucode.h +++ b/sys/x86/include/ucode.h @@ -63,7 +63,7 @@ struct ucode_intel_extsig_table { }; const void *ucode_amd_find(const char *path, uint32_t signature, - uint32_t revision, const uint8_t *fw_data, size_t fw_size, + uint32_t *revision, const uint8_t *fw_data, size_t fw_size, size_t *selected_sizep); int ucode_intel_load(const void *data, bool unsafe, uint64_t *nrevp, uint64_t *orevp); diff --git a/sys/x86/x86/ucode.c b/sys/x86/x86/ucode.c index 0c153c0b656c..1973047fafd1 100644 --- a/sys/x86/x86/ucode.c +++ b/sys/x86/x86/ucode.c @@ -277,7 +277,8 @@ ucode_amd_match(const uint8_t *data, size_t *len) signature = regs[0]; revision = rdmsr(MSR_BIOS_SIGN); - return (ucode_amd_find("loader blob", signature, revision, data, *len, len)); + return (ucode_amd_find("loader blob", signature, &revision, data, *len, + len)); } /* diff --git a/sys/x86/x86/ucode_subr.c b/sys/x86/x86/ucode_subr.c index 9e128ad2bf04..53d7cfc06769 100644 --- a/sys/x86/x86/ucode_subr.c +++ b/sys/x86/x86/ucode_subr.c @@ -94,7 +94,7 @@ typedef struct container_header { * source code. */ const void * -ucode_amd_find(const char *path, uint32_t signature, uint32_t revision, +ucode_amd_find(const char *path, uint32_t signature, uint32_t *revision, const uint8_t *fw_data, size_t fw_size, size_t *selected_sizep) { const amd_10h_fw_header_t *fw_header; @@ -112,7 +112,7 @@ ucode_amd_find(const char *path, uint32_t signature, uint32_t revision, (signature >> 4) & 0x0f, (signature >> 0) & 0x0f, (signature >> 20) & 0xff, (signature >> 16) & 0x0f); - WARNX(1, "microcode revision %#x", revision); + WARNX(1, "microcode revision %#x", *revision); nextfile: WARNX(1, "checking %s for update.", path); @@ -212,9 +212,9 @@ nextfile: fw_header->processor_rev_id, equiv_id); continue; /* different cpu */ } - if (fw_header->patch_id <= revision) { + if (fw_header->patch_id <= *revision) { WARNX(1, "patch_id %x, revision %x", - fw_header->patch_id, revision); + fw_header->patch_id, *revision); continue; /* not newer revision */ } if (fw_header->nb_dev_id != 0 || fw_header->sb_dev_id != 0) { @@ -222,7 +222,7 @@ nextfile: } WARNX(3, "selecting revision: %x", fw_header->patch_id); - revision = fw_header->patch_id; + *revision = fw_header->patch_id; selected_fw = fw_header; selected_size = section_header->size; } diff --git a/usr.sbin/cpucontrol/amd10h.c b/usr.sbin/cpucontrol/amd10h.c index 4fda44f0b797..9fc861fe5914 100644 --- a/usr.sbin/cpucontrol/amd10h.c +++ b/usr.sbin/cpucontrol/amd10h.c @@ -93,7 +93,7 @@ amd10h_update(const struct ucode_update_params *params) size_t fw_size; size_t selected_size; uint32_t revision; - uint32_t new_rev; + uint32_t new_rev, old_rev; uint32_t signature; int devfd; int error; @@ -121,15 +121,16 @@ amd10h_update(const struct ucode_update_params *params) WARN(0, "ioctl(%s)", dev); goto done; } - revision = (uint32_t)msrargs.data; + old_rev = revision = (uint32_t)msrargs.data; - selected_fw = ucode_amd_find(path, signature, revision, fw_image, + selected_fw = ucode_amd_find(path, signature, &revision, fw_image, fw_size, &selected_size); if (selected_fw != NULL) { WARNX(1, "selected ucode size is %zu", selected_size); - fprintf(stderr, "%s: updating cpu %s to revision %#x... ", - path, dev, revision); + fprintf(stderr, + "%s: updating cpu %s from rev %#x to rev %#x... ", + path, dev, old_rev, revision); args.data = __DECONST(void *, selected_fw); args.size = selected_size; From nobody Thu Sep 18 16:18:04 2025 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 4cSLQh5Rhtz67dc1; Thu, 18 Sep 2025 16:18:04 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSLQh4pnNz45rC; Thu, 18 Sep 2025 16:18:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758212284; 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=mwkcZWMFVgFWAkHSQsI5O2uPHii/soesOkNutBo1gnU=; b=d4/voGv+DOr8piT90BdpOEzyzPWpjv/T9L09GgmIOjVZswfNE+0dWu6nXcov16kvXfKzqN qAVltNZmxdi44kepIv4efmhIsZLtwMgnx8/JVFMC/wwbLlWE/kOderalyuFnJKAFMZuuzj AUg4ZUtnhgAu1sd9AODBEH/Sopfh6bUOrDjVL0dZjPOpne/En/gBwI0sXDqAM+UcIG8lPy VqvdcOIyF5O1KOwfLbn3EgVco1tRrpuRpJW9/Rqgvk2OP8d5I67FWRpDV9KYxA77QkFSYa 9HQwq+O/ZnXZab1MeavGPUjQzYnVyrGhBlDThh16oriThZVBiEgKouN37swDAA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758212284; 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=mwkcZWMFVgFWAkHSQsI5O2uPHii/soesOkNutBo1gnU=; b=wAOAaQ6HufZADcFo/7py3+um0VF16IJfSXAdWmbd2sIIvLny+GiysqyYj2eAztK/doYuBA i7coNfZeAIslgQhHJOvVY5+1O8EQ9NrrvDRAn53yzCNB8guGKJ4bnEhoGTIPIM9SLe2mN6 Zl41/3EeiVf0OBYDmDLES8ddIEv39+yZTXrROkZqE7UP5FJgm1bvgHDx5dW39jGZwdxDXW Zl/j3xZvoiD2mVmeIHkDj7e9lI9Gq9XIu5atyTIzEj+4WIUga0ab+qdwWH9BAUxHYCxhDi /3QpVcWVYeRtkEhdg8Wk4LtYRafmr0/87srUFwSwakORz7qAVKSVL61Pm329Tg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758212284; a=rsa-sha256; cv=none; b=R+zOk9XuiLPOFKLsN9YF2bQtKO2kv8424ivjx2H2oQ3zS4+ArRdRM0BGw2Eb6SB7YHvvb6 MFOTb91S6zJ4tFdci30GwLtN3ESjgOCyVLdHKW6gDoCGwsTXllY3cs7RtEjG9i5ywBJ4w/ XEdbJerEEVdZON68ujOZNkyCXrVAFMLnTvIqVnTExDYganDrE5znaWnJXPCTJLRYBG7nKd QDepyMqGsVCIxXuO1Yl/yNCU9Ohs2ll9Z+S3WZA+VDP77qetuBeS5a0wYNygm1rfacVVrN MsuwQ2d/KF5U0aJas7/QHkOSCE97WdZDurBV6q26L5bnkz71r+4Tm527wg2vgw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSLQh444fz3t5; Thu, 18 Sep 2025 16:18:04 +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 58IGI4wl050827; Thu, 18 Sep 2025 16:18:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IGI4JV050824; Thu, 18 Sep 2025 16:18:04 GMT (envelope-from git) Date: Thu, 18 Sep 2025 16:18:04 GMT Message-Id: <202509181618.58IGI4JV050824@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 5aa49c98edfc - stable/15 - qlnxe: Unconditionally enable extended media types 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 5aa49c98edfc48fbe96f7aba0e0631d4c0f29493 Auto-Submitted: auto-generated The branch stable/15 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=5aa49c98edfc48fbe96f7aba0e0631d4c0f29493 commit 5aa49c98edfc48fbe96f7aba0e0631d4c0f29493 Author: Zhenlei Huang AuthorDate: 2025-09-09 10:04:54 +0000 Commit: Zhenlei Huang CommitDate: 2025-09-18 16:15:52 +0000 qlnxe: Unconditionally enable extended media types Those extended media types are available since about 2015 [1]. All supported branches already have them defined. No functional change intended. [1] eb7e25b22f1c ifmedia changes: Extend the number of available subtypes for Ethernet media ... Reviewed by: kbowling MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52374 (cherry picked from commit 08356a733eb7a7bef1afe20ded2d983b55310de7) --- sys/dev/qlnx/qlnxe/qlnx_def.h | 16 ---------------- sys/dev/qlnx/qlnxe/qlnx_os.c | 21 +++++++++------------ 2 files changed, 9 insertions(+), 28 deletions(-) diff --git a/sys/dev/qlnx/qlnxe/qlnx_def.h b/sys/dev/qlnx/qlnxe/qlnx_def.h index 4342bba89587..796845f3f8c6 100644 --- a/sys/dev/qlnx/qlnxe/qlnx_def.h +++ b/sys/dev/qlnx/qlnxe/qlnx_def.h @@ -696,22 +696,6 @@ extern int qlnx_alloc_mem_sb(qlnx_host_t *ha, struct ecore_sb_info *sb_info, * Some OS specific stuff */ -#if (defined IFM_100G_SR4) -#define QLNX_IFM_100G_SR4 IFM_100G_SR4 -#define QLNX_IFM_100G_LR4 IFM_100G_LR4 -#define QLNX_IFM_100G_CR4 IFM_100G_CR4 -#else -#define QLNX_IFM_100G_SR4 IFM_UNKNOWN -#define QLNX_IFM_100G_LR4 IFM_UNKNOWN -#endif /* #if (defined IFM_100G_SR4) */ - -#if (defined IFM_25G_SR) -#define QLNX_IFM_25G_SR IFM_25G_SR -#define QLNX_IFM_25G_CR IFM_25G_CR -#else -#define QLNX_IFM_25G_SR IFM_UNKNOWN -#define QLNX_IFM_25G_CR IFM_UNKNOWN -#endif /* #if (defined IFM_25G_SR) */ #define QLNX_INC_IERRORS(ifp) if_inc_counter(ifp, IFCOUNTER_IERRORS, 1) #define QLNX_INC_IQDROPS(ifp) if_inc_counter(ifp, IFCOUNTER_IQDROPS, 1) diff --git a/sys/dev/qlnx/qlnxe/qlnx_os.c b/sys/dev/qlnx/qlnxe/qlnx_os.c index 4ad190374f87..696604cf1202 100644 --- a/sys/dev/qlnx/qlnxe/qlnx_os.c +++ b/sys/dev/qlnx/qlnxe/qlnx_os.c @@ -2375,18 +2375,15 @@ qlnx_init_ifnet(device_t dev, qlnx_host_t *ha) ifmedia_add(&ha->media, (IFM_ETHER | IFM_40G_CR4), 0, NULL); } else if ((device_id == QLOGIC_PCI_DEVICE_ID_1656) || (device_id == QLOGIC_PCI_DEVICE_ID_8070)) { - ifmedia_add(&ha->media, (IFM_ETHER | QLNX_IFM_25G_SR), 0, NULL); - ifmedia_add(&ha->media, (IFM_ETHER | QLNX_IFM_25G_CR), 0, NULL); + ifmedia_add(&ha->media, (IFM_ETHER | IFM_25G_SR), 0, NULL); + ifmedia_add(&ha->media, (IFM_ETHER | IFM_25G_CR), 0, NULL); } else if (device_id == QLOGIC_PCI_DEVICE_ID_1654) { ifmedia_add(&ha->media, (IFM_ETHER | IFM_50G_KR2), 0, NULL); ifmedia_add(&ha->media, (IFM_ETHER | IFM_50G_CR2), 0, NULL); } else if (device_id == QLOGIC_PCI_DEVICE_ID_1644) { - ifmedia_add(&ha->media, - (IFM_ETHER | QLNX_IFM_100G_LR4), 0, NULL); - ifmedia_add(&ha->media, - (IFM_ETHER | QLNX_IFM_100G_SR4), 0, NULL); - ifmedia_add(&ha->media, - (IFM_ETHER | QLNX_IFM_100G_CR4), 0, NULL); + ifmedia_add(&ha->media, (IFM_ETHER | IFM_100G_LR4), 0, NULL); + ifmedia_add(&ha->media, (IFM_ETHER | IFM_100G_SR4), 0, NULL); + ifmedia_add(&ha->media, (IFM_ETHER | IFM_100G_CR4), 0, NULL); } ifmedia_add(&ha->media, (IFM_ETHER | IFM_FDX), 0, NULL); @@ -3808,11 +3805,11 @@ qlnx_get_optics(qlnx_host_t *ha, struct qlnx_link_output *if_link) case MEDIA_MODULE_FIBER: case MEDIA_UNSPECIFIED: if (if_link->speed == (100 * 1000)) - ifm_type = QLNX_IFM_100G_SR4; + ifm_type = IFM_100G_SR4; else if (if_link->speed == (40 * 1000)) ifm_type = IFM_40G_SR4; else if (if_link->speed == (25 * 1000)) - ifm_type = QLNX_IFM_25G_SR; + ifm_type = IFM_25G_SR; else if (if_link->speed == (10 * 1000)) ifm_type = (IFM_10G_LR | IFM_10G_SR); else if (if_link->speed == (1 * 1000)) @@ -3822,11 +3819,11 @@ qlnx_get_optics(qlnx_host_t *ha, struct qlnx_link_output *if_link) case MEDIA_DA_TWINAX: if (if_link->speed == (100 * 1000)) - ifm_type = QLNX_IFM_100G_CR4; + ifm_type = IFM_100G_CR4; else if (if_link->speed == (40 * 1000)) ifm_type = IFM_40G_CR4; else if (if_link->speed == (25 * 1000)) - ifm_type = QLNX_IFM_25G_CR; + ifm_type = IFM_25G_CR; else if (if_link->speed == (10 * 1000)) ifm_type = IFM_10G_TWINAX; From nobody Thu Sep 18 16:18:05 2025 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 4cSLQj6JWgz67dW8; Thu, 18 Sep 2025 16:18:05 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSLQj5HWBz469q; Thu, 18 Sep 2025 16:18:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758212285; 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=1rJCBj8mCf/7YWjR7karOq5Rj5940rquPKqOTp6uwXk=; b=Fmdg+S5dcv90ACtVdBejZA7Jl5iLV0k1NovIquE5OLUdqlc0w7FuTXXSSxgXHE+1hU6URf VwHu6jaCbqAfeuB6WlkbcEkGtR2ji6y47MbELax8JrmZFXc6vp2S0TRoITKUsSt+miVpwV TfbeMMgPhQZworL2qeJGrqcqAJCmHNF3gjUCKgwfBdgMW3FMj4/EgppzWGvij+BsGpqZ9E AtHkBv3ub0hCGTBbIGowoRb7u86T+XsW+Zfpz2KK0PUzWNOcMuGtWWqx1wnSRokfDxzMps g7bjnqdkgC8SktWzi6qFFX82q7oxw0OIrETn8cmEvU9v2doX/eEWPqDgaFQ+KA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758212285; 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=1rJCBj8mCf/7YWjR7karOq5Rj5940rquPKqOTp6uwXk=; b=rE3I626/VtlQJ6rPCinrS7tb+vlG1MrDT6Z/bHReHfVp7UhTZM8R4grLed7lJRew9ndEyq A8/DSpIoKlWC6mQiMMvYpQMqmuPPaw71Nm3UpDaCJ8teshIglgbwX1pNduvkZGM8pplCli 0bzjNFXZkxn9CytiyDJRw5QAKxvz1CMUB0MgLodvEvctxs6GSd3VaFwNt/W1T9p7k0HB78 HEmjh5mvaTJcCf5JxovpAyQeJWXxFTre5SBVuSXV29g7bjQZ3lAZu7krfnLF1Y4BgM0FHY UnsdXrH8CdTd1R/rnsjkVlLU5WREpJZhy4mYWSnXUJt0OtnKUp0GW/ucaQM4nw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758212285; a=rsa-sha256; cv=none; b=PPTgWp8P3938BiXUxsP3AxBKKMNT4pG63BTtqBf9A4PJgcVzjG7aVW0ad6KHBW0E5EvmKR TfKqH9kLwcxHd0eEqWmHJU9FePqiN+HhojqpRMneapos9LIxXZGjG7XUiJVeUwGO9EPlEf d0FEKgIDuvKoy5/Y/YZvoPhSU/NL+7LPYLQ4+xuNOqM75beNmq8zJXhu8vG+s/E/L+vV/j VaIgxSSXxHCcDv+OrEKeu1lK3WUk0CNCwT/TOUt4kJvexwJ3CBHuioeqjk0c6ocGZkmW32 ufcerjrYpkaTD3WktCbGFaWlG/Iv28K7epcw1Nb+jhXLmOiLgWogw1v/S+gI2A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSLQj4mDqz3Ck; Thu, 18 Sep 2025 16:18:05 +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 58IGI5F6050860; Thu, 18 Sep 2025 16:18:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IGI5b4050857; Thu, 18 Sep 2025 16:18:05 GMT (envelope-from git) Date: Thu, 18 Sep 2025 16:18:05 GMT Message-Id: <202509181618.58IGI5b4050857@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 817bc7009270 - stable/15 - qlnxe: Support SIOCGIFXMEDIA ioctl 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 817bc700927087a52d0dd34c43e45736a867240e Auto-Submitted: auto-generated The branch stable/15 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=817bc700927087a52d0dd34c43e45736a867240e commit 817bc700927087a52d0dd34c43e45736a867240e Author: Zhenlei Huang AuthorDate: 2025-09-09 10:04:54 +0000 Commit: Zhenlei Huang CommitDate: 2025-09-18 16:15:52 +0000 qlnxe: Support SIOCGIFXMEDIA ioctl ifconfig(8) will try SIOCGIFXMEDIA first and then retry SIOCGIFMEDIA if that fails. Since the driver reports extended media types, support SIOCGIFXMEDIA ioctl directly rather than doing another round. Reviewed by: kbowling MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52375 (cherry picked from commit 6e3c8c0f709ab0b9d70e2725e58f4a4ba7a4404e) --- sys/dev/qlnx/qlnxe/qlnx_os.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/dev/qlnx/qlnxe/qlnx_os.c b/sys/dev/qlnx/qlnxe/qlnx_os.c index 696604cf1202..9963f472c615 100644 --- a/sys/dev/qlnx/qlnxe/qlnx_os.c +++ b/sys/dev/qlnx/qlnxe/qlnx_os.c @@ -2721,7 +2721,9 @@ qlnx_ioctl(if_t ifp, u_long cmd, caddr_t data) case SIOCSIFMEDIA: case SIOCGIFMEDIA: - QL_DPRINT4(ha, "SIOCSIFMEDIA/SIOCGIFMEDIA (0x%lx)\n", cmd); + case SIOCGIFXMEDIA: + QL_DPRINT4(ha, + "SIOCSIFMEDIA/SIOCGIFMEDIA/SIOCGIFXMEDIA (0x%lx)\n", cmd); ret = ifmedia_ioctl(ifp, ifr, &ha->media, cmd); break; From nobody Thu Sep 18 16:18:06 2025 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 4cSLQl1n87z67dF7; Thu, 18 Sep 2025 16:18:07 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSLQk74Hhz45xd; Thu, 18 Sep 2025 16:18:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758212287; 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=Co/JdMk7EPhaHHoNz1teoDFV24gCfQKb3ungT43Mhm0=; b=sLVGMTwD+yur9HRt4/dxUCmVos5zEt6BUC3ruGv7RbrrkWjKFQO8bGpCP18hIHQ539twhx awEe5gqfx7085vHvb/Lf3vzHi5cOkzc5sNqlH7m/DfowuLPLPoGRkxVqrAxvfFXo4zdWDc spYsb3csLfDFTKbdJlTVb4tq9ll7o1uHu93o4Q+yaWXyOItsU+Nstuw2KKOSrZCjxlCZNA aN9gXwUKHNSmLl3VSzjSz+hnhy7eYyn2hbcO+O7BaAao8HSTzeuXRTe2tzqQtOS2SCwWPv TiYDR5YlUrx+dPYMDxcOh3dB+kligu8ozT1xwEvBjkT5iZg5wMPC4BF6VdHxeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758212287; 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=Co/JdMk7EPhaHHoNz1teoDFV24gCfQKb3ungT43Mhm0=; b=EnZQlXaxCKFTYxbmHUyiLyCYYzm31JKsH55NEqnKUC34K531hEgfpC0i0dj5ah/dPn8I9e LJ9fYe7DFZONpJ0LjwJlXA4EDhNxHpCT98uKiUj2SXtuDCClmb1dqSdGuz6VYe3Sfv6xJV d3KVo9A5FTtBhGqlx/6YtvL0BZbJqXrPYMQVoYN40gqOnNgbvoUN/JyaQ7OuaX847tx9ig 9HdE1RudkBVs/bZJJdTFxvwXDhoVNokpEJDplGDV1+crN384u7w3kjDSV3p/jv7IV6anRr sgW/6VNotEpOiBW1td1LQv23YtzyubbEgPUXmsjZ9/olwqHRbIXnF7+itdvzpQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758212287; a=rsa-sha256; cv=none; b=G061TSlryt8R2IbcJwzCaSzOhIendqUlejjJEY/LKKTXVxIDeeuhYO+84ooSkd9dgOjjO3 kXZrpMnR5TbKMiWeJdMcvbvD8rwDLVuA/o8/0Aac75wCsdZg0tYCf1UO6W+b9spKLNF4lT YLSBBGS4uIQ5JPb9951Ipm0pbXUrsikIUj2X/If4nCHzTK7jVyz1n9L91Qxz+/72tXDYY6 3LaIEdDkZtD50notPk2A0HVFu4fY/ZT0JpSTIxDd0VhAQOLjVYlu/Z0EsXb+fjCAAeoMmH rv+uAqpGNecT+/whLtasZ7l8EzT1OwHTVqydfpQIZ5aTgEJJt9XtyMLnEdmiMw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSLQk5YLJz39W; Thu, 18 Sep 2025 16:18:06 +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 58IGI6Hc050893; Thu, 18 Sep 2025 16:18:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IGI6tY050890; Thu, 18 Sep 2025 16:18:06 GMT (envelope-from git) Date: Thu, 18 Sep 2025 16:18:06 GMT Message-Id: <202509181618.58IGI6tY050890@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 6fb046515ea6 - stable/15 - qlnxe: Report speeds in decimal format 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 6fb046515ea6005b3958e0c3220d0e6e630af292 Auto-Submitted: auto-generated The branch stable/15 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=6fb046515ea6005b3958e0c3220d0e6e630af292 commit 6fb046515ea6005b3958e0c3220d0e6e630af292 Author: Zhenlei Huang AuthorDate: 2025-09-09 10:04:55 +0000 Commit: Zhenlei Huang CommitDate: 2025-09-18 16:15:52 +0000 qlnxe: Report speeds in decimal format It is more natural to read the speed in decimal format than hexadecimal one. Spotted this while diagnosing PR 287445, ``` [__ecore_configure_pf_max_bandwidth:6864(qlnx-0)]Configured MAX bandwidth to be 000061a8 Mb/sec [__ecore_configure_pf_min_bandwidth:6922(qlnx-0)]Configured MIN bandwidth to be 750 Mb/sec ``` Reviewed by: kbowling MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52376 (cherry picked from commit e1c5e043961ab3a5429a0c6e727265dfa819cf00) --- sys/dev/qlnx/qlnxe/ecore_dev.c | 6 +++--- sys/dev/qlnx/qlnxe/ecore_mcp.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/dev/qlnx/qlnxe/ecore_dev.c b/sys/dev/qlnx/qlnxe/ecore_dev.c index 6187ecdbc446..389a95a4164c 100644 --- a/sys/dev/qlnx/qlnxe/ecore_dev.c +++ b/sys/dev/qlnx/qlnxe/ecore_dev.c @@ -5268,7 +5268,7 @@ ecore_hw_get_nvm_info(struct ecore_hwfn *p_hwfn, } DP_VERBOSE(p_hwfn, ECORE_MSG_LINK, - "Read default link: Speed 0x%08x, Adv. Speed 0x%08x, AN: 0x%02x, PAUSE AN: 0x%02x EEE: %02x [%08x usec]\n", + "Read default link: Speed %u Mb/sec, Adv. Speeds 0x%08x, AN: 0x%02x, PAUSE AN: 0x%02x EEE: %02x [%u usec]\n", link->speed.forced_speed, link->speed.advertised_speeds, link->speed.autoneg, link->pause.autoneg, p_caps->default_eee, p_caps->eee_lpi_timer); @@ -6860,7 +6860,7 @@ int __ecore_configure_pf_max_bandwidth(struct ecore_hwfn *p_hwfn, p_hwfn->qm_info.pf_rl); DP_VERBOSE(p_hwfn, ECORE_MSG_LINK, - "Configured MAX bandwidth to be %08x Mb/sec\n", + "Configured MAX bandwidth to be %u Mb/sec\n", p_link->speed); return rc; @@ -6918,7 +6918,7 @@ int __ecore_configure_pf_min_bandwidth(struct ecore_hwfn *p_hwfn, rc = ecore_init_pf_wfq(p_hwfn, p_ptt, p_hwfn->rel_pf_id, min_bw); DP_VERBOSE(p_hwfn, ECORE_MSG_LINK, - "Configured MIN bandwidth to be %d Mb/sec\n", + "Configured MIN bandwidth to be %u Mb/sec\n", p_link->min_pf_rate); return rc; diff --git a/sys/dev/qlnx/qlnxe/ecore_mcp.c b/sys/dev/qlnx/qlnxe/ecore_mcp.c index ab14b1eb5186..6d1e5fe24d06 100644 --- a/sys/dev/qlnx/qlnxe/ecore_mcp.c +++ b/sys/dev/qlnx/qlnxe/ecore_mcp.c @@ -1638,7 +1638,7 @@ enum _ecore_status_t ecore_mcp_set_link(struct ecore_hwfn *p_hwfn, if (b_up) DP_VERBOSE(p_hwfn, ECORE_MSG_LINK, - "Configuring Link: Speed 0x%08x, Pause 0x%08x, adv_speed 0x%08x, loopback 0x%08x\n", + "Configuring Link: Speed %u Mb/sec, Pause 0x%08x, adv_speed 0x%08x, loopback 0x%08x\n", phy_cfg.speed, phy_cfg.pause, phy_cfg.adv_speed, phy_cfg.loopback_mode); else From nobody Thu Sep 18 16:18:07 2025 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 4cSLQm31bKz67dWC; Thu, 18 Sep 2025 16:18:08 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSLQm1GCmz46BC; Thu, 18 Sep 2025 16:18:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758212288; 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=zlYwiSI2dYlLdkqMzSAlD2RsH0qzuLfYiOUMDz7rduQ=; b=MVchWE5UXPz1xY9OtgBahKwx20J0LQUvmzLzq4aSYAOYyPS90Wl3vQDdlZqfxal+OSgXdJ wAhTeqH6kNBYgUJq+xMyDoKD/FNHD4JBGotZzGHA2rIgiVYAk/QVzli+IC27xsnN31urVB kvv0Q+Ot4hxcjVkHFjZGT2eMfKuyvgrVCHO0bb/OY19YSGyKILe1NMpqsfZVvlpFYVl8jc VvY99PmEh2Tlpfe9Lzrf/1jYshWVZWuR2JlWhNvqP8sEXn5OmqWq4T1YqFBkmgvDVFncGP MoJOKD87nC2duOFAAkhiFnCgwbOhQcpPRhV/t3aghyvy//IdZ4oJhh0pKeanRg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758212288; 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=zlYwiSI2dYlLdkqMzSAlD2RsH0qzuLfYiOUMDz7rduQ=; b=cIoUOFcWoHMKxYZ3wEEGKd7Zbi+0ShunZFXKh99bz4KFK+Uf0UGww/JMA0QFoGLICO67jp Ksp8E2vjctsGjiX/7856gjY0MBIbVGu9s2V363rLX1smhkd5tSKKrNcpBKHZlkI9P5yxWi ffvhUq860pwOULUzAB1cPNKXRk/5c43jxFcBwV7Ee0443FMzoDrqwszK5Cquz4Jc9O8UyC I0L1J5X62MGYTGSFwltfJO/4ZDoa/SxJVZyxs21DZKVtRd7abwTee3f4Lc95ctJTtFmsi4 A2FJR8y7LVP42XLk7efLlBkNz3h8TIfuE3hd7Mm8Zqh3XR4quUMfsySBEznRfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758212288; a=rsa-sha256; cv=none; b=PoCkPSxdbea2izKYpjmvPQCpiGdWQW17KTuvHSjBLD+ege5ymLw08OtHwo/xyBbwZ9BAd9 /xo70wKljhSz/hCQ52EMzxjaY1t+TfytWzbjgs6hJtwwzIDm4a6BL5ahWS3Rs9/W+gVVCa 7noUPX9WXhGhaiiXAQQ+2LKDF/2iBFmcyIQcNJosIlfNOCaLhEaW9SRhjB0CRGjdL+QZBY TwfxiB10FjDhf9liLnm3iB/oaWxuHLTg33JQ5dVkG6qWSFIDZZ/6isNXhHwKtYA5tvbnQq mbj7bewZB1RG4HFrHieeVv3zAsnP4gw6YU8jS2w7wn3Fgc84WAmg2CwRlrBbJA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSLQl6lrDz3h7; Thu, 18 Sep 2025 16:18:07 +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 58IGI7M2050932; Thu, 18 Sep 2025 16:18:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IGI72X050929; Thu, 18 Sep 2025 16:18:07 GMT (envelope-from git) Date: Thu, 18 Sep 2025 16:18:07 GMT Message-Id: <202509181618.58IGI72X050929@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: bd721f6e8040 - stable/15 - tslog: Move sysinit_tslog_shim() into kern_tslog.c 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: bd721f6e8040f0b9d0546c293954290844b6a070 Auto-Submitted: auto-generated The branch stable/15 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=bd721f6e8040f0b9d0546c293954290844b6a070 commit bd721f6e8040f0b9d0546c293954290844b6a070 Author: Zhenlei Huang AuthorDate: 2025-09-10 14:44:36 +0000 Commit: Zhenlei Huang CommitDate: 2025-09-18 16:15:53 +0000 tslog: Move sysinit_tslog_shim() into kern_tslog.c struct sysinit's func pointer requires its address, thus a real function is generated in every translation unit when the source file has SYSINITs declared. That results in plenty of identical sysinit_tslog_shim in the final kernel file, in which only one is used and others are left useless. MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52413 (cherry picked from commit 5f9a05e574050c8b3f6b444311a12e8fb293ad1a) --- sys/kern/kern_tslog.c | 10 ++++++++++ sys/sys/kernel.h | 11 ++--------- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/sys/kern/kern_tslog.c b/sys/kern/kern_tslog.c index fbf81d423b95..09070eea284f 100644 --- a/sys/kern/kern_tslog.c +++ b/sys/kern/kern_tslog.c @@ -220,3 +220,13 @@ SYSCTL_PROC(_debug, OID_AUTO, tslog_user, CTLTYPE_STRING|CTLFLAG_RD|CTLFLAG_MPSAFE|CTLFLAG_SKIP, 0, 0, sysctl_debug_tslog_user, "", "Dump recorded userland event timestamps"); + +void +sysinit_tslog_shim(const void *data) +{ + const struct sysinit_tslog *x = data; + + tslog(curthread, TS_ENTER, "SYSINIT", x->name); + (x->func)(x->data); + tslog(curthread, TS_EXIT, "SYSINIT", x->name); +} diff --git a/sys/sys/kernel.h b/sys/sys/kernel.h index 380099092107..81efeff527f5 100644 --- a/sys/sys/kernel.h +++ b/sys/sys/kernel.h @@ -249,15 +249,8 @@ struct sysinit_tslog { const void *data; const char *name; }; -static inline void -sysinit_tslog_shim(const void *data) -{ - const struct sysinit_tslog *x = data; - - TSRAW(curthread, TS_ENTER, "SYSINIT", x->name); - (x->func)(x->data); - TSRAW(curthread, TS_EXIT, "SYSINIT", x->name); -} +void sysinit_tslog_shim(const void *); + #define C_SYSINIT(uniquifier, subsystem, order, func, ident) \ static struct sysinit_tslog uniquifier ## _sys_init_tslog = { \ func, \ From nobody Thu Sep 18 16:34:51 2025 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 4cSLp36TKhz67fPL; Thu, 18 Sep 2025 16:34:51 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSLp35lgFz488t; Thu, 18 Sep 2025 16:34:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758213291; 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=X03/ZeBRpQ2KkBEmH3e8KEgTRNrn5JLp1lxl9dY8RNc=; b=W2Yp86k7BrFlSaNxDuxKvcD3y1arNnm0E6V0qan1DEc62YlJcO5MD+Cs5UYTCe7/kvKgaZ wJ+uIPJ0swXTXIYh2K85U2HR4dcqiTv4I+XwXz6K9r0KThp/mdcS/ubz7fn8/B6IVM9QH4 58riP3EcEmNLl2FsANseAgYuanWX4hA5k4XWN63vyNEXnj+vNUqvZmtV7Pw3dfNBJS6W06 XGTm4wuRahDn05QtzB5g07xw+WbAbEKacOJOKNxRTo+LjupSe9shT+tstYDc1eoP1fE6AE Cmjus+h5ypKGb30xv2IKRIyakkw3kcKrZkLYCSJg9suUfyjIJhyThgMv9AMu4g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758213291; 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=X03/ZeBRpQ2KkBEmH3e8KEgTRNrn5JLp1lxl9dY8RNc=; b=MyIVEzubo3/Z33E7raxTrtG9A6N6FHkPelk1xOLcOfzUp0ZVDFc8WCJQx3RjaIrRranJVN NWcr9sACFpKoWKYYBunFQv+dfJuj56RL6vglZ17UsSmEyRS0E5DAbS/i4UiAMYTBeUN1FN KVQXEUwfSzeLHZ6IySSzX5+0lcW9ZhvsvK8cTOQ+qBdyLf+cEe9utmuVwjqjJqxK2g8CSc FweNkU5/0r0zUk5vm/go1/ZHex0SEhiG9neBWKlB7jIVUMTzfknDfJURTiyWs3oOl1IdIR tzeqqsEGTKq2NWBWGTRvXghLy/xCmFfT0Ao2AaOWzakHIzbUXv5gloFhHkY0Tg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758213291; a=rsa-sha256; cv=none; b=RrynHUazwN03yx4ncoJGE+RYehSGT5c4fvpMTkwhc3qVNyLXHrWjBz8UOC7hvfkJTa4+6R XrgmkLvd1pchk1tf7tdbnh4U4nu6Lg7wv0HPeZKCYH61BCRwLA2G5+QObPCglwGKX+lv2H vo/YxTkVexTdV6feo51qSSnfOYWQXk7zAHZx/dxlmsyXjsV0hsSCmnSEGax8qqKiFdjMqr 4OdWl9LeSkIufU/FEAtG/9cfbMTZhp3O5YXwiXwOXnLutmx3DXfjhD1ephE/bM3YjMrO7q XoKhRsVLL3U+L7JVch2Hp4tLtp5NkMyivgnTnAy/crcEEROsgHsYENZTILHiAQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSLp353qhz37K; Thu, 18 Sep 2025 16:34:51 +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 58IGYpgq086806; Thu, 18 Sep 2025 16:34:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IGYp6Y086803; Thu, 18 Sep 2025 16:34:51 GMT (envelope-from git) Date: Thu, 18 Sep 2025 16:34:51 GMT Message-Id: <202509181634.58IGYp6Y086803@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alexander Ziaee Subject: git: 8f7a4d7949d8 - main - ObsoleteFiles: Remove the miscapitalized vimage.9 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: ziaee X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8f7a4d7949d83c13a7451cba7626950d182dfc5d Auto-Submitted: auto-generated The branch main has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=8f7a4d7949d83c13a7451cba7626950d182dfc5d commit 8f7a4d7949d83c13a7451cba7626950d182dfc5d Author: Alexander Ziaee AuthorDate: 2025-09-18 16:22:56 +0000 Commit: Alexander Ziaee CommitDate: 2025-09-18 16:29:03 +0000 ObsoleteFiles: Remove the miscapitalized vimage.9 MFC after: 3 days Fixes: 08d41d8803d9 (ObsoleteFiles: Remove the miscapitalized vnet.9) Fixes: 3049b2f5115b (vnet.9: Rename vnet.9/vimage.9 to VNET.9/VIMAGE.9) --- ObsoleteFiles.inc | 1 + 1 file changed, 1 insertion(+) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index 76e2027d9af2..d3b1a0239e3f 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -53,6 +53,7 @@ # 20250917: Remove a miscapitalized manual OLD_FILES+=usr/share/man/man9/vnet.9.gz +OLD_FILES+=usr/share/man/man9/vimage.9.gz # 20250911: This tool is no longer needed OLD_FILES+=usr/tests/bin/cp/sparse From nobody Thu Sep 18 17:38:19 2025 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 4cSNCH5FTcz67lHF; Thu, 18 Sep 2025 17:38:19 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSNCH4Qdxz4Hrk; Thu, 18 Sep 2025 17:38:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758217099; 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=/52mhIJHpt4dSi1Vy943nxmHXuQAe2LHMmn2dPkOw9E=; b=cZZ0FtKYQ9d8+1m3Z+WXFsQjW/6RVFE7e2YlQdr+zp1Mim86Bz+jtnRMQ0jSfd+aW/NOrm wcTytdHQZVmmpJkx6qdxrONMd0e7736fG14C5d/mDv0UxDVsNuRtHP2WuUIv6IvOONT/oo Sa1etKjeFE0DRF0A/qWSuo0+93tUn+A2Sm3zIFnR2sR8IRWehf8zhQagZTXJJljymyw0vf jTPNnTAKI3w4S6dI2G+0ZENLfEtO3lYKMgmjekM48k8JB9pv4nX03VQKJ27Q2XkWOQD31O OxXM+nGUPijLrvwJu2l314yPJIBsA5J1XS6uFcBoVnRTZ3FcH06CW4cA/R7n/w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758217099; 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=/52mhIJHpt4dSi1Vy943nxmHXuQAe2LHMmn2dPkOw9E=; b=HtuamoFbvzSPDEf7Hy8cEuQPxyK7D0mVCU+iZz42KccKxWfqqMTAgXEQbx2Nu5oLnu+CJw pCvBn3M5rx6XGH1Jsc3mm9L9hcvr9dP7HqHVOI6dAuG7j+dZkG4HoVWV8FSYA25DrPTwxB OnQb0XofKNj8UKdgO3yTWCtjvPNVquyNqXbVklOrmtqxO/3Rgp6ibuzlxMQR1qSSmi3oWj jagWMAqOaKSxt0aqgitO26cOkZoLd7oAPEZbzLMnwpfDTEPxCCFL2kdSJk2U3Q+Yb7ZA+a IT3O0dW1yDw8PF79Fv8MDIKDFffsmjnmPKmH3nvcC73WJwy1TKa2zdyXTs+6RQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758217099; a=rsa-sha256; cv=none; b=QLu7e2X0/mpRlbg6kCLSzjb/2tFzc+gsYmrKET+RRHFFDb8sSMT4oapGv4HM9fAR5PqdB6 U/csYODQ5phDpI9/0FAuEi49le7/OVncuuNBo7i4xMDvgIkorwRr34KgtMvNUFEa6fXm9i j7VYSXYDPegRMgX1f/MvvTmMGoVnrKqkRB+HV7GHzNInMtIrIZgvI7rNaZ/5T6GgirZaAW Q/1rTaMOg64P6wVOpZoHTbzS4FPXtJZPU2gnkb6ZecAaS+bBm/Tb+8+830LniFvLGpwCIg ntxLZuVYYjlp0Co7c6Th3PIUkWXxgOFaCog8jDgwHH3EdcpXnPlWqIO/wJSnXg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSNCH3BvPz62y; Thu, 18 Sep 2025 17:38:19 +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 58IHcJWB001074; Thu, 18 Sep 2025 17:38:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IHcJqV001071; Thu, 18 Sep 2025 17:38:19 GMT (envelope-from git) Date: Thu, 18 Sep 2025 17:38:19 GMT Message-Id: <202509181738.58IHcJqV001071@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alexander Ziaee Subject: git: a37825313f62 - main - stand/man: Fix mdoc typos for emails, tag spdx 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: ziaee X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a37825313f624121c6f07bc03f9cf655c300885b Auto-Submitted: auto-generated The branch main has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=a37825313f624121c6f07bc03f9cf655c300885b commit a37825313f624121c6f07bc03f9cf655c300885b Author: Alexander Ziaee AuthorDate: 2025-09-18 17:12:19 +0000 Commit: Alexander Ziaee CommitDate: 2025-09-18 17:20:01 +0000 stand/man: Fix mdoc typos for emails, tag spdx MFC after: 3 days --- stand/man/boot1.efi.8 | 2 ++ stand/man/loader.8 | 9 ++++++--- stand/man/loader_4th.8 | 7 +++++-- stand/man/loader_lua.8 | 3 +++ stand/man/loader_simp.8 | 5 ++++- 5 files changed, 20 insertions(+), 6 deletions(-) diff --git a/stand/man/boot1.efi.8 b/stand/man/boot1.efi.8 index b6135f8e0e12..2c882a595592 100644 --- a/stand/man/boot1.efi.8 +++ b/stand/man/boot1.efi.8 @@ -1,4 +1,6 @@ .\" +.\" SPDX-License-Identifier: BSD-2-Clause +.\" .\" Copyright (c) 2020 Netflix, Inc .\" .\" Redistribution and use in source and binary forms, with or without diff --git a/stand/man/loader.8 b/stand/man/loader.8 index 4fc3bbb7cff0..234eabd571e0 100644 --- a/stand/man/loader.8 +++ b/stand/man/loader.8 @@ -1,3 +1,6 @@ +.\" +.\" SPDX-License-Identifier: BSD-2-Clause +.\" .\" Copyright (c) 1999 Daniel C. Sobral .\" All rights reserved. .\" Copyright (c) 2021 Warner Losh @@ -115,11 +118,11 @@ scripting language changed to Lua by default in The .Nm was written by -.An Michael Smith Aq msmith@FreeBSD.org . +.An Michael Smith Aq Mt msmith@FreeBSD.org . .Pp FICL was written by -.An John Sadler Aq john_sadler@alum.mit.edu . +.An John Sadler Aq Mt john_sadler@alum.mit.edu . .Pp -.An Warner Losh Aq imp@FreeBSD.org +.An Warner Losh Aq Mt imp@FreeBSD.org integrated Lua into the tree based on initial work done by Pedro Souza for the 2014 Google Summer of Code. diff --git a/stand/man/loader_4th.8 b/stand/man/loader_4th.8 index 9e87326f893b..21e907bd8630 100644 --- a/stand/man/loader_4th.8 +++ b/stand/man/loader_4th.8 @@ -1,3 +1,6 @@ +.\" +.\" SPDX-License-Identifier: BSD-2-Clause +.\" .\" Copyright (c) 1999 Daniel C. Sobral .\" All rights reserved. .\" @@ -576,8 +579,8 @@ first appeared in The .Nm was written by -.An Michael Smith Aq msmith@FreeBSD.org . +.An Michael Smith Aq Mt msmith@FreeBSD.org . .Pp .Tn FICL was written by -.An John Sadler Aq john_sadler@alum.mit.edu . +.An John Sadler Aq Mt john_sadler@alum.mit.edu . diff --git a/stand/man/loader_lua.8 b/stand/man/loader_lua.8 index 0aa467237266..c60de9417abc 100644 --- a/stand/man/loader_lua.8 +++ b/stand/man/loader_lua.8 @@ -1,3 +1,6 @@ +.\" +.\" SPDX-License-Identifier: BSD-2-Clause +.\" .\" Copyright (c) 1999 Daniel C. Sobral .\" All rights reserved. .\" diff --git a/stand/man/loader_simp.8 b/stand/man/loader_simp.8 index cdacd823b1a5..683ca8b2da5d 100644 --- a/stand/man/loader_simp.8 +++ b/stand/man/loader_simp.8 @@ -1,3 +1,6 @@ +.\" +.\" SPDX-License-Identifier: BSD-2-Clause +.\" .\" Copyright (c) 1999 Daniel C. Sobral .\" All rights reserved. .\" @@ -755,4 +758,4 @@ first appeared in The .Nm was written by -.An Michael Smith Aq msmith@FreeBSD.org . +.An Michael Smith Aq Mt msmith@FreeBSD.org . From nobody Thu Sep 18 19:17:24 2025 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 4cSQPc5Y5rz67tP9; Thu, 18 Sep 2025 19:17:24 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSQPc5BXSz3F94; Thu, 18 Sep 2025 19:17:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758223044; 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=ptV1c81YY3t3Il3LMhiTWuS8grTOmIMJUzSuLkj84jk=; b=INpPhRb4QPwyzO5vaMgxJZIgzRovs+9BFAspMejWyJt+K4xCI0va8mXgUJAthZD43UwJPZ rbH2QiVxaVBJfqkSZtQGUiwCfm5RB+NosyZmd5ZQ4Ipez1Rh5UJYCn8S37cHh2RlbOxKR0 xRn7U+Mh1poVolf6FiL2H+X5W7zdQElhrEszYjtffq9a2apaindKjobumAZ5WdtCzpEDs/ 7jhH9DMADsRwKxNzvHziA6oTvH/qIzj/nAypJhaMZ+q/Ka1jXHPjOuQ0R/rNaYlX0JR801 0LdITzcCzdWsA+8/ArPa2qQ/ULreRFxDthyghURzwntCVHIsJewmVxqKLlwONg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758223044; 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=ptV1c81YY3t3Il3LMhiTWuS8grTOmIMJUzSuLkj84jk=; b=uGeV7+s94wCnxzLyBR2vDQVhjXgeixR8n/YRqVnFrBtITwdZnKGdw81wm7tHQLRynECuUi RTDXjUn0FdfRFSN+CG3QM1M156UPJQNNziZpDhxLcRwoek15uzJldP99yZRruJvjFmWUVM mxVcv6grPX99Ba+FaE7t1aPPQfPomlxbaj+/itLkqNwlPpk9xR98hZ77stelqAJ63RBeuB I0mTdF+kMhCoQN/SEAP7IOQmWt8jk6VrX9XUySmmEqBojdkubxK+UGLcLjFmlYk4HzIo7d Zb1Nam9hIxyD7/V1gYt0LPGL9jqVDjXf8b1XMaZxwZkmzEejuLUwfUMZwxmeKA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758223044; a=rsa-sha256; cv=none; b=gDZewSMC8lgrPnBjPeSPJPorKJVYsNyt/CLOJCTiB8ncazF14OCI3Z1oZfpBIRxL+z0yDz 9xBKiXZ4bg+qVPA5+pDLXO9YT3avRZeWZGskorb3vDYekm6KvRCj6wGDIVPPUADP7TDTJE p+FyBTC5/mW4l9UewR13XT7g4ZyDqDh8YDfuLN0gibNUvJHcpNzh+G2CIxe3tVIchw1ShK tzJW6AHpWYndXnYRswMKGikI4QhsK0Ghw7pSeIv8TkQZNxlz58EDKGITzYMwwY/noW3gI7 wsID+fJX+DOqiz/lWzVDoYUYV0wjChgBvCvS+Rfea/OZXCWscasedY48DCwRbg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSQPc4gR9z811; Thu, 18 Sep 2025 19:17:24 +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 58IJHOJF088556; Thu, 18 Sep 2025 19:17:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IJHOn8088552; Thu, 18 Sep 2025 19:17:24 GMT (envelope-from git) Date: Thu, 18 Sep 2025 19:17:24 GMT Message-Id: <202509181917.58IJHOn8088552@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Enji Cooper Subject: git: c99bb5747f5e - main - nanobsd: minor formatting cleanup 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: ngie X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c99bb5747f5e88527e7414fd543c903f367001c4 Auto-Submitted: auto-generated The branch main has been updated by ngie: URL: https://cgit.FreeBSD.org/src/commit/?id=c99bb5747f5e88527e7414fd543c903f367001c4 commit c99bb5747f5e88527e7414fd543c903f367001c4 Author: Enji Cooper AuthorDate: 2025-09-17 18:06:43 +0000 Commit: Enji Cooper CommitDate: 2025-09-18 19:17:11 +0000 nanobsd: minor formatting cleanup - Reformat function definitions POSIX states that compound commands, i.e., ones that use `(..)` or `{ .. } `, are permissible as function definitions, however, many shell syntax validators do not acknowledge the former format. Switch to the latter format so more naive editors, like the vim syntax highlighter, better parse the syntax of the file. Moreover, replacing `(..)` with `{..}` replaces several subshells with their non-subshell equivalents. Given that `set -e` is used liberally and `exit` is not used in the calling code when `set -e` is not enforced, there is no net loss by making this change. - Clean trailing whitespace. - Reindent some related comments to match the indentation of the previous line. - Add shebangs to the tops of files to help syntax colorizers and file identifiers understand that the files are in shell syntax. MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D52596 --- tools/tools/nanobsd/defaults.sh | 162 ++++++++++++++++++------------------ tools/tools/nanobsd/embedded/common | 56 ++++++------- tools/tools/nanobsd/legacy.sh | 12 +-- tools/tools/nanobsd/rescue/common | 32 +++---- 4 files changed, 130 insertions(+), 132 deletions(-) diff --git a/tools/tools/nanobsd/defaults.sh b/tools/tools/nanobsd/defaults.sh index 4c4323c4bd87..4f0cc2fa99bd 100755 --- a/tools/tools/nanobsd/defaults.sh +++ b/tools/tools/nanobsd/defaults.sh @@ -209,30 +209,29 @@ SRC_ENV_CONF=/dev/null # ####################################################################### -# Export values into the shell. Must use { } instead of ( ) like -# other functions to avoid a subshell. +# Export values into the shell. # We set __MAKE_CONF as a global since it is easier to get quoting # right for paths with spaces in them. -make_export ( ) { +make_export() { # Similar to export_var, except puts the data out to stdout - var=$1 + local var=$1 eval val=\$$var echo "Setting variable: $var=\"$val\"" export $1 } -nano_make_build_env ( ) { +nano_make_build_env() { __MAKE_CONF="${NANO_MAKE_CONF_BUILD}" make_export __MAKE_CONF } -nano_make_install_env ( ) { +nano_make_install_env() { __MAKE_CONF="${NANO_MAKE_CONF_INSTALL}" make_export __MAKE_CONF } # Extra environment variables for kernel builds -nano_make_kernel_env ( ) { +nano_make_kernel_env() { if [ -f "${NANO_KERNEL}" ] ; then KERNCONFDIR="$(realpath $(dirname ${NANO_KERNEL}))" KERNCONF="$(basename ${NANO_KERNEL})" @@ -244,23 +243,23 @@ nano_make_kernel_env ( ) { fi } -nano_global_make_env ( ) ( +nano_global_make_env() { # global settings for the make.conf file, if set [ -z "${NANO_ARCH}" ] || echo TARGET_ARCH="${NANO_ARCH}" [ -z "${NANO_CPUTYPE}" ] || echo TARGET_CPUTYPE="${NANO_CPUTYPE}" -) +} # # Create empty files in the target tree, and record the fact. All paths # are relative to NANO_WORLDDIR. # -tgt_touch ( ) ( +tgt_touch() { cd "${NANO_WORLDDIR}" for i; do touch $i echo "./${i} type=file" >> ${NANO_METALOG} done -) +} # # Convert a directory into a symlink. Takes two arguments, the @@ -268,9 +267,9 @@ tgt_touch ( ) ( # directory is removed and a symlink is created. If we're doing # a nopriv build, then append this fact to the metalog # -tgt_dir2symlink ( ) ( - dir=$1 - symlink=$2 +tgt_dir2symlink() { + local dir=$1 + local symlink=$2 cd "${NANO_WORLDDIR}" rm -xrf "$dir" @@ -278,28 +277,28 @@ tgt_dir2symlink ( ) ( if [ -n "$NANO_METALOG" ]; then echo "./${dir} type=link mode=0777 link=${symlink}" >> ${NANO_METALOG} fi -) +} # run in the world chroot, errors fatal -CR ( ) { +CR() { chroot "${NANO_WORLDDIR}" /bin/sh -exc "$*" } # run in the world chroot, errors not fatal -CR0 ( ) { +CR0() { chroot "${NANO_WORLDDIR}" /bin/sh -c "$*" || true } -clean_build ( ) ( +clean_build() { pprint 2 "Clean and create object directory (${MAKEOBJDIRPREFIX})" if ! rm -xrf ${MAKEOBJDIRPREFIX}/ > /dev/null 2>&1 ; then chflags -R noschg ${MAKEOBJDIRPREFIX}/ rm -xr ${MAKEOBJDIRPREFIX}/ fi -) +} -make_conf_build ( ) ( +make_conf_build() { pprint 2 "Construct build make.conf ($NANO_MAKE_CONF_BUILD)" mkdir -p ${MAKEOBJDIRPREFIX} @@ -312,9 +311,9 @@ make_conf_build ( ) ( echo "${CONF_WORLD}" echo "${CONF_BUILD}" ) > ${NANO_MAKE_CONF_BUILD} -) +} -build_world ( ) ( +build_world() { pprint 2 "run buildworld" pprint 3 "log: ${MAKEOBJDIRPREFIX}/_.bw" @@ -324,9 +323,9 @@ build_world ( ) ( cd "${NANO_SRC}" ${NANO_PMAKE} buildworld ) > ${MAKEOBJDIRPREFIX}/_.bw 2>&1 -) +} -build_kernel ( ) ( +build_kernel() { pprint 2 "build kernel ($NANO_KERNEL)" pprint 3 "log: ${MAKEOBJDIRPREFIX}/_.bk" @@ -342,9 +341,9 @@ build_kernel ( ) ( cd "${NANO_SRC}" ${NANO_PMAKE} buildkernel ) > ${MAKEOBJDIRPREFIX}/_.bk 2>&1 -) +} -clean_world ( ) ( +clean_world() { if [ "${NANO_OBJ}" != "${MAKEOBJDIRPREFIX}" ]; then pprint 2 "Clean and create object directory (${NANO_OBJ})" if ! rm -xrf ${NANO_OBJ}/ > /dev/null 2>&1 ; then @@ -361,9 +360,9 @@ clean_world ( ) ( fi mkdir -p "${NANO_WORLDDIR}" fi -) +} -make_conf_install ( ) ( +make_conf_install() { pprint 2 "Construct install make.conf ($NANO_MAKE_CONF_INSTALL)" # Make sure we get all the global settings that NanoBSD wants @@ -377,9 +376,9 @@ make_conf_install ( ) ( echo METALOG=${NANO_METALOG} fi ) > ${NANO_MAKE_CONF_INSTALL} -) +} -install_world ( ) ( +install_world() { pprint 2 "installworld" pprint 3 "log: ${NANO_LOG}/_.iw" @@ -390,9 +389,9 @@ install_world ( ) ( ${NANO_MAKE} installworld DESTDIR="${NANO_WORLDDIR}" DB_FROM_SRC=yes chflags -R noschg "${NANO_WORLDDIR}" ) > ${NANO_LOG}/_.iw 2>&1 -) +} -install_etc ( ) ( +install_etc() { pprint 2 "install /etc" pprint 3 "log: ${NANO_LOG}/_.etc" @@ -405,9 +404,9 @@ install_etc ( ) ( # so they can spam it. cp /dev/null "${NANO_WORLDDIR}"/etc/make.conf ) > ${NANO_LOG}/_.etc 2>&1 -) +} -install_kernel ( ) ( +install_kernel() { pprint 2 "install kernel ($NANO_KERNEL)" pprint 3 "log: ${NANO_LOG}/_.ik" @@ -426,9 +425,9 @@ install_kernel ( ) ( ${NANO_MAKE} installkernel DESTDIR="${NANO_WORLDDIR}" DB_FROM_SRC=yes ) > ${NANO_LOG}/_.ik 2>&1 -) +} -native_xtools ( ) ( +native_xtools() { pprint 2 "Installing the optimized native build tools for cross env" pprint 3 "log: ${NANO_LOG}/_.native_xtools" @@ -441,13 +440,13 @@ native_xtools ( ) ( ${NANO_MAKE} native-xtools-install DESTDIR="${NANO_WORLDDIR}" ) > ${NANO_LOG}/_.native_xtools 2>&1 -) +} # # Run the requested set of early customization scripts, run before # buildworld. # -run_early_customize ( ) { +run_early_customize() { pprint 2 "run early customize scripts" for c in $NANO_EARLY_CUSTOMIZE do @@ -467,7 +466,7 @@ run_early_customize ( ) { # done an installworld, installed the etc files, installed the kernel # and tweaked them in the standard way. # -run_customize ( ) ( +run_customize() { pprint 2 "run customize scripts" for c in $NANO_CUSTOMIZE @@ -477,13 +476,13 @@ run_customize ( ) ( pprint 4 "`type $c`" ( set -o xtrace ; $c ) > ${NANO_LOG}/_.cust.$c 2>&1 done -) +} # # Run any last-minute customization commands after we've had a chance to # setup nanobsd, prune empty dirs from /usr, etc # -run_late_customize ( ) ( +run_late_customize() { pprint 2 "run late customize scripts" for c in $NANO_LATE_CUSTOMIZE do @@ -492,7 +491,7 @@ run_late_customize ( ) ( pprint 4 "`type $c`" ( set -o xtrace ; $c ) > ${NANO_LOG}/_.late_cust.$c 2>&1 done -) +} # # Hook called after we run all the late customize commands, but @@ -501,7 +500,7 @@ run_late_customize ( ) ( # have been recording their actions. It's not anticipated that # a user's cfg file would override this. # -fixup_before_diskimage ( ) ( +fixup_before_diskimage() { # Run the deduplication script that takes the metalog journal and # combines multiple entries for the same file (see source for # details). We take the extra step of removing the size keywords. This @@ -517,9 +516,9 @@ fixup_before_diskimage ( ) ( cat ${NANO_METALOG}.pre | ${NANO_TOOLS}/mtree-dedup.awk | \ sed -e 's/ size=[0-9][0-9]*//' | sort >> ${NANO_METALOG} fi -) +} -setup_nanobsd ( ) ( +setup_nanobsd() { pprint 2 "configure nanobsd setup" pprint 3 "log: ${NANO_LOG}/_.dl" @@ -564,9 +563,9 @@ setup_nanobsd ( ) ( tgt_dir2symlink tmp var/tmp ) > ${NANO_LOG}/_.dl 2>&1 -) +} -setup_nanobsd_etc ( ) ( +setup_nanobsd_etc() { pprint 2 "configure nanobsd /etc" ( @@ -623,18 +622,18 @@ EOF # Create directory for eventual /usr/local/etc contents mkdir -p etc/local ) -) +} -prune_usr ( ) ( +prune_usr() { # Remove all empty directories in /usr find "${NANO_WORLDDIR}"/usr -type d -depth -print | while read d do rmdir $d > /dev/null 2>&1 || true done -) +} -newfs_part ( ) ( +newfs_part() { local dev mnt lbl dev=$1 mnt=$2 @@ -642,15 +641,15 @@ newfs_part ( ) ( echo newfs ${NANO_NEWFS} ${NANO_LABEL:+-L${NANO_LABEL}${lbl}} ${dev} newfs ${NANO_NEWFS} ${NANO_LABEL:+-L${NANO_LABEL}${lbl}} ${dev} mount -o async ${dev} ${mnt} -) +} # Convenient spot to work around any umount issues that your build environment # hits by overriding this method. -nano_umount ( ) ( +nano_umount() { umount ${1} -) +} -populate_slice ( ) ( +populate_slice() { local dev dir mnt lbl dev=$1 dir=$2 @@ -665,23 +664,23 @@ populate_slice ( ) ( fi df -i ${mnt} nano_umount ${mnt} -) +} -populate_cfg_slice ( ) ( +populate_cfg_slice() { populate_slice "$1" "$2" "$3" "$4" -) +} -populate_data_slice ( ) ( +populate_data_slice() { populate_slice "$1" "$2" "$3" "$4" -) +} -last_orders ( ) ( +last_orders() { # Redefine this function with any last orders you may have # after the build completed, for instance to copy the finished # image to a more convenient place: # cp ${NANO_DISKIMGDIR}/${NANO_IMG1NAME} /home/ftp/pub/nanobsd.disk true -) +} ####################################################################### # @@ -693,7 +692,7 @@ last_orders ( ) ( # Common Flash device geometries # -FlashDevice ( ) { +FlashDevice() { if [ -d ${NANO_TOOLS} ] ; then . ${NANO_TOOLS}/FlashDevice.sub else @@ -722,8 +721,8 @@ FlashDevice ( ) { # The generic-hdd device is preferred for flash devices larger than 1GB. # -UsbDevice ( ) { - a1=`echo $1 | tr '[:upper:]' '[:lower:]'` +UsbDevice() { + local a1=`echo $1 | tr '[:upper:]' '[:lower:]'` case $a1 in generic-fdd) NANO_HEADS=64 @@ -745,7 +744,7 @@ UsbDevice ( ) { ####################################################################### # Setup serial console -cust_comconsole ( ) ( +cust_comconsole() { # Enable getty on console sed -i "" -e '/^tty[du]0/s/off/onifconsole/' ${NANO_WORLDDIR}/etc/ttys @@ -754,32 +753,32 @@ cust_comconsole ( ) ( # Tell loader to use serial console early. echo "${NANO_BOOT2CFG}" > ${NANO_WORLDDIR}/boot.config -) +} ####################################################################### # Allow root login via ssh -cust_allow_ssh_root ( ) ( +cust_allow_ssh_root() { sed -i "" -E 's/^#?PermitRootLogin.*/PermitRootLogin yes/' \ ${NANO_WORLDDIR}/etc/ssh/sshd_config -) +} ####################################################################### # Install the stuff under ./Files -cust_install_files ( ) ( +cust_install_files() { cd "${NANO_TOOLS}/Files" find . -print | grep -Ev '/(CVS|\.svn|\.hg|\.git)/' | cpio ${CPIO_SYMLINK} -Ldumpv ${NANO_WORLDDIR} if [ -n "${NANO_CUST_FILES_MTREE}" -a -f ${NANO_CUST_FILES_MTREE} ]; then CR "mtree -eiU -p /" <${NANO_CUST_FILES_MTREE} fi -) +} ####################################################################### # Install packages from ${NANO_PACKAGE_DIR} -cust_pkgng ( ) ( +cust_pkgng() { mkdir -p ${NANO_WORLDDIR}/usr/local/etc local PKG_CONF="${NANO_WORLDDIR}/usr/local/etc/pkg.conf" local PKGCMD="env BATCH=YES ASSUME_ALWAYS_YES=YES PKG_DBDIR=${NANO_PKG_META_BASE}/pkg SIGNATURE_TYPE=none /usr/sbin/pkg" @@ -841,14 +840,14 @@ cust_pkgng ( ) ( umount ${NANO_WORLDDIR}/dev umount ${NANO_WORLDDIR}/_.p rm -xrf ${NANO_WORLDDIR}/_.p -) +} ####################################################################### # Convenience function: # Register all args as early customize function to run just before # build commences. -early_customize_cmd ( ) { +early_customize_cmd() { NANO_EARLY_CUSTOMIZE="$NANO_EARLY_CUSTOMIZE $*" } @@ -856,7 +855,7 @@ early_customize_cmd ( ) { # Convenience function: # Register all args as customize function. -customize_cmd ( ) { +customize_cmd() { NANO_CUSTOMIZE="$NANO_CUSTOMIZE $*" } @@ -865,7 +864,7 @@ customize_cmd ( ) { # Register all args as late customize function to run just before # image creation. -late_customize_cmd ( ) { +late_customize_cmd() { NANO_LATE_CUSTOMIZE="$NANO_LATE_CUSTOMIZE $*" } @@ -877,14 +876,14 @@ late_customize_cmd ( ) { # Progress Print # Print $2 at level $1. -pprint ( ) ( +pprint() { if [ "$1" -le $PPLEVEL ]; then runtime=$(( `date +%s` - $NANO_STARTTIME )) printf "%s %.${1}s %s\n" "`date -u -r $runtime +%H:%M:%S`" "#####" "$2" 1>&3 fi -) +} -usage ( ) { +usage() { ( echo "Usage: $0 [-BbfhIiKknpqvWwX] [-c config_file]" echo " -B suppress installs (both kernel and world)" @@ -911,7 +910,7 @@ usage ( ) { # Setup and Export Internal variables # -export_var ( ) { # Don't want a subshell +export_var() { var=$1 # Lookup value of the variable. eval val=\$$var @@ -920,8 +919,7 @@ export_var ( ) { # Don't want a subshell } # Call this function to set defaults _after_ parsing options. -# don't want a subshell otherwise variable setting is thrown away. -set_defaults_and_export ( ) { +set_defaults_and_export() { : ${NANO_OBJ:=/usr/obj/nanobsd.${NANO_NAME}${NANO_LAYOUT:+.${NANO_LAYOUT}}} : ${MAKEOBJDIRPREFIX:=${NANO_OBJ}} : ${NANO_DISKIMGDIR:=${NANO_OBJ}} diff --git a/tools/tools/nanobsd/embedded/common b/tools/tools/nanobsd/embedded/common index 4aecd3602f6f..132ca9e2ba5b 100644 --- a/tools/tools/nanobsd/embedded/common +++ b/tools/tools/nanobsd/embedded/common @@ -1,4 +1,4 @@ - +#!/bin/sh #- # Copyright (c) 2015 M. Warner Losh # Copyright (c) 2010-2011 iXsystems, Inc. @@ -113,18 +113,18 @@ NANO_FAT_DIR=${NANO_LOG}/_.fat customize_cmd cust_allow_ssh_root -add_etc_make_conf ( ) ( +add_etc_make_conf() { touch ${NANO_WORLDDIR}/etc/make.conf -) +} customize_cmd add_etc_make_conf -cust_install_machine_files ( ) ( +cust_install_machine_files() { echo "cd ${NANO_CFG_BASE}/Files" cd ${NANO_CFG_BASE}/Files find . -print | grep -Ev '/(CVS|\.svn|\.hg|\.git)' | cpio -dumpv ${NANO_WORLDDIR} -) +} customize_cmd cust_install_files -customize_cmd cust_install_machine_files +customize_cmd cust_install_machine_files CONF_BUILD=" LOCAL_XTOOL_DIRS=usr.bin/mkimg @@ -173,13 +173,13 @@ NANO_PACKAGE_ONLY=1 # Creates images for all the formats that use MBR / GPT # split later if the #ifdef soup gets too bad. -create_diskimage_gpt ( ) ( +create_diskimage_gpt() { pprint 2 "build diskimage gpt ${NANO_NAME}" create_diskimage_mbr $* -) +} -create_diskimage_mbr ( ) ( +create_diskimage_mbr() { local fmt @@ -314,7 +314,7 @@ create_diskimage_mbr ( ) ( rm -f ${out}.xz xz -9 --keep ${out} ) > ${NANO_LOG}/_.di 2>&1 -) +} die( ) { echo "$*" @@ -373,7 +373,7 @@ $var=$val" fi done -typical_embedded ( ) ( +typical_embedded() { # Need to create rc.conf before we copy over /etc to /conf/base/etc # so now's a good time. @@ -388,10 +388,10 @@ typical_embedded ( ) ( # Make sure that firstboot scripts run so growfs works. # Note: still some issues remvoing this XXX touch ${NANO_WORLDDIR}/firstboot -) +} customize_cmd typical_embedded -fix_pkg ( ) ( +fix_pkg() { chdir ${NANO_WORLDDIR} mkdir -p pkg mkdir -p pkg/db @@ -410,20 +410,20 @@ fix_pkg ( ) ( echo "./pkg/db type=dir uname=root gname=wheel mode=0755" echo "./pkg/tmp type=dir uname=root gname=wheel mode=0755" ) >> ${NANO_METALOG} -) +} customize_cmd fix_pkg -save_build ( ) ( +save_build() { VERSION_FILE=${NANO_WORLDDIR}/etc/version if [ "${SVNREVISION}" = "${REVISION}" ]; then echo "${NANO_NAME}" > "${VERSION_FILE}" else echo "${NANO_NAME} (${SVNREVISION})" > "${VERSION_FILE}" fi -) +} customize_cmd save_build -shrink_md_fbsize ( ) ( +shrink_md_fbsize() { # We have a lot of little files on our memory disks. Let's decrease # the block and frag size to fit more little files on them (this # halves our space requirement by ~50% on /etc and /var on 8.x -- @@ -431,12 +431,12 @@ shrink_md_fbsize ( ) ( # are 4 times larger). sed -i '' -e 's,-S -i 4096,-S -i 4096 -b 4096 -f 512,' \ ${NANO_WORLDDIR}/etc/rc.initdiskless -) +} customize_cmd shrink_md_fbsize customize_cmd cust_comconsole -dos_boot_part ( ) ( +dos_boot_part() { local d=/usr/local/share/u-boot/${NANO_BOOT_PKG} local f=${NANO_FAT_DIR} @@ -453,7 +453,7 @@ dos_boot_part ( ) ( # Now we need to copy over dtb files from the build. cp ${NANO_WORLDDIR}/boot/dtb/*.dtb . -) +} if [ -n "$NANO_BOOT_PKG" ]; then d=/usr/local/share/u-boot/${NANO_BOOT_PKG} @@ -468,7 +468,7 @@ if [ -n "$NANO_BOOT_PKG" ]; then customize_cmd dos_boot_part fi -product_custom ( ) ( +product_custom() { # not quite ready to tweak these in nopriv build if [ -z ${NANO_NOPRIV_BUILD} ]; then # Last second tweaks -- generally not needed @@ -480,7 +480,7 @@ product_custom ( ) ( chown root:wheel ${NANO_WORLDDIR}/ chown root:wheel ${NANO_WORLDDIR}/usr fi -) +} late_customize_cmd product_custom # @@ -615,19 +615,19 @@ esac NANO_SLICE_DATA= # Not included # These don't make any sense to this strategy, so stub them out. -calculate_partitioning ( ) ( -) +calculate_partitioning() { +} # These don't make any sense to this strategy, so stub them out. -create_code_slice ( ) ( -) +create_code_slice() { +} # Each major disk scheme has its own routine. Generally # this is for mbr, gpt, etc. These are generally are widely # shared, but some specialized formats won't be shared. -create_diskimage ( ) ( +create_diskimage() { eval create_diskimage_${NANO_DISK_SCHEME} -) +} # Set the path to the same path we use for buldworld to use latest mkimg NANO_TARGET=$(cd ${NANO_SRC}; ${NANO_MAKE} TARGET_ARCH=${NANO_ARCH} -V _TARGET) diff --git a/tools/tools/nanobsd/legacy.sh b/tools/tools/nanobsd/legacy.sh index 2f689212263e..cbe56d6f560c 100644 --- a/tools/tools/nanobsd/legacy.sh +++ b/tools/tools/nanobsd/legacy.sh @@ -34,7 +34,7 @@ # Functions and variable definitions used by the legacy nanobsd # image building system. -calculate_partitioning ( ) ( +calculate_partitioning() { echo $NANO_MEDIASIZE $NANO_IMAGES \ $NANO_SECTS $NANO_HEADS \ $NANO_CODESIZE $NANO_CONFSIZE $NANO_DATASIZE | @@ -90,9 +90,9 @@ calculate_partitioning ( ) ( } } ' > ${NANO_LOG}/_.partitioning -) +} -create_code_slice ( ) ( +create_code_slice() { pprint 2 "build code slice" pprint 3 "log: ${NANO_OBJ}/_.cs" @@ -142,10 +142,10 @@ create_code_slice ( ) ( trap - 1 2 15 EXIT ) > ${NANO_OBJ}/_.cs 2>&1 -) +} -create_diskimage ( ) ( +create_diskimage() { pprint 2 "build diskimage" pprint 3 "log: ${NANO_OBJ}/_.di" @@ -243,4 +243,4 @@ create_diskimage ( ) ( trap - 1 2 15 EXIT ) > ${NANO_LOG}/_.di 2>&1 -) +} diff --git a/tools/tools/nanobsd/rescue/common b/tools/tools/nanobsd/rescue/common index 15bf10f5e67d..a145a1ded32a 100644 --- a/tools/tools/nanobsd/rescue/common +++ b/tools/tools/nanobsd/rescue/common @@ -1,5 +1,5 @@ -# -# +#!/bin/sh + #NANO_SRC=$(pwd) #NANO_SRC=${NANO_SRC%/tools/tools/nanobsd/rescue} #NANO_OBJ=${NANO_SRC}/../nanobsd-builds/${NANO_NAME}/obj @@ -24,12 +24,12 @@ NANO_MD_BACKING=file # Options to put in make.conf during buildworld only CONF_BUILD=' ' -# Options to put in make.conf during installworld only +# Options to put in make.conf during installworld only CONF_INSTALL=' ' -# Options to put in make.conf during both build- & installworld. -CONF_WORLD=' -CFLAGS=-O -pipe +# Options to put in make.conf during both build- & installworld. +CONF_WORLD=' +CFLAGS=-O -pipe # We do not need these for rescue WITHOUT_TESTS=true WITHOUT_DEBUG_FILES=true @@ -71,9 +71,9 @@ customize_cmd cust_install_files #customize_cmd cust_pkgng -cust_etc_cfg () ( - cd ${NANO_WORLDDIR} -# mkdir -pv scratch +cust_etc_cfg() { + cd ${NANO_WORLDDIR} + # mkdir -pv scratch echo "hostname=\"rescue\"" > etc/rc.conf echo "font8x14=\"iso15-8x14\"" >> etc/rc.conf echo "font8x16=\"iso15-8x16\"" >> etc/rc.conf @@ -85,12 +85,12 @@ cust_etc_cfg () ( echo "/dev/${NANO_DRIVE}s3 /cfg ufs rw,noauto 2 2" >> etc/fstab echo "tmpfs /boot/zfs tmpfs rw,size=1048576,mode=777 0 0" >> etc/fstab echo "ports:/usr/ports /usr/ports nfs rw,noauto,noatime,bg,soft,intr,nfsv3 0 0" >> etc/fstab -# echo "/dev/ad1s1a /scratch ufs rw,noauto,noatime 0 0" >> etc/fstab + # echo "/dev/ad1s1a /scratch ufs rw,noauto,noatime 0 0" >> etc/fstab /usr/sbin/pwd_mkdb -d etc etc/master.passwd -) +} customize_cmd cust_etc_cfg -setup_nanobsd_etc ( ) ( +setup_nanobsd_etc() { pprint 2 "configure nanobsd /etc" ( cd ${NANO_WORLDDIR} @@ -102,8 +102,8 @@ setup_nanobsd_etc ( ) ( echo "NANO_DRIVE=${NANO_DRIVE}" > etc/nanobsd.conf mkdir -p cfg ) -) -last_orders () ( +} +last_orders() { pprint 2 "last orders" ( cd ${NANO_WORLDDIR} @@ -112,7 +112,7 @@ last_orders () ( echo "/dev/iso9660/${BIGLABEL} / cd9660 ro,noatime 0 0" > etc/fstab echo "tmpfs /boot/zfs tmpfs rw,size=1048576,mode=777 0 0" >> etc/fstab echo "ports:/usr/ports /usr/ports nfs rw,noauto,noatime,bg,soft,intr,nfsv3 0 0" >> etc/fstab -# echo "/dev/ad1s1a /scratch ufs rw,noauto,noatime 0 0" >> etc/fstab + # echo "/dev/ad1s1a /scratch ufs rw,noauto,noatime 0 0" >> etc/fstab rm -f conf/default/etc/remount touch conf/default/etc/.keepme touch conf/default/var/.keepme @@ -125,4 +125,4 @@ last_orders () ( -o label="${BIGLABEL}" -o publisher="RMX" \ -o bootimage="i386;_.w/boot/cdboot" -o no-emul-boot _.disk.iso _.w/ ) -) +} From nobody Thu Sep 18 19:17:50 2025 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 4cSQQ65qX9z67tG7; Thu, 18 Sep 2025 19:17:50 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSQQ64lb6z3Fm8; Thu, 18 Sep 2025 19:17:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758223070; 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=W7FWcqWvu9hxM0dk5Rnwtfq7rHeXO7jV/cvq2IrSao0=; b=RxfcOt2BHkQZG1KG8CPib3madlNjGkliZ3uP8ORvZVffjS+Q7O0dsVXid6l9YYC4fxs8Mg 1qEzYVXS47U+/Bs2RXPye/7m53+cWC1OAoLv9VUkEclwER5/U4RvDKhSLfAFAHpJf2DlvS o/ugqAP7oUjB0pKWn9xaeSE0EAOjYkbuFlW/q3Hu3kRVDrSXb4npTBgv6rvKUQzR+ACIWG 7CMAN5/u6SiFmNwrWtRqt2TcmWY54qNkROvNqQV62MF6HKdFud2fllQk7zFZgcf3gatjvN iZkFJZg4Ey7GdcPKR8qpYbF0zTwbPwZ0/k115Omb3lhqZ6rmJ++gZiHBLuX9kQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758223070; 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=W7FWcqWvu9hxM0dk5Rnwtfq7rHeXO7jV/cvq2IrSao0=; b=sVJarPxz6CWLmsocVVdfFo0695ikya1f5BRFpBEwwRkqAC6OiVXGmbGNbO9zTsltaTJDjg xpIBxMxxFMAlDB6+kn2gxkEW1/JguXPyrcCax+sREkwuURG17RmXz0Jhm3uaQUftPGxWUo 0YJERlha0i7mG//houYrb/NjuKWZsuNVpjllXs1bOmQesjn42CmQ7Dgt//AAL3vhKuwWqq WONiG4FEfTRJ77VGDZbhSLlfdy5jt14w7XMasC16OcdcxOTamRrYmHhtUZUVeFsX2EoNAb x3qg/5/cmbPhgy2Wrzez4FGq9/Pvcf/ZAaU0Aqxr/wqnY7gqqf9by/c1gjAYIQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758223070; a=rsa-sha256; cv=none; b=ZcZo/s8JBMJ8FRJCTHiwTgtt/Esnh+hQFhDbk+dflwq9PlwL8LzxUeoI6bgc98mXC0ZbDF PuwBiU9moEzUGabW5wmxR7zTN6zcouxijWAwWHaiXkpCheakypC+WyMlAO5QngHFj9e/pQ fHXPa+tAmXjavIuwWa0pp7Jw+a6Ua+7Z8rHSjIFwA/IIOF/9fD1oJWembu5VicA17yfckF UA1CMqp20SKeTCPOfWJqEv6nKFQx3x+RnUsS1i0DtFSkBvKvTc97RsW7L2sBW9KaJnMqjA x+4w+Ca8dQRaDbnsT/fMwnf69GXOPUwO1QeypFMCY7dMdEOiToULm5gj/mZAHg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSQQ642FHz7Xg; Thu, 18 Sep 2025 19:17:50 +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 58IJHo0K088810; Thu, 18 Sep 2025 19:17:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IJHoPv088807; Thu, 18 Sep 2025 19:17:50 GMT (envelope-from git) Date: Thu, 18 Sep 2025 19:17:50 GMT Message-Id: <202509181917.58IJHoPv088807@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Enji Cooper Subject: git: d5984d5f29a7 - main - OpenSSL: update Makefiles to reflect 3.5.1 release 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: ngie X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d5984d5f29a7c717b88ccd17a85a747792403cdf Auto-Submitted: auto-generated The branch main has been updated by ngie: URL: https://cgit.FreeBSD.org/src/commit/?id=d5984d5f29a7c717b88ccd17a85a747792403cdf commit d5984d5f29a7c717b88ccd17a85a747792403cdf Author: Enji Cooper AuthorDate: 2025-09-08 03:20:42 +0000 Commit: Enji Cooper CommitDate: 2025-09-18 19:17:44 +0000 OpenSSL: update Makefiles to reflect 3.5.1 release This is a targeted effort to update the INCS and SRCS entries for libcrypto, the legacy provider, and libssl to match what upstream (OpenSSL) builds in their respective libraries. The number of stylistic changes were kept at a minimum. Another incoming change will reformat this file to make future maintenance easier. MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52554 --- secure/lib/libcrypto/Makefile | 49 +++++++++++++++++----------- secure/lib/libcrypto/modules/Makefile.inc | 7 ---- secure/lib/libcrypto/modules/legacy/Makefile | 41 ++++++++++++++++++++--- secure/lib/libssl/Makefile | 2 +- share/mk/src.libnames.mk | 2 +- 5 files changed, 68 insertions(+), 33 deletions(-) diff --git a/secure/lib/libcrypto/Makefile b/secure/lib/libcrypto/Makefile index 75ebb6e65327..5cb3f5a7c3fe 100644 --- a/secure/lib/libcrypto/Makefile +++ b/secure/lib/libcrypto/Makefile @@ -91,7 +91,7 @@ SRCS+= x_bignum.c x_info.c x_int64.c x_long.c x_pkey.c x_sig.c x_spki.c SRCS+= x_val.c # async -SRCS+= async.c async_err.c async_posix.c async_wait.c +SRCS+= async.c async_err.c async_null.c async_posix.c async_wait.c async_win.c # bf SRCS+= bf_cfb64.c bf_ecb.c bf_ofb64.c bf_prefix.c bf_readbuff.c bf_skey.c @@ -224,7 +224,11 @@ SRCS+= dsa_gen.c dsa_key.c dsa_lib.c dsa_meth.c dsa_ossl.c dsa_pmeth.c SRCS+= dsa_prn.c dsa_sign.c dsa_vrf.c # dso +SRCS+= dso_dl.c SRCS+= dso_dlfcn.c dso_err.c dso_lib.c +SRCS+= dso_openssl.c +SRCS+= dso_vms.c +SRCS+= dso_win32.c # ec SRCS+= curve25519.c curve448.c curve448_tables.c ec2_oct.c ec2_smpl.c @@ -291,7 +295,7 @@ SRCS+= ffc_params.c ffc_params_generate.c ffc_params_validate.c SRCS+= hashtable.c hashfunc.c # hmac -SRCS+= hmac.c hmac_s390x.c +SRCS+= hmac.c # hpke SRCS+= hpke_util.c hpke.c @@ -424,17 +428,10 @@ SRCS+= cipher_aes_xts_fips.c SRCS+= cipher_aes_gcm_siv.c cipher_aes_gcm_siv_hw.c \ cipher_aes_gcm_siv_polyval.c SRCS+= cipher_aes_siv.c cipher_aes_siv_hw.c -SRCS+= cipher_blowfish.c cipher_blowfish_hw.c SRCS+= cipher_camellia.c cipher_camellia_hw.c -SRCS+= cipher_cast5.c cipher_cast5_hw.c SRCS+= cipher_chacha20.c cipher_chacha20_hw.c SRCS+= cipher_chacha20_poly1305.c cipher_chacha20_poly1305_hw.c -SRCS+= cipher_des.c cipher_des_hw.c -SRCS+= cipher_desx.c cipher_desx_hw.c SRCS+= cipher_null.c -SRCS+= cipher_rc4.c cipher_rc4_hw.c -SRCS+= cipher_rc4_hmac_md5.c cipher_rc4_hmac_md5_hw.c -SRCS+= cipher_seed.c cipher_seed_hw.c SRCS+= cipher_tdes.c cipher_tdes_common.c cipher_tdes_hw.c SRCS+= cipher_tdes_default.c cipher_tdes_default_hw.c \ cipher_tdes_wrap.c cipher_tdes_wrap_hw.c @@ -442,12 +439,10 @@ SRCS+= cipher_tdes_default.c cipher_tdes_default_hw.c \ # providers/implementations/digests SRCS+= digestcommon.c SRCS+= blake2_prov.c blake2b_prov.c blake2s_prov.c -SRCS+= md4_prov.c SRCS+= md5_prov.c md5_sha1_prov.c SRCS+= null_prov.c SRCS+= ripemd_prov.c SRCS+= sha2_prov.c sha3_prov.c -SRCS+= wp_prov.c # providers/implementations/encode_decode SRCS+= decode_der2key.c decode_epki2pki.c decode_msblob2key.c decode_pvk2key.c @@ -463,8 +458,8 @@ SRCS+= kdf_exch.c # providers/implementations/kdfs SRCS+= argon2.c hkdf.c hmacdrbg_kdf.c kbkdf.c krb5kdf.c -SRCS+= pbkdf1.c pbkdf2.c pbkdf2_fips.c -SRCS+= pkcs12kdf.c pvkkdf.c scrypt.c sskdf.c sshkdf.c tls1_prf.c x942kdf.c +SRCS+= pbkdf2.c pbkdf2_fips.c +SRCS+= pkcs12kdf.c scrypt.c sskdf.c sshkdf.c tls1_prf.c x942kdf.c # providers/implementations/kem SRCS+= ec_kem.c ecx_kem.c kem_util.c ml_kem_kem.c mlx_kem.c rsa_kem.c @@ -484,6 +479,7 @@ SRCS+= siphash_prov.c # providers/implementations/rands SRCS+= drbg.c drbg_ctr.c drbg_hash.c drbg_hmac.c test_rng.c SRCS+= seed_src.c +SRCS+= seed_src_jitter.c # providers/implementations/rands/seeding SRCS+= rand_cpu_x86.c rand_tsc.c rand_unix.c rand_win.c @@ -499,7 +495,7 @@ SRCS+= aes_skmgmt.c generic.c SRCS+= file_store.c file_store_any2obj.c # rand -SRCS+= prov_seed.c rand_deprecated.c rand_egd.c rand_err.c rand_lib.c +SRCS+= prov_seed.c rand_deprecated.c rand_err.c rand_lib.c SRCS+= rand_meth.c rand_pool.c rand_uniform.c randfile.c # rc2 @@ -573,7 +569,10 @@ SRCS+= store_err.c store_init.c store_lib.c store_meth.c store_register.c SRCS+= store_result.c store_strings.c # thread -SRCS+= api.c arch.c arch/thread_win.c arch/thread_posix.c arch/thread_none.c internal.c +SRCS+= api.c arch.c internal.c +SRCS+= thread_none.c +SRCS+= thread_posix.c +SRCS+= thread_win.c # ts SRCS+= ts_asn1.c ts_conf.c ts_err.c ts_lib.c ts_req_print.c ts_req_utils.c @@ -620,11 +619,21 @@ SRCS+= x509type.c INCS= aes.h asn1.h asn1err.h asn1t.h async.h asyncerr.h bio.h INCS+= bioerr.h blowfish.h bn.h bnerr.h buffer.h buffererr.h byteorder.h camellia.h -INCS+= cast.h cmac.h cmp.h cmp_util.h cmperr.h cms.h cmserr.h comp.h comperr.h conf.h conf_api.h +INCS+= cast.h cmac.h cmp.h cmp_util.h cmperr.h cms.h cmserr.h comp.h comperr.h conf.h INCS+= conferr.h configuration.h conftypes.h core.h core_dispatch.h core_names.h core_object.h INCS+= crmf.h crmferr.h crypto.h cryptoerr.h cryptoerr_legacy.h ct.h cterr.h -INCS+= decoder.h decodererr.h des.h dh.h dherr.h dsa.h -INCS+= dsaerr.h dtls1.h e_os2.h e_ostime.h ebcdic.h ec.h ecdh.h ecdsa.h ecerr.h encoder.h encodererr.h +INCS+= decoder.h decodererr.h +INCS+= der_digests.h +INCS+= der_dsa.h +INCS+= der_ec.h +INCS+= der_ecx.h +INCS+= der_ml_dsa.h +INCS+= der_rsa.h +INCS+= der_slh_dsa.h +INCS+= der_wrap.h +INCS+= des.h dh.h dherr.h dsa.h +INCS+= dsaerr.h +INCS+= dtls1.h e_os2.h e_ostime.h ebcdic.h ec.h ecdh.h ecdsa.h ecerr.h encoder.h encodererr.h INCS+= engine.h engineerr.h err.h ess.h esserr.h evp.h evperr.h fips_names.h fipskey.h hmac.h hpke.h http.h httperr.h idea.h indicator.h INCS+= kdf.h kdferr.h lhash.h macros.h md2.h md4.h md5.h mdc2.h modes.h obj_mac.h INCS+= objects.h objectserr.h ocsp.h ocsperr.h opensslconf.h opensslv.h @@ -762,6 +771,7 @@ PICFLAG+= -DOPENSSL_PIC ${LCRYPTO_SRC}/crypto/stack \ ${LCRYPTO_SRC}/crypto/store \ ${LCRYPTO_SRC}/crypto/thread \ + ${LCRYPTO_SRC}/crypto/thread/arch \ ${LCRYPTO_SRC}/crypto/ts \ ${LCRYPTO_SRC}/crypto/txt_db \ ${LCRYPTO_SRC}/crypto/ui \ @@ -771,6 +781,7 @@ PICFLAG+= -DOPENSSL_PIC ${LCRYPTO_SRC}/providers \ ${LCRYPTO_SRC}/providers/common \ ${LCRYPTO_SRC}/providers/common/der \ + ${LCRYPTO_SRC}/providers/common/include/prov \ ${LCRYPTO_SRC}/providers/implementations/asymciphers \ ${LCRYPTO_SRC}/providers/implementations/ciphers \ ${LCRYPTO_SRC}/providers/implementations/digests \ @@ -787,4 +798,4 @@ PICFLAG+= -DOPENSSL_PIC ${LCRYPTO_SRC}/providers/implementations/storemgmt \ ${LCRYPTO_SRC}/ssl \ ${LCRYPTO_SRC}/ssl/record \ - ${LCRYPTO_SRC}/ssl/record/methods + ${LCRYPTO_SRC}/ssl/record/methods \ diff --git a/secure/lib/libcrypto/modules/Makefile.inc b/secure/lib/libcrypto/modules/Makefile.inc index 4b3d9fc512ce..64fb57ee74c5 100644 --- a/secure/lib/libcrypto/modules/Makefile.inc +++ b/secure/lib/libcrypto/modules/Makefile.inc @@ -10,11 +10,4 @@ CFLAGS+= -I${LCRYPTO_SRC}/providers/common/include CFLAGS+= -I${LCRYPTO_SRC}/providers/fips/include CFLAGS+= -I${LCRYPTO_SRC}/providers/implementations/include -# common -SRCS+= provider_err.c provider_ctx.c -SRCS+= provider_util.c - -.PATH: ${LCRYPTO_SRC}/providers \ - ${LCRYPTO_SRC}/providers/common - WARNS?= 0 diff --git a/secure/lib/libcrypto/modules/legacy/Makefile b/secure/lib/libcrypto/modules/legacy/Makefile index db05f212f62a..8f91d9504504 100644 --- a/secure/lib/libcrypto/modules/legacy/Makefile +++ b/secure/lib/libcrypto/modules/legacy/Makefile @@ -1,7 +1,7 @@ SHLIB_NAME?= legacy.so LIBADD= crypto -SRCS+= legacyprov.c prov_running.c params_idx.c +SRCS+= legacyprov.c prov_running.c # ciphers SRCS+= ciphercommon.c ciphercommon_hw.c ciphercommon_block.c \ @@ -16,17 +16,48 @@ SRCS+= cipher_rc4.c cipher_rc4_hw.c SRCS+= cipher_rc4_hmac_md5.c cipher_rc4_hmac_md5_hw.c SRCS+= cipher_seed.c cipher_seed_hw.c -# digests +# crypto +SRCS+= cpuid.c +SRCS+= ctype.c + +# crypto/des +SRCS+= des_enc.c +SRCS+= fcrypt_b.c + +# crypto/md5 +SRCS+= md5_dgst.c +SRCS+= md5_one.c +SRCS+= md5_sha1.c + +# providers/implementations/digests SRCS+= digestcommon.c SRCS+= md4_prov.c wp_prov.c ripemd_prov.c -# kdfs -SRCS+= pbkdf1.c pvkkdf.c +# providers/implementations/kdfs +SRCS+= pbkdf1.c +SRCS+= pvkkdf.c + +# common +SRCS+= provider_err.c provider_ctx.c +SRCS+= provider_util.c + +SRCS+= tls_pad.c + +# This is needed so the provider can be loaded for us. +# +# There's a discrepancy between how this provider gets built in OpenSSL proper +# and FreeBSD. +SRCS+= params_idx.c .include .PATH: ${LCRYPTO_SRC}/crypto \ + ${LCRYPTO_SRC}/crypto/des \ + ${LCRYPTO_SRC}/crypto/md5 \ + ${LCRYPTO_SRC}/providers \ + ${LCRYPTO_SRC}/providers/common \ ${LCRYPTO_SRC}/providers/implementations/ciphers \ ${LCRYPTO_SRC}/providers/implementations/digests \ ${LCRYPTO_SRC}/providers/implementations/kdfs \ - ${LCRYPTO_SRC}/ssl + ${LCRYPTO_SRC}/ssl \ + ${LCRYPTO_SRC}/ssl/record/methods \ diff --git a/secure/lib/libssl/Makefile b/secure/lib/libssl/Makefile index b0ca31644279..fe2e2492045f 100644 --- a/secure/lib/libssl/Makefile +++ b/secure/lib/libssl/Makefile @@ -76,7 +76,7 @@ CFLAGS+=-DOPENSSL_NO_KTLS SRCS+= ktls_meth.c .endif -LIBADD= crypto +LIBADD= pthread crypto CFLAGS+= -I${LCRYPTO_SRC}/ssl CFLAGS+= -I${.OBJDIR:H}/libcrypto diff --git a/share/mk/src.libnames.mk b/share/mk/src.libnames.mk index d6597caf7e2a..95cd3b02d8e4 100644 --- a/share/mk/src.libnames.mk +++ b/share/mk/src.libnames.mk @@ -329,7 +329,7 @@ _DP_archive+= md .endif .endif _DP_sqlite3= pthread -_DP_ssl= crypto +_DP_ssl= pthread crypto _DP_ssh= crypto crypt z .if ${MK_LDNS} != "no" _DP_ssh+= ldns From nobody Thu Sep 18 19:25:02 2025 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 4cSQZR2Bhqz67tSM; Thu, 18 Sep 2025 19:25:03 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSQZR0d7Fz3GxP; Thu, 18 Sep 2025 19:25:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758223503; 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=rhPBSpMkGEiE3vTtYjM5zD7VQyZTQfdj+CXiWX5kVcc=; b=xG0r3faSZH8Bfc5nBEWmEjrY9EmM3/hFKhWBmA82BPGDLilomD+nHwndVsUdqtVNh+/6kY exnekNOkY9/kVs0tKXY/HVa6UF/VoqI/bfBkI1yp7kPs4iQ/inDqFlz9ki0IlZwcVMwjfS zZIzIsl0elqJLDIkcGQ/qQXMVDBlKhxBxcYmQ1b75RWxrWQ+rme2BHSDWe8dZOPdIDRsH7 w4lQ4JfMxwEMJ01zZ2pQUMcYQTWNeKXYLRFXkT4ISzors0XQRMn5MN1Aqt8WeGlyvij0XL 9JweMwE9hRfVx2zamwTr/C3rdjinZYPuBKpUde1UgfMGstNUE++tq49/DDAzIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758223503; 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=rhPBSpMkGEiE3vTtYjM5zD7VQyZTQfdj+CXiWX5kVcc=; b=X9BoqtxAvAzCajwAltnS5KR8dfdUCL9OQWLcoP4y9IT5m50E0+Nu5QVgo3VmgdVtNkUBIv Je03BHIFy2h7oHXaYvxGUWOMtjgtKw1f8qNJSyK03Dm/4zlh6INUsmOMsP8KpYzbfv8L/b ghC/BiUgW64jtnLf4CVpxkE9u86Qo1YOyqLXi/iCgVSgp2b7wQjqqyzYT5onXnZ9JWTOgu VtVxroTmDRDm9/cghIK8zL70DrQ4SUeQiN4R47dPqL99ZLy8MCkoAp52xkWmpfclEb0VYF aOYy4kPsOc0xuwTyTbdPyrgsUij4cpwd1YIEg6Ky9o3LNyNitGvDRCUUgXt8Qw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758223503; a=rsa-sha256; cv=none; b=NFMelCWekUXcaSbuxOGOnZjAjneBABW6VU0mVzjT7Tflov95xyBOtrb1iAk3BcDUvOpxI/ +PFPItOPcSjTy+Zb8xf4qaJc0cgA15OHbyUfT4N8QhI7iF+qv76hKGoQd+XOSULbDmJ/QZ s4UERnNSdJHBSgNtrCxpzwIv42QzrRYvADYetPHySB7pq+iAfqPX9HgbqQEwOnUuRP8qm5 Xmax8PgmyG2bsFWLSCX/Hr4GdJ9ser1P1WHQnJp8Eh1x2kyG53ANk2g1B5jJNaJ3zwPHxa SGaES4K4XtmrGG1JAXOLzc4a/WjTGpSm82OY7dJZsIhQM+MVsKPZATCj/bcBjA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSQZR09qrz7tr; Thu, 18 Sep 2025 19:25:03 +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 58IJP233007200; Thu, 18 Sep 2025 19:25:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IJP2P1007197; Thu, 18 Sep 2025 19:25:02 GMT (envelope-from git) Date: Thu, 18 Sep 2025 19:25:02 GMT Message-Id: <202509181925.58IJP2P1007197@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Colin Percival Subject: git: 2c06b824436d - main - pkgbootstrap: Build pkg if PORTSDIR exists 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2c06b824436df6177545cc0f1603e5c3bfbf3365 Auto-Submitted: auto-generated The branch main has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=2c06b824436df6177545cc0f1603e5c3bfbf3365 commit 2c06b824436df6177545cc0f1603e5c3bfbf3365 Author: Colin Percival AuthorDate: 2025-09-18 19:21:29 +0000 Commit: Colin Percival CommitDate: 2025-09-18 19:21:29 +0000 pkgbootstrap: Build pkg if PORTSDIR exists If we don't already have the pkg tool installed, we need to install it before we can build packages for pkgbase. (This arises in release builds which run in clean chroots; most users will have pkg installed already.) Installing it from pkg.freebsd.org via "pkg bootstrap" runs into two problems: First, it's an external dependency with security implications; and second, there's a bootstrapping problem on new major versions where pkg.freebsd.org does not have packages yet. Instead, if we have a ports tree, use it to build pkg ourselves. With hat: re MFC after: 6 hours Sponsored by: https://www.patreon.com/cperciva --- Makefile.inc1 | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Makefile.inc1 b/Makefile.inc1 index cd0385ea32ac..d41741d15384 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -1992,8 +1992,16 @@ PKG_ABI!= ${PKG_CMD} -o ABI_FILE=${PKG_ABI_FILE} config ABI _pkgbootstrap: .PHONY .if make(*package*) && !exists(${LOCALBASE}/sbin/pkg) +.if exists(${PORTSDIR}/ports-mgmt/pkg/Makefile) + env - UNAME_r=${UNAME_r} PATH=$$PATH \ + make -C ${PORTSDIR}/ports-mgmt/pkg \ + I_DONT_CARE_IF_MY_BUILDS_TARGET_THE_WRONG_RELEASE=1 \ + BATCH=1 WRKDIRPREFIX=/tmp/ports DISTDIR=/tmp/distfiles \ + all install clean +.else @env ASSUME_ALWAYS_YES=YES pkg bootstrap .endif +.endif PKG_BIN_VERSION!=${PKG_CMD} --version /dev/null |\ awk -F. '/^[0-9.]+$$/ {print $$1 * 10000 + $$2 * 100 + $$3}' From nobody Thu Sep 18 21:22:42 2025 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 4cSTBC1WRnz683Sc; Thu, 18 Sep 2025 21:22:43 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSTBB6tCLz3Y2y; Thu, 18 Sep 2025 21:22:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758230563; 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=axRjiI/FZsBzTyBGshw01cWyIqcTSMAdVLIkhFRfOo0=; b=swV01QvDt3049eEyRBssEkeKI+POUNc1qh89yzwJXYDgvUkkvrcggYmW+ieM8ALw37b2WI AH2Xj9qLUmoAvx+qZ0LZ3vOExoTIIMjTYsZ+0TbTQFhk80V05NxIl6imWv8DAAFrKRic1K q6cumRpQM7AT2bUduYEFQqkAvKofIZim6t1QYb2A4N439OK5KHNb7/fkLztJFtTD5rUrfX uXY4FHdR2QQ3m5QOeeagrljYe1poSycdzAFF/OlXbjoyaYY2P4zdoNushL2Y9/cddBsFRS x1s7jbGZlMLeK8LlwTTG27sGd5DZFIR2q8n1m9dWrpFYhfltxXDEQ+kutrQzdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758230563; 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=axRjiI/FZsBzTyBGshw01cWyIqcTSMAdVLIkhFRfOo0=; b=p0Ml8x97Chgp6Q0xjjsaI8+5DradKk6zv3oi3OdP9SOdKs1l0r8DGYWANjpKwvB94lblq+ bg6HpbfCq9jflAz1+nP4U9TREQG+J4OIc+i6f7F16EA6qI/EeiocSZi4GMk96zacjg/IgL oh5auGh+CgjtWe+z16viLxnxSmPHH5bJWr6AG2lO6Zf4d6oKm5urV8wD56W5N1tauCfMFa jNmU+3jPyCaeXQE7s7dpqkVhTabLxX9yq5PVvHMb3afwG3dNqASmOlVjekWqs4lGRWj8bq r9pgovrhnKvNORRSjxWIMk6sPUG5FlektmRpkhvsbc8ufDwWw78lr9ftQJTG5w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758230563; a=rsa-sha256; cv=none; b=avnwt2K3fGhqOSfP1hz2FrpJGbF59oRiRoQiJcz2eF/NujSlOX96+8wwTylcGkYBlMKPbR 3tct6l3ZPj6VoCDLOcebvc4y6nge//G5S2VL0x32uOyXSXnWD9pHWJ9VgNFyNhG5/y+/Wu OG+XrYuBrPbikQRqWMPJ6EGN+ZI9g875am3K56mp/G4AdXEZk4INww5uJCjWb7UJuzjssv aOwwKe3ZidB+1XHZv0j3cx4d5l90dtaQ6EYKpAneS3r+FpyruV6J9hRLT3K4nJPhH08tj0 Ambwd83kwjkXz7VAqQwiCvuw0faGTFEOVBKT3AVGVilN3vadikJqQnFj5z142w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSTBB6H0CzCLX; Thu, 18 Sep 2025 21:22:42 +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 58ILMg8l030763; Thu, 18 Sep 2025 21:22:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58ILMgvh030760; Thu, 18 Sep 2025 21:22:42 GMT (envelope-from git) Date: Thu, 18 Sep 2025 21:22:42 GMT Message-Id: <202509182122.58ILMgvh030760@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 3b47fcc146da - stable/14 - release: Fix typo in powerpc mkisoimages.sh 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 3b47fcc146dae76988084983fbb95e82d44e6b54 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=3b47fcc146dae76988084983fbb95e82d44e6b54 commit 3b47fcc146dae76988084983fbb95e82d44e6b54 Author: Colin Percival AuthorDate: 2025-09-16 01:09:05 +0000 Commit: Colin Percival CommitDate: 2025-09-18 21:22:32 +0000 release: Fix typo in powerpc mkisoimages.sh "[ n foo ]" is an error and should have been "[ -n foo ]". Fortunately the only ill effect was to result in garbage in /tmp/ when creating powerpc ISO images. Fixes: 6c3e01bf8578 ("release: Randomize powerpc boot block file name") MFC after: 3 days Sponsored by: https://www.patreon.com/cperciva (cherry picked from commit 8c9a919abaa3f6f16a17586ca72bab939788bf69) --- release/powerpc/mkisoimages.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/powerpc/mkisoimages.sh b/release/powerpc/mkisoimages.sh index ba7c32f87bee..62656cdaaede 100644 --- a/release/powerpc/mkisoimages.sh +++ b/release/powerpc/mkisoimages.sh @@ -109,7 +109,7 @@ if [ -n "${METALOG}" ]; then fi makefs -D -N ${BASEBITSDIR}/etc -t cd9660 $bootable -o rockridge -o label="$LABEL" -o publisher="$publisher" "$NAME" "$MAKEFSARG" "$@" rm -f "$BASEBITSDIR/etc/fstab" -if [ n "$bootable" ]; then +if [ -n "$bootable" ]; then rm $BOOTBLOCK fi rm -rf "$BASEBITSDIR/ppc" From nobody Thu Sep 18 22:08:07 2025 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 4cSVBb4SFbz686Xv; Thu, 18 Sep 2025 22:08:07 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSVBb3t0Yz3kND; Thu, 18 Sep 2025 22:08:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758233287; 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=SQDsmDLhb+Hxo/DoTzCidGt59sSMMVf1jW7pUA62rWY=; b=Jyw2TdoAF5apWlK7c1bSEBE8TUkCehO51mX+xHHi60pJ9Wi/Nol8g1MhpBh1u4kKyJgJMD x8dX/TjfVv3+loglpXsTKrMG32MsCjZXAy0MK8Xkk4tJYz9mRcFMYWxavJcXp0bMTVfX7R 5+Hgg92EwAoicomagA77yJL/KC8A6BC7IVMLEYe7yIfuFVL+b1CvuB14a0ey28dCJTQ1K3 k9CesqLWlBzQBL1B5NgEhhMbHcps/4ZxG264R6Uci7TEq1ByAA+xF4dEJqAe2XZI3zyTG/ PfU4sT6NUgVpUl9PW2tHqW9rr8IHoWlGiCXiOq4yPOmn49m/sct/jpoJzxkJvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758233287; 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=SQDsmDLhb+Hxo/DoTzCidGt59sSMMVf1jW7pUA62rWY=; b=i0v6QnXHc7S8OQHlwgdurRr0Pu0pROdzYd8H93CW1qmIeHFMsBGpydlYIThPIqgyWUjJ75 nwuaVYjifshpwhfbYTuTenLHpEy6HeEmn/nz6IixxhJ6/pDVds9xbI5Igp4C+VTEuis3kL ySjZGiViYFTk838V0zBE6DaNAO+uoYbDqINiRR7zXKlMGa6HAo93uiZN3pMgqKSB2pmtJG lVQRRCCjIipaLGm+r2Dfed1Q3obiKv9HyCLFIW32HwwlVagFdO53A4FROpql8k4tGJIS+n SmKhKjlXILqbzWz9Qevez95MOSk6ZN9EOd80J7j7hojXHSc76loZL7A6DAnPOA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758233287; a=rsa-sha256; cv=none; b=fhYYV7A2hBZpLoaANl7a6LS4Dc0bCe1C9usSriqhnytf8P6+3u1HpRHit2r4Df2yA4Dwg8 5fIbaubU8EyS5zlU1ItQvdpE+5rGVtvqEJ0YiIkEe0L1aIb9ZNgxuEY4IQGeho9YE2TPss 3+rpMuMFN/uVeXo1/1RnwkcYCuTYkLjhXy/Sm7B46xIiyrn+0ZhubpFtOo2d7Y4lFOpKRE ZheMD3Kw9XpP+w6URS5iUmyARwfYJdFmpdBCGVwH/DXBK0U9TrmyiSI3VDKI/XGZXA5Y7m Eed63ZmakkNa7UG3NJI8QIEMeNaUl8A/z3LPBDsPKCoMxTq8rZpPSLY7rnr5Ew== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSVBb3QRGzTt8; Thu, 18 Sep 2025 22:08:07 +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 58IM87tl007811; Thu, 18 Sep 2025 22:08:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IM87fG007808; Thu, 18 Sep 2025 22:08:07 GMT (envelope-from git) Date: Thu, 18 Sep 2025 22:08:07 GMT Message-Id: <202509182208.58IM87fG007808@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ahmad Khalifa Subject: git: e0c83ab3b362 - main - gpioled: remove redundant -1 check 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: vexeduxr X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e0c83ab3b362c9bd45c5d21683012cecab28d802 Auto-Submitted: auto-generated The branch main has been updated by vexeduxr: URL: https://cgit.FreeBSD.org/src/commit/?id=e0c83ab3b362c9bd45c5d21683012cecab28d802 commit e0c83ab3b362c9bd45c5d21683012cecab28d802 Author: Ahmad Khalifa AuthorDate: 2025-09-18 22:03:32 +0000 Commit: Ahmad Khalifa CommitDate: 2025-09-18 22:06:37 +0000 gpioled: remove redundant -1 check The function is never called with onoff = -1 MFC after: 3 days MFC with: 9ae3c30 --- sys/dev/gpio/gpioled.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/sys/dev/gpio/gpioled.c b/sys/dev/gpio/gpioled.c index 71af5741b2fe..a36c2faef379 100644 --- a/sys/dev/gpio/gpioled.c +++ b/sys/dev/gpio/gpioled.c @@ -75,8 +75,6 @@ gpioled_control(void *priv, int onoff) struct gpioled_softc *sc; sc = (struct gpioled_softc *)priv; - if (onoff == -1) /* Keep the current state. */ - return; if (sc->sc_softinvert) onoff = !onoff; GPIOLED_LOCK(sc); From nobody Thu Sep 18 22:10:52 2025 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 4cSVFn0svDz686pd; Thu, 18 Sep 2025 22:10:53 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSVFn07T5z3lSx; Thu, 18 Sep 2025 22:10:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758233453; 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=1SiiepdOcRXUTlnSP7B1MpaZZJ93iX1viO1cAMsIRFA=; b=iEQEuWs95wUm9q+9kvyZJW9GP3VtizOMB6jJM7AWyD4ylA5RJSkYE2MrUhyg0InyUNyG/i F8yPaqYv75PmtvO3PH19o9dUckErgPdlyntb7WSKpvDvhyK9Luhz7mDuuQPXZ8fnh84/6L YDeCd5O+bpmHiwgN+hhO5nmOM5XY2U5MS+U+kw3WvrDcaVcby3ALKksghEdi4CmyNMAUCw Cf7fKQA9ep343ytWe/Nez/ayeDgcVjHH5K2Xg+hYipJRNA71pjvLvBbl4vEq5F39dFfA4N FcIXspKYa8ifZ/ye2bLxfk/wrqEx0WbChzn/rr4cLeEsOyFs70td4saHJ0CnIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758233453; 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=1SiiepdOcRXUTlnSP7B1MpaZZJ93iX1viO1cAMsIRFA=; b=ZqtYE8bEeMX1HFX2BJ+mxB8AYmGlnS3MNNKZJ6B8J0YUsVChUDpr8UiqV1IDl+94wt94Nj LXNP/Ol/lBs0rwaBMXegVk+lh8S/Y5mx6A2QJx7QykhrWQgOseOeZ8iM/r2Pdv4opBw0+n /zMvtVEmzVn526kNu+4Le/sHJzY2HpTb+3eCQGTdMkQRIWloT6hiUBNowEOrQbCbP/9RFp 24TP0y1E0ly4i0mIYrNsNWi7UsXzCZIGW3HyrXnx3TZDBG1w/zKUSZw3rp2G7KGzSlwJx4 Hu6Vv+vEDezBITS/yI9EgolAs7KlKr5sI0lzHAbII9K/5Ro1u1Qfm7zdeCxIlg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758233453; a=rsa-sha256; cv=none; b=Zf6dJiBhJWh6HXOPQxrynGFMH5sTHbX7oXBqGbl2+/9SK7knBzDt5bPIjVPtW6Y4C5OxeQ qOT9RLEx9uFrhXG16yfFV8L2JSt/FC23aFYWSpH1cej+eMcLgEd+b8FWUfVln+I53ojwuZ SdI4YNQRZZbGhR5kUiUpyZaobCo2mywIxHjQYA2Eom3DOcSPwj4E8hykl8VU3FGCZA7/aW CgPM+hQH+BKTFocPSIyprH9xVi3Evwga3Pm5/EYh3zec3vHKAieTvaGDLGHswxO15IZK21 Ecm2cfo8V3SEE5PTspgLqSj4YbMk6QS7q1Z5MeUZlB39gTu8dCxKBLMCD2Qy6A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSVFm6mwSzTbK; Thu, 18 Sep 2025 22:10:52 +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 58IMAqtF020979; Thu, 18 Sep 2025 22:10:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IMAqu2020976; Thu, 18 Sep 2025 22:10:52 GMT (envelope-from git) Date: Thu, 18 Sep 2025 22:10:52 GMT Message-Id: <202509182210.58IMAqu2020976@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: bf115203bb8a - main - dtrace: Deduplicate dtrace_sync() and dtrace_xcall() implementations 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: bf115203bb8a61bd03ba23931ff0b5bf931b7d1b Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=bf115203bb8a61bd03ba23931ff0b5bf931b7d1b commit bf115203bb8a61bd03ba23931ff0b5bf931b7d1b Author: Mark Johnston AuthorDate: 2025-09-17 15:29:48 +0000 Commit: Mark Johnston CommitDate: 2025-09-18 22:09:49 +0000 dtrace: Deduplicate dtrace_sync() and dtrace_xcall() implementations dtrace_xcall() is just a thin wrapper around smp_rendezvous_cpus(). There's no need for six identical implementations to live in MD layers. No functional change intended. MFC after: 2 weeks --- .../contrib/opensolaris/uts/common/dtrace/dtrace.c | 25 ++++++++++++++++++++ sys/cddl/dev/dtrace/aarch64/dtrace_subr.c | 27 ---------------------- sys/cddl/dev/dtrace/amd64/dtrace_subr.c | 25 -------------------- sys/cddl/dev/dtrace/arm/dtrace_subr.c | 25 -------------------- sys/cddl/dev/dtrace/i386/dtrace_subr.c | 25 -------------------- sys/cddl/dev/dtrace/powerpc/dtrace_subr.c | 25 -------------------- sys/cddl/dev/dtrace/riscv/dtrace_subr.c | 27 ---------------------- 7 files changed, 25 insertions(+), 154 deletions(-) diff --git a/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c b/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c index 8078f3f6d4b1..853cfb845878 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c +++ b/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c @@ -707,6 +707,31 @@ dtrace_error(uint32_t *counter) } while (dtrace_cas32(counter, oval, nval) != oval); } +void +dtrace_xcall(processorid_t cpu, dtrace_xcall_t func, void *arg) +{ + cpuset_t cpus; + + if (cpu == DTRACE_CPUALL) + cpus = all_cpus; + else + CPU_SETOF(cpu, &cpus); + + smp_rendezvous_cpus(cpus, smp_no_rendezvous_barrier, func, + smp_no_rendezvous_barrier, arg); +} + +static void +dtrace_sync_func(void) +{ +} + +void +dtrace_sync(void) +{ + dtrace_xcall(DTRACE_CPUALL, (dtrace_xcall_t)dtrace_sync_func, NULL); +} + /* * Use the DTRACE_LOADFUNC macro to define functions for each of loading a * uint8_t, a uint16_t, a uint32_t and a uint64_t. diff --git a/sys/cddl/dev/dtrace/aarch64/dtrace_subr.c b/sys/cddl/dev/dtrace/aarch64/dtrace_subr.c index 32e84d8fbfe9..ff880e804770 100644 --- a/sys/cddl/dev/dtrace/aarch64/dtrace_subr.c +++ b/sys/cddl/dev/dtrace/aarch64/dtrace_subr.c @@ -124,33 +124,6 @@ dtrace_toxic_ranges(void (*func)(uintptr_t base, uintptr_t limit)) (*func)(0, (uintptr_t)VM_MIN_KERNEL_ADDRESS); } -void -dtrace_xcall(processorid_t cpu, dtrace_xcall_t func, void *arg) -{ - cpuset_t cpus; - - if (cpu == DTRACE_CPUALL) - cpus = all_cpus; - else - CPU_SETOF(cpu, &cpus); - - smp_rendezvous_cpus(cpus, smp_no_rendezvous_barrier, func, - smp_no_rendezvous_barrier, arg); -} - -static void -dtrace_sync_func(void) -{ - -} - -void -dtrace_sync(void) -{ - - dtrace_xcall(DTRACE_CPUALL, (dtrace_xcall_t)dtrace_sync_func, NULL); -} - static uint64_t nsec_scale; #define SCALE_SHIFT 25 diff --git a/sys/cddl/dev/dtrace/amd64/dtrace_subr.c b/sys/cddl/dev/dtrace/amd64/dtrace_subr.c index 81aa53d00bd8..877d52fe18a7 100644 --- a/sys/cddl/dev/dtrace/amd64/dtrace_subr.c +++ b/sys/cddl/dev/dtrace/amd64/dtrace_subr.c @@ -142,31 +142,6 @@ dtrace_toxic_ranges(void (*func)(uintptr_t base, uintptr_t limit)) (*func)(0, la57 ? (uintptr_t)addr_P5Tmap : (uintptr_t)addr_P4Tmap); } -void -dtrace_xcall(processorid_t cpu, dtrace_xcall_t func, void *arg) -{ - cpuset_t cpus; - - if (cpu == DTRACE_CPUALL) - cpus = all_cpus; - else - CPU_SETOF(cpu, &cpus); - - smp_rendezvous_cpus(cpus, smp_no_rendezvous_barrier, func, - smp_no_rendezvous_barrier, arg); -} - -static void -dtrace_sync_func(void) -{ -} - -void -dtrace_sync(void) -{ - dtrace_xcall(DTRACE_CPUALL, (dtrace_xcall_t)dtrace_sync_func, NULL); -} - #ifdef notyet void dtrace_safe_synchronous_signal(void) diff --git a/sys/cddl/dev/dtrace/arm/dtrace_subr.c b/sys/cddl/dev/dtrace/arm/dtrace_subr.c index bb42044aa477..10e9281709b6 100644 --- a/sys/cddl/dev/dtrace/arm/dtrace_subr.c +++ b/sys/cddl/dev/dtrace/arm/dtrace_subr.c @@ -138,31 +138,6 @@ dtrace_toxic_ranges(void (*func)(uintptr_t base, uintptr_t limit)) */ } -void -dtrace_xcall(processorid_t cpu, dtrace_xcall_t func, void *arg) -{ - cpuset_t cpus; - - if (cpu == DTRACE_CPUALL) - cpus = all_cpus; - else - CPU_SETOF(cpu, &cpus); - - smp_rendezvous_cpus(cpus, smp_no_rendezvous_barrier, func, - smp_no_rendezvous_barrier, arg); -} - -static void -dtrace_sync_func(void) -{ -} - -void -dtrace_sync(void) -{ - dtrace_xcall(DTRACE_CPUALL, (dtrace_xcall_t)dtrace_sync_func, NULL); -} - /* * DTrace needs a high resolution time function which can * be called from a probe context and guaranteed not to have diff --git a/sys/cddl/dev/dtrace/i386/dtrace_subr.c b/sys/cddl/dev/dtrace/i386/dtrace_subr.c index 026581f5a899..ebe2194a4b2f 100644 --- a/sys/cddl/dev/dtrace/i386/dtrace_subr.c +++ b/sys/cddl/dev/dtrace/i386/dtrace_subr.c @@ -139,31 +139,6 @@ dtrace_toxic_ranges(void (*func)(uintptr_t base, uintptr_t limit)) (*func)(0, kernelbase); } -void -dtrace_xcall(processorid_t cpu, dtrace_xcall_t func, void *arg) -{ - cpuset_t cpus; - - if (cpu == DTRACE_CPUALL) - cpus = all_cpus; - else - CPU_SETOF(cpu, &cpus); - - smp_rendezvous_cpus(cpus, smp_no_rendezvous_barrier, func, - smp_no_rendezvous_barrier, arg); -} - -static void -dtrace_sync_func(void) -{ -} - -void -dtrace_sync(void) -{ - dtrace_xcall(DTRACE_CPUALL, (dtrace_xcall_t)dtrace_sync_func, NULL); -} - #ifdef notyet void dtrace_safe_synchronous_signal(void) diff --git a/sys/cddl/dev/dtrace/powerpc/dtrace_subr.c b/sys/cddl/dev/dtrace/powerpc/dtrace_subr.c index 5dd083310e6f..ee8be8da642f 100644 --- a/sys/cddl/dev/dtrace/powerpc/dtrace_subr.c +++ b/sys/cddl/dev/dtrace/powerpc/dtrace_subr.c @@ -123,31 +123,6 @@ dtrace_toxic_ranges(void (*func)(uintptr_t base, uintptr_t limit)) */ } -void -dtrace_xcall(processorid_t cpu, dtrace_xcall_t func, void *arg) -{ - cpuset_t cpus; - - if (cpu == DTRACE_CPUALL) - cpus = all_cpus; - else - CPU_SETOF(cpu, &cpus); - - smp_rendezvous_cpus(cpus, smp_no_rendezvous_barrier, func, - smp_no_rendezvous_barrier, arg); -} - -static void -dtrace_sync_func(void) -{ -} - -void -dtrace_sync(void) -{ - dtrace_xcall(DTRACE_CPUALL, (dtrace_xcall_t)dtrace_sync_func, NULL); -} - static int64_t tgt_cpu_tsc; static int64_t hst_cpu_tsc; static int64_t timebase_skew[MAXCPU]; diff --git a/sys/cddl/dev/dtrace/riscv/dtrace_subr.c b/sys/cddl/dev/dtrace/riscv/dtrace_subr.c index 3a6aacd86fcd..ed2c0bdba7e2 100644 --- a/sys/cddl/dev/dtrace/riscv/dtrace_subr.c +++ b/sys/cddl/dev/dtrace/riscv/dtrace_subr.c @@ -127,33 +127,6 @@ dtrace_toxic_ranges(void (*func)(uintptr_t base, uintptr_t limit)) (*func)(0, (uintptr_t)VM_MIN_KERNEL_ADDRESS); } -void -dtrace_xcall(processorid_t cpu, dtrace_xcall_t func, void *arg) -{ - cpuset_t cpus; - - if (cpu == DTRACE_CPUALL) - cpus = all_cpus; - else - CPU_SETOF(cpu, &cpus); - - smp_rendezvous_cpus(cpus, smp_no_rendezvous_barrier, func, - smp_no_rendezvous_barrier, arg); -} - -static void -dtrace_sync_func(void) -{ - -} - -void -dtrace_sync(void) -{ - - dtrace_xcall(DTRACE_CPUALL, (dtrace_xcall_t)dtrace_sync_func, NULL); -} - /* * DTrace needs a high resolution time function which can * be called from a probe context and guaranteed not to have From nobody Thu Sep 18 22:10:54 2025 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 4cSVFp2PMtz686vc; Thu, 18 Sep 2025 22:10:54 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSVFp1GZbz3lY8; Thu, 18 Sep 2025 22:10:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758233454; 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=RbmcHBtYh4tT3ENf01XPNkiI8k9+9TUBhV6eG8Liex0=; b=KC6pqKBS4cozynYL35JSWnVBSqvfAER85uVIlNlfCcI+hE3Mh70gwpm2mfMlRlpW2UHnf0 OlZDnsXQ+6oLqaes8GBEK2KY/IumWmMTbNhTT9dbtJ365+k+wbrEIGw2+vFKBRM84sme4z QmxLFfBD/j8Ni+ztJBh+nqFSm5vUAL28N/8VLiKrD6/tRLCvukMG/Os/3+v19nfJ8gLoCg Xp77Givzg2cqXmwy6/QmEaUBkID+Rf5nitra4J2BNt2z/JGPvSW4yuDw8La7waX5elmiT5 pylDf6EIrGIsDE0eppI68w80XKzKC9Gt5AZcdlNS3tqBgKFv4h+rBwp6JQVE5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758233454; 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=RbmcHBtYh4tT3ENf01XPNkiI8k9+9TUBhV6eG8Liex0=; b=e8XGNhmKgi4ud5Jnxf80yCCrF+g/nlmt5MvAoUGU324qjmbxz712tgWB4abDaEA7hZfjHF 7bs6wm0eltk8XdDc6rlkhTc1YZihNC+Bg3f/1B/m4Xczv478JyDeSxbiq80fimrGXpyNky 2PiNGjPfi2xetO0HzHu1k5GyThqjRCz+skreFykknwg679aG+ithm+8qSQ57oVfZ1BSAMw LlnAvZx2BeVe1KFJfZJYIUvnWKIJD7taNXIvKfLARsr/eefLqCfya1oxoWVfkXEmsZZdvG OkKrR45Z2Ie3/5kHyJC9sA5lcBmhlR8tYan8kUoScpxI1Rm5pxL4/4MeFyYcbQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758233454; a=rsa-sha256; cv=none; b=qdYGM+86I1WQZS8D1EFVtT95HqulRbc583Di8usX11dy50gDSBaVrZ4fK/kEEst/XU9RCk x+Xa7hxG/6KVy/c+ZQfjPahMJdTZbibtqCZITwI7/gmh+PaI6J9c8vaMrUQITQUnDZuGq9 Q1ieX7UFFQDp/ts4+0EEQV/VtTB2nO7JTitBVFUedQOmNJm7LBAED/IqMGj8mhz1VEfa0F Asd2PE6Fyi/65YaBqGyZmneN5kEB3CEdpzZmVepaCTB8OmFS+6g3G/1i5vCqT8w40nZDF3 g5EkVga2RbkZmC2ZfMp5/3Fkp7tzAI7H0Tm+sDh0MgHB9zIzpHVRL5HijyYy7A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSVFp0q66zTtN; Thu, 18 Sep 2025 22:10:54 +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 58IMAswb021014; Thu, 18 Sep 2025 22:10:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IMAsaN021011; Thu, 18 Sep 2025 22:10:54 GMT (envelope-from git) Date: Thu, 18 Sep 2025 22:10:54 GMT Message-Id: <202509182210.58IMAsaN021011@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: 4784ca874410 - main - pw: Remove duplicate lines from the pw useradd usage message 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4784ca87441093328cec4e9b133608e172343f64 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=4784ca87441093328cec4e9b133608e172343f64 commit 4784ca87441093328cec4e9b133608e172343f64 Author: Mark Johnston AuthorDate: 2025-09-18 15:13:26 +0000 Commit: Mark Johnston CommitDate: 2025-09-18 22:09:49 +0000 pw: Remove duplicate lines from the pw useradd usage message No functional change intended. MFC after: 1 week Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. --- usr.sbin/pw/pw.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/usr.sbin/pw/pw.c b/usr.sbin/pw/pw.c index a4c95258f3bb..fc778b16c7e5 100644 --- a/usr.sbin/pw/pw.c +++ b/usr.sbin/pw/pw.c @@ -257,8 +257,6 @@ cmdhelp(int mode, int which) "\t-Y update NIS maps\n" "\t-N no update\n" " Setting defaults:\n" - "\t-V etcdir alternate /etc location\n" - "\t-R rootdir alternate root directory\n" "\t-D set user defaults\n" "\t-b dir default home root dir\n" "\t-e period default expiry period\n" From nobody Thu Sep 18 22:42:46 2025 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 4cSVyZ4DlTz688bs; Thu, 18 Sep 2025 22:42:46 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSVyZ3Y6Vz3pqX; Thu, 18 Sep 2025 22:42:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235366; 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=+tBrvCw2rV5mbBB6g0ctE1fQlsFnFWyeadlIjiz7eR8=; b=juOcdXgt6lgpRC5QuSdbw4MRYBuNBV5y8vVh41f4CWkNRBJoeu5Gmt3TwDs7KNrMLj4Yxb NNM59NZrPwgwtzERBoYJEEy17/qh30Ec+BhmRkPPHtkF80+fZnM0wltr763pelOUxybw3z Lv6LrAdMKLF0mNBuQcXOfDDGeXY9KyiXAaLJapTb7yuYpzep/WpQGLLP3XTcMiNE6K/MuF HIzNMdvMedRZnghjWjuyD62XzNmZoVcS2OghwshmzEjvAVi3YUgn7LhQnIo7FB5F/sduq1 Sn7IoYcounXFF3Az4Qjl5qOwVUUvX57kzeveQDqhUeexdrjPJIxa8UA0OcP5fw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235366; 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=+tBrvCw2rV5mbBB6g0ctE1fQlsFnFWyeadlIjiz7eR8=; b=okl21iy+w4h7ZkvefgjZEP09o2MXKPyBcUjIldHDHWMFHxFbRgHeQWpRQ6YvCzGNR4jnen 2j34ozE9Z7WQFFKZMh29a2NwuG6IYeGZxiqcyc2TodYua9R2IVGg2UDE7gLz8PIri+yW/8 Jh/8nJ14LUGQXLO13Zf/Ye1j2yGmjMmRHAthObTdBYu3iASSjmxSW2hF8/dA6ED6TX0pMN HyxN9CYFE7b+FJXmcCYr/lISERqfrlQsixFXSvUXb2rUQLAmjW39D2Jd4i76hJn+4zntnW q9qMYrg53wIsI88l2cycdBuua0/ru7weKiS4RY3Xqnm7EBAw4m159YGhIa7IXA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758235366; a=rsa-sha256; cv=none; b=k1fF0XV7Zqq9MCaRcuWjLCNsnUfrBCwgDhlI+EBfWw3VW0jaNr6Gb7viDFAkEjXVWQp0/w BqP0qIp8C8DY9M1iu+luU5bggJP2t59lm7Ogj1MtuSP1TuPOBmj/BW1JRcOIxzZGclb1B0 qa9qtu+B4rd17msquJCrdd5T+Xv9OgJ2resTbgLCCoN+swJGwbe0ZtAlsowtpaOfLU5MgO M+cqpod78nJo6/2FON9eAkXhbJ8SluGSxk6DnCfomE2ZYLUYFeg9x7x3RUAfQ90iqLzeoj JV9RH+p0uKYyPy3+dvoPOHae3HJnCXTKqbtLBjJjpkMAuH8XItqv/vBygY9vPA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSVyZ2yYkzWqn; Thu, 18 Sep 2025 22:42:46 +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 58IMgkYh081713; Thu, 18 Sep 2025 22:42:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IMgkNv081710; Thu, 18 Sep 2025 22:42:46 GMT (envelope-from git) Date: Thu, 18 Sep 2025 22:42:46 GMT Message-Id: <202509182242.58IMgkNv081710@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: daa63c9417a2 - main - pw: Print warnings when metadata updates fail 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: daa63c9417a28ad08881ff03df828fd8180dad12 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=daa63c9417a28ad08881ff03df828fd8180dad12 commit daa63c9417a28ad08881ff03df828fd8180dad12 Author: Mark Johnston AuthorDate: 2025-09-18 22:38:33 +0000 Commit: Mark Johnston CommitDate: 2025-09-18 22:38:33 +0000 pw: Print warnings when metadata updates fail We do this in most places already, but not consistently. MFC after: 1 week Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. --- usr.sbin/pw/cpdir.c | 6 ++++-- usr.sbin/pw/pw_user.c | 3 ++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/usr.sbin/pw/cpdir.c b/usr.sbin/pw/cpdir.c index 3dee8f7c43ac..63068cab000c 100644 --- a/usr.sbin/pw/cpdir.c +++ b/usr.sbin/pw/cpdir.c @@ -127,8 +127,10 @@ copymkdir(int rootfd, char const * dir, int skelfd, mode_t mode, uid_t uid, /* * Propagate special filesystem flags */ - fchown(destfd, uid, gid); - fchflags(destfd, st.st_flags); + if (fchown(destfd, uid, gid) != 0) + warn("chown(%s)", p); + if (fchflags(destfd, st.st_flags) != 0) + warn("chflags(%s)", p); close(destfd); } closedir(d); diff --git a/usr.sbin/pw/pw_user.c b/usr.sbin/pw/pw_user.c index 8a9a4342f5ef..9f5cfb0f4473 100644 --- a/usr.sbin/pw/pw_user.c +++ b/usr.sbin/pw/pw_user.c @@ -123,7 +123,8 @@ mkdir_home_parents(int dfd, const char *dir) if (fstatat(dfd, dirs, &st, 0) == -1) { if (mkdirat(dfd, dirs, _DEF_DIRMODE) == -1) err(EX_OSFILE, "'%s' (home parent) is not a directory", dirs); - fchownat(dfd, dirs, 0, 0, 0); + if (fchownat(dfd, dirs, 0, 0, 0) != 0) + warn("chown(%s)", dirs); } free(dirs); From nobody Thu Sep 18 22:42:47 2025 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 4cSVyb5J55z688fH; Thu, 18 Sep 2025 22:42:47 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSVyb4Qr8z3q99; Thu, 18 Sep 2025 22:42:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235367; 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=btLp5BLsZAcqTuNzN/ZY5k8wRDacqiQ2fMcNJoCb1GM=; b=dfUnjK94N+BuWV0Rn0I2AoM6J7ESkWPG7t32o2sdDgSWHHqSxP/rIeITIn12p4mhzEOLe9 zK0X6r4msRYiON/1Dr7o8jLXjP74m+thMCC2j2mhYXOwO/mmYh8ayHGfBehzk4PiQDmWK+ AgRWhxPiFimEWhoFwu5jcf10AG/KBAkPcmbCTHGWGgixpcfB5ebR400OnYFad5igzH/HqN Hd/lvS6LNttRA/WAIUkQqJIV7WeAqsvljndcxKwxggBTeUS9zA+nMWvz1pL75fnmkU1J5+ XdGP6fNNDt2KkbHG8FaTUeWBVdBhcz7frdq32hHe1VCPKAtiSqR2X+XUxZRznw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235367; 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=btLp5BLsZAcqTuNzN/ZY5k8wRDacqiQ2fMcNJoCb1GM=; b=K0tlyU/TX9IJV2zNxkhjonKo4jXXEM3raBqlWV0Wvp+XZ8tGx2UZHKiNgjCaraIcBVb7ZK KT/YWaOr43OrKKr4lNkk2ZXe0qmUPQZCjWEHJqGHKd9KzSh8swP3eEeTn5LMLHDB6iHc/j Wl0AMQOileqeEcFzl6y+ebcGEUKb0vWbmOS5pJQqIYoyxHCa2NndknV4N/JT0cNE9xMxBX JctsXRsUWefwPnGMccWe8PXUhibvvN0TwwffmHMDOZaGj8aFWAspuE7PzkaEJL+gBL/IAl vAQWUXuj+VrwA4nRFUbipPS9p15J6L22TBt6B5gfFqAvrSXXGqgi5lowIrXxKg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758235367; a=rsa-sha256; cv=none; b=dxdVxQjuwdEpLHzrx3Anl8KRFXvzjk+dpXoOvyIWqAuJq9jw8JKB8SN/BkLevrptNAltY9 4tqcDquEGNCYIwgEvz1zoLmcUv/Mmq84g4rHwe8cIEDvg5s1OyPHbTP6AIOs/f7wP58gri eKzllr3YKgH2AeXHwN7Wqf+I+HVTry89xvwi+krX0Uutdolb+g1mr7UXKIqHDTeCz9+wot YQPu5ofsxp4a+00+vbD6dRBFs7+sFZKERuU2dC4I6/OREuoyzntyzuYZGw2kpfONbAuSAD CpjGfrRrLcIRbBqY5JHO6LlQN0n0CtXjfW79WohoDqvHHMvXKwMm0AvMP0f1bg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSVyb3zLJzWp4; Thu, 18 Sep 2025 22:42:47 +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 58IMglXs081746; Thu, 18 Sep 2025 22:42:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IMglMh081743; Thu, 18 Sep 2025 22:42:47 GMT (envelope-from git) Date: Thu, 18 Sep 2025 22:42:47 GMT Message-Id: <202509182242.58IMglMh081743@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: bc69d5dffa21 - main - pw: Clean up a couple of errx() calls 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: bc69d5dffa21cdf228e481b5502fd0f053d65e6d Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=bc69d5dffa21cdf228e481b5502fd0f053d65e6d commit bc69d5dffa21cdf228e481b5502fd0f053d65e6d Author: Mark Johnston AuthorDate: 2025-09-18 22:38:45 +0000 Commit: Mark Johnston CommitDate: 2025-09-18 22:38:45 +0000 pw: Clean up a couple of errx() calls - Remove a stray backslash. - Make an error message fit on one line. No functional change intended. MFC after: 1 week Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. --- usr.sbin/pw/pw.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/usr.sbin/pw/pw.c b/usr.sbin/pw/pw.c index fc778b16c7e5..18f1a17ba942 100644 --- a/usr.sbin/pw/pw.c +++ b/usr.sbin/pw/pw.c @@ -143,12 +143,13 @@ main(int argc, char *argv[]) optarg = &argv[1][2]; if (*optarg == '\0') { if (stat(argv[2], &st) != 0) - errx(EX_OSFILE, \ + errx(EX_OSFILE, "no such directory `%s'", argv[2]); if (!S_ISDIR(st.st_mode)) - errx(EX_OSFILE, "`%s' not a " - "directory", argv[2]); + errx(EX_OSFILE, + "`%s' not a directory", + argv[2]); optarg = argv[2]; ++argv; --argc; From nobody Thu Sep 18 22:42:48 2025 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 4cSVyd2vhQz688Pg; Thu, 18 Sep 2025 22:42:49 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSVyc4wFJz3pkr; Thu, 18 Sep 2025 22:42:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235368; 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=4gNO/ALPxcQVNDgBAs0G5OCCtQlXtC6QpQNRwY1slT8=; b=St0Ag53/XzMSr9r1qFPQHsAZR0qvqr7o047PFweXszyX1WYqRFgMVWiAO7aw/eRIwsSXMY 4Z1Nzs7mBNJdLOmuCHYYJdIKuiZdNf8kRYxfaamAhLOe9jlT2xU/FZy/zbARKr5wkylcgh +qR9MkyEimMIcxYdLM0c9mU+HAiZAHIm3/9JxruvPSABgOeHt5PMvjl3YKd4Zi0glKDFWz SQGAhwOfnwOAbiH6C34NPiWHfSSsABWtML25/FSU9IHnDK6RUMNl39NBxslJ5PrwtiYPGk v1KbD2NiuruRDmK9mpE/k/HJ71Nqqw3HVVgV9eaEjlcv16SAJEfNJnkyeQsJBg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235368; 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=4gNO/ALPxcQVNDgBAs0G5OCCtQlXtC6QpQNRwY1slT8=; b=fSSF5dXi7CQknOr0VfHmHsp5Vc85f53XFUtcJBhL5T4DgmxKGmyodsxGMs7p3piOSBaTVS Ey0p0741I1pXRmZN6zoE6ZMK0Pe3lo5NK3EhhFY3p2kBTBjjolSFPaqad07OKLpaiZ2Chj t/oAXpQchk2tgLx1Xbn1y8Koj5pQhtnIELOx1n+ZfWyVwwpmRF5x8z5nI5xpRf4cM/wvG1 jAniBv/HOp2otApi6+MIhfJea/fYFcjBGqBzBRZTJ+WFnjb9nn73Hgg5qNz2nJyvix6mVm bNb3qPy5YEYhY0h0IhIlLVJbOwvppnNGgI23i73Gb+57QFjWDKIBBMACXYCjug== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758235368; a=rsa-sha256; cv=none; b=PmknSTeN97TgtdJ5q9wCMvTqodqvvNgnhR5q0jYhyY1zEED85wz78SJKP8x4pREcFJUSmB 3bYjqqtq+pUItyPKKPfxOpPAbjLYPGGRRqkIOjbVEiXkxC3A8T8lCzjczXVUWiRsTqlqf5 WbDKMYrouiVlVFIfDiVnKAB2XkOWhFATQKRKbcQ6tA8FWS2VJ8FrVcAOzpypkCwkHZ95bd SkjnRJx9fbiFI1oE/yHI4TzzS6Voo5YWVsDyY6dVQw/Z+1AblLWBHQjf/FZM2NDxQfO4fM 8oY3rcGfLK6XxWbry2SHoy5G+Pamyb89FEVhFkJ3c54gfiqA/udr+trKaDQDqg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSVyc4Qc4zXK8; Thu, 18 Sep 2025 22:42:48 +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 58IMgm6B081779; Thu, 18 Sep 2025 22:42:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IMgmMT081776; Thu, 18 Sep 2025 22:42:48 GMT (envelope-from git) Date: Thu, 18 Sep 2025 22:42:48 GMT Message-Id: <202509182242.58IMgmMT081776@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: 42dc71a544a4 - main - pw: Style 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 42dc71a544a4d78d0068f70b6d4089a8c9e07cb1 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=42dc71a544a4d78d0068f70b6d4089a8c9e07cb1 commit 42dc71a544a4d78d0068f70b6d4089a8c9e07cb1 Author: Mark Johnston AuthorDate: 2025-09-18 22:38:58 +0000 Commit: Mark Johnston CommitDate: 2025-09-18 22:38:58 +0000 pw: Style No functional change intended. MFC after: 1 week Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. --- usr.sbin/pw/pw.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/usr.sbin/pw/pw.c b/usr.sbin/pw/pw.c index 18f1a17ba942..6f59e392bdd0 100644 --- a/usr.sbin/pw/pw.c +++ b/usr.sbin/pw/pw.c @@ -166,8 +166,7 @@ main(int argc, char *argv[]) conf.altroot = true; } else break; - } - else if (mode == -1 && (tmp = getindex(Modes, argv[1])) != -1) + } else if (mode == -1 && (tmp = getindex(Modes, argv[1])) != -1) mode = tmp; else if (which == -1 && (tmp = getindex(Which, argv[1])) != -1) which = tmp; @@ -179,7 +178,7 @@ main(int argc, char *argv[]) } else if (strcmp(argv[1], "help") == 0 && argv[2] == NULL) cmdhelp(mode, which); else if (which != -1 && mode != -1) - arg1 = argv[1]; + arg1 = argv[1]; else errx(EX_USAGE, "unknown keyword `%s'", argv[1]); ++argv; From nobody Thu Sep 18 22:42:49 2025 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 4cSVyf1w57z688Ph; Thu, 18 Sep 2025 22:42:50 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSVyd62VZz3q9b; Thu, 18 Sep 2025 22:42:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235369; 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=Xarth6ENTuwjiznDgQ0TffMCZY6SGjUIGJ/sK2jmcdk=; b=JiOyghU+l43jcswl8wVj3iaOvSZaoucK4S7ASZu+IUmWXnH6DhodXoUTt9fzHf9MhXGG6p KD1fP/ue6DoYH3VhEujIHGxRhoHnpIArThiPbos7F8ST61s1gvmFsHfkBY3Mg+rajCiI/3 lsWUuU6/qTNwe80DvLvpCTvpi/kfBysV+m2t50Nq7q4zIRKVI18SjZSS4qkqbPmcU6p/M+ EmOuWtpFYOhPWeaP6qfT4UrySGIBoDkXbP7eGuCArN7WkZzohzln2bSPbC32rRVCy8hJqo MlhCjvvRTZijNuifn4RwGMncQRGvJr61iIJW/8uXMLc5s/EOSpfVjgeipf+0zg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235369; 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=Xarth6ENTuwjiznDgQ0TffMCZY6SGjUIGJ/sK2jmcdk=; b=DqDHpoWHCsQ8s8UJ8KNBDwf4TM3F4kR4LP7RoWn4uABoRGjmbzQpx8E0kv63acQ/YZ4yPv QhFWgUI5SmtyzJkinyn8Uka9s24tZnLiztSrXhjlP0XBfq8C6dSFwZh/YxfkGGMI7mWIWF WmIm1gYJjVECH9Pf0i8qa7nJhZJRmTZ3XUmymgU2/tOQ0RBAo4KJ0Jr7iUYHvVwt0UN/Pj pnXJgX37SCM3R4G7qE38mxmqYpuGlhHjJX4r64OEjnQnDTRrHGiRbFlLOQEhuGqYDwslPE MLUDBRJbmAD5OMwlXvHCtYx/ckrnvcmi8HjwxvBUNpz2PyKc3b09Euhejw0Oog== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758235369; a=rsa-sha256; cv=none; b=lpKe3r9Y0NzLlHMbTdu9AWX/svCWesMW+M7l51dDXpSX950pBfbj4TqYcBafGtqsLFHPMa SX39s6YIz2c5ANIDmXdh99cPbRoSNedkRqPouotW66Chi5UMz/8ZAIcpbOp74q+1W3OzXX IeHU0FbKxLoDprB8HvCQI0c8GnwBJ7FeYEz3LvUfa4JdP2cq0ZKmZQD6YkfG5FxQabqhcW qAfxRCqHJaCn+sXGatgsWgjWJ7QhgkJXJzsdFb/Irsg0BJ9NXaI+jN1fHzT8yDCZ04d9Z0 RcD8GLGKaQrH/fTA5kAQKAVaqjACl2GBnm7+xULhME0MBVt7Hsa6y2j7eeZGjA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSVyd5Q0zzVh9; Thu, 18 Sep 2025 22:42:49 +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 58IMgnYl081812; Thu, 18 Sep 2025 22:42:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IMgnRY081809; Thu, 18 Sep 2025 22:42:49 GMT (envelope-from git) Date: Thu, 18 Sep 2025 22:42:49 GMT Message-Id: <202509182242.58IMgnRY081809@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: 41b2a80353e0 - main - pw: Add a missing chown() when creating dirs in mkdir_home_parents() 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 41b2a80353e0dd04939cc260d5763854a264c158 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=41b2a80353e0dd04939cc260d5763854a264c158 commit 41b2a80353e0dd04939cc260d5763854a264c158 Author: Mark Johnston AuthorDate: 2025-09-18 22:39:11 +0000 Commit: Mark Johnston CommitDate: 2025-09-18 22:39:11 +0000 pw: Add a missing chown() when creating dirs in mkdir_home_parents() mkdir_home_parents() effectively performs a mkdir -p of the root home directory. It chowns the home directory to 0, 0, but doesn't do so for the intermediate directories. Add an explicit chown() call for those too. Fix a long line while here. Reviewed by: bapt MFC after: 1 week Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D52587 --- usr.sbin/pw/pw_user.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/usr.sbin/pw/pw_user.c b/usr.sbin/pw/pw_user.c index 9f5cfb0f4473..007f750c7d1a 100644 --- a/usr.sbin/pw/pw_user.c +++ b/usr.sbin/pw/pw_user.c @@ -115,7 +115,11 @@ mkdir_home_parents(int dfd, const char *dir) *tmp = '\0'; if (fstatat(dfd, dirs, &st, 0) == -1) { if (mkdirat(dfd, dirs, _DEF_DIRMODE) == -1) - err(EX_OSFILE, "'%s' (home parent) is not a directory", dirs); + err(EX_OSFILE, + "'%s' (home parent) is not a directory", + dirs); + if (fchownat(dfd, dirs, 0, 0, 0) != 0) + warn("chown(%s)", dirs); } *tmp = '/'; } From nobody Thu Sep 18 22:42:50 2025 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 4cSVyg1LkSz6893g; Thu, 18 Sep 2025 22:42:51 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSVyf6s27z3qC4; Thu, 18 Sep 2025 22:42:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235371; 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=ZeWGZfJMluhc5Vm98w7F91z7UQDhvEhvgbA0cmcYpZA=; b=EmjLy7YAzhSmx74/Yfym6YjzvBEuTuvn7AdPFERuQW4wML4X6GKHvXjgvYeUaEl0DlR5wQ 0wksXT8GSSa0KrEKaVWnz1Rvwzp7gl8Rgo4wlXYZ4IMOKk+r5AR4zy2fv6JgOn7h0HexST eIceN6r/p+oIr7whYeWysgq0YNbQsVQzmN30v6wmPSGL31fx8UWLSnHCQNwUmw31A5R7PA R5Kdm1UPugATtrIRAfWWm2ehYF1EKwr6jocssUHn21KPMnHe03UZX9nGMBEnkc6iZG1As6 ZJUrYKOUtqgatefp89UVlb/BIQ74pjZ/PhIQGQt+PKV3S0vwpoGX3EZysnDbqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235371; 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=ZeWGZfJMluhc5Vm98w7F91z7UQDhvEhvgbA0cmcYpZA=; b=pVchVRTqkA6vGTajI+ypfUGoJ8sFLK7mcKEpU0QqiVTEU+v9fYoT6/7yCudZbIK5Mgd3Oz gD1ctQrx5o/II5KcH0aPFVhDNq6lu4FTl8hE8lnT5PNil1W/VU2H4sIXCXt4OcankcIbYI BqJtdEbMEhNVEoBdErcN2Z/xi9yQfL2/QVMkwrN57n2p7y8ZEeiHwJk7aC9sOhAWy04bG2 K6GktyFC+aKVBbmeqrXKPyqkzqoPv/5wHO69S1ssY9EEpPgmV5BK5fDNxIx5vdYgdB2nv+ qzVOdPwVzVMbcfe9AxDHesP7f2v6yllycZ2XPpIrPedAR/mQ4IWq+kjrxN7LLg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758235371; a=rsa-sha256; cv=none; b=quwKr4AY8ZkEWEhkeBNfio6cxv7ctn94plyDvJVuRtIo+VqZl9KwA9DGWgcn9vF8MPi8PM 8qBbTHsPF7pPEexnVKU+hePnS0O6As421rN9zhwuD31hJ+D1pC7MW1vyb/MAIGb4UV1wPf +zK3d0EN0KolBpj8D75xkrYuM5IOCcnsZIlFqzzyMnlmTQ7UKw4lBrhQeeVNvAt9VKrSAj R8rryNA4jjqpN9urXQnViwOd+Eu7NNIBan0Iuwf4LryxZ6Uu/Ve/GsQhRRN2Xh+7/ECknA u3f843Xkz0dpiNtpw/upkcquV2oamvvc63N3Kxd1bzzfxIG04PXaOIcDbUP4Fw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSVyf6M4KzWbm; Thu, 18 Sep 2025 22:42:50 +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 58IMgo0q081852; Thu, 18 Sep 2025 22:42:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IMgoiA081849; Thu, 18 Sep 2025 22:42:50 GMT (envelope-from git) Date: Thu, 18 Sep 2025 22:42:50 GMT Message-Id: <202509182242.58IMgoiA081849@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: a03d150a3d44 - main - pw: Use copy_file_range() when copying skeleton files 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a03d150a3d44c49344ebd0862defd1a5ad1f524e Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=a03d150a3d44c49344ebd0862defd1a5ad1f524e commit a03d150a3d44c49344ebd0862defd1a5ad1f524e Author: Mark Johnston AuthorDate: 2025-09-18 22:39:39 +0000 Commit: Mark Johnston CommitDate: 2025-09-18 22:39:39 +0000 pw: Use copy_file_range() when copying skeleton files As a bonus, check for I/O errors and print them to standard error. Reviewed by: bapt, emaste MFC after: 1 week Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D52588 --- usr.sbin/pw/cpdir.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/usr.sbin/pw/cpdir.c b/usr.sbin/pw/cpdir.c index 63068cab000c..3839a039495a 100644 --- a/usr.sbin/pw/cpdir.c +++ b/usr.sbin/pw/cpdir.c @@ -36,10 +36,10 @@ #include "pw.h" void -copymkdir(int rootfd, char const * dir, int skelfd, mode_t mode, uid_t uid, +copymkdir(int rootfd, char const *dir, int skelfd, mode_t mode, uid_t uid, gid_t gid, int flags) { - char *p, lnk[MAXPATHLEN], copybuf[4096]; + char *p, lnk[MAXPATHLEN]; int len, homefd, srcfd, destfd; ssize_t sz; struct stat st; @@ -120,8 +120,12 @@ copymkdir(int rootfd, char const * dir, int skelfd, mode_t mode, uid_t uid, continue; } - while ((sz = read(srcfd, copybuf, sizeof(copybuf))) > 0) - write(destfd, copybuf, sz); + do { + sz = copy_file_range(srcfd, NULL, destfd, NULL, + SSIZE_MAX, 0); + } while (sz > 0); + if (sz < 0) + warn("copy_file_range"); close(srcfd); /* From nobody Thu Sep 18 22:42:51 2025 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 4cSVyh4gk4z688fM; Thu, 18 Sep 2025 22:42: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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSVyh1cTkz3qJ7; Thu, 18 Sep 2025 22:42:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235372; 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=Uzqni+XDKxGynOI11Cdtyx2y5SgZmhyWOfjsK4T5F2I=; b=RxoTVlQbYt9938/V3DABmbassufylAuJyxxN4jAbE4ETN0MpB6UVh7SaPfTD9/aUW/bRmt a+C5HA1QvR4xYB08gepaNFwwnEOibELmUKEtiBhMm3jqHWhqqCN2+RDiqZ0IQOdDmkLPX7 8Qc5O51OWIQYoVyMZfTRth4ZSo1/1R/0FO7pTX6UTcuDy/2AAV0xUG9xHcXxD5/VzvPllN bmtJqCr6XNzdE9rI6Qlbd2n+TIlvgWW7h6PvltWQhXsPiP2Wl2HSCOxorQ870zYA1hjEOG jRQbJP5BnpNn9XtLtN3gA73c7ToDzJuw5JyIfRr2CZzlmP3zkcdZ/2MybZr6Cg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758235372; 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=Uzqni+XDKxGynOI11Cdtyx2y5SgZmhyWOfjsK4T5F2I=; b=lfKcM8bDebXe6ZvrUTvRBtMCkhh7N0y7/LOMp6m0IxxOek7cyzeFeDYxNM4yggD5Zg0AAM jgqY/WIWEYoaEj16rgZwyHmXI1bVFbcXi6z7FXCYpBNjwgnh8dWJugUMc/CMZ5dpyYyAU8 pN2qKV+bNewf4aHkmAq1oS7FnMBCHDlLJmJ79mwywZHsR3CBfg+DSHaIASpe1uY4ALy1H5 KAvK985xH7Bb11ZcUIeYFfeThq21dNI4tO1ZRCAq2vTsQBMx/tEXbZVrp+KpjEKKpDP2J6 J7GMGQWCMXZN9XwvwsL906fZwlyQCSVm5evaq8RV0ymIUE6W8JZSVBXadPhyFw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758235372; a=rsa-sha256; cv=none; b=wzfTp0kNRJuNC2zCHmRRVB4WKt2+mQ/tE940mnQNQT2+sTDxjdEHKwGtCdbnPxzZhx46OO J3806NMTrsCLEHP6IQ49W/JFjUeNGI7SUDuDEkPt79wgdakbzTgzEuMdRNedvcUjXZngaZ y/vxfTxefwJbrVGNOxY+5Jbocsfaqha3M7GqSpnB0lkC/k8bVBzNbFcQSbEUpMUEgMxQAJ yQDtXuRKLKxOJidtA2XD4DWpePbHud0go5KXBExbavggJdAFkdbPHkL/7OEitNvtj68tsL eyMZv0aGKN1BaesCSvpnlW3/3rHAfMHF2uqxdF81wAloyN0ZA2QtESYKEq0kVQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSVyh1D5fzVhB; Thu, 18 Sep 2025 22:42:52 +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 58IMgpjX081887; Thu, 18 Sep 2025 22:42:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58IMgppj081884; Thu, 18 Sep 2025 22:42:51 GMT (envelope-from git) Date: Thu, 18 Sep 2025 22:42:51 GMT Message-Id: <202509182242.58IMgppj081884@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: 182ed3c0755f - main - pw: Add a metalog output mode 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 182ed3c0755f1bf161d8be02016b5f6cf9b57556 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=182ed3c0755f1bf161d8be02016b5f6cf9b57556 commit 182ed3c0755f1bf161d8be02016b5f6cf9b57556 Author: Mark Johnston AuthorDate: 2025-09-18 22:40:00 +0000 Commit: Mark Johnston CommitDate: 2025-09-18 22:42:16 +0000 pw: Add a metalog output mode When creating OS images as a non-root user, it may be useful to pre-create users in the staged tree. The useradd operation adds files to the new user's home directory, copied from the skeleton directory (/usr/share/skel), which makes it inconvient for use in this scenario since the added files are not recorded in the mtree metalog. To cover this gap, this change adds a new -M option to pw's useradd operation, causing pw to add mtree entries for newly added files. Extend an existing regression test to validate this mode. Reviewed by: bapt, emaste MFC after: 1 week Sponsored by: The FreeBSD Foundation Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D52590 --- usr.sbin/pw/cpdir.c | 43 +++++++++++++++++++++------------ usr.sbin/pw/pw.8 | 16 +++++++++++++ usr.sbin/pw/pw.c | 30 +++++++++++++++++++++-- usr.sbin/pw/pw.h | 5 ++++ usr.sbin/pw/pw_user.c | 9 ++++++- usr.sbin/pw/pw_utils.c | 46 ++++++++++++++++++++++++++++++++++++ usr.sbin/pw/pwupd.h | 1 + usr.sbin/pw/tests/pw_useradd_test.sh | 20 ++++++++++++---- 8 files changed, 148 insertions(+), 22 deletions(-) diff --git a/usr.sbin/pw/cpdir.c b/usr.sbin/pw/cpdir.c index 3839a039495a..979323d64342 100644 --- a/usr.sbin/pw/cpdir.c +++ b/usr.sbin/pw/cpdir.c @@ -40,49 +40,48 @@ copymkdir(int rootfd, char const *dir, int skelfd, mode_t mode, uid_t uid, gid_t gid, int flags) { char *p, lnk[MAXPATHLEN]; - int len, homefd, srcfd, destfd; + int len, srcfd, destfd; ssize_t sz; struct stat st; struct dirent *e; DIR *d; + mode_t pumask; if (*dir == '/') dir++; + pumask = umask(0); + umask(pumask); + if (mkdirat(rootfd, dir, mode) != 0) { - mode_t pumask; if (errno != EEXIST) { warn("mkdir(%s)", dir); return; } - pumask = umask(0); - umask(pumask); - if (fchmodat(rootfd, dir, mode & ~pumask, AT_SYMLINK_NOFOLLOW) == -1) warn("chmod(%s)", dir); } - if (fchownat(rootfd, dir, uid, gid, AT_SYMLINK_NOFOLLOW) == -1) warn("chown(%s)", dir); - if (flags > 0 && chflagsat(rootfd, dir, flags, AT_SYMLINK_NOFOLLOW) == -1) warn("chflags(%s)", dir); + metalog_emit(dir, (mode | S_IFDIR) & ~pumask, uid, gid, flags); if (skelfd == -1) return; - homefd = openat(rootfd, dir, O_DIRECTORY); if ((d = fdopendir(skelfd)) == NULL) { close(skelfd); - close(homefd); return; } while ((e = readdir(d)) != NULL) { + char path[MAXPATHLEN]; + if (strcmp(e->d_name, ".") == 0 || strcmp(e->d_name, "..") == 0) continue; @@ -92,19 +91,32 @@ copymkdir(int rootfd, char const *dir, int skelfd, mode_t mode, uid_t uid, if (strncmp(p, "dot.", 4) == 0) /* Conversion */ p += 3; + (void)snprintf(path, sizeof(path), "%s/%s", dir, p); if (S_ISDIR(st.st_mode)) { - copymkdir(homefd, p, openat(skelfd, e->d_name, O_DIRECTORY), - st.st_mode & _DEF_DIRMODE, uid, gid, st.st_flags); + int fd; + + fd = openat(skelfd, e->d_name, O_DIRECTORY); + if (fd == -1) { + warn("openat(%s)", e->d_name); + continue; + } + copymkdir(rootfd, path, fd, st.st_mode & _DEF_DIRMODE, + uid, gid, st.st_flags); continue; } if (S_ISLNK(st.st_mode) && - (len = readlinkat(skelfd, e->d_name, lnk, sizeof(lnk) -1)) + (len = readlinkat(skelfd, e->d_name, lnk, sizeof(lnk) - 1)) != -1) { lnk[len] = '\0'; - symlinkat(lnk, homefd, p); - fchownat(homefd, p, uid, gid, AT_SYMLINK_NOFOLLOW); + if (symlinkat(lnk, rootfd, path) != 0) + warn("symlink(%s)", path); + else if (fchownat(rootfd, path, uid, gid, + AT_SYMLINK_NOFOLLOW) != 0) + warn("chown(%s)", path); + metalog_emit_symlink(path, lnk, st.st_mode & ~pumask, + uid, gid); continue; } @@ -113,7 +125,7 @@ copymkdir(int rootfd, char const *dir, int skelfd, mode_t mode, uid_t uid, if ((srcfd = openat(skelfd, e->d_name, O_RDONLY)) == -1) continue; - destfd = openat(homefd, p, O_RDWR | O_CREAT | O_EXCL, + destfd = openat(rootfd, path, O_RDWR | O_CREAT | O_EXCL, st.st_mode); if (destfd == -1) { close(srcfd); @@ -135,6 +147,7 @@ copymkdir(int rootfd, char const *dir, int skelfd, mode_t mode, uid_t uid, warn("chown(%s)", p); if (fchflags(destfd, st.st_flags) != 0) warn("chflags(%s)", p); + metalog_emit(path, st.st_mode & ~pumask, uid, gid, st.st_flags); close(destfd); } closedir(d); diff --git a/usr.sbin/pw/pw.8 b/usr.sbin/pw/pw.8 index 5eae810b6732..f6d9ebca6308 100644 --- a/usr.sbin/pw/pw.8 +++ b/usr.sbin/pw/pw.8 @@ -30,6 +30,7 @@ .Nd create, remove, modify & display system users and groups .Sh SYNOPSIS .Nm +.Op Fl M Ar metalog .Op Fl R Ar rootdir .Op Fl V Ar etcdir .Cm useradd @@ -464,6 +465,21 @@ option, bearing the name of the new account. This can be overridden by the .Fl d option on the command line, if desired. +.It Fl M Ar metalog +Specify a path to a +.Xr mtree 5 +metalog file. +.Nm +will add entries for all files added to a user's home directory. +This is useful when building images as a non-root user, as the +metalog can be used as input to +.Xr tar 1 +or +.Xr makefs 8 . +Note that this option must precede the +.Ql useradd +string on the command line, otherwise it will be interpreted as the mode +option. .It Fl M Ar mode Create the user's home directory with the specified .Ar mode , diff --git a/usr.sbin/pw/pw.c b/usr.sbin/pw/pw.c index 6f59e392bdd0..7cb5dd160e12 100644 --- a/usr.sbin/pw/pw.c +++ b/usr.sbin/pw/pw.c @@ -132,7 +132,11 @@ main(int argc, char *argv[]) while (argc > 1) { if (*argv[1] == '-') { /* - * Special case, allow pw -V [args] for scripts etc. + * Special case, allow pw -V [args] for + * scripts etc. + * + * The -M option before the keyword is handled + * differently from -M after a keyword. */ arg = argv[1][1]; if (arg == 'V' || arg == 'R') { @@ -164,6 +168,23 @@ main(int argc, char *argv[]) "%s%s", optarg, arg == 'R' ? _PATH_PWD : ""); conf.altroot = true; + } else if (mode == -1 && which == -1 && arg == 'M') { + int fd; + + optarg = &argv[1][2]; + if (*optarg == '\0') { + optarg = argv[2]; + ++argv; + --argc; + } + fd = open(optarg, + O_WRONLY | O_APPEND | O_CREAT | O_CLOEXEC, + 0644); + if (fd == -1) + errx(EX_OSERR, + "Cannot open metalog `%s'", + optarg); + conf.metalog = fdopen(fd, "ae"); } else break; } else if (mode == -1 && (tmp = getindex(Modes, argv[1])) != -1) @@ -195,6 +216,10 @@ main(int argc, char *argv[]) if (conf.rootfd == -1) errx(EXIT_FAILURE, "Unable to open '%s'", conf.rootdir); + if (conf.metalog != NULL && (which != W_USER || mode != M_ADD)) + errx(EXIT_FAILURE, + "metalog can only be specified with 'useradd'"); + return (cmdfunc[which][mode](argc, argv, arg1)); } @@ -233,10 +258,11 @@ cmdhelp(int mode, int which) static const char *help[W_NUM][M_NUM] = { { - "usage: pw useradd [name] [switches]\n" + "usage: pw [-M metalog] useradd [name] [switches]\n" "\t-V etcdir alternate /etc location\n" "\t-R rootdir alternate root directory\n" "\t-C config configuration file\n" + "\t-M metalog mtree file, must precede 'useradd'\n" "\t-q quiet operation\n" " Adding users:\n" "\t-n name login name\n" diff --git a/usr.sbin/pw/pw.h b/usr.sbin/pw/pw.h index c3725693f91d..ceb843d79503 100644 --- a/usr.sbin/pw/pw.h +++ b/usr.sbin/pw/pw.h @@ -70,6 +70,11 @@ struct userconf *get_userconfig(const char *cfg); struct userconf *read_userconfig(char const * file); int write_userconfig(struct userconf *cnf, char const * file); +void metalog_emit(const char *path, mode_t mode, uid_t uid, gid_t gid, + int flags); +void metalog_emit_symlink(const char *path, const char *target, mode_t mode, + uid_t uid, gid_t gid); + int pw_group_add(int argc, char **argv, char *name); int pw_group_del(int argc, char **argv, char *name); int pw_group_mod(int argc, char **argv, char *name); diff --git a/usr.sbin/pw/pw_user.c b/usr.sbin/pw/pw_user.c index 007f750c7d1a..413eac4882cc 100644 --- a/usr.sbin/pw/pw_user.c +++ b/usr.sbin/pw/pw_user.c @@ -86,10 +86,13 @@ mkdir_home_parents(int dfd, const char *dir) { struct stat st; char *dirs, *tmp; + mode_t pumask; + + pumask = umask(0); + umask(pumask); if (*dir != '/') errx(EX_DATAERR, "invalid base directory for home '%s'", dir); - dir++; if (fstatat(dfd, dir, &st, 0) != -1) { @@ -120,6 +123,9 @@ mkdir_home_parents(int dfd, const char *dir) dirs); if (fchownat(dfd, dirs, 0, 0, 0) != 0) warn("chown(%s)", dirs); + metalog_emit(dir, + (_DEF_DIRMODE | S_IFDIR) & ~pumask, 0, 0, + 0); } *tmp = '/'; } @@ -129,6 +135,7 @@ mkdir_home_parents(int dfd, const char *dir) err(EX_OSFILE, "'%s' (home parent) is not a directory", dirs); if (fchownat(dfd, dirs, 0, 0, 0) != 0) warn("chown(%s)", dirs); + metalog_emit(dirs, (_DEF_DIRMODE | S_IFDIR) & ~pumask, 0, 0, 0); } free(dirs); diff --git a/usr.sbin/pw/pw_utils.c b/usr.sbin/pw/pw_utils.c index 9be1656bcfe1..87dd421ca8a3 100644 --- a/usr.sbin/pw/pw_utils.c +++ b/usr.sbin/pw/pw_utils.c @@ -92,3 +92,49 @@ nis_update(void) { errx(i, "make exited with status %d", i); return (i); } + +static void +metalog_emit_record(const char *path, const char *target, mode_t mode, + uid_t uid, gid_t gid, int flags) +{ + const char *flagstr, *type; + int error; + + if (conf.metalog == NULL) + return; + + if (target != NULL) + type = "link"; + else if (S_ISDIR(mode)) + type = "dir"; + else if (S_ISREG(mode)) + type = "file"; + else + errx(1, "metalog_emit: unhandled file type for %s", path); + + flagstr = fflagstostr(flags & + (UF_IMMUTABLE | UF_APPEND | SF_IMMUTABLE | SF_APPEND)); + if (flagstr == NULL) + errx(1, "metalog_emit: fflagstostr failed"); + + error = fprintf(conf.metalog, + "./%s type=%s mode=0%03o uid=%u gid=%u%s%s%s%s\n", + path, type, mode & ACCESSPERMS, uid, gid, + target != NULL ? " link=" : "", target != NULL ? target : "", + *flagstr != '\0' ? " flags=" : "", *flagstr != '\0' ? flagstr : ""); + if (error < 0) + errx(1, "metalog_emit: write error"); +} + +void +metalog_emit(const char *path, mode_t mode, uid_t uid, gid_t gid, int flags) +{ + metalog_emit_record(path, NULL, mode, uid, gid, flags); +} + +void +metalog_emit_symlink(const char *path, const char *target, mode_t mode, + uid_t uid, gid_t gid) +{ + metalog_emit_record(path, target, mode, uid, gid, 0); +} diff --git a/usr.sbin/pw/pwupd.h b/usr.sbin/pw/pwupd.h index a39a022ca309..605c51dcec2a 100644 --- a/usr.sbin/pw/pwupd.h +++ b/usr.sbin/pw/pwupd.h @@ -76,6 +76,7 @@ struct userconf { struct pwconf { char rootdir[MAXPATHLEN]; char etcpath[MAXPATHLEN]; + FILE *metalog; int fd; int rootfd; bool altroot; diff --git a/usr.sbin/pw/tests/pw_useradd_test.sh b/usr.sbin/pw/tests/pw_useradd_test.sh index 6413c063d482..75e96a64ba8e 100755 --- a/usr.sbin/pw/tests/pw_useradd_test.sh +++ b/usr.sbin/pw/tests/pw_useradd_test.sh @@ -1,4 +1,3 @@ - # Import helper functions . $(atf_get_srcdir)/helper_functions.shin @@ -357,15 +356,28 @@ user_add_skel_body() { echo "c" > ${HOME}/skel/c/d/dot.c mkdir ${HOME}/home ln -sf /nonexistent ${HOME}/skel/c/foo - atf_check -s exit:0 ${RPW} useradd foo -k /skel -m + atf_check -s exit:0 ${RPW} -M METALOG useradd foo -k /skel -m test -d ${HOME}/home/foo || atf_fail "Directory not created" test -f ${HOME}/home/foo/.a || atf_fail "File not created" atf_check -o file:${HOME}/skel/.a -s exit:0 cat ${HOME}/home/foo/.a atf_check -o file:${HOME}/skel/b -s exit:0 cat ${HOME}/home/foo/b - test -d ${HOME}/home/foo/c || atf_fail "Dotted directory in skel not copied" - test -d ${HOME}/home/foo/.plop || atf_fail "Directory in skell not created" + test -d ${HOME}/home/foo/c || atf_fail "Directory in skel not copied" + test -d ${HOME}/home/foo/.plop || atf_fail "Dotted directory in skel not created" atf_check -o inline:"/nonexistent\n" -s ignore readlink -f ${HOME}/home/foo/c/foo atf_check -o file:${HOME}/skel/c/d/dot.c -s exit:0 cat ${HOME}/home/foo/c/d/.c + + cat <<__EOF__ >METALOG.expected +./home/foo type=dir mode=0755 uid=1001 gid=1001 +./home/foo/.a type=file mode=0644 uid=1001 gid=1001 +./home/foo/.plop type=dir mode=0755 uid=1001 gid=1001 +./home/foo/b type=file mode=0644 uid=1001 gid=1001 +./home/foo/c type=dir mode=0755 uid=1001 gid=1001 +./home/foo/c/d type=dir mode=0755 uid=1001 gid=1001 +./home/foo/c/d/.c type=file mode=0644 uid=1001 gid=1001 +./home/foo/c/foo type=link mode=0755 uid=1001 gid=1001 link=/nonexistent +__EOF__ + atf_check -o save:METALOG.out sort METALOG + atf_check diff METALOG.out METALOG.expected } atf_test_case user_add_uid0 From nobody Thu Sep 18 23:42:59 2025 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 4cSXJ3363tz68DNb; Thu, 18 Sep 2025 23:42:59 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSXJ32QPFz3vl9; Thu, 18 Sep 2025 23:42:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758238979; 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=QMQR87znho0JLmW/UYf1BDDPzoyeKgOAD8HYRUI67zo=; b=yuF2dOc38ugp9RLt+lX3s+NOvSFCtCWAiNI9Jyz5JpRjcYGwvKbGgahMZl8lxQwrUHdaTm 806XQj2pE8nvbmkAbQNRg+pbQ9UdDryVPItK10UrmT329B4lfSX0ry0K6XeRRdnOzNmKHn 2oboNO7PQQrPtw+Y+SM0Zb8E5tLwfQmsja5NWL2ZuHHnIoBy7i+j9GTKdTmOPrnwiNt5vx OJE67zMOobujb7Q+5beeAB4K4jjDvkp3GY2NDxJ3Xe1jlKafXKvuysIgx/2xnwIde2+3Fi DMSFlBMnvnrVL030G9sxDF760/47ze2+BH51StHcTgo8vswJU6dFO1PvWZNRiw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758238979; 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=QMQR87znho0JLmW/UYf1BDDPzoyeKgOAD8HYRUI67zo=; b=R5tUJcITRtRJI6bpnB99XE3sthWmtqoiXv7uuLUrlVi6okVu83Y/bnXPULm9RbFko18ZL4 OQC2Ch2udWKkD6XF4my/if0jsZoVB+m2ERcOPFDcXGDu93eqXjmhyYmZYNI7RBBQCf97IK HYxIEdl6WUtDeGq/HlYdpyIaKG+Ntmkl2W6bMBYbbLX4vDdKrp6xmZs4CwReGqyYwkx53Y UxN127sjf7P/iqDuRQDLgfPecBpWyfbHwtIE4V0J88YSsBbyzEy3bcvQ7fe39N/EPxgP8h vTRWQt2cNp/zsy0Xto1bk4ibGcVxaeqbTR2rWIxR5J7c4SFvXhOelQ1W/HWiCg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758238979; a=rsa-sha256; cv=none; b=Jd44ZwcAubzoKhhkYBEUTespjMwM3VYhbhITkv5u22fpfLfaJvZQxCg9c4qE8oxlAUpCKy rso5dbuQ4zxw2SM+i6DbYJZTfZR8kBpsJS6UtmaKe+20TYRIcJAgDy30WfjAdYYsdDlvCa eBXe+EqAWFEwf52773Zx/lULM6CWgBQK+VGkJgAXM1BVgg0Qz0S4ZU9hkvsx2fXmFntjiM oX3Ymz4X8Ee99oxVMETbHGJmS/UYyPHbEfN09Q1A7w3zL96kLw01yeXopk8OaK4zj4Nz/G FmjQBfw991d+WkEQbm3hfeKOyP1t+G8wMsiKENC+dseOwIHfoH6Oz7pQsFJw6A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSXJ3229lzYP0; Thu, 18 Sep 2025 23:42:59 +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 58INgxZx094078; Thu, 18 Sep 2025 23:42:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58INgxvZ094075; Thu, 18 Sep 2025 23:42:59 GMT (envelope-from git) Date: Thu, 18 Sep 2025 23:42:59 GMT Message-Id: <202509182342.58INgxvZ094075@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Colin Percival Subject: git: 5918b4866a96 - main - release: Allow pkg build on "wrong" major 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5918b4866a9689b50180da42aad6d742466b0d1b Auto-Submitted: auto-generated The branch main has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=5918b4866a9689b50180da42aad6d742466b0d1b commit 5918b4866a9689b50180da42aad6d742466b0d1b Author: Colin Percival AuthorDate: 2025-09-18 23:37:46 +0000 Commit: Colin Percival CommitDate: 2025-09-18 23:41:14 +0000 release: Allow pkg build on "wrong" major While we usually build FreeBSD releases on the same major version, we do need to be able to e.g. build 15 on 16. Tell the ports tree that we know what we're doing. (We don't, not really, but we can at least pretend...) MFC after: 6 hours Sponsored by: https://www.patreon.com/cperciva --- release/scripts/make-pkg-package.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/release/scripts/make-pkg-package.sh b/release/scripts/make-pkg-package.sh index a0ac0fc16305..7712054d26c0 100755 --- a/release/scripts/make-pkg-package.sh +++ b/release/scripts/make-pkg-package.sh @@ -13,6 +13,7 @@ export WRKDIR=$(make -C ${PORTSDIR}/ports-mgmt/pkg -V WRKDIR) make -C ${PORTSDIR}/ports-mgmt/pkg TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \ CONFIGURE_ARGS="--host=$(uname -m)-portbld-freebsd${REVISION}" \ + I_DONT_CARE_IF_MY_BUILDS_TARGET_THE_WRONG_RELEASE=YES \ BATCH=YES stage create-manifest ${PKG_CMD} -o ABI=${PKG_ABI} \ From nobody Fri Sep 19 00:46:15 2025 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 4cSYj35yJ8z68Hwb; Fri, 19 Sep 2025 00:46:15 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSYj34Swtz439w; Fri, 19 Sep 2025 00:46:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758242775; 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=P2WL+AVs5HUpZO959l1Y3arW9PGfnS9s2TMJgXUMUSI=; b=mYwhq0QsUpPlKYx8QDzrjUXSELk+2fO0EHzpMkF66CjTQSz8Q3e3TakHui5L8opF+hPqND O+1VZcWQdKEZczkXkgEKE2Vcon+4mNIIHEaeGl1kmgPKEbi9fYkZgUHFqXGBNIuQZXBeIR c96v1r0YQYPyApJAaQWyfYOWQnWsjmkZK7/BA+tEwBNVh2/x+5f2qIYZ81sYUODUnyCw9c T99wCrg9O24gt02i78b0EjPA+xIDZUErKu2oDB/k2+DAB8DwEuuo2U3skxsvBuR91NG7Mn 6981HT/VmRSGDEEUe1z+XwgUgwNp9ge+b97CuZ4ZrChXKNDbIvXG92f2pWrp4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758242775; 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=P2WL+AVs5HUpZO959l1Y3arW9PGfnS9s2TMJgXUMUSI=; b=i6rGSosnRiHwASg5zAFbdUylmVU2j8dfxH0FdfH7njq4HAHku0Z8VYVJBWUsGWQ9CsaoQ2 oooL7xdhOgE2hQQpMo5IPfA4bPGGTwM+sxqywfqID3EnG97V6T/8w8gPGjpJB4QDjuRZ/7 G47gDeR0O4v2tS0tiiw5W4bhju1qTCoCQMRZp7QE7GYIJ6PbjZoayGvI4+g3SIFF5EgPVb oKa1FTKijS/x7K8Z/iB8tz1FpUYBciLVGOKdK8WCJ1iVgPANbP0A6Rto1Q5mIOfazbgZir eqN9DQwiw7VXKH6L43EcBfYqoTaWQovAspEgqVTfXU2UzF7jdZuRl+6sRkNN4A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758242775; a=rsa-sha256; cv=none; b=xw14ZKOTtzFoZo704+qTL0szKDZeHQsIP/pGoBQkD3EGDx3Z9s62vEj83AxAuyPh2Zr9oO fHOPGGAtsnja6FakRraOMqCVF7QP4nbMR8NpI7opVSAEbjXPYsG47Y0gH0qG27T93XxtiT XnYOsn8lH8jISWt0DRZNu0Stbr1Na6aG7h8oDB6R80s9SJSSCsDwWUqpN61MdFItLE3PWQ kk2tVAo93fwwdOaKsgm7a058OJcFUA2o4QNJAqYItYITgaJx+hruVQSaHutdnS6F20WaQv gyfrYbXjUS/agxD5HfevXMU6Uc6yZrywZ8Y/U72yEQcTlgxb1V88xbcNCm4LPg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSYj342MlzbQ4; Fri, 19 Sep 2025 00:46:15 +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 58J0kFff008768; Fri, 19 Sep 2025 00:46:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58J0kFTX008765; Fri, 19 Sep 2025 00:46:15 GMT (envelope-from git) Date: Fri, 19 Sep 2025 00:46:15 GMT Message-Id: <202509190046.58J0kFTX008765@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alexander Ziaee Subject: git: c8d87fd983e9 - stable/15 - rmuser.sh: Improve prompt consistency with adduser 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: ziaee X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: c8d87fd983e96785a58967fca40db6d2f2a3a850 Auto-Submitted: auto-generated The branch stable/15 has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=c8d87fd983e96785a58967fca40db6d2f2a3a850 commit c8d87fd983e96785a58967fca40db6d2f2a3a850 Author: Alexander Ziaee AuthorDate: 2025-09-09 17:06:29 +0000 Commit: Alexander Ziaee CommitDate: 2025-09-19 00:45:25 +0000 rmuser.sh: Improve prompt consistency with adduser While here, improve userlist error message. PR: 289399 MFC after: 3 days Reviewed by: kbowling, rgrimes Approved by: kbowling, rgrimes (src) Reported by: michaeldexter, rgrimes Differential Revision: https://reviews.freebsd.org/D52464 (cherry picked from commit fc68f8aac623b5494484adfa41ac600415609870) --- usr.sbin/adduser/rmuser.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/usr.sbin/adduser/rmuser.sh b/usr.sbin/adduser/rmuser.sh index 4c1e4049763a..8e5dd28cf01f 100644 --- a/usr.sbin/adduser/rmuser.sh +++ b/usr.sbin/adduser/rmuser.sh @@ -303,7 +303,7 @@ if [ ! "$userlist" ]; then show_usage exit 1 else - echo -n "Please enter one or more usernames: " + echo -n "Please enter one or more usernames, or press enter to exit: " read userlist fi fi @@ -333,11 +333,11 @@ for _user in $userlist ; do echo echo $userrec echo - if ! prompt_yesno "Is this the entry you wish to remove? " ; then + if ! prompt_yesno "Is this the entry you wish to remove? (yes/no): " ; then continue fi _homedir=`echo $userrec | awk -F: '{print $9}'` - if prompt_yesno "Remove user's home directory ($_homedir)? "; then + if prompt_yesno "Remove user's home directory? [$_homedir] (yes/no): "; then pw_rswitch="-r" fi else From nobody Fri Sep 19 00:59:24 2025 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 4cSZ0D2X23z68Jpg; Fri, 19 Sep 2025 00:59:24 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSZ0D1VsTz44cH; Fri, 19 Sep 2025 00:59:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758243564; 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=nzYBVTDgFn5Q/JeRyv3vqRc7kZxMYgxrt/wKniuJio0=; b=h+LKfb5MnsC4voifIXplpoSjijO8soDwdDn7lY9x/Xl7HTlYDTJ3re9lyUqjpaqDvK2zP4 aXijjx3KHtbh1qsTZ/7ycjEbnJEmyNL575hsvW489wA3lk9Omyvcam+ijc06UBBimueAQN egfp64UbX2VMB3xK4AUinOGjtC40pD6ZEyaxhM7QJOdnPx6qMS/4Yn4JrSWyEcJz9KKNn5 SM6F9BYRiaxfeLT7FekS2SpAQXXkj2MT+zV/40WAsEavuhIGaA3diZtTNpFcgzZoRABW05 jj2LXGgzquBC2p+3xJuHQsBx4j80tHGjZiYaAi8DzJY7OY/lxE5iAHXZABE7cg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758243564; 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=nzYBVTDgFn5Q/JeRyv3vqRc7kZxMYgxrt/wKniuJio0=; b=XVaSRWLdJsbbVoZMd7/7YJNLKJ+2tT82RqHWpwpfw7Ri7zkKEhkRblOBJepOVdcWrq/UbH 7HiZAga2zy3oPdfQ3XXkti5qTPy3KEPlwltAvsNxbbxuIz71r/JkTN/RM/2P3vKaeK7Vry 8WAkAJci06GOFIU+1niK+iIKsuHCXh9/H0vBkyNm5w3uw0dgJyG0RToxD91NgqDSWdlOQL zCSZHrNrHU+nomgMzJvOSsfYnfEN9T6lLwbM0qd09VAUDNYLsgWI92/CQw6jU/84sP/U44 QY/7K8pyhP3D6FV4OaGb4O2c2jzf65wk4uFPoXSRekEv5Z76uDc0USZSCI9VEw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758243564; a=rsa-sha256; cv=none; b=o/bN7vOrJOs7yLULWkxDR6djW5d4Grqp372BXJELNqt3apSZip806ebaBt4s9m/aTzWMWh LB/qQI7j45giSsNgmX2amjthJbLWG2jnddnXXDfRjGfBi6L/WSdCHfk2jJmQT1DV6/9FSS e+iLR3DrxDPFFe2q21byGNMKSOFJncGsqltqIRmfEs5f87ib+8zbwX7DB3ZJllTieRbdCw stPbkhuqL07Gm7wz5ht8tjrzwYKq7xHS+/shW3N6nKDIDUh9X5T6D/AHB+kucCEMg6jrxi mt7qy8uy5hwVjS2DnIVusZhkDKH29m9o63rlz2JA2mxZLSV73LZTWOezW9VXTw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSZ0D1558zcCx; Fri, 19 Sep 2025 00:59:24 +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 58J0xO2K028233; Fri, 19 Sep 2025 00:59:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58J0xOD3028230; Fri, 19 Sep 2025 00:59:24 GMT (envelope-from git) Date: Fri, 19 Sep 2025 00:59:24 GMT Message-Id: <202509190059.58J0xOD3028230@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: 92801ed02423 - stable/15 - lib/msun: cpow{,f,l}(CMLX(0.0, 0.0)) should return 1.0 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/15 X-Git-Reftype: branch X-Git-Commit: 92801ed02423bd8f7237223168eaa194b28d147f Auto-Submitted: auto-generated The branch stable/15 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=92801ed02423bd8f7237223168eaa194b28d147f commit 92801ed02423bd8f7237223168eaa194b28d147f Author: Steve Kargl AuthorDate: 2025-09-11 16:38:17 +0000 Commit: Konstantin Belousov CommitDate: 2025-09-19 00:58:53 +0000 lib/msun: cpow{,f,l}(CMLX(0.0, 0.0)) should return 1.0 PR: 289447 (cherry picked from commit 8b41ba845c7e10b5f241a1f944fe9a8e19ad75a9) --- lib/msun/src/s_cpow.c | 5 ++++- lib/msun/src/s_cpowf.c | 5 ++++- lib/msun/src/s_cpowl.c | 5 ++++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/lib/msun/src/s_cpow.c b/lib/msun/src/s_cpow.c index b887db51aa2a..2c20a8f3b48b 100644 --- a/lib/msun/src/s_cpow.c +++ b/lib/msun/src/s_cpow.c @@ -58,7 +58,10 @@ cpow(double complex a, double complex z) y = cimag (z); absa = cabs (a); if (absa == 0.0) { - return (CMPLX(0.0, 0.0)); + if (x == 0 && y == 0) + return (CMPLX(1., 0.)); + else + return (CMPLX(0., 0.)); } arga = carg (a); r = pow (absa, x); diff --git a/lib/msun/src/s_cpowf.c b/lib/msun/src/s_cpowf.c index 144291079f97..b8bdbd9cb07b 100644 --- a/lib/msun/src/s_cpowf.c +++ b/lib/msun/src/s_cpowf.c @@ -57,7 +57,10 @@ cpowf(float complex a, float complex z) y = cimagf(z); absa = cabsf (a); if (absa == 0.0f) { - return (CMPLXF(0.0f, 0.0f)); + if (x == 0 && y == 0) + return (CMPLXF(1.f, 0.f)); + else + return (CMPLXF(0.f, 0.f)); } arga = cargf (a); r = powf (absa, x); diff --git a/lib/msun/src/s_cpowl.c b/lib/msun/src/s_cpowl.c index 39797cadcfcb..efbe4936895f 100644 --- a/lib/msun/src/s_cpowl.c +++ b/lib/msun/src/s_cpowl.c @@ -57,7 +57,10 @@ cpowl(long double complex a, long double complex z) y = cimagl(z); absa = cabsl(a); if (absa == 0.0L) { - return (CMPLXL(0.0L, 0.0L)); + if (x == 0 && y == 0) + return (CMPLXL(1.L, 0.L)); + else + return (CMPLXL(0.L, 0.L)); } arga = cargl(a); r = powl(absa, x); From nobody Fri Sep 19 01:00:37 2025 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 4cSZ1d68j3z68Jpm; Fri, 19 Sep 2025 01:00:37 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSZ1d4q74z450H; Fri, 19 Sep 2025 01:00:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758243637; 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=EPgU/jJTYgSNgJe9/abup3+Wz85wcpdoB0Th2+zo3FY=; b=E+pPJHgG7CA25nYNg96yBVv81/HNpgl8ntV6YB7JOBA6RugFIQ7GdUta7TxVC40tMnB0Oj CjU2MKTUW/DfJg4D0yOGS/lzldJKeR4OEBIXrpIT0mOBi36BakIzfl/pjF7nHiCZqlHCGF ucF4iRrAVBJIqliqxfM09eTiZttmFnMa4Bp4JUZdbtwjHY+0dCBNRpOfhT0dX0fFJC6dGq w9LIdmdLpkR2/AgX/n25TNuiKFKxr534lzfYabqj6pU4zghSMaAJ5IzkPn21slj1AQKCE9 09VxrUgY68lX9ADQMdllyeLIc90qX3I7g4olzXkHpTSMCm8ENXmBjgUkcchepw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758243637; 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=EPgU/jJTYgSNgJe9/abup3+Wz85wcpdoB0Th2+zo3FY=; b=r/Jz61Kgj4dfRnX+SV90y1+OO+YOf64/lpbcc1FtP3GSJd66rxYH343yQ+onmVUCau/TcJ yVlWvF2GFaQX8f1nxXBADGWoc3ATWj/2zOU202Lz5fiW9f9Jvc4+sk5YtSvmglaxx7zTiB nMa9dJekCUctfzElpMT/SR81VbtQm74p+bzBGHfqjTImnTIeW1/SGuZtAUsWm07lcxgFtf 7G18SEMKzLFFw0BsDgI05JT0ftV06tRCYnQtsElx5tV8ed1bZqxcimKfuSLpfz8QIJlgW4 dMPgKSqsCUPEBsngCfZkdIN6jDMCO8THRg4jD4GgwIylATTxOTQBM/+3BTCVOQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758243637; a=rsa-sha256; cv=none; b=nNoH2K6Dr6YErbLAsmhMuB5QEXUiibVjmShslx8wo3u28RSFEoQtT5UHfkHzkw38uIJKJp t4VfvH7+HzR4SbAFL1b0gM9dRDkwskU5zEPm2/j7x45Z8RRAGVT2Yn8JqHlr26meFeDSUh gEs0BKXEUYmjd9O8RdhHupysMGG7AW/nAVCOVoparfIdeUfdaxGk2eO/etwIqvQBi43daD /ZPb+t0/fKJD/IpAWsAMac5j/Rf5plX9qztdRrTgKD7rtVjBZL997AVZIuD6NABxPTsY+k GO7DbelAUVHyp9AkpcPRf61XJrOy0sgvXmdopKyamGQP//EF+O9iUggx3v8+yA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSZ1d4BWbzbtK; Fri, 19 Sep 2025 01:00:37 +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 58J10bBd038497; Fri, 19 Sep 2025 01:00:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58J10bfi038494; Fri, 19 Sep 2025 01:00:37 GMT (envelope-from git) Date: Fri, 19 Sep 2025 01:00:37 GMT Message-Id: <202509190100.58J10bfi038494@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: 6f59cb79e84a - stable/14 - lib/msun: cpow{,f,l}(CMLX(0.0, 0.0)) should return 1.0 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: 6f59cb79e84a86d7b864d709652ec57b6928a6cf Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=6f59cb79e84a86d7b864d709652ec57b6928a6cf commit 6f59cb79e84a86d7b864d709652ec57b6928a6cf Author: Steve Kargl AuthorDate: 2025-09-11 16:38:17 +0000 Commit: Konstantin Belousov CommitDate: 2025-09-19 00:59:55 +0000 lib/msun: cpow{,f,l}(CMLX(0.0, 0.0)) should return 1.0 PR: 289447 (cherry picked from commit 8b41ba845c7e10b5f241a1f944fe9a8e19ad75a9) --- lib/msun/src/s_cpow.c | 5 ++++- lib/msun/src/s_cpowf.c | 5 ++++- lib/msun/src/s_cpowl.c | 5 ++++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/lib/msun/src/s_cpow.c b/lib/msun/src/s_cpow.c index b887db51aa2a..2c20a8f3b48b 100644 --- a/lib/msun/src/s_cpow.c +++ b/lib/msun/src/s_cpow.c @@ -58,7 +58,10 @@ cpow(double complex a, double complex z) y = cimag (z); absa = cabs (a); if (absa == 0.0) { - return (CMPLX(0.0, 0.0)); + if (x == 0 && y == 0) + return (CMPLX(1., 0.)); + else + return (CMPLX(0., 0.)); } arga = carg (a); r = pow (absa, x); diff --git a/lib/msun/src/s_cpowf.c b/lib/msun/src/s_cpowf.c index 144291079f97..b8bdbd9cb07b 100644 --- a/lib/msun/src/s_cpowf.c +++ b/lib/msun/src/s_cpowf.c @@ -57,7 +57,10 @@ cpowf(float complex a, float complex z) y = cimagf(z); absa = cabsf (a); if (absa == 0.0f) { - return (CMPLXF(0.0f, 0.0f)); + if (x == 0 && y == 0) + return (CMPLXF(1.f, 0.f)); + else + return (CMPLXF(0.f, 0.f)); } arga = cargf (a); r = powf (absa, x); diff --git a/lib/msun/src/s_cpowl.c b/lib/msun/src/s_cpowl.c index 39797cadcfcb..efbe4936895f 100644 --- a/lib/msun/src/s_cpowl.c +++ b/lib/msun/src/s_cpowl.c @@ -57,7 +57,10 @@ cpowl(long double complex a, long double complex z) y = cimagl(z); absa = cabsl(a); if (absa == 0.0L) { - return (CMPLXL(0.0L, 0.0L)); + if (x == 0 && y == 0) + return (CMPLXL(1.L, 0.L)); + else + return (CMPLXL(0.L, 0.L)); } arga = cargl(a); r = powl(absa, x); From nobody Fri Sep 19 01:16:39 2025 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 4cSZN72hqsz68LKY; Fri, 19 Sep 2025 01:16:39 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSZN72B33z485l; Fri, 19 Sep 2025 01:16:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758244599; 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=oFqUz13KNNENTfPLq6g0F9OJEDLBdh7iyhDuYo5OjkM=; b=jR5h7xvT7+kE0khQsF/K2MS/Moe5uXwgt3yeQznvWjjUy6e0qwu5ROxvdcQYM8HorQTYiY Df8XfYrxQ6o844jIAII//1VBnrAUOATvdXe0S7bVaFUJTwOrLc5OTentLzfRb4dYt8/+qa 885B9a1nhfUi93Oi5k+QC4pNfZ+uoXXgi7nR0PaAkEERbCo0tXwt49n3WeBcqaZTw5UvLv QGQBCfB/uaW30N8DCBogpc/m9Mlv5sKa07qrHAFjGurTcOoJo/nhJHV6JTN+uCAkuAKeXJ bGrqcBrSA47MGP7OmtJOinFG2zOoQ8OfunloB+P2Y2LhPR6vj4NUIsqrr/DeTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758244599; 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=oFqUz13KNNENTfPLq6g0F9OJEDLBdh7iyhDuYo5OjkM=; b=G94uSQNXZTSo9qN099PkkB14j/Lz0JIffw8vbgXNoeuHEVnzuzqdYvWBpgoO7xmtVZPoJf Agxq5OJ/I8QhkKjisYbuAP9FUuRVdwVoBFWvNNeR5R2GGb6l0ZsfhQzsplye4h8dShG59P Avu+yvK4P5wFOKCpVEToAPfCdLF89rUGpNdd7SS/4OXs9nQW0uuTo39y+nhJhVKSQD9pRZ cfvkAxqGCvYkTzFon9cwEY2fi20+4e+1vv+/IEJOTLIhIQ0ZMaFHa4FwxQxNdJZvqBA7/z P4CJlZ8eSt1rpQxHG+03MnxQ2xxI2QECEeRqsJNYekwIsl/wRROkh9xJkOfQpQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758244599; a=rsa-sha256; cv=none; b=bnDgWVlJ7ji7vIfdacdvFMLpo98KWz3rUT8oeRAsmIlkosqoNEtqUvIIuygN++MQrNX4AA fnRcGB1rhz3tDRoocdCmN15af3Ouss93lrEn3Ff8cfxLwEXGOJ9kDZqBlm1HeeuoXOilI5 ipD3SjrPWdqsGjrysPT2wUYbv7hM5eak/7vZHPRhOGaxce8iWpEIogYQGbHbT53hYU935+ HdCd/YTtZpepM4CRbdf8eQ8eTcJnucr6HEAaP4C7YaoN5X4Cwvj7D/tDOxX4fc1O2eY+d2 T0oCHyZXr4xZ6IGF10UdmfoQYtB9deEHHu2xTfBqxv381viySGZhGYvrGtPwkA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSZN71jDmzc82; Fri, 19 Sep 2025 01:16:39 +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 58J1Gdxo066028; Fri, 19 Sep 2025 01:16:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58J1GdYu066025; Fri, 19 Sep 2025 01:16:39 GMT (envelope-from git) Date: Fri, 19 Sep 2025 01:16:39 GMT Message-Id: <202509190116.58J1GdYu066025@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Lexi Winter Subject: git: 561dc357c2f5 - main - bsdinstall: Use package sets for pkgbase install 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 561dc357c2f5892af3aa481a1020860b7ff473e0 Auto-Submitted: auto-generated The branch main has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=561dc357c2f5892af3aa481a1020860b7ff473e0 commit 561dc357c2f5892af3aa481a1020860b7ff473e0 Author: Lexi Winter AuthorDate: 2025-09-18 17:28:36 +0000 Commit: Lexi Winter CommitDate: 2025-09-19 01:15:10 +0000 bsdinstall: Use package sets for pkgbase install Update the pkgbase component selection dialogue to take the components list from the meta-package sets available on the install media, except for "kernel" which is still handled magically. Always install "minimal", and by default select "base", "kernel-dbg" and any libcompat sets (e.g., lib32) if they're available. Replace the various "dbg" options with a single "debug" component that installs the debug symbols for all the components the user selected, except for kernel since we handle that separately and it's common to want kernel debugs symbols without userland debug symbols. MFC after: 3 seconds Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D52558 --- usr.sbin/bsdinstall/scripts/pkgbase.in | 159 ++++++++++++++++++++------------- 1 file changed, 97 insertions(+), 62 deletions(-) diff --git a/usr.sbin/bsdinstall/scripts/pkgbase.in b/usr.sbin/bsdinstall/scripts/pkgbase.in index d123394c170e..c06a3f789791 100755 --- a/usr.sbin/bsdinstall/scripts/pkgbase.in +++ b/usr.sbin/bsdinstall/scripts/pkgbase.in @@ -77,37 +77,57 @@ end -- traditional tarball component selection dialog. local function select_components(components, options) local descriptions = { - kernel_dbg = "Kernel debug info", - base_dbg = "Base system debug info", - src = "System source tree", - tests = "Test suite", - lib32 = "32-bit compatibility libraries", - lib32_dbg = "32-bit compatibility libraries debug info", + ["kernel-dbg"] = "Debug symbols for the kernel", + ["devel"] = "C/C++ compilers and related utilities", + ["base"] = "The complete base system (includes devel)", + ["src"] = "System source tree", + ["tests"] = "Test suite", + ["lib32"] = "32-bit compatibility libraries", + ["debug"] = "Debug symbols for the selected components", } + + -- These defaults match what the non-pkgbase installer selects + -- by default. local defaults = { - kernel_dbg = "on", - base_dbg = "off", - src = "off", - tests = "off", - lib32 = "on", - lib32_dbg = "off", + ["base"] = "on", + ["kernel-dbg"] = "on", } + -- Enable compat sets by default. + for compat in all_libcompats:gmatch("%S+") do + defaults["lib" .. compat] = "on" + end -- Sorting the components is necessary to ensure that the ordering is -- consistent in the UI. local sorted_components = {} for component, _ in pairs(components) do - table.insert(sorted_components, component) + -- Decide which sets we want to offer to the user: + -- + -- "minimal" is not offered since it's always included. + -- + -- "-dbg" sets are never offered, because those are handled + -- via the "debug" component. + -- + -- "kernels" is never offered because we only want one kernel, + -- which is handled separately. + -- + -- Sets whose name ends in "-jail" are intended for jails, and + -- are only offered if no_kernel is set. + if not component:match("^minimal") and + not component:match("%-dbg$") and + not (component == "kernels") and + not (not options.no_kernel and component:match("%-jail$")) then + table.insert(sorted_components, component) + end end table.sort(sorted_components) local checklist_items = {} for _, component in ipairs(sorted_components) do - if component ~= "base" and component ~= "kernel" and - not (component == "kernel_dbg" and options.no_kernel) and - #components[component] > 0 then - local description = descriptions[component] or "''" - local default = defaults[component] or "off" + if component ~= "kernel" and not + (component == "kernel-dbg" and options.no_kernel) then + local description = descriptions[component] or "" + local default = defaults[component] or "off" table.insert(checklist_items, component) table.insert(checklist_items, description) table.insert(checklist_items, default) @@ -120,7 +140,10 @@ local function select_components(components, options) "--nocancel", "--disable-esc", "--separate-output", - "--checklist", "Choose optional system components to install:", + "--checklist", + "A minimal set of packages suitable for a multi-user system ".. + "is always installed. Select additional packages you wish ".. + "to install:", "0", "0", "0", -- autosize } append_list(bsddialog_args, checklist_items) @@ -132,10 +155,16 @@ local function select_components(components, options) -- hopefully useful stack trace. assert(exit_code == 0) - local selected = {"base"} + -- Always install the minimal set, since it's required for the system + -- to work. The base set depends on minimal, but it's fine to install + -- both, and this way the user can remove the base set without pkg + -- autoremove then trying to remove minimal. + local selected = {"minimal"} + if not options.no_kernel then table.insert(selected, "kernel") end + for component in output:gmatch("[^\n]+") do table.insert(selected, component) end @@ -145,26 +174,21 @@ end -- Returns a list of pkgbase packages selected by the user local function select_packages(pkg, options) + -- These are the components which aren't generated automatically from + -- package sets. local components = { - kernel = {}, - kernel_dbg = {}, - base = {}, - base_dbg = {}, - src = {}, - tests = {}, + ["kernel"] = {}, + ["kernel-dbg"] = {}, + ["debug"] = {}, } - for compat in all_libcompats:gmatch("%S+") do - components["lib" .. compat] = {} - components["lib" .. compat .. "_dbg"] = {} - end - local rquery = capture(pkg .. "rquery -U -r FreeBSD-base %n") for package in rquery:gmatch("[^\n]+") do - if package == "FreeBSD-src" or package:match("^FreeBSD%-src%-.*") then - table.insert(components["src"], package) - elseif package == "FreeBSD-tests" or package:match("^FreeBSD%-tests%-.*") then - table.insert(components["tests"], package) + local setname = package:match("^FreeBSD%-set%-(.+)$") + + if setname then + components[setname] = components[setname] or {} + table.insert(components[setname], package) elseif package:match("^FreeBSD%-kernel%-.*") and package ~= "FreeBSD-kernel-man" then @@ -172,40 +196,51 @@ local function select_packages(pkg, options) if package == "FreeBSD-kernel-generic" then table.insert(components["kernel"], package) elseif package == "FreeBSD-kernel-generic-dbg" then - table.insert(components["kernel_dbg"], package) - end - elseif package:match(".*%-dbg$") then - table.insert(components["base_dbg"], package) - else - local found = false - for compat in all_libcompats:gmatch("%S+") do - if package:match(".*%-dbg%-lib" .. compat .. "$") then - table.insert(components["lib" .. compat .. "_dbg"], package) - found = true - break - elseif package:match(".*%-lib" .. compat .. "$") then - table.insert(components["lib" .. compat], package) - found = true - break - end - end - if not found then - table.insert(components["base"], package) + table.insert(components["kernel-dbg"], package) end end end - -- Don't assert the existence of dbg, tests, and src packages here. If using - -- a custom local repository with BSDINSTALL_PKG_REPOS_DIR we shouldn't - -- require it to have all packages. + + -- Assert that both a kernel and the "minimal" set are available, since + -- those are both required to install a functional system. Don't worry + -- if other sets are missing (e.g. base or src), which might happen + -- when using custom install media. assert(#components["kernel"] == 1) - assert(#components["base"] > 0) + assert(#components["minimal"] == 1) - local selected = {} - for _, component in ipairs(select_components(components, options)) do - append_list(selected, components[component]) + -- Prompt the user for what to install. + local selected = select_components(components, options) + + -- Determine if the "debug" component was selected. + local debug = false + for _, component in ipairs(selected) do + if component == "debug" then + debug = true + break + end end - return selected + local packages = {} + for _, component in ipairs(selected) do + local pkglist = components[component] + append_list(packages, pkglist) + + -- If the debug component was selected, install the -dbg + -- package for each set. We have to check if the dbg set + -- actually exists, because some sets (src, tests) don't + -- have a -dbg subpackage. + for _, c in ipairs(pkglist) do + local setname = c:match("^FreeBSD%-set%-(.*)$") + if debug and setname then + local dbgset = setname.."-dbg" + if components[dbgset] then + append_list(packages, components[dbgset]) + end + end + end + end + + return packages end local function parse_options() From nobody Fri Sep 19 01:16:40 2025 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 4cSZN83qP0z68LHJ; Fri, 19 Sep 2025 01:16:40 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSZN82w0Rz47lT; Fri, 19 Sep 2025 01:16:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758244600; 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=EYXT2AumXWtftAC4/0p/5Q2NyRdZCPByUD2K5PTLG+8=; b=fF6wDver4Ql7sBrEcS3/uAEazgoxGsxJU4q7JFR5h61vxclS8qCHa47Q/jfiFLqe/30D4w hVWjbMtksAP9V7L5wsBCrehUS9PsTafLk9w6kllK2kiGWmLxJPfoGLYwNQndCrzVtLqxdH o6Xn99GozgjoILDhp5ONXwb0GkKAFhG3XkK7pnE0nKn453iTipFpIKKZ4VM4wzh7Me5gvu rUWRLxvn/N2v1l6ARhxibzW5UiVORvIwK01Fdv+JpL3zSvtblFukacGdqTZXPqTeBcMdQ9 X3VBUr6xaHSanE5MaNRY1A0E8fSzpbgE2t8f9gy6cz4STXkJDVZtOEXO8V82pQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758244600; 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=EYXT2AumXWtftAC4/0p/5Q2NyRdZCPByUD2K5PTLG+8=; b=F8s0rUtxCxMzw/CnAA/ohJ+XBwQ+BYXK20mANs/CdXb+uCobPTNbXnvQ6pQykGtki/zhy/ YakRHrmE9gGDrq6hnwWCWJWM0cCGuzwjFpSNfYm/Vmc4s6zYjeSO+orLJehn9SFQnlCtjF /lRZ5KqECfCCHQqHG8qV5RsG5W2JpdtjqmgSv1xdhBWYZFiJWofZgd82xJEctr4M4HOt5C 0djCDA+zIS3Gh8LU8W1IOqIP9WRoBbDPGesNDiCtKB7j9+GconL6rs2+4pTYA4dQlEUM+u ZZWMd69kR8s+6O/4ekQ/ZnYOxw10hT0Yqht/+6HcI/K4/ZgnfqXbvifh9FoEFw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758244600; a=rsa-sha256; cv=none; b=TWvOGGdSZDznOqozlBuJW+1plYowztBqkwkxr0zTVgy4S5bPRKJRDtpit6ioiyXa3nlT2d hniEnoF1ovfV0r3WvDoIilrZyixruhp9EOQi3/6+rdbBlzL7GEdoWdMt3dAA57hMSnkzLz 1f5byG+/Iq43vubCmMgoT46S8DY8OoPu66BSPJbxAV3n3lFG9MW9o2w1ulMeqwfeaZw+0b djHOyoIX5lmB//iCKOI6rUdkbngy+IQPdEeiT5LnYugO37zh0lSfh+LSR/JVfJ5gQGMmSO 9itMvz583eJasS9g5BZVNFml1gI8nisyjqsp/xbvkVMfvKngL9GD/amz2hiJ4A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSZN82WCpzcFS; Fri, 19 Sep 2025 01:16:40 +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 58J1Gegf066062; Fri, 19 Sep 2025 01:16:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58J1GefE066059; Fri, 19 Sep 2025 01:16:40 GMT (envelope-from git) Date: Fri, 19 Sep 2025 01:16:40 GMT Message-Id: <202509190116.58J1GefE066059@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Lexi Winter Subject: git: 7e79bc8ce706 - main - release: use sets to select base packages 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7e79bc8ce70693a892c443c42af5ec16a95ba466 Auto-Submitted: auto-generated The branch main has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=7e79bc8ce70693a892c443c42af5ec16a95ba466 commit 7e79bc8ce70693a892c443c42af5ec16a95ba466 Author: Isaac Freund AuthorDate: 2025-09-16 19:38:54 +0000 Commit: Lexi Winter CommitDate: 2025-09-19 01:15:10 +0000 release: use sets to select base packages The introduction of package sets allows us to replace the current fragile string matching with this simpler and more robust alternative. Sponsored by: The FreeBSD Foundation MFC after: 3 seconds Reviewed by: emaste, ivy Differential Revision: https://reviews.freebsd.org/D52592 --- release/scripts/pkgbase-stage.lua | 98 +++++++++++---------------------------- 1 file changed, 28 insertions(+), 70 deletions(-) diff --git a/release/scripts/pkgbase-stage.lua b/release/scripts/pkgbase-stage.lua index 0cd4cbb5c438..9e968fd150f8 100755 --- a/release/scripts/pkgbase-stage.lua +++ b/release/scripts/pkgbase-stage.lua @@ -18,89 +18,47 @@ local function capture(command) return output:match("(.-)\n$") or output end -local function append_list(list, other) - for _, item in ipairs(other) do - table.insert(list, item) - end -end - -- Returns a list of packages to be included in the given media local function select_packages(pkg, media, all_libcompats) - local components = { - kernel = {}, - kernel_dbg = {}, - base = {}, - base_dbg = {}, - src = {}, - tests = {}, - } - - for compat in all_libcompats:gmatch("%S+") do - components["lib" .. compat] = {} - components["lib" .. compat .. "_dbg"] = {} - end - + local components = {} local rquery = capture(pkg .. "rquery -U -r FreeBSD-base %n") for package in rquery:gmatch("[^\n]+") do - if package == "FreeBSD-src" or package:match("^FreeBSD%-src%-.*") then - table.insert(components["src"], package) - elseif package == "FreeBSD-tests" or package:match("^FreeBSD%-tests%-.*") then - table.insert(components["tests"], package) - elseif package:match("^FreeBSD%-kernel%-.*") and - package ~= "FreeBSD-kernel-man" - then - -- Kernels other than FreeBSD-kernel-generic are ignored - -- Note that on powerpc64 and powerpc64le the names are - -- slightly different. - if package:match("^FreeBSD%-kernel%-generic.*%-dbg") then - table.insert(components["kernel_dbg"], package) - elseif package:match("^FreeBSD%-kernel%-generic.*") then - table.insert(components["kernel"], package) - end - elseif package:match(".*%-dbg$") then - table.insert(components["base_dbg"], package) - else - local found = false - for compat in all_libcompats:gmatch("%S+") do - if package:match(".*%-dbg%-lib" .. compat .. "$") then - table.insert(components["lib" .. compat .. "_dbg"], package) - found = true - break - elseif package:match(".*%-lib" .. compat .. "$") then - table.insert(components["lib" .. compat], package) - found = true - break - end - end - if not found then - table.insert(components["base"], package) - end + local set = package:match("^FreeBSD%-set%-(.*)$") + if set then + components[set] = package + -- Kernels other than FreeBSD-kernel-generic are ignored + -- Note that on powerpc64 and powerpc64le the names are + -- slightly different. + elseif package:match("^FreeBSD%-kernel%-generic.*-dbg") then + components["kernel-dbg"] = package + elseif package:match("^FreeBSD%-kernel%-generic.*") then + components["kernel"] = package end end - assert(#components["kernel"] == 1) - assert(#components["base"] > 0) + assert(components["kernel"]) + assert(components["base"]) local selected = {} if media == "disc" then - append_list(selected, components["base"]) - append_list(selected, components["kernel"]) - append_list(selected, components["kernel_dbg"]) - append_list(selected, components["src"]) - append_list(selected, components["tests"]) + table.insert(selected, components["base"]) + table.insert(selected, components["kernel"]) + table.insert(selected, components["kernel-dbg"]) + table.insert(selected, components["src"]) + table.insert(selected, components["tests"]) for compat in all_libcompats:gmatch("%S+") do - append_list(selected, components["lib" .. compat]) + table.insert(selected, components["lib" .. compat]) end else assert(media == "dvd") - append_list(selected, components["base"]) - append_list(selected, components["base_dbg"]) - append_list(selected, components["kernel"]) - append_list(selected, components["kernel_dbg"]) - append_list(selected, components["src"]) - append_list(selected, components["tests"]) + table.insert(selected, components["base"]) + table.insert(selected, components["base-dbg"]) + table.insert(selected, components["kernel"]) + table.insert(selected, components["kernel-dbg"]) + table.insert(selected, components["src"]) + table.insert(selected, components["tests"]) for compat in all_libcompats:gmatch("%S+") do - append_list(selected, components["lib" .. compat]) - append_list(selected, components["lib" .. compat .. "_dbg"]) + table.insert(selected, components["lib" .. compat]) + table.insert(selected, components["lib" .. compat .. "-dbg"]) end end @@ -138,7 +96,7 @@ local function main() local packages = select_packages(pkg, media, all_libcompats) - assert(os.execute(pkg .. "fetch -o " .. target .. " " .. table.concat(packages, " "))) + assert(os.execute(pkg .. "fetch -d -o " .. target .. " " .. table.concat(packages, " "))) assert(os.execute(pkg .. "repo " .. target)) end From nobody Fri Sep 19 01:19:50 2025 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 4cSZRp2hGRz68LcJ; Fri, 19 Sep 2025 01:19:50 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSZRp1rmpz49Lx; Fri, 19 Sep 2025 01:19:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758244790; 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=a4Wtjf7WP/GPLPkICiNZ0tGksc+A2LVYhNfA/Nn5zjU=; b=hOMA+ncrEGKEBwa9mjx0yUVPkoQAdbzwmPF9byPz1RI0SYAxuOB8W4tOB2LW62PkHq0690 jkUhKbIGG5l9I+FpZjfAi0A5wFjwOkcdeKmvOYpL4e7RKZkg4ciwLLG7jmGOKYAd/Ua78d 6jQb0pKZE7/bXObTo34WlafCpP437y+OIvAD75tId3W9j3nVix5/dq8oOD3sBe1VkApKKC FROHda64DP0L256YnUVXHTfJ+0NR5vhJejiOy8RV0z9HS2zj2nOZ2ZJDpCLZ54p9Go2Dmk WoAh7eUD2jsH0qWRm1qPNXfsqgaCL93ufSMxvucoFU+3iUbvlvrpNbCBocUd1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758244790; 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=a4Wtjf7WP/GPLPkICiNZ0tGksc+A2LVYhNfA/Nn5zjU=; b=y27IW8jdtNLNeJxpfsOtB7e35UsL4ImHPzqvFCpsj9mmMw04wUUD+KihankZFJXAF0kvhk py53Uaidqvynf40kZJKneZVU/oUtC7I2ieny1q6ixVKY5skQuQwrO8NwzZdGr0YFJU/8A1 YSaE+rF6jsV+xV8n5c7jAR0RDDDk6+3WaYc2drOl8q3ZczVnySWW/zCtw/T0TYyEctrncO WeWBV4/Sm9al4L9WwuuBMkCsXm5rdQ7cMgtfTMzaEfihM2BgiPV5MU+/BvOEG8RP+A3KI2 sk0/05M0vNqn/zYOTBDwyNW+cry3Z+S96lV3MeeR3/jd0Z5eX057TSEEFDKxmQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758244790; a=rsa-sha256; cv=none; b=KHbq3Mw6W8FARb+Xnu+Da/HOcZVR7YupbC2WFSi9yVtOi/+diX1baln+PrBnJ9Fl9aNgW+ d609ISrFCufjixzpb5iTs2VJAeeYJshk7S84BA9XL+6hajdOXknBpT6UfrpS9JhkPqicrv JyW9u08J1NKwdu4hGLPgMh0Sc/tHaMlZWIGZPXq2y7yBex7RnEPnrktxkx8M+hUgS2sD2F C9YFEXQYsyH/y46hfFxmeeO/Cb83d2Teen8PhNEQ+yyTKnSc+G2YSMNJ0oaRQpokiSxnCI aBsjcPGBrE81RYkrHqah0KQhUn07OyUT413qHNX7QqMxpUXAgLjzCR+DZpAcGQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSZRp1SLbzcM8; Fri, 19 Sep 2025 01:19:50 +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 58J1JoT3066987; Fri, 19 Sep 2025 01:19:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58J1JoVd066984; Fri, 19 Sep 2025 01:19:50 GMT (envelope-from git) Date: Fri, 19 Sep 2025 01:19:50 GMT Message-Id: <202509190119.58J1JoVd066984@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Lexi Winter Subject: git: 7e9f0bf1c05c - stable/15 - packages: Turn off MANSPLITPKG by default 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 7e9f0bf1c05c3e0de161c4ea9f0dfd71791f8957 Auto-Submitted: auto-generated The branch stable/15 has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=7e9f0bf1c05c3e0de161c4ea9f0dfd71791f8957 commit 7e9f0bf1c05c3e0de161c4ea9f0dfd71791f8957 Author: Lexi Winter AuthorDate: 2025-09-10 18:38:01 +0000 Commit: Lexi Winter CommitDate: 2025-09-19 01:17:27 +0000 packages: Turn off MANSPLITPKG by default Manpages are very small, and having a separate manpages package for every base package is quite annoying for users. Turn this option off by default. Discussed with: bapt Reviewed by: manu, emaste MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D52417 (cherry picked from commit a8a18eeb5e1711ad27c3ee20eb342b73d3badffa) --- UPDATING | 6 ++++++ share/man/man5/src.conf.5 | 4 ++-- share/mk/bsd.opts.mk | 2 +- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/UPDATING b/UPDATING index ae4f14a24858..fa8ef72082c1 100644 --- a/UPDATING +++ b/UPDATING @@ -12,6 +12,12 @@ Items affecting the ports and packages system can be found in /usr/ports/UPDATING. Please read that file before updating system packages and/or ports. +20250918: + The MANSPLITPKG knob has been turned off by default, so pkgbase builds + will no longer generate "-man" subpackages; instead the manpages will + be shipped in the packages they belong to. If you want to continue + building split man packages, set WITH_MANSPLITPKG=1. + 20250916: If SRCCONF is unset and a file named src.conf is present at the top of the source tree, it will now be used instead of diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index 648249148817..7ba8b4ac5e8f 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -1215,8 +1215,8 @@ is set explicitly) .It Va WITHOUT_MANCOMPRESS Do not install compressed man pages. Only the uncompressed versions will be installed. -.It Va WITHOUT_MANSPLITPKG -Do not split man pages into their own packages during make package. +.It Va WITH_MANSPLITPKG +Split man pages into their own packages during make package. .It Va WITHOUT_MAN_UTILS Do not build utilities for manual pages, .Xr apropos 1 , diff --git a/share/mk/bsd.opts.mk b/share/mk/bsd.opts.mk index 2251b499ffdc..73ebf82c258f 100644 --- a/share/mk/bsd.opts.mk +++ b/share/mk/bsd.opts.mk @@ -60,7 +60,6 @@ __DEFAULT_YES_OPTIONS = \ MAKE_CHECK_USE_SANDBOX \ MAN \ MANCOMPRESS \ - MANSPLITPKG \ NIS \ NLS \ OPENSSH \ @@ -79,6 +78,7 @@ __DEFAULT_NO_OPTIONS = \ CCACHE_BUILD \ CTF \ INSTALL_AS_USER \ + MANSPLITPKG \ RETPOLINE \ RUN_TESTS \ STALE_STAGED \ From nobody Fri Sep 19 01:19:51 2025 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 4cSZRq4Lvgz68LXY; Fri, 19 Sep 2025 01:19:51 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cSZRq39JFz49WV; Fri, 19 Sep 2025 01:19:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758244791; 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=yss9+GPiNpYnXnUoiVjEeuooTe8fZlJxofgdbajeYNk=; b=qQYUq2ZBjBDFY3VPzhTxE48tJB+9V+0g21Dh05G6qBUDlGgIyknXlYSYAA4/sexLpQEvT2 mLKOcb3OdOAhF+vCBiCaJaAASAduQfwJSDacrpCAifU++e0AX3LrIWdWL+CTx6EtMSfWpa ozO7kEsa37SA51+IgLLsfhiX2wbpZySYGVgvhguDG6qp/N8CUh9xYh9M8XoOIKm1TPlRcG ei0VhnQLP7rODw24pna8jwoqlB0bfs5CB1tF9VYtu82ADg0jd9SidsnMegsiggAx4K9p0K HZ0KsLiUZ3cinEO3eyOm0bXk31xnSselPmitm6rs4piWZrgwrm+1Ls94NIti6w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1758244791; 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=yss9+GPiNpYnXnUoiVjEeuooTe8fZlJxofgdbajeYNk=; b=aVsifB3YK6E0+kr54jMfgjxzaKGjZW0K23swMY1Np+NES8jYo9gxX44k4qsdfoBgxh8zre FPr1ig4m/NTWbMVXFndZqEplTQB4qDGXAIk7vtm+Fft+UdQQS61HEx4Lsu4qPkxSjl7H/0 WbxddY1WE8vv93aovcfmeNo/xIdGH2+js4YAo8eBhWCXNrj16lrsEMaZQQp0OEQuIzc6Ix ReC7+5U0TMfFNdwaCI24fZWfrRkrTdoTz4pPgjHHsdlHRj7Vmf8FXJRVP1wr9vRLvsiqwD ax+JyksAzojMfJznZhoABhgsJ/0fGrn04W6vbEHN01tBprIEXBK/N1g/51IFSg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1758244791; a=rsa-sha256; cv=none; b=Oo6CjDVZqMOqUp1x/SCpE769K4XOsMrsGeG0Ca7szIaoUVnRzrEovYixxN2bzTWE8v00AR Ld1ccJrQAhHTp63llUoilIV11qtxCxHgwChMhg4ksXrsDiBXCcCDHxEODgQ6hnSuHtFwVd PtpghV2A3BkycjXjKCwM6ao8IlozuOiqLEnJe+CEdmwsRf4MNuuqrnxGD4F0Vtud5dYMXA y1KdY0BYyZ4FmowVQwXYj5ZEj5JfPB4iizy6xc5axSfxmsYzX+Wy/Isd+vMeK0ShAKK7GK Y5CCctb6V0iEaF360JaVOlunNFhWBow27iw2Co7K6yF0EC5DXn2kLqBTXh7nww== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cSZRq2kcrzcj6; Fri, 19 Sep 2025 01:19:51 +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 58J1JpbJ067021; Fri, 19 Sep 2025 01:19:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 58J1JpBf067018; Fri, 19 Sep 2025 01:19:51 GMT (envelope-from git) Date: Fri, 19 Sep 2025 01:19:51 GMT Message-Id: <202509190119.58J1JpBf067018@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Lexi Winter Subject: git: f0971db25826 - stable/15 - packages: Use LIB_PACKAGE for zfs and ufs packages 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: f0971db25826d7e8a969cdd05858122554ca5663 Auto-Submitted: auto-generated The branch stable/15 has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=f0971db25826d7e8a969cdd05858122554ca5663 commit f0971db25826d7e8a969cdd05858122554ca5663 Author: Lexi Winter AuthorDate: 2025-09-11 19:46:26 +0000 Commit: Lexi Winter CommitDate: 2025-09-19 01:17:27 +0000 packages: Use LIB_PACKAGE for zfs and ufs packages Commit f9513c334ff7 moved the shared libraries for ZFS and UFS into separate packages (libzfs and libufs), which resulted in a rather large number of packages being created, e.g. for ZFS: FreeBSD-libzfs FreeBSD-libzfs-dbg FreeBSD-libzfs-dbg-lib32 FreeBSD-libzfs-dev FreeBSD-libzfs-dev-lib32 FreeBSD-libzfs-lib32 FreeBSD-zfs FreeBSD-zfs-dbg FreeBSD-zfs-dbg-lib32 FreeBSD-zfs-dev FreeBSD-zfs-dev-lib32 FreeBSD-zfs-lib32 FreeBSD-zfs-man Use LIB_PACKAGE instead, which significantly reduces the number of packages: FreeBSD-zfs FreeBSD-zfs-dbg FreeBSD-zfs-dbg-lib32 FreeBSD-zfs-dev FreeBSD-zfs-dev-lib32 FreeBSD-zfs-lib FreeBSD-zfs-lib32 FreeBSD-zfs-man MFC after: 3 days Reviewed by: bapt Differential Revision: https://reviews.freebsd.org/D52416 (cherry picked from commit 29185c9a26204383270cf96957c685c51f5bc894) --- cddl/lib/libavl/Makefile | 4 +++- cddl/lib/libicp/Makefile | 2 ++ cddl/lib/libnvpair/Makefile | 4 +++- cddl/lib/libspl/Makefile | 4 +++- cddl/lib/libtpool/Makefile | 7 ++++--- cddl/lib/libumem/Makefile | 4 +++- cddl/lib/libuutil/Makefile | 4 +++- cddl/lib/libzdb/Makefile | 4 +++- cddl/lib/libzfs/Makefile | 4 +++- cddl/lib/libzfs_core/Makefile | 3 ++- cddl/lib/libzfsbootenv/Makefile | 2 ++ cddl/lib/libzpool/Makefile | 2 ++ cddl/lib/libzutil/Makefile | 4 +++- lib/libbe/Makefile | 1 + lib/libufs/Makefile | 4 +++- release/packages/ucl/libufs-all.ucl | 8 -------- release/packages/ucl/libzfs-all.ucl | 5 ----- 17 files changed, 40 insertions(+), 26 deletions(-) diff --git a/cddl/lib/libavl/Makefile b/cddl/lib/libavl/Makefile index ce77012def9f..4ce1de20a3d9 100644 --- a/cddl/lib/libavl/Makefile +++ b/cddl/lib/libavl/Makefile @@ -1,6 +1,8 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/module/avl -PACKAGE= libzfs +PACKAGE= zfs +LIB_PACKAGE= + LIB= avl LIBADD= spl SRCS= avl.c diff --git a/cddl/lib/libicp/Makefile b/cddl/lib/libicp/Makefile index 8e801246215f..1a9a79103b50 100644 --- a/cddl/lib/libicp/Makefile +++ b/cddl/lib/libicp/Makefile @@ -1,6 +1,8 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/module/icp PACKAGE= zfs +LIB_PACKAGE= + LIB= icp LIBADD= diff --git a/cddl/lib/libnvpair/Makefile b/cddl/lib/libnvpair/Makefile index 2d9ef1c7af1e..8245b324688b 100644 --- a/cddl/lib/libnvpair/Makefile +++ b/cddl/lib/libnvpair/Makefile @@ -2,10 +2,12 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libnvpair .PATH: ${SRCTOP}/sys/contrib/openzfs/include +PACKAGE= zfs +LIB_PACKAGE= + LIB= nvpair LIBADD= spl -PACKAGE= libzfs # user INCS= libnvpair.h SRCS= libnvpair.c \ diff --git a/cddl/lib/libspl/Makefile b/cddl/lib/libspl/Makefile index d8d997c6f377..26e14ea72b8a 100644 --- a/cddl/lib/libspl/Makefile +++ b/cddl/lib/libspl/Makefile @@ -4,9 +4,11 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libspl .PATH: ${SRCTOP}/sys/contrib/openzfs/include +PACKAGE= zfs +LIB_PACKAGE= + LIB= spl LIBADD= -PACKAGE= libzfs SRCS = \ assert.c \ diff --git a/cddl/lib/libtpool/Makefile b/cddl/lib/libtpool/Makefile index 7acf34219a47..3a50a21bf62c 100644 --- a/cddl/lib/libtpool/Makefile +++ b/cddl/lib/libtpool/Makefile @@ -1,11 +1,12 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libtpool .PATH: ${SRCTOP}/sys/contrib/openzfs/include +PACKAGE= zfs +LIB_PACKAGE= -LIB= tpool +LIB= tpool SHLIBDIR?= /lib -LIBADD= spl -PACKAGE= libzfs +LIBADD= spl INCS= thread_pool_impl.h SRCS= thread_pool.c diff --git a/cddl/lib/libumem/Makefile b/cddl/lib/libumem/Makefile index 9164ba771fe6..512332275fec 100644 --- a/cddl/lib/libumem/Makefile +++ b/cddl/lib/libumem/Makefile @@ -1,6 +1,8 @@ .PATH: ${SRCTOP}/cddl/compat/opensolaris/lib/libumem -PACKAGE= libzfs +PACKAGE= zfs +LIB_PACKAGE= + LIB= umem SRCS= umem.c WARNS?= 3 diff --git a/cddl/lib/libuutil/Makefile b/cddl/lib/libuutil/Makefile index 8c8a786ee039..947e755d4aae 100644 --- a/cddl/lib/libuutil/Makefile +++ b/cddl/lib/libuutil/Makefile @@ -1,6 +1,8 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libuutil -PACKAGE= libzfs +PACKAGE= zfs +LIB_PACKAGE= + LIB= uutil SRCS=\ uu_alloc.c \ diff --git a/cddl/lib/libzdb/Makefile b/cddl/lib/libzdb/Makefile index 0eb30c55d107..040d7d2c63f9 100644 --- a/cddl/lib/libzdb/Makefile +++ b/cddl/lib/libzdb/Makefile @@ -1,8 +1,10 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libzdb .PATH: ${SRCTOP}/sys/contrib/openzfs/include -LIB= zdb PACKAGE= zfs +LIB_PACKAGE= + +LIB= zdb INCS = libzdb.h diff --git a/cddl/lib/libzfs/Makefile b/cddl/lib/libzfs/Makefile index 40553aa68719..376e32fb893f 100644 --- a/cddl/lib/libzfs/Makefile +++ b/cddl/lib/libzfs/Makefile @@ -7,7 +7,9 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/module/zstd .PATH: ${SRCTOP}/sys/contrib/openzfs/module/zstd/lib -PACKAGE= libzfs +PACKAGE= zfs +LIB_PACKAGE= + LIB= zfs LIBADD= \ avl \ diff --git a/cddl/lib/libzfs_core/Makefile b/cddl/lib/libzfs_core/Makefile index bac81ca73497..10533c5de05b 100644 --- a/cddl/lib/libzfs_core/Makefile +++ b/cddl/lib/libzfs_core/Makefile @@ -3,10 +3,11 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/include/os/freebsd/zfs .PATH: ${SRCTOP}/sys/contrib/openzfs/module/os/freebsd/zfs +PACKAGE= zfs +LIB_PACKAGE= LIB= zfs_core LIBADD= nvpair spl zutil -PACKAGE= libzfs INCS= libzfs_core.h SRCS= libzfs_core.c \ diff --git a/cddl/lib/libzfsbootenv/Makefile b/cddl/lib/libzfsbootenv/Makefile index 15ee5bfaeaa4..22f5da1ee5b1 100644 --- a/cddl/lib/libzfsbootenv/Makefile +++ b/cddl/lib/libzfsbootenv/Makefile @@ -2,6 +2,8 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/include PACKAGE= zfs +LIB_PACKAGE= + LIB= zfsbootenv SHLIB_MAJOR= 1 diff --git a/cddl/lib/libzpool/Makefile b/cddl/lib/libzpool/Makefile index 4da3840e59f0..82ec0e890d56 100644 --- a/cddl/lib/libzpool/Makefile +++ b/cddl/lib/libzpool/Makefile @@ -29,6 +29,8 @@ PICFLAG= -fPIC .endif PACKAGE= zfs +LIB_PACKAGE= + LIB= zpool USER_C = \ diff --git a/cddl/lib/libzutil/Makefile b/cddl/lib/libzutil/Makefile index 07ca3b9bc156..37e9e8dd5e63 100644 --- a/cddl/lib/libzutil/Makefile +++ b/cddl/lib/libzutil/Makefile @@ -2,9 +2,11 @@ .PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libzutil/os/freebsd .PATH: ${SRCTOP}/sys/contrib/openzfs/module/os/freebsd/zfs +PACKAGE= zfs +LIB_PACKAGE= + LIB= zutil LIBADD= avl geom m tpool -PACKAGE= libzfs INCS = zutil_import.h diff --git a/lib/libbe/Makefile b/lib/libbe/Makefile index b04becc38d74..3ba456aee4b7 100644 --- a/lib/libbe/Makefile +++ b/lib/libbe/Makefile @@ -3,6 +3,7 @@ SHLIBDIR?= /lib .include PACKAGE= zfs +LIB_PACKAGE= LIB= be SHLIB_MAJOR= 1 SHLIB_MINOR= 0 diff --git a/lib/libufs/Makefile b/lib/libufs/Makefile index ab913f834bb3..3b1911d7a5cd 100644 --- a/lib/libufs/Makefile +++ b/lib/libufs/Makefile @@ -1,4 +1,6 @@ -PACKAGE= libufs +PACKAGE= ufs +LIB_PACKAGE= + LIB= ufs SHLIBDIR?= /lib SHLIB_MAJOR= 8 diff --git a/release/packages/ucl/libufs-all.ucl b/release/packages/ucl/libufs-all.ucl deleted file mode 100644 index d86a84bbd637..000000000000 --- a/release/packages/ucl/libufs-all.ucl +++ /dev/null @@ -1,8 +0,0 @@ -comment = "Low-level access to UFS filesystems" -desc = < To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Lexi Winter Subject: git: 74e73673d5cb - stable/15 - packages: Add correct license for zoneinfo 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 74e73673d5cbfdef92769e59354ec9c6905a8433 Auto-Submitted: auto-generated The branch stable/15 has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=74e73673d5cbfdef92769e59354ec9c6905a8433 commit 74e73673d5cbfdef92769e59354ec9c6905a8433 Author: Lexi Winter AuthorDate: 2025-09-11 19:49:09 +0000 Commit: Lexi Winter CommitDate: 2025-09-19 01:17:27 +0000 packages: Add correct license for zoneinfo Source: contrib/tzdata/LICENSE MFC after: 3 days Reviewed by: bapt Differential Revision: https://reviews.freebsd.org/D51886 (cherry picked from commit 163f8625c4df3ccdfab0717cf8b8d13a163e22eb) --- release/packages/ucl/zoneinfo-all.ucl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/release/packages/ucl/zoneinfo-all.ucl b/release/packages/ucl/zoneinfo-all.ucl index 39991bf144e6..ed737c740bee 100644 --- a/release/packages/ucl/zoneinfo-all.ucl +++ b/release/packages/ucl/zoneinfo-all.ucl @@ -1,5 +1,8 @@ comment = "Timezone database" + desc = < To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Lexi Winter Subject: git: 00ae91fa64a1 - stable/15 - packages: Add meta-package sets 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: ivy X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 00ae91fa64a10c7c0b1edcea466b0b2ba97cb0cc Auto-Submitted: auto-generated The branch stable/15 has been updated by ivy: URL: https://cgit.FreeBSD.org/src/commit/?id=00ae91fa64a10c7c0b1edcea466b0b2ba97cb0cc commit 00ae91fa64a10c7c0b1edcea466b0b2ba97cb0cc Author: Lexi Winter AuthorDate: 2025-09-12 20:59:25 +0000 Commit: Lexi Winter CommitDate: 2025-09-19 01:17:27 +0000 packages: Add meta-package sets Add several metapackages which contain no files themselves, but depend on other packages. This allows the user to install a system by using a set like "FreeBSD-set-minimal" instead of having to know which specific packages are required, and it means if we add more package in the future, existing installations will get them automatically as long as they were installed using a set. The defined sets are significantly less granular than the actual packages; the assumption is that users who want a very specific set of packages installed can do that manually, while sets are intended more for typical users who just want to install FreeBSD. The following sets are defined: * minimal: the set of packages required to boot the system and bring up a multi-user UNIX system. This includes hardware support, networking (wireless, DHCP), basic functionality like syslogd, cron and periodic. It does not include a kernel, because the kernels are quite large and the user might want to use a custom kernel. sendmail and DMA are not included in minimal. Since we provide two MTAs, the user should select which one they want, or install one from ports. sshd is not included because it's not required for the base system, and the user might want to install it from ports. Some other significant subsystems (e.g. NFS, Kerberos) are also not included. The minimal set does not include any libraries itself, since we rely on dependencies to pull these in. This implies it doesn't include library manpages, which is fine, since users won't want manpages for libraries unless they've also installed the development packages. * devel: the compiler toolchain for building software, along with all "-dev" packages which include header files and static libraries. * lib32: 32-bit compatibility packages. This includes both runtime and development packages. * kernels: the kernel packages. For freebsd.org builds, this will be GENERIC, GENERIC-DEBUG, etc., for custom builds it will be whatever was set in $KERNCONF. * base: everything else; this includes the entire base system. For each set, also generate a -dbg set containing the debug packages for the set. The sets are built along with the rest of the packages using a new script called create-sets.sh, which examines the "set" annotation in each package and puts it in the appropriate set. This is in anticipation of the later "groups" feature appearing in pkg itself, at which point we can simply replace the set annotation with the group. MFC after: 3 days Reviewed by: imp, bapt Differential Revision: https://reviews.freebsd.org/D52412 (cherry picked from commit 66f36c3686762d9a6e48b0453fc7221be36a0eb8) --- Makefile.inc1 | 30 +++++++++- release/packages/create-sets.sh | 45 ++++++++++++++ release/packages/generate-set-ucl.lua | 96 ++++++++++++++++++++++++++++++ release/packages/generate-ucl.lua | 34 +++++++++++ release/packages/set-template.ucl | 15 +++++ release/packages/sets/base-dbg.ucl | 16 +++++ release/packages/sets/base.ucl | 16 +++++ release/packages/sets/devel-dbg.ucl | 13 ++++ release/packages/sets/devel.ucl | 13 ++++ release/packages/sets/kernels-dbg.ucl | 6 ++ release/packages/sets/kernels.ucl | 6 ++ release/packages/sets/lib32-dbg.ucl | 6 ++ release/packages/sets/lib32.ucl | 6 ++ release/packages/sets/minimal-dbg.ucl | 6 ++ release/packages/sets/minimal.ucl | 6 ++ release/packages/template.ucl | 33 +++++++--- release/packages/ucl/README | 21 +++++++ release/packages/ucl/at-all.ucl | 4 ++ release/packages/ucl/bmake-all.ucl | 5 ++ release/packages/ucl/bootloader-all.ucl | 4 ++ release/packages/ucl/caroot-all.ucl | 4 ++ release/packages/ucl/certctl-all.ucl | 4 ++ release/packages/ucl/clang-all.ucl | 4 ++ release/packages/ucl/clibs-all.ucl | 5 ++ release/packages/ucl/cron-all.ucl | 4 ++ release/packages/ucl/ctf-tools-all.ucl | 5 ++ release/packages/ucl/devd-all.ucl | 5 ++ release/packages/ucl/devmatch-all.ucl | 11 +++- release/packages/ucl/dhclient-all.ucl | 5 ++ release/packages/ucl/dtb-all.ucl | 5 ++ release/packages/ucl/fetch-all.ucl | 10 +++- release/packages/ucl/firmware-iwm-all.ucl | 10 +++- release/packages/ucl/fwget-all.ucl | 10 +++- release/packages/ucl/geom-all.ucl | 11 +++- release/packages/ucl/hyperv-tools-all.ucl | 10 +++- release/packages/ucl/inetd-all.ucl | 9 ++- release/packages/ucl/kernel-all.ucl | 5 ++ release/packages/ucl/lld-all.ucl | 4 ++ release/packages/ucl/lldb-all.ucl | 4 ++ release/packages/ucl/locales-all.ucl | 5 ++ release/packages/ucl/mtree-all.ucl | 5 ++ release/packages/ucl/newsyslog-all.ucl | 10 +++- release/packages/ucl/nuageinit-all.ucl | 5 ++ release/packages/ucl/periodic-all.ucl | 11 +++- release/packages/ucl/pkg-bootstrap-all.ucl | 11 +++- release/packages/ucl/ppp-all.ucl | 5 ++ release/packages/ucl/rc-all.ucl | 11 +++- release/packages/ucl/rdma-all.ucl | 3 + release/packages/ucl/rescue-all.ucl | 11 +++- release/packages/ucl/resolvconf-all.ucl | 11 +++- release/packages/ucl/runtime-all.ucl | 10 +++- release/packages/ucl/runtime.ucl | 1 + release/packages/ucl/syslogd-all.ucl | 10 +++- release/packages/ucl/toolchain-all.ucl | 5 ++ release/packages/ucl/ufs-all.ucl | 5 ++ release/packages/ucl/utilities-all.ucl | 5 ++ release/packages/ucl/vi-all.ucl | 10 +++- release/packages/ucl/vt-data-all.ucl | 5 ++ release/packages/ucl/wpa-all.ucl | 5 ++ release/packages/ucl/zfs-all.ucl | 5 ++ release/packages/ucl/zoneinfo-all.ucl | 4 ++ 61 files changed, 619 insertions(+), 40 deletions(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index 98059640daab..97a0b00cc517 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -2097,6 +2097,14 @@ create-packages-world: _pkgbootstrap _repodir .PHONY DESTDIR=${WSTAGEDIR} \ PKG_VERSION=${PKG_VERSION} create-world-packages +.ORDER: create-packages-world create-packages-sets +.ORDER: create-packages-kernel create-packages-sets +create-packages-sets: _pkgbootstrap _repodir .PHONY + ${_+_}@cd ${.CURDIR}; \ + ${MAKE} -f Makefile.inc1 \ + DESTDIR=${WSTAGEDIR} \ + PKG_VERSION=${PKG_VERSION} create-sets-packages + create-packages-kernel: _pkgbootstrap _repodir .PHONY ${_+_}@cd ${.CURDIR}; \ ${MAKE} -f Makefile.inc1 \ @@ -2109,6 +2117,8 @@ create-packages-kernel-repo: .PHONY create-packages-kernel sign-packages create-packages-world-repo: .PHONY create-packages-world sign-packages +create-packages-sets-repo: .PHONY create-packages-sets sign-packages + create-packages-source: _pkgbootstrap _repodir .PHONY ${_+_}@cd ${.CURDIR}; \ ${MAKE} -f Makefile.inc1 \ @@ -2117,7 +2127,7 @@ create-packages-source: _pkgbootstrap _repodir .PHONY SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH} \ create-source-packages -create-packages: .PHONY create-packages-world create-packages-kernel create-packages-source +create-packages: .PHONY create-packages-world create-packages-kernel create-packages-source create-packages-sets create-source-src-package: _pkgbootstrap .PHONY rm -f ${SSTAGEDIR}/src.plist 2>/dev/null || : @@ -2214,6 +2224,24 @@ create-world-package-${pkgname}: .PHONY -o ${REPODIR}/${PKG_ABI}/${PKG_OUTPUT_DIR} .endfor +create-sets-packages-jobs: .PHONY create-sets-packages +create-sets-packages: .PHONY + @echo "==> Creating set metapackages." + sh "${SRCDIR}/release/packages/create-sets.sh" "${SRCDIR}" \ + "${WSTAGEDIR}" "${REPODIR}/${PKG_ABI}/${PKG_OUTPUT_DIR}" \ + VERSION "${PKG_VERSION}" \ + PKG_NAME_PREFIX "${PKG_NAME_PREFIX}" \ + PKG_MAINTAINER "${PKG_MAINTAINER}" \ + PKG_WWW "${PKG_WWW}" + @for manifest in ${WSTAGEDIR}/set-*.ucl; do \ + echo "--> Processing manifest: $$manifest"; \ + ${PKG_CMD} -o ABI=${PKG_ABI} -o OSVERSION="${SRCRELDATE}" \ + create -f ${PKG_FORMAT} ${PKG_CLEVEL} \ + -M $$manifest \ + -o "${REPODIR}/${PKG_ABI}/${PKG_OUTPUT_DIR}" \ + || exit 1; \ + done + _default_flavor= -default .if make(*package*) && exists(${KSTAGEDIR}/kernel.meta) . if ${MK_DEBUG_FILES} != "no" diff --git a/release/packages/create-sets.sh b/release/packages/create-sets.sh new file mode 100755 index 000000000000..6c034834672e --- /dev/null +++ b/release/packages/create-sets.sh @@ -0,0 +1,45 @@ +#! /bin/sh + +# Generate metapackage sets. We do this by examining the annotations field +# of the packages we previously built. + +set -e + +if [ $# -lt 3 ]; then + printf >&2 'usage: %s \n' "$0" + exit 1 +fi + +srcdir="$1"; shift +wstagedir="$1"; shift +repodir="$1"; shift +# Everything after the first three arguments is UCL variables we pass to +# generate-set-ucl.lua. +UCL_VARS="$@" + +for pkg in "$repodir"/*.pkg; do + # If the package name doesn't containing a '-', then it's + # probably data.pkg or packagesite.pkg, which are not real + # packages. + { echo "$pkg" | grep -q '-'; } || continue + + set -- $(pkg query -F "$pkg" '%At %n %Av' | grep '^set ') + pkgname="$2" + set="$3" + SETS="$SETS $set" + setvar="$(echo "$set" | tr - _)" + eval PKGS_${setvar}=\"\$PKGS_${setvar} $pkgname\" +done + +for set in $(echo $SETS | tr ' ' '\n' | sort | uniq); do + setvar="$(echo "$set" | tr - _)" + eval deps=\"\$PKGS_${setvar}\" + + "${srcdir}/release/packages/generate-set-ucl.lua" \ + "${srcdir}/release/packages/set-template.ucl" \ + PKGNAME "$set" \ + SET_DEPENDS "$deps" \ + UCLFILES "${srcdir}/release/packages/sets" \ + $UCL_VARS \ + > "${wstagedir}/set-${set}.ucl" +done diff --git a/release/packages/generate-set-ucl.lua b/release/packages/generate-set-ucl.lua new file mode 100755 index 000000000000..b1b70053b02a --- /dev/null +++ b/release/packages/generate-set-ucl.lua @@ -0,0 +1,96 @@ +#!/usr/libexec/flua + +--[[ usage: +generare-set-ucl.lua