From nobody Mon Mar 2 08:52:11 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPXk43rJGz6T6lW for ; Mon, 02 Mar 2026 08:52: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPXk36NZqz40jR for ; Mon, 02 Mar 2026 08:52:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772441531; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XWa+lGSsIrBqSDC0eK2SzksrMCMmiLqUbr7raBlcjU8=; b=eZbbyGAgGYn8fQjPbUfLieZ6n/mpATzmoM9istDfuua0hFziYUmTjWukjr71pIO5Huw9Ac eXfcP+A1KorvVS70VqW1P2vhZV/urI2YL28qK9LL110cpT1Ax3t8jnTW9jKGDWTSCzLnPS 0mDK/N06wRmrmxzE/zh2CMXr9/Ia3cUCeKXp8a/SmRgbuG7vqo7l85ETGfNerpT2Cgue4A Me2Snvt1sijzxymJZ1U28v2tUqvReRiPljRjCt34MRpoJzzQuYD9teYuObKUybcPJUe+i9 aeBezNFrerwNp9Npc5QEZRjTnBxHqCV1RGVPJkPL6Pk/fp0ofMJB5v4JOyOqug== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772441531; a=rsa-sha256; cv=none; b=sjiSe9bN8oYd6W/XRuDDuvHtSDpIO2plP+9J3KzXtm+ubx1Eb8H4TuaJfvB95Tg5qwVZGU 7YF+cAjMKm5vlfgclCC2+JyBN9VzZsG+j3eW82qWGCV/UoaKR0agj4ZIkTVo7NXJFzSB/7 Oxs37NVYhjkOTxMcWnz/cDtIPUJGmXWggv/n5hFGopM4gJPF86zG8+FK1REBKQ7+mtXhqQ 2u9iFLoEy4inyYtz98a9QvD5Bq0VPmH39k1HY+NZuwbEZim4PsnRASCjDRWD3ygWkw24AN EuPvkMvKcJOyEdyAfyxUzEQcmp8eYP431UdpsGTRAGLjDrtntwMJFM5GC4ecxA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772441531; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XWa+lGSsIrBqSDC0eK2SzksrMCMmiLqUbr7raBlcjU8=; b=FQo8OWtfAelxL8+v5+eXmBvwCRCGj9t8dpvZWvEzylI9h5ohJVtwKG6ndmuoFQCdnbOy/A lvpyJXM/p8oYzDFWb7q82+v21tVKJZp3reWIW3CX8jbLVgSoi5+ilp2ZkRpOqhZn/zpDwv vzrFoT2VGbmDmXljOX1kmExv0gq5sB7mNg96GKsP+eNXE+nkwrH5xVpbZod21EVLOXkTCQ svbzAXMMX6kEngxnipHcSJCjlSJ9bRN96U6rCHL78sgEcDa7RBmyRlGj5G1WALBbVQXAPK 0qkcQxre0I74pTIQ7axThjzBrz8FgTgl+qHXxvmDXkVyhD1y1eHiNzPGqKKpNg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPXk360fHzCWJ for ; Mon, 02 Mar 2026 08:52:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 21594 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 08:52:11 +0000 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=B8rg?=rav Subject: git: fe5341287c6c - main - diff3: Produce correct exit status List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: fe5341287c6c9bacc18879b25ed72ceb42e1c811 Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 08:52:11 +0000 Message-Id: <69a54fbb.21594.1713b21f@gitrepo.freebsd.org> The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=fe5341287c6c9bacc18879b25ed72ceb42e1c811 commit fe5341287c6c9bacc18879b25ed72ceb42e1c811 Author: Dag-Erling Smørgrav AuthorDate: 2026-03-02 08:52:06 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2026-03-02 08:52:06 +0000 diff3: Produce correct exit status Use exit status 2 for errors, 1 only to indicate that differences were found between the inputs (in some operating modes). MFC after: 1 week Sponsored by: Klara, Inc. Reviewed by: ngie, bapt Differential Revision: https://reviews.freebsd.org/D55608 --- usr.bin/diff3/diff3.1 | 17 ++++++++++++++++- usr.bin/diff3/diff3.c | 26 +++++++++++++------------- 2 files changed, 29 insertions(+), 14 deletions(-) diff --git a/usr.bin/diff3/diff3.1 b/usr.bin/diff3/diff3.1 index 9286a79e6ec6..8ca2d9f853af 100644 --- a/usr.bin/diff3/diff3.1 +++ b/usr.bin/diff3/diff3.1 @@ -27,7 +27,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd June 23, 2022 +.Dd March 1, 2026 .Dt DIFF3 1 .Os .Sh NAME @@ -196,6 +196,21 @@ The lines beneath this notation are ranges of lines which are exclusively different in file .Va n . .El +.Sh EXIT STATUS +The +.Nm +utility exits with a status of 0 on success +and >1 if an error occurred. +Additionally, if the +.Fl A , +.Fl E , +.Fl L , +.Fl m , +or +.Fl X +flags were specified, +it exits with a status of 1 if conflicts were found. +.El .Sh SEE ALSO .Xr diff 1 , .Xr ed 1 , diff --git a/usr.bin/diff3/diff3.c b/usr.bin/diff3/diff3.c index fce4d353af69..0f114163321f 100644 --- a/usr.bin/diff3/diff3.c +++ b/usr.bin/diff3/diff3.c @@ -202,7 +202,7 @@ strtoi(char *str, char **end) if ((end != NULL && *end == str) || num < 0 || num > INT_MAX || errno == EINVAL || errno == ERANGE) - err(1, "error in diff output"); + err(2, "error in diff output"); return (int)num; } @@ -267,7 +267,7 @@ readin(int fd, struct diff **dd) if (*p == ',') d = strtoi(p + 1, &p); if (*p != '\n') - errx(1, "error in diff output"); + errx(2, "error in diff output"); if (kind == 'a') a++; else if (kind == 'c') @@ -275,11 +275,11 @@ readin(int fd, struct diff **dd) else if (kind == 'd') c++; else - errx(1, "error in diff output"); + errx(2, "error in diff output"); b++; d++; if (b < a || d < c) - errx(1, "error in diff output"); + errx(2, "error in diff output"); (*dd)[i].old.from = a; (*dd)[i].old.to = b; (*dd)[i].new.from = c; @@ -287,7 +287,7 @@ readin(int fd, struct diff **dd) if (i > 0) { if ((*dd)[i].old.from < (*dd)[i - 1].old.to || (*dd)[i].new.from < (*dd)[i - 1].new.to) - errx(1, "diff output out of order"); + errx(2, "diff output out of order"); } } if (i > 0) { @@ -564,7 +564,7 @@ skip(int i, int from, const char *pr) for (n = 0; cline[i] < from - 1; n += j) { if ((line = get_line(fp[i], &j)) == NULL) - errx(1, "logic error"); + errx(2, "logic error"); if (pr != NULL) printf("%s%s", Tflag == 1 ? "\t" : pr, line); cline[i]++; @@ -595,7 +595,7 @@ duplicate(struct range *r1, struct range *r2) if (c == -1 && d == -1) break; if (c == -1 || d == -1) - errx(1, "logic error"); + errx(2, "logic error"); nchar++; if (c != d) { repos(nchar); @@ -652,7 +652,7 @@ printrange(FILE *p, struct range *r) return; if (r->from > r->to) - errx(1, "invalid print range"); + errx(2, "invalid print range"); /* * XXX-THJ: We read through all of the file for each range printed. @@ -900,27 +900,27 @@ increase(void) p = reallocarray(d13, newsz, sizeof(*p)); if (p == NULL) - err(1, NULL); + err(2, NULL); memset(p + szchanges, 0, incr * sizeof(*p)); d13 = p; p = reallocarray(d23, newsz, sizeof(*p)); if (p == NULL) - err(1, NULL); + err(2, NULL); memset(p + szchanges, 0, incr * sizeof(*p)); d23 = p; p = reallocarray(de, newsz, sizeof(*p)); if (p == NULL) - err(1, NULL); + err(2, NULL); memset(p + szchanges, 0, incr * sizeof(*p)); de = p; q = reallocarray(overlap, newsz, 1); if (q == NULL) - err(1, NULL); + err(2, NULL); memset(q + szchanges, 0, incr * 1); overlap = q; s = reallocarray(de_delta, newsz, sizeof(*s)); if (s == NULL) - err(1, NULL); + err(2, NULL); memset(s + szchanges, 0, incr * sizeof(*s)); de_delta = s; szchanges = newsz; From nobody Mon Mar 2 11:15:36 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPbvX2mbVz6TGwc for ; Mon, 02 Mar 2026 11: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPbvX1pnTz3GX5 for ; Mon, 02 Mar 2026 11: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=1772450136; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WZcPd1XBDp5erzfRGHP4oQRMVNCpF5eByrkW8PffRP4=; b=qdszbrVwpL7uu9K5Ee0rW5GV3cAiBEneuy8SRrvxfUdEQzx+mrbdOc/66s0v8czGtJWZbx 7j0Cl3EMGETJtv8lTK9z45siZoPjV0c3B0MGv/tekN4C6vtuLTHb4HfgOwABZtlfaB043X 8+vVpTJkx1VN+R1o4F02LcR+aBGUdl4Kfy1SA/6Nex6MYmPbi+ZT0XrnO7UY0KHJ2GKfPV 66QizEIpwwqFZl+cqeGQa4ww9YKRz5hMkRqxB7TwbJvhca2WpvePJSIVS2Y1oTlQtW/4Rb WjwGze4qkkwGI+i98ErdXfc8rTDfTpmTY2n42tL8zivHFfn+mqWGXWW0FHoSUQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772450136; a=rsa-sha256; cv=none; b=q71z0z8qAfvSVPjQVSNs+4cv1hrGem7ukWrgLc8rtKT/6BzkJj4YZShrzxq9R77kwucXU8 bNwmn3FpbJqE0x+t6vp6RSvxpXOX9YSFu/Lm9JRoOXngvF4CnKotETL8eZ5e9q199Lns7n zifeu9jt9HMcjW+3ii9AgnkAzyTfXhnOvprLRhV0pmo1yrq336x5Af85eX0/RLKRpBP7U4 sg+Vh8HdMPwJFdDJg5rb7jvbYABwIHXhva2uTJBS8qv56aeScDblOM5iEbrkHHA1Q54rBO G8bTrP3yQOm7CY6sBIzVdNQihhNK9ng56CSe/76e//IWwUTJI2ExeP8kO0KoAg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772450136; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WZcPd1XBDp5erzfRGHP4oQRMVNCpF5eByrkW8PffRP4=; b=K90NvBA02MmNydwE+tjUOZGcpPH4cJPElv5IwaAL5547AuGo5sWmo5mzyhyudcqCsmP4Dh hZXjpoDYYHtYv+ux3+UVjU5X4eq49G+LSRK6qIVbHfFa89x9PcPmHVXgxzKYqCzbYe1pcr nKtD2yyKWfSjCEqC64tCQbBK8KWg3GypHASocr3CqS1yOFAYEQMOnQLaahX73MwWJxQWnN /sTImSMcHqFFTwGGFJgd/K59HgxrFzVFlu9UsS1djwAs9t89Ff6+YRavFIsvnLER0EO2EZ BclVDpoLG7IlZXQ7jpJmevBfXFjYxi1crXhMuyRPAppcE6eGnj/GPktDruBbog== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPbvX19zzzYPP for ; Mon, 02 Mar 2026 11:15:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3743b by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 11:15:36 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alexander Ziaee Subject: git: fae551b76785 - main - style.mdoc: Li macro is undeprecated for some time List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: fae551b76785d2357b09e2c022a92f410d871b9b Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 11:15:36 +0000 Message-Id: <69a57158.3743b.4cbf6eed@gitrepo.freebsd.org> The branch main has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=fae551b76785d2357b09e2c022a92f410d871b9b commit fae551b76785d2357b09e2c022a92f410d871b9b Author: Alexander Ziaee AuthorDate: 2026-03-02 10:20:01 +0000 Commit: Alexander Ziaee CommitDate: 2026-03-02 10:54:26 +0000 style.mdoc: Li macro is undeprecated for some time Previously, the mdoc linter warned against using Li as it was deprecated upstream. However, upstream undeprecated it since last year. As usual when it comes to style, the best thing to do is to follow the existing style of the page. We have many manuals which prefer double quotes. MFC after: 3 days Citation: https://cvsweb.bsd.lv/mandoc/mdoc.7?rev=1.297 Differential Revision: https://reviews.freebsd.org/D55297 --- share/man/man5/style.mdoc.5 | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/share/man/man5/style.mdoc.5 b/share/man/man5/style.mdoc.5 index 98cc516ffd64..e0c41915ecb1 100644 --- a/share/man/man5/style.mdoc.5 +++ b/share/man/man5/style.mdoc.5 @@ -3,7 +3,7 @@ .\" .\" SPDX-License-Identifier: BSD-2-Clause .\" -.Dd October 24, 2025 +.Dd February 16, 2025 .Dt STYLE.MDOC 5 .Os .Sh NAME @@ -41,14 +41,6 @@ which renders as: Then run .Ql Nm make Cm install Cm clean . .Ed -.It -The -.Sy \&Ql -macro is the preferred macro for formatting literal inline fragments. -Historically, -.Sy \&Dq \&Li -was the preferred way before the deprecation of -.Sy \&Li . .El .Ss Copyright Header Refer to From nobody Mon Mar 2 11:15:37 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPbvY5vdZz6TGrl for ; Mon, 02 Mar 2026 11:15: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPbvY3C24z3GMy for ; Mon, 02 Mar 2026 11:15:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772450137; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cU5aUEfeimkhIK+oA4oJqg7VddlcNGpjY/3jIUSHrlY=; b=pYZ6UVBad/PpQJq3F17ZzK3F7kNMwRwTLokFzSKQPiVMIDRhWSHb1XUXkE7jheOTPEx9Bc 8WV0IYWgLGsLKWHv3HZKLSaMALxeLnSkaqTiHNsa/P7L8Ex4IR1k8Yn8l46qu5q9NpNuaL WCIYJjkAH3d4ERc4e53igcKjFySQ9xfFUmlPtI/LGnpjC7dVEfho9mc5JemoeP8EI/t+vE pjOiL8zeqW1WPV70ZHmTjVYhAtIjn9khY/cutR9ML/402C5RmZGUWgoamjVkN3jxU5XC7l j3NUOMdW+tHle6iut4dsfnh74g5Bi+8lteyq6Kd0d6TvZSwrHuyfQGPUs2mYmg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772450137; a=rsa-sha256; cv=none; b=c7Fa8foQ9ayN+T0YuBOgY2RwULfPQ0jbyD4vYE80hjZqDHGOmAy8FyUIQ6IBhwieBNQsvT Ud5aPAJoURSP2dLHTUhGa/W7EA/+bSEYGtMfI87WApxVZ/JHBeuq0cJidYUx0I2oTeUp+9 lPG2FKxEOkXbQHEL58fyOab99H0m6xQ8dGcZh/vMLSOHzx1baWLBf3udB/UKOTzfoyQ/Up bNEZ2pGZ01/KF5N35Uh3KWhP5qQ0dpUNPDyoFWnfz1vdjZ274ArMc6GHsY5FVgwGDOHJyz aszL71JUzCdHTUuZp4lVg4OtLj6S+EPAJgLGbl5kagRLvQZl8dGFqDtFv+JvfQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772450137; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cU5aUEfeimkhIK+oA4oJqg7VddlcNGpjY/3jIUSHrlY=; b=SglDzhkSWNnVglAp9SuC1hXsFlNjhFOsmEwJ2WwAenIgKojwNq1BmdRltoZ/GA99QEG5pS VzLicNpBCzy9rBnzFYb+q26U/+Sy2PkugkGCrhwSQYw/NG7uiFEZYqgD6VnmfK3BNd7gHl s0CPXuUj9Af/gCzyiYY2QMv7XmQ6/EtbG1o2yFcBL9Rg1del58S7FGyIh1e7XQo34kzsIY 41Ac2HO2eKk5ums3BWZjPvpVMOW3tzQJOWy5R3ChRtQ5FP9nL2w5DMJWt9CWpIn4u5kO8f zQTxEtzIP6WgcmQc8tOpB8OxvdSm5MGFIWURcL9EteThC0VeSCM60hAud2A14w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPbvY1zhDzYqD for ; Mon, 02 Mar 2026 11:15:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 368da by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 11:15:37 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alexander Ziaee Subject: git: 47326cb47027 - main - style.mdoc: Remove synopsis formatting advice List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 47326cb470278e891975354286481b5ba876929a Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 11:15:37 +0000 Message-Id: <69a57159.368da.4c403145@gitrepo.freebsd.org> The branch main has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=47326cb470278e891975354286481b5ba876929a commit 47326cb470278e891975354286481b5ba876929a Author: Alexander Ziaee AuthorDate: 2026-03-02 10:24:11 +0000 Commit: Alexander Ziaee CommitDate: 2026-03-02 11:10:21 +0000 style.mdoc: Remove synopsis formatting advice Remove incorrect advice. The first rule was no spaces padding pipes when showing alternates. Almost universally we not do this, and third party manuals do not either. The second was using Cm to mark up symbols. This advice is in conflict with mdoc(7), and the extended documentation on mdoc linked below, which is also linked at the bottom of mdoc(7). Conflicting information in our docs is a natural result of documentation proliferation. The most important thing we can do to reduce technical debt in the documentation is reduce the amount of doc overlap. Excessive technical debt and conflicting rules is a barrier to new contributors. This type of work requires thorough expertise, is not glamorous at all, and to add insult to injury, is socially unsafe. To get new contributors to the docs project, we must deduplicate documentation. We have the mdoc manual, examples/mdoc, style.mdoc, and the fdp chapter on manual pages. With this many, they will inevitably come to contain conflicting information, and people will learn not to read them or work on them. MFC after: 3 days Ref: https://mandoc.bsd.lv/mdoc/style/commands.html Differential Revision: https://reviews.freebsd.org/D55298 --- share/man/man5/style.mdoc.5 | 67 --------------------------------------------- 1 file changed, 67 deletions(-) diff --git a/share/man/man5/style.mdoc.5 b/share/man/man5/style.mdoc.5 index e0c41915ecb1..84eb281dc76a 100644 --- a/share/man/man5/style.mdoc.5 +++ b/share/man/man5/style.mdoc.5 @@ -152,73 +152,6 @@ Install the missing packages. \&.El .Ed .El -.Ss Synopsis Formatting -.Bl -dash -width "" -.It -Do not put whitespace between alternative parameters separated with a pipe -.Pq Dq | , -e.g.: -.Bd -literal -offset indent -\&.Cm compression Cm on Ns | Ns Cm off -\&.Cm install Fl -all Ns | Ns Ar portname Ar ... -.Ed -.Pp -which in the SYNOPSIS section is rendered as: -.Bd -unfilled -offset indent -.Cm compression Cm on Ns | Ns Cm off -.Cm install Fl -all Ns | Ns Ar portname Ar ... -.Ed -.It -Use -.Sy \&Cm -to stylize characters that are command modifiers -.Po e.g., -.Dq \&, , -.Dq @ -or -.Dq "=" -.Pc . -For example: -.Bd -literal -offset indent -\&.Sm off -\&.Fl -meet Cm = Ar who Oo Cm \&, Ar who " " Ar "..." Oc Cm @ Ar where -\&.Sm on -.Ed -.Pp -which renders as: -.Bd -filled -offset indent -.Sm off -.Fl -meet Cm = Ar who Oo Cm \&, Ar who " " Ar "..." Oc Cm @ Ar where -.Sm on -.Ed -.Pp -instead of: -.Bd -literal -offset indent -\&.Sm off -\&.Fl -meet No = Ar who Oo , Ar who " " Ar "..." Oc @ Ar where -\&.Sm on -.Ed -.Pp -which would render as: -.Bd -filled -offset indent -.Sm off -.Fl -meet No = Ar who Oo , Ar who " " Ar "..." Oc @ Ar where -.Sm on -.Ed -.Pp -It is important to realize that in the correct example, -.Dq \&, , -.Dq @ -and -.Dq = -are stylized with -.Sy \&Cm . -At the same time, the square brackets -.Pq Dq "[]" -are not stylized as they do not belong to the syntax of the -.Fl -meet -flag. -.El .Ss Quoting .Bl -dash -width "" .It From nobody Mon Mar 2 11:15:38 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPbvZ5wMKz6TGL1 for ; Mon, 02 Mar 2026 11:15: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPbvZ3NdHz3Gq7 for ; Mon, 02 Mar 2026 11:15:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772450138; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ahncSqpGVDI6Gz0gL0m6Je5rHXeSlS/1c7o+IM8ZdaM=; b=aZTdauErxhKaEQlyfmoM5hbbm7SXrL9W1d7bjd378GGFhbCGMwo5qJdbNhBw4A+BL0yF99 q4kuRibxIAwqlvlyKnAyo+WAABYR++iw0re6He8yQZ3ErCHm5enIsndXPlzImWd8/50amE gId39uEpY6G9xFKDWkALLX1GydJYSWzyJ8yjdp1wkH+SloeLpLUCrgVuFwcPU9QYJ2yKNl 568qD1pNruDFDtLa5LU2HqIVzcV1OZT8jUHeQ+qMLveO1F1iVVaF/FicTYAojEiHLTNfQx QIUwGnI/yL2OjleaOBSd0TNDwfpsfEef2L8jeXJxseumE1wV8TUDDVOdEpYRdQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772450138; a=rsa-sha256; cv=none; b=podLe4wW9WCZZCzCntDppeck0MhVoeYq9mw8K5L8/HhpIYnkc1u0Sp3TxbyP/7eTE6DD5x WPqfLwvBysqZrLUbJ6aQRVVHmNQwDVg1jfPTwvqaFyYFMAbDkf3pce/n3fw2kvLpkhCWss Fvk6O8HrlxrAYIOinL5eyuCj4wK8ecnuHyDy7lbqbgP4uTYrALDhPKONgPElp5XI5Ft+ho kulCKa26y4gP96UUK2fogHcqEmEL6clm0cXtuU0XxuTgMoWXCfn/GK09waTBk+FN+MBKwz 2ciieBDbNWH6gbqN5VHxL88HhnSFbqxACSekeEfgenyDuYihD404p+p20QSjfQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772450138; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ahncSqpGVDI6Gz0gL0m6Je5rHXeSlS/1c7o+IM8ZdaM=; b=krHCP6tQWC8b9C7WjJhbXevZWWyomBIU7b6joaOE5azvAfKbzViCPBqM+0K+Qah3LNRa/v nFm1OOypLfvqZR9+bHMJo6+NQRgk+19LunVwOwzqXcMq+loyoSK6W71VOYNrDmSgWThF0e 0/VU3lifQlN7gUKb+vmOJiyHlh83OFcAG0U4YErxKANO8b3OMPJw49L26UPhgKb/iSiPDK aX032hC/7I5vRayETOd5f3L9+E528yk91l9kMjeE5hLaS1lxu+hCeruoU4lriKPL43oFJ+ CgEHbZ2kpi7VdBfntuSEC0q3tjyqMfbnR3u01BAZxxaVTUk9OS4NWLSa6JK8fw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPbvZ2lJgzYqF for ; Mon, 02 Mar 2026 11:15:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 374df by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 11:15:38 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alexander Ziaee Subject: git: 06ac71cffba4 - main - style.mdoc: Left angle bracket is not less-than List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 06ac71cffba4a0f86334844453d0a6fb3c46aa12 Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 11:15:38 +0000 Message-Id: <69a5715a.374df.7449640@gitrepo.freebsd.org> The branch main has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=06ac71cffba4a0f86334844453d0a6fb3c46aa12 commit 06ac71cffba4a0f86334844453d0a6fb3c46aa12 Author: Alexander Ziaee AuthorDate: 2026-03-02 10:41:07 +0000 Commit: Alexander Ziaee CommitDate: 2026-03-02 11:14:13 +0000 style.mdoc: Left angle bracket is not less-than MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D55300 --- share/man/man5/style.mdoc.5 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man5/style.mdoc.5 b/share/man/man5/style.mdoc.5 index 84eb281dc76a..64e2291d1c75 100644 --- a/share/man/man5/style.mdoc.5 +++ b/share/man/man5/style.mdoc.5 @@ -183,7 +183,7 @@ variables like .It Use the angle brackets .Sy \&Aq -.Pq Dq "<>" +.Pq Dq Ao Ac macro for arguments .Pq Sy \&Ar From nobody Mon Mar 2 15:32:19 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPjbl5jXSz6SqKD for ; Mon, 02 Mar 2026 15:32: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPjbl3NZnz3l3s for ; Mon, 02 Mar 2026 15:32:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772465539; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jCxbttVpLOvOKtxuCm111wNR1J/w/wgtGoYXUPZThss=; b=QhElGsPvnGww3Vtv901nqKx3TqiUIafh6ltQVIhFFumGJSRFgSLuGyDq1qPpAd9dBDQC68 GtkhiN89DXeZmHiS8TgIkFSIMPCh6GosL2N2hL0F3eWsSm12XNL51ii9tjpVXK2aw4qOB+ VFxwoqdsQnh+xFYh5Us3chkap2ob2HWIkl+D3A7crmJ2yLD6xeabdZYt/PwVFIDg3Xxzyv QHlxDrCVSlrlgVFo6/nybCNFiDnDYaZQjFDzEBMLQNMGC/VXtJO4rz5+S+NNsqTMZZ2ybR 0I/mmovVbVi5I2C4HyXlhqe/ILqBhofVFzSxb8vMfeXXr55necYvW+MoFgOClw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772465539; a=rsa-sha256; cv=none; b=sRHl70EqxrCaIAq4gP/CK2225jAe2BVpZaNyTtk3MtXLu6ebqIUrcFHW80rIu4N8CoTtqK wfVZxK36Xd3vG6ITCzvwxsQj0/KN/+RUmlXH5IDU4K0ZyvgbCJR3C/UQYCAcqsuK0TNVGj laHZ7I9EKEckFRiBAiEm+nLEwKBm76GzWBTB1ziW7odrZzXHIJWx4PhtO+TNPr//vN2To8 A3TXqzz6stR3Yq0dZ4L1ePtgiBh0RIv4GncCnlP9BnnJWsIdoCq/hwShX+5AHsIDj4M1up LrQP5BMwrpUTYOpBwenNiG7Qttg4W8E/rU0bCa3NrSx9RSZ3EkKpBCAitNaKKw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772465539; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jCxbttVpLOvOKtxuCm111wNR1J/w/wgtGoYXUPZThss=; b=IKZ7Vd0XdXyRapzkHVbg05F95XoKsII/FURm8oPBwQxdH/YNhZn6RePMf95YB5CibmxVoL 3BHEtx+2qoQjpl0ETTvWMIMpUByRVjIzJQCJh1dHc6qdQlB959nzoD9GIhOHKeniXFlRoB erIygfag8cPHn8v21xIDcpOFz0gcBMAiyQ9VDHYR0lHwjISr25yd44IJeLYCt8G0E/LJME GtkiQAtiFsXo17+fDgWYd3tQ4ce2wluMg8qwXqSdDT2ai+b8AsliSRRQDt5NUS9cNnBIWn 6ns5fqqgHOrE0UQaHvL0s4Q+XS2cQjSTbwDHQTRuJHeLzkvRRTVIFpmYzDeo9w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPjbl271fzgt2 for ; Mon, 02 Mar 2026 15:32:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 33e8b by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 15:32:19 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Pouria Mousavizadeh Tehrani Subject: git: b55bffeaaf9b - main - netinet6: Fix memory leak on auto_linklocal List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pouria X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b55bffeaaf9bae5dc7aa21eae441d89c999ebab8 Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 15:32:19 +0000 Message-Id: <69a5ad83.33e8b.5a67b99f@gitrepo.freebsd.org> The branch main has been updated by pouria: URL: https://cgit.FreeBSD.org/src/commit/?id=b55bffeaaf9bae5dc7aa21eae441d89c999ebab8 commit b55bffeaaf9bae5dc7aa21eae441d89c999ebab8 Author: Pouria Mousavizadeh Tehrani AuthorDate: 2026-03-02 15:24:23 +0000 Commit: Pouria Mousavizadeh Tehrani CommitDate: 2026-03-02 15:25:23 +0000 netinet6: Fix memory leak on auto_linklocal release the refcount of link-local prefix information to ensure it gets freed when the address is deleted. Reviewed By: zlei, ivy MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D55593 --- sys/netinet6/in6_ifattach.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netinet6/in6_ifattach.c b/sys/netinet6/in6_ifattach.c index a952192b6b62..237fb7ecfd44 100644 --- a/sys/netinet6/in6_ifattach.c +++ b/sys/netinet6/in6_ifattach.c @@ -630,8 +630,8 @@ in6_ifattach_linklocal(struct ifnet *ifp, struct ifnet *altifp) /* Reference prefix */ ia->ia6_ndpr = pr; pr->ndpr_addrcnt++; - } else - nd6_prefix_rele(pr); + } + nd6_prefix_rele(pr); return 0; } From nobody Mon Mar 2 15:42:22 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPjqM6FYcz6SrPX; Mon, 02 Mar 2026 15:42:23 +0000 (UTC) (envelope-from jhb@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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPjqM5fSlz3mCK; Mon, 02 Mar 2026 15:42:23 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772466143; 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=CZa6IP31DbDdzS5SUAG4O3KhrPu9txwPgFr5fCbSi6U=; b=ZQOst4ouC6Jz6lGkRRBKSYEoqbBUiIlezIVKp0i8C2iJUb4hMEavL9IZa8gBCoojkJWZ3L WSzs/5wdW92cjvxIYlAqA6WDiykMRksTTf3GXa/NHirIt1Imtk3m1H8Lz9NWMt84zhO1WQ B/K0C40rr6+ffyt+BDm+Yrvptu6qJUidMepHSpVBJ5vOfInNJdXlozp9i9b/5fR8LqL2Dd c15T9PxASvmmkqCdchlV5tUH79k3YuVMtTaUiOszMyOk04HBns833Uo/gkNo4taeuwTE7p xy1wiKLlz3ARETzCDvQ8kodEoA3818DJSQLgIrf7EZIpoPdoOzvGpRXj1SvTEA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772466143; a=rsa-sha256; cv=none; b=bRpvLNORyarFjNrPzQzS2MDFSH6KkFfCoFXqNJnMdycMCEKLORX9f6sdbBFgTwPOcF6ZHk zZ91CNIF6cLj8IFLHzOP1t1pISAzLSKm4VnGRIh2Y86CqOas62DYlwFKfoa2RrWRvMy20J TcBhkP9z64MtfpCMXfcDRwEMuUpnl9LwehhhdFQ+Je0BqaHVGF0MaA4ScngYWTv1+vj9GU ntFQPPiNX2O/R2A+dDFfCC39YjE/oUkZpouPaTyUMWes0LQuIUEPtXhU4Ry8Dv9Xnc7ks0 DV7wMjq0u5PBiWbsq7tPWNJZPffxFBNF78kj3ghq5FRQGikJzU89oZkRbVuk6w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772466143; 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=CZa6IP31DbDdzS5SUAG4O3KhrPu9txwPgFr5fCbSi6U=; b=HcPjLnKU8KoJzRuJyv+5H2pCmDtWc8LIUOPNAPQuxOCVDUsxq8nyR0vm1rcjDW/yPURbJq FIzaEsxke8VnzG2FarZZEW3cBJTeMxrMFInETIWHmkoLiilsyJ+3u87Gi6eAwspc55D6qr qfnfaj5wAijaBC3/6/oDdvE9lI2y1Yo+2pANJTogvyA4ts+0YNcolJekpw31IT+0aRf6cG f3XhAYfo9+RoFgaoSTt0SJ3G0BBMYe5sUp+qhNtVrYk0BktslLMX+BDq0DaNOl8YJ9Hr3I lcKnRGAvmJZ+DhQyDyfkK7QwiXLynkPtm1p33o0DM7A7XvrtvQ+gxOJ0GShvog== Received: from [IPV6:2601:5c0:4202:5670:937:93a7:f96c:e50a] (unknown [IPv6:2601:5c0:4202:5670:937:93a7:f96c:e50a]) (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: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4fPjqM3gqfz16Nw; Mon, 02 Mar 2026 15:42:23 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: Date: Mon, 2 Mar 2026 10:42:22 -0500 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: ee73475119ff - main - llvm: Link private LLVM libraries against compiler_rt for aarch64 Content-Language: en-US To: Mark Millard , Jessica Clarke Cc: "dev-commits-src-all@freebsd.org" , "dev-commits-src-main@freebsd.org" , Andrew Turner References: <698a0b1e.1d294.40e36519@gitrepo.freebsd.org> <23acebb1-f71c-46e6-9eea-3fa44316335d@FreeBSD.org> <720e4cb6-fd13-4686-93d9-ef095ad611c2@yahoo.com> <4514bc7c-49c0-46af-b67a-3e4565a7e8cd@yahoo.com> From: John Baldwin In-Reply-To: <4514bc7c-49c0-46af-b67a-3e4565a7e8cd@yahoo.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 2/27/26 17:01, Mark Millard wrote: > On 2/27/26 13:24, John Baldwin wrote: >> On 2/27/26 15:55, Mark Millard wrote: >>> On 2/27/26 09:27, John Baldwin wrote: >>>> On 2/9/26 11:47, John Baldwin wrote: >>>>> On 2/9/26 11:40, Jessica Clarke wrote: >>>>>> On 9 Feb 2026, at 16:28, John Baldwin wrote: >>>>>>> >>>>>>> The branch main has been updated by jhb: >>>>>>> >>>>>>> URL: https://cgit.FreeBSD.org/src/commit/? >>>>>>> id=ee73475119ff7aa98bd11828625d524f6ab87f06 >>>>>>> >>>>>>> commit ee73475119ff7aa98bd11828625d524f6ab87f06 >>>>>>> Author:     John Baldwin >>>>>>> AuthorDate: 2026-02-09 16:26:52 +0000 >>>>>>> Commit:     John Baldwin >>>>>>> CommitDate: 2026-02-09 16:26:52 +0000 >>>>>>> >>>>>>>       llvm: Link private LLVM libraries against compiler_rt for >>>>>>> aarch64 >>>>>>> >>>>>>>       This is required for GCC which uses libcalls for outlined >>>>>>> atomics. >>>>>> >>>>>> This doesn’t seem right, they’re provided by libgcc.a, so why aren’t >>>>>> they being pulled in? libcompiler_rt.a doesn’t even have the symbols. >>>>> >>>>> My guess is that we don't link libraries against libgcc by default, >>>>> only >>>>> binaries (maybe this is a GCC feature/bug vs clang)?  I have another >>>>> review >>>>> open for a couple of google test libraries which similarly fail to >>>>> link. >>>> >>>> So after some more digging (along with Jessica), it seems that GCC only >>>> uses -lgcc_s (and not -lgcc) for C++ (but not C) on both Linux and >>>> FreeBSD. >>>> clang's FreeBSD toolchain driver is supposed to mimic GCC but >>>> doesn't, it >>>> applies the C rules even for C++ linking, so clang is implicitly adding >>>> both -lgcc and -lgcc_s for C++. >>>> >>>> On Linux, libgcc.so is a linker script that includes both the dynamic >>>> library and -lgcc which is how the static libgcc (including outline >>>> atomics >>>> for aarch64) is effectively linked into C++ shared libraries on Linux. >>>> (Note: libgcc.so is a linker script on seemingly all arches on Linux, >>>> not >>>> just aarch64) >>>> >>>> So I think we have a couple of choices here.  I can patch the devel/ >>>> freebsd-gccN >>>> ports to stop passing -shared-libgcc to cc1plus which will cause GCC to >>>> follow >>>> the same rules as clang on FreeBSD (passing -lgcc -as-needed -lgcc_s - >>>> no-as-needed >>>> instead of -lgcc_s), or we could change libgcc.so to be a linker script >>>> to match >>>> Linux (and then eventually fix the FreeBSD driver in clang to only pass >>>> -lgcc_s for C++ linking) (I think Andrew already has a review to make >>>> libgcc.so >>>> a linker script). >>>> >>>> I can see arguments both ways.  Using a linker script seems kind of dumb >>>> given >>>> all the hoops GCC goes to internally to decide whether or not to link >>>> only >>>> shared or static or both.  (Esp given libgcc is in theory part of the >>>> compiler, >>>> so the compiler should know that libgcc_s should depend on libgcc and be >>>> able >>>> to encode that in the default drivers.)  OTOH, the linker script >>>> approach would >>>> mean we would more closely align with Linux.  I think Jess favors >>>> patching GCC. >>>> Does anyone else have any strong opinions? >>>> >>> >>> Is the question limited to devel/freebsd-gcc* ? Or does it span >>> lang/gcc* use as well? >> >> We don't really support building the base system with lang/gcc* >> (it's why devel/freebsd-gcc* exist) as the base system builds require >> various changes like kernel printf support, defaulting to libc++, etc. >> > > > Likely more food for thought than you were originally trying to deal > with for aarch64 contexts. I was not trying to indicate that any > devel/freebsd-gcc* commit vs. lang/gcc* commit would/should be the same > commit. More like . . . > > Are all of the potentially involved linking issues/techniques limited to > that aarch64 system context and the use of devel/freebsd-gcc* ? Or are > there, for example, "uses libcalls for outlined atomics" issues also for > lang/gcc* g++* use, especially when it is told to use -stdlib=libc++ > ( the system libc++ ) instead of using libstdc++ ? Do any issues and > techniques generalize beyond devel/freebsd-gcc* use in any meaningful way? > > Even without committing anything for lang/gcc* , notes might prove > useful later for someone, depending on the answers to the above. In the case of googletest and the LLVM libraries, the undefined symbols for atomics weren't in libc++, so I think you would have the same problem if you used lang/gccX to build googletest or llvm in ports using USE_GCC=yes or the like on aarch64. You also might have the problem on RISC-V for builtins where clang tends to inline operations more often than GCC which tends to invoke libcalls. Note that the GCC behavior is not specific to aarch64. In g++specs.cc it defaults to passing --shared-libgcc to the backend on all platforms that support the option unless an explicit --static-libgcc is specified on the command line to g++. For C, it only passes --shared-gcc by default if an ObjC object file is specified as an input to the linker. -- John Baldwin From nobody Mon Mar 2 18:10:52 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPn6n6PNRz6T2Wr for ; Mon, 02 Mar 2026 18:10: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPn6n3sNVz42lg for ; Mon, 02 Mar 2026 18:10:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772475057; 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; bh=4IzzrR9oDWnRG++AecYUjwecmwiz18dGVDxTNc5T+xs=; b=daY6q7KhyU1nKn0ZeBzVo+0oZQr2cfimdl/tvb9PdeuNqvbLhBBdahmor0OxgpuJljptNl +1vuosKVyUZY1N8+2W1e8DPcZPbKnEY0wPio1kUFUtIn7HZZtmKfU16DP9TLwNQ+LHoHfQ Zc10OVMQsidvJscTlxSxvWVCMnVHots+AZ3wpbTKbvBDgP15cs2FzxTQrBU/CsPp4V7QZ8 ajy8ZJpJHSmC2ugGws1BxnhzAF161RhCPUy3PthtVItBP9riNROfyjQMuHpSseusKPVsTx zILZmPwmCkc1He9cOr9rHaA7WWkL0k9RL/tsrlZKqoKqLaPrDDArFHheBl//Lw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772475057; a=rsa-sha256; cv=none; b=L5Frl9cHRgRw2u5d+OPkrqkoU/3tbSTbEQNcD9IR1r0y8CrBuen6kZW8Tbz8/F5AfP0KhA plDiSCghBU7W4WEVOovhvQleNfItHCtXSCgIk/gZHu+2sa2M5dl+vcYQujdLrbN5SyMHhC mLW7i1zficd/lA2S3jMWi2hFzaXPX0R5AQTGKXLD/zL4+STfBo9bqWEMLv5Ysjh31Y31nj YN1SmfzDEVc8Uuc0X0wT5G619748jzCO20iSw+AhcwDyIxv0e70Ze/298GNcenMefoU+s9 QHV94oupUvpUay7co+Inm14M5XAgpcIrgYLOIZNujiL0A97h0+qfjOl5qm8w/g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772475057; 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; bh=4IzzrR9oDWnRG++AecYUjwecmwiz18dGVDxTNc5T+xs=; b=c9155tK7A/Ncru3Ldw/eThGi3JBa1pqJvUrKJsZcoxiA5Fo5LqJmGStNV+DNfvLfD2OD0F fzxQQca+SP9eSbcZ3KBhkQseByToJHFCrmtJQgxbUIsFXENk8omLlXI3gmkeZkeHZXiaVc HFzYX4lrzxJtYZXJB1s4eGIhF2UKfXYv+XoxXUXwHjZ22kyZaCKWJ6b2XM4/yNUqMrpX45 3GHExQG/a5SWUfeV7nfpyQJs9DlK5CMTqtziJmE1hvN4nOrfnIs2MTkkwR5xUnzIMujWiH Srwa2Bg6L/8Tf0MFFnPm6ANsJYq4xK5RAkeXlRTqhS7ahMVrTudkFk/BdrYVHg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPn6n2zfxzmNg for ; Mon, 02 Mar 2026 18:10:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 432e0 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 18:10:52 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Timo =?utf-8?Q?V=C3=B6lker?= From: Michael Tuexen Subject: git: 0272359ada14 - main - arm64/pmap: fix pmap_is_valid_memattr() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 0272359ada144aa540c28fefaf996afa30dc0aa5 Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 18:10:52 +0000 Message-Id: <69a5d2ac.432e0.50b47cad@gitrepo.freebsd.org> The branch main has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=0272359ada144aa540c28fefaf996afa30dc0aa5 commit 0272359ada144aa540c28fefaf996afa30dc0aa5 Author: Timo Völker AuthorDate: 2026-03-02 17:59:45 +0000 Commit: Michael Tuexen CommitDate: 2026-03-02 17:59:45 +0000 arm64/pmap: fix pmap_is_valid_memattr() The function pmap_is_valid_memattr(pmap, mode) checks whether the given variable mode is between the two constant values VM_MEMATTR_DEVICE and VM_MEMATTR_WRITE_THROUGH. After the code for this function was written, the value of VM_MEMATTR_DEVICE changed from 0 to 4. Since VM_MEMATTR_WRITE_THROUGH is still 3, the condition is always false. This patch changes the condition to check whether mode is equal to any of the VM_MEMATTR* constants. Reviewed by: andrew, tuexen MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D55534 --- sys/arm64/arm64/pmap.c | 2 +- sys/arm64/include/vm.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/arm64/arm64/pmap.c b/sys/arm64/arm64/pmap.c index 0cfc8ae80d70..25192bfef653 100644 --- a/sys/arm64/arm64/pmap.c +++ b/sys/arm64/arm64/pmap.c @@ -9643,7 +9643,7 @@ bool pmap_is_valid_memattr(pmap_t pmap __unused, vm_memattr_t mode) { - return (mode >= VM_MEMATTR_DEVICE && mode <= VM_MEMATTR_WRITE_THROUGH); + return (mode >= 0 && mode < VM_MEMATTR_END); } static void * diff --git a/sys/arm64/include/vm.h b/sys/arm64/include/vm.h index 342143c57246..e03e615bb841 100644 --- a/sys/arm64/include/vm.h +++ b/sys/arm64/include/vm.h @@ -33,6 +33,7 @@ #define VM_MEMATTR_WRITE_BACK 2 #define VM_MEMATTR_WRITE_THROUGH 3 #define VM_MEMATTR_DEVICE_nGnRE 4 +#define VM_MEMATTR_END (VM_MEMATTR_DEVICE_nGnRE + 1) #define VM_MEMATTR_DEVICE VM_MEMATTR_DEVICE_nGnRE #define VM_MEMATTR_DEVICE_NP VM_MEMATTR_DEVICE_nGnRnE From nobody Mon Mar 2 18:17:56 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPnGy1lxTz6T2hw for ; Mon, 02 Mar 2026 18:18: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPnGx5fPzz44K0 for ; Mon, 02 Mar 2026 18:18:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772475481; 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; bh=KV1qNqAKPR8aVmONgKCJLgDDM+LozCRaWlP8cIxvmEk=; b=E5yifQbkgUQcRxfg7nl9UpLL3/LVbUkY5nVxOUN+ick60ncVAKYrbT+WvDsjkfyT+psWiT xOgh+Y7QatQJBvJTVswa/6waEs+iqjN7XJUQ6b89+fiHZpM5ZwSkR4+a5eu19YZeUFkeaB gZtZI3SHh1tPv5+wJz+FdwcQMLJeNnAwXPyJUOJKIqUGDSBuBEBA7rNsdaqJDB3gY+xakh 88/KvQ3ZYq2i86qUs1qJ4sZxX5DHSnPceW9nQlXQ86tnoHYvtbVR2rOP1GhrF9DAbhKq5S 6Zq40qY4y0FwW+URFmuJDWJ5OBgDnBDJLPCmMPpllNVfUUU7l+Cf9L5TDl0n9A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772475481; a=rsa-sha256; cv=none; b=BKZBxEN3JV3N3xjdWJOmJ7C4gWVawl+aOEfTDbwA728jlOEtg+kAyzYLpSxvC/USEKpZWQ bBZO8a59qSHV2zpAhPHyLh0cdO3xPaMCsN6QNOYwm3JJBEJaBJnG3FALQtEl2ldJm2RbBV /xdIsiS8fl6+zSIQGujtX6laUQimGcuFzjwb3uALOpLoF3Rggd6NOuBi2A6D55m56bp0Br m1GGTLcT5jasGzlPczyTC43nzu1Nr2TA7yyng5FCWgzx8CKNRQXHKfT6t07GiKMzNdfEqz g4sitZl1dlXy0rvsBsGllDHqxpI4ZrW+Bssy5R5L0VrJ/KXzEAy5N3UDQo4mCA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772475481; 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; bh=KV1qNqAKPR8aVmONgKCJLgDDM+LozCRaWlP8cIxvmEk=; b=dgYEXyjiAv/YYqByFdABc+LE1XTZvbbRbANBZewslfy34MTm6WPliGomBXP+8E1vuZ5rhL ZYvAtX4oiMd8T6fDjeslA+tvpIUypWuHFAiy4jbJz80xOC8WWaIZOTNBmYOlYJQA4HRzbj nyMLQXlRThpkNVuSOP8yfhm8g+E/aTx3dUGMBnsBcHlyLmi5QWgBQBYHTDbedgHkR2gzJR NMSLcgd41mD1WRXjYfQZrUzbNfRJG77wnDvmPXypPYGAgzWH10J9FQj35Wjj9+6k1N53D3 ChJIJv3K4cnHFs6S7hjXwNtXwzJjCZkmXqpaE12EQl62oxgUipE6mQyzgM7e2g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPnGx4mJMzmbK for ; Mon, 02 Mar 2026 18:18:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 4421d by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 18:17:56 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Timo =?utf-8?Q?V=C3=B6lker?= From: Michael Tuexen Subject: git: c70755bc0d8f - main - virtio: add loader tunables to sysctl List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: c70755bc0d8f703dbaa1520c15e8213a95847dd5 Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 18:17:56 +0000 Message-Id: <69a5d454.4421d.5b2bbca8@gitrepo.freebsd.org> The branch main has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=c70755bc0d8f703dbaa1520c15e8213a95847dd5 commit c70755bc0d8f703dbaa1520c15e8213a95847dd5 Author: Timo Völker AuthorDate: 2026-03-02 18:15:37 +0000 Commit: Michael Tuexen CommitDate: 2026-03-02 18:15:37 +0000 virtio: add loader tunables to sysctl virtio_pci uses two loader tunables that should be more visible. This patch adds these loader tunables to sysctl and describes them in the virtio(4) man page. Reviewed by: imp (erlier version), tuexen MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D55533 --- share/man/man4/virtio.4 | 28 ++++++++++++++++++++++++++-- sys/dev/virtio/pci/virtio_pci.c | 7 ++++++- sys/dev/virtio/pci/virtio_pci_modern.c | 7 ++++++- sys/dev/virtio/virtio.c | 4 ++++ 4 files changed, 42 insertions(+), 4 deletions(-) diff --git a/share/man/man4/virtio.4 b/share/man/man4/virtio.4 index 1e5ea0e4a7da..0598d5d8621d 100644 --- a/share/man/man4/virtio.4 +++ b/share/man/man4/virtio.4 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd May 26, 2019 +.Dd March 2, 2026 .Dt VIRTIO 4 .Os .Sh NAME @@ -54,7 +54,7 @@ The .Nm module provides a shared memory transport called a virtqueue. The -.Xr virtio_pci +.Sy virtio_pci device driver represents an emulated PCI device that the hypervisor makes available to the VM. This device provides the probing, configuration, and @@ -92,6 +92,30 @@ An emulated SCSI HBA is provided by the .Xr virtio_scsi 4 device driver. .El +.Sh LOADER TUNABLES +Tunables can be set at the +.Xr loader 8 +prompt before booting the kernel or stored in +.Xr loader.conf 5 . +.Bl -tag -width "hw.virtio.pci.transitional" +.It Va hw.virtio.pci.disable_msix +If set to 1, disables MSI-X. +The default value is 0. +.It Va hw.virtio.pci.transitional +For a transitional +.Nm +device, this tunable specifies whether to negotiate +modern mode and use the modern +.Nm +driver +.Pq 1 +or to negotiate legacy mode and +use the legacy +.Nm +driver +.Pq 1 . +The default value is 0. +.El .Sh SEE ALSO .Xr virtio_balloon 4 , .Xr virtio_blk 4 , diff --git a/sys/dev/virtio/pci/virtio_pci.c b/sys/dev/virtio/pci/virtio_pci.c index b7b34b448f6e..2d33d99014ae 100644 --- a/sys/dev/virtio/pci/virtio_pci.c +++ b/sys/dev/virtio/pci/virtio_pci.c @@ -97,8 +97,13 @@ MODULE_VERSION(virtio_pci, 1); MODULE_DEPEND(virtio_pci, pci, 1, 1, 1); MODULE_DEPEND(virtio_pci, virtio, 1, 1, 1); +SYSCTL_DECL(_hw_virtio); +SYSCTL_NODE(_hw_virtio, OID_AUTO, pci, CTLFLAG_RD | CTLFLAG_MPSAFE, 0, + "VirtIO PCI driver parameters"); + int vtpci_disable_msix = 0; -TUNABLE_INT("hw.virtio.pci.disable_msix", &vtpci_disable_msix); +SYSCTL_INT(_hw_virtio_pci, OID_AUTO, disable_msix, CTLFLAG_RDTUN, + &vtpci_disable_msix, 0, "If set to 1, disables MSI-X."); static uint8_t vtpci_read_isr(struct vtpci_common *cn) diff --git a/sys/dev/virtio/pci/virtio_pci_modern.c b/sys/dev/virtio/pci/virtio_pci_modern.c index eb1d5a1e6989..108fd2b5f8e9 100644 --- a/sys/dev/virtio/pci/virtio_pci_modern.c +++ b/sys/dev/virtio/pci/virtio_pci_modern.c @@ -33,6 +33,7 @@ #include #include #include +#include #include #include @@ -188,8 +189,12 @@ static void vtpci_modern_write_device_8(struct vtpci_modern_softc *, bus_size_t, uint64_t); /* Tunables. */ +SYSCTL_DECL(_hw_virtio_pci); + static int vtpci_modern_transitional = 0; -TUNABLE_INT("hw.virtio.pci.transitional", &vtpci_modern_transitional); +SYSCTL_INT(_hw_virtio_pci, OID_AUTO, transitional, CTLFLAG_RDTUN, + &vtpci_modern_transitional, 0, + "If 0, a transitional VirtIO device is used in legacy mode; otherwise, in modern mode."); static device_method_t vtpci_modern_methods[] = { /* Device interface. */ diff --git a/sys/dev/virtio/virtio.c b/sys/dev/virtio/virtio.c index 75d65ba4a8c8..be5edcafa7ff 100644 --- a/sys/dev/virtio/virtio.c +++ b/sys/dev/virtio/virtio.c @@ -30,6 +30,7 @@ #include #include #include +#include #include #include @@ -90,6 +91,9 @@ static struct virtio_feature_desc virtio_common_feature_desc[] = { { 0, NULL } }; +SYSCTL_NODE(_hw, OID_AUTO, virtio, CTLFLAG_RD | CTLFLAG_MPSAFE, 0, + "VirtIO driver parameters"); + const char * virtio_device_name(uint16_t devid) { From nobody Mon Mar 2 19:10:52 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPpRw3BPnz6T6N9 for ; Mon, 02 Mar 2026 19:10: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPpRw2XF3z3D6q for ; Mon, 02 Mar 2026 19:10:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772478652; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rpY3i8Fh9LfIdYJWxbKhTN6/8JLDBReeHpta+v+512A=; b=F/7tfOwkgMfiUzUEvS1GZQSpazSJRJ2x8XIsx4lfffWg8c5G1drIHF9Um75ZCm/WVeYZhp dDMQIcaLE10UYNgAcddt4naVF13tHozoRK8FyrxArYSWYK4BuvJok3mOp4Xmv4tGDGi8OC 5nH7OTIm/uPH48S9LZsM2LkrNeIFvnUQTmcIv1ePbZOTszw+gRyQ0kk4nfJizS1Y/6W+/L qjSWo04KFYX415p7ICl7NUzU4Fkgjo96ZeQ/+nTwiIHboGCLMN2PlKnBM4ojFpNDDt8m97 dfbHpr0ZzRR6PhPq2WbIMpsFRW/Pxnsxl70Fme4sZsyjhhol4cq9WFTy9ZZW/g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772478652; a=rsa-sha256; cv=none; b=X7ptsEwU2PxRhx92TTO8w43Ib7VlkkX0cK5d5xObKSbU/6WieNOEpM0sPqrvk02xQfkt3y lBfXX+LsDjKQPgZ+o5kBoO/BwICVJjh43DUmnriCRS+wd9+VnTgBtUCqzzRodD0RSEBFqE 7gahfZZsZ7d1HaI+dCSwNInWttbqiatrTyAWWynVzCiCnxNQTgeo9yj95Raz4hPis3vfnx 8s0sgxdwzMatqIR1Wl2wBaMkEkZ6NkI8nl7AFy79SzPBjxXtZqY9k56EqoJmH387TNgeM0 OC/Fa2LfvqiON5fu/scM/rsdpidcgVW0YIZihtZLBJA0jv39mtn/vG5e03QkVA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772478652; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rpY3i8Fh9LfIdYJWxbKhTN6/8JLDBReeHpta+v+512A=; b=fSutlCr0Rm5TvxsRHr0gLITDzBSeNqI7qOlR5o3+lhSgg4gMGEhSmiT64PO3nG1YOqhvwz T94C51xdy2nrch2gALDZN0g4izLuQNpr6eWAl2kZVqUuXNcWmDHtwLgykVgCbGkictPsUq 40Ta2i+cECQkuPbkiL+5JJtCCvXqedfGSdKQDinThyINS1H7+SmDsi1bSpOXFwZLyu+N/b OggZvRaJ56CK/4BV5qjgppaYTFnpxVOpCU9hgnD9H+FGjD5S0pA00pk0hz0J7+OuKgLoNw 07vpX8JlSw8YRd/4bIEOAVK18hXjOl5VCLW+hDeA1kfFCgCfaNVMilvGZaBJ4g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPpRw26nnzp0r for ; Mon, 02 Mar 2026 19:10:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 19f0f by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 19:10:52 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 7a323f873662 - main - sys: Retire le(4) List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 7a323f873662dae95a061d1eaf8b1d9d1a0f8a23 Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 19:10:52 +0000 Message-Id: <69a5e0bc.19f0f.446748b8@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=7a323f873662dae95a061d1eaf8b1d9d1a0f8a23 commit 7a323f873662dae95a061d1eaf8b1d9d1a0f8a23 Author: Ed Maste AuthorDate: 2025-10-24 17:26:03 +0000 Commit: Ed Maste CommitDate: 2026-03-02 19:10:15 +0000 sys: Retire le(4) We retired most obsolete 10 and 10/100 Ethernet NIC drivers in 2019 -- see commits following ebcf740a32ae ("FCP-101: remove obsolete 10 and 10/100 Ethernet drivers.). le(4) was retained with with the note "Emulated by QEMU, alternatives don't yet work for mips64." MIPS has since been removed from the tree and emulators and virtual machines offer many other, more suitable devices. Reviewed by: brooks Relnotes: Yes Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55516 --- ObsoleteFiles.inc | 3 + share/man/man4/Makefile | 2 - share/man/man4/le.4 | 374 ---------------------- sys/amd64/conf/GENERIC | 1 - sys/conf/NOTES | 2 - sys/dev/le/am7990.c | 616 ------------------------------------ sys/dev/le/am79900.c | 651 -------------------------------------- sys/dev/le/am79900reg.h | 148 --------- sys/dev/le/am79900var.h | 56 ---- sys/dev/le/am7990reg.h | 181 ----------- sys/dev/le/am7990var.h | 56 ---- sys/dev/le/if_le_isa.c | 494 ----------------------------- sys/dev/le/if_le_pci.c | 498 ----------------------------- sys/dev/le/lance.c | 818 ------------------------------------------------ sys/dev/le/lancereg.h | 611 ------------------------------------ sys/dev/le/lancevar.h | 208 ------------ sys/i386/conf/GENERIC | 1 - sys/modules/Makefile | 1 - sys/modules/le/Makefile | 12 - 19 files changed, 3 insertions(+), 4730 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index f0e2e12a695a..1b5fe1dec9b3 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -51,6 +51,9 @@ # xargs -n1 | sort | uniq -d; # done +# 20260302: Remove obsolete le(4) ethernet driver +OLD_FILES+=usr/share/man/man4/le.4.gz + # 20260209: Moved allwinner pages to share/man/man4 OLD_FILES+=usr/share/man/man4/arm/aw_gpio.4.gz OLD_FILES+=usr/share/man/man4/arm/aw_mmc.4.gz diff --git a/share/man/man4/Makefile b/share/man/man4/Makefile index a385363138d0..07320734210b 100644 --- a/share/man/man4/Makefile +++ b/share/man/man4/Makefile @@ -296,7 +296,6 @@ MAN= aac.4 \ kue.4 \ ${_kvmclock.4} \ lagg.4 \ - le.4 \ led.4 \ lge.4 \ lindebugfs.4 \ @@ -758,7 +757,6 @@ MLINKS+=jme.4 if_jme.4 MLINKS+=kue.4 if_kue.4 MLINKS+=lagg.4 trunk.4 MLINKS+=lagg.4 if_lagg.4 -MLINKS+=le.4 if_le.4 MLINKS+=lge.4 if_lge.4 MLINKS+=lo.4 loop.4 MLINKS+=lp.4 plip.4 diff --git a/share/man/man4/le.4 b/share/man/man4/le.4 deleted file mode 100644 index 04b57633c91f..000000000000 --- a/share/man/man4/le.4 +++ /dev/null @@ -1,374 +0,0 @@ -.\" $NetBSD: le.4,v 1.22 2004/10/04 19:12:52 rumble Exp $ -.\" -.\"- -.\" Copyright (c) 1992, 1993 -.\" The Regents of the University of California. All rights reserved. -.\" -.\" This software was developed by the Computer Systems Engineering group -.\" at Lawrence Berkeley Laboratory under DARPA contract BG 91-66 and -.\" contributed to Berkeley. -.\" -.\" 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. -.\" 3. Neither the name of the University nor the names of its contributors -.\" may be used to endorse or promote products derived from this software -.\" without specific prior written permission. -.\" -.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS 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 REGENTS 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. -.\" -.\" from: Header: le.4,v 1.2 92/10/13 05:31:33 leres Exp -.\" -.Dd October 24, 2025 -.Dt LE 4 -.Os -.Sh NAME -.Nm le -.Nd "AMD Am7900 LANCE and Am79C9xx ILACC/PCnet Ethernet interface driver" -.Sh SYNOPSIS -To compile this driver into the kernel, -place the following line in your -kernel configuration file: -.Bd -ragged -offset indent -.Cd "device le" -.Ed -.Pp -Alternatively, to load the driver as a -module at boot time, place the following line in -.Xr loader.conf 5 : -.Bd -literal -offset indent -if_le_load="YES" -.Ed -.Pp -For ISA non-PnP adapters, the port address as well as the IRQ and the DRQ -numbers have to be specified in -.Pa /boot/device.hints : -.Cd hint.le.0.at="isa" -.Cd hint.le.0.port="0x280" -.Cd hint.le.0.irq="10" -.Cd hint.le.0.drq="0" -.Sh DEPRECATION NOTICE -The -.Nm -driver may not be present in -.Fx 16.0 -and later. -.Sh DESCRIPTION -The -.Nm -driver provides support for Ethernet adapters based on the -.Tn AMD Am7990 -and -.Tn Am79C90 -.Pq CMOS, pin-compatible -Local Area Network Controller for Ethernet -.Pq Tn LANCE -chips. -.Pp -The -.Nm -driver also supports Ethernet adapters based on the -.Tn AMD Am79C900 -Integrated Local Area Communications Controller -.Pq Tn ILACC -as well as the -.Tn Am79C9xx PCnet -family of chips, which are single-chip implementations of a -.Tn LANCE -chip and a DMA engine. -The -.Nm -driver treats all of these -.Tn PCI -bus Ethernet chips as an -.Tn AMD Am79C970 PCnet-PCI -and does not support the additional features like the MII bus and burst mode of -.Tn AMD Am79C971 PCnet-FAST -and greater chips. -.Pp -Generally, the -.Nm -driver aims at supporting as many different chips on as many different -platforms as possible, -partially at the cost of the best performance with some of these. -.Pp -The -.Nm -driver supports reception and transmission of extended frames for -.Xr vlan 4 . -Selective reception of multicast Ethernet frames is provided by a 64-bit mask; -multicast destination addresses are hashed to a bit entry using the Ethernet -CRC function. -.Sh HARDWARE -.Ss ISA -The -.Nm -driver supports -.Tn ISA -bus Ethernet adapters which are based on the following chips: -.Pp -.Bl -bullet -compact -.It -.Tn AMD Am7990 and Am79C90 LANCE -.It -.Tn AMD Am79C960 PCnet-ISA -.It -.Tn AMD Am79C961 PCnet-ISA+ -.It -.Tn AMD Am79C961A PCnet-ISA II -.El -.Pp -This includes support for the following Ethernet adapters: -.Pp -ISA non-PnP: -.Pp -.Bl -bullet -compact -.It -.Tn BICC Isolan -.\" .It -.\" .Tn Digital DEPCA -.It -.Tn Novell NE2100 -.El -.Pp -ISA PnP: -.Pp -.Bl -bullet -compact -.It -.Tn AMD AM1500T/AM2100 -.It -.Tn AMD PCnet-32 -.It -.Tn AMD PCnet-ISA -.It -.Tn Allied Telesyn AT-1500 -.It -.Tn Boca LANCard Combo -.It -.Tn Cabletron E2100 Series DNI -.It -.Tn Cabletron E2200 Single Chip -.It -.Tn Melco Inc. LGY-IV -.It -.Tn Novell NE2100 -.It -.Tn Racal InterLan EtherBlaster -.El -.Pp -The -.Nm -driver does not support the selection of media types and options via -.Xr ifconfig 8 -with -.Tn ISA -bus Ethernet adapters. -.Ss PCI -The -.Tn PCI -bus Ethernet chips supported by the -.Nm -driver are: -.Pp -.Bl -bullet -compact -.It -.Tn AMD Am53C974/Am79C970/Am79C974 PCnet-PCI -.It -.Tn AMD Am79C970A PCnet-PCI II -.It -.Tn AMD Am79C971 PCnet-FAST -.It -.Tn AMD Am79C972 PCnet-FAST+ -.It -.Tn AMD Am79C973/Am79C975 PCnet-FAST III -.It -.Tn AMD Am79C976 PCnet-PRO -.It -.Tn AMD Am79C978 PCnet-Home -.El -.Pp -This includes support for the following Ethernet adapters: -.Pp -.Bl -bullet -compact -.It -.Tn AcerLAN NIC P20 -.It -.Tn Allied Telesyn AT-2450 and AT-2700 series -.It -.Tn VMware emulated AMD Am79C970A PCnet-PCI II interface -.El -.Pp -The -.Nm -driver supports the selection of the following media types via -.Xr ifconfig 8 -with -.Tn PCI -bus Ethernet adapters: -.Bl -tag -width ".Cm 10base5/AUI" -.It Cm autoselect -Enable autoselection of the media type. -.It Cm 10baseT/UTP -Select UTP media. -.It Cm 10base5/AUI -Select AUI/BNC media. -.El -.Pp -The following media option is supported with these media types: -.Bl -tag -width ".Cm full-duplex" -.It Cm full-duplex -Select full duplex operation. -.El -.Pp -Note that the -.Nm -driver does not support selecting 100Mbps (Fast Ethernet) media types. -.Sh DIAGNOSTICS -.Bl -diag -.It "le%d: overflow" -More packets came in from the Ethernet than there was space in the -.Tn LANCE -receive buffers. -Packets were missed. -.It "le%d: receive buffer error" -The -.Tn LANCE -ran out of buffer space, packet dropped. -.It "le%d: lost carrier" -The Ethernet carrier disappeared during an attempt to transmit. -The -.Tn LANCE -will finish transmitting the current packet, -but will not automatically retry transmission if there is a collision. -.It "le%d: excessive collisions, tdr %d" -The Ethernet was extremely busy or jammed, -outbound packets were dropped after 16 attempts to retransmit. -.Pp -TDR -is the abbreviation of -.Qq Time Domain Reflectometry . -The optionally reported TDR value is an internal counter of the interval -between the start of a transmission and the occurrence of a collision. -This value can be used to determine the distance from the Ethernet tap to -the point on the Ethernet cable that is shorted or open (unterminated). -.It "le%d: dropping chained buffer" -A packet did not fit into a single receive buffer and was dropped. -Since the -.Nm -driver allocates buffers large enough to receive maximum sized Ethernet -packets, this means some other station on the LAN transmitted a packet -larger than allowed by the Ethernet standard. -.It "le%d: transmit buffer error" -The -.Tn LANCE -ran out of buffer space before finishing the transmission of a packet. -If this error occurs, the driver software has a bug. -.It "le%d: underflow" -The -.Tn LANCE -ran out of buffer space before finishing the transmission of a packet. -If this error occurs, the driver software has a bug. -.It "le%d: controller failed to initialize" -Driver failed to start the -.Tn LANCE . -This is potentially a hardware failure. -.It "le%d: memory error" -RAM failed to respond within the timeout when the -.Tn LANCE -wanted to read or write it. -This is potentially a hardware failure. -.It "le%d: receiver disabled" -The receiver of the -.Tn LANCE -was turned off due to an error. -.It "le%d: transmitter disabled" -The transmitter of the -.Tn LANCE -was turned off due to an error. -.El -.Sh SEE ALSO -.Xr altq 4 , -.Xr arp 4 , -.Xr intro 4 , -.Xr netintro 4 , -.Xr vlan 4 , -.Xr ifconfig 8 -.Sh HISTORY -The -.Nm -driver was ported from -.Nx -and first appeared in -.Fx 6.1 . -The -.Nx -version in turn was derived from the -.Nm -driver which first appeared in -.Bx 4.4 . -.Sh AUTHORS -The -.Nm -driver was ported by -.An Marius Strobl Aq Mt marius@FreeBSD.org . -.\" .Sh BUGS -.\" The Am7990 Revision C chips have a bug which causes garbage to be inserted -.\" in front of the received packet occasionally. -.\" The work-around is to ignore packets with an invalid destination address -.\" (garbage will usually not match), by double-checking the destination -.\" address of every packet in the driver. -.\" This work-around can be enabled with the -.\" .Dv LANCE_REVC_BUG -.\" kernel option. -.\" .Pp -.\" When -.\" .Dv LANCE_REVC_BUG -.\" is enabled, the -.\" .Nm -.\" driver executes one or two calls to an inline Ethernet address comparison -.\" function for every received packet. -.\" On the -.\" .Tn MC68000 -.\" it is exactly eight instructions of 16 bits each. -.\" There is one comparison for each unicast packet, and two comparisons for -.\" each broadcast packet. -.\" .Pp -.\" In summary, the cost of the LANCE_REVC_BUG option is: -.\" .Bl -enum -compact -.\" .It -.\" loss of multicast support, and -.\" .It -.\" eight extra -.\" .Tn CPU -.\" instructions per received packet, sometimes sixteen, depending on both the -.\" processor, and the type of packet. -.\" .El -.\" .Pp -.\" All sun3 systems are presumed to have this bad revision of the Am7990, -.\" until proven otherwise. -.\" Alas, the only way to prove what revision of the chip is in a particular -.\" system is inspection of the date code on the chip package, -.\" to compare against a list of what chip revisions were fabricated between -.\" which dates. -.\" .Pp -.\" Alas, the Am7990 chip is so old that -.\" .Tn AMD -.\" has -.\" .Qq de-archived -.\" the production information about it; pending a search elsewhere, we do not -.\" know how to identify the revision C chip from the date codes. diff --git a/sys/amd64/conf/GENERIC b/sys/amd64/conf/GENERIC index c390ff7596b6..0868cdfc95e7 100644 --- a/sys/amd64/conf/GENERIC +++ b/sys/amd64/conf/GENERIC @@ -243,7 +243,6 @@ device axp # AMD EPYC integrated NIC (requires miibus) # PCI Ethernet NICs. device aq # Aquantia / Marvell AQC1xx device bxe # Broadcom NetXtreme II BCM5771X/BCM578XX 10GbE -device le # AMD Am7900 LANCE and Am79C9xx PCnet device rge # Realtek 8125/8126/8127 device ti # Alteon Networks Tigon I/II gigabit Ethernet diff --git a/sys/conf/NOTES b/sys/conf/NOTES index 1f734a700cd1..0114ed51c4f2 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -1897,7 +1897,6 @@ device xmphy # XaQti XMAC II # (hint of prefer_iomap can be done to prefer I/O instead of Mem mapping) # gem: Apple GMAC/Sun ERI/Sun GEM # jme: JMicron JMC260 Fast Ethernet/JMC250 Gigabit Ethernet based adapters. -# le: AMD Am7900 LANCE and Am79C9xx PCnet # lge: Support for PCI gigabit ethernet adapters based on the Level 1 # LXT1001 NetCellerator chipset. This includes the D-Link DGE-500SX, # SMC TigerCard 1000 (SMC9462SX), and some Addtron cards. @@ -2008,7 +2007,6 @@ device cxgb # Chelsio T3 10 Gigabit Ethernet device cxgb_t3fw # Chelsio T3 10 Gigabit Ethernet firmware device cxgbe # Chelsio T4-T6 1/10/25/40/100 Gigabit Ethernet device cxgbev # Chelsio T4-T6 Virtual Functions -device le # AMD Am7900 LANCE and Am79C9xx PCnet device mxge # Myricom Myri-10G 10GbE NIC device rge # Realtek 8125/8126/8127 device oce # Emulex 10GbE (OneConnect Ethernet) diff --git a/sys/dev/le/am7990.c b/sys/dev/le/am7990.c deleted file mode 100644 index 95184356f33b..000000000000 --- a/sys/dev/le/am7990.c +++ /dev/null @@ -1,616 +0,0 @@ -/* $NetBSD: am7990.c,v 1.68 2005/12/11 12:21:25 christos Exp $ */ - -/*- - * SPDX-License-Identifier: BSD-2-Clause AND BSD-3-Clause - * - * Copyright (c) 1997, 1998 The NetBSD Foundation, Inc. - * All rights reserved. - * - * This code is derived from software contributed to The NetBSD Foundation - * by Charles M. Hannum and by Jason R. Thorpe of the Numerical Aerospace - * Simulation Facility, NASA Ames Research Center. - * - * 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. - */ - -/*- - * Copyright (c) 1992, 1993 - * The Regents of the University of California. All rights reserved. - * - * This code is derived from software contributed to Berkeley by - * Ralph Campbell and Rick Macklem. - * - * 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. - * 3. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS 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 REGENTS 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 - -static void am7990_meminit(struct lance_softc *); -static void am7990_rint(struct lance_softc *); -static void am7990_tint(struct lance_softc *); -static void am7990_start_locked(struct lance_softc *sc); - -#ifdef LEDEBUG -static void am7990_recv_print(struct lance_softc *, int); -static void am7990_xmit_print(struct lance_softc *, int); -#endif - -int -am7990_config(struct am7990_softc *sc, const char* name, int unit) -{ - int error, mem; - - sc->lsc.sc_meminit = am7990_meminit; - sc->lsc.sc_start_locked = am7990_start_locked; - - error = lance_config(&sc->lsc, name, unit); - if (error != 0) - return (error); - - mem = 0; - sc->lsc.sc_initaddr = mem; - mem += sizeof(struct leinit); - sc->lsc.sc_rmdaddr = mem; - mem += sizeof(struct lermd) * sc->lsc.sc_nrbuf; - sc->lsc.sc_tmdaddr = mem; - mem += sizeof(struct letmd) * sc->lsc.sc_ntbuf; - sc->lsc.sc_rbufaddr = mem; - mem += LEBLEN * sc->lsc.sc_nrbuf; - sc->lsc.sc_tbufaddr = mem; - mem += LEBLEN * sc->lsc.sc_ntbuf; - - if (mem > sc->lsc.sc_memsize) - panic("%s: memsize", __func__); - - lance_attach(&sc->lsc); - - return (0); -} - -void -am7990_detach(struct am7990_softc *sc) -{ - - lance_detach(&sc->lsc); -} - -/* - * Set up the initialization block and the descriptor rings. - */ -static void -am7990_meminit(struct lance_softc *sc) -{ - if_t ifp = sc->sc_ifp; - struct leinit init; - struct lermd rmd; - struct letmd tmd; - u_long a; - int bix; - - LE_LOCK_ASSERT(sc, MA_OWNED); - - if (if_getflags(ifp) & IFF_PROMISC) - init.init_mode = LE_MODE_NORMAL | LE_MODE_PROM; - else - init.init_mode = LE_MODE_NORMAL; - - init.init_padr[0] = (sc->sc_enaddr[1] << 8) | sc->sc_enaddr[0]; - init.init_padr[1] = (sc->sc_enaddr[3] << 8) | sc->sc_enaddr[2]; - init.init_padr[2] = (sc->sc_enaddr[5] << 8) | sc->sc_enaddr[4]; - lance_setladrf(sc, init.init_ladrf); - - sc->sc_last_rd = 0; - sc->sc_first_td = sc->sc_last_td = sc->sc_no_td = 0; - - a = sc->sc_addr + LE_RMDADDR(sc, 0); - init.init_rdra = a; - init.init_rlen = (a >> 16) | ((ffs(sc->sc_nrbuf) - 1) << 13); - - a = sc->sc_addr + LE_TMDADDR(sc, 0); - init.init_tdra = a; - init.init_tlen = (a >> 16) | ((ffs(sc->sc_ntbuf) - 1) << 13); - - (*sc->sc_copytodesc)(sc, &init, LE_INITADDR(sc), sizeof(init)); - - /* - * Set up receive ring descriptors. - */ - for (bix = 0; bix < sc->sc_nrbuf; bix++) { - a = sc->sc_addr + LE_RBUFADDR(sc, bix); - rmd.rmd0 = a; - rmd.rmd1_hadr = a >> 16; - rmd.rmd1_bits = LE_R1_OWN; - rmd.rmd2 = -LEBLEN | LE_XMD2_ONES; - rmd.rmd3 = 0; - (*sc->sc_copytodesc)(sc, &rmd, LE_RMDADDR(sc, bix), - sizeof(rmd)); - } - - /* - * Set up transmit ring descriptors. - */ - for (bix = 0; bix < sc->sc_ntbuf; bix++) { - a = sc->sc_addr + LE_TBUFADDR(sc, bix); - tmd.tmd0 = a; - tmd.tmd1_hadr = a >> 16; - tmd.tmd1_bits = 0; - tmd.tmd2 = LE_XMD2_ONES; - tmd.tmd3 = 0; - (*sc->sc_copytodesc)(sc, &tmd, LE_TMDADDR(sc, bix), - sizeof(tmd)); - } -} - -static void -am7990_rint(struct lance_softc *sc) -{ - if_t ifp = sc->sc_ifp; - struct mbuf *m; - struct lermd rmd; - int bix, rp; -#if defined(LANCE_REVC_BUG) - struct ether_header *eh; - /* Make sure this is short-aligned, for ether_cmp(). */ - static uint16_t bcast_enaddr[3] = { ~0, ~0, ~0 }; -#endif - - bix = sc->sc_last_rd; - - /* Process all buffers with valid data. */ - for (;;) { - rp = LE_RMDADDR(sc, bix); - (*sc->sc_copyfromdesc)(sc, &rmd, rp, sizeof(rmd)); - - if (rmd.rmd1_bits & LE_R1_OWN) - break; - - m = NULL; - if ((rmd.rmd1_bits & (LE_R1_ERR | LE_R1_STP | LE_R1_ENP)) != - (LE_R1_STP | LE_R1_ENP)) { - if (rmd.rmd1_bits & LE_R1_ERR) { -#ifdef LEDEBUG - if (rmd.rmd1_bits & LE_R1_ENP) { - if ((rmd.rmd1_bits & LE_R1_OFLO) == 0) { - if (rmd.rmd1_bits & LE_R1_FRAM) - if_printf(ifp, - "framing error\n"); - if (rmd.rmd1_bits & LE_R1_CRC) - if_printf(ifp, - "crc mismatch\n"); - } - } else - if (rmd.rmd1_bits & LE_R1_OFLO) - if_printf(ifp, "overflow\n"); -#endif - if (rmd.rmd1_bits & LE_R1_BUFF) - if_printf(ifp, - "receive buffer error\n"); - } else if ((rmd.rmd1_bits & (LE_R1_STP | LE_R1_ENP)) != - (LE_R1_STP | LE_R1_ENP)) - if_printf(ifp, "dropping chained buffer\n"); - } else { -#ifdef LEDEBUG - if (sc->sc_flags & LE_DEBUG) - am7990_recv_print(sc, bix); -#endif - /* Pull the packet off the interface. */ - m = lance_get(sc, LE_RBUFADDR(sc, bix), - (int)rmd.rmd3 - ETHER_CRC_LEN); - } - - rmd.rmd1_bits = LE_R1_OWN; - rmd.rmd2 = -LEBLEN | LE_XMD2_ONES; - rmd.rmd3 = 0; - (*sc->sc_copytodesc)(sc, &rmd, rp, sizeof(rmd)); - - if (++bix == sc->sc_nrbuf) - bix = 0; - - if (m != NULL) { - if_inc_counter(ifp, IFCOUNTER_IPACKETS, 1); - -#ifdef LANCE_REVC_BUG - /* - * The old LANCE (Rev. C) chips have a bug which - * causes garbage to be inserted in front of the - * received packet. The workaround is to ignore - * packets with an invalid destination address - * (garbage will usually not match). - * Of course, this precludes multicast support... - */ - eh = mtod(m, struct ether_header *); - if (ether_cmp(eh->ether_dhost, sc->sc_enaddr) && - ether_cmp(eh->ether_dhost, bcast_enaddr)) { - m_freem(m); - continue; - } -#endif - - /* Pass the packet up. */ - LE_UNLOCK(sc); - if_input(ifp, m); - LE_LOCK(sc); - } else - if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); - } - - sc->sc_last_rd = bix; -} - -static void -am7990_tint(struct lance_softc *sc) -{ - if_t ifp = sc->sc_ifp; - struct letmd tmd; - int bix; - - bix = sc->sc_first_td; - - for (;;) { - if (sc->sc_no_td <= 0) - break; - - (*sc->sc_copyfromdesc)(sc, &tmd, LE_TMDADDR(sc, bix), - sizeof(tmd)); - -#ifdef LEDEBUG - if (sc->sc_flags & LE_DEBUG) - if_printf(ifp, "trans tmd: " - "ladr %04x, hadr %02x, flags %02x, " - "bcnt %04x, mcnt %04x\n", - tmd.tmd0, tmd.tmd1_hadr, tmd.tmd1_bits, - tmd.tmd2, tmd.tmd3); -#endif - - if (tmd.tmd1_bits & LE_T1_OWN) - break; - - if_setdrvflagbits(ifp, 0, IFF_DRV_OACTIVE); - - if (tmd.tmd1_bits & LE_T1_ERR) { - if (tmd.tmd3 & LE_T3_BUFF) - if_printf(ifp, "transmit buffer error\n"); - else if (tmd.tmd3 & LE_T3_UFLO) - if_printf(ifp, "underflow\n"); - if (tmd.tmd3 & (LE_T3_BUFF | LE_T3_UFLO)) { - lance_init_locked(sc); - return; - } - if (tmd.tmd3 & LE_T3_LCAR) { - if (sc->sc_flags & LE_CARRIER) - if_link_state_change(ifp, - LINK_STATE_DOWN); - sc->sc_flags &= ~LE_CARRIER; - if (sc->sc_nocarrier) - (*sc->sc_nocarrier)(sc); - else - if_printf(ifp, "lost carrier\n"); - } - if (tmd.tmd3 & LE_T3_LCOL) - if_inc_counter(ifp, IFCOUNTER_COLLISIONS, 1); - if (tmd.tmd3 & LE_T3_RTRY) { -#ifdef LEDEBUG - if_printf(ifp, "excessive collisions, tdr %d\n", - tmd.tmd3 & LE_T3_TDR_MASK); -#endif - if_inc_counter(ifp, IFCOUNTER_COLLISIONS, 16); - } - if_inc_counter(ifp, IFCOUNTER_OERRORS, 1); - } else { - if (tmd.tmd1_bits & LE_T1_ONE) - if_inc_counter(ifp, IFCOUNTER_COLLISIONS, 1); - else if (tmd.tmd1_bits & LE_T1_MORE) - /* Real number is unknown. */ - if_inc_counter(ifp, IFCOUNTER_COLLISIONS, 2); - if_inc_counter(ifp, IFCOUNTER_OPACKETS, 1); - } - - if (++bix == sc->sc_ntbuf) - bix = 0; - - --sc->sc_no_td; - } - - sc->sc_first_td = bix; - - sc->sc_wdog_timer = sc->sc_no_td > 0 ? 5 : 0; -} - -/* - * Controller interrupt - */ -void -am7990_intr(void *arg) -{ - struct lance_softc *sc = arg; - if_t ifp = sc->sc_ifp; - uint16_t isr; - - LE_LOCK(sc); - - if (sc->sc_hwintr && (*sc->sc_hwintr)(sc) == -1) { - if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); - lance_init_locked(sc); - LE_UNLOCK(sc); - return; - } - - isr = (*sc->sc_rdcsr)(sc, LE_CSR0); -#if defined(LEDEBUG) && LEDEBUG > 1 - if (sc->sc_flags & LE_DEBUG) - if_printf(ifp, "%s: entering with isr=%04x\n", __func__, isr); -#endif - if ((isr & LE_C0_INTR) == 0) { - LE_UNLOCK(sc); - return; - } - - /* - * Clear interrupt source flags and turn off interrupts. If we - * don't clear these flags before processing their sources we - * could completely miss some interrupt events as the NIC can - * change these flags while we're in this handler. We toggle - * the interrupt enable bit in order to keep receiving them - * (some chips work without this, some don't). - */ - (*sc->sc_wrcsr)(sc, LE_CSR0, isr & ~(LE_C0_INEA | LE_C0_TDMD | - LE_C0_STOP | LE_C0_STRT | LE_C0_INIT)); - - if (isr & LE_C0_ERR) { - if (isr & LE_C0_BABL) { -#ifdef LEDEBUG - if_printf(ifp, "babble\n"); -#endif - if_inc_counter(ifp, IFCOUNTER_OERRORS, 1); - } -#if 0 - if (isr & LE_C0_CERR) { - if_printf(ifp, "collision error\n"); - if_inc_counter(ifp, IFCOUNTER_COLLISIONS, 1); - } -#endif - if (isr & LE_C0_MISS) { -#ifdef LEDEBUG - if_printf(ifp, "missed packet\n"); -#endif - if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); - } - if (isr & LE_C0_MERR) { - if_printf(ifp, "memory error\n"); - lance_init_locked(sc); - LE_UNLOCK(sc); - return; - } - } - - if ((isr & LE_C0_RXON) == 0) { - if_printf(ifp, "receiver disabled\n"); - if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); - lance_init_locked(sc); - LE_UNLOCK(sc); - return; - } - if ((isr & LE_C0_TXON) == 0) { - if_printf(ifp, "transmitter disabled\n"); - if_inc_counter(ifp, IFCOUNTER_OERRORS, 1); - lance_init_locked(sc); - LE_UNLOCK(sc); - return; - } - - /* - * Pretend we have carrier; if we don't this will be cleared shortly. - */ - if (!(sc->sc_flags & LE_CARRIER)) - if_link_state_change(ifp, LINK_STATE_UP); - sc->sc_flags |= LE_CARRIER; - - if (isr & LE_C0_RINT) - am7990_rint(sc); - if (isr & LE_C0_TINT) - am7990_tint(sc); - - /* Enable interrupts again. */ - (*sc->sc_wrcsr)(sc, LE_CSR0, LE_C0_INEA); - - if (!if_sendq_empty(ifp)) - am7990_start_locked(sc); - - LE_UNLOCK(sc); -} - -/* - * Set up output on interface. - * Get another datagram to send off of the interface queue, and map it to the - * interface before starting the output. - */ *** 3951 LINES SKIPPED *** From nobody Mon Mar 2 19:16:36 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPpZX1mLlz6T6Pj for ; Mon, 02 Mar 2026 19:16: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPpZX14t2z3GYC for ; Mon, 02 Mar 2026 19:16:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772478996; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bR056A9qPUpG41EldBIZInZX9hbD0oEsBqE/UnYnaVg=; b=OQQ0z9w5yU4CDyq61R6wL7J/G27bhzVhJXtmk2tYoXwKY2IZTarJwvepEgivZn/eMGcY7D tpeF/7dSdd2U3l8RaovI2gkNce1K3gApwXaUBstFLmNhFMSQfEtpgChwQAZ/VbKc9U9SJ6 0kIScPVgVbFJDkeprIxu3NpAVb/3TMUd4Wn9hfkKjg6mBGoZrY5RwEs9BVcDzBFW8dplgz nFe+qyp2+Yzp9AjmR+psGNZYBa5+HdcdmhrH9AvIswfqiTWUDYHyO0O2gkLoCFoNH4CNHx JqqekIkreTLFBYhJesvsLyQ3zQu5F2YUbxEzJtoqZBQ5r/D6NM4Hp9nVe7ENqQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772478996; a=rsa-sha256; cv=none; b=ikseb9Lmklk81JEv08XumlAA9jzKQHoHuVdJlSCqBAaJG/3oMk2JkHEJrfAhZj25rsdJUb DJ8cfiDMxr34gJX58lAIsbANbVeaVq8KfEh7KhjaaVAZ2wa51tkGpElKeegNHOscwRPMPu QtRUUnzGJbiFp27En35XmgzqUvQsi3635E4YvJmtWbf+ccG597kUiw8l75KuM8rrymBwOw D253N0Sr/labxbT2xj3i+TRUrnCrAfUyCz3dK/4Sx0W6jvVZyS4ZVNQryfclyyQCeDyb+3 4MKwcmjDLSbTofpOybkD4UbFzEsfUMBZrZkh5SEs3kzKJmDwX+aFRQlBzy8Tkg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772478996; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bR056A9qPUpG41EldBIZInZX9hbD0oEsBqE/UnYnaVg=; b=pRTRQ6r5BSRBHJ4ZxnbAXOr5lnIom+aOt53MmznR7dFvAfjHFiwFT3kslkJAV0lezGUJqw I5W+O8ZOWh4pxn5smTQNYGLMa+2m+jaRihpLWBFcI0636ws4PSan+MtWnE5D1aH5Hvg4mq +4WWOoo5rMIPFuzYwWsKn3O8/RmchmsMfy2ce39dlWhRototXaqAgtCPYesaB1KqB6WavD swYQxiSIz5/d1I2sVMwxAIAsB90m/xkgTuQtSgC7GhQkduKC9scqcNQvP03yI3d+Iwws9p AvbL0BPIUtLsZq2M+CPSHv8ofDT+oDhbFAMd+/gM1Ot5sRLpi+ogaTuO+d3rvA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPpZX0NHjznhh for ; Mon, 02 Mar 2026 19:16:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 197b8 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 19:16:36 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kenneth D. Merry Subject: git: 930486f9be5c - main - mt(1)/libmt: Add LTO-10 density codes and specs. List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: ken X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 930486f9be5c884d1d2f0aae9f81a3f5af1f2718 Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 19:16:36 +0000 Message-Id: <69a5e214.197b8.1c968524@gitrepo.freebsd.org> The branch main has been updated by ken: URL: https://cgit.FreeBSD.org/src/commit/?id=930486f9be5c884d1d2f0aae9f81a3f5af1f2718 commit 930486f9be5c884d1d2f0aae9f81a3f5af1f2718 Author: Kenneth D. Merry AuthorDate: 2026-03-02 19:13:47 +0000 Commit: Kenneth D. Merry CommitDate: 2026-03-02 19:13:47 +0000 mt(1)/libmt: Add LTO-10 density codes and specs. These were obtained from IBM specs and actual tapes/drives. Standard LTO-10 cartriges hold 30TB raw, 75TB with 2.5:1 compression. Premium LTO-10 cartridges hold 40TB raw, 100TB with 2.5:1 compression. LTO-10 tape drives are not backward compatible with previous generation LTO tapes. (This is a change from older generation drives.) Since the Premium tape is a new thing for LTO, we'll call this density code LTO-10P vs. the standard LTO-10. The barcode identifier for LTO-10 tapes is "LA"; the barcode identifier for LTO-10P tapes is "PA". LTO-10 cartridges contain 1035m of tape, while LTO-10 Premium cartridges contain 1337m of tape and have slightly higher density. (Obtained from MAM data on actual tape cartridges and the density report, obtained via 'mt getdensity'.) LTO-10 cartridges use a polyethylene naphthalate (PEN) film substrate. LTO-10 Premium cartridges use an Aramid (aromatic polyamide) substrate that is thinner and stronger, allowing a longer tape to fit in the same cartridge form factor. usr.bin/mt/mt.1: Add density codes and specs for LTO-10 and LTO-10P. lib/libmt/mtlib.c: Add density codes for LTO-10 and LTO-10P. Sponsored by: Spectra Logic MFC after: 3 days --- lib/libmt/mtlib.c | 2 ++ usr.bin/mt/mt.1 | 9 ++++++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/lib/libmt/mtlib.c b/lib/libmt/mtlib.c index 6175f6b8888a..4cbee073de56 100644 --- a/lib/libmt/mtlib.c +++ b/lib/libmt/mtlib.c @@ -647,6 +647,8 @@ static struct densities { { 0x5D, 19107, 485318, "LTO-M8" }, { 0x5E, 20669, 524993, "LTO-8" }, { 0x60, 23031, 584987, "LTO-9" }, + { 0x62, 21657, 550088, "LTO-10" }, + { 0x63, 22441, 570001, "LTO-10P" }, { 0x71, 11800, 299720, "3592A1 (encrypted)" }, { 0x72, 11800, 299720, "3592A2 (encrypted)" }, { 0x73, 13452, 341681, "3592A3 (encrypted)" }, diff --git a/usr.bin/mt/mt.1 b/usr.bin/mt/mt.1 index 4cafdf4437c7..361c9ae65bda 100644 --- a/usr.bin/mt/mt.1 +++ b/usr.bin/mt/mt.1 @@ -26,7 +26,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd October 31, 2023 +.Dd March 2, 2026 .Dt MT 1 .Os .Sh NAME @@ -524,6 +524,8 @@ Value Width Tracks Density Code Type Reference Note 0x5D 12.7 (0.5) 5376 19,107 (485,318) C LTO-M8 14 0x5E 12.7 (0.5) 6656 20,669 (524,993) C LTO-8 0x60 12.7 (0.5) 8960 23,031 (584,987) C LTO-9 +0x62 12.7 (0.5)15104 21,657 (550,088) C LTO-10 15 +0x63 12.7 (0.5)15104 22,441 (570,001) C LTO-10P 15 0x71 12.7 (0.5) 512 11,800 (299,720) C 3592A1 (encrypted) 0x72 12.7 (0.5) 896 11,800 (299,720) C 3592A2 (encrypted) 0x73 12.7 (0.5) 1152 13,452 (341,681) C 3592A3 (encrypted) @@ -572,6 +574,11 @@ NOTES LTO-7 cartridge initialized with a higher density format by an LTO-8 drive. It cannot be read by an LTO-7 drive. Uncompressed capacity is 9TB, compared to 6TB for LTO-7 and 12TB for LTO-8. +15. LTO-10 Premium cartridges hold 40TB uncompressed vs. 30TB + uncompressed for standard LTO-10 cartridges due to slightly higher + density and stronger, thinner, longer tape. LTO-10 tape drives + are not backward compatible with previous generation LTO tape + cartridges. .Ed .Bd -literal -offset 2n NOTE ON QIC STREAMERS From nobody Mon Mar 2 19:18:46 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPpd25FbLz6T6q5 for ; Mon, 02 Mar 2026 19:18: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPpd233pGz3Gx6 for ; Mon, 02 Mar 2026 19:18:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772479126; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6zzmZG+y5aELts7T+fBLGD4Qeyektb3Yli5TB11DA7o=; b=oDQr+pmSSjNbJ02EJS2DohAcsaBiY5UejNLLhlORvdPZmHBlmSP3vSc4W2HzbFV5uhCYS+ n+xlVsBmE75u3n0KSiWUYInjD5GcxKkZFpOiAEYZuMqvOeXbpVL4oD6kRSUY/YVhsAnoLV T+ma2VsztQ3VAOMmNyBry4jZAzKHq2BLQXbNQr4w6HsFV7pB3Df6lYKGkau4qaitAwoNJe H2zrcTN5D0PKWnbfZyUgBqrJ5XlCj8YOWrB33ism+EeczkMr3ab1Jm/D9MY9py9Wos2XVK Eu4hOPzy1x2Kxd7Mn82MZzO5BgENyajgBoA1qJpHLWg/eX//9yuj7H9HxsP6KQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772479126; a=rsa-sha256; cv=none; b=edeDtfEAem3MqOap9SaLMwZAkioLBt7jgXThfmSct6mPBkRucvM3/CTPrD5JM/5ZM8fFOY 6uZi1M9xSFEikxNEoGU3tB4SQ8TXQ6w+sKkue4b7prGmQpGIP9lBi9TLdb0FK+OJAkj1IL SkhPrM7wsJEwCvChHAueRGvuAjkxXaSPEaG97H1R2NlbTVjQ3sO0yK3LcDJBECg8l/WAeK iJJ5t02DeQGezh0mHDoWdNr3jDugdP8LHWw5sFBbbKzNpwZMxHSG6eRvR+xgqP81ncmP18 Zm6YlmqSgNVNv7aeKrhGr2uIaBgw3HiDgdoJ1HQ3jRvWjF2y4nysz2z6VOiTlw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772479126; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6zzmZG+y5aELts7T+fBLGD4Qeyektb3Yli5TB11DA7o=; b=janx3eKppib/+Xv93GlXOELFheAyUuOdkLEv8W4NroBa8BoBN5qSG7oCokvBcP0pCsfSO0 5/uJTXy2e/KdMDerRcK3ZzX5gbUMbRAGgUt3XKkoMAWzwXxyY8zAMtQ3TolugTBdsn/zku 9EPj5qdsYRvND4o6skUB93TYg0NHVLUBXbP6nAtqExm7px7tGosPWAkCETGNeiSqYBkGsZ QUa9Rr15qU9T+y5N9hqANstrIt++SyWTK+FjJvlUiYtfjQegF3MZlQ2zFa3qY1uAqUvtlw Smmf34J3U9wiT2iO7hdmtyw7WqjmZQ7Fp0dtUQuIj2F4xD11djgUZ/hNT+nMtg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPpd22HfKzp73 for ; Mon, 02 Mar 2026 19:18:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 19f16 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 19:18:46 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 34d7f100c1d9 - main - lesspipe: Use zstdcat List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 34d7f100c1d9e6f21d2f79097e891f7a17749d1b Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 19:18:46 +0000 Message-Id: <69a5e296.19f16.48e260a1@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=34d7f100c1d9e6f21d2f79097e891f7a17749d1b commit 34d7f100c1d9e6f21d2f79097e891f7a17749d1b Author: Ed Maste AuthorDate: 2026-02-23 18:59:55 +0000 Commit: Ed Maste CommitDate: 2026-03-02 19:18:41 +0000 lesspipe: Use zstdcat zstdcat is equivalent to zstd -dcf, and matches our intention. Suggested by: delphij (in D55101) Sponsored by: The FreeBSD Foundation --- usr.bin/less/lesspipe.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.bin/less/lesspipe.sh b/usr.bin/less/lesspipe.sh index 6fc6cc471638..7992cc4e2e3d 100644 --- a/usr.bin/less/lesspipe.sh +++ b/usr.bin/less/lesspipe.sh @@ -21,7 +21,7 @@ case "$1" in exec lzma -d -c "$1" 2>/dev/null ;; *.zst) - exec zstd -d -q -c -f "$1" 2>/dev/null + exec zstdcat -q "$1" 2>/dev/null ;; *) exec cat "$1" 2>/dev/null ;; From nobody Mon Mar 2 19:37:00 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPq2459mPz6T81S for ; Mon, 02 Mar 2026 19:37: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPq244XJjz3KRd for ; Mon, 02 Mar 2026 19:37:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772480220; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=i8taPDmwXhK0ay3B5MbPZvZPBMYcorf+4zL/LTyglfs=; b=cUSWRsehm+U8D8P1L5xr/0bTjOFgFmTwtwQjNgUzXFJQdtJvQd5nSNM0RiaMWjK5fNRAJ9 5deDS5xgam6uXcr8gLEma24+PUX3kx3kcMg6ZNqWafOgVUwC026ZTRvfgT21DNWJ4FMpZp lMJg4fJj8lKlicWM+CP9gv55vI9O0WV4fujPqCM4x5GOLotwMWtu3dRnaqXSv/01wbGwpq AvwNaVFqFSSkJpz7m96xMhWxbGFv4iRshAkNkAo6tal7IwMsG+uJJL4afwmVsTAzGNIQbs bHRD64BeDTBZ4upeky9K27JopIqAA6imcXG8UYh607epc+pUcaMvZkPUd0qfrA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772480220; a=rsa-sha256; cv=none; b=VppD0KYGFeKs6iOYByPZ/eK0SG26KQKQcGnSC4fvHdwQSnwOEKXS/dGA9908h4zIP3OgK/ cDI0tieuVGNzxAjumBaADcF28CqVPWCd7cI/m0WPc+cMznDJT597D5NJsdpHivy00cVj2Y uJAV7YevNQoOZAlHMugtEUy4cnwSia7nEdxk/54yn624l1lVIpZqlEPCYQJ9ubCHZemYxU 5keF8eKNvPy3TYaSuEjCYcbVRQOQs18rmwEGJQUvATcqHyuqKbYDtElNiKln8D6DR6Zg0p S8xcj6JrgwjsmIanB4Syv3jjzy5w1eDo+qR956VfyeH4IrHBz7okF6nM2yrt1A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772480220; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=i8taPDmwXhK0ay3B5MbPZvZPBMYcorf+4zL/LTyglfs=; b=df7alSdfBrU2N/7wgZ9xp/nafvWbD0pgfLiVQZAQ10+Ap8Suptw4H1vAUHTfFp1yHQbPJf 6AiRFKybM+9YW6u/NcksAdpXMvKGtbg7BkQ5WVYSTZLgEy6ZW8M7JNy3rudL8RWG1TznB+ 144i98cDYPUO23MZ8k1NfW6pvpyJtSFkZrDGIfnynloY+IRPH9M/8fmQPFa7XZ/ex9gkBu Pgrt47TxK2tmy0SjrtRdz803wwR5iRx7QlZXirV8N5wLN4JSFmZMDlgSTL8GZn+uK6r0DH hlCT7ETlhAuWV+/2cE98gy9y5GB2DP2vFt9wQzJ0FwEmkZ402cKw522OXhbPBA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPq243ZgvzpWH for ; Mon, 02 Mar 2026 19:37:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1d730 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 19:37:00 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: e4c8058cf48d - main - crunch: ldconfig and ldd are unrelated to GNU ld List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: e4c8058cf48df2d98e89a7de66d189c71bd4c3fb Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 19:37:00 +0000 Message-Id: <69a5e6dc.1d730.21b7b727@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=e4c8058cf48df2d98e89a7de66d189c71bd4c3fb commit e4c8058cf48df2d98e89a7de66d189c71bd4c3fb Author: Ed Maste AuthorDate: 2026-03-02 19:34:29 +0000 Commit: Ed Maste CommitDate: 2026-03-02 19:35:57 +0000 crunch: ldconfig and ldd are unrelated to GNU ld Move them to the usr.bin section. Fixes: de5663609e4c ("This is the new crunch utility for making...") --- usr.sbin/crunch/examples/really-big.conf | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/usr.sbin/crunch/examples/really-big.conf b/usr.sbin/crunch/examples/really-big.conf index 9c227a7b8d29..50f026e3ed6a 100644 --- a/usr.sbin/crunch/examples/really-big.conf +++ b/usr.sbin/crunch/examples/really-big.conf @@ -41,8 +41,8 @@ progs apropos ar asa at basename biff cal calendar cap_mkdb checknr chpass progs cksum cmp col colcrt colrm column comm compress crontab ctags cut progs dirname du env error expand false file find finger fmt fold fpr from progs fsplit fstat ftp getconf getopt gprof head hexdump id indent ipcrm -progs ipcs join kdump ktrace last lastcomm leave lex lock logger locate -progs login logname look m4 machine mail make man mesg mkfifo +progs ipcs join kdump ktrace last lastcomm ldconfig ldd leave lex lock logger +progs locate progs login logname look m4 machine mail make man mesg mkfifo progs mkstr modstat more msgs netstat newsyslog nfsstat nice nm nohup progs pagesize passwd paste patch pr printenv printf quota ranlib progs renice rev rlogin rpcgen rpcinfo rsh rup ruptime rusers rwall rwho @@ -110,8 +110,8 @@ srcdirs /usr/src/gnu/usr.bin progs bc cpio diff diff3 gas gawk grep gzip sdiff sort tar -srcdirs /usr/src/gnu/usr.bin/ld # ldd and ldconfig -progs ld ldd ldconfig +srcdirs /usr/src/gnu/usr.bin/ld +progs ld # rcs stuff loses because there are cross dependencies between librcs.a and # the individual programs. The solution would be to specify the objpaths From nobody Mon Mar 2 20:44:57 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPrXX34FDz6TCtS for ; Mon, 02 Mar 2026 20:45: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPrXX147bz3Sbp for ; Mon, 02 Mar 2026 20:45:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772484300; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iLFiDw/SoOGbiKR0qAGuAcWekwj/0VpiAjH/CTpbSWU=; b=h929Z4jivFAD4Xjw9N+y9YHX5smV5J+4VMkefZ/DPbHc6yiCSoX8E8viBPXmGpczdLIQ71 IkQuAdCBADvJ2z3nDh+25ESOV+evxBLhaD85Haeob1sbgUyVFB3shLZBdSfNrKGezCbFRp O3ufjtng0HVSkx9CI4nnpzO82Wm3XvpOwm6ISPrBrCs9JPk2qZPp27xZGxUx1BzENaGdJE 2nYMd1xDfhdd+zxVWFVyz2oafPSmuOrQhkVzEEbqGPw/rA77ue3qhZYFWam81pSznTAcvm 5wRWp+06p2eqVwNu35QgFbMiYUXvS1E2UKY8VnfPD3FiBhaVOnXT+nyXeXSaoA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772484300; a=rsa-sha256; cv=none; b=rPPdol/sHKM+Zd2qHQpbSgjdSoYDm6+UYmA6fmTNQNxX2wrDgYpA4eE+ZpLgVDqPIS0gfN Q310lD3eU3DAvNy+bCV3r5oyX/CRp5g+bXSjS1+7rj2un+07RiIJ+8gVrrM5DJvnBUDmvH IL3gW3aVWTSkxF/rsgGA9WdfDPXMzdGari21UPBQqYL4uR3GbyqxTKojF8fdraTeqLJizN PITu9PQDeUVPvxRYCMSluNkhsJv5LFSuXp0NQ0DhlBq5ElY8fz+ock+diFiMUZDSMkxxR6 tm3jbqPOyIOxkQBlh+Y29Xsrp3I8p1SfhUntpLesn57rcw5HUb2Y6oWHgKRIrw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772484300; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iLFiDw/SoOGbiKR0qAGuAcWekwj/0VpiAjH/CTpbSWU=; b=TGRN7pWe6YJhfb6Bi9Q1eG7EIflrBhWeHnizuRW8ff+AyqWrHvNXLudTUM8+3F3OCqq7mJ 9kpgWw9CAlASDsP07DyUko4WPqTEQDcERHxjk0FUWvmRg8x8M88WL0CfoGXP1s203mfF5A Q9+37WyxqlN7roQmnVJH7Rm7yKNnmwB5cgR7f2BWpvPwWm2CtjzLm7aFZKnDJHH8XhM/lE KV/EnliSXUqnnDOwUU0Z1miOCZbk8CsvrPxLC3s/DlzecEvC1tfTRP91LF68Ho7VkkF2O5 0iuh8Kz5kZvKbgfsLZ+E/dXz4ahF9JxDjXMNHRYkXwVPMzdB9kBhpo1Dm1+BxQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPrXX018nzrYn for ; Mon, 02 Mar 2026 20:44:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 24fe4 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 20:44:57 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Philip Paeps Subject: git: 6becc3dff922 - main - contrib/tzdata: import tzdata 2026a List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: philip X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6becc3dff922476d667c15f029e520da496d4295 Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 20:44:57 +0000 Message-Id: <69a5f6c9.24fe4.4ad29f25@gitrepo.freebsd.org> The branch main has been updated by philip: URL: https://cgit.FreeBSD.org/src/commit/?id=6becc3dff922476d667c15f029e520da496d4295 commit 6becc3dff922476d667c15f029e520da496d4295 Merge: e4c8058cf48d 18b0e604df30 Author: Philip Paeps AuthorDate: 2026-03-02 20:34:06 +0000 Commit: Philip Paeps CommitDate: 2026-03-02 20:34:06 +0000 contrib/tzdata: import tzdata 2026a Changes: https://github.com/eggert/tz/blob/2026a/NEWS MFC after: 3 days contrib/tzdata/Makefile | 48 +++++++------------ contrib/tzdata/NEWS | 99 +++++++++++++++++++++++++++++++++++++++- contrib/tzdata/backzone | 5 +- contrib/tzdata/etcetera | 3 +- contrib/tzdata/europe | 74 +++++++++++++++++++++++++++--- contrib/tzdata/leap-seconds.list | 8 ++-- contrib/tzdata/leapseconds | 8 ++-- contrib/tzdata/theory.html | 22 +++++---- contrib/tzdata/version | 2 +- contrib/tzdata/zonenow.tab | 3 -- 10 files changed, 207 insertions(+), 65 deletions(-) diff --cc contrib/tzdata/Makefile index bb7cb1014f73,000000000000..1e0a5903534d mode 100644,000000..100644 --- a/contrib/tzdata/Makefile +++ b/contrib/tzdata/Makefile @@@ -1,1463 -1,0 +1,1447 @@@ +# Make and install tzdb code and data. +# This file is in the public domain, so clarified as of +# 2009-05-17 by Arthur David Olson. +# Request POSIX conformance; this must be the first non-comment line. +.POSIX: +# By default, builds of code and data assume POSIX.1-2001 or later; +# this assumption can be relaxed by tailoring the build as described below. +# On older platforms you may need to scrounge for POSIX conformance. +# For example, on Solaris 10 (2005) with Sun Studio 12 aka Sun C 5.9 (2007), +# use 'PATH=/usr/xpg4/bin:$PATH make CC=c99'. +# Reproducible builds of distribution tarballs also need a copy of the +# Git repository, and assume the behavior of the following programs +# (or later versions): +# Git 2.7.0 (2016) +# GNU Coreutils 6.3 (2006) +# GNU Tar 1.14 (2004) +# GnuPG 1.4 (2004) +# Although tzdb does not come with a software bill of materials, +# you should be able to construct one based on the above information, +# your platform, and the way you use this Makefile. + +# To affect how this Makefile works, you can run a shell script like this: +# +# #!/bin/sh +# make CFLAGS='-O2 -DHAVE_GETTEXT=0' "$@" +# +# This example script is appropriate for a GNU/Linux system +# which needs more optimization than default, and which does not want +# gettext's internationalization of diagnostics. +# +# Alternatively, you can simply edit this Makefile to tailor the following +# macro definitions. + +############################################################################### +# Start of macros that one plausibly might want to tailor. + +# Package name for the code distribution. +PACKAGE= tzcode + +# Version number for the distribution, overridden in the 'tarballs' rule below. +VERSION= unknown + +# Email address for bug reports. +BUGEMAIL= tz@iana.org + +# DATAFORM selects the data format. +# Available formats represent essentially the same data, albeit +# possibly with minor discrepancies that users are not likely to notice. +# To get new features and the best data right away, use: +# DATAFORM= vanguard +# To wait a while before using new features, to give downstream users +# time to upgrade zic (the default), use: +# DATAFORM= main +# To wait even longer for new features, use: +# DATAFORM= rearguard +# Rearguard users might also want "ZFLAGS = -b fat"; see below. +DATAFORM= main + +# Change the line below for your timezone (after finding the one you want in +# one of the $(TDATA) source files, or adding it to a source file). +# Alternatively, if you discover you've got the wrong timezone, you can just +# 'zic -l -' to remove it, or 'zic -l rightzone' to change it. +# Use the command +# make zonenames +# to get a list of the values you can use for LOCALTIME. + +LOCALTIME= Factory + - # The POSIXRULES macro controls interpretation of POSIX-like TZ - # settings like TZ='EET-2EEST' that lack DST transition rules. - # If POSIXRULES is '-', no template is installed; this is the default. - # Any other value for POSIXRULES is obsolete and should not be relied on, as: - # * It does not work correctly in popular implementations such as GNU/Linux. - # * It does not work even in tzcode, except for historical timestamps - # that precede the last explicit transition in the POSIXRULES file. - # Hence it typically does not work for current and future timestamps. - # If, despite the above, you want a template for handling these settings, - # you can change the line below (after finding the timezone you want in the - # one of the $(TDATA) source files, or adding it to a source file). - # Alternatively, if you discover you've got the wrong timezone, you can just - # 'zic -p -' to remove it, or 'zic -p rightzone' to change it. - # Use the command - # make zonenames - # to get a list of the values you can use for POSIXRULES. - - POSIXRULES= - - - # Also see TZDEFRULESTRING below, which takes effect only - # if POSIXRULES is '-' or if the template file cannot be accessed. - + +# Installation locations. +# +# The defaults are suitable for Debian, except that if REDO is +# posix_right or right_posix then files that Debian puts under +# /usr/share/zoneinfo/posix and /usr/share/zoneinfo/right are instead +# put under /usr/share/zoneinfo-posix and /usr/share/zoneinfo-leaps, +# respectively. Problems with the Debian approach are discussed in +# the commentary for the right_posix rule (below). + +# Destination directory, which can be used for staging. +# 'make DESTDIR=/stage install' installs under /stage (e.g., to +# /stage/etc/localtime instead of to /etc/localtime). Files under +# /stage are not intended to work as-is, but can be copied by hand to +# the root directory later. If DESTDIR is empty, 'make install' does +# not stage, but installs directly into production locations. +DESTDIR = + +# Everything is installed into subdirectories of TOPDIR, and used there. +# TOPDIR should be empty (meaning the root directory), +# or a directory name that does not end in "/". +# TOPDIR should be empty or an absolute name unless you're just testing. +TOPDIR = + +# The default local timezone is taken from the file TZDEFAULT. +TZDEFAULT = $(TOPDIR)/etc/localtime + +# The subdirectory containing installed program and data files, and +# likewise for installed files that can be shared among architectures. +# These should be relative file names. +USRDIR = usr +USRSHAREDIR = $(USRDIR)/share + +# "Compiled" timezone information is placed in the "TZDIR" directory +# (and subdirectories). +# TZDIR_BASENAME should not contain "/" and should not be ".", ".." or empty. +TZDIR_BASENAME= zoneinfo +TZDIR = $(TOPDIR)/$(USRSHAREDIR)/$(TZDIR_BASENAME) + +# The "tzselect" and (if you do "make INSTALL") "date" commands go in: +BINDIR = $(TOPDIR)/$(USRDIR)/bin + +# The "zdump" command goes in: +ZDUMPDIR = $(BINDIR) + +# The "zic" command goes in: +ZICDIR = $(TOPDIR)/$(USRDIR)/sbin + +# Manual pages go in subdirectories of. . . +MANDIR = $(TOPDIR)/$(USRSHAREDIR)/man + +# Library functions are put in an archive in LIBDIR. +LIBDIR = $(TOPDIR)/$(USRDIR)/lib + + +# Types to try, as an alternative to time_t. +TIME_T_ALTERNATIVES = $(TIME_T_ALTERNATIVES_HEAD) $(TIME_T_ALTERNATIVES_TAIL) +TIME_T_ALTERNATIVES_HEAD = int_least64_t.ck +TIME_T_ALTERNATIVES_TAIL = int_least32_t.ck uint_least32_t.ck \ + uint_least64_t.ck + +# What kind of TZif data files to generate. (TZif is the binary time +# zone data format that zic generates; see Internet RFC 9636.) +# If you want only POSIX time, with time values interpreted as +# seconds since the epoch (not counting leap seconds), use +# REDO= posix_only +# below. If you want only "right" time, with values interpreted +# as seconds since the epoch (counting leap seconds), use +# REDO= right_only +# below. If you want both sets of data available, with leap seconds not +# counted normally, use +# REDO= posix_right +# below. If you want both sets of data available, with leap seconds counted +# normally, use +# REDO= right_posix +# below. POSIX mandates that leap seconds not be counted, and a +# nonnegative TZ_CHANGE_INTERVAL also assumes this, so to be compatible with +# these, use "posix_only" or "posix_right". Use POSIX time on systems with +# leap smearing; this can work better than unsmeared "right" time with +# applications that are not leap second aware, and is closer to unsmeared +# "right" time than unsmeared POSIX time is (e.g., 0.5 vs 1.0 s max error). + - REDO= posix_right ++REDO= posix_only + +# Whether to put an "Expires" line in the leapseconds file. +# Use EXPIRES_LINE=1 to put the line in, 0 to omit it. +# The EXPIRES_LINE value matters only if REDO's value contains "right". +# If you change EXPIRES_LINE, remove the leapseconds file before running "make". +# zic's support for the Expires line was introduced in tzdb 2020a, +# and was modified in tzdb 2021b to generate version 4 TZif files. +# EXPIRES_LINE defaults to 0 for now so that the leapseconds file +# can be given to pre-2020a zic implementations and so that TZif files +# built by newer zic implementations can be read by pre-2021b libraries. +EXPIRES_LINE= 0 + +# To install data in text form that has all the information of the TZif data, +# (optionally incorporating leap second information), use +# TZDATA_TEXT= tzdata.zi leapseconds +# To install text data without leap second information (e.g., because +# REDO='posix_only'), use +# TZDATA_TEXT= tzdata.zi +# To avoid installing text data, use +# TZDATA_TEXT= + +TZDATA_TEXT= leapseconds tzdata.zi + +# For backward-compatibility links for old zone names, use +# BACKWARD= backward +# To omit these links, use +# BACKWARD= + +BACKWARD= backward + +# If you want out-of-scope and often-wrong data from the file 'backzone', +# but only for entries listed in the backward-compatibility file zone.tab, use +# PACKRATDATA= backzone +# PACKRATLIST= zone.tab +# If you want all the 'backzone' data, use +# PACKRATDATA= backzone +# PACKRATLIST= +# To omit this data, use +# PACKRATDATA= +# PACKRATLIST= + +PACKRATDATA= +PACKRATLIST= + +# The name of a locale using the UTF-8 encoding, used during self-tests. +# The tests are skipped if the name does not appear to work on this system. + +UTF8_LOCALE= en_US.utf8 + +# Extra flags for producing man page files like tzfile.5.txt. +# These flags are used only if groff (or mandoc) is present. +# Each option should begin with "-" and should lack shell metacharacters. +# Plausible options include -Tascii and -Tutf8. +MANFLAGS= -Tutf8 + +# Non-default libraries needed to link. +# On some hosts, this should have -lintl unless CFLAGS has -DHAVE_GETTEXT=0. +LDLIBS= + +# Add the following to an uncommented "CFLAGS=" line as needed +# to override defaults specified in the source code or by the system. +# "-DFOO" is equivalent to "-DFOO=1". +# -DDEPRECATE_TWO_DIGIT_YEARS for optional runtime warnings about strftime +# formats that generate only the last two digits of year numbers +# -DEPOCH_LOCAL if the 'time' function returns local time not UT +# -DEPOCH_OFFSET=N if the 'time' function returns a value N greater +# than what POSIX specifies, assuming local time is UT. +# For example, N is 252460800 on AmigaOS. +# -DFREE_PRESERVES_ERRNO=[01] if the 'free' function munges or preserves errno +# (default is guessed) +# -DHAVE_DECL_ASCTIME_R=0 if does not declare asctime_r +# on POSIX platforms predating POSIX.1-2024 +# -DHAVE_DECL_ENVIRON if declares 'environ' +# -DHAVE_DECL_TIMEGM=0 if does not declare timegm +# -DHAVE_DIRECT_H if mkdir needs (MS-Windows) +# -DHAVE_FCHMOD=0 if your system lacks the fchmod function +# -DHAVE__GENERIC=0 if _Generic does not work* +# -DHAVE_GETEUID=0 if gete?[ug]id do not work +# -DHAVE_GETRANDOM if getrandom works (e.g., GNU/Linux), +# -DHAVE_GETRANDOM=0 to avoid using getrandom +# -DHAVE_GETRESUID=0 if getres[ug]id do not work +# -DHAVE_GETTEXT if gettext works (e.g., GNU/Linux, FreeBSD, Solaris), +# where LDLIBS also needs to contain -lintl on some hosts; +# -DHAVE_GETTEXT=0 to avoid using gettext +# -DHAVE_INCOMPATIBLE_CTIME_R if your system's time.h declares +# ctime_r and asctime_r incompatibly with POSIX.1-2017 and earlier +# (Solaris when _POSIX_PTHREAD_SEMANTICS is not defined). +# -DHAVE_INTTYPES_H=0 if does not work*+ +# -DHAVE_ISSETUGID=1 if issetugid works, 0 otherwise (default is guessed) +# If 0, you may also use -DHAVE_SYS_AUXV_H=1 if works, +# 0 otherwise (default is guessed). +# -DHAVE_LINK=0 if your system lacks a link function +# -DHAVE_LOCALTIME_R=0 if your system lacks a localtime_r function +# -DHAVE_LOCALTIME_RZ=0 if you do not want zdump to use localtime_rz +# localtime_rz can make zdump significantly faster, but is nonstandard. +# -DHAVE_MALLOC_ERRNO=0 if malloc etc. do not set errno on failure. +# -DHAVE_MEMPCPY=1 if your system has mempcpy, 0 if not (default is guessed) +# -DHAVE_POSIX_DECLS=0 if your system's include files do not declare +# variables like 'tzname' required by POSIX +# -DHAVE_PWD_H=0 if your system lacks pwd.h, grp.h and corresponding functions +# If 0, you may also need -Dgid_t=G -Duid_t=U +# to define gid_t and uid_t to be types G and U. +# -DHAVE_SETENV=0 if your system lacks the setenv function +# -DHAVE_SETMODE=[01] if your system lacks or has the setmode and getmode +# functions (default is guessed) +# -DHAVE_SNPRINTF=0 if your system lacks the snprintf function+ +# -DHAVE_STDCKDINT_H=0 if neither nor substitutes like +# __builtin_add_overflow work* +# -DHAVE_STDINT_H=0 if does not work*+ +# -DHAVE_STRFTIME_L if declares locale_t and strftime_l +# -DHAVE_STRDUP=0 if your system lacks the strdup function +# -DHAVE_STRNLEN=0 if your system lacks the strnlen function+ +# -DHAVE_STRTOLL=0 if your system lacks the strtoll function+ - # -DHAVE_STRUCT_STAT_ST_CTIM=0 if struct stat lacks a member st_ctim+ ++# -DHAVE_STRUCT_STAT_ST_CTIM=0 if struct stat lacks a status-change member ++# of type struct timespec, so code should use st_ctime instead; ++# but if the status-change member name is st_ctimespec, ++# use -Dst_ctim=st_ctimespec instead (default is guessed)+ +# -DHAVE_STRUCT_TIMESPEC=0 if your system lacks struct timespec+ +# -DHAVE_SYMLINK=0 if your system lacks the symlink function +# -DHAVE_SYS_STAT_H=0 if does not work* +# If 0, you may also need -Dmode_t=M to define mode_t to be type M. +# -DHAVE_TZSET=0 if your system lacks a tzset function +# -DHAVE_UNISTD_H=0 if does not work* +# -DHAVE_UTMPX_H=0 if does not work* +# -Dlocale_t=XXX if your system uses XXX instead of locale_t +# -DMKTIME_MIGHT_OVERFLOW if mktime might fail due to time_t overflow +# -DOPENAT_TZDIR if tzset should use openat on TZDIR then a relative open. +# See localtime.c for details. +# -DPORT_TO_C89 if tzcode should also run on mostly-C89 platforms+ +# Typically it is better to use a later standard. For example, +# with GCC 4.9.4 (2016), prefer '-std=gnu11' to '-DPORT_TO_C89'. +# Even with -DPORT_TO_C89, the code needs at least one C99 +# feature (integers at least 64 bits wide) and maybe more. +# -DRESERVE_STD_EXT_IDS if your platform reserves standard identifiers +# with external linkage, e.g., applications cannot define 'localtime'. +# -Dssize_t=int on hosts like MS-Windows that lack ssize_t +# -DSUPPORT_C89=0 if the tzcode library should not support C89 callers +# Although -DSUPPORT_C89=0 might work around latent bugs in callers, +# it does not conform to POSIX. +# -DSUPPORT_POSIX2008 if the library should support older POSIX callers+ +# However, this might cause problems in POSIX.1-2024-or-later callers. +# -DSUPPRESS_TZDIR to not prepend TZDIR to file names; this has +# security implications and is not recommended for general use +# -DTHREAD_SAFE to make localtime.c thread-safe, as POSIX requires; +# not needed by the main-program tz code, which is single-threaded. +# Append other compiler flags as needed, e.g., -pthread on GNU/Linux. +# The following options can also be used: +# -DTHREAD_PREFER_SINGLE to prefer speed in single-threaded apps, +# at some cost in CPU time and energy in multi-threaded apps. +# The following options can also be used: +# -DHAVE___ISTHREADED=1 if there is an extern int __isthreaded +# variable, 0 otherwise (default is guessed) +# -DHAVE_SYS_SINGLE_THREADED_H=0 if works, +# 0 otherwise (default is guessed) - # -DTHREAD_RWLOCK to use read-write locks intead of mutexes. - # This can improve paralellism and thus save real time ++# -DTHREAD_RWLOCK to use read-write locks instead of mutexes. ++# This can improve parallelism and thus save real time +# if many threads call tzcode functions simultaneously. +# It also costs CPU time and thus energy. +# -DTHREAD_TM_MULTI to have gmtime, localtime, and offtime +# return different struct tm * addresses in different threads. - # This supports unportable programs that call ++# This supports nonportable programs that call +# gmtime/localtime/offtime when they should call +# gmtime_r/localtime_r/offtime_r to avoid races. +# Because the corresponding storage is freed on thread exit, +# this option is incompatible with POSIX.1-2024 and earlier. +# It also costs CPU time and memory. +# -Dtime_tz=\"T\" to use T as the time_t type, rather than the system time_t +# This is intended for internal use only; it mangles external names. +# -DTZ_CHANGE_INTERVAL=N if functions depending on TZ should check +# no more often than every N seconds for TZif file changes. +# If N is negative (the default), no such checking is done. +# This option is intended for platforms that want localtime etc. +# to respond to changes to a file selected by TZ, including to +# TZDEFAULT (normally /etc/localtime) if TZ is unset. +# On these platforms, REDO should be "posix_only" or "posix_right". +# This option does not affect tzalloc-allocated objects. +# -DTZ_DOMAIN=\"foo\" to use "foo" for gettext domain name; default is "tz" +# -DTZ_DOMAINDIR=\"/path\" to use "/path" for gettext directory; +# the default is system-supplied, typically "/usr/lib/locale" ++# -DTZ_RUNTIME_LEAPS=0 to disable runtime support for leap seconds. ++# This conforms to POSIX, shrinks tzcode's attack surface, ++# and is more efficient. However, it fails to support Internet ++# RFC 9636's leap seconds. +# -DTZDEFRULESTRING=\",date/time,date/time\" to default to the specified - # DST transitions for proleptic format TZ strings lacking them, - # in the usual case where POSIXRULES is '-'. If not specified, - # TZDEFRULESTRING defaults to US rules for future DST transitions. ++# DST transitions for proleptic format TZ strings lacking them. ++# If not specified, it defaults to US rules for future DST transitions. +# This mishandles some past timestamps, as US DST rules have changed. +# It also mishandles settings like TZ='EET-2EEST' for eastern Europe, +# as Europe and US DST rules differ. +# -DTZNAME_MAXIMUM=N to limit time zone abbreviations to N bytes (default 254) +# -DUNINIT_TRAP if reading uninitialized storage can cause problems +# other than simply getting garbage data +# -DUSE_LTZ=0 to build zdump with the system time zone library +# Also set TZDOBJS=zdump.o and CHECK_TIME_T_ALTERNATIVES= below. +# -DZIC_BLOAT_DEFAULT=\"fat\" to default zic's -b option to "fat", and +# similarly for "slim". Fat TZif files work around incompatibilities +# and bugs in some TZif readers, notably older ones that +# ignore or otherwise mishandle 64-bit data in TZif files; +# however, fat TZif files may trigger bugs in newer TZif readers. +# Slim TZif files are more efficient, and are the default. +# -DZIC_MAX_ABBR_LEN_WO_WARN=3 +# (or some other number) to set the maximum time zone abbreviation length +# that zic will accept without a warning (the default is 6) +# -g to generate symbolic debugging info +# -Idir to include from directory 'dir' +# -O0 to disable optimization; other -O options to enable more optimization +# -Uname to remove any definition of the macro 'name' +# $(GCC_DEBUG_FLAGS) if you are using recent GCC and want lots of checking +# +# * Options marked "*" can be omitted if your compiler is C23 compatible. +# * Options marked "+" are obsolescent and are planned to be removed +# once the code assumes C99 or later (say in the year 2029) +# and POSIX.1-2024 or later (say in the year 2034). +# +# Select instrumentation via "make GCC_INSTRUMENT='whatever'". +GCC_INSTRUMENT = \ + -fsanitize=undefined -fsanitize-address-use-after-scope \ + -fsanitize-trap=all -fstack-protector +# Omit -fanalyzer from GCC_DEBUG_FLAGS, as it makes GCC too slow. +GCC_DEBUG_FLAGS = -DGCC_LINT -g3 -O3 \ + $(GCC_INSTRUMENT) \ + -Wall -Wextra \ + -Walloc-size-larger-than=100000 -Warray-bounds=2 \ + -Wbad-function-cast -Wbidi-chars=any,ucn -Wcast-align=strict -Wcast-qual \ + -Wdate-time \ + -Wdeclaration-after-statement -Wdouble-promotion \ + -Wduplicated-branches -Wduplicated-cond -Wflex-array-member-not-at-end \ + -Wformat=2 -Wformat-overflow=2 -Wformat-signedness -Wformat-truncation \ + -Wimplicit-fallthrough=5 -Winit-self -Wlogical-op \ + -Wmissing-declarations -Wmissing-prototypes \ + -Wmissing-variable-declarations -Wnested-externs \ + -Wnull-dereference \ + -Wold-style-definition -Woverlength-strings -Wpointer-arith \ + -Wshadow -Wshift-overflow=2 -Wstrict-overflow \ + -Wstrict-prototypes -Wstringop-overflow=4 \ - -Wstringop-truncation -Wsuggest-attribute=cold \ ++ -Wsuggest-attribute=cold \ + -Wsuggest-attribute=const -Wsuggest-attribute=format \ + -Wsuggest-attribute=malloc \ + -Wsuggest-attribute=noreturn -Wsuggest-attribute=pure \ + -Wtrampolines -Wundef -Wunused-macros -Wuse-after-free=3 \ + -Wvariadic-macros -Wvla -Wwrite-strings \ ++ -Wzero-as-null-pointer-constant \ + -Wno-format-nonliteral -Wno-sign-compare -Wno-type-limits +# +# If your system has a "GMT offset" field in its "struct tm"s +# (or if you decide to add such a field in your system's "time.h" file), +# add the name to a define such as +# -DTM_GMTOFF=tm_gmtoff +# to the end of the "CFLAGS=" line. If not defined, the code attempts to +# guess TM_GMTOFF from other macros; define NO_TM_GMTOFF to suppress this. +# Similarly, if your system has a "zone abbreviation" field, define +# -DTM_ZONE=tm_zone +# and define NO_TM_ZONE to suppress any guessing. +# Although POSIX.1-2024 requires these fields and they are widely available +# on GNU/Linux and BSD systems, some older systems lack them. +# +# The next batch of options control support for external variables +# exported by tzcode. In practice these variables are less useful +# than TM_GMTOFF and TM_ZONE. However, most of them are standardized. +# # +# # To omit or support the external variable "tzname", add one of: +# # -DHAVE_TZNAME=0 # do not support "tzname" +# # -DHAVE_TZNAME=1 # support "tzname", which is defined by system library +# # -DHAVE_TZNAME=2 # support and define "tzname" +# # to the "CFLAGS=" line. Although "tzname" is required by POSIX.1-1988 +# # and later, its contents are unspecified if you use a geographical TZ +# # and the variable is planned to be removed in a future POSIX edition. +# # If not defined, the code attempts to guess HAVE_TZNAME from other macros. +# # Warning: unless time_tz is also defined, HAVE_TZNAME=1 can cause +# # crashes when combined with some platforms' standard libraries, +# # presumably due to memory allocation issues. +# # +# # To omit or support the external variables "timezone" and "daylight", add +# # -DUSG_COMPAT=0 # do not support +# # -DUSG_COMPAT=1 # support, and variables are defined by system library +# # -DUSG_COMPAT=2 # support and define variables +# # to the "CFLAGS=" line; "timezone" and "daylight" are inspired by Unix +# # Systems Group code and are required by POSIX.1-2008 and later (with XSI), +# # although their contents are unspecified if you use a geographical TZ +# # and the variables are planned to be removed in a future edition of POSIX. +# # If not defined, the code attempts to guess USG_COMPAT from other macros. +# # +# # To support the external variable "altzone", add +# # -DALTZONE=0 # do not support +# # -DALTZONE=1 # support "altzone", which is defined by system library +# # -DALTZONE=2 # support and define "altzone" +# # to the end of the "CFLAGS=" line; although "altzone" appeared in +# # System V Release 3.1 it has not been standardized. +# # If not defined, the code attempts to guess ALTZONE from other macros. +# +# If you want functions that were inspired by early versions of X3J11's work, +# add +# -DSTD_INSPIRED +# to the end of the "CFLAGS=" line. This arranges for the following +# functions to be added to the time conversion library. +# "offtime" is like "gmtime" except that it accepts a second (long) argument +# that gives an offset to add to the time_t when converting it. +# "offtime_r" is to "offtime" what "gmtime_r" is to "gmtime". +# I.e., "offtime" and "offtime_r" are like calling "localtime_rz" +# with a fixed-offset zone. +# "timelocal" is nearly equivalent to "mktime". +# "timeoff" is like "timegm" except that it accepts a second (long) argument +# that gives an offset to use when converting to a time_t. +# I.e., "timeoff" is like calling "mktime_z" with a fixed-offset zone. +# "posix2time" and "time2posix" are described in an included manual page. +# X3J11's work does not describe any of these functions. +# These functions may well disappear in future releases of the time +# conversion package. +# +# If you don't want functions that were inspired by NetBSD, add +# -DNETBSD_INSPIRED=0 +# to the end of the "CFLAGS=" line. Otherwise, the functions +# "localtime_rz", "mktime_z", "tzalloc", and "tzfree" are added to the +# time library, and if STD_INSPIRED is also defined to nonzero the functions +# "posix2time_z" and "time2posix_z" are added as well. +# The functions ending in "_z" (or "_rz") are like their unsuffixed +# (or suffixed-by-"_r") counterparts, except with an extra first +# argument of opaque type timezone_t that specifies the timezone. +# "tzalloc" allocates a timezone_t value, and "tzfree" frees it. +# +# If you want to allocate state structures in localtime, add +# -DALL_STATE +# to the end of the "CFLAGS=" line. Storage is obtained by calling malloc. +# +# NIST-PCTS:151-2, Version 1.4, (1993-12-03) is a test suite put +# out by the National Institute of Standards and Technology +# which claims to test C and POSIX conformance. If you want to pass PCTS, add +# -DPCTS +# to the end of the "CFLAGS=" line. +# +# If you want strict compliance with XPG4 as of 1994-04-09, add +# -DXPG4_1994_04_09 +# to the end of the "CFLAGS=" line. This causes "strftime" to always return +# 53 as a week number (rather than 52 or 53) for January days before +# January's first Monday when a "%V" format is used and January 1 +# falls on a Friday, Saturday, or Sunday. +# +# POSIX says CFLAGS defaults to "-O 1". +# Uncomment the following line and edit its contents as needed. + +#CFLAGS= -O 1 + + +# The name of a POSIX-like library archiver, its flags, C compiler, +# linker flags, and 'make' utility. Ordinarily the defaults suffice. +# The commented-out values are the defaults specified by POSIX.1-2024. +#AR = ar +#ARFLAGS = -rv +#CC = c17 +#LDFLAGS = +#MAKE = make + +# Where to fetch leap-seconds.list from. +leaplist_URI = \ + https://hpiers.obspm.fr/iers/bul/bulc/ntp/leap-seconds.list +# The file is generated by the IERS Earth Orientation Centre, in Paris. +leaplist_TZ = Europe/Paris +# +# To fetch leap-seconds.list from NIST via a less-secure protocol +# and with less-volatile metadata, use these settings: +#leaplist_URI = ftp://ftp.boulder.nist.gov/pub/time/leap-seconds.list +#leaplist_TZ = America/Denver + +# The zic command and its arguments. + +zic= ./zic +ZIC= $(zic) $(ZFLAGS) + +# To shrink the size of installed TZif files, +# append "-r @N" to omit data before N-seconds-after-the-Epoch. +# To grow the files and work around bugs in older applications, +# possibly at the expense of introducing bugs in newer ones, +# append "-b fat"; see ZIC_BLOAT_DEFAULT above. +# See the zic man page for more about -b and -r. +ZFLAGS= + +# How to use zic to install TZif files. + +ZIC_INSTALL= $(ZIC) -d '$(DESTDIR)$(TZDIR)' + +# The name of a POSIX-compliant 'awk' on your system. +# mawk 1.3.3 and Solaris 10 /usr/bin/awk do not work. +# Also, it is better (though not essential) if 'awk' supports UTF-8, +# and unfortunately mawk and busybox awk do not support UTF-8. +# Try AWK=gawk or AWK=nawk if your awk has the abovementioned problems. +AWK= awk + +# The full path name of a POSIX-compliant shell, preferably one that supports +# the Korn shell's 'select' statement as an extension. +# These days, Bash is the most popular. +# It should be OK to set this to /bin/sh, on platforms where /bin/sh +# lacks 'select' or doesn't completely conform to POSIX, but /bin/bash +# is typically nicer if it works. +KSHELL= /bin/bash + +# Name of curl , used for HTML validation +# and to fetch leap-seconds.list from upstream. +# Set CURL=: to disable use of the Internet. +CURL= curl + +# Name of GNU Privacy Guard , used to sign distributions. +GPG= gpg + +# This expensive test requires USE_LTZ. +# To suppress it, define this macro to be empty. +CHECK_TIME_T_ALTERNATIVES = check_time_t_alternatives + +# SAFE_CHAR is a regular expression that matches a safe character. +# Some parts of this distribution are limited to safe characters; +# others can use any UTF-8 character. +# For now, the safe characters are a safe subset of ASCII. +# The caller must set the shell variable 'sharp' to the character '#', +# since Makefile macros cannot contain '#'. +# TAB_CHAR is a single tab character, in single quotes. +TAB_CHAR= ' ' +SAFE_CHARSET1= $(TAB_CHAR)' !\"'$$sharp'$$%&'\''()*+,./0123456789:;<=>?@' +SAFE_CHARSET2= 'ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\^_`' +SAFE_CHARSET3= 'abcdefghijklmnopqrstuvwxyz{|}~' +SAFE_CHARSET= $(SAFE_CHARSET1)$(SAFE_CHARSET2)$(SAFE_CHARSET3) +SAFE_CHAR= '[]'$(SAFE_CHARSET)'-]' + +# These non-alphabetic, non-ASCII printable characters are +# used in commentary or in generated *.txt files +# and are not likely to cause confusion. +UNUSUAL_OK_CHARSET= §«°±»½¾×–‘’“”•→−≤★⟨⟩⯪ + +# Put this in a bracket expression to match spaces. +s = [:space:] + +# OK_CHAR matches any character allowed in the distributed files. +# This is the same as SAFE_CHAR, except that UNUSUAL_OK_CHARSET and +# multibyte letters are also allowed so that commentary can contain a +# few safe symbols and people's names and can quote non-English sources. +OK_CHAR= '[][:alpha:]$(UNUSUAL_OK_CHARSET)'$(SAFE_CHARSET)'-]' + +# SAFE_LINE matches a line of safe characters. +# SAFE_SHARP_LINE is similar, except any OK character can follow '#'; +# this is so that comments can contain non-ASCII characters. +# OK_LINE matches a line of OK characters. +SAFE_LINE= '^'$(SAFE_CHAR)'*$$' +SAFE_SHARP_LINE='^'$(SAFE_CHAR)'*('$$sharp$(OK_CHAR)'*)?$$' +OK_LINE= '^'$(OK_CHAR)'*$$' + +# Flags to give 'tar' when making a distribution. +# Try to use flags appropriate for GNU tar. +GNUTARFLAGS= --format=pax --pax-option=delete=atime,delete=ctime \ + --numeric-owner --owner=0 --group=0 \ + --mode=go+u,go-w --sort=name +SETUP_TAR= \ + export LC_ALL=C && \ + if tar $(GNUTARFLAGS) --version >/dev/null 2>&1; then \ + TAR='tar $(GNUTARFLAGS)'; \ + else \ + TAR=tar; \ + fi + +# Flags to give 'gzip' when making a distribution. +GZIPFLAGS= -9n + +# When comparing .tzs files, use GNU diff's -F'^TZ=' option if supported. +# This makes it easier to see which Zone has been affected. +SETUP_DIFF_TZS = \ + if diff -u -F'^TZ=' - - <>/dev/null >&0 2>&1; then \ + DIFF_TZS='diff -u -F^TZ='; \ + else \ + DIFF_TZS='diff -u'; \ + fi + +# ':' on typical hosts; 'ranlib' on the ancient hosts that still need ranlib. +RANLIB= : + +# POSIX prohibits defining or using SHELL. However, csh users on systems +# that use the user shell for Makefile commands may need to define SHELL. +#SHELL= /bin/sh + +# End of macros that one plausibly might want to tailor. +############################################################################### + + +TZCOBJS= zic.o +TZDOBJS= zdump.o localtime.o strftime.o +DATEOBJS= date.o localtime.o strftime.o +LIBSRCS= localtime.c asctime.c difftime.c strftime.c +LIBOBJS= localtime.o asctime.o difftime.o strftime.o +HEADERS= tzfile.h private.h +NONLIBSRCS= zic.c zdump.c +NEWUCBSRCS= date.c +SOURCES= $(HEADERS) $(LIBSRCS) $(NONLIBSRCS) $(NEWUCBSRCS) \ + tzselect.ksh workman.sh +MANS= newctime.3 newstrftime.3 newtzset.3 time2posix.3 \ + tzfile.5 tzselect.8 zic.8 zdump.8 +MANTXTS= newctime.3.txt newstrftime.3.txt newtzset.3.txt \ + time2posix.3.txt \ + tzfile.5.txt tzselect.8.txt zic.8.txt zdump.8.txt \ + date.1.txt +COMMON= calendars CONTRIBUTING LICENSE Makefile \ + NEWS README SECURITY theory.html version +WEB_PAGES= tz-art.html tz-how-to.html tz-link.html +CHECK_WEB_PAGES=theory.ck tz-art.ck tz-how-to.ck tz-link.ck +DOCS= $(MANS) date.1 $(MANTXTS) $(WEB_PAGES) +PRIMARY_YDATA= africa antarctica asia australasia \ + europe northamerica southamerica +YDATA= $(PRIMARY_YDATA) etcetera +NDATA= factory +TDATA_TO_CHECK= $(YDATA) $(NDATA) backward +TDATA= $(YDATA) $(NDATA) $(BACKWARD) +ZONETABLES= zone.tab zone1970.tab zonenow.tab +TABDATA= iso3166.tab $(TZDATA_TEXT) $(ZONETABLES) +LEAP_DEPS= leapseconds.awk leap-seconds.list +TZDATA_ZI_DEPS= ziguard.awk zishrink.awk version $(TDATA) \ + $(PACKRATDATA) $(PACKRATLIST) +DSTDATA_ZI_DEPS= ziguard.awk $(TDATA) $(PACKRATDATA) $(PACKRATLIST) +DATA= $(TDATA_TO_CHECK) backzone iso3166.tab leap-seconds.list \ + leapseconds $(ZONETABLES) +AWK_SCRIPTS= checklinks.awk checknow.awk checktab.awk leapseconds.awk \ + ziguard.awk zishrink.awk +MISC= $(AWK_SCRIPTS) +TZS_YEAR= 2050 +TZS_CUTOFF_FLAG= -c $(TZS_YEAR) +TZS= to$(TZS_YEAR).tzs +TZS_NEW= to$(TZS_YEAR)new.tzs +TZS_DEPS= $(YDATA) localtime.c private.h \ + strftime.c tzfile.h zdump.c zic.c +TZDATA_DIST = $(COMMON) $(DATA) $(MISC) +# EIGHT_YARDS is just a yard short of the whole ENCHILADA. +EIGHT_YARDS = $(TZDATA_DIST) $(DOCS) $(SOURCES) tzdata.zi +ENCHILADA = $(EIGHT_YARDS) $(TZS) + +# Consult these files when deciding whether to rebuild the 'version' file. +# This list is not the same as the output of 'git ls-files', since +# .gitignore is not distributed. +VERSION_DEPS= \ + calendars CONTRIBUTING LICENSE Makefile NEWS README SECURITY \ + africa antarctica asctime.c asia australasia \ + backward backzone \ + checklinks.awk checknow.awk checktab.awk \ + date.1 date.c difftime.c \ + etcetera europe factory iso3166.tab \ + leap-seconds.list leapseconds.awk localtime.c \ + newctime.3 newstrftime.3 newtzset.3 northamerica \ + private.h southamerica strftime.c theory.html \ + time2posix.3 tz-art.html tz-how-to.html tz-link.html \ + tzfile.5 tzfile.h tzselect.8 tzselect.ksh \ + workman.sh zdump.8 zdump.c zic.8 zic.c \ + ziguard.awk zishrink.awk \ + zone.tab zone1970.tab zonenow.tab + +all: tzselect zic zdump libtz.a $(TABDATA) \ + vanguard.zi main.zi rearguard.zi + +ALL: all date $(ENCHILADA) + +install: all $(DATA) $(REDO) $(MANS) + mkdir -p '$(DESTDIR)$(BINDIR)' \ + '$(DESTDIR)$(ZDUMPDIR)' '$(DESTDIR)$(ZICDIR)' \ + '$(DESTDIR)$(LIBDIR)' \ + '$(DESTDIR)$(MANDIR)/man3' '$(DESTDIR)$(MANDIR)/man5' \ + '$(DESTDIR)$(MANDIR)/man8' + $(ZIC_INSTALL) -l $(LOCALTIME) \ - -p $(POSIXRULES) \ + -t '$(DESTDIR)$(TZDEFAULT)' + cp -f $(TABDATA) '$(DESTDIR)$(TZDIR)/.' + cp tzselect '$(DESTDIR)$(BINDIR)/.' + cp zdump '$(DESTDIR)$(ZDUMPDIR)/.' + cp zic '$(DESTDIR)$(ZICDIR)/.' + cp libtz.a '$(DESTDIR)$(LIBDIR)/.' + $(RANLIB) '$(DESTDIR)$(LIBDIR)/libtz.a' + cp -f newctime.3 newtzset.3 '$(DESTDIR)$(MANDIR)/man3/.' + cp -f tzfile.5 '$(DESTDIR)$(MANDIR)/man5/.' + cp -f tzselect.8 zdump.8 zic.8 '$(DESTDIR)$(MANDIR)/man8/.' + +INSTALL: ALL install date.1 + mkdir -p '$(DESTDIR)$(BINDIR)' '$(DESTDIR)$(MANDIR)/man1' + cp date '$(DESTDIR)$(BINDIR)/.' + cp -f date.1 '$(DESTDIR)$(MANDIR)/man1/.' + +# Calculate version number from git, if available. +# Otherwise, use $(VERSION) unless it is "unknown" and there is already +# a 'version' file, in which case reuse the existing 'version' contents +# and append "-dirty" if the contents do not already end in "-dirty". +version: $(VERSION_DEPS) + { (type git) >/dev/null 2>&1 && \ + V=$$(git describe --match '[0-9][0-9][0-9][0-9][a-z]*' \ + --abbrev=7 --dirty) || \ + if test '$(VERSION)' = unknown && read -r V <$@; then \ + V=$${V%-dirty}-dirty; \ + else \ + V='$(VERSION)'; \ + fi; } && \ + printf '%s\n' "$$V" >$@.out + mv $@.out $@ + +# These files can be tailored by setting BACKWARD, PACKRATDATA, PACKRATLIST. +vanguard.zi main.zi rearguard.zi: $(DSTDATA_ZI_DEPS) + $(AWK) \ + -v DATAFORM=$(@:.zi=) \ + -v PACKRATDATA='$(PACKRATDATA)' \ + -v PACKRATLIST='$(PACKRATLIST)' \ + -f ziguard.awk \ + $(TDATA) $(PACKRATDATA) >$@.out + mv $@.out $@ +# This file has a version comment that attempts to capture any tailoring +# via BACKWARD, DATAFORM, PACKRATDATA, PACKRATLIST, and REDO. +tzdata.zi: $(DATAFORM).zi version zishrink.awk + read -r version $@.out + mv $@.out $@ + +tzdir.h: + printf '%s\n' >$@.out \ + '#ifndef TZDEFAULT' \ + '# define TZDEFAULT "$(TZDEFAULT)" /* default zone */' \ + '#endif' \ + '#ifndef TZDIR' \ + '# define TZDIR "$(TZDIR)" /* TZif directory */' \ + '#endif' + mv $@.out $@ + +version.h: version + read -r VERSION $@.out + mv $@.out $@ + +zdump: $(TZDOBJS) + $(CC) -o $@ $(CFLAGS) $(LDFLAGS) $(TZDOBJS) $(LDLIBS) + +zic: $(TZCOBJS) + $(CC) -o $@ $(CFLAGS) $(LDFLAGS) $(TZCOBJS) $(LDLIBS) + +leapseconds: $(LEAP_DEPS) + $(AWK) -v EXPIRES_LINE=$(EXPIRES_LINE) \ + -f leapseconds.awk leap-seconds.list >$@.out + mv $@.out $@ + +# Awk script to extract a Git-style author from leap-seconds.list comments. +EXTRACT_AUTHOR = \ + author_line { sub(/^.[[:space:]]*/, ""); \ + sub(/:[[:space:]]*/, " <"); \ + printf "%s>\n", $$0; \ + success = 1; \ + exit \ + } \ + /Questions or comments to:/ { author_line = 1 } \ + END { exit !success } + +# Fetch leap-seconds.list from upstream. +fetch-leap-seconds.list: + $(CURL) -OR $(leaplist_URI) + +# Fetch leap-seconds.list from upstream and commit it to the local repository. +commit-leap-seconds.list: fetch-leap-seconds.list + author=$$($(AWK) '$(EXTRACT_AUTHOR)' leap-seconds.list) && \ + date=$$(TZ=$(leaplist_TZ) stat -c%y leap-seconds.list) && \ + git commit --author="$$author" --date="$$date" -m'make $@' \ + leap-seconds.list + +# Arguments to pass to submakes. +# They can be overridden by later submake arguments. +INSTALLARGS = \ + BACKWARD='$(BACKWARD)' \ + DESTDIR='$(DESTDIR)' \ + PACKRATDATA='$(PACKRATDATA)' \ + PACKRATLIST='$(PACKRATLIST)' \ + TZDEFAULT='$(TZDEFAULT)' \ + TZDIR='$(TZDIR)' \ + ZIC='$(ZIC)' + +INSTALL_DATA_DEPS = zic leapseconds tzdata.zi + +posix_only: $(INSTALL_DATA_DEPS) + $(ZIC_INSTALL) tzdata.zi + +right_only: $(INSTALL_DATA_DEPS) + $(ZIC_INSTALL) -L leapseconds tzdata.zi + +# In earlier versions of this makefile, the other two directories were +# subdirectories of $(TZDIR). However, this led to configuration errors. +# For example, with posix_right under the earlier scheme, +# TZ='right/Australia/Adelaide' got you localtime with leap seconds, +# but gmtime without leap seconds, which led to problems with applications +# like sendmail that subtract gmtime from localtime. +# Therefore, the other two directories are now siblings of $(TZDIR). +# You must replace all of $(TZDIR) to switch from not using leap seconds +# to using them, or vice versa. +right_posix: right_only + rm -fr '$(DESTDIR)$(TZDIR)-leaps' + ln -s '$(TZDIR_BASENAME)' '$(DESTDIR)$(TZDIR)-leaps' || \ + $(MAKE) $(INSTALLARGS) TZDIR='$(TZDIR)-leaps' right_only + $(MAKE) $(INSTALLARGS) TZDIR='$(TZDIR)-posix' posix_only + +posix_right: posix_only + rm -fr '$(DESTDIR)$(TZDIR)-posix' + ln -s '$(TZDIR_BASENAME)' '$(DESTDIR)$(TZDIR)-posix' || \ + $(MAKE) $(INSTALLARGS) TZDIR='$(TZDIR)-posix' posix_only + $(MAKE) $(INSTALLARGS) TZDIR='$(TZDIR)-leaps' right_only + +zones: $(REDO) + +# dummy.zd is not a real file; it is mentioned here only so that the +# top-level 'make' does not have a syntax error. +ZDS = dummy.zd +# Rule used only by submakes invoked by the $(TZS_NEW) rule. +# It is separate so that GNU 'make -j' can run instances in parallel. +$(ZDS): zdump + ./zdump -i $(TZS_CUTOFF_FLAG) "$$PWD/$(@:.zd=)" >$@ + +TZS_NEW_DEPS = tzdata.zi zdump zic +$(TZS_NEW): $(TZS_NEW_DEPS) + rm -fr tzs$(TZS_YEAR).dir + mkdir tzs$(TZS_YEAR).dir + $(zic) -d tzs$(TZS_YEAR).dir tzdata.zi + $(AWK) '/^L/{print "Link\t" $$2 "\t" $$3}' \ + tzdata.zi | LC_ALL=C sort >$@.out + x=$$($(AWK) '/^Z/{print "tzs$(TZS_YEAR).dir/" $$2 ".zd"}' \ + tzdata.zi \ + | LC_ALL=C sort -t . -k 2,2) && \ + set x $$x && \ + shift && \ + ZDS=$$* && \ + $(MAKE) TZS_CUTOFF_FLAG="$(TZS_CUTOFF_FLAG)" \ + ZDS="$$ZDS" $$ZDS && \ + sed 's,^TZ=".*\.dir/,TZ=",' $$ZDS >>$@.out + rm -fr tzs$(TZS_YEAR).dir + mv $@.out $@ + +# If $(TZS) exists but 'make tzs.ck' fails, a maintainer should inspect the +# failed output and fix the inconsistency, perhaps by running 'make force_tzs'. +$(TZS): + touch $@ + +force_tzs: $(TZS_NEW) + cp $(TZS_NEW) $(TZS) + +libtz.a: $(LIBOBJS) + rm -f $@ + $(AR) $(ARFLAGS) $@ $(LIBOBJS) + $(RANLIB) $@ + +date: $(DATEOBJS) + $(CC) -o $@ $(CFLAGS) $(LDFLAGS) $(DATEOBJS) $(LDLIBS) + +tzselect: tzselect.ksh version + read -r VERSION $@.out + chmod +x $@.out + mv $@.out $@ + +check: check_mild back.ck now.ck +check_mild: check_web check_zishrink \ + character-set.ck white-space.ck links.ck mainguard.ck \ + name-lengths.ck slashed-abbrs.ck sorted.ck \ + tables.ck ziguard.ck tzs.ck + +# True if UTF8_LOCALE does not work; +# otherwise, false but with LC_ALL set to $(UTF8_LOCALE). *** 527 LINES SKIPPED *** From nobody Tue Mar 3 04:10:30 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQ2QZ4sf6z6Tj3j for ; Tue, 03 Mar 2026 04:10: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQ2QZ49LPz46Gy for ; Tue, 03 Mar 2026 04:10:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772511030; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qpJCWyECM5yiVRPeVSuWzO//HzluaFVxVSNkvAJ8lYY=; b=b3FxaS+jV5Pqbf76bZnub7X2wQNZ0oRCtZj8c7bqQS7850A7+8RlhKTsfIRurlo5sJlEVv mpr+1PB+KVDgxJOWWtaEgFDCLQgI1hb96v/Gu+0InXXMfD/zX4rmPtxzHNNDFlOHw4D9ro Nkpjm7hkPnjTMCUr0aOTmFPi2sULH+MyrDA4yBntYgHRaWwwYUHdmMDaW7zIbIaIoiG62E eWWKqv+gJ4Wjdd6DiTtLPul6WaqajTvJbe1hDcY5EMlzNgwFnIbem+WR6TFqtvlahm1NTf TUgDXLffx+uMQHnSluqfPKMD1pe+KZ1eT6zzIJ7lYqcZuO2ceazBhCmt+6EJfQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772511030; a=rsa-sha256; cv=none; b=pIhVGivU6L0CpSWU27D+RTt+fJaZqwEOCSIZVVfThjbiU28JZkSwxaEI5p3N25JFweJq+K RCFGhwnJFeDh8v7VRmoKpy+vNQIy3xI+4j6eraWYQ1Lsb5JAEsyUbbLbToxoXgowHmQSMk 4oSv1BgH9vqYDSbGIBIypnr9XB2UTI49FuDvNijqfKsVnKKho+skRUWswv6q7eF4l06h9/ Ov2lRpLB5PaVQ2xbOFokwmizVFON1Y1RdQk+v3YUzsJWf85hFs4Icq4XyLqCpc3Osir2q8 EcpHDnLmAgzH89G8uND0SdP81uAjr8Iv1ESKTUtil6CEdDdT4IDSeO+vLXFzNA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772511030; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qpJCWyECM5yiVRPeVSuWzO//HzluaFVxVSNkvAJ8lYY=; b=AuLhY427sMtqrcPA5AeyL3FCyAHTkriP9H5h/nyLShm8LG3ZOq1ztpU74QwrNu7JZ4gkIW vIxOtx93QJiGH0Uig7xAgfwKqviESwchb5zztondVy2ZCX8OoyBCPoGcj1ZI+O5GYFvI8g uMXN/wd7x+2m106kgAgtWdusBX8xotdA/UecORHrXVKmPgyzs592flVWghUN/Dycu7aCux 6DlrSLjSYmM82Pcns9pl6rKn+RyNDe5yGugtMb+x9H5dcjgYQRsnRlJzj5crBWCc4c+Jxm uL3PGVe2aeA0yJGmLlYFqxf6XJ6OhwCwEHQcN9XHWtYGw87l4wm7X6eAHFcwGw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQ2QZ3VpDz14WK for ; Tue, 03 Mar 2026 04:10:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 32640 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 04:10:30 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Enji Cooper Subject: git: 876d2b8392e6 - main - acpi: build dev/acpi_support/acpi_wmi_if.m on ARM64 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 876d2b8392e6570a835a500d8fd7c4a5b0abf844 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 04:10:30 +0000 Message-Id: <69a65f36.32640.7934d24c@gitrepo.freebsd.org> The branch main has been updated by ngie: URL: https://cgit.FreeBSD.org/src/commit/?id=876d2b8392e6570a835a500d8fd7c4a5b0abf844 commit 876d2b8392e6570a835a500d8fd7c4a5b0abf844 Author: Enji Cooper AuthorDate: 2026-03-03 04:09:41 +0000 Commit: Enji Cooper CommitDate: 2026-03-03 04:09:49 +0000 acpi: build dev/acpi_support/acpi_wmi_if.m on ARM64 Per Wikipedia, ACPI WMI support is available on all x86* platforms and ARM platforms. Add the source to `files.arm64` so code that relies on its headers (thunderbolt(4) for instance), can be built on ARM64. MFC after: 1 month Reviewed By: andrew Differential Revision: https://reviews.freebsd.org/D55535 --- sys/conf/files.arm64 | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/conf/files.arm64 b/sys/conf/files.arm64 index 3b12999a6c87..cb326a2229a4 100644 --- a/sys/conf/files.arm64 +++ b/sys/conf/files.arm64 @@ -206,6 +206,7 @@ dev/acpica/acpi_pci.c optional acpi pci dev/acpica/acpi_pci_link.c optional acpi pci dev/acpica/acpi_pcib.c optional acpi pci dev/acpica/acpi_pxm.c optional acpi +dev/acpi_support/acpi_wmi_if.m optional acpi acpi_wmi dev/ahci/ahci_generic.c optional ahci cddl/dev/dtrace/aarch64/dtrace_asm.S optional dtrace compile-with "${DTRACE_S}" From nobody Tue Mar 3 04:50:50 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQ3K61CD4z6TktX for ; Tue, 03 Mar 2026 04:50: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQ3K60RPHz49Lk for ; Tue, 03 Mar 2026 04:50:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772513450; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tFCDrgGfm+0HqFfiECW5Spw7cpp1nQbog1eBfd3EF2M=; b=ZlJ4LKHW8A9IKGuIxP9Tg1EONbyrFFhlm8jLOFrz6d8B9AfgzaWEmpbt5iQZsdOtLrVGq9 ogkiCPIorgRreFgqn2P+xcE4Ifn9lFK0gUwKOhQdcXCbNNJwo1dq/2qKx3gPfchXW8WrAO mc4zys6klgTQREcQmh6BDa5f1wVZ1bo8DH8qx15/JmlWRUSRg6lSFqfDKeak7jhxe/qWYW cP4TDMxGKogZNOWP4U6n7v896OfEkTkIDiC3PC+43CPsIvJmR1ExRVxBUqJbQHDagFwYOS wCADw+qaqteHfThV6EQJ+7lMN5kMmGfJe2iQJMawdheFNlKDi3Qrcu9CGuU4mg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772513450; a=rsa-sha256; cv=none; b=uxWTDxqvHBkM32honROESH5tct6GtfF6WjmdvQlGMsTFRx7/Vt4CvGjL4gg4B3FZ5ltp17 Cls+tljS4+Q+cUi2F94we/THyT2Q0y8pOWQUwiuKiEDCYxLTlIidXrki5pMGAND6vM6yqF 2ZMKMLm1ZpOuMaUfJO3wSAREeMczCtjlZhGuVg1tJ7zLDQVyZYuif4nfBdp6qyHuKXo7OK uefe+1tHFFtWchFcHaFW1UUCjCGA7eAYoYlfaLpnvYjJvkm3FuvcykcZ7GpjGoHL3Sv4wD HKsXKR1WdFRsqEiwVu0pHSh8d78/vPaKEpAKpovpZHuEG/e6Fj6qvLjFCKyMPg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772513450; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tFCDrgGfm+0HqFfiECW5Spw7cpp1nQbog1eBfd3EF2M=; b=cQb+x6Q9MP/Jqg6qlQarSPdkCbq/pdHvb0swS83GtIYWH5x60/w4CDSYwgA9RB0yYQciQu NySg6KTKSPIRsiIRTnXxOATPIjgXaHZFRcgRQ8BBpl3bE+I1L04BJzVLv613mdIn0489NU BZQlmPUiDoUxybY6HN4RMEVPimOG5wgH8DtET3vnE7bBZuAZwUzY6yok0OcxsEGbu8qNfz e8hgWPPmNywqptsFNm/DPpTaeRWpJ5blLQibQh+LblFjNYc/IQ6NU0LvQSfDT/lKdFWoWw SLMYLEVQMicm8y2FTQXu2tEm8dnLNXX/sl3SvCZqudDNFCjLLlDbVUBEnIrk1A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQ3K603Jkz15X6 for ; Tue, 03 Mar 2026 04:50:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3785e by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 04:50:50 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Enji Cooper Subject: git: c47cefba8312 - main - Only build USB-related modules if MK_USB != no List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: c47cefba831240a1b3de375f18134b93cf998f5c Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 04:50:50 +0000 Message-Id: <69a668aa.3785e.4a16f236@gitrepo.freebsd.org> The branch main has been updated by ngie: URL: https://cgit.FreeBSD.org/src/commit/?id=c47cefba831240a1b3de375f18134b93cf998f5c commit c47cefba831240a1b3de375f18134b93cf998f5c Author: Enji Cooper AuthorDate: 2026-03-03 04:49:54 +0000 Commit: Enji Cooper CommitDate: 2026-03-03 04:50:03 +0000 Only build USB-related modules if MK_USB != no This change moves the thunderbolt module and other USB modules under a MK_USB != no conditional to ensure that users not desiring USB support can easily build systems without USB-specific drivers using this knob. MFC after: 1 week Reviewed By: imp Differential Revision: https://reviews.freebsd.org/D55576 --- sys/conf/kern.opts.mk | 5 +++++ sys/conf/kmod.mk | 8 ++++++-- sys/modules/Makefile | 16 ++++++++++------ 3 files changed, 21 insertions(+), 8 deletions(-) diff --git a/sys/conf/kern.opts.mk b/sys/conf/kern.opts.mk index 81b117492916..f26a44eb61f5 100644 --- a/sys/conf/kern.opts.mk +++ b/sys/conf/kern.opts.mk @@ -47,6 +47,7 @@ __DEFAULT_YES_OPTIONS = \ SOURCELESS_UCODE \ SPLIT_KERNEL_DEBUG \ TESTS \ + USB \ USB_GADGET_EXAMPLES \ ZFS @@ -207,6 +208,10 @@ MK_KERNEL_SYMBOLS:= no MK_DTRACE:= no .endif +.if ${MK_USB} == "no" +MK_USB_GADGET_EXAMPLES:= no +.endif + # Some modules only compile successfully if option FDT is set, due to #ifdef FDT # wrapped around declarations. Module makefiles can optionally compile such # things using .if !empty(OPT_FDT) diff --git a/sys/conf/kmod.mk b/sys/conf/kmod.mk index 17358428a023..4f1509592483 100644 --- a/sys/conf/kmod.mk +++ b/sys/conf/kmod.mk @@ -103,10 +103,14 @@ LINUXKPI_GENSRCS+= \ pci_iov_if.h \ pcib_if.h \ vnode_if.h \ - usb_if.h \ - opt_usb.h \ opt_stack.h +.if ${MK_USB} != "no" +LINUXKPI_GENSRCS+= \ + usb_if.h \ + opt_usb.h +.endif + LINUXKPI_INCLUDES+= \ -I${SYSDIR}/compat/linuxkpi/common/include \ -I${SYSDIR}/compat/linuxkpi/dummy/include \ diff --git a/sys/modules/Makefile b/sys/modules/Makefile index 49a15588e9a5..a4100c31ef26 100644 --- a/sys/modules/Makefile +++ b/sys/modules/Makefile @@ -356,7 +356,7 @@ SUBDIR= \ ${_rtw89} \ rtwn \ rtwn_pci \ - rtwn_usb \ + ${_rtwn_usb} \ ${_rtwnfw} \ ${_s3} \ ${_safe} \ @@ -411,7 +411,7 @@ SUBDIR= \ ${_ufshci} \ uinput \ unionfs \ - usb \ + ${_usb} \ ${_vesa} \ ${_vf_i2c} \ virtio \ @@ -710,6 +710,14 @@ SUBDIR+= ktest SUBDIR+= tests .endif +.if ${MK_USB} != "no" || defined(ALL_MODULES) +_rtwn_usb= rtwn_usb +_usb= usb +. if ${MACHINE_CPUARCH} == "amd64" +_thunderbolt= thunderbolt +. endif +.endif + .if ${MK_ZFS} != "no" || defined(ALL_MODULES) SUBDIR+= zfs .endif @@ -938,10 +946,6 @@ _bcm283x_pwm= bcm283x_pwm _neta= neta .endif -.if ${MACHINE_CPUARCH} == "amd64" -_thunderbolt= thunderbolt -.endif - .if !(${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} < 110000) # LLVM 10 crashes when building if_malo_pci.c, fixed in LLVM11: # https://bugs.llvm.org/show_bug.cgi?id=44351 From nobody Tue Mar 3 06:00:19 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQ4sP25NNz6TqDr for ; Tue, 03 Mar 2026 06:00: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQ4sP1Sbcz4GPP for ; Tue, 03 Mar 2026 06:00:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772517625; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3sz7/fRMpCVWNbill7ILv66yA/AsMFcvwrp7mTgQz0c=; b=agX+WK1YWqGj+KWh+6MOAaWs1zjr/ojt17ccvWNJfQoa+AySymTQcIaN2ZOT7Z3LtS3A7R Sg/42OCFZb1M5ZdeBv8pQBIWqYCx+S1EmQhLvQe+2h5igEanqEvvtwUJPbtgXs3Q0DeWlS XBnh3f7Y5uqCmuqfsbTvc7FT/FJNVAz59b8v9+7ZOasPCygUzCox/7Oqn3IppRSIiKNLSU JULJji0cZwHSNgKuRs0bEMkNTm+6WlWRpEb3rqi/IPSaMUKlw50v8bSl8AnpaZ+0ER9NO3 bTdtymtSPg9vH01nRwrlwazOFiNebf/qTW0+AGr2XSoZ7P4vB/5KHclnkHnDJg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772517625; a=rsa-sha256; cv=none; b=v1v1xNmM/pJtNAgaE833rjy/D3nyJv6VedeUbpRl9deC2keIKTE1u71JDPTX80oULxECPt /C6G4lADcSWZMqmiOPvRCVbBIrAvDSFvsDUiWiAszR7tRfVLIchk0237t8pnna6jHUdhK6 GY1KEVJ3W4OoAMR0bh6kANBHNC+8tgJtIe4eis9ZfSLWHRLKSkIJIwLWnXE9Ucp95IFn3r dfmX7F8do7VUEYpK7N7k6M/4RmKmBBn6Vq4ADFdd5HAht1uWyAXzjz69f4bJgV+zRFFQ+5 L0Lqf2ph1NLG88AqhBQBN0G4X2NOFHXIfZrC4ODv3En65Mvo8RWtLfEexqlllQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772517625; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3sz7/fRMpCVWNbill7ILv66yA/AsMFcvwrp7mTgQz0c=; b=wo3uI5s1VYfOSF0Mkhc9Kb2JqFbNoX8o3yOW+t5Ia3eIaLSWocEPJqZVApCr7w+IkOigs7 8TXUHIMY46UeMOSQBIn36xyo7KmZAhJWFQUNO5kCO8ooKFQ+zbxc9AKs5JEep7Ncf4dH2w 4yn2faOSILSaR2UyvBOjAZdsjt+Q9cwSTgxVgz7P7al+HRoTAlOh3Yk6ZgVt7gs8bp+S+O CmmHKRP9eNlhsXepdtPxWMvi6FcEHpRf5FTpkwSQqx5Jzlq7nfq71mk00zKLFRF1aAZ69q /ebMfCWoolRqDOBsDKTddXjoH6pZWVzcbZPaaVC4iq9eydNPq15+kbhjdJPYJg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQ4sP0wrVz16wd for ; Tue, 03 Mar 2026 06:00:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3f811 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 06:00:19 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Enji Cooper Subject: git: 912864912b71 - main - Run `make obj` before running `make test-includes` List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 912864912b71951f9a636190b1dba80528f588eb Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 06:00:19 +0000 Message-Id: <69a678f3.3f811.148b0d7d@gitrepo.freebsd.org> The branch main has been updated by ngie: URL: https://cgit.FreeBSD.org/src/commit/?id=912864912b71951f9a636190b1dba80528f588eb commit 912864912b71951f9a636190b1dba80528f588eb Author: Enji Cooper AuthorDate: 2026-03-03 05:59:50 +0000 Commit: Enji Cooper CommitDate: 2026-03-03 05:59:56 +0000 Run `make obj` before running `make test-includes` Before this change, `make test-includes` (run as part of buildworld) would place test files in the current directory, which would clutter up git clones. Run `make obj` beforehand to ensure that the files are put in `${.OBJDIR}` instead of `${.CURDIR}`. This helps cut down on the noise significantly when running commands like `git status`. MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D55499 --- Makefile.inc1 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index 93c54e0a0d14..c4696abae8cd 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -1207,7 +1207,7 @@ _includes: .if !empty(SUBDIR_OVERRIDE) && make(buildworld) ${_+_}cd ${.CURDIR}; ${WMAKE} MK_INCLUDES=yes SHARED=symlinks includes .endif - ${_+_}cd ${.CURDIR}; ${WMAKE} test-includes + ${_+_}cd ${.CURDIR}; ${WMAKE} test-includes _libraries: @echo @echo "--------------------------------------------------------------" @@ -1575,6 +1575,7 @@ makeman: .PHONY # Ensure no regressions in self-includeability of sys/*.h and net*/*.h test-includes: .PHONY ${_+_}cd ${.CURDIR}/tools/build/test-includes; \ + ${WMAKEENV} ${MAKE} ${WORLD_FLAGS} obj; \ ${WMAKEENV} ${MAKE} ${WORLD_FLAGS} DESTDIR=${WORLDTMP} test-includes # We can't assume here that ${TMPPATH} will include ${PATH} or /usr/libexec From nobody Tue Mar 3 11:25:48 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQD575YV8z6SycN for ; Tue, 03 Mar 2026 11:26:03 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pj1-x102e.google.com (mail-pj1-x102e.google.com [IPv6:2607:f8b0:4864:20::102e]) (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 4fQD571HhHz3VCk for ; Tue, 03 Mar 2026 11:26:03 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pj1-x102e.google.com with SMTP id 98e67ed59e1d1-354bc7c2c46so3105691a91.0 for ; Tue, 03 Mar 2026 03:26:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1772537160; cv=none; d=google.com; s=arc-20240605; b=lDzgLLTXJw8G4HX7EEI1k5kOiAKFiV6tIT7RN/V0O6/T2O2zi8t6R5yh1WOVR4QU4k Pk4ekRkH6A8f0Isr2t/mG2VS2Fy9FhA4h/0CLFgmwaBRIIawB1LL1h5mVHagF8lDfgKn ry8Uo5LU5zkofNmrOIAGcSoueUYkamsonF1+Afbf+C15n1tVPKZ5a1FEdHNSb8GWIFUe 3cdHvbI0NspirQAQKXCmykLCjBY3QPTbmXqvHA0qqITM9vdRoSNMyuW5TArr8AQgEl5b Y+hiZYLClC7CwdDOPZI6v3It9UAjVj8PBEN+WPyhN4P+TB1+VdIhSVoKE7g8muvZ7QBN WLUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=Bx+AO1lVryOD0R/NWm8A9HkRHnoZGy+fUGBNuB9w+rk=; fh=yB5D+XPt8GRnMMeup8Qb/cx6rCQrP/FKjqB3mXqUYsw=; b=Kh9Wa5+RjVp3HvN8LHjfXO9Dt9Mg0cJYlO4lfIANJGhzZnhmpYE1RFqfcRNqIOtfr1 u12DIy/722/sxi6y//hiTGj+q3guZrNJL6gxGKHK0QCagts3wNwibInjxXnBjxXWDzld i2/Is6mR/Ij6w316KOQ+DcLsxgvvk/fiBZLr9DTPcld47MARRGSL+9vtMKwE1xFCa2QK 3MkNmSDwTrL6sz3i8fCY1co0hN5KE2/zlXwB/SSP8xhG8KF5k4GRCPlS1IsYieMsIhmR KtWGHvZ6LhIlxdx6f2pnIwdLkepviH+iNksVpd0MMMp854eWivRit9R2EG88YhIjab9a XRZg==; darn=freebsd.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1772537160; x=1773141960; 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=Bx+AO1lVryOD0R/NWm8A9HkRHnoZGy+fUGBNuB9w+rk=; b=i7FmGWgBIxFIKKXCDbdrIqaypqa2G9znwdSOdPAOuys8hvR3drUIKZSnOwU15x0mPy 0IYwHIAFmAA5R1b4VJdcAFU9mBH9dxOUdLCoCFohYNqdNO+GuroM2+/a7Rb0uDqRzcwC O7QhIT4u8zGcp1H7WGslH1Z5mKlOIaOvU9Ml2//jMRVhhEysTSIxPEBt+tFUfrkApMI1 Bt7nGyr7cxDEuMD+/MonBffytKkFORJgvJU7JrlJ/0qOchavAhrcjQPWl/4nUrFnJN2t H7mxudz4tIlZsKioFlpStUvA0jjA//+d106rYekPOLwvVJwN0oaQalyGpcbVEzw1vXZx YXDg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772537160; x=1773141960; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=Bx+AO1lVryOD0R/NWm8A9HkRHnoZGy+fUGBNuB9w+rk=; b=OsjR3SAhk8k6fANug4UsznejTatvAoCfNLW/fDirvVJI2dcGiiGArr4X4FdOfFcHqu OTPnWDPSuebicG9GqAnTr67On7q7WMTiJr4jokp1bVoPLG95isV1bN1SPwV+IgO1fTj8 yW3+c/iE+p12S6Z4QQFGJEEJA8FswIh4IKvEegwSLzYJ1bkvWZrGnOKErbZ/CGg9gL5d AwYRd1XnWkmUZFI9gxBkE7NHNXl5Fxrhy9se9eQjgG4WdoCXW3maCnvVcXC6zOgiFOwZ uq1nGkkFmxC4PtXZb2ge0LDj8mndpPE0aeYVv0YdUTEZrLX1/2jIkn0EF/Cc5aVdTL5s R9wg== X-Forwarded-Encrypted: i=1; AJvYcCV8xldPh3lnp2GIV7BvWQjYUlxFjWz0MPfoB0stklNxdK9GyEPf3pXGcb2A89Pf7Z560LOog7j9RZq9o4oaXuXWskYUCg==@freebsd.org X-Gm-Message-State: AOJu0Yw5hExZP3WfTXRUoCDvdy9dRGmSAgUXrK5Dig5XScEF6dl6cMj8 /XwYuM86o50t+edjg8cz4rIRIHbEO7j/AYEtIZt92i4a8xq7fSZ449VQI6N1qiOF+Wahb4yYnYm FsPEIdS9/dzm2OWIbO47nSwNzUuCtbH972fM9Zab63Q== X-Gm-Gg: ATEYQzxMd+h6XJ6kftPfQkcgiKseljcIgHQbXk2sS60orV2QpAofd7UpF9Z0/oOUkyC 8tLfqsEnai0eozAKWgYneF/liGMTOJwe/x+7/C8MY8aP1RROuZcRxG8sVl+AV1h1mY4rRb3RATE DWFxZsFVmS3yzO+Oh/yaAqrYaUiCEXrQFhgw8yO60/V3SF52LtFCtYuF/LcjZKitCuDu8iBIcKb WvF/U0WBzKaX1IyICnYi0QCQ7avOazVhjAMTtXekApaf0aOQ4q3v/2V90ObaBod5WRszI1jaWAT Xh8/zUQdOFj6qg7LrRcaRqWWBczau1ZqilQyMg== X-Received: by 2002:a17:90b:584e:b0:354:a332:1a61 with SMTP id 98e67ed59e1d1-35965c276bfmr11147086a91.5.1772537159971; Tue, 03 Mar 2026 03:25:59 -0800 (PST) List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 References: <69a678f3.3f811.148b0d7d@gitrepo.freebsd.org> In-Reply-To: <69a678f3.3f811.148b0d7d@gitrepo.freebsd.org> From: Warner Losh Date: Tue, 3 Mar 2026 04:25:48 -0700 X-Gm-Features: AaiRm52os4sKYYoCYfrNMZLFWv4GlwJt7I8GRJlav4CG_cIpu9ZUBudXuY_8p8w Message-ID: Subject: Re: git: 912864912b71 - main - Run `make obj` before running `make test-includes` To: Enji Cooper Cc: src-committers , "" , "" Content-Type: multipart/alternative; boundary="000000000000c57f16064c1cf72e" X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated 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-Queue-Id: 4fQD571HhHz3VCk X-Spamd-Bar: ---- --000000000000c57f16064c1cf72e Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, Mar 2, 2026, 11:00=E2=80=AFPM Enji Cooper wrote: > The branch main has been updated by ngie: > > URL: > https://cgit.FreeBSD.org/src/commit/?id=3D912864912b71951f9a636190b1dba80= 528f588eb > > commit 912864912b71951f9a636190b1dba80528f588eb > Author: Enji Cooper > AuthorDate: 2026-03-03 05:59:50 +0000 > Commit: Enji Cooper > CommitDate: 2026-03-03 05:59:56 +0000 > > Run `make obj` before running `make test-includes` > > Before this change, `make test-includes` (run as part of buildworld) > would place test files in the current directory, which would clutter = up > git clones. Run `make obj` beforehand to ensure that the files are pu= t > in `${.OBJDIR}` instead of `${.CURDIR}`. This helps cut down on the > noise significantly when running commands like `git status`. > I've never seen this happen. .OBJDIR is created automatically for me always for the last 5 years... I run buildworld all the time. Can you explain when / how it happens more specifically or back out the change? Warner MFC after: 1 week > Differential Revision: https://reviews.freebsd.org/D55499 > --- > Makefile.inc1 | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/Makefile.inc1 b/Makefile.inc1 > index 93c54e0a0d14..c4696abae8cd 100644 > --- a/Makefile.inc1 > +++ b/Makefile.inc1 > @@ -1207,7 +1207,7 @@ _includes: > .if !empty(SUBDIR_OVERRIDE) && make(buildworld) > ${_+_}cd ${.CURDIR}; ${WMAKE} MK_INCLUDES=3Dyes SHARED=3Dsymlinks > includes > .endif > - ${_+_}cd ${.CURDIR}; ${WMAKE} test-includes > + ${_+_}cd ${.CURDIR}; ${WMAKE} test-includes > _libraries: > @echo > @echo > "--------------------------------------------------------------" > @@ -1575,6 +1575,7 @@ makeman: .PHONY > # Ensure no regressions in self-includeability of sys/*.h and net*/*.h > test-includes: .PHONY > ${_+_}cd ${.CURDIR}/tools/build/test-includes; \ > + ${WMAKEENV} ${MAKE} ${WORLD_FLAGS} obj; \ > ${WMAKEENV} ${MAKE} ${WORLD_FLAGS} DESTDIR=3D${WORLDTMP} > test-includes > > # We can't assume here that ${TMPPATH} will include ${PATH} or > /usr/libexec > > --000000000000c57f16064c1cf72e Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Mon, Mar 2, 2026, 11:00=E2=80= =AFPM Enji Cooper <ngie@freebsd.org<= /a>> wrote:
The branch main has = been updated by ngie:

URL:
ht= tps://cgit.FreeBSD.org/src/commit/?id=3D912864912b71951f9a636190b1dba80528f= 588eb

commit 912864912b71951f9a636190b1dba80528f588eb
Author:=C2=A0 =C2=A0 =C2=A0Enji Cooper <ngie@FreeBSD.org>
AuthorDate: 2026-03-03 05:59:50 +0000
Commit:=C2=A0 =C2=A0 =C2=A0Enji Cooper <ngie@FreeBSD.org>
CommitDate: 2026-03-03 05:59:56 +0000

=C2=A0 =C2=A0 Run `make obj` before running `make test-includes`

=C2=A0 =C2=A0 Before this change, `make test-includes` (run as part of buil= dworld)
=C2=A0 =C2=A0 would place test files in the current directory, which would = clutter up
=C2=A0 =C2=A0 git clones. Run `make obj` beforehand to ensure that the file= s are put
=C2=A0 =C2=A0 in `${.OBJDIR}` instead of `${.CURDIR}`. This helps cut down = on the
=C2=A0 =C2=A0 noise significantly when running commands like `git status`.<= br>

I= 've never seen this happen. .OBJDIR is created automatically for me alw= ays for the last 5 years... I run buildworld all the time. Can you explain = when /=C2=A0 how it happens more specifically or back out the change?
=

Warner

=C2=A0 =C2=A0 MFC after:=C2=A0 =C2=A0 =C2=A0 1 week
=C2=A0 =C2=A0 Differential Revision: https://reviews.fr= eebsd.org/D55499
---
=C2=A0Makefile.inc1 | 3 ++-
=C2=A01 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Makefile.inc1 b/Makefile.inc1
index 93c54e0a0d14..c4696abae8cd 100644
--- a/Makefile.inc1
+++ b/Makefile.inc1
@@ -1207,7 +1207,7 @@ _includes:
=C2=A0.if !empty(SUBDIR_OVERRIDE) && make(buildworld)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 ${_+_}cd ${.CURDIR}; ${WMAKE} MK_INCLUDES=3Dyes= SHARED=3Dsymlinks includes
=C2=A0.endif
-=C2=A0 =C2=A0 =C2=A0 =C2=A0${_+_}cd ${.CURDIR};=C2=A0 ${WMAKE} test-includ= es
+=C2=A0 =C2=A0 =C2=A0 =C2=A0${_+_}cd ${.CURDIR}; ${WMAKE} test-includes
=C2=A0_libraries:
=C2=A0 =C2=A0 =C2=A0 =C2=A0 @echo
=C2=A0 =C2=A0 =C2=A0 =C2=A0 @echo "-----------------------------------= ---------------------------"
@@ -1575,6 +1575,7 @@ makeman: .PHONY
=C2=A0# Ensure no regressions in self-includeability of sys/*.h and net*/*.= h
=C2=A0test-includes: .PHONY
=C2=A0 =C2=A0 =C2=A0 =C2=A0 ${_+_}cd ${.CURDIR}/tools/build/test-includes; = \
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0${WMAKEENV} ${MAKE} ${WORLD_FLAGS= } obj; \
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 ${WMAKEENV} ${MAKE} ${WORLD_FLAGS= } DESTDIR=3D${WORLDTMP} test-includes

=C2=A0# We can't assume here that ${TMPPATH} will include ${PATH} or /u= sr/libexec

--000000000000c57f16064c1cf72e-- From nobody Tue Mar 3 11:32:58 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQDF6287rz6T0WN for ; Tue, 03 Mar 2026 11:32: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQDF61XRyz3Vrw for ; Tue, 03 Mar 2026 11:32:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772537578; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VXoxoU9nckkAUAl+HFVMafWDe/a2QH8CNa8SfbmAx5U=; b=kKYJJaPi9O32P21QgypaPiKLQszgG3j9Td8H7Gkh+H88UIKYwjqD5cR+8jCKlsHKSOpIq8 8FXmbck6izXzJpNdWmaZCDMUHtW5DJfBo4DFR437rM1HoyZSj5oPsMTvNQdJhYC50nLHsx wl3d7ypDP94V3VAafXe+oDw+VsI0n/94LNbXNAHAi/prUT6wXEFDKgrVC7MGSVJG2aly2T vhPx7gWD6FgVmQVrROyPkLWKIYf4DebCghMTRkfGn92QUEVzv9wecBff1H/1FOdGGB4cQY 80AErIRLDUhU8OQoJnq/sxQ0i5KfWi1sSsbPX4eaM0D+UjQuFWgFiT+cC/owqg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772537578; a=rsa-sha256; cv=none; b=L/0jpglSaDNCXdIWRQ5IVYmSh0DMk/alp9crOhdUFD3hjpRI/Sdh5OXBhc9mYVMdLCMDah 2xPxVzUhccr4ldpHSQY/JHWrvT1F46DrOSotuSDXSsGGQCOjZ31cvcLQS8yQ1ZAq5ECQYg b9sf4cYT5OXUWiKrPb+FwTaFeMrMIcQqsxe6i0Cf1KShybxqzF2rbwjbn/sQ22/ifZHtxv rUxppIlSuIPSwIsY152rFa1CwPm3dhjos0gDXPgp+YjXBCbC6w8Hby7qwcRph/5t2Wy1Uy 3Og9640nQy6rQ6cZ/gYB+rI7AZgzEsFDW6YcXHJx6nBXDhv4pWqI9uewevKbKg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772537578; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VXoxoU9nckkAUAl+HFVMafWDe/a2QH8CNa8SfbmAx5U=; b=PKjvjBHp9qDw3f3xv07h0A7N/TGAye2F+yu1mNBMfCjrVjkFObVHo33rdOws2SRSjqAjzg q/XS6CB8/qEXk2tDc/6lKcwZaOgKINZeMHhrhGM5Hj5vKbJx/44GHccMtOczA4pnrS4YPQ bvRX1ZEEVR8L6Ex0GsQ6PBo/YULUwVc3pd8wDAXdZgtC1rMPd7QLkf616AbkwYNxmaZyky 4DGepKDMMfcwD9NZk3Tt02AX1BRRhDXhmMw1DrcoQG3SdgQcDedyHESQZA7E1W98nr0zwd 3kXCQedmdn2ALomtZXTolTys/43vm4VxMAnGm0fC2lqQgMYqduIhQ/3rnyuahA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQDF614xrz1Hgv for ; Tue, 03 Mar 2026 11:32:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 4261c by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 11:32:58 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: d40189f8259e - main - sound: Notify devd on hw.snd.default_unit change List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: d40189f8259e3565c69a40194f7b603d0ca648de Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 11:32:58 +0000 Message-Id: <69a6c6ea.4261c.751a8a36@gitrepo.freebsd.org> The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=d40189f8259e3565c69a40194f7b603d0ca648de commit d40189f8259e3565c69a40194f7b603d0ca648de Author: Christos Margiolis AuthorDate: 2026-03-03 11:32:32 +0000 Commit: Christos Margiolis CommitDate: 2026-03-03 11:32:32 +0000 sound: Notify devd on hw.snd.default_unit change If we have virtual_oss running, this devd notification will make sure to automatically transfer sound to the new default unit, while also making sure that we switch to it only for the supported directions (recording and/or playback). For more information, please refer to 2ffaca551eaf ("snd_hda: Implement automatic redirection between associations"). Sponsored by: The FreeBSD Foundation MFC after: 1 week Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D55530 --- sys/dev/sound/pcm/sound.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sys/dev/sound/pcm/sound.c b/sys/dev/sound/pcm/sound.c index 8ce369bfce5e..abd92d93e02d 100644 --- a/sys/dev/sound/pcm/sound.c +++ b/sys/dev/sound/pcm/sound.c @@ -81,6 +81,7 @@ static int sysctl_hw_snd_default_unit(SYSCTL_HANDLER_ARGS) { struct snddev_info *d; + char buf[32]; int error, unit; unit = snd_unit; @@ -95,6 +96,12 @@ sysctl_hw_snd_default_unit(SYSCTL_HANDLER_ARGS) snd_unit = unit; snd_unit_auto = 0; bus_topo_unlock(); + + snprintf(buf, sizeof(buf), "cdev=dsp%d", snd_unit); + if (d->reccount > 0) + devctl_notify("SND", "CONN", "IN", buf); + if (d->playcount > 0) + devctl_notify("SND", "CONN", "OUT", buf); } return (error); } From nobody Tue Mar 3 11:32:59 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQDF72wmHz6T0FY for ; Tue, 03 Mar 2026 11:32: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQDF72Tbhz3Vgk for ; Tue, 03 Mar 2026 11:32:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772537579; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mZqk/4lNrhjMdEtB+WQBLOUpuKG3AuU3s4JOpW/4se4=; b=t9/yU2bo7acFAJnFAEwHfjCgRtKVW7ySwa7i0Afy4uDZ/egouVOwcXWHvr8c7+41BY8F+D K0BLafv7f7Fak7BESfeW/XdlV9UOeQU1CQpcXaDipOupshYuLYrD0uTLt56UO7TIvq+67z 6lgR+KTa7mgsHWB3GfjGZ0P1LWfmV3yVu39pqdcvZN9kdyYhPe7v/QiHnpYxZxU1q31vtR jVLCuEkVRYBs+2+WoSf0LRkZV8ssNmv294g+xp+yUYj/chH2s0hHfDnuw+jsUiek0hFgeD 4pVH3cv9rBF7KHLIMQBMrvsc1IU9LXLmtjVNaZh5nKOCQw69uNw5o1iN5DLuaA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772537579; a=rsa-sha256; cv=none; b=q7daJw0hd8yTpFrZDQ4rjY4jGa6cukLRYM/zzeKNIVkFgNpfS6D7E5adMKXdOtNZyzwGzK 6RFlos0KAr5Juf8MNGVAf0QTlN6EW1JUuLfDvWh9Z8DWasPiSShBR2WziGIByxse2OBgFQ rjP0VSUQGkMaborOTnuIqsEEDs3nCEE8ksb5A5S/yVkfebWiOSX7K/77C9N0oiWvCDex+v hXx6YgYb5vWxiM5ThxElSsMYuEjdDbVGboDHXGlKCuDqige2dkgp7edYoNkfj/J0t6gznD WXSY05YKheHhYQfj3JHw9z/RHZPC4yYmdkPnYHRXxaOj89oubqlvb8nKa/jgfQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772537579; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mZqk/4lNrhjMdEtB+WQBLOUpuKG3AuU3s4JOpW/4se4=; b=ZOQ1WTICDhK01Keq2ERG+9XMEr13GE6H0uhd4a04SUG7QAhaNCQPR/1MgxlphLHBvQyEBg t4XfJsEePkUEg4bMAoGcr8eoc5u6upcdn+XU49XiTTO7KByHOiLe5JtnabbHrrWJn1X8hZ XNPUBrZPaqkcMKlQSo5yOuhgMwMDX7Dwbq2AdGIKiFlqpk6FWtqyom3EpahDo7kc5GSybm /tzOPmxOxDxAJRxY1lKP1ZbAYRsTDTkX8w8eMvGHl4JNNJXpRNhrIbRAuNPNvnN6IWqJ4G olQfP51GcbIiSIy7MLMwyQ+JpHCzH3nGKveVmUzKhwAx0xEu+1/i56OhlKpY2g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQDF71tr0z1JCV for ; Tue, 03 Mar 2026 11:32:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 420ba by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 11:32:59 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: 428517a7712e - main - sound: Notify devd when no devices are connected List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 428517a7712e44b58e0687fbee4037a8ebe5bf5a Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 11:32:59 +0000 Message-Id: <69a6c6eb.420ba.33f3e2c@gitrepo.freebsd.org> The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=428517a7712e44b58e0687fbee4037a8ebe5bf5a commit 428517a7712e44b58e0687fbee4037a8ebe5bf5a Author: Christos Margiolis AuthorDate: 2026-03-03 11:32:38 +0000 Commit: Christos Margiolis CommitDate: 2026-03-03 11:32:38 +0000 sound: Notify devd when no devices are connected Sponsored by: The FreeBSD Foundation MFC after: 1 week Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D55531 --- sbin/devd/devd.conf.5 | 4 +++- sbin/devd/snd.conf | 10 ++++++++++ sys/dev/sound/pcm/sound.c | 2 ++ 3 files changed, 15 insertions(+), 1 deletion(-) diff --git a/sbin/devd/devd.conf.5 b/sbin/devd/devd.conf.5 index b1fca89991ed..a1d6a9051389 100644 --- a/sbin/devd/devd.conf.5 +++ b/sbin/devd/devd.conf.5 @@ -38,7 +38,7 @@ .\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS .\" SOFTWARE. .\" -.Dd July 9, 2025 +.Dd February 26, 2026 .Dt DEVD.CONF 5 .Os .Sh NAME @@ -666,6 +666,8 @@ variable. Connected output device specified in .Pa cdev variable. +.It Li SND Ta Li CONN Ta Li NODEV Ta +No connected devices. .El .Pp .\" diff --git a/sbin/devd/snd.conf b/sbin/devd/snd.conf index a45f427f6c79..5ca0be86e246 100644 --- a/sbin/devd/snd.conf +++ b/sbin/devd/snd.conf @@ -24,3 +24,13 @@ notify 0 { # See comment above. action "/usr/sbin/virtual_oss_cmd /dev/vdsp.ctl -P /dev/$cdev"; }; + +notify 0 { + match "system" "SND"; + match "subsystem" "CONN"; + match "type" "NODEV"; + + # No connected devices. Disable both recording and playback to avoid + # repeated virtual_oss error messages. + action "/usr/sbin/virtual_oss_cmd /dev/vdsp.ctl -f /dev/null"; +}; diff --git a/sys/dev/sound/pcm/sound.c b/sys/dev/sound/pcm/sound.c index abd92d93e02d..305d663cd6ad 100644 --- a/sys/dev/sound/pcm/sound.c +++ b/sys/dev/sound/pcm/sound.c @@ -483,6 +483,8 @@ pcm_unregister(device_t dev) snd_unit = pcm_best_unit(-1); if (snd_unit_auto == 0) snd_unit_auto = 1; + if (snd_unit < 0) + devctl_notify("SND", "CONN", "NODEV", NULL); } return (0); From nobody Tue Mar 3 11:33:00 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQDF866hjz6T0CP for ; Tue, 03 Mar 2026 11:33: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQDF84lgBz3W8N for ; Tue, 03 Mar 2026 11:33:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772537580; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=BFFD4UnHFG03L4QTbt9i/MwUgLUgg+bS/E/W/hrJz4k=; b=iJHJFn+54tP83Igqh8220zn9UI3StoItZTeptI4PBXTOuhRz4OdIRkr6wImtmZJ6u1SuFr ji83SVi/ZUJ7oIqEyylJTcZ+IpE2+SKyAUk9qcQDTvd0Y7wrd1Iy6R+vvtm5aZNQdgwPVw VAF44tQ8xLOW5+8fMu+MdbUCoC2mussUVxS7p99ScUgX44MnT4+AqoWnSBDWgS50bOSs4y kZ6KyJDS/ju6PQr4PKpd00fCAZKeIQcebAbhK5dS8pWeTTz8Uk8Cg68agIEmWOPq34kd5c yx5a3eL4gG3EICZGihI8i4gmFK+2MP2XSOxYbTVUxeYui7CmkhBNgksip1xAlQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772537580; a=rsa-sha256; cv=none; b=sMP+RNk4Y5zJ+mgb8sAiuetoOInQLR6WrsAHD6BMzt7aGMmpuIiPFmTZWszLbFJXiOvYVs 3qD3uZoDw+SrAGw8LtnxJg0SwZy5uqQoKMyVYUCv7zzBeNfdsKvp0gkSlB1DpatCR3wEpO GE18HuigldcqDj6sfZjWCLhuku/MKcg5DIZ/vDn5ATB0UoXOshJrEshu+C3tVeg+y0khZa apohk4iIz2JjE2ulZCcWTB2BKlKwFGbM35JdlQg/erfYPi2mPZO4bV3z+Qo53edDwxrR+n A6v6ARa0ZTc61zkwOeJaA1WCt+mw21L/MnZk9hzUDJlkd2xnwrnGBQOlHl6GfA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772537580; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=BFFD4UnHFG03L4QTbt9i/MwUgLUgg+bS/E/W/hrJz4k=; b=wUNXi7QuzmzN4SovnNThLxItMJBLGeYgcgoUecui1+If1iYjkz+dxIJVatwmfwj/KBRue9 WkpdSLDelBQjLKv6CrLJRIsrHg0zpU1fyHmcsZNBfwHa8HZqISHUpaAnVcMmFUQ3CYvitH HSU4ESBkydLYXSm/CZZO+lXA7lWiZHQuFkPPQmlobjhHJGkm16gsXpbZNLOu3l7KD4vUU3 H83YHrvct49wH/AmDF4+GESor8UqNh927LH99v+X8EAk+yuO644ZdfLJlkDXv8tIGUWqLj ugKI79KNSvQLITcSYaIVMafJ9vIrLy5LpaFMoCrwz9KGpv3qtw1+WEyr5FP33Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQDF82VVgz1JCW for ; Tue, 03 Mar 2026 11:33:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 42a82 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 11:33:00 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: d00b32c2d70c - main - Revert "mixer(8): Implement hot-swapping" List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: d00b32c2d70ce79fddb94dd990d2b162c8fc3a85 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 11:33:00 +0000 Message-Id: <69a6c6ec.42a82.20d515f1@gitrepo.freebsd.org> The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=d00b32c2d70ce79fddb94dd990d2b162c8fc3a85 commit d00b32c2d70ce79fddb94dd990d2b162c8fc3a85 Author: Christos Margiolis AuthorDate: 2026-03-03 11:32:42 +0000 Commit: Christos Margiolis CommitDate: 2026-03-03 11:32:42 +0000 Revert "mixer(8): Implement hot-swapping" We now have devd rules in snd.conf that achieve this in a much cleaner way. This reverts commit 9aac27599acaffa21ff69c5be8a2d71d29cc3d6b. Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D55532 --- usr.sbin/mixer/mixer.8 | 75 +++------------------------------------------- usr.sbin/mixer/mixer.c | 81 +++++--------------------------------------------- 2 files changed, 11 insertions(+), 145 deletions(-) diff --git a/usr.sbin/mixer/mixer.8 b/usr.sbin/mixer/mixer.8 index d7de675bceee..bdff0dbedc11 100644 --- a/usr.sbin/mixer/mixer.8 +++ b/usr.sbin/mixer/mixer.8 @@ -19,7 +19,7 @@ .\" OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN .\" THE SOFTWARE. .\" -.Dd October 31, 2025 +.Dd February 26, 2026 .Dt MIXER 8 .Os .Sh NAME @@ -28,7 +28,7 @@ .Sh SYNOPSIS .Nm .Op Fl f Ar device -.Op Fl d Ar pcmX | X Op Fl V Ar voss_device:mode +.Op Fl d Ar pcmX | X .Op Fl os .Op Ar dev Ns Op Cm \&. Ns Ar control Ns Op Cm \&= Ns Ar value .Ar ... @@ -43,7 +43,7 @@ The utility is used to set and display soundcard mixer device controls. .Pp The options are as follows: -.Bl -tag -width "-V voss_device:mode" +.Bl -tag -width "-d pcmN | N" .It Fl a Print the values for all mixer devices available in the system .Pq see Sx FILES . @@ -54,30 +54,6 @@ where X is the device's unit number (e.g for pcm0, the unit number is 0). See .Sx EXAMPLES on how to list all available audio devices in the system. -.Pp -There is also the possibility of hot-swapping to the new default device if -.Xr virtual_oss 8 -exists in the system and is running, in which case the -.Fl V -option needs to be specified as well. -.Pp -Hot-swapping generally cannot happen with plain -.Xr sound 4 , -so the user has to restart the track in order to get sound coming out of the -new default device. -This is because applications usually open a device at the start of the track -and do not check for default device changes, in order to open the new device -mid-track. -.Xr virtual_oss 8 , -on the other hand, can do hot-swapping, because it creates a virtual device for -applications to open, and then does all the necessary routing and conversions -to the appropriate device(s). -.Pp -Note that hot-swapping will work only for applications that are using -.Xr virtual_oss 8 -devices, and not plain -.Xr sound 4 -ones. .It Fl f Ar device Open .Ar device @@ -90,33 +66,6 @@ Print mixer values in a format suitable for use inside scripts. The mixer's header (name, audio card name, ...) will not be printed. .It Fl s Print only the recording source(s) of the mixer device. -.It Fl V Ar voss_device:mode -Specify a -.Xr virtual_oss 8 -control device, as well as a mode (see below), in order to hot-swap devices. -This option is meant to only be used in combination with the -.Fl d -option. -.Pp -The available modes are as follows: -.Bl -column play -.It Sy Mode Ta Sy Action -.It all Ta Playback and recording -.It play Ta Playback -.It rec Ta Recording -.El -.Pp -The -.Pa mode -part is needed, so that -.Nm -will not accidentally hot-swap both the recording and playback device in -.Xr virtual_oss 8 , -if only one direction is to be hot-swapped. -.Pp -See -.Sx EXAMPLES -on how to use this option. .El .Pp The list of mixer devices that may be modified are: @@ -316,26 +265,10 @@ $ mixer -f /dev/mixer0 -o > info \&... $ mixer -f /dev/mixer0 `cat info` .Ed -.Pp -Suppose -.Xr virtual_oss 8 -is running with -.Pa /dev/vdsp.ctl -as its control device, and -.Pa pcm0 -as the playback device. -Change the default device to -.Pa pcm1 , -and hot-swap to it for both recording and playback in -.Xr virtual_oss 8 : -.Bd -literal -offset indent -$ mixer -d pcm1 -V /dev/vdsp.ctl:all -.Ed .Sh SEE ALSO .Xr mixer 3 , .Xr sound 4 , -.Xr sysctl 8 , -.Xr virtual_oss 8 +.Xr sysctl 8 .Sh HISTORY The .Nm diff --git a/usr.sbin/mixer/mixer.c b/usr.sbin/mixer/mixer.c index 15e0eae69952..a0fc9705a301 100644 --- a/usr.sbin/mixer/mixer.c +++ b/usr.sbin/mixer/mixer.c @@ -20,9 +20,6 @@ * THE SOFTWARE. */ -#include -#include - #include #include #include @@ -43,7 +40,7 @@ static void printall(struct mixer *, int); static void printminfo(struct mixer *, int); static void printdev(struct mixer *, int); static void printrecsrc(struct mixer *, int); /* XXX: change name */ -static int set_dunit(struct mixer *, int, char *); +static int set_dunit(struct mixer *, int); /* Control handlers */ static int mod_volume(struct mix_dev *, void *); static int mod_mute(struct mix_dev *, void *); @@ -57,13 +54,13 @@ main(int argc, char *argv[]) { struct mixer *m; mix_ctl_t *cp; - char *name = NULL, buf[NAME_MAX], *vctl = NULL; + char *name = NULL, buf[NAME_MAX]; char *p, *q, *devstr, *ctlstr, *valstr = NULL; int dunit, i, n, pall = 1, shorthand; int aflag = 0, dflag = 0, oflag = 0, sflag = 0; int ch; - while ((ch = getopt(argc, argv, "ad:f:hosV:")) != -1) { + while ((ch = getopt(argc, argv, "ad:f:hos")) != -1) { switch (ch) { case 'a': aflag = 1; @@ -86,9 +83,6 @@ main(int argc, char *argv[]) case 's': sflag = 1; break; - case 'V': - vctl = optarg; - break; case 'h': /* FALLTHROUGH */ case '?': default: @@ -125,7 +119,7 @@ main(int argc, char *argv[]) initctls(m); if (dflag) { - if (set_dunit(m, dunit, vctl) < 0) + if (set_dunit(m, dunit) < 0) goto parse; else { /* @@ -217,8 +211,7 @@ next: static void __dead2 usage(void) { - fprintf(stderr, "usage: %1$s [-f device] [-d pcmN | N " - "[-V voss_device:mode]] [-os] [dev[.control[=value]]] ...\n" + fprintf(stderr, "usage: %1$s [-f device] [-d pcmN | N] [-os] [dev[.control[=value]]] ...\n" " %1$s [-os] -a\n" " %1$s -h\n", getprogname()); exit(1); @@ -331,32 +324,9 @@ printrecsrc(struct mixer *m, int oflag) } static int -set_dunit(struct mixer *m, int dunit, char *vctl) +set_dunit(struct mixer *m, int dunit) { - const char *opt; - char *dev, *mode; - char buf[32]; - size_t size; - int n, rc; - - /* - * Issue warning in case of hw.snd.basename_clone being unset. Omit the - * check and warning if the -V flag is used, since the user is most - * likely to be aware of this, and the warning might be confusing. - */ - if (vctl == NULL) { - size = sizeof(int); - if (sysctlbyname("hw.snd.basename_clone", &n, &size, - NULL, 0) < 0) { - warn("hw.snd.basename_clone failed"); - return (-1); - } - if (n == 0) { - warnx("warning: hw.snd.basename_clone not set. " - "/dev/dsp is managed externally and does not " - "change with the default unit change here."); - } - } + int n; if ((n = mixer_get_dunit()) < 0) { warn("cannot get default unit"); @@ -368,43 +338,6 @@ set_dunit(struct mixer *m, int dunit, char *vctl) } printf("default_unit: %d -> %d\n", n, dunit); - /* Hot-swap in case virtual_oss exists and is running. */ - if (vctl != NULL) { - dev = strsep(&vctl, ":"); - mode = vctl; - if (dev == NULL || mode == NULL) { - warnx("voss_device:mode tuple incomplete"); - return (-1); - } - if (strcmp(mode, "all") == 0) - opt = "-f"; - else if (strcmp(mode, "play") == 0) - opt = "-P"; - else if (strcmp(mode, "rec") == 0) - opt = "-R"; - else { - warnx("please use one of the following modes: " - "all, play, rec"); - return (-1); - } - snprintf(buf, sizeof(buf), "/dev/dsp%d", dunit); - switch (fork()) { - case -1: - warn("fork"); - break; - case 0: - rc = execl("/usr/sbin/virtual_oss_cmd", - "virtual_oss_cmd", dev, opt, buf, NULL); - if (rc < 0) - warn("virtual_oss_cmd"); - _exit(0); - default: - if (wait(NULL) < 0) - warn("wait"); - break; - } - } - return (0); } From nobody Tue Mar 3 12:18:21 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQFFV24sxz6T39y; Tue, 03 Mar 2026 12:18:22 +0000 (UTC) (envelope-from brooks@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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQFFV1T12z3brB; Tue, 03 Mar 2026 12:18:22 +0000 (UTC) (envelope-from brooks@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772540302; 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=bOyNk1wZ68Xu2JEPA4p6+VSELfYKB8WyrtWpZXDyh9g=; b=Yy/wCsCApwTbnFc+fgD0CC1W1dbdvUsLVImHT7wjwqNFwfqBIxiWTiHRvug47vTQ+y60kv IZzGXqn5eL8KBRdzIHwpdOqpTJYhroArFVUsRkBU4YrZ1AfFKiFISBWK+OHBNcgx1YKauk Cvf06HKDl97iK8YgcM/QdEmU7ZR+jlcfVeatJdJOQjKjNCFT8onwdlKCQRvApwqbL5UDQ6 GKjAeF7kYUkIanpT80pbSF7PWvb7vMmAFoE4xtVNDzOMG9L1BXBUSe+4l/8zQvC9Idym56 /UWoxs9DyjKyVfZ0nL1oRQv9SZMCs1kSoLYovoOyEpirCCqTxlLwsPvgE18yPQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772540302; a=rsa-sha256; cv=none; b=QMnCLHDHWpscU7rG2dTC9mrw93B52CdUppZUPorBq3oM21+y9VWMoBiphaZ3R0u/nakC7d Li0/nhAGCf9Cl1DPSWxH12FZr5CQD+6HcFFHfRHac/cyvI1tQzjbIwtmfjrF3HCplr4LrN lZPytbof3HrpLgVjK4ozkPVdfX7GP/f89/5vX6evikYEIlmdSRKnZHJj0CyMIQ/mB4tAOa RcZ+slMVcq4/dmIBB2fKfaLuqG3db/97OS3blCqBc7IYCupdtXGl1mZYNSEdUvihN8O8ZI 85Mf6ROyDQ1tqlzzrbYq/3CCZgcgOZRId+3l324QnPGl7DJ8bKZ8819mFR8sbA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772540302; 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=bOyNk1wZ68Xu2JEPA4p6+VSELfYKB8WyrtWpZXDyh9g=; b=wCqxwq8NeEJWnrc0yqtHDBdPPTpLiVCsj8DaMcrbJ+9sJmUbt1AdMkEHMhdLKoXMrldgZw nEuOAmBtAzf/xeJgP+Qaj7V/2PLRxlBSCtkPg90FfAv61LqB5Gf7mnFfvkmRsBeDnsGPpa Jo0lgdP2FRZS0CcRfpu+rEd+28HaB/1irv4GPDb+mLzG5HnJZWogPo8kRV3LhEzXxt6Ghx 5J936ImdR6JSuBW00JBq32531hcbEguc1CryxnzS6PlJH3vEae7+HhOusD/FJneHlZW3kr EHz213c1+HLFfhHeipN+epURk7msuDI2S+PB77YqvdprJEC55UcKG2+jdSmDwA== Received: from spindle.one-eyed-alien.net (spindle.one-eyed-alien.net [199.48.129.229]) (using TLSv1.3 with cipher TLS_AES_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: brooks/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4fQFFV0Ww6zJVZ; Tue, 03 Mar 2026 12:18:22 +0000 (UTC) (envelope-from brooks@freebsd.org) Received: by spindle.one-eyed-alien.net (Postfix, from userid 3001) id 74D9B3C01A0; Tue, 03 Mar 2026 12:18:21 +0000 (UTC) Date: Tue, 3 Mar 2026 12:18:21 +0000 From: Brooks Davis To: Warner Losh Cc: Enji Cooper , src-committers , "" , "" Subject: Re: git: 912864912b71 - main - Run `make obj` before running `make test-includes` Message-ID: References: <69a678f3.3f811.148b0d7d@gitrepo.freebsd.org> List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Tue, Mar 03, 2026 at 04:25:48AM -0700, Warner Losh wrote: > On Mon, Mar 2, 2026, 11:00???PM Enji Cooper wrote: > > > The branch main has been updated by ngie: > > > > URL: > > https://cgit.FreeBSD.org/src/commit/?id=912864912b71951f9a636190b1dba80528f588eb > > > > commit 912864912b71951f9a636190b1dba80528f588eb > > Author: Enji Cooper > > AuthorDate: 2026-03-03 05:59:50 +0000 > > Commit: Enji Cooper > > CommitDate: 2026-03-03 05:59:56 +0000 > > > > Run `make obj` before running `make test-includes` > > > > Before this change, `make test-includes` (run as part of buildworld) > > would place test files in the current directory, which would clutter up > > git clones. Run `make obj` beforehand to ensure that the files are put > > in `${.OBJDIR}` instead of `${.CURDIR}`. This helps cut down on the > > noise significantly when running commands like `git status`. > > > > I've never seen this happen. .OBJDIR is created automatically for me always > for the last 5 years... I run buildworld all the time. Can you explain when > / how it happens more specifically or back out the change? The commit message is unintentionally misleading and incomplete. I hit the problem a week or so ago when fixing gcc12 builds and lacked the time to follow up. test-includes is fine as part of buildworld, but when run directly from src does fill tools/build/test-includes with .c files if you blow away the objdir (which seems to the the only reliably way to cause test-includes to retest some more complex cases.) -- Brooks From nobody Tue Mar 3 12:22:42 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQFLl6xfsz6T3TY for ; Tue, 03 Mar 2026 12:22:55 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pj1-x102d.google.com (mail-pj1-x102d.google.com [IPv6:2607:f8b0:4864:20::102d]) (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 4fQFLl51HBz3cpY for ; Tue, 03 Mar 2026 12:22:55 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pj1-x102d.google.com with SMTP id 98e67ed59e1d1-3598b2318c2so1232452a91.3 for ; Tue, 03 Mar 2026 04:22:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1772540574; cv=none; d=google.com; s=arc-20240605; b=kGBUZJM9DkehlDFWPG6BzPVZzS9gW8/xMoJq6f/DJXNFqgTYjKC+a7YhRWmTbJaP5T 3YzM6+QlTenFWwVyrYJ8oLdfQqYnUBKnh0Qab7H9cUqnDJl0gX5Rqh91c5gURMsB+7Jn YV143C7zFin3IE0uNDkQj4WvTc6XfajtgesuXATZQwIy6AEV01i78HehKleUXbrEBO8n Sz6TwWXNE763qGozaoIu1K1n1LUGsbBl2T1PqNlcRZHtO5lXC+rR/W+CCk9lP79i0i8x xqpgqig/sD3MrZQkKLUUsIwxV0ooAQuN+yrzNp4UFm3rlj/rmwP1nLrGrF0LnkZM9EXe Kezw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=bdE7lbu1GQ/XGD9KX4lBzwzb8cI5hK67bQEE5T2fKU0=; fh=oDmUv+gOGP/cuUYRwPbMBo76G2znjUU3u495iyD4cXo=; b=f9LECKffaZvhPqVKqOxNdJyCUoJ/4BNCBnbmB2BV233Gq5IJQyTF+Hotn3dFkXtGjY 3aIwf+f8jYXuBA4m+VE3SA+LJEwaEnEwH3iVF5zh2Ry69M3dziRhv6cUHhgy9+QRKalH Mq4nGtKRHdc9jq9A8P4ryWh8Wnl6EGgw9DUNgdB72gRNKKqtN9MDQVsv7yJd0ubLnmrx /k/VyWMslWsJUQg0I0TgUr8eXg4G0HufCodlholvhhyKjq/oMMc47TfcFOmxygudNyk1 UJDud45vOPXbgXwHfdG0jrXuOfbpO4Wrkf0XS0iORhXfYjo/fsjXyBhj1iyGV3teAMTD M90w==; darn=freebsd.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1772540574; x=1773145374; 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=bdE7lbu1GQ/XGD9KX4lBzwzb8cI5hK67bQEE5T2fKU0=; b=YfCSwlHDT03/bkpA85zPyom0lvjOPd1B9HcZw2GUzBGAN6cgOE/FtWc/XBTYa+MlNQ LBufP3OAGKx2la8afuimMaD3g+h+2S0GNKww1yku5bzQKfDQGIc/uOPcSAjZ2P+4++pH +ujytGWm9CVvY/NyAAprq1GwDiVxD0XUCM59nNbSJ4HjnkyCoj62rfq61jlkAPUEJ33p 4nocZ12+FYjVJ3jgFHPOla1rNTT/BU/qMqU9PbHmmJnm/l7nYx1pq29aeNM59IZipNgK OIwIknuMEigKIl4MAJWnL4OTAo1WPQryNHp6xm+u6l0hjszJElz3AQK1f6OyEsfpHZYe 61RQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772540574; x=1773145374; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=bdE7lbu1GQ/XGD9KX4lBzwzb8cI5hK67bQEE5T2fKU0=; b=FJDURMI9M5QICUBuiIDh895dQiHKSpN3BmAfDROmRFx4ik1l1MfNaD1Y2QIkmfoC4b WliHPOHewp0JiAj7Eib8dwL+sxlagaT41fW64zydyTevhDA2CC3zESbM0WDEaRXlydSV 4fyD/4vFZXfvtRg5yK7z35k44nmiaZWpquAyxgzTiLl2hFsfn2sHMgI19lUFc9/cDwUX 9nnZO3Zd6YGReMHkK3cghTXLuyJEhIzWkd/xLS7vs32HqLCBCWD6DyWvBIIvW4gouhst BcyTsJ9RL461Re398W/bYZQyQ+dDR6UM0gnv+xW/IbDAcouWVUMi57UsgsgfG8kBC+me 0YoQ== X-Forwarded-Encrypted: i=1; AJvYcCXik7GkmKj81zxmg447a/Sf/Fk7D+rK0cTnjGky+FrHX+MHMnVnHZJ/N46RUdU3U+I/NaDg8VMoFmfKWAtQOj7C+6GuGA==@freebsd.org X-Gm-Message-State: AOJu0YwNeXCaZOTPSxnVPYkdDsENxcYYcRYP57nR2CYD1HE4Af1gOHKO nb0BK735HirObKUJPkVYQzzpXt8vLRo4aOXe7+ODrE248p43Y76Hwlf+TkBiSOvcPBehfw8dRYk S/QybaNgkS0rjJLJcFI1jh5Kd4KcwX/qWqgeVSpzT4Q== X-Gm-Gg: ATEYQzxHDZclc6FmbITZcdRzy4ye6oHSyoBM50PS1N1Xj4RAY4P3VSHAe36wXiNEERs OelHG6+vBmBLgS/Xh4W4APy0iPemmsWVRTJ09udsi7Xl+d+9wgxSRy/S4v6QosjS9tXP9mnJN1Q /AdXwjavy6wC9Fd7VPN6dyy8m9a6ezitiQh4WqlAefHqN0Gh+2xPMTWQc+JagliPpP5I3VGXLjI z6WSLbyaX4zP23NdiBamchyrgGVyGeONhoePTHo4WHTLI4U7Udg6Ye1qtj6cf5AeWWrUZV9EFbk frWKzkQ= X-Received: by 2002:a17:90b:2e0e:b0:359:8d38:cdee with SMTP id 98e67ed59e1d1-3598d38dcbdmr5672727a91.2.1772540573608; Tue, 03 Mar 2026 04:22:53 -0800 (PST) List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 References: <69a678f3.3f811.148b0d7d@gitrepo.freebsd.org> In-Reply-To: From: Warner Losh Date: Tue, 3 Mar 2026 05:22:42 -0700 X-Gm-Features: AaiRm51-d9MmHTvMClVX0KURzOo75eC0I0uaLzl9aojDlLQ-OuEnr3lWSxZtq60 Message-ID: Subject: Re: git: 912864912b71 - main - Run `make obj` before running `make test-includes` To: Brooks Davis Cc: Enji Cooper , src-committers , "" , "" Content-Type: multipart/alternative; boundary="0000000000003d7be1064c1dc36c" X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated 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-Queue-Id: 4fQFLl51HBz3cpY X-Spamd-Bar: ---- --0000000000003d7be1064c1dc36c Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, Mar 3, 2026 at 5:18=E2=80=AFAM Brooks Davis wr= ote: > On Tue, Mar 03, 2026 at 04:25:48AM -0700, Warner Losh wrote: > > On Mon, Mar 2, 2026, 11:00???PM Enji Cooper wrote: > > > > > The branch main has been updated by ngie: > > > > > > URL: > > > > https://cgit.FreeBSD.org/src/commit/?id=3D912864912b71951f9a636190b1dba80= 528f588eb > > > > > > commit 912864912b71951f9a636190b1dba80528f588eb > > > Author: Enji Cooper > > > AuthorDate: 2026-03-03 05:59:50 +0000 > > > Commit: Enji Cooper > > > CommitDate: 2026-03-03 05:59:56 +0000 > > > > > > Run `make obj` before running `make test-includes` > > > > > > Before this change, `make test-includes` (run as part of > buildworld) > > > would place test files in the current directory, which would > clutter up > > > git clones. Run `make obj` beforehand to ensure that the files ar= e > put > > > in `${.OBJDIR}` instead of `${.CURDIR}`. This helps cut down on t= he > > > noise significantly when running commands like `git status`. > > > > > > > I've never seen this happen. .OBJDIR is created automatically for me > always > > for the last 5 years... I run buildworld all the time. Can you explain > when > > / how it happens more specifically or back out the change? > > The commit message is unintentionally misleading and incomplete. I hit > the problem a week or so ago when fixing gcc12 builds and lacked the > time to follow up. test-includes is fine as part of buildworld, but > when run directly from src does fill tools/build/test-includes with .c > files if you blow away the objdir (which seems to the the only reliably > way to cause test-includes to retest some more complex cases.) > Ah! That should have been in the commit message as the edge case that provoked this. That's a decent explanation, though there's other bits of buildworld that will also cause problems if you do them in isolatio= n and not part of buildworld. This one, though, is important enough to make an exception for, I think. It's one that's most likely to be used in isolation. Warner --0000000000003d7be1064c1dc36c Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Tue, Mar 3, = 2026 at 5:18=E2=80=AFAM Brooks Davis <brooks@freebsd.org> wrote:
On Tue, Mar 03, 2026 at 04:25:48AM -0700, Warner Losh= wrote:
> On Mon, Mar 2, 2026, 11:00???PM Enji Cooper <ngie@freebsd.org> wrote:
>
> > The branch main has been updated by ngie:
> >
> > URL:
> > https://= cgit.FreeBSD.org/src/commit/?id=3D912864912b71951f9a636190b1dba80528f588eb<= /a>
> >
> > commit 912864912b71951f9a636190b1dba80528f588eb
> > Author:=C2=A0 =C2=A0 =C2=A0Enji Cooper <ngie@FreeBSD.org> > > AuthorDate: 2026-03-03 05:59:50 +0000
> > Commit:=C2=A0 =C2=A0 =C2=A0Enji Cooper <ngie@FreeBSD.org> > > CommitDate: 2026-03-03 05:59:56 +0000
> >
> >=C2=A0 =C2=A0 =C2=A0Run `make obj` before running `make test-inclu= des`
> >
> >=C2=A0 =C2=A0 =C2=A0Before this change, `make test-includes` (run = as part of buildworld)
> >=C2=A0 =C2=A0 =C2=A0would place test files in the current director= y, which would clutter up
> >=C2=A0 =C2=A0 =C2=A0git clones. Run `make obj` beforehand to ensur= e that the files are put
> >=C2=A0 =C2=A0 =C2=A0in `${.OBJDIR}` instead of `${.CURDIR}`. This = helps cut down on the
> >=C2=A0 =C2=A0 =C2=A0noise significantly when running commands like= `git status`.
> >
>
> I've never seen this happen. .OBJDIR is created automatically for = me always
> for the last 5 years... I run buildworld all the time. Can you explain= when
> /=C2=A0 how it happens more specifically or back out the change?

The commit message is unintentionally misleading and incomplete.=C2=A0 I hi= t
the problem a week or so ago when fixing gcc12 builds and lacked the
time to follow up.=C2=A0 test-includes is fine as part of buildworld, but when run directly from src does fill tools/build/test-includes with .c
files if you blow away the objdir (which seems to the the only reliably
way to cause test-includes to retest some more complex cases.)

Ah! That should have been in the commit message as = the edge case
that provoked this. That's a decent explanation= , though there's other
bits of buildworld that will also caus= e problems if you do them in isolation
and not part of buildworld= . This one, though, is important enough to make
an exception for,= I think. It's one that's most likely to be used in isolation.

Warner=C2=A0
--0000000000003d7be1064c1dc36c-- From nobody Tue Mar 3 14:26:35 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQJ5R4klyz6TB3H for ; Tue, 03 Mar 2026 14:26: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQJ5R43PPz3psN for ; Tue, 03 Mar 2026 14:26:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772547995; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=A+DrG+u0u+XFaX8XBMYic00/ielIAk6oKT9vrl5lwBc=; b=tuIy1q5Tp27Kxy+iz0WZr+F1eVr5fxGvXwzukk8ciqIrcE3LJjcjzprsyoECu7YSDdt8At SbYEUoQbUAFiDWmgA5Vahy65Id4fXsmz51D5hLzdr0QdBP19mJbCo8ZLfwg3SDJNzu3Rf1 MIQNkE7wHTR5PM6u5ob+kjQeI/QR3hp4VDSB1TNHEzD/Deibuomc9axgljyozSmTOq37nw iaF6bZiToEAc0SzWr20A0w60bCCzfgrGhAtNv+4oiVolD94yL24ZSrpjGDyH02skQqSHEe swuzsarJ2SzB2WLMtEuRWnbMUfQKiV5t+G3NnaSSpt0d4hS7V/nFGC5pbz2TaA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772547995; a=rsa-sha256; cv=none; b=h0yWjA6N2ka6lO98Wpc9jx9qcCXNEveB0lB13+oz5sbKstttYXTJRjX9K4I0A+okRtamU2 l03sXZ70hdETIeN8gric8whLVTrtca4GBJ+WrhJePRNsvgIJVtZzhZCP0CgyRkss3z9kqh +lbo86g6Y6i6KSLLZqPJZvx7PMWClfy3r/BYCLIwUTVVCIS2Sq1XgZl0Ex70lJEn+vwfP3 cGerKOu7QDMlhY1Hsur0h9ma/3LkEGfkpgPb63rG1sQYTb2D/J96Pr3NrkkzrFrcVpxyRl yRHiuQUss3rUsmHzkQi/RaV4czB7g476KR+5/V4aJRpvxRf3x+34kIv27c83yg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772547995; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=A+DrG+u0u+XFaX8XBMYic00/ielIAk6oKT9vrl5lwBc=; b=DuvrPjpvKMF4GpwvIfQzn3GmIpItywo3G+uNBC0+Yj/hUhY90P9CaoPsH9i/CBFVK2Qcwd bxPrKyAhv5UH8s7gpUM1yDKhf+Z5BDbiIB0iVb3nPN20zTtYB2L4u0Zv9mCeeh+8Fp4OJb wumPNT8xaR28/LssCackcCsqsUS+soUgqwkKtvoqIhexTDat+3QCz84j7HPtBNgRTQ0JMB aiXxJzo45EplLfO2twCuY3JgiVutseopiZnlGmCmqeHKdsxwCIXLBnv6k5P8nBiRxI8x/9 oqgOQeOgQs96JSU5VgkEA4b0GRtTvt93b9deIKCcF7RO+DMQqOSrvosazwhWow== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQJ5R38Zdz1NRM for ; Tue, 03 Mar 2026 14:26:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 2479f by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 14:26:35 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 4c822e8b7de2 - main - src.conf.5: Regen for typo fix in commit 8e9515839369 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 4c822e8b7de246bbf139e493ee33c73cdc4e4c28 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 14:26:35 +0000 Message-Id: <69a6ef9b.2479f.5fd083b4@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=4c822e8b7de246bbf139e493ee33c73cdc4e4c28 commit 4c822e8b7de246bbf139e493ee33c73cdc4e4c28 Author: Ed Maste AuthorDate: 2026-03-03 14:24:38 +0000 Commit: Ed Maste CommitDate: 2026-03-03 14:25:53 +0000 src.conf.5: Regen for typo fix in commit 8e9515839369 --- share/man/man5/src.conf.5 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index 1a0f14d9f7ba..ead1a7cf3148 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -1997,7 +1997,7 @@ Build the base system or kernel with stack variables initialized to zero on function entry. This value is converted to .Li none -for amd64 kernel builds due to incompatibility with ifunc memset. +for amd64 kernel builds due to incompatability with ifunc memset. .El .It Va LIBC_MALLOC Specify the From nobody Tue Mar 3 14:26:36 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQJ5S5Q9vz6TBFR for ; Tue, 03 Mar 2026 14:26: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQJ5S48GLz3qLK for ; Tue, 03 Mar 2026 14:26:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772547996; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=W4K0IfhVZEA5Xf5u/iXIxbq/vHwaIFGyNsnCqUpbzIs=; b=KyNI08auhD4ag9YkP7o5zNRRcPSjkcuDuFtOFA54QX5eagtNB2xgqLxQo4+4woGNdwMruK BBsyA97LHusDHS/Xrpg9JGZGVCvWd5r+HN/kHnA2KAKJCXd1lLE16f2ItSZrh0TEDwv9Oa GEJqFlQFJC59BlAMrQb3npxojQ4WGscoTgO4OvZskXvymhaKrs6J/zsqRa5Lhal740r6SW b7bP8BZnzZXVAlzecEnmNNqWqFq9iFAqCa2wMiGN0A/VxkeZ1pD9lr5C/ljDpNQm3TLTys iVzrwF0pWxEw2DGTzdFTU3wNZVTD6BnnwNUqwfxnarMVcx+tqM8LthpD2sGUcA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772547996; a=rsa-sha256; cv=none; b=TSvSeIVD4MRFtic1bBamyFE9OGYLNtpMASE7/DObXICRd+SfevFlKBz0ofMKQcmTkuyZL3 w8vLeGcFV/NzxN8ABVHMOkP5DPjDluNMx9ljPzdYdG0AEtQ5z+80v/+abP5dLvQGu1Junt nPDjrRUKH3ReumieOXJSaCdP8+XCI4hgA/ZqCBCtONq4QupzE+GICLIJL3niCzSO2IGPFb iCzFdrydDOylCdv+2Su6QZM4bvNRkzFPfCSBoirRAidY24ZavbrvRAbZ5kOaw2LaS6AcVg Hr/9BFYNcM2zS411tT+v1SfI6tdjAKjHX2pnPMq5abKQjJc1+onItuvU1z43rg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772547996; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=W4K0IfhVZEA5Xf5u/iXIxbq/vHwaIFGyNsnCqUpbzIs=; b=iOIfoB6WC3tG0u1V02idLrnAsoqmkHXM1/wjDmwigr/jApWDmFpBVf79SKsIrDMiWSu64U tpZLHwynIGqRnUwpxqtdczylqra+rJKTvEnyFahj/UEoftzpWZLEZ1MNzKNjioBAYyr+Av CABqP4w5hPQYNr8464HwtBlAMDfiHmFXyktrg4Ca6U5FdYDQHmD0BIlclhlYWPPV6z22Le qsdRIQI+Ga+z7aBKV+sml2R/8FmQwUXZbAACe3UMye62pE8Pdmk390Jbf0hr1sjG4758nq F73cBKgw3+uERvDiw9/b66j/AGaMmop4n9fawdGMtOkg8aoWfJsvBQrqDF+acw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQJ5S3LYLz1NRN for ; Tue, 03 Mar 2026 14:26:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 23ad6 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 14:26:36 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: b6bb2fc77e37 - main - src.opts.mk: Retire BSD_CPIO option List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: b6bb2fc77e37fcb1efb4f83fcb2965f26b4db705 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 14:26:36 +0000 Message-Id: <69a6ef9c.23ad6.116baa11@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=b6bb2fc77e37fcb1efb4f83fcb2965f26b4db705 commit b6bb2fc77e37fcb1efb4f83fcb2965f26b4db705 Author: Ed Maste AuthorDate: 2026-02-23 19:36:09 +0000 Commit: Ed Maste CommitDate: 2026-03-03 14:25:53 +0000 src.opts.mk: Retire BSD_CPIO option Prior to commit 6973701a00e3 ("1. Make the BSD version of cpio the default [1]") GNU cpio was installed unconditionally. The BSD_CPIO option was added when we introduced the BSD licensed, libarchive-based cpio, to support installation of GNU cpio, libarchive cpio, or both. GNU cpio was removed long ago and there is no longer a need for this option. We can just install BSD cpio unconditionally. Reviewed by: des Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55467 --- share/man/man5/src.conf.5 | 5 +---- share/mk/src.opts.mk | 1 - tools/build/mk/OptionalObsoleteFiles.inc | 7 ------- usr.bin/Makefile | 2 +- 4 files changed, 2 insertions(+), 13 deletions(-) diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index ead1a7cf3148..9b185e77c126 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 February 13, 2026 +.Dd March 3, 2026 .Dt SRC.CONF 5 .Os .Sh NAME @@ -296,9 +296,6 @@ Do not build .Xr bsdinstall 8 , .Xr sade 8 , and related programs. -.It Va WITHOUT_BSD_CPIO -Do not build the BSD licensed version of cpio based on -.Xr libarchive 3 . .It Va WITHOUT_BSNMP Do not build or install .Xr bsnmpd 1 diff --git a/share/mk/src.opts.mk b/share/mk/src.opts.mk index bd282224ea65..4abe1c699b4e 100644 --- a/share/mk/src.opts.mk +++ b/share/mk/src.opts.mk @@ -71,7 +71,6 @@ __DEFAULT_YES_OPTIONS = \ BOOT \ BOOTPARAMD \ BOOTPD \ - BSD_CPIO \ BSDINSTALL \ BSNMP \ BZIP2 \ diff --git a/tools/build/mk/OptionalObsoleteFiles.inc b/tools/build/mk/OptionalObsoleteFiles.inc index 648d0d3b297d..c915da8ca501 100644 --- a/tools/build/mk/OptionalObsoleteFiles.inc +++ b/tools/build/mk/OptionalObsoleteFiles.inc @@ -452,13 +452,6 @@ OLD_FILES+=usr/share/man/man8/sade.8.gz OLD_DIRS+=usr/libexec/bsdinstall .endif -.if ${MK_BSD_CPIO} == no -OLD_FILES+=usr/bin/bsdcpio -OLD_FILES+=usr/bin/cpio -OLD_FILES+=usr/share/man/man1/bsdcpio.1.gz -OLD_FILES+=usr/share/man/man1/cpio.1.gz -.endif - .if ${MK_BSNMP} == no OLD_FILES+=etc/snmpd.config OLD_FILES+=etc/rc.d/bsnmpd diff --git a/usr.bin/Makefile b/usr.bin/Makefile index de422170be1a..0c9c66748269 100644 --- a/usr.bin/Makefile +++ b/usr.bin/Makefile @@ -24,6 +24,7 @@ SUBDIR= apply \ comm \ command \ compress \ + cpio \ csplit \ ctlstat \ cut \ @@ -185,7 +186,6 @@ SUBDIR= apply \ SUBDIR.${MK_ACCT}+= lastcomm SUBDIR.${MK_AT}+= at SUBDIR.${MK_BLUETOOTH}+= bluetooth -SUBDIR.${MK_BSD_CPIO}+= cpio SUBDIR.${MK_CALENDAR}+= calendar .if ${MK_CLANG} != "no" || ${MK_LLVM_BINUTILS} != "no" || \ ${MK_LLD} != "no" || ${MK_LLDB} != "no" From nobody Tue Mar 3 16:03:47 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQLFx3MNkz6TJ2f for ; Tue, 03 Mar 2026 16:04:05 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-oi1-f179.google.com (mail-oi1-f179.google.com [209.85.167.179]) (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 4fQLFr3yqsz44QZ for ; Tue, 03 Mar 2026 16:04:00 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Authentication-Results: mx1.freebsd.org; dkim=none; arc=pass ("google.com:s=arc-20240605:i=1"); dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=freebsd.org (policy=none); spf=pass (mx1.freebsd.org: domain of carpeddiem@gmail.com designates 209.85.167.179 as permitted sender) smtp.mailfrom=carpeddiem@gmail.com Received: by mail-oi1-f179.google.com with SMTP id 5614622812f47-45f10d7eb81so2320234b6e.3 for ; Tue, 03 Mar 2026 08:04:00 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1772553838; cv=none; d=google.com; s=arc-20240605; b=eOrexErTP1f2d+JsD3qxlqiWs8RpjEzWYdMC1PuUd5e6lvu3JR9rYR1iy92/63nJN+ 1cwFc9vj/iGX1y4yFk9GUZ6H2QKnIld5u9hnOtZlE1KKRcBjYFmjamys0WIAhfILAuRy zLTZuzLdGPzUQ+qo+19soX9t0KuJcpOBq5JYy6U8WBvtp7XJNaSX+JJnmts9qvVZqCL3 HvbwHUBgngoYsxaG4T3zi5yhvG8W1LpWZcn3fdLeBVQGYG4tXafQ/qal8qfWNaXyFQzl glofOeSEpvpLADsUUXl3dbI5VoLWnEXW1mwJaiM2HrHxrLJBqG0rnmeBmXj7NoWn2A88 ClAA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=to:subject:message-id:date:from:in-reply-to:references:mime-version; bh=AebgYAn9duLNcAZOCRrMABvNGAFq4nCgJg5lDHTR7Tk=; fh=gjInN7E9QWCVaFuomIofbpEwWvJLrR7vFHL5PrGiAtc=; b=evYDMOxBc4fVs71CNI/m25cNf23CCJphHSJeyfclKmhFDZ0asW0qJG7EGTE10PZmGh qaAPJLFn8FUlzv/PS7tlQQgP5NHirmPHX99mjhFPIZ75c5CXelWCNn4w/r+UqSxoDvR7 2PBIA0gftl2x4CqkYMrIxaC52tgnd6Z+kkqBC6++F1/C+iRkVlTI92TFpOwpOswae1/O Q9NCyzcTYfMEv4Qq9lC1LELCxh/yC1bbvr4kEihdIWpf6WvZDIHuRTMmg8WLfx7gX0uf WfLNGtTpt2M0dA9c1cfy2obtJXH5svJcKd2kihsYYT7OXRIGYP3VruiuLKoyqWOh0T8r 8zmA==; darn=freebsd.org ARC-Authentication-Results: i=1; mx.google.com; arc=none X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772553838; x=1773158638; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=AebgYAn9duLNcAZOCRrMABvNGAFq4nCgJg5lDHTR7Tk=; b=iTfET+n7dpxW/U3hE58a98XrHa//52oC/hPUmIr8Ga/cJm46+ocTjR57qry3xaVABI e/X5BShURrRIiKsn8LoDOAXr3LDJ62wkf2Iw8NhMpYYvsX3FCsekgrugg4a5UrvaMu9K QE1/lhmkX5o6eQKtGzIWkG3r+2UNJ4BmKwm+zkjNDrRqkQb1hxIQI6EMQbUWYE23yNDv lfnxpnEoKXyx0PfUQNH54/fW4/YoxbLzjBJGKlxHQSDXc82FQn7HWmlMw/aOWC4l5vy5 DNtNLRwW2ylORCFf9Ljt6sfTnoPlTmLxogfP1l8/J2GHZbtUXTQkLb9g+YDIZUOABowc ij7w== X-Forwarded-Encrypted: i=1; AJvYcCU0OylN6wUz6AI03n3wIGM3LH9/sSPIQ2Zyig3tMlxE6BXE7v591uaysU1afFXk+k/OiS5jFITZUys4KphjDbNym8eV5w==@freebsd.org X-Gm-Message-State: AOJu0YxGAjFcaIwetScnG549W89iji45Zxurc8VyW9rlyMxD7/H7fDKC VAeC9cjAJlPLstzjhgb5uPi0fMuRmFA26Fb1fDJQIBsZcRa/oLpeWQqvBqelkm1UHL2VBmLlWhH B+4rBsA86d2QYsed6YUGkvSOD8J/U+/I= X-Gm-Gg: ATEYQzxvRzGZ4zlkRVe0PAXHN0cKOCL8SDbYuKqw3TrYNNmZdFfHoSBoRNp++/ekBS5 I5H+uQQOvOkE7BnOrfViZVYxlYDt9ERb3v5VZmVQWiFBQNORpDCpXH4yQvLNvdHWtQmt1aEriMS 9tbejhlPs9yNpE18gGTOQoXSWQ17rLhCXO5sD9isUvGP1UbT5kqhYMc91C+hq5U3RU8vWe5xN/M QlXGwfWatA5ydBn9pA74u6tb4wmFobj5yxMT170fMA7O0nvTho/V+TE+3AEia62DBI0nIqcrUE3 5rxBUj3uC0C5E9F4CAr15oYLbydyDOV+UDB3pms= X-Received: by 2002:a05:6808:1b12:b0:450:839a:557 with SMTP id 5614622812f47-464be972c03mr8754291b6e.9.1772553838458; Tue, 03 Mar 2026 08:03:58 -0800 (PST) List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 References: <69a6ef9b.2479f.5fd083b4@gitrepo.freebsd.org> In-Reply-To: <69a6ef9b.2479f.5fd083b4@gitrepo.freebsd.org> From: Ed Maste Date: Tue, 3 Mar 2026 11:03:47 -0500 X-Gm-Features: AaiRm53fskOlwN2o8b3HzUyhvu3w-RYDDw6kqEqqr583kQMkNmBVGxH-0mVmfV8 Message-ID: Subject: Re: git: 4c822e8b7de2 - main - src.conf.5: Regen for typo fix in commit 8e9515839369 To: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: text/plain; charset="UTF-8" X-Spamd-Result: default: False [-3.81 / 15.00]; ARC_ALLOW(-1.00)[google.com:s=arc-20240605:i=1]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.99)[-0.994]; NEURAL_HAM_LONG(-0.92)[-0.918]; FORGED_SENDER(0.30)[emaste@freebsd.org,carpeddiem@gmail.com]; R_SPF_ALLOW(-0.20)[+ip4:209.85.128.0/17:c]; DMARC_POLICY_SOFTFAIL(0.10)[freebsd.org : SPF not aligned (relaxed), No valid DKIM,none]; MIME_GOOD(-0.10)[text/plain]; FREEFALL_USER(0.00)[carpeddiem]; MISSING_XM_UA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN_FAIL(0.00)[179.167.85.209.asn.rspamd.com:server fail]; RCVD_COUNT_ONE(0.00)[1]; FROM_HAS_DN(0.00)[]; FREEMAIL_ENVFROM(0.00)[gmail.com]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RWL_MAILSPIKE_POSSIBLE(0.00)[209.85.167.179:from]; FROM_NEQ_ENVFROM(0.00)[emaste@freebsd.org,carpeddiem@gmail.com]; RCVD_TLS_LAST(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[dev-commits-src-main@freebsd.org]; TO_DN_NONE(0.00)[]; MLMMJ_DEST(0.00)[dev-commits-src-main@freebsd.org]; RCVD_IN_DNSWL_NONE(0.00)[209.85.167.179:from]; R_DKIM_NA(0.00)[]; RCPT_COUNT_THREE(0.00)[3] X-Rspamd-Queue-Id: 4fQLFr3yqsz44QZ X-Spamd-Bar: --- On Tue, 3 Mar 2026 at 09:27, Ed Maste wrote: > > The branch main has been updated by emaste: > > URL: https://cgit.FreeBSD.org/src/commit/?id=4c822e8b7de246bbf139e493ee33c73cdc4e4c28 > > commit 4c822e8b7de246bbf139e493ee33c73cdc4e4c28 > Author: Ed Maste > AuthorDate: 2026-03-03 14:24:38 +0000 > Commit: Ed Maste > CommitDate: 2026-03-03 14:25:53 +0000 > > src.conf.5: Regen for typo fix in commit 8e9515839369 This is a mistake, 8e9515839369 is unrelated to the change here. This change actually reverts 102fed041d7f, which fixed a typo in src.conf.5 but not in the source file tools/build/options/INIT_ALL. The fix was lost when I regenerated src.conf.5 after the BSD_CPIO change. ziaee@ is going to fix the source file and regenerate again. From nobody Tue Mar 3 17:09:10 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQMj32LbBz6TMdj for ; Tue, 03 Mar 2026 17: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQMj30B6Mz49pV for ; Tue, 03 Mar 2026 17: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=1772557751; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=MQOVvrjSUveAP5cZti8CF1ym223BQW7qtL55FqOAtAY=; b=fNdpTiT4bhXkJ+AYN92ovVTRTWorVv6KrZuwDNLxV2YOIc/IF/aDxj7BBblq2Gjix/Yz0j XSIix41h6XmAJKRyyo1fS76oAaWrWHRxBvJ9vt30sEE6+GXoSsxqyz8eawXLTr53CUs7AS ybEyoJP5wMFcVQymtibs/tfmq69E6Lwh8/vy495p57J+cfNSl+RLBYJ6Tc45AepDk7Zes4 PhTPm/mU4vJiaPJio10Kb2sx+/1+XNtNA/u0Wq6aR1SXj3yDK2ArS4ZF/ZZLGmLRmzRxdG lIAbKsIoSfLbGoK9cRPbO+LfzUCucKTqCfarLMXP5+jkMduXaUGOzo2YnOmx4Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772557751; a=rsa-sha256; cv=none; b=vp4zF5yJTGf5yJ2giCKWk1xn5H9D/82u+pvu0YfJ2dM96YJU2bUY4wTc6Y1GESuOjxrFtK e4iFZYvcNEN2njlrbHJjQ0zqH9dBMWaOvb+NcoCJ0MkY0sWLn2lfd3ZGHu8KX8iDAnn3Zm o7pTS4PtPH5pF3tDataisU911Rr8tYUg8NJrdTPkPnW5Mc2j0X6u6FgYtEL9tafRWFY5ED /QUOr+9G3CjpsATFsZBu2NvDEK2fOWKvi6/wPQvPMjGVUYVxZ0F1PtEcimGuUGI9oy881Z 8EAVKranzkKXmzQVhWYqEVHkAf0E+ZwP+s8xXbKWKEf4vDGPKOs5pifVKEE8uw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772557751; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=MQOVvrjSUveAP5cZti8CF1ym223BQW7qtL55FqOAtAY=; b=UejFbqE0xUdzFvPMssgOE/m8U3yak8+MR9utcr7U9hqv4gj/2XP4mrpDGBxwLsmRPVT6yE R++zGD2BS06HqaNgj2jLW0Hg+gvR4Vib+q5iusat+jFWxNVoFyNJ9pIvNoJyH7kuhDDcZe zCwAv7BGXWR/HorftaYS2TKS1Hf3VOYiLjIoz6qXWef+VLJd2QhG0/kiQgA2PXn8c97bWw vHp54XRq3TvmbJaIt8cpXCrQrGPkpOqlbjhH7JbCLzRKWrg1FeKttfTjkVB7b2sxO75o0W mzvONkg3F9g8+giy4oWrHFDSY8ZdiC78ZayZT5WTPniT0iQqDkqC23lCDC8zfw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQMj26thGz1SLy for ; Tue, 03 Mar 2026 17:09:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3d3d9 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 17:09:10 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: e80c45dbf7d0 - main - src.conf.5: Regen after commit c47cefba8312 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: e80c45dbf7d098677a607a29a55c07b85ea7f315 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 17:09:10 +0000 Message-Id: <69a715b6.3d3d9.5a440daf@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=e80c45dbf7d098677a607a29a55c07b85ea7f315 commit e80c45dbf7d098677a607a29a55c07b85ea7f315 Author: Ed Maste AuthorDate: 2026-03-03 17:08:39 +0000 Commit: Ed Maste CommitDate: 2026-03-03 17:08:39 +0000 src.conf.5: Regen after commit c47cefba8312 --- share/man/man5/src.conf.5 | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index 9b185e77c126..9b1ef4c3e8d4 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -1876,6 +1876,12 @@ not .Pa /etc/src.conf . .It Va WITHOUT_USB Do not build USB-related programs and libraries. +When set, it enforces these options: +.Pp +.Bl -item -compact +.It +.Va WITHOUT_USB_GADGET_EXAMPLES +.El .It Va WITHOUT_USB_GADGET_EXAMPLES Do not build USB gadget kernel modules. .It Va WITHOUT_UTMPX From nobody Tue Mar 3 17:11:10 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQMlL5qXqz6TMtm for ; Tue, 03 Mar 2026 17: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQMlL4xw3z3C7q for ; Tue, 03 Mar 2026 17: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=1772557870; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=QI1EdwQfBRECeK19oU8TmeHawBlQTTETn36nk94R3Wo=; b=RNZ7yBqke/mXbeLpCQ4IpSi1/885joqyU8S9XRocDcv93kZERnYcd9t1fMhL6Tyxj0EeR+ mUnGirBmvZvYKhKcPZbSu3krtQ9qfcuAFU1tGIfbuKZXpOsrXBffduSSmv0k63n+V12EET JVxaNKqaNIEUpn0wEusa200SFtb68JxG+qwqRbi5el2pjxulSs8og3LbzTED9Ji6lopzTG royOh7J6AbxMbph8zT7eY+CiRaeumG4nxTnFx7KxU5MclFx3STmjHTjm2y3ohusAdWrVeP ri/+yCNAoA6bNHgI7pwmd2EQbKv5fLay5oLR2ITlf7dEijZJpFs2zHjHmCKysA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772557870; a=rsa-sha256; cv=none; b=yP9qht6//if47QtPe6CuBJLS6w8muPrWJ/Ef3NLrH2bf4ou3yMNGBshel/B7LUDNmWI/Rj 2hgEIwcpeM20kkwIY7j8cYX5GsHd1S0TIkoqaKdUm66PMX7+8+mw5NGDPNr6JKzZwWoWk+ SmbXay2cRnyUMFs49GnjIIMrt5at2Boo+rqryfotqDTlcz5ODx3UKFi+I0CCeptpKKP0Jv i5+Ny0tSNqt7pPeAYsV/eVIlDD73YkC/wdWnYwAvmQEOCqyKbdLhC6yCgZhKqQRNQ7Kf1i U99qujJm6Wqfz20KSSysJIpJFbLXvl2sexlefpwg/Gltl+3zfQOUNSSRNY/35w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772557870; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=QI1EdwQfBRECeK19oU8TmeHawBlQTTETn36nk94R3Wo=; b=PRurn0Dt/OmCS3vmEkDP6Vg4hyFf45E9pyMcnYVe9pmoH/1F0Awkr0nwUz6+1mYggy9jeo V5FN9Rr1hB1xXT0fEsvaIZQ9+Qt0k2CdDC/kcwB3EsE6oxTcR6XQFmQUzewHL9J73AVA8+ zsPHYqFNwLPeqVFl3FXNXzFyfvMzjqf/X64cIr4tyK5gpJUTwRzUF0uJsEH38L++2CNUk9 bZRydLZxlW5PJjKZL40dgYMZyl3I6wzpdfsQAeH9t0U9iLY3TwW7P3Cs6KOJ/xXPtwYqoS rYu1zP1UyKKRNBbk3J6c/rWgIMFAuRJCDvb6bVKmYE6NNnhM1KeobZAFaO3rOA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQMlL4W64z1SMH for ; Tue, 03 Mar 2026 17:11:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3e996 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 17:11:10 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: George V. Neville-Neil Subject: git: bc9229035c5f - main - Allow programs run under this program to have arguments. List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gnn X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: bc9229035c5f46674cf06b48d66e9f039b3a9875 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 17:11:10 +0000 Message-Id: <69a7162e.3e996.108a155f@gitrepo.freebsd.org> The branch main has been updated by gnn: URL: https://cgit.FreeBSD.org/src/commit/?id=bc9229035c5f46674cf06b48d66e9f039b3a9875 commit bc9229035c5f46674cf06b48d66e9f039b3a9875 Author: George V. Neville-Neil AuthorDate: 2026-03-03 17:10:26 +0000 Commit: George V. Neville-Neil CommitDate: 2026-03-03 17:10:42 +0000 Allow programs run under this program to have arguments. --- tools/test/hwpmc/pmctest.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/tools/test/hwpmc/pmctest.py b/tools/test/hwpmc/pmctest.py index ba20306f1d68..1c113c256e32 100755 --- a/tools/test/hwpmc/pmctest.py +++ b/tools/test/hwpmc/pmctest.py @@ -27,6 +27,7 @@ import argparse import tempfile from pathlib import Path import os +import shlex def gather_counters(): """Run program and return output as array of lines.""" @@ -58,7 +59,9 @@ def main(): print("Choose one of --count OR --sample.") sys.exit() - program = Path(args.program).name + # Split program and arguments properly + program_parts = shlex.split(args.program) + program = Path(program_parts[0]).name if args.count == True: tmpdir = tempfile.mkdtemp(prefix=program + "-", suffix="-counting-pmc") @@ -73,8 +76,7 @@ def main(): continue if args.count == True: with open(tmpdir + "/" + program + "-" + counter + ".txt", 'w') as file: - p = subprocess.Popen(["pmcstat", - "-p", counter, args.program], + p = subprocess.Popen(["pmcstat", "-p", counter] + program_parts, text=True, stderr=file, stdout=file) result = p.wait() print(result) @@ -82,7 +84,7 @@ def main(): pmcout = tmpdir + "/" + program + "-" + counter + ".pmc" p = subprocess.Popen(["pmcstat", "-O", pmcout, - "-P", counter, args.program], + "-P", counter] + program_parts, text=True, stderr=PIPE) result = p.wait() resdir = tmpdir + "/" + program + "-" + counter + ".results" @@ -97,7 +99,7 @@ def main(): if Path(gmondir).is_dir(): with open(gmondir + "/" + "gprof.out", "w") as file: p = subprocess.Popen(["gprof", - args.program, + program_parts[0], program + ".gmon"], cwd=gmondir, text=True, @@ -109,7 +111,7 @@ def main(): print(result) else: - p = subprocess.Popen(["pmcstat", "-p", counter, args.program], + p = subprocess.Popen(["pmcstat", "-p", counter] + program_parts, text=True, stderr=PIPE) result = p.wait() print(result) From nobody Tue Mar 3 17:37:57 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQNLF1p7Nz6TPb9 for ; Tue, 03 Mar 2026 17:37: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQNLF1Hffz3DvG for ; Tue, 03 Mar 2026 17:37:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772559477; 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; bh=811KZl5qhWo7GrCk5Dk5Yf5B8s0CiC+iuyEob5W/eWQ=; b=j2YkTGFh6hjlNwjvvvUdLJAz32Lh3HycrqMHQbveOSBlb4iy14emWnSkbnEqdyhkB1ETy3 xCo8cixMM2i7JGuV0ZCXWUzeXyPj8utNr1BPX9mVSFQcBbGR/Z8MgzBxUdd/U9URErsLl4 CD+ubUNGtMEt05JxEIzhZIBEwG7I67sXX33NFeD/EtuYbcGCaQhdCEC7ZrtQwnZN0wlwIV 2OFX3Tqy/Y6GRHmH8q2T81Da5BPCxPL10QYMZM8TC+aAHKrNkIUgtGYgPxTMRyoyh/Y4ns t0egP0ce952TrbqOwJN833DC7GVuH2bmw4qhsyuCQU8ptopK8qmoutzrvju/Pg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772559477; a=rsa-sha256; cv=none; b=vfqbk9iCalcQ9Jnwr81Le8CD1cIwnMBQ8Xpmngd40yqphlPw/M5t5uC9RuSHvy19dQlqWl 9kSix0yJHCH2LAsxn+zj29TyFcPf/fUNoswpjSsGtwx2eB74O1EGTy8fITfjUTRGx09wEs oaGF7FQRwEWAGlwqsquNzurBVoGaesDygy6Z4YVuPIZHUAwjju1bmjrNU2RljsGWVNzgcn AEObonL5NnGkX2PGlb9d/Zk3ZkVH/uQ7bEABudL/mGRx4wMxRlfGL8s2/WzQ/cP1P0TCc0 eeJ7BcusJr5Gz1T7j7EdKsxGtqZ1A/PK7FRJTnnhH17+uVTnkcSot7px8CaU4A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772559477; 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; bh=811KZl5qhWo7GrCk5Dk5Yf5B8s0CiC+iuyEob5W/eWQ=; b=hCFMM8luky5f6zA58Ae/8lVnQ1bBrm/wcPg87cna5ZoywkpyTN7HpZtuI5wTw6hJMLYA+e 0uqWQIhBCdsuYoGc0O3JYbqPw1csT2hpuGBuEc2KCdoMDuaN75RkfR5gjkO0p4MrMyzWa2 BO5ecIXhh69gxy93P4+y3le8RvwlBdjHdP27BMJjp5RvEwOtW9Nvn440SS0FC2u4p2Gpr6 x75566igXLb7qMZdc5q7ktIdhzXNCx/Vf7cZXrufi95g77P175caUvWsckQNfeD3jq2kaq ZyXb9JRK/O47hNc1FB0ONvVjj2oFbGkwx0A3s9HA+EHRIb8xu0ZLdinvwiWNAA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQNLF0mFkzcr for ; Tue, 03 Mar 2026 17:37:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 40215 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 17:37:57 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Sarah Walker From: Andrew Turner Subject: git: c499ad6f997c - main - virtio: Use bus_dma for ring and indirect buffer allocations List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: c499ad6f997c8c5f61c88925e6d1e826d0c0f6c4 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 17:37:57 +0000 Message-Id: <69a71c75.40215.43f39fc6@gitrepo.freebsd.org> The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=c499ad6f997c8c5f61c88925e6d1e826d0c0f6c4 commit c499ad6f997c8c5f61c88925e6d1e826d0c0f6c4 Author: Sarah Walker AuthorDate: 2026-03-03 16:08:11 +0000 Commit: Andrew Turner CommitDate: 2026-03-03 16:29:15 +0000 virtio: Use bus_dma for ring and indirect buffer allocations While the majority of virtio platforms will be fully coherent, some may require cache maintenance or other specific device memory handling (eg for secure partitioning). Using bus_dma allows for these usecases. The virtio buffers are marked as coherent; this should ensure that sync calls are no-ops in the common cases. Reviewed by: andrew Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D54959 --- sys/dev/virtio/virtio_ring.h | 27 ++++-- sys/dev/virtio/virtqueue.c | 216 +++++++++++++++++++++++++++++++++++++------ 2 files changed, 209 insertions(+), 34 deletions(-) diff --git a/sys/dev/virtio/virtio_ring.h b/sys/dev/virtio/virtio_ring.h index 15348a77d8a3..7ac78f0defed 100644 --- a/sys/dev/virtio/virtio_ring.h +++ b/sys/dev/virtio/virtio_ring.h @@ -88,6 +88,10 @@ struct vring { struct vring_desc *desc; struct vring_avail *avail; struct vring_used *used; + + vm_paddr_t desc_paddr; + vm_paddr_t avail_paddr; + vm_paddr_t used_paddr; }; /* Alignment requirements for vring elements. @@ -145,15 +149,24 @@ vring_size(unsigned int num, unsigned long align) } static inline void -vring_init(struct vring *vr, unsigned int num, uint8_t *p, +vring_init(struct vring *vr, unsigned int num, uint8_t *p, vm_paddr_t paddr, unsigned long align) { - vr->num = num; - vr->desc = (struct vring_desc *) p; - vr->avail = (struct vring_avail *) (p + - num * sizeof(struct vring_desc)); - vr->used = (void *) - (((unsigned long) &vr->avail->ring[num] + align-1) & ~(align-1)); + unsigned long avail_offset; + unsigned long used_offset; + + avail_offset = num * sizeof(struct vring_desc); + used_offset = (avail_offset + sizeof(struct vring_avail) + + sizeof(uint16_t) * num + align - 1) & ~(align - 1); + + vr->num = num; + vr->desc = (struct vring_desc *) p; + vr->avail = (struct vring_avail *) (p + avail_offset); + vr->used = (struct vring_used *) (p + used_offset); + + vr->desc_paddr = paddr; + vr->avail_paddr = paddr + avail_offset; + vr->used_paddr = paddr + used_offset; } /* diff --git a/sys/dev/virtio/virtqueue.c b/sys/dev/virtio/virtqueue.c index 41e01549c8b2..dbd55e02e091 100644 --- a/sys/dev/virtio/virtqueue.c +++ b/sys/dev/virtio/virtqueue.c @@ -35,6 +35,7 @@ #include #include #include +#include #include #include #include @@ -55,6 +56,8 @@ struct virtqueue { device_t vq_dev; + struct mtx vq_ring_mtx; + struct mtx vq_indirect_mtx; uint16_t vq_queue_index; uint16_t vq_nentries; uint32_t vq_flags; @@ -83,15 +86,22 @@ struct virtqueue { uint16_t vq_used_cons_idx; void *vq_ring_mem; + bus_dmamap_t vq_ring_mapp; + vm_paddr_t vq_ring_paddr; + int vq_indirect_mem_size; int vq_alignment; int vq_ring_size; char vq_name[VIRTQUEUE_MAX_NAME_SZ]; + bus_dma_tag_t vq_ring_dmat; + bus_dma_tag_t vq_indirect_dmat; + struct vq_desc_extra { void *cookie; struct vring_desc *indirect; vm_paddr_t indirect_paddr; + bus_dmamap_t mapp; uint16_t ndescs; } vq_descx[0]; }; @@ -148,6 +158,21 @@ SDT_PROBE_DEFINE1(virtqueue, , enqueue_segments, return, "uint16_t"); #define vq_gtoh32(_vq, _val) virtio_gtoh32(vq_modern(_vq), _val) #define vq_gtoh64(_vq, _val) virtio_gtoh64(vq_modern(_vq), _val) +static void +virtqueue_ring_load_callback(void *arg, bus_dma_segment_t *segs, + int nsegs, int error) +{ + struct virtqueue *vq; + + if (error != 0) + return; + + KASSERT(nsegs == 1, ("%s: %d segments returned!", __func__, nsegs)); + + vq = (struct virtqueue *)arg; + vq->vq_ring_paddr = segs[0].ds_addr; +} + int virtqueue_alloc(device_t dev, uint16_t queue, uint16_t size, bus_size_t notify_offset, int align, vm_paddr_t highaddr, @@ -199,19 +224,58 @@ virtqueue_alloc(device_t dev, uint16_t queue, uint16_t size, if (VIRTIO_BUS_WITH_FEATURE(dev, VIRTIO_RING_F_EVENT_IDX) != 0) vq->vq_flags |= VIRTQUEUE_FLAG_EVENT_IDX; + vq->vq_ring_size = round_page(vring_size(size, align)); + + mtx_init(&vq->vq_ring_mtx, device_get_nameunit(dev), + "VirtIO Queue Lock", MTX_DEF); + + error = bus_dma_tag_create( + bus_get_dma_tag(dev), /* parent */ + align, /* alignment */ + 0, /* boundary */ + BUS_SPACE_MAXADDR, /* lowaddr */ + BUS_SPACE_MAXADDR, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + vq->vq_ring_size, /* max request size */ + 1, /* max # segments */ + vq->vq_ring_size, /* maxsegsize */ + BUS_DMA_COHERENT, /* flags */ + busdma_lock_mutex, /* lockfunc */ + &vq->vq_ring_mtx, /* lockarg */ + &vq->vq_ring_dmat); + if (error) { + device_printf(dev, "cannot create bus_dma_tag\n"); + goto fail; + } + +#ifdef __powerpc__ + /* + * Virtio uses physical addresses rather than bus addresses, so we + * need to ask busdma to skip the iommu physical->bus mapping. At + * present, this is only a thing on the powerpc architectures. + */ + bus_dma_tag_set_iommu(vq->vq_ring_dmat, NULL, NULL); +#endif + if (info->vqai_maxindirsz > 1) { error = virtqueue_init_indirect(vq, info->vqai_maxindirsz); if (error) goto fail; } - vq->vq_ring_size = round_page(vring_size(size, align)); - vq->vq_ring_mem = contigmalloc(vq->vq_ring_size, M_DEVBUF, - M_NOWAIT | M_ZERO, 0, highaddr, PAGE_SIZE, 0); - if (vq->vq_ring_mem == NULL) { - device_printf(dev, - "cannot allocate memory for virtqueue ring\n"); - error = ENOMEM; + error = bus_dmamem_alloc(vq->vq_ring_dmat, &vq->vq_ring_mem, + BUS_DMA_NOWAIT | BUS_DMA_ZERO | BUS_DMA_COHERENT, + &vq->vq_ring_mapp); + if (error) { + device_printf(dev, "bus_dmamem_alloc failed\n"); + goto fail; + } + + error = bus_dmamap_load(vq->vq_ring_dmat, vq->vq_ring_mapp, + vq->vq_ring_mem, vq->vq_ring_size, virtqueue_ring_load_callback, + vq, BUS_DMA_NOWAIT); + if (error) { + device_printf(dev, "vq->vq_ring_mapp load failed\n"); goto fail; } @@ -227,12 +291,29 @@ fail: return (error); } +static void +virtqueue_indirect_load_callback(void *arg, bus_dma_segment_t *segs, + int nsegs, int error) +{ + struct vq_desc_extra *dxp; + + if (error != 0) + return; + + KASSERT(nsegs == 1, ("%s: %d segments returned!", __func__, nsegs)); + + dxp = (struct vq_desc_extra *)arg; + dxp->indirect_paddr = segs[0].ds_addr; +} + static int virtqueue_init_indirect(struct virtqueue *vq, int indirect_size) { device_t dev; struct vq_desc_extra *dxp; int i, size; + int error; + int align; dev = vq->vq_dev; @@ -254,16 +335,61 @@ virtqueue_init_indirect(struct virtqueue *vq, int indirect_size) vq->vq_indirect_mem_size = size; vq->vq_flags |= VIRTQUEUE_FLAG_INDIRECT; + mtx_init(&vq->vq_indirect_mtx, device_get_nameunit(dev), + "VirtIO Indirect Queue Lock", MTX_DEF); + + align = size; + error = bus_dma_tag_create( + bus_get_dma_tag(dev), /* parent */ + align, /* alignment */ + 0, /* boundary */ + BUS_SPACE_MAXADDR, /* lowaddr */ + BUS_SPACE_MAXADDR, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + size, /* max request size */ + 1, /* max # segments */ + size, /* maxsegsize */ + BUS_DMA_COHERENT, /* flags */ + busdma_lock_mutex, /* lockfunc */ + &vq->vq_indirect_mtx, /* lockarg */ + &vq->vq_indirect_dmat); + if (error) { + device_printf(dev, "cannot create indirect bus_dma_tag\n"); + return (error); + } + +#ifdef __powerpc__ + /* + * Virtio uses physical addresses rather than bus addresses, so we + * need to ask busdma to skip the iommu physical->bus mapping. At + * present, this is only a thing on the powerpc architectures. + */ + bus_dma_tag_set_iommu(vq->vq_indirect_dmat, NULL, NULL); +#endif + for (i = 0; i < vq->vq_nentries; i++) { dxp = &vq->vq_descx[i]; - dxp->indirect = malloc(size, M_DEVBUF, M_NOWAIT); - if (dxp->indirect == NULL) { - device_printf(dev, "cannot allocate indirect list\n"); - return (ENOMEM); + error = bus_dmamem_alloc(vq->vq_indirect_dmat, + (void **)&dxp->indirect, + BUS_DMA_NOWAIT | BUS_DMA_ZERO | BUS_DMA_COHERENT, + &dxp->mapp); + if (error) { + panic("dxp->mapp alloc failed\n"); + return (error); + } + + error = bus_dmamap_load(vq->vq_indirect_dmat, dxp->mapp, + dxp->indirect, size, virtqueue_indirect_load_callback, dxp, + BUS_DMA_NOWAIT); + if (error) { + panic("dxp->mapp load failed\n"); + bus_dmamem_free(vq->vq_indirect_dmat, dxp->indirect, + dxp->mapp); + dxp->indirect = NULL; + return (error); } - dxp->indirect_paddr = vtophys(dxp->indirect); virtqueue_init_indirect_list(vq, dxp->indirect); } @@ -282,7 +408,8 @@ virtqueue_free_indirect(struct virtqueue *vq) if (dxp->indirect == NULL) break; - free(dxp->indirect, M_DEVBUF); + bus_dmamap_unload(vq->vq_indirect_dmat, dxp->mapp); + bus_dmamem_free(vq->vq_indirect_dmat, dxp->indirect, dxp->mapp); dxp->indirect = NULL; dxp->indirect_paddr = 0; } @@ -360,9 +487,14 @@ virtqueue_free(struct virtqueue *vq) virtqueue_free_indirect(vq); if (vq->vq_ring_mem != NULL) { - free(vq->vq_ring_mem, M_DEVBUF); + bus_dmamap_unload(vq->vq_ring_dmat, vq->vq_ring_mapp); + bus_dmamem_free(vq->vq_ring_dmat, vq->vq_ring_mem, + vq->vq_ring_mapp); vq->vq_ring_size = 0; - vq->vq_ring_mem = NULL; + } + + if (vq->vq_ring_dmat != NULL) { + bus_dma_tag_destroy(vq->vq_ring_dmat); } free(vq, M_DEVBUF); @@ -371,29 +503,25 @@ virtqueue_free(struct virtqueue *vq) vm_paddr_t virtqueue_paddr(struct virtqueue *vq) { - - return (vtophys(vq->vq_ring_mem)); + return (vq->vq_ring_paddr); } vm_paddr_t virtqueue_desc_paddr(struct virtqueue *vq) { - - return (vtophys(vq->vq_ring.desc)); + return (vq->vq_ring.desc_paddr); } vm_paddr_t virtqueue_avail_paddr(struct virtqueue *vq) { - - return (vtophys(vq->vq_ring.avail)); + return (vq->vq_ring.avail_paddr); } vm_paddr_t virtqueue_used_paddr(struct virtqueue *vq) { - - return (vtophys(vq->vq_ring.used)); + return (vq->vq_ring.used_paddr); } uint16_t @@ -434,9 +562,9 @@ virtqueue_full(struct virtqueue *vq) void virtqueue_notify(struct virtqueue *vq) { - /* Ensure updated avail->idx is visible to host. */ - mb(); + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_PREWRITE); if (vq_ring_must_notify_host(vq)) vq_ring_notify_host(vq); @@ -448,6 +576,9 @@ virtqueue_nused(struct virtqueue *vq) { uint16_t used_idx, nused; + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_POSTREAD); + used_idx = vq_htog16(vq, vq->vq_ring.used->idx); nused = (uint16_t)(used_idx - vq->vq_used_cons_idx); @@ -459,6 +590,8 @@ virtqueue_nused(struct virtqueue *vq) int virtqueue_intr_filter(struct virtqueue *vq) { + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_POSTREAD); if (vq->vq_used_cons_idx == vq_htog16(vq, vq->vq_ring.used->idx)) return (0); @@ -487,6 +620,9 @@ virtqueue_postpone_intr(struct virtqueue *vq, vq_postpone_t hint) { uint16_t ndesc, avail_idx; + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_POSTREAD); + avail_idx = vq_htog16(vq, vq->vq_ring.avail->idx); ndesc = (uint16_t)(avail_idx - vq->vq_used_cons_idx); @@ -518,6 +654,9 @@ virtqueue_disable_intr(struct virtqueue *vq) } vq->vq_ring.avail->flags |= vq_gtoh16(vq, VRING_AVAIL_F_NO_INTERRUPT); + + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_PREWRITE); } int @@ -561,6 +700,9 @@ virtqueue_enqueue(struct virtqueue *vq, void *cookie, struct sglist *sg, idx = vq_ring_enqueue_segments(vq, vq->vq_ring.desc, head_idx, sg, readable, writable); + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_PREWRITE); + vq->vq_desc_head_idx = idx; vq->vq_free_cnt -= needed; if (vq->vq_free_cnt == 0) @@ -580,6 +722,9 @@ virtqueue_dequeue(struct virtqueue *vq, uint32_t *len) void *cookie; uint16_t used_idx, desc_idx; + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_POSTREAD); + if (vq->vq_used_cons_idx == vq_htog16(vq, atomic_load_16(&vq->vq_ring.used->idx))) return (NULL); @@ -666,11 +811,14 @@ vq_ring_init(struct virtqueue *vq) size = vq->vq_nentries; vr = &vq->vq_ring; - vring_init(vr, size, ring_mem, vq->vq_alignment); + vring_init(vr, size, ring_mem, vq->vq_ring_paddr, vq->vq_alignment); for (i = 0; i < size - 1; i++) vr->desc[i].next = vq_gtoh16(vq, i + 1); vr->desc[i].next = vq_gtoh16(vq, VQ_RING_DESC_CHAIN_END); + + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_PREWRITE); } static void @@ -694,6 +842,9 @@ vq_ring_update_avail(struct virtqueue *vq, uint16_t desc_idx) /* Keep pending count until virtqueue_notify(). */ vq->vq_queued_cnt++; + + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_PREWRITE); } static uint16_t @@ -777,6 +928,10 @@ vq_ring_enqueue_indirect(struct virtqueue *vq, void *cookie, vq_ring_enqueue_segments(vq, dxp->indirect, 0, sg, readable, writable); + bus_dmamap_sync(vq->vq_indirect_dmat, dxp->mapp, BUS_DMASYNC_PREWRITE); + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_PREWRITE); + vq->vq_desc_head_idx = vq_htog16(vq, dp->next); vq->vq_free_cnt--; if (vq->vq_free_cnt == 0) @@ -803,7 +958,8 @@ vq_ring_enable_interrupt(struct virtqueue *vq, uint16_t ndesc) vq_gtoh16(vq, ~VRING_AVAIL_F_NO_INTERRUPT); } - mb(); + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_PREWRITE); /* * Enough items may have already been consumed to meet our threshold @@ -821,6 +977,9 @@ vq_ring_must_notify_host(struct virtqueue *vq) { uint16_t new_idx, prev_idx, event_idx, flags; + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_POSTREAD); + if (vq->vq_flags & VIRTQUEUE_FLAG_EVENT_IDX) { new_idx = vq_htog16(vq, vq->vq_ring.avail->idx); prev_idx = new_idx - vq->vq_queued_cnt; @@ -876,4 +1035,7 @@ vq_ring_free_chain(struct virtqueue *vq, uint16_t desc_idx) */ dp->next = vq_gtoh16(vq, vq->vq_desc_head_idx); vq->vq_desc_head_idx = desc_idx; + + bus_dmamap_sync(vq->vq_ring_dmat, vq->vq_ring_mapp, + BUS_DMASYNC_PREWRITE); } From nobody Tue Mar 3 17:37:58 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQNLG3dbnz6TPdl for ; Tue, 03 Mar 2026 17:37: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQNLG2DYVz3F5Z for ; Tue, 03 Mar 2026 17:37:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772559478; 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; bh=qJhQrLFvOWL/DsaaSnp0giLW/qagimFc1smY4m2DxZk=; b=In6IKvOjJdFSgloS3c5KNa9ZgQ43AviSL25pGIKxO0uphmq4NXYOYJimk6jJHXkHe7ofs/ CuZK99o5tnKXdbU0E8JSVOTPabf4jkMocBkMNWRHhXq0l3E4jPm2X17WhVcgBiiubdm0gS Hk/lZI+ue0v4wpvXlFs3SoIjro6S1/3KdMI3IyToiDIFBDxsJIxCbZRmCR/TrTv0BHXz7D JmQAUYmbyn7mvvNkEWp/V6/VHd1oRcU61ev2egvwakwGLnC1pwPr+og3q0VztZ+lePOxRB 4s5bWtdh20sw6lF4YfAuuVie24msTUh1FjllwnbIfWB2RXjy7mWAubD3vwbPYQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772559478; a=rsa-sha256; cv=none; b=kTjIrckiiqJwjnrsAd0a4Ofl2+0AxB/zjUoCKofNcZITXc7sm54zIFF+eL/ZVLiO84+tKJ phmzvufdk8YTv4qKgOg25hEF35Y47604I8G9CeGvmKgHnNnwEtzHOGen6VIWDeqK3LZvnR 6+L0x4oQojfAYvDckuvxQr9WX7sNDGZ/Tu2EnynGhfTMmVDqzSHCNf8GfWWO3QOlEK5gqy YJDVzM3ZSzN1gHE0Yme6nxkEdX7ofPBGBgwYoMoPjWphwJ2OD+90J6nVDgODLQbb+aBLTe HUtpkWul5SUEfwaVNJPHNiJ5sm441DYkecXzNoLWUmLjyJeZ1JXhWFlQmngM7A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772559478; 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; bh=qJhQrLFvOWL/DsaaSnp0giLW/qagimFc1smY4m2DxZk=; b=Kh8tij+Gs06EBFZYhjnQEOqROJcTGGgRRXDZa5G/58JRpFqt7gPcQC2o6qHbGTFpXfgE2+ glao7V6qZIIUmsEYs0tEUll1iqsDEgLhLcrN/8X1/0gFH+ky0vQzPzns1j/9IcaVs3Tk3/ hL8mkNGE+eegw9WIyhr43JQzxxifWgnw0YZyNUatugbUXbhP3QNJ410gjKy4iURdzwfHpl P3Ra1zjKn8BII4zcp9C1uXwgSXxpam6pnwLOyPrd89ECi/ik1Kx2LU6tM7s487X7D9eDOS yUhfU4A7oa/2I1DHusqkqk2x+pEiqOItMBeCYxvMO7pXF1kUxh6GO9U75gh/Kg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQNLG1bp1zFf for ; Tue, 03 Mar 2026 17:37:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 409df by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 17:37:58 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Sarah Walker From: Andrew Turner Subject: git: c8c37141a661 - main - virtio_blk: Use bus_dma for command/ack buffer allocations List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: c8c37141a661cc9a6a51e43599d1afc8a3f0ef46 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 17:37:58 +0000 Message-Id: <69a71c76.409df.5a93939b@gitrepo.freebsd.org> The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=c8c37141a661cc9a6a51e43599d1afc8a3f0ef46 commit c8c37141a661cc9a6a51e43599d1afc8a3f0ef46 Author: Sarah Walker AuthorDate: 2026-03-03 16:27:38 +0000 Commit: Andrew Turner CommitDate: 2026-03-03 16:29:15 +0000 virtio_blk: Use bus_dma for command/ack buffer allocations While the majority of virtio platforms will be fully coherent, some may require cache maintenance or other specific device memory handling (eg for secure partitioning). Using bus_dma allows for these usecases. The virtio buffers are marked as coherent; this should ensure that sync calls are no-ops in the common cases. Reviewed by: andrew, br Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D54960 --- sys/dev/virtio/block/virtio_blk.c | 221 +++++++++++++++++++++++++++++++------- 1 file changed, 182 insertions(+), 39 deletions(-) diff --git a/sys/dev/virtio/block/virtio_blk.c b/sys/dev/virtio/block/virtio_blk.c index 5eb681128e9c..4cedb9b45a0e 100644 --- a/sys/dev/virtio/block/virtio_blk.c +++ b/sys/dev/virtio/block/virtio_blk.c @@ -59,10 +59,15 @@ struct vtblk_request { struct vtblk_softc *vbr_sc; bus_dmamap_t vbr_mapp; + struct virtio_blk_outhdr *vbr_hdr; + vm_paddr_t vbr_hdr_paddr; + bus_dmamap_t vbr_hdr_mapp; + uint8_t *vbr_ack; + vm_paddr_t vbr_ack_paddr; + bus_dmamap_t vbr_ack_mapp; + /* Fields after this point are zeroed for each request. */ - struct virtio_blk_outhdr vbr_hdr; struct bio *vbr_bp; - uint8_t vbr_ack; uint8_t vbr_requeue_on_error; uint8_t vbr_busdma_wait; int vbr_error; @@ -78,6 +83,8 @@ enum vtblk_cache_mode { struct vtblk_softc { device_t vtblk_dev; struct mtx vtblk_mtx; + struct mtx vtblk_hdr_mtx; + struct mtx vtblk_ack_mtx; uint64_t vtblk_features; uint32_t vtblk_flags; #define VTBLK_FLAG_INDIRECT 0x0001 @@ -91,6 +98,8 @@ struct vtblk_softc { struct virtqueue *vtblk_vq; struct sglist *vtblk_sglist; bus_dma_tag_t vtblk_dmat; + bus_dma_tag_t vtblk_hdr_dmat; + bus_dma_tag_t vtblk_ack_dmat; struct disk *vtblk_disk; struct bio_queue_head vtblk_bioq; @@ -385,7 +394,7 @@ vtblk_attach(device_t dev) maxphys, /* max request size */ sc->vtblk_max_nsegs - VTBLK_MIN_SEGMENTS, /* max # segments */ maxphys, /* maxsegsize */ - 0, /* flags */ + BUS_DMA_COHERENT, /* flags */ busdma_lock_mutex, /* lockfunc */ &sc->vtblk_mtx, /* lockarg */ &sc->vtblk_dmat); @@ -394,6 +403,46 @@ vtblk_attach(device_t dev) goto fail; } + error = bus_dma_tag_create( + bus_get_dma_tag(dev), /* parent */ + (sc->vtblk_flags & VTBLK_FLAG_BUSDMA_ALIGN) ? PAGE_SIZE : + sizeof(struct virtio_blk_outhdr), /* alignment */ + 0, /* boundary */ + BUS_SPACE_MAXADDR, /* lowaddr */ + BUS_SPACE_MAXADDR, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + sizeof(struct virtio_blk_outhdr), /* max request size */ + 1, /* max # segments */ + sizeof(struct virtio_blk_outhdr), /* maxsegsize */ + BUS_DMA_COHERENT, /* flags */ + busdma_lock_mutex, /* lockfunc */ + &sc->vtblk_hdr_mtx, /* lockarg */ + &sc->vtblk_hdr_dmat); + if (error) { + device_printf(dev, "cannot create hdr bus dma tag\n"); + goto fail; + } + + error = bus_dma_tag_create( + bus_get_dma_tag(dev), /* parent */ + (sc->vtblk_flags & VTBLK_FLAG_BUSDMA_ALIGN) ? PAGE_SIZE : + sizeof(uint8_t), /* alignment */ + 0, /* boundary */ + BUS_SPACE_MAXADDR, /* lowaddr */ + BUS_SPACE_MAXADDR, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + sizeof(uint8_t), /* max request size */ + 1, /* max # segments */ + sizeof(uint8_t), /* maxsegsize */ + BUS_DMA_COHERENT, /* flags */ + busdma_lock_mutex, /* lockfunc */ + &sc->vtblk_ack_mtx, /* lockarg */ + &sc->vtblk_ack_dmat); + if (error) { + device_printf(dev, "cannot create ack bus dma tag\n"); + goto fail; + } + #ifdef __powerpc__ /* * Virtio uses physical addresses rather than bus addresses, so we @@ -401,6 +450,8 @@ vtblk_attach(device_t dev) * present, this is only a thing on the powerpc architectures. */ bus_dma_tag_set_iommu(sc->vtblk_dmat, NULL, NULL); + bus_dma_tag_set_iommu(sc->vtblk_hdr_dmat, NULL, NULL); + bus_dma_tag_set_iommu(sc->vtblk_ack_dmat, NULL, NULL); #endif error = vtblk_alloc_virtqueue(sc); @@ -452,6 +503,16 @@ vtblk_detach(device_t dev) sc->vtblk_disk = NULL; } + if (sc->vtblk_ack_dmat != NULL) { + bus_dma_tag_destroy(sc->vtblk_ack_dmat); + sc->vtblk_ack_dmat = NULL; + } + + if (sc->vtblk_hdr_dmat != NULL) { + bus_dma_tag_destroy(sc->vtblk_hdr_dmat); + sc->vtblk_hdr_dmat = NULL; + } + if (sc->vtblk_dmat != NULL) { bus_dma_tag_destroy(sc->vtblk_dmat); sc->vtblk_dmat = NULL; @@ -839,6 +900,36 @@ vtblk_create_disk(struct vtblk_softc *sc) disk_create(dp, DISK_VERSION); } +static void +vtblk_ack_load_callback(void *arg, bus_dma_segment_t *segs, int nsegs, + int error) +{ + struct vtblk_request *req; + + if (error != 0) + return; + + KASSERT(nsegs == 1, ("%s: %d segments returned!", __func__, nsegs)); + + req = (struct vtblk_request *)arg; + req->vbr_ack_paddr = segs[0].ds_addr; +} + +static void +vtblk_hdr_load_callback(void *arg, bus_dma_segment_t *segs, int nsegs, + int error) +{ + struct vtblk_request *req; + + if (error != 0) + return; + + KASSERT(nsegs == 1, ("%s: %d segments returned!", __func__, nsegs)); + + req = (struct vtblk_request *)arg; + req->vbr_hdr_paddr = segs[0].ds_addr; +} + static int vtblk_request_prealloc(struct vtblk_softc *sc) { @@ -861,19 +952,51 @@ vtblk_request_prealloc(struct vtblk_softc *sc) return (ENOMEM); req->vbr_sc = sc; - if (bus_dmamap_create(sc->vtblk_dmat, 0, &req->vbr_mapp)) { - free(req, M_DEVBUF); - return (ENOMEM); - } - MPASS(sglist_count(&req->vbr_hdr, sizeof(req->vbr_hdr)) == 1); - MPASS(sglist_count(&req->vbr_ack, sizeof(req->vbr_ack)) == 1); + if (bus_dmamap_create(sc->vtblk_dmat, 0, &req->vbr_mapp)) + goto error_free; + + if (bus_dmamem_alloc(sc->vtblk_hdr_dmat, (void **)&req->vbr_hdr, + BUS_DMA_NOWAIT | BUS_DMA_ZERO | BUS_DMA_COHERENT, + &req->vbr_hdr_mapp)) + goto error_destroy; + + if (bus_dmamem_alloc(sc->vtblk_ack_dmat, (void **)&req->vbr_ack, + BUS_DMA_NOWAIT | BUS_DMA_ZERO | BUS_DMA_COHERENT, + &req->vbr_ack_mapp)) + goto error_hdr_free; + + MPASS(sglist_count(req->vbr_hdr, sizeof(*req->vbr_hdr)) == 1); + MPASS(sglist_count(req->vbr_ack, sizeof(*req->vbr_ack)) == 1); + + if (bus_dmamap_load(sc->vtblk_hdr_dmat, req->vbr_hdr_mapp, + req->vbr_hdr, sizeof(struct virtio_blk_outhdr), + vtblk_hdr_load_callback, req, BUS_DMA_NOWAIT)) + goto error_ack_free; + + if (bus_dmamap_load(sc->vtblk_ack_dmat, req->vbr_ack_mapp, + req->vbr_ack, sizeof(uint8_t), vtblk_ack_load_callback, + req, BUS_DMA_NOWAIT)) + goto error_hdr_unload; sc->vtblk_request_count++; vtblk_request_enqueue(sc, req); } return (0); + +error_hdr_unload: + bus_dmamap_unload(sc->vtblk_hdr_dmat, req->vbr_hdr_mapp); +error_ack_free: + bus_dmamem_free(sc->vtblk_ack_dmat, req->vbr_ack, req->vbr_ack_mapp); +error_hdr_free: + bus_dmamem_free(sc->vtblk_hdr_dmat, req->vbr_hdr, req->vbr_hdr_mapp); +error_destroy: + bus_dmamap_destroy(sc->vtblk_dmat, req->vbr_mapp); +error_free: + free(req, M_DEVBUF); + + return (ENOMEM); } static void @@ -885,8 +1008,13 @@ vtblk_request_free(struct vtblk_softc *sc) while ((req = vtblk_request_dequeue(sc)) != NULL) { sc->vtblk_request_count--; + bus_dmamap_unload(sc->vtblk_ack_dmat, req->vbr_ack_mapp); + bus_dmamem_free(sc->vtblk_ack_dmat, req->vbr_ack, + req->vbr_ack_mapp); + bus_dmamap_unload(sc->vtblk_hdr_dmat, req->vbr_hdr_mapp); + bus_dmamem_free(sc->vtblk_hdr_dmat, req->vbr_hdr, + req->vbr_hdr_mapp); bus_dmamap_destroy(sc->vtblk_dmat, req->vbr_mapp); - free(req, M_DEVBUF); } KASSERT(sc->vtblk_request_count == 0, @@ -901,8 +1029,10 @@ vtblk_request_dequeue(struct vtblk_softc *sc) req = TAILQ_FIRST(&sc->vtblk_req_free); if (req != NULL) { TAILQ_REMOVE(&sc->vtblk_req_free, req, vbr_link); - bzero(&req->vbr_hdr, sizeof(struct vtblk_request) - - offsetof(struct vtblk_request, vbr_hdr)); + bzero(req->vbr_hdr, sizeof(struct virtio_blk_outhdr)); + *req->vbr_ack = 0; + bzero(&req->vbr_bp, sizeof(struct vtblk_request) - + offsetof(struct vtblk_request, vbr_bp)); } return (req); @@ -965,32 +1095,35 @@ vtblk_request_bio(struct vtblk_softc *sc) bp = bioq_takefirst(bioq); req->vbr_bp = bp; - req->vbr_ack = -1; - req->vbr_hdr.ioprio = vtblk_gtoh32(sc, 1); + *req->vbr_ack = -1; + req->vbr_hdr->ioprio = vtblk_gtoh32(sc, 1); switch (bp->bio_cmd) { case BIO_FLUSH: - req->vbr_hdr.type = vtblk_gtoh32(sc, VIRTIO_BLK_T_FLUSH); - req->vbr_hdr.sector = 0; + req->vbr_hdr->type = vtblk_gtoh32(sc, VIRTIO_BLK_T_FLUSH); + req->vbr_hdr->sector = 0; break; case BIO_READ: - req->vbr_hdr.type = vtblk_gtoh32(sc, VIRTIO_BLK_T_IN); - req->vbr_hdr.sector = vtblk_gtoh64(sc, bp->bio_offset / VTBLK_BSIZE); + req->vbr_hdr->type = vtblk_gtoh32(sc, VIRTIO_BLK_T_IN); + req->vbr_hdr->sector = vtblk_gtoh64(sc, bp->bio_offset / + VTBLK_BSIZE); break; case BIO_WRITE: - req->vbr_hdr.type = vtblk_gtoh32(sc, VIRTIO_BLK_T_OUT); - req->vbr_hdr.sector = vtblk_gtoh64(sc, bp->bio_offset / VTBLK_BSIZE); + req->vbr_hdr->type = vtblk_gtoh32(sc, VIRTIO_BLK_T_OUT); + req->vbr_hdr->sector = vtblk_gtoh64(sc, bp->bio_offset / + VTBLK_BSIZE); break; case BIO_DELETE: - req->vbr_hdr.type = vtblk_gtoh32(sc, VIRTIO_BLK_T_DISCARD); - req->vbr_hdr.sector = vtblk_gtoh64(sc, bp->bio_offset / VTBLK_BSIZE); + req->vbr_hdr->type = vtblk_gtoh32(sc, VIRTIO_BLK_T_DISCARD); + req->vbr_hdr->sector = vtblk_gtoh64(sc, bp->bio_offset / + VTBLK_BSIZE); break; default: panic("%s: bio with unhandled cmd: %d", __func__, bp->bio_cmd); } if (bp->bio_flags & BIO_ORDERED) - req->vbr_hdr.type |= vtblk_gtoh32(sc, VIRTIO_BLK_T_BARRIER); + req->vbr_hdr->type |= vtblk_gtoh32(sc, VIRTIO_BLK_T_BARRIER); return (req); } @@ -1072,13 +1205,17 @@ vtblk_request_execute_cb(void * callback_arg, bus_dma_segment_t * segs, goto out; } ordered = 1; - req->vbr_hdr.type &= vtblk_gtoh32(sc, + req->vbr_hdr->type &= vtblk_gtoh32(sc, ~VIRTIO_BLK_T_BARRIER); } } + bus_dmamap_sync(sc->vtblk_hdr_dmat, req->vbr_hdr_mapp, + BUS_DMASYNC_PREWRITE); + sglist_reset(sg); - sglist_append(sg, &req->vbr_hdr, sizeof(struct virtio_blk_outhdr)); + sglist_append_phys(sg, req->vbr_hdr_paddr, + sizeof(struct virtio_blk_outhdr)); if (bp->bio_cmd == BIO_READ || bp->bio_cmd == BIO_WRITE) { /* @@ -1125,8 +1262,11 @@ vtblk_request_execute_cb(void * callback_arg, bus_dma_segment_t * segs, } } + bus_dmamap_sync(sc->vtblk_ack_dmat, req->vbr_ack_mapp, + BUS_DMASYNC_PREREAD); + writable++; - sglist_append(sg, &req->vbr_ack, sizeof(uint8_t)); + sglist_append_phys(sg, req->vbr_ack_paddr, sizeof(uint8_t)); readable = sg->sg_nseg - writable; if (req->vbr_mapp != NULL) { @@ -1168,7 +1308,10 @@ vtblk_request_error(struct vtblk_request *req) { int error; - switch (req->vbr_ack) { + bus_dmamap_sync(req->vbr_sc->vtblk_ack_dmat, req->vbr_ack_mapp, + BUS_DMASYNC_POSTREAD); + + switch (*req->vbr_ack) { case VIRTIO_BLK_S_OK: error = 0; break; @@ -1409,10 +1552,10 @@ vtblk_ident(struct vtblk_softc *sc) if (req == NULL) return; - req->vbr_ack = -1; - req->vbr_hdr.type = vtblk_gtoh32(sc, VIRTIO_BLK_T_GET_ID); - req->vbr_hdr.ioprio = vtblk_gtoh32(sc, 1); - req->vbr_hdr.sector = 0; + *req->vbr_ack = -1; + req->vbr_hdr->type = vtblk_gtoh32(sc, VIRTIO_BLK_T_GET_ID); + req->vbr_hdr->ioprio = vtblk_gtoh32(sc, 1); + req->vbr_hdr->sector = 0; req->vbr_bp = &buf; g_reset_bio(&buf); @@ -1547,10 +1690,10 @@ vtblk_dump_write(struct vtblk_softc *sc, void *virtual, off_t offset, req = &sc->vtblk_dump_request; req->vbr_sc = sc; - req->vbr_ack = -1; - req->vbr_hdr.type = vtblk_gtoh32(sc, VIRTIO_BLK_T_OUT); - req->vbr_hdr.ioprio = vtblk_gtoh32(sc, 1); - req->vbr_hdr.sector = vtblk_gtoh64(sc, offset / VTBLK_BSIZE); + *req->vbr_ack = -1; + req->vbr_hdr->type = vtblk_gtoh32(sc, VIRTIO_BLK_T_OUT); + req->vbr_hdr->ioprio = vtblk_gtoh32(sc, 1); + req->vbr_hdr->sector = vtblk_gtoh64(sc, offset / VTBLK_BSIZE); req->vbr_bp = &buf; g_reset_bio(&buf); @@ -1570,10 +1713,10 @@ vtblk_dump_flush(struct vtblk_softc *sc) req = &sc->vtblk_dump_request; req->vbr_sc = sc; - req->vbr_ack = -1; - req->vbr_hdr.type = vtblk_gtoh32(sc, VIRTIO_BLK_T_FLUSH); - req->vbr_hdr.ioprio = vtblk_gtoh32(sc, 1); - req->vbr_hdr.sector = 0; + *req->vbr_ack = -1; + req->vbr_hdr->type = vtblk_gtoh32(sc, VIRTIO_BLK_T_FLUSH); + req->vbr_hdr->ioprio = vtblk_gtoh32(sc, 1); + req->vbr_hdr->sector = 0; req->vbr_bp = &buf; g_reset_bio(&buf); From nobody Tue Mar 3 17:59:59 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQNr01qrWz6TR43 for ; Tue, 03 Mar 2026 18:00:16 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg1-x532.google.com (mail-pg1-x532.google.com [IPv6:2607:f8b0:4864:20::532]) (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 4fQNqz519Gz3J1M for ; Tue, 03 Mar 2026 18:00:15 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pg1-x532.google.com with SMTP id 41be03b00d2f7-b6ce6d1d3dcso1998597a12.3 for ; Tue, 03 Mar 2026 10:00:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1772560813; x=1773165613; darn=freebsd.org; h=to:references:message-id:cc:date:in-reply-to:from:subject :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=lCbKQM42v7TFsWMPcFYPr6Q/hgaMM/Ih0JJvHMyC77U=; b=Z2ihYzqDshgJ0FSLKzU8o6huIeXhGe/R4xYzQn1kZszrsjHRWGBjT/6IBr/eocIRnT VfrunqkgMTQb9brh44CB/85BzavYV/zvblT60zNtXPVHB/+Sid7GnT0PmMUs7jPQpvfJ xqxBaTxbyMbHqRMRsbO3sSecIgB6PZ1sgm3FPseuL9jfG+XLrNDo/wU8Wv6KB9PE/hSI aDqEumR82l57YOVsE6bd66aABnXiWvRLT9GoAuRZ158UgzHiLOaF86mif9bfkmRT9XVY Y+CQaPz1qcwrVWFLcabVPIR5FPVEjbKoq9riKQ172GG5ukzyjoHbyVpRpsA+GEyXYSvU 3BZw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772560813; x=1773165613; h=to:references:message-id:cc:date:in-reply-to:from:subject :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=lCbKQM42v7TFsWMPcFYPr6Q/hgaMM/Ih0JJvHMyC77U=; b=ksIf7h2MWoxiZE8ButiL+bLs0aInFGNYNpyDMT/kIDrPfPL8TTNnvQrU/Lbxl8xZlC mR0DgesRbYqRkthzC9Pw7taKRLfLgAADvCkfaOWfyVEb7W/BJ6OfVUVdprmRT98QmIQt a5tC7Z7ASgLk3YA6y0N/cWOgvlwCNWI6cTRqA5TDUV3v94Ty3TRKQZX2MAASmzFOvr5T JZXScLcrS95nqvAbNqTLXTOFwbyyJn4C6IGzwBiFjHjRoQQPAX44HSMrXpdK/+Wz0+7A cPlHNBnj0kpoL948LuvifnurbbrPyUgx0blnQqTIQ9j21zgaYZOXWlMjzRz3dWV3glfl CrNQ== X-Forwarded-Encrypted: i=1; AJvYcCXVMnKr7odEVN4DGWklcvN/kqv81c5oHONnJjdzRbQkJnLgXUPhKTxL/XRSK9ZBmO16n2xYjHHRhL1+DRcWvNt90R0l/A==@freebsd.org X-Gm-Message-State: AOJu0Yzazt80r5GdjaYMntNosYNCVVOqNXVkkfdUN/aT3FF3lm6RqKRc ZJsWmzM6BIVg2GPPnT0Op4EDxMFN/PaqpGHTEgDUl4yJ8khiD38kXnmV X-Gm-Gg: ATEYQzwGKIrMzI0f1gEKiRNE/pHq0FavQgkIppCoSqn4eoinLyaXQZzGk7G/MmFUF7x sPRegjuoGAs0fbcCLQ69zlA/IpEoR/U+hc/vbXNzN2FVPKPtMbrlOyJpohxLuqQTJkfdXnmGFI9 //S7rNO2XJGwdw2y0sdh64/LecmmKTYkRkV81Lr3Dls41j4wXdzRPi/ZorXrdClh+r+xWJWyOEz PAvzH7kNyrVOMF8prZ8/DwYLJKTELMRYQCQhZqvzDcEJcTZNw1Cc9OnLCMVFnnA46WU7Z2SzjDJ 3HNfZtnKGH3DukvoHIOKKuLfRN0vgKNRPP7jHFQQkQsdEYegOVkAFR2DZ9P8g5VBGquFQqfyctT ojc13IKjm2bRHsfb/AcaE/MuMSnRxaTFIizLsaEv4eor7YNX9VfneLlSTtO63fxBodw5TopNCb9 pz2bAlAjVx+FW3XpY3ht4EFZLurOL5dI+7o8zgnu7jODubcE91pkKq X-Received: by 2002:a17:903:390f:b0:2ae:478f:2ec with SMTP id d9443c01a7336-2ae478f12cfmr107569995ad.29.1772560812351; Tue, 03 Mar 2026 10:00:12 -0800 (PST) Received: from smtpclient.apple ([145.79.197.104]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2ae5e1699c9sm30763975ad.10.2026.03.03.10.00.11 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 03 Mar 2026 10:00:11 -0800 (PST) Content-Type: multipart/signed; boundary="Apple-Mail=_1719D464-A3AF-4CFA-B3EB-46B72A91B06A"; protocol="application/pgp-signature"; micalg=pgp-sha256 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3826.700.81.1.3\)) Subject: Re: git: bc9229035c5f - main - Allow programs run under this program to have arguments. From: "Enji Cooper (yaneurabeya)" In-Reply-To: <69a7162e.3e996.108a155f@gitrepo.freebsd.org> Date: Tue, 3 Mar 2026 09:59:59 -0800 Cc: "src-committers@freebsd.org" , "dev-commits-src-all@freebsd.org" , "dev-commits-src-main@freebsd.org" Message-Id: References: <69a7162e.3e996.108a155f@gitrepo.freebsd.org> To: "George V. Neville-Neil" X-Mailer: Apple Mail (2.3826.700.81.1.3) X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated 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-Queue-Id: 4fQNqz519Gz3J1M X-Spamd-Bar: ---- --Apple-Mail=_1719D464-A3AF-4CFA-B3EB-46B72A91B06A Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 3, 2026, at 9:11=E2=80=AFAM, George V. Neville-Neil = wrote: >=20 > The branch main has been updated by gnn: >=20 > URL: = https://cgit.FreeBSD.org/src/commit/?id=3Dbc9229035c5f46674cf06b48d66e9f03= 9b3a9875 >=20 > commit bc9229035c5f46674cf06b48d66e9f039b3a9875 > Author: George V. Neville-Neil > AuthorDate: 2026-03-03 17:10:26 +0000 > Commit: George V. Neville-Neil > CommitDate: 2026-03-03 17:10:42 +0000 >=20 > Allow programs run under this program to have arguments. > --- > tools/test/hwpmc/pmctest.py | 14 ++++++++------ > 1 file changed, 8 insertions(+), 6 deletions(-) >=20 > diff --git a/tools/test/hwpmc/pmctest.py b/tools/test/hwpmc/pmctest.py > index ba20306f1d68..1c113c256e32 100755 > --- a/tools/test/hwpmc/pmctest.py > +++ b/tools/test/hwpmc/pmctest.py > @@ -27,6 +27,7 @@ import argparse > import tempfile > from pathlib import Path > import os > +import shlex >=20 > def gather_counters(): > """Run program and return output as array of lines.""" > @@ -58,7 +59,9 @@ def main(): > print("Choose one of --count OR --sample.") > sys.exit() >=20 > - program =3D Path(args.program).name > + # Split program and arguments properly > + program_parts =3D shlex.split(args.program) > + program =3D Path(program_parts[0]).name >=20 > if args.count =3D=3D True: > tmpdir =3D tempfile.mkdtemp(prefix=3Dprogram + "-", = suffix=3D"-counting-pmc") > @@ -73,8 +76,7 @@ def main(): > continue > if args.count =3D=3D True: > with open(tmpdir + "/" + program + "-" + counter + ".txt", = 'w') as file: > - p =3D subprocess.Popen(["pmcstat", > - "-p", counter, args.program], > + p =3D subprocess.Popen(["pmcstat", "-p", counter] + = program_parts, > text=3DTrue, stderr=3Dfile, = stdout=3Dfile) Hi George, The idiom that ruff recommends here is to use the unpacking = operator. For example, instead of doing: a =3D [] b =3D [] + a They recommend using: a =3D [] b =3D [*a] More about the rationale for this suggestion is discussed here: = https://docs.astral.sh/ruff/rules/collection-literal-concatenation/ . -Enji= --Apple-Mail=_1719D464-A3AF-4CFA-B3EB-46B72A91B06A Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEkHfexGRJ3gYRdA2gGpE5DjPsNJgFAmmnIZ8ACgkQGpE5DjPs NJjbXw//YybrvdsnUnxQDX7ec9+agmAmf/DtT7Zbao2pbYeQ3Z+DbfHUENlcrbz7 SXNxfpHlheq8UxFWyhy8h5fiioUOHkOBct9WI+u3xJmxq/zjl68GgIeDWnQvKdV9 mo9hFWzejW4nYk8ZblPvp9aTOpNq8NXrTzEOvj976qNHsAC/uHNjUiZi0IZM07+j aNJ98PERwrDF1QYw47nqRUuwaUfoSeydLfDYHue6XiI7DkksZzagQPYYHLqesSbo GAZuOqFzRR4VtKGAnrAbf6jqDaF4j7mgWOLp4+oRu3e0VUvngl9T5AItOre50Pgz jHFEKKOuMbhCm0Nnm6hqsfNCF9qc0b/N50EOgva4e/e82OYDiHB+vm4wqUXxcXJB 72U7b9qs4t2BejgMUbm3HM2xekK0f25Ku1WYGG1XzZGQkGIDCYuBH+WSkXW7XFDI Cy6wMd5cUT6TG/CDtYDXE2mG6V/I+39M35R4UVfySZFq63qpzUsXAmGxU5Yz3Bx2 TJnSGFYGv49NVfAjT6BmzSTtb6gFRfAlcfJk7rzqErgIkrYDW2y/q+LjBo2PTjBR KGFGWfZGmygfdmRkF34ZsVtyVPtuYEUEF8QqRVapS3kpxTDlMcQzsKP8PLRTzZLu qvf+Rro/IxTnNGSFYu167b1IwsUjsgZj04+mi8g3LTULgSuXmig= =xZhW -----END PGP SIGNATURE----- --Apple-Mail=_1719D464-A3AF-4CFA-B3EB-46B72A91B06A-- From nobody Tue Mar 3 18:01:12 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs4257Xz6TQwc for ; Tue, 03 Mar 2026 18:01: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQNs41WhZz3JKC for ; Tue, 03 Mar 2026 18:01:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560872; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9xib/ORSMGN24X8XaOUowyVgraxQmPVsCbQRzuUqiew=; b=Zih3jK2tEVZEgXo+QQ3eOuiOr6YiOOwBSFZTHtBOI3DFZV4bMJXw4FZP8m57OEbmd/EZWy lNuyfkCOd5I21Dsrbv11/6iFBVrJZ5nqZQe0zuAh4/lXeO3hI6ihqPp/3FCEBYTeorUYJn 5uWDkmz/ay8G4lfMrhs9w/XhThDnfGTBPaEHe4yZNIYeMc09U94+JD0GQhWkfEInDOTMgc VN71c+yX5xiCGUzUHIgQstvt5hknjLccU3hvoVWN76XlAhK6W4B9TGLgFRX0wca/k3Tbwo 5WehU7yjNpaCQuslZUmAmzDlIyyTgN1euHKrR085DWrzYDvOYYX/O6Bm618OqQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772560872; a=rsa-sha256; cv=none; b=Zj7lxWBPUyLqWrTnyIsVYrFZ5i7SVQaqdcX0lCLDL2E8dH1tLxXjTY8BcAtHowibvs6g+W CkZmPRvxSTVxnNtjVVtdUE6d6MTuwFRaVLfGPYfM7Is0CxEQaFxZyOJLjBb8YHGxUxt8+F /kixd7bgfYU5zL6wWplo1cQ06IQCGIqpUYnwu+F4XNh3uKA5W1GoROIptGEoL37LCRzIro eTPar546V2KHDlxqCrCoyMfRVVODIQWEsIs7VI90N1eZg9fb/Q9aWLCpFhKzsheFTP41bP woBGFoMF7w0zNGYzpMnPujfm4GmkOyeYzH29ks2oTtHRqwFxCgi0htnNu64rTQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560872; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9xib/ORSMGN24X8XaOUowyVgraxQmPVsCbQRzuUqiew=; b=YE0XRecmoynp5IorVa3c7ltY8Z1KB+1jXPIf976YQEgyaX737v8Aw+o1izJR+c+Ufm5qhW lVS7u7sbvsEWRaOSpFc5p57TtO7fGKofc3sSTSq+6D1DNiCxuzi8uXsK30VmZd84n8N4jo zXPrut3yPwno7PkvRxRF4eogIjtQrIFLjfCv0GXaBUvgulmRIz1jVVkanhw0wZSQzudrKV wg7v1aNcOKkgmwvDIaJZF1/8MPE0Ufj3QXZBA4VG8pQkkdCXHVnAxTD6mLHVLYuALefKrF iWMTnKNC34oTqsSOx4msbrW9viN0xkuIGLd+2APinWMDd7sNZ4g7MwW6rm4Npw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs416Vvz1D1 for ; Tue, 03 Mar 2026 18:01:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 43586 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 18:01:12 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 3212aa86ac87 - main - nvme xpt: convert restart to a bool. List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 3212aa86ac87fcd3b483d3f1668dcb26a3ab84b0 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 18:01:12 +0000 Message-Id: <69a721e8.43586.7e83dfa0@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=3212aa86ac87fcd3b483d3f1668dcb26a3ab84b0 commit 3212aa86ac87fcd3b483d3f1668dcb26a3ab84b0 Author: Warner Losh AuthorDate: 2026-03-03 17:59:18 +0000 Commit: Warner Losh CommitDate: 2026-03-03 17:59:18 +0000 nvme xpt: convert restart to a bool. restart is a boolean. While I'm here, convert to a bool. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D55518 --- sys/cam/nvme/nvme_xpt.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/cam/nvme/nvme_xpt.c b/sys/cam/nvme/nvme_xpt.c index c22d5fed350c..475da6fcf783 100644 --- a/sys/cam/nvme/nvme_xpt.c +++ b/sys/cam/nvme/nvme_xpt.c @@ -114,7 +114,7 @@ typedef struct { }; nvme_probe_action action; nvme_probe_flags flags; - int restart; + bool restart; struct cam_periph *periph; } nvme_probe_softc; @@ -267,7 +267,7 @@ nvme_probe_start(struct cam_periph *periph, union ccb *start_ccb) lun = xpt_path_lun_id(periph->path); if (softc->restart) { - softc->restart = 0; + softc->restart = false; NVME_PROBE_SET_ACTION(softc, NVME_PROBE_IDENTIFY_CD); } @@ -473,7 +473,7 @@ device_fail: if ((path->device->flags & CAM_DEV_UNCONFIGURED) == 0) } done: if (softc->restart) { - softc->restart = 0; + softc->restart = false; xpt_release_ccb(done_ccb); nvme_probe_schedule(periph); goto out; @@ -562,7 +562,7 @@ nvme_scan_lun(struct cam_periph *periph, struct cam_path *path, softc = (nvme_probe_softc *)old_periph->softc; TAILQ_INSERT_TAIL(&softc->request_ccbs, &request_ccb->ccb_h, periph_links.tqe); - softc->restart = 1; + softc->restart = true; CAM_DEBUG(path, CAM_DEBUG_TRACE, ("restarting nvme_probe device\n")); } else { From nobody Tue Mar 3 18:01:13 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs54h6sz6TQwg for ; Tue, 03 Mar 2026 18:01: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQNs52bPwz3JTx for ; Tue, 03 Mar 2026 18:01:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560873; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2GOjeL09ydwEnyqdf5gsStR4ob8QAUGp5ZPj+cL8MGk=; b=n0gkHuXhVR6IxGYtOALuqNNJz5PCypW9+wfbOv8+ACpVHE/bvft4tyKT6qyOoPlvj2NcXA GLJwy77hFO7hMtb3P2TQOHRmZGuO0a3X0NgdfouaKRqS36jgtmOOx3Tb9KSV/uW22rYGvi 5bipPPbuDmclqON+gE/A9OlTEedVPRhZuISDT9k5TTvolmTpuSunKkqpHuU7oV2Sm7MAPL P5XfeEBN3CiBehKfWeuJK3UIZ4/4oMj6+CXFb6iwKpv7G2rYNi4Fj+hRBuUJOi0+Lo0QAB Ouddsmc9s8wZ0kD4sjBP2j1mrEBXvdd3dcgi/lra1H9Gbk9vsmYBpdyalq3BZg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772560873; a=rsa-sha256; cv=none; b=N2zIhmfPYGhylakNCZPAixvomXCNdIvkt3GmaZhXVfxqqzX6DWJYws+duntvi9Z/A3NxM5 kc+NP1nbbKn78xjjrV8/9MUdaquvCpfl+vP2NFmVZF5d2cffj0WuFb3a6QMpgF6O1eATu3 EW17/y4rFM1h7i+9jQ4KeMLwGarnInRl4Rwdq98iBi4b/3322IpUx0eIoZKJVYPb3jArIV YiHlZk38xvApXi65xUU2nGvDVeSX/VsNAJplQF4W0SaWG3f8ePsHWQRo+1n9xKYZemqP6K 210irrmefJ8mHRpHbZQ60EJ5uuqFxJL01Ir6NpV6DMS4tsy+WIq7C/jChWjAGg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560873; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2GOjeL09ydwEnyqdf5gsStR4ob8QAUGp5ZPj+cL8MGk=; b=Jn2moMRU6DtNSSWqYuyz3ez/JBpvxLC34VIHrJsnRYO421axM/Y5eZel4yzyIjYvNb+bsE GNNTtx/AbhPS1ho5maijN9XYZLaSp9sk4Mv593mRbS/ZwLDNyqqC59YYV3fSAO4jI5Rd4S WZk3xotOjrknMqzofbP5MotaYHBNR50WITnAf4zrUQsPCzyXNZxovhPf5rQ9Jiy7CGXvaX SD8YH6pW+anjLXpDSX5tmyMLcyD09J+LLmI9F3q8HZg/MUy86U1MSgiN12GfIImfKxcW15 j52qfq9I6cjK3JoDEitlPpNJfPwlxWhxP3ls1EVQ8DutYe2rWD3NWiKNeqiRkQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs51s3pz1D2 for ; Tue, 03 Mar 2026 18:01:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 42135 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 18:01:13 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: b1bd7fed589f - main - nda: Move ndasetgeom List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: b1bd7fed589fb5381fa2595f1f08e74895868941 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 18:01:13 +0000 Message-Id: <69a721e9.42135.5ed33ec5@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=b1bd7fed589fb5381fa2595f1f08e74895868941 commit b1bd7fed589fb5381fa2595f1f08e74895868941 Author: Warner Losh AuthorDate: 2026-03-03 17:59:22 +0000 Commit: Warner Losh CommitDate: 2026-03-03 17:59:22 +0000 nda: Move ndasetgeom Move ndasetgeom up in the file. We'll need it here for future commits. Also, preserve the UNMAPPED_BIO flag since we can't observe enough data from this routine to set it directly. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D55519 --- sys/cam/nvme/nvme_da.c | 57 +++++++++++++++++++++++++++++--------------------- 1 file changed, 33 insertions(+), 24 deletions(-) diff --git a/sys/cam/nvme/nvme_da.c b/sys/cam/nvme/nvme_da.c index 833738cfcb98..9646b792e9a9 100644 --- a/sys/cam/nvme/nvme_da.c +++ b/sys/cam/nvme/nvme_da.c @@ -285,6 +285,39 @@ nda_nvme_rw_bio(struct nda_softc *softc, struct ccb_nvmeio *nvmeio, nvme_ns_rw_cmd(&nvmeio->cmd, rwcmd, softc->nsid, lba, count); } +static void +ndasetgeom(struct nda_softc *softc, struct cam_periph *periph) +{ + struct disk *disk = softc->disk; + const struct nvme_namespace_data *nsd; + const struct nvme_controller_data *cd; + uint8_t flbas_fmt, lbads, vwc_present; + u_int flags; + + nsd = nvme_get_identify_ns(periph); + cd = nvme_get_identify_cntrl(periph); + + /* + * Preserve flags we can't infer that were set before. UNMAPPED comes + * from the PIM, so won't change after we set it the first + * time. Subsequent times, we have to preserve it. + */ + flags = disk->d_flags & DISKFLAG_UNMAPPED_BIO; /* Need to preserve */ + + flbas_fmt = NVMEV(NVME_NS_DATA_FLBAS_FORMAT, nsd->flbas); + lbads = NVMEV(NVME_NS_DATA_LBAF_LBADS, nsd->lbaf[flbas_fmt]); + disk->d_sectorsize = 1 << lbads; + disk->d_mediasize = (off_t)(disk->d_sectorsize * nsd->nsze); + disk->d_delmaxsize = disk->d_mediasize; + disk->d_flags = DISKFLAG_DIRECT_COMPLETION; + if (nvme_ctrlr_has_dataset_mgmt(cd)) + disk->d_flags |= DISKFLAG_CANDELETE; + vwc_present = NVMEV(NVME_CTRLR_DATA_VWC_PRESENT, cd->vwc); + if (vwc_present) + disk->d_flags |= DISKFLAG_CANFLUSHCACHE; + disk->d_flags |= flags; +} + static int ndaopen(struct disk *dp) { @@ -644,30 +677,6 @@ ndacleanup(struct cam_periph *periph) cam_periph_lock(periph); } -static void -ndasetgeom(struct nda_softc *softc, struct cam_periph *periph) -{ - struct disk *disk = softc->disk; - const struct nvme_namespace_data *nsd; - const struct nvme_controller_data *cd; - uint8_t flbas_fmt, lbads, vwc_present; - - nsd = nvme_get_identify_ns(periph); - cd = nvme_get_identify_cntrl(periph); - - flbas_fmt = NVMEV(NVME_NS_DATA_FLBAS_FORMAT, nsd->flbas); - lbads = NVMEV(NVME_NS_DATA_LBAF_LBADS, nsd->lbaf[flbas_fmt]); - disk->d_sectorsize = 1 << lbads; - disk->d_mediasize = (off_t)(disk->d_sectorsize * nsd->nsze); - disk->d_delmaxsize = disk->d_mediasize; - disk->d_flags = DISKFLAG_DIRECT_COMPLETION; - if (nvme_ctrlr_has_dataset_mgmt(cd)) - disk->d_flags |= DISKFLAG_CANDELETE; - vwc_present = NVMEV(NVME_CTRLR_DATA_VWC_PRESENT, cd->vwc); - if (vwc_present) - disk->d_flags |= DISKFLAG_CANFLUSHCACHE; -} - static void ndaasync(void *callback_arg, uint32_t code, struct cam_path *path, void *arg) { From nobody Tue Mar 3 18:01:14 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs64Kbfz6TQrK for ; Tue, 03 Mar 2026 18:01: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQNs62qL8z3JXF for ; Tue, 03 Mar 2026 18:01:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560874; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WoOrJeDX+CHUPSjnktALO+HQoNeUWJUAkAO2jv6APKk=; b=UQOFe340jWzQE4/uaV/92nZloPNhmxFzUSCRfGOgu2qhV/XF+jCVtu4Pkq64ph/bGNohtY IN5LRkqpQPLTgLB9lLegVC8BqSmsnaN9feXQRIVPk9f0bCSfsh1e7FnBHftT9nRh4RJ1lV N3CULPbNIo2u9hb5CKzICnJQ514C+0k32d/pOWI0uxiHQQvy7DCgPilexiIGBCvUSwCwWn +MpN3SRxU0akFXS05aLtcLM7DBYD/bQKaK6QIypO0Hnu9mMN0h0T+Hi+abrYdnI2seARly XtGcsBkOvbn+zOpFtrs2lZPQcVun2kasZDcawQ5tEtivFIqftjV6Fl2C+JZWzg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772560874; a=rsa-sha256; cv=none; b=Cz3L4IWLH5Te3K0anAtuQ0K0f/AFK/zqdvDNL8XkvxLGxtoF7fjOV4f7UdOUdKIMCN4uHi jKjjbNA3BOJmHpSJd2flYIHwqVydzpG73nf00wDqUhReVlg6854jbsli8Liiy5GfdnQi35 MY1wq/+4sgfHCCuCLTLjaNEnew6yWCS6mZcFNSDF5FnvFQdxcKSPAXrfyLllE0yyCoDmY6 /be5IzFR9nYqYf4H86xZMPxDH6rsbx54qQXd+Gy9+FgS+5LAMGMEyrH1HtMR5bJx6ihVmS nuSg5lqKAO2qHyoY8irlskgMnXNj32Kvsx9H8vcAGr743C4348DpxwYoUlaMiA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560874; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WoOrJeDX+CHUPSjnktALO+HQoNeUWJUAkAO2jv6APKk=; b=Q6FEZqeweu4W+XQbe/FOMyUhlxz/UqQ3lhQjhL2uPmWrMKra3b3+RmYl5aUnD5C+uu5tF3 tQ+tTiMvGGTJV92xUEOhaRAh+DF1rrCORSzDgXD+B/SLBqtjhZZ/60Psffkz1Od7rYZA83 UsVUauHvD8pkWlXrd8pgTZGo6cN0Ykwi4cE39WjCUQ6m/pEoo4twxw58GnXQ8CvQt5w55m 2lj5NtfQgXZAi1abwsmYg0QvzenZ+juKxJmzO0BvoJ4RqCMC2QBrgVhwytODuusVXUdqZV ddYFUDjkkocoNrFzuQ1ceLmAW7qic0iu3BTh4qVp6wFXtN549MSrgYRoZHRVUg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs6274tzfv for ; Tue, 03 Mar 2026 18:01:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 43196 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 18:01:14 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 5c2186b99254 - main - nda: Rescan the drive on open List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 5c2186b992546bce212dfad3e49012f4c69c2d0c Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 18:01:14 +0000 Message-Id: <69a721ea.43196.3698350a@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=5c2186b992546bce212dfad3e49012f4c69c2d0c commit 5c2186b992546bce212dfad3e49012f4c69c2d0c Author: Warner Losh AuthorDate: 2026-03-03 17:59:31 +0000 Commit: Warner Losh CommitDate: 2026-03-03 17:59:31 +0000 nda: Rescan the drive on open SCSI and ATA drives rescan the drive on opens to catch changes to the disk. We do it here to so we catch if a drive has been FORMATed or SANITIZEd with different parameters. We don't use xpt_rescan() since we don't want to interfere with boot or keep all busses locked (this rescan won't change the bus, so we don't need the CAM topo lock). Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D55520 --- sys/cam/nvme/nvme_da.c | 49 +++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 47 insertions(+), 2 deletions(-) diff --git a/sys/cam/nvme/nvme_da.c b/sys/cam/nvme/nvme_da.c index 9646b792e9a9..2e8e376f985d 100644 --- a/sys/cam/nvme/nvme_da.c +++ b/sys/cam/nvme/nvme_da.c @@ -73,12 +73,14 @@ typedef enum { NDA_FLAG_OPEN = 0x0001, NDA_FLAG_DIRTY = 0x0002, NDA_FLAG_SCTX_INIT = 0x0004, + NDA_FLAG_RESCAN = 0x0008, } nda_flags; #define NDA_FLAG_STRING \ "\020" \ "\001OPEN" \ "\002DIRTY" \ - "\003SCTX_INIT" + "\003SCTX_INIT" \ + "\004RESCAN" typedef enum { NDA_Q_4K = 0x01, @@ -318,11 +320,27 @@ ndasetgeom(struct nda_softc *softc, struct cam_periph *periph) disk->d_flags |= flags; } +static void +ndaopen_rescan_done(struct cam_periph *periph, union ccb *ccb) +{ + struct nda_softc *softc; + + softc = (struct nda_softc *)periph->softc; + + cam_periph_assert(periph, MA_OWNED); + + softc->flags &= ~NDA_FLAG_RESCAN; + xpt_release_ccb(ccb); + wakeup(&softc->disk->d_mediasize); +} + + static int ndaopen(struct disk *dp) { struct cam_periph *periph; struct nda_softc *softc; + union ccb *ccb; int error; periph = (struct cam_periph *)dp->d_drv1; @@ -337,10 +355,37 @@ ndaopen(struct disk *dp) return (error); } + softc = (struct nda_softc *)periph->softc; CAM_DEBUG(periph->path, CAM_DEBUG_TRACE | CAM_DEBUG_PERIPH, ("ndaopen\n")); - softc = (struct nda_softc *)periph->softc; + /* + * Rescan the lun in case the mediasize or sectorsize has changed since + * we probed the device. Format and secure erase operations can do this, + * but the nvme standard doesn't require a async notification of that + * happening. da/ada do this by restarting their probe, but since + * nvme_xpt gets the identify information we need, we just rescan here + * since it's the easiest way to notice size changes. + * + * Not acquiring / releasing for the geom probe -- it's inline + */ + ccb = cam_periph_getccb(periph, CAM_PRIORITY_NORMAL); + ccb->ccb_h.func_code = XPT_SCAN_LUN; + ccb->ccb_h.cbfcnp = ndaopen_rescan_done; + ccb->ccb_h.ppriv_ptr0 = periph; + ccb->crcn.flags = 0; + xpt_action(ccb); + + softc->flags |= NDA_FLAG_RESCAN; + error = 0; + while ((softc->flags & NDA_FLAG_RESCAN) != 0 && error == 0) + error = cam_periph_sleep(periph, &softc->disk->d_mediasize, PRIBIO, + "ndareprobe", 0); + if (error != 0) + xpt_print(periph->path, "Unable to retrieve capacity data\n"); + else + ndasetgeom(softc, periph); + softc->flags |= NDA_FLAG_OPEN; cam_periph_unhold(periph); From nobody Tue Mar 3 18:01:15 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs76MTrz6TRCQ for ; Tue, 03 Mar 2026 18:01: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQNs73dbXz3JVB for ; Tue, 03 Mar 2026 18:01:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560875; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=TwG31/mJXuxBmLMpCV3l/uQ1c+P+lJ0rJmGh/jRRQwc=; b=VcpxY2sKxtr0oN9m63vJlFnDWlWsE5fJP47QxnbFEc1/nWw/drUNfjg7i379rGF2HhNG5o 66dgsDfXTO/P4XBKd1Mx/0vcZ4UnFfvq1rqt9cjeHThth7aHN6TStrqJsaWkCrM70+KG+3 J7EQFxAAhBT9/6z6nZ1EK0gMq++qqMB0pK5OLub3KUhVF3A3dSdrIkEVOSzgNOb9/JtVr1 jVcvm0PttO2piUp/h25kq3V6bCfCKqjyNcxNmeVLe7kzNYs1RWMpw+6LIvtu1FGVRfLGkk PJWBpvuEd6GNf/h6wsufG/k0IAM9k+l9GAOd836Le7aHmQzHiMsdifzaB69EPw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772560875; a=rsa-sha256; cv=none; b=UJVSOmDjJOUsAdOfPNREjV/uvNBvjatHeGZD/TLB8v3Ia7DwtFRpUicd8t7T0Fr+vaQkOa mgiKEnSzd7x6gBx8ZOUgYr06go9EGNVpFo+9zkMal49jBfd1hPWqKjiHTNBRZ1agPzKceQ boNqeJVGn1ilrzX2zwbMGzOjfdx9kh9yU9c/8O8cpCgNAmhzhVb+geC84TFZOTOcwBXEdi l+7m/ReSmRXK8/RgQI0NDfb+LPp7gG4fph7PJBMiIQYVqYEiLdGZi1sxKyAboE4ZnVXSG2 PtfvRiX8iSE3fOnWjEQeSRWA/2GS6f7aeHZoXumtKUQ4diQjjgsbAb7t7w0Y8Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560875; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=TwG31/mJXuxBmLMpCV3l/uQ1c+P+lJ0rJmGh/jRRQwc=; b=AWGWpBGCzQn1n5VDFDIyjAMQAQiuLop2t8obW2HSEqVhNnzT/MTgAe3P9fkV6u5sjZHVTX 52FKCWdifImshJ6wVxYqZpM+a81i51mAdByChSA1lI91cih+PGdNeH8ZwLa/d0Ehlo57f3 E+5nJkEjd90WUxo4CD+rTzp1UYwbHHOImg0g6WF9CmRHcKnmnsW2xQ5iajCfX7qK4biC+P pZRwnlEFKanwzSo16/CdjaF0WQPtnJvg2b/nlpp+xnsk4WJ/sPQnMIs0AIE2+WznIbK891 qDGVm5npHn25DW4ePdahyWwbVR7IeqxJtdBUqmtU29lgJ8QUBMjqFBWvaQbMag== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs731yGz19P for ; Tue, 03 Mar 2026 18:01:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 42f2e by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 18:01:15 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 628d7a3270b6 - main - nda: AC_GETDEV_CHANGED calls media chanaged for sectorsize change List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 628d7a3270b64b6c7fae3b0c98068c670162a154 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 18:01:15 +0000 Message-Id: <69a721eb.42f2e.29157302@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=628d7a3270b64b6c7fae3b0c98068c670162a154 commit 628d7a3270b64b6c7fae3b0c98068c670162a154 Author: Warner Losh AuthorDate: 2026-03-03 17:59:36 +0000 Commit: Warner Losh CommitDate: 2026-03-03 17:59:36 +0000 nda: AC_GETDEV_CHANGED calls media chanaged for sectorsize change When the sector size changes, we assume it's new media. When the mediasize changes, we'll just resize the disk (we get called for both events). When neither have changed, don't call either. Some NVMe drives (but not all) post a async event on page 4 with the sector size changes via a FORMAT command. We'll notice the new media right away, rather than the next device open. As a practical effect, this just means that certain geom operations will see it sooner. Since most drive interaction goes through open, that will catch those drives that do not post this event well enough. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D55521 --- sys/cam/nvme/nvme_da.c | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/sys/cam/nvme/nvme_da.c b/sys/cam/nvme/nvme_da.c index 2e8e376f985d..a1114ffe8a44 100644 --- a/sys/cam/nvme/nvme_da.c +++ b/sys/cam/nvme/nvme_da.c @@ -432,7 +432,7 @@ ndaclose(struct disk *dp) ("nda %d outstanding commands", softc->outstanding_cmds)); cam_periph_unlock(periph); cam_periph_release(periph); - return (0); + return (0); } static void @@ -760,17 +760,23 @@ ndaasync(void *callback_arg, uint32_t code, struct cam_path *path, void *arg) } case AC_GETDEV_CHANGED: { - int error; + off_t mediasize; + u_int sectorsize; softc = periph->softc; + mediasize = softc->disk->d_mediasize; + sectorsize = softc->disk->d_sectorsize; ndasetgeom(softc, periph); - error = disk_resize(softc->disk, M_NOWAIT); - if (error != 0) { - xpt_print(periph->path, "disk_resize(9) failed, error = %d\n", error); - break; - } + /* + * If the sectorsize changed, then it's new media. Otherwise if + * the media size changed, resize the existing disk. Otherwise + * do nothing. + */ + if (sectorsize != softc->disk->d_sectorsize) + disk_media_changed(softc->disk, M_WAITOK); + else if (mediasize != softc->disk->d_mediasize) + disk_resize(softc->disk, M_WAITOK); break; - } case AC_ADVINFO_CHANGED: { From nobody Tue Mar 3 18:01:16 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs863HHz6TR1v for ; Tue, 03 Mar 2026 18:01: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQNs848dBz3JVR for ; Tue, 03 Mar 2026 18:01:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560876; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=i5i8uCU+HItLc+/YAbuW+50KVsQQBFy+SxpGL+Y+jsA=; b=P8mOk+toibhse4lQT/pTnHCoaQ7Tg8hCU5JaPuSsLqgopEXhMaaRqT0UrkJFMiDfqP3f4L lpmMOmtdDv2oYGhm4OaAWwuv5fzLQiyjGKNgZHglqLwPdebK5DQ+VveCmm3iqBb078T4pN eiar/md3yiDVyhxEqCum3ZnyHsGG61YNr9MInoYxi67SGoP97Q6pZbVkzzUljs5ED6bEPv 1sDuVTQxaLe7jSWrt55fiLDLb9r1lOy8nIZMoe0CQFM8QoPGYJxRT/9H8aztAqVxREbXvm tmAnOnF7j0H/eTIzoZN1dNSF8je68KtWWgvFtrJSstH21hfPzY02yeUO+GK3Gw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772560876; a=rsa-sha256; cv=none; b=IXpyfVEsl552zm+Wr7vZyTZDWNB5+5QuL5ruMmRraOomwVI3K3Ra3scnVX7CMcdMz29Fh9 LTDJBjksXOQT2cutED/TI7pNRyYtH6vqDQNJzsd4WEav3l7TwdM5aOuAXtesVKrvPVajo+ j7hjfaJdEedbmDkAjW2DP8cMUSlcrV7zDmwMk+Mf5o+zpua3fGOpdtO6omlIIGcF0bI4sY nZU8gBWpaq5eO/qHg6KbJxqCjI5GwD4CIp0zL7OXjNbEtaLxQpttRqHp8+iPqRTX/yhWox B3NYfXdBl4ksVUQeqYQYLB7/9Uei/qe5UE/RZEvWO3ZmK76IwJAwx1GqDeXwbg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560876; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=i5i8uCU+HItLc+/YAbuW+50KVsQQBFy+SxpGL+Y+jsA=; b=GeGruq5eiImpDgSYqIGRRT2PKc4H/vuM+Zhjm3jtQZGJm6iDD3DrJoBoLA40k7wUTUhhHX XW6EunkZyxg2Rw6hTdChgg157dBjkwldLQFEJhVFbBAZDqIise5n2Gz8Q84XUJTp1/0Rj3 qlhlfgOE8yaPVcows2S7xelAOO7H57GWymEviR29WHxCtW4/YktwGi3bK753MTj7wveZUV fuORCSQ9aHnkrHBIlvH99xIvTygUOCDh8ORHgFSVUdr+pu/nlNmYOjuq5QiYDd0dBaLQ4q ubVEpFy1El+j7qdDBppao51fDXI/pkUiafnQ2jseUI/ZV8oS0+s/8ajqcBHYOA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs83dhmz19R for ; Tue, 03 Mar 2026 18:01:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 43699 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 18:01:16 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 244ae85eb975 - main - nvme_sim: Fix a cut and paste error List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 244ae85eb97548fd81783f079ee26e0aa9f4b984 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 18:01:16 +0000 Message-Id: <69a721ec.43699.5152f76e@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=244ae85eb97548fd81783f079ee26e0aa9f4b984 commit 244ae85eb97548fd81783f079ee26e0aa9f4b984 Author: Warner Losh AuthorDate: 2026-03-03 17:59:42 +0000 Commit: Warner Losh CommitDate: 2026-03-03 17:59:42 +0000 nvme_sim: Fix a cut and paste error Fix the error message in nvme_sim_ns_removed that was cut and pasted from nvme_sim_ns_changed to reflect its new home. No functional change. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D55522 --- sys/dev/nvme/nvme_sim.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/nvme/nvme_sim.c b/sys/dev/nvme/nvme_sim.c index a3176f12b11a..a4bb5df4e456 100644 --- a/sys/dev/nvme/nvme_sim.c +++ b/sys/dev/nvme/nvme_sim.c @@ -438,7 +438,7 @@ nvme_sim_ns_removed(device_t dev, struct nvme_namespace *ns) if (xpt_create_path(&tmppath, /*periph*/NULL, cam_sim_path(sc->s_sim), 0, ns->id) != CAM_REQ_CMP) { - printf("unable to create path for rescan\n"); + printf("unable to create path for ns removal\n"); return (ENOMEM); } xpt_async(AC_LOST_DEVICE, tmppath, NULL); From nobody Tue Mar 3 18:01:17 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQNsB310Bz6TQrP for ; Tue, 03 Mar 2026 18:01: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQNs95PCyz3Jb6 for ; Tue, 03 Mar 2026 18:01:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560877; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=FtSV6JgRoJaNRyAKhil+AnDFoVOfj/uEj4zNKWRcLr8=; b=pnC1cZ2cwm/XiBxsxBBYkWejZOXq8jzVUrsFRCUp6Y+dUI1NhyM7Nh4KHoZJ1R4lyAVPqu ++KaZWEEYsoNM3EWLvy2b5QXqv8Ne4JAW+Cdd5EpRkFz2zDqQfFPqWaD0gPBjwsGsPV7Kz sCL7ckvQzNaC0MY/r1ACso1eEGNXHFBuUYwOf9uemnSd9/mHPs+PVMwEoW4DL/oQuomSAH +6nSgvHT2oV9RXxShsOIR8JWhLeP88J/IJhu4UqWS/C1r3sVGzs2Kc+T6K91mDI4jlWpQ0 TDsbbBZzmtiFdydgk62bhwOUGZDKhEwMFnEavBFusr2k9EpL0oVS1imlg0Dy0g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772560877; a=rsa-sha256; cv=none; b=UAiyh6NrY179z4H0epeFdsquGxOcKHKjqUzFjgZskrvFkGr2AoZ6BoYZK3pds3fVWdDyYe ijapiAwkD12HMLV9xXn1N7+A/PqnSyjHNhrPV/ZEGj8BL+7J0B0KpkErDggLTdgD/hen77 A++5ODwpzXDs7yzctuGmPvHcaZotFHgY94VFHYelzuME/JkRLes8Fl3uLFkBZe08lmuK1t vBUlRdfOAWKghI48gPVRw8tFQI+cXCnVKq1jkuE/Z4rKQ+HHtzL4gXKUGGMAwA+2y1jYT+ xADDFBD6GXqQRdKDm1A5udhjuk9jbVR3T82ADPjDHeTrVZZJnFzLrwwmZ6bLDA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772560877; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=FtSV6JgRoJaNRyAKhil+AnDFoVOfj/uEj4zNKWRcLr8=; b=Sirx2eAfuKI0+OqCzWX4ZOvAkaYRh2USL9rSFk82NKNFKHM8nzfKy7heAZ3t3/+XqRQDDo jnhklA2EXPIvuA0tdR9pkVenlcyACJzZrIokV9HVEBhi/htqX5u3/o8yaEkvRKuYh6jasd KpToTOnwyhc5HsMXE7vggmTn64LXUrNsXrNL4KpZMYzUvFmOUhYTBKhe7KzWheczh6RnvV WS+xHgNUEqiarjsdZEfkBlzQ2/ZOxhTXe/ACxFfhKVjRwLXEsp27bv7CKBhEn3Bpjhlx60 OKXN3HE7jmtybHKcT1aBHabOSPmRx/ri4gLL4INxko7C8HgwoV1Pc6yTp9XvRw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQNs94QX8z19S for ; Tue, 03 Mar 2026 18:01:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 42fa8 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 18:01:17 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 824530a5c4fd - main - nda: Assume all cases in ndaasync can sleep List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 824530a5c4fd59427cda0eae0a4ac85212814958 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 18:01:17 +0000 Message-Id: <69a721ed.42fa8.5c0394b@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=824530a5c4fd59427cda0eae0a4ac85212814958 commit 824530a5c4fd59427cda0eae0a4ac85212814958 Author: Warner Losh AuthorDate: 2026-03-03 18:00:15 +0000 Commit: Warner Losh CommitDate: 2026-03-03 18:00:15 +0000 nda: Assume all cases in ndaasync can sleep The error recovery is nicer if we can wait for the tiny memory we need to send the messages when the physpath changes. Since we've moved the async handler into a sleepable context, we can wait for the allocation to complete since async events are rare enough and it's not an indefinite wait. Also add a comment about the scope of AC_ADVINFO_CHANGED for nvme drives. We could use it for broadcasting INDENTIFY changes in nvme drives. However, the underlying mechanisms in NVMe don't really allow for that (they are more fine-grained). So for namespace changes, for example, we'll send AC_GETDEV_CHANGED instead of a AC_ADVINFO_CHANGED. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D55523 --- sys/cam/nvme/nvme_da.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/sys/cam/nvme/nvme_da.c b/sys/cam/nvme/nvme_da.c index a1114ffe8a44..be578bae5da5 100644 --- a/sys/cam/nvme/nvme_da.c +++ b/sys/cam/nvme/nvme_da.c @@ -782,11 +782,19 @@ ndaasync(void *callback_arg, uint32_t code, struct cam_path *path, void *arg) { uintptr_t buftype; + /* + * Note: In theory, we could send CDAI_TYPE_NVME_* events here, + * but instead the rescan code only sends more specific + * AC_GETDEV_CHANGED. There's no way to generically get + * notifications of changes to these structures from the drive + * (though we could notice with memcmp). The automation in NVME + * is at a much more granular level, so we leverage that. + */ softc = periph->softc; buftype = (uintptr_t)arg; if (buftype == CDAI_TYPE_PHYS_PATH) { disk_attr_changed(softc->disk, "GEOM::physpath", - M_NOWAIT); + M_WAITOK); } break; } From nobody Tue Mar 3 18:16:59 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQPCv66tcz6TS5q for ; Tue, 03 Mar 2026 18:17:31 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pl1-x62e.google.com (mail-pl1-x62e.google.com [IPv6:2607:f8b0:4864:20::62e]) (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 4fQPCt1kqxz3QNC for ; Tue, 03 Mar 2026 18:17:30 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pl1-x62e.google.com with SMTP id d9443c01a7336-2ab46931cf1so45291035ad.0 for ; Tue, 03 Mar 2026 10:17:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1772561832; x=1773166632; darn=freebsd.org; h=to:references:message-id:cc:date:in-reply-to:from:subject :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=s3nl9oc+Z4Vaj+jGQDZa5B9XqS0NfFtv/spEtCwXDrg=; b=lUwavJWC2WsbW+xFnvMjOImWqUklxPbcrsAEO+UpQDCpAr2zP4cgO15kVypwaxvSIn mlnh8+KaQBO+Qic5ThENhrW13DIJJpr/ND3f0aG93m1XCjgKV3XgVy2+i4u1TorNQBSj M6aMQYQNxG6i2e+5oFLYAGrj8Oq/atejhAJ/DUj7eI/XbqR+yFrugaX7sEluMe2ShLKO ja/yG6KP+FQqJ1aLdxJ0wibTdYoXmw2YMhTbKWaCwpdpDMPuBSs8a3ywHGBR1Oh8+6eb S6cEytB5cSjofGW8wJgbxCibKVS8MICOypx7ZOk6cXxBxZ0t4Pi46WLudf02SWEauKug n2zQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772561832; x=1773166632; h=to:references:message-id:cc:date:in-reply-to:from:subject :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=s3nl9oc+Z4Vaj+jGQDZa5B9XqS0NfFtv/spEtCwXDrg=; b=GJ1FuOBY4Xs24ak9fgajp7znxhc096AxkY9w0aW1TF5xxv3rmqIBPB1SNfTEq9K6b9 3oophb2ZJ/godxn9bpN3CoUp73fDMt7fwYx4y5FrH2oNjwXjut/FM8d/Fvvb/8sCrmj/ yZbDQpeT3rdGrM6aigF53zhluT1d0JBZleD9Lp/YjbnOVqVuDleS+lgQ4M0UQTOnfaLP xsC57847TKyEERSmTPw2QW6FEvIhxPK0KVsSbfIwYzidrxlGUT3sbLllHQALUuDbMKAJ J9D7Sv4TBYForhf0/ydQffIviULOoldn2g56vC8c8TseiwMwANI9cYA21+CBXh7c0SS+ G4Bg== X-Forwarded-Encrypted: i=1; AJvYcCW+W/Z51qMeaE0apEBoLKdIswNlC5T/WmaeumVFRfplqWMFb+ylWKSfHEhnfEHgVtEKFtHmoRMA1Xp1nRr+FaB7aXprPg==@freebsd.org X-Gm-Message-State: AOJu0YwjsFaUqHldNd/8gm9wjkpNfsiERqI0QYUDpIN650POqT6wOumz orejhPCKr3aaONFmGPBD8geCnvCTY4u1/pmGIz1tLQW0adp6T3uhWQneO1deHcg3 X-Gm-Gg: ATEYQzzKfudwgnCjL1dJWGnsRtO+TyXcqyJn7HHlue0qYErgRXXexxnAdaE0yUMmwA7 pzYm5noiKTE2eB/ceCWvKZmXZ3Js38aFTruLJmzjhg8RGj06iPwQXGOIW+61g+ru/ZEIUb4e2rq K94xWms4l8rzE3zTQzIITV2gzLg17XXKkKV92hGe8QqIVKbUxErPTW039vlGjteUTnBYsgxFKKn T1w21LsnWgXwwbQ3CnMEh6X8RI6EOZDMsuf/g9ifj8EcCbyLf7GAYbdKvqxiOqzWe1FAzRcaSVL jZoaSTLBMJndwi+r4J4/0HI0ptyjmsMSG9EPan1bovzfbJp/EScJzzPY6n3lpKwXq1oLIbxonzr URuu8BZi6v7nRWvMgYQApoQwkC5sj0bw2dkVbAdkyKcN31YHwEe5ZsHBaAy6qLYUUzxoxzRx5OD YCWK9fX48br4HNEYjDy5DmuIiNOu+eMEM7BxEKtLpVIQ== X-Received: by 2002:a17:903:1905:b0:2ae:47d7:e101 with SMTP id d9443c01a7336-2ae60c53f62mr27571055ad.1.1772561832017; Tue, 03 Mar 2026 10:17:12 -0800 (PST) Received: from smtpclient.apple ([145.79.197.104]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2ae4f945985sm101939455ad.71.2026.03.03.10.17.10 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 03 Mar 2026 10:17:10 -0800 (PST) Content-Type: multipart/signed; boundary="Apple-Mail=_6A232A0B-4DA2-4CDC-9776-749693A57015"; protocol="application/pgp-signature"; micalg=pgp-sha256 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3826.700.81.1.3\)) Subject: Re: git: 912864912b71 - main - Run `make obj` before running `make test-includes` From: "Enji Cooper (yaneurabeya)" In-Reply-To: Date: Tue, 3 Mar 2026 10:16:59 -0800 Cc: Brooks Davis , Enji Cooper , src-committers , "" , "" Message-Id: References: <69a678f3.3f811.148b0d7d@gitrepo.freebsd.org> To: Warner Losh X-Mailer: Apple Mail (2.3826.700.81.1.3) X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated 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-Queue-Id: 4fQPCt1kqxz3QNC X-Spamd-Bar: ---- --Apple-Mail=_6A232A0B-4DA2-4CDC-9776-749693A57015 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 3, 2026, at 4:22=E2=80=AFAM, Warner Losh = wrote: >=20 > On Tue, Mar 3, 2026 at 5:18=E2=80=AFAM Brooks Davis = wrote: > On Tue, Mar 03, 2026 at 04:25:48AM -0700, Warner Losh wrote: > > On Mon, Mar 2, 2026, 11:00???PM Enji Cooper = wrote: > >=20 > > > The branch main has been updated by ngie: > > > > > > URL: > > > = https://cgit.FreeBSD.org/src/commit/?id=3D912864912b71951f9a636190b1dba805= 28f588eb > > > > > > commit 912864912b71951f9a636190b1dba80528f588eb > > > Author: Enji Cooper > > > AuthorDate: 2026-03-03 05:59:50 +0000 > > > Commit: Enji Cooper > > > CommitDate: 2026-03-03 05:59:56 +0000 > > > > > > Run `make obj` before running `make test-includes` > > > > > > Before this change, `make test-includes` (run as part of = buildworld) > > > would place test files in the current directory, which would = clutter up > > > git clones. Run `make obj` beforehand to ensure that the files = are put > > > in `${.OBJDIR}` instead of `${.CURDIR}`. This helps cut down = on the > > > noise significantly when running commands like `git status`. > > > > >=20 > > I've never seen this happen. .OBJDIR is created automatically for me = always > > for the last 5 years... I run buildworld all the time. Can you = explain when > > / how it happens more specifically or back out the change? >=20 > The commit message is unintentionally misleading and incomplete. I = hit > the problem a week or so ago when fixing gcc12 builds and lacked the > time to follow up. test-includes is fine as part of buildworld, but > when run directly from src does fill tools/build/test-includes with .c > files if you blow away the objdir (which seems to the the only = reliably > way to cause test-includes to retest some more complex cases.) >=20 > Ah! That should have been in the commit message as the edge case > that provoked this. That's a decent explanation, though there's other > bits of buildworld that will also cause problems if you do them in = isolation > and not part of buildworld. This one, though, is important enough to = make > an exception for, I think. It's one that's most likely to be used in = isolation. Hi Warner, I consistently run into this behavior when doing mfsbsd builds on my = 14.3-RELEASE host using this src.conf: https://reviews.freebsd.org/P702 = . MK_AUTO_OBJ=3Dyes as shown here: https://reviews.freebsd.org/P703 . I always run this target as part of buildworld on my 14.3-RELEASE host, = so whatever is working on your end is likely an artifact of the build = host environment, whereas what=E2=80=99s not working for me like you = expect is an artifact of my build host environment. This: > Before this change, `make test-includes` (run as part of buildworld) > would place test files in the current directory, which would clutter = up > git clones.=20 Could more accurately be expressed like this: > Before this change, `make test-includes` (run as part of buildworld) > would place test files in the current directory on my 14.3-RELEASE > build host, which would clutter up git clones.=20 The exact reason why there=E2=80=99s a difference eludes me right now. -Enji PS I was waiting for a response to the Differential for over a week; I = landed the change because I hadn=E2=80=99t received feedback on the = review in that period of time and because it gets really old quickly = having to always do `git status -uno` in my clones to make sure I=E2=80=99= m not accidentally committing things that shouldn=E2=80=99t be = committed. This is especially annoying when doing rebases with my = =E2=80=9CMac=E2=80=9D dev branch because it has a lot of overlapping = sections of code in asmc(4) and thunderbolt(4).= --Apple-Mail=_6A232A0B-4DA2-4CDC-9776-749693A57015 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEkHfexGRJ3gYRdA2gGpE5DjPsNJgFAmmnJZsACgkQGpE5DjPs NJirEQ//YJuRxzhrEiJmZE6Oa1OnC+z9d9MKSGL2wxUrHYyKVh6vMTstrHaEG+uS 1R9zrZPPnKK4GazKcKcfA+86iATUwdFl9elQ0TmUPCjvqqdtyN5jYpkwL0h84hJ1 slgo9di4vgYZC7qQdTSWNXZt+wwpYNM+QE9GjTBuyFfgEpFryKMfeNyDLUE7Amgr n9LRbRucZv/kDPA3WrHHpGLyl8oiwgLO7bMyw9ch8ZGJQCQn967iA4Vrj2hjST8+ H2USEt785lOK7I8lQcTCOjvv+oqNUaldf8mtP7lfdWzay21vNajYlrPmx2HFsRwt S3ShoPiOTJmmBxNfcZRVAGiYPfJIli044CM7k+75l/Va9eZBcHa4/wD3EnNHrIDg md0gLbkt/wavf8rNXYJX1cheELYlRODpvrHfpXY+o7B4suGIuAAkRTNKqTKIyAPw WhfjaEcQwmDTKHollNfSpQVf8aQ48b+DQSpnl/HRkAE/T5Koz0Qy0nwxsqEIyf4q +IkqiqrOFGsIvbnSCHdLF+yMudGLYuNtvJIjbR0ZcHR1XPAWprdP9LQQ8JTs/TYz sQvziVHjw0yPwZGbwZtdQaDj4fP5E/yK+q6KdxVD8yayy6Lzj+iL9Zh1EQM2+wXt foetu1s2wPkDWJoBhAUsG5tCSzwrXTr7QbFeGa929KKQAxUmLN0= =7t/q -----END PGP SIGNATURE----- --Apple-Mail=_6A232A0B-4DA2-4CDC-9776-749693A57015-- From nobody Tue Mar 3 18:29:16 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQPTX3PZFz6TSf0; Tue, 03 Mar 2026 18:29:20 +0000 (UTC) (envelope-from bz@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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQPTX2rBcz3RM9; Tue, 03 Mar 2026 18:29:20 +0000 (UTC) (envelope-from bz@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772562560; 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=hLsIilWgI4ouvn0NCL2W78dvFQDqJWAUqxDn6wuMi9Q=; b=FwjlYdrFRnkcAqedS9cD03dWXo+5SR5z2OB2EecRV+5qmH/KUfRdo0qr/D18LTvHrzWIxe dl9T0Mg1JUZvc9sXEey3i51mcMPXynJw/U05sVMxZVK3biTJ0WwbxaBQXwG/WVOjRR1oxG 1ec81teRpQEfzRYh9xFhSkTvCHQHcq+1v98KJYZiWq3rAviVi+znDlpri6uOYxA9yUs2FM nmoBNSnmldgKm/UUZi2uluTNKkqsm4yBCKvFe9sxB1j3ZyJzmarWM84b/51hLXkboWJurh vemEag2UjOq2MukMROQU3XO7bhCq3zaKVHzzNrDzqSLPXK8MFkbpeICWQ0+B1w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772562560; a=rsa-sha256; cv=none; b=FiUXkBLkmgKmDCGeuJL3YpVPiQie0cwnOqctqBhBFpdz8Nuc1oNt+e75J2vYVmQl/u94TL X5ezyZZl7PP7XGDVzOPnBDOJT9ivfS8FIFEWOqzT5Qps8KOzO+gV3ExJVKXNxRfjyeoGT9 GNQVmbwfhBfVKjf6Xfc4btRqGdxbRKjYFSvhDNyDX83TYCDoRJCXpBCHOszPGdohkD9HZh hLJympv+uC08j4qSMZSpQQQSlbH+XwZEIZ5NoN8/eXmmcrpgQ2DASs+RGsT9Gg4Z+AmgBh Buh6D+Jl3L1a42uLqwLhN2UzU0lXjDVwdJKAb3Du710TLzhAc0/D+8MLmlCKpQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772562560; 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=hLsIilWgI4ouvn0NCL2W78dvFQDqJWAUqxDn6wuMi9Q=; b=cjwSqadnHhacwQ2T2+d+hMchmnokkPwKy/KftMc9/zn59LSBFF4lJmuuT1MbcLeJKmuqWU 0PV0extCF8zdLYWLziotwWo2NtAi3un2TAmFqfNcN56fwbfdKVNIVXf5ENXfgDPqcxXoVb BipnHY2lnoFbhwDwyN0uFiu1OBrInQl2gmjONwQe0zp7DwHx6TvltQ0Va4fnojrOypVs4I LEC1Ncqdhc7p88qqXTPNYCNOu6Vm18Y+Y0p9YEAf8LZc5N8bAcWBLB+Xe2SF7txOffMoKr ZJsHT+OBALsIWdYZPn/2t39X7rn14b4nQvKA/+a+O8KPGG1WgapX8nqoE4KeCw== Received: from mx-01.divo.sbone.de (legacy1.sbone.de [80.151.10.34]) (using TLSv1.3 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 "E7" (not verified)) (Authenticated sender: bz/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4fQPTX15LKzZ9d; Tue, 03 Mar 2026 18:29:20 +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 4E9CEA64806; Tue, 03 Mar 2026 18:28:59 +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 63BC42D029E7; Tue, 3 Mar 2026 18:29:18 +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 r3a1BIc6O1Z9; Tue, 3 Mar 2026 18:29:17 +0000 (UTC) Received: from nv.t4-02.sbone.de (nv.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:22]) (using 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 097312D029D8; Tue, 3 Mar 2026 18:29:17 +0000 (UTC) Date: Tue, 3 Mar 2026 18:29:16 +0000 (UTC) From: "Bjoern A. Zeeb" To: Enji Cooper cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: c47cefba8312 - main - Only build USB-related modules if MK_USB != no In-Reply-To: <69a668aa.3785e.4a16f236@gitrepo.freebsd.org> Message-ID: <1s9oq316-3q4o-9273-3qos-3n3o793ns725@mnoonqbm.arg> References: <69a668aa.3785e.4a16f236@gitrepo.freebsd.org> X-OpenPGP-Key-Id: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed On Tue, 3 Mar 2026, Enji Cooper wrote: > The branch main has been updated by ngie: > > URL: https://cgit.FreeBSD.org/src/commit/?id=c47cefba831240a1b3de375f18134b93cf998f5c > > commit c47cefba831240a1b3de375f18134b93cf998f5c > Author: Enji Cooper > AuthorDate: 2026-03-03 04:49:54 +0000 > Commit: Enji Cooper > CommitDate: 2026-03-03 04:50:03 +0000 > > Only build USB-related modules if MK_USB != no > > This change moves the thunderbolt module and other USB modules under a > MK_USB != no conditional to ensure that users not desiring USB support > can easily build systems without USB-specific drivers using this knob. > > MFC after: 1 week > Reviewed By: imp > Differential Revision: https://reviews.freebsd.org/D55576 > --- > sys/conf/kern.opts.mk | 5 +++++ > sys/conf/kmod.mk | 8 ++++++-- > sys/modules/Makefile | 16 ++++++++++------ > 3 files changed, 21 insertions(+), 8 deletions(-) There is a hige load of further devices which depend on USB which are not part of the current set excluded; I assume they will now break with dependency issues if USB is no longer built but these modules are built. Is there any plan to also "hide" all the other modules? -- Bjoern A. Zeeb r15:7 From nobody Tue Mar 3 18:41:39 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQPm661RTz6TTfV for ; Tue, 03 Mar 2026 18:41:58 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pj1-x102e.google.com (mail-pj1-x102e.google.com [IPv6:2607:f8b0:4864:20::102e]) (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 4fQPm632Lvz3Sx0 for ; Tue, 03 Mar 2026 18:41:58 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pj1-x102e.google.com with SMTP id 98e67ed59e1d1-3597df496f6so1769788a91.1 for ; Tue, 03 Mar 2026 10:41:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1772563312; cv=none; d=google.com; s=arc-20240605; b=F4RstXdluOjBaoAz8Oe1I34DvOuqVoLRWP5ezG5mPil4lfVMqfobRfbOfsgEzqfyjT G8uGbRbDolEdfc7IhY5GV3mE9MnHSgTA0BSbxofiSs6FhXLaTDowVfQJNU+wStzR643U AnquozL5QpWFCK2hg2xvjSF5zmVJs2wdiP/KUKrkLuSlCiPRJwJq7HrsPIzATK/cPj6h 3FaSFREkGyS0m8w/p7gBGac0TgXvO3BuPG/uQHBSv5r1swV4D3nUNWRWAJj1hnQ1sJT5 L5HwxOOPE5P0lyvJIxyLgN2c7iYbWjBZmkDJ+hcWIa6tbwu0f6S5hkjR77VB3x+SQiYk Sk3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=2OeCHzisgkJfQBpCFBHvZTubw7E1yadYrpIs+trCzbg=; fh=8jSNRK7LPctBsxWWarDfWXy1sA8Fr9LP+JEVT8v0zRI=; b=I3kVFR3cKPAxAzFtHid2h5aGTvWHe/fWUX6kmoQ0RHoLhdiDnRynQDHMEKP80ngEca nRdWQD/R2GMNRRV7/U7ImzqvPDFtUfQvpXzOjcBCU9ZMy1417TU0zoxZAU83kYEIdB2b 7ByIfN5RlW2/sXJDMtCeRhkmEzOh4KSxARrjKpQdT6MX3zedeL6urJ7qzBBVKXgoxTOT uiMp1pRVWmKbJolGAXDz2T+aj2ikabX4UhyYOX2Vu9k/3ZVbFKueriHXLzd9yYqJ7K/i zS9CNMnzsCL1WLWF369V10mkCmRagGgStTZC6PStuz3haAoCqyPnx6woMjcT/IfkkX0Q 8EIQ==; darn=freebsd.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1772563312; x=1773168112; 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=2OeCHzisgkJfQBpCFBHvZTubw7E1yadYrpIs+trCzbg=; b=N0ayZcfIq9k4dH7U8zMU3ZAGoGsI3SkOIMYvgUMZKKUkO0JF4wjw35Z6ciPu1cZXUE JSMkv3FwsZb/BV/ttXHOcEp/saWKp1i5AaCWrekGbhfq471JbEspQWU4TA2eiAEbO3GC PaagcU0lEFHfEe/fd1vaMYeIz/bDIBvU+XF3ymO6YI3rhxeNi78oqgAQO0dlAtXvXzy9 D6YUxxr3UhrY91tZtyp4rOx0cfEvo3yMFyD026+okg+2r5E1UU56SuM62Jl9OOdat6Tt a4Jt10b6c9X2zWKkKlzggTiwVcrqEgXAUKqlwqO+dnUTmLipAPJapgSUN67vpVJ/O4dw 5myw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772563312; x=1773168112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=2OeCHzisgkJfQBpCFBHvZTubw7E1yadYrpIs+trCzbg=; b=Iusce1v6R+wjyDGevvvvr6yWRz1r6BM5KuKKgzewWjCutzMqfJiwyD+kJA0yRrx6H8 94VUWVT2x5c0YhOnedkCWojv9Mn6wN31HsmDG2D3K2fzZEtkMdI0ORTS4fQWbT+6NoPt j3xdonqo3ir8WdM8ddP0EdsfXGazWcNxuywGB7OESR125EdyXD8QPSwSkxlwoJZ2Mkzs pjVwipjPbBQSLxs4v4Ql42DN7GkLHP1W9zouqYm2hacqNdmf1X7i41eTvQKVzli5OWIV G/tdw5CLTnFSjt2j5X8Iym13JgmLuRC7ODHe1aYTouoGtlaiPI+lg3XYyzyMgIkXYZiq fmKQ== X-Forwarded-Encrypted: i=1; AJvYcCXk3CHPpDtwCyAFmD16JZZkazIdNNMvyhUjHvYfqf+k5FJnsuBRoDAPmkfcgf4K7rHJVrL9u6kD/711ekYX71EaOCiTzQ==@freebsd.org X-Gm-Message-State: AOJu0YyP+f0VnCt0Kq7zE1UXPXnLTjnvPBzWGgyUyCBSNyUHLan2nSG/ Fdcr8WoPWYrlNaR9Vq7WHouz5prVeuSeuZDHP9fW259YeOHbnqokvakThRdzthzY7LfSrl6Vbfc Z1zCXPUsGGLdlbHTrvaRD4rYPUJr1ACP1yi/65zYMig== X-Gm-Gg: ATEYQzyeRqGNmTdr3y4N9E9yliIPOPH/lFYpyewZ9DXVuSN+q/lVHsFpiGiiBQ58Khu nEjBaP1D8//IUnUF4iFCuxQl1Duo6zhMLivPVR6M7jrVuTa2Ldg0MMWss7gYRppTY/dfpeU8M4q 3MswgJl1cfPTXXzeyHz3mAL+LJ94JViAnTkYQkSlIZbqHwEfb3mtu83ypKJx7+K6RsVAoh3x7c7 sBzyiMOQw3HCwpuSOgwubL6ZicqakEld9zpzGpFmrznLnS33g8get6bTf9aEtJDFNN2MKozgvUe m5hNuvI= X-Received: by 2002:a17:90b:5747:b0:354:a065:ec3e with SMTP id 98e67ed59e1d1-35965cd0f50mr13790421a91.26.1772563312113; Tue, 03 Mar 2026 10:41:52 -0800 (PST) List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 References: <69a668aa.3785e.4a16f236@gitrepo.freebsd.org> <1s9oq316-3q4o-9273-3qos-3n3o793ns725@mnoonqbm.arg> In-Reply-To: <1s9oq316-3q4o-9273-3qos-3n3o793ns725@mnoonqbm.arg> From: Warner Losh Date: Tue, 3 Mar 2026 11:41:39 -0700 X-Gm-Features: AaiRm52dwUYZ4JsA5Fd8hJayeDaLwyMlBaQwsXvpS2i3hliWPJdQaXPZ8JzSmlM Message-ID: Subject: Re: git: c47cefba8312 - main - Only build USB-related modules if MK_USB != no To: "Bjoern A. Zeeb" Cc: Enji Cooper , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: multipart/alternative; boundary="0000000000008f8938064c230ee7" X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated 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-Queue-Id: 4fQPm632Lvz3Sx0 X-Spamd-Bar: ---- --0000000000008f8938064c230ee7 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, Mar 3, 2026 at 11:29=E2=80=AFAM Bjoern A. Zeeb wro= te: > On Tue, 3 Mar 2026, Enji Cooper wrote: > > > The branch main has been updated by ngie: > > > > URL: > https://cgit.FreeBSD.org/src/commit/?id=3Dc47cefba831240a1b3de375f18134b9= 3cf998f5c > > > > commit c47cefba831240a1b3de375f18134b93cf998f5c > > Author: Enji Cooper > > AuthorDate: 2026-03-03 04:49:54 +0000 > > Commit: Enji Cooper > > CommitDate: 2026-03-03 04:50:03 +0000 > > > > Only build USB-related modules if MK_USB !=3D no > > > > This change moves the thunderbolt module and other USB modules under= a > > MK_USB !=3D no conditional to ensure that users not desiring USB sup= port > > can easily build systems without USB-specific drivers using this kno= b. > > > > MFC after: 1 week > > Reviewed By: imp > > Differential Revision: https://reviews.freebsd.org/D55576 > > --- > > sys/conf/kern.opts.mk | 5 +++++ > > sys/conf/kmod.mk | 8 ++++++-- > > sys/modules/Makefile | 16 ++++++++++------ > > 3 files changed, 21 insertions(+), 8 deletions(-) > > There is a hige load of further devices which depend on USB which are not > part of the current set excluded; I assume they will now break with > dependency > issues if USB is no longer built but these modules are built. > > Is there any plan to also "hide" all the other modules? > As I said in my review, I'm generally uneasy about this trend... Warner --0000000000008f8938064c230ee7 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Tue, 3 Mar 2026, Enji Cooper wrote:

> The branch main has been updated by ngie:
>
> URL: https://= cgit.FreeBSD.org/src/commit/?id=3Dc47cefba831240a1b3de375f18134b93cf998f5c<= /a>
>
> commit c47cefba831240a1b3de375f18134b93cf998f5c
> Author:=C2=A0 =C2=A0 =C2=A0Enji Cooper <ngie@FreeBSD.org>
> AuthorDate: 2026-03-03 04:49:54 +0000
> Commit:=C2=A0 =C2=A0 =C2=A0Enji Cooper <ngie@FreeBSD.org>
> CommitDate: 2026-03-03 04:50:03 +0000
>
>=C2=A0 =C2=A0 Only build USB-related modules if MK_USB !=3D no
>
>=C2=A0 =C2=A0 This change moves the thunderbolt module and other USB mo= dules under a
>=C2=A0 =C2=A0 MK_USB !=3D no conditional to ensure that users not desir= ing USB support
>=C2=A0 =C2=A0 can easily build systems without USB-specific drivers usi= ng this knob.
>
>=C2=A0 =C2=A0 MFC after:=C2=A0 =C2=A0 =C2=A0 1 week
>=C2=A0 =C2=A0 Reviewed By:=C2=A0 =C2=A0 imp
>=C2=A0 =C2=A0 Differential Revision:
https://reviews.freebsd.o= rg/D55576
> ---
> sys/conf/kern.opts.mk |=C2=A0 5 +++++
> sys/conf/kmod.mk=C2=A0 =C2=A0 =C2=A0 |=C2=A0 8 ++++++--
> sys/modules/Makefile=C2=A0 | 16 ++++++++++------
> 3 files changed, 21 insertions(+), 8 deletions(-)

There is a hige load of further devices which depend on USB which are not part of the current set excluded;=C2=A0 I assume they will now break with d= ependency
issues if USB is no longer built but these modules are built.

Is there any plan to also "hide" all the other modules?

As I said in my review, I'm generally uneasy= about this trend...

Warner
--0000000000008f8938064c230ee7-- From nobody Tue Mar 3 18:46:54 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQPt40tbcz6TT8s for ; Tue, 03 Mar 2026 18:47:08 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pj1-x1029.google.com (mail-pj1-x1029.google.com [IPv6:2607:f8b0:4864:20::1029]) (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 4fQPt347nDz3T9K for ; Tue, 03 Mar 2026 18:47:07 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pj1-x1029.google.com with SMTP id 98e67ed59e1d1-359866a1d02so2466136a91.0 for ; Tue, 03 Mar 2026 10:47:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1772563626; cv=none; d=google.com; s=arc-20240605; b=jaLB9hBcGAtUhmgbaxM2P3StsFhVBSF4wf86uKeuqd2IrAV5Vjw/wXXh2QWCXJfyW7 6CJKL47sjZevRPPFXOt6ypqlReY6xZb0WrBs1CmOxA5MWn8/5yqEVxrJFNcT8zY8lmcv ygdVJjCE8RZUNkucOAjAUSfHgytmqTKYofpEtGRyE3Nj4NiugFIIlsvyyB8dzqsgvnDn vw9V2P1602xQS9bwbZq991mstd7IghkBmw9E/+Q5O63R1esEAnwDjDDgHvshfaMOmWKI 26X90GS0+Z2aO6Eh7FP5wB8+RvfqwnyDEZAeDGW/bDAiJrLMmSxwCrxFsSgjyPifxa+G 5yUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=oMq1lhjEuef5erMXhpz5bzkhXZNyHyRcJxuf0wDNgtQ=; fh=alDvjAORupuQlJsOg39C5xSRMHcMzPUspJwdsfg09Bs=; b=Bovn/Gt/EzoQy3sQ8FDGh+g32rZ6lVYDLNWzIX7kbWzIUUwVcc2r3ht75H/eBtyi5P mQ5/TDfyUPJSynZBGxfG+C1fxXGYOIOR4EpuSGCPWBrvx9pFN7uxc2oiksiOY9P0v0Nj jswCLlbwuZfGdEvL25rP+BaBXxTV96CnfiJMcImW9t9bIzBMI3DA2XS/GeDkLRQejE97 faYXntk/apDJgLkkNQUwj6md2pbFkHNdcOXH/P7HSPAD9hVhJDT9XYDxkb49Lkas8vM3 xtzDVmUJTgrMjUbmwbYZDkXan1PEcwuTNp4YBkGI6/LLafTyJsGRPOCdr0ck8zluxkBZ RDxg==; darn=freebsd.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1772563626; x=1773168426; 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=oMq1lhjEuef5erMXhpz5bzkhXZNyHyRcJxuf0wDNgtQ=; b=yd41UizTd/XPug7WQc6APYTWlwRSivj8TcLFlwa+K+eisWU3z/FqJsUn4PV0pXw1HA yDjlBw5KTgjh7tpNgI06voZYv8w734uuwNvg115tBPg0+eeEfrgGpP38S9V0pTh/qJDb OTyXDFSLUnvZZx6cdCP935eySSDaey8xo21Gd8jUe7jX2YUWZqoHZSjnHgu+OmMEOiS6 yLLWWR6OW/KS9drQV0zKbFXuVWUlOjmNvNAQCEe/MyO4P7EjCsDZkSFDGEs8CBFS7zM2 yy9ZPGrqkpwVL1adpJM/jUY/IceIRnWbNHf1E83fNDuy/JWnPR08Xu9A9R/DSVmCDgeV gDlQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772563626; x=1773168426; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=oMq1lhjEuef5erMXhpz5bzkhXZNyHyRcJxuf0wDNgtQ=; b=LXHXhunMKQavKxek7Or15QpRuhUG7DdYJyYzRddwuCNONh72Z+QFKzyREReNA3IDhA mdnfTWMZaNIzPoIhLu4gO3WLLV8IBPpeARHGNmsCh4E3xryLngw/s+MpiWNAucc14wqQ F2hcNxlyDiZV9Uf02h1drhr9d/moCy17ARsiQvxNKaRcOWbyRpNuN5n+i7UtGiZw1Yk5 WlAp1USjOZk6ICbv4kinldQ3GhikuLLcU4gIEEhwZVCe+JLmA5r8bZ5ta7GRW2YX4cKJ 5NJ97YHZA4dTx8jrNDP0sLM5ZDnKu8K8oVkMoZ8QQxlrWzsUazn+/4HwhUpKYJoxdhIN anmA== X-Forwarded-Encrypted: i=1; AJvYcCUdUqLy/ge2boa2Nz977QApX6qTgKNyZ1K2xTV41Co01RTbOhfMMnqmUOUy4sMp1tatTn2jzfOo6wOrmg/fP1QYTaNMhA==@freebsd.org X-Gm-Message-State: AOJu0Yxb6fsCp4U73mufHgndqNRbqv4+N78cZfc63bmQJzaNICAYDPmO t1SQ9Q9x7rXfINnjcxakVj42ZgV+1ZxL11+29XzR2UHt9XrZIz3zL+7E6d4YtGV26pR3oG+r4Kq MLH9NTUJASvsO95NKgh+xoFQ6hStoPNE2vmebkiNiWg== X-Gm-Gg: ATEYQzwXQBfKSbcHoP4AejTkWfMX/45F872ac84ImFKDdK1IeQWDqIu18Q4H7mCng5E AtbHEJ0RFO9hSrGAVwOw+yr43NsB51aCqNs89isgwNW5yt+ivo89vMkmE7jKsms5pG5vHlgXvZA xFEV4TndKspB+T7Jkt8AGIhbJ5TwLChPsEPM0ktm8/Q/wA0Hq4W7T8YrQzixaL/X23U++BSU8sw 4MYB+QF6qHBeo8Sxq70kdXWW2NagFcgsIA9zzha9tvJxe09Xawc5OwjuNYM0OEnXeICGWww44JM lE9BW2k= X-Received: by 2002:a17:90b:2496:b0:359:7d76:5ead with SMTP id 98e67ed59e1d1-3597d765fe6mr7801114a91.3.1772563626379; Tue, 03 Mar 2026 10:47:06 -0800 (PST) List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 References: <69a678f3.3f811.148b0d7d@gitrepo.freebsd.org> In-Reply-To: From: Warner Losh Date: Tue, 3 Mar 2026 11:46:54 -0700 X-Gm-Features: AaiRm52H5II1DpgyXi46Ppbj8O047QxIkqjOt5f8t-8ha9l_ToPEAsnsnIgmsHA Message-ID: Subject: Re: git: 912864912b71 - main - Run `make obj` before running `make test-includes` To: "Enji Cooper (yaneurabeya)" Cc: Brooks Davis , Enji Cooper , src-committers , "" , "" Content-Type: multipart/alternative; boundary="0000000000004ad9b0064c2321a5" X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated 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-Queue-Id: 4fQPt347nDz3T9K X-Spamd-Bar: ---- --0000000000004ad9b0064c2321a5 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, Mar 3, 2026 at 11:17=E2=80=AFAM Enji Cooper (yaneurabeya) < yaneurabeya@gmail.com> wrote: > > > On Mar 3, 2026, at 4:22=E2=80=AFAM, Warner Losh wrote: > > > > On Tue, Mar 3, 2026 at 5:18=E2=80=AFAM Brooks Davis wrote: > > On Tue, Mar 03, 2026 at 04:25:48AM -0700, Warner Losh wrote: > > > On Mon, Mar 2, 2026, 11:00???PM Enji Cooper wrote: > > > > > > > The branch main has been updated by ngie: > > > > > > > > URL: > > > > > https://cgit.FreeBSD.org/src/commit/?id=3D912864912b71951f9a636190b1dba80= 528f588eb > > > > > > > > commit 912864912b71951f9a636190b1dba80528f588eb > > > > Author: Enji Cooper > > > > AuthorDate: 2026-03-03 05:59:50 +0000 > > > > Commit: Enji Cooper > > > > CommitDate: 2026-03-03 05:59:56 +0000 > > > > > > > > Run `make obj` before running `make test-includes` > > > > > > > > Before this change, `make test-includes` (run as part of > buildworld) > > > > would place test files in the current directory, which would > clutter up > > > > git clones. Run `make obj` beforehand to ensure that the files > are put > > > > in `${.OBJDIR}` instead of `${.CURDIR}`. This helps cut down on > the > > > > noise significantly when running commands like `git status`. > > > > > > > > > > I've never seen this happen. .OBJDIR is created automatically for me > always > > > for the last 5 years... I run buildworld all the time. Can you explai= n > when > > > / how it happens more specifically or back out the change? > > > > The commit message is unintentionally misleading and incomplete. I hit > > the problem a week or so ago when fixing gcc12 builds and lacked the > > time to follow up. test-includes is fine as part of buildworld, but > > when run directly from src does fill tools/build/test-includes with .c > > files if you blow away the objdir (which seems to the the only reliably > > way to cause test-includes to retest some more complex cases.) > > > > Ah! That should have been in the commit message as the edge case > > that provoked this. That's a decent explanation, though there's other > > bits of buildworld that will also cause problems if you do them in > isolation > > and not part of buildworld. This one, though, is important enough to ma= ke > > an exception for, I think. It's one that's most likely to be used in > isolation. > > Hi Warner, > > I consistently run into this behavior when doing mfsbsd builds on my > 14.3-RELEASE host using this src.conf: https://reviews.freebsd.org/P702 . > MK_AUTO_OBJ=3Dyes as shown here: https://reviews.freebsd.org/P703 . > > I always run this target as part of buildworld on my 14.3-RELEASE host, s= o > whatever is working on your end is likely an artifact of the build host > environment, whereas what=E2=80=99s not working for me like you expect is= an > artifact of my build host environment. > > This: > > > Before this change, `make test-includes` (run as part of buildworld) > > would place test files in the current directory, which would clutter up > > git clones. > > > Could more accurately be expressed like this: > > > Before this change, `make test-includes` (run as part of buildworld) > > would place test files in the current directory on my 14.3-RELEASE > > build host, which would clutter up git clones. > > > The exact reason why there=E2=80=99s a difference eludes me right now. > The likely reason is that you explicitly ran `make test-includes` without first running `buildworld` to create the objdir. As part of buildworld, it always creates the right thing. Or there's some other partial evaluation. That's the only way I could recreate it, and only if I turned off metamode. PS I was waiting for a response to the Differential for over a week; I > landed the change because I hadn=E2=80=99t received feedback on the revie= w in that > period of time and because it gets really old quickly having to always do > `git status -uno` in my clones to make sure I=E2=80=99m not accidentally = committing > things that shouldn=E2=80=99t be committed. This is especially annoying w= hen doing > rebases with my =E2=80=9CMac=E2=80=9D dev branch because it has a lot of = overlapping > sections of code in asmc(4) and thunderbolt(4). Yea, you didn't ping me on it. I've got a lot going on... There's a lot of requests with my name on it and w/o an explicit ping, I can often miss them. It's not wrong, per se, but the commit message was incorrect and overly broad. Brooks showed me a way to recreate it, which I did, but I couldn't otherwise create this with either meta mode on or off. I doubt that cross-version builds would cause it too, but I suppose it might. I do get the annoyance. And it all worked out: I found a way to trigger this, even if it isn't what you are hitting. Warner --0000000000004ad9b0064c2321a5 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Tue, Mar 3, = 2026 at 11:17=E2=80=AFAM Enji Cooper (yaneurabeya) <yaneurabeya@gmail.com> wrote:

> On Mar 3, 2026, at 4:22=E2=80=AFAM, Warner Losh <imp@bsdimp.com> wrote:
>
> On Tue, Mar 3, 2026 at 5:18=E2=80=AFAM Brooks Davis <brooks@freebsd.org> wrote:=
> On Tue, Mar 03, 2026 at 04:25:48AM -0700, Warner Losh wrote:
> > On Mon, Mar 2, 2026, 11:00???PM Enji Cooper <ngie@freebsd.org> wrote:
> >
> > > The branch main has been updated by ngie:
> > >
> > > URL:
> > > htt= ps://cgit.FreeBSD.org/src/commit/?id=3D912864912b71951f9a636190b1dba80528f5= 88eb
> > >
> > > commit 912864912b71951f9a636190b1dba80528f588eb
> > > Author:=C2=A0 =C2=A0 =C2=A0Enji Cooper <ngie@FreeBSD.org&= gt;
> > > AuthorDate: 2026-03-03 05:59:50 +0000
> > > Commit:=C2=A0 =C2=A0 =C2=A0Enji Cooper <ngie@FreeBSD.org&= gt;
> > > CommitDate: 2026-03-03 05:59:56 +0000
> > >
> > >=C2=A0 =C2=A0 =C2=A0Run `make obj` before running `make test-= includes`
> > >
> > >=C2=A0 =C2=A0 =C2=A0Before this change, `make test-includes` = (run as part of buildworld)
> > >=C2=A0 =C2=A0 =C2=A0would place test files in the current dir= ectory, which would clutter up
> > >=C2=A0 =C2=A0 =C2=A0git clones. Run `make obj` beforehand to = ensure that the files are put
> > >=C2=A0 =C2=A0 =C2=A0in `${.OBJDIR}` instead of `${.CURDIR}`. = This helps cut down on the
> > >=C2=A0 =C2=A0 =C2=A0noise significantly when running commands= like `git status`.
> > >
> >
> > I've never seen this happen. .OBJDIR is created automatically= for me always
> > for the last 5 years... I run buildworld all the time. Can you ex= plain when
> > /=C2=A0 how it happens more specifically or back out the change?<= br> >
> The commit message is unintentionally misleading and incomplete.=C2=A0= I hit
> the problem a week or so ago when fixing gcc12 builds and lacked the > time to follow up.=C2=A0 test-includes is fine as part of buildworld, = but
> when run directly from src does fill tools/build/test-includes with .c=
> files if you blow away the objdir (which seems to the the only reliabl= y
> way to cause test-includes to retest some more complex cases.)
>
> Ah! That should have been in the commit message as the edge case
> that provoked this. That's a decent explanation, though there'= s other
> bits of buildworld that will also cause problems if you do them in iso= lation
> and not part of buildworld. This one, though, is important enough to m= ake
> an exception for, I think. It's one that's most likely to be u= sed in isolation.

Hi Warner,

I consistently run into this behavior when doing mfsbsd builds on my 14.3-R= ELEASE host using this src.conf: https://reviews.freebsd.org/P702 . MK_AUTO_OBJ=3Dyes as shown here: https://reviews.freebsd.org/P70= 3 .

I always run this target as part of buildworld on my 14.3-RELEASE host, so = whatever is working on your end is likely an artifact of the build host env= ironment, whereas what=E2=80=99s not working for me like you expect is an a= rtifact of my build host environment.

This:

> Before this change, `make test-includes` (run as part of buildworld) > would place test files in the current directory, which would clutter u= p
> git clones.


Could more accurately be expressed like this:

> Before this change, `make test-includes` (run as part of buildworld) > would place test files in the current directory on my 14.3-RELEASE
> build host, which would clutter up git clones.


The exact reason why there=E2=80=99s a difference eludes me right now.
<= /blockquote>

The likely reason is that you explicitly ra= n `make test-includes` without first running `buildworld` to create the obj= dir. As part of buildworld, it always creates the right thing. Or there'= ;s some other partial evaluation. That's the only way I could recreate = it, and only if I turned off metamode.

PS I was waiting for a response to the Differential for over a week; I land= ed the change because I hadn=E2=80=99t received feedback on the review in t= hat period of time and because it gets really old quickly having to always = do `git status -uno` in my clones to make sure I=E2=80=99m not accidentally= committing things that shouldn=E2=80=99t be committed. This is especially = annoying when doing rebases with my =E2=80=9CMac=E2=80=9D dev branch becaus= e it has a lot of overlapping sections of code in asmc(4) and thunderbolt(4= ).

Yea, you didn't ping me on it. I'= ;ve got a lot going on... There's a lot of requests with my name on it = and w/o an explicit ping, I can often miss them. It's not wrong, per se= , but the commit message was incorrect and overly broad. Brooks showed me a= way to recreate it, which I did, but I couldn't otherwise create this = with either meta mode on or off. I doubt that cross-version builds would ca= use it too, but I suppose it might.=C2=A0

I do get= the annoyance. And it all worked out: I found a way to trigger this, even = if it isn't what you are hitting.

Warner
=
--0000000000004ad9b0064c2321a5-- From nobody Tue Mar 3 19:25:11 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQQk353Gzz6TWhH; Tue, 03 Mar 2026 19:25:15 +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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQQk34DvDz3Z73; Tue, 03 Mar 2026 19:25:15 +0000 (UTC) (envelope-from bz@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772565915; 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=mBnaKboyQ7Z6F3LqrJI3uQdaPpV6hYhoCHXKJ174LRI=; b=y0Y7oVYErVTw7Ib/iL1IyBFTAAUaZbjzM6OX+SJ/7C3W7J7ON0M1w4gFTtxCuDHCAlyzoN MohneeKI6jLA299YS4tu94E4Z7DRBRqq06M0jkxov2rVeTvVEBa8qLb6dUN50nagk16XdX lRzTQqXBBIoklXcxOKwyy3Yk/ctFDCv2PCbFmQBNEuwQonSy92HaeqM+kLjqHFTDFSoDii Va9mvYRmgYaYpUcMK1mWQm16etbDMESw8aXv+NCsS3keoy3uBfilLKfRNfISL8YfhPVwsX TCytiAVxjHeiq7QRT0QX1gkM2dxyWouPQdiQbncsTwAd03cqC+NBupfUDUAByA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772565915; a=rsa-sha256; cv=none; b=Vpc8LdUSfdU72snzYvVbX96IAjYdqhgDKZmn6D7AtdBo2PyEvPaa8NfMEGHkIuPZmwZ9Jh qYg0/ACTZoADG4OX3aO1wperpmCUJVki9D4bTi5OW22HukDAUOwe0RbI6d8JAsMxnXsFww A9KV9Hf1I+rwEEoE16Opt2G6P2jCt0woUmwZO25nALLHoQA8YtmzL5AZTxW6zdo97h+x37 DbHCo2ountp5CSb8oQW5HGnrsTEdL1ZrVNOCob8mkSsu4kizMvM1R9gCHUh2BJnkh8x9Vs lBR75RkqdTnGV8cLJc9slV7qJ6Jirb9UyNOrXGiybhI9Z+oT45vdbKynqRdp8w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772565915; 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=mBnaKboyQ7Z6F3LqrJI3uQdaPpV6hYhoCHXKJ174LRI=; b=IFgCuNFzsTjUPtmwROyVPjBRGHBkQyWkeOe35OmyPl9GseVkVeHcAdxMVabIRkCq/mt7RP i7FUgWVKoCNQ+C6PdmR9SElQ13Ev/Xs7LGF2QkcFGVlV5M62+vaOPDtC2KpKYLwq5c+G0a SW+mo1BQpDKyu1thPN/E4PQhwtVCjJUwe6HVaTC2VHHcMh4P05lZu22fmHbcujyr/e5Jc6 wZXCExoXM+GDqArao1bDgXPUnNF9j3G7uneWvhmHp9WEo1ETSKxzhe98Y99+nrUJIo63ui a2RJGZIiKB+yESxZl/g5b0bYHEfvqxzGYSRHHdWkWK/Nftr420ujw9xyRhtPXQ== Received: from mx-01.divo.sbone.de (legacy1.sbone.de [80.151.10.34]) (using TLSv1.3 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 "E7" (not verified)) (Authenticated sender: bz/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4fQQk32G0pzkVm; Tue, 03 Mar 2026 19:25:15 +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 712C5A64806; Tue, 03 Mar 2026 19:24:54 +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 86DDC2D029E7; Tue, 3 Mar 2026 19:25:13 +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 yZT96Hvrjz1a; Tue, 3 Mar 2026 19:25:12 +0000 (UTC) Received: from nv.t4-02.sbone.de (nv.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:22]) (using 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 0B92F2D029D8; Tue, 3 Mar 2026 19:25:12 +0000 (UTC) Date: Tue, 3 Mar 2026 19:25:11 +0000 (UTC) From: "Bjoern A. Zeeb" To: Warner Losh cc: Enji Cooper , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: c47cefba8312 - main - Only build USB-related modules if MK_USB != no In-Reply-To: Message-ID: <947orn62-43rq-383n-son8-90o6q2275os6@serrofq.bet> References: <69a668aa.3785e.4a16f236@gitrepo.freebsd.org> <1s9oq316-3q4o-9273-3qos-3n3o793ns725@mnoonqbm.arg> X-OpenPGP-Key-Id: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="0-1526680494-1772565912=:11296" This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --0-1526680494-1772565912=:11296 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8BIT On Tue, 3 Mar 2026, Warner Losh wrote: > On Tue, Mar 3, 2026 at 11:29 AM Bjoern A. Zeeb wrote: > >> On Tue, 3 Mar 2026, Enji Cooper wrote: >> >>> The branch main has been updated by ngie: >>> >>> URL: >> https://cgit.FreeBSD.org/src/commit/?id=c47cefba831240a1b3de375f18134b93cf998f5c >>> >>> commit c47cefba831240a1b3de375f18134b93cf998f5c >>> Author: Enji Cooper >>> AuthorDate: 2026-03-03 04:49:54 +0000 >>> Commit: Enji Cooper >>> CommitDate: 2026-03-03 04:50:03 +0000 >>> >>> Only build USB-related modules if MK_USB != no >>> >>> This change moves the thunderbolt module and other USB modules under a >>> MK_USB != no conditional to ensure that users not desiring USB support >>> can easily build systems without USB-specific drivers using this knob. >>> >>> MFC after: 1 week >>> Reviewed By: imp >>> Differential Revision: https://reviews.freebsd.org/D55576 >>> --- >>> sys/conf/kern.opts.mk | 5 +++++ >>> sys/conf/kmod.mk | 8 ++++++-- >>> sys/modules/Makefile | 16 ++++++++++------ >>> 3 files changed, 21 insertions(+), 8 deletions(-) >> >> There is a hige load of further devices which depend on USB which are not >> part of the current set excluded; I assume they will now break with >> dependency >> issues if USB is no longer built but these modules are built. >> >> Is there any plan to also "hide" all the other modules? >> > > As I said in my review, I'm generally uneasy about this trend... I never got that far as the review diff I looked at was broken at that point. This may also be wrong: % ls -l tools/build/options/*USB* -rw-r--r-- 1 bz bz 49 Mar 21 2025 tools/build/options/WITHOUT_USB -rw-r--r-- 1 bz bz 40 Mar 21 2025 tools/build/options/WITHOUT_USB_GADGET_EXAMPLES -rw-r--r-- 1 bz bz 33 Mar 21 2025 tools/build/options/WITH_USB_GADGET_EXAMPLES % cat tools/build/options/WITHOUT_USB Do not build USB-related programs and libraries. Usually we used to have a FOO_SUPPORT which would then also not build kernel modules or not build FOO suport into (programs, libraries, and) kernel modules, e.g. INET, INET6, NETGRAPH. Though, unless INET and INET6 started to become loadable seems wrong these days and I'd use a check based on the kernel config (which I believe came years later as an option) and remove the entire MK_INET[6]_SUPPORT checks for the kernel. The NETGRAPH example is a bad one as it seems to be unimplemeted for the kernel side so NETGRAPH_SUPPORT description is misleading. USB tends to be more tricky as it is fully loadable but then then answer for people who don't want a system supporting USB would mean removing all the modules (which we cannot do based on the kernel config). The question then remains whether a src.conf based knob is the right thing and which one it should be. MK_USB seems wrong but more knobs do not make it better as we have too many of them these days if you ask me. The answer may simply be to rm the modules if a system does not want/need them. I kind-of see that as a rare special-case problem and if someone really needs to ship a system like that then they may have to go the extra length and maintain that bit? If we were really to support this in the build system then we should make sure that all USB modules are no longer build. Given I had my fingers in the USB modules list (though not the full one) recently "uneasy" is maybe not enough for the feeling in my stomach. /bz -- Bjoern A. Zeeb r15:7 --0-1526680494-1772565912=:11296-- From nobody Tue Mar 3 19:26:07 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQQl85rS3z6TX3X for ; Tue, 03 Mar 2026 19:26: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQQl83sL5z3ZdP for ; Tue, 03 Mar 2026 19:26:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772565972; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zZ4rp2JBojvXB0j6kEAcwDBo1s5GWuKc4Eb8pRIWJ+4=; b=JpYyJoSuG1YETCdPzaYCNK8Tgo7OhBzvVeqF5zdt7WVCW0ZjslL8pa6BqBiZK2G54ZBW1Z DZxWtN0L8hh4CMF4UvL5MxciHvihgbSskXve8S5sZe1F2huVb1U4Vqne3N3ax1MQ1NOBdv ttr+BX4Md4TUyJeExCnhnrhHj26GiREIICtLl7IMfunxl7PiMtWyBUBpFKnPhofFbve5Nz mrZ6MZoZak4OCmHSp9ITOuLP2XHth8wveISQSaYnFaRmErohV8RdBPaEByvEh+YewEoQ8A IVl4JRs1+wHQpKcTzEwwqnfQk4A6b+4OxuR+zl92hFPxgXVZUkX4OgdUQ8Xvzw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772565972; a=rsa-sha256; cv=none; b=Ouf/6XRMg2QJ56W7b772j94EzPFSbHzA6mGnKDdldil13fckCU0d9HnQ1VG4PvZguzq4kc cTAmsxr3clPYA8EtXZHNeBdUKwkQplegklFGXcy39kIdwBNNy1IZlfD0mSfFYYJJpvB73b NE1IrDZ8uFdTtJusrVon889rVrQaKVch/WCROUhKsh89Xu4aB93FJhwDzxoK/ZnIskY7W2 BK2VgA8O6F2XwGr8Ksc58mZrIyuHF6Uu7I6vM2j1FDAsrONvvwnkrRqvDjE+CxrUPNGVsM 2zyqpWO7E3C1ju8UPInBoaSsGOq2aeTs8OaRqjfuD46seZLld9tNN42CCQ0GvA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772565972; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zZ4rp2JBojvXB0j6kEAcwDBo1s5GWuKc4Eb8pRIWJ+4=; b=sMDjArri3CUMuzttRW9qtfAcfXDKU7E7ntA0EaYX/BRN2jy5HAyflDLLKfj1djFdMTDLwo swLcdzoti3RccDl12qo3HwUuQLd9ewx1L8/GEJNjp9WU44sJWTNUTSsDAmDUzCoMWKvwIj bB54+5g8AIA/kUIuuza4axNuI6QbcqjHw/lUX4yZ2JmBEjvPK5zqaXXW+sQQaTEA7DsNf5 H3y3agLthOR1gnBuT6mgkMCrYCCET/3ge4bKoAIjlwCM+FHh3TJg9zVkx7DqAHelcP0amK igGWpnxi5i+E11U4U+ggqRzohu2GM51vr00vjIWgHirtWIdf96kx7yT4TY7qMw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQQl82br7z3DB for ; Tue, 03 Mar 2026 19:26:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1c359 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 19:26:07 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Siva Mahadevan Subject: git: f26cb4757eb7 - main - LinuxKPI: avoid -Werror=unused-value in sort() from BUILD_BUG_ON_ZERO() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: siva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f26cb4757eb74ceace39144933ae198ebf1b4f28 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 19:26:07 +0000 Message-Id: <69a735cf.1c359.19b4d8ff@gitrepo.freebsd.org> The branch main has been updated by siva: URL: https://cgit.FreeBSD.org/src/commit/?id=f26cb4757eb74ceace39144933ae198ebf1b4f28 commit f26cb4757eb74ceace39144933ae198ebf1b4f28 Author: Siva Mahadevan AuthorDate: 2026-03-03 19:09:35 +0000 Commit: Siva Mahadevan CommitDate: 2026-03-03 19:19:32 +0000 LinuxKPI: avoid -Werror=unused-value in sort() from BUILD_BUG_ON_ZERO() The BUILD_BUG_ON_ZERO() macro returns an (int)0 if it does not fail at build time. LinuxKPI sort() has it as a guard for an unsupported argument but ignores the return value. This leads to gcc complaining: /usr/src/sys/compat/linuxkpi/common/include/linux/build_bug.h:60:33: error: statement with no effect [-Werror=unused-value] 60 | #define BUILD_BUG_ON_ZERO(x) ((int)sizeof(struct { int:-((x) != 0); })) | ^ /usr/src/sys/compat/linuxkpi/common/include/linux/sort.h:37:9: note: in expansion of macro 'BUILD_BUG_ON_ZERO' 37 | BUILD_BUG_ON_ZERO(swap); \ | ^~~~~~~~~~~~~~~~~ /usr/src/sys/contrib/dev/rtw89/core.c:2575:9: note: in expansion of macro 'sort' 2575 | sort(drift, RTW89_BCN_TRACK_STAT_NR, sizeof(*drift), cmp_u16, NULL); Change to BUILD_BUG_ON() for the statement version. Reported by: CI Co-authored-by: bz Approved by: emaste (mentor) MFC after: 3 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55634 --- sys/compat/linuxkpi/common/include/linux/sort.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/include/linux/sort.h b/sys/compat/linuxkpi/common/include/linux/sort.h index e6196d1f41c7..361b37c587c8 100644 --- a/sys/compat/linuxkpi/common/include/linux/sort.h +++ b/sys/compat/linuxkpi/common/include/linux/sort.h @@ -34,7 +34,7 @@ #include #define sort(base, num, size, cmp, swap) do { \ - BUILD_BUG_ON_ZERO(swap); \ + BUILD_BUG_ON(swap); \ qsort(base, num, size, cmp); \ } while (0) From nobody Tue Mar 3 19:44:15 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQR7z6HXTz6TXY0 for ; Tue, 03 Mar 2026 19:44: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQR7z5hdHz3cFx for ; Tue, 03 Mar 2026 19:44:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772567055; 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; bh=W2JYvjus7z7bZA/gD1CECaerFQrJxDEyhsUQ8Uq6gGg=; b=wVsqtEu2qT/vGSvk8wI2JTc/dQ6JnC/67a8+9Efr+sQze+S7d0zDMmg8nruLUC7WhXLJQl X4txeeG91A3ht6Km6UhszxAXUud/NEYbSB5igY/vv1GgemOLGLpTVFzE0aAMR4nEvQtLJV Nx4EvoTXCzQCLo5W7I5slUMwpLVPRsZSelUg9vkxIijflqAHP30q6lVkeIiuU8xJwjhPaf yBph9sYSnNzTw5VokMN4YgpCHHF5UE2SFMwhQLfEsrKhfhsTfmtEE/JGN+jDTlzwRowK7X U4prp76RgLzzIQMEISQ1SSDBu+qwaWeQKPGgFbviIbTaEdj9ZC3mrNeogI5E/w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772567055; a=rsa-sha256; cv=none; b=VkwTZwjJCU5SZeHHGMxtMC363zFtp+ZNlYZ1xgFdnkndHnNqNtMytKpTZik8ksc37GH2FN 5IPMHaHQNNKLrS1TZ6j2J8uET/KX7M9/lxAixWlwpLYhh4noCwI1vPl/IXFLaPd02N2L4x TAIa3kdjec6vAQJucJ7XekE9gOOOqlBkfjOgfolkXMHghIx+JohYVGgRkFrimadotLPVF6 7RmCFxBVl/uGAN+dj+s+yVL5fGx1T10GVBZ96ojVoU8HKlPKqFCLYMo8kOMJyhX5tnHmtg NR6iQqX/dev4jDXLqulhvnj6o5dAD9bWw4iqP5yh4wFW4kTw7v3TvEvjnliu/Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772567055; 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; bh=W2JYvjus7z7bZA/gD1CECaerFQrJxDEyhsUQ8Uq6gGg=; b=CpdQmle383BqoBPhUErsPSiAuZauVpUI6AdXYqN06SQYztOhy1N6MS0PFjK0cfpD0RGmue enGBcNRQtuyPdhmm99roj7xlO5sD9XgacKGPhU3HHFUr+mta5wD75zmVkgx6U9diATwwbP 0aG0BPEoh/w4bWFjt/oLs7VcdDq8MYrkuhu/WWKRX7PCHGtERgmyv5Vo/sFbNyxmEDy/wu R6tMzsjKVSy0EfbpVbWXOaatboItgDxCkDf4AsB+dlwfuJ72nBmBf5MhprjcjEGa38YrLW VUWwrAbhd3QCQwxCAksPuFmmtkiI8lt2LCJn5bOzlUueQ384pet9pSTo3dGcqg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQR7z4lvwz3hC for ; Tue, 03 Mar 2026 19:44:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1d37f by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 19:44:15 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Tuukka Pasanen From: Ed Maste Subject: git: 5778700fb8c5 - main - diff3: Add SPDX-License-Identifier tag List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 5778700fb8c54a33e5bb00a4a0c4e40fde2edbd9 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 19:44:15 +0000 Message-Id: <69a73a0f.1d37f.6cae5f5b@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=5778700fb8c54a33e5bb00a4a0c4e40fde2edbd9 commit 5778700fb8c54a33e5bb00a4a0c4e40fde2edbd9 Author: Tuukka Pasanen AuthorDate: 2026-02-12 09:27:34 +0000 Commit: Ed Maste CommitDate: 2026-03-03 19:43:21 +0000 diff3: Add SPDX-License-Identifier tag Reviewed by: bapt Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55462 --- usr.bin/diff3/diff3.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/usr.bin/diff3/diff3.c b/usr.bin/diff3/diff3.c index 0f114163321f..d85a5da94b10 100644 --- a/usr.bin/diff3/diff3.c +++ b/usr.bin/diff3/diff3.c @@ -1,6 +1,8 @@ /* $OpenBSD: diff3prog.c,v 1.11 2009/10/27 23:59:37 deraadt Exp $ */ /* + * SPDX-License-Identifier: Caldera-no-preamble AND BSD-3-Clause + * * Copyright (C) Caldera International Inc. 2001-2002. * All rights reserved. * From nobody Tue Mar 3 19:47:16 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQRCk2f24z6TXlg for ; Tue, 03 Mar 2026 19:47:30 +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 4fQRCj6j5Qz3cfv for ; Tue, 03 Mar 2026 19:47:29 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pj1-x1036.google.com with SMTP id 98e67ed59e1d1-358d80f60ccso2761974a91.3 for ; Tue, 03 Mar 2026 11:47:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1772567247; cv=none; d=google.com; s=arc-20240605; b=cSjwGXYPVaLRsnKfmCUD9xqZmAiPu6rUQIR2nxAeBoPPyn31qj6C86z85+kpB7s5ji qMfJsCPBir+mEuI3vn82E8Q+7YiQt75AvnD7vY4cClgBiLAwdheDD+I6q46OKJJD+p4T CmNbt0RomviQpmkshXePg+XASHtHV/aKmbCx5SZnibtT/Ve6Dz3BACo83mYq/znCT1Yf Z/FIKWAt9pH5/67dUqj0r+D2VUFufYbLD3+mmgjUIbmk7bjl96NVi7RL51r2zc0YZDn0 Wb0FFPIt/Sr9updSD4CCSVxtzkqPTZbBy9SPkOfRQ+U/1zMXl7ahNfVPJ/9DUJ3yw/ZB ZZrA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=e82ujAwuZLVXawVXxQHQjNxiqL+TXMIyJ+3YKj6n/Gg=; fh=MNXipXUQ83Uw4F+RpnfLqHzq/29+GFdibcTvIvgWwdQ=; b=cwu18FRMdQwkGJRaJOSRTWQcqYbOuwrGGRmp53rzqrIeSNeKn6Iar4Z9qNwT82wR6y 6Sb37UdeGX50XoSdk1c3GE6TdYp3yiBRHAODsrKSO4dYH2brfX7q5I+acgQfnW6qRtso mP+30ZJCcoKTL+glg1iUBA7saSiW0gmc51vV2XcFddJBIE/OorL+g58OJjffnAg632Oc Eu63y6cNKYeBaePvzCnKIX+p/5nUnQK6IeS8g4uYiekNf24K7zYehc9jDVXNZ9pSoHWU uLhyPbZfQm3cGtp8q/r4W2h20h3BjzEGE9ihZSGl4yBg1j4BTRbJS1rX/1KrrC+YH/A1 DlwQ==; darn=freebsd.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1772567247; x=1773172047; 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=e82ujAwuZLVXawVXxQHQjNxiqL+TXMIyJ+3YKj6n/Gg=; b=yRW0uyWcsk6cxZos9l/ormUVMQSz01dyfQ7dvb2i1QzmGqTKM6GLUTl5H1IsTZcjZ3 S3JZV7titpldoufMcGBqU25zH37a5qdQlcBdmvPMDYmOAzY/aVxh3aZI/YuzcIMspDGF CMEwvBRan1bC+oxqePPT4jknWN4VqHRZe2gDqChZTclWpfF3ykkg3ID66qnOxakBJLmY gBwG/tyi0PIthkE6vv8p1hA5wIEoDxpJ/fFWMgizKghTjVgBrtFKg2DGXV0BM7mcXx/G VZF26VWrlY1zZsPSZp8fuSh13P8mQG4fQ0+11B0gOacS+PMGV8W5kkRgrwPRiwS42OFP zIMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772567247; x=1773172047; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=e82ujAwuZLVXawVXxQHQjNxiqL+TXMIyJ+3YKj6n/Gg=; b=h+8poY+Irv6Q5pwp9t9IsPkyikPG8pBwajBzcPBe7QE0k8fXKnifnuFLAgI1hZ9lTA HVehmq3uMSfmt0ORQf57oK2ZPR0wJ2ZZLkq30biJnK52CVaTe7iGvrMiH6lDW+qSPieQ crMYbl9O8sqwehA9hxC6HFJSbYjdaDK1A9c8oLWjzARU7LhlOKUuWMzAKXzKdzjdv08I FqF+TLbDTMTXUi2N9kAoh+A1J80jN4w7uR8mu4P4QZQdd0G66hVonroKuCdRXkBc6CL2 0K3CY+hDRWsix33hPm1qvCT0UxAsjusiXkEGpxzrrJ4uGBGw4Po7F3qMa9syIxvGEVpN emKQ== X-Forwarded-Encrypted: i=1; AJvYcCXXjg5HRTFTCLI+URwsf3khc0/yYpJYKWJs8btGg3As4+Yrq3fhB7qgh3ySHxE0p3IbfE6/q4ldLafQhN3xKKryiNpn7g==@freebsd.org X-Gm-Message-State: AOJu0YyxwWZpLxWn0TeHPZPUG7RDXWZu0Q1f0bV6VKJEpLm4hRCWPNZu r+G7s+WlixUE7V2my3P3AfTACNrYaOjth8TAcPMV/3diuSuWP5tTbXYSM6sDtUOcIhT15N/WmKl c5R7nsXFpBl9B5ysM62pASIeFw3oeNqM5KN03umAEzA== X-Gm-Gg: ATEYQzy+hc0sdrTl8hVy2HmDGyOVEC2kJdbU2SwFI+nLJZXyFgP/J5rq3ILOP4XxHVN RNhbooonFraa7a37LMvhYdHV0NwnsURkYJE+bn+c5LaXyqjDEmihtDDZrhmTGX8Z+prngO53Rhi V1uhc2IUYoB/+h2O/ck52NRzQi939qFRDaGvjc09k866BQF4WtD57KLhlCzAUWxnjsQVD9nyBgS aICkkhfetpj6f5vEwNMj+4B+Pu+4njZeDtvjYuMqLn3+mwagv/CUYBUsaNuiBsy7HOxUNHBu58j 61nW0hAjmON5sJUDDA== X-Received: by 2002:a17:90b:2ecd:b0:359:9b45:7754 with SMTP id 98e67ed59e1d1-3599b4587b7mr2906989a91.32.1772567247129; Tue, 03 Mar 2026 11:47:27 -0800 (PST) List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 References: <69a668aa.3785e.4a16f236@gitrepo.freebsd.org> <1s9oq316-3q4o-9273-3qos-3n3o793ns725@mnoonqbm.arg> <947orn62-43rq-383n-son8-90o6q2275os6@serrofq.bet> In-Reply-To: <947orn62-43rq-383n-son8-90o6q2275os6@serrofq.bet> From: Warner Losh Date: Tue, 3 Mar 2026 12:47:16 -0700 X-Gm-Features: AaiRm53Zv_tKorRK-ITXGCK2iLNbhnoxjz7oT4KC0khoMQy3jRReZIYIIZx_ELo Message-ID: Subject: Re: git: c47cefba8312 - main - Only build USB-related modules if MK_USB != no To: "Bjoern A. Zeeb" Cc: Enji Cooper , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: multipart/alternative; boundary="0000000000001b1ce5064c23f90e" X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated 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-Queue-Id: 4fQRCj6j5Qz3cfv X-Spamd-Bar: ---- --0000000000001b1ce5064c23f90e Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, Mar 3, 2026 at 12:25=E2=80=AFPM Bjoern A. Zeeb wro= te: > On Tue, 3 Mar 2026, Warner Losh wrote: > > > On Tue, Mar 3, 2026 at 11:29=E2=80=AFAM Bjoern A. Zeeb = wrote: > > > >> On Tue, 3 Mar 2026, Enji Cooper wrote: > >> > >>> The branch main has been updated by ngie: > >>> > >>> URL: > >> > https://cgit.FreeBSD.org/src/commit/?id=3Dc47cefba831240a1b3de375f18134b9= 3cf998f5c > >>> > >>> commit c47cefba831240a1b3de375f18134b93cf998f5c > >>> Author: Enji Cooper > >>> AuthorDate: 2026-03-03 04:49:54 +0000 > >>> Commit: Enji Cooper > >>> CommitDate: 2026-03-03 04:50:03 +0000 > >>> > >>> Only build USB-related modules if MK_USB !=3D no > >>> > >>> This change moves the thunderbolt module and other USB modules > under a > >>> MK_USB !=3D no conditional to ensure that users not desiring USB > support > >>> can easily build systems without USB-specific drivers using this > knob. > >>> > >>> MFC after: 1 week > >>> Reviewed By: imp > >>> Differential Revision: https://reviews.freebsd.org/D55576 > >>> --- > >>> sys/conf/kern.opts.mk | 5 +++++ > >>> sys/conf/kmod.mk | 8 ++++++-- > >>> sys/modules/Makefile | 16 ++++++++++------ > >>> 3 files changed, 21 insertions(+), 8 deletions(-) > >> > >> There is a hige load of further devices which depend on USB which are > not > >> part of the current set excluded; I assume they will now break with > >> dependency > >> issues if USB is no longer built but these modules are built. > >> > >> Is there any plan to also "hide" all the other modules? > >> > > > > As I said in my review, I'm generally uneasy about this trend... > > I never got that far as the review diff I looked at was broken at that > point. > > This may also be wrong: > > % ls -l tools/build/options/*USB* > -rw-r--r-- 1 bz bz 49 Mar 21 2025 tools/build/options/WITHOUT_USB > -rw-r--r-- 1 bz bz 40 Mar 21 2025 > tools/build/options/WITHOUT_USB_GADGET_EXAMPLES > -rw-r--r-- 1 bz bz 33 Mar 21 2025 > tools/build/options/WITH_USB_GADGET_EXAMPLES > % cat tools/build/options/WITHOUT_USB > Do not build USB-related programs and libraries. > > > Usually we used to have a FOO_SUPPORT which would then also not build > kernel > modules or not build FOO suport into (programs, libraries, and) kernel > modules, > e.g. INET, INET6, NETGRAPH. > > Though, unless INET and INET6 started to become loadable seems wrong thes= e > days > and I'd use a check based on the kernel config (which I believe came year= s > later > as an option) and remove the entire MK_INET[6]_SUPPORT checks for the > kernel. > > The NETGRAPH example is a bad one as it seems to be unimplemeted for the > kernel > side so NETGRAPH_SUPPORT description is misleading. > > > USB tends to be more tricky as it is fully loadable but then then answer > for people who don't want a system supporting USB would mean removing > all the modules (which we cannot do based on the kernel config). > > The question then remains whether a src.conf based knob is the right > thing and which one it should be. MK_USB seems wrong but more knobs do > not make it better as we have too many of them these days if you ask me. > > The answer may simply be to rm the modules if a system does not want/need > them. I kind-of see that as a rare special-case problem and if someone > really needs to ship a system like that then they may have to go the > extra length and maintain that bit? > > If we were really to support this in the build system then we should make > sure that all USB modules are no longer build. > > > Given I had my fingers in the USB modules list (though not the full one) > recently "uneasy" is maybe not enough for the feeling in my stomach. > Given all this, maybe we should revert this change and move the discussion to arch@. The USB vs USB_SUPPORT nails a lot of my uneasiness here. Warner --0000000000001b1ce5064c23f90e Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Tue, Mar 3, = 2026 at 12:25=E2=80=AFPM Bjoern A. Zeeb <bz@freebsd.org> wrote:
On Tue, 3 Mar 2026, Warner Losh wrote:

> On Tue, Mar 3, 2026 at 11:29=E2=80=AFAM Bjoern A. Zeeb <bz@freebsd.org> wrote:
>
>> On Tue, 3 Mar 2026, Enji Cooper wrote:
>>
>>> The branch main has been updated by ngie:
>>>
>>> URL:
>> https://c= git.FreeBSD.org/src/commit/?id=3Dc47cefba831240a1b3de375f18134b93cf998f5c
>>>
>>> commit c47cefba831240a1b3de375f18134b93cf998f5c
>>> Author:=C2=A0 =C2=A0 =C2=A0Enji Cooper <ngie@FreeBSD.org>= ;
>>> AuthorDate: 2026-03-03 04:49:54 +0000
>>> Commit:=C2=A0 =C2=A0 =C2=A0Enji Cooper <ngie@FreeBSD.org>= ;
>>> CommitDate: 2026-03-03 04:50:03 +0000
>>>
>>>=C2=A0 =C2=A0 Only build USB-related modules if MK_USB !=3D no<= br> >>>
>>>=C2=A0 =C2=A0 This change moves the thunderbolt module and othe= r USB modules under a
>>>=C2=A0 =C2=A0 MK_USB !=3D no conditional to ensure that users n= ot desiring USB support
>>>=C2=A0 =C2=A0 can easily build systems without USB-specific dri= vers using this knob.
>>>
>>>=C2=A0 =C2=A0 MFC after:=C2=A0 =C2=A0 =C2=A0 1 week
>>>=C2=A0 =C2=A0 Reviewed By:=C2=A0 =C2=A0 imp
>>>=C2=A0 =C2=A0 Differential Revision:
https://reviews.f= reebsd.org/D55576
>>> ---
>>> sys/conf/kern.opts.mk |=C2=A0 5 +++++
>>> sys/conf/kmod.mk=C2=A0 =C2=A0 =C2=A0 |=C2=A0 8 ++++++--
>>> sys/modules/Makefile=C2=A0 | 16 ++++++++++------
>>> 3 files changed, 21 insertions(+), 8 deletions(-)
>>
>> There is a hige load of further devices which depend on USB which = are not
>> part of the current set excluded;=C2=A0 I assume they will now bre= ak with
>> dependency
>> issues if USB is no longer built but these modules are built.
>>
>> Is there any plan to also "hide" all the other modules?<= br> >>
>
> As I said in my review, I'm generally uneasy about this trend...
I never got that far as the review diff I looked at was broken at that poin= t.

This may also be wrong:

% ls -l tools/build/options/*USB*
-rw-r--r--=C2=A0 1 bz bz 49 Mar 21=C2=A0 2025 tools/build/options/WITHOUT_U= SB
-rw-r--r--=C2=A0 1 bz bz 40 Mar 21=C2=A0 2025 tools/build/options/WITHOUT_U= SB_GADGET_EXAMPLES
-rw-r--r--=C2=A0 1 bz bz 33 Mar 21=C2=A0 2025 tools/build/options/WITH_USB_= GADGET_EXAMPLES
% cat tools/build/options/WITHOUT_USB
Do not build USB-related programs and libraries.


Usually we used to have a FOO_SUPPORT which would then also not build kerne= l
modules or not build FOO suport into (programs, libraries, and) kernel modu= les,
e.g. INET, INET6, NETGRAPH.

Though, unless INET and INET6 started to become loadable seems wrong these = days
and I'd use a check based on the kernel config (which I believe came ye= ars later
as an option) and remove the entire MK_INET[6]_SUPPORT checks for the kerne= l.

The NETGRAPH example is a bad one as it seems to be unimplemeted for the ke= rnel
side so NETGRAPH_SUPPORT description is misleading.


USB tends to be more tricky as it is fully loadable but then then answer for people who don't want a system supporting USB would mean removing all the modules (which we cannot do based on the kernel config).

The question then remains whether a src.conf based knob is the right
thing and which one it should be.=C2=A0 MK_USB seems wrong but more knobs d= o
not make it better as we have too many of them these days if you ask me.
The answer may simply be to rm the modules if a system does not want/need them.=C2=A0 I kind-of see that as a rare special-case problem and if someon= e
really needs to ship a system like that then they may have to go the
extra length and maintain that bit?

If we were really to support this in the build system then we should make sure that all USB modules are no longer build.


Given I had my fingers in the USB modules list (though not the full one) recently "uneasy" is maybe not enough for the feeling in my stoma= ch.

Given all this, maybe we should rev= ert this change and move the discussion
to arch@. The USB vs USB_= SUPPORT nails a lot of my uneasiness here.

Warner= =C2=A0
--0000000000001b1ce5064c23f90e-- From nobody Tue Mar 3 22:51:11 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQWHh4btmz6TlLl for ; Tue, 03 Mar 2026 22:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQWHg75fbz425K for ; Tue, 03 Mar 2026 22:51:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772578272; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Bv5Zd2D/69G3DFGcOCoRMZeXZrJfqsbv8XJrD2c29TI=; b=BZVHajKnO2in25iBWY/IFfqO6jCahmRLplh9S6+RiN+Ycbz2dM8iUuv/a72ea5tzZj95AB JBiq9qlRzZIH+1cIxBEK1mYBsUbwr0PSc5QesLpWemNiOdUIH8LFz4HI9CDJUYj3ghoDL/ 6hSsoamBeM3vKFP0O5tM090D+eUVrT1vCExETPg3pTuqGI3KlH3Zuo+x1EXz+H+t4raTEh WlWTQ9iSaXAVURZg1h3j6j/btR/gADoG5pW6zN93ehcOmsPDOA4ClIgJ3fLy8uPSZaENy7 0x2d9N8u/JftXwAq29QWjJADDeIed/9X3wENb72HGe0WPU/QBEgNlUil1PNWJA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772578272; a=rsa-sha256; cv=none; b=UbShY3z7/CdbcJuTiFZKcqG8aqUIG+PM7vkCAEBr27xcmbnc5uLl3/rhGmA3w0btK491pS RXIOGmjjo9bmgGZnUfH45ngdfsOMHWYHfyI4WGN58kyy0bs7Bq4/d9rMPPyPRrARQk6sWZ 0cwciD+N03XGaVgK9zJz0+KGW/Ah4hRg2IWBZDlTtgooz5kjiHr/vznmuNGuLy6cnilGgV nEsZdILuE/aOIO6qV+PoWG6eTjMSB/Qii5TnH3KArxrpw8B4phyiWGINqCvkU6O0J+aO1S xOoAHucHoF5vz++3SmU+doScMZKTlIqGDcv9iVmCN4GfYIoTIiK7XHanS2jhag== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772578272; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Bv5Zd2D/69G3DFGcOCoRMZeXZrJfqsbv8XJrD2c29TI=; b=b/yR8zju/fce7IjQrcnB3Fi/fEiXy+lun9ytI55vVSr2qTH1RuICS6YCq2WwMxv2YonGa+ 8EBNqsM6/wOuqaXXF5rweseVA5scGwbqL5ZAf3+pT+Vf1yHZEcpnO/KJavbkT24fsVIQjz HHPsFt/4wJ5bm+14iDIhR65p1TkHF52YV/oAGiD4C+2Wtff+k0lxtXTDaw0aEIb02L9nER 9G9AcTxv2kHiBNmmXL64M6s24z2edm/erxZHen5a1moVu5eQAwu0xS9tb4UFm1hSC4oQQm +qWdwKk8Iz8VXE/kbcMT23g/nwDOXeyxsfUFjoZx8XqgGm6YtAwKYCjAyLFpSg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQWHg6dmQz8qG for ; Tue, 03 Mar 2026 22:51:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3abcc by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 22:51:11 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 7e70589b1bee - main - libutil: take a size_t in trimdomain() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7e70589b1bee4853cb11e3d8eb963079b18ff534 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 22:51:11 +0000 Message-Id: <69a765df.3abcc.3800efea@gitrepo.freebsd.org> The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=7e70589b1bee4853cb11e3d8eb963079b18ff534 commit 7e70589b1bee4853cb11e3d8eb963079b18ff534 Author: Kyle Evans AuthorDate: 2026-03-03 22:51:01 +0000 Commit: Kyle Evans CommitDate: 2026-03-03 22:51:01 +0000 libutil: take a size_t in trimdomain() INT_MAX is already larger than a reasonable hostname might be, but size_t makes some of this easier to reason about as we do arithmetic with it. This would maybe not be worth it if we had to bump the soversion because of it, but libutil does symbol versioning now so we can provide a compat shim. While we're here, fix some inconsistencies in argument names in the manpage. Reviewed by: des Obtained from: https://github.com/apple-oss-distributions/libutil Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D54622 --- lib/libutil/Symbol.map | 5 ++++- lib/libutil/libutil.h | 2 +- lib/libutil/trimdomain.3 | 8 ++++---- lib/libutil/trimdomain.c | 18 +++++++++++++++++- 4 files changed, 26 insertions(+), 7 deletions(-) diff --git a/lib/libutil/Symbol.map b/lib/libutil/Symbol.map index 2b28456f4406..fbd10769b2a0 100644 --- a/lib/libutil/Symbol.map +++ b/lib/libutil/Symbol.map @@ -115,7 +115,6 @@ FBSD_1.8 { setclassenvironment; setclassresources; setusercontext; - trimdomain; uu_lock_txfr; uu_lock; uu_lockerr; @@ -130,6 +129,10 @@ FBSD_1.8 { crypt_set_format; }; +FBSD_1.9 { + trimdomain; +}; + FBSDprivate_1.0 { __pw_initpwd; }; diff --git a/lib/libutil/libutil.h b/lib/libutil/libutil.h index 9b5b2abe7f09..17e4f1fba247 100644 --- a/lib/libutil/libutil.h +++ b/lib/libutil/libutil.h @@ -140,7 +140,7 @@ int realhostname(char *_host, size_t _hsize, const struct in_addr *_ip); int realhostname_sa(char *_host, size_t _hsize, struct sockaddr *_addr, int _addrlen); int _secure_path(const char *_path, uid_t _uid, gid_t _gid); -void trimdomain(char *_fullhost, int _hostsize); +void trimdomain(char *_fullhost, size_t _hostsize); const char * uu_lockerr(int _uu_lockresult); int uu_lock(const char *_ttyname); diff --git a/lib/libutil/trimdomain.3 b/lib/libutil/trimdomain.3 index 114d8d139869..4a3a4d5827ec 100644 --- a/lib/libutil/trimdomain.3 +++ b/lib/libutil/trimdomain.3 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd February 17, 2025 +.Dd March 3, 2026 .Dt TRIMDOMAIN 3 .Os .Sh NAME @@ -34,7 +34,7 @@ .In sys/types.h .In libutil.h .Ft void -.Fn trimdomain "char *fullhost" "int hostsize" +.Fn trimdomain "char *fullhost" "size_t hostsize" .Sh DESCRIPTION The function .Fn trimdomain @@ -53,13 +53,13 @@ the first time this function is called and is cached for future use. The .Fn trimdomain function will only trim the domain name if the passed -.Ar fullname +.Ar fullhost ends with the current domain name and if the length of the resulting host name does not exceed .Ar hostsize . .Pp If the passed -.Ar fullname +.Ar fullhost is actually an X11 .Ev DISPLAY specification of the form diff --git a/lib/libutil/trimdomain.c b/lib/libutil/trimdomain.c index 77518a389419..47297817a76f 100644 --- a/lib/libutil/trimdomain.c +++ b/lib/libutil/trimdomain.c @@ -34,6 +34,7 @@ #include #include +void freebsd15_trimdomain(char *, int); static int isDISP(const char *); /*- @@ -50,7 +51,7 @@ static int isDISP(const char *); * trimdomain("abcde.my.domain:0.0", 8) -> "abcde.my.domain:0.0" */ void -trimdomain(char *fullhost, int hostsize) +trimdomain(char *fullhost, size_t hostsize) { static size_t dlen; static int first = 1; @@ -89,6 +90,21 @@ trimdomain(char *fullhost, int hostsize) } } +void +freebsd15_trimdomain(char *fullhost, int hostsize) +{ + /* + * Note that we intentionally aren't doing anything here about a + * negative `hostsize`, to preserve historical behavior. Functionally, + * it would have ended up as a very large size passing to the memchr(3), + * thus either appearing to work or reading off the end of the buffer if + * `fullhost` is actually malformed. + */ + trimdomain(fullhost, hostsize); +} + +__sym_compat(trimdomain, freebsd15_trimdomain, FBSD_1.8); + /* * Is the given string NN or NN.NN where ``NN'' is an all-numeric string ? */ From nobody Tue Mar 3 22:51:13 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQWHj3jPWz6TlGm for ; Tue, 03 Mar 2026 22:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQWHj0zmDz42B6 for ; Tue, 03 Mar 2026 22:51:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772578273; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UAFh0UIuiiboLFQYC2loMqxE3e7lIte99DVUgoDdIC8=; b=miDNN1dwftKakuJwNLY3i6QeRWplNP+YQ5LPy9CEbublEA2C4fUF3Vz297Stv4W6dxtZol p9Ds95s3saBKrN3+v4Ns8WM8oCWtHck+RUdmHxWDUzIcx9G0208x9Ll1nVOSEWB2z5v2Mp k+UzxejqdTWIGhD84H5nbrSr7VxV98jSCwkiqJe79IEzVavpMae82khyKQZ7RwFOyS/hef MHGnBjXekdmQFdWgS0MlR2ku4PqnD3/uSD5ieptMAyNZirazPleAx/PIXomOLPMF4DJIO8 yTpkX5znN6+gvaapaeBzpXnJOgc6SFn8bH1BPe16+TJJCHHCH9nuuxwJlDku/w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772578273; a=rsa-sha256; cv=none; b=GeVDYdNeeuUVKaXJeGCQYqlFbnPvQzgsSLh7pAGVyNtDlyeM85/zRncf9hc6WNC8Mmgm+V zNjbgQgYjAu6jvxlFDLsiMThaC5kdcWKcMesCRtTljtTZr6wLjoEh/Ykd4ZTyJTlC0r7hN yOQ1jFqxas0wLVnjLNuBC5+v+MOf514SjliprDnQwSlNTzT2yEjjrA2TR/QvwrY71T9Fkz R6RpS1Jq0NxLBo1ZFB4dX6ZdRC7vewJYtX0LAQRGiS+L3bahd8yg+JGn4cEpEXz+iRx2Fo fA+7bg9JiUdC6E0L2ZSpvdFgrYnNLw5Wwxdo0swuPWwMpXUiDF67HE5qkujG2w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772578273; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UAFh0UIuiiboLFQYC2loMqxE3e7lIte99DVUgoDdIC8=; b=WTJzXZbVScBNbWWffSi6AFtHAqDWSMCivbOSnJHCN3fuzIIy8G3C598i2izzrKNleBbxKp vQiwDEXENLZf2dIYD2Vglx92yYGd8BVtJ6/bbyIB7+Ic3rLt3C7lCjGLqPKicUM5frtUcA zrIn3eyHvFBqsbTAsb5AtRPbxFY8FsIXCJRuqavpMLJj6SNDXp1F+iP9OfRGbADi5HZCHc FiRXVIdwenkC7Wmy2y94QGaZIB/cXdQDRILb7+W2wZEPgzxZfWHUqa02wXKOv5nRz5abXB iaRpUN7I0SaN47L7jccW2yglSGV+lI6FHs/GRa0XuCSBgkyy5vv5D0l+Zn+Lpw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQWHj0DBCz8fW for ; Tue, 03 Mar 2026 22:51:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 39c57 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 22:51:13 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: f268f95955f5 - main - libutil: avoid an out-of-bounds read in trimdomain(3) List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f268f95955f5f0f91f4d39e13bcd69a24e0d8ce4 Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 22:51:13 +0000 Message-Id: <69a765e1.39c57.10364b9c@gitrepo.freebsd.org> The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=f268f95955f5f0f91f4d39e13bcd69a24e0d8ce4 commit f268f95955f5f0f91f4d39e13bcd69a24e0d8ce4 Author: Kyle Evans AuthorDate: 2026-03-03 22:51:02 +0000 Commit: Kyle Evans CommitDate: 2026-03-03 22:51:02 +0000 libutil: avoid an out-of-bounds read in trimdomain(3) memchr(3) will happily believe we've passed in a valid object, but hostsize could easily exceed the bounds of fullhost. Clamp it down to the string size to be safe and avoid UB. This plugs a potential overread noted in the compat shim that was just added. Reviewed by: des Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D54623 --- lib/libutil/tests/trimdomain_test.c | 4 +++- lib/libutil/trimdomain.c | 6 ++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/lib/libutil/tests/trimdomain_test.c b/lib/libutil/tests/trimdomain_test.c index ad5b92b0ce1e..c6305fa72ae9 100644 --- a/lib/libutil/tests/trimdomain_test.c +++ b/lib/libutil/tests/trimdomain_test.c @@ -78,11 +78,13 @@ int main(void) { - printf("1..5\n"); + printf("1..6\n"); testit(TESTFQDN, -1, TESTHOST, "self"); testit("XXX" TESTDOMAIN, -1, "XXX", "different host, same domain"); testit("XXX" TESTDOMAIN, 1, NULL, "short hostsize"); + testit("XXX" TESTDOMAIN, strlen(TESTDOMAIN) + 256, "XXX", + "long hostsize"); testit("bogus.example.net", -1, NULL, "arbitrary host"); testit("XXX." TESTFQDN, -1, NULL, "domain is local hostname"); diff --git a/lib/libutil/trimdomain.c b/lib/libutil/trimdomain.c index 47297817a76f..a4d53deaa216 100644 --- a/lib/libutil/trimdomain.c +++ b/lib/libutil/trimdomain.c @@ -73,6 +73,12 @@ trimdomain(char *fullhost, size_t hostsize) if (domain[0] == '\0') return; + /* + * Clamp hostsize down if it's out-of-bounds of fullhost, to avoid any + * kind of out-of-bounds read in the below memchr(). + */ + hostsize = strnlen(fullhost, hostsize); + s = fullhost; end = s + hostsize + 1; if ((s = memchr(s, '.', (size_t)(end - s))) != NULL) { From nobody Tue Mar 3 23:16:52 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQWsJ29H9z6TmmN for ; Tue, 03 Mar 2026 23:16: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQWsJ1W92z45Dk for ; Tue, 03 Mar 2026 23:16:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772579812; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=uJMFFTgP36fAEKULXE1T8ARly2Ozz3LHCkf3DeUGW6Y=; b=hlnm1aFzjSZH7fU1en6G2OBT4dy543QNcYmyPf3kSviG2WK1l4A+EOu73nG3A1lRldGEZh J50JEInfuPc5r1ckW0tG9r6Q3UBD7D/Vo410djZrHGNijVgZTqTgOmhBw9sExA5aUq24dF MHw6s3XnMIINVq8KhY/Fb2+CmAO3dILxE9lw2lNxBLvc5/Tq+hSFzytpL14ybY/qsM9Ja1 oo9wCDLBSbmMFXUhJr/cs/B7vw3jprBUZzTqtyMCc/jWQFSgjgmDUW6de/PvoQlkmyirfS r74OMc3dJWHWGSj2KkhwOJ7CpenVy8XHuf7Vy/u9ZCEQpqQMkpMAfxoOETI8sA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772579812; a=rsa-sha256; cv=none; b=q8v81GP3gvca5/Oacz55e7mV70Hkv4ZVv2CgJUxwKHrIZ2AAZcGY7hNPbESjYmSTvB/IxF OPk9I5IGqW5vUzpLqUJGrPy70MHSX43Jxv9qCugJlGzeF5Xxzm4F+Wm8mMTlO5KEARK8ze ZR90rPITED19rCBosP0elhtiHKHkklqzUDH3hgsjWGaaGPeHquKG/peuHkkUP0unuJAysQ Jpwwe+BBZg5rhWa4YCTLyxKbDWpTGJPFdt9q1zjTDz5pNJLzJWtFFNqTa7sBUPJmb94O/y 3No72a03dvlcd/f3QqkP9BhKP/ZfoEkwlPXXovxmZRr+hdlzLRdsjuUBqIVuXQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772579812; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=uJMFFTgP36fAEKULXE1T8ARly2Ozz3LHCkf3DeUGW6Y=; b=W8bhZBbGYuzLbzXt3BzhB2Ugi36HlVLE3N34ulNw1TryyVUNUa15Z+urUfmqeQkPhPrLq/ VN2f3GOQIbiRiZeWTADimxI3+DlHMCfNFfL3nRSh/63p1qQU9kA7JOB+YrZzsZwQmpno2L USaVwciq81PL1uFWQFGj5oulh2991lujqHKmkpLRqa7bpAnAzy/Pw5M5lDqOJdeEZNW29V R1lCyLAAmooX5XgeYv4x7RU92tkHXxE9uiIhC2ZWs+ubv7dpIBCp9Aaqm5BeU2DRs8zlQd prKbM1HIoAdmb8mrMlsh4crCxnMCpkd9hG/FJjxwTLJZgzYP4kNriFuE/vSvhw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQWsJ0rzDz94t for ; Tue, 03 Mar 2026 23:16:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3c1ab by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 03 Mar 2026 23:16:52 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Cochard Subject: git: 4d876fc5fc42 - main - acpi_spmc: fix revision check reading name as integer List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: olivier X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4d876fc5fc427f9e4a110da5cc2ce62a21998b6c Auto-Submitted: auto-generated Date: Tue, 03 Mar 2026 23:16:52 +0000 Message-Id: <69a76be4.3c1ab.43a6fdf3@gitrepo.freebsd.org> The branch main has been updated by olivier: URL: https://cgit.FreeBSD.org/src/commit/?id=4d876fc5fc427f9e4a110da5cc2ce62a21998b6c commit 4d876fc5fc427f9e4a110da5cc2ce62a21998b6c Author: Olivier Cochard AuthorDate: 2026-03-03 23:05:04 +0000 Commit: Olivier Cochard CommitDate: 2026-03-03 23:08:23 +0000 acpi_spmc: fix revision check reading name as integer In acpi_spmc_get_constraints_spec(), the revision of the device constraint detail package was mistakenly read from constraint_obj->Package.Elements[0], which is the device name (a string), instead of from the detail sub-package's first element. Move the initialisation of 'detail' before the revision check and read the revision from detail->Package.Elements[0] as the comment already states Approved by: obiwac Differential Revision: https://reviews.freebsd.org/D55639 Sponsored by: Netflix --- sys/dev/acpica/acpi_spmc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/acpica/acpi_spmc.c b/sys/dev/acpica/acpi_spmc.c index e8ed14fdcb1b..6b4363bb364d 100644 --- a/sys/dev/acpica/acpi_spmc.c +++ b/sys/dev/acpica/acpi_spmc.c @@ -322,11 +322,12 @@ acpi_spmc_get_constraints_spec(struct acpi_spmc_softc *sc, ACPI_OBJECT *object) return (ENOMEM); } + detail = &constraint_obj->Package.Elements[2]; /* * The first element in the device constraint detail package is * the revision, and should always be zero. */ - revision = constraint_obj->Package.Elements[0].Integer.Value; + revision = detail->Package.Elements[0].Integer.Value; if (revision != 0) { device_printf(sc->dev, "Unknown revision %d for " "device constraint detail package\n", revision); @@ -334,7 +335,6 @@ acpi_spmc_get_constraints_spec(struct acpi_spmc_softc *sc, ACPI_OBJECT *object) continue; } - detail = &constraint_obj->Package.Elements[2]; constraint_package = &detail->Package.Elements[1]; constraint->lpi_uid = From nobody Wed Mar 4 07:30:49 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQkqF47hVz6T6Lt for ; Wed, 04 Mar 2026 07:30: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQkqF24lMz3r1c for ; Wed, 04 Mar 2026 07:30:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772609449; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PQX2sQoFsT62834ryCnSD/53AzYSoC50MjTJPNfSwS0=; b=kzXfIL1XiitEuz/pgIRljIuit8DWO4IugJ0NdgJKY5F8TJh/Docgg/Z4sCQXGNDirJ26Ur 7YJGfu2cevg1BE+BdTcRFrz/bEG+T9yZKkhpbO2dkmIEVl9DGpt8Ts3iuWJkE9ez3XM9ss dtoPXQjwGLtSNdpbpsDa16UcpeuIXX2xJb24kwTXh3RBvN3grVWbbpQniN03WZWwyDFOz+ qQHy4V3rBOwBKDoJ756yQHSrOTZ77FiXfM6anwIWAyQP6CHXUlPV3Qgs+zcjV79c87x2mn o79RoQwf9+tLtfVGVKAeUX+uICeBe78K9yPNIEp8Cpfc4GUgckvmXqaIf4R+4g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772609449; a=rsa-sha256; cv=none; b=gq6b3iPsWMBFbgZmLFarb7cEgnSGdIvl0kzO+4tXKmVGwXb8UTIOGqX/LoTNt1sIyT28L6 btV8sYIgy0T0pIkTUzejeIfgcyG2r49Cai8Eyzx+iVGyuxcrOmX/2MECkT1MECJW2C57Mo 7WRRJjiZDKmx+sra49SKc5zaR49nPD9KCZIxi4iSpYQK2mUW3GXk+FjrMT284LgHYeXq86 loBOZVuDia9hk1yLEfBoltm84v6aeDE2qKss3kyVo94Tn7FD5laC4iaedmCFBkBESfiIeF 8bwDh68t4cuZKeqg9jZtjOYGmSRsDiuprzXNOnpZkSHCzG+ZNHKmStpGUlTOBg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772609449; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PQX2sQoFsT62834ryCnSD/53AzYSoC50MjTJPNfSwS0=; b=OuFiJ/UhOyXFEVXlsOAyhq+92XWi9AM9pgUGueLrngEtsXjF3HBuvaLuLOqA1cvmhAt0x0 APcn8PcTqXVTmUGWkPz1sTgabF3Lg9Z4SMsTJqQe1Ah+JakeOXc04IfB4aHeq/uVattRxW NPM2iGQql9rhgPRgxJZFOQwp93NbVWtmIDK+czxhcROcpjETeNMmdBZFtO+YIRxM22r0jh eL/xxelf/G9BU2SNif0hx4pRMC4WRjgPytrHPLEu/nRC5275Y6EBB2vh7RKP0YDJK9QNuI fRdWYwc32NV1j5Ljb2KbK4euhJxCVv6neK/e0mm3O2syBh5tW6GmIgH7g9WCHg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQkqF1R2xzhY7 for ; Wed, 04 Mar 2026 07:30:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 207e2 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 07:30:49 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Eugene Grosbein Subject: git: 46ba263d6eeb - main - me.4: link if_me kernel module to its manual page. List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: eugen X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 46ba263d6eeb1c6029841b4c42f54912ad61de5c Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 07:30:49 +0000 Message-Id: <69a7dfa9.207e2.ff379e5@gitrepo.freebsd.org> The branch main has been updated by eugen: URL: https://cgit.FreeBSD.org/src/commit/?id=46ba263d6eeb1c6029841b4c42f54912ad61de5c commit 46ba263d6eeb1c6029841b4c42f54912ad61de5c Author: Eugene Grosbein AuthorDate: 2026-03-04 07:29:26 +0000 Commit: Eugene Grosbein CommitDate: 2026-03-04 07:29:26 +0000 me.4: link if_me kernel module to its manual page. MFC after: 1 week --- share/man/man4/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/share/man/man4/Makefile b/share/man/man4/Makefile index 07320734210b..7612bead9580 100644 --- a/share/man/man4/Makefile +++ b/share/man/man4/Makefile @@ -761,6 +761,7 @@ MLINKS+=lge.4 if_lge.4 MLINKS+=lo.4 loop.4 MLINKS+=lp.4 plip.4 MLINKS+=malo.4 if_malo.4 +MLINKS+=me.4 if_me.4 MLINKS+=mem.4 kmem.4 MLINKS+=mfi.4 mfi_linux.4 \ mfi.4 mfip.4 From nobody Wed Mar 4 08:07:45 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQldt138zz6T8Kk for ; Wed, 04 Mar 2026 08:07: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQldt0R51z3v9w for ; Wed, 04 Mar 2026 08:07:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772611666; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=QXNPDMNXgGQhO6FGA+CmLjEcGRJJUc3ceMzP6FSYUTg=; b=jGBIMjYXLC+HondsWgMu3KW/lvwFC4OXBZQxPkCXSXBTEMib5Xx9RyDsObHJi7F4uoYIWT 9vJTjqnBWqQRpjC9QExbwg6P3gGMlN/sRSaVrHk3zKFoHHYiXe4s3QduiNK7KwvaTPgZjO yKB/JzfEfrAQwh/B8JGj8L89h5Vi7jjpPGyfmg7YI1efbjDhY6o93XxEyn0jaEYCbppN01 wcsr5DmGiL0D2z62Ui/KHFfKGbaWbBri8DV30IBzAAtIoFyNRzsR+wgVeprgiYjJFvjA2M tqlCpxbDLlrU3SKAzf91bkpKT0gDQ+OMcouOWO/EcZPiBSZ06NcDe+k94WHucw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772611666; a=rsa-sha256; cv=none; b=Fsp6/56cc4U2yrhUy/Gjf9udY1aJJqos+Q5nIyUghCIf7g6K5vrXZfKWX5Ta6PaQQZKfx2 PHs9Ya6nrRnTBA+RwHwliooFlsCXm7u8u3WbloULahQBF9XXCH8vGzXQitJVrGKL5dXntI YNhMpUPeTtmxSg1Uxrlob62LbDsqjtdLq8m3Kq29+WvPE86yTq6ftErbZp42jAxtW01knD Bp0Kx/s7jv1kcojaFodDlt8g/Rbr3rXq2NaDqwlGulunKDhzbkaGs+cXcuxBATfTdkF2uS VVzqNXqyx4cwYak+ie3JDwBU0jQLq5GpJXNt1Dzc0YuBjHgloV0n/DPMu4dmiA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772611666; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=QXNPDMNXgGQhO6FGA+CmLjEcGRJJUc3ceMzP6FSYUTg=; b=AQd98Nl0j9PQEvvcoaFGry32TJ1Djkl6dJZuJJ4ctjQygOWHzGQ/gSpZPV7JoFlMBCGX7R RGIlWkB7dzV9Ja/T+66YgbLcb+zchFzBxVRqHtPQL57O44xw/TR2WoeNH0hTq9JkiKOkwC 26cIQTy5mOHhOMgGMI5kvy/22BilP734VMI86LuAXrEe5MhJZrNcZttMwHnKab8+Bbl54F KxGmcgaK9VqMJ3wuN6EamY9Aa3PrOp7Isoa/d4aQsYHcSpydIOmXSfS3Mo9Ec1cE9GB2k5 bnL8iXUR0bJOI9ZZmO11Vhvlqr2Fiof327WXEkk+eUs1/v3K++N5XqEImI+QIQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQldt01srzjk6 for ; Wed, 04 Mar 2026 08:07:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 25881 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 08:07:45 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Eugene Grosbein Subject: git: f69eab727edb - main - me.4: note that it is a point-to-point interface List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: eugen X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f69eab727edbab1385e5ffc8b3f6cb5a233f62c0 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 08:07:45 +0000 Message-Id: <69a7e851.25881.56a3d263@gitrepo.freebsd.org> The branch main has been updated by eugen: URL: https://cgit.FreeBSD.org/src/commit/?id=f69eab727edbab1385e5ffc8b3f6cb5a233f62c0 commit f69eab727edbab1385e5ffc8b3f6cb5a233f62c0 Author: Eugene Grosbein AuthorDate: 2026-03-04 08:06:05 +0000 Commit: Eugene Grosbein CommitDate: 2026-03-04 08:06:05 +0000 me.4: note that it is a point-to-point interface Add explicit note that me(4) works as a point-to-point pseudo device. MFC after: 1 week --- share/man/man4/me.4 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/share/man/man4/me.4 b/share/man/man4/me.4 index f10891c2fa8f..9c8795b58e4b 100644 --- a/share/man/man4/me.4 +++ b/share/man/man4/me.4 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd November 7, 2014 +.Dd March 4, 2026 .Dt ME 4 .Os .Sh NAME @@ -45,7 +45,7 @@ if_me_load="YES" .Sh DESCRIPTION The .Nm -network interface pseudo device encapsulates datagrams +network interface is a point-to-point pseudo device encapsulating datagrams into IP. These encapsulated datagrams are routed to a destination host, where they are decapsulated and further routed to their final destination. From nobody Wed Mar 4 11:13:24 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQqm46CPFz6TMVv for ; Wed, 04 Mar 2026 11:13: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQqm458tDz4LFL for ; Wed, 04 Mar 2026 11:13:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772622804; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=0X8oxB2hsb3BXMq8gIW4DbVExSLGzNZtUuKmXQkCkG0=; b=h+PT/N5pxzKWRJ1lwNo5ANXxBIpKcFmN8DVItKWRaYQG6IKxWBFsBRJXJw7WH71+yJyrJw B3aTP7tASB8SPbgTu3LTyfFAM8NGcDmB93WA57eKDifl6ZopLBsCdq9mfaLDxr1UdKyPPV lBrBIdDw1iWABcox44r1UIEk5Hj8ZAlSvfsNsMXkDm35uTEKWZ2UVlTEKRFUFrQqsUCeXM 1mV21Sc2Fuq3N9ZbQMfOAfsOChEADHtocMUHfmZY4HSdiHSyXXYjkA06slyiJrLzzTCBSm TD+mAmcX8f7jKT2lA9H+uaXhumYVvewHK6DcqSuDnI8aep9izfAa9HYLco9vkg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772622804; a=rsa-sha256; cv=none; b=iNf3DhRwPvHDIXbK9raFZb2klpIWQ7XsaoCRPUF88I2PtiuqqcCcBKYINUQzzWeMRAqF2y /dwXUrIT0usDJVaRGG6geiprnZ6hg9mFNFOGVfQ7K7TGM2/UmT3KFUOnUwHh1rIZ+xZcGD 4XzUp/ND1g3uMInM5tdNIfKxaT8e4felnoqVx6bBv4btJhpxr+2vBQU581ZAcs9pk1ckii 7+7NLy3CJPEapX+k7SdrkN6TOO7RIIpLmGTZtttyDAkH0YmAXOkR6KPNQW6QJsHW9Gq104 3ySgxfZEkXwnhyHDoeXO05x8o0rZFAt6ssLRcgZkARlBfyaAKkgfQ61h34emWA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772622804; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=0X8oxB2hsb3BXMq8gIW4DbVExSLGzNZtUuKmXQkCkG0=; b=aKIcGQ+/I/qlmzewxwLNHAtp5GDiAyIEqJE/YW1Mqzh3sf2z7Q2Z3Tr/JYTGr0Yz/mv9GN WuRsHO6RrXg0kpdL12sg8/aaMsCGovpq316SqMlV8SbbyKZ5Go6zDYV3t8/mj/GWpCTyHU c5RAYLX4k68wxOVtccUcyX2IDsxvGzxE+xKAALtfr90+c6FT6to0rVZ+Hz8XQYudi4Hosq f/ldf+4iq9x+Vl1hzvGKqKg5NnQSzJKxKQvQQGEza5uDnBYsKR+GO0YwNaE6ZK+r0MGr3O 0rvEKlOB5xgGJR8JLuDdJRmas8t7CEp+03LzmDkI3AOoVZNe4PwDviGilcQNkg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQqm44Xb0zpKt for ; Wed, 04 Mar 2026 11:13:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3e27b by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 11:13:24 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: fa0f891d5444 - main - LinuxKPI: 802.11: fix typo List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: fa0f891d54449837b47f2ef2266163bdd9117879 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 11:13:24 +0000 Message-Id: <69a813d4.3e27b.b2514c1@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=fa0f891d54449837b47f2ef2266163bdd9117879 commit fa0f891d54449837b47f2ef2266163bdd9117879 Author: Bjoern A. Zeeb AuthorDate: 2026-02-17 03:05:16 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-04 08:21:41 +0000 LinuxKPI: 802.11: fix typo Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/compat/linuxkpi/common/src/linux_80211.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 48b87ae47751..20ab5a641415 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -3508,7 +3508,7 @@ lkpi_iv_newstate(struct ieee80211vap *vap, enum ieee80211_state nstate, int arg) } else { ic_printf(vap->iv_ic, "%s: only station mode currently supported: " - "cap %p iv_opmode %d\n", __func__, vap, vap->iv_opmode); + "vap %p iv_opmode %d\n", __func__, vap, vap->iv_opmode); return (ENOSYS); } From nobody Wed Mar 4 11:13:25 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQqm56cqSz6TMmV for ; Wed, 04 Mar 2026 11:13: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQqm55sVJz4LFM for ; Wed, 04 Mar 2026 11:13:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772622805; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=m95nIKLfE5xKTordcLWv1ogseAVsNDxQ52d67+Sz3zA=; b=n9lwobta5JD4ssV2XxotibJYyAzMEym7xO16LR5XnarERNoxCCKOmmeHPQb4XrGxKxFC+x ZePhwvGPO2WaHBjjgZgK4hyzUamlQP9S6pzpvgXFA/aoveoG/V9m74mQJB0xQ+dzgeNfjR qS1pa29cdP4ZH2v+q+/1H7n8CODRlebkygl8FHhQ6kB3Fp/7tGvbYwqIkXyn/3HbFf43Ap VDJfJiqbrr10I2GrNdluCTbj0pxY+Pr1gJzjXi3xsFwREX7xCeLSh2gREuZSqHheyC3TTm vXqPqA72mCSmCtO0MuBmzGsHiTE9LdBZuUdhRpBxEaM27H9qKPrLN30CpE2qHQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772622805; a=rsa-sha256; cv=none; b=dTSyMoYllcwRo4sdWhPQFuyJSXLPU3keOuzCAM3dRFgwkE4PpkqvGU/u2iCSMWrjPInr8H qg++bFRf7PVfk8mqBvmZ49+rhH7+uaIjD2yIKfg9xJafevp8hmCYkPdwChhIjg6egdfRaO aBloeoUld2ogXm0qHf8SmbS4FrEa1OwRVktPVXyLQhUc89feKyRq3OtGI684YoRt25ptpA VvWt7by7fmj1P23eg6lvkfBVMnEp+RFDRjzSE2rSbRc+c/jqolhP/Ded6UfquPEoNkMfBO tJoPUfhlOQ+AG9I4nonp+hRC6dMwe9Q64dMi5fLQxk4RNSwQq/y4zY4Vh0rydQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772622805; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=m95nIKLfE5xKTordcLWv1ogseAVsNDxQ52d67+Sz3zA=; b=Ui1WTgyYy/r9zk/gEYCv8S3DyBI6C5AEMQP1kVJwS9DRXWwP5kl9trbi3QCTzzd3qEwnq7 8lJfiM4R70kGXGD19uzJAc7w3WkiJWdGc03NCe7qkAdo7OEwUbBSX84y0rTom6+NmqK/Gv bMFWgH9GNFTfkMdEPfluSz2lkN0Ep4Xqv1tr7hjbF46aB8boOpFe941Ea3YAsqVEr4ywxK C8TO3wziyiIqDdrAv7xip94OgilPmFxNXSGmnsLYRQJnPTd5AKb6Sl1i+kBXxmUVOJnpIf CgtY4r5rdriFOXsMhS1/ClvW2gXCuEsvbjsbZm1elUngaj2qQ1J+U0HgTrNsIg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQqm55Pw5zpYH for ; Wed, 04 Mar 2026 11:13:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 409c1 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 11:13:25 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 3d3303b756ad - main - LinuxKPI: 802.11: move linuxkpi_ieee80211_handle_wake_tx_queue() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 3d3303b756ad4ee3ae520f6d07df6978d049a871 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 11:13:25 +0000 Message-Id: <69a813d5.409c1.3970f769@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=3d3303b756ad4ee3ae520f6d07df6978d049a871 commit 3d3303b756ad4ee3ae520f6d07df6978d049a871 Author: Bjoern A. Zeeb AuthorDate: 2026-03-04 08:11:03 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-04 08:21:41 +0000 LinuxKPI: 802.11: move linuxkpi_ieee80211_handle_wake_tx_queue() No functional changes. Just moved the function within the file. Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/compat/linuxkpi/common/src/linux_80211.c | 76 ++++++++++++++-------------- 1 file changed, 37 insertions(+), 39 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 20ab5a641415..7b61ff6603b7 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -8574,6 +8574,43 @@ linuxkpi_ieee80211_wake_queue(struct ieee80211_hw *hw, int qnum) spin_unlock_irqrestore(&lhw->txq_lock, flags); } +void +linuxkpi_ieee80211_handle_wake_tx_queue(struct ieee80211_hw *hw, + struct ieee80211_txq *txq) +{ + struct lkpi_hw *lhw; + + lhw = HW_TO_LHW(hw); + + LKPI_80211_LHW_TXQ_LOCK(lhw); + ieee80211_txq_schedule_start(hw, txq->ac); + do { + struct lkpi_txq *ltxq; + struct ieee80211_txq *ntxq; + struct ieee80211_tx_control control; + struct sk_buff *skb; + + ntxq = ieee80211_next_txq(hw, txq->ac); + if (ntxq == NULL) + break; + ltxq = TXQ_TO_LTXQ(ntxq); + + memset(&control, 0, sizeof(control)); + control.sta = ntxq->sta; + do { + skb = linuxkpi_ieee80211_tx_dequeue(hw, ntxq); + if (skb == NULL) + break; + ltxq->frms_tx++; + lkpi_80211_mo_tx(hw, &control, skb); + } while(1); + + ieee80211_return_txq(hw, ntxq, false); + } while (1); + ieee80211_txq_schedule_end(hw, txq->ac); + LKPI_80211_LHW_TXQ_UNLOCK(lhw); +} + /* -------------------------------------------------------------------------- */ /* This is just hardware queues. */ @@ -8675,45 +8712,6 @@ out: /* -------------------------------------------------------------------------- */ -void -linuxkpi_ieee80211_handle_wake_tx_queue(struct ieee80211_hw *hw, - struct ieee80211_txq *txq) -{ - struct lkpi_hw *lhw; - - lhw = HW_TO_LHW(hw); - - LKPI_80211_LHW_TXQ_LOCK(lhw); - ieee80211_txq_schedule_start(hw, txq->ac); - do { - struct lkpi_txq *ltxq; - struct ieee80211_txq *ntxq; - struct ieee80211_tx_control control; - struct sk_buff *skb; - - ntxq = ieee80211_next_txq(hw, txq->ac); - if (ntxq == NULL) - break; - ltxq = TXQ_TO_LTXQ(ntxq); - - memset(&control, 0, sizeof(control)); - control.sta = ntxq->sta; - do { - skb = linuxkpi_ieee80211_tx_dequeue(hw, ntxq); - if (skb == NULL) - break; - ltxq->frms_tx++; - lkpi_80211_mo_tx(hw, &control, skb); - } while(1); - - ieee80211_return_txq(hw, ntxq, false); - } while (1); - ieee80211_txq_schedule_end(hw, txq->ac); - LKPI_80211_LHW_TXQ_UNLOCK(lhw); -} - -/* -------------------------------------------------------------------------- */ - struct lkpi_cfg80211_bss { u_int refcnt; struct cfg80211_bss bss; From nobody Wed Mar 4 11:13:26 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQqm70vWrz6TMWp for ; Wed, 04 Mar 2026 11:13: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQqm66dwwz4KsW for ; Wed, 04 Mar 2026 11:13:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772622806; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=d02krJi0lje0dMRl50gl0aiPM2IegGlax+75pNvmS5U=; b=Hpz1/cjS7KK1edlgsV/TZqOA6wa6bwAWFI+XraRQvk6SsN98AbdzZ/yOEqQ5oPAf8N4Y1P Po6QdUGDuBlIqNozJT8tesXAyfdQ0UP62V9IgpiRxAYpcuJSNelbD8SRrPThLXvHOdF7mr T/ob1yzy2TCPZ3xD9z2B0lQz1+5mXi6aALN0VpWdNA8l7rOt5AYuHOqgL8Gbb/hsZOkvuR laf+ZCS+A/NHaUzF6PuUEgI83pM/Jrg/W9/0eh20N1Lkp/UZsanTEGJDred93dpvQigR17 3VdGMqKqcgCO37r6TNsGfRHOYusWlrXNxxIGmd7i68+x856vD7CF3lbrxyEcTQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772622806; a=rsa-sha256; cv=none; b=Q2HsL8WOKAWdxSVznus5am7K02+a1DiISYI9nr6LodCEuU65wKLMOTUs1cUhvcp5lfV7nM Hxit7AXaaTkTJ5tlVlSrY7uSFW/9e1k1UK6eu9WVqBto2KAY8X9oP9EmDaqVxsnVOpp8za vj60chnne8SPbKkXgNh7jxr+srXZjdQc1MlK8Dup3yXJn73TzQynGKmDuNWJftQ5+s6T0N RirnaA/vC72+2VTZ0d8/OcjkCIEYjdVS08KDXB9uOgWwyd2hzsMZaA7ReJoej9b36y55rw Ljek0lLDgIe69OTBfPcLvyct1EGE02DLCmdNJMsBDySI+CZj7G3XJB81BoY7Rw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772622806; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=d02krJi0lje0dMRl50gl0aiPM2IegGlax+75pNvmS5U=; b=eKa/aHJToaseYD6Q9Z0zpm+SakXCcoocYHN45y7A9s2NIm2f2HMAtIuFyFIrP+vrRvJoUU CCck5Xen6Cyp+SnL8s++m010iGZumqArvxYtA/LXwTaFofK4KUUeSrVyNTOdLoD2v/Qc+F D2/oL3bIsh5YkT0tHWWrnxquR3W8Vv5D+UItMG8+YqcWEfSPd3PWEwLgWSI8skl86A7AzS AnibJ4rGBuiGCLaPXzIkuP9TstIm+/fK5F3HHnLUIUM6Jb+txNM3a8PVOsz0e170XHmvbH a3CgtpvhvhqTwoARwnqxqnuOblKb22CGXCPbgVdzIIXCXL+qwV0bh02Fo+ZT0w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQqm65sGHzpBb for ; Wed, 04 Mar 2026 11:13:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 409c5 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 11:13:26 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 8f532c7b25d5 - main - LinuxKPI: 802.11: improve prep_tx_info List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 8f532c7b25d54906c307bfda6cb679632cc26313 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 11:13:26 +0000 Message-Id: <69a813d6.409c5.2bf61770@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=8f532c7b25d54906c307bfda6cb679632cc26313 commit 8f532c7b25d54906c307bfda6cb679632cc26313 Author: Bjoern A. Zeeb AuthorDate: 2026-03-02 12:51:55 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-04 08:21:41 +0000 LinuxKPI: 802.11: improve prep_tx_info Over time struct ieee80211_prep_tx_info has grown further fields. One which is becoming mandatory is the subtype (of the mgmt frame). iwlwifi(mld) has a WARN for it if it does not match, so we now have to set this for proper operation. In addition we are tyring to improve the situation of setting/unsetting (prepare_tx/complete_tx) in various states and cleanup the use of other fields but link_id which we now leave as a marker for the future everywhere. The general problem we are facing is that our hook surface in this case is the state machine but likely would have to be tx/rx mgmt frames but we would alos have to driver the TX queues from there which is tricky. The long-term answer is to change net80211. Further the hardware flag DEAUTH_NEED_MGD_TX_PREP is dead and was removed again in favour of leting drivers deal with it. iwlwifi(mvm) likely being the only driver which ever used this. Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/compat/linuxkpi/common/include/net/mac80211.h | 1 - sys/compat/linuxkpi/common/src/linux_80211.c | 93 ++++++++++++++++++----- 2 files changed, 72 insertions(+), 22 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/net/mac80211.h b/sys/compat/linuxkpi/common/include/net/mac80211.h index 18891d035094..4f3aad532810 100644 --- a/sys/compat/linuxkpi/common/include/net/mac80211.h +++ b/sys/compat/linuxkpi/common/include/net/mac80211.h @@ -431,7 +431,6 @@ enum ieee80211_hw_flags { IEEE80211_HW_BUFF_MMPDU_TXQ, IEEE80211_HW_CHANCTX_STA_CSA, IEEE80211_HW_CONNECTION_MONITOR, - IEEE80211_HW_DEAUTH_NEED_MGD_TX_PREP, IEEE80211_HW_HAS_RATE_CONTROL, IEEE80211_HW_MFP_CAPABLE, IEEE80211_HW_NEEDS_UNIQUE_STA_ADDR, diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 7b61ff6603b7..bbda35cb2e38 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2502,7 +2502,9 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* Start mgd_prepare_tx. */ memset(&prep_tx_info, 0, sizeof(prep_tx_info)); - prep_tx_info.duration = PREP_TX_INFO_DURATION; + prep_tx_info.duration = PREP_TX_INFO_DURATION; /* SAE */ + prep_tx_info.subtype = IEEE80211_STYPE_AUTH; + prep_tx_info.link_id = 0; lkpi_80211_mo_mgd_prepare_tx(hw, vif, &prep_tx_info); lsta->in_mgd = true; @@ -2638,6 +2640,7 @@ lkpi_sta_auth_to_assoc(struct ieee80211vap *vap, enum ieee80211_state nstate, in /* End mgd_complete_tx. */ if (lsta->in_mgd) { memset(&prep_tx_info, 0, sizeof(prep_tx_info)); + prep_tx_info.subtype = IEEE80211_STYPE_AUTH; prep_tx_info.success = true; lkpi_80211_mo_mgd_complete_tx(hw, vif, &prep_tx_info); lsta->in_mgd = false; @@ -2648,7 +2651,8 @@ lkpi_sta_auth_to_assoc(struct ieee80211vap *vap, enum ieee80211_state nstate, in /* Start mgd_prepare_tx. */ if (nstate == IEEE80211_S_ASSOC && !lsta->in_mgd) { memset(&prep_tx_info, 0, sizeof(prep_tx_info)); - prep_tx_info.duration = PREP_TX_INFO_DURATION; + prep_tx_info.subtype = IEEE80211_STYPE_ASSOC_REQ; + prep_tx_info.link_id = 0; lkpi_80211_mo_mgd_prepare_tx(hw, vif, &prep_tx_info); lsta->in_mgd = true; } @@ -2796,7 +2800,9 @@ lkpi_sta_assoc_to_run(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* End mgd_complete_tx. (we do not have to check ostate == IEEE80211_S_ASSOC). */ if (lsta->in_mgd) { memset(&prep_tx_info, 0, sizeof(prep_tx_info)); - prep_tx_info.success = true; + prep_tx_info.subtype = IEEE80211_STYPE_ASSOC_REQ; + prep_tx_info.success = true; /* Needs vif->cfg.assoc set! */ + prep_tx_info.link_id = 0; lkpi_80211_mo_mgd_complete_tx(hw, vif, &prep_tx_info); lsta->in_mgd = false; } @@ -2860,6 +2866,9 @@ out: * DOWN1 * "to assoc" means we are going back to State 2 from State 4[/3]. * This means ni still is authenticated, so we keep sta, chanctx, .. + * We will send a (Re)Assoc Request in case net80211 handles roadming. + * Note: this can be called as part of a DEAUTH going to State 1 as well, + * so for RoC prep_tx_info we need to check nstate (see run_to_{auth,scan,init}). */ static int lkpi_sta_run_to_assoc(struct ieee80211vap *vap, enum ieee80211_state nstate, int arg) @@ -2910,15 +2919,33 @@ lkpi_sta_run_to_assoc(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* flush, drop. */ lkpi_80211_mo_flush(hw, vif, nitems(sta->txq), true); - IMPROVE("What are the proper conditions for DEAUTH_NEED_MGD_TX_PREP?"); - if (ieee80211_hw_check(hw, DEAUTH_NEED_MGD_TX_PREP) && - !lsta->in_mgd) { - memset(&prep_tx_info, 0, sizeof(prep_tx_info)); - prep_tx_info.duration = PREP_TX_INFO_DURATION; - prep_tx_info.was_assoc = true; - lkpi_80211_mo_mgd_prepare_tx(hw, vif, &prep_tx_info); - lsta->in_mgd = true; + /* We should make this a KASSERT. */ + if (lsta->in_mgd) { + ic_printf(vap->iv_ic, "%s:%d: lvif %p vap %p lsta %p in_mgd\n", + __func__, __LINE__, lvif, vap, lsta); } + /* + * Problem is that we should hook into the tx/rx flow and not + * try to re-model the state machine parts. We may miss a SME + * triggered frame this way. + */ + memset(&prep_tx_info, 0, sizeof(prep_tx_info)); + if (nstate == IEEE80211_S_ASSOC) { + if (vap->iv_roaming == IEEE80211_ROAMING_AUTO) { + if (arg) + prep_tx_info.subtype = IEEE80211_STYPE_REASSOC_REQ; + else + prep_tx_info.subtype = IEEE80211_STYPE_ASSOC_REQ; + } else { + /* wpa_supplicant upon RTM_IEEE80211_LEAVE. */ + prep_tx_info.subtype = IEEE80211_STYPE_DISASSOC; + } + } else + prep_tx_info.subtype = IEEE80211_STYPE_DEAUTH; + prep_tx_info.was_assoc = true; + prep_tx_info.link_id = 0; + lkpi_80211_mo_mgd_prepare_tx(hw, vif, &prep_tx_info); + lsta->in_mgd = true; wiphy_unlock(hw->wiphy); IEEE80211_LOCK(vap->iv_ic); @@ -2957,13 +2984,13 @@ lkpi_sta_run_to_assoc(struct ieee80211vap *vap, enum ieee80211_state nstate, int lkpi_80211_mo_flush(hw, vif, nitems(sta->txq), false); /* End mgd_complete_tx. */ - if (lsta->in_mgd) { - memset(&prep_tx_info, 0, sizeof(prep_tx_info)); - prep_tx_info.success = false; - prep_tx_info.was_assoc = true; - lkpi_80211_mo_mgd_complete_tx(hw, vif, &prep_tx_info); - lsta->in_mgd = false; + /* We should make this a KASSERT. */ + if (!lsta->in_mgd) { + ic_printf(vap->iv_ic, "%s:%d: lvif %p vap %p lsta %p !in_mgd\n", + __func__, __LINE__, lvif, vap, lsta); } + lkpi_80211_mo_mgd_complete_tx(hw, vif, &prep_tx_info); + lsta->in_mgd = false; #if 0 /* sync_rx_queues */ @@ -3047,6 +3074,7 @@ lkpi_sta_assoc_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, in struct ieee80211_vif *vif; struct ieee80211_node *ni; struct lkpi_sta *lsta; + struct ieee80211_prep_tx_info prep_tx_info; int error; lhw = vap->iv_ic->ic_softc; @@ -3077,6 +3105,20 @@ lkpi_sta_assoc_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, in lkpi_lsta_dump(lsta, ni, __func__, __LINE__); + /* End mgd_complete_tx. */ + if (lsta->in_mgd && vap->iv_state == IEEE80211_S_ASSOC) { + memset(&prep_tx_info, 0, sizeof(prep_tx_info)); + prep_tx_info.subtype = IEEE80211_STYPE_ASSOC_REQ; + prep_tx_info.link_id = 0; + lkpi_80211_mo_mgd_complete_tx(hw, vif, &prep_tx_info); + lsta->in_mgd = false; + } else if (lsta->in_mgd) { + ic_printf(vap->iv_ic, "%s:%d: in_mgd %d (%s) -> %d (%s) %d\n", + __func__, __LINE__, + vap->iv_state, ieee80211_state_name[vap->iv_state], + nstate, ieee80211_state_name[nstate], arg); + } + /* Take the station down. */ /* Update sta_state (AUTH to NONE). */ KASSERT(lsta != NULL, ("%s: ni %p lsta is NULL\n", __func__, ni)); @@ -3158,7 +3200,8 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* End mgd_complete_tx. */ if (lsta->in_mgd) { memset(&prep_tx_info, 0, sizeof(prep_tx_info)); - prep_tx_info.success = false; + prep_tx_info.subtype = IEEE80211_STYPE_AUTH; + prep_tx_info.link_id = 0; lkpi_80211_mo_mgd_complete_tx(hw, vif, &prep_tx_info); lsta->in_mgd = false; } @@ -3342,17 +3385,25 @@ lkpi_sta_a_to_a(struct ieee80211vap *vap, enum ieee80211_state nstate, int arg) /* End mgd_complete_tx. */ if (lsta->in_mgd) { memset(&prep_tx_info, 0, sizeof(prep_tx_info)); - prep_tx_info.success = false; + if (vap->iv_state == IEEE80211_S_AUTH) + prep_tx_info.subtype = IEEE80211_STYPE_AUTH; + else + prep_tx_info.subtype = IEEE80211_STYPE_ASSOC_REQ; + prep_tx_info.link_id = 0; lkpi_80211_mo_mgd_complete_tx(hw, vif, &prep_tx_info); lsta->in_mgd = false; } - /* Now start assoc. */ + /* Now start auth/assoc. */ /* Start mgd_prepare_tx. */ if (!lsta->in_mgd) { memset(&prep_tx_info, 0, sizeof(prep_tx_info)); - prep_tx_info.duration = PREP_TX_INFO_DURATION; + if (nstate == IEEE80211_S_AUTH) + prep_tx_info.subtype = IEEE80211_STYPE_AUTH; + else + prep_tx_info.subtype = IEEE80211_STYPE_ASSOC_REQ; + prep_tx_info.link_id = 0; lkpi_80211_mo_mgd_prepare_tx(hw, vif, &prep_tx_info); lsta->in_mgd = true; } From nobody Wed Mar 4 11:13:27 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQqm82cXFz6TMZd for ; Wed, 04 Mar 2026 11:13: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQqm775D6z4LL0 for ; Wed, 04 Mar 2026 11:13:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772622808; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=aIi6EJ/dhUK4/AwyTRh8I4q21yUGI3wb9TseZYA7VKs=; b=ZwfJE1nRoFb+2qd6kqAQNsOo9HxhhcAO1QU5BM4EyUcOqHkkEg0VoiQl5YLw9pncVqQLiy DwO0vOydiUa3xprxr5lINJji9ZQgXTurTjdYMviOxDarzs2F6xK8s6PVdWinZjZnSWVLrk kh21Q03l6xy8l5D7tU/wUdr+gPhD8vuO4dNk0cMX3h2O8/EdxxtzSRh7kR3zB66ur2cutU RglS3Exw842Gg7M7ivr7iEA5gDi0iCEB1GmEPxVWwRpANFt71ITsGrYBoCVW+7kT+rGyOS iGyYAIef6LqW5k/IIwf66x0jfFFcmgmx9yNpRg+pkkx7t8Gfi31npreem8S3nQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772622808; a=rsa-sha256; cv=none; b=jsXNt8EqVL5ZGNZVsY99YLpF32in0I1afksiHWa2ay/c5RCUVZngPfOZIi8vg++JHJVGfn KzJ9A0bbdbcPoAg4L9nY+la0odc1Ts8VaZ7q1ucNpRHmxZ/BspZnomQDBjix+0EWk6Y8Pr wZrwOTkH9rsAKO6mKPntmoR4Mzn8WlG2XNa/gudOyqgdNzebvFQ8FQWPuPfkHwS+FwQhJU sBRxWbspUmujj3gINJ+dHHqKzNZJo+1b406qdTvgn3JJguRnBwAk3rzvugzA5mb4KBIC5b X9WMRawTMWgHQmew+LRGX794s1z3SZxfJddt2wq6GmXhM63aoo7YoRyAJBPXQg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772622808; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=aIi6EJ/dhUK4/AwyTRh8I4q21yUGI3wb9TseZYA7VKs=; b=KHKv2P7MflNumnCyj8ez1F+mtbe3z8haVNEmcs5dNu5DJtC4/EwXZBfhsfLjCHt+qbFgip w46TAPyNExnHutI8AQqtJuWFLTjw4SME4cdIZnfUZpa7QC2ELpI6tsuBwWK1elbrNGvzOb FAXuJ4aPvzXpw/TM5QRRgBOF7UmO0+0HgLVSZ9BkaQzQ87i5BWoqH2rYBDnC0fL/Fih/Ye xxzwgLjd9DYu5HDTl3Ir11rfMPZ/JHEwAFxW8n8qskMn2HZ/g2YLRVijzfvObqGzkP/PiA 4qPBKP+wSLcYPY4piHJk+wbggJJSwciyVnXYDiMbHXJ36NO3iiav0yODrz+mIw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQqm76fkkzpMw for ; Wed, 04 Mar 2026 11:13:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 40a2f by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 11:13:27 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 31c3cba80783 - main - LinuxKPI: pass attrs in more places in dma-mapping.h List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 31c3cba807839a1a16e6f4bca91d530d9342b61a Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 11:13:27 +0000 Message-Id: <69a813d7.40a2f.16767a3c@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=31c3cba807839a1a16e6f4bca91d530d9342b61a commit 31c3cba807839a1a16e6f4bca91d530d9342b61a Author: Bjoern A. Zeeb AuthorDate: 2026-02-19 23:17:47 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-04 08:23:22 +0000 LinuxKPI: pass attrs in more places in dma-mapping.h Various macros (dma_map_sg_attrs, dma_unmap_sg_attrs, dma_map_single_attrs, and dma_unmap_single_attrs) currently supress passing on the attrs argument. Their implementation (even though at times still marked the argument __unused; we remove that) have long gained support for handling the argument. With ofed fixed (5edf24aac1d09), pass the argument through so that other drivers using these functions may hopefully work just a bit better as well. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: kib Differential Revision: https://reviews.freebsd.org/D55391 --- sys/compat/linuxkpi/common/include/linux/dma-mapping.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/dma-mapping.h b/sys/compat/linuxkpi/common/include/linux/dma-mapping.h index 76efbfd51074..5e5d40ef8339 100644 --- a/sys/compat/linuxkpi/common/include/linux/dma-mapping.h +++ b/sys/compat/linuxkpi/common/include/linux/dma-mapping.h @@ -106,10 +106,10 @@ void lkpi_dma_unmap(struct device *, dma_addr_t, size_t, enum dma_data_direction, unsigned long); int linux_dma_map_sg_attrs(struct device *dev, struct scatterlist *sgl, int nents, enum dma_data_direction direction, - unsigned long attrs __unused); + unsigned long attrs); void linux_dma_unmap_sg_attrs(struct device *dev, struct scatterlist *sg, int nents __unused, enum dma_data_direction direction, - unsigned long attrs __unused); + unsigned long attrs); void linuxkpi_dma_sync(struct device *, dma_addr_t, size_t, bus_dmasync_op_t); static inline int @@ -201,10 +201,10 @@ dma_map_page_attrs(struct device *dev, struct page *page, size_t offset, /* linux_dma_(un)map_sg_attrs does not support attrs yet */ #define dma_map_sg_attrs(dev, sgl, nents, dir, attrs) \ - linux_dma_map_sg_attrs(dev, sgl, nents, dir, 0) + linux_dma_map_sg_attrs(dev, sgl, nents, dir, attrs) #define dma_unmap_sg_attrs(dev, sg, nents, dir, attrs) \ - linux_dma_unmap_sg_attrs(dev, sg, nents, dir, 0) + linux_dma_unmap_sg_attrs(dev, sg, nents, dir, attrs) static inline dma_addr_t dma_map_page(struct device *dev, struct page *page, @@ -361,10 +361,10 @@ dma_max_mapping_size(struct device *dev) } #define dma_map_single_attrs(dev, ptr, size, dir, attrs) \ - _dma_map_single_attrs(dev, ptr, size, dir, 0) + _dma_map_single_attrs(dev, ptr, size, dir, attrs) #define dma_unmap_single_attrs(dev, dma_addr, size, dir, attrs) \ - _dma_unmap_single_attrs(dev, dma_addr, size, dir, 0) + _dma_unmap_single_attrs(dev, dma_addr, size, dir, attrs) #define dma_map_single(d, a, s, r) dma_map_single_attrs(d, a, s, r, 0) #define dma_unmap_single(d, a, s, r) dma_unmap_single_attrs(d, a, s, r, 0) From nobody Wed Mar 4 11:17:54 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQqsL06sXz6TMt0; Wed, 04 Mar 2026 11:17:58 +0000 (UTC) (envelope-from bz@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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQqsK6dpYz4MZc; Wed, 04 Mar 2026 11:17:57 +0000 (UTC) (envelope-from bz@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772623077; 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=mCVLD0r416Xwv/XRTOgcPnDyTl+Lemr1QRxDT08Z6PU=; b=UvrdarsIAfXNowVoj9kpPKBoHJkkGqa98MDA6kQkq2ytbeL/1JD4Lz/K66bPKjSTq3/vjB 4niYzzzHGv9A0hTZuNfi8fXgPxL0K1kG0gEh69xswguFOPQ0XCcjYmve6vC3KSuJ6aqNJW 4Gs1anHZcorPv+CsktR9UX3eYkwS9hCedNhn04fdHrLvvqomAULmSQY3Tpe8ZpZzBvVgZ4 BudcWmy6TGxwaXDd3+o4EdbhfLJnDUSkvpXaH9qksuKoenHYrzaNKnZL9RNYMSDKez657G +ijDNToNCdgZiyinqJ2gIYj6Hviv2UmHyDZpuBxOIAUIyVIZPl9bJQue/CT7MQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772623077; a=rsa-sha256; cv=none; b=x2lyrFmL8I+9F6trN6ZtpoirI5YdEqGPq8HBT2jFg/oqUrWL+5mWrhJT3CKiiuWnjFzAI9 kDIXxdBHoknkPb4lA+E1/Ts/pnaoIFaKkWhzxljF6g8UZWrU15AeMfctRswp02/jWklMgE caoTsa5oQsgA/eSYCVNOtFs8JhtGr9gLv2q0trfmzsPoeMNueTYMRbIi4tcDTEwK4NK1VD /3pOL9JBElHYz51nFaQKaLDFkxNpS+Fir/q6iUvEPmX2e7OGgFc+TdeC3CNTqkfqT/yrvU h1WRCOMXfwQTJwe2rPgJ7Xed7rfMUAAqaiym7u/qMZVD231AI9DuzIGnrF2Ukw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772623077; 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=mCVLD0r416Xwv/XRTOgcPnDyTl+Lemr1QRxDT08Z6PU=; b=Zt1MHZtGpnIX9QmWHOj2BvFq/SXdPIMlhSaQp5BwNbO3xPLIOrT7QtanXldQ1eh3lw8ktN H6e4hB5o1i2FqbPqBk30q13/oIPBHbRsU4bTYqzq7mEtvw85InBYBoMKcAmvIPr6FWR6NZ QCK6ojxmPx5YmFAXMI0/h9oDEZlpHa2wDE6MI2EleDwRngXnZTda6zKVuVBoQQBSEXd67H srMx9l4opZ3uYQ0GYn2oh0huuKPixinBpkkfPFC+49Ha5P9ax4tKcfMFQWvTji4b4goWQ4 z2Kw1IsNsqMtPQRLXtASxaZcQrJh4dIp2c6SvVTC8Zn3WnfuDtI1IETX0N+xrQ== Received: from mx-01.divo.sbone.de (legacy1.sbone.de [80.151.10.34]) (using TLSv1.3 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 "E7" (not verified)) (Authenticated sender: bz/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4fQqsK56C5z15DX; Wed, 04 Mar 2026 11:17:57 +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 9EF75A64806; Wed, 04 Mar 2026 11:17:36 +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 C3EE62D029E7; Wed, 4 Mar 2026 11:17:55 +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 u5TAqIanGlTM; Wed, 4 Mar 2026 11:17:54 +0000 (UTC) Received: from nv.t4-02.sbone.de (nv.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:22]) (using 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 8CA052D029D8; Wed, 4 Mar 2026 11:17:54 +0000 (UTC) Date: Wed, 4 Mar 2026 11:17:54 +0000 (UTC) From: "Bjoern A. Zeeb" To: Warner Losh cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org, Ali Mashtizadeh Subject: Re: git: e51ef8ae490f - main - hwpmc: Initial support for AMD IBS In-Reply-To: <69a215ee.34056.b6b1ce8@gitrepo.freebsd.org> Message-ID: <4157s999-p3p-4622-1pq6-6n69pr67s824@mnoonqbm.arg> References: <69a215ee.34056.b6b1ce8@gitrepo.freebsd.org> X-OpenPGP-Key-Id: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed On Fri, 27 Feb 2026, Warner Losh wrote: Hi, > The branch main has been updated by imp: > > URL: https://cgit.FreeBSD.org/src/commit/?id=e51ef8ae490fc9f73191f33e7ad388c2511c454a > > commit e51ef8ae490fc9f73191f33e7ad388c2511c454a > Author: Ali Mashtizadeh > AuthorDate: 2026-01-30 09:12:17 +0000 > Commit: Warner Losh > CommitDate: 2026-02-27 21:22:16 +0000 > > hwpmc: Initial support for AMD IBS > > This patch adds support for AMD IBS. It adds a new class of performance > counter that cotains two events: ibs-fetch and ibs-op events. Unlike > most existing sampled events, IBS events provide a number of values > containing extra information regarding the sample. To support this we > use the existing callchain event, and introduce a new flag for multipart > payloads. The first 8 bytes of the pc_sample contains a header that > defines up to four payloads. > > Sponsored by: Netflix > > Reviewed by: imp,mhorne > Pull Request: https://github.com/freebsd/freebsd-src/pull/2022 > --- > lib/libpmc/libpmc.c | 64 ++++- > sys/amd64/include/pmc_mdep.h | 5 + > sys/conf/files.x86 | 1 + > sys/dev/hwpmc/hwpmc_amd.c | 25 +- > sys/dev/hwpmc/hwpmc_ibs.c | 614 +++++++++++++++++++++++++++++++++++++++++ > sys/dev/hwpmc/hwpmc_ibs.h | 176 ++++++++++++ > sys/dev/hwpmc/hwpmc_mod.c | 96 ++++++- > sys/dev/hwpmc/pmc_events.h | 13 +- > sys/i386/include/pmc_mdep.h | 5 + > sys/modules/hwpmc/Makefile | 4 +- > sys/sys/pmc.h | 19 +- > sys/sys/pmclog.h | 14 + > sys/x86/x86/local_apic.c | 27 +- > usr.sbin/pmcstat/pmcstat_log.c | 99 ++++++- > 14 files changed, 1130 insertions(+), 32 deletions(-) can someone clarify is this is/will be needed or why is was added but not used? /sys/dev/hwpmc/hwpmc_mod.c:4597:1: warning: unused function 'pmc_is_multipart' [-Wunused-function] 4597 | pmc_is_multipart(struct pmc_sample *ps) | ^~~~~~~~~~~~~~~~ -- Bjoern A. Zeeb r15:7 From nobody Wed Mar 4 13:51:33 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQvGY5T3Jz6TY1L for ; Wed, 04 Mar 2026 13:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQvGY3CXpz3QkY for ; Wed, 04 Mar 2026 13:51:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772632293; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=at3ZU5T0RwQtYtu6mh1jisuO56smA1ECSnjQDUIOSn0=; b=mdLF1yiQ1/Eu/s4r2SE2Sb4WTPTTZjl6KffntXbmq0mNasw2FJE+P45AQUI/fzTuxU4jX0 xaW7LvzKKblccsn/lmIMvOfrPy0tLcV0NtubynTBwY5vCA9NWKCUPbTaZPdlCmtBMD55n4 GqOJBkY2J8s5rQ4WwHRHuuAYrW02vT9deZNRsW9TSzrNRiXhASp1EsKPCAz/sTyC+Wtr8u WZ4FSkeoNe8aS3rofpRQkHPCh2HH/FVf61DA2Cp1OhUd/9UFwe0JMJPfBInRRq2mdetAte Upy9vl5wk0slcIblp+yDG0+zX134dc/ymMrdb/W0G03PLxe4zlB7Ekt7TyZImw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772632293; a=rsa-sha256; cv=none; b=GayIZmeKr9LEwivdI8SaGKOiZ8AVuKTmJxs2tG+WI1E+jpW+Z9FBpT+Ze3xeCZzj9le7d4 YKW5ynnuKRJBqPqMjZT+ygubjq+D3b7w4RCVC+kogpQqD0UAoKwYxuCOHrQSleWZgSVLpP 6Za65GtqEveRlVP2yoesXofq9Onv+8Vw9qK4zzORhEM+yC7WZ5Rz0j2DtWW7bkCw6N0tHO SK3exXmmIftwUIuOhqg1rcO0f8aB8lteCycrAawLKLMguiiCJzlN5izRH1NGjFdEAWLuv2 NY3NoetFEIEwXjRQqflUDOMh2xVq7eMvaSZTvowTs6lP2G2ucvjs7nRGRGQXQQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772632293; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=at3ZU5T0RwQtYtu6mh1jisuO56smA1ECSnjQDUIOSn0=; b=gAOCGlsS/VHSXoinGu/dKWmNj2F94DPvsaetHVcUxSJsfidQfGlyFo2bx4A+jueHbqyrC/ pefYTAZK6lhurruX7IbNs7I2zaOo1wqLFLe/mAt9uHWNKeq9C9O6d5d3DjbZWPQl+xYqzg WOjyWM4Bg5+0akYux/D6oIa+AhrW8FELvsm1K5fvnxbIPFx29a9xJDeMNy41voK/BBBpy7 616uJn7hJS8+XEOaOmLFqiZ3CsikoorhR6CVAM//c+NpEW7zwAmlxCcnPRVKAgMoR8F/26 CsAh1diWDU7KoNDxIIqgpAKmYXNGtq1o7PGDVE5DUlapHIAPx1WzCDtpGxSQBA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQvGY2ZmWztMK for ; Wed, 04 Mar 2026 13:51:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 2253b by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 13:51:33 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: ShengYi Hung Subject: git: 546d925cb44f - main - ichwd: Add manual for i6300esb watchdog List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: aokblast X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 546d925cb44f1da7efee76bfebb42df8fdbc83a8 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 13:51:33 +0000 Message-Id: <69a838e5.2253b.58682e0f@gitrepo.freebsd.org> The branch main has been updated by aokblast: URL: https://cgit.FreeBSD.org/src/commit/?id=546d925cb44f1da7efee76bfebb42df8fdbc83a8 commit 546d925cb44f1da7efee76bfebb42df8fdbc83a8 Author: ShengYi Hung AuthorDate: 2026-01-03 06:12:26 +0000 Commit: ShengYi Hung CommitDate: 2026-03-04 13:51:13 +0000 ichwd: Add manual for i6300esb watchdog Reviewed by: ziaee, mhorne Approved by: lwhsu (mentor) MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54466 --- share/man/man4/ichwd.4 | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/share/man/man4/ichwd.4 b/share/man/man4/ichwd.4 index cc6924f7f866..25de73778d36 100644 --- a/share/man/man4/ichwd.4 +++ b/share/man/man4/ichwd.4 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 20, 2008 +.Dd January 3, 2026 .Dt ICHWD 4 .Os .Sh NAME @@ -55,6 +55,16 @@ The ICH WDT counts down in ticks of approximately 0.6 seconds; the exact value depends on hardware quality and environmental factors. Supported watchdog intervals range from 2 to 63 ticks. .Pp +In QEMU, there is a dedicated watchdog implementation for x86 +systems based on the Intel 6300ESB controller hub. +Support for this watchdog is provided by this kernel module. +.Pp +Optionally, set the +.Va hw.i6300esbwd.x.locked=1 +.Xr sysctl 8 +to prevent users from disabling the watchdog timeout check +after it has been enabled. +.Pp Note that on some ICH-based systems, the WDT may be present but disabled, either in hardware or by the BIOS. The From nobody Wed Mar 4 14:20:27 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQvvv4ZPXz6TZ49 for ; Wed, 04 Mar 2026 14:20: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQvvv3ySNz3TC5 for ; Wed, 04 Mar 2026 14:20:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772634027; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Bta7Gtph0Kq3Uj3N88Jn9mtVHgbkwhZ1IEO5Oe4+emw=; b=ejIByA1yLJovk8eAcd8KpmS07tjLN3a8Kdq45BTvaY7LCS5PKkzfT1zSuL5SoJ0kKxJed/ dycxQA+kUBij2P8E8OeoTCdr5c06j8VF2519tNJWL+r6rBl2KEvioHcTAzyeC+NpR/bWaM wCXgHFg0j6scMq0ofRV1CkfVK240KN4QQorKEesuXv0vUZowBO0zNJB547rvv9Kd4xLn0r WAvR8lqiVSOcyUVAep9sYCHho93NaYowRg9Wfh+vgN9h35ECUV3UekCgEqEJwJ2p02bdFV 0zqbQivAHykLrXS1KrpFAh5niowS2WB/uHbSAlcIIAbDKMCqh3NN/mXoTk9mww== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772634027; a=rsa-sha256; cv=none; b=RxDgUR87HBFS4kNc6bOherDHgiQSM273jVldeCtosItRolBvFRToNLGc3adPdjL/Ee/Gn4 cHnXG6OkA2Med3jRhga8Kj4HBBIOG0xsv8Ds04u6qRFmgOXWV0fYwsboV1aEzCa44DB8CJ CX9nwJkX9wUXx+CwsjkvdAmHCjVA3trqGebujw3hJ+n22Tj5gyeHWrIFvg0F4QPg/Mk4wu YT9gEO78/tjSQxie3MRcfkK+0R/aQu/EuQDFUdP+seuuD+r1BB2S52vuGqCcbAmtEW38xY FJ1tPCeEKuSd2TcXylvWAZB22GbzmrRjwobZ1I5rPpIFTd38b3gsECIIrVBY8w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772634027; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Bta7Gtph0Kq3Uj3N88Jn9mtVHgbkwhZ1IEO5Oe4+emw=; b=jooTNy3HdBZGA6323WudaplTiFUdBLac3gXvDM8+jyYx/dCzUhDpivW59qIWi5AULJDV5h N8hFAj2+ULzmWZbiWCDx6+2sUGEtmd8NoPj9iXDWjn+8pR814MVucdVBMs7sT6VAvq5atm bsF3/AoVo+SslFeN+ypNXw8aWaiUHxIL8A60sfQOaOQvH8DxMMesRUDInTvrKp10PRYFZl CaRN+ur2yOw9SlBB0oSZOAZ8hqmMk1IR3Vksu/Z3GD/MagzqXZq9FbUP8pGU7/W/UbJmXp RZhkOUbQrJ76DoVqz8lDRKencUy8rSKPJAB96oMa4y6bgLaGys8UVkhYu4QhaA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQvvv3VlJzv89 for ; Wed, 04 Mar 2026 14:20:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 24a57 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 14:20:27 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Michael Tuexen Subject: git: 3d69387ece53 - main - tcp: improve NOINET builds List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 3d69387ece535fc33821d089aab241bfb9551d69 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 14:20:27 +0000 Message-Id: <69a83fab.24a57.1ceb82f9@gitrepo.freebsd.org> The branch main has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=3d69387ece535fc33821d089aab241bfb9551d69 commit 3d69387ece535fc33821d089aab241bfb9551d69 Author: Michael Tuexen AuthorDate: 2026-03-04 14:18:58 +0000 Commit: Michael Tuexen CommitDate: 2026-03-04 14:18:58 +0000 tcp: improve NOINET builds Reported by: bz MFC after: 1 week Sponsored by: Netflix, Inc. --- sys/netinet/tcp_subr.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/netinet/tcp_subr.c b/sys/netinet/tcp_subr.c index c759e9a1cd6b..8aa8a7b7fefc 100644 --- a/sys/netinet/tcp_subr.c +++ b/sys/netinet/tcp_subr.c @@ -341,8 +341,11 @@ static struct inpcb *tcp_drop_syn_sent(struct inpcb *, int); static char * tcp_log_addr(struct in_conninfo *inc, struct tcphdr *th, const void *ip4hdr, const void *ip6hdr); static void tcp_default_switch_failed(struct tcpcb *tp); + +#ifdef INET static ipproto_ctlinput_t tcp_ctlinput; static udp_tun_icmp_t tcp_ctlinput_viaudp; +#endif static struct tcp_function_block tcp_def_funcblk = { .tfb_tcp_block_name = "freebsd", From nobody Wed Mar 4 15:22:59 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQxJ84TCZz6Tdtj for ; Wed, 04 Mar 2026 15:23: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQxJ83y8Bz3lLp for ; Wed, 04 Mar 2026 15:23:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772637784; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=29Btjg5h7TYmIvBoeQvaIi3UW4lYNP6a2eNXqGl0Ln4=; b=ji8fk4XCeNNbhBj9JuT/n4F8U6rKXaVVJIFPy8AbXTFMbtlaDf4J+NpUDMLeD5s8Ja6pk7 L8BDNZT52eP/sd+66OVc5slJIO4ewKxjXkj8Qq3kplfzRfm3+0eaDCjP5lw8duqoDZHs0x oxPQltDkTeMEMJATLnCuKy38Yt1SYKFveDZymR8iug06Wl6E416BnQBILq3z09KHCWyRfL t+GzbMtG91LwNprGkfkZq8aCoP/TtJqvRNptvDXKQ8qExqCkGMMuzhivYQg/NEVmPGo7cl TSNLAo62ZE7esDLLc+Vtxxl9QBLvGE2cQl4PHlk8SNQFqczRqS5bpG+gZqf8dQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772637784; a=rsa-sha256; cv=none; b=nJ81DbNlX7rwSP8IHzmP63u3xHoObv2IwvANioK0FKISOIJXmeZr7JM+xpBItNnl4v8pnm GhJIzr4aCeFb4h2atEmJhgUSdTw5PuQBS7gzqwyiVKi950VKh3sIaZMpatsCelwRaEygP1 MsGz8+srZngvB4E2xSlfl8zHIyZzi8/4b7mnqu80zRHPdwofB1EMuym8s+3LbD16rPgl3L f+PACrEdI1MiudtMYcCHZW8zR7ty2tyh9sLxhcVfgDsn5YIuZ4jHQjexTZf1L0MFxvd9hO O1cQChPneS1fJJdxtsu7H9XQQlnKZuQZUG9GvVTNoY6dBVNfdGgjErr2D/CJ5w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772637784; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=29Btjg5h7TYmIvBoeQvaIi3UW4lYNP6a2eNXqGl0Ln4=; b=TvHCDuVcGgny1aDp8ivPlgQv9b2ovZ/mU18GTRJl+zq925zQh1uXQm0jTSZylecW4V1O1F 0pV3wiC1jBP/02Dv3Zd9G8FO773yhmDSFCKybIM2Sve6noW88vH0GID8xCmBGPfKAqqqz1 l358gbApLm/GGFCa1CKnTlkGv6xzuz/1QGrkJVVrQGLXT+G9YgC315Eu2rEUACt4Pz7U3w wMS0nOoqmCkDAPdmgT+Swcj55e3AM04Uk6O6S7Fgq7O0JZBTDA6V5Isp9fVn+ysFeb+HqD RuHnnb/qvlvJ7pKACwnzRGQAGx3xzlKRq5Z8xJBtLXDdAB2m8jdMTc1jMCcX1w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQxJ83WMlzx4K for ; Wed, 04 Mar 2026 15:23:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 317d4 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 15:22:59 +0000 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=B8rg?=rav Subject: git: 40e52e0edd03 - main - system(3): Unwrap execve() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 40e52e0edd038460a2a2aca017b3ac5a513fe37b Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 15:22:59 +0000 Message-Id: <69a84e53.317d4.78cb8c78@gitrepo.freebsd.org> The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=40e52e0edd038460a2a2aca017b3ac5a513fe37b commit 40e52e0edd038460a2a2aca017b3ac5a513fe37b Author: Dag-Erling Smørgrav AuthorDate: 2026-03-04 15:22:42 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2026-03-04 15:22:42 +0000 system(3): Unwrap execve() There is no need to call execl(), which will allocate an array and copy our arguments into it, when we can use a static array and call execve() directly. MFC after: 1 week Sponsored by: Klara, Inc. Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D55648 --- lib/libc/stdlib/system.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/libc/stdlib/system.c b/lib/libc/stdlib/system.c index 94f7460c9b68..a2f472502bfd 100644 --- a/lib/libc/stdlib/system.c +++ b/lib/libc/stdlib/system.c @@ -60,6 +60,8 @@ __libc_system(const char *command) static struct sigaction ointact, oquitact; struct sigaction ign; sigset_t sigblock, osigblock; + char *argv[] = { "sh", "-c", __DECONST(char *, command), NULL }; + extern char **environ; int pstat = -1, serrno = 0; pid_t pid; @@ -101,7 +103,7 @@ __libc_system(const char *command) /* * Exec the command. */ - execl(_PATH_BSHELL, "sh", "-c", command, NULL); + _execve(_PATH_BSHELL, argv, environ); _exit(127); } else { /* parent */ /* From nobody Wed Mar 4 15:50:26 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQxvk2560z6TgKG for ; Wed, 04 Mar 2026 15: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQxvk14sFz3nRV for ; Wed, 04 Mar 2026 15:50:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772639426; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ncMEpIyeELc2z2bauQlpzWVLnyBFHIQOID4EKoODQOM=; b=xOl8OZEclb8q7EH8tlpAPds969ITKzLj2Xxl9VhKA7jViYUjJgPHqeQBN2M86rGUmG5TzX 5oe5LlHT12ThumiE1lqEv9sfa4NQjbxyXzwOLBvM+ZgVH2F3NXtyrF8KuBRO2FtS5sQHVH 5S/47ApYcchCfckW4mVJnBSkIp68IDUd16xYK4CZ8ztXHmdeALlBUJF4Na/nxEp5XtGtp5 2eI1Bnadd4o8NSFspCy5Jgnlfcgmb0hQi+e5INjTbY73VIq3v+g+4amOD6GY5GwUY4WBY/ bSVl9xgxtQAX+Lc4pT6GcaH4UvQeNOi/AcihKB0Tm3BpDJwIZhN0xq/5R53mfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772639426; a=rsa-sha256; cv=none; b=BNoxteHEKwTUcsWgya+zdzBNc1iJ5+EzqnZkHI4UFwsSxidMueusO6326ZQIhxzCKdykbF nKj+CsWKnqAHHDKUqYmpcmQ/Gd3z7oCNZENGZo64OhIXuFo5AwhMQOPHlL42z7NAyiYdxh wzymJ2q5fpR8ANPSe4/iSMF+2JBqPxhPeLiMNcR09K4LSb5MuDjPtdGX72hUNWORiIrbzv hkAzjnSWH1wgTUOAjr7vvWXT075ISQFzZmXBLUPuU2jjq7XXcpeeTXTVS4M0c48drXF5vU Y9Sk2rX0nrqvWVXP2Wx09839Kjcav0qAspit2QYHLxvhnkoIHlCC6qb3WfvBkA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772639426; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ncMEpIyeELc2z2bauQlpzWVLnyBFHIQOID4EKoODQOM=; b=LqtvQ9fCQjac/Akc7Uwp9nrBdiz8faJv5KQhxYlQoKZ24ZujID3Bywr/LJCMR0pW82SYcO 1TtbLJXR5zRQCOHTOPbaQm/0ZGUICjiMkplZ7Bn286xTeXl4FNmAQPHTUXntAwliWCdr7A GkSNmHr6aEJZFqos3f0HOcH6lwHjU+5Q2U70+vOSJqoWuoGJRJhJHEjNaVvWbXT2C/livE mIAHl1GHHc4w/u4tE++7c3MyNJSaYD4i5rMalZto09erKLAWqRla+V0pS88y7bEyAjPCWw GRFmzUARTWMHRRrzL8WxNM8npe1ZSwCerppjnH4H4GTq84rWBXj8wdihVMUZpQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQxvk0Rl6zxT1 for ; Wed, 04 Mar 2026 15:50:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3386c by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 15:50:26 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Aymeric Wibo Subject: git: 2c60fce365f4 - main - amdsmu: Sleep entry/exit hints for PMFW List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 2c60fce365f4398ff02a86b46e2862905f88fa97 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 15:50:26 +0000 Message-Id: <69a854c2.3386c.1a45b68f@gitrepo.freebsd.org> The branch main has been updated by obiwac: URL: https://cgit.FreeBSD.org/src/commit/?id=2c60fce365f4398ff02a86b46e2862905f88fa97 commit 2c60fce365f4398ff02a86b46e2862905f88fa97 Author: Aymeric Wibo AuthorDate: 2025-06-14 15:33:24 +0000 Commit: Aymeric Wibo CommitDate: 2026-03-04 15:38:57 +0000 amdsmu: Sleep entry/exit hints for PMFW amdsmu_suspend() and amdsmu_resume() for sending hints to the AMD SMU power management firmware (PMFW) that we are entering and exiting s2idle. We also dump sleep metrics once we tell it we're exiting sleep, so the relevant metrics are updated. Register these as acpi_post_dev_suspend and acpi_post_dev_resume eventhandlers. Reviewed by: olce Approved by: olce Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D48721 --- sys/dev/amdsmu/amdsmu.c | 48 ++++++++++++++++++++++++++++++++++++++++++++- sys/dev/amdsmu/amdsmu.h | 11 +++++++++-- sys/dev/amdsmu/amdsmu_reg.h | 1 + sys/modules/amdsmu/Makefile | 3 ++- 4 files changed, 59 insertions(+), 4 deletions(-) diff --git a/sys/dev/amdsmu/amdsmu.c b/sys/dev/amdsmu/amdsmu.c index 416f875c6176..9a6873b43517 100644 --- a/sys/dev/amdsmu/amdsmu.c +++ b/sys/dev/amdsmu/amdsmu.c @@ -1,7 +1,7 @@ /* * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2025 The FreeBSD Foundation + * Copyright (c) 2025-2026 The FreeBSD Foundation * * This software was developed by Aymeric Wibo * under sponsorship from the FreeBSD Foundation. @@ -14,6 +14,13 @@ #include #include +#include "opt_acpi.h" + +#if defined(DEV_ACPI) +#include +#include +#endif + #include #include @@ -289,6 +296,27 @@ amdsmu_fetch_idlemask(device_t dev) sc->idlemask = amdsmu_read4(sc, SMU_REG_IDLEMASK); } +static void +amdsmu_suspend(device_t dev, enum power_stype stype) +{ + if (stype != POWER_STYPE_SUSPEND_TO_IDLE) + return; + if (amdsmu_cmd(dev, SMU_MSG_SLEEP_HINT, true, NULL) != 0) + device_printf(dev, "failed to hint to SMU to enter sleep"); +} + +static void +amdsmu_resume(device_t dev, enum power_stype stype) +{ + if (stype != POWER_STYPE_SUSPEND_TO_IDLE) + return; + if (amdsmu_cmd(dev, SMU_MSG_SLEEP_HINT, false, NULL) != 0) + device_printf(dev, "failed to hint to SMU to exit sleep"); + /* Update metrics after resume. */ + amdsmu_dump_metrics(dev); + amdsmu_fetch_idlemask(dev); +} + static int amdsmu_attach(device_t dev) { @@ -422,6 +450,19 @@ amdsmu_attach(device_t dev) "value is not documented - only used to help AMD internally debug " "issues"); +#if defined(DEV_ACPI) + /* + * Register post device suspend/pre device resume eventhandlers. We use + * a lower priority for the suspend event as we want this to be called + * after the SPMC suspend hook, and a higher priority for the resume + * event as we want this to be called before the SPMC hook. + */ + sc->eh_suspend = EVENTHANDLER_REGISTER(acpi_post_dev_suspend, + amdsmu_suspend, dev, -10); + sc->eh_resume = EVENTHANDLER_REGISTER(acpi_pre_dev_resume, + amdsmu_resume, dev, 10); +#endif + return (0); err_dump: bus_space_unmap(sc->bus_tag, sc->reg_space, SMU_MEM_SIZE); @@ -438,6 +479,11 @@ amdsmu_detach(device_t dev) struct amdsmu_softc *sc = device_get_softc(dev); int rid = 0; +#if defined(DEV_ACPI) + EVENTHANDLER_DEREGISTER(acpi_post_dev_suspend, sc->eh_suspend); + EVENTHANDLER_DEREGISTER(acpi_pre_dev_resume, sc->eh_resume); +#endif + bus_space_unmap(sc->bus_tag, sc->smu_space, SMU_MEM_SIZE); bus_space_unmap(sc->bus_tag, sc->reg_space, SMU_MEM_SIZE); diff --git a/sys/dev/amdsmu/amdsmu.h b/sys/dev/amdsmu/amdsmu.h index 025887f7fe5a..857fa21cba4e 100644 --- a/sys/dev/amdsmu/amdsmu.h +++ b/sys/dev/amdsmu/amdsmu.h @@ -6,11 +6,13 @@ * This software was developed by Aymeric Wibo * under sponsorship from the FreeBSD Foundation. */ + #ifndef _AMDSMU_H_ #define _AMDSMU_H_ #include #include +#include #include #include #include @@ -60,6 +62,9 @@ struct amdsmu_softc { struct sysctl_ctx_list *sysctlctx; struct sysctl_oid *sysctlnode; + struct eventhandler_entry *eh_suspend; + struct eventhandler_entry *eh_resume; + struct resource *res; bus_space_tag_t bus_tag; @@ -72,8 +77,10 @@ struct amdsmu_softc { uint32_t active_ip_blocks; struct sysctl_oid *ip_blocks_sysctlnode; size_t ip_block_count; - struct sysctl_oid *ip_block_sysctlnodes[nitems(amdsmu_ip_blocks_names)]; - bool ip_blocks_active[nitems(amdsmu_ip_blocks_names)]; + struct sysctl_oid *ip_block_sysctlnodes[ + nitems(amdsmu_ip_blocks_names)]; + bool ip_blocks_active[ + nitems(amdsmu_ip_blocks_names)]; bus_space_handle_t metrics_space; struct amdsmu_metrics metrics; diff --git a/sys/dev/amdsmu/amdsmu_reg.h b/sys/dev/amdsmu/amdsmu_reg.h index e685b34e6883..d45fa60941d5 100644 --- a/sys/dev/amdsmu/amdsmu_reg.h +++ b/sys/dev/amdsmu/amdsmu_reg.h @@ -45,6 +45,7 @@ enum amdsmu_res { enum amdsmu_msg { SMU_MSG_GETSMUVERSION = 0x02, + SMU_MSG_SLEEP_HINT = 0x03, SMU_MSG_LOG_GETDRAM_ADDR_HI = 0x04, SMU_MSG_LOG_GETDRAM_ADDR_LO = 0x05, SMU_MSG_LOG_START = 0x06, diff --git a/sys/modules/amdsmu/Makefile b/sys/modules/amdsmu/Makefile index 752f57173d61..faeb1b136060 100644 --- a/sys/modules/amdsmu/Makefile +++ b/sys/modules/amdsmu/Makefile @@ -9,6 +9,7 @@ KMOD= amdsmu SRCS= amdsmu.c -SRCS+= bus_if.h device_if.h pci_if.h +SRCS+= bus_if.h device_if.h pci_if.h \ + opt_acpi.h .include From nobody Wed Mar 4 15:50:27 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQxvl4Z39z6TgGk for ; Wed, 04 Mar 2026 15:50: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQxvl1lQ7z3nP7 for ; Wed, 04 Mar 2026 15:50:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772639427; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zwA3XCsGkTl/ywgGMI2XF58biAYkf83O20luIfC9aYk=; b=EIg2QlCwIhpvFcXYAIqPFg2VNVlvko0Otn8vFZL/PI59m30Wzb+qF+I8XJsRKGd1ao9G1x IYrnw3CjJ6tszkBfAnrVgqzba3TSV56Yw6BjL9QuvDCw9X0bxv5cnbYgA3mF6OsFZo/+kR 6v6gwC55hwkOkRSoceD/2GealF+YAGBJt3KW++dE7ucOGWUeEqVz3QxiAE3h0Sr5c0w8sI 03Iw6mvb4hG/t8AGHxVhxKEWsOtYhN6PltoUtBbe6KklA48YoL8ikgzTrFQa7rZFbQnBxk 4tCKu4jFEhc4Wax3XSBr11Ia44zjscVZ51FedL7UtNrCqZn0LV+UJwUqNC2Q+w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772639427; a=rsa-sha256; cv=none; b=i8UlwliqH/XfTDq5tVeO++xb+yGUC+k5kHioKOMc4mL2o6Ls/lSJC5PPwhoukpUnhQNsrz 3DFHQZY9+4oGWviS74ZGFKBwX9phkSgnnteE1CNLOfW5jY4OMS88953byi6zB5uOkEMkm2 jOUGIypTbIfS1T/R3y8bWLRgN5Sq1nWYx6twCnVIWDxyjcOzF4H9brRgsgQTpPcsCBJM5o BCVLmPDEqWpcRaKcKJc/3avpoWQS45SfAoAWIj/PzlPE6vLJ50kP/uif7cfq1Jg79RSK5K f3lwABp++etRwAy26imYVtJZO1t5CTh2JILgNB34I6+HO3tzzHLuvBhEKl1+fw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772639427; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zwA3XCsGkTl/ywgGMI2XF58biAYkf83O20luIfC9aYk=; b=gknSxcmnJWQgJ929jyNEd0RnYNjNeDrPmez4jzv7jhF4PIS8eiU32TGn+Azo0xe+AQAdQb 914CT5twhtW/P4udetN3mL2Dpopfoz1+uScrjrWoZIcRk10J7O2wNtKNShj0JyXw8hk2kb QeNukYfsDAfl8ywufmaqZs+t0PnNwPNo+jhRg5LeeNfj5ltcvHncnWbNd9T4LYqD4jfLC4 2YZ2vZwXPB7V+tSz6yUoYoPtYJ9xo4cp7g14xti4aUO6aLKQQgzXG94YOZs2sXZHco/iAE Tv6QyT8B5r5GJsV9w7TbEbpCodBHbslxPTXZoQy9YqwWowUH6ZEQC5mpNqlHFQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQxvl0yQwzxT2 for ; Wed, 04 Mar 2026 15:50:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3651d by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 15:50:27 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Aymeric Wibo Subject: git: bc3914737bce - main - bus_if: Fix typo List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: bc3914737bce07a912a8024ba19983d7c388736c Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 15:50:27 +0000 Message-Id: <69a854c3.3651d.1dc49d09@gitrepo.freebsd.org> The branch main has been updated by obiwac: URL: https://cgit.FreeBSD.org/src/commit/?id=bc3914737bce07a912a8024ba19983d7c388736c commit bc3914737bce07a912a8024ba19983d7c388736c Author: Aymeric Wibo AuthorDate: 2026-03-04 15:39:27 +0000 Commit: Aymeric Wibo CommitDate: 2026-03-04 15:48:11 +0000 bus_if: Fix typo Reviewed by: olce Approved by: olce Fixes: 4c4392e791b7 ("Add doxygen doc comments for most of newbus and the BUS interface.") Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D48721 --- sys/kern/bus_if.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/kern/bus_if.m b/sys/kern/bus_if.m index b9c916accd67..944064a77c54 100644 --- a/sys/kern/bus_if.m +++ b/sys/kern/bus_if.m @@ -31,7 +31,7 @@ /** * @defgroup BUS bus - KObj methods for drivers of devices with children - * @brief A set of methods required device drivers that support + * @brief A set of methods required for device drivers that support * child devices. * @{ */ From nobody Wed Mar 4 16:21:12 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQybK5sJ7z6ThYs for ; Wed, 04 Mar 2026 16:21: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQybK51GBz3rDG for ; Wed, 04 Mar 2026 16:21:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772641277; 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; bh=AUqJAIRpTWVFLY9gorqqjh8Nvf8bD/tl6Oc36g3qKB8=; b=pzJb2VT5SklTHy8e8phcW786BlYbE09jQyMGj5SB1pyEhWwnK8GxJJOdiYx3f6cCG1xyFb deCgAxPLfnpOnveCXgaMc6PurBRz/Xgy6tOqPpEWiRgesfK8sw980H+buEaE97Ja8LKTZ9 Mp/MlRax92bBY6kARasnJDMJ6KOlquFkd0EWUmqOzAp0eGgw7IU6qrATdqN0XcXGAVefEn Z1+labcTRZeYnNgribl4iF3fP3QhvumiJ6a+YB8LZZKoBy5RqeQuLzIeM9zWaj37G5emwF c25wUtomZseblJo5298zGlGzvdP+hBt8+qgh/iX1mH9DkbaQUm/WVW2vXr5l6Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772641277; a=rsa-sha256; cv=none; b=t8c/G9R/DbOSK89eAZUqg6SaIX1jMKyvp29U3h6parsIkuzj4iOejFSCFJOM+Ji9Tg/qz4 noTkytY3AnG08t86bhy7Dc9mUZNAhI/njZ0+aq4SYOT2yoAbtAip/gSe2lU959Ixj91Sc1 kXADbSkTCoaXa1ZUePEvV0B2b7bS408jQt18TqOXiqr72uF3dxN6QkjDAbgwK12J9qcSqH SCsTVEaMMoyyhc5BKtL5k7z92tuHm49cPzMLYQaleKH1IFQWePh9j+JBil/4kavqheOV7W ksJucKdOFfmTRW5wHgILIbfaBxhmX3v9lxjYK0oER8oQLqD3kxd/9IMqRLLjkg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772641277; 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; bh=AUqJAIRpTWVFLY9gorqqjh8Nvf8bD/tl6Oc36g3qKB8=; b=Xb4BK2Wwa+P59X2VHSoXGyw1aarcK7QljYlV1c8aKM215s5hwF0rbsGB+tz6tgpJLyXP4V HWE5XhMmDFXShwyqnTX0gGDIGIVh2tcm5xISku/DJw8ZODW+rRQcFM/J9UeC/kcDq7p5fF rNe95qWv8a7zDtS4rerzPoZFlVOOsQlLmwUnglivG8c/4r2PahS+Pn/X8wDVHxQONxgt+q f8gZJqK6qT97c1vFXHwrEluAxlgRi6I8op+4Xp7pPxa7rH70rO4TMdLMZkvolFNcKUd8rY PBRQo3G7PHnzviItPdg7cyfcl9L786ut5LAx266CgjfiicIgOGHdMlO8x2yqbw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQybK4NLKzyNW for ; Wed, 04 Mar 2026 16:21:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 387c0 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 16:21:12 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Seth Hoffert From: Kristof Provost Subject: git: 36acf1bd32ed - main - pfctl: consistency List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 36acf1bd32ed5749af4a9f735aeea1a3434fe42f Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 16:21:12 +0000 Message-Id: <69a85bf8.387c0.2f397e61@gitrepo.freebsd.org> The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=36acf1bd32ed5749af4a9f735aeea1a3434fe42f commit 36acf1bd32ed5749af4a9f735aeea1a3434fe42f Author: Seth Hoffert AuthorDate: 2026-03-03 21:56:45 +0000 Commit: Kristof Provost CommitDate: 2026-03-04 16:20:34 +0000 pfctl: consistency % pfctl -F ethernet Ethernet rules cleared % pfctl -s ethernet pfctl: Unknown show modifier 'ethernet' pfctl accepts 'ethernet' (or any prefix of it) in the -F flag but accepts only 'ether' (or any prefix of it) in the -s flag, which seems inconsistent. This change brings the two to parity while remaining backwards compatible. Reviewed by: kp MFC after: 2 weeks Signed-off-by: Seth Hoffert --- sbin/pfctl/pfctl.8 | 2 +- sbin/pfctl/pfctl.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sbin/pfctl/pfctl.8 b/sbin/pfctl/pfctl.8 index 662f5a4b0f16..05a76641ca8d 100644 --- a/sbin/pfctl/pfctl.8 +++ b/sbin/pfctl/pfctl.8 @@ -456,7 +456,7 @@ When used together with .Nm will loop and show updated queue statistics every five seconds, including measured bandwidth and packets per second. -.It Cm ether +.It Cm ethernet Show the currently loaded Ethernet rules. When used together with .Fl v , diff --git a/sbin/pfctl/pfctl.c b/sbin/pfctl/pfctl.c index ee1b2202cc1d..87343f762842 100644 --- a/sbin/pfctl/pfctl.c +++ b/sbin/pfctl/pfctl.c @@ -305,7 +305,7 @@ struct pfctl_opt_id { }; static const struct pfctl_opt_id showopt_list[] = { - { "ether", SHOWOPT_ETHER }, + { "ethernet", SHOWOPT_ETHER }, { "nat", SHOWOPT_NAT }, { "queue", SHOWOPT_QUEUE }, { "rules", SHOWOPT_RULES }, From nobody Wed Mar 4 17:14:18 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQzmV3MrGz6Smm4 for ; Wed, 04 Mar 2026 17:14: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQzmV2bfsz3wQP for ; Wed, 04 Mar 2026 17:14:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772644458; 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; bh=jwJA6gvRjWn3abM1vhyB2FNVb87/XH/FEGrIk/35qNI=; b=tfrXxYbAbbuPi8ex2BX59xmD4XdIjYlA86WJDogiYej6d4TcFNbjkxYrdlqZlC24rue9jb Wd2XcdcC5scgBzOfRjEEh9koMIARthIgr4aLk5uxUgpQzIVZvKvPPCEGf8CASeN3pLOvMM vzn3GxRkfpDNpl7Xu37MTZI++XTyrzc8783c/P5i1wN4gsdd5p1ssH+YEl/3bfS7YoqFFR Rn08Hn+nMufGRL61TmARLmWCwz0W+xE99AZuokMlQ+qTlSWIGXBo8CdlaahcGFjxVn+1gX v85mXK+qXSQ/CGjICjRQobIOG4z3fIsyv34jqLznhe4z1DghypnyQVk+2ZUB3Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772644458; a=rsa-sha256; cv=none; b=RmRygBQHcf9KRbLIIOUCk9ZUHIKhstjIy18Aa6XJz41pXG5gwhwIwlFz0WpfJC3LEiuDul mKEB6BiYgOmMotfkFhM7K52H18AlebUmIDz2RIPlPjhug6FTmHDCfUGKbTEGVaV0M4NaJ8 nxvKahaMFEDhx6hl0DT6AF0j91moSlxnCnBDARQDRzK52ZaHgcEwMr/G8YZdVsojl+Sz+l q85oHhUg+dHkOQWw4QI/ECngfy0u40BqmHdAEtfgCkaXIqZOnYgcpio1wqmCyiaU5EGSWG z5bMCa1CerfKJYodOnv/hDL11fLTEwYMLc9oZzIXz4oZRfESCkGOC9S9hIqrTA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772644458; 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; bh=jwJA6gvRjWn3abM1vhyB2FNVb87/XH/FEGrIk/35qNI=; b=Nm7VvP4hs3oviY+PPEwZl61nWtsze3QLWxRUxafjmXlhAyzmuoyMmrdxmlHJmsFmLXU5Rs ZySMQAZcziCkFhI1/dQNcl3zFmxUd64GlOmCW+awg5XwArDictsJaZfhilEtysBI558RvY tnNegducgewawmq3sKxqrbbnHOux2Gz9/+9vbFVPlTmJRxoOBzzzFzrTzM5hq0gjBda6Js RmLoDutCLEO/BlmAzeHC8jGj9z37wYdsSldQ2n1JS1uNvenj/15xquBSI5+595UzYoIosf YyYYdVTVbvtpkJ/fNkNpSlaITVOc3tYUYy4ir0ponko5lQLHD/pcfTMyK8viyQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQzmV1wqdz10Bh for ; Wed, 04 Mar 2026 17:14:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3c553 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 17:14:18 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Kajetan Puchalski From: Andrew Turner Subject: git: e40e5458616d - main - arm64: Treat the PMUVer field of ID_AA64DFR0 as unsigned List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: e40e5458616d13b44cd407aa1afff620f8ff8766 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 17:14:18 +0000 Message-Id: <69a8686a.3c553.5a339866@gitrepo.freebsd.org> The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=e40e5458616d13b44cd407aa1afff620f8ff8766 commit e40e5458616d13b44cd407aa1afff620f8ff8766 Author: Kajetan Puchalski AuthorDate: 2026-03-04 15:16:35 +0000 Commit: Andrew Turner CommitDate: 2026-03-04 17:10:52 +0000 arm64: Treat the PMUVer field of ID_AA64DFR0 as unsigned The PMUVer field of ID_AA64DFR0 contains an unsigned version of the Performance Monitors Extension, but it is currently treated as signed. Change it to unsigned. Reviewed by: andrew Sponsored by: Arm Ltd Signed-off-by: Kajetan Puchalski Pull Request: https://github.com/freebsd/freebsd-src/pull/2062 --- sys/arm64/arm64/identcpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/arm64/arm64/identcpu.c b/sys/arm64/arm64/identcpu.c index e2f09fcb7f52..4b5361090ead 100644 --- a/sys/arm64/arm64/identcpu.c +++ b/sys/arm64/arm64/identcpu.c @@ -632,7 +632,7 @@ static const struct mrs_field id_aa64dfr0_fields[] = { MRS_FIELD(ID_AA64DFR0, PMSS, false, MRS_LOWER, 0, id_aa64dfr0_pmss), MRS_FIELD(ID_AA64DFR0, BRPs, false, MRS_LOWER, MRS_USERSPACE, id_aa64dfr0_brps), - MRS_FIELD(ID_AA64DFR0, PMUVer, true, MRS_LOWER, 0, id_aa64dfr0_pmuver), + MRS_FIELD(ID_AA64DFR0, PMUVer, false, MRS_LOWER, 0, id_aa64dfr0_pmuver), MRS_FIELD(ID_AA64DFR0, TraceVer, false, MRS_LOWER, 0, id_aa64dfr0_tracever), MRS_FIELD(ID_AA64DFR0, DebugVer, false, MRS_LOWER | MRS_SAFE(0x6), 0, From nobody Wed Mar 4 17:14:19 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fQzmW3lkNz6SmHp for ; Wed, 04 Mar 2026 17:14: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fQzmW321Mz3w8Z for ; Wed, 04 Mar 2026 17:14:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772644459; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Y1LImEaDI1T9J5FS1VVK75R52/eqP2ORHX1g/HRXDm8=; b=K8rYYV2Lp4Ij8Hx0/Y3QE69Ys0yCNvAls5ye3plKpVFdB/N66OZD1VHiGG6tsed6cH84/r FRhmQiQMjmng5QyS0FVIyvengz3VqJi7u5yeMCrc7Rf/BHhVjpOs9ldIW6CHts0ef85CSk Sp8UOgERdRi9scFZH9Ie/JamkJxo4wysOMeM6BmcLnaOHRCd2uQM58IekRxdbg/SITRPTw VKwY2qMpemz+uyY43qGrxsHnf+haHf6Y5eN8qmtjHtLtvvd8vK+n8yqMhko/MrCyV83S0Q pta+VbzEUdwmvzz2pQ31x0udWCsIjmTUwvZHXfX30Tuy0/k8ducwnkmupizrIg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772644459; a=rsa-sha256; cv=none; b=bxV5RaGibPmaLHN6X9PlwpmeHjM4k9XQKGi0XRC9i88emFSMmHTUCQoXJ646gM0AFY+k8T J2iVfqrzgkkOLMUL86a4OvZcswalFhAc1LiMx6UWyyup86Y2oRXrr2tP8Ps96jP+5eb/+G N256/dy+zcaFDZrclCzk5H9syfF6WJi9MYTmYJSnqV6bpEv+OsGNlC1xnLMBwMNm8bJkWJ 63zROWDF8YaTqct53OKMrCka1dHIVJ3ILJCZYJ3RetJvCRPecG4ilYkXtYdbXhf5ldbMVk A0DPz3+nwAq9MDf060O0Tq6LaJSpzi4dXlgr0Ms2ivyxtZF6JvnQARD47PA4hA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772644459; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Y1LImEaDI1T9J5FS1VVK75R52/eqP2ORHX1g/HRXDm8=; b=D4dtwptF9KVHgr763ALoHJJTcaCjYKzjiUAXWiMzh9QMGDQ0fylipELxUuK/GWG44JJFPH Z4BCFNTJi4CvjiFXZNm1wSYu2MBiFTKu7NxqrDEyG47wwV766pOGYxW8c9AUtCSSJ4rVzG HjlZT20qN3cXBvlU3ruH+Ktx4NGN3abfe6Md71To7zYuwWJcVIbWoVZ5bBWoDyknjiS6dC +S9f3Z7pBHWpNUb/pAjeUsjIoW0ReKKp6uTTZatJWIlG/rUGx1nPyyKo6CfCXfPt7dVBnO C18+HbE+rokr2lwe4lCQ4vhqcPunoVm9+ru4+472CSzYSK87XBgu3TkU/03GwA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fQzmW2Dr8z10wY for ; Wed, 04 Mar 2026 17:14:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3c3e8 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 17:14:19 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Turner Subject: git: d1650d226205 - main - arm64/vmm: Support PMU v3p9 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: d1650d226205cdf07fb19e0c9b10b47b941e8747 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 17:14:19 +0000 Message-Id: <69a8686b.3c3e8.5132c232@gitrepo.freebsd.org> The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=d1650d226205cdf07fb19e0c9b10b47b941e8747 commit d1650d226205cdf07fb19e0c9b10b47b941e8747 Author: Andrew Turner AuthorDate: 2026-03-04 16:35:57 +0000 Commit: Andrew Turner CommitDate: 2026-03-04 17:10:52 +0000 arm64/vmm: Support PMU v3p9 The only new register is read-only. As the kernel just passes the registers to the guest directly no further change should be needed. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D51764 --- sys/arm64/vmm/vmm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/arm64/vmm/vmm.c b/sys/arm64/vmm/vmm.c index 4231746e7eb2..07be8b1707a0 100644 --- a/sys/arm64/vmm/vmm.c +++ b/sys/arm64/vmm/vmm.c @@ -98,7 +98,7 @@ static const struct vmm_regs vmm_arch_regs_masks = { ID_AA64DFR0_CTX_CMPs_MASK | ID_AA64DFR0_WRPs_MASK | ID_AA64DFR0_BRPs_MASK | - ID_AA64DFR0_PMUVer_3 | + ID_AA64DFR0_PMUVer_3_9 | ID_AA64DFR0_DebugVer_8, .id_aa64isar0 = ID_AA64ISAR0_TLB_TLBIOSR | From nobody Wed Mar 4 17:30:20 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR0702jgvz6Sncm for ; Wed, 04 Mar 2026 17:30: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR0701TC5z3y5C for ; Wed, 04 Mar 2026 17:30:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772645420; 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; bh=NL/CHktlUnnwm1CT/Utc3mclLhig9fidARQWbk+xJuk=; b=Y7qtYNzuSL130lisZwfmoQ5/2ZDsghfjX9uNJU3s2IW5F4JpIzez8QmLir9eC+zFsk2NK2 R+D4IH8Y1Bgc5X+8EcNzKr3wPAKjx7LmOef0unhoR6GzQH6SprL1jxN2BHdRANkuuaETdM UsXWMHikhG7OG4L843iG/d/kqYGhVRjweUXCBZFfEwTBtfUHV81D0YmsKI9QiqgDtc6/4o Xb4/B2KdQHkPiqicb0Y0lGGONSZWe1ywRpaPTgYZTSdojPRvdF63qS5n1wn4IAlwpzbfeD ibsB4PcgyOIos4TtgrhxhPQCKpBFqLneqd39q3pGcOG3bv2QKMPUpGkBn0SLog== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772645420; a=rsa-sha256; cv=none; b=TPHF9x5PK0BQkjgPs41epbaN+T86t3ISF0gLUYABRjmRKdcAlzjpH4/9bjSVldaltC1xw+ 3GTpQEBA2bkL6omdAOilUFb0mA7aldUqW56Mp8MPEJoK1adDzELqtYiwt/AiGgL/saHRlk 8rCxeNv/OQra/6/VwvqSueeeMNZgLHh7MbA0VIfjk8XjvtIIAbZ6vEJyunuy7nW3RoXyBK o85x/m4mlbaNfKRHOPluebPHjCP8M7cl9Y8kENUB7dRlRbmq7/UcUi9SYFuoFahMhQzUik 3LDjqMZ0Xzvn1RT93J48ptEIsb+0Y93UTBnVdYO6ERFIPu1Sk3VNDEJyN2sEcA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772645420; 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; bh=NL/CHktlUnnwm1CT/Utc3mclLhig9fidARQWbk+xJuk=; b=HCxgfqGzq4NgFptTHsz9j3epbePu7b0PZbAmNySyt1u2+Hb1Ker9hR+KW4p82jxPuXEsK5 KyxLjrez3NL7GFZauIe7cpBRZg7jjD9bVKbN9LnG9yhaAeMMVtSkomNgp4SUQHp/orqPTU TTroCeCAM8nuaTlIPiV0ujD+PRr0pyIfSnda6BzAoI1srskkxsLQblbiqOSSXLXF7Snq4q YXIYkwK1IGFBYEgIIdpUpjTtlJvPxKO3dn7a8J0Nd+KvyD3vg9uHpyPXRRxEqrjDa7pxkJ zEzK8jKwhunSV6tUheGhEfp/76k4Av15fejF9tNWgrf0TUCPvl2ysNCk8N7tbw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR0700x7Gz118c for ; Wed, 04 Mar 2026 17:30:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3eae0 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 17:30:20 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Hans Rosenfeld From: Ed Maste Subject: git: 2a514d377b37 - main - bhyve/virtio-scsi: Preallocate all I/O requests List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 2a514d377b37a30356c5c27a07b4fb0fd6df4881 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 17:30:20 +0000 Message-Id: <69a86c2c.3eae0.6544adfe@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=2a514d377b37a30356c5c27a07b4fb0fd6df4881 commit 2a514d377b37a30356c5c27a07b4fb0fd6df4881 Author: Hans Rosenfeld AuthorDate: 2025-10-15 21:07:37 +0000 Commit: Ed Maste CommitDate: 2026-03-04 17:30:02 +0000 bhyve/virtio-scsi: Preallocate all I/O requests By preallocating all I/O requests on all queues, we can take most allocations out of the hot I/O code paths and simplify the code significantly. While here, make sure we check all allocations for success and make sure to handle failures gracefully. Additionally, check for I/O request validity as early as possible, and return illegal requests immediately. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D53469 --- usr.sbin/bhyve/pci_virtio_scsi.c | 476 +++++++++++++++++++++++++++++---------- 1 file changed, 359 insertions(+), 117 deletions(-) diff --git a/usr.sbin/bhyve/pci_virtio_scsi.c b/usr.sbin/bhyve/pci_virtio_scsi.c index 5eaf55496467..758e2643f6a0 100644 --- a/usr.sbin/bhyve/pci_virtio_scsi.c +++ b/usr.sbin/bhyve/pci_virtio_scsi.c @@ -102,13 +102,46 @@ struct pci_vtscsi_config { uint32_t max_lun; } __attribute__((packed)); +/* + * I/O request state and I/O request queues + * + * In addition to the control queue and notification queues, each virtio-scsi + * device instance has at least one I/O request queue, the state of which is + * is kept in an array of struct pci_vtscsi_queue in the device softc. + * + * Currently there is only one I/O request queue, but it's trivial to support + * more than one. + * + * Each pci_vtscsi_queue has VTSCSI_RINGSZ pci_vtscsi_request structures pre- + * allocated on vsq_free_requests. For each I/O request coming in on the I/O + * virtqueue, the request queue handler will take a pci_vtscsi_request off + * vsq_free_requests, fills in the data from the I/O virtqueue, puts it on + * vsq_requests, and signals vsq_cv. + * + * There are VTSCSI_THR_PER_Q worker threads for each pci_vtscsi_queue which + * wait on vsq_cv. When signalled, they repeatedly take one pci_vtscsi_request + * off vsq_requests, construct a ctl_io for it, and hand it off to the CTL ioctl + * Interface, which processes it synchronously. After completion of the request, + * the pci_vtscsi_request is re-initialized and put back onto vsq_free_requests. + * + * The worker threads exit when vsq_cv is signalled after vsw_exiting was set. + * + * There are three mutexes to coordinate the accesses to an I/O request queue: + * - vsq_rmtx protects vsq_requests and must be held when waiting on vsq_cv + * - vsq_fmtx protects vsq_free_requests + * - vsq_qmtx must be held when operating on the underlying virtqueue, vsq_vq + */ +STAILQ_HEAD(pci_vtscsi_req_queue, pci_vtscsi_request); + struct pci_vtscsi_queue { struct pci_vtscsi_softc * vsq_sc; struct vqueue_info * vsq_vq; - pthread_mutex_t vsq_mtx; + pthread_mutex_t vsq_rmtx; + pthread_mutex_t vsq_fmtx; pthread_mutex_t vsq_qmtx; pthread_cond_t vsq_cv; - STAILQ_HEAD(, pci_vtscsi_request) vsq_requests; + struct pci_vtscsi_req_queue vsq_requests; + struct pci_vtscsi_req_queue vsq_free_requests; LIST_HEAD(, pci_vtscsi_worker) vsq_workers; }; @@ -124,8 +157,15 @@ struct pci_vtscsi_request { struct iovec vsr_iov[VTSCSI_MAXSEG + SPLIT_IOV_ADDL_IOV]; struct iovec * vsr_iov_in; struct iovec * vsr_iov_out; + struct iovec * vsr_data_iov_in; + struct iovec * vsr_data_iov_out; + struct pci_vtscsi_req_cmd_rd * vsr_cmd_rd; + struct pci_vtscsi_req_cmd_wr * vsr_cmd_wr; + union ctl_io * vsr_ctl_io; size_t vsr_niov_in; size_t vsr_niov_out; + size_t vsr_data_niov_in; + size_t vsr_data_niov_out; uint32_t vsr_idx; STAILQ_ENTRY(pci_vtscsi_request) vsr_link; }; @@ -237,13 +277,27 @@ static void pci_vtscsi_tmf_handle(struct pci_vtscsi_softc *, struct pci_vtscsi_ctrl_tmf *); static void pci_vtscsi_an_handle(struct pci_vtscsi_softc *, struct pci_vtscsi_ctrl_an *); -static int pci_vtscsi_request_handle(struct pci_vtscsi_queue *, struct iovec *, - size_t, struct iovec *, size_t); + +static struct pci_vtscsi_request *pci_vtscsi_alloc_request( + struct pci_vtscsi_softc *); +static void pci_vtscsi_free_request(struct pci_vtscsi_request *); +static struct pci_vtscsi_request *pci_vtscsi_get_request( + struct pci_vtscsi_req_queue *); +static void pci_vtscsi_put_request(struct pci_vtscsi_req_queue *, + struct pci_vtscsi_request *); +static void pci_vtscsi_queue_request(struct pci_vtscsi_softc *, + struct vqueue_info *); +static void pci_vtscsi_return_request(struct pci_vtscsi_queue *, + struct pci_vtscsi_request *, int); +static int pci_vtscsi_request_handle(struct pci_vtscsi_softc *, + struct pci_vtscsi_request *); + static void pci_vtscsi_controlq_notify(void *, struct vqueue_info *); static void pci_vtscsi_eventq_notify(void *, struct vqueue_info *); static void pci_vtscsi_requestq_notify(void *, struct vqueue_info *); static int pci_vtscsi_init_queue(struct pci_vtscsi_softc *, struct pci_vtscsi_queue *, int); +static void pci_vtscsi_destroy_queue(struct pci_vtscsi_queue *); static int pci_vtscsi_init(struct pci_devinst *, nvlist_t *); static struct virtio_consts vtscsi_vi_consts = { @@ -262,37 +316,33 @@ pci_vtscsi_proc(void *arg) { struct pci_vtscsi_worker *worker = (struct pci_vtscsi_worker *)arg; struct pci_vtscsi_queue *q = worker->vsw_queue; - struct pci_vtscsi_request *req; + struct pci_vtscsi_softc *sc = q->vsq_sc; int iolen; for (;;) { - pthread_mutex_lock(&q->vsq_mtx); + struct pci_vtscsi_request *req; - while (STAILQ_EMPTY(&q->vsq_requests) - && !worker->vsw_exiting) - pthread_cond_wait(&q->vsq_cv, &q->vsq_mtx); + pthread_mutex_lock(&q->vsq_rmtx); - if (worker->vsw_exiting) - break; + while (STAILQ_EMPTY(&q->vsq_requests) && !worker->vsw_exiting) + pthread_cond_wait(&q->vsq_cv, &q->vsq_rmtx); - req = STAILQ_FIRST(&q->vsq_requests); - STAILQ_REMOVE_HEAD(&q->vsq_requests, vsr_link); + if (worker->vsw_exiting) { + pthread_mutex_unlock(&q->vsq_rmtx); + return (NULL); + } - pthread_mutex_unlock(&q->vsq_mtx); - iolen = pci_vtscsi_request_handle(q, req->vsr_iov_in, - req->vsr_niov_in, req->vsr_iov_out, req->vsr_niov_out); + req = pci_vtscsi_get_request(&q->vsq_requests); + pthread_mutex_unlock(&q->vsq_rmtx); - pthread_mutex_lock(&q->vsq_qmtx); - vq_relchain(q->vsq_vq, req->vsr_idx, iolen); - vq_endchains(q->vsq_vq, 0); - pthread_mutex_unlock(&q->vsq_qmtx); + DPRINTF("I/O request lun %d, data_niov_in %zu, data_niov_out " + "%zu", pci_vtscsi_get_lun(req->vsr_cmd_rd->lun), + req->vsr_data_niov_in, req->vsr_data_niov_out); - DPRINTF("request completed", req->vsr_idx); - free(req); - } + iolen = pci_vtscsi_request_handle(sc, req); - pthread_mutex_unlock(&q->vsq_mtx); - return (NULL); + pci_vtscsi_return_request(q, req, iolen); + } } static void @@ -395,6 +445,14 @@ pci_vtscsi_tmf_handle(struct pci_vtscsi_softc *sc, int err; io = ctl_scsi_alloc_io(sc->vss_iid); + if (io == NULL) { + WPRINTF("failed to allocate ctl_io: err=%d (%s)", + errno, strerror(errno)); + + tmf->response = VIRTIO_SCSI_S_FAILURE; + return; + } + ctl_scsi_zero_io(io); io->io_hdr.io_type = CTL_IO_TASK; @@ -460,34 +518,112 @@ pci_vtscsi_an_handle(struct pci_vtscsi_softc *sc __unused, { } -static int -pci_vtscsi_request_handle(struct pci_vtscsi_queue *q, struct iovec *iov_in, - size_t niov_in, struct iovec *iov_out, size_t niov_out) +static struct pci_vtscsi_request * +pci_vtscsi_alloc_request(struct pci_vtscsi_softc *sc) { - struct pci_vtscsi_softc *sc = q->vsq_sc; - struct pci_vtscsi_req_cmd_rd *cmd_rd = NULL; - struct pci_vtscsi_req_cmd_wr *cmd_wr; - struct iovec *data_iov_in, *data_iov_out; - union ctl_io *io; - size_t data_niov_in, data_niov_out; - void *ext_data_ptr = NULL; - uint32_t ext_data_len = 0, ext_sg_entries = 0; - int err, nxferred; + struct pci_vtscsi_request *req; + + req = calloc(1, sizeof(struct pci_vtscsi_request)); + if (req == NULL) + goto fail; + + req->vsr_cmd_rd = calloc(1, VTSCSI_IN_HEADER_LEN(sc)); + if (req->vsr_cmd_rd == NULL) + goto fail; + req->vsr_cmd_wr = calloc(1, VTSCSI_OUT_HEADER_LEN(sc)); + if (req->vsr_cmd_wr == NULL) + goto fail; + + req->vsr_ctl_io = ctl_scsi_alloc_io(sc->vss_iid); + if (req->vsr_ctl_io == NULL) + goto fail; + ctl_scsi_zero_io(req->vsr_ctl_io); + + return (req); + +fail: + EPRINTLN("failed to allocate request: %s", strerror(errno)); + + if (req != NULL) + pci_vtscsi_free_request(req); + + return (NULL); +} + +static void +pci_vtscsi_free_request(struct pci_vtscsi_request *req) +{ + if (req->vsr_ctl_io != NULL) + ctl_scsi_free_io(req->vsr_ctl_io); + if (req->vsr_cmd_rd != NULL) + free(req->vsr_cmd_rd); + if (req->vsr_cmd_wr != NULL) + free(req->vsr_cmd_wr); + + free(req); +} + +static struct pci_vtscsi_request * +pci_vtscsi_get_request(struct pci_vtscsi_req_queue *req_queue) +{ + struct pci_vtscsi_request *req; + + assert(!STAILQ_EMPTY(req_queue)); + + req = STAILQ_FIRST(req_queue); + STAILQ_REMOVE_HEAD(req_queue, vsr_link); + + return (req); +} + +static void +pci_vtscsi_put_request(struct pci_vtscsi_req_queue *req_queue, + struct pci_vtscsi_request *req) +{ + STAILQ_INSERT_TAIL(req_queue, req, vsr_link); +} + +static void +pci_vtscsi_queue_request(struct pci_vtscsi_softc *sc, struct vqueue_info *vq) +{ + struct pci_vtscsi_queue *q = &sc->vss_queues[vq->vq_num - 2]; + struct pci_vtscsi_request *req; + struct vi_req vireq; + int n; + + pthread_mutex_lock(&q->vsq_fmtx); + req = pci_vtscsi_get_request(&q->vsq_free_requests); + assert(req != NULL); + pthread_mutex_unlock(&q->vsq_fmtx); + + n = vq_getchain(vq, req->vsr_iov, VTSCSI_MAXSEG, &vireq); + assert(n >= 1 && n <= VTSCSI_MAXSEG); + + req->vsr_idx = vireq.idx; + req->vsr_queue = q; + req->vsr_iov_in = &req->vsr_iov[0]; + req->vsr_niov_in = vireq.readable; + req->vsr_iov_out = &req->vsr_iov[vireq.readable]; + req->vsr_niov_out = vireq.writable; /* * Make sure we got at least enough space for the VirtIO-SCSI * command headers. If not, return this request immediately. */ - if (check_iov_len(iov_out, niov_out, + if (check_iov_len(req->vsr_iov_out, req->vsr_niov_out, VTSCSI_OUT_HEADER_LEN(q->vsq_sc)) == false) { WPRINTF("ignoring request with insufficient output"); - return (0); + req->vsr_cmd_wr->response = VIRTIO_SCSI_S_FAILURE; + pci_vtscsi_return_request(q, req, 1); + return; } - if (check_iov_len(iov_in, niov_in, + if (check_iov_len(req->vsr_iov_in, req->vsr_niov_in, VTSCSI_IN_HEADER_LEN(q->vsq_sc)) == false) { WPRINTF("ignoring request with incomplete header"); - return (0); + req->vsr_cmd_wr->response = VIRTIO_SCSI_S_FAILURE; + pci_vtscsi_return_request(q, req, 1); + return; } /* @@ -500,8 +636,8 @@ pci_vtscsi_request_handle(struct pci_vtscsi_queue *q, struct iovec *iov_in, * by one to make room for a new iovec covering the first part of the * output data portion. */ - data_iov_out = split_iov(iov_out, &niov_out, - VTSCSI_OUT_HEADER_LEN(q->vsq_sc), &data_niov_out); + req->vsr_data_iov_out = split_iov(req->vsr_iov_out, &req->vsr_niov_out, + VTSCSI_OUT_HEADER_LEN(q->vsq_sc), &req->vsr_data_niov_out); /* * Similarly, to not overwrite the first iovec of the output section, @@ -509,43 +645,106 @@ pci_vtscsi_request_handle(struct pci_vtscsi_queue *q, struct iovec *iov_in, * cover the entire iovec array (both input and the already split output * sections). */ - niov_in += niov_out + data_niov_out; + req->vsr_niov_in += req->vsr_niov_out + req->vsr_data_niov_out; - data_iov_in = split_iov(iov_in, &niov_in, - VTSCSI_IN_HEADER_LEN(q->vsq_sc), &data_niov_in); + req->vsr_data_iov_in = split_iov(req->vsr_iov_in, &req->vsr_niov_in, + VTSCSI_IN_HEADER_LEN(q->vsq_sc), &req->vsr_data_niov_in); /* * And of course we now have to adjust data_niov_in accordingly. */ - data_niov_in -= niov_out + data_niov_out; + req->vsr_data_niov_in -= req->vsr_niov_out + req->vsr_data_niov_out; + + /* + * iov_to_buf() realloc()s the buffer given as 3rd argument to the + * total size of all iovecs it will be copying. Since we've just + * truncated it in split_iov(), we know that the size will be + * VTSCSI_IN_HEADER_LEN(q->vsq_sc). + * + * Since we pre-allocated req->vsr_cmd_rd to this size, the realloc() + * should never fail. + * + * This will have to change if we begin allowing config space writes + * to change sense size. + */ + assert(iov_to_buf(req->vsr_iov_in, req->vsr_niov_in, + (void **)&req->vsr_cmd_rd) == VTSCSI_IN_HEADER_LEN(q->vsq_sc)); - iov_to_buf(iov_in, niov_in, (void **)&cmd_rd); + pthread_mutex_lock(&q->vsq_rmtx); + pci_vtscsi_put_request(&q->vsq_requests, req); + pthread_cond_signal(&q->vsq_cv); + pthread_mutex_unlock(&q->vsq_rmtx); - cmd_wr = calloc(1, VTSCSI_OUT_HEADER_LEN(sc)); - io = ctl_scsi_alloc_io(sc->vss_iid); - ctl_scsi_zero_io(io); + DPRINTF("request enqueued", vireq.idx); +} + +static void +pci_vtscsi_return_request(struct pci_vtscsi_queue *q, + struct pci_vtscsi_request *req, int iolen) +{ + void *cmd_rd = req->vsr_cmd_rd; + void *cmd_wr = req->vsr_cmd_wr; + void *ctl_io = req->vsr_ctl_io; + int idx = req->vsr_idx; + + DPRINTF("request completed, response %d", idx, + req->vsr_cmd_wr->response); + + iolen += buf_to_iov(cmd_wr, VTSCSI_OUT_HEADER_LEN(q->vsq_sc), + req->vsr_iov_out, req->vsr_niov_out); + + ctl_scsi_zero_io(req->vsr_ctl_io); + + memset(cmd_rd, 0, VTSCSI_IN_HEADER_LEN(q->vsq_sc)); + memset(cmd_wr, 0, VTSCSI_OUT_HEADER_LEN(q->vsq_sc)); + memset(req, 0, sizeof(struct pci_vtscsi_request)); + + req->vsr_cmd_rd = cmd_rd; + req->vsr_cmd_wr = cmd_wr; + req->vsr_ctl_io = ctl_io; + + pthread_mutex_lock(&q->vsq_fmtx); + pci_vtscsi_put_request(&q->vsq_free_requests, req); + pthread_mutex_unlock(&q->vsq_fmtx); + + pthread_mutex_lock(&q->vsq_qmtx); + vq_relchain(q->vsq_vq, idx, iolen); + vq_endchains(q->vsq_vq, 0); + pthread_mutex_unlock(&q->vsq_qmtx); +} + +static int +pci_vtscsi_request_handle(struct pci_vtscsi_softc *sc, + struct pci_vtscsi_request *req) +{ + union ctl_io *io = req->vsr_ctl_io; + void *ext_data_ptr = NULL; + uint32_t ext_data_len = 0, ext_sg_entries = 0; + int err, nxferred; io->io_hdr.nexus.initid = sc->vss_iid; - io->io_hdr.nexus.targ_lun = pci_vtscsi_get_lun(cmd_rd->lun); + io->io_hdr.nexus.targ_lun = pci_vtscsi_get_lun(req->vsr_cmd_rd->lun); io->io_hdr.io_type = CTL_IO_SCSI; - if (data_niov_in > 0) { - ext_data_ptr = (void *)data_iov_in; - ext_sg_entries = data_niov_in; - ext_data_len = count_iov(data_iov_in, data_niov_in); + if (req->vsr_data_niov_in > 0) { + ext_data_ptr = (void *)req->vsr_data_iov_in; + ext_sg_entries = req->vsr_data_niov_in; + ext_data_len = count_iov(req->vsr_data_iov_in, + req->vsr_data_niov_in); io->io_hdr.flags |= CTL_FLAG_DATA_OUT; - } else if (data_niov_out > 0) { - ext_data_ptr = (void *)data_iov_out; - ext_sg_entries = data_niov_out; - ext_data_len = count_iov(data_iov_out, data_niov_out); + } else if (req->vsr_data_niov_out > 0) { + ext_data_ptr = (void *)req->vsr_data_iov_out; + ext_sg_entries = req->vsr_data_niov_out; + ext_data_len = count_iov(req->vsr_data_iov_out, + req->vsr_data_niov_out); io->io_hdr.flags |= CTL_FLAG_DATA_IN; } io->scsiio.sense_len = sc->vss_config.sense_size; - io->scsiio.tag_num = cmd_rd->id; + io->scsiio.tag_num = req->vsr_cmd_rd->id; io->io_hdr.flags |= CTL_FLAG_USER_TAG; - switch (cmd_rd->task_attr) { + switch (req->vsr_cmd_rd->task_attr) { case VIRTIO_SCSI_S_ORDERED: io->scsiio.tag_type = CTL_TAG_ORDERED; break; @@ -565,7 +764,7 @@ pci_vtscsi_request_handle(struct pci_vtscsi_queue *q, struct iovec *iov_in, io->scsiio.ext_data_len = ext_data_len; io->scsiio.ext_data_filled = 0; io->scsiio.cdb_len = sc->vss_config.cdb_size; - memcpy(io->scsiio.cdb, cmd_rd->cdb, sc->vss_config.cdb_size); + memcpy(io->scsiio.cdb, req->vsr_cmd_rd->cdb, sc->vss_config.cdb_size); if (pci_vtscsi_debug) { struct sbuf *sb = sbuf_new_auto(); @@ -578,22 +777,19 @@ pci_vtscsi_request_handle(struct pci_vtscsi_queue *q, struct iovec *iov_in, err = ioctl(sc->vss_ctl_fd, CTL_IO, io); if (err != 0) { WPRINTF("CTL_IO: err=%d (%s)", errno, strerror(errno)); - cmd_wr->response = VIRTIO_SCSI_S_FAILURE; + req->vsr_cmd_wr->response = VIRTIO_SCSI_S_FAILURE; } else { - cmd_wr->sense_len = MIN(io->scsiio.sense_len, - sc->vss_config.sense_size); - cmd_wr->residual = ext_data_len - io->scsiio.ext_data_filled; - cmd_wr->status = io->scsiio.scsi_status; - cmd_wr->response = VIRTIO_SCSI_S_OK; - memcpy(&cmd_wr->sense, &io->scsiio.sense_data, - cmd_wr->sense_len); + req->vsr_cmd_wr->sense_len = + MIN(io->scsiio.sense_len, sc->vss_config.sense_size); + req->vsr_cmd_wr->residual = ext_data_len - + io->scsiio.ext_data_filled; + req->vsr_cmd_wr->status = io->scsiio.scsi_status; + req->vsr_cmd_wr->response = VIRTIO_SCSI_S_OK; + memcpy(&req->vsr_cmd_wr->sense, &io->scsiio.sense_data, + req->vsr_cmd_wr->sense_len); } - buf_to_iov(cmd_wr, VTSCSI_OUT_HEADER_LEN(sc), iov_out, niov_out); - nxferred = VTSCSI_OUT_HEADER_LEN(sc) + io->scsiio.ext_data_filled; - free(cmd_rd); - free(cmd_wr); - ctl_scsi_free_io(io); + nxferred = io->scsiio.ext_data_filled; return (nxferred); } @@ -635,34 +831,8 @@ pci_vtscsi_eventq_notify(void *vsc __unused, struct vqueue_info *vq) static void pci_vtscsi_requestq_notify(void *vsc, struct vqueue_info *vq) { - struct pci_vtscsi_softc *sc; - struct pci_vtscsi_queue *q; - struct pci_vtscsi_request *req; - struct vi_req vireq; - int n; - - sc = vsc; - q = &sc->vss_queues[vq->vq_num - 2]; - while (vq_has_descs(vq)) { - req = calloc(1, sizeof(struct pci_vtscsi_request)); - - n = vq_getchain(vq, req->vsr_iov, VTSCSI_MAXSEG, &vireq); - assert(n >= 1 && n <= VTSCSI_MAXSEG); - - req->vsr_idx = vireq.idx; - req->vsr_queue = q; - req->vsr_iov_in = &req->vsr_iov[0]; - req->vsr_niov_in = vireq.readable; - req->vsr_iov_out = &req->vsr_iov[vireq.readable]; - req->vsr_niov_out = vireq.writable; - - pthread_mutex_lock(&q->vsq_mtx); - STAILQ_INSERT_TAIL(&q->vsq_requests, req, vsr_link); - pthread_cond_signal(&q->vsq_cv); - pthread_mutex_unlock(&q->vsq_mtx); - - DPRINTF("request enqueued", vireq.idx); + pci_vtscsi_queue_request(vsc, vq); } } @@ -670,32 +840,75 @@ static int pci_vtscsi_init_queue(struct pci_vtscsi_softc *sc, struct pci_vtscsi_queue *queue, int num) { - struct pci_vtscsi_worker *worker; + struct pci_vtscsi_worker *workers; char tname[MAXCOMLEN + 1]; int i; queue->vsq_sc = sc; queue->vsq_vq = &sc->vss_vq[num + 2]; - pthread_mutex_init(&queue->vsq_mtx, NULL); + pthread_mutex_init(&queue->vsq_rmtx, NULL); + pthread_mutex_init(&queue->vsq_fmtx, NULL); pthread_mutex_init(&queue->vsq_qmtx, NULL); pthread_cond_init(&queue->vsq_cv, NULL); STAILQ_INIT(&queue->vsq_requests); + STAILQ_INIT(&queue->vsq_free_requests); LIST_INIT(&queue->vsq_workers); + for (i = 0; i < VTSCSI_RINGSZ; i++) { + struct pci_vtscsi_request *req; + + req = pci_vtscsi_alloc_request(sc); + if (req == NULL) + goto fail; + + pci_vtscsi_put_request(&queue->vsq_free_requests, req); + } + + workers = calloc(VTSCSI_THR_PER_Q, sizeof(struct pci_vtscsi_worker)); + if (workers == NULL) + goto fail; + for (i = 0; i < VTSCSI_THR_PER_Q; i++) { - worker = calloc(1, sizeof(struct pci_vtscsi_worker)); - worker->vsw_queue = queue; + workers[i].vsw_queue = queue; - pthread_create(&worker->vsw_thread, NULL, &pci_vtscsi_proc, - (void *)worker); + pthread_create(&workers[i].vsw_thread, NULL, &pci_vtscsi_proc, + (void *)&workers[i]); snprintf(tname, sizeof(tname), "vtscsi:%d-%d", num, i); - pthread_set_name_np(worker->vsw_thread, tname); - LIST_INSERT_HEAD(&queue->vsq_workers, worker, vsw_link); + pthread_set_name_np(workers[i].vsw_thread, tname); + LIST_INSERT_HEAD(&queue->vsq_workers, &workers[i], vsw_link); } return (0); + +fail: + pci_vtscsi_destroy_queue(queue); + + return (-1); + +} + +static void +pci_vtscsi_destroy_queue(struct pci_vtscsi_queue *queue) +{ + if (queue->vsq_sc == NULL) + return; + + for (int i = VTSCSI_RINGSZ; i > 0; i--) { + struct pci_vtscsi_request *req; + + if (STAILQ_EMPTY(&queue->vsq_free_requests)) + break; + + req = pci_vtscsi_get_request(&queue->vsq_free_requests); + pci_vtscsi_free_request(req); + } + + pthread_cond_destroy(&queue->vsq_cv); + pthread_mutex_destroy(&queue->vsq_qmtx); + pthread_mutex_destroy(&queue->vsq_fmtx); + pthread_mutex_destroy(&queue->vsq_rmtx); } static int @@ -722,9 +935,13 @@ pci_vtscsi_init(struct pci_devinst *pi, nvlist_t *nvl) { struct pci_vtscsi_softc *sc; const char *devname, *value; + int err; int i; sc = calloc(1, sizeof(struct pci_vtscsi_softc)); + if (sc == NULL) + return (-1); + value = get_config_value_node(nvl, "iid"); if (value != NULL) sc->vss_iid = strtoul(value, NULL, 10); @@ -733,8 +950,7 @@ pci_vtscsi_init(struct pci_devinst *pi, nvlist_t *nvl) if (value != NULL) { if (pci_emul_add_boot_device(pi, atoi(value))) { EPRINTLN("Invalid bootindex %d", atoi(value)); - free(sc); - return (-1); + goto fail; } } @@ -744,8 +960,7 @@ pci_vtscsi_init(struct pci_devinst *pi, nvlist_t *nvl) sc->vss_ctl_fd = open(devname, O_RDWR); if (sc->vss_ctl_fd < 0) { WPRINTF("cannot open %s: %s", devname, strerror(errno)); - free(sc); - return (1); + goto fail; } pthread_mutex_init(&sc->vss_mtx, NULL); @@ -753,6 +968,19 @@ pci_vtscsi_init(struct pci_devinst *pi, nvlist_t *nvl) vi_softc_linkup(&sc->vss_vs, &vtscsi_vi_consts, sc, pi, sc->vss_vq); sc->vss_vs.vs_mtx = &sc->vss_mtx; + /* + * Perform a "reset" before we set up our queues. + * + * This will write the default config into vss_config, which is used + * by the rest of the driver to get the request header size. Note that + * if we ever allow the guest to override sense size through config + * space writes, pre-allocation of I/O requests will have to change + * accordingly. + */ + pthread_mutex_lock(&sc->vss_mtx); + pci_vtscsi_reset(sc); + pthread_mutex_unlock(&sc->vss_mtx); + /* controlq */ sc->vss_vq[0].vq_qsize = VTSCSI_RINGSZ; sc->vss_vq[0].vq_notify = pci_vtscsi_controlq_notify; @@ -765,7 +993,10 @@ pci_vtscsi_init(struct pci_devinst *pi, nvlist_t *nvl) for (i = 2; i < VTSCSI_MAXQ; i++) { sc->vss_vq[i].vq_qsize = VTSCSI_RINGSZ; sc->vss_vq[i].vq_notify = pci_vtscsi_requestq_notify; - pci_vtscsi_init_queue(sc, &sc->vss_queues[i - 2], i - 2); + + err = pci_vtscsi_init_queue(sc, &sc->vss_queues[i - 2], i - 2); + if (err != 0) + goto fail; } /* initialize config space */ @@ -776,10 +1007,21 @@ pci_vtscsi_init(struct pci_devinst *pi, nvlist_t *nvl) pci_set_cfgdata16(pi, PCIR_SUBVEND_0, VIRTIO_VENDOR); if (vi_intr_init(&sc->vss_vs, 1, fbsdrun_virtio_msix())) - return (1); + goto fail; + vi_set_io_bar(&sc->vss_vs, 0); return (0); + +fail: + for (i = 2; i < VTSCSI_MAXQ; i++) + pci_vtscsi_destroy_queue(&sc->vss_queues[i - 2]); + + if (sc->vss_ctl_fd > 0) + close(sc->vss_ctl_fd); + + free(sc); + return (-1); } From nobody Wed Mar 4 17:30:21 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR0712zj3z6SnW0 for ; Wed, 04 Mar 2026 17:30: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR0711gqGz3xtt for ; Wed, 04 Mar 2026 17:30:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772645421; 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; bh=0HFC45LzAekJ8v7menuO6YQTCJ2EsLLArt2yAS16rjg=; b=ZoRGKazSYkljjPRiWf0mCl79gLorobZl/TXbDTUKHhXEXw1hTE0SbRSW4RYeaI+cRxwXxe I9EIhnozrwz1RyRnIH8CohMEqFQPDovvMj1f00+ZyThV/njEq3aEZlnlOUvWki6DPurll0 8mtParmNXJB3Hs9meMXPtdKjnAg2FZx8hlBltzSGmpx1L0/5Ye1n4fNiTSfgqZBtWdt3Wb nKV8uhpPhV6u5PGj32TkNje3I96+2/c1MqvNIK91Co+FrUWokLADYhwxd0JWFbivJWJaa3 P4GUivSH3n7mRRDWaLxKh6lU0Q9S+7omkX/UwsysA21bkvUVD7EUaBkD/RL/Vg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772645421; a=rsa-sha256; cv=none; b=mIsDEabkf4T3VDKAREGo3kSi+ysk4Dd81Oznou1vTEOBY8jhrvOiJGqdTSQysn0bgAcXFY RfRk09Sk/nVGWpeg/fJSfELdmirH6q+ByOLwqM7thQ6B+6DwuGBnSS92SLL8CJU7eSzMCb 61QisbqW4/KPhdx+jg4iVU+3TUERTrhI1Noh+q9j6vTnbc+6KcLSGxQumWKobNB1zpXV1W bciI21HlR9jJYIFlr/2thZof/ZrC3j/WCXiPaTX4UJi//V4fXlPufFUFuuVY3zKFEn61Cy LksFDOg9dWrE6gmepBCWbheS0XJ2GaDBD0qV6IVSaG6uzVsIuf959Xz4c3JZCg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772645421; 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; bh=0HFC45LzAekJ8v7menuO6YQTCJ2EsLLArt2yAS16rjg=; b=rObHKlI64VqbGTfsGY2s7hHit9lU6X3MTJsJOSvBpRqQRrXauttw6cX5oQgkbu3iRBcKYB 6bFcyzRzyq37dOxaEneikrKyKOTdJvrurbvNBO+dMK9hYTgGXU818uydz2G3ogHAZGJBIj mbTTZbxE9HefEX62Wz6AN3zQOP0X9pvGFstINvE6pItyOw0735FKY/FlK00qwnp5caDYl3 tyDY4X4Eg2mv/+v1N0EuhVc7VeBMQ4GzV1KO22WEth5F2fobuI0B0wrb2Dk7gj9qhN0W/2 R1X105dy5V4Bc/WuqSb/GFNwyx2q6b+sBebAD/TV9nZkIlLFWxN9jTnSVvGfIw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR0711Gylz10Xt for ; Wed, 04 Mar 2026 17:30:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 409ab by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 17:30:21 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Hans Rosenfeld From: Ed Maste Subject: git: 4dfeadc32e46 - main - bhyve/virtio-scsi: Check LUN address validity List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 4dfeadc32e464557c2aa450212ac419bc567d1e6 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 17:30:21 +0000 Message-Id: <69a86c2d.409ab.42ac10c5@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=4dfeadc32e464557c2aa450212ac419bc567d1e6 commit 4dfeadc32e464557c2aa450212ac419bc567d1e6 Author: Hans Rosenfeld AuthorDate: 2025-10-28 08:51:26 +0000 Commit: Ed Maste CommitDate: 2026-03-04 17:30:02 +0000 bhyve/virtio-scsi: Check LUN address validity Instead of blindly trusting the guest OS driver that it sends us well- formed LUN addresses, check the LUN address for validity and fail the request if it is invalid. While here, constify the members of the virtio requests which aren't device-writable anyway. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D53470 --- usr.sbin/bhyve/pci_virtio_scsi.c | 123 ++++++++++++++++++++++++++++++++++----- 1 file changed, 108 insertions(+), 15 deletions(-) diff --git a/usr.sbin/bhyve/pci_virtio_scsi.c b/usr.sbin/bhyve/pci_virtio_scsi.c index 758e2643f6a0..dafff50fa531 100644 --- a/usr.sbin/bhyve/pci_virtio_scsi.c +++ b/usr.sbin/bhyve/pci_virtio_scsi.c @@ -200,10 +200,10 @@ struct pci_vtscsi_softc { #define VIRTIO_SCSI_S_FUNCTION_REJECTED 11 struct pci_vtscsi_ctrl_tmf { - uint32_t type; - uint32_t subtype; - uint8_t lun[8]; - uint64_t id; + const uint32_t type; + const uint32_t subtype; + const uint8_t lun[8]; + const uint64_t id; uint8_t response; } __attribute__((packed)); @@ -216,9 +216,9 @@ struct pci_vtscsi_ctrl_tmf { #define VIRTIO_SCSI_EVT_ASYNC_DEVICE_BUSY 64 struct pci_vtscsi_ctrl_an { - uint32_t type; - uint8_t lun[8]; - uint32_t event_requested; + const uint32_t type; + const uint8_t lun[8]; + const uint32_t event_requested; uint32_t event_actual; uint8_t response; } __attribute__((packed)); @@ -249,12 +249,12 @@ struct pci_vtscsi_event { } __attribute__((packed)); struct pci_vtscsi_req_cmd_rd { - uint8_t lun[8]; - uint64_t id; - uint8_t task_attr; - uint8_t prio; - uint8_t crn; - uint8_t cdb[]; + const uint8_t lun[8]; + const uint64_t id; + const uint8_t task_attr; + const uint8_t prio; + const uint8_t crn; + const uint8_t cdb[]; } __attribute__((packed)); struct pci_vtscsi_req_cmd_wr { @@ -271,7 +271,10 @@ static void pci_vtscsi_reset(void *); static void pci_vtscsi_neg_features(void *, uint64_t); static int pci_vtscsi_cfgread(void *, int, int, uint32_t *); static int pci_vtscsi_cfgwrite(void *, int, int, uint32_t); -static inline int pci_vtscsi_get_lun(uint8_t *); + +static inline bool pci_vtscsi_check_lun(const uint8_t *); +static inline int pci_vtscsi_get_lun(const uint8_t *); + static void pci_vtscsi_control_handle(struct pci_vtscsi_softc *, void *, size_t); static void pci_vtscsi_tmf_handle(struct pci_vtscsi_softc *, struct pci_vtscsi_ctrl_tmf *); @@ -398,9 +401,76 @@ pci_vtscsi_cfgwrite(void *vsc __unused, int offset __unused, int size __unused, return (0); } +/* + * LUN address parsing + * + * The LUN address consists of 8 bytes. While the spec describes this as 0x01, + * followed by the target byte, followed by a "single-level LUN structure", + * this is actually the same as a hierarchical LUN address as defined by SAM-5, + * consisting of four levels of addressing, where in each level the two MSB of + * byte 0 select the address mode used in the remaining bits and bytes. + * + * + * Only the first two levels are acutally used by virtio-scsi: + * + * Level 1: 0x01, 0xTT: Peripheral Device Addressing: Bus 1, Target 0-255 + * Level 2: 0xLL, 0xLL: Peripheral Device Addressing: Bus MBZ, LUN 0-255 + * or: Flat Space Addressing: LUN (0-16383) + * Level 3 and 4: not used, MBZ + * + * Currently, we only support Target 0. + * + * Alternatively, the first level may contain an extended LUN address to select + * the REPORT_LUNS well-known logical unit: + * + * Level 1: 0xC1, 0x01: Extended LUN Adressing, Well-Known LUN 1 (REPORT_LUNS) + * Level 2, 3, and 4: not used, MBZ + * + * The virtio spec says that we SHOULD implement the REPORT_LUNS well-known + * logical unit but we currently don't. + * + * According to the virtio spec, these are the only LUNS address formats to be + * used with virtio-scsi. + */ + +/* + * Check that the given LUN address conforms to the virtio spec, does not + * address an unknown target, and especially does not address the REPORT_LUNS + * well-known logical unit. + */ +static inline bool +pci_vtscsi_check_lun(const uint8_t *lun) +{ + if (lun[0] == 0xC1) + return (false); + + if (lun[0] != 0x01) + return (false); + + if (lun[1] != 0x00) + return (false); + + if (lun[2] != 0x00 && (lun[2] & 0xc0) != 0x40) + return (false); + + if (lun[4] != 0 || lun[5] != 0 || lun[6] != 0 || lun[7] != 0) + return (false); + + return (true); +} + +/* + * Get the LUN id from a LUN address. + * + * Every code path using this function must have called pci_vtscsi_check_lun() + * before to make sure the LUN address is valid. + */ static inline int -pci_vtscsi_get_lun(uint8_t *lun) +pci_vtscsi_get_lun(const uint8_t *lun) { + assert(lun[0] == 0x01); + assert(lun[1] == 0x00); + assert(lun[2] == 0x00 || (lun[2] & 0xc0) == 0x40); return (((lun[2] << 8) | lun[3]) & 0x3fff); } @@ -444,6 +514,16 @@ pci_vtscsi_tmf_handle(struct pci_vtscsi_softc *sc, union ctl_io *io; int err; + if (pci_vtscsi_check_lun(tmf->lun) == false) { + DPRINTF("TMF request to invalid LUN %.2hhx%.2hhx-%.2hhx%.2hhx-" + "%.2hhx%.2hhx-%.2hhx%.2hhx", tmf->lun[0], tmf->lun[1], + tmf->lun[2], tmf->lun[3], tmf->lun[4], tmf->lun[5], + tmf->lun[6], tmf->lun[7]); + + tmf->response = VIRTIO_SCSI_S_BAD_TARGET; + return; + } + io = ctl_scsi_alloc_io(sc->vss_iid); if (io == NULL) { WPRINTF("failed to allocate ctl_io: err=%d (%s)", @@ -670,6 +750,19 @@ pci_vtscsi_queue_request(struct pci_vtscsi_softc *sc, struct vqueue_info *vq) assert(iov_to_buf(req->vsr_iov_in, req->vsr_niov_in, (void **)&req->vsr_cmd_rd) == VTSCSI_IN_HEADER_LEN(q->vsq_sc)); + /* Make sure this request addresses a valid LUN. */ + if (pci_vtscsi_check_lun(req->vsr_cmd_rd->lun) == false) { + DPRINTF("I/O request to invalid LUN " + "%.2hhx%.2hhx-%.2hhx%.2hhx-%.2hhx%.2hhx-%.2hhx%.2hhx", + req->vsr_cmd_rd->lun[0], req->vsr_cmd_rd->lun[1], + req->vsr_cmd_rd->lun[2], req->vsr_cmd_rd->lun[3], + req->vsr_cmd_rd->lun[4], req->vsr_cmd_rd->lun[5], + req->vsr_cmd_rd->lun[6], req->vsr_cmd_rd->lun[7]); + req->vsr_cmd_wr->response = VIRTIO_SCSI_S_BAD_TARGET; + pci_vtscsi_return_request(q, req, 1); + return; + } + pthread_mutex_lock(&q->vsq_rmtx); pci_vtscsi_put_request(&q->vsq_requests, req); pthread_cond_signal(&q->vsq_cv); From nobody Wed Mar 4 17:30:19 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR0744nSGz6SnRs for ; Wed, 04 Mar 2026 17:30: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR0742P57z3xsB for ; Wed, 04 Mar 2026 17:30:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772645424; 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; bh=G/agU4BF2wxoEgY9236aSgvhW3oFVUlfmKi7kZEuH2A=; b=CZ73UdeLB0o23X+9jQA9OlxeJGMVgaRWyKqnAxUhy3XPgYiq6GOfvBVdPOg8jKhpvya/ok Qc2tGY1AoLoAEsRZYrwWw+AakUnDrk0qdQ3TtOcNwLx1IphH1VSGlFtiabLS3qfwKrhKqG RZDtA1nW82gSgnh6pB83J3qhTaTDWVh/Ss5eVljC+dau0RpcleWraBLWdz6kZLabhS9JB/ R60/6f1St0TytgoTp4QlbWT06STZG+5YOfBgkxc3q5O9pwk/Jupfz5hj7SjBbCfFcGt94N di+mUfqcb8HINKqa8JiwDuG6Iu7PG5Np5RvsiXdAmsxDtd+67oJx8+dwBg+Wnw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772645424; a=rsa-sha256; cv=none; b=DNGfKHEWpzk1XKgGqMk3/f5pW+ZxV/DgiFItx2iDVlA1QoEzvvH6HQTfXmsyqBN6E/cMPK k1yJMBZPDcS1P8eS8vha4CAW97XqfkoQdhgrtAHrOwgLx6MK34nrd1bDaRKgAD4su6CgVS RK8DNle/dsWsvC2kOtOKUWenbxx5CHtcbvLsjumsoOmOrNH4YXi2wW3cO5ROo2azCJDjt7 5Et26iGndzuDP+M+Aks7Mf0PK8u4CLLhyqi6BZdtzK4+hsngIseD4G4eObUtHgRchIwz/c AIP4Km1fynqX5E8TYDyXRGvydLc4R4Pj6EGU/w+yfr+sMyzs7rZ9Elu/+Fp43w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772645424; 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; bh=G/agU4BF2wxoEgY9236aSgvhW3oFVUlfmKi7kZEuH2A=; b=eWeyxvWWs0qkSHF4Rb6s99CC2tIgrOBvETnYoA1AgZcW+mny5k4ScXZuG0yW1QWdJKkIUc La29NXY1WQ1AoUChpRc4m8/0g3QPReXgc8HvJCcPgwLw2KxPj4EFsMkjVL2NHJVk16gXl0 IdBPuxSCmZ/1sPD+lFVS4dJiC76bwzsa3TaLY9cwMeXgL/0NGkl+pb9Q/Yw9zGRbn97DOI I+Z6Ov0hl+VnzupHr1ouyt33vBcpeFdwjE1A7ObYJUwiZyOy5g9e+JzploNPWxFW+rhKQZ CaThe/OKrFBA+wIS8crPPn/y3K1jBQLpHyrpFbwbYBTye4DkdX8Mk/B9IJRemA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR0741NWTz118g for ; Wed, 04 Mar 2026 17:30:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3f5a5 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 17:30:19 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Hans Rosenfeld From: Ed Maste Subject: git: a28cf86c4171 - main - bhyve/virtio: Rework iovec handling functions for efficiency and clarity List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: a28cf86c4171fbd004d02f331026e1a946d85778 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 17:30:19 +0000 Message-Id: <69a86c2b.3f5a5.741e2f82@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=a28cf86c4171fbd004d02f331026e1a946d85778 commit a28cf86c4171fbd004d02f331026e1a946d85778 Author: Hans Rosenfeld AuthorDate: 2025-10-28 10:33:42 +0000 Commit: Ed Maste CommitDate: 2026-03-04 17:30:02 +0000 bhyve/virtio: Rework iovec handling functions for efficiency and clarity Add check_iov_len() to check whether an iovec array covers a certain length without the need to call count_iov() on the whole array first. Garbage-collect the 'seek' argument to buf_to_iov(), used only by virtio-scsi control request handling. The apparent benefit of using it to copy only the final status byte instead of the whole TMF or AN request (25 and 21 bytes, respectively) is dubious at best, given that the extra code to handle this in buf_to_iov() allocates and frees a new iovec array and uses seek_iov(), which traverses the whole array and copies iovecs around. Replace seek_iov() and truncate_iov(), used only by virtio-scsi, with a single function split_iov() which combines the functionality of both in a more efficient way: While seek_iov() always copies all iovecs past the seek offset into a new iovec array, split_iov() works in place and doesn't copy iovecs unless actually necessary. By using split_iov(), we can avoid almost all copying of iovecs in I/O handling code paths of virtio-scsi. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D53468 --- usr.sbin/bhyve/iov.c | 106 ++++++++++++++++++----------------- usr.sbin/bhyve/iov.h | 18 +++--- usr.sbin/bhyve/net_backends.c | 2 +- usr.sbin/bhyve/pci_virtio_scsi.c | 116 +++++++++++++++++++++++---------------- 4 files changed, 136 insertions(+), 106 deletions(-) diff --git a/usr.sbin/bhyve/iov.c b/usr.sbin/bhyve/iov.c index 2bad55267ff3..16d7765b437b 100644 --- a/usr.sbin/bhyve/iov.c +++ b/usr.sbin/bhyve/iov.c @@ -3,6 +3,7 @@ * * Copyright (c) 2016 Jakub Klama . * Copyright (c) 2018 Alexander Motin + * Copyright (c) 2026 Hans Rosenfeld * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -32,70 +33,88 @@ #include #include +#include +#include +#include #include #include #include "iov.h" -void -seek_iov(const struct iovec *iov1, int niov1, struct iovec *iov2, int *niov2, - size_t seek) -{ - size_t remainder = 0; - size_t left = seek; - int i, j; - - for (i = 0; i < niov1; i++) { - size_t toseek = MIN(left, iov1[i].iov_len); - left -= toseek; - if (toseek == iov1[i].iov_len) - continue; +/* + * Given an iovec and an offset, split the iovec into two at the offset and + * return a pointer to the beginning of the second iovec. + * + * The caller is responsible for providing an extra iovec in the array for the + * split. That is, there should be space for *niov1 + 1 iovecs in the array. + */ +struct iovec * +split_iov(struct iovec *iov, size_t *niov1, size_t offset, size_t *niov2) +{ + size_t count, resid; - if (left == 0) { - remainder = toseek; + /* Find the iovec entry that contains the offset. */ + resid = offset; + for (count = 0; count < *niov1; count++) { + if (resid < iov[count].iov_len) break; - } + resid -= iov[count].iov_len; } - for (j = i; j < niov1; j++) { - iov2[j - i].iov_base = (char *)iov1[j].iov_base + remainder; - iov2[j - i].iov_len = iov1[j].iov_len - remainder; - remainder = 0; + if (resid == 0 || count == *niov1) { + /* Easy case, we don't have to split an iovec entry. */ + *niov2 = *niov1 - count; + *niov1 = count; + if (*niov2 == 0) + return (NULL); + return (&iov[count]); } - *niov2 = j - i; + /* The entry iov[count] needs to be split. */ + *niov1 = count + 1; + *niov2 = *niov1 - count; + memmove(&iov[count + 1], &iov[count], sizeof(struct iovec) * (*niov2)); + iov[count].iov_len = resid; + iov[count + 1].iov_base = (char *)iov[count].iov_base + resid; + iov[count + 1].iov_len -= resid; + return (&iov[count + 1]); } size_t -count_iov(const struct iovec *iov, int niov) +count_iov(const struct iovec *iov, size_t niov) { size_t total = 0; - int i; + size_t i; - for (i = 0; i < niov; i++) + for (i = 0; i < niov; i++) { + assert(total <= SIZE_MAX - iov[i].iov_len); total += iov[i].iov_len; + } return (total); } -void -truncate_iov(struct iovec *iov, int *niov, size_t length) +bool +check_iov_len(const struct iovec *iov, size_t niov, size_t len) { - int i; + size_t total = 0; + size_t i; - for (i = 0; i < *niov && length > 0; i++) { - if (length < iov[i].iov_len) - iov[i].iov_len = length; - length -= iov[i].iov_len; + for (i = 0; i < niov; i++) { + assert(total <= SIZE_MAX - iov[i].iov_len); + total += iov[i].iov_len; + if (total >= len) + return (true); } - *niov = i; + + return (false); } ssize_t -iov_to_buf(const struct iovec *iov, int niov, void **buf) +iov_to_buf(const struct iovec *iov, size_t niov, void **buf) { size_t ptr, total; - int i; + size_t i; total = count_iov(iov, niov); *buf = realloc(*buf, total); @@ -111,21 +130,10 @@ iov_to_buf(const struct iovec *iov, int niov, void **buf) } ssize_t -buf_to_iov(const void *buf, size_t buflen, const struct iovec *iov, int niov, - size_t seek) +buf_to_iov(const void *buf, size_t buflen, const struct iovec *iov, size_t niov) { - struct iovec *diov; size_t off = 0, len; - int i; - - if (seek > 0) { - int ndiov; - - diov = malloc(sizeof(struct iovec) * niov); - seek_iov(iov, niov, diov, &ndiov, seek); - iov = diov; - niov = ndiov; - } + size_t i; for (i = 0; i < niov && off < buflen; i++) { len = MIN(iov[i].iov_len, buflen - off); @@ -133,9 +141,5 @@ buf_to_iov(const void *buf, size_t buflen, const struct iovec *iov, int niov, off += len; } - if (seek > 0) - free(diov); - return ((ssize_t)off); } - diff --git a/usr.sbin/bhyve/iov.h b/usr.sbin/bhyve/iov.h index aef0a2e1ee49..e14a9bc7e019 100644 --- a/usr.sbin/bhyve/iov.h +++ b/usr.sbin/bhyve/iov.h @@ -3,6 +3,7 @@ * * Copyright (c) 2016 Jakub Klama . * Copyright (c) 2018 Alexander Motin + * Copyright (c) 2026 Hans Rosenfeld * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -31,12 +32,15 @@ #ifndef _IOV_H_ #define _IOV_H_ -void seek_iov(const struct iovec *iov1, int niov1, struct iovec *iov2, - int *niov2, size_t seek); -void truncate_iov(struct iovec *iov, int *niov, size_t length); -size_t count_iov(const struct iovec *iov, int niov); -ssize_t iov_to_buf(const struct iovec *iov, int niov, void **buf); -ssize_t buf_to_iov(const void *buf, size_t buflen, const struct iovec *iov, - int niov, size_t seek); +#include + +/* Number of additional iovecs required for split_iov() */ +#define SPLIT_IOV_ADDL_IOV 2 + +struct iovec *split_iov(struct iovec *, size_t *, size_t, size_t *); +size_t count_iov(const struct iovec *, size_t); +bool check_iov_len(const struct iovec *, size_t, size_t); +ssize_t iov_to_buf(const struct iovec *, size_t, void **); +ssize_t buf_to_iov(const void *, size_t, const struct iovec *, size_t); #endif /* _IOV_H_ */ diff --git a/usr.sbin/bhyve/net_backends.c b/usr.sbin/bhyve/net_backends.c index 95909d1f8ea2..e7421df3492a 100644 --- a/usr.sbin/bhyve/net_backends.c +++ b/usr.sbin/bhyve/net_backends.c @@ -198,7 +198,7 @@ tap_recv(struct net_backend *be, const struct iovec *iov, int iovcnt) * we read it from there. */ ret = buf_to_iov(priv->bbuf, priv->bbuflen, - iov, iovcnt, 0); + iov, iovcnt); /* Mark the bounce buffer as empty. */ priv->bbuflen = 0; diff --git a/usr.sbin/bhyve/pci_virtio_scsi.c b/usr.sbin/bhyve/pci_virtio_scsi.c index bb0b18c51571..5eaf55496467 100644 --- a/usr.sbin/bhyve/pci_virtio_scsi.c +++ b/usr.sbin/bhyve/pci_virtio_scsi.c @@ -3,6 +3,7 @@ * * Copyright (c) 2016 Jakub Klama . * Copyright (c) 2018 Marcelo Araujo . + * Copyright (c) 2026 Hans Rosenfeld * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -120,10 +121,11 @@ struct pci_vtscsi_worker { struct pci_vtscsi_request { struct pci_vtscsi_queue * vsr_queue; - struct iovec vsr_iov_in[VTSCSI_MAXSEG]; - int vsr_niov_in; - struct iovec vsr_iov_out[VTSCSI_MAXSEG]; - int vsr_niov_out; + struct iovec vsr_iov[VTSCSI_MAXSEG + SPLIT_IOV_ADDL_IOV]; + struct iovec * vsr_iov_in; + struct iovec * vsr_iov_out; + size_t vsr_niov_in; + size_t vsr_niov_out; uint32_t vsr_idx; STAILQ_ENTRY(pci_vtscsi_request) vsr_link; }; @@ -230,13 +232,13 @@ static void pci_vtscsi_neg_features(void *, uint64_t); static int pci_vtscsi_cfgread(void *, int, int, uint32_t *); static int pci_vtscsi_cfgwrite(void *, int, int, uint32_t); static inline int pci_vtscsi_get_lun(uint8_t *); -static int pci_vtscsi_control_handle(struct pci_vtscsi_softc *, void *, size_t); -static int pci_vtscsi_tmf_handle(struct pci_vtscsi_softc *, +static void pci_vtscsi_control_handle(struct pci_vtscsi_softc *, void *, size_t); +static void pci_vtscsi_tmf_handle(struct pci_vtscsi_softc *, struct pci_vtscsi_ctrl_tmf *); -static int pci_vtscsi_an_handle(struct pci_vtscsi_softc *, +static void pci_vtscsi_an_handle(struct pci_vtscsi_softc *, struct pci_vtscsi_ctrl_an *); static int pci_vtscsi_request_handle(struct pci_vtscsi_queue *, struct iovec *, - int, struct iovec *, int); + size_t, struct iovec *, size_t); static void pci_vtscsi_controlq_notify(void *, struct vqueue_info *); static void pci_vtscsi_eventq_notify(void *, struct vqueue_info *); static void pci_vtscsi_requestq_notify(void *, struct vqueue_info *); @@ -353,7 +355,7 @@ pci_vtscsi_get_lun(uint8_t *lun) return (((lun[2] << 8) | lun[3]) & 0x3fff); } -static int +static void pci_vtscsi_control_handle(struct pci_vtscsi_softc *sc, void *buf, size_t bufsize) { @@ -363,7 +365,7 @@ pci_vtscsi_control_handle(struct pci_vtscsi_softc *sc, void *buf, if (bufsize < sizeof(uint32_t)) { WPRINTF("ignoring truncated control request"); - return (0); + return; } type = *(uint32_t *)buf; @@ -371,25 +373,21 @@ pci_vtscsi_control_handle(struct pci_vtscsi_softc *sc, void *buf, if (type == VIRTIO_SCSI_T_TMF) { if (bufsize != sizeof(*tmf)) { WPRINTF("ignoring tmf request with size %zu", bufsize); - return (0); + return; } tmf = (struct pci_vtscsi_ctrl_tmf *)buf; - return (pci_vtscsi_tmf_handle(sc, tmf)); - } - - if (type == VIRTIO_SCSI_T_AN_QUERY) { + pci_vtscsi_tmf_handle(sc, tmf); + } else if (type == VIRTIO_SCSI_T_AN_QUERY) { if (bufsize != sizeof(*an)) { WPRINTF("ignoring AN request with size %zu", bufsize); - return (0); + return; } an = (struct pci_vtscsi_ctrl_an *)buf; - return (pci_vtscsi_an_handle(sc, an)); + pci_vtscsi_an_handle(sc, an); } - - return (0); } -static int +static void pci_vtscsi_tmf_handle(struct pci_vtscsi_softc *sc, struct pci_vtscsi_ctrl_tmf *tmf) { @@ -454,46 +452,73 @@ pci_vtscsi_tmf_handle(struct pci_vtscsi_softc *sc, tmf->response = io->taskio.task_status; ctl_scsi_free_io(io); - return (1); } -static int +static void pci_vtscsi_an_handle(struct pci_vtscsi_softc *sc __unused, struct pci_vtscsi_ctrl_an *an __unused) { - return (0); } static int pci_vtscsi_request_handle(struct pci_vtscsi_queue *q, struct iovec *iov_in, - int niov_in, struct iovec *iov_out, int niov_out) + size_t niov_in, struct iovec *iov_out, size_t niov_out) { struct pci_vtscsi_softc *sc = q->vsq_sc; struct pci_vtscsi_req_cmd_rd *cmd_rd = NULL; struct pci_vtscsi_req_cmd_wr *cmd_wr; - struct iovec data_iov_in[VTSCSI_MAXSEG], data_iov_out[VTSCSI_MAXSEG]; + struct iovec *data_iov_in, *data_iov_out; union ctl_io *io; - int data_niov_in, data_niov_out; + size_t data_niov_in, data_niov_out; void *ext_data_ptr = NULL; uint32_t ext_data_len = 0, ext_sg_entries = 0; int err, nxferred; - if (count_iov(iov_out, niov_out) < VTSCSI_OUT_HEADER_LEN(sc)) { + /* + * Make sure we got at least enough space for the VirtIO-SCSI + * command headers. If not, return this request immediately. + */ + if (check_iov_len(iov_out, niov_out, + VTSCSI_OUT_HEADER_LEN(q->vsq_sc)) == false) { WPRINTF("ignoring request with insufficient output"); return (0); } - if (count_iov(iov_in, niov_in) < VTSCSI_IN_HEADER_LEN(sc)) { + + if (check_iov_len(iov_in, niov_in, + VTSCSI_IN_HEADER_LEN(q->vsq_sc)) == false) { WPRINTF("ignoring request with incomplete header"); return (0); } - seek_iov(iov_in, niov_in, data_iov_in, &data_niov_in, - VTSCSI_IN_HEADER_LEN(sc)); - seek_iov(iov_out, niov_out, data_iov_out, &data_niov_out, - VTSCSI_OUT_HEADER_LEN(sc)); + /* + * We have to split the iovec array into a header and data portion each + * for input and output. + * + * We need to start with the output section (at the end of iov) in case + * the iovec covering the final part of the output header needs to be + * split, in which case split_iov() will move all reamaining iovecs up + * by one to make room for a new iovec covering the first part of the + * output data portion. + */ + data_iov_out = split_iov(iov_out, &niov_out, + VTSCSI_OUT_HEADER_LEN(q->vsq_sc), &data_niov_out); + + /* + * Similarly, to not overwrite the first iovec of the output section, + * the 2nd call to split_iov() to split the input section must actually + * cover the entire iovec array (both input and the already split output + * sections). + */ + niov_in += niov_out + data_niov_out; + + data_iov_in = split_iov(iov_in, &niov_in, + VTSCSI_IN_HEADER_LEN(q->vsq_sc), &data_niov_in); + + /* + * And of course we now have to adjust data_niov_in accordingly. + */ + data_niov_in -= niov_out + data_niov_out; - truncate_iov(iov_in, &niov_in, VTSCSI_IN_HEADER_LEN(sc)); - truncate_iov(iov_out, &niov_out, VTSCSI_OUT_HEADER_LEN(sc)); iov_to_buf(iov_in, niov_in, (void **)&cmd_rd); cmd_wr = calloc(1, VTSCSI_OUT_HEADER_LEN(sc)); @@ -564,7 +589,7 @@ pci_vtscsi_request_handle(struct pci_vtscsi_queue *q, struct iovec *iov_in, cmd_wr->sense_len); } - buf_to_iov(cmd_wr, VTSCSI_OUT_HEADER_LEN(sc), iov_out, niov_out, 0); + buf_to_iov(cmd_wr, VTSCSI_OUT_HEADER_LEN(sc), iov_out, niov_out); nxferred = VTSCSI_OUT_HEADER_LEN(sc) + io->scsiio.ext_data_filled; free(cmd_rd); free(cmd_wr); @@ -580,7 +605,7 @@ pci_vtscsi_controlq_notify(void *vsc, struct vqueue_info *vq) struct vi_req req; void *buf = NULL; size_t bufsize; - int iolen, n; + int n; sc = vsc; @@ -589,14 +614,13 @@ pci_vtscsi_controlq_notify(void *vsc, struct vqueue_info *vq) assert(n >= 1 && n <= VTSCSI_MAXSEG); bufsize = iov_to_buf(iov, n, &buf); - iolen = pci_vtscsi_control_handle(sc, buf, bufsize); - buf_to_iov((uint8_t *)buf + bufsize - iolen, iolen, iov, n, - bufsize - iolen); + pci_vtscsi_control_handle(sc, buf, bufsize); + buf_to_iov((uint8_t *)buf, bufsize, iov, n); /* * Release this chain and handle more */ - vq_relchain(vq, req.idx, iolen); + vq_relchain(vq, req.idx, bufsize); } vq_endchains(vq, 1); /* Generate interrupt if appropriate. */ free(buf); @@ -614,7 +638,6 @@ pci_vtscsi_requestq_notify(void *vsc, struct vqueue_info *vq) struct pci_vtscsi_softc *sc; struct pci_vtscsi_queue *q; struct pci_vtscsi_request *req; - struct iovec iov[VTSCSI_MAXSEG]; struct vi_req vireq; int n; @@ -622,18 +645,17 @@ pci_vtscsi_requestq_notify(void *vsc, struct vqueue_info *vq) q = &sc->vss_queues[vq->vq_num - 2]; while (vq_has_descs(vq)) { - n = vq_getchain(vq, iov, VTSCSI_MAXSEG, &vireq); + req = calloc(1, sizeof(struct pci_vtscsi_request)); + + n = vq_getchain(vq, req->vsr_iov, VTSCSI_MAXSEG, &vireq); assert(n >= 1 && n <= VTSCSI_MAXSEG); - req = calloc(1, sizeof(struct pci_vtscsi_request)); req->vsr_idx = vireq.idx; req->vsr_queue = q; + req->vsr_iov_in = &req->vsr_iov[0]; req->vsr_niov_in = vireq.readable; + req->vsr_iov_out = &req->vsr_iov[vireq.readable]; req->vsr_niov_out = vireq.writable; - memcpy(req->vsr_iov_in, iov, - req->vsr_niov_in * sizeof(struct iovec)); - memcpy(req->vsr_iov_out, iov + vireq.readable, - req->vsr_niov_out * sizeof(struct iovec)); pthread_mutex_lock(&q->vsq_mtx); STAILQ_INSERT_TAIL(&q->vsq_requests, req, vsr_link); From nobody Wed Mar 4 18:06:45 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR0x11pB0z6Sqp8 for ; Wed, 04 Mar 2026 18:06: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR0x112Hmz454X for ; Wed, 04 Mar 2026 18:06:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772647605; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GkMFCMpN0iuz/GoeOpGlbf3VcA+LVjpv70B1MImi6gM=; b=enj0N/0fdlfBS9P0ZDuXw6Jm4XaNlMjrgvdnTE6Rz6GCGlv5KmXJqTQtA5ozudyGav4m3i XI5t5LPRV0pjRC5g6nmWtHmPbNHtkgLHUgZY8CJjfmsGOGKxlrLjdT/9XSkYP+vS00l8Wd 6IzsN/7y0IXcQTiB1rfM9JNq//h0Vyp23Mep/qdiPpSrOtxWpO3UGp444j4hr1tx61OuT2 UAiJsEd0wnaU0aREzp/KPwXE5xxZld5iy5ZNNxS6blOElpso/FPl+HvkRzi95L2jegLz4e GmMjzto5BELqrcppYK6tphiq05o0Rxph+vBjpweSGTX0RkKGhvsTPOxC6E76Yw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772647605; a=rsa-sha256; cv=none; b=MpPo1gNK+GGaWou7Fy+8pP6f4SsWRfKDz5umOmNPBEGqmM7HdWr/O35qNyUhgxYF0SqjiD kW/UTc9zf96OJdw3gmlmCOvkCZKrOmwDEnNt6fzf/paRUrqb2lvgi23HOF3PGHvbzHkOP4 sfZyzRnzZQX11PFFZDDUKkM91nxyrb7PP01NQwFRuD38lyPD6JjMM3Oc2DvLsMlxn3BV2T /A81i6hwibgxCj+jhalQ7ZHEFsxoFNjdoZ5RP5+yOX70qWz3cUsEWIX5uq2X6dIEfbXplW ZtYIKg0LJUHfjmPymMKOnXbLU+RHHELoi63m9fDN/DuWDA62SelQ6V1b/E3sWg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772647605; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GkMFCMpN0iuz/GoeOpGlbf3VcA+LVjpv70B1MImi6gM=; b=fSf/FzzJfINZzIf/IISZTL/tkOTc37XBCcxamB7NiiqL+xd6WPoS0EUDMarWA0256VseCB K+blZL+8uohuU69mqpd6x+DvyGCINXZoGXqYKD19iHTOmi6kB3wS+OZAzqjEhoOVVqFRkg LkmIQC2LCaEsqHftohuGAdD8r7ip+wyXbYft6zRbqvfhhrCauL0UNJL/KCXPNnlzK2C9Bv O6QNENB561G33OmpMJaeOtVrD09eNttKgizCsvVpZb/JmryjY1rq7vAVZjWT7BdSFlHVRm KW9azIUlWNuqw73y2huqQ27/Ym5TKAV4xY7YoLA0ME8s7Gjjf2MKX7M/OM5VJg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR0x10G47z12Cb for ; Wed, 04 Mar 2026 18:06:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 42059 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 18:06:45 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: d15987cc0619 - main - virtual_oss(8): Expose ioctl interface List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: d15987cc06192f78a31040f2c142bcaf88e8a1ee Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 18:06:45 +0000 Message-Id: <69a874b5.42059.40b4a473@gitrepo.freebsd.org> The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=d15987cc06192f78a31040f2c142bcaf88e8a1ee commit d15987cc06192f78a31040f2c142bcaf88e8a1ee Author: Christos Margiolis AuthorDate: 2026-03-04 18:06:17 +0000 Commit: Christos Margiolis CommitDate: 2026-03-04 18:06:17 +0000 virtual_oss(8): Expose ioctl interface PR: 293545 Sponsored by: The FreeBSD Foundation MFC after: 3 days --- usr.sbin/virtual_oss/virtual_oss/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/usr.sbin/virtual_oss/virtual_oss/Makefile b/usr.sbin/virtual_oss/virtual_oss/Makefile index 78532356f097..f5f3d684138e 100644 --- a/usr.sbin/virtual_oss/virtual_oss/Makefile +++ b/usr.sbin/virtual_oss/virtual_oss/Makefile @@ -12,6 +12,8 @@ SRCS= audio_delay.c \ ring.c \ virtual_oss.c +INCS= ${PROG}.h + CFLAGS+= -I${SYSROOT:U${DESTDIR}}/${INCLUDEDIR}/private/samplerate LIBADD= cuse m nv pthread samplerate From nobody Wed Mar 4 18:58:46 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR2526z00z6SvMv for ; Wed, 04 Mar 2026 18:58: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR2526SZgz3FJC for ; Wed, 04 Mar 2026 18:58:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772650726; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=87Iv6ixXexSTwGX5SYO8OZ7yp9aSAZXCoxD95YqTTAQ=; b=T/c//KP6LpewyZdt3ttPCipMwHeCKdCezPyeXAFsYARd2xyBDcd5mBMjoL5n4NnYUBUY4k mcwDylvfZhvZCV7B9DWObqfiwHsgC4iPRHKAzxVgigekyh6IdPsEgKU0EuzrYFijSUlt+h Jz1gA2t9Za0aiKlIxE+dbtf7Q/sWb9Lw5KDoWzMWdxOaRvVjIZfXUS6a9ZlcquW/zTs9Bb dcEi2Ot5FNYfjh5AkYJ9Zrn8IXMQ77/Wo29ut9Z3MfbCq4wl0YR+neAmscxJc2Vy84wXKY i7vizGWCrlvr2Si8w2WwCMZYaNn+3rOuRvduQKXDcHafryvhN3+2tvVrtER6nA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772650726; a=rsa-sha256; cv=none; b=ZIl9QRINLmgpkKifxqG39S7PIqokyyAl5ey/vZZIvme7nY4qkKfj1I7aKAu/mw8mxIA8C1 2nrC5vM5NENDeG9Z+WIqcXnsBfkESJqXytBApsYi5tuRgQo3QI6LbLsWB0cieO89LsZ7Ki LjCaFTeSxI6Yoep9CrwBHu7tnKzPGdaeUwFeQ6BN1QBn1jTudKK+5ngqUYGA1ugn6CoBzk K43iP4DAIXybGZuEvISpLgS1c0fiPWnt7mrQ+J09Z3GFvsBpHp216twI7cIV6uQ5JFdw2A f8pS9jmNwB/VsUhOaU5j6tu2Aquy4cJ0qZHcoKdZQIsEFiLtItLEgpTWcfcAUQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772650726; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=87Iv6ixXexSTwGX5SYO8OZ7yp9aSAZXCoxD95YqTTAQ=; b=voYiY87C1uAFm5Ul8c6EzvN2Pur9ND4MHyd7HUyb/RN0DfSWr7WR/2bAQCUkDTHHGleHWW u0NyaMrvm98ejNt0hO2O/t2xlSRphkNS5GduoZz0mbVxa6qY1b2LWO+PbXY4eQLwnsaPPJ 0DEroUQ35LkJrnV7tdWj7sZsIP+Idq2EIFSTZ+IJe0If/02b8MEr87qyaIJj0tOh+RTpvC 1Dk6rY8dA/++jwMSTErz3M8ZBM1NYKb61UpIUJknXQlb0PK3RPFCz16CCLwzV6bpDYFCNz 170J3aJMzNj+MdzkDA/CwPVQc1cSNPXcXQNAfkdY5B9BrijZVzCNbMi4SSlnfw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR2525nfNz13N0 for ; Wed, 04 Mar 2026 18:58:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 18cba by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 18:58:46 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: c9f3de0ba95b - main - INIT_ALL: Fix typo in option description List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: c9f3de0ba95b8da31d35fa92e0a54cf6f3d3f1dd Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 18:58:46 +0000 Message-Id: <69a880e6.18cba.63ecc7e1@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=c9f3de0ba95b8da31d35fa92e0a54cf6f3d3f1dd commit c9f3de0ba95b8da31d35fa92e0a54cf6f3d3f1dd Author: Ed Maste AuthorDate: 2026-03-04 18:31:29 +0000 Commit: Ed Maste CommitDate: 2026-03-04 18:32:32 +0000 INIT_ALL: Fix typo in option description From GitHub pull request #2035; the change needs to be applied to the source file for the option description, not the generated src.conf.5. --- tools/build/options/INIT_ALL | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/build/options/INIT_ALL b/tools/build/options/INIT_ALL index 3ca70337b8f1..af7be9e407c4 100644 --- a/tools/build/options/INIT_ALL +++ b/tools/build/options/INIT_ALL @@ -17,5 +17,5 @@ Build the base system or kernel with stack variables initialized to zero on function entry. This value is converted to .Li none -for amd64 kernel builds due to incompatability with ifunc memset. +for amd64 kernel builds due to incompatibility with ifunc memset. .El From nobody Wed Mar 4 18:58:47 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR25422PYz6SvRl for ; Wed, 04 Mar 2026 18:58: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR2540sSBz3FCc for ; Wed, 04 Mar 2026 18:58:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772650728; 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; bh=X+MIizTzTcpFR2Lj8KuHQcgEeEQnKNrxxvEEB/BqqnM=; b=l/YT5D4YYH3omDekScjx+VlZS9UBlTJ0vvnZ1xWCXJUBiEujpxhajO523WXxAqHd+w4AAy aPh+JkNTxdIG7g7xd9Py9q0wZXAbrZ5i/gU8IKZ9SF2wI3p0GTVqFuABHUlvrFep0K31iR SweGIhaJiUdD76cRHnarM9UVKo/m17eXaphUwn56FoOiuL3hIhVadPie7+ZIHvswL2G3+u 5QL/PNIH4f1MxxlpFe8E4oeiSWaJiOXBbmJirXc2vq4UMLCTsQLx7Oe2w84dVCMEkQMuMy asn9ftwKMUT6Es6sDaW+bQvMtZUhMzUj9+HKS++vCxSc+BI8CmfXb1V2Yiicrg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772650728; a=rsa-sha256; cv=none; b=FCOTQIb9PQW1swBFWtpEIWUwWQsKWaF9wE/eHVfUMVJ93fG7TrmCE3yYJfn/23ZsWyzIh4 2/2IcpCy9qqNjW9C0PZaJp/i8zD5gEgkvFar9B+CkwpwNUq0RB4V8dPWj8CMqtdGo0pu/D 6TPulrMHhWd78LIrUKu0D8nL0Sisr05qTKzWwCivU0/+GcHU3q8eTR2POBUJ943/IU7aRB Bfyj+mb7VIZf6CSGXsOb3ZzTvpNTXB6FofLu5OH9EUzmDKu0fcOfLOLG+ZlMCrrAJMGa25 8xRb8u6nwNQ1uyKy8OlTHUeIdO57hEUCAPf42yuT+QqyMRIPY49xOe1rGQZTwg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772650728; 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; bh=X+MIizTzTcpFR2Lj8KuHQcgEeEQnKNrxxvEEB/BqqnM=; b=r81t23/GRka2IW0e8Jzaoh4YAn5iw33e3FejCgV+hdGeC5HWjsFVRPENu6JqyvVHbuiZwY g7Mmnvq/T1DUBq6Ngdowbo9ZMOYtfMev9snRKxLuT1S3mApg1xKcJPV906f55Hy3w3D34m ehTz2Ber89GFv0sMFyuZ7dZDHdAbk3YzsYDZcvH7hcLboclbLxaGN72qIiC0hx9AAch0L7 XzXemDOYHV+bpl5OS3P9zqj3CKz2oDzYJsqPnytVdhXWYZF2fA1comRi1anke5yUYdawbU dtghiW2VtlB3LzcUUP6XCxn1rdapf4HzGMhw/0kGUC6d4WELR1CTtCZCeDSzPQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR2536XD7z13L1 for ; Wed, 04 Mar 2026 18:58:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 47f0e by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 18:58:47 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Christos Longros From: Ed Maste Subject: git: 71e8b32415c2 - main - src.conf.5: Fix "incompatibility" typo List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 71e8b32415c2c70a95e89644782006f84de17f2d Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 18:58:47 +0000 Message-Id: <69a880e7.47f0e.22f473a6@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=71e8b32415c2c70a95e89644782006f84de17f2d commit 71e8b32415c2c70a95e89644782006f84de17f2d Author: Christos Longros AuthorDate: 2026-02-19 19:37:47 +0000 Commit: Ed Maste CommitDate: 2026-03-04 18:32:33 +0000 src.conf.5: Fix "incompatibility" typo MFC after: 3 days Reviewed by: ziaee Signed-off-by: Christos Longros Closes: https://github.com/freebsd/freebsd-src/pull/2035 --- share/man/man5/src.conf.5 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index 9b1ef4c3e8d4..01e9db1f1915 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -2000,7 +2000,7 @@ Build the base system or kernel with stack variables initialized to zero on function entry. This value is converted to .Li none -for amd64 kernel builds due to incompatability with ifunc memset. +for amd64 kernel builds due to incompatibility with ifunc memset. .El .It Va LIBC_MALLOC Specify the From nobody Wed Mar 4 19:12:19 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR2Ng4QkRz6SwDB for ; Wed, 04 Mar 2026 19:12: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR2Ng3hS9z3Hlj for ; Wed, 04 Mar 2026 19:12:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772651539; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=l7+xUNO7eF7nSg9kGUnZ6MUo+Yz4vGic9JxsSNJm5AE=; b=hNaFoG6bCdKXhDCeW437BnwwAk7ZlTCHzhySbwRvH49gMNJzbdCYfTaa8t/Ue6w2JvimfO DKCXPBp6ICd8401cwehwEKG66QUVEIfJ2H5f57KNKcOP06cQfohTsneVdbG6eus0nMnTzK mkSwE3Mk3r6SechOcZQsV6fBrfh3frrcya+TBxg79bzFmTQQedggw8lBwV60JAzEo+13fp IW9pNXecru/F/Q/sYZS+I+fTdmARrOtEQZ2SkTU0Af6N0N1dUbopAwW8LOieZEJuNzdkuC XXKCXdgm7PdrfFHQQ+Zsi9tljmJS8XgByfmaNRyULdUCNt/rITgADjxRUrvIJA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772651539; a=rsa-sha256; cv=none; b=W7wWqk6OmwWU6NYcmJ0+fPA1q3BcyMbcftP5btBDdsLj7gQNYyPTVB122ej94rb9cmSsYi N+A3m90lHDCPWF1zdPhTpPc8Rpop8q5cgiGN/ToBmGzNMlbIMW8TIvyDegs3lWX06QWzoe Ay/9DXNixziDj63E57Dr+GPjI5DXBg6WqtnuwmGMfLGQlHe3FEDVALcIh0ZqnAKBuPPb7j La05xzuuvFufmqCQOAyYm+jUIaCQPUoYKLGSMB8DHFX5JDlZNmcqKnZl+F0SxIAJYCithT kJROYw2BE4bdSYSwzfygz2k6QJDrk/cRyym9zGk97dCmgAGwTGptU+Qf9glgxA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772651539; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=l7+xUNO7eF7nSg9kGUnZ6MUo+Yz4vGic9JxsSNJm5AE=; b=pKwcdPTfyQGkkTUbZko6DYlhJKHNyfMSoub5yK/rEvPNAP58VGEak+Iyk/ftmxuWIlKnZk L2+VrOTrRBu8ZnIy2ZNFCBJdNuN/eCE6HWiC5zptPLAp1CW2QBPJwlI+bh50EO0u2h9TTX h31SeBfgHRDiaFzCfWVBim6rt7heQWBwR3J7tG5LxUdAFvnSF2HtBBOgT5pM9IxDFtvRBJ H41aN4g4vA0zLcuobIcTAb43iBx71oEe/KHImJfrR0L8qh4XU0BHsNuTJqB4tbDy0FqTvF cfsnWqMQWijVubs9AXyl2a8XPRHo71FmccumK4ETALNlf8umqYCeDU/bd9qEUw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR2Ng3D4sz13ln for ; Wed, 04 Mar 2026 19:12:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1be02 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 19:12:19 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 858f53dd43ec - main - Makefile.inc1: Don't force LLVM_BINUTILS off for cross-tools List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 858f53dd43ecb84cf2597229e9dbda2f242d9dd6 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 19:12:19 +0000 Message-Id: <69a88413.1be02.24089406@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=858f53dd43ecb84cf2597229e9dbda2f242d9dd6 commit 858f53dd43ecb84cf2597229e9dbda2f242d9dd6 Author: Ed Maste AuthorDate: 2026-03-04 15:06:26 +0000 Commit: Ed Maste CommitDate: 2026-03-04 19:10:48 +0000 Makefile.inc1: Don't force LLVM_BINUTILS off for cross-tools Because of this setting we were still using ELF Tool Chain tools for buildworld. The sets of binary utilities are largely equivalent and this went unnoticed after commit 1cae7121c667 ("Enable LLVM_BINUTILS by default"). This was discovered recently because ELF Tool Chain objcopy produces standalone debug files without phdrs and this caused an issue with a 3rd party ELF parser [1]. Remove the forced setting so that we use LLVM's binutils to build the system. [1] https://sourceware.org/bugzilla/show_bug.cgi?id=33876 Reviewed by: imp, jhb Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55650 --- Makefile.inc1 | 1 - 1 file changed, 1 deletion(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index c4696abae8cd..8a1958902db5 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -808,7 +808,6 @@ XMAKE= ${BMAKE} \ TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \ MK_CLANG=${MK_CLANG_BOOTSTRAP} \ MK_LLDB=no \ - MK_LLVM_BINUTILS=no \ MK_TESTS=no # kernel-tools stage From nobody Wed Mar 4 20:19:59 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR3tl4yG5z6T1Vv for ; Wed, 04 Mar 2026 20:19: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR3tl4PZMz3Pgk for ; Wed, 04 Mar 2026 20:19:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772655599; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NliTxjwDcIB0Vl8uP9nfHrPtk+hmsCIVOVSIBhOM9LA=; b=sAAgpfQTn1EE0vkABymTvEzrPmHUuM9WV5lu7r6KV5jRND5dtVzN2S1eSGOnMo8b03cQRX sPlV7VZGI4Z3TjVnj6fRpjCGKFU2ETkcSFBqURAkBvcGfE8phJvhg0VpEbQGZlyKol1ei5 qt/zuOlYSVH2onWxHmlG/bilLtPL2gsSPbme/xkrhUHD7sbT3cIfefpe7CTvsXTPDRv+fq bwdp0+ncs88L28ptCDaLh1fIycoBcDvJIMbCV5kny/RmdRkjC3ldGOjlqkeiKm/HSPJEwh BG2S8c5kh1DaYF+yep9vWGIg+H0+WwVIdrLX/gSqk0g0D8G1Et9nBux2QVoS9Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772655599; a=rsa-sha256; cv=none; b=kSswmRp2pf20305QBja+A7iy7gbPiB+yTNOm9uP8lR5e9qufiGFjCdkIKUxGhQ+Kuvge0k IWEjHxj+rvZPrICEzTnUh2Ck6mNRG4pVHefOHveDn2AgwcOSyRLqS4eo6cYNICEib8+Rg0 lHxSvoObfhGJ52fE3czdOywYLVH9dsf7c+SeG8rQV73rNuSB/xU5c7emg9GIhuNDb0yn4c kj8M82EJd5VT/rr+Hgrk1kJ1zfR0YmM3nBx8amUFtk7ODxve4ffrGOmmdBxE9cnuZpOBMw 7jmAemHYEfxy/RgJxoNpwllcJGx4hnG21F1BGVrnDTiim5gYtE6EiKRc+taqWQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772655599; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NliTxjwDcIB0Vl8uP9nfHrPtk+hmsCIVOVSIBhOM9LA=; b=elymggewCBQjFHT0IvYJL0+bV/6JoUcnRYnwnev+x/SJ+RjR99BAipl+ajP/kfqJ/chAsi Ap/0Z1cB0oZywjQA2Rbhpb1llRHa68JXjZAd9ABStGzN1xCr6KuHJcOZCsRPeSnZodsK+y gw5ZGRsCTe2QQtNgidlfB6QX6Ve5GqKerBYeAJ98gY0am59nwFhEp94LOFGdlTk2fM1bDy uxcv6rARfZ/lgDcMhMsmozIx7WTehOwNzo0PrYwLQrPnbOvGAoSiffQ5nRveqTrgwMFaiM +Xh07+x7A6dMbnzJKa+47V5sds1v4WPTNY+Nwn257HC7poOkF05BmArO8wFReg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR3tl3yj3z15FM for ; Wed, 04 Mar 2026 20:19:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 21975 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 20:19:59 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 00ff89c1e0c8 - main - acpi: Treat ACPI_IVAR_FLAGS as a global IVAR List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 00ff89c1e0c8d92fe644ea97b521ceb66d46e170 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 20:19:59 +0000 Message-Id: <69a893ef.21975.7d303d92@gitrepo.freebsd.org> The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=00ff89c1e0c8d92fe644ea97b521ceb66d46e170 commit 00ff89c1e0c8d92fe644ea97b521ceb66d46e170 Author: John Baldwin AuthorDate: 2026-03-04 20:19:48 +0000 Commit: John Baldwin CommitDate: 2026-03-04 20:19:48 +0000 acpi: Treat ACPI_IVAR_FLAGS as a global IVAR The ACPI bus uses the flags IVAR for any device with a _PRW method including devices such as PCI bridges/devices that are not direct children of acpi0. Reported by: ngie Reviewed by: ngie Fixes: 0bb867e9f565 ("acpi: Split ACPI IVARs into global and private sets") Differential Revision: https://reviews.freebsd.org/D55561 --- sys/dev/acpica/acpivar.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/acpica/acpivar.h b/sys/dev/acpica/acpivar.h index b86c6c1aa3c6..1099e7a25b0a 100644 --- a/sys/dev/acpica/acpivar.h +++ b/sys/dev/acpica/acpivar.h @@ -279,9 +279,9 @@ extern int acpi_override_isa_irq_polarity; */ enum { ACPI_IVAR_PRIVATE = 20, - ACPI_IVAR_FLAGS, ACPI_IVAR_DOMAIN, - ACPI_IVAR_HANDLE = BUS_IVARS_ACPI + ACPI_IVAR_HANDLE = BUS_IVARS_ACPI, + ACPI_IVAR_FLAGS }; /* From nobody Wed Mar 4 21:35:42 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR5Z61Txjz6T5qP for ; Wed, 04 Mar 2026 21:35: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR5Z60yVQz3Wkq for ; Wed, 04 Mar 2026 21:35:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772660142; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=l1agfO6BVCY2p8HvkQtfGplf4IqXzXPO0pC4ph9GR+U=; b=IslUj0wQGaITuV0nsdpRseYZ+oWWEaqueA2GYJ8joJmKj1Eq/amoy9IAd5B7DSw9mlgf5I qeyLxImBMvw2BUr1DRyyQQiHFeBGlj2u5IQI3ehsLU5FDedeNzIgc4AATuXZy0OiWmmi5Z C2eqX1Wj70xE5XVyB0o8JaalFrjYbHKhMUEGaX9JjaLUn+EwVPkRG7JoGXmS1vcwFE5dAO Stz9teMkyMoGszTf1xOgcpIkg73dMWiwJIH55ivZTcacUXnlrHrTX+89YLWcrCntxWV9sn XjbZoMCCNmUuTQvF4CanHPnZeQErM7fWXyOnI9U+fT4Wt4REUZ5Wi0jDFlO+TQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772660142; a=rsa-sha256; cv=none; b=VKAXH3ykrr4H7eimpOknSikJBPpyxW2szh11l8btSlsCXjTW9TRlBxo8Emm7vJ+96oz1th n/weqdqIh3azYuHPu+3qbj6LJhe0W/y755uULGtaSaMGTrc8nhr3CJW0WUVEuFc1PSw9jK YwIy8h/Kw/etub4B8Nv4fPGAuAJXEOU7aNHt7bIVmdVepwHatwncDflVb9BM6sHJFLGzRF H4P29PKEwVmh4UJ7yITDvnVZUjYrsElUmW3o+P6kn8TohH8MdqIhQjlszkX1vddWzTsfcM YHAyLiJnu2OUMQhSoj31E4h+xbIKj9nrdhmpGXqbY13JF98FHZBH5/VY7Q2w1A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772660142; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=l1agfO6BVCY2p8HvkQtfGplf4IqXzXPO0pC4ph9GR+U=; b=hxcl5itP1sDuVAajcSsfPJTBUpC+WvKnw4fzr2hrfntEONGiKj2eIFbEjXxA1egszT7HhX 9OdJEdCnlm6JyuBGWXtTQCL3YNB3ZFIaNztDYUjN8Xq/kaZiiCfopmjrORsHEZBNoKmIkk syEN3B78EKFMZmpCsVB6H2Xxcvpk6u6vMCcggveowP6LvGgIHvK7zmZMxPqgAjORkuSN8+ dz3cT8Q0NaLqEZHTBBysrelJ3PrlwNwHFCNLdm2sVy7lH4WO17Q5VfVtJL1+0iv+79ssja bAkJI8k+KTbRSBpwnd6UtKhix6WsA5BTY2PObL5Z9TGuASaQasZnGo6oYOAb0A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR5Z60R6fz175T for ; Wed, 04 Mar 2026 21:35:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 306bb by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 21:35:42 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: df97a58afdea - main - inpcb: use correct label name in a comment List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: df97a58afdea2dc23746c84ebeb60790d8786b22 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 21:35:42 +0000 Message-Id: <69a8a5ae.306bb.7982060f@gitrepo.freebsd.org> The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=df97a58afdea2dc23746c84ebeb60790d8786b22 commit df97a58afdea2dc23746c84ebeb60790d8786b22 Author: Gleb Smirnoff AuthorDate: 2026-02-28 05:10:54 +0000 Commit: Gleb Smirnoff CommitDate: 2026-03-04 21:35:07 +0000 inpcb: use correct label name in a comment --- sys/netinet/in_pcb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c index 9610ce2fe363..96c8d3c73b0e 100644 --- a/sys/netinet/in_pcb.c +++ b/sys/netinet/in_pcb.c @@ -1632,8 +1632,8 @@ next: /* * Entries are never inserted in middle of a list, thus * as long as we are in SMR, we can continue traversal. - * Jump to 'restart' should yield in the same result, - * but could produce unnecessary looping. Could this + * Jump to 'next' should yield in the same result, but + * could produce unnecessary looping. Could this * looping be unbound? */ inp_unlock(inp, lock); From nobody Wed Mar 4 21:35:43 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR5Z72CjCz6T5NT for ; Wed, 04 Mar 2026 21:35: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR5Z71jk7z3WwX for ; Wed, 04 Mar 2026 21:35:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772660143; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cUsk7kSZs2eKaI23gL1xRdIxxH0BoDJbyx5MVLBS8RA=; b=V2HoEiL9iCQTUKk3zMu1snpuZt49EV5yiTzrw04qbVCYCd4hQ3bGS4BKmdX72tOw28rSN7 pQj7p+/pBMABM0U7lrDvwTBH4S37OGLq6CuLEWsv2pYdz+vz484D/2b5UvRUx40G8ZSaVl nShrsV1t1G/7/+if9YlA/YMOl3vZ0OulP5LuoGq9HlAmIxWVA/TxpUtQCDfL/lYof04uyt Mxwap/11D6C/YzKWJGX2LYVznpDRb9Qj8+17EzK0MzlrbHzJome0pfQ3j08Yr7LlXN0/sC FRJU1OHDfUDrCdojQFUZ0Fyl5V8TyTZFmrXUEjpB2beDx18naLyHdQuVGo2BAw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772660143; a=rsa-sha256; cv=none; b=LXtz3CIUq6nRvERiZTLjZ0a5QaQQVP9umBz6BS3k8tORwCyUMqBt+hU5gEYdcg6HJhibrl BlEtaJQ0nQVm9kvU8T9+WJ8BAFN6SnKZgXa8xlVMQf0OZV1EsKMBA0iEFSWp7fXd5/dakq VEOCB7vFIe2CWvPONRyDFq5g/ItINwZbOagmCBtUrmysl5QZRdaaaRZeo1/k9O1ZxSuHFW vdG6ZdnJkQAsKlRJObRrnM48kKcrHYPIBUDN4gPC6NsB9/2SNKANZ93L9y9upFZjC9AHTV rQ2+3TQzKoJFKuW5ZtxjNxVCNpK1x+m8euaZJKIsVjI4yj28Z+x118jfGl7Daw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772660143; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cUsk7kSZs2eKaI23gL1xRdIxxH0BoDJbyx5MVLBS8RA=; b=DqCa3ndsPgAwayPUk8tsku2f5XEGKCQbDlzAxhQOlU7orYHr0BAQzg52Nv8mJotNAWhrXi e3Xd4kdZyKuEE++H4LQt1KbSldvH6PBzsjcmvjPr+g0P9x943m/amdFckAVN+CCm9/xfaX eB4+vhG7eu9EPIgerzGfcuWGbwjTxA6rXEsbL/T1/JdsdTi0aGVHr60daZKYGJBCZRN4ht 5btVNb9qS6ToHc6MQaJg8cZCQWgUZtodehEbMcCU6x+P3a742Oh9ba1KcC8/YgrN3SxU/z 7Wi06kVrL9IxjwnkWlIavvZXzWOY+mLBTqYOGFVlEAtUjX8clZ6h1ztQyM7T1w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR5Z710Wyz175V for ; Wed, 04 Mar 2026 21:35:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 31b62 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 21:35:43 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: c5c54f7d21e5 - main - hpts: remove no longer relevant comment List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: c5c54f7d21e573741d8ebcfc68d2a852ce416b54 Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 21:35:43 +0000 Message-Id: <69a8a5af.31b62.1c2b4dd3@gitrepo.freebsd.org> The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=c5c54f7d21e573741d8ebcfc68d2a852ce416b54 commit c5c54f7d21e573741d8ebcfc68d2a852ce416b54 Author: Gleb Smirnoff AuthorDate: 2026-03-04 08:20:01 +0000 Commit: Gleb Smirnoff CommitDate: 2026-03-04 21:35:29 +0000 hpts: remove no longer relevant comment --- sys/netinet/tcp_hpts.c | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/sys/netinet/tcp_hpts.c b/sys/netinet/tcp_hpts.c index 29a55c1a7e39..b8650cd60c2f 100644 --- a/sys/netinet/tcp_hpts.c +++ b/sys/netinet/tcp_hpts.c @@ -186,18 +186,6 @@ static MALLOC_DEFINE(M_TCPHPTS, "tcp_hpts", "TCP hpts"); static void tcp_hpts_thread(void *ctx); -/* - * When using the hpts, a TCP stack must make sure - * that once a INP_DROPPED flag is applied to a INP - * that it does not expect tcp_output() to ever be - * called by the hpts. The hpts will *not* call - * any output (or input) functions on a TCB that - * is in the DROPPED state. - * - * This implies final ACK's and RST's that might - * be sent when a TCB is still around must be - * sent from a routine like tcp_respond(). - */ #define LOWEST_SLEEP_ALLOWED 50 #define DEFAULT_MIN_SLEEP 250 /* How many usec's is default for hpts sleep * this determines min granularity of the From nobody Wed Mar 4 23:49:54 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fR8Y41jnvz6TFYQ for ; Wed, 04 Mar 2026 23: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fR8Y36tJrz3lG1 for ; Wed, 04 Mar 2026 23: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=1772668200; 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; bh=tN7DeUkXYk0VOBOYslSskdmfv6BhbZSwqO7kiOuhn4c=; b=HEpHoHLtzf7uvxYG11MlcoIN0eriokGrfz6Fce/Xf5zqKXkUtHR78DvOLoWwa5TLKzePE+ 8okF9l9DrZ8N6eCkLChWann96a9iqryeNf9VMDTWGDADuajVdIptc/l3gYA11/LiIErFVs A4CyZDuCtfBETwloqY7HJMdow5dvcL2PvD6Zkrk6G5ihBQ5WW1yv/xs9johpZIY2mgPJC5 0SYVqoZGx6N6Am2euFzDLeuVeH2e2ppaMw9ngPfeswoRrT+xrbl9Vz/7XmVp03+hYF7Gkz l0p7xyOLHtWAj8jXtaPcIOpth8VmG3fodc9IbUQQTqgdZ7CyEVjYCGuZjNMJ0A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772668200; a=rsa-sha256; cv=none; b=F6bVbh7MVsSo0fdZBlI62sr0ca7tUR9bmsR3XboutNCzymdNUdE8gtITlkiQg+CY9DLsK0 vF3oQXHUMAAYh0fyS3MD7Dymf7Y25TXGbpO9xOb+kybxf+dj8aCChY2Td3jT9OCaPwCWpc aFrKEvZSgAWtKVR5fT90VACz/ohomWXsMBEdtTxaKBpKTfgaVwFshTEqKAR7tt95FAbc3V M53nEOn2u/GfhrnkYUaBDj2uSQxQXxAvUOy68USkpxQ2MMYDnOmu0SouiJ2fNDc/tCUX83 9sGI788eU+Id726gR8tHTM9G1okYzDpwXuFaWH/+VAkowI2Towe9jM14jvD0TQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772668200; 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; bh=tN7DeUkXYk0VOBOYslSskdmfv6BhbZSwqO7kiOuhn4c=; b=FBsYjcH3SBUqImw+0I8eqCxb96PX7nKGhmIIHhPrxX+6vBaijora6fyWb6iQPKb6tkTpob 7cKgP9PFylSE1kfLFM+SKrK289Z/5rNNXOk8Z+xwvCEG4cshiKciZun3/wmQst9MZSBA4s bRobVy5534dPTXmTPjifR0a8hZqTNga5mrTKt/2ok9+79scdbSaiEeR7k+kjqo+Drtevf/ j4hhE3fJdvMB+gIwDmGlb+9UZg80zlOJu/+xivajb1XVPcp3sBzKxCjmSQ8IEIot2fmNxC ytYrtPlVOkWHlXSF5VXgnE2b9ALfDVzR23zQyV/aTCPA/olBILJ+cym3B0cL6A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fR8Y366LYz1Bqt for ; Wed, 04 Mar 2026 23:49:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3e3f9 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 04 Mar 2026 23:49:54 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Majed Alkhaleefah From: Aymeric Wibo Subject: git: 2f440158c686 - main - hid: Fix 'strenght' typo in hpen.c List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 2f440158c6865c93c9f8ef611b8673bba1f81dfa Auto-Submitted: auto-generated Date: Wed, 04 Mar 2026 23:49:54 +0000 Message-Id: <69a8c522.3e3f9.45762ecb@gitrepo.freebsd.org> The branch main has been updated by obiwac: URL: https://cgit.FreeBSD.org/src/commit/?id=2f440158c6865c93c9f8ef611b8673bba1f81dfa commit 2f440158c6865c93c9f8ef611b8673bba1f81dfa Author: Majed Alkhaleefah AuthorDate: 2026-03-04 23:40:38 +0000 Commit: Aymeric Wibo CommitDate: 2026-03-04 23:41:57 +0000 hid: Fix 'strenght' typo in hpen.c Reviewed by: wulf, obiwac Approved by: wulf, obiwac Fixes: d97d5c0ce89d ("hid: Import hidmap-based drivers written by Greg V") Differential Revision: https://reviews.freebsd.org/D55626 --- sys/dev/hid/hpen.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/dev/hid/hpen.c b/sys/dev/hid/hpen.c index c298dea57042..fb1f0c96bcba 100644 --- a/sys/dev/hid/hpen.c +++ b/sys/dev/hid/hpen.c @@ -56,7 +56,7 @@ static const uint8_t hpen_graphire_report_descr[] = static const uint8_t hpen_graphire3_4x5_report_descr[] = { HID_GRAPHIRE3_4X5_REPORT_DESCR() }; -static hidmap_cb_t hpen_battery_strenght_cb; +static hidmap_cb_t hpen_battery_strength_cb; static hidmap_cb_t hpen_final_pen_cb; #define HPEN_MAP_BUT(usage, code) \ @@ -77,7 +77,7 @@ static const struct hidmap_item hpen_map_pen[] = { { HPEN_MAP_ABS( Y_TILT, ABS_TILT_Y) }, { HPEN_MAP_ABS( CONTACTID, 0), .forbidden = true }, { HPEN_MAP_ABS( CONTACTCOUNT, 0), .forbidden = true }, - { HPEN_MAP_ABS_CB(BATTERY_STRENGTH, hpen_battery_strenght_cb) }, + { HPEN_MAP_ABS_CB(BATTERY_STRENGTH, hpen_battery_strength_cb) }, { HPEN_MAP_BUT( TOUCH, BTN_TOUCH) }, { HPEN_MAP_BUT( TIP_SWITCH, BTN_TOUCH) }, { HPEN_MAP_BUT( SEC_TIP_SWITCH, BTN_TOUCH) }, @@ -109,7 +109,7 @@ static const struct hid_device_id hpen_devs_no_load[] = { }; static int -hpen_battery_strenght_cb(HIDMAP_CB_ARGS) +hpen_battery_strength_cb(HIDMAP_CB_ARGS) { struct evdev_dev *evdev = HIDMAP_CB_GET_EVDEV(); From nobody Thu Mar 5 03:16:44 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRF7d17nrz6TTwP for ; Thu, 05 Mar 2026 03:16: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRF7d0cBzz45X0 for ; Thu, 05 Mar 2026 03:16:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772680605; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9pzd/wwmrBBuyYT1X824d+6rN6gEmMGB9LDE5f48Vj4=; b=sF0V2YwwFihGisbNt5uiXS4+GUVuDA6N5P6pxTean8ijIKr7PrWhV+N0xqinU873a1bpvy CT3TQObZQYSEOwexQ2CziE7Hm8ew6XpmBuyW9tdZ9TptXIRagERxqSDKFeyQ9hN3Pxopph WZ+LSzK7MuxTJjX+2jr05sxqtfXgWkL0Kn04xAqyzC1u6uEv7a5Yx5n6CyJNvOwsAVSDdO XDIykIdQgNZOLOae/WdHFdQB30WMWFiu3B/plMcPBQYVWfUYN7n7D99Rs+nlzABu1zO6Xl VxGLE2ZrxBcBz2oLCKXEUDrOxMySa5e0u2m/f9iTvc1EEsqk/4p3hYoXt/2W8A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772680605; a=rsa-sha256; cv=none; b=nzqwVSgkoKZztlmI+sR36+ReLplR8ooVWgUvsnhhcomhXmb0IiPR2RZ1mJktT8vc/J8biL pYW9ZVeV42WYTPUXZ9ove/lS/dbiLcqMJPPtYFaDT1ot34klllmW2AHRvgnKukZeq0yeYb kTQh0cFqCAVl3lV1iQCJHfOXoBfnNvpri8RlpbPCmzohaJT8CBqxBztZWipM3LaUdOQn8q LS5ooiu/xL0rOx4j8KFvcNpVTABpPy3apLZxmuWNxfztL0NKTuyDEJ3BQX3ixyB/RmCLN+ /+w8KzML9rSgA2mZAua/DzCrabgQGpvO7/vopnET2cUdwMuE/5nhF/LEyL5b4g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772680605; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9pzd/wwmrBBuyYT1X824d+6rN6gEmMGB9LDE5f48Vj4=; b=b2A2E8A+VYDkRPqklrNjXBVVjd9fqVBOKFJiRluOKJFCREM1xxElSy5fuiJ3+PZP4rtmrv mR355ZnapJcfgV89NfakII/fxjmfcu0rX7Eez+6LnExZksLW35HgcX6I4sEmziw0xLT+Am I/qJ40lqGiBZ2eu6JaYfbYv+yI7+V6Nce/STNsBmjd4LhYN638iZpwmpZZPW64sa4ai4Vk 3avvvaOK3Z/GMbKYURRMLoSv6+19z1cbCyDs2uVEN2rdcl/spfmCXxvLWfLgznnCz++XQX yRbcq6jIRSVTZpbzKBDZv1TaVEINim0bbzz8KDEUfSK0b/DowLJfNa9gkeW6mQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRF7d01vYz4GL for ; Thu, 05 Mar 2026 03:16:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 36625 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 03:16:44 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: 776604651ea6 - main - hpts: remove call into TCP HPTS from userret() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 776604651ea640d65baa241c90fb0531aba30f29 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 03:16:44 +0000 Message-Id: <69a8f59c.36625.af74263@gitrepo.freebsd.org> The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=776604651ea640d65baa241c90fb0531aba30f29 commit 776604651ea640d65baa241c90fb0531aba30f29 Author: Gleb Smirnoff AuthorDate: 2026-03-05 03:16:00 +0000 Commit: Gleb Smirnoff CommitDate: 2026-03-05 03:16:00 +0000 hpts: remove call into TCP HPTS from userret() This hack introduced in d7955cc0ffdf and e3cbc572f154 proved to have more ill side effects than benefits. Sorry for that. Now the HPTS soft clock is called only after the LRO completion. Refactor HPTS module linkage to address that and share the pointer only between HPTS and LRO. Reviewed by: Nick Banks Differential Revision: https://reviews.freebsd.org/D55640 --- sys/kern/subr_trap.c | 16 ---------------- sys/netinet/tcp_hpts.c | 21 +++++++++------------ sys/netinet/tcp_hpts.h | 3 +++ sys/netinet/tcp_lro.c | 4 +++- sys/netinet/tcp_lro_hpts.c | 4 +++- sys/sys/systm.h | 8 -------- 6 files changed, 18 insertions(+), 38 deletions(-) diff --git a/sys/kern/subr_trap.c b/sys/kern/subr_trap.c index bac7d0080c71..bad3319afdfe 100644 --- a/sys/kern/subr_trap.c +++ b/sys/kern/subr_trap.c @@ -74,10 +74,6 @@ #include #endif -volatile uint32_t __read_frequently hpts_that_need_softclock = 0; - -void (*tcp_hpts_softclock)(void); - /* * Define the code needed before returning to user mode, for trap and * syscall. @@ -129,18 +125,6 @@ userret(struct thread *td, struct trapframe *frame) if (PMC_THREAD_HAS_SAMPLES(td)) PMC_CALL_HOOK(td, PMC_FN_THR_USERRET, NULL); #endif - /* - * Calling tcp_hpts_softclock() here allows us to avoid frequent, - * expensive callouts that trash the cache and lead to a much higher - * number of interrupts and context switches. Testing on busy web - * servers at Netflix has shown that this improves CPU use by 7% over - * relying only on callouts to drive HPTS, and also results in idle - * power savings on mostly idle servers. - * This was inspired by the paper "Soft Timers: Efficient Microsecond - * Software Timer Support for Network Processing" - * by Mohit Aron and Peter Druschel. - */ - tcp_hpts_softclock(); /* * Let the scheduler adjust our priority etc. */ diff --git a/sys/netinet/tcp_hpts.c b/sys/netinet/tcp_hpts.c index b8650cd60c2f..67b028d7603b 100644 --- a/sys/netinet/tcp_hpts.c +++ b/sys/netinet/tcp_hpts.c @@ -185,6 +185,7 @@ const struct tcp_hptsi_funcs tcp_hptsi_default_funcs = { static MALLOC_DEFINE(M_TCPHPTS, "tcp_hpts", "TCP hpts"); static void tcp_hpts_thread(void *ctx); +static volatile uint32_t __read_frequently hpts_that_need_softclock; #define LOWEST_SLEEP_ALLOWED 50 #define DEFAULT_MIN_SLEEP 250 /* How many usec's is default for hpts sleep @@ -1560,13 +1561,16 @@ tcp_choose_hpts_to_run(struct tcp_hptsi *pace) return(pace->rp_ent[(curcpu % pace->rp_num_hptss)]); } -static void -__tcp_run_hpts(void) +void +_tcp_hpts_softclock(void) { struct epoch_tracker et; struct tcp_hpts_entry *hpts; int slots_ran; + if (hpts_that_need_softclock == 0) + return; + hpts = tcp_choose_hpts_to_run(tcp_hptsi_pace); if (hpts->p_hpts_active) { @@ -1607,7 +1611,7 @@ __tcp_run_hpts(void) } /* * In this mode the timer is a backstop to - * all the userret/lro_flushes so we use + * all the lro_flushes so we use * the dynamic value and set the on_min_sleep * flag so we will not be awoken. */ @@ -1733,7 +1737,7 @@ tcp_hpts_thread(void *ctx) } /* * In this mode the timer is a backstop to - * all the userret/lro_flushes so we use + * all the lro_flushes so we use * the dynamic value and set the on_min_sleep * flag so we will not be awoken. */ @@ -2124,9 +2128,6 @@ tcp_hpts_mod_load(void) /* Start the threads */ tcp_hptsi_start(tcp_hptsi_pace); - /* Enable the global HPTS softclock function */ - tcp_hpts_softclock = __tcp_run_hpts; - /* Initialize LRO HPTS */ tcp_lro_hpts_init(); @@ -2154,9 +2155,6 @@ tcp_hpts_mod_unload(void) { tcp_lro_hpts_uninit(); - /* Disable the global HPTS softclock function */ - atomic_store_ptr(&tcp_hpts_softclock, NULL); - tcp_hptsi_stop(tcp_hptsi_pace); tcp_hptsi_destroy(tcp_hptsi_pace); tcp_hptsi_pace = NULL; @@ -2185,8 +2183,7 @@ tcp_hpts_mod_event(module_t mod, int what, void *arg) /* * Since we are a dependency of TCP stack modules, they should * already be unloaded, and the HPTS ring is empty. However, - * function pointer manipulations aren't 100% safe. Although, - * tcp_hpts_mod_unload() use atomic(9) the userret() doesn't. + * function pointer manipulations aren't 100% safe. * Thus, allow only forced unload of HPTS. */ return (EBUSY); diff --git a/sys/netinet/tcp_hpts.h b/sys/netinet/tcp_hpts.h index 13527f7f9a4a..b7ff957a0577 100644 --- a/sys/netinet/tcp_hpts.h +++ b/sys/netinet/tcp_hpts.h @@ -93,6 +93,9 @@ struct hpts_diag { #ifdef _KERNEL +void _tcp_hpts_softclock(void); +extern void (*tcp_hpts_softclock)(void); + extern struct tcp_hptsi *tcp_hptsi_pace; /* diff --git a/sys/netinet/tcp_lro.c b/sys/netinet/tcp_lro.c index 3b04d757c0f9..59358db6ecf9 100644 --- a/sys/netinet/tcp_lro.c +++ b/sys/netinet/tcp_lro.c @@ -89,6 +89,7 @@ SYSCTL_NODE(_net_inet_tcp, OID_AUTO, lro, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, long tcplro_stacks_wanting_mbufq; int (*tcp_lro_flush_tcphpts)(struct lro_ctrl *lc, struct lro_entry *le); +void (*tcp_hpts_softclock)(void); counter_u64_t tcp_inp_lro_direct_queue; counter_u64_t tcp_inp_lro_wokeup_queue; @@ -1257,7 +1258,8 @@ tcp_lro_flush_all(struct lro_ctrl *lc) done: /* flush active streams */ tcp_lro_rx_done(lc); - tcp_hpts_softclock(); + if (tcp_hpts_softclock != NULL) + tcp_hpts_softclock(); lc->lro_mbuf_count = 0; } diff --git a/sys/netinet/tcp_lro_hpts.c b/sys/netinet/tcp_lro_hpts.c index 99989d2833c0..4a606e36514f 100644 --- a/sys/netinet/tcp_lro_hpts.c +++ b/sys/netinet/tcp_lro_hpts.c @@ -665,11 +665,13 @@ _tcp_lro_flush_tcphpts(struct lro_ctrl *lc, struct lro_entry *le) void tcp_lro_hpts_init(void) { + tcp_hpts_softclock = _tcp_hpts_softclock; tcp_lro_flush_tcphpts = _tcp_lro_flush_tcphpts; } void tcp_lro_hpts_uninit(void) { - atomic_store_ptr(&tcp_lro_flush_tcphpts, NULL); + tcp_hpts_softclock = NULL; + tcp_lro_flush_tcphpts = NULL; } diff --git a/sys/sys/systm.h b/sys/sys/systm.h index c4e0aafac452..1c96d99ff98f 100644 --- a/sys/sys/systm.h +++ b/sys/sys/systm.h @@ -399,14 +399,6 @@ void cpu_et_frequency(struct eventtimer *et, uint64_t newfreq); extern int cpu_disable_c2_sleep; extern int cpu_disable_c3_sleep; -extern void (*tcp_hpts_softclock)(void); -extern volatile uint32_t __read_frequently hpts_that_need_softclock; - -#define tcp_hpts_softclock() do { \ - if (hpts_that_need_softclock > 0) \ - tcp_hpts_softclock(); \ -} while (0) - char *kern_getenv(const char *name); void freeenv(char *env); int getenv_int(const char *name, int *data); From nobody Thu Mar 5 04:15:38 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRGRZ5PnYz6TY7y for ; Thu, 05 Mar 2026 04:15: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRGRZ2jCrz3BrJ for ; Thu, 05 Mar 2026 04:15:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772684138; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zWDvHPYW29V18TJbESlAFZMbPm3teC71we6Gi8FnNJ8=; b=dE1J6ev9/8RyixTSeeN9r+VYmvpmXhduRTAv1o3rQ54xh0tKiwq/LRqg5t0OMZfkHawH5v RXRHsjniOEw0oZAA43IouDC2t8qXqjLfu5iPr0OldWoa3A3kb1ojalEmfGsX1Mrdcb35hF /jLviHPJwq9bfTX95bPlo4SRTP8RwOyF41TOw/BNghm8/Pk7GxR/wHHPbLIq/d5ThoQ3BN IPqp3L+gMqGbPlNSugYT9Yi9s01h7oF+AcnpVsGdNPpFzspr+j/OyXJ3+sfCZb7FpaUHO6 CyVN+7dfUEfquMxnu7W5zNd6bEn3es6TY2Z23gfVwryJZmP3GK0/kaP9AyBqXQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772684138; a=rsa-sha256; cv=none; b=ng1ZuJurmRRY4gCf5gbuvhvj/D1kBuxldSwRcsby2iQdkcL3pBT2mBQD/C2K2mvOoq7t+m 4aagDWz7lT3DIUIpXtMb1NSANsPUVSa3wj1i5RfQifzDafmBUPUq/sE+pCbK/8puaeiJiT zealGnToMPkORy3ZrkzhPk+3VUcnRXJsWTNOY85ArMwanI2RXNUty3cFIkahIGjPDBi+8t rshFLQtbxySbCSDPkn5e2KLKFHUmemi4u5iit5/mv2fvvPAFLj5Tm5/PF6Nm8Hgm1CtPts eYkoHXMrFNRU5SrGRYNXHNTqbFnQrcdcMi/Fa2DSkdHgiFHzKN8NxByiNGquRw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772684138; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zWDvHPYW29V18TJbESlAFZMbPm3teC71we6Gi8FnNJ8=; b=ZN4Tvpaf6cMupII02n3K2JVR+U/Bb2WihC7YjhzSmlHaQEEkEDZKMPuEvD7bnx0gnzCO2d HQo4FXrDrOOjJvmS25TaqNc5JqLJxGurJ7ADswQXsXErdJu8p3HihMdm12ngOKAVylGC7F 6qjoG2E0W9ur8FtY2llREOjeaQJzuvXYnNqJp9Ya6HG1W5kJbcLA2NeVxE5r//wXrw7ZF5 G/Pa2k4p3fmd1kAMxuP09CiykuCLIvNP7Qjxm2pAUeLV7cX8B+bfy9rnJxbisrmrMJ0MYJ Kzj6lo0IXOG18shdHQtSVp9OwOw+Xsk9b1GmN/x7rGj3ftrngiyYczYca5+XOw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRGRZ215tz5ww for ; Thu, 05 Mar 2026 04:15:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3b9ec by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 04:15:38 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: d4083fb836cf - main - tests/net/bpf: hexdump(3) the packets if compare fails List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: d4083fb836cf5d06a2bc2d6fe7297fb5139c8fc6 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 04:15:38 +0000 Message-Id: <69a9036a.3b9ec.175bcd91@gitrepo.freebsd.org> The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=d4083fb836cf5d06a2bc2d6fe7297fb5139c8fc6 commit d4083fb836cf5d06a2bc2d6fe7297fb5139c8fc6 Author: Gleb Smirnoff AuthorDate: 2026-03-05 03:57:59 +0000 Commit: Gleb Smirnoff CommitDate: 2026-03-05 03:57:59 +0000 tests/net/bpf: hexdump(3) the packets if compare fails --- tests/sys/net/bpf/Makefile | 2 +- tests/sys/net/bpf/pcap-test.c | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/tests/sys/net/bpf/Makefile b/tests/sys/net/bpf/Makefile index cee27b550434..62e04e5a9707 100644 --- a/tests/sys/net/bpf/Makefile +++ b/tests/sys/net/bpf/Makefile @@ -10,7 +10,7 @@ LIBADD+= nv PROGS= bpf_multi_read pcap-test LIBADD.bpf_multi_read+= pcap CFLAGS.pcap-test.c+= -Wno-cast-align -LIBADD.pcap-test+= pcap +LIBADD.pcap-test+= pcap util ATF_TESTS_SH= bpf diff --git a/tests/sys/net/bpf/pcap-test.c b/tests/sys/net/bpf/pcap-test.c index 9d01548f7aae..4f837959208f 100644 --- a/tests/sys/net/bpf/pcap-test.c +++ b/tests/sys/net/bpf/pcap-test.c @@ -31,6 +31,7 @@ #include #include #include +#include #include #include #include @@ -219,8 +220,11 @@ compare(int argc __unused, char *argv[]) if (p1->caplen != p2->caplen) errx(1, "packet #%u capture length %u != %u", cnt, p1->caplen, p2->caplen); - if (memcmp(p1->data, p2->data, p1->caplen) != 0) + if (memcmp(p1->data, p2->data, p1->caplen) != 0) { + hexdump(p1->data, p1->caplen, argv[0], 0); + hexdump(p2->data, p2->caplen, argv[1], 0); errx(1, "packet #%u payload different", cnt); + } } if (p1 != NULL || p2 != NULL) errx(1, "packet count different"); From nobody Thu Mar 5 04:15:40 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRGRc66p4z6TYY2 for ; Thu, 05 Mar 2026 04: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRGRc42X8z3C4K for ; Thu, 05 Mar 2026 04: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=1772684140; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=D/MfA5XfKTDZQ4iO6Lh3J3YkvXy4s7U5/a84UhlUVog=; b=vLaqGKukQ7iyb+giFABbc95ac9/DXGSJZLLBOvbBa2a9dLViCWgNfSLu99tk1DJ0ZZGQ+4 Ss6FQiZeQUlVneJlBR76Ow+u7Dzopb/6XKwqCK2c1gjry9CftqOLYb7C+wINcnJbinVTsp UicjPC/Hg03A74MajmZXCV0icENHnZVnHlc2xJ7Wc1VaVnpP+8EeqSRTlciOlloS7c/VDV cvvKqKPAfbPLHWzBbADu1TD8O4NCTxsnKkcy7wrRXHgHpPKSAVpVjSiODc/yqx/4QLiEJX 8Mn6mrvQrjj7GX7SeO0q8zV8ZKQVnf8+WfFRSqdna+9M5KHb7XAGJ7xjNkl2Cw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772684140; a=rsa-sha256; cv=none; b=fUTHjax287ZPuTzLCW7AtZwgYdm7dQZx9ETIMYyyZ3Pf5+o+2gf8qdrlNjlyrNql0onB8Y I/BAXjnWcAqhAs4gO5W5/rL/gMGEKFWrVuQLFtuG9A9nJ29n+ltT3JziVCCxXcwD/YcJeF LVR/DQEx6Pu5bJwSFEVonOgnsvB0Ec+sAqkQKSbjs/gz6s04jd7WpV5BG1PHt/bgAB/qb1 caxubswj/bszHuZB8n+7aUr7YK37fmoqYcfFSx7BI6GcVjeKjjnxmWhJoLDMj0zx46hb5G WNn42dByQKSgYmGBnEPmAbtnaSv1VRQ91zP+4AwOh/yqnVQWe8F+u92XafuusA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772684140; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=D/MfA5XfKTDZQ4iO6Lh3J3YkvXy4s7U5/a84UhlUVog=; b=GMODTV8vldHnUPrEkkauTWEuUxKLhAI/biWFrjpF5N1MS24LvevMVI2pHVHX0g/VIja2f+ 0NhXslh6T3j+FUmnrRIHxiBis3T5jdnTbX/B3tYQv254RfEgIlyPUS0MWgiI71flGrUgto 7MmQDGDDOi/RmgwG2gEQg8u4rOr/BTmNfgi/RjqB/Or6ZeJTvyk6ZFQ+PNrWhCYqzK/r0F s4VAGvNvkemRuOInsvGOMbEYWHqI7uIFbfNewOQ+VMKJE5TCikW5nJKS3bWy2AXTpF2f+f 0IwbHlkAgkhcMeC4jmDXZ4+LbXoaFo7IhbhfdawinG2/YadnSAtKnm77u6EghA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRGRc3cTsz60V for ; Thu, 05 Mar 2026 04:15:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3ca6c by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 04:15:40 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: 1abb62867f2a - main - tests/net/bpf: skip the bpf:inject test when RSS is present List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 1abb62867f2a36acb689fdfed62af00b78d8f324 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 04:15:40 +0000 Message-Id: <69a9036c.3ca6c.ef38a0e@gitrepo.freebsd.org> The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=1abb62867f2a36acb689fdfed62af00b78d8f324 commit 1abb62867f2a36acb689fdfed62af00b78d8f324 Author: Gleb Smirnoff AuthorDate: 2026-03-05 04:04:11 +0000 Commit: Gleb Smirnoff CommitDate: 2026-03-05 04:04:11 +0000 tests/net/bpf: skip the bpf:inject test when RSS is present With RSS the epair(4) may reorder packets making the test flaky. See net/if_epair.c:epair_select_queue(). --- tests/sys/net/bpf/bpf.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/sys/net/bpf/bpf.sh b/tests/sys/net/bpf/bpf.sh index f2d647b61de0..a721c3327b19 100644 --- a/tests/sys/net/bpf/bpf.sh +++ b/tests/sys/net/bpf/bpf.sh @@ -69,6 +69,10 @@ inject_body() { vnet_init + if sysctl -q kern.features.rss >/dev/null; then + atf_skip "This test is flaky with RSS" + fi + epair=$(vnet_mkepair) ifconfig ${epair}a inet 192.0.2.1/24 up vnet_mkjail alcatraz ${epair}b From nobody Thu Mar 5 04:15:39 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRGRb726yz6TY3D for ; Thu, 05 Mar 2026 04: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRGRb3Cn9z3Bx5 for ; Thu, 05 Mar 2026 04: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=1772684139; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=RbndACEfzX3r+c8tBxBnREIiFRuY19jRZdnEQqbaL7Y=; b=c+0povnfYNBUX2MmS8BD8ucHuKZVjWQglqdxNVrPk972RSirXfG6ptdCFIj+0G40OAt3H5 U+GVckkNM37eHc6BRkEmIA0w12RuJ7vm0CP9vo47gYBvxxlnXv/q86FQedBgaqg6GPFW7l GaXIZ8wFO/c+U5BBoTQvuT0+WLL8pZCZ1LfhSM+i5Womduq/xlBv19lxSORgAX+p6iAYOb WyxqvLSWOyalK65H3Uy1rKT9/5AcmHwbW2qmY8pqfSoKiN3n1aFMbnFv4bCGf1JTTgrvff /rsodxgf/HA+5IdwNLn0f8+qNr63JMSUqe/HiHIyTDz3WnLsrUUsLMs40V4aMg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772684139; a=rsa-sha256; cv=none; b=bOcpYxTMAYWhpECMcg5V+vqc5EMH+9Zhq7wUpj/8y684afFYUq/TLL7ZnyvVGfomdU+Ek/ Q+/e0mo97TQceamJ/iMbd9bYSxRCNHNJAbIBU4QoqLxTi4+XJOeBnD25vB/9SiCIl1/aOE EUePYuWQq+u/gCziU59fgOlMAdh1+OFBdr6bojAfAqMedpx1wJ3m0vIdLmtaCx2OfUd2Ow 5nSnbwbf7r/YSO4zTCPhigdxUZ90IcMBJ7wd452GxjKxySEdMrLnl9Yzt5fJnhArBkOFrv bMd6nvd4uMIDNMOkGD0tp9VXpGUTIdAfnox9VH2jPGwcoHsmrgiImuPh8DD/5w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772684139; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=RbndACEfzX3r+c8tBxBnREIiFRuY19jRZdnEQqbaL7Y=; b=ExWuuYgnFD5trCNK6KIjSyJKR7oDy4krIIZzP20n12NmXzIXQMOSkaSRZmdWKL43hUZaFt YGFDIqDC1CIt6U4q5Lv6gx4DpIY23PR3jDX+0MFvCutuZTpxNdDmqttUe7NPjG/WRhROJi ADptA/Sdh3zJnCnaPXFvVDo5vLSf0z7opf4NlfBIan8U8vmaDOQdO7UFxUfMGMBRt5wFxc dMEZnh8i1bSQ9JPSy5bRTXEJOHWYa/js7eMkex4YoTcMMIg3FlR0ex94aF0k02zWtntq6Y ceav3rdHhWfc25Bez/HhQBF7cXVX0WsOKwrfc9fWOgJBa6ezyzUjY33SGq9hYg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRGRb2q4kz55C for ; Thu, 05 Mar 2026 04:15:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3d22d by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 04:15:39 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: 78843218b0cc - main - rss: manifest RSS option in kernel with kern.features sysctl List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 78843218b0cc4679826c15829b355f27c17d3fc1 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 04:15:39 +0000 Message-Id: <69a9036b.3d22d.3878a3d4@gitrepo.freebsd.org> The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=78843218b0cc4679826c15829b355f27c17d3fc1 commit 78843218b0cc4679826c15829b355f27c17d3fc1 Author: Gleb Smirnoff AuthorDate: 2026-03-05 04:01:22 +0000 Commit: Gleb Smirnoff CommitDate: 2026-03-05 04:01:22 +0000 rss: manifest RSS option in kernel with kern.features sysctl --- sys/net/rss_config.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/net/rss_config.c b/sys/net/rss_config.c index 9e4120a4e9dd..5be5aecd15d9 100644 --- a/sys/net/rss_config.c +++ b/sys/net/rss_config.c @@ -91,6 +91,7 @@ SYSCTL_INT(_net_inet_rss, OID_AUTO, hashalgo, CTLFLAG_RDTUN, &rss_hashalgo, 0, "RSS hash algorithm"); #ifdef RSS +FEATURE(rss, "Receiver-side scaling"); /* * Size of the indirection table; at most 128 entries per the RSS spec. We * size it to at least 2 times the number of CPUs by default to allow useful From nobody Thu Mar 5 07:18:10 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRLVC0XVMz6Tm9w for ; Thu, 05 Mar 2026 07:18: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRLVB67Jbz3TyY for ; Thu, 05 Mar 2026 07:18:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772695090; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=A6CQ9YW3H7gz8b5XK5nyuBVaAa50t/OwsKDMOlHw3cc=; b=CeW+4TwfgZSTVQ5+nHiRww85DaHkVYGxxdH4tCti6YYncZfAXy9fpxq5MUD0ExjPDGIsT6 wl2tfws3XpLt5fGngtcSC9bmX0G5H/QO+x4H5muXQg9OhbKrQ9XJlpaIcq2hYh16jifUs5 41LO/BK4nV5d1b7eDrmwhN/CHbNSZFIX8oKn1Pg+IgthDC58RoNciBw+h0LSU5HyXloECK 7ksjJBPtYL3QABiQgTgKbPyKeuGKCZa8ReWUMfwbKLewZ0I/zSNtKlROKdzNwmW8BXSedp wdEGcGNrmOfo1rvmIGFjI9mUku6XzHqQ1BMUVYOjvpmDIf4mesvBuUh+b3uo2A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772695090; a=rsa-sha256; cv=none; b=mrb47BY0H5a5O2Egynytd7mhhKLq+f8B8u4I0m6Jg0YubdduLSr4StnHYjz7gIhizUPGgX gMkJCk0VMf5Dc9DvC2x9m3BTWfRrXUesGtLTH+BJXohjX7rueIXGuQI06d1wlQBbi84Gdf FNq7ckdsVP0TIX7v/0SXb3mL9DlsZnNyLUBewZJcfT+8ixhDmnKXv8r3zbYUgzcWSV7HiP lZpSEnVJ9zXJ02x3tHifp3rJNCYDXbHxrsbZplNXT5PhANvzvUaDi2k/R4cC4y4aPkSSwU N4m3Ud+uFzibTOnUOJuvnU8QYQijeR2Q1RDDRbsr1m+6cFXCZ3H1ytO+mBPaRA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772695090; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=A6CQ9YW3H7gz8b5XK5nyuBVaAa50t/OwsKDMOlHw3cc=; b=cEFgeeSUJ4X8TZfY7k2uASwngsmPq8QZl50R2cnGe2rrRojwd0RQgZB9I+sUJPIFe4UqtE h787opAcCPpm+qwLYPgfO6IZ0HU57ixghqOSCCaiqVCw5o4lp+98pK2frKG52Yns7XwwIw eQqpv8ak1vH8yVgki3qSo/BT9vWazizSkzJh2kBRlKQQ2V3T45+plYQA7BxN7yjqv3ouf6 8ZraO3M8QfZIWdnovWXE4Cdxr7f8ktmFrPGiA8gjdsviRVIxszlKCAiI/k7M/HTRAy0wY3 +LcGMJPuWtdA7P3w8mSoikE4Bavp0oMn+3iZbhclI6tXudrT50WgSj01Us0DaA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRLVB5SSKzBQn for ; Thu, 05 Mar 2026 07:18:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1f40f by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 07:18:10 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Baptiste Daroussin Subject: git: 28ff4d35f8b9 - main - libedit: vendor import version 2026-03-04 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 28ff4d35f8b904952bf86b3264650d91cc0cb5d7 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 07:18:10 +0000 Message-Id: <69a92e32.1f40f.65c93a59@gitrepo.freebsd.org> The branch main has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=28ff4d35f8b904952bf86b3264650d91cc0cb5d7 commit 28ff4d35f8b904952bf86b3264650d91cc0cb5d7 Merge: 1abb62867f2a b1ddc060e941 Author: Baptiste Daroussin AuthorDate: 2026-03-05 07:17:09 +0000 Commit: Baptiste Daroussin CommitDate: 2026-03-05 07:17:51 +0000 libedit: vendor import version 2026-03-04 MFC After: 1 week contrib/libedit/ChangeLog | 6123 ++++++++++++++++++++++++++++++++++- contrib/libedit/chared.c | 50 +- contrib/libedit/chared.h | 22 +- contrib/libedit/common.c | 12 +- contrib/libedit/edit.expsym | 1 + contrib/libedit/editline.3 | 38 +- contrib/libedit/editline.7 | 10 +- contrib/libedit/el.c | 30 +- contrib/libedit/el.h | 3 +- contrib/libedit/eln.c | 12 +- contrib/libedit/emacs.c | 16 +- contrib/libedit/hist.c | 10 +- contrib/libedit/hist.h | 4 +- contrib/libedit/histedit.h | 4 +- contrib/libedit/history.c | 6 +- contrib/libedit/makelist | 4 +- contrib/libedit/map.c | 45 +- contrib/libedit/map.h | 7 +- contrib/libedit/readline.c | 16 +- contrib/libedit/readline/readline.h | 3 +- contrib/libedit/refresh.c | 14 +- contrib/libedit/search.c | 7 +- contrib/libedit/sig.c | 6 +- contrib/libedit/terminal.c | 6 +- contrib/libedit/vi.c | 14 +- 25 files changed, 6358 insertions(+), 105 deletions(-) From nobody Thu Mar 5 08:56:21 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRNgT3Km6z6TtNp for ; Thu, 05 Mar 2026 08:56: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRNgT2F7yz3fdT for ; Thu, 05 Mar 2026 08:56:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772700981; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VCUMdpCjSOSQ3GRbn40SrMRW0UW5zzU7YnnwPCXDUvw=; b=ODmHs600rBc9FvGOOXodjIBTsnMNQPnLeke9hsTsWFkrtWbA+zBiLcKiBbQitLKxN7FC4X k0Xj+FPLlsMU/pJifmLw/cpEElG6IxWNn4foaZMie4bbhX5tCj0oHw18dueh3d7xEAReS9 iNP5IhiOAvERfAcxUmu6PwdIqERB/MWOGwjLAkVQbW7qQvEDoy5j6lQFNYc4D0hH6Ji6Cf haZqjguOg6hke0KZX2fTZHER9+lqGIgU8rhC467U+HHm3wB9D8W/F261gvjwZGBxcXcGk1 DGfKxVl60StrJ6MS5RVioyLp7tsF8TpTegsUAJhxuFrYhgRTZrI1e/K2LkKZzA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772700981; a=rsa-sha256; cv=none; b=e25DTkJr+XWLpVeSi1oVgEMJ/aOk6BM7QPqcZHrfbbZ9U+OwTBJgfeanB8yt77k+qy8zX6 AKoO7D+SMqB7p+cWzyp8aHGHiPo+fOh9dUp8vBw70uF8YSsa3LsE8pDw7Orn/ruarMSEff amZaNNsK65gP4sd8+5Unz5IXBCJQHgha5Yn8G4YWhwEboigdPAkjuyI+XuYHf6kGAFquvD XBklIsp7gbdKx6hr6ShXyNSSiPoBDPK9biRxu1dLDZ2Fs6aXffIcvX3cJxlymehJRtpf/c YVGyHVg6G5QdOY90Oq29lxWVRDxsa8X8i7sWoJ9jozGZD1o0oTYYCBVEmCunJw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772700981; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VCUMdpCjSOSQ3GRbn40SrMRW0UW5zzU7YnnwPCXDUvw=; b=YwNYAySLMhnr2FdfHMo/2QoBEJFKu473E4d6dMZBC1ai9yJKycmVA2OLMWkxIwBhgQm5tL ErJC4czOQkSQYLbYU3mpgugpAfQlwTk/Tn87WfjzBvdop3eZ0NwpNLm51x0kwPYgYw9K1O M2Ff0GVrWwn9yrLcCmpBBeh2HTep1jPg91DijoTCl038VuLMxTmFOc91uxIBduqNNtDfJP OCcsTSrKZf9MUbOX9Oie43l2wtBYILbrB00+gsCW5HdR/uFRUduRg7hxpWtoJfKoYb2sY5 EXD68yCs1wG9m42/ww2JAoLwKZKihywhJDv5CEakX2AFNxKCeDlxCySslZg8SA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRNgT1Fs1zTbm for ; Thu, 05 Mar 2026 08:56:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 31a88 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 08:56:21 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ruslan Bukin Subject: git: dff2758b5fa7 - main - static dtb: add BTI note List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: br X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: dff2758b5fa7d4987b03f3a04e1b02b367fe9b73 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 08:56:21 +0000 Message-Id: <69a94535.31a88.2ad98473@gitrepo.freebsd.org> The branch main has been updated by br: URL: https://cgit.FreeBSD.org/src/commit/?id=dff2758b5fa7d4987b03f3a04e1b02b367fe9b73 commit dff2758b5fa7d4987b03f3a04e1b02b367fe9b73 Author: Ruslan Bukin AuthorDate: 2026-03-05 08:50:18 +0000 Commit: Ruslan Bukin CommitDate: 2026-03-05 08:50:26 +0000 static dtb: add BTI note Add BTI note to fdt_static_dtb.o - resolves "Branch Target Exception" panic on FDT systems with static DTB due to missing landing pads (bti note has to be in all object files used for linkage) - also required by bti_report linker feature Reviewed by: andrew Differential Revision: https://reviews.freebsd.org/D55636 --- sys/dev/fdt/fdt_static_dtb.S | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sys/dev/fdt/fdt_static_dtb.S b/sys/dev/fdt/fdt_static_dtb.S index 6ff6e312197d..d657236479aa 100644 --- a/sys/dev/fdt/fdt_static_dtb.S +++ b/sys/dev/fdt/fdt_static_dtb.S @@ -28,6 +28,13 @@ #include "fdt_static_dtb.h" +#if defined(__aarch64__) +#include +#include + +GNU_PROPERTY_AARCH64_FEATURE_1_NOTE(GNU_PROPERTY_AARCH64_FEATURE_1_VAL) +#endif + .data .ascii "Device Tree Blob STARTS here" .global fdt_static_dtb From nobody Thu Mar 5 09:01:47 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRNns0kJCz6Tv57 for ; Thu, 05 Mar 2026 09:01: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRNnl5z35z3g6f for ; Thu, 05 Mar 2026 09:01:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772701307; 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; bh=qEtXm3UrWCO+x0XKLi+8YGJF1851SjNHYVlnRpHb7hg=; b=FizL2AbgHp6SvvBBlJJ95XVTHQHTDhEpEkdRKarJNX1V0nkhhn7HEKMfffR6YUocMH+SsR 17Aq/ADkL/0NvMepU+B5Zp6/TOuwOP7/ukip8t9m7WcTd8QMD5ZdGEpEZtueHnrHPLuH+i +NEmHSP6WnaYt0z7NceETncuz2H+Pw5z3KCfmAK2Jvt+HT1QgLzCEx35eGzR4XWEVxA9TL 3OiiRYeBIb1JGuZMc0A+MY8b3Slut/yG2bcAuzQ6m9mU7PEszEfpXTqB7xXG0SiuCw0v1j KTMBTLRXiXi8tLKw9qPZ/MtyxlpwKqqhmCQuuOu1rfOMH73k8TBkpcpxt2NCtg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772701307; a=rsa-sha256; cv=none; b=LVImvddrFqkSjsyFmzFmPyLL8ZnCG09SDaFs3CzX2uVQzL4bNDRYEdDBsXsuTdkrfUHgXN 6UdnsOYMkYkTSGUfNfKkR51DawJcvlV7gGYIgAJZVR9rB1/bUGgocOIt1tcW1SF1KamM3i h7l88uUWCPDKT8v1yYB/k1cj3dmkxPYrjWclyYKYCW6ViUsYLpsbFnOQbN27HkoFW93pTz 4Hd2mRQrexNBgtnbkkCfFW0su6vUksVZD9/qc5/OxWjKfINBSOMJc4oqTfDTSKFYSTJuwN ZDzLwY2NTfghTD1b/YIoMI5t/81AdU8iFJzT8vbEU/3xBhtGOWPaICqCrr7Dpg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772701307; 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; bh=qEtXm3UrWCO+x0XKLi+8YGJF1851SjNHYVlnRpHb7hg=; b=BLireQ2c3JESujyAcO9MzVtqpw+2mtM2LSfmnRElTQt7/MVcB3/LxRTWNi/ABJKIiAfXA0 u9JWDs+QxhnhyUwd2ECg6qMKnMJkd3iemuHWkpGU8s14LHS0gJCScPu1QTnyQzClRwx/on BN5ySgQ/Iu5f0/M/6lyp8EmR5e+wlWoFedAbgVpaaC9eRc5J1EycylcrPYD5lYa5q9bLpp 0ZXIyNswpGwMM6YXrWp3oIT47QWX4C/ZexfEx1j3u7GTflin1H4ulKCweHss/u52sCw1UQ /xeluqbgEWhnO7XyLw1+32Po0w2d2rvGagUt7JAYUYeMTohTVXaKD50F74Sl3A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRNnl5S7nzVTZ for ; Thu, 05 Mar 2026 09:01:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 32d34 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 09:01:47 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Jari Sihvola From: Ruslan Bukin Subject: git: d3eaa40282c7 - main - riscv: save FPE state in cpu_fork(). List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: br X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d3eaa40282c7734385d028b6a4fb9574d17255e3 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 09:01:47 +0000 Message-Id: <69a9467b.32d34.7c7a08cf@gitrepo.freebsd.org> The branch main has been updated by br: URL: https://cgit.FreeBSD.org/src/commit/?id=d3eaa40282c7734385d028b6a4fb9574d17255e3 commit d3eaa40282c7734385d028b6a4fb9574d17255e3 Author: Jari Sihvola AuthorDate: 2026-03-05 08:57:22 +0000 Commit: Ruslan Bukin CommitDate: 2026-03-05 09:00:23 +0000 riscv: save FPE state in cpu_fork(). Save the Floating Point Extension (FPE) state before copying struct pcb. Reviewed by: br Differential Revision: https://reviews.freebsd.org/D53804 --- sys/riscv/riscv/vm_machdep.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/sys/riscv/riscv/vm_machdep.c b/sys/riscv/riscv/vm_machdep.c index e5a5cf31af15..e0254f80e62f 100644 --- a/sys/riscv/riscv/vm_machdep.c +++ b/sys/riscv/riscv/vm_machdep.c @@ -48,6 +48,7 @@ #include #include +#include #include #include #include @@ -91,7 +92,13 @@ cpu_fork(struct thread *td1, struct proc *p2, struct thread *td2, int flags) if ((flags & RFPROC) == 0) return; - /* RISCVTODO: save the FPU state here */ + /* Ensure the floating-point state is saved before copying the pcb. */ + if ((td1->td_pcb->pcb_fpflags & PCB_FP_STARTED) != 0) { + MPASS(td1 == curthread); + critical_enter(); + fpe_state_save(td1); + critical_exit(); + } cpu_set_pcb_frame(td2); From nobody Thu Mar 5 10:25:08 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRQdx04nLz6Slkj for ; Thu, 05 Mar 2026 10:25: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRQdw5N07z3sVn for ; Thu, 05 Mar 2026 10:25:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772706308; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PfnAAJ2AUBdkg+81Mb53MPrI+9l91G+qGMQNFYHKm2k=; b=g/xkxM7mJu3yE00a9QvZlL/pv9W6gPDzgZKiVEKPQfC2+qqShlP9h3CXwHw55/OEXyQyUy HcUitUfHMWOWNoRbYsNhak+2nIrMfc3lHEqhIcYLCcfzgzdxgeRZ7J0x3PsHK0JS0W5NLO rhf7J90+3qveQyT0oqjT0wWz7qo1kc5YWh1E49bpHEJv1608bn01Ax6PMh3DKnHQkvcG0k yuCq5PQoWSYiD+uys60X9njqOAE6GbjkJvGpRwA2IMzjPMGm+9lEmODMjjbpz6yeFJn+8r RKUExscO32JhYXMhi+Z9hVM40Oun+vr9TwD/wXtEiflEfhsHyNFnestE48bRzw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772706308; a=rsa-sha256; cv=none; b=WkXEiodWp2F+goihxiFEjtaGWLouQB69W8L9UYhM1y+2PnoiQM1eQFxUNYQuxapsF6FuAa NVOqMJXBdT7xYigNorTji98i2w5vLu8G1Pn9WmgA8w2t9TTIWvwJiNFsHXJhmO7LiE/FKk qJqhuqhL66nYV118aSFxPQMSsWwOw2TXudCvewuhvshE8Qf5Y2slMmjYfAiZHYCctQMbCD MNmP2Q8Ct9gs6ocu4zelkV+jc6CYcNG85DkkzkTysPN+Yrt+JdBVyyZ/96xmVUa9SN6XwV eLYK37z5asMC6L6oCO1nvXks0ROEToOtNdatI9gUR50lcUfkaEZlFzHvWLSs/A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772706308; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PfnAAJ2AUBdkg+81Mb53MPrI+9l91G+qGMQNFYHKm2k=; b=LJ6M/6iMCqlBBYKS9/1ifDgRErrvkVNjWUiT1A2Kxd7U75dNJBE1nCBJor1+4C17kjeNbD M/DjwBMgJYWVN9uGzNZsPVDz7qx8q9oz2SRKZunEUOMYWKRk+jH/jqOlrVPvbR7OqClDMR P/fsAMo/4kgm6mO0xXak/HSMj7Hmu0ovNVYZXY44QF5HguTTATxcIoWvF9aexRiEJzTl5h FD+q0gMB8Fr1neJGOqq3VIRPzKPkt3O+vEjt3tCZD8uXcqUCroUdlGhF0E5UPxyBRb/HHj kQd41UK/R+SyHerPS9e0GRJm8kZN2WHRl6XfN8E7JxnD+ION0IdGBJzavST+bg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRQdw4gp1zZ1L for ; Thu, 05 Mar 2026 10:25:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3ad7c by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 10:25:08 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Brooks Davis Subject: git: ea9bc8465830 - main - cirrus-ci: move package_check after test List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: brooks X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ea9bc84658308c8bdef94b2bda00781ef7c473a6 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 10:25:08 +0000 Message-Id: <69a95a04.3ad7c.67d71cff@gitrepo.freebsd.org> The branch main has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=ea9bc84658308c8bdef94b2bda00781ef7c473a6 commit ea9bc84658308c8bdef94b2bda00781ef7c473a6 Author: Brooks Davis AuthorDate: 2026-03-05 10:23:51 +0000 Commit: Brooks Davis CommitDate: 2026-03-05 10:23:51 +0000 cirrus-ci: move package_check after test Liveness is often more important than minor packaging glitches (which might well be the fault of a prior commit.) Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D55481 --- .cirrus.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.cirrus.yml b/.cirrus.yml index 4d166e1c6818..83cfe6e5c591 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -162,13 +162,13 @@ task: package_script: - su user -c "make -j$(nproc) CROSS_TOOLCHAIN=${TOOLCHAIN} WITHOUT_TOOLCHAIN=yes packages" - package_check_script: - - su user -c "/usr/libexec/flua tools/pkgbase/metalog_reader.lua -c /usr/obj/$(pwd -P)/${TARGET}.${TARGET_ARCH}/worldstage/METALOG" - test_script: - sh .cirrus-ci/pkg-install.sh qemu-nox11 - sh tools/boot/ci-qemu-test.sh + package_check_script: + - su user -c "/usr/libexec/flua tools/pkgbase/metalog_reader.lua -c /usr/obj/$(pwd -P)/${TARGET}.${TARGET_ARCH}/worldstage/METALOG" + make_sysent_script: # Check that make sysent results were committed if required - make sysent From nobody Thu Mar 5 10:30:41 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRQmK6jDmz6SmLG for ; Thu, 05 Mar 2026 10:30: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRQmK5wQRz3sjh for ; Thu, 05 Mar 2026 10:30:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772706641; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2atVUUKurYaqvo6cCXBeNGJF8aQQexQwov6HTfOOelM=; b=dH5z9xqawF9EWeo6uhrIkemUvmZtlumHLcW9SlrYHfdbZVtvrlfAaInSBMiVim1p4VavQK uN0RR0D4zVfFF1waLtbBAE/WVBlnimYiFLxNDV+EkiAnxoVZIa64Ba0N2DJcrKc1Rs27nR Z9oBuGVjMXnPPCQT64QExp1wlRlqBiBaMUVRi2Mg4UiBRDHtmZFRzvD5e/eyXQ75QXLYCH lgx53LgurZy2ZvdsJ+c/Opb+8G5COXaYOz51Sn0LFJDgugt5DngbC6VDORtoV5J2XiL4Vs VZWSig8X2Mf2OFlbZsnVbqA0HN08JTv4q+VMahP7AtmTjvJ8Tkyvl4CUgOR5rg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772706641; a=rsa-sha256; cv=none; b=IQ5JkhB4jTo5Ansr58/QBf/xU3rrFi/U4TCkkGRihxU255oKVAq46bNvrRLeSqgn17XzUC RceqPG+wzIomw7CcvIrkmNn31l6YDgcm7a31t6R472yFrmZjO70qLWPIRH6DvNf4Vmvurx EHxcMk9h4Bxcl+5HqrXMrVjyHm3pdtORvga9B7/EAc4guvrk8ODGw4gJTMXUvsktMMn1x8 jSP4QzAS2GjIJqsPS6ySfwQj0UlGmI9ijxl6Cm3fTauWmWKvBnvnT4mE1S62iCK75/OrJQ eDluq30eVlYCPmePML1JkTjpor8qIGHLRqe+cbRsGDGFEJ+iLpJWN2SbrgC+sA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772706641; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2atVUUKurYaqvo6cCXBeNGJF8aQQexQwov6HTfOOelM=; b=XynY4+YUiUdaxx4l+advPtEP29yzOmpF/Sv8a6GsT/4juxszd1XScvPnytDzMYDajnEonl egl7PPECvHwoK6XUptzhuG5EkhnorvQVWFlajhRaWX87+36HThM3PujpFEmI1Pq+6mDrQa bojS4fUHcHjNca5esOer62mIX8sIXdG57mX1Uu/slnFVJwihX8gqkZ558RMNU0WPDHtq+z gEGlDBo19/wFzO4BpZas2hNQOwWVdHgR001NwxuVp7iO1Dsm5/JUYNp8RMaiXOemjZXYUD wmofK7wOJSSrS9Jggv3bRABAx2JND5vCc7D4htwQgCa961NrnbRcNmqABSTQbg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRQmK5B8xzYk5 for ; Thu, 05 Mar 2026 10:30:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3c585 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 10:30:41 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Brooks Davis Subject: git: db1ecd5854d4 - main - getnetconfig: make nc_error a thread local variable List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: brooks X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: db1ecd5854d4d9ed596d6411a01de0df6e41e629 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 10:30:41 +0000 Message-Id: <69a95b51.3c585.e5364fe@gitrepo.freebsd.org> The branch main has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=db1ecd5854d4d9ed596d6411a01de0df6e41e629 commit db1ecd5854d4d9ed596d6411a01de0df6e41e629 Author: Brooks Davis AuthorDate: 2026-03-05 10:30:30 +0000 Commit: Brooks Davis CommitDate: 2026-03-05 10:30:30 +0000 getnetconfig: make nc_error a thread local variable Remove a bunch of complexity at the cost of 4 bytes of storage per thread. Reviewed by: jhb Sponsored by: DARPA, AFRL Differential Revision: https://reviews.freebsd.org/D55310 --- lib/libc/rpc/getnetconfig.c | 39 +-------------------------------------- 1 file changed, 1 insertion(+), 38 deletions(-) diff --git a/lib/libc/rpc/getnetconfig.c b/lib/libc/rpc/getnetconfig.c index 03a4497b21ec..5e78cd19ebf1 100644 --- a/lib/libc/rpc/getnetconfig.c +++ b/lib/libc/rpc/getnetconfig.c @@ -118,7 +118,6 @@ struct netconfig_vars { #define NC_INVALID 0 -static int *__nc_error(void); static int parse_ncp(char *, struct netconfig *); static struct netconfig *dup_ncp(struct netconfig *); @@ -129,46 +128,10 @@ static mutex_t nc_file_lock = MUTEX_INITIALIZER; static struct netconfig_info ni = { 0, 0, NULL, NULL}; static mutex_t ni_lock = MUTEX_INITIALIZER; -static thread_key_t nc_key; -static once_t nc_once = ONCE_INITIALIZER; -static int nc_key_error; - -static void -nc_key_init(void) -{ - - nc_key_error = thr_keycreate(&nc_key, free); -} +static _Thread_local int nc_error = 0; #define MAXNETCONFIGLINE 1000 -static int * -__nc_error(void) -{ - static int nc_error = 0; - int *nc_addr; - - /* - * Use the static `nc_error' if we are the main thread - * (including non-threaded programs), or if an allocation - * fails. - */ - if (thr_main()) - return (&nc_error); - if (thr_once(&nc_once, nc_key_init) != 0 || nc_key_error != 0) - return (&nc_error); - if ((nc_addr = (int *)thr_getspecific(nc_key)) == NULL) { - nc_addr = (int *)malloc(sizeof (int)); - if (thr_setspecific(nc_key, (void *) nc_addr) != 0) { - free(nc_addr); - return (&nc_error); - } - *nc_addr = 0; - } - return (nc_addr); -} - -#define nc_error (*(__nc_error())) /* * A call to setnetconfig() establishes a /etc/netconfig "session". A session * "handle" is returned on a successful call. At the start of a session (after From nobody Thu Mar 5 10:35:46 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRQtB6QQmz6SnBQ for ; Thu, 05 Mar 2026 10:35: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRQtB3hb0z3tBW for ; Thu, 05 Mar 2026 10:35:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772706946; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yzeLViW0f7l6Eugz2j9l9ZnBgNn2hRq+KVJOs1Ex4/0=; b=BgTsZSBH6wodGMPbMmtYCZozDg2fe9cUjFMQg5ApIQjdD1z++ag4ahw6WuK2XKBDNWLq25 K+SG299EAYAe4hQ470VPB25QY6yALWwpJDV9n60Fb5LuHUcg2YRZXsyNoods/BVAOe67gM 5C5reIyLMyw3G5NGo2DAbcbUqDAqtJe03bvHkUtm1wTxgb7oQfBrR6R4IkVlqQQ5z7E58v a35vJkuMeq/t8Aqcq7TB7CPxGhfvur9EpoPz7QtWCGmRwE6S0xqj+oZ4dPt/j9vc+cAMZa TLygSQbbE9y2mrRBRWTojTTias5SmCZ5SO/UgVArrTV5u5wKjVJZozs9zpUu6A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772706946; a=rsa-sha256; cv=none; b=bXIBhSJe6eGDDX267OPO4+Sh/MdXaFRpHf7vtM87KNDjJa7G0CkH5bM451Q/SGZvizh0Tw ckger7xxsZ7Us2mh2eF1wfNLqD2GOBbFAymaP5miIBvjmkFlWxpQGYKydfMu3A4D+urVC1 4cZQr3yWOMs9VRL+13BtH2T49xpdIMpshpH7vj0W1MvXsp1wGuolrpGFw+s7C7lSHBn6Dp xpMQuE+ckP62ToGVwy8UI2R7NBX8cP0ivEMZK59DffKd/zKTs36W1XtCPLgFJJboHtyyq3 LtcT3CoJ9dd74GbTJ9SH04vMydTJEpSYGkPh26YFoSugEoVQiG2JCrjqusRNBg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772706946; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yzeLViW0f7l6Eugz2j9l9ZnBgNn2hRq+KVJOs1Ex4/0=; b=ifhMKgahi8lTORjEo6uAKgyAoBw4cJ4Tf3xLvZSldiKIiGgrkpTvCQ0KAmtRSS3dJXov7V Cyht/VKaEl/3ixR2e1XC5aRIiT7epOdAOITYNc9I1E4rRMRb0NVeanETGCMfI3+vD/X0fl RDQhN9s63nbqb+JI+iUlgx9/AaGFumei8PQFKypLnHD0VjkWfrqMY42ylXVGdk9MWqvPnp dQmkRL8YfqKxEFm4eo/x2E5JxpGS+RivRNBRqqh1awdt2c9p8348NVYXp7iojF/4hn/qcp k0SqA+55XVFHGjfWjHnf/lwxCS0fHh1xpCCdPzNKEJsOtgmw38QAauNZ1jA+4Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRQtB3HQhzZDR for ; Thu, 05 Mar 2026 10:35:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3c2ac by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 10:35:46 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Brooks Davis Subject: git: 4dd517acb694 - main - libc/armv7: remove default version for alloca List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: brooks X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4dd517acb6949d6fed5b16f26fbffb150749b121 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 10:35:46 +0000 Message-Id: <69a95c82.3c2ac.37899708@gitrepo.freebsd.org> The branch main has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=4dd517acb6949d6fed5b16f26fbffb150749b121 commit 4dd517acb6949d6fed5b16f26fbffb150749b121 Author: Brooks Davis AuthorDate: 2026-03-05 10:33:53 +0000 Commit: Brooks Davis CommitDate: 2026-03-05 10:34:47 +0000 libc/armv7: remove default version for alloca The alloca() interface has been a macro expanding to __builtin_alloca() since 2003 (commit 79806b4cdce0, included in FreeBSD 5.2). Even before that virtually every compiler version I was able to test replaced alloca() with compiler generated code when targeting C. Hide it to prevent future (mis)use. Reviewed by: imp, kib Differential Revision: https://reviews.freebsd.org/D51858 --- lib/libc/arm/Symbol.map | 1 - lib/libc/arm/gen/alloca.S | 3 +++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/libc/arm/Symbol.map b/lib/libc/arm/Symbol.map index 49476d2e176a..0be97d4ea693 100644 --- a/lib/libc/arm/Symbol.map +++ b/lib/libc/arm/Symbol.map @@ -5,7 +5,6 @@ */ FBSD_1.0 { __mcount; - alloca; brk; sbrk; }; diff --git a/lib/libc/arm/gen/alloca.S b/lib/libc/arm/gen/alloca.S index 3545cc642aad..88db0cab749b 100644 --- a/lib/libc/arm/gen/alloca.S +++ b/lib/libc/arm/gen/alloca.S @@ -35,6 +35,7 @@ /* like alloc, but automatic automatic free in return */ #include + ENTRY(alloca) add r0, r0, #0x00000007 /* round up to next 8 byte alignment */ bic r0, r0, #0x00000007 @@ -43,4 +44,6 @@ ENTRY(alloca) RET END(alloca) + .symver alloca, alloca@FBSD_1.0 + .section .note.GNU-stack,"",%progbits From nobody Thu Mar 5 11:12:51 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRRhz5Fl8z6SqV0 for ; Thu, 05 Mar 2026 11:12: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRRhz33RTz3xpF for ; Thu, 05 Mar 2026 11:12:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772709171; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=oVBUKqEKgLjm7vg8m8a0I4n20fU3E1tkNyWYTKs8FQ0=; b=KIpnnU8ssZSfkv8cpPOroHvq4ZUA+mI4Zr8Hvhpp2PyUjVmp2VyxRlPc6D81mSn9mk19yy 2ccs4qUwtdSRkfKa/LvBvvHueEenSWUTBEw1MIh1lGfOEyeu79gCGVnFjN6e2GLxeY/pNI E/rJ9ZWNl1QRnllU3U7ApL2RYx26Y3dZSU9I4gxY+wqV9k/945eEBLADptsUJORIAl0RY6 KFgAGo3BTTGocnE65z+pNbqEzJ8xZ5o2YeL4RGrkHy88abDhtH+vEYnUOrX9PHVj7TCY4F A3/sG7r411RtACvgcos0yruUro9VPTUwF4N05TtG4ublGzj7muculwtefLSZGA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772709171; a=rsa-sha256; cv=none; b=I3e4vC99+tgtzftcHGS/9ZJaqiIFIDt5SbwsS7Aorq9YE1GyFtg1x/YNseAj/Jst7vil4o 56GpJC9kDbZfUsJIa1gkOS5l3fg9x7LSCvyWG4bkaoxtmWf1mo9Wm5Rmq7jj19XmwCKu05 VNvNMjvDdgqSjRO++evUfgv/+pNJVyTp1h2gofBUyZfPHp/KVtoh4Os8X+4i2qWIhZ8ONg ZjqLsxUV1Kc41NlfHI7+gbKXOLzl1mdV1k4EA8uHh8zLDppZ5OKRAxEBXLDLYQKJyFN/jj 3Nou/jWYruW7qMZjy9OmFqqMtaAoxy4AjpBb1GxhnOI009hGD54frBbTBNPJgQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772709171; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=oVBUKqEKgLjm7vg8m8a0I4n20fU3E1tkNyWYTKs8FQ0=; b=eh8YcaMfYDcZ3ZQSihwa6cRPFv0318/bQUMVo5GQfLtTh5R3Lt2A2T3CZJTyesukPVf+SW u8FShftKw33/GHepaq0LpUee/yANyd5QbFvioNbYQsAoVzf+Fn0V1aYDsReEQ/4nUXD6uJ dloQNXuBobrrcLOmsxJAzwTmO0asu/pKoLuuk9YLC+NaYwj4nqk9GPM63DuY3g1ZT8PIch Kp/4/C3gngw0uwT0hmo4pBQca9gtV6IYnLxHLZbPjwTWfYMliAbicFOGBArqeTvloeLTU/ BNSG0d2E6xgDcTQplVBhkRXUNpqhS4S1gJmn0wMHZHh3XkQ/Xpprpa4mZZvAEg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRRhz2Qbyzb3K for ; Thu, 05 Mar 2026 11:12:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3eacf by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 11:12:51 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Cochard Subject: git: 9f71153aec0c - main - carp: fix global demotion counter to VRRP advertisements List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: olivier X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9f71153aec0cb455cd49af6d4ca7e4c16fd45d7a Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 11:12:51 +0000 Message-Id: <69a96533.3eacf.766f5032@gitrepo.freebsd.org> The branch main has been updated by olivier: URL: https://cgit.FreeBSD.org/src/commit/?id=9f71153aec0cb455cd49af6d4ca7e4c16fd45d7a commit 9f71153aec0cb455cd49af6d4ca7e4c16fd45d7a Author: Olivier Cochard AuthorDate: 2026-03-05 11:02:20 +0000 Commit: Olivier Cochard CommitDate: 2026-03-05 11:02:20 +0000 carp: fix global demotion counter to VRRP advertisements When net.inet.carp.preempt=1 and a physical interface goes down, the global V_carp_demotion counter is incremented. For CARP this was already reflected in outgoing advertisements via DEMOTE_ADVSKEW(), but VRRP sent the raw sc_vrrp_prio unchanged, so demotion had no effect. Add DEMOTE_VRRP_PRIO(), a macro analogous to DEMOTE_ADVSKEW(): It subtracts V_carp_demotion from the configured priority and clamps the result to [0, 254]. Priority 0 is VRRPv3's "resign" signal and causes backups to preempt immediately. Priority 255 (IP address owner) is never demoted. Reviewed by: kp Approved by: kp Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D55558 --- sys/netinet/ip_carp.c | 17 ++++++++++--- tests/sys/netinet/carp.sh | 61 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 75 insertions(+), 3 deletions(-) diff --git a/sys/netinet/ip_carp.c b/sys/netinet/ip_carp.c index d33ac4e9a154..3fedbda6b57f 100644 --- a/sys/netinet/ip_carp.c +++ b/sys/netinet/ip_carp.c @@ -331,6 +331,17 @@ SYSCTL_VNET_PCPUSTAT(_net_inet_carp, OID_AUTO, stats, struct carpstats, (((sc)->sc_advskew + V_carp_demotion < 0) ? \ 0 : ((sc)->sc_advskew + V_carp_demotion))) +/* + * VRRPv3 priority is the inverse of CARP advskew: higher is better. + * Subtract the global demotion counter and clamp to [0, 254]. + * Priority 255 (IP address owner) is never demoted. + */ +#define DEMOTE_VRRP_PRIO(sc) \ + ((sc)->sc_vrrp_prio == 255 ? 255 : \ + (((int)(sc)->sc_vrrp_prio - V_carp_demotion < 0) ? 0 : \ + (((int)(sc)->sc_vrrp_prio - V_carp_demotion > 254) ? 254 : \ + (int)(sc)->sc_vrrp_prio - V_carp_demotion))) + static void carp_input_c(struct mbuf *, struct carp_header *, sa_family_t, int); static void vrrp_input_c(struct mbuf *, int, sa_family_t, int, int, uint16_t); static struct carp_softc @@ -1009,7 +1020,7 @@ vrrp_input_c(struct mbuf *m, int off, sa_family_t af, int ttl, * Same if the peer has a higher priority than us. */ if (ntohs(vh->vrrp_max_adver_int) < sc->sc_vrrp_adv_inter || - vh->vrrp_priority > sc->sc_vrrp_prio) { + vh->vrrp_priority > DEMOTE_VRRP_PRIO(sc)) { callout_stop(&sc->sc_ad_tmo); carp_set_state(sc, BACKUP, "more frequent advertisement received"); @@ -1023,7 +1034,7 @@ vrrp_input_c(struct mbuf *m, int off, sa_family_t af, int ttl, * and this one claims to be slower, treat him as down. */ if (V_carp_preempt && (ntohs(vh->vrrp_max_adver_int) > sc->sc_vrrp_adv_inter - || vh->vrrp_priority < sc->sc_vrrp_prio)) { + || vh->vrrp_priority < DEMOTE_VRRP_PRIO(sc))) { carp_master_down_locked(sc, "preempting a slower master"); break; @@ -1359,7 +1370,7 @@ vrrp_send_ad_locked(struct carp_softc *sc) .vrrp_version = CARP_VERSION_VRRPv3, .vrrp_type = VRRP_TYPE_ADVERTISEMENT, .vrrp_vrtid = sc->sc_vhid, - .vrrp_priority = sc->sc_vrrp_prio, + .vrrp_priority = DEMOTE_VRRP_PRIO(sc), .vrrp_count_addr = 0, .vrrp_max_adver_int = htons(sc->sc_vrrp_adv_inter), .vrrp_checksum = 0, diff --git a/tests/sys/netinet/carp.sh b/tests/sys/netinet/carp.sh index 90ed9d6f9baf..e0ef2fd97583 100755 --- a/tests/sys/netinet/carp.sh +++ b/tests/sys/netinet/carp.sh @@ -497,6 +497,66 @@ negative_demotion_cleanup() vnet_cleanup } +atf_test_case "vrrp_preempt" "cleanup" +vrrp_preempt_head() +{ + atf_set descr 'Test VRRP preemption' + atf_set require.user root +} + +vrrp_preempt_body() +{ + carp_init + + epair1=$(vnet_mkepair) + epair2=$(vnet_mkepair) + + vnet_mkjail one ${epair1}a ${epair2}a + jexec one sysctl net.inet.carp.preempt=1 + jexec one ifconfig ${epair1}a 192.0.2.1/24 up + jexec one ifconfig ${epair1}a add vhid 1 carpver 3 192.0.2.254/24 \ + vrrpprio 10 pass foobar1 + jexec one ifconfig ${epair2}a 192.0.3.1/24 up + jexec one ifconfig ${epair2}a add vhid 2 carpver 3 192.0.3.254/24 \ + vrrpprio 10 pass foobar2 + + vnet_mkjail two ${epair1}b ${epair2}b + jexec two sysctl net.inet.carp.preempt=1 + jexec two ifconfig ${epair1}b 192.0.2.2/24 up + jexec two ifconfig ${epair2}b 192.0.3.2/24 up + jexec two ifconfig ${epair1}b add vhid 1 carpver 3 192.0.2.254/24 \ + vrrpprio 1 pass foobar1 + jexec two ifconfig ${epair2}b add vhid 2 carpver 3 192.0.3.254/24 \ + vrrpprio 1 pass foobar2 + + # Allow things to settle + wait_for_carp one ${epair1}a two ${epair1}b + wait_for_carp one ${epair2}a two ${epair2}b + + # Bring down one interface; preemption should demote the second interface too + jexec one ifconfig ${epair1}a down + sleep 3 + + if is_master one ${epair2}a + then + atf_fail "preemption did not affect the second interface" + fi + + # Bring interface back up; one should reclaim master + jexec one ifconfig ${epair1}a up + sleep 3 + + if ! is_master one ${epair2}a + then + atf_fail "Priority router did not take its master role back" + fi +} + +vrrp_preempt_cleanup() +{ + vnet_cleanup +} + atf_test_case "nd6_ns_source_mac" "cleanup" @@ -596,5 +656,6 @@ atf_init_test_cases() atf_add_test_case "unicast_ll_v6" atf_add_test_case "negative_demotion" atf_add_test_case "nd6_ns_source_mac" + atf_add_test_case "vrrp_preempt" atf_add_test_case "switch" } From nobody Thu Mar 5 13:44:31 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRW401xJLz6T3NQ for ; Thu, 05 Mar 2026 13:44: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRW4001l2z3JT0 for ; Thu, 05 Mar 2026 13:44:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772718272; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zx7b1U61tDca5A69HTbNYyp7gD+AUoH0rLh5jCxjmX0=; b=VL8ucZyJnijEfLNBU4egeE4gKBP34oUImcrsrZP0SAdxa5qHhRiyYB8v8fWjEUQN5wSjWw V1P9sGhYeKLFM0SRxpueG8vZBAO0NjO7GKSWCUHb4htQLdu9jWZVmoIARTnUkvqMHoMGga U5OBTKKYpfSQh07ymaEx0B3mZp0gcd8irWCwppxENOjvmOVXpBib8Nch7Zv/Vf7JswIalQ 7iH/JcQRl3URolaGH/dRGLt40QMZMTa3AcM41bacCdfYDyRgL768u6J4WHXutVe51JgPuy B4ehROJqoMkUcVbkiHCAVMp4sYk9Gq51pA5YL9zHOYNDUUjq53+Wv9bmxFhcVQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772718272; a=rsa-sha256; cv=none; b=cD6mvfGYcu7grZMO+hJv6UaZ9+9LaeVGwAZPt14A2OIpw2IuJ6VOdfKMr7YQlLusDZm0Iy pTlH99/oT8iDlHro+Ir/pXifUVT3IvtMXQMSnm7/o+Rz9W7/1y6Zwqip9FQBeJpLIQwok+ lrXyixWd9R1+So69RfK/CC6tBFw5vozXPop+6NI6h7lWuSa+NWzUH8ANaEbmBKayPDCZss 1YGk/6T6uoDtIeX1AY5G9R3NiKOnh/DzJYzgUL3Kc54Hj7KkO4kfGygGCo3xUHAFItMUpf nvGFdEZYhC0xiI7GoSlq0dzpdStchc1DqteQC0mTrjmBqxGEpo14H3E+Rm5azw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772718272; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zx7b1U61tDca5A69HTbNYyp7gD+AUoH0rLh5jCxjmX0=; b=o2XxRLQrtaG9S1JPY+W53KY93g1M+CBiWYY8T65GQ2CDcNvfl9QeVKFPscJF7RuSlURiE8 QI4z1RIc/I/24qb32F5pKzoFTn3cQTNLSDT8mvP5a/DK+VB4kw+6IrdKEG8wJUoHg6CS2W oH9ViGWL6OvPui2Cvs7lSV1zv2z+rLAcT/gsAmAbyYHNHngSHuf3Y7nHrU8oMvjtjteOOJ IOLIB/QabgCGJJiR4frhCdsG0Od2w8cYYefoy0aqcDrXA5gU6b5KZyWSxoKh+m2hRJUpR5 dCYsyA0AAa0L1K5HsuJ0reRNkXiVFVrw20syl4XV92zNznuHno632nAcQXmtpw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRW3z6Hv1zg61 for ; Thu, 05 Mar 2026 13:44:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 21582 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 13:44:31 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 9b03cc2a70e4 - main - net80211: sta: use IEEE80211_STATUS_SUCCESS instead of magic 0 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 9b03cc2a70e4b6354c5f5b90e4c51b850b6b1dd2 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 13:44:31 +0000 Message-Id: <69a988bf.21582.38fcbb17@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=9b03cc2a70e4b6354c5f5b90e4c51b850b6b1dd2 commit 9b03cc2a70e4b6354c5f5b90e4c51b850b6b1dd2 Author: Bjoern A. Zeeb AuthorDate: 2026-03-02 10:33:53 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-05 13:44:00 +0000 net80211: sta: use IEEE80211_STATUS_SUCCESS instead of magic 0 Rather than using the status != 0 check use the way more descriptive status != IEEE80211_STATUS_SUCCESS definition. This makes it a lot more clear what is checked here. While here add a comment in case aof the (Re)Assoc Resp failure as we do not update state in that case but rely on a timeout which will bounce us back to State 1 (cf. 802.11-2024, Figure 11-23) which means SCAN in our case, rather than possibly moving us back to AUTH. We will likely have to revisit this when SAE hits the tree. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: adrian Differential Revision: https://reviews.freebsd.org/D55643 --- sys/net80211/ieee80211_sta.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/sys/net80211/ieee80211_sta.c b/sys/net80211/ieee80211_sta.c index 19e5ffe9a367..3522b1b24742 100644 --- a/sys/net80211/ieee80211_sta.c +++ b/sys/net80211/ieee80211_sta.c @@ -1011,7 +1011,7 @@ sta_auth_open(struct ieee80211_node *ni, struct ieee80211_frame *wh, vap->iv_stats.is_rx_bad_auth++; return; } - if (status != 0) { + if (status != IEEE80211_STATUS_SUCCESS) { IEEE80211_NOTE(vap, IEEE80211_MSG_DEBUG | IEEE80211_MSG_AUTH, ni, "open auth failed (reason %d)", status); vap->iv_stats.is_rx_auth_fail++; @@ -1100,7 +1100,7 @@ sta_auth_shared(struct ieee80211_node *ni, struct ieee80211_frame *wh, IEEE80211_FREE(ni->ni_challenge, M_80211_NODE); ni->ni_challenge = NULL; } - if (status != 0) { + if (status != IEEE80211_STATUS_SUCCESS) { IEEE80211_NOTE_FRAME(vap, IEEE80211_MSG_DEBUG | IEEE80211_MSG_AUTH, wh, "shared key auth failed (reason %d)", status); @@ -1766,7 +1766,12 @@ sta_recv_mgmt(struct ieee80211_node *ni, struct mbuf *m0, int subtype, frm += 2; status = le16toh(*(uint16_t *)frm); frm += 2; - if (status != 0) { + if (status != IEEE80211_STATUS_SUCCESS) { + /* + * See ieee80211_tx_mgt_cb() for state handling. This + * essentially provokes a timeout bouncing us back to + * State 1 instead of dealing with it properly. + */ IEEE80211_NOTE_MAC(vap, IEEE80211_MSG_ASSOC, wh->i_addr2, "%sassoc failed (reason %d)", ISREASSOC(subtype) ? "re" : "", status); From nobody Thu Mar 5 13:44:32 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRW4131P7z6T3GN for ; Thu, 05 Mar 2026 13:44: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRW410gG1z3JWP for ; Thu, 05 Mar 2026 13:44:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772718273; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4mGx5vLyNW3FDbq9hoBT9zPy6nE2nGAUMuy6YYcpfdU=; b=WK3YyLDGOX3e7YPBa6tCDpWr330cxa3rrBZZ/zQRZkXFLXAskjneeAZFzKwRRa0qglCdXc WJVG1KjItkbNjEzbN9attOt0pWDDI8QOwDTyprYpGb57iArEwd0GVZ9McK380D3R+Fv61a 3LVDmsIBVhwWp71U9M6Vap9aW5VnXZ0qpEZInE2tmlc01hF8i0LzADAqFbfQ6mqEzkwlE1 fLIhMhARU2w6PK9fmjVc8THQN8DPRBBKRzDDwqGIN3H4eaYvkcPPlecKTHtXmxwOFk4P7/ TJMSW/upxuI9b2onD0uGiZvz9qwiXP+DIoJy4whrS046cqwSjxFVQ4VdRttcFg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772718273; a=rsa-sha256; cv=none; b=UqUYEd19UUjPzjTlNiG2zy0w4SKb1IK2wfSpXUIVbeliQgSYoPhIorhLsEDcNIq5YuZEkI 8YwamwJ0pssz5BY6LDY3Qz2pC0EcqRfIsVTnbI56TmAn5O9l8/SHTQzX6XxLwdbP/HWr9D zCwY4MQG+slnELIBgzpQWcPLSUHOG+z07gAmsVjNHsmDMQVPPLFhA74rAuyphbgysmKkQl hTNo8MgKV5SNVRclg2ShYk38m8VIjatIy3tUfDlLGiXDS0aPDFCLWrP8TcNrY6/AwnSvPn eyENaPSWOj2aKx5YeCzRC5yiZGU/F2bzwGu4tgp8vQ3gaHHcrOZ8kCE6v9A2QA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772718273; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4mGx5vLyNW3FDbq9hoBT9zPy6nE2nGAUMuy6YYcpfdU=; b=uSrDdcG3L43P13ZkI4U04lbIWGLevT7Lk0/1rDxeR/UxTpeMLQZxw/q5adizaGXwGbFBS8 e507zt8ok/2PRRRfdlWLxxD1CnRlKzg6jyQylxRGsdv/ozaik2j9yq1bR1uhXYMzmtnylP tFgHZmM1cO3VY3uuup3jKMhobOqZAL/a+cxSVKIPJaqPlE9v+Hw0czKmChs1og3sBoJ+w3 Q+gUUMZI1y3bap0XyzQUolwG2dK9Hd766xTfaZAYwRP+mBBGpJ57YNqia+YF3mTV2TPKZ5 +6Gq6yskYRUpGPHYg70NFXU97jyWPEMGfHoCYD8/1y9NqEni6dwNx97GwVJzqw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRW406Tf9zffn for ; Thu, 05 Mar 2026 13:44:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 20e36 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 13:44:32 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 760e0a18d303 - main - iwlwifi: fixup link_id for certain cases List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 760e0a18d3033152899fbd0e3f587dfe3c28d6bf Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 13:44:32 +0000 Message-Id: <69a988c0.20e36.66aa516e@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=760e0a18d3033152899fbd0e3f587dfe3c28d6bf commit 760e0a18d3033152899fbd0e3f587dfe3c28d6bf Author: Bjoern A. Zeeb AuthorDate: 2026-03-05 09:47:10 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-05 13:44:01 +0000 iwlwifi: fixup link_id for certain cases In iwl_mvm_mld_vif_cfg_changed_station() if we do not do MLO (which we do not do yet at all), dtim_period is not yet set but asssoc is (our common case) the link_id can become -1 as active_links is always 0 for the non-MLO case. This leads to logging of a WARN; Invalid link ID for session protection: 4294967295 Fixup the link_id if it is -1 to be 0. This is the deflink link_id so that should always be fine in this case. For Linux 7.0-rc2 that code is already gone so this is a local temporary stopgap measure for the mvm-mld devices (e.g., some AX210). Sponosred by: The FreeBSD Foundation MFC after: 3 days --- sys/contrib/dev/iwlwifi/mvm/mld-mac80211.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sys/contrib/dev/iwlwifi/mvm/mld-mac80211.c b/sys/contrib/dev/iwlwifi/mvm/mld-mac80211.c index bf24f8cb673e..8b88f211066d 100644 --- a/sys/contrib/dev/iwlwifi/mvm/mld-mac80211.c +++ b/sys/contrib/dev/iwlwifi/mvm/mld-mac80211.c @@ -838,6 +838,14 @@ static void iwl_mvm_mld_vif_cfg_changed_station(struct iwl_mvm *mvm, */ unsigned int link_id = ffs(vif->active_links) - 1; +#if defined(__FreeBSD__) + /* link_id is gone in Linux v7.0. + * For us it can become -1 if this is non-MLO + * and dtim_period is still 0. + */ + if (link_id == -1) + link_id = 0; +#endif /* If we're not restarting and still haven't * heard a beacon (dtim period unknown) then From nobody Thu Mar 5 13:44:34 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRW423MFbz6T3JT for ; Thu, 05 Mar 2026 13:44: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRW420Y8Tz3JR5 for ; Thu, 05 Mar 2026 13:44:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772718274; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=atbZFl91ykztZKct5ErIgJc6LNcI+rzVLtDTz/vvDZo=; b=NN7dcOn9bZ5psuCJrhsoIH+hp57M3VByU4C1jQH97Ike/9IuG2IZWD/eE+dHW1XX8A5OWA PKLYAJ2O26ZaWto89WuwwKKPdc88uqouasuSXrK6bneRobRT36kFyhI9Gj/vTOXwmLs8sM 7Ek5Lyhd9XnslLacm7C9sIARdVS2ZcIzfONoKWEuy+lSKquEAw9M/Gyv1jIh0ArUIw90D+ TQLXDSFCoGjV6X9sEFIeCwKG4Nduf0j3+XQoK6lrHFmrfb28NqvvdRGtBrD7drpILd9Jjo b3i/ExTbiSuIs0qGmk8JWZt6GGVi+i3YvqcWdLfZHyyw868GbMUDiz0TCoi81A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772718274; a=rsa-sha256; cv=none; b=OmMsIegpawnN9HxfMkt0EjWfbprZolsen6cbElWCtfXRL1KD66MPltb90Jre9W85MquKlA i3/8Q6CdgEhvoHKHnP9KoEMfAHob1WB9KG8W4FlRx3FDkH/VpmA6EZPYhhfZRS8khj5rGt 11YfyQFXeYr7bLMpcllpv0QcVYtO1SDQM7k6GrPqDpof3BpfvmPMZTuZmFTvtxwiyEKUDR He+QHMLLSAqIuQ+ya0R0Bx/IEEPEVBAtwxtpWjtg5aqVyjOjvta1+HBsiJLLSKeWmOSaH3 nDXMrhEIwwnF1ImUGMv2+PWW1uTkzyAU/Efx6wGBbegelNvTtSTwkaPVsyTIFQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772718274; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=atbZFl91ykztZKct5ErIgJc6LNcI+rzVLtDTz/vvDZo=; b=FXS7GIoQ75Bkn/abtVNn6QgDbNmSv11ECz8qIlQTciCvXUx5rq6n/bswI9lnXij2LBMdQb gcipHZ8KaZR7NhufNT8olRrHjU6CNz96Towv/J4XTC8R4x9Kr3VmNUoc1okb9EOT2D6yHS 7WJqqUoVOztxk3OPUPNcK7FIt/vTU1I//Zm8pasGBjnYUZGod7ePTkOxkk8vSlv1htLr/N lkvA6Oh76UIE0n/m7tUUr5crr/1izPEv8JWIxaqgr45oJfRuBtavngehPLNCR/jjjHoSrb KyS0fozrYjnYYf4UymbpXRFeZtT1BP3snS2VgXHseuqgEC5zLr6gYXOZNiv+3A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRW4207JDzg62 for ; Thu, 05 Mar 2026 13:44:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1eb66 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 13:44:34 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: fa41408d6043 - main - LinuxKPI: 802.11: fix typo List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: fa41408d6043df3779d94bd1ac871a5ba8f4dafb Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 13:44:34 +0000 Message-Id: <69a988c2.1eb66.59dff008@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=fa41408d6043df3779d94bd1ac871a5ba8f4dafb commit fa41408d6043df3779d94bd1ac871a5ba8f4dafb Author: Bjoern A. Zeeb AuthorDate: 2026-03-05 10:30:46 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-05 13:44:01 +0000 LinuxKPI: 802.11: fix typo Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/compat/linuxkpi/common/src/linux_80211.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index bbda35cb2e38..799ecb245661 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2004,7 +2004,7 @@ lkpi_update_dtim_tsf(struct ieee80211_vif *vif, struct ieee80211_node *ni, * we set the BSS_CHANGED_BEACON_INFO on the non-teardown * path so make sure we only do run this check once we are * assoc. (*iv_recv_mgmt)() will be called before we enter - * here so the ni will be updates with information from the + * here so the ni will be updated with information from the * beacon via net80211::sta_recv_mgmt(). We also need to * make sure we do not do it on every beacon we still may * get so only do if something changed. vif->bss_conf.dtim_period From nobody Thu Mar 5 13:44:35 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRW434wj3z6T3fw for ; Thu, 05 Mar 2026 13:44: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRW431TVfz3JR6 for ; Thu, 05 Mar 2026 13:44:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772718275; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LgPNGPEp8K3TNHQtxRq49qrwZlPPgtMdZFgesamG1DE=; b=JPqmQYx0IIZArhSdAkN2fAx8RkoSZnpdO2jk1f7VQGTj3QZRzLAsTcKf4K4GFpr1mFAAhh 0TELlyIykaA2bIiYiNJR5axeHlfRwIcEKLKRnApHZ0lC9SrOreSv9h+FeIJg0BGtM+c50B +q/6yyfeUgZNGL3Ee66GQ6LAJxVUXvEcPAy6YCk7UOHVRVbaIsWE8DNG3Cavts/nXtriXT TiqLTDctcFkoU1WDAhPGILKU9IQy3wNk0RUbCgewCb6CFwd7Tswm0VXhYP2hszQKN2PzBw Iu84hxeL+c5VczoMB3ZW0fUJG4J/XOHy3V3ZD170gMxXcG5Xh4k/lZczxqyuJQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772718275; a=rsa-sha256; cv=none; b=MM4dy0cDQbIYYNgAZUhIis+yEqHeO9MUdKlhu/MtZ5fU+5xgxp8g8fPO8fHpauTsO24BN5 3QFgU2Y44nzkFp00WLfrN+dZ5dQmtNzcf/f4IDiX8KekL3qIseGav06lFY+KaNGBHDY9zi QomjaxVjpQzfPyYETFHNXmZHI4Iw2tgMJjdBSWxRYrgR21Rlxfybeb2X00rpXhvtc4oKVr Ip/yApRe6l6brFzEE6RS8RVzQa6epEcasnHU4zv6O4Uzy1dMHtWO6b+wwDZG1pWWc4GEyt dMwjLPuflXL/LwxW7enfWtvcfv+wONVidH0wim3kB//+Ch9DBmEy5nj4VP2mxA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772718275; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LgPNGPEp8K3TNHQtxRq49qrwZlPPgtMdZFgesamG1DE=; b=TWOScYrX+MCyLzFpZWU5aUE2ltFSYy2vFopaLwrBSzxV0/lJb9Zbf4SVA37EcFQmrfaGQD ydtcQLlR9pEbRpJVUb52kffLK8inT0FXx/yHq8jHUIpyv+xGWzqHH9VTksi6qh3HfbAVpV wopbytZtHhDb84na8SGymjHCeSMRI0hVGKiPYeppj893fCbxrdP0nrFgR5kKXOyxwuNRIC rHmy7sOiJEtsy/5GmEk6ulctqGJ98PmLdvEajgmtZjIv9mxdupEAGPa44MrCDAAZO/5Ppq 65Kqp32/K/rLdlVwIrzNxj+NF2I1XC6QHhu11Bu0S9bnLBZ8d/ct/WzW7J3XHg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRW4311bGzg64 for ; Thu, 05 Mar 2026 13:44:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1f243 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 13:44:35 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 9592f563c36b - main - LinuxKPI: 802.11: split (*bss_info_changed) up for more modern drivers List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 9592f563c36bd207d98f1b3a13839b88d5760d97 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 13:44:35 +0000 Message-Id: <69a988c3.1f243.1cea2a48@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=9592f563c36bd207d98f1b3a13839b88d5760d97 commit 9592f563c36bd207d98f1b3a13839b88d5760d97 Author: Bjoern A. Zeeb AuthorDate: 2026-01-03 20:10:00 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-05 13:44:02 +0000 LinuxKPI: 802.11: split (*bss_info_changed) up for more modern drivers With the advent of MLO some of the updates (*bss_info_changed) would have done are not per-link. This had (*vif_cfg_changed) and (*link_conf_changed) introduced which are used by iwlwifi, rtw89, select mt76 drivers, and ath12k currently it seems. A driver normally only supports on or the other set. Factor out the call to (*bss_info_changed) into an internal function. There split the options up depending on whether they are for the vif or a link and leave a fallback to (*bss_info_changed) for older drivers. Add the mac80211 ops implementations for the two new calls along with a currently unused backup option for (*bss_info_changed) for each as I assume we will eventually call the directly rather than from the internal wrapper function. Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/compat/linuxkpi/common/src/linux_80211.c | 75 ++++++++++++++++++---- sys/compat/linuxkpi/common/src/linux_80211.h | 4 ++ .../linuxkpi/common/src/linux_80211_macops.c | 70 ++++++++++++++++++-- 3 files changed, 128 insertions(+), 21 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 799ecb245661..c003075ae601 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2242,6 +2242,53 @@ lkpi_remove_chanctx(struct ieee80211_hw *hw, struct ieee80211_vif *vif) free(lchanctx, M_LKPI80211); } +/* -------------------------------------------------------------------------- */ + +/* Any other options belong here? Check more drivers. */ +#define BSS_CHANGED_VIF_CFG_BITS \ + (BSS_CHANGED_SSID | BSS_CHANGED_IDLE | BSS_CHANGED_PS | BSS_CHANGED_ASSOC | \ + BSS_CHANGED_ARP_FILTER | BSS_CHANGED_MLD_VALID_LINKS | BSS_CHANGED_MLD_TTLM) + +static void +lkpi_bss_info_change(struct ieee80211_hw *hw, struct ieee80211_vif *vif, + enum ieee80211_bss_changed bss_changed) +{ + struct lkpi_vif *lvif; + enum ieee80211_bss_changed vif_cfg_bits, link_info_bits; + + if (ieee80211_vif_is_mld(vif)) { + TODO("This likely needs a subset only; split up into 3 parts."); + } + + /* Nothing to do? */ + if (bss_changed == 0) + return; + + /* + * If the vif is not known to the driver there is nothing to notifiy for. + * We MUST NOT check for !lvif_bss_synched here (the reasonable it seems) + * as we need to execute the update(s) or we will have follow-up issues. + */ + lvif = VIF_TO_LVIF(vif); + if (!lvif->added_to_drv) + return; + + /* + * With the advent of MLO bss_conf got split up into vif and link + * change notfications, while historically it was one. + * We now need to support all possible models. + */ + vif_cfg_bits = bss_changed & BSS_CHANGED_VIF_CFG_BITS; + if (vif_cfg_bits != 0) + lkpi_80211_mo_vif_cfg_changed(hw, vif, vif_cfg_bits, false); + + link_info_bits = bss_changed & ~(BSS_CHANGED_VIF_CFG_BITS); + if (link_info_bits != 0) + lkpi_80211_mo_link_info_changed(hw, vif, &vif->bss_conf, + link_info_bits, 0, false); + + lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, bss_changed); +} /* -------------------------------------------------------------------------- */ @@ -2457,7 +2504,7 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* RATES */ IMPROVE("bss info: not all needs to come now and rates are missing"); - lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, bss_changed); + lkpi_bss_info_change(hw, vif, bss_changed); /* * Given ni and lsta are 1:1 from alloc to free we can assert that @@ -2791,7 +2838,7 @@ lkpi_sta_assoc_to_run(struct ieee80211vap *vap, enum ieee80211_state nstate, int } bss_changed |= lkpi_update_dtim_tsf(vif, ni, vap, __func__, __LINE__); - lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, bss_changed); + lkpi_bss_info_change(hw, vif, bss_changed); /* - change_chanctx (if needed) * - event_callback @@ -2851,7 +2898,7 @@ lkpi_sta_assoc_to_run(struct ieee80211vap *vap, enum ieee80211_state nstate, int bss_changed = 0; bss_changed |= lkpi_update_dtim_tsf(vif, ni, vap, __func__, __LINE__); - lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, bss_changed); + lkpi_bss_info_change(hw, vif, bss_changed); /* Prepare_multicast && configure_filter. */ lkpi_update_mcast_filter(vap->iv_ic); @@ -3289,7 +3336,7 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* XXX BSS_CHANGED_???? */ vif->bss_conf.dtim_period = 0; /* go back to 0. */ bss_changed |= BSS_CHANGED_BEACON_INFO; - lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, bss_changed); + lkpi_bss_info_change(hw, vif, bss_changed); LKPI_80211_LVIF_LOCK(lvif); /* Remove ni reference for this cache of lsta. */ @@ -3653,7 +3700,7 @@ lkpi_wme_update(struct lkpi_hw *lhw, struct ieee80211vap *vap, bool planned) struct chanAccParams chp; struct wmeParams wmeparr[WME_NUM_AC]; struct ieee80211_tx_queue_params txqp; - enum ieee80211_bss_changed changed; + enum ieee80211_bss_changed bss_changed; int error; uint16_t ac; @@ -3704,11 +3751,11 @@ lkpi_wme_update(struct lkpi_hw *lhw, struct ieee80211vap *vap, bool planned) ic_printf(ic, "%s: conf_tx ac %u failed %d\n", __func__, ac, error); } - changed = BSS_CHANGED_QOS; + bss_changed = BSS_CHANGED_QOS; if (!planned) - lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, changed); + lkpi_bss_info_change(hw, vif, bss_changed); - return (changed); + return (bss_changed); } #endif @@ -3774,7 +3821,7 @@ lkpi_iv_sta_recv_mgmt(struct ieee80211_node *ni, struct mbuf *m0, * locking, see if queue_work() is fast enough. */ bss_changed = lkpi_update_dtim_tsf(vif, ni, ni->ni_vap, __func__, __LINE__); - lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, bss_changed); + lkpi_bss_info_change(hw, vif, bss_changed); } /* @@ -3820,7 +3867,7 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], struct ieee80211vap *vap; struct ieee80211_vif *vif; struct ieee80211_tx_queue_params txqp; - enum ieee80211_bss_changed changed; + enum ieee80211_bss_changed bss_changed; struct sysctl_oid *node; size_t len; int error, i; @@ -3937,8 +3984,8 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], LKPI_80211_LHW_LVIF_UNLOCK(lhw); /* Set bss_info. */ - changed = 0; - lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, changed); + bss_changed = 0; + lkpi_bss_info_change(hw, vif, bss_changed); /* Configure tx queues (conf_tx), default WME & send BSS_CHANGED_QOS. */ IMPROVE("Hardcoded values; to fix see 802.11-2016, 9.4.2.29 EDCA Parameter Set element"); @@ -3956,8 +4003,8 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], __func__, ac, error); } wiphy_unlock(hw->wiphy); - changed = BSS_CHANGED_QOS; - lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, changed); + bss_changed = BSS_CHANGED_QOS; + lkpi_bss_info_change(hw, vif, bss_changed); /* Force MC init. */ lkpi_update_mcast_filter(ic); diff --git a/sys/compat/linuxkpi/common/src/linux_80211.h b/sys/compat/linuxkpi/common/src/linux_80211.h index 3d25ab4a857b..8ae5c3d13d2d 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.h +++ b/sys/compat/linuxkpi/common/src/linux_80211.h @@ -469,6 +469,10 @@ void lkpi_80211_mo_change_chanctx(struct ieee80211_hw *, struct ieee80211_chanctx_conf *, uint32_t); void lkpi_80211_mo_remove_chanctx(struct ieee80211_hw *, struct ieee80211_chanctx_conf *); +void lkpi_80211_mo_vif_cfg_changed(struct ieee80211_hw *, struct ieee80211_vif *, + uint64_t, bool); +void lkpi_80211_mo_link_info_changed(struct ieee80211_hw *, struct ieee80211_vif *, + struct ieee80211_bss_conf *, uint64_t, uint8_t, bool); void lkpi_80211_mo_bss_info_changed(struct ieee80211_hw *, struct ieee80211_vif *, struct ieee80211_bss_conf *, uint64_t); int lkpi_80211_mo_conf_tx(struct ieee80211_hw *, struct ieee80211_vif *, diff --git a/sys/compat/linuxkpi/common/src/linux_80211_macops.c b/sys/compat/linuxkpi/common/src/linux_80211_macops.c index 634cffddea9e..42067e36c953 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211_macops.c +++ b/sys/compat/linuxkpi/common/src/linux_80211_macops.c @@ -546,24 +546,80 @@ lkpi_80211_mo_remove_chanctx(struct ieee80211_hw *hw, } void -lkpi_80211_mo_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif, - struct ieee80211_bss_conf *conf, uint64_t changed) +lkpi_80211_mo_vif_cfg_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif, + uint64_t vif_cfg_bits, bool fallback) +{ + struct lkpi_hw *lhw; + + might_sleep(); + /* XXX-FINISH all callers for lockdep_assert_wiphy(hw->wiphy); */ + + lhw = HW_TO_LHW(hw); + if (lhw->ops->vif_cfg_changed == NULL && + lhw->ops->bss_info_changed == NULL) + return; + + if (vif_cfg_bits == 0) + return; + + LKPI_80211_TRACE_MO("hw %p vif %p vif_cfg_bits %#jx", hw, vif, (uintmax_t)vif_cfg_bits); + if (lhw->ops->link_info_changed != NULL) + lhw->ops->vif_cfg_changed(hw, vif, vif_cfg_bits); + else if (fallback) + lhw->ops->bss_info_changed(hw, vif, &vif->bss_conf, vif_cfg_bits); +} + +void +lkpi_80211_mo_link_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif, + struct ieee80211_bss_conf *conf, uint64_t link_info_bits, uint8_t link_id, + bool fallback) { struct lkpi_hw *lhw; + might_sleep(); + /* XXX-FINISH all callers for lockdep_assert_wiphy(hw->wiphy); */ + lhw = HW_TO_LHW(hw); if (lhw->ops->link_info_changed == NULL && lhw->ops->bss_info_changed == NULL) return; - if (changed == 0) + if (link_info_bits == 0) return; - LKPI_80211_TRACE_MO("hw %p vif %p conf %p changed %#jx", hw, vif, conf, (uintmax_t)changed); + if (!ieee80211_vif_link_active(vif, link_id)) + return; + + LKPI_80211_TRACE_MO("hw %p vif %p conf %p link_info_bits %#jx", hw, vif, conf, (uintmax_t)link_info_bits); if (lhw->ops->link_info_changed != NULL) - lhw->ops->link_info_changed(hw, vif, conf, changed); - else - lhw->ops->bss_info_changed(hw, vif, conf, changed); + lhw->ops->link_info_changed(hw, vif, conf, link_info_bits); + else if (fallback) + lhw->ops->bss_info_changed(hw, vif, conf, link_info_bits); +} + +/* + * This is basically obsolete but one caller. + * The functionality is now split between lkpi_80211_mo_link_info_changed() and + * lkpi_80211_mo_vif_cfg_changed(). Those functions have a flag whether to call + * the (*bss_info_changed) fallback or not. See lkpi_bss_info_change(). + */ +void +lkpi_80211_mo_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif, + struct ieee80211_bss_conf *conf, uint64_t bss_changed) +{ + struct lkpi_hw *lhw; + + /* XXX-FINISH all callers for lockdep_assert_wiphy(hw->wiphy); */ + + lhw = HW_TO_LHW(hw); + if (lhw->ops->bss_info_changed == NULL) + return; + + if (bss_changed == 0) + return; + + LKPI_80211_TRACE_MO("hw %p vif %p conf %p changed %#jx", hw, vif, conf, (uintmax_t)bss_changed); + lhw->ops->bss_info_changed(hw, vif, conf, bss_changed); } int From nobody Thu Mar 5 13:44:36 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRW445MPDz6T3Jj for ; Thu, 05 Mar 2026 13:44: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRW442L53z3JPv for ; Thu, 05 Mar 2026 13:44:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772718276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JqxaN5hVDDyldURgmhts88IfmJ4lEjI0/qQ8J48hu2Q=; b=rWwZPgoYW9h/JyRg3HQVNlgjz75cL5bi+DNmFBtWwrv/NDZeVFhJJvJNjbJ3rty6aGyj0J /RMlLuwOsMKye+Q4NCPBbiTpgyCHknNDnAvB+222WjqCkmVmzlg61As3t/PIApLN9xfRs4 ZuvLLzcVBRfRv4DVFz4gYQX/RKXZHjge6idn3lZujqRy0OqOhfLXPFhaHAMkAQQf0D2tbr 9jvEjdsPJYrA+lRbtjtwX3aXHzM03dqutbfGEmO0GPiCvlVNF06pOHwRr3zcCYfByXOg9t yDrt02q0CljhD3sL/5aMziow1+Ve37hsfYAXOJLs05BKfyf3K4bCb0lm5Q/1aA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772718276; a=rsa-sha256; cv=none; b=S2nqqLmDtiOdFrRq3vKmOSI8V2ecinnd9PqyNroJxum/okiLNqA8ZhwJC/nicoVtotq1rK SdtCxHCuAGiYIKivjCLPeCGvoAGMFDY+zFW1T09bYifeIBKBZoaEYOsp1B8dJdX+tIsfLz TZ0KAJiHXBJFs8exVh86uzlGCyESwRKqMSSuVRpopKJXJDPtGOOU+T1HQBWJBMtRkQ7JXM LJcWobnQfRcV/BBDLYn8FK7lt3w3pkt+PkCi9+blZaUknKENmW4bmnkof+KeC1r7Oy5zwc 98+gETaY75pggcZEmoyqkte+KIReBtIegOBYbuWCsqH5Fnn2cLZHmL8xD5Rs0Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772718276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JqxaN5hVDDyldURgmhts88IfmJ4lEjI0/qQ8J48hu2Q=; b=AwEOjcKAhQsLjS8myuulGdjGVb4QiZDtUhn1BEN58+eF97/6rfKlJhXpwXBY4zos4MPDB1 2wVS9FebsTE6MNEBTujRK99urQg+lWVtd8adIsZgNWYm3gD4op6iHyxazJ5bvyIB8LcbOR nP/kyeVA42Y4IkAXERr6fYL++NUAPchQYtQQBz/hertJatTO9fT/d54ZplEZjFnctEMgy6 CFcf0/FxW4ech23LyTzKnMVIHi41E9Ab7JsI+062R+F30SzscSF+VpaquAhFBMxyGKTBU7 eruu9rBQJndW/hDa9DKkGsRMBiadhJWP3k+A+apkCC2RCW6KrSZi8O6dqSZPzA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRW441vM7zfYn for ; Thu, 05 Mar 2026 13:44:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 20f01 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 13:44:36 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: f68ebebd8ae4 - main - LinuxKPI: 802.11: change teardown order of disassoc and sta rm List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: f68ebebd8ae469e344f10ed2f3c4d9d983a29f41 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 13:44:36 +0000 Message-Id: <69a988c4.20f01.58d7738d@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=f68ebebd8ae469e344f10ed2f3c4d9d983a29f41 commit f68ebebd8ae469e344f10ed2f3c4d9d983a29f41 Author: Bjoern A. Zeeb AuthorDate: 2026-03-05 09:58:28 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-05 13:44:02 +0000 LinuxKPI: 802.11: change teardown order of disassoc and sta rm In lkpi_sta_auth_to_scan() we remove the sta from the firmware for everything supporting (*sta_state). We used to run into issues here with iwlwifi in that we had to use a specific order: set vif->cfg.assoc = false, .aid = 0, then remove the sta, and then send the mac update as otherwise we would either have the sta silently removed (if we run (*bss_info_change) first and fail then or silently not have the sta removed and upon sta add we would trigger the fw crash. The order of events seem to have changed now and especially BE200 (iwlwifi/mld) is picky about this and would crash the firmware with something like: iwlwifi0: 0x20103311 | ADVANCED_SYSASSERT iwlwifi0: 0x00000000 | umac branchlink1 iwlwifi0: 0xC00808AA | umac branchlink2 iwlwifi0: 0xD00D6E90 | umac interruptlink1 iwlwifi0: 0x0108C504 | umac interruptlink2 iwlwifi0: 0x00000000 | umac data1 (link_id? seen weird values there though) iwlwifi0: 0x00000006 | umac data2 (fw_sta_id) iwlwifi0: 0x00000001 | umac data3 if it would still think we were assoc. So the new order is as one would have expected initially: set assoc = false, aid = 0; do the remaining bss_conf (vif/link) changes and issue the (*vif_cfg_changed) / (*link_info_changed) or for older drivers (*bss_info_changed). That will tell the mac we are no longer associated. And only then remove the sta from the firmware. Update the comment there along so we do have the paper trail as to when and why this changed. Tested on: BE200, AX210 (11ac) Tested on: AX200. 9260, 8265, 3165 (11a) Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/compat/linuxkpi/common/src/linux_80211.c | 57 +++++++++++++++------------- 1 file changed, 30 insertions(+), 27 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index c003075ae601..63f92b8afb2b 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -3281,24 +3281,27 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int bss_changed = 0; /* - * Start updating bss info (bss_info_changed) (assoc, aid, ..). + * Start updating bss info (*bss_info_changed) (assoc, aid, ..). * - * One would expect this to happen when going off AUTHORIZED. - * See comment there; removes the sta from fw if not careful - * (bss_info_changed() change is executed right away). + * One would expect this to happen when going off AUTHORIZED but + * not so. * - * We need to do this now, before sta changes to IEEE80211_STA_NOTEXIST - * as otherwise drivers (iwlwifi at least) will silently not remove - * the sta from the firmware and when we will add a new one trigger - * a fw assert. + * Immediately issuing the (*bss_info_changed) used to also remove the + * sta from firmware for iwlwifi; or we have problems with the sta + * silently not being removed and then crash upon the next sta add. + * Neither seems to be the case or a problem still. * - * The order which works best so far avoiding early removal or silent - * non-removal seems to be (for iwlwifi::mld-mac80211.c cases; - * the iwlwifi:mac80211.c case still to be tested): - * 1) lkpi_disassoc(): set vif->cfg.assoc = false (aid=0 side effect here) - * 2) call the last sta_state update -> IEEE80211_STA_NOTEXIST - * (removes the sta given assoc is false) - * 3) add the remaining BSS_CHANGED changes and call bss_info_changed() + * Contrary for BE200 (iwlwifi/mld) if we do not issue the + * (*vif_cfg_change) to tell FW that we are no longer assoc + * it will crash now upon sta rm. So the order now is as we once + * expected it: + * + * 1) lkpi_disassoc(): set vif->cfg.assoc = false and .aid=0 + * 2) add the remaining BSS_CHANGED changes and call (*bss_info_changed) + * (which may be split up into (*vif_cfg_change) and + * (*link_info_changed) for more modern drivers). + * 3) call the last sta_state update -> IEEE80211_STA_NOTEXIST + * (removes the sta given assoc is false) and tidy up our lists. * 4) call unassign_vif_chanctx * 5) call lkpi_hw_conf_idle * 6) call remove_chanctx @@ -3310,6 +3313,18 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int lkpi_lsta_dump(lsta, ni, __func__, __LINE__); + IMPROVE("Any bss_info changes to announce?"); + vif->bss_conf.qos = false; + bss_changed |= BSS_CHANGED_QOS; + vif->cfg.ssid_len = 0; + memset(vif->cfg.ssid, '\0', sizeof(vif->cfg.ssid)); + bss_changed |= BSS_CHANGED_BSSID; + vif->bss_conf.use_short_preamble = false; + /* XXX BSS_CHANGED_???? */ + vif->bss_conf.dtim_period = 0; /* go back to 0. */ + bss_changed |= BSS_CHANGED_BEACON_INFO; + lkpi_bss_info_change(hw, vif, bss_changed); + /* Adjust sta and change state (from NONE) to NOTEXIST. */ KASSERT(lsta != NULL, ("%s: ni %p lsta is NULL\n", __func__, ni)); KASSERT(lsta->state == IEEE80211_STA_NONE, ("%s: lsta %p state not " @@ -3326,18 +3341,6 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int lkpi_lsta_dump(lsta, ni, __func__, __LINE__); - IMPROVE("Any bss_info changes to announce?"); - vif->bss_conf.qos = false; - bss_changed |= BSS_CHANGED_QOS; - vif->cfg.ssid_len = 0; - memset(vif->cfg.ssid, '\0', sizeof(vif->cfg.ssid)); - bss_changed |= BSS_CHANGED_BSSID; - vif->bss_conf.use_short_preamble = false; - /* XXX BSS_CHANGED_???? */ - vif->bss_conf.dtim_period = 0; /* go back to 0. */ - bss_changed |= BSS_CHANGED_BEACON_INFO; - lkpi_bss_info_change(hw, vif, bss_changed); - LKPI_80211_LVIF_LOCK(lvif); /* Remove ni reference for this cache of lsta. */ lvif->lvif_bss = NULL; From nobody Thu Mar 5 14:43:54 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRXNW0Xk0z6T80t for ; Thu, 05 Mar 2026 14:43: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRXNV6P50z3S4W for ; Thu, 05 Mar 2026 14:43:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772721834; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=lz+fsGFEz2lLpMLI1wL9vN8pxHGHnz3dB0fY3P5R2PE=; b=RuKaAeafEUUytCOH13dUOUiF33scLgNCUetosxZqHOAG2Ic7lnDMSt4Itws3z7xMcM1q25 wmdLwkDvUoG1FsrbkxcmdW+Ibjdk2sc1ggHZzom/Kz5KadGVI4zt8BZiRIOOhz0REokqUY ZBJ8+7NHwRkvh7rlaeHmcP4wrVlQpuAfHh714Pf4ru3ZXamXQPwIeBpHr7bgeGwkv3onnr 43Aanpz0+gZo4NSYoZBFBsXQ34NpBWsYREmxWa1llyx62BJ8Cv3p7fcZf4l60cyKA/p0bQ Nmtt5DqZZlmXVe691WjV6TPQzvROjcZM8TFWnB/kPnH8g8exLuw6TSi5nH0uOw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772721834; a=rsa-sha256; cv=none; b=ELhIKbOgBnxpVNm5wCS1XCHSZQUIxPXNFA1pECoLlruFohKbR7vHHRmFqAA1cr/PbUXMdR hjlR0E8eqApVp94cYsjkZt9htHjeDm+L7apEnjAwaiIi+wyjGiqWnTNtrElH8MuiZts8DU WmFOHHAtO0YD5iEX7okgQ6wv3xo5HfyEtSZMdhsu9DVNDYwH3Eklk+Z9sSsPigbv6XkpUr sFXvypDyZFBL6mNY1QD11811nn65+B1vXJVDU9AuqFkCM225WrWYjFy/OtDCcqyRMVJG0q rPXNurUUl001jY5fzkO6TsdnI9PQRYQDdsV7spl+bSbF3KYMeCp4DBD3j8VJ4g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772721834; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=lz+fsGFEz2lLpMLI1wL9vN8pxHGHnz3dB0fY3P5R2PE=; b=jRieps/4Li+PdJ8AlO96Ql1z1pvjiLeVJJSiWYJDxl/P2XbtoLWFkmT7v0Qaoh5vsspKoX TbLRj9gF/S9J6puotxX2Tz230jMRkIcREm9QEsZzYDUBcSqojVhdGYFfMuhIB/cu1YTw+I nyhBgnOvibLlLtYDpd/BveTJdeONUP1kyCvdh30hpF6KIJnETGXRm0S0YXzFyxPv2oCCao QSjuMQjSYdHLyXfinU58ISJismWsR1ZHhVP2xRyEKOfmZR7xPjcuYNn/VTjJc8eTFeEKRf skMWrUdV+tcMdNRFodTy07p/LgswUyeeGuJVTuf78rVqvH4EbBVorI8QYqJVQQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRXNV5LzFzhkj for ; Thu, 05 Mar 2026 14:43:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 259b0 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 14:43:54 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 5d757312ad59 - main - build: Retire LLVM_CXXFILT option List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 5d757312ad591aae26b39943f113ebf3819718da Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 14:43:54 +0000 Message-Id: <69a996aa.259b0.1da0d24a@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=5d757312ad591aae26b39943f113ebf3819718da commit 5d757312ad591aae26b39943f113ebf3819718da Author: Ed Maste AuthorDate: 2026-03-04 19:03:42 +0000 Commit: Ed Maste CommitDate: 2026-03-05 14:43:46 +0000 build: Retire LLVM_CXXFILT option The LLVM_CXXFILT option was added when we used ELF Tool Chain tools by default. ELF Tool Chain's c++filt failed to demangle some symbols, so we added a special case to install LLVM's version and enabled it by default. The rest of the LLVM tools are now used by default, as of commit 9fa94e1c099d ("Turn on WITH_LLVM_CXXFILT by default"). Simplify the build logic by removing a special case and just include llvm-cxxfilt with the rest of the LLVM utilities. Reviewed by: dim Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55654 --- share/man/man5/src.conf.5 | 6 +----- share/mk/src.opts.mk | 7 ------- tools/build/mk/OptionalObsoleteFiles.inc | 7 ++----- tools/build/options/WITHOUT_LLVM_CXXFILT | 1 - tools/build/options/WITH_LLVM_CXXFILT | 1 - usr.bin/Makefile | 2 -- usr.bin/clang/Makefile | 5 +---- usr.bin/clang/llvm-cxxfilt/Makefile | 2 -- 8 files changed, 4 insertions(+), 27 deletions(-) diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index 01e9db1f1915..71d8af3057d5 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 March 3, 2026 +.Dd March 5, 2026 .Dt SRC.CONF 5 .Os .Sh NAME @@ -122,8 +122,6 @@ When set, it enforces these options: .Bl -item -compact .It .Va WITH_LLVM_BINUTILS -.It -.Va WITH_LLVM_CXXFILT .El .It Va WITHOUT_ASSERT_DEBUG Compile programs and libraries without the @@ -995,8 +993,6 @@ is always provided by ELF Tool Chain. Do not build the .Xr llvm-cov 1 tool. -.It Va WITHOUT_LLVM_CXXFILT -Install ELF Tool Chain's cxxfilt as c++filt, instead of LLVM's llvm-cxxfilt. .It Va WITH_LLVM_FULL_DEBUGINFO Generate full debug information for LLVM libraries and tools, which uses more disk space and build resources, but allows for easier debugging. diff --git a/share/mk/src.opts.mk b/share/mk/src.opts.mk index 4abe1c699b4e..fa91c537188d 100644 --- a/share/mk/src.opts.mk +++ b/share/mk/src.opts.mk @@ -125,7 +125,6 @@ __DEFAULT_YES_OPTIONS = \ LLVM_ASSERTIONS \ LLVM_BINUTILS \ LLVM_COV \ - LLVM_CXXFILT \ LOADER_BIOS_TEXTONLY \ LOADER_GELI \ LOADER_KBOOT \ @@ -508,12 +507,6 @@ MK_LLVM_COV:= no MK_LLVM_BINUTILS:= yes .endif -.if ${MK_LLVM_BINUTILS} == "yes" -# MK_LLVM_CXXFILT is a subset of MK_LLVM_BINUTILS and should therefore be -# enabled if MK_LLVM_BINUTILS is set. -MK_LLVM_CXXFILT:= yes -.endif - .if ${MK_LOADER_VERIEXEC} == "no" MK_LOADER_VERIEXEC_PASS_MANIFEST := no .endif diff --git a/tools/build/mk/OptionalObsoleteFiles.inc b/tools/build/mk/OptionalObsoleteFiles.inc index c915da8ca501..fd25359c7c0b 100644 --- a/tools/build/mk/OptionalObsoleteFiles.inc +++ b/tools/build/mk/OptionalObsoleteFiles.inc @@ -896,6 +896,7 @@ OLD_LIBS+=usr/lib/libprivatellvm.so.19 .if ${MK_CLANG} == no && ${MK_LLVM_BINUTILS} == no OLD_FILES+=usr/bin/llvm-addr2line OLD_FILES+=usr/bin/llvm-ar +OLD_FILES+=usr/bin/llvm-cxxfilt OLD_FILES+=usr/bin/llvm-nm OLD_FILES+=usr/bin/llvm-objcopy OLD_FILES+=usr/bin/llvm-objdump @@ -908,6 +909,7 @@ OLD_FILES+=usr/bin/llvm-symbolizer OLD_FILES+=usr/bin/objdump OLD_FILES+=usr/share/man/man1/llvm-addr2line.1.gz OLD_FILES+=usr/share/man/man1/llvm-ar.1.gz +OLD_FILES+=usr/share/man/man1/llvm-cxxfilt.1.gz OLD_FILES+=usr/share/man/man1/llvm-nm.1.gz OLD_FILES+=usr/share/man/man1/llvm-objcopy.1.gz OLD_FILES+=usr/share/man/man1/llvm-ranlib.1.gz @@ -1388,11 +1390,6 @@ OLD_FILES+=usr/share/man/man1/opt.1.gz OLD_FILES+=usr/bin/clang-format .endif -.if ${MK_CLANG_EXTRAS} == no && ${MK_LLVM_CXXFILT} == no -OLD_FILES+=usr/bin/llvm-cxxfilt -OLD_FILES+=usr/share/man/man1/llvm-cxxfilt.1.gz -.endif - .if ${MK_CPP} == no OLD_FILES+=usr/bin/cpp OLD_FILES+=usr/share/man/man1/cpp.1.gz diff --git a/tools/build/options/WITHOUT_LLVM_CXXFILT b/tools/build/options/WITHOUT_LLVM_CXXFILT deleted file mode 100644 index e7d263f01f2a..000000000000 --- a/tools/build/options/WITHOUT_LLVM_CXXFILT +++ /dev/null @@ -1 +0,0 @@ -Install ELF Tool Chain's cxxfilt as c++filt, instead of LLVM's llvm-cxxfilt. diff --git a/tools/build/options/WITH_LLVM_CXXFILT b/tools/build/options/WITH_LLVM_CXXFILT deleted file mode 100644 index f6ac38b20af7..000000000000 --- a/tools/build/options/WITH_LLVM_CXXFILT +++ /dev/null @@ -1 +0,0 @@ -Install LLVM's llvm-cxxfilt as c++filt, instead of ELF Tool Chain's cxxfilt. diff --git a/usr.bin/Makefile b/usr.bin/Makefile index 0c9c66748269..125ecb6f05a0 100644 --- a/usr.bin/Makefile +++ b/usr.bin/Makefile @@ -255,9 +255,7 @@ SUBDIR.${MK_TOOLCHAIN}+= size SUBDIR.${MK_TOOLCHAIN}+= c89 SUBDIR.${MK_TOOLCHAIN}+= c99 SUBDIR.${MK_TOOLCHAIN}+= ctags -.if ${MK_LLVM_CXXFILT} == "no" SUBDIR.${MK_TOOLCHAIN}+= cxxfilt -.endif # ELF Tool Chain elfcopy required for EFI objects (PR280771) SUBDIR.${MK_TOOLCHAIN}+= elfcopy SUBDIR.${MK_TOOLCHAIN}+= file2c diff --git a/usr.bin/clang/Makefile b/usr.bin/clang/Makefile index e2debfb8c582..ac92b08a54cb 100644 --- a/usr.bin/clang/Makefile +++ b/usr.bin/clang/Makefile @@ -14,6 +14,7 @@ SUBDIR+= clang-scan-deps # as the default binutils (ar,nm,addr2line, etc.). .if ${MK_CLANG} != "no" || ${MK_LLVM_BINUTILS} != "no" SUBDIR+= llvm-ar +SUBDIR+= llvm-cxxfilt SUBDIR+= llvm-nm SUBDIR+= llvm-objcopy SUBDIR+= llvm-objdump @@ -23,10 +24,6 @@ SUBDIR+= llvm-strings SUBDIR+= llvm-symbolizer .endif -.if ${MK_LLVM_BINUTILS} != "no" || ${MK_LLVM_CXXFILT} != "no" -SUBDIR+= llvm-cxxfilt -.endif - .if ${MK_CLANG_EXTRAS} != "no" SUBDIR+= bugpoint SUBDIR+= llc diff --git a/usr.bin/clang/llvm-cxxfilt/Makefile b/usr.bin/clang/llvm-cxxfilt/Makefile index f9621da8da89..98cc5c09f4c4 100644 --- a/usr.bin/clang/llvm-cxxfilt/Makefile +++ b/usr.bin/clang/llvm-cxxfilt/Makefile @@ -22,9 +22,7 @@ DEPENDFILES+= ${TGHDRS:C/$/.d/} DPSRCS+= ${TGHDRS} CLEANFILES+= ${TGHDRS} ${TGHDRS:C/$/.d/} -.if ${MK_LLVM_CXXFILT} != "no" LINKS= ${BINDIR}/llvm-cxxfilt ${BINDIR}/c++filt MLINKS= llvm-cxxfilt.1 c++filt.1 -.endif .include "../llvm.prog.mk" From nobody Thu Mar 5 15:14:20 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRY3c5Fbpz6TBPX for ; Thu, 05 Mar 2026 15:14: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRY3c4c7bz3Zj6 for ; Thu, 05 Mar 2026 15:14:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772723660; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=u9yyFK9PRdo0ppkSsv6hcR6gfPuzNIpsipQehHydPZI=; b=mbjN1oeHx8nojG2td5ZqtdFbsyf5s7j7q0PBAGhtu5gQCLgwNLBaqg4byH3KbKoz85Lwp2 Zx/IROqBw4rGLTFGHHhgFF1HABki1hIBcKJftfohlwkeBG7mbU7W8Hjl3Hv3/9bTtYpi1p hapx7488FY/SWozXas2V4ikcP/FloKQOZma2voG6B2k12XNkm9Qu2mv4B4MtbHsnlzCoyb fn5Ia3bkrsjXBoOk7sje9Gw5IJRMlBxeyo8EThcOLXzFOISkA2H1MZ1zeUgjEL32IWjiL1 dYrvResrpmGIlxRyOTVwan05SDgtLcG/VV0eFWaeSuC2YeINLgbQ62jwef4KdA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772723660; a=rsa-sha256; cv=none; b=WcasaO8emgmJzpqs5ZOvmpz7kNG/g5xGHazUzRbZZLUgavHnqW3gi0k6zyhpuRxyIzk9ag 6dmBJAr2uzfQNEkXKvoyIDBjVG5hrfWdlrVhZPL3T5uBHr7H1PkOa91V3i+KWaMqIbwEzn hGqWRFtfAtY6B5eMZqta7tStmDTs1MgW0l7Xmg3lw0zdwyfnCt9nLZhpWI3kQEJeXcSx1a Yh5SNW9q6VO9lXIJaNSlh+Qjdk+m3iOPUeXqmjnzB+1CsaI7QcxX+gb7ceoW9iK8S/lmry C6S+aSQiiyxTPZjx/iqZmrFcoyBNZmo4wNYEST3JdXCO6MIVkY33QEkXmrbw6w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772723660; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=u9yyFK9PRdo0ppkSsv6hcR6gfPuzNIpsipQehHydPZI=; b=j1EmhKEmqgBvtop4RdkIDn0ibqfujSweUaMCL4JSkKfHdMtibM3y42GV3CzGAldY5ErPwj MlesBmKTeWahErQ3imQ6lk+la8HewfX5eXL/5jHcOi/bC50omGqaIudXa/kLS2wsuz2E82 p5TcFsfR7G7wMTik842QjwK3kCFwYLFhLXwkGM9m5v03KHYSAVYVgU/VaE3JePRMrYZsSl dLlV4TbSkNcRUa/8YUhnS/WagM/6lcyPLf4USylxamsdaJ+6b9LKINekQbG9wAFKKS+mGV TtQHsnXu8CB5Abqtf0VjpBTOHSuZhH3G8SmLQefoHHQBzvQlvgOGFKwN/EUpqw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRY3c40Rgzjd2 for ; Thu, 05 Mar 2026 15:14:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 31814 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 15:14:20 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Turner Subject: git: 570b8b25753c - main - arm64: Use a canonical address when TBI is enabled List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 570b8b25753c2be7657f0e906cb5a89c7f35b56e Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 15:14:20 +0000 Message-Id: <69a99dcc.31814.fa2f629@gitrepo.freebsd.org> The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=570b8b25753c2be7657f0e906cb5a89c7f35b56e commit 570b8b25753c2be7657f0e906cb5a89c7f35b56e Author: Andrew Turner AuthorDate: 2026-03-05 14:27:37 +0000 Commit: Andrew Turner CommitDate: 2026-03-05 15:13:30 +0000 arm64: Use a canonical address when TBI is enabled When Top Byte Ignore (TBI) is enabled in a processor we need to pass a canonical address to the vm subsystem. Reviewed by: alc, kib Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D55619 --- sys/arm64/arm64/trap.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sys/arm64/arm64/trap.c b/sys/arm64/arm64/trap.c index b3c68fa4826f..3ce0b29f0b82 100644 --- a/sys/arm64/arm64/trap.c +++ b/sys/arm64/arm64/trap.c @@ -262,6 +262,7 @@ data_abort(struct thread *td, struct trapframe *frame, uint64_t esr, { struct vm_map *map; struct pcb *pcb; + vm_offset_t fault_va; vm_prot_t ftype; int error, sig, ucode; #ifdef KDB @@ -282,8 +283,11 @@ data_abort(struct thread *td, struct trapframe *frame, uint64_t esr, } #endif + fault_va = far; if (lower) { map = &td->td_proc->p_vmspace->vm_map; + if ((td->td_proc->p_md.md_tcr & TCR_TBI0) != 0) + fault_va = ADDR_MAKE_CANONICAL(far); } else if (!ADDR_IS_CANONICAL(far)) { /* We received a TBI/PAC/etc. fault from the kernel */ error = KERN_INVALID_ADDRESS; @@ -338,7 +342,7 @@ data_abort(struct thread *td, struct trapframe *frame, uint64_t esr, * or pmap_fault() will recurse on that lock. */ if ((lower || map == kernel_map || pcb->pcb_onfault != 0) && - pmap_fault(map->pmap, esr, far) == KERN_SUCCESS) + pmap_fault(map->pmap, esr, fault_va) == KERN_SUCCESS) return; #ifdef INVARIANTS @@ -379,7 +383,8 @@ data_abort(struct thread *td, struct trapframe *frame, uint64_t esr, } /* Fault in the page. */ - error = vm_fault_trap(map, far, ftype, VM_FAULT_NORMAL, &sig, &ucode); + error = vm_fault_trap(map, fault_va, ftype, VM_FAULT_NORMAL, &sig, + &ucode); if (error != KERN_SUCCESS) { if (lower) { call_trapsignal(td, sig, ucode, (void *)far, From nobody Thu Mar 5 15:14:21 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRY3d62VCz6TBY7 for ; Thu, 05 Mar 2026 15:14: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRY3d5GZFz3ZZh for ; Thu, 05 Mar 2026 15:14:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772723661; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GTmNKIhzYkbUxyaCn9WrwCuhJrAvcSVygP706IIqj7w=; b=XvpfOobqfawjUgEwvaeFeMMS/r6A1eMK3cXWuzGAiNk6xUOcn7qb/en2U6HJAyK42Wv5ST wzzzmQhLW9P657HbLppvaIpftIrIFzMKLjaYOEgTCqilTxa7j5+SgkH4tRcpR3Djl7+e+v HIDVoBtZksol4P48wi78sRS7X08UxOW2RGY5xETb169MBp2bRshpU+y6Pq7pZnOUAi1xlA z9J5GnePN/mJz9xwaVu/u0BZ20zDY1+h215o+gC3amXu1m3pYkrZfVUHTsonBMXsjOoYtU hZHvAv0CBTA00NpybOv7egd9PGfaNUqEOtP9q68uSNWGKMSajPzyJ6jxAi2YxA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772723661; a=rsa-sha256; cv=none; b=qrtIzkBaGzEah8LXXHU1+KGDwCSiKyBpC54597edoWtBkE8pHb5Fc3xirWan1zdDARAg1q qdU1TdgjDYm9969771V39YQ10uit2jL3ohYyENMr1ubnwtn8YK3UBQjJzDURCr04hKPT5q JdAVmhQfckJNbv98dzTXPFAxxahi076TVH+8Usype3B/pb7kCqYcHSHIoWN5Sltew4DTjL J1rZ4CKsyimDpHAOC4p2kDMztnqyC02TtZouHv6w1zmdHSiK0w4YMiPpwefolyrP4KxYz7 Jt9O6QDffjHdm1SJwbMM8dNsbMFe6uRWphSezIet2Mf2nnEg/SrH1znEvIeFPQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772723661; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GTmNKIhzYkbUxyaCn9WrwCuhJrAvcSVygP706IIqj7w=; b=oa/qx8viL6FXN98xsxiq4tagECgXH6Ul5gOTcAK6fB4pOWVHCKtC4veXFKqTJbYaMmAc0K KTCTCN8XzO6OV0j4urWRu2Pyi2nikChk4nU8lDhO9JwvHhcEoAj9+UKJSbi/uxOF9ilALi qhIbNgWPg2o2yp0bPZO+Tx5W6mFwd7hIjwsjqzk3RzwxoZAThHa3iG//4c/71bYdT9GqjV HJehW1+AKBqOAjF+QlLHmXZyz5TvHHmQlXeTa/YT013/bHWUQoD0iIVRuvozazK7FNjMRg Dwj131K4hWGIHLbTgSziMeBX7zVzgdJaHaPxrTweGyCflPqqtelba6B0S83nTA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRY3d4qmyzjXG for ; Thu, 05 Mar 2026 15:14:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 30857 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 15:14:21 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Turner Subject: git: 80b4129bef8b - main - arm64: Optimise the repeated TLBI workaround List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 80b4129bef8b908eb19fe47853cb6e45e4513d76 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 15:14:21 +0000 Message-Id: <69a99dcd.30857.41c1a2ad@gitrepo.freebsd.org> The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=80b4129bef8b908eb19fe47853cb6e45e4513d76 commit 80b4129bef8b908eb19fe47853cb6e45e4513d76 Author: Andrew Turner AuthorDate: 2026-03-05 14:28:01 +0000 Commit: Andrew Turner CommitDate: 2026-03-05 15:13:30 +0000 arm64: Optimise the repeated TLBI workaround It has been reported that the overhead of repeating all TLBI instructions is too large [1]. The Software Developer Errata Notices (SDEN) for the relevant Arm CPUs have been updated so a single "tlbi vale1is, xzr" followed by "dsb ish" is sufficient to work around the issues. Replace the places we repeat TLBI instructions with the new sequence. [1] https://lore.kernel.org/linux-arm-kernel/20260218164348.2022831-1-mark.rutland@arm.com/ Reviewed by: kib Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D55646 --- sys/arm64/arm64/pmap.c | 44 ++++++++++++++------------------------------ 1 file changed, 14 insertions(+), 30 deletions(-) diff --git a/sys/arm64/arm64/pmap.c b/sys/arm64/arm64/pmap.c index 25192bfef653..86ef7359bbe9 100644 --- a/sys/arm64/arm64/pmap.c +++ b/sys/arm64/arm64/pmap.c @@ -1926,17 +1926,13 @@ pmap_s1_invalidate_page(pmap_t pmap, vm_offset_t va, bool final_only) r = TLBI_VA(va); if (pmap == kernel_pmap) { pmap_s1_invalidate_kernel(r, final_only); - if (pmap_multiple_tlbi) { - dsb(ish); - pmap_s1_invalidate_kernel(r, final_only); - } } else { r |= ASID_TO_OPERAND(COOKIE_TO_ASID(pmap->pm_cookie)); pmap_s1_invalidate_user(r, final_only); - if (pmap_multiple_tlbi) { - dsb(ish); - pmap_s1_invalidate_user(r, final_only); - } + } + if (pmap_multiple_tlbi) { + dsb(ish); + __asm __volatile("tlbi vale1is, xzr" ::: "memory"); } dsb(ish); isb(); @@ -1978,24 +1974,16 @@ pmap_s1_invalidate_strided(pmap_t pmap, vm_offset_t sva, vm_offset_t eva, end = TLBI_VA(eva); for (r = start; r < end; r += TLBI_VA(stride)) pmap_s1_invalidate_kernel(r, final_only); - - if (pmap_multiple_tlbi) { - dsb(ish); - for (r = start; r < end; r += TLBI_VA(stride)) - pmap_s1_invalidate_kernel(r, final_only); - } } else { start = end = ASID_TO_OPERAND(COOKIE_TO_ASID(pmap->pm_cookie)); start |= TLBI_VA(sva); end |= TLBI_VA(eva); for (r = start; r < end; r += TLBI_VA(stride)) pmap_s1_invalidate_user(r, final_only); - - if (pmap_multiple_tlbi) { - dsb(ish); - for (r = start; r < end; r += TLBI_VA(stride)) - pmap_s1_invalidate_user(r, final_only); - } + } + if (pmap_multiple_tlbi) { + dsb(ish); + __asm __volatile("tlbi vale1is, xzr" ::: "memory"); } dsb(ish); isb(); @@ -2036,11 +2024,11 @@ pmap_s1_invalidate_all_kernel(void) { dsb(ishst); __asm __volatile("tlbi vmalle1is"); - dsb(ish); if (pmap_multiple_tlbi) { - __asm __volatile("tlbi vmalle1is"); dsb(ish); + __asm __volatile("tlbi vale1is, xzr" ::: "memory"); } + dsb(ish); isb(); } @@ -2058,17 +2046,13 @@ pmap_s1_invalidate_all(pmap_t pmap) dsb(ishst); if (pmap == kernel_pmap) { __asm __volatile("tlbi vmalle1is"); - if (pmap_multiple_tlbi) { - dsb(ish); - __asm __volatile("tlbi vmalle1is"); - } } else { r = ASID_TO_OPERAND(COOKIE_TO_ASID(pmap->pm_cookie)); __asm __volatile("tlbi aside1is, %0" : : "r" (r)); - if (pmap_multiple_tlbi) { - dsb(ish); - __asm __volatile("tlbi aside1is, %0" : : "r" (r)); - } + } + if (pmap_multiple_tlbi) { + dsb(ish); + __asm __volatile("tlbi vale1is, xzr" ::: "memory"); } dsb(ish); isb(); From nobody Thu Mar 5 16:04:48 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRZ9w2whwz6TG34; Thu, 05 Mar 2026 16:04:52 +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 4fRZ9v5LmFz3glY; Thu, 05 Mar 2026 16:04:51 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Authentication-Results: mx1.freebsd.org; none Received: from shw-obgw-4003b.ext.cloudfilter.net ([10.228.9.157]) by cmsmtp with ESMTPS id y6N3v4F8kPzKyyBBzv4m9Z; Thu, 05 Mar 2026 16:04:51 +0000 Received: from spqr.komquats.com ([70.66.136.217]) by cmsmtp with ESMTPSA id yBBxv7gbNRXCAyBByv9L2X; Thu, 05 Mar 2026 16:04:51 +0000 X-Auth-User: cschuber X-Authority-Analysis: v=2.4 cv=CNonnBrD c=1 sm=1 tr=0 ts=69a9a9a3 a=h7br+8Ma+Xn9xscxy5znUg==:117 a=h7br+8Ma+Xn9xscxy5znUg==:17 a=kj9zAlcOel0A:10 a=Yq5XynenixoA:10 a=6I5d2MoRAAAA:8 a=EkcXrb_YAAAA:8 a=YxBL1-UpAAAA:8 a=V5JxOvHHU22uCPVm3GUA:9 a=CjuIK1q_8ugA:10 a=O8hF6Hzn-FEA: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 12688963; Thu, 05 Mar 2026 08:04:49 -0800 (PST) Received: by slippy.cwsent.com (Postfix, from userid 1000) id CA4EF360; Thu, 05 Mar 2026 08:04:48 -0800 (PST) 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: Baptiste Daroussin cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 28ff4d35f8b9 - main - libedit: vendor import version 2026-03-04 In-reply-to: <69a92e32.1f40f.65c93a59@gitrepo.freebsd.org> References: <69a92e32.1f40f.65c93a59@gitrepo.freebsd.org> Comments: In-reply-to Baptiste Daroussin message dated "Thu, 05 Mar 2026 07:18:10 +0000." List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 05 Mar 2026 08:04:48 -0800 Message-Id: <20260305160448.CA4EF360@slippy.cwsent.com> X-CMAE-Envelope: MS4xfBFCVS9b6bjA5oaiCAc4y7WkobTO6wdRP9lNPxg5vL2NmcwtqnvWGrjuCFbmuNuFlMKPZSjfJUQi9+56FLypYHSmBGKPqyQ0WrXzQGeLH8BUXiqr1gRH 8/leiNV1ActFhoiksWgoNRmpov6yAoaxRI6v+V76KeuAQngyhzXXL2w5N3ICLLhFXrVMZcf9J5C7oPChAztttSFpFg+E5RGnIqZFj9hk+ABMWRB5nJnfVo2m bJHdx4vS4SPrVzlEosjSDnEHR2n0pjDHowazW1MRB4uK+eamjMIgoBVmx+rBVXNg5eHlyLGGil9/elCUCmaInPfi9kyzEsZTe5dhfBKnD9Y= X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:16509, ipnet:3.96.0.0/15, country:US] X-Rspamd-Queue-Id: 4fRZ9v5LmFz3glY X-Spamd-Bar: ---- This breaks exec(1) builtin. For instance, exec csh exec bash exec some_other_app All the above result in /bin/sh segfaulting at map.c:968. -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org e**(i*pi)+1=0 In message <69a92e32.1f40f.65c93a59@gitrepo.freebsd.org>, Baptiste Daroussin wr ites: > The branch main has been updated by bapt: > > URL: https://cgit.FreeBSD.org/src/commit/?id=28ff4d35f8b904952bf86b3264650d91 > cc0cb5d7 > > commit 28ff4d35f8b904952bf86b3264650d91cc0cb5d7 > Merge: 1abb62867f2a b1ddc060e941 > Author: Baptiste Daroussin > AuthorDate: 2026-03-05 07:17:09 +0000 > Commit: Baptiste Daroussin > CommitDate: 2026-03-05 07:17:51 +0000 > > libedit: vendor import version 2026-03-04 > > MFC After: 1 week > > contrib/libedit/ChangeLog | 6123 +++++++++++++++++++++++++++++++++ > +- > contrib/libedit/chared.c | 50 +- > contrib/libedit/chared.h | 22 +- > contrib/libedit/common.c | 12 +- > contrib/libedit/edit.expsym | 1 + > contrib/libedit/editline.3 | 38 +- > contrib/libedit/editline.7 | 10 +- > contrib/libedit/el.c | 30 +- > contrib/libedit/el.h | 3 +- > contrib/libedit/eln.c | 12 +- > contrib/libedit/emacs.c | 16 +- > contrib/libedit/hist.c | 10 +- > contrib/libedit/hist.h | 4 +- > contrib/libedit/histedit.h | 4 +- > contrib/libedit/history.c | 6 +- > contrib/libedit/makelist | 4 +- > contrib/libedit/map.c | 45 +- > contrib/libedit/map.h | 7 +- > contrib/libedit/readline.c | 16 +- > contrib/libedit/readline/readline.h | 3 +- > contrib/libedit/refresh.c | 14 +- > contrib/libedit/search.c | 7 +- > contrib/libedit/sig.c | 6 +- > contrib/libedit/terminal.c | 6 +- > contrib/libedit/vi.c | 14 +- > 25 files changed, 6358 insertions(+), 105 deletions(-) > > From nobody Thu Mar 5 16:13:25 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRZMn6yYgz6TGdk for ; Thu, 05 Mar 2026 16:13: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRZMn5HZrz3k4K for ; Thu, 05 Mar 2026 16:13:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772727205; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8sbA8JUGzdXQhCASXjzGmInfjearVQ2T2P9b+MJ8mvI=; b=eQPSQ4EQskfPy0egk3wEWBc/tfw7XMRqALrUC4MK76IlbaGKx/UuzSvtTo27GGoqMlbBGA 1g+XEQpi8rAZBAhFn2scj/aDpXPAfkLms8vQy1TOCuzZHXbcVXd7sqnFrrfIivE7wqTB4T MO/zKHYib+ez/PwwItED08HB89J6PIZ+FTi345niP8Z5v71bj+a4fFSq36lQs3aIHC33Cx O9kPWVsd9d9G9LzwEIE6/WaAs60h/SYNFerajCji7zeq1JiLMt9I8TESNa7c02NlcrywSQ F+Yok4htmHdWbr2KYHEfNrkpa1qerylXFEZ4/XJZPYbJTgDhNveJRajx4gP9Sw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772727205; a=rsa-sha256; cv=none; b=FhDkq6deA2NNRrNV/3wJWCQCksGfkj35yJE++F1ihU0dTgNV7IPj4C6NB9/mxuLkJ8sLcZ hfQILppOyEwao6kCr7H8JI3ONtG1baSkTnm1x8Rr212QzQZdW7eOuu21/TADVf9KBXnFUc oNvtOopFgHLa+IfQeMqx0O4mU1VDY8wcViaemathvbwYtytyEK+gn/7BaK5l+ArfQtHz15 pH/rEO8ADgOBPOd7wAkieeE8ljhbO2+8UqIfMOARNNxKNMmPLmIL8snzsnMhbVIHR4M7uo ZsQjNdTp8wZJcAzn0TZ5OPOz/6lJ3YqD6+uqc0tFf+kOono/p5wlEboeotVh/A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772727205; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8sbA8JUGzdXQhCASXjzGmInfjearVQ2T2P9b+MJ8mvI=; b=JOkl7Ik4g3nCamxymdJp+FQpA+HMKIo12ih432D40if6+xfaITNKqziJ4H2pGNRIb8SvMa 9d54rhApvOa87qXCuqxKbwdgkdwKG+qzXvVsLIGqBYhOk0+/tgYWnu2tA/xd1EZlfDqgTf Hw6Kus9evaFcuYNdYBqcw2yA8KuloEmqFDirDZuUt86udvXIvdaErBSN0PdxwmYZmlfbJE Tjlocs2x0sEMG6VE1WH86rQozF/Z7Fkd4ktBUGaODyVFZeCFGVZht4YqwViFlvp2QKxn1z I87JN8sfM7gEmxXi906WlrLNrrjKw4Ly/1VLN8/yfiA75Q0eXkjwyrS1HdR4vw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRZMn4DV2zkhP for ; Thu, 05 Mar 2026 16:13:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 38ca9 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 16:13:25 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Baptiste Daroussin Subject: git: 6d2a147ae558 - main - libedit: fix use after free List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 6d2a147ae558ef423e3df451a9049200b291a8d0 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 16:13:25 +0000 Message-Id: <69a9aba5.38ca9.25c6649c@gitrepo.freebsd.org> The branch main has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=6d2a147ae558ef423e3df451a9049200b291a8d0 commit 6d2a147ae558ef423e3df451a9049200b291a8d0 Author: Baptiste Daroussin AuthorDate: 2026-03-05 16:12:51 +0000 Commit: Baptiste Daroussin CommitDate: 2026-03-05 16:13:08 +0000 libedit: fix use after free --- contrib/libedit/map.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/libedit/map.c b/contrib/libedit/map.c index e45b819c0be0..6e08d647a980 100644 --- a/contrib/libedit/map.c +++ b/contrib/libedit/map.c @@ -962,12 +962,12 @@ map_end(EditLine *el) el->el_map.emacs = NULL; el->el_map.vic = NULL; el->el_map.vii = NULL; - el_free(el->el_map.help); - el->el_map.help = NULL; for (size_t nf = EL_NUM_FCNS; nf < el->el_map.nfunc; nf++) { el_free((void *)(intptr_t)el->el_map.help[nf].name); el_free((void *)(intptr_t)el->el_map.help[nf].description); } + el_free(el->el_map.help); + el->el_map.help = NULL; el_free(el->el_map.func); el->el_map.func = NULL; } From nobody Thu Mar 5 16:17:36 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRZSh0p3zz6TH7w; Thu, 05 Mar 2026 16:17:40 +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 4fRZSg3LXfz3kV9; Thu, 05 Mar 2026 16:17:39 +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.33 as permitted sender) smtp.mailfrom=cy.schubert@cschubert.com Received: from shw-obgw-4001b.ext.cloudfilter.net ([10.228.9.171]) by cmsmtp with ESMTPS id y5B2v4CjEPzKyyBOMv5SIO; Thu, 05 Mar 2026 16:17:38 +0000 Received: from spqr.komquats.com ([70.66.136.217]) by cmsmtp with ESMTPSA id yBOLvuptLX0jpyBOMvCbSp; Thu, 05 Mar 2026 16:17:38 +0000 X-Auth-User: cschuber X-Authority-Analysis: v=2.4 cv=FMIWBuos c=1 sm=1 tr=0 ts=69a9aca2 a=h7br+8Ma+Xn9xscxy5znUg==:117 a=h7br+8Ma+Xn9xscxy5znUg==:17 a=kj9zAlcOel0A:10 a=Yq5XynenixoA:10 a=6I5d2MoRAAAA:8 a=EkcXrb_YAAAA:8 a=YxBL1-UpAAAA:8 a=VxmjJ2MpAAAA:8 a=bYwXNKrmTY7iAf6SOOwA:9 a=CjuIK1q_8ugA:10 a=O8hF6Hzn-FEA:10 a=LK5xJRSDVpKd5WXXoEvA:22 a=Ia-lj3WSrqcvXOmTRaiG:22 a=7gXAzLPJhVmCkEl4_tsf:22 Received: from slippy.cwsent.com (slippy.cwsent.com [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTP id 0ACF896D; Thu, 05 Mar 2026 08:17:36 -0800 (PST) Received: by slippy.cwsent.com (Postfix, from userid 1000) id DE0812E2; Thu, 05 Mar 2026 08:17:36 -0800 (PST) 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: Baptiste Daroussin cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 28ff4d35f8b9 - main - libedit: vendor import version 2026-03-04 In-reply-to: <20260305160448.CA4EF360@slippy.cwsent.com> References: <69a92e32.1f40f.65c93a59@gitrepo.freebsd.org> <20260305160448.CA4EF360@slippy.cwsent.com> Comments: In-reply-to Cy Schubert message dated "Thu, 05 Mar 2026 08:04:48 -0800." List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 05 Mar 2026 08:17:36 -0800 Message-Id: <20260305161736.DE0812E2@slippy.cwsent.com> X-CMAE-Envelope: MS4xfLO2Pg9Hod19emfqt26MoTGP6mwzK6k5ziWG3g5bx2sgC87XHIZHK3EuVvzJZnm3OmF0J7CHHEayf40oUIytNGtOLAeGvNPnUU65zLr3nQcK2ELWgJir 3eOuniAYSRGz3xlEosz9lYWgWgOsh2nrFHZyhmi55uRwfUEvGqvgHrz61+CWSWlrIOPZExT6rMtnpH3aLLEG2OcKj29OnU++RwDcnCA+eP52YpOslSaVuKus fv8MCgKztEFvLqlNwND7cv6xdpl8MUdN+47VB8HEIDzU3OcEeiJsUbJMLjyhXdjvwbTk/jm6k4/3ykNcZuNDIsspIQ5uTRV1aav+vDf0q6c= X-Spamd-Result: default: False [-2.88 / 15.00]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.98)[-0.975]; MV_CASE(0.50)[]; R_SPF_ALLOW(-0.20)[+ip4:3.97.99.32/31]; MIME_GOOD(-0.10)[text/plain]; RCVD_IN_DNSWL_LOW(-0.10)[3.97.99.33:from]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; ASN(0.00)[asn:16509, ipnet:3.96.0.0/15, country:US]; FROM_HAS_DN(0.00)[]; RCVD_COUNT_THREE(0.00)[4]; DMARC_BAD_POLICY(0.00)[cschubert.com : p tag has invalid value: quarantine rua=mailto:p[ostmaster@cschubert.com]; RCPT_COUNT_THREE(0.00)[4]; FROM_EQ_ENVFROM(0.00)[]; HAS_REPLYTO(0.00)[Cy.Schubert@cschubert.com]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MLMMJ_DEST(0.00)[dev-commits-src-all@freebsd.org,dev-commits-src-main@freebsd.org]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; REPLYTO_EQ_FROM(0.00)[] X-Rspamd-Queue-Id: 4fRZSg3LXfz3kV9 X-Spamd-Bar: -- BTW, it's upsream's (NetBSD's) last two commits to their map.c that are the offending commits. They're supposed to mitigate a memory leak but on FreeBSD the commits do more than that. -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org e**(i*pi)+1=0 In message <20260305160448.CA4EF360@slippy.cwsent.com>, Cy Schubert writes: > This breaks exec(1) builtin. > > For instance, > > exec csh > exec bash > exec some_other_app > > All the above result in /bin/sh segfaulting at map.c:968. > > > -- > Cheers, > Cy Schubert > FreeBSD UNIX: Web: https://FreeBSD.org > NTP: Web: https://nwtime.org > > e**(i*pi)+1=0 > > In message <69a92e32.1f40f.65c93a59@gitrepo.freebsd.org>, Baptiste > Daroussin wr > ites: > > The branch main has been updated by bapt: > > > > URL: https://cgit.FreeBSD.org/src/commit/?id=28ff4d35f8b904952bf86b3264650d > 91 > > cc0cb5d7 > > > > commit 28ff4d35f8b904952bf86b3264650d91cc0cb5d7 > > Merge: 1abb62867f2a b1ddc060e941 > > Author: Baptiste Daroussin > > AuthorDate: 2026-03-05 07:17:09 +0000 > > Commit: Baptiste Daroussin > > CommitDate: 2026-03-05 07:17:51 +0000 > > > > libedit: vendor import version 2026-03-04 > > > > MFC After: 1 week > > > > contrib/libedit/ChangeLog | 6123 +++++++++++++++++++++++++++++++ > ++ > > +- > > contrib/libedit/chared.c | 50 +- > > contrib/libedit/chared.h | 22 +- > > contrib/libedit/common.c | 12 +- > > contrib/libedit/edit.expsym | 1 + > > contrib/libedit/editline.3 | 38 +- > > contrib/libedit/editline.7 | 10 +- > > contrib/libedit/el.c | 30 +- > > contrib/libedit/el.h | 3 +- > > contrib/libedit/eln.c | 12 +- > > contrib/libedit/emacs.c | 16 +- > > contrib/libedit/hist.c | 10 +- > > contrib/libedit/hist.h | 4 +- > > contrib/libedit/histedit.h | 4 +- > > contrib/libedit/history.c | 6 +- > > contrib/libedit/makelist | 4 +- > > contrib/libedit/map.c | 45 +- > > contrib/libedit/map.h | 7 +- > > contrib/libedit/readline.c | 16 +- > > contrib/libedit/readline/readline.h | 3 +- > > contrib/libedit/refresh.c | 14 +- > > contrib/libedit/search.c | 7 +- > > contrib/libedit/sig.c | 6 +- > > contrib/libedit/terminal.c | 6 +- > > contrib/libedit/vi.c | 14 +- > > 25 files changed, 6358 insertions(+), 105 deletions(-) > > > > > > > From nobody Thu Mar 5 16:51:52 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRbDC2wqCz6TLKk; Thu, 05 Mar 2026 16:51:55 +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 4fRbDC0g5Wz3nYl; Thu, 05 Mar 2026 16:51:55 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Authentication-Results: mx1.freebsd.org; none Received: from shw-obgw-4003b.ext.cloudfilter.net ([10.228.9.157]) by cmsmtp with ESMTPS id y6S6v4FJePzKyyBvWv6Q4B; Thu, 05 Mar 2026 16:51:54 +0000 Received: from spqr.komquats.com ([70.66.136.217]) by cmsmtp with ESMTPSA id yBvUv7rFQRXCAyBvVv9QsQ; Thu, 05 Mar 2026 16:51:54 +0000 X-Auth-User: cschuber X-Authority-Analysis: v=2.4 cv=CNonnBrD c=1 sm=1 tr=0 ts=69a9b4aa a=h7br+8Ma+Xn9xscxy5znUg==:117 a=h7br+8Ma+Xn9xscxy5znUg==:17 a=kj9zAlcOel0A:10 a=Yq5XynenixoA:10 a=6I5d2MoRAAAA:8 a=EkcXrb_YAAAA:8 a=YxBL1-UpAAAA:8 a=VxmjJ2MpAAAA:8 a=bLTTr1hbErLoM9muAxUA:9 a=CjuIK1q_8ugA:10 a=O8hF6Hzn-FEA:10 a=LK5xJRSDVpKd5WXXoEvA:22 a=Ia-lj3WSrqcvXOmTRaiG:22 a=7gXAzLPJhVmCkEl4_tsf:22 Received: from slippy.cwsent.com (slippy.cwsent.com [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTP id 9D5CD8FE; Thu, 05 Mar 2026 08:51:52 -0800 (PST) Received: by slippy.cwsent.com (Postfix, from userid 1000) id 7CD6C490; Thu, 05 Mar 2026 08:51:52 -0800 (PST) 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: Cy Schubert cc: Baptiste Daroussin , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 28ff4d35f8b9 - main - libedit: vendor import version 2026-03-04 In-reply-to: <20260305161736.DE0812E2@slippy.cwsent.com> References: <69a92e32.1f40f.65c93a59@gitrepo.freebsd.org> <20260305160448.CA4EF360@slippy.cwsent.com> <20260305161736.DE0812E2@slippy.cwsent.com> Comments: In-reply-to Cy Schubert message dated "Thu, 05 Mar 2026 08:17:36 -0800." List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 05 Mar 2026 08:51:52 -0800 Message-Id: <20260305165152.7CD6C490@slippy.cwsent.com> X-CMAE-Envelope: MS4xfFBMWURxrYFq7NG7EoOph68wM4MwyiABHwl+lNzzkmGpM9Zo/fuxZX2Pq+QNYrWgLXRgdm4rpQM7pRqmMlIWxYXeEI4f1INvfFG/ZapvUR3VN3N2HKAc 4EpB77czVadqbjnGrFyqypjOafG0JcVhbNrhl15l7ZsURmL7BQ1UFbODUIMGZup+mAYRjTtWp3pqycBOXYkCyxvDGGmp9LN4FwoCmT0U/ci4IgrT99xpWS51 oDTNz24LzXMX0m6gFA2m2FZ0h9eL5ZXO79GWycoPyejG8TFINBWrldVW+vAhOyEYp5a/OyrGe5liWKGVyWDAQ5KMSVMicnMjff4hzG82ano= X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:16509, ipnet:3.96.0.0/15, country:US] X-Rspamd-Queue-Id: 4fRbDC0g5Wz3nYl X-Spamd-Bar: ---- Never mind. You fixed it already. -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org e**(i*pi)+1=0 In message <20260305161736.DE0812E2@slippy.cwsent.com>, Cy Schubert writes: > BTW, it's upsream's (NetBSD's) last two commits to their map.c that are the > offending commits. They're supposed to mitigate a memory leak but on > FreeBSD the commits do more than that. > > > -- > Cheers, > Cy Schubert > FreeBSD UNIX: Web: https://FreeBSD.org > NTP: Web: https://nwtime.org > > e**(i*pi)+1=0 > > > In message <20260305160448.CA4EF360@slippy.cwsent.com>, Cy Schubert writes: > > This breaks exec(1) builtin. > > > > For instance, > > > > exec csh > > exec bash > > exec some_other_app > > > > All the above result in /bin/sh segfaulting at map.c:968. > > > > > > -- > > Cheers, > > Cy Schubert > > FreeBSD UNIX: Web: https://FreeBSD.org > > NTP: Web: https://nwtime.org > > > > e**(i*pi)+1=0 > > > > In message <69a92e32.1f40f.65c93a59@gitrepo.freebsd.org>, Baptiste > > Daroussin wr > > ites: > > > The branch main has been updated by bapt: > > > > > > URL: https://cgit.FreeBSD.org/src/commit/?id=28ff4d35f8b904952bf86b326465 > 0d > > 91 > > > cc0cb5d7 > > > > > > commit 28ff4d35f8b904952bf86b3264650d91cc0cb5d7 > > > Merge: 1abb62867f2a b1ddc060e941 > > > Author: Baptiste Daroussin > > > AuthorDate: 2026-03-05 07:17:09 +0000 > > > Commit: Baptiste Daroussin > > > CommitDate: 2026-03-05 07:17:51 +0000 > > > > > > libedit: vendor import version 2026-03-04 > > > > > > MFC After: 1 week > > > > > > contrib/libedit/ChangeLog | 6123 +++++++++++++++++++++++++++++ > ++ > > ++ > > > +- > > > contrib/libedit/chared.c | 50 +- > > > contrib/libedit/chared.h | 22 +- > > > contrib/libedit/common.c | 12 +- > > > contrib/libedit/edit.expsym | 1 + > > > contrib/libedit/editline.3 | 38 +- > > > contrib/libedit/editline.7 | 10 +- > > > contrib/libedit/el.c | 30 +- > > > contrib/libedit/el.h | 3 +- > > > contrib/libedit/eln.c | 12 +- > > > contrib/libedit/emacs.c | 16 +- > > > contrib/libedit/hist.c | 10 +- > > > contrib/libedit/hist.h | 4 +- > > > contrib/libedit/histedit.h | 4 +- > > > contrib/libedit/history.c | 6 +- > > > contrib/libedit/makelist | 4 +- > > > contrib/libedit/map.c | 45 +- > > > contrib/libedit/map.h | 7 +- > > > contrib/libedit/readline.c | 16 +- > > > contrib/libedit/readline/readline.h | 3 +- > > > contrib/libedit/refresh.c | 14 +- > > > contrib/libedit/search.c | 7 +- > > > contrib/libedit/sig.c | 6 +- > > > contrib/libedit/terminal.c | 6 +- > > > contrib/libedit/vi.c | 14 +- > > > 25 files changed, 6358 insertions(+), 105 deletions(-) > > > > > > > > > > > > > > > From nobody Thu Mar 5 17:49:51 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRcW60qfQz6TQD8 for ; Thu, 05 Mar 2026 17:49:54 +0000 (UTC) (envelope-from shawn.webb@hardenedbsd.org) Received: from mail-ot1-x335.google.com (mail-ot1-x335.google.com [IPv6:2607:f8b0:4864:20::335]) (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 4fRcW56Lx8z3vcQ for ; Thu, 05 Mar 2026 17:49:53 +0000 (UTC) (envelope-from shawn.webb@hardenedbsd.org) Authentication-Results: mx1.freebsd.org; none Received: by mail-ot1-x335.google.com with SMTP id 46e09a7af769-7d4c3896e32so4672098a34.0 for ; Thu, 05 Mar 2026 09:49:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hardenedbsd.org; s=google; t=1772732992; x=1773337792; darn=freebsd.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=ZMBnwFdtbwEV59MpPwBswm8MRP35o4wwDus6WFw1l3k=; b=LUbbfNyuDGFYRmPwB5pQGDrWmYYYuc2YYhp+9oH1nKKffhF6ER1eaZ0/6dvL/nhZDi MVM1jAIYZWCKRHHd2Jy7mMkoI8bieHhan9kDClMviL6fv5i9S/1PWc+q8Y0h4UjVWXRD HnSY0Yk9tJj47Q52jnWIynygMglRzEz7FBLUUzURKM7qIEZeJgo2kHc0VH8IuXFdIdv4 O0hCpkOzj9iDuvix+Bi5RKmlR1dOW6N4KjuLUjwLbZC8jjBooQWc6ltE/Jm0CT8IkCxI TaHBeYmQy/YK7tRxnI00Y6GZ33yTxAuZlg3hTz2RUnEEgwsepKMKrHYjpg2zBXa94mWb PBFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772732992; x=1773337792; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ZMBnwFdtbwEV59MpPwBswm8MRP35o4wwDus6WFw1l3k=; b=hWNFd7Bumos0HbFYOkyYHfChUGMGPeZ3q1TTKkpVRnWPbiWKHk0UjAkZQezoHKhHIo ix82wPaI07EzUAeVqniuFl9IACU/zv6frjn11FCR+71EyuZ8ts3CZwZRsWnf88/kBqr4 Q4aecRW3is7dsDnXbR++BRkZmq9fH4Cs91tBB7+jrvtT1nf8FEr7t9bG8OLe1Ox+axZr /FzvgWJBzzo+3ztE0ol3B54BHqPX5zAyODHZcoatde/4zEfdfLx75yvharC9nG+MyPPQ arvCZb835DDYhaMKEC/IAJaFJqXnxSUtw16xXlEmaORZ4YVC3g1VfyonuJ+GcfSGmyGe zN7w== X-Forwarded-Encrypted: i=1; AJvYcCUiWi5FzKYwqczfAFHZJMjr+dDjvoFF2t8hruoJ/pLDNH6MAZXyZ5QE2iPWumvgQD6RfM8xPJ2S2948yTJ7N7p1gQndGg==@freebsd.org X-Gm-Message-State: AOJu0Ywknz1cE4lZZMeSqf3J2DaexNOgL3L5PPI9r5DLAj2HI9XeKabm VSRFLH4KGiqjDf/yUawzG30PTUvuk7qS6+NpyuZm5i2Cb8IgPmEVSFucPneFALz5qCs= X-Gm-Gg: ATEYQzx3uq9jFc5UwoM/2m/5l9cwkYK75740eqKVy6exaEGE0/ghQJSpKPyG5sPsce1 eVNjBAf7IJtwAY1yyQb/nHoj5cCXWVrOkzb2zunThRDa1X36sG+25A8azvZ152YuNnP9hWkXzU9 4aEyQuStKv0HOeKgeIZWWva4muZUM0vqmUbUgdFzpnajKN6DP1h5GiFn+NOqH4fMRrHa0xuV/01 Jg3LWjSefE9m03pzm1ND/6/EcsN6JNYXBJkJfnjBj4vm2M989lkPscUKHWl5S/cfuwSeKuWDY1I m69JGC4vDepZwQ36FU+QbJC6Fsf15ZIk4dQsRt30+lwbmgaMGW0jqngKWaYlovMiUj9D9RC+UE8 SeJz1Ff7Hpn+RRd2wj82f0+5A/wrXtu/2VNHfuHGogu4+YOc/Q7CKG1iZa6xTH6rlK5kb+A/A+5 sa2/0x X-Received: by 2002:a05:6830:3902:b0:7cf:e4a1:8b56 with SMTP id 46e09a7af769-7d6da20ec7amr3779101a34.36.1772732991968; Thu, 05 Mar 2026 09:49:51 -0800 (PST) Received: from mutt-hbsd ([2001:470:4001:1::95]) by smtp.gmail.com with ESMTPSA id 46e09a7af769-7d5866269a8sm18563003a34.13.2026.03.05.09.49.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 Mar 2026 09:49:51 -0800 (PST) Date: Thu, 5 Mar 2026 17:49:51 +0000 From: Shawn Webb To: Baptiste Daroussin Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 6d2a147ae558 - main - libedit: fix use after free Message-ID: X-Operating-System: FreeBSD mutt-hbsd 15.0-STABLE-HBSD FreeBSD 15.0-STABLE-HBSD HARDENEDBSD amd64 X-PGP-Key: https://git.hardenedbsd.org/hardenedbsd/pubkeys/-/blob/master/Shawn_Webb/03A4CBEBB82EA5A67D9F3853FF2E67A277F8E1FA.pub.asc References: <69a9aba5.38ca9.25c6649c@gitrepo.freebsd.org> List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="ubs7vg3hq72cyggd" Content-Disposition: inline In-Reply-To: <69a9aba5.38ca9.25c6649c@gitrepo.freebsd.org> X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated 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-Queue-Id: 4fRcW56Lx8z3vcQ X-Spamd-Bar: ---- --ubs7vg3hq72cyggd Content-Type: text/plain; protected-headers=v1; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Subject: Re: git: 6d2a147ae558 - main - libedit: fix use after free MIME-Version: 1.0 On Thu, Mar 05, 2026 at 04:13:25PM +0000, Baptiste Daroussin wrote: > The branch main has been updated by bapt: >=20 > URL: https://cgit.FreeBSD.org/src/commit/?id=3D6d2a147ae558ef423e3df451a9= 049200b291a8d0 >=20 > commit 6d2a147ae558ef423e3df451a9049200b291a8d0 > Author: Baptiste Daroussin > AuthorDate: 2026-03-05 16:12:51 +0000 > Commit: Baptiste Daroussin > CommitDate: 2026-03-05 16:13:08 +0000 >=20 > libedit: fix use after free > --- > contrib/libedit/map.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) Hey Baptiste, UAF bugs are typically thought to be security issues. Does this particular fix warrant a security advisory? The log is unfortunately lacking much useful metadata usually included in these kinds of commits. Thanks, --=20 Shawn Webb Cofounder / Security Engineer HardenedBSD Signal Username: shawn_webb.74 Tor-ified Signal: +1 303-901-1600 / shawn_webb_opsec.50 https://git.hardenedbsd.org/hardenedbsd/pubkeys/-/raw/master/Shawn_Webb/03A= 4CBEBB82EA5A67D9F3853FF2E67A277F8E1FA.pub.asc --ubs7vg3hq72cyggd Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEA6TL67gupaZ9nzhT/y5nonf44foFAmmpwjEACgkQ/y5nonf4 4fpiuw//YUv9qJe9z5z7fSkbERGBGbPC61R/lSxBw9irXRdNjs2G+7fPKJkxiAak GDwMgfR+Ia62uv6vkBpxcU8NanTZ1GzhkZ1NFhlkw+BiD6D6ZRhPqEnaQNqIb2mi ii5pDUoNXrTEnMiGY+aQqZl9DHIJhsCpAzgcSin2fcByjDE9qRjM5823/fwpjDjw PGnBPWYjCaShiPocDoCa6Vvp7te71tHRmwoe8JFzIn6pgWooutdzhR80e7Ll/yFS FVoYdKnq6L92tNTchPwTOpCxNbocmGDH4jeRYxvNiOc6oI6NmrMN2tko38vaR79j F6c5lg4n07C0y48IVSPhEEpGs4cK+tJ6yNytM7AlzWzb/raWVSK7+E0GYjpcBuLx pIthcXloFHYBDVe/dSbouQV1f6NrVO5S/BT4pbQ+lMc3B4MEsktCtRbLDRWEz1Ul 3iVpJmHm5b5FxFkUay2L3JyCwAOHBAAZPfwIlc2POStJ2sGaoIpl76bGzUzWdbuN glE26BYcqUcMEOoWJnufkYt/T/ANX5ETFoxnQZrR3kihi6n03wECVs95lVFkdZiZ 7LV+yxpKnLEfcmUll6rtIU6K2tCpBq+rdQBS688aN8l0FTv47SsQQ4y7TtnH0xDW 4Jk3gM+AijYLBGHcEy9iDc8RcMV/JIF/kAOBVnDR0l62IG+ewmI= =A3t8 -----END PGP SIGNATURE----- --ubs7vg3hq72cyggd-- From nobody Thu Mar 5 18:22:47 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRdF42rbyz6TSdB for ; Thu, 05 Mar 2026 18:22: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRdF35Pnvz40QF for ; Thu, 05 Mar 2026 18:22:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772734967; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I5jyzw7PFH1ASOLGspyC5PQEylIrgHTUWgbKUgZcbLc=; b=iAxESbydY63pvy9nTfxhIIYw1EoAtVuYMAhGoK1g2sI6pKTcUbn517o67Zy2hsZDeo7x7V IrC3EvBYit8XREYPmsSSkbOYW5Wf6a4IFnM4KRIs5m0t6i/a/qcknE2cUThkcXMpqDB0ez gtM4s7n/PStBeQg4Pm/PYZpD9m4gQPqQGT8w0MHb8VOlHMzoBcvVN/ND4YhB/NHAf0rvqU B8RrDmr7Kq0GMqgrSxRy1JjWSVpt59hBBdyGeccdPwjI9K7OMAtJAXmOEw+8NoPCuFo422 q5RhkwzVKVOwLzMuz5FPRLViM+zyFBrEoUyjWSB1i1nNfvFG7iYB8QrN0I6utQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772734967; a=rsa-sha256; cv=none; b=TgfUh1ALErSX04SeRuupeEUEqcUKey9HPcDgi4uOmarkZaoB6aovx1pjbsvmU2L9iycI+9 BxC2pVPSAWleeAJ5Fr+7/Eu2wRk2nOFTdqC2KCVgWM1Uuphc/U5MKLjFLvWf2HW5DnktRK V4DTfduU11K9FXgUsqsg/2ONZrbNtTU8Dv08Fc24NuhSbx4DP/M3+OxQvQ2fbaD6SrJFqu nnxnBIvRoMZYgQUvwpooE+osC+Pwzww4uZwpwBPpD+9Z7J6YxLsJeBa7OUguPsMKORuSI0 UzLoOgD9xpCbyFu9nmYdJ8uOwJzxZEv8kruD+3gtsD82CRN68dApxTveTVPJpw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772734967; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I5jyzw7PFH1ASOLGspyC5PQEylIrgHTUWgbKUgZcbLc=; b=JNyimjAV+FgVk3VXTF4mDBfThC2zvtCHmZZinLcwl0+NucJ2GP2SeNOfaEKvqgGW27zT0g dF/aUddxSqTktrXdKPI+YscZjVxgAwKNzv5Cs3FDq/JMbNOxGonHNGTqy9hy7GRMt3mKz4 oCp7SxXG3PXYNwxzprKReK/cEKW8Ef2kekODTjoou3cXR08MRM5RvjB4NrS9RFiOKVZeEa NSBp5WZR8chbCAY8LtPClUVzKJ+86dzje0XIZz2x0tuIn6pdKjYH981rHsSYRhTiU5rpAu e6Xfpo7vwVjWGJi78yUrANE1AUbwHmG9E0A8aGJI+gPejZNtA11L6dtGKrkSOA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRdF3506PznlP for ; Thu, 05 Mar 2026 18:22:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 44455 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 18:22:47 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Pouria Mousavizadeh Tehrani Subject: git: 0616521adc35 - main - ndp: Simplify and breakdown nd6_ra_input() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pouria X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0616521adc35cb252cb399f1147f103284f0f188 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 18:22:47 +0000 Message-Id: <69a9c9f7.44455.6ac74e64@gitrepo.freebsd.org> The branch main has been updated by pouria: URL: https://cgit.FreeBSD.org/src/commit/?id=0616521adc35cb252cb399f1147f103284f0f188 commit 0616521adc35cb252cb399f1147f103284f0f188 Author: Pouria Mousavizadeh Tehrani AuthorDate: 2026-03-05 18:01:30 +0000 Commit: Pouria Mousavizadeh Tehrani CommitDate: 2026-03-05 18:04:32 +0000 ndp: Simplify and breakdown nd6_ra_input() `nd6_ra_input()` is simplied to make it easier to add additional options. Reviewed by: glebius Differential Revision: https://reviews.freebsd.org/D55267 --- sys/netinet6/nd6.c | 8 +- sys/netinet6/nd6_rtr.c | 300 +++++++++++++++++++++++++------------------------ 2 files changed, 158 insertions(+), 150 deletions(-) diff --git a/sys/netinet6/nd6.c b/sys/netinet6/nd6.c index f4e48eb57329..5b93c7f115e9 100644 --- a/sys/netinet6/nd6.c +++ b/sys/netinet6/nd6.c @@ -435,11 +435,11 @@ nd6_option(union nd_opts *ndopts) } olen = nd_opt->nd_opt_len << 3; + /* + * RFC 4861 section 6.1.2: All included options + * must have a length that is greater than zero. + */ if (olen == 0) { - /* - * Message validation requires that all included - * options have a length that is greater than zero. - */ bzero(ndopts, sizeof(*ndopts)); return NULL; } diff --git a/sys/netinet6/nd6_rtr.c b/sys/netinet6/nd6_rtr.c index ba2f025b7db1..6f415408daae 100644 --- a/sys/netinet6/nd6_rtr.c +++ b/sys/netinet6/nd6_rtr.c @@ -79,7 +79,7 @@ MALLOC_DEFINE(M_IP6NDP, "ip6ndp", "IPv6 Neighbor Discovery"); static struct nd_defrouter *defrtrlist_update(struct nd_defrouter *); static int prelist_update(struct nd_prefixctl *, struct nd_defrouter *, - struct mbuf *, int); + bool, int); static int nd6_prefix_onlink(struct nd_prefix *); static int in6_get_tmp_ifid(struct in6_aliasreq *); @@ -180,7 +180,7 @@ nd6_rs_input(struct mbuf *m, int off, int icmp6len) if (!V_ip6_forwarding || ifp->if_inet6->nd_flags & ND6_IFF_ACCEPT_RTADV) goto freeit; - /* RFC 6980: Nodes MUST silently ignore fragments */ + /* RFC 6980: Nodes MUST silently ignore fragments */ if(m->m_flags & M_FRAGMENTED) goto freeit; @@ -355,6 +355,127 @@ nd6_ifnet_link_event(void *arg __unused, struct ifnet *ifp, int linkstate) #endif } +static void +nd6_ra_opt_pi(struct nd_opt_hdr *pt, struct ifnet *ifp, + struct nd_router_advert *nd_ra, struct nd_defrouter *dr, + bool auth, bool mcast) +{ + struct nd_opt_prefix_info *pi = NULL; + struct nd_prefixctl pr; + char ip6bufs[INET6_ADDRSTRLEN]; + + if (pt->nd_opt_type != ND_OPT_PREFIX_INFORMATION) + return; + + pi = (struct nd_opt_prefix_info *)pt; + if (pi->nd_opt_pi_len != 4) { + nd6log((LOG_INFO, + "%s: invalid option len %d for prefix " + "information option, ignored\n", __func__, + pi->nd_opt_pi_len)); + return; + } + + if (pi->nd_opt_pi_prefix_len > 128) { + nd6log((LOG_INFO, + "%s: invalid prefix len %d for prefix " + "information option, ignored\n", __func__, + pi->nd_opt_pi_prefix_len)); + return; + } + + if (IN6_IS_ADDR_MULTICAST(&pi->nd_opt_pi_prefix) + || IN6_IS_ADDR_LINKLOCAL(&pi->nd_opt_pi_prefix)) { + nd6log((LOG_INFO, + "%s: invalid prefix %s, ignored\n", + __func__, ip6_sprintf(ip6bufs, + &pi->nd_opt_pi_prefix))); + return; + } + + bzero(&pr, sizeof(pr)); + pr.ndpr_prefix.sin6_family = AF_INET6; + pr.ndpr_prefix.sin6_len = sizeof(pr.ndpr_prefix); + pr.ndpr_prefix.sin6_addr = pi->nd_opt_pi_prefix; + pr.ndpr_ifp = ifp; + + pr.ndpr_raf_onlink = (pi->nd_opt_pi_flags_reserved & + ND_OPT_PI_FLAG_ONLINK) ? 1 : 0; + pr.ndpr_raf_auto = (pi->nd_opt_pi_flags_reserved & + ND_OPT_PI_FLAG_AUTO) ? 1 : 0; + pr.ndpr_plen = pi->nd_opt_pi_prefix_len; + pr.ndpr_vltime = ntohl(pi->nd_opt_pi_valid_time); + pr.ndpr_pltime = ntohl(pi->nd_opt_pi_preferred_time); + (void)prelist_update(&pr, dr, auth, mcast); +} + +static void +nd6_ra_opt_mtu(struct nd_opt_mtu *optmtu, struct ifnet *ifp, + struct in6_addr saddr6) +{ + struct in6_ifextra *ndi; + char ip6bufs[INET6_ADDRSTRLEN]; + uint32_t mtu, maxmtu; + + ndi = ifp->if_inet6; + + if (optmtu->nd_opt_mtu_len != 1) + return; + mtu = (uint32_t)ntohl(optmtu->nd_opt_mtu_mtu); + /* lower bound */ + if (mtu < IPV6_MMTU) { + nd6log((LOG_INFO, "%s: bogus mtu option mtu=%u sent from %s, " + "ignoring\n", __func__, mtu, ip6_sprintf(ip6bufs, &saddr6))); + return; + } + + /* upper bound */ + maxmtu = (ndi->nd_maxmtu && ndi->nd_maxmtu < ifp->if_mtu) + ? ndi->nd_maxmtu : ifp->if_mtu; + if (mtu <= maxmtu) { + if (ndi->nd_linkmtu != mtu) { + ndi->nd_linkmtu = mtu; + rt_updatemtu(ifp); + } + } else { + nd6log((LOG_INFO, "%s: bogus mtu=%u sent from %s; " + "exceeds maxmtu %u, ignoring\n", __func__, + mtu, ip6_sprintf(ip6bufs, &saddr6), maxmtu)); + } +} + +static int +nd6_ra_opt_src_lladdr(struct nd_opt_hdr *opthdr, struct ifnet *ifp, + struct in6_addr saddr6) +{ + char ip6bufs[INET6_ADDRSTRLEN]; + char *lladdr = NULL; + int lladdrlen = 0; + + if (opthdr != NULL) { + lladdr = (char *)(opthdr + 1); + lladdrlen = opthdr->nd_opt_len << 3; + } + + if (lladdr && ((ifp->if_addrlen + 2 + 7) & ~7) != lladdrlen) { + nd6log((LOG_INFO, + "%s: lladdrlen mismatch for %s (if %d, RA packet %d)\n", + __func__, ip6_sprintf(ip6bufs, &saddr6), + ifp->if_addrlen, lladdrlen - 2)); + return (-1); + } + + nd6_cache_lladdr(ifp, &saddr6, lladdr, lladdrlen, ND_ROUTER_ADVERT, 0); + + /* + * Installing a link-layer address might change the state of the + * router's neighbor cache, which might also affect our on-link + * detection of adveritsed prefixes. + */ + pfxlist_onlink_check(); + return (0); +} + /* * Receive Router Advertisement Message. * @@ -369,11 +490,13 @@ nd6_ra_input(struct mbuf *m, int off, int icmp6len) struct in6_ifextra *ndi; struct ip6_hdr *ip6; struct nd_router_advert *nd_ra; + struct nd_opt_hdr *pt; struct in6_addr saddr6; - struct nd_defrouter *dr; + struct nd_defrouter dr0, *dr; union nd_opts ndopts; char ip6bufs[INET6_ADDRSTRLEN], ip6bufd[INET6_ADDRSTRLEN]; - int mcast; + uint32_t advreachable; + bool mcast, auth; /* * We only accept RAs only when the per-interface flag @@ -389,6 +512,7 @@ nd6_ra_input(struct mbuf *m, int off, int icmp6len) goto freeit; ip6 = mtod(m, struct ip6_hdr *); + /* RFC 4861 section 6.1.2: hlim must be 255 */ if (__predict_false(ip6->ip6_hlim != 255)) { ICMP6STAT_INC(icp6s_invlhlim); nd6log((LOG_ERR, @@ -399,6 +523,7 @@ nd6_ra_input(struct mbuf *m, int off, int icmp6len) } saddr6 = ip6->ip6_src; + /* RFC 4861 section 6.1.2: source address must be link-local */ if (!IN6_IS_ADDR_LINKLOCAL(&saddr6)) { nd6log((LOG_ERR, "%s: src %s is not link-local\n", __func__, @@ -413,7 +538,6 @@ nd6_ra_input(struct mbuf *m, int off, int icmp6len) return; } } - ip6 = mtod(m, struct ip6_hdr *); nd_ra = (struct nd_router_advert *)((caddr_t)ip6 + off); icmp6len -= sizeof(*nd_ra); @@ -425,15 +549,11 @@ nd6_ra_input(struct mbuf *m, int off, int icmp6len) goto freeit; } - mcast = 0; dr = NULL; - { - struct nd_defrouter dr0; - u_int32_t advreachable = nd_ra->nd_ra_reachable; - + mcast = false; /* remember if this is a multicasted advertisement */ if (IN6_IS_ADDR_MULTICAST(&ip6->ip6_dst)) - mcast = 1; + mcast = true; bzero(&dr0, sizeof(dr0)); dr0.rtaddr = saddr6; @@ -443,17 +563,20 @@ nd6_ra_input(struct mbuf *m, int off, int icmp6len) * ND6_IFF_NO_RADR enabled on the receiving interface or * (ip6.forwarding == 1 && ip6.rfc6204w3 != 1). */ - if (ndi->nd_flags & ND6_IFF_NO_RADR) - dr0.rtlifetime = 0; - else if (V_ip6_forwarding && !V_ip6_rfc6204w3) + if ((ndi->nd_flags & ND6_IFF_NO_RADR) || + (V_ip6_forwarding && !V_ip6_rfc6204w3)) dr0.rtlifetime = 0; else dr0.rtlifetime = ntohs(nd_ra->nd_ra_router_lifetime); dr0.expire = time_uptime + dr0.rtlifetime; dr0.ifp = ifp; - /* unspecified or not? (RFC 2461 6.3.4) */ - if (advreachable) { - advreachable = ntohl(advreachable); + /* + * RFC 4861 6.3.4: RA fields such as Cur Hop Limit, + * Reachable Time, and Retrans Timer may be unspecified. + * In such cases, the parameter should be ignored. + */ + if (nd_ra->nd_ra_reachable) { + advreachable = ntohl(nd_ra->nd_ra_reachable); if (advreachable <= MAX_REACHABLE_TIME && ndi->nd_basereachable != advreachable) { ndi->nd_basereachable = advreachable; @@ -479,63 +602,18 @@ nd6_ra_input(struct mbuf *m, int off, int icmp6len) #ifdef EXPERIMENTAL defrtr_ipv6_only_ifp(ifp); #endif - } - - /* - * prefix - */ - if (ndopts.nd_opts_pi) { - struct nd_opt_hdr *pt; - struct nd_opt_prefix_info *pi = NULL; - struct nd_prefixctl pr; - + /* Prefix Information */ + if (ndopts.nd_opts_pi != NULL) { + /* + * Authenticity for NA consists authentication for + * both IP header and IP datagrams, doesn't it ? + */ + auth = ((m->m_flags & M_AUTHIPHDR) && (m->m_flags & M_AUTHIPDGM)); for (pt = (struct nd_opt_hdr *)ndopts.nd_opts_pi; pt <= (struct nd_opt_hdr *)ndopts.nd_opts_pi_end; pt = (struct nd_opt_hdr *)((caddr_t)pt + (pt->nd_opt_len << 3))) { - if (pt->nd_opt_type != ND_OPT_PREFIX_INFORMATION) - continue; - pi = (struct nd_opt_prefix_info *)pt; - - if (pi->nd_opt_pi_len != 4) { - nd6log((LOG_INFO, - "%s: invalid option len %d for prefix " - "information option, ignored\n", __func__, - pi->nd_opt_pi_len)); - continue; - } - - if (128 < pi->nd_opt_pi_prefix_len) { - nd6log((LOG_INFO, - "%s: invalid prefix len %d for prefix " - "information option, ignored\n", __func__, - pi->nd_opt_pi_prefix_len)); - continue; - } - - if (IN6_IS_ADDR_MULTICAST(&pi->nd_opt_pi_prefix) - || IN6_IS_ADDR_LINKLOCAL(&pi->nd_opt_pi_prefix)) { - nd6log((LOG_INFO, - "%s: invalid prefix %s, ignored\n", - __func__, ip6_sprintf(ip6bufs, - &pi->nd_opt_pi_prefix))); - continue; - } - - bzero(&pr, sizeof(pr)); - pr.ndpr_prefix.sin6_family = AF_INET6; - pr.ndpr_prefix.sin6_len = sizeof(pr.ndpr_prefix); - pr.ndpr_prefix.sin6_addr = pi->nd_opt_pi_prefix; - pr.ndpr_ifp = (struct ifnet *)m->m_pkthdr.rcvif; - - pr.ndpr_raf_onlink = (pi->nd_opt_pi_flags_reserved & - ND_OPT_PI_FLAG_ONLINK) ? 1 : 0; - pr.ndpr_raf_auto = (pi->nd_opt_pi_flags_reserved & - ND_OPT_PI_FLAG_AUTO) ? 1 : 0; - pr.ndpr_plen = pi->nd_opt_pi_prefix_len; - pr.ndpr_vltime = ntohl(pi->nd_opt_pi_valid_time); - pr.ndpr_pltime = ntohl(pi->nd_opt_pi_preferred_time); - (void)prelist_update(&pr, dr, m, mcast); + nd6_ra_opt_pi(pt, ifp, nd_ra, dr, auth, mcast); } } if (dr != NULL) { @@ -543,70 +621,13 @@ nd6_ra_input(struct mbuf *m, int off, int icmp6len) dr = NULL; } - /* - * MTU - */ - if (ndopts.nd_opts_mtu && ndopts.nd_opts_mtu->nd_opt_mtu_len == 1) { - u_long mtu; - u_long maxmtu; - - mtu = (u_long)ntohl(ndopts.nd_opts_mtu->nd_opt_mtu_mtu); - - /* lower bound */ - if (mtu < IPV6_MMTU) { - nd6log((LOG_INFO, "%s: bogus mtu option mtu=%lu sent " - "from %s, ignoring\n", __func__, - mtu, ip6_sprintf(ip6bufs, &ip6->ip6_src))); - goto skip; - } - - /* upper bound */ - maxmtu = (ndi->nd_maxmtu && ndi->nd_maxmtu < ifp->if_mtu) - ? ndi->nd_maxmtu : ifp->if_mtu; - if (mtu <= maxmtu) { - if (ndi->nd_linkmtu != mtu) { - ndi->nd_linkmtu = mtu; - rt_updatemtu(ifp); - } - } else { - nd6log((LOG_INFO, "%s: bogus mtu=%lu sent from %s; " - "exceeds maxmtu %lu, ignoring\n", __func__, - mtu, ip6_sprintf(ip6bufs, &ip6->ip6_src), maxmtu)); - } - } - - skip: + /* MTU */ + if (ndopts.nd_opts_mtu != NULL) + nd6_ra_opt_mtu(ndopts.nd_opts_mtu, ifp, saddr6); - /* - * Source link layer address - */ - { - char *lladdr = NULL; - int lladdrlen = 0; - - if (ndopts.nd_opts_src_lladdr) { - lladdr = (char *)(ndopts.nd_opts_src_lladdr + 1); - lladdrlen = ndopts.nd_opts_src_lladdr->nd_opt_len << 3; - } - - if (lladdr && ((ifp->if_addrlen + 2 + 7) & ~7) != lladdrlen) { - nd6log((LOG_INFO, - "%s: lladdrlen mismatch for %s (if %d, RA packet %d)\n", - __func__, ip6_sprintf(ip6bufs, &saddr6), - ifp->if_addrlen, lladdrlen - 2)); + /* Source link layer address */ + if (nd6_ra_opt_src_lladdr(ndopts.nd_opts_src_lladdr, ifp, saddr6) != 0) goto bad; - } - - nd6_cache_lladdr(ifp, &saddr6, lladdr, - lladdrlen, ND_ROUTER_ADVERT, 0); - - /* - * Installing a link-layer address might change the state of the - * router's neighbor cache, which might also affect our on-link - * detection of adveritsed prefixes. - */ - pfxlist_onlink_check(); - } freeit: m_freem(m); @@ -1478,32 +1499,19 @@ nd6_prefix_del(struct nd_prefix *pr) static int prelist_update(struct nd_prefixctl *new, struct nd_defrouter *dr, - struct mbuf *m, int mcast) + bool auth, int mcast) { struct in6_ifaddr *ia6 = NULL, *ia6_match = NULL; struct ifaddr *ifa; struct ifnet *ifp = new->ndpr_ifp; struct nd_prefix *pr; int error = 0; - int auth; struct in6_addrlifetime lt6_tmp; char ip6buf[INET6_ADDRSTRLEN]; bool has_temporary = false; NET_EPOCH_ASSERT(); - auth = 0; - if (m) { - /* - * Authenticity for NA consists authentication for - * both IP header and IP datagrams, doesn't it ? - */ -#if defined(M_AUTHIPHDR) && defined(M_AUTHIPDGM) - auth = ((m->m_flags & M_AUTHIPHDR) && - (m->m_flags & M_AUTHIPDGM)); -#endif - } - if ((pr = nd6_prefix_lookup(new)) != NULL) { /* * nd6_prefix_lookup() ensures that pr and new have the same From nobody Thu Mar 5 18:22:46 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRdF30y54z6TSRP for ; Thu, 05 Mar 2026 18:22: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRdF24ZDfz40SR for ; Thu, 05 Mar 2026 18:22:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772734966; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=vSL3LrhXzqX7uLPDxEfj+aEvoWhYST/KVvjbBRb76tw=; b=FMgGqaEAN6AuKBlM1DSbUCoLwitIRNteMBlHjIxpIokMzaxheHCC3aVNNdaWHltqrbw6uU MTIiwOwghnB+2k6uf1xdrZUFN1ErJM+B+8j2/VhtsOXNbc7RzL/8fKtFREDqZ/z+suUjhA AxZ4c68Tfnu5pOyiXb/Hm3BhNCP7ZtvgXOTBWtb4kiHnH6CaUlO0XXaAkG/8ca82s4YTKD 4Rm9U7spF+e14nPfuqzLqGGdAs7XeOk1jp3sM/7rPD86F0+zfXmvCy+KwuOzvP7YdRZxPa OEDaEozdhWx41/tSlPJ0nfjGY8Az4+UNtQoqpm8xnUgNPZy0bAQTOMr83Fr27w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772734966; a=rsa-sha256; cv=none; b=vEr3IfqVQ1w5Kro274u72jouYBIijDRBDm/oczAxiTi93LN2w04Js4aQEGBKbrdJM/qNIM e6ATUYaXR1ixX0/VPo8vE5MfMucssn+/C2yjnzKpqx0tqqVwpU4YHdquQ4rONIuYBPkzgN 0aX7YHmFGBlF6Y79H4bmcaJ9Dot+tN92IPTUTZV38PhrGDO+AZWRYdyC5hqvsnnf7W1OjO IYvdSq32C5Gn7cAbfaNITUuCvSHN57Pf8XU2NbmZgIohWIlubbL5PtvjmDmbbq2cvqGkMj NCIStikTjSQfVzLOviEE2igqT37odKUo9/8I45zx0UJEgwueDF1t6nl6Mfwz7A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772734966; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=vSL3LrhXzqX7uLPDxEfj+aEvoWhYST/KVvjbBRb76tw=; b=xQsxm9sdO37qjb7DGht3a2Dof0LE/xs5UTTDcPqnueCY4+hI1MEeSYTcgdxvwQTc4/HD/o +DILfYMODL10pXDzRzhM3VFmCVUPQw0qjODyw+d+DhVbDjTm1ipNPWJA79XzieCVtreweF vok93Dia5S8jH3zDmNAt7xRVFdLL/zseWF9ZH2YT908FDnL/TPbdfHhUwruvFrhczQ0fAf VepO1E7hTNfbgo7OInoCZ00bQSuvFeZUgKTKHpvYV5ifY5ZWHTSFVl1lJ3V/UreOV5BYPY mGFNLN0d8hhV475ZmkfQZ4ThLuR/0DGnJsM9kL0IplcS6J7ro2LxMh5GzuLyNA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRdF2493PzpD1 for ; Thu, 05 Mar 2026 18:22:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 43378 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 18:22:46 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Pouria Mousavizadeh Tehrani Subject: git: 7f3b46fe54f1 - main - ndp: Add support for Gratuitous Neighbor Discovery (GRAND) List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pouria X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7f3b46fe54f16b24e9ce33294fb805f6e7f785c9 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 18:22:46 +0000 Message-Id: <69a9c9f6.43378.5de25b54@gitrepo.freebsd.org> The branch main has been updated by pouria: URL: https://cgit.FreeBSD.org/src/commit/?id=7f3b46fe54f16b24e9ce33294fb805f6e7f785c9 commit 7f3b46fe54f16b24e9ce33294fb805f6e7f785c9 Author: Pouria Mousavizadeh Tehrani AuthorDate: 2026-03-05 17:58:14 +0000 Commit: Pouria Mousavizadeh Tehrani CommitDate: 2026-03-05 17:58:38 +0000 ndp: Add support for Gratuitous Neighbor Discovery (GRAND) Implement RFC 4861 Section 7.2.6 and RFC 9131, which is also address one of the IPv6 deployment issues in RFC 9898 Section 3.9. GRAND should be triggered by a change in link-layer address of interface or by configuration of a new global ipv6 address after DAD completes. Reviewed by: glebius Differential Revision: https://reviews.freebsd.org/D55015 --- share/man/man4/inet6.4 | 13 +++- sys/netinet6/in6.c | 3 + sys/netinet6/in6.h | 3 +- sys/netinet6/in6_proto.c | 4 + sys/netinet6/in6_var.h | 1 + sys/netinet6/ip6_var.h | 2 + sys/netinet6/nd6.c | 23 ++++++ sys/netinet6/nd6.h | 7 ++ sys/netinet6/nd6_nbr.c | 185 +++++++++++++++++++++++++++++++++++++++++++++++ 9 files changed, 239 insertions(+), 2 deletions(-) diff --git a/share/man/man4/inet6.4 b/share/man/man4/inet6.4 index 21bae5255d66..20d32e03ec60 100644 --- a/share/man/man4/inet6.4 +++ b/share/man/man4/inet6.4 @@ -27,7 +27,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd February 22, 2023 +.Dd January 31, 2026 .Dt INET6 4 .Os .Sh NAME @@ -295,6 +295,17 @@ probe packets. The packets will be generated when .Tn IPv6 interface addresses are configured. +.It Dv IPV6CTL_GRAND_COUNT +.Pq ip6.grand_count +Integer: default number of +.Tn IPv6 +GRAND +.Pq gratuitous neighbor discovery +unsolicited NA packets. +The packets will be generated when +.Tn IPv6 +interface addresses are configured or when there are changes to +link-layer interface addresses. .It Dv IPV6CTL_AUTO_FLOWLABEL .Pq ip6.auto_flowlabel Boolean: enable/disable automatic filling of diff --git a/sys/netinet6/in6.c b/sys/netinet6/in6.c index e1504400d55b..eb6c327de76f 100644 --- a/sys/netinet6/in6.c +++ b/sys/netinet6/in6.c @@ -1432,6 +1432,9 @@ in6_purgeaddr(struct ifaddr *ifa) ia->ia_flags &= ~IFA_RTSELF; } + /* make sure there are no queued ND6 */ + nd6_queue_stop(ifa); + /* stop DAD processing */ nd6_dad_stop(ifa); diff --git a/sys/netinet6/in6.h b/sys/netinet6/in6.h index f250d7e49982..1206960357da 100644 --- a/sys/netinet6/in6.h +++ b/sys/netinet6/in6.h @@ -643,7 +643,8 @@ struct ip6_mtuinfo { * queue */ #define IPV6CTL_MAXFRAGSPERPACKET 53 /* Max fragments per packet */ #define IPV6CTL_MAXFRAGBUCKETSIZE 54 /* Max reassembly queues per bucket */ -#define IPV6CTL_MAXID 55 +#define IPV6CTL_GRAND_COUNT 55 +#define IPV6CTL_MAXID 56 #endif /* __BSD_VISIBLE */ /* diff --git a/sys/netinet6/in6_proto.c b/sys/netinet6/in6_proto.c index dbbe7c4b3eca..560698a5e6ad 100644 --- a/sys/netinet6/in6_proto.c +++ b/sys/netinet6/in6_proto.c @@ -156,6 +156,7 @@ VNET_DEFINE(int, ip6_rfc6204w3) = 0; VNET_DEFINE(int, ip6_hdrnestlimit) = 15;/* How many header options will we * process? */ VNET_DEFINE(int, ip6_dad_count) = 1; /* DupAddrDetectionTransmits */ +VNET_DEFINE(int, ip6_grand_count) = MAX_NEIGHBOR_ADVERTISEMENT; VNET_DEFINE(int, ip6_auto_flowlabel) = 1; VNET_DEFINE(int, ip6_use_deprecated) = 1;/* allow deprecated addr * (RFC2462 5.5.4) */ @@ -291,6 +292,9 @@ SYSCTL_INT(_net_inet6_ip6, IPV6CTL_HDRNESTLIMIT, hdrnestlimit, SYSCTL_INT(_net_inet6_ip6, IPV6CTL_DAD_COUNT, dad_count, CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_dad_count), 0, "Number of ICMPv6 NS messages sent during duplicate address detection"); +SYSCTL_INT(_net_inet6_ip6, IPV6CTL_GRAND_COUNT, grand_count, + CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_grand_count), 0, + "Number of ICMPv6 NA messages sent by gratuitous ND per interface"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_AUTO_FLOWLABEL, auto_flowlabel, CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_auto_flowlabel), 0, "Provide an IPv6 flowlabel in outbound packets"); diff --git a/sys/netinet6/in6_var.h b/sys/netinet6/in6_var.h index 057cd84b6ea7..b1209a324cc9 100644 --- a/sys/netinet6/in6_var.h +++ b/sys/netinet6/in6_var.h @@ -505,6 +505,7 @@ struct in6_ifextra { int nd_recalc_timer; u_int nd_dad_failures; uint8_t nd_curhoplimit; + TAILQ_HEAD(, nd_queue) nd_queue; struct mld_ifsoftc { /* Timers and invervals measured in seconds. */ diff --git a/sys/netinet6/ip6_var.h b/sys/netinet6/ip6_var.h index 6c5604a2a562..002b07e85434 100644 --- a/sys/netinet6/ip6_var.h +++ b/sys/netinet6/ip6_var.h @@ -319,6 +319,7 @@ VNET_DECLARE(int, ip6_rfc6204w3); /* Accept defroute from RA even when VNET_DECLARE(int, ip6_hdrnestlimit); /* upper limit of # of extension * headers */ VNET_DECLARE(int, ip6_dad_count); /* DupAddrDetectionTransmits */ +VNET_DECLARE(int, ip6_grand_count); /* Gratuitous ND Transmits */ #define V_ip6_sendredirects VNET(ip6_sendredirects) #define V_ip6_accept_rtadv VNET(ip6_accept_rtadv) #define V_ip6_no_radr VNET(ip6_no_radr) @@ -326,6 +327,7 @@ VNET_DECLARE(int, ip6_dad_count); /* DupAddrDetectionTransmits */ #define V_ip6_rfc6204w3 VNET(ip6_rfc6204w3) #define V_ip6_hdrnestlimit VNET(ip6_hdrnestlimit) #define V_ip6_dad_count VNET(ip6_dad_count) +#define V_ip6_grand_count VNET(ip6_grand_count) VNET_DECLARE(int, ip6_auto_flowlabel); VNET_DECLARE(int, ip6_auto_linklocal); diff --git a/sys/netinet6/nd6.c b/sys/netinet6/nd6.c index 969b32032a60..f4e48eb57329 100644 --- a/sys/netinet6/nd6.c +++ b/sys/netinet6/nd6.c @@ -221,11 +221,28 @@ nd6_lle_event(void *arg __unused, struct llentry *lle, int evt) static void nd6_iflladdr(void *arg __unused, struct ifnet *ifp) { + struct ifaddr *ifa; + struct epoch_tracker et; + /* XXXGL: ??? */ if (ifp->if_inet6 == NULL) return; lltable_update_ifaddr(LLTABLE6(ifp)); + + if ((ifp->if_flags & IFF_UP) == 0) + return; + + /* + * Sends gratuitous NAs for each ifaddr to notify other + * nodes about the address change. + */ + NET_EPOCH_ENTER(et); + CK_STAILQ_FOREACH(ifa, &ifp->if_addrhead, ifa_link) { + if (ifa->ifa_addr->sa_family == AF_INET6) + nd6_grand_start(ifa, ND6_QUEUE_FLAG_LLADDR); + } + NET_EPOCH_EXIT(et); } void @@ -321,6 +338,9 @@ nd6_ifattach(struct ifnet *ifp) /* If we globally accept rtadv, assume IPv6 on. */ nd->nd_flags &= ~ND6_IFF_IFDISABLED; } + + /* nd6 queue initialization */ + TAILQ_INIT(&nd->nd_queue); } void @@ -334,6 +354,9 @@ nd6_ifdetach(struct ifnet *ifp) if (ifa->ifa_addr->sa_family != AF_INET6) continue; + /* make sure there are no queued ND6 */ + nd6_queue_stop(ifa); + /* stop DAD processing */ nd6_dad_stop(ifa); } diff --git a/sys/netinet6/nd6.h b/sys/netinet6/nd6.h index a22a0e24735b..eca9f6262568 100644 --- a/sys/netinet6/nd6.h +++ b/sys/netinet6/nd6.h @@ -152,6 +152,10 @@ struct in6_ndifreq { #define ND6_NA_OPT_LLA 0x01 #define ND6_NA_CARP_MASTER 0x02 +/* ND6 queue flags */ +#define ND6_QUEUE_FLAG_NEWGUA 0x01 /* new global unicast address event */ +#define ND6_QUEUE_FLAG_LLADDR 0x02 /* link-layer address change event */ + /* protocol constants */ #define MAX_RTR_SOLICITATION_DELAY 1 /* 1sec */ #define RTR_SOLICITATION_INTERVAL 4 /* 4sec */ @@ -173,6 +177,7 @@ struct in6_ndifreq { #define ND_COMPUTE_RTIME(x) \ (((MIN_RANDOM_FACTOR * (x >> 10)) + (arc4random() & \ ((MAX_RANDOM_FACTOR - MIN_RANDOM_FACTOR) * (x >> 10)))) /1000) +#define MAX_NEIGHBOR_ADVERTISEMENT 3 /* RFC4891 Section 10 */ struct nd_defrouter { TAILQ_ENTRY(nd_defrouter) dr_entry; @@ -366,6 +371,8 @@ caddr_t nd6_ifptomac(struct ifnet *); void nd6_dad_init(void); void nd6_dad_start(struct ifaddr *, int); void nd6_dad_stop(struct ifaddr *); +void nd6_grand_start(struct ifaddr *, uint32_t); +void nd6_queue_stop(struct ifaddr *); /* nd6_rtr.c */ void nd6_rs_input(struct mbuf *, int, int); diff --git a/sys/netinet6/nd6_nbr.c b/sys/netinet6/nd6_nbr.c index 4da62575eaac..6a1f29c31eed 100644 --- a/sys/netinet6/nd6_nbr.c +++ b/sys/netinet6/nd6_nbr.c @@ -121,6 +121,13 @@ SYSCTL_INT(_net_inet6_icmp6, ICMPV6CTL_ND6_ONLINKNSRFC4861, &VNET_NAME(nd6_onlink_ns_rfc4861), 0, "Accept 'on-link' ICMPv6 NS messages in compliance with RFC 4861"); +struct nd_queue { + TAILQ_ENTRY(nd_queue) ndq_list; + struct ifaddr *ndq_ifa; + uint32_t ndq_flags; + struct callout ndq_callout; +}; + /* * Input a Neighbor Solicitation Message. * @@ -1464,6 +1471,12 @@ nd6_dad_timer(void *arg) ia->ia6_flags &= ~IN6_IFF_TENTATIVE; if ((ifp->if_inet6->nd_flags & ND6_IFF_STABLEADDR) && !(ia->ia6_flags & IN6_IFF_TEMPORARY)) atomic_store_int(&DAD_FAILURES(ifp), 0); + /* + * RFC 9131 Section 6.1.2: The first advertisement + * SHOULD be sent as soon as an address changes the + * state from tentative to preferred. + */ + nd6_grand_start(ifa, ND6_QUEUE_FLAG_NEWGUA); } nd6log((LOG_DEBUG, @@ -1632,3 +1645,175 @@ nd6_dad_na_input(struct ifaddr *ifa) dp->dad_na_icount++; DADQ_RUNLOCK(); } + +static void +nd6_queue_rel(void *arg) +{ + struct nd_queue *ndq = arg; + struct ifnet *ifp = ndq->ndq_ifa->ifa_ifp; + + IF_ADDR_WLOCK_ASSERT(ifp); + + /* Remove ndq from the nd_queue and release its reference */ + TAILQ_REMOVE(&ifp->if_inet6->nd_queue, ndq, ndq_list); + IF_ADDR_WUNLOCK(ifp); + + ifa_free(ndq->ndq_ifa); + free(ndq, M_IP6NDP); +} + +static void +nd6_queue_timer(void *arg) +{ + struct nd_queue *ndq = arg; + struct ifaddr *ifa = ndq->ndq_ifa; + struct ifnet *ifp = ifa->ifa_ifp; + struct in6_ifextra *ext = ifp->if_inet6; + struct in6_addr taddr6 = IN6ADDR_ANY_INIT; + struct epoch_tracker et; + int delay, tlladdr; + u_long flags; + + KASSERT(ifa != NULL, ("ND6 queue entry %p with no address", ndq)); + + CURVNET_SET(ifp->if_vnet); + NET_EPOCH_ENTER(et); + + tlladdr = ND6_NA_OPT_LLA; + flags = (V_ip6_forwarding) ? ND_NA_FLAG_ROUTER : 0; + if ((ext->nd_flags & ND6_IFF_ACCEPT_RTADV) != 0 && V_ip6_norbit_raif) + flags &= ~ND_NA_FLAG_ROUTER; + + /* + * RFC 9131 Section 6.1.2: if new global address added, + * use the all-routers multicast address. + * If the address is preferred, then the Override flag SHOULD NOT be set. + */ + if ((ndq->ndq_flags & ND6_QUEUE_FLAG_NEWGUA) != 0) { + taddr6 = in6addr_linklocal_allrouters; + /* + * XXX: If the address is in the Optimistic state, + * then the Override flag MUST NOT be set. + * We don't support RFC 4429 yet. + */ + if ((ext->nd_flags & ND6_IFF_PREFER_SOURCE) == 0) + flags |= ND_NA_FLAG_OVERRIDE; + } + /* + * RFC 4891 Section 7.2.6: if link-layer address changed, + * use the all-nodes multicast address. + * The Override flag MAY be set to either zero or one. + */ + if ((ndq->ndq_flags & ND6_QUEUE_FLAG_LLADDR) != 0) { + taddr6 = in6addr_linklocal_allnodes; + flags |= ND_NA_FLAG_OVERRIDE; + } + + /* Wait at least a RetransTimer before removing from queue */ + delay = ext->nd_retrans * hz / 1000; + callout_reset(&ndq->ndq_callout, delay, nd6_queue_rel, ndq); + IF_ADDR_WUNLOCK(ifp); + + if (__predict_true(in6_setscope(&taddr6, ifp, NULL) == 0)) + nd6_na_output_fib(ifp, &taddr6, IFA_IN6(ifa), flags, tlladdr, NULL, ifp->if_fib); + + NET_EPOCH_EXIT(et); + CURVNET_RESTORE(); +} + +static void +nd6_queue_add(struct ifaddr *ifa, int delay, uint32_t flags) +{ + struct nd_queue *ndq; + struct ifnet *ifp = ifa->ifa_ifp; + struct in6_ifaddr *ia = (struct in6_ifaddr *)ifa; + struct in6_ifextra *ext = ifp->if_inet6; + char ip6buf[INET6_ADDRSTRLEN]; + + NET_EPOCH_ASSERT(); + + ndq = malloc(sizeof(*ndq), M_IP6NDP, M_NOWAIT | M_ZERO); + if (ndq == NULL) { + log(LOG_ERR, "nd6_queue_add: memory allocation failed for " + "%s(%s)\n", + ip6_sprintf(ip6buf, &ia->ia_addr.sin6_addr), + ifp ? if_name(ifp) : "???"); + return; + } + + IF_ADDR_WLOCK(ifa->ifa_ifp); + callout_init_mtx(&ndq->ndq_callout, &ifp->if_addr_lock, + CALLOUT_TRYLOCK | CALLOUT_RETURNUNLOCKED); + nd6log((LOG_DEBUG, "%s: send delayed IPv6 ND for %s\n", if_name(ifp), + ip6_sprintf(ip6buf, &ia->ia_addr.sin6_addr))); + + ndq->ndq_ifa = ifa; + ifa_ref(ndq->ndq_ifa); + ndq->ndq_flags = flags; + + TAILQ_INSERT_TAIL(&ext->nd_queue, ndq, ndq_list); + callout_reset(&ndq->ndq_callout, delay, nd6_queue_timer, ndq); + IF_ADDR_WUNLOCK(ifa->ifa_ifp); +} + +/* + * Start Gratuitous Neighbor Discovery (GRAND) for specified address. + * Called after DAD completes and by interface link layer change event. + */ +void +nd6_grand_start(struct ifaddr *ifa, uint32_t flags) +{ + struct nd_queue *ndq; + struct in6_ifextra *ext = ifa->ifa_ifp->if_inet6; + int delay, count = 0; + + NET_EPOCH_ASSERT(); + /* If we don't need GRAND, don't do it. */ + if (V_ip6_grand_count == 0 || + ifa->ifa_carp != NULL) + return; + + /* Check if new address is global */ + if ((flags & ND6_QUEUE_FLAG_NEWGUA) != 0 && + in6_addrscope(IFA_IN6(ifa)) != IPV6_ADDR_SCOPE_GLOBAL) + return; + + /* + * RFC 9131 Section 6.1.2: These advertisements MUST be + * separated by at least RetransTimer seconds. + */ + TAILQ_FOREACH(ndq, &ext->nd_queue, ndq_list) { + /* + * RFC 9131 Section 6.1.2: a node SHOULD send + * up to MAX_NEIGHBOR_ADVERTISEMENT Neighbor Advertisement messages. + * Make sure we don't queue GRAND more than V_ip6_grand_count + * per interface. + */ + count++; + if (count >= V_ip6_grand_count) + return; + } + + delay = ext->nd_retrans * hz / 1000; + nd6_queue_add(ifa, count * delay, flags); +} + +/* + * drain nd6 queue. used for address removals. + */ +void +nd6_queue_stop(struct ifaddr *ifa) +{ + struct nd_queue *ndq; + + IF_ADDR_WLOCK(ifa->ifa_ifp); + TAILQ_FOREACH(ndq, &ifa->ifa_ifp->if_inet6->nd_queue, ndq_list) { + if (ndq->ndq_ifa != ifa) + continue; + + callout_stop(&ndq->ndq_callout); + nd6_queue_rel(ndq); + return; + } + IF_ADDR_WUNLOCK(ifa->ifa_ifp); +} From nobody Thu Mar 5 18:32:52 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRdSv5skQz6TSmM for ; Thu, 05 Mar 2026 18:33:03 +0000 (UTC) (envelope-from shawn.webb@hardenedbsd.org) Received: from mail-qk1-x72b.google.com (mail-qk1-x72b.google.com [IPv6:2607:f8b0:4864:20::72b]) (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 4fRdSv4DZCz41Qp for ; Thu, 05 Mar 2026 18:33:03 +0000 (UTC) (envelope-from shawn.webb@hardenedbsd.org) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=hardenedbsd.org header.s=google header.b=C4s4rAbw; dmarc=pass (policy=none) header.from=hardenedbsd.org; spf=pass (mx1.freebsd.org: domain of shawn.webb@hardenedbsd.org designates 2607:f8b0:4864:20::72b as permitted sender) smtp.mailfrom=shawn.webb@hardenedbsd.org Received: by mail-qk1-x72b.google.com with SMTP id af79cd13be357-8cb39647a70so805474285a.0 for ; Thu, 05 Mar 2026 10:33:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hardenedbsd.org; s=google; t=1772735573; x=1773340373; darn=freebsd.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=5tGCA23AuFCBJaPgqRf9m/WKdwb0KHBHv0fPMWWkVTw=; b=C4s4rAbwreZlDBVEZ227q/dCJTRnjpl/QcmfdRuqcii9VmEOFsLK0pZsFz/019FUWR ErOCpDH1KY4CkHSm95vC5+I+0K5ebvcuGtov9/ErPaJQMG6Ku8aUg1CMjYFyQdxQn/FQ sGZ9BsBGlVQT8hb6QHNAgyiF9NK0xDCHcP/+ch9rKaUoISPDObSX/myWuW30a87ewnMU co4+uzkSunhZJq1j05XVwG5v8MLOhz7OWTFrwQZvrLOjQ3nMBQFNNghy6y6RKn0anQNo vz7PP6zYIlYxp6OzhGs+hL0YRD1Hsatp/RXb3ThX18alWdeM49cjUtmg4wV+LczScL6n Ru2A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772735573; x=1773340373; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=5tGCA23AuFCBJaPgqRf9m/WKdwb0KHBHv0fPMWWkVTw=; b=rIVxPCIjmAgh9aPeFJGKnnQHywe2dU65dtG6GBcJR3Or+ZrtUfKPUpjc9HBmTTJ5Ch +vKNDYkhyIKllQ80GIyLZvKAmKn5poGeIlZHlp2bslzM5JqpeVsAOiGS8jDpdjH2sIRE ufWQaoOl6NDRiK0qdQiXhwqLHYMMRAb58dV7Ld2onsWSyJii10MDvDV1VCagwbHOXtwy NymzcIMzG8plskR6///PTvnyVp90ek4K0hF+o4WweEilAPQL5xHEoz7Ft8d/mbW5EVLc Dtyuo+Dz6nzDWX11X9l9DDqkZItuom1pDJKlzyYlb4zSRAp5xHjczqAnC3iVtJpJWPtc OFsQ== X-Forwarded-Encrypted: i=1; AJvYcCVZekxLucGiQsi3HzVJ/piqlloK8tB3dIqTiqijf816pvTApiKE903vKUqapH82CKd5XgZjcE+gabHrI9PrEILdlDLGfw==@freebsd.org X-Gm-Message-State: AOJu0YwU3uueaN9eWDR2gKqdYUjJyF9A66DlG+vzZzVO3nJmTXr8pxrX I2aqANdbXvwS9D4oDE2/zbY990WIpne7zL13j06Cc1pj0UQSMx8spEX2joZC7t9n5XI= X-Gm-Gg: ATEYQzyzt5mkmq/D505xZtkhonhZOPNWYy6CBF2fXhNSRDOZqmq0ERqkbypazZcQrte ekIwiIKS745M8dcQ/ShL2shsnZBpIPWp0TuEqoa7w+lvB3I03HgdR5uaduN7KIpYkcn0ULsV+OH CnX9yrovaDHV0kMemeYXuQ12b3R0a9tHLs7eVUHDFhYuoYeNr3NnftQDV0b5a9mLjMu84QbKlbP ysIv7BP6hYXgw/w2hrPnNz45revwUrXxWxZ4hJ7D+YQCdOae5Kbsi7vXOugYxdWAyJvczYl/7Ad Mr5CICUOsKoM9qGhEFKUbWROfaCpUevwQZz95X4Bbci4vu9oUtps/IhveoHmt4Jqwb81pocfkg3 kJs6FxMwvDWmK4Ru81zKw12LzSDf9I143DMzG6WSPC0VQXqwyYv3FNsHfaXRXj0UXkrGvxLQWLR ubhb/N X-Received: by 2002:a05:620a:2681:b0:8c6:a26b:7e92 with SMTP id af79cd13be357-8cd5aec6952mr847019585a.15.1772735572835; Thu, 05 Mar 2026 10:32:52 -0800 (PST) Received: from mutt-hbsd ([2001:470:4001:1::95]) by smtp.gmail.com with ESMTPSA id af79cd13be357-8cbbf68b014sm1949629385a.21.2026.03.05.10.32.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 Mar 2026 10:32:52 -0800 (PST) Date: Thu, 5 Mar 2026 18:32:52 +0000 From: Shawn Webb To: Baptiste Daroussin Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 6d2a147ae558 - main - libedit: fix use after free Message-ID: X-Operating-System: FreeBSD mutt-hbsd 15.0-STABLE-HBSD FreeBSD 15.0-STABLE-HBSD HARDENEDBSD amd64 X-PGP-Key: https://git.hardenedbsd.org/hardenedbsd/pubkeys/-/blob/master/Shawn_Webb/03A4CBEBB82EA5A67D9F3853FF2E67A277F8E1FA.pub.asc References: <69a9aba5.38ca9.25c6649c@gitrepo.freebsd.org> List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="tb64ejnr2lp4arnq" Content-Disposition: inline In-Reply-To: X-Spamd-Result: default: False [-5.60 / 15.00]; SIGNED_PGP(-2.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-0.998]; DMARC_POLICY_ALLOW(-0.50)[hardenedbsd.org,none]; MID_RHS_NOT_FQDN(0.50)[]; R_DKIM_ALLOW(-0.20)[hardenedbsd.org:s=google]; MIME_GOOD(-0.20)[multipart/signed,text/plain]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36:c]; PREVIOUSLY_DELIVERED(0.00)[dev-commits-src-main@freebsd.org]; MISSING_XM_UA(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; TO_DN_SOME(0.00)[]; FROM_HAS_DN(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::72b:from]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; RCVD_TLS_LAST(0.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_COUNT_TWO(0.00)[2]; RCPT_COUNT_THREE(0.00)[4]; MLMMJ_DEST(0.00)[dev-commits-src-main@freebsd.org]; DKIM_TRACE(0.00)[hardenedbsd.org:+] X-Rspamd-Queue-Id: 4fRdSv4DZCz41Qp X-Spamd-Bar: ----- --tb64ejnr2lp4arnq Content-Type: text/plain; protected-headers=v1; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Subject: Re: git: 6d2a147ae558 - main - libedit: fix use after free MIME-Version: 1.0 On Thu, Mar 05, 2026 at 05:49:51PM +0000, Shawn Webb wrote: > On Thu, Mar 05, 2026 at 04:13:25PM +0000, Baptiste Daroussin wrote: > > The branch main has been updated by bapt: > >=20 > > URL: https://cgit.FreeBSD.org/src/commit/?id=3D6d2a147ae558ef423e3df451= a9049200b291a8d0 > >=20 > > commit 6d2a147ae558ef423e3df451a9049200b291a8d0 > > Author: Baptiste Daroussin > > AuthorDate: 2026-03-05 16:12:51 +0000 > > Commit: Baptiste Daroussin > > CommitDate: 2026-03-05 16:13:08 +0000 > >=20 > > libedit: fix use after free > > --- > > contrib/libedit/map.c | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) >=20 > Hey Baptiste, >=20 > UAF bugs are typically thought to be security issues. Does this > particular fix warrant a security advisory? The log is unfortunately > lacking much useful metadata usually included in these kinds of > commits. Chatted out-of-band with another FreeBSD developer. Turns out this UAF only existed in main for nine hours. Didn't make it to a stable or releng branch. A Fixes: tag probably could've helped address the confusion. Thanks, --=20 Shawn Webb Cofounder / Security Engineer HardenedBSD Signal Username: shawn_webb.74 Tor-ified Signal: +1 303-901-1600 / shawn_webb_opsec.50 https://git.hardenedbsd.org/hardenedbsd/pubkeys/-/raw/master/Shawn_Webb/03A= 4CBEBB82EA5A67D9F3853FF2E67A277F8E1FA.pub.asc --tb64ejnr2lp4arnq Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEA6TL67gupaZ9nzhT/y5nonf44foFAmmpzEwACgkQ/y5nonf4 4foX2Q/+Lav/cuHoB24v2wvfpAavKUC2nmAE0YtpvgwKg32BphNqEYtSo4a7F+Dt pGgNBhsjsNWmEOSInpe0Gv2N61pl99aIjvwklFRTDDgFPke1GIrbe2H9Uio58ScU G/m4MaeWvHi4/kMWTEzXy0xP2jPRTu45PnqXW2BPWFTN7SaZQZPkUNdqSGbdm7sY msqN4QNg5VvDcyRjlmPw+A4ox4HUoGOAy8RRMiJf4AtQ7jOrP8bC3VvmmaGaNY6w KXp+03/Siq0MUZXk2QydsLFeQT6uwk30gETu7tskimeZKQJLmccwtoDnx+hs1hh+ IGsrnNWuFo9IjltPbccFhaPT6HgpCTjlMxiCqrEHPHoYgNZo0d9FsO3fJMdshd9+ F3ILUd3XQf1KtnmiCzLcJSMHgGx1koizKGtBsfW7RJ0I2ei2wpEhGNgp8ptZKtzB ghKde5PT8uYY5ZTyslT65zXcSVO4jkIXUDJ6UGXo21ODiTKuPZo9OEOE2o6oqlEP kuRpe8ltAHVloj+autvpE5g61bO07gAqEwCNRT18sr1iSWpc82/DPw8RkFnjSXpp z9MUqMHkj1vuLTLswpQ7Ghe+Xrin23R3X3gkLhqgeC+l+FaTG/lT5IgZvI3aByUr nLoCbGZSk2hXjKrKX+Z+3qGv6TQgbgibYemObII5oTHSz6h4juQ= =KzF6 -----END PGP SIGNATURE----- --tb64ejnr2lp4arnq-- From nobody Thu Mar 5 18:44:27 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRdk41Bskz6TTXL for ; Thu, 05 Mar 2026 18:44: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRdk40JSRz42H4 for ; Thu, 05 Mar 2026 18:44:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772736268; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=urHMBuQCfUCd8ZD2iYoU9dWNAtwvHPVSIsif7W7CHtU=; b=qzTnRm1hMpr/0YY5NfgrJjN3TrFXQoLZ1vKS9kw0DPqay/cs/hc25KdKn5nwx5jqeOhN3B WBLtBMemFcTiAKBWhc0ImgzUcVa3zUYdLEzDoxL2cuUXWB2z6ZBTqE2kfJU6c3Yb1QSVln VWMcGoCiLm+iDTrcYZNyKM1gxL5ogUuFLdjKVZfQgpJJp8TdkPrRKl19/Pu+KwfgzN4Fsn +GTBu6yt9Jj2RXQ98M5K6w5ih5fIyzB8pXEqBXRdEX1oUuhcYHvufrOSBHUx5idATMs1oE J5MYUaCcVW5nKrq3IFMQoVl3m7mv+s7Q8knrlNog5G5G9W7qQGmzep153SvKPg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772736268; a=rsa-sha256; cv=none; b=G67uZF2O7nBKYmVmDMg+osOgAHjY1lvGwC3CKULg5bq4mZMJnfi5tZCLlfg8qT8ngVU9T0 vAJpD0ZBw7rJIZgsCe/Niw0qhRx+T3lqtOylLI4jNXpTPa1GYQ/srkk/AujFc9akGZ4Z8S C6Y2oss9SHL3608Qcpf1SWZgSgvyLUuVvNX82zinatuU3IaAd0xGHdx2MhX5OMclQqMMyD iUPMhU/h29jY5cBPgFENNf48SXgXJkA62HibyJKibLN4Z5ZnHCEbXZ8z6OzsWTbtK7FxqS 9w6JA8/gsJMJoPn+Wrmn/dxSLXJg8GcweGZpZWlGKL0VH5WT6yOaMPR+OXr+bw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772736268; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=urHMBuQCfUCd8ZD2iYoU9dWNAtwvHPVSIsif7W7CHtU=; b=hMbDGcORwWCZ34W2ibe9t9VFePgfx4kveTrXGm8cZbqiz8vaY/4xur5/QHmc5lceyM/Sk8 qgtWWmjShw4wiDlZYvftkOrNMGlyKvE2CPczcAccokJASTa9ZeTmSXKADKbnee9e1u+ArS y9w2qgWLQv1S7/t36EExtMgam7qmt96noTYuX5SIIiLTxl9PjE3J3XlNHBvxOCKKg7GaGL ojbp0VVaEzxXTg3Ky6KoRljrDGM2E2XrEj35GanfvzmPpJjPTv8XH69yCrTyal7t17Weyx t36mNDlMIpIyINMVxc9iJtjhfAWCp4DtlFqcRmR7D7qJOEeE51gMNrOrwE0ITA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRdk36rNYzppM for ; Thu, 05 Mar 2026 18:44:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 47158 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 18:44:27 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: 6feb16b77e7d - main - witness: report a thread that can't sleep in WITNESS_WARN List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 6feb16b77e7df470c635bc3af65d448fd37deb10 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 18:44:27 +0000 Message-Id: <69a9cf0b.47158.66f48a02@gitrepo.freebsd.org> The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=6feb16b77e7df470c635bc3af65d448fd37deb10 commit 6feb16b77e7df470c635bc3af65d448fd37deb10 Author: Gleb Smirnoff AuthorDate: 2026-03-05 18:43:17 +0000 Commit: Gleb Smirnoff CommitDate: 2026-03-05 18:43:17 +0000 witness: report a thread that can't sleep in WITNESS_WARN Although this is not related to locking, but seems to be the right place to catch violators, given that WITNESS_WARN is already used widely in the kernel. Reviewed by: kib, markj Differential Revision: https://reviews.freebsd.org/D55316 --- sys/kern/subr_witness.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/sys/kern/subr_witness.c b/sys/kern/subr_witness.c index 7437a7e238f0..85dc0c321797 100644 --- a/sys/kern/subr_witness.c +++ b/sys/kern/subr_witness.c @@ -2136,6 +2136,15 @@ witness_warn(int flags, struct lock_object *lock, const char *fmt, ...) n += witness_list_locks(&lock_list, printf); } else sched_unpin(); + + if (td->td_no_sleeping != 0 && (flags & WARN_SLEEPOK) != 0) { + va_start(ap, fmt); + vprintf(fmt, ap); + va_end(ap); + printf(" with %d sleep inhibitors\n", td->td_no_sleeping); + n += td->td_no_sleeping; + } + if (flags & WARN_PANIC && n) kassert_panic("%s", __func__); else From nobody Thu Mar 5 19:07:35 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRfDl4tNvz6TWPD for ; Thu, 05 Mar 2026 19:07: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRfDl3pYWz44LK for ; Thu, 05 Mar 2026 19:07:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737655; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=a7z+1dAlMU/+hud3WY7Ks0L9852uQB7xkg6e3XkdlAA=; b=Ay6UxZWaeBVuKHS2Pg35rEE9G3VkqT2+C+tihBvD0etktwOij+5+GclHZP4YvFidMq1xMd BgVZEM+/qwFU9KY8FC1opwHUc3SLxNG3ey+u1tWMUv5ZSo7cLNmu9LuVQQ2QG1VdG32GYV yM7VYDtaPSWEIr32f9kvf/G3PI7PkVRSBy8PQ4L4WgOCNpFFj0Fk3S3qPGVWKsUzKW17T8 YBWmHKM+dJBRuWW+UMSbQCivkiMejspQzHz6MJNoj/AowoYdrPgl6Fwbwe9mXyBHtyOiSL et8cTQWRaKzy97Hm/Q8BFn7rspJqf6HTl4TW0bJKtHEPl0LzWnilYBNAbI1jmA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772737655; a=rsa-sha256; cv=none; b=pdf++gwQQBq2xaz8Oj15Yl/uVs2mMmLSSrZqtwzkcsA8c2NvDtDCfRaE77OYLspzAYKRTJ Tdzao4IALeaXuduwTOUUzm4nHJU5tgoNa2k955uGz59yOQItQ3dJjEP9f12OTeY5XosmUu lAxiiqqUlm3aJkjOS2eNCC+hIyR9da42B1JPkCWUrZ1205ymuypphCFUelmmGPvWmEBbSP tnp8ViNQFv/YdXxLlWLfABXn79HtFshfDAKmz5NoAd5ijwOY9LPL2paf3K7FNG5brehsjP mjdSI+wIIvn649OkQnlCAEBUopk7J3iAki925bv8mS9RsYtkUWY2YoaDCz8yRg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737655; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=a7z+1dAlMU/+hud3WY7Ks0L9852uQB7xkg6e3XkdlAA=; b=YVQioKZg0wsCWOdabjNXiHn3kn9waECX5mwup0O86/mJA/GqtRrnGkh4ET3eTHY4P6FQoV BDqNYgXRMuGNNWEcpnskAOg3cbTS3YvRyCm86VVC3jSPOaBTZFEa6eDbHnf5ZRQkiYSzip iOcH4z44G+v0Xsi+5HNj4sYqZ69Kuo2C7gX/HbbiQJwCHgGtTb42PEBONYYbnffl65n0iC 78n+3XincFuJU/KsY5TnhkMaz8F1SBB4GqgdZ7MwOH7a3RwMAnEU/3CdPpINl5mGjZ1193 r5rw6Dd6jBKexKrSMNEpD86/ZMxpftkY8Vh7UFlv9ZIx+VbCesFsewa5VSTkbg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRfDl3DWRzqTv for ; Thu, 05 Mar 2026 19:07:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 47dfc by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 19:07:35 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: d19f2af2b7f9 - main - acpi: Don't attach a "wake" sysctl node to devices without the ACPI flags IVAR List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: d19f2af2b7f9c964622fd2eba7d077c6f221b652 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 19:07:35 +0000 Message-Id: <69a9d477.47dfc.2269a454@gitrepo.freebsd.org> The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=d19f2af2b7f9c964622fd2eba7d077c6f221b652 commit d19f2af2b7f9c964622fd2eba7d077c6f221b652 Author: John Baldwin AuthorDate: 2026-03-05 19:07:09 +0000 Commit: John Baldwin CommitDate: 2026-03-05 19:07:09 +0000 acpi: Don't attach a "wake" sysctl node to devices without the ACPI flags IVAR Not all bus drivers for ACPI-aware devices implement the ACPI flags IVAR used by the acpi_wake_set_sysctl handler. In some cases this may be a feature as some new-bus devices share the same ACPI handle (e.g. a pcibX device and its child pciY device) which can lead to confusing results (e.g. setting the sysctl on pciY changes the behavior of the parent pcibX device, but the "wake" sysctl for pcibX won't reflect the new behavior, or reflect the device's state). Reviewed by: obiwac, ngie, imp Differential Revision: https://reviews.freebsd.org/D55562 --- sys/dev/acpica/acpi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index 3a664523c27e..01b584ec30aa 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -3951,7 +3951,7 @@ acpi_wake_sysctl_walk(device_t dev) for (i = 0; i < numdevs; i++) { child = devlist[i]; acpi_wake_sysctl_walk(child); - if (!device_is_attached(child)) + if (!device_is_attached(child) || !acpi_has_flags(child)) continue; status = AcpiEvaluateObject(acpi_get_handle(child), "_PRW", NULL, NULL); if (ACPI_SUCCESS(status)) { From nobody Thu Mar 5 19:07:36 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRfDm6nd3z6TWV3 for ; Thu, 05 Mar 2026 19:07: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRfDm4c1kz44RR for ; Thu, 05 Mar 2026 19:07:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737656; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rBNBpCPleDqfjNTqtCQAENDY9f14X2hMA/QL+ETvG6w=; b=h8ObGRVH5ka1ogNvlRBpSvL5pjdrEGeyeTGq8EFt97fK4VYMJ1VZ/0UHmyLhXAMpDsiD4Q ZrVNfAjj9ZjD1D+YR38UQBPXUI/2/hh5L2A4nm12dYp2CbFLFEK5L5mUMR4H//WQyGOmpI x0ZZjFRO5hjA/kUGotlU5xgXzZd6WPbM+9v9SXzLBU/rluAcAc8VstjxIlGNzKB0seO4It Vnz3xYKQq6BzVoXxz7hRPTb6MJRm+wXYKp1hmJbjvapBtwIkVFS/efV6XUaQfAMmx3YAYJ bSx+r7qpUg5BncGEImECl4U1eNtx0dgPAzRh/LGgkhH3GjzXWuiaWxkzI3dYdQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772737656; a=rsa-sha256; cv=none; b=jV3GuX52FGUzyDeEIEIJxN3k2zfBen5Y9+N+aBuUcWQNKnAF4QJ6IbwzMYquFxmuQr48+Q hh2Jss0eBAWNcAQOZ5gadKXFVVHM30vqyXn+Hxy00UY6kkLMxVarovHcxok8+7Ml9KDMkJ s8cnzRTHDSMr+ujJ2nzMziNpNiZdPo+dehHmr8uez/RVOsOlSEnfQXBpFBlXUZprcn+VWO ACminA0V4nZq8DKER8GOA7UJ6zSLLqOCyZ5If0ZjTfy2Peb76PC/7ejFc57jZi/MV33dCk Jfi8QG+2tizh0gWa8LxDslTe61a3jtvmq9pFov+btbcS1GeKXxBMUASIx9LmOQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737656; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rBNBpCPleDqfjNTqtCQAENDY9f14X2hMA/QL+ETvG6w=; b=IQB9C+XShU9AvgYaUhDLsCK1mAyuiEoNXx9HTAOFKGIk1R46u+qVPw257TQIQSkd4bNg3d Imn+Om6+S3UdDjTfcVlBIkklllPEkrT1iyizL/DUUhjvJPdMsog9HYAuR2sTzlJbMu6HVp wy5IjEbZPnzVqnWx0kkoDZyknzwWmEJCGf/DTjEbKek14P1Z/fPw+NNsKLKPnb1EFxd4zK Hl2fNNZcAfwyUtdbBWkMwqfH20N3bwH9F6PPAqdYWJJNWNvLV3qKYFZliZeWlnhQ2XW2fU 4QSJ3ItDkfVCkbdeXheWSDcUc9Xdo4OFPxCgNhRnE0jbAqvCNoF+yYcWku8uRw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRfDm3d73zqXQ for ; Thu, 05 Mar 2026 19:07:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1824a by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 19:07:36 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 1b77f6ec6b9f - main - bsd.linker.mk: Document ifunc, ifunc-noplt, riscv-relaxations features List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 1b77f6ec6b9f5e0e916e2f559f045262645f2364 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 19:07:36 +0000 Message-Id: <69a9d478.1824a.3d08603e@gitrepo.freebsd.org> The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=1b77f6ec6b9f5e0e916e2f559f045262645f2364 commit 1b77f6ec6b9f5e0e916e2f559f045262645f2364 Author: John Baldwin AuthorDate: 2026-03-05 19:07:09 +0000 Commit: John Baldwin CommitDate: 2026-03-05 19:07:09 +0000 bsd.linker.mk: Document ifunc, ifunc-noplt, riscv-relaxations features Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D55655 --- share/mk/bsd.linker.mk | 3 +++ 1 file changed, 3 insertions(+) diff --git a/share/mk/bsd.linker.mk b/share/mk/bsd.linker.mk index 95d98231b641..116b437e6de9 100644 --- a/share/mk/bsd.linker.mk +++ b/share/mk/bsd.linker.mk @@ -12,8 +12,11 @@ # linker support for that feature: # # - build-id: support for generating a Build-ID note +# - ifunc: support for indirect functions +# - ifunc-noplt: support for indirect functions without PLT stubs # - retpoline: support for generating PLT with retpoline speculative # execution vulnerability mitigation +# - riscv-relaxations: support for RISC-V relocation relaxations # - bti-report: support for specifying how to report the missing # Branch Target Identification (BTI) property (AArch64) # From nobody Thu Mar 5 19:07:37 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRfDp0dcqz6TWJm for ; Thu, 05 Mar 2026 19:07: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRfDn4srcz44Sc for ; Thu, 05 Mar 2026 19:07:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737657; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=U6IKk81dVcotlSG1aCFUAJJCGzYYcYUyaYFsgkvLHLo=; b=mPBpxPiFgcEVGnjcmp1KONpQZwLaYGZX/09rqX12nKrsmBpaMLTt/hZRwv0D3iYl0iLBd0 BwSDpctFBvK1lC7GM/shu+Wdp7XM0SbhcpL8JlrIf3KpywKVb6GGj69SL86in+On/tAp85 iI5/r+bfhFpAvPXZ0t5dT44INclKEUwPm7Th/DbBsJenr5tWWD03vKQejleWc9+Jj+bKP6 MEmdt994b3V+25LdJCuitVRZphAWuvwrt/AMfbeBQuNpe2OhyL0ivDDgqLRJxxaMfQz8/K O+ozK0zwda+HFZqXAk7vdmSJK4D6KkVYxAC8or0VQPlosr+lhWipPsXihG+3XA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772737657; a=rsa-sha256; cv=none; b=N7RBwB/G/HxaJrRIx11nGVrmBZSctBgpV0d9RYwT/uI87KBN1vMc++J4gS51912Zwi2c1W SUCi3WL+f6Fz8/kB0sVjqDJsUQ0EcjUI2k9oLOnPs1E9QTVz633VRSftTH8Ep24QMElfHX IukYfVvy/k0Tpb4iyYA3nfR69KLdFsvQzTlG5nv3v+ilPA3XMIfTooHCxdGUubofjtNzbX 8OUbT5wp1bYu7Yc/b7xUuSbGWWdvQr8U/cIzKx+fTQwV+k19QfEtPTIizjiN6atcPifOHT 4mYfzkf4we9zONnm9ktrqO8UiD2O64GJjo00nvSswXUtueh3szoWsBip6bhcRg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737657; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=U6IKk81dVcotlSG1aCFUAJJCGzYYcYUyaYFsgkvLHLo=; b=CbC85lhMDPvSmJHfLtvlnRn9FLWO9JbwyJO7I7Zif/zdQPnpJlKanXHR6duC6Oc0dui5L/ +Zn+io2n+HtSZCSS8NAAet08L4w/cUd/3nMzUwhFjpYme0Z+rqHrPGLmXs2eC5g9QMfrir vLe0njZ2HBvo9QlTiK8DUqT3PJfLE9lOQgPPhINlJTkYFg/DjXQC9mrLTRRR6+HitsMTCp 86Vs7URGsgX35l82yg+w9taqg8UQ6riaxWEgIy8neQEc1+k2sPvVD3iqsJFS5nLLze9KMn 0PJa7tjIleDJENWzPDz9qJXwNXv2cAzI4CQUkau2S/557XDBiHPi6wR9FXC8OA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRfDn4N8Dzpm5 for ; Thu, 05 Mar 2026 19:07:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 18d12 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 19:07:37 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: cf92fa337074 - main - bsd.linker.mk: Sort list of linker features List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: cf92fa337074b0ac36f89b826ecf0769a1c45609 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 19:07:37 +0000 Message-Id: <69a9d479.18d12.3cd754e@gitrepo.freebsd.org> The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=cf92fa337074b0ac36f89b826ecf0769a1c45609 commit cf92fa337074b0ac36f89b826ecf0769a1c45609 Author: John Baldwin AuthorDate: 2026-03-05 19:07:09 +0000 Commit: John Baldwin CommitDate: 2026-03-05 19:07:09 +0000 bsd.linker.mk: Sort list of linker features Reindent the features as well to be friendly to long feature names. Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D55656 --- share/mk/bsd.linker.mk | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/share/mk/bsd.linker.mk b/share/mk/bsd.linker.mk index 116b437e6de9..4b3305dc82b3 100644 --- a/share/mk/bsd.linker.mk +++ b/share/mk/bsd.linker.mk @@ -11,14 +11,14 @@ # LINKER_FEATURES may contain one or more of the following, based on # linker support for that feature: # -# - build-id: support for generating a Build-ID note -# - ifunc: support for indirect functions -# - ifunc-noplt: support for indirect functions without PLT stubs -# - retpoline: support for generating PLT with retpoline speculative -# execution vulnerability mitigation -# - riscv-relaxations: support for RISC-V relocation relaxations -# - bti-report: support for specifying how to report the missing -# Branch Target Identification (BTI) property (AArch64) +# - bti-report: support for specifying how to report the missing +# Branch Target Identification (BTI) property (AArch64) +# - build-id: support for generating a Build-ID note +# - ifunc: support for indirect functions +# - ifunc-noplt: support for indirect functions without PLT stubs +# - retpoline: support for generating PLT with retpoline speculative +# execution vulnerability mitigation +# - riscv-relaxations: support for RISC-V relocation relaxations # # LINKER_FREEBSD_VERSION is the linker's internal source version. # From nobody Thu Mar 5 19:07:38 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRfDq0KR0z6TWd5 for ; Thu, 05 Mar 2026 19:07: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRfDp5th3z44Sl for ; Thu, 05 Mar 2026 19:07:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737658; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=k1ttpL8jLYJQM3Kb3F6OzAZdcPTAhwir3m3HNzNZfYc=; b=Th+JhQsu8uoN/e7ZefrAqNIJ8DOQBKlgqparrqMik6Q8r9xuWi2/tnIWmwiUyaPTG0e3l6 e3CI//RA7ohkly751YdsvMcNjHkleZFo9fx/k6Gp+1TgVBt9zx275cPANsrNG2q/Ue1XHz anNktG+eLA33SDUDcY5d+sX0tZ2fcTEz5ATELg+ZrV+hO2Vu7uJmh++qKtGZ/xxAKI8G+N DpCtNVO0C57R8JEPjNPxB9BYbKn2opxpFZx3W4gKtqdLcnRmC4Oq6PVK7SzcLYxFdbdA8T Hy6JiPpuHhMh+leezcFbdn/BBbYng88hL9vklZ6eNjyPhqJwDBGJT9NM/kV1RA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772737658; a=rsa-sha256; cv=none; b=C9Iu3MkaIgkNTeFu8L8t7ccrFDLWCtLniMgxrzzN7xh7LZ9xf7+kbqFJ9Ia5s+oNekmaOj FsDnu2RBIkjNvVaKEgUsj7IEMc6KxNEQzLWOgs0loDzMeK5BCcoRMz79614CeF/cydwJqY qIksXiM2bRBp+ArQHuPnYYrjWzXybv9gTzH+tpfBkurmCGkuilqZ9fkIxpEcxCVpr962xr uDjYqYq+v2LBTZ6uP4znm+d4U0N3FpJgwgpFAAgD/kZ/EHIaIj7I5nBtpCdHRj37Uyo6BC XmbwDiAUjf56/eWodMrxVQMF6oGzGlXpKq35WCGM4Z3UucrJpB8uucfxmrHTug== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737658; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=k1ttpL8jLYJQM3Kb3F6OzAZdcPTAhwir3m3HNzNZfYc=; b=H9+dU7u1Bz6qEqWqjrbjdmIfAy+B4TaUzRSENZ/qdY8ySFcEKIaQsSIVsakwxwseDAHGjG DUyVj9MEnj9gQi16ONAsTZ75tTaw3OOWOFxo8NQOvmyiTL04pyLcw6QuXx3skCfoAGbAnc QH4NrP29mFi6q9eGh+4wu0cJS9XDB/SK5wN8UQdIsIC9Ne1omfnpH0koW5JLrLQDMME9ng mm8h2WskxC7SPbkeIe+VkL4FWvc7nbpezNVlGXRrwfTpuwRDgGaDqD0vLfbgfR3fPx6APx qqRwXSLIRqmAIM1dO9zutdIIg9PU+WRr/xSRNlxUqkWICHLcem0MRhxzB3CGkw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRfDp5BCFzpXM for ; Thu, 05 Mar 2026 19:07:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 19619 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 19:07:38 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 27cfa8ec633a - main - libc/quad: narrow list of symbols exposed for 32-bit arm List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 27cfa8ec633ae7527dc6187c6a78db04983c9ccf Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 19:07:38 +0000 Message-Id: <69a9d47a.19619.67ba477a@gitrepo.freebsd.org> The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=27cfa8ec633ae7527dc6187c6a78db04983c9ccf commit 27cfa8ec633ae7527dc6187c6a78db04983c9ccf Author: John Baldwin AuthorDate: 2026-03-05 19:07:09 +0000 Commit: John Baldwin CommitDate: 2026-03-05 19:07:09 +0000 libc/quad: narrow list of symbols exposed for 32-bit arm lld doesn't notice, but ld.bfd complains. Reviewed by: brooks Differential Revision: https://reviews.freebsd.org/D55657 --- lib/libc/quad/Symbol.map | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/lib/libc/quad/Symbol.map b/lib/libc/quad/Symbol.map index f7dcdebfc7ae..7c60d8183b75 100644 --- a/lib/libc/quad/Symbol.map +++ b/lib/libc/quad/Symbol.map @@ -8,36 +8,50 @@ FBSD_1.0 { #ifndef __i386__ __adddi3; __anddi3; +#ifndef __arm__ __ashldi3; __ashrdi3; #endif +#endif +#ifndef __arm__ __cmpdi2; __divdi3; +#endif #ifndef __i386__ +#ifndef __arm__ __fixdfdi; __fixsfdi; __fixunsdfdi; __fixunssfdi; __floatdidf; __floatdisf; +#endif __floatunsdidf; __iordi3; __lshldi3; +#ifndef __arm__ __lshrdi3; #endif +#endif +#ifndef __arm__ __moddi3; +#endif #ifndef __i386__ +#ifndef __arm__ __muldi3; __negdi2; +#endif __one_cmpldi2; #endif __qdivrem; #ifndef __i386__ __subdi3; #endif +#ifndef __arm__ __ucmpdi2; __udivdi3; __umoddi3; +#endif #ifndef __i386__ __xordi3; #endif From nobody Thu Mar 5 19:07:39 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRfDr24JKz6TWJr for ; Thu, 05 Mar 2026 19:07: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRfDq6NYnz44T3 for ; Thu, 05 Mar 2026 19:07:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737659; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=FiyuZ/kpziMZS9VfxHi+boK1GqV4zROE65P0FLIXHbk=; b=hhxlAOIms0jTPyEqEMMbUMRJ+hKzBXmDpb31fSdbEKOf4DGzcqhNfO7ud1tcKUl3n3lneY hr+603jusZmRtPh4kKQwlj1Ef4mveoQkrAztHePlmsEgC0IuGcPuE0jziFnwVxAqLAtULs P6wO9NatTswc3b8GOdrgkLLf371JiNYvdelt5VVk8mN0WMHdUbWdmnWmpFEOWkcli9n41d DNAHGt7JF15fmce0c/piMEijn3/DoLTqesRfqguzLtJblazAJbR0tQsYKrrxwjk2rn2luw YVtvWXYnKR7AbyoQ+bd/eEp0+ZyiAD1YztFzayhMV+ovYKPmH5NmG44f0XqFEA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772737659; a=rsa-sha256; cv=none; b=rp7eHZnf1h02diEd68kJ2bCp1Pb4iy+ZD/I5B6MII+1wTW9OalIOzoIiVSTjgP3lk5rydf UmQ7wFwASTAoRNvVjAbjxWYPfoavLqoBdthnms9g2v8et52Vb5h91PTbgIm++mLqbj3peR TomgUCzefu208Apsyr9ndQ1/52nUx/aNSfaV2oQup/k1b+Odi0+gU/GFe5K7k2IVAIoI5o L3VnU8dkU/ojD10N0fsA73Ah8188/prhU1VVRPjX5nTJQV8JqE6FD9jrp/llMhok+5qPMb 3UjF+BWNsVHnbuDWayaGq5nFxQKnLurUdNFiBkD49/lvuvP/LIeGG+1IQ2aGWA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737659; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=FiyuZ/kpziMZS9VfxHi+boK1GqV4zROE65P0FLIXHbk=; b=FU5n5BSIPiWkcEszNExyLlJ5CayK7dzR2QzPrxiVmDxq6kGdbsmI8JBWOUvHed08g7yvv7 QehQVfUC90wMhMFUxRQIuXGQpYqWnpNhPUyywZB1jF+b5mJpjHFBzjB8qVKizm7uM7+xKq Pkc1vmzGhrVIsfPSHJnAXTUgRii3eOeQVFhhjV16ewOil+9MS/pMcpjdCWQkrDR/Wt+sbw Lcqzl/r1Bjw4eFKs1tdJgaBgOfLTVWF1zHnLfgzSNvlN2OEApgGrM0/L/fVKrEa8t2btbg njKwLhd4HKzA99qfnxxrl/QTjnga7cDM+ZLYp26FGkRb3QhbKcU9tyEYXkJ4uQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRfDq5z4jzq4k for ; Thu, 05 Mar 2026 19:07:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1928a by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 19:07:39 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 54bf594851f6 - main - libc/quad: Switch to per-arch lists of symbols List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 54bf594851f671e231d2786cdacaf68f290ff738 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 19:07:39 +0000 Message-Id: <69a9d47b.1928a.7f6e7682@gitrepo.freebsd.org> The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=54bf594851f671e231d2786cdacaf68f290ff738 commit 54bf594851f671e231d2786cdacaf68f290ff738 Author: John Baldwin AuthorDate: 2026-03-05 19:07:09 +0000 Commit: John Baldwin CommitDate: 2026-03-05 19:07:09 +0000 libc/quad: Switch to per-arch lists of symbols This more closely mirrors libc/quad/Makefile.inc and is easier to read. Reviewed by: brooks Differential Revision: https://reviews.freebsd.org/D55658 --- lib/libc/quad/Symbol.map | 43 +++++++++++++++++++------------------------ 1 file changed, 19 insertions(+), 24 deletions(-) diff --git a/lib/libc/quad/Symbol.map b/lib/libc/quad/Symbol.map index 7c60d8183b75..c28f9a180704 100644 --- a/lib/libc/quad/Symbol.map +++ b/lib/libc/quad/Symbol.map @@ -5,54 +5,49 @@ FBSD_1.0 { * broken and they expect to see them in libc. glibc exports * them, but they do not appear to be exported in Solaris. */ -#ifndef __i386__ +#ifdef __i386__ + __cmpdi2; + __divdi3; + __moddi3; + __qdivrem; + __ucmpdi2; + __udivdi3; + __umoddi3; +#elif defined(__arm__) + __adddi3; + __anddi3; + __floatunsdidf; + __iordi3; + __lshldi3; + __one_cmpldi2; + __qdivrem; + __subdi3; + __xordi3; +#else __adddi3; __anddi3; -#ifndef __arm__ __ashldi3; __ashrdi3; -#endif -#endif -#ifndef __arm__ __cmpdi2; __divdi3; -#endif -#ifndef __i386__ -#ifndef __arm__ __fixdfdi; __fixsfdi; __fixunsdfdi; __fixunssfdi; __floatdidf; __floatdisf; -#endif __floatunsdidf; __iordi3; __lshldi3; -#ifndef __arm__ __lshrdi3; -#endif -#endif -#ifndef __arm__ __moddi3; -#endif -#ifndef __i386__ -#ifndef __arm__ __muldi3; __negdi2; -#endif __one_cmpldi2; -#endif __qdivrem; -#ifndef __i386__ __subdi3; -#endif -#ifndef __arm__ __ucmpdi2; __udivdi3; __umoddi3; -#endif -#ifndef __i386__ __xordi3; -#endif }; From nobody Thu Mar 5 19:09:10 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRfGg6Xcvz6TWKD; Thu, 05 Mar 2026 19:09:15 +0000 (UTC) (envelope-from bapt@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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRfGg4SfJz46T9; Thu, 05 Mar 2026 19:09:15 +0000 (UTC) (envelope-from bapt@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737755; 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=foPkF4u26SaQO/pY4zpJroGOIByWcQ5TwTMw49ojG/4=; b=sYbh6jpP18E4nL0bJ+QZLz7iF4edk8iHLR+0OcaiMinVLMMtXReT8Pq54+P1N8Pjf/JhDK 7uLBRuag9pj0FGH4w7CH85WGWqIAFujbMLX81A9l8MWGqmKnKS7LgVuPNPKmCWNBIP+Na3 DXvuE4v9Dcxwve7nGGJ17B8fk2uaF9zXMcu1r5lxDDSzH6aJ4W5j62toG6i390TRDTm+7k sg43hnrU6Cr0cmXwscxdsYxLPsMF4wxkHoag1QEX6Jlh85YDW8nP5ANStt0mzPehsi3DLK kGMaUGv21owWyZBtmQK11aWmUms/FBgDVLsd7zDdJoC+5Wf75oDN2ns4zeaNsQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772737755; a=rsa-sha256; cv=none; b=i2RhnA4Umoh6+g/kjruXjHspbmmdz0sbHU+so040Nmq1TWRtqL76n3j4znd6kl9tFMLPZ/ chFRN/ys4v1BTynkogyY3AquPuQPcJdzKzdrEWlTGaDbck+FZZEEVqvKlT+tKoCD75V+LR mSlp3C/mRtsAeXsetoV6IJ+n9KoHg3iV9WQjKxLBI5rdk3+weNBAX0txfQiylf40+j907V XWGfWEZe4vqockB6EyCtmsVJSdWNJcfAfemI13yBzDWK2BdRgkhLHeRJxDpuRsEdtSFEHT K0aDbqTpx4DbZOuxLLK6vgGBGZbnUeqTEf27C8cSxaU6tB8FzQEc/VMAcfg2nw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772737755; 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=foPkF4u26SaQO/pY4zpJroGOIByWcQ5TwTMw49ojG/4=; b=XTLcKChT7icftIUfE3DdAuAcGFl3qhad50taky1pZr7ybourBg0BrKpwNOj3sCf/PVbjsD SokjcuOrWhMaTVuKyjM9CVoXCtxCqGzx4IUgOdKxj0r2jucMeO9bwAu6OiJRFUZ4wrNV3C n9Faay0fBVK/3VtdkDPk4hNhD7offPbTFWao8l1YQ84WArAO2oFfx/eamrKI7/LO2TKblI q484orDxuLilzZuX0JEIlDjvGZnhdVw8cpxEHAve8huHOdMdI7NzZVx+3eRVrYb6zkz1+n zvtPtiFgHick3jxk44uMenI6IRBWl1SJLd4rq7SgqOKy8I4ZnpJ9MWI6kljFow== Received: from b.nours.eu (b.nours.eu [IPv6:2001:41d0:303:5e39::1]) (using TLSv1.3 with cipher TLS_AES_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: bapt) by smtp.freebsd.org (Postfix) with ESMTPSA id 4fRfGg3Sc4zJJ6; Thu, 05 Mar 2026 19:09:15 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from ehlo.thunderbird.net (unknown [IPv6:2a01:e0a:274:cc70:b90e:a46c:77b7:b409]) (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) (No client certificate requested) by b.nours.eu (Postfix) with ESMTPSA id 3303C10AE4A; Thu, 05 Mar 2026 20:09:11 +0100 (CET) Date: Thu, 05 Mar 2026 20:09:10 +0100 From: Daroussin To: Shawn Webb CC: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 6d2a147ae558 - main - libedit: fix use after free User-Agent: Thunderbird for Android In-Reply-To: References: <69a9aba5.38ca9.25c6649c@gitrepo.freebsd.org> Message-ID: List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Le 5 mars 2026 18:49:51 GMT+01:00, Shawn Webb a =C3=A9crit=C2=A0: >On Thu, Mar 05, 2026 at 04:13:25PM +0000, Baptiste Daroussin wrote: >> The branch main has been updated by bapt: >>=20 >> URL: https://cgit=2EFreeBSD=2Eorg/src/commit/?id=3D6d2a147ae558ef423e3d= f451a9049200b291a8d0 >>=20 >> commit 6d2a147ae558ef423e3df451a9049200b291a8d0 >> Author: Baptiste Daroussin >> AuthorDate: 2026-03-05 16:12:51 +0000 >> Commit: Baptiste Daroussin >> CommitDate: 2026-03-05 16:13:08 +0000 >>=20 >> libedit: fix use after free >> --- >> contrib/libedit/map=2Ec | 4 ++-- >> 1 file changed, 2 insertions(+), 2 deletions(-) > >Hey Baptiste, > >UAF bugs are typically thought to be security issues=2E Does this >particular fix warrant a security advisory? The log is unfortunately >lacking much useful metadata usually included in these kinds of >commits=2E > >Thanks, > this issue has been in the tree just a few hours and never in a release=2E best regards, Bapt From nobody Thu Mar 5 19:58:17 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRgMG1GJ8z6TZmv for ; Thu, 05 Mar 2026 19:58: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRgMG0jqWz4Dlx for ; Thu, 05 Mar 2026 19:58:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772740698; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UqXuXeLHZCJNkAnmbGCMR/6LozaBtM/IUTA5UoFWJEM=; b=xrDFlDhvl/V5KwalwX8TSdle0vNazYFY3McGkVRnoC4e1cHlv1cjBwjzNaiNE5by+15gsW oXnwX8C99hXwvwMrK49QJyCPn21p5gSIvd5Iyc9zRoPBGINMZ9vSKpx86otnZsU+eiWzB5 gokmp0V8hWakcJsob27NO5xWKTsZ3ITNp9SIrS5JNZImhTIDu61NhHGFuVGzMpqQSjJI7i e21D/WdYuEPGlGLftHog2kG3Wp+Kk6U2oHAGkanoD9JL5mHsigjf8pGiJuj6e7bOOhAhWz sWxrQc/f0FMJjFAako4SRwCTeKsuPaMAFPd5WTHstilqH9YmAsYlfmyOgqUr6g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772740698; a=rsa-sha256; cv=none; b=dGmO3vfe0jUl0MVKwyUKJ9/mGEqwz8R4NqyaPL0a1Ni8A8oU+rQGLzQ5Skzmh2R0TpRMbL 1XZjKTPC44cC5EhjMAFysmoHm14wuS/mfl0CqAHC+6q8PLGCbBKixO1HDuaHUnGRr9JQoA 0oQySDeE0Naftd+ov6JzxPtg3eCYmncDT6uQL6d3Pen63OGHU3al405N1wiH3mWOYJQ4kx 1dgjWP9890JI6DIEpLxgc3JEQsd3rQPkJC4v0mZhh0vfUmaoG1i4y9N4+R2FboSo3iyZ4D mhk6BHU5X/ZLTCYpib1oTQ159LC2HT2vSzwOiMfpaGwWbRsoaX09HVV5wXOAcA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772740698; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UqXuXeLHZCJNkAnmbGCMR/6LozaBtM/IUTA5UoFWJEM=; b=LfTUJ2dCHcbaFlxDktPCoCeE96x7gfVoxmrU3CLaVstsVw+aYRh2JAbm6GLdkcxIj2LaW+ W/b3iYi+gjP8s7qkLkqThZtRVIZEjRXa6EGm++hRHUgq5Qdl7prKTN+Y2InTVLjIJBc9cD 2ZrgomdPi2FW/pvFwfVT4GC2Xn2Ys4TnpKlgsUsGL7UyzF901uasHr8zXtOUHSdjboFzza 31WGRsWV5VbxskrFTFtvMp9BDipgLJdiCuwS4eSdNHwQqTTgiCoS+yxtWbom5DZ0gL0rA+ Y4WpHYHEDgSIXWMzhHeiDtIzuxNEwTRLFKtqkkGgr/DxYg4Mi7xE18pJ2o2GAw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRgMF74TczrXP for ; Thu, 05 Mar 2026 19:58:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1f98d by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 19:58:17 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: a1789fa30c0b - main - netinet6: Remove support for connecting to IN6ADDR_ANY List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: a1789fa30c0b1e4c20a083c550f0ec2d50e480e4 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 19:58:17 +0000 Message-Id: <69a9e059.1f98d.33da1c36@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=a1789fa30c0b1e4c20a083c550f0ec2d50e480e4 commit a1789fa30c0b1e4c20a083c550f0ec2d50e480e4 Author: Ed Maste AuthorDate: 2026-01-27 21:29:20 +0000 Commit: Ed Maste CommitDate: 2026-03-05 19:57:36 +0000 netinet6: Remove support for connecting to IN6ADDR_ANY RFC4291 section 2.5.2: The unspecified address must not be used as the destination address of IPv6 packets or in IPv6 Routing headers. An IPv6 packet with a source address of unspecified must never be forwarded by an IPv6 router. We disallowed connections to IN6ADDR_ANY by default, as of commit 627e126dbb07 ("netinet6: Disallow connections to IN6ADDR_ANY"). As this is actually disallowed by the RFC, just remove the support. Reported by: bz (in D54306) Reviewed by: bz, glebius Relnotes: yes Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54942 --- sys/netinet6/in6_pcb.c | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/sys/netinet6/in6_pcb.c b/sys/netinet6/in6_pcb.c index 9eb7a59fcf55..d503165979c8 100644 --- a/sys/netinet6/in6_pcb.c +++ b/sys/netinet6/in6_pcb.c @@ -113,14 +113,6 @@ #include #include -SYSCTL_DECL(_net_inet6); -SYSCTL_DECL(_net_inet6_ip6); -VNET_DEFINE_STATIC(int, connect_in6addr_wild) = 0; -#define V_connect_in6addr_wild VNET(connect_in6addr_wild) -SYSCTL_INT(_net_inet6_ip6, OID_AUTO, connect_in6addr_wild, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(connect_in6addr_wild), 0, - "Allow connecting to the unspecified address for connect(2)"); - int in6_pcbsetport(struct in6_addr *laddr, struct inpcb *inp, struct ucred *cred) { @@ -396,16 +388,9 @@ in6_pcbladdr(struct inpcb *inp, struct sockaddr_in6 *sin6, if ((error = sa6_embedscope(sin6, V_ip6_use_defzone)) != 0) return(error); - if (V_connect_in6addr_wild && !CK_STAILQ_EMPTY(&V_in6_ifaddrhead)) { - /* - * If the destination address is UNSPECIFIED addr, - * use the loopback addr, e.g ::1. - */ - if (IN6_IS_ADDR_UNSPECIFIED(&sin6->sin6_addr)) - sin6->sin6_addr = in6addr_loopback; - } else if (IN6_IS_ADDR_UNSPECIFIED(&sin6->sin6_addr)) { + /* RFC4291 section 2.5.2 */ + if (IN6_IS_ADDR_UNSPECIFIED(&sin6->sin6_addr)) return (ENETUNREACH); - } if ((error = prison_remote_ip6(inp->inp_cred, &sin6->sin6_addr)) != 0) return (error); From nobody Thu Mar 5 20:02:02 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRgRb1GWFz6TZwy for ; Thu, 05 Mar 2026 20:02: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRgRZ3tzvz4Fl5 for ; Thu, 05 Mar 2026 20:02:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772740922; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LYJgirwkZ+zjvLQBLgi4RKzNtEiqxJT4+wtgWY5uuPY=; b=rW88sJOoenY0jZgJtjhNiTKKTbmtJG1ntVSnMVUslsVAZO7hvxm8X+EZFLqEaFbtPvv+k1 KP8xgyIO69U0ALYNn6Y2JGVRqx0+v/uMR0qTfXiEkARJ7dcOPWnzjeQvDwGqBqlDJMFr/0 jbdSMUjIrLS8zkoa1Y7MSQwndIxpmoEOm6xsB/5UZCRbKrRH1FkUqki/nuCHTLqtxRxBBt orp8FgvSDidulYuPVduP/vJiIGpwhqSJhx4f7W1izs6vhLisSC8IHQ3/JqziZC6oI3gyQK osnTgJTUWeULEEI186Qf0cEbx7VvxrN3879Y5YAZ5W24kqzjG8VgEZlDczHFoA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772740922; a=rsa-sha256; cv=none; b=Q/jYR7GyyXPw9Ya8fd2DFOLCicr/4gNMADtqeA55XnKk1Oq68aZmaRHm9KD69vB3Wc4jwR MTVmA5OsRqMZLmcakDQJM8ROEB9NYhvIE5fzMRk7MuKl1saxq04LV1Z/FfMH/k3jYE+0Ql 5p+iC2yYPkxkI4o/5PnsUbZ97Vnhk8bbMF2cge3W594txkX6eo+z3RLDpDy39I0W7uI9+N D3j88pIwMSE5pSVXpKVanIYmt/qo3ZDZiak5OBF2p85UQoPn/u8+ibPKZYbxNbl+wkXDXU /TlapXMDUDH3q+MKo/s455LxoQGBJFu8AOuQYIsLnqkCj+4GHCqGjjxbp6aasA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772740922; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LYJgirwkZ+zjvLQBLgi4RKzNtEiqxJT4+wtgWY5uuPY=; b=BXwV0uPlKyyDBU6/oBZR4SSO079N4jgYD8M4RGVkDCNc2xMXZxz5x5q9a7ztBpEu/M4eIG MEg1X/g9SQsJEyfXMnFysOuzQgaemdSqXkdDn20MC+BVryp8LO0kmORI51uGv/chzbGYJ6 LMqo+vYD3pmfJhycKJxzLSOED6TFBfW1AtAN8SxKOp/3o2OeUHajGSWdnbRmPJduSCh+oO up1LXGAiL4ec+tQOkC++DZWwRi4HZCW1kigr9XgdsTcVZEcpyRBcdqKrvB0uZw09i0YRJ+ CrZaegxOzi0lKigR30LshL+Xeka74MdjJPVaf1ps2Z58AOiYB0icpE5zreb1UA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRgRZ3C6zzrry for ; Thu, 05 Mar 2026 20:02:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 20c13 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 20:02:02 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 9cea0f0be79d - main - bsd.linker.mk: Retire support for binutils 2.17.50 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 9cea0f0be79dc080761154cb934db0218ae512f3 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 20:02:02 +0000 Message-Id: <69a9e13a.20c13.14177d46@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=9cea0f0be79dc080761154cb934db0218ae512f3 commit 9cea0f0be79dc080761154cb934db0218ae512f3 Author: Ed Maste AuthorDate: 2026-03-05 18:49:58 +0000 Commit: Ed Maste CommitDate: 2026-03-05 20:01:21 +0000 bsd.linker.mk: Retire support for binutils 2.17.50 GNU binutils 2.17.50 is the last GPLv2 version, and we retained support in FreeBSD while it was part of the in-tree toolchain. The last parts of binutils 2.17.50 were removed in commit 74e8d41e0ac8 ("Retire BINUTILS and BINUTILS_BOOTSTRAP options") and there is no longer a need for the build infrastructure. We retain build-id and ifunc in LINKER_FEATURES unconditionally for now, as they may be tested by 3rd-party Makefiles. We can however stop testing for them in the tree. Reviewed by: imp Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55674 --- share/mk/bsd.linker.mk | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/share/mk/bsd.linker.mk b/share/mk/bsd.linker.mk index 4b3305dc82b3..1349767abff6 100644 --- a/share/mk/bsd.linker.mk +++ b/share/mk/bsd.linker.mk @@ -104,11 +104,9 @@ ${X_}LINKER_VERSION!= echo "${_v:M[1-9]*.[0-9]*}" | \ .undef _ld_version .undef _v ${X_}LINKER_FEATURES= -.if ${${X_}LINKER_TYPE} != "bfd" || ${${X_}LINKER_VERSION} > 21750 ${X_}LINKER_FEATURES+= build-id ${X_}LINKER_FEATURES+= ifunc -.endif -.if ${${X_}LINKER_TYPE} == "bfd" && ${${X_}LINKER_VERSION} > 21750 +.if ${${X_}LINKER_TYPE} == "bfd" ${X_}LINKER_FEATURES+= riscv-relaxations .endif .if ${${X_}LINKER_TYPE} == "lld" && ${${X_}LINKER_VERSION} >= 60000 From nobody Thu Mar 5 20:41:42 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRhKL1R5qz6Td5V for ; Thu, 05 Mar 2026 20:41: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRhKL0nx2z4J3n for ; Thu, 05 Mar 2026 20:41:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772743302; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=IMvWC2QF4l5XEY3xlIM1lNKwU4zOlHhYImtyFqV2C+k=; b=W3r969CpgBY8Xgr47v82c3DAxtH0Vb85OoOyBg//fdsm3ow6b4B7YVrIPFEYb70Ptb438B 9TFzTRPwFvNGGwZ7H7qqx6RyYjSgAxBn65dCg9YNKO5yVV+1dvXpnizHGMBGRGMVZtIJou xQWUoucSNGiBNjpxUj3OdGclnkUb2ke5RVpjH6EcP+PVnU5p4X1jlY4guLsgml99ujAeaW jW9Vu1rDl5GbxeVbXAB/hH+ndsNXztM1ey3hb6x/a5j1rVB2EJA6YKAWfXBxKnoYktBRbW aCWYZ71QOqVReKa3jh0tZixk4cKeT1DGXXPo19FW9LBG7HfGnwK9qrgpjfGoSQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772743302; a=rsa-sha256; cv=none; b=VFmnKGNDVHaStmqnFDYWRMJCRTChS+FN5yiXQBGio73zp4XaxD/4r0ZhhUEBG7xOAiOE6u TD6jQ1GMNalugR+zIrNKuINK6VszJ1wmP1dUejv7g92u9LKmmRU51iWZuk33Xw6HtsceVr 7Liis+jMxXKAUPkS12wPijJOsVJi5bIrYxi2jEA9we/BjWXCK7kY6oPGaUNwj1mE3QAXx/ 9j+9TaAr2VKUlXMnv8p57CsDW82/Czf9Iw7H9LLvTtOIdj1NSpku+FU1PlnqR4D5ifnrOq 7rJ0aqVLXMrGoPW+yA8oF2p9DvdA5wE5bQek4GiRv7vdcVxU4qgpGwzww1rA0Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772743302; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=IMvWC2QF4l5XEY3xlIM1lNKwU4zOlHhYImtyFqV2C+k=; b=l0e7k7GC1T3uqHNtFacqHcTrYU4gMvBGDyx1YvAcxkQkAZBPExFLDwh9KCo+rso2j7hSLP RVx8ICxIPycMszidVNbWjDsr0S3dP4aeZwhN3/xf0jXiPspiHcDZ4TPyrAhGX2sG0nXDR8 h6zXQd/ewRGNLb2rfzJATKA0WdjM0tOzqs4AdVJ44Uw1arI5bFY6zxyDYztdaesRVpQH9W FOoqBRraoDS1gQLHmfy+J/FxyO5WhlOniG1fYtG12/RHtW4XBf6sv1cSBdfm9L1YihRdgR JwPxyE19ALPHrbReuO9tzQGyDMk2hTjSSATL5+JQO0gCAQKSHLi+DR1buEaNCQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRhKL0Mt1zsQT for ; Thu, 05 Mar 2026 20:41:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 24715 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 20:41:42 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 35da55c28dbb - main - iwx: Fix 32-bit compilation List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 35da55c28dbb56dd7056b7863efc5b547950d885 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 20:41:42 +0000 Message-Id: <69a9ea86.24715.1743999a@gitrepo.freebsd.org> The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=35da55c28dbb56dd7056b7863efc5b547950d885 commit 35da55c28dbb56dd7056b7863efc5b547950d885 Author: Olivier Certner AuthorDate: 2026-03-05 12:31:51 +0000 Commit: Olivier Certner CommitDate: 2026-03-05 20:40:53 +0000 iwx: Fix 32-bit compilation - Avoid shifts wider than integer types, by wrapping the corresponding checks into '#if __SIZEOF_SIZE_T__ > 32' blocks. 'bus_addr_t' currently has the same width as 'size_t' on all architectures (and this is not going to change for 32-bit architectures). - Use appropriate printf(3) format for 'wk_keytsc'. Reviewed by: adrian MFC after: 1 minute MFC to: stable/15 Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55667 --- sys/dev/iwx/if_iwx.c | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/sys/dev/iwx/if_iwx.c b/sys/dev/iwx/if_iwx.c index 8f11e6a414e7..ea1ba513734a 100644 --- a/sys/dev/iwx/if_iwx.c +++ b/sys/dev/iwx/if_iwx.c @@ -155,6 +155,7 @@ #include #include +#include #include #include #include @@ -5818,15 +5819,21 @@ iwx_tx(struct iwx_softc *sc, struct mbuf *m, struct ieee80211_node *ni) desc->tbs[0].tb_len = htole16(IWX_FIRST_TB_SIZE); paddr = htole64(data->cmd_paddr); memcpy(&desc->tbs[0].addr, &paddr, sizeof(paddr)); - if (data->cmd_paddr >> 32 != (data->cmd_paddr + le32toh(desc->tbs[0].tb_len)) >> 32) +#if __SIZEOF_SIZE_T__ > 32 + if (data->cmd_paddr >> 32 != (data->cmd_paddr + + le32toh(desc->tbs[0].tb_len)) >> 32) DPRINTF(("%s: TB0 crosses 32bit boundary\n", __func__)); +#endif desc->tbs[1].tb_len = htole16(sizeof(struct iwx_cmd_header) + txcmd_size + hdrlen + pad - IWX_FIRST_TB_SIZE); paddr = htole64(data->cmd_paddr + IWX_FIRST_TB_SIZE); memcpy(&desc->tbs[1].addr, &paddr, sizeof(paddr)); - if (data->cmd_paddr >> 32 != (data->cmd_paddr + le32toh(desc->tbs[1].tb_len)) >> 32) +#if __SIZEOF_SIZE_T__ > 32 + if (data->cmd_paddr >> 32 != (data->cmd_paddr + + le32toh(desc->tbs[1].tb_len)) >> 32) DPRINTF(("%s: TB1 crosses 32bit boundary\n", __func__)); +#endif /* Other DMA segments are for data payload. */ for (i = 0; i < nsegs; i++) { @@ -5834,8 +5841,12 @@ iwx_tx(struct iwx_softc *sc, struct mbuf *m, struct ieee80211_node *ni) desc->tbs[i + 2].tb_len = htole16(seg->ds_len); paddr = htole64(seg->ds_addr); memcpy(&desc->tbs[i + 2].addr, &paddr, sizeof(paddr)); - if (data->cmd_paddr >> 32 != (data->cmd_paddr + le32toh(desc->tbs[i + 2].tb_len)) >> 32) - DPRINTF(("%s: TB%d crosses 32bit boundary\n", __func__, i + 2)); +#if __SIZEOF_SIZE_T__ > 32 + if (data->cmd_paddr >> 32 != (data->cmd_paddr + + le32toh(desc->tbs[i + 2].tb_len)) >> 32) + DPRINTF(("%s: TB%d crosses 32bit boundary\n", __func__, + i + 2)); +#endif } bus_dmamap_sync(ring->data_dmat, data->map, BUS_DMASYNC_PREWRITE); @@ -11079,8 +11090,8 @@ iwx_key_set(struct ieee80211vap *vap, const struct ieee80211_key *k) cmd.common.sta_id = IWX_STATION_ID; cmd.transmit_seq_cnt = htole64(k->wk_keytsc); - IWX_DPRINTF(sc, IWX_DEBUG_KEYMGMT, "%s: k->wk_keytsc=%lu\n", __func__, - k->wk_keytsc); + IWX_DPRINTF(sc, IWX_DEBUG_KEYMGMT, "%s: k->wk_keytsc=%" PRIu64 "\n", + __func__, k->wk_keytsc); status = IWX_ADD_STA_SUCCESS; err = iwx_send_cmd_pdu_status(sc, IWX_ADD_STA_KEY, sizeof(cmd), &cmd, From nobody Thu Mar 5 21:39:16 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRjbr0WKPz6Tj5g; Thu, 05 Mar 2026 21:39:20 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from mx-01.divo.sbone.de (legacy1.sbone.de [80.151.10.34]) (using TLSv1.3 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 "E7" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRjbq49cJz4Nww; Thu, 05 Mar 2026 21:39:19 +0000 (UTC) (envelope-from bz@FreeBSD.org) Authentication-Results: mx1.freebsd.org; none 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 88B3BA64805; Thu, 05 Mar 2026 21:38:58 +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 B460F2D029E7; Thu, 5 Mar 2026 21:39:17 +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 d3taayeudLuA; Thu, 5 Mar 2026 21:39:16 +0000 (UTC) Received: from nv.t4-02.sbone.de (nv.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:22]) (using 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 738D82D029D8; Thu, 5 Mar 2026 21:39:16 +0000 (UTC) Date: Thu, 5 Mar 2026 21:39:16 +0000 (UTC) From: "Bjoern A. Zeeb" To: John Baldwin cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 54bf594851f6 - main - libc/quad: Switch to per-arch lists of symbols In-Reply-To: <69a9d47b.1928a.7f6e7682@gitrepo.freebsd.org> Message-ID: References: <69a9d47b.1928a.7f6e7682@gitrepo.freebsd.org> X-OpenPGP-Key-Id: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:3320, ipnet:80.144.0.0/13, country:DE] X-Rspamd-Queue-Id: 4fRjbq49cJz4Nww X-Spamd-Bar: ---- On Thu, 5 Mar 2026, John Baldwin wrote: > The branch main has been updated by jhb: > > URL: https://cgit.FreeBSD.org/src/commit/?id=54bf594851f671e231d2786cdacaf68f290ff738 > > commit 54bf594851f671e231d2786cdacaf68f290ff738 > Author: John Baldwin > AuthorDate: 2026-03-05 19:07:09 +0000 > Commit: John Baldwin > CommitDate: 2026-03-05 19:07:09 +0000 > > libc/quad: Switch to per-arch lists of symbols > > This more closely mirrors libc/quad/Makefile.inc and is easier to > read. > > Reviewed by: brooks > Differential Revision: https://reviews.freebsd.org/D55658 > --- > lib/libc/quad/Symbol.map | 43 +++++++++++++++++++------------------------ > 1 file changed, 19 insertions(+), 24 deletions(-) I find this in an i386 buildworld (from universe): 4135 ===> lib/libc (obj,all,install) 4136 :1336:2: error: unterminated conditional directive 4137 1336 | #ifdef __i386__ 4138 | ^ 4139 1 error generated. I assume it's from this? Yes, seems there is an #endif missing. -- Bjoern A. Zeeb r15:7 From nobody Thu Mar 5 23:44:54 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmNk5jBXz6Ts6c for ; Thu, 05 Mar 2026 23:44: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmNk3QRvz3LfL for ; Thu, 05 Mar 2026 23:44:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754294; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6VBkHmcTPxuFs6knyrm2sDWE15lP3fGEaAYHQBSWvvs=; b=I3SAkiDECFQ4ss5MWpXQaE/IpE/Js4tW0mUbjlOL3nzv2tGiVZ/jvEoeUpUj3AtfKhnpav J4ItRBNA/Q3NqEl/lWsd4ckOZZdjKmq1MZclrVwt0ZMRaFfxMLURgqKmJHfa/A65SQNBau rdh53CT6GzMLA9Eby0ehQI41cQdBPIyIS0cFJjT9zvS4a261K1MbOf5k9cinhtBcPSeJ7L N4amu1AuCL1wjubdq4zvZmi/6Wg19tWoHyTfeZFJVQMLC5Ahe9Tz0lVSQ9NvWkZDPPiquJ l8Wih/a4lXf/N7Jax4FcJ7pxrSjPmCbEwJXLA7aKc9IV2g7nXd4VArB5jA4B7w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754294; a=rsa-sha256; cv=none; b=A0S3Jq5dHnE8OpRblPds31eGoA3Vc9X11QfOHZtKy4MJ/6SPDrPptF/uhgxuzwzjkyD4Hk tQ2N9OCVAKuyeWRn4L9cQbZw04P8/Q3uQPyXepOT0C6oQRe2NOQJJ7aAYDnDm2UTDGxfBI QOssSeSYMGMux1xznpfi76lnCxuCJgi5z3GmxAuNyI60u84gdIE+4OuOsKtDGSR9pu97Rm rvSrIFAU0EQ3NWmzhtzdFZmGKvyKYyisqHTO6Lu2nW9hpL/W3Uc6Id3nCGrhgH8pCCQ7cl ThRNRiiL2ozxYfsC7KJDtfLBMVluLz8IKwclMe6QkDPuLvmtyFNhZluIT1j2gg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754294; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6VBkHmcTPxuFs6knyrm2sDWE15lP3fGEaAYHQBSWvvs=; b=K4Ztg+6bp21tdej8e6UPu/k1g9k1vSkVIfQGvLLOwJZbGJ5eLMsaPEbNX4RwDN/pRvmMQ2 OSmRJnWawBBsmeB0/X3255Eofs7pFtbUGeObhMzt7AfeGV0apiOqk/4C38W3+c4b+I7qcA xG04cJE667Qgw6qlgVCY3diYGcZMQQiaPnatEmCsd9Bi+mFJDAJUs7JpITDN0jYna0Vd/H ZHRWUVZXwTB0ks5KtDFYuRQh19eHAD/CgRLhfKt6zSORoCEAjYVUCHWHB4d3ZYA9cBQllq +WL6ly2rrncuj+Zpd9T4aDx4j1JrAH8Ys5F2l99NQqoCnPXtyrCf3D0+pu/N6g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmNk2l10zyJ7 for ; Thu, 05 Mar 2026 23:44:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3e2ad by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:44:54 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 347cec10e25e - main - amd64: align stack on 16 bytes when calling into a EFIRT method List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 347cec10e25eacb2906a0a8105eff036850db766 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:44:54 +0000 Message-Id: <69aa1576.3e2ad.945c091@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=347cec10e25eacb2906a0a8105eff036850db766 commit 347cec10e25eacb2906a0a8105eff036850db766 Author: Konstantin Belousov AuthorDate: 2026-03-05 08:37:23 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:43:55 +0000 amd64: align stack on 16 bytes when calling into a EFIRT method Reported by: Abdelkader Boudih Sponsored by: The FreeBSD Foundation MFC after: 1 week --- sys/amd64/amd64/efirt_support.S | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/amd64/amd64/efirt_support.S b/sys/amd64/amd64/efirt_support.S index 98063ad561aa..54578f573750 100644 --- a/sys/amd64/amd64/efirt_support.S +++ b/sys/amd64/amd64/efirt_support.S @@ -58,6 +58,7 @@ ENTRY(efi_rt_arch_call) cmovbl %eax, %ecx shll $3, %ecx subq %rcx, %rsp + andq $~0xf, %rsp cmpl $0, %ebx jz 1f From nobody Thu Mar 5 23:48:16 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSc3ptSz6TrfG for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSc2Grcz3MN9 for ; Thu, 05 Mar 2026 23:48:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754496; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I/9mLdzNdS35cOGdYQpRy1rFftUahVMJWUJ3jpsuhmM=; b=X8SMmdOFOBp5rnSqC5GkD38ci2ST+1zlf1/fAKfnuffV8hpmQnSvUfdIv3hpmEH4LlpcwO YUZgVAFebjsCf8XnxkxG64NyVJBBvZoG2xXomoG6LdyZg8hFWmoHg+odt7CuXWMpZj9o+M vMxtWnFG1xBIYnDOEjVFzklCeRM7mr2ytLDzLIOmbuCFRmPnt+a/BT364u5mwfyN2IGvZj e/vsBRlm5LJ9yUqIuP/Weazshg1ilY3y4FIoxAq0VzZozptaHtQaR/4tybACHOct4vNUe2 6xxwBQmoq7xTthRaHFapA5NzMnmNw5sLDfVS5s6zmq/JYjxgCpjw6fjfXaeevw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754496; a=rsa-sha256; cv=none; b=HWA7G76EqV9kmUbSTrof4id82V4bGdGuVVaZ5B/pGQQX4Xct6D6+8h1hKtG+SnUQvJ7Pz/ wz0obt1f0i+BSh7G6s4tjYK1l15JNIySKzA4en0pS6kjqyL/7Sj3vRNUDcQE3+aDplON25 Ji+2tb86al+od/sh3IqVWrnEd8vkmf11r/K7dR0JfBbJJxHhRV/u+oUlr1Cx8P0FU5bGI2 FLGx15ONdul7zaZMU2vC3l3raioNG+98yprSOOKUWPhxmAho6aliJswO56Tuy7s9hHuh9H bkj/Ctr2o7zabs2052ID7y9Kj7n9Cieu2kKzYMDDM4qskitYmUwg7J6VQi69ow== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754496; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I/9mLdzNdS35cOGdYQpRy1rFftUahVMJWUJ3jpsuhmM=; b=IIgtP3snxVKi3gqXElGmHXvJXFnNVKLG6nhViuV5nNt+50fJ4ZoOTMMEfLHZ7BhJFXmg70 +T05GXFSYl5nTs6iK/LBfBaH98c9IQYRgGL0T1tTgbCdarwQhjtpHJsQi/v+s20qk5cqBF GoVbkZxRn6P29EKHg0vpKBZplUZdlTI0i0ptxkl3w1GZkiuf6ET5ZhlaL06GiB17st3PXP v6WfWhnXpq2LtL5PRs6VKWeZEnSIgj86v3kNWfPq+uTLqs9uU7jg0CheXsdh4WL8kiliyf Nn3UhgOGLbkjhQs50BNZgK572Y837xH3xtg7aIXQS9b8IMWnE7VGCJtHFG6/Bw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSc1blTzyZF for ; Thu, 05 Mar 2026 23:48:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3f286 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:16 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: ed87040311b8 - main - zfs rename: properly cleanup on errors occuring before zfs_do_rename() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: ed87040311b88e2c95a791aa049f2c37c857f048 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:16 +0000 Message-Id: <69aa1640.3f286.50f64742@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=ed87040311b88e2c95a791aa049f2c37c857f048 commit ed87040311b88e2c95a791aa049f2c37c857f048 Author: Konstantin Belousov AuthorDate: 2026-03-05 02:57:34 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:53 +0000 zfs rename: properly cleanup on errors occuring before zfs_do_rename() Reported and tested by: arrowd Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55539 --- .../openzfs/module/os/freebsd/zfs/zfs_vnops_os.c | 23 +++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c b/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c index 05ac77741d4f..31654ec82392 100644 --- a/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c +++ b/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c @@ -5527,15 +5527,24 @@ zfs_freebsd_rename(struct vop_rename_args *ap) } #endif - if (error == 0) + if (error == 0) { error = zfs_do_rename(fdvp, &fvp, ap->a_fcnp, tdvp, &tvp, ap->a_tcnp, ap->a_fcnp->cn_cred); - - vrele(fdvp); - vrele(fvp); - vrele(tdvp); - if (tvp != NULL) - vrele(tvp); + vrele(fdvp); + vrele(fvp); + vrele(tdvp); + if (tvp != NULL) + vrele(tvp); + } else { + if (tdvp == tvp) + vrele(tdvp); + else + vput(tdvp); + if (tvp != NULL) + vput(tvp); + vrele(fdvp); + vrele(fvp); + } return (error); } From nobody Thu Mar 5 23:48:17 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSd522nz6Trmt for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSd2csDz3MKv for ; Thu, 05 Mar 2026 23:48:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754497; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=MFF2u/YRkINsDO9sGGU5OsdBZqUQcrKMKLPnY6HcNvs=; b=GbeGGO6hORCS5FI85zHFTok/Q7/FL+cPDiqr1qMOhmq4o/ZdZntBprqMZ4D3yAX5gYdXPZ jhAek9hxAdPvLJ0LvBH8yWGC1xTIzGRadbOd804tArmzNV21PZLGknl5YJ7HucOzxTxpCI MXGuREP30jFCi7ApnCQXi08M1tyWWgEcJaHA2CnGRvnCpPoS+C+cM0xzEOX4C/4RF/8sac IeD2MW+utwbaPQbc5pNak0s4q5DT5QRxnQxXpCcsr/om1afOdC00ZLB70Sk5qvQQ/YZODm PUHT4ETAe61B0n8nR3S8GpRurWwTrPQk4SmuvhzOA9EBU0011ulh3YnlcIgbDw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754497; a=rsa-sha256; cv=none; b=ODyUTVJr2SFN8FohQyPXaCkXwetZZHDeYQzRp/+D6gehp/TZRq3V1R6BdwPsoNPSoSk2Tm QfdsMhfWB+SUM4IqMFEoNotC4bwMwJKoeVNrjkzWIMRMdiaGDA0BPqn31V5Gx1QI3D7nY7 zuKOJCcX5JVmo+slWgskjIcZfO3rPLx7YwFld+ekRcRVZlw02Hmatn6AskE1qIyWzoDHFe jLDeqosr7zB6ytdoeSIbAruGk+FyTIIcjMIO2br2gllP362IibX41MUmDN1EnVX1TkwFSl dpL/W+imwTt1XRWCkgVPjYlK+paWFj+GvTwTT/cGBr4uPdvbBReNZ/rAsdjZ7w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754497; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=MFF2u/YRkINsDO9sGGU5OsdBZqUQcrKMKLPnY6HcNvs=; b=QkRg8z21ePI8cTzKumIa+u4xBQtydXpp6aSAkaY4+2oONydcNTVYWqr3fNKccfu7EvCS/V mU1oN8ATZyR22BPBVy5lx/uPX+EAeykVi7TXoZ9qfWDfklrE5fekkm4Wik3fzoB9h5UrpP HPzg80PEvwwz4D1HTN4hSjB/H8eCa45uGsy4coED94bGMJEDSZOfjQwWo8aU8ekBO8Bcob YtzDanC06aSh6SRLHhZdJpLJZgZE++NREhG5AkoE7a2j/jgosq0khH8+8J+vexaP+kbVPY uWDi6lPTTZKpei1xFrU9cZerDgK4dxkF9tS/HyueOsXHoRtNQw/3aZxmI3PbTw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSd1yNWzygK for ; Thu, 05 Mar 2026 23:48:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3ea28 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:17 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: e486066cf48a - main - VOP_RENAME(9): add flags argument List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: e486066cf48a89ba87fab6b3d2b56f271f50439b Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:17 +0000 Message-Id: <69aa1641.3ea28.92248b4@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=e486066cf48a89ba87fab6b3d2b56f271f50439b commit e486066cf48a89ba87fab6b3d2b56f271f50439b Author: Konstantin Belousov AuthorDate: 2026-02-26 18:22:48 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:53 +0000 VOP_RENAME(9): add flags argument Reviewed by: markj Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55539 --- sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c | 3 +++ sys/fs/fuse/fuse_vnops.c | 4 ++++ sys/fs/msdosfs/msdosfs_vnops.c | 5 +++++ sys/fs/nfsclient/nfs_clvnops.c | 6 ++++++ sys/fs/nfsserver/nfs_nfsdport.c | 2 +- sys/fs/nullfs/null_vnops.c | 3 ++- sys/fs/p9fs/p9fs_vnops.c | 5 +++++ sys/fs/smbfs/smbfs_vnops.c | 5 +++++ sys/fs/tmpfs/tmpfs_vnops.c | 5 +++++ sys/fs/unionfs/union_vnops.c | 7 ++++++- sys/kern/vfs_syscalls.c | 2 +- sys/kern/vnode_if.src | 1 + sys/ufs/ufs/ufs_vnops.c | 7 +++++++ 13 files changed, 51 insertions(+), 4 deletions(-) diff --git a/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c b/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c index 31654ec82392..04fd772603b9 100644 --- a/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c +++ b/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c @@ -5527,6 +5527,9 @@ zfs_freebsd_rename(struct vop_rename_args *ap) } #endif + if (error == 0 && ap->a_flags != 0) + error = EOPNOTSUPP; + if (error == 0) { error = zfs_do_rename(fdvp, &fvp, ap->a_fcnp, tdvp, &tvp, ap->a_tcnp, ap->a_fcnp->cn_cred); diff --git a/sys/fs/fuse/fuse_vnops.c b/sys/fs/fuse/fuse_vnops.c index 49014a1cdd35..c66d3bcf01e0 100644 --- a/sys/fs/fuse/fuse_vnops.c +++ b/sys/fs/fuse/fuse_vnops.c @@ -2254,6 +2254,10 @@ fuse_vnop_rename(struct vop_rename_args *ap) err = EXTERROR(EXDEV, "Cross-device rename"); goto out; } + if (ap->a_flags != 0) { + err = EOPNOTSUPP; + goto out; + } cache_purge(fvp); /* diff --git a/sys/fs/msdosfs/msdosfs_vnops.c b/sys/fs/msdosfs/msdosfs_vnops.c index 6dfac1b4ebd2..3e28a7ce9d05 100644 --- a/sys/fs/msdosfs/msdosfs_vnops.c +++ b/sys/fs/msdosfs/msdosfs_vnops.c @@ -970,6 +970,11 @@ msdosfs_rename(struct vop_rename_args *ap) goto abortit; } + if (ap->a_flags != 0) { + error = EOPNOTSUPP; + goto abortit; + } + /* * If source and dest are the same, do nothing. */ diff --git a/sys/fs/nfsclient/nfs_clvnops.c b/sys/fs/nfsclient/nfs_clvnops.c index 8e4d58c0e554..edd6974a50d0 100644 --- a/sys/fs/nfsclient/nfs_clvnops.c +++ b/sys/fs/nfsclient/nfs_clvnops.c @@ -2196,6 +2196,12 @@ nfs_rename(struct vop_rename_args *ap) error = EXDEV; goto out; } + + if (ap->a_flags != 0) { + error = EOPNOTSUPP; + goto out; + } + nmp = VFSTONFS(fvp->v_mount); if (fvp == tvp) { diff --git a/sys/fs/nfsserver/nfs_nfsdport.c b/sys/fs/nfsserver/nfs_nfsdport.c index 833203cd86fc..350785487a2b 100644 --- a/sys/fs/nfsserver/nfs_nfsdport.c +++ b/sys/fs/nfsserver/nfs_nfsdport.c @@ -1715,7 +1715,7 @@ out: if (error == 0) { error = VOP_RENAME(fromndp->ni_dvp, fromndp->ni_vp, &fromndp->ni_cnd, tondp->ni_dvp, tondp->ni_vp, - &tondp->ni_cnd); + &tondp->ni_cnd, 0); lockmgr(&mp->mnt_renamelock, LK_RELEASE, 0); vfs_rel(mp); } else { diff --git a/sys/fs/nullfs/null_vnops.c b/sys/fs/nullfs/null_vnops.c index d4baabeb40ab..a372a46bc6c6 100644 --- a/sys/fs/nullfs/null_vnops.c +++ b/sys/fs/nullfs/null_vnops.c @@ -741,7 +741,8 @@ null_rename(struct vop_rename_args *ap) ltvp = NULL; } - error = VOP_RENAME(lfdvp, lfvp, ap->a_fcnp, ltdvp, ltvp, ap->a_tcnp); + error = VOP_RENAME(lfdvp, lfvp, ap->a_fcnp, ltdvp, ltvp, ap->a_tcnp, + ap->a_flags); vrele(fdvp); vrele(fvp); vrele(tdvp); diff --git a/sys/fs/p9fs/p9fs_vnops.c b/sys/fs/p9fs/p9fs_vnops.c index 2ed1be82b57f..e64d7840f7f9 100644 --- a/sys/fs/p9fs/p9fs_vnops.c +++ b/sys/fs/p9fs/p9fs_vnops.c @@ -2084,6 +2084,11 @@ p9fs_rename(struct vop_rename_args *ap) goto out; } + if (ap->a_flags != 0) { + error = EOPNOTSUPP; + goto out; + } + /* warning if you are renaming to the same name */ if (fvp == tvp) error = 0; diff --git a/sys/fs/smbfs/smbfs_vnops.c b/sys/fs/smbfs/smbfs_vnops.c index e960d8d78b66..3a6fcf862be2 100644 --- a/sys/fs/smbfs/smbfs_vnops.c +++ b/sys/fs/smbfs/smbfs_vnops.c @@ -577,6 +577,11 @@ smbfs_rename(struct vop_rename_args *ap) goto out; } + if (ap->a_flags != 0) { + error = EOPNOTSUPP; + goto out; + } + if (tvp && vrefcnt(tvp) > 1) { error = EBUSY; goto out; diff --git a/sys/fs/tmpfs/tmpfs_vnops.c b/sys/fs/tmpfs/tmpfs_vnops.c index 341c88e19115..6b32f53b3363 100644 --- a/sys/fs/tmpfs/tmpfs_vnops.c +++ b/sys/fs/tmpfs/tmpfs_vnops.c @@ -993,6 +993,11 @@ tmpfs_rename(struct vop_rename_args *v) goto out; } + if (v->a_flags != 0) { + error = EOPNOTSUPP; + goto out; + } + /* If source and target are the same file, there is nothing to do. */ if (fvp == tvp) { error = 0; diff --git a/sys/fs/unionfs/union_vnops.c b/sys/fs/unionfs/union_vnops.c index 63e5cd54ade5..cfa0f4ab768e 100644 --- a/sys/fs/unionfs/union_vnops.c +++ b/sys/fs/unionfs/union_vnops.c @@ -1413,6 +1413,11 @@ unionfs_rename(struct vop_rename_args *ap) goto unionfs_rename_abort; } + if (ap->a_flags != 0) { + error = EOPNOTSUPP; + goto unionfs_rename_abort; + } + /* Renaming a file to itself has no effect. */ if (fvp == tvp) goto unionfs_rename_abort; @@ -1581,7 +1586,7 @@ unionfs_rename(struct vop_rename_args *ap) if (rfvp == rtvp) goto unionfs_rename_abort; - error = VOP_RENAME(rfdvp, rfvp, fcnp, rtdvp, rtvp, tcnp); + error = VOP_RENAME(rfdvp, rfvp, fcnp, rtdvp, rtvp, tcnp, ap->a_flags); if (error == 0) { if (rtvp != NULL && rtvp->v_type == VDIR) diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 68f155de3db2..be296f41809e 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -3887,7 +3887,7 @@ again1: out: if (error == 0) { error = VOP_RENAME(fromnd.ni_dvp, fromnd.ni_vp, &fromnd.ni_cnd, - tond.ni_dvp, tond.ni_vp, &tond.ni_cnd); + tond.ni_dvp, tond.ni_vp, &tond.ni_cnd, 0); NDFREE_PNBUF(&fromnd); NDFREE_PNBUF(&tond); } else { diff --git a/sys/kern/vnode_if.src b/sys/kern/vnode_if.src index 3faefb607f24..6b7448d9f1df 100644 --- a/sys/kern/vnode_if.src +++ b/sys/kern/vnode_if.src @@ -336,6 +336,7 @@ vop_rename { IN WILLRELE struct vnode *tdvp; IN WILLRELE struct vnode *tvp; IN struct componentname *tcnp; + IN u_int flags; }; diff --git a/sys/ufs/ufs/ufs_vnops.c b/sys/ufs/ufs/ufs_vnops.c index 736c5a66267e..429e6b5c8dd7 100644 --- a/sys/ufs/ufs/ufs_vnops.c +++ b/sys/ufs/ufs/ufs_vnops.c @@ -1255,6 +1255,7 @@ ufs_rename( struct vnode *a_tdvp; struct vnode *a_tvp; struct componentname *a_tcnp; + u_int a_flags; } */ *ap) { struct vnode *tvp = ap->a_tvp; @@ -1293,6 +1294,12 @@ ufs_rename( goto releout; } + if (ap->a_flags != 0) { + error = EOPNOTSUPP; + mp = NULL; + goto releout; + } + fdvp_s = fvp_s = tdvp_s = tvp_s = SEQC_MOD; relock: /* From nobody Thu Mar 5 23:48:18 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSf42RNz6Ts6y for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSf2kVfz3MBn for ; Thu, 05 Mar 2026 23:48:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754498; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=pNu/riE2+qyntcklDcWfnu8vZua1gEzftF1XnFx+rUU=; b=xKPHDiKmO+VlNM9+5nCkfiqwX88BuN3nTnHiXJGd6uSJEUqsOubfpAmG1Gsl35OEqXBITh qKbWwYr879G+WglBc9NWURkIWO55yh4kjijy0NK92b2/JRueJPDplx+k+NV4vNfnQjG6SU /iUDLgZ6ovMogCnVk80D1e2HqCXV0uMklzU4IqqAwzX5E08filiJW8tREO90Y7UyEHK7Wz ur+Z7O9nDUbboNSgcUzdwthd18z2VxCvlSjALrvjaeZysUVwEhRRb9+9OqDV5zltMOlv8W FpGF074rFMcp7MNauxmVCBagP3Nleqx0F87LmHj9zmH/dukVgS8zwuDVEnf9Jw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754498; a=rsa-sha256; cv=none; b=AK2EIvmWBzO+JIgZdZdSjWqltBwLlhraRLujZnNg51W9uHBQ+UigsmLZAs6g/1jdq8y/wn vhUK4/+1tzooaVMy3mJvaDR/Ux6xmnfLQNMSNSuAr/C5A1WxPmsDpcevlPY9f+SwmNlsVx vjEXGiCB+J646oaSChM0YafOcKLWQev+SqrOEGRS139mrffN0QI6KwlZjlvjUAmNqkJdzx iY8UZKjDNf+WAI5phnqxyp1vkyR0ha654NUMM4p7QbHzDtiFKHbep3anMuVv+H8Ctbdcfc p9RyKrkdNJDYK+xtFbmJ13i8L0NeQ+NhAbFYoKT6L6lMcOsJ7tnRwI2DhjCFAg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754498; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=pNu/riE2+qyntcklDcWfnu8vZua1gEzftF1XnFx+rUU=; b=kWg0tNPJUVigpnVzKEodnA9XMLggNQ/baMB6khUG0Wbf11/kAsdxrZZSxEYc6vfeLkNYrd GlFLrKw/cMiRQCbEzr32kSfOAdQdiuLY9qy2F4fYNixAUqZLjL9lSaeKiXghYiOTea9SqR cG3fNdQzxK6JnrnBBRg5ewEip2WezXUtcA0ZYMQubdFt2U2wNbMIf+xYw/vwt6nwEJVj2e CfB5M2WYtypTw3XdyyO3MrMOg/+NoWM0CmqhBKaqfqC1SYuPf80XSoBrBInHhr+rNOAZl6 t9Pd2ryG5a1aOsp+4D6OfqCDGG4NHf+nU5a7Za61tW/9lvR2QgMycy52ffjeSw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSf26RBzyLV for ; Thu, 05 Mar 2026 23:48:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3d266 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:18 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 1f3020067ab3 - main - kern_renameat(9): add flags argument List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 1f3020067ab3f3c5043d01ea1e3a3d2998a39d4a Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:18 +0000 Message-Id: <69aa1642.3d266.4b356432@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=1f3020067ab3f3c5043d01ea1e3a3d2998a39d4a commit 1f3020067ab3f3c5043d01ea1e3a3d2998a39d4a Author: Konstantin Belousov AuthorDate: 2026-02-26 18:30:14 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:53 +0000 kern_renameat(9): add flags argument Reviewed by: markj Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55539 --- sys/compat/linux/linux_file.c | 4 ++-- sys/kern/vfs_syscalls.c | 8 ++++---- sys/sys/syscallsubr.h | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/sys/compat/linux/linux_file.c b/sys/compat/linux/linux_file.c index ca089585bb95..43ccac0308d3 100644 --- a/sys/compat/linux/linux_file.c +++ b/sys/compat/linux/linux_file.c @@ -811,7 +811,7 @@ linux_rename(struct thread *td, struct linux_rename_args *args) { return (kern_renameat(td, AT_FDCWD, args->from, AT_FDCWD, - args->to, UIO_USERSPACE)); + args->to, UIO_USERSPACE, 0)); } #endif @@ -858,7 +858,7 @@ linux_renameat2(struct thread *td, struct linux_renameat2_args *args) olddfd = (args->olddfd == LINUX_AT_FDCWD) ? AT_FDCWD : args->olddfd; newdfd = (args->newdfd == LINUX_AT_FDCWD) ? AT_FDCWD : args->newdfd; return (kern_renameat(td, olddfd, args->oldname, newdfd, - args->newname, UIO_USERSPACE)); + args->newname, UIO_USERSPACE, 0)); } #ifdef LINUX_LEGACY_SYSCALLS diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index be296f41809e..4409b0295587 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -3720,7 +3720,7 @@ sys_rename(struct thread *td, struct rename_args *uap) { return (kern_renameat(td, AT_FDCWD, uap->from, AT_FDCWD, - uap->to, UIO_USERSPACE)); + uap->to, UIO_USERSPACE, 0)); } #ifndef _SYS_SYSPROTO_H_ @@ -3736,7 +3736,7 @@ sys_renameat(struct thread *td, struct renameat_args *uap) { return (kern_renameat(td, uap->oldfd, uap->old, uap->newfd, uap->new, - UIO_USERSPACE)); + UIO_USERSPACE, 0)); } #ifdef MAC @@ -3766,7 +3766,7 @@ kern_renameat_mac(struct thread *td, int oldfd, const char *old, int newfd, int kern_renameat(struct thread *td, int oldfd, const char *old, int newfd, - const char *new, enum uio_seg pathseg) + const char *new, enum uio_seg pathseg, u_int flags) { struct mount *mp, *tmp; struct vnode *tvp, *fvp, *tdvp; @@ -3887,7 +3887,7 @@ again1: out: if (error == 0) { error = VOP_RENAME(fromnd.ni_dvp, fromnd.ni_vp, &fromnd.ni_cnd, - tond.ni_dvp, tond.ni_vp, &tond.ni_cnd, 0); + tond.ni_dvp, tond.ni_vp, &tond.ni_cnd, flags); NDFREE_PNBUF(&fromnd); NDFREE_PNBUF(&tond); } else { diff --git a/sys/sys/syscallsubr.h b/sys/sys/syscallsubr.h index a714ecf9412b..8d546428820e 100644 --- a/sys/sys/syscallsubr.h +++ b/sys/sys/syscallsubr.h @@ -305,7 +305,7 @@ int kern_readv(struct thread *td, int fd, struct uio *auio); int kern_recvit(struct thread *td, int s, struct msghdr *mp, enum uio_seg fromseg, struct mbuf **controlp); int kern_renameat(struct thread *td, int oldfd, const char *old, int newfd, - const char *new, enum uio_seg pathseg); + const char *new, enum uio_seg pathseg, u_int flags); int kern_sched_getparam(struct thread *td, struct thread *targettd, struct sched_param *param); int kern_sched_getscheduler(struct thread *td, struct thread *targettd, From nobody Thu Mar 5 23:48:19 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSh26lhz6TrfN for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSg65g3z3MHk for ; Thu, 05 Mar 2026 23:48:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754499; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=W4PLGXGVIjWXax2ODY0Fo6I2UUCMor/TvmXumLDTt0o=; b=nn4HaEWm2g1am8n87Iqjoce0WT4VAcTtfJWatYcU1Y0WuxWP3fOciGAPlysItYzWOV57TH mJsar7kZ2d7f9ENmuyk6RQQvNFRXUELoV43I0Xog3TGi2MFr3CfGaUu9pKqrMws5kzrSIE OjWjrcPMpz0JnAh46QmU2TMA4mD054FnbZAtosYEMyL9ePax+1U/oT9iLmjuQlhwMgR5b7 /0M8o+wI3C7jVIwQ2Ed8RKpWruVhS/n2h6gZdQ75Eryt3KcrTROXO2SxM8fl1T/GZUmjnC kPRetjKYJ9QhS6CwI5tVYjbuL1F5B9Ly+EYI1H2CXnTMEn/gAijYKlESflEFrw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754499; a=rsa-sha256; cv=none; b=Hjrj+rD3QgGSQR4nSoFxUDYLLbRH/EA+VbL5CA6a+eUsBiXeuIilbKMa8jAIbaG2AH5o7x 8jPTEw2Sghpq3wL44UoTSd8Hqv/pS8m4j23CfWTUy3h2EPC/jJyzLMHUbuQObGkyBjnkAP lB2X4Eg7YBLemOnBcG4Wm/zSWf7V1/3WhxKnL/xyrpGqlVV1THql0GiBuKv84B2a8Fy3oT 7IwJgQJbUSJOftodNW7aq5JfiOnqh8TLfSqTAqnqB+/FdU62J3tE0hAMW9UDU4vAVhA/rq 7sFIbqTsf82luJq52mJkXz9GeD57KQI7EKheQlXUT2z4ksc+sntRozWVQ3Z9xg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754499; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=W4PLGXGVIjWXax2ODY0Fo6I2UUCMor/TvmXumLDTt0o=; b=dkx4U6u3JRhnnHRcAUIOVm4mku5CjTtre1Se7gueeq4iE0xGdiA4DRbuLaXG/h33l59zga DC/c7EDM+40SB+tn5daWcxLdqb3cJ54mOJCcVefHtRvp9xGWvJbZVJruZjvunyXYIV6L9O G395taWsrQ5EN1Jew+J7dPwUDLHHmPTzvG92/Xj4lHxgI0IWAoqUYm/cmEpDBk7O1WB9JE WB8PCgBCbkMLRNc/0+m1LZJkls9DWI3v1Rra9B5OT7ODrsHDEGYFyLkhfDiWS0ug98jaZ+ iJdU+YB62SFDebMCcujllGeUlDLQ6V/zU6U4swHcuAx4bipEZiajTSAzguiDjA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSg2sYXzyFD for ; Thu, 05 Mar 2026 23:48:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3e9fb by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:19 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 28599a1e5f1b - main - sys: add renameat2(2) syscall List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 28599a1e5f1b90676a818e0a4818cddd0839ad25 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:19 +0000 Message-Id: <69aa1643.3e9fb.6b909ea5@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=28599a1e5f1b90676a818e0a4818cddd0839ad25 commit 28599a1e5f1b90676a818e0a4818cddd0839ad25 Author: Konstantin Belousov AuthorDate: 2026-02-26 18:33:33 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:53 +0000 sys: add renameat2(2) syscall Reviewed by: markj Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55539 --- include/stdio.h | 1 + lib/libsys/Symbol.sys.map | 1 + sys/kern/syscalls.master | 10 +++++++++- sys/kern/vfs_syscalls.c | 10 ++++++++++ 4 files changed, 21 insertions(+), 1 deletion(-) diff --git a/include/stdio.h b/include/stdio.h index 34e877b60c14..753c7f3df03f 100644 --- a/include/stdio.h +++ b/include/stdio.h @@ -398,6 +398,7 @@ int fdclose(FILE *, int *); char *fgetln(FILE *, size_t *); const char *fmtcheck(const char *, const char *) __format_arg(2); int fpurge(FILE *); +int renameat2(int, const char *, int, const char *, unsigned int); void setbuffer(FILE *, char *, int); int setlinebuf(FILE *); int vasprintf(char **, const char *, __va_list) diff --git a/lib/libsys/Symbol.sys.map b/lib/libsys/Symbol.sys.map index 46767f5b6a4d..7f5c252af91b 100644 --- a/lib/libsys/Symbol.sys.map +++ b/lib/libsys/Symbol.sys.map @@ -393,6 +393,7 @@ FBSD_1.8 { FBSD_1.9 { pdrfork; pdrfork_thread; + renameat2; }; FBSDprivate_1.0 { diff --git a/sys/kern/syscalls.master b/sys/kern/syscalls.master index 8a30e5931a0e..b3e1d4be9fee 100644 --- a/sys/kern/syscalls.master +++ b/sys/kern/syscalls.master @@ -3420,5 +3420,13 @@ _Out_opt_ _Contains_long_ptr_ struct __siginfo *info ); } - +602 AUE_RENAMEAT STD|CAPENABLED { + int renameat2( + int oldfd, + _In_z_ const char *old, + int newfd, + _In_z_ const char *new, + int flags + ); + } ; vim: syntax=off diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 4409b0295587..20780334a6b5 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -3739,6 +3739,14 @@ sys_renameat(struct thread *td, struct renameat_args *uap) UIO_USERSPACE, 0)); } +int +sys_renameat2(struct thread *td, struct renameat2_args *uap) +{ + + return (kern_renameat(td, uap->oldfd, uap->old, uap->newfd, uap->new, + UIO_USERSPACE, uap->flags)); +} + #ifdef MAC static int kern_renameat_mac(struct thread *td, int oldfd, const char *old, int newfd, @@ -3775,6 +3783,8 @@ kern_renameat(struct thread *td, int oldfd, const char *old, int newfd, int error; short irflag; + if (flags != 0) + return (EINVAL); again: tmp = mp = NULL; bwillwrite(); From nobody Thu Mar 5 23:48:20 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSj02jXz6TsJ4 for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSh4NTZz3M8x for ; Thu, 05 Mar 2026 23:48:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754500; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JgTKzHNCqtCZpkaMyKakrXfeXZBUsLyPDblyXUlUZ5A=; b=yA1MGN8JyTqdJr0Nah1hu9WM5douMddha+G0eB009w0YSNPWmdy719TpZUIxiP3xeJ2J/f r5KBwGWcbiKbLdEdp3XtlT2F7EJbiOOQef/wtKtnYAuIuugOuHcC0E/GuwJCK8xPl6Gpjk yMZ8CTQSjlzP49Nahr6QmdXv+Q7+WZz9YxLWI9RblyU+aF66A3/NltvASZdJltOWdcUWnx qk3CShko0pPaD+J+euTLFr3WTv3I08WyXrQfRV1mzjCBTVCHee9G4EPxAGL1J5+RkwYeNX 3LRRq84tj8mrR27ZlkVHgTLPYzV218L+vVlZ+5MhUAJ/a79h4EjBkZ8oDUWWNQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754500; a=rsa-sha256; cv=none; b=g6MWAu8C3ZyRnlw+5gw1OwI3YNb391jny2RGXS/7fZdk2YkYKiuNwRR/oexAVALoLTDhxo JBVZ+rOCHjN36lWMYr+H0bQuiPLA2EMlYc+eFX09P44663NEQo+11pckQq0rqCV9Rk9wx4 AYfPjrLOsxljx9bod+9aPaVg2v7+RWChnhkSCz0KTEs95vvJ6ufNNwJeg9Ms273oVee+qP Vgk11CD9iYcbEwBpuKikRM0xv9OoNT2J8RJcXSZgzOV8iPzbAS2yIKgOHTRqKc3fprKqmz IBckfR56ZDqD8t8/mt7sn5vyHzYKirIwrdZpnuLKhHPYksg6qsD80B5XMOnzHQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754500; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JgTKzHNCqtCZpkaMyKakrXfeXZBUsLyPDblyXUlUZ5A=; b=Fc8Mi/zehN8zvrdxlsuh0bYO38IF7xm24qUMgPMILRcUq0T0LPG7opEP8Lb3+1hTnhVMSB z8gEAwpFydfu0l7fXDHZcGoQ5MybT3qCCmTFl3y6AE8KGDNkU0Ameqc0r94LtFe3C0hVql ObiU0yj1rqxLTSaZPf+wi9PJ4PsXXay1LYr8I17lNq6kWhoLmjK+5fWTkDctC9dMx+Rvaa pQ7Fbjb3W02O/iX5GBBgYpqMSUL9i1t4r3Rkg6olpyNo/JpU9TsGFAk6zZCpS2QsBp8YKe ANpo2fFz25Gu+NGHK7ZyLgIuCp3xgX1coTpPnMut2/6jKdLO4SVuoAckpXmKWQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSh3jgpzyJ8 for ; Thu, 05 Mar 2026 23:48:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3e8e0 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:20 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 7aaec5f3faec - main - renameat2(2): implement AT_RENAME_NOREPLACE flag List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 7aaec5f3faecf98e377c97e24dddb9c65f4b2e75 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:20 +0000 Message-Id: <69aa1644.3e8e0.14839235@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=7aaec5f3faecf98e377c97e24dddb9c65f4b2e75 commit 7aaec5f3faecf98e377c97e24dddb9c65f4b2e75 Author: Konstantin Belousov AuthorDate: 2026-02-26 18:57:24 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:53 +0000 renameat2(2): implement AT_RENAME_NOREPLACE flag For msdosfs, tmpfs, and ufs. Reviewed by: markj Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55539 --- sys/fs/msdosfs/msdosfs_vnops.c | 9 +++++++-- sys/fs/tmpfs/tmpfs_vnops.c | 9 +++++++-- sys/kern/vfs_syscalls.c | 24 ++++++++++++++++++++---- sys/sys/fcntl.h | 3 +++ sys/ufs/ufs/ufs_vnops.c | 7 ++++++- 5 files changed, 43 insertions(+), 9 deletions(-) diff --git a/sys/fs/msdosfs/msdosfs_vnops.c b/sys/fs/msdosfs/msdosfs_vnops.c index 3e28a7ce9d05..d626aed28076 100644 --- a/sys/fs/msdosfs/msdosfs_vnops.c +++ b/sys/fs/msdosfs/msdosfs_vnops.c @@ -49,12 +49,12 @@ * October 1992 */ -#include #include #include #include #include #include +#include #include #include #include @@ -970,7 +970,7 @@ msdosfs_rename(struct vop_rename_args *ap) goto abortit; } - if (ap->a_flags != 0) { + if ((ap->a_flags & ~(AT_RENAME_NOREPLACE)) != 0) { error = EOPNOTSUPP; goto abortit; } @@ -1041,6 +1041,11 @@ relock: vrele(tvp); tvp = NULL; } + if (error == 0 && tvp != NULL && + (ap->a_flags & AT_RENAME_NOREPLACE) != 0) { + error = EEXIST; + goto unlock; + } if (error == 0) { nip = NULL; error = deget(pmp, scn, blkoff, LK_EXCLUSIVE | LK_NOWAIT, diff --git a/sys/fs/tmpfs/tmpfs_vnops.c b/sys/fs/tmpfs/tmpfs_vnops.c index 6b32f53b3363..05d8f3e863e8 100644 --- a/sys/fs/tmpfs/tmpfs_vnops.c +++ b/sys/fs/tmpfs/tmpfs_vnops.c @@ -993,7 +993,7 @@ tmpfs_rename(struct vop_rename_args *v) goto out; } - if (v->a_flags != 0) { + if ((v->a_flags & ~(AT_RENAME_NOREPLACE)) != 0) { error = EOPNOTSUPP; goto out; } @@ -1018,9 +1018,14 @@ tmpfs_rename(struct vop_rename_args *v) "tmpfs_rename: fdvp not locked"); ASSERT_VOP_ELOCKED(tdvp, "tmpfs_rename: tdvp not locked"); - if (tvp != NULL) + if (tvp != NULL) { ASSERT_VOP_ELOCKED(tvp, "tmpfs_rename: tvp not locked"); + if ((v->a_flags & AT_RENAME_NOREPLACE) != 0) { + error = EEXIST; + goto out_locked; + } + } if (fvp == tvp) { error = 0; goto out_locked; diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 20780334a6b5..06500909589e 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -3783,7 +3783,7 @@ kern_renameat(struct thread *td, int oldfd, const char *old, int newfd, int error; short irflag; - if (flags != 0) + if ((flags & ~(AT_RENAME_NOREPLACE)) != 0) return (EINVAL); again: tmp = mp = NULL; @@ -3820,6 +3820,19 @@ again: } tdvp = tond.ni_dvp; tvp = tond.ni_vp; + if (tvp != NULL && (flags & AT_RENAME_NOREPLACE) != 0) { + /* + * Often filesystems need to relock the vnodes in + * VOP_RENAME(), which opens a window for invalidation + * of this check. Then, not all filesystems might + * implement AT_RENAME_NOREPLACE. This leads to + * situation where sometimes EOPNOTSUPP might be + * returned from the VOP due to race, while most of + * the time this check works. + */ + error = EEXIST; + goto out; + } error = vn_start_write(fvp, &mp, V_NOWAIT); if (error != 0) { again1: @@ -3912,9 +3925,12 @@ out: vrele(fromnd.ni_dvp); vrele(fvp); } - lockmgr(&tmp->mnt_renamelock, LK_RELEASE, 0); - vfs_rel(tmp); - vn_finished_write(mp); + if (tmp != NULL) { + lockmgr(&tmp->mnt_renamelock, LK_RELEASE, 0); + vfs_rel(tmp); + } + if (mp != NULL) + vn_finished_write(mp); out1: if (error == ERESTART) return (0); diff --git a/sys/sys/fcntl.h b/sys/sys/fcntl.h index 18d3928e91c7..8f2fc1e2debb 100644 --- a/sys/sys/fcntl.h +++ b/sys/sys/fcntl.h @@ -245,6 +245,9 @@ typedef __pid_t pid_t; #define AT_RESOLVE_BENEATH 0x2000 /* Do not allow name resolution to walk out of dirfd */ #define AT_EMPTY_PATH 0x4000 /* Operate on dirfd if path is empty */ + +#define AT_RENAME_NOREPLACE 0x0001 /* Fail rename if target exists */ +#define RENAME_NOREPLACE AT_RENAME_NOREPLACE #endif /* __BSD_VISIBLE */ /* diff --git a/sys/ufs/ufs/ufs_vnops.c b/sys/ufs/ufs/ufs_vnops.c index 429e6b5c8dd7..4abbd4ee807f 100644 --- a/sys/ufs/ufs/ufs_vnops.c +++ b/sys/ufs/ufs/ufs_vnops.c @@ -1294,7 +1294,7 @@ ufs_rename( goto releout; } - if (ap->a_flags != 0) { + if ((ap->a_flags & ~(AT_RENAME_NOREPLACE)) != 0) { error = EOPNOTSUPP; mp = NULL; goto releout; @@ -1394,6 +1394,11 @@ relock: } } + if (tvp != NULL && (ap->a_flags & AT_RENAME_NOREPLACE) != 0) { + error = EEXIST; + goto unlockout; + } + if (DOINGSUJ(fdvp) && (seqc_in_modify(fdvp_s) || !vn_seqc_consistent(fdvp, fdvp_s) || seqc_in_modify(fvp_s) || !vn_seqc_consistent(fvp, fvp_s) || From nobody Thu Mar 5 23:48:21 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSk1SGcz6TsLZ for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSj4pLqz3M98 for ; Thu, 05 Mar 2026 23:48:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754501; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=lVq3XtUrtgJ2D/AXIUrm0M8Mg7OkYPABEaR/tsliZ9c=; b=rvV09y4LOmpbaMIc7mmvl//TLxhsyblHhi5hjNiGBIVGWJKPA7LnHJJglzA8UNp1GjGqAm p2XWghPyXURxDSfA6QaJFyIurwclvKtisTjLT6KW6nfTUWbpYklc5kNdNHoi+q9HyT/day j6WG6rvjhFMVs/aR49TXhZdoIUuXTe1hgS4CAPkzvvkZEPdlTKL7LslYNXHABbHZy6DE2s r1CsHdY+iIxXSSOBfuEU+DJ4N2FYbVIX45/d5oDJ4E4OyocIIFlOwXHdmh9kE7UxlK+Uw3 5U8T1Z2oWfOxOzs2nE2ro7R4VajZKi07vHTyZC9Wk+MHUvogAlZZu0KyYeQt/A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754501; a=rsa-sha256; cv=none; b=Q1S9eog7JtBEzGk16oPqwgLoNBLwCbNd2F0Z37NqySNd8bN70E/TwWAM8wzswbdrzfPMOm Dvokz0vBACgjgTk4sSs2IMF7x7Zm9cSsxrqN+UKwJdgCZybs2yZz5q0SIHPlheY41BNkFV 7EWGLPspQwQxAxN3rt9JEXc2z27wb7oJAeXwgqK/9q3frf+L5LnlWJE2AlwwZJf3jleRb3 Gg74r/bOvu1SakJzHnhkCdTDQ9ABViRb91k6uoSAXLJq/CKvQYEUvl9qw5d5d5qQwh39Wp 9Ywr8jpUBLrcLW3Kfc/sHnFYz5zXKNHHQnrNYim8sKQf9BQ9tMYtS0n/b1mdrg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754501; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=lVq3XtUrtgJ2D/AXIUrm0M8Mg7OkYPABEaR/tsliZ9c=; b=cn/uMJhs/Bd1lMNrvwFRnwwIglaL66Jwl+fgg6vFrCNNG/Wk/wt4YNVC2hh4ZE83ovb1QJ 8fw/MwaDJOJfFiy51TUB6MhwPogF+jpi5LTfSS9lBJLkES2lQ8kB/CZbihBMu0g8isUrxe 2qM2ImZOi8YscVRV51bVe34Am0uwwQ0L04FZYfPfZatGX5F0Cs8cBJ/M5yopQKCDQb3S59 n4ek2viLDSH78oQ9dFnlsu/YhVTgyAbIW1dta9feL4tsTBTCyCnl0aa73nbOcyEhWgvy+r oRHdCs/BOC3fM6nSdx5GO/g7FHYXdVp/uTeTWZA9J+c/NjA32ACGF+UxcEYBKQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSj4LNLzyJB for ; Thu, 05 Mar 2026 23:48:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3f28a by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:21 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 7a1217ff3bbd - main - zfs: implement AT_RENAME_NOREPLACE List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 7a1217ff3bbdd1ef40d1b94170c53611fadeb026 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:21 +0000 Message-Id: <69aa1645.3f28a.6da320f9@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=7a1217ff3bbdd1ef40d1b94170c53611fadeb026 commit 7a1217ff3bbdd1ef40d1b94170c53611fadeb026 Author: Konstantin Belousov AuthorDate: 2026-03-01 13:16:55 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:53 +0000 zfs: implement AT_RENAME_NOREPLACE Reviewed by: markj Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55539 --- .../include/os/freebsd/zfs/sys/zfs_vnops_os.h | 4 ++-- .../openzfs/module/os/freebsd/zfs/zfs_vnops_os.c | 25 +++++++++++++++------- sys/contrib/openzfs/module/zfs/zfs_replay.c | 2 +- 3 files changed, 20 insertions(+), 11 deletions(-) diff --git a/sys/contrib/openzfs/include/os/freebsd/zfs/sys/zfs_vnops_os.h b/sys/contrib/openzfs/include/os/freebsd/zfs/sys/zfs_vnops_os.h index e27c6527e2b6..17ba5255b7b2 100644 --- a/sys/contrib/openzfs/include/os/freebsd/zfs/sys/zfs_vnops_os.h +++ b/sys/contrib/openzfs/include/os/freebsd/zfs/sys/zfs_vnops_os.h @@ -42,8 +42,8 @@ extern int zfs_rmdir(znode_t *dzp, const char *name, znode_t *cwd, extern int zfs_setattr(znode_t *zp, vattr_t *vap, int flag, cred_t *cr, zidmap_t *mnt_ns); extern int zfs_rename(znode_t *sdzp, const char *snm, znode_t *tdzp, - const char *tnm, cred_t *cr, int flags, uint64_t rflags, vattr_t *wo_vap, - zidmap_t *mnt_ns); + const char *tnm, cred_t *cr, int flags, uint64_t rflags, u_int at_flags, + vattr_t *wo_vap, zidmap_t *mnt_ns); extern int zfs_symlink(znode_t *dzp, const char *name, vattr_t *vap, const char *link, znode_t **zpp, cred_t *cr, int flags, zidmap_t *mnt_ns); extern int zfs_link(znode_t *tdzp, znode_t *sp, diff --git a/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c b/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c index 04fd772603b9..d0c1a4755b22 100644 --- a/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c +++ b/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c @@ -3256,7 +3256,7 @@ zfs_rename_check(znode_t *szp, znode_t *sdzp, znode_t *tdzp) static int zfs_do_rename_impl(vnode_t *sdvp, vnode_t **svpp, struct componentname *scnp, vnode_t *tdvp, vnode_t **tvpp, struct componentname *tcnp, - cred_t *cr); + cred_t *cr, u_int at_flags); /* * Move an entry from the provided source directory to the target @@ -3267,6 +3267,7 @@ zfs_do_rename_impl(vnode_t *sdvp, vnode_t **svpp, struct componentname *scnp, * tdvp - Target directory to contain the "new entry". * tcnp - New entry name. * cr - credentials of caller. + * at_flags - AT_RENAME_* * INOUT: svpp - Source file * tvpp - Target file, may point to NULL initially * @@ -3278,7 +3279,7 @@ zfs_do_rename_impl(vnode_t *sdvp, vnode_t **svpp, struct componentname *scnp, static int zfs_do_rename(vnode_t *sdvp, vnode_t **svpp, struct componentname *scnp, vnode_t *tdvp, vnode_t **tvpp, struct componentname *tcnp, - cred_t *cr) + cred_t *cr, u_int at_flags) { int error; @@ -3307,7 +3308,8 @@ zfs_do_rename(vnode_t *sdvp, vnode_t **svpp, struct componentname *scnp, return (error); } - error = zfs_do_rename_impl(sdvp, svpp, scnp, tdvp, tvpp, tcnp, cr); + error = zfs_do_rename_impl(sdvp, svpp, scnp, tdvp, tvpp, tcnp, cr, + at_flags); VOP_UNLOCK(sdvp); VOP_UNLOCK(*svpp); out: @@ -3322,7 +3324,7 @@ out: static int zfs_do_rename_impl(vnode_t *sdvp, vnode_t **svpp, struct componentname *scnp, vnode_t *tdvp, vnode_t **tvpp, struct componentname *tcnp, - cred_t *cr) + cred_t *cr, u_int at_flags) { dmu_tx_t *tx; zfsvfs_t *zfsvfs; @@ -3431,6 +3433,11 @@ zfs_do_rename_impl(vnode_t *sdvp, vnode_t **svpp, struct componentname *scnp, * Does target exist? */ if (tzp) { + if ((at_flags & AT_RENAME_NOREPLACE) != 0) { + error = SET_ERROR(EEXIST); + goto out; + } + /* * Source and target must be the same type. */ @@ -3551,7 +3558,8 @@ out: int zfs_rename(znode_t *sdzp, const char *sname, znode_t *tdzp, const char *tname, - cred_t *cr, int flags, uint64_t rflags, vattr_t *wo_vap, zidmap_t *mnt_ns) + cred_t *cr, int flags, uint64_t rflags, u_int at_flags, vattr_t *wo_vap, + zidmap_t *mnt_ns) { struct componentname scn, tcn; vnode_t *sdvp, *tdvp; @@ -3583,7 +3591,8 @@ zfs_rename(znode_t *sdzp, const char *sname, znode_t *tdzp, const char *tname, goto fail; } - error = zfs_do_rename(sdvp, &svp, &scn, tdvp, &tvp, &tcn, cr); + error = zfs_do_rename(sdvp, &svp, &scn, tdvp, &tvp, &tcn, cr, + at_flags); fail: if (svp != NULL) vrele(svp); @@ -5527,12 +5536,12 @@ zfs_freebsd_rename(struct vop_rename_args *ap) } #endif - if (error == 0 && ap->a_flags != 0) + if (error == 0 && (ap->a_flags & ~(AT_RENAME_NOREPLACE)) != 0) error = EOPNOTSUPP; if (error == 0) { error = zfs_do_rename(fdvp, &fvp, ap->a_fcnp, tdvp, &tvp, - ap->a_tcnp, ap->a_fcnp->cn_cred); + ap->a_tcnp, ap->a_fcnp->cn_cred, ap->a_flags); vrele(fdvp); vrele(fvp); vrele(tdvp); diff --git a/sys/contrib/openzfs/module/zfs/zfs_replay.c b/sys/contrib/openzfs/module/zfs/zfs_replay.c index 78be046f2262..d8b7c4e8a83e 100644 --- a/sys/contrib/openzfs/module/zfs/zfs_replay.c +++ b/sys/contrib/openzfs/module/zfs/zfs_replay.c @@ -710,7 +710,7 @@ do_zfs_replay_rename(zfsvfs_t *zfsvfs, _lr_rename_t *lr, char *sname, wo_vap, zfs_init_idmap); #else error = zfs_rename(sdzp, sname, tdzp, tname, kcred, vflg, rflags, - wo_vap, NULL); + 0, wo_vap, NULL); #endif zrele(tdzp); From nobody Thu Mar 5 23:48:22 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSl0plFz6TsC5 for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSk5gxPz3M7C for ; Thu, 05 Mar 2026 23:48:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754502; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+qmdQaXGwwyIFuwQlmVEsm4P48ShPvCfHp7lnaSP4Ls=; b=ij7R5adUrOn6+9JHSEMNZ7/B7nt58M1sbwBvnktNe4pmDPRgbll8n/EyXW+nFqX+aGaD6P 0ChxkjeCXwBs312jO4moYRxvW+MaYGHS1LVcnbigzd5lRZM5SJEL3KL9JkD4bSYJQNMDcY mCfqLJCprQWFMYL9Z7hcZ0roOQRJIK6lFFMe7n3PY7Wd5WjClhXxOxU94s8T1ej9PmEGhJ EIswJ7M4e9tndyk2zTZ7AR+K5anRu/4uYJYRGI0zYfQqcMBfOMRGFA434QwE4LZwheCFkr gBldRxVj1CLQkaYPrrFLlx8MzWc4wnpt9yG9qMjfDb9kGq6S1WffWc8vQkRWQw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754502; a=rsa-sha256; cv=none; b=NMotz+wDeL79+FtLob7miEDlLSDSGHD8aI64R4x+dw/uu5jFJ63VPQ/09zx1VZZJeKRZbJ Vq3RBeJWtx9PICzqPEaFgIpgTEr/aFLP/FMvMx45G9wwMeT3RaVBYkagP5oVznFWa6GCWc IjvOw2h6yJr8/I+9zGAWUQxEe1/QfeNdQAD899iDQDFoMyA7DJSC9OkZOmBMZLMZFg+mwW whkr3xFpqm79bw7/4biS9810NCvf0nb4IbDI1p2qnMrf2ElmwGX+CavNQq20k727nD8UCq HxP6WotTeQlVsZZNm7YDuBM1BYrzyK+IEEDt9c5iUf4MBCiIXrNnO9OTZr5Kug== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754502; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+qmdQaXGwwyIFuwQlmVEsm4P48ShPvCfHp7lnaSP4Ls=; b=otAsCOcJdtiEnhBDcQihGg3IGC7/tYnlvRwSi6k5O/EqW6SGXeevNSYzJM7l8qeHOpMGWc MGK1x4+G5q03Qt7ZM49v4DJcZtTF0WXUNYJ2pO+y5tsTbLOZ5SWOhbXEaScIXUcKH3LjZZ h0YkMQXSh9rXyApNpc3ZmC8+ntO37dG4ClySJD2jQohcImeL+LKGmurd3R1la0sG83Gadi Y7f327uB5LwZS99PuZLmRz4hB1nFVGd2k99ECGpWGgm6ulrl1qays/EHT4JcLTiO3Fd1cs G8okxFU6Ro8/J1b5EmTQ+8icd2ZMF0vPW3YflSk/JDhq9eHzTrX+6mtLijBGSQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSk5CFdzycl for ; Thu, 05 Mar 2026 23:48:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3e6fc by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:22 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 8feb8d221cfb - main - linuxolator: translate LINUX_RENAME_NOREPLACE into our AT_RENAME_NOREPLACE List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 8feb8d221cfb842ee11d744d22571baec6c18cd8 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:22 +0000 Message-Id: <69aa1646.3e6fc.654bf75@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=8feb8d221cfb842ee11d744d22571baec6c18cd8 commit 8feb8d221cfb842ee11d744d22571baec6c18cd8 Author: Konstantin Belousov AuthorDate: 2026-02-26 19:21:08 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:53 +0000 linuxolator: translate LINUX_RENAME_NOREPLACE into our AT_RENAME_NOREPLACE Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55539 --- sys/compat/linux/linux_file.c | 35 +++++++++++++++++++++++------------ 1 file changed, 23 insertions(+), 12 deletions(-) diff --git a/sys/compat/linux/linux_file.c b/sys/compat/linux/linux_file.c index 43ccac0308d3..30e79a53ad2a 100644 --- a/sys/compat/linux/linux_file.c +++ b/sys/compat/linux/linux_file.c @@ -833,23 +833,34 @@ int linux_renameat2(struct thread *td, struct linux_renameat2_args *args) { int olddfd, newdfd; + u_int atflags; - if (args->flags != 0) { - if (args->flags & ~(LINUX_RENAME_EXCHANGE | - LINUX_RENAME_NOREPLACE | LINUX_RENAME_WHITEOUT)) - return (EINVAL); - if (args->flags & LINUX_RENAME_EXCHANGE && - args->flags & (LINUX_RENAME_NOREPLACE | - LINUX_RENAME_WHITEOUT)) + atflags = 0; + if ((args->flags & ~(LINUX_RENAME_EXCHANGE | + LINUX_RENAME_NOREPLACE | LINUX_RENAME_WHITEOUT)) != 0) + return (EINVAL); + if ((args->flags & LINUX_RENAME_EXCHANGE) != 0 && + (args->flags & (LINUX_RENAME_NOREPLACE | + LINUX_RENAME_WHITEOUT)) != 0) + return (EINVAL); + if ((args->flags & LINUX_RENAME_NOREPLACE) != 0) { + if ((args->flags & (LINUX_RENAME_EXCHANGE | + LINUX_RENAME_WHITEOUT)) != 0) return (EINVAL); -#if 0 + args->flags &= ~LINUX_RENAME_NOREPLACE; + atflags |= AT_RENAME_NOREPLACE; + } + + if (args->flags != 0) { /* * This spams the console on Ubuntu Focal. * - * What's needed here is a general mechanism to let users know - * about missing features without hogging the system. + * What's needed here is a general mechanism to let + * users know about missing features without hogging + * the system. */ - linux_msg(td, "renameat2 unsupported flags 0x%x", +#if 0 + linux_msg(td, "renameat2 unsupported flags %#x", args->flags); #endif return (EINVAL); @@ -858,7 +869,7 @@ linux_renameat2(struct thread *td, struct linux_renameat2_args *args) olddfd = (args->olddfd == LINUX_AT_FDCWD) ? AT_FDCWD : args->olddfd; newdfd = (args->newdfd == LINUX_AT_FDCWD) ? AT_FDCWD : args->newdfd; return (kern_renameat(td, olddfd, args->oldname, newdfd, - args->newname, UIO_USERSPACE, 0)); + args->newname, UIO_USERSPACE, atflags)); } #ifdef LINUX_LEGACY_SYSCALLS From nobody Thu Mar 5 23:48:23 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSm2gb8z6TsJ8 for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSl6dz3z3MCX for ; Thu, 05 Mar 2026 23:48:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754503; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=R8T2eABtkLSaHyynA4BWGUL8h+C/zIW5ykfjCYcxVqw=; b=ckRTCCkq4waB6GwHA11G2LtV3QED+d0j1wHFmDlI+gZ4oGf/L21Rk+0YSmB2jWJRp4aS/W mtRqbXD3HHkl51G+xwUaF9z5hv9aNyX/exDgqFOILaZEJtrgbnMhzLBQChKlmUmLYi3ipU zIh+QcDNPVfgsgem8OByJQ9t1MimshAA/IrubdD7xAkkqKxf73zV1adnyW1/EtTMovBBmF i1yvvxfqYhO/8p1EdfxjLT0Uxm8n6uIOlEHdmfWozHsYcZ/pn+rTGVgy8ix0SBDhvrgBTJ tYkSG6TmhM/9i44va4+k4pFZmdHinPf9qlZWKIjshXBjwiOammQaVEHILaWxgQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754503; a=rsa-sha256; cv=none; b=Ea0bts24i90B7JKMFCia1VopzzS+A+TuVCEOlJ+PXutfbzMZlRF9aC0YeeMvXR5v/ORkgt gnUUUPziZKRYY11z1RCerQt3CyUJodhHlx9+4/aXkL7AZ+CzJ+rUn/WPdIvB5JFMtw8j5H ybCtWFmOhEGAOq92UK8aSKHDmYm0upj415xkzLTIHr2XWUuFIF/gugynvMV7imSBk7pmNX VIL391ywWhtnLKYrcxSJaUYKE7ku2YbqJNHm9HOcpXfei8Mlq0YeRu3PXvGre6PJLkVz4V GEhLq0rbUXdc/W51axDm1kPZNXfvcw3hmhAEfFYKyEjowfECigawDyeB4WP2zg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754503; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=R8T2eABtkLSaHyynA4BWGUL8h+C/zIW5ykfjCYcxVqw=; b=jW2vfcCGn5i2nr/kr30rEzVMNGPJpk8ETdsPQSrMmcjNvUrVOP/Cgjcm+HT5dXt3o3eIYD 5nQC3ixZnrD7qzpDKLpgPG2VaBG0ta/K1vTKJj2Fxjz4E0An1OQURG0BE7+4zt+pAS7DZg 9ZojrR2pWgNng5+AigzMWRtFXY5i2dcZgDrKHCI9Jii90rEPjHxw5SDq9P/AVzgCKCrwbc Kb9cop/+CAPOOGm6b0WHc3fpy7sGQxcf0G9l0VkbZeRNI7x6oaD+oaRaJPhT6udU/C61uL Tg7ynGeMrW+HrJm4QbuCksV6WIvEiGLEINDCHwESrN03lcSCDp9iOmCbLIFKQw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSl63mjzyJF for ; Thu, 05 Mar 2026 23:48:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3f18e by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:23 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 5f911eaba017 - main - libsys/rename.2: remove commented-out CAVEAT section List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 5f911eaba017645487a1eaee3609b26a77f0f174 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:23 +0000 Message-Id: <69aa1647.3f18e.383df380@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=5f911eaba017645487a1eaee3609b26a77f0f174 commit 5f911eaba017645487a1eaee3609b26a77f0f174 Author: Konstantin Belousov AuthorDate: 2026-02-27 00:03:59 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:53 +0000 libsys/rename.2: remove commented-out CAVEAT section FreeBSD UFS does not support hardlinks to directories. Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55539 --- lib/libsys/rename.2 | 26 -------------------------- 1 file changed, 26 deletions(-) diff --git a/lib/libsys/rename.2 b/lib/libsys/rename.2 index 4faba81ff509..1806321245ec 100644 --- a/lib/libsys/rename.2 +++ b/lib/libsys/rename.2 @@ -112,32 +112,6 @@ or .Fa tofd parameter, the current working directory is used in the determination of the file for the respective path parameter. -.\".Sh CAVEAT -.\"The system can deadlock if a loop in the file system graph is present. -.\"This loop takes the form of an entry in directory -.\".Pa a , -.\"say -.\".Pa a/foo , -.\"being a hard link to directory -.\".Pa b , -.\"and an entry in -.\"directory -.\".Pa b , -.\"say -.\".Pa b/bar , -.\"being a hard link -.\"to directory -.\".Pa a . -.\"When such a loop exists and two separate processes attempt to -.\"perform -.\".Ql rename a/foo b/bar -.\"and -.\".Ql rename b/bar a/foo , -.\"respectively, -.\"the system may deadlock attempting to lock -.\"both directories for modification. -.\"Hard links to directories should be -.\"replaced by symbolic links by the system administrator. .Sh RETURN VALUES .Rv -std rename .Sh ERRORS From nobody Thu Mar 5 23:48:24 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSn4Ztvz6Trn1 for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSn0lcDz3MJs for ; Thu, 05 Mar 2026 23:48:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754505; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=EsyLdsg+5fhG62qCplymCftVTWQsxeFgj/FpyJijeNI=; b=LO6qwdZmPXr5Wqxj0zhNVj1p1qN4kGtaOl2v25OJWBLbr0p+zFAi1pyCmDTnDfHTa8bN+j BYzMrOyHbGujc/UxCWYd2eBJoP/b48sFBAMlQvwpwpGe65nJjOaI83WC3bgzglsKCNvrX5 0FiOvEtAZDW1sDXNz4HU218He+oh+uJ65RKQxSx3qmG+VTgvE0xlbUXgnjTksqglQRozcl vVrlowGM2hkkaM7uto8vV0JmVYXThFCyYKv8WIRPm2E6ayLS88n/Zy16xmrTWkRhdSHA2U E0/v/MEb72mxLs34uMfoyzxdMdEmjVs/dDtbusDYt5kXunsTDd5jeD07hjaBfg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754505; a=rsa-sha256; cv=none; b=oDcr1llPodA7ZmwYqzELved81tHpOSFqkYUT48LAE/5he1wjz1iY4hCdWUUrZbkV5F86vP CezTffKd3iJoqRj75EVROiZlBy0B9pIzZT/oWBJDJ4ChuLF3nxXK+1frei2gQsT49MRTE/ HmvU8GeHJVfA8w4OJtcgO3wli+kV78mB2CqCzyshJJrxh8W+JA6FB79PnKNCLzXfAvG4BX wEN9J9ak6CIwL9mQU4nUQZ5Ol9UVg2ttvyCba9m7Cc1pr6Tg4y6J1odlBcWt03/1VqK1SI opzVD2tXhMnk/55kAPNYf2n0Azpv0hzxSQqHeoGFFKaN4Kb+PY2YxtTMeobwKw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754505; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=EsyLdsg+5fhG62qCplymCftVTWQsxeFgj/FpyJijeNI=; b=gdgrBIa1JGsSh97UxILs9+1VfKsUPZNZD3I1ueF4uPwjU4Uz35DXaGwtFPyUOXJeCMfp0q VI32n0P2Cb0xd32H0H6c3Op4hLHGmq3sFHNSZg0+wZCwb38ZKhXma7Ucsy/3/14xPNmoVq 9VwSONsUMFus5KH951VPpfeFoSJE45sZux1NhQF2mREUfMPpa2NIOugdphWi3mi7rE4AIV l6q3BEeLggWDxeJ5XIV7RzN9mnAk1GeaqnvnWKDZbDZaeEtLgu9+a75Zv1vgAghhkKgo7s BFTaPLSfi6s09EPD5Qjwq9utDmuVjVYARCicjeUukewe0dBAi3Zg9Wej3jlTLg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSm6nmqzyJH for ; Thu, 05 Mar 2026 23:48:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3d26a by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:24 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 619e49b2ba58 - main - renameat2(2): document List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 619e49b2ba58e1ffd2ab111fef6d1e87d77e7391 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:24 +0000 Message-Id: <69aa1648.3d26a.45e9ca09@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=619e49b2ba58e1ffd2ab111fef6d1e87d77e7391 commit 619e49b2ba58e1ffd2ab111fef6d1e87d77e7391 Author: Konstantin Belousov AuthorDate: 2026-02-27 00:10:36 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:53 +0000 renameat2(2): document Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55539 --- lib/libsys/Makefile.sys | 3 ++- lib/libsys/rename.2 | 65 +++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 67 insertions(+), 1 deletion(-) diff --git a/lib/libsys/Makefile.sys b/lib/libsys/Makefile.sys index eac28fbd2fe9..76855e0ae54d 100644 --- a/lib/libsys/Makefile.sys +++ b/lib/libsys/Makefile.sys @@ -513,7 +513,8 @@ MLINKS+=readlink.2 readlinkat.2 MLINKS+=recv.2 recvfrom.2 \ recv.2 recvmmsg.2 \ recv.2 recvmsg.2 -MLINKS+=rename.2 renameat.2 +MLINKS+=rename.2 renameat.2 \ + rename.2 renameat2.2 MLINKS+=rtprio.2 rtprio_thread.2 MLINKS+=sched_get_priority_max.2 sched_get_priority_min.2 \ sched_get_priority_max.2 sched_rr_get_interval.2 diff --git a/lib/libsys/rename.2 b/lib/libsys/rename.2 index 1806321245ec..dbad50edb9a9 100644 --- a/lib/libsys/rename.2 +++ b/lib/libsys/rename.2 @@ -39,6 +39,16 @@ .Fn rename "const char *from" "const char *to" .Ft int .Fn renameat "int fromfd" "const char *from" "int tofd" "const char *to" +.In sys/fcntl.h +.In stdio.h +.Ft int +.Fo renameat2 +.Fa "int fromfd" +.Fa "const char *from" +.Fa "int tofd" +.Fa "const char *to" +.Fa "unsigned int flags" +.Fc .Sh DESCRIPTION The .Fn rename @@ -112,6 +122,28 @@ or .Fa tofd parameter, the current working directory is used in the determination of the file for the respective path parameter. +.Pp +The +.Fn renameat2 +system call takes an additional +.Fa flags +argument. +If +.Fa flags +is zero, the +.Fn renameat2 +call operates identically to +.Fn renameat . +Additionally, the following flags can be specified: +.Bl -tag -width AT_RENAME_NOREPLACE +.It Dv AT_RENAME_NOREPLACE +If the path specified by +.Fa tofd +and +.Fa to +exists, the request fails with the error +.Er EEXIST . +.El .Sh RETURN VALUES .Rv -std rename .Sh ERRORS @@ -298,6 +330,35 @@ file descriptor lacks the .Dv CAP_RENAMEAT_TARGET right. .El +.Pp +In addition to the errors returned by the +.Fn renameat +system call, the +.Fn renameat2 +system call may fail if: +.Bl -tag -width Er +.It Bq Er EEXIST +The +.Dv AT_RENAME_NOREPLACE +flag was provided, and a file exists at the path specified by +.Fa to . +.It Bq Er EOPNOTSUPP +One of the +.Fa flags +specified is not supported by the filesystem where the to-be +renamed file is located. +.El +.Sh CAVEATS +If the filesystem which owns the file to be renamed does not +implement the +.Dv AT_RENAME_NOREPLACE +flag, it is possible that due to race with target file creation, +the error returned by the +.Fn renameat2 +system call would be non-deterministically either +.Er EEXIST +or +.Er EOPNOTSUPP . .Sh SEE ALSO .Xr chflags 2 , .Xr open 2 , @@ -315,3 +376,7 @@ The .Fn renameat system call appeared in .Fx 8.0 . +The +.Fn renameat2 +system call appeared in +.Fx 16.0 . From nobody Thu Mar 5 23:48:25 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSp3KJhz6TsCC for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSp0j7Hz3MCp for ; Thu, 05 Mar 2026 23:48:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754506; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=O2wiofUv0kcOKGuCsZZdqFD+I1P7EnDNRM9zHffzIvw=; b=Sth+nDTeQCSQu09SOm/qigfQPcWoCZ/33G0KIkudOfEqYhTs1pB1OwFDyjorNTRV4nwz5F 8Acy7aVhowGhKMc14CxCvcRDhCxDM/aiqniWX9G3f+soDW4nHQYX5EeihS4CjfDERyVDKt JySbziAff3e0sj4YYcX9HaJLPxuy9cp+3D7rLSkaAmeh98//WxMvwISEUuEmhJKytQtTgK vi5lzxL+cCcvuk8OpYXuS1fpA8Uk9IxE9JbyTMuXDD6CsF23EklZTqSQh9NY4VzLJ5c6FX YgZ66hQSCC32k7Qq+Ku+GJUpwyMjUsLNqCpcwKQQjutuB2yYNJy0BlyMG7+i8A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754506; a=rsa-sha256; cv=none; b=Ri1da0W5HDAZhO3WkbaMeMOI86BlsLJwJfr847UL8i6/916aHDjWw1Ja/g38F/+CPRrCy8 DaY/fs1TPyd9ZuI0bECAukIKBej1KA3E5JwZOff3OqV7zs7kaMhdnnV2CM1LXYgyS/7FOo dJl/6d1fbW8Z892N3YwIFYVv+sMmm8GhUhAmhuyak3ZBAvklTgwTREYouyx1YnyIBaKxXQ kpyRIA2P0fSs3jvk/GF13uNJ/eJZjpad+b13WVfdxHZvmUOH8HtiiVCFoLEt7KvGp8GKef xB2NxAgA5cFvfLl0M5fJ2xDBMGBlP9nG7y/xCIy119fM3TFttUwPL9+L0g+Vpg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754506; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=O2wiofUv0kcOKGuCsZZdqFD+I1P7EnDNRM9zHffzIvw=; b=kxGn03oJb7+gMYAN6tu1ZgjTtzKa//se4SGGvhB1Xn6xV7c+cyiK1W33l3y/n4Cz8So5zr IFTSJOzcyO5YKhk79RGGTE6TjmYkxy56uTzYsxY4MOpI1fBNE3THOACzCjOfs1Etpkugrv VL/93vuzgPKjTg+cqR3+8AWn5zpik19TEEu5zp8igaQxOYlCTGxsN9fD1+mbhCB8/de+wB shPWCW3PkACcfD3037GrQRt+4TLwnP/wE2luZyoKjhoCNitlGUJdYu2haBkp7SAomrl9mP K/ZT3eajymLmXDlyI3seucRvqp7fpRweER9cZkPpETuHJYXUmjKDYzYqhhFEdw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSp03LSzygM for ; Thu, 05 Mar 2026 23:48:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3f02d by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:25 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: ef8292e33957 - main - Regen List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: ef8292e339572dc669409d233f9e3d43f13acb87 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:25 +0000 Message-Id: <69aa1649.3f02d.5f09581c@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=ef8292e339572dc669409d233f9e3d43f13acb87 commit ef8292e339572dc669409d233f9e3d43f13acb87 Author: Konstantin Belousov AuthorDate: 2026-02-26 18:47:52 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:54 +0000 Regen --- lib/libsys/_libsys.h | 2 ++ lib/libsys/syscalls.map | 2 ++ sys/compat/freebsd32/freebsd32_syscall.h | 3 +- sys/compat/freebsd32/freebsd32_syscalls.c | 1 + sys/compat/freebsd32/freebsd32_sysent.c | 1 + sys/compat/freebsd32/freebsd32_systrace_args.c | 38 ++++++++++++++++++++++++++ sys/kern/init_sysent.c | 1 + sys/kern/syscalls.c | 1 + sys/kern/systrace_args.c | 38 ++++++++++++++++++++++++++ sys/sys/syscall.h | 3 +- sys/sys/syscall.mk | 3 +- sys/sys/sysproto.h | 9 ++++++ 12 files changed, 99 insertions(+), 3 deletions(-) diff --git a/lib/libsys/_libsys.h b/lib/libsys/_libsys.h index 2af6d2bb22b3..c454fc3fece9 100644 --- a/lib/libsys/_libsys.h +++ b/lib/libsys/_libsys.h @@ -474,6 +474,7 @@ typedef int (__sys_jail_remove_jd_t)(int); typedef int (__sys_kexec_load_t)(uint64_t, u_long, struct kexec_segment *, u_long); typedef int (__sys_pdrfork_t)(int *, int, int); typedef int (__sys_pdwait_t)(int, int *, int, struct __wrusage *, struct __siginfo *); +typedef int (__sys_renameat2_t)(int, const char *, int, const char *, int); _Noreturn void __sys__exit(int rval); int __sys_fork(void); @@ -883,6 +884,7 @@ int __sys_jail_remove_jd(int fd); int __sys_kexec_load(uint64_t entry, u_long nseg, struct kexec_segment * segments, u_long flags); int __sys_pdrfork(int * fdp, int pdflags, int rfflags); int __sys_pdwait(int fd, int * status, int options, struct __wrusage * wrusage, struct __siginfo * info); +int __sys_renameat2(int oldfd, const char * old, int newfd, const char * new, int flags); __END_DECLS #endif /* __LIBSYS_H_ */ diff --git a/lib/libsys/syscalls.map b/lib/libsys/syscalls.map index bc8574681132..928817e57b7c 100644 --- a/lib/libsys/syscalls.map +++ b/lib/libsys/syscalls.map @@ -823,4 +823,6 @@ FBSDprivate_1.0 { __sys_pdrfork; _pdwait; __sys_pdwait; + _renameat2; + __sys_renameat2; }; diff --git a/sys/compat/freebsd32/freebsd32_syscall.h b/sys/compat/freebsd32/freebsd32_syscall.h index 67ff022922a8..9fed7ec58669 100644 --- a/sys/compat/freebsd32/freebsd32_syscall.h +++ b/sys/compat/freebsd32/freebsd32_syscall.h @@ -519,4 +519,5 @@ #define FREEBSD32_SYS_jail_remove_jd 598 #define FREEBSD32_SYS_pdrfork 600 #define FREEBSD32_SYS_freebsd32_pdwait 601 -#define FREEBSD32_SYS_MAXSYSCALL 602 +#define FREEBSD32_SYS_renameat2 602 +#define FREEBSD32_SYS_MAXSYSCALL 603 diff --git a/sys/compat/freebsd32/freebsd32_syscalls.c b/sys/compat/freebsd32/freebsd32_syscalls.c index 54b826098a9d..d91d45130c89 100644 --- a/sys/compat/freebsd32/freebsd32_syscalls.c +++ b/sys/compat/freebsd32/freebsd32_syscalls.c @@ -607,4 +607,5 @@ const char *freebsd32_syscallnames[] = { "#599", /* 599 = kexec_load */ "pdrfork", /* 600 = pdrfork */ "freebsd32_pdwait", /* 601 = freebsd32_pdwait */ + "renameat2", /* 602 = renameat2 */ }; diff --git a/sys/compat/freebsd32/freebsd32_sysent.c b/sys/compat/freebsd32/freebsd32_sysent.c index 2b5609e8a317..68c0388eaa79 100644 --- a/sys/compat/freebsd32/freebsd32_sysent.c +++ b/sys/compat/freebsd32/freebsd32_sysent.c @@ -669,4 +669,5 @@ struct sysent freebsd32_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 599 = freebsd32_kexec_load */ { .sy_narg = AS(pdrfork_args), .sy_call = (sy_call_t *)sys_pdrfork, .sy_auevent = AUE_PDRFORK, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 600 = pdrfork */ { .sy_narg = AS(freebsd32_pdwait_args), .sy_call = (sy_call_t *)freebsd32_pdwait, .sy_auevent = AUE_PDWAIT, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 601 = freebsd32_pdwait */ + { .sy_narg = AS(renameat2_args), .sy_call = (sy_call_t *)sys_renameat2, .sy_auevent = AUE_RENAMEAT, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 602 = renameat2 */ }; diff --git a/sys/compat/freebsd32/freebsd32_systrace_args.c b/sys/compat/freebsd32/freebsd32_systrace_args.c index 59a74d365e1c..e85cf4765c98 100644 --- a/sys/compat/freebsd32/freebsd32_systrace_args.c +++ b/sys/compat/freebsd32/freebsd32_systrace_args.c @@ -3447,6 +3447,17 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) *n_args = 5; break; } + /* renameat2 */ + case 602: { + struct renameat2_args *p = params; + iarg[a++] = p->oldfd; /* int */ + uarg[a++] = (intptr_t)p->old; /* const char * */ + iarg[a++] = p->newfd; /* int */ + uarg[a++] = (intptr_t)p->new; /* const char * */ + iarg[a++] = p->flags; /* int */ + *n_args = 5; + break; + } default: *n_args = 0; break; @@ -9314,6 +9325,28 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; }; break; + /* renameat2 */ + case 602: + switch (ndx) { + case 0: + p = "int"; + break; + case 1: + p = "userland const char *"; + break; + case 2: + p = "int"; + break; + case 3: + p = "userland const char *"; + break; + case 4: + p = "int"; + break; + default: + break; + }; + break; default: break; }; @@ -11242,6 +11275,11 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) if (ndx == 0 || ndx == 1) p = "int"; break; + /* renameat2 */ + case 602: + if (ndx == 0 || ndx == 1) + p = "int"; + break; default: break; }; diff --git a/sys/kern/init_sysent.c b/sys/kern/init_sysent.c index 33586db22600..54f1ada9453c 100644 --- a/sys/kern/init_sysent.c +++ b/sys/kern/init_sysent.c @@ -668,4 +668,5 @@ struct sysent sysent[] = { { .sy_narg = AS(kexec_load_args), .sy_call = (sy_call_t *)sys_kexec_load, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 599 = kexec_load */ { .sy_narg = AS(pdrfork_args), .sy_call = (sy_call_t *)sys_pdrfork, .sy_auevent = AUE_PDRFORK, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 600 = pdrfork */ { .sy_narg = AS(pdwait_args), .sy_call = (sy_call_t *)sys_pdwait, .sy_auevent = AUE_PDWAIT, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 601 = pdwait */ + { .sy_narg = AS(renameat2_args), .sy_call = (sy_call_t *)sys_renameat2, .sy_auevent = AUE_RENAMEAT, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 602 = renameat2 */ }; diff --git a/sys/kern/syscalls.c b/sys/kern/syscalls.c index e2467c39fe6d..cf54a656d639 100644 --- a/sys/kern/syscalls.c +++ b/sys/kern/syscalls.c @@ -607,4 +607,5 @@ const char *syscallnames[] = { "kexec_load", /* 599 = kexec_load */ "pdrfork", /* 600 = pdrfork */ "pdwait", /* 601 = pdwait */ + "renameat2", /* 602 = renameat2 */ }; diff --git a/sys/kern/systrace_args.c b/sys/kern/systrace_args.c index 8f5a5cd5153d..18c6462d4207 100644 --- a/sys/kern/systrace_args.c +++ b/sys/kern/systrace_args.c @@ -3544,6 +3544,17 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) *n_args = 5; break; } + /* renameat2 */ + case 602: { + struct renameat2_args *p = params; + iarg[a++] = p->oldfd; /* int */ + uarg[a++] = (intptr_t)p->old; /* const char * */ + iarg[a++] = p->newfd; /* int */ + uarg[a++] = (intptr_t)p->new; /* const char * */ + iarg[a++] = p->flags; /* int */ + *n_args = 5; + break; + } default: *n_args = 0; break; @@ -9488,6 +9499,28 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; }; break; + /* renameat2 */ + case 602: + switch (ndx) { + case 0: + p = "int"; + break; + case 1: + p = "userland const char *"; + break; + case 2: + p = "int"; + break; + case 3: + p = "userland const char *"; + break; + case 4: + p = "int"; + break; + default: + break; + }; + break; default: break; }; @@ -11511,6 +11544,11 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) if (ndx == 0 || ndx == 1) p = "int"; break; + /* renameat2 */ + case 602: + if (ndx == 0 || ndx == 1) + p = "int"; + break; default: break; }; diff --git a/sys/sys/syscall.h b/sys/sys/syscall.h index 814437732df3..0bbbf38ceea0 100644 --- a/sys/sys/syscall.h +++ b/sys/sys/syscall.h @@ -540,4 +540,5 @@ #define SYS_kexec_load 599 #define SYS_pdrfork 600 #define SYS_pdwait 601 -#define SYS_MAXSYSCALL 602 +#define SYS_renameat2 602 +#define SYS_MAXSYSCALL 603 diff --git a/sys/sys/syscall.mk b/sys/sys/syscall.mk index e9d54983b5c4..5c9bc8b3c0ab 100644 --- a/sys/sys/syscall.mk +++ b/sys/sys/syscall.mk @@ -443,4 +443,5 @@ MIASM = \ jail_remove_jd.o \ kexec_load.o \ pdrfork.o \ - pdwait.o + pdwait.o \ + renameat2.o diff --git a/sys/sys/sysproto.h b/sys/sys/sysproto.h index 0496077bb555..b3819b8f4bda 100644 --- a/sys/sys/sysproto.h +++ b/sys/sys/sysproto.h @@ -1925,6 +1925,13 @@ struct pdwait_args { char wrusage_l_[PADL_(struct __wrusage *)]; struct __wrusage * wrusage; char wrusage_r_[PADR_(struct __wrusage *)]; char info_l_[PADL_(struct __siginfo *)]; struct __siginfo * info; char info_r_[PADR_(struct __siginfo *)]; }; +struct renameat2_args { + char oldfd_l_[PADL_(int)]; int oldfd; char oldfd_r_[PADR_(int)]; + char old_l_[PADL_(const char *)]; const char * old; char old_r_[PADR_(const char *)]; + char newfd_l_[PADL_(int)]; int newfd; char newfd_r_[PADR_(int)]; + char new_l_[PADL_(const char *)]; const char * new; char new_r_[PADR_(const char *)]; + char flags_l_[PADL_(int)]; int flags; char flags_r_[PADR_(int)]; +}; int sys__exit(struct thread *, struct _exit_args *); int sys_fork(struct thread *, struct fork_args *); int sys_read(struct thread *, struct read_args *); @@ -2334,6 +2341,7 @@ int sys_jail_remove_jd(struct thread *, struct jail_remove_jd_args *); int sys_kexec_load(struct thread *, struct kexec_load_args *); int sys_pdrfork(struct thread *, struct pdrfork_args *); int sys_pdwait(struct thread *, struct pdwait_args *); +int sys_renameat2(struct thread *, struct renameat2_args *); #ifdef COMPAT_43 @@ -3335,6 +3343,7 @@ int freebsd14_setgroups(struct thread *, struct freebsd14_setgroups_args *); #define SYS_AUE_kexec_load AUE_NULL #define SYS_AUE_pdrfork AUE_PDRFORK #define SYS_AUE_pdwait AUE_PDWAIT +#define SYS_AUE_renameat2 AUE_RENAMEAT #undef PAD_ #undef PADL_ From nobody Thu Mar 5 23:48:27 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSq39q2z6Ts7N for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSq1H8mz3MKH for ; Thu, 05 Mar 2026 23:48:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754507; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wR86wjXnBsmP5MXwjvDrB+oefXJMg+3J3JJlILZMUlE=; b=oPVvhXKVhcZ5h5SHY2ArlUNM/IIYoqRM2jEvhf1Ad8c8rXxNMLs29m5mJPn9yCX/PWRiVW xvMMfkWQU366kFl0qMNNEIfCKMbhp4aVbe767nW0rqVg4AjI0xtDgrwUIs4EltsvJusMTw Js2dKTdR1r2lCQRLZd4jne4IN9VBXu8iGgXcu06PwYp4FW7bXYLql73fI0coyotpZqrW0A lAvIqx7HkQmsEL6gMzZHF+Tr+8fHoAmzDXKr2ZCuTL0qve0tHVU4pBPlo0Vp0ArW78r4pR Jz0TxmniT3Y0CBoGNI1nSLXLCFs1t8dLbKwDSz6c4Oe0Nc23pEhMaUnVJgBMLw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754507; a=rsa-sha256; cv=none; b=AA4LVi3uI+G2AFwkRf1SQw27cDG7pYwmHHLvSvXjigHvwO1Vm1RP7Y22m72oo7EHVzM4eo eR2c8QZYXB7PAsNa6B0LDihpHoJNQDKLgHNe1n/bE4ORyWtxgBMw04tZBb6TnCKOxZzFRy L6mhi/PVGF6GrlNnBXubTNCnrejtYLx5hwzyOlV/E04X6rY56i0/CEB+MLMb5ghhKgm+OY A5fwgUT/P/DGdIxu5oHC2upJTBAgylU61cAPEnPp62VMStmfdluYL/rb9CiZmkJdV6DYzc dkdVaBQH5auwfLfm2q6zWjxoyzziXsKW92/pYMbVrjHBG5kj5Chx9bVmsg5VbA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754507; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wR86wjXnBsmP5MXwjvDrB+oefXJMg+3J3JJlILZMUlE=; b=Owo98w5xWfUFbRvourQn5wFfjeK00iyJgLBhWMoWtfnutqsJQDIQIPph+Dx0cfNvbzAORZ b2ZTEPa1ReTgxcUSwRbJgBLhIeZwHTN49F6/jkOyET3IZapOpx084Llua3vPGQHmt7Rbvn eYuq1B4+tj3/ePSI2wvHoRrVGFjRBF+VMpfmrPYNIa3mO+U/UK0wLsdW18OCT+C18akoK5 ERegVWuo7oh3DFgmftmB+YlMImYw0OmokK78DGPmKzZCaf2XdAIX6g6SyvITK/wYZpXdA1 krfJOm40xUQ+1bgoEXt/D5TsgTL3YTBdn4CcEzFSD9UxxsZwZIybue9bkW/9Rw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSq0v91zygQ for ; Thu, 05 Mar 2026 23:48:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3f031 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:27 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 45117ffcd533 - main - vfs: add VOP_DELAYED_SETSIZE() and related infrastructure List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 45117ffcd533ddf995f654db60b10899ae8370ec Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:27 +0000 Message-Id: <69aa164b.3f031.66f290ac@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=45117ffcd533ddf995f654db60b10899ae8370ec commit 45117ffcd533ddf995f654db60b10899ae8370ec Author: Konstantin Belousov AuthorDate: 2026-02-28 16:11:58 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:54 +0000 vfs: add VOP_DELAYED_SETSIZE() and related infrastructure The change generalizes code that was initially developed for nfs client to handle filesystems that needs to call vnode_pager_setsize() while only owning the vnode lock shared. Since vnode pager might need to trim or extend the vnode vm_object' page queue, the vnode lock for the call must be owned exclusive. This is typical for filesystems with remote authorative source of file attributes, like nfs/p9/fuse. Handle the conflict by delaying the vnode_pager_setsize() to the next vnode locking to avoid relock. But if the next locking request is in shared mode, lock it exclusively instead, perform the delayed vnode_pager_setsize() call by doing VOP_DEFAULT_SETSIZE(), and then downgrade to shared. Filesystems that opt into the feature must provide the implementation of VOP_DELAYED_SETSIZE() that actually calls vnode_pager_setsize(), and use vn_delay_setsize() helper to mark the vnode as requiring the delay call. Reviewed by: rmacklem Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55595 --- sys/fs/deadfs/dead_vnops.c | 1 + sys/kern/vfs_default.c | 1 + sys/kern/vfs_vnops.c | 74 +++++++++++++++++++++++++++++++++++++++++++++- sys/kern/vnode_if.src | 8 +++++ sys/sys/vnode.h | 31 +++++++++++++++++++ 5 files changed, 114 insertions(+), 1 deletion(-) diff --git a/sys/fs/deadfs/dead_vnops.c b/sys/fs/deadfs/dead_vnops.c index 137c86b65058..b6d6fa55d221 100644 --- a/sys/fs/deadfs/dead_vnops.c +++ b/sys/fs/deadfs/dead_vnops.c @@ -80,6 +80,7 @@ struct vop_vector dead_vnodeops = { .vop_write = dead_write, .vop_fplookup_vexec = VOP_EOPNOTSUPP, .vop_fplookup_symlink = VOP_EOPNOTSUPP, + .vop_delayed_setsize = VOP_NULL, }; VFS_VOP_VECTOR_REGISTER(dead_vnodeops); diff --git a/sys/kern/vfs_default.c b/sys/kern/vfs_default.c index 468d5d18b02b..3151c69d1912 100644 --- a/sys/kern/vfs_default.c +++ b/sys/kern/vfs_default.c @@ -147,6 +147,7 @@ struct vop_vector default_vnodeops = { .vop_add_writecount = vop_stdadd_writecount, .vop_copy_file_range = vop_stdcopy_file_range, .vop_vput_pair = vop_stdvput_pair, + .vop_delayed_setsize = VOP_PANIC, }; VFS_VOP_VECTOR_REGISTER(default_vnodeops); diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c index a53df50c06bd..24efdf4ac0d5 100644 --- a/sys/kern/vfs_vnops.c +++ b/sys/kern/vfs_vnops.c @@ -1959,9 +1959,74 @@ _vn_lock_fallback(struct vnode *vp, int flags, const char *file, int line, return (0); } +static int +vn_lock_delayed_setsize(struct vop_lock1_args *ap) +{ + struct vnode *vp; + int error, lktype; + bool onfault; + + vp = ap->a_vp; + lktype = ap->a_flags & LK_TYPE_MASK; + if (vp->v_op == &dead_vnodeops) + return (0); + VI_LOCK(vp); + if ((vp->v_iflag & VI_DELAYEDSSZ) == 0 || (lktype != LK_SHARED && + lktype != LK_EXCLUSIVE && lktype != LK_UPGRADE && + lktype != LK_TRYUPGRADE)) { + VI_UNLOCK(vp); + return (0); + } + onfault = (ap->a_flags & LK_EATTR_MASK) == LK_NOWAIT && + (ap->a_flags & LK_INIT_MASK) == LK_CANRECURSE && + (lktype == LK_SHARED || lktype == LK_EXCLUSIVE); + if (onfault && vp->v_vnlock->lk_recurse == 0) { + /* + * Force retry in vm_fault(), to make the lock request + * sleepable, which allows us to piggy-back the + * sleepable call to vnode_pager_setsize(). + */ + VI_UNLOCK(vp); + VOP_UNLOCK(vp); + return (EBUSY); + } + if ((ap->a_flags & LK_NOWAIT) != 0 || + (lktype == LK_SHARED && vp->v_vnlock->lk_recurse > 0)) { + VI_UNLOCK(vp); + return (0); + } + if (lktype == LK_SHARED) { + VOP_UNLOCK(vp); + ap->a_flags &= ~LK_TYPE_MASK; + ap->a_flags |= LK_EXCLUSIVE | LK_INTERLOCK; + error = VOP_LOCK1_APV(&default_vnodeops, ap); + if (error != 0 || vp->v_op == &dead_vnodeops) + return (error); + if (vp->v_data == NULL) + goto downgrade; + MPASS(vp->v_data != NULL); + VI_LOCK(vp); + if ((vp->v_iflag & VI_DELAYEDSSZ) == 0) { + VI_UNLOCK(vp); + goto downgrade; + } + } + vp->v_iflag &= ~VI_DELAYEDSSZ; + VI_UNLOCK(vp); + VOP_DELAYED_SETSIZE(vp); +downgrade: + if (lktype == LK_SHARED) { + ap->a_flags &= ~(LK_TYPE_MASK | LK_INTERLOCK); + ap->a_flags |= LK_DOWNGRADE; + (void)VOP_LOCK1_APV(&default_vnodeops, ap); + } + return (0); +} + int _vn_lock(struct vnode *vp, int flags, const char *file, int line) { + struct vop_lock1_args ap; int error; VNASSERT((flags & LK_TYPE_MASK) != 0, vp, @@ -1970,7 +2035,14 @@ _vn_lock(struct vnode *vp, int flags, const char *file, int line) error = VOP_LOCK1(vp, flags, file, line); if (__predict_false(error != 0 || VN_IS_DOOMED(vp))) return (_vn_lock_fallback(vp, flags, file, line, error)); - return (0); + if (__predict_false((vp->v_iflag & VI_DELAYEDSSZ) == 0)) + return (0); + ap.a_gen.a_desc = &vop_lock1_desc; + ap.a_vp = vp; + ap.a_flags = flags; + ap.a_file = file; + ap.a_line = line; + return (vn_lock_delayed_setsize(&ap)); } /* diff --git a/sys/kern/vnode_if.src b/sys/kern/vnode_if.src index 6b7448d9f1df..78ba1aa7afda 100644 --- a/sys/kern/vnode_if.src +++ b/sys/kern/vnode_if.src @@ -847,6 +847,14 @@ vop_inotify_add_watch { IN struct thread *td; }; + +%% delayed_setsize vp E E E + +vop_delayed_setsize { + IN struct vnode *vp; +}; + + # The VOPs below are spares at the end of the table to allow new VOPs to be # added in stable branches without breaking the KBI. New VOPs in HEAD should # be added above these spares. When merging a new VOP to a stable branch, diff --git a/sys/sys/vnode.h b/sys/sys/vnode.h index 1a267e0e272c..36e10fd8d8b7 100644 --- a/sys/sys/vnode.h +++ b/sys/sys/vnode.h @@ -268,6 +268,7 @@ _Static_assert(sizeof(struct vnode) <= 448, "vnode size crosses 448 bytes"); #define VI_DEFINACT 0x0010 /* deferred inactive */ #define VI_FOPENING 0x0020 /* In open, with opening process having the first right to advlock file */ +#define VI_DELAYEDSSZ 0x0040 /* Delayed setsize */ #define VV_ROOT 0x0001 /* root of its filesystem */ #define VV_ISTTY 0x0002 /* vnode represents a tty */ @@ -1251,6 +1252,36 @@ vn_get_state(struct vnode *vp) atomic_load_consume_ptr(&(_vp)->v_data);\ }) +static inline void +vn_delay_setsize_locked(struct vnode *vp) +{ + ASSERT_VI_LOCKED(vp, "delayed_setsize"); + vp->v_iflag |= VI_DELAYEDSSZ; +} + +static inline void +vn_delay_setsize(struct vnode *vp) +{ + VI_LOCK(vp); + vn_delay_setsize_locked(vp); + VI_UNLOCK(vp); +} + +static inline void +vn_clear_delayed_setsize_locked(struct vnode *vp) +{ + ASSERT_VI_LOCKED(vp, "delayed_setsize"); + vp->v_iflag &= ~VI_DELAYEDSSZ; +} + +static inline void +vn_clear_delayed_setsize(struct vnode *vp) +{ + VI_LOCK(vp); + vn_clear_delayed_setsize_locked(vp); + VI_UNLOCK(vp); +} + #endif /* _KERNEL */ #endif /* !_SYS_VNODE_H_ */ From nobody Thu Mar 5 23:48:28 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSr4sxnz6TsJJ for ; Thu, 05 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmSr2Dq3z3MD9 for ; Thu, 05 Mar 2026 23:48:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754508; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6g5zoZ9rLlQONg9RJaCoH/OPhTHJnBQpue8WTX6wMNE=; b=I4wtj+yKA7PcGPuqtJzqQlhoT1W/IqOdpUgfSCr+v/LgO0mpzcR/61uy/7GiNj3wjYeA/8 ++my5B0CFkwnFbqkHbAZOSKnVAx7mFyFuZCgxHtBO6+pyLn/wsE4jElz6rvmTEk2Yg7rmy emYa+1WFHzUdsM/nR80hE+7PWmgeuvzbr9hyR3YGoAPYjWy1bp0nAEciwllFtDV2wtRJWB QCnQc3GoQChKD5AfcjACY3v7T11EAxZyz7tRv4vk+uGIUvy6njS1L59h4FaT9KBV9JU+Kf LqOKGAQAQdIp0GUJCH0aczIRLkA+TD7eo1Y7e0qnR1flHYHe+I2i7x0sPl9GMg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754508; a=rsa-sha256; cv=none; b=OjlLshzLuRhKyoIFt3h8ZVqpaDbiKegZPyzlEq+tHJf17lGB8nbVu7i+Vq7E+n9UikA6YB L11sEJq7VEfnpire8FP5OfiZBDDD7Iie1eOoSRKPI4ElK5QwB3zbE3ui59CEPMnNwefx1T z6hFtmwXUqUr0xsamhSwhbNNIdvtKPMgYYTO0U4+9YIQBM8U0ffGBkxVTzLJXC+OE6JrsK zNsr4cu9NRO//ZnwN5JVwvDvsJJjxSfOtYlJuu1FItKyCUwOy62t5v8BZitSTMBLQVXPvU E/a/6kDjRlH6V0kQyjB0l09Cb18Qs80Pl54H68fJhFApYBUk3WsyWYUluR2ErA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754508; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6g5zoZ9rLlQONg9RJaCoH/OPhTHJnBQpue8WTX6wMNE=; b=t5E9n+QWI8ushSuuAASSAew01HV+FT4egPBSfaCdv+TsZC7AcTB9vd7LaDsJNEifMgYn+3 4W7CEEePG9H0U6+3xBuppTOhW2rZw0MpFfkyLnjClwijLPBIEDa6RuyapcGlMWcE0yKUCI /KD7dxvAgeBZUzS43bJc7BLZi+tTTm/tLmO0OnEEbLiRJkxYD9J44zhKCdoBKy2JIHxb9O oLLHGd5wiLTkbTQwDfI37tyqZLIKWmLAXk6GqeGCHgZr968MCqdXCScL4LSzBpbYe9XEnz 8yKVtDsQMUrOHsHspYUyPsPH9ErkugAv718QsUVuW+y447Z1Arlhj8kVjezSSg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmSr1jw1zyNk for ; Thu, 05 Mar 2026 23:48:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3f8f4 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:48:28 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 5c71df985035 - main - nfsclient: convert to use vn_delayed_setsize() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 5c71df9850355e20cf8f89fb656b18ef79cdf178 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:48:28 +0000 Message-Id: <69aa164c.3f8f4.35428cd8@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=5c71df9850355e20cf8f89fb656b18ef79cdf178 commit 5c71df9850355e20cf8f89fb656b18ef79cdf178 Author: Konstantin Belousov AuthorDate: 2026-02-28 16:26:12 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:46:54 +0000 nfsclient: convert to use vn_delayed_setsize() Reviewed by: rmacklem Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55595 --- sys/fs/nfsclient/nfs_clbio.c | 4 +-- sys/fs/nfsclient/nfs_clport.c | 2 +- sys/fs/nfsclient/nfs_clvnops.c | 68 +++++------------------------------------- sys/fs/nfsclient/nfsnode.h | 1 - 4 files changed, 10 insertions(+), 65 deletions(-) diff --git a/sys/fs/nfsclient/nfs_clbio.c b/sys/fs/nfsclient/nfs_clbio.c index e181bf593e23..b534a2eb5555 100644 --- a/sys/fs/nfsclient/nfs_clbio.c +++ b/sys/fs/nfsclient/nfs_clbio.c @@ -1041,7 +1041,7 @@ again: NFSLOCKNODE(np); np->n_size = uio->uio_offset + n; np->n_flag |= NMODIFIED; - np->n_flag &= ~NVNSETSZSKIP; + vn_clear_delayed_setsize(vp); vnode_pager_setsize(vp, np->n_size); NFSUNLOCKNODE(np); @@ -1071,7 +1071,7 @@ again: if (uio->uio_offset + n > np->n_size) { np->n_size = uio->uio_offset + n; np->n_flag |= NMODIFIED; - np->n_flag &= ~NVNSETSZSKIP; + vn_clear_delayed_setsize(vp); vnode_pager_setsize(vp, np->n_size); } NFSUNLOCKNODE(np); diff --git a/sys/fs/nfsclient/nfs_clport.c b/sys/fs/nfsclient/nfs_clport.c index c5f7ce0a12c7..1156e1738703 100644 --- a/sys/fs/nfsclient/nfs_clport.c +++ b/sys/fs/nfsclient/nfs_clport.c @@ -646,7 +646,7 @@ ncl_pager_setsize(struct vnode *vp, u_quad_t *nsizep) (curthread->td_pflags2 & TDP2_SBPAGES) == 0) setnsize = true; else - np->n_flag |= NVNSETSZSKIP; + vn_delay_setsize(vp); } if (nsizep == NULL) { NFSUNLOCKNODE(np); diff --git a/sys/fs/nfsclient/nfs_clvnops.c b/sys/fs/nfsclient/nfs_clvnops.c index edd6974a50d0..26aa6491ac4a 100644 --- a/sys/fs/nfsclient/nfs_clvnops.c +++ b/sys/fs/nfsclient/nfs_clvnops.c @@ -155,7 +155,7 @@ static vop_getextattr_t nfs_getextattr; static vop_setextattr_t nfs_setextattr; static vop_listextattr_t nfs_listextattr; static vop_deleteextattr_t nfs_deleteextattr; -static vop_lock1_t nfs_lock; +static vop_delayed_setsize_t nfs_delayed_setsize; /* * Global vfs data structures for nfs @@ -168,13 +168,13 @@ static struct vop_vector newnfs_vnodeops_nosig = { .vop_advlockasync = nfs_advlockasync, .vop_close = nfs_close, .vop_create = nfs_create, + .vop_delayed_setsize = nfs_delayed_setsize, .vop_fsync = nfs_fsync, .vop_getattr = nfs_getattr, .vop_getpages = ncl_getpages, .vop_putpages = ncl_putpages, .vop_inactive = ncl_inactive, .vop_link = nfs_link, - .vop_lock1 = nfs_lock, .vop_lookup = nfs_lookup, .vop_mkdir = nfs_mkdir, .vop_mknod = nfs_mknod, @@ -331,73 +331,19 @@ SYSCTL_U64(_vfs_nfs, OID_AUTO, maxalloclen, CTLFLAG_RW, */ static int -nfs_lock(struct vop_lock1_args *ap) +nfs_delayed_setsize(struct vop_delayed_setsize_args *ap) { struct vnode *vp; struct nfsnode *np; u_quad_t nsize; - int error, lktype; - bool onfault; vp = ap->a_vp; - lktype = ap->a_flags & LK_TYPE_MASK; - error = VOP_LOCK1_APV(&default_vnodeops, ap); - if (error != 0 || vp->v_op != &newnfs_vnodeops) - return (error); np = VTONFS(vp); - if (np == NULL) - return (0); - NFSLOCKNODE(np); - if ((np->n_flag & NVNSETSZSKIP) == 0 || (lktype != LK_SHARED && - lktype != LK_EXCLUSIVE && lktype != LK_UPGRADE && - lktype != LK_TRYUPGRADE)) { - NFSUNLOCKNODE(np); - return (0); - } - onfault = (ap->a_flags & LK_EATTR_MASK) == LK_NOWAIT && - (ap->a_flags & LK_INIT_MASK) == LK_CANRECURSE && - (lktype == LK_SHARED || lktype == LK_EXCLUSIVE); - if (onfault && vp->v_vnlock->lk_recurse == 0) { - /* - * Force retry in vm_fault(), to make the lock request - * sleepable, which allows us to piggy-back the - * sleepable call to vnode_pager_setsize(). - */ - NFSUNLOCKNODE(np); - VOP_UNLOCK(vp); - return (EBUSY); - } - if ((ap->a_flags & LK_NOWAIT) != 0 || - (lktype == LK_SHARED && vp->v_vnlock->lk_recurse > 0)) { - NFSUNLOCKNODE(np); - return (0); - } - if (lktype == LK_SHARED) { - NFSUNLOCKNODE(np); - VOP_UNLOCK(vp); - ap->a_flags &= ~(LK_TYPE_MASK | LK_INTERLOCK); - ap->a_flags |= LK_EXCLUSIVE; - error = VOP_LOCK1_APV(&default_vnodeops, ap); - if (error != 0 || vp->v_op != &newnfs_vnodeops) - return (error); - if (vp->v_data == NULL) - goto downgrade; - MPASS(vp->v_data == np); + if (np != NULL) { NFSLOCKNODE(np); - if ((np->n_flag & NVNSETSZSKIP) == 0) { - NFSUNLOCKNODE(np); - goto downgrade; - } - } - np->n_flag &= ~NVNSETSZSKIP; - nsize = np->n_size; - NFSUNLOCKNODE(np); - vnode_pager_setsize(vp, nsize); -downgrade: - if (lktype == LK_SHARED) { - ap->a_flags &= ~(LK_TYPE_MASK | LK_INTERLOCK); - ap->a_flags |= LK_DOWNGRADE; - (void)VOP_LOCK1_APV(&default_vnodeops, ap); + nsize = np->n_size; + NFSUNLOCKNODE(np); + vnode_pager_setsize(vp, nsize); } return (0); } diff --git a/sys/fs/nfsclient/nfsnode.h b/sys/fs/nfsclient/nfsnode.h index 9b2627015612..07c7ccb0ff10 100644 --- a/sys/fs/nfsclient/nfsnode.h +++ b/sys/fs/nfsclient/nfsnode.h @@ -160,7 +160,6 @@ struct nfsnode { #define NWRITEOPENED 0x00040000 /* Has been opened for writing */ #define NHASBEENLOCKED 0x00080000 /* Has been file locked. */ #define NDSCOMMIT 0x00100000 /* Commit is done via the DS. */ -#define NVNSETSZSKIP 0x00200000 /* Skipped vnode_pager_setsize() */ #define NMIGHTBELOCKED 0x00400000 /* Might be file locked. */ #define NNAMEDNOTSUPP 0x00800000 /* Openattr is not supported. */ From nobody Thu Mar 5 23:55:37 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmd60DNtz6Tsm0 for ; Thu, 05 Mar 2026 23:55: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmd54nrtz3Syg for ; Thu, 05 Mar 2026 23:55:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754937; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HsqrDDlJy3YuZPpCgfI0e1MchUyexgHNsWfyxgHV1K4=; b=toYjSNIIjpvQtvKmXnLJr6lpeaumdZmjmXWWqg5Ds6U6CegkuK/uQ89MEl9wQsX1/UVqvS /99Dr4FX4IvVBk79VETx/I9NYNklh/kv7vHOpVrnyUXPkN2canS3b3VZzsI6N9jeJ1K8t2 OLa8cO2HL1uhnLhfvp+JgVGN3jHjudNqS6pIbPPV5i6API7j9rcTIaADtFGhvoZdZzOTKY nkPYqzey9ZQiF7lAVo7RMSdtv2InUQ7lV6m+5FaA8C1pdy6jFgG87oi6uydHCKXtPmQZIw cnD3DBRPbC+1BywVJ4U4Tg079dj9U1TQWQqJHGjJQo5CIqy+XyCNue0Zgd6n/w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754937; a=rsa-sha256; cv=none; b=L415WHTlocKvCzpm3XQwvP9kY1hqqVVUuviQz+4wMWgFJBBwjLeqpb4jr+Le6938fpFFXg +x8YSjTa3t7KyCX5AaTyrLp6Bm6AHTb1y2/W8pQwhMoAOCMEB4Ci4QUA3UxQLE0ptSbvP/ d9VGHugy4PPSRToRV1pQ8Cuodlk2NwxpYkfw8iunaSDu8gOk1PvS7kHhL7ibBPYVP7u+N7 vgRqKFZVK4/HOEmhDC6b6i2aywdcmta/Tywyd5ywRuXOs8ppXaDEpEYRtUXR/I8NHnLARj j2gqQQio2rrDgZMNHzTxKKM9xdVb6T/cVNW/OsXnUESgemuRa9jog7DXzjqybQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754937; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HsqrDDlJy3YuZPpCgfI0e1MchUyexgHNsWfyxgHV1K4=; b=WH1JcUxn2083M3poTQndwldIuooIJ8rLiz09mgeUHSd06IX9yCM9qMAhqHw6FpzaD6avyV DvQT08SqOpNGMRe4EiUdD0OWt6N9VWbMvcDw86KdFSk+lLAjaQQ+ivHcvyC0+lLH906u1g Y8aKHpBoEjJKzBEfHNCOr56IaP4mE2cTfAkHmahSmNRt52/J2Gw3kKY0vpSwMToEfUTKKT x7pfyiZMYUwwm2JKETd97nnhxAU3SyYYLnPyFc6FE7c0IOn9u+qTfCoQjbLkcY5m/mb9Q1 H55kX0lAquVRFYYgVRmx90iMY83M5qJcLc4/msy/kaI6DSkora2Ao3+ICByIpg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmd53ZGyzyQV for ; Thu, 05 Mar 2026 23:55:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1821b by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:55:37 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 272ea4511994 - main - amd64: print userspace fsbase and gsbase for uprintf_signal List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 272ea451199462dffd55dd580532eb28ddc92174 Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:55:37 +0000 Message-Id: <69aa17f9.1821b.55252830@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=272ea451199462dffd55dd580532eb28ddc92174 commit 272ea451199462dffd55dd580532eb28ddc92174 Author: Konstantin Belousov AuthorDate: 2026-03-04 03:22:26 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:53:57 +0000 amd64: print userspace fsbase and gsbase for uprintf_signal --- sys/amd64/amd64/trap.c | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/sys/amd64/amd64/trap.c b/sys/amd64/amd64/trap.c index d07fbc223193..d173f57e2e4f 100644 --- a/sys/amd64/amd64/trap.c +++ b/sys/amd64/amd64/trap.c @@ -182,15 +182,32 @@ trap_uprintf_signal(struct thread *td, struct trapframe *frame, register_t addr, int signo, int ucode) { struct proc *p; + struct pcb *pcb; + register_t fsbase, gsbase, r; if (!uprintf_signal) return; p = td->td_proc; + pcb = td->td_pcb; + if ((cpu_stdext_feature & CPUID_STDEXT_FSGSBASE) != 0) { + r = intr_disable(); + if ((pcb->pcb_flags & PCB_FULL_IRET) == 0) { + fsbase = rdfsbase(); + gsbase = rdmsr(MSR_KGSBASE); + } else { + fsbase = pcb->pcb_fsbase; + gsbase = pcb->pcb_gsbase; + } + intr_restore(r); + } else { + fsbase = pcb->pcb_fsbase; + gsbase = pcb->pcb_gsbase; + } uprintf("pid %d comm %s: signal %d err %#lx code %d type %d " - "addr %#lx rsp %#lx rip %#lx rax %#lx " + "addr %#lx rsp %#lx rip %#lx rax %#lx fsb %#lx gsb %#lx " "<%02x %02x %02x %02x %02x %02x %02x %02x>\n", p->p_pid, p->p_comm, signo, frame->tf_err, ucode, frame->tf_trapno, - addr, frame->tf_rsp, frame->tf_rip, frame->tf_rax, + addr, frame->tf_rsp, frame->tf_rip, frame->tf_rax, fsbase, gsbase, fubyte((void *)(frame->tf_rip + 0)), fubyte((void *)(frame->tf_rip + 1)), fubyte((void *)(frame->tf_rip + 2)), From nobody Thu Mar 5 23:55:36 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRmd60DkZz6TsxT for ; Thu, 05 Mar 2026 23:55: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRmd54Q4Dz3T99 for ; Thu, 05 Mar 2026 23:55:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754937; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jN6xhYYVBuCfwwYGX41jddmHAvHsmPIeFs7Q1cNe1t4=; b=NRieurUJ1zysCOyE9zZLZXKDOYzdRQ4NAUEofzSyPjB6nACzaEMrzUmnBYTLIMo7mV9AKx RvHavnf9Mbu1fJBXSsE2ARc4Cx7jXrPaskUOmvkpnNVRTbwV+XCUPpt6QcVTdqrw8AvZYn M09d8iCwif86pRRZscg3o/VaSphsT5QVGj9grgVVnxEsHhORrvDeGsCcFiPwoDhvcJt3GO p8DxMWs9Xz4tB2/GSH53N8MglSXKVUBDQOAlvFXpxE4YoTFrNfxNNf8Tv//GlwF1A9ayvg xg70kK2CZm4pFvldJQVa7e31iR7VazEL14RJ5or3DEP24oEVmS4ssXlsK5pkrA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772754937; a=rsa-sha256; cv=none; b=J4URTI2WOhO7mbWOsd3AmDjDPEs3iqybjdzRtk7oBZOxXcJPa/pLd2dz3MnMrr6hkRUe8u F9O3ImLSF4oXgRpCD7tvBDS5OZD8dEKr5Th+riNPnEmkSMjKVUZtE3X/eo+UfjsAo1dGzX AfNhqO7piZpMcuqK+1opQFQSdq3kJkbH3snZtPPWSqpaNcnnTD6wIQRu+7bgCV3V/jcL3u UaHP2lPy1nccO5qubUlrIPXaDXJR5I2lsbwTrYdb+3kQUvNn53lFJ/4c60/lDALiPtLFTq hOqVokkcy+asU/JFzFuUvS6n4jb6Oj9GJT8/dEwcsY1jntB2x7tI0Hd5vRu7LA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772754937; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jN6xhYYVBuCfwwYGX41jddmHAvHsmPIeFs7Q1cNe1t4=; b=djYfbocseCjSi8vXhEVK3/788/glAK6SUmWscWK3KUqIU2ME6whwnKgz5bsIIHlX47WWsV VBbs8WWFDtxd8UhG0M3vHIdixpWPkUvTnx2Z+GFfQ6jCKUZA+xLrPiSYXH4SehPDOZyVmG aD5fwd2R70FP3AzMTkHIztovXglG2qIEsg1lujWHO9pOASkx6B/pBuLpjdfWLAGg4bPxy8 zidd4QaOYwtc/MGgxxkdL41EYtYJcMaM92+CtX8O6+qqc77oYzdroAWQyOlr1Ab9YqTHHH p4FSU5en55Di1pkqRrhNzpD3u8ooFpmY2nYJ+57x3HNz7KyrD5iKSTm+VjjqSA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRmd53WMtzyMP for ; Thu, 05 Mar 2026 23:55:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 18217 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 05 Mar 2026 23:55:36 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 3e8a9995e954 - main - amd64: extract uprintf_signal printing into a helper List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 3e8a9995e9541a0bdd707f111e51ef46a544ee3e Auto-Submitted: auto-generated Date: Thu, 05 Mar 2026 23:55:36 +0000 Message-Id: <69aa17f8.18217.2cae361d@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=3e8a9995e9541a0bdd707f111e51ef46a544ee3e commit 3e8a9995e9541a0bdd707f111e51ef46a544ee3e Author: Konstantin Belousov AuthorDate: 2026-02-18 19:04:39 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-05 23:53:57 +0000 amd64: extract uprintf_signal printing into a helper --- sys/amd64/amd64/trap.c | 40 +++++++++++++++++++++++++--------------- 1 file changed, 25 insertions(+), 15 deletions(-) diff --git a/sys/amd64/amd64/trap.c b/sys/amd64/amd64/trap.c index 84305ca918df..d07fbc223193 100644 --- a/sys/amd64/amd64/trap.c +++ b/sys/amd64/amd64/trap.c @@ -177,6 +177,30 @@ SYSCTL_INT(_machdep, OID_AUTO, nmi_flush_l1d_sw, CTLFLAG_RWTUN, &nmi_flush_l1d_sw, 0, "Flush L1 Data Cache on NMI exit, software bhyve L1TF mitigation assist"); +static void +trap_uprintf_signal(struct thread *td, struct trapframe *frame, register_t addr, + int signo, int ucode) +{ + struct proc *p; + + if (!uprintf_signal) + return; + p = td->td_proc; + uprintf("pid %d comm %s: signal %d err %#lx code %d type %d " + "addr %#lx rsp %#lx rip %#lx rax %#lx " + "<%02x %02x %02x %02x %02x %02x %02x %02x>\n", + p->p_pid, p->p_comm, signo, frame->tf_err, ucode, frame->tf_trapno, + addr, frame->tf_rsp, frame->tf_rip, frame->tf_rax, + fubyte((void *)(frame->tf_rip + 0)), + fubyte((void *)(frame->tf_rip + 1)), + fubyte((void *)(frame->tf_rip + 2)), + fubyte((void *)(frame->tf_rip + 3)), + fubyte((void *)(frame->tf_rip + 4)), + fubyte((void *)(frame->tf_rip + 5)), + fubyte((void *)(frame->tf_rip + 6)), + fubyte((void *)(frame->tf_rip + 7))); +} + /* * Table of handlers for various segment load faults. */ @@ -626,21 +650,7 @@ trap(struct trapframe *frame) ksi.ksi_code = ucode; ksi.ksi_trapno = type; ksi.ksi_addr = (void *)addr; - if (uprintf_signal) { - uprintf("pid %d comm %s: signal %d err %#lx code %d type %d " - "addr %#lx rsp %#lx rip %#lx rax %#lx " - "<%02x %02x %02x %02x %02x %02x %02x %02x>\n", - p->p_pid, p->p_comm, signo, frame->tf_err, ucode, type, - addr, frame->tf_rsp, frame->tf_rip, frame->tf_rax, - fubyte((void *)(frame->tf_rip + 0)), - fubyte((void *)(frame->tf_rip + 1)), - fubyte((void *)(frame->tf_rip + 2)), - fubyte((void *)(frame->tf_rip + 3)), - fubyte((void *)(frame->tf_rip + 4)), - fubyte((void *)(frame->tf_rip + 5)), - fubyte((void *)(frame->tf_rip + 6)), - fubyte((void *)(frame->tf_rip + 7))); - } + trap_uprintf_signal(td, frame, addr, signo, ucode); KASSERT((read_rflags() & PSL_I) != 0, ("interrupts disabled")); trapsignal(td, &ksi); From nobody Fri Mar 6 02:51:43 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRrXJ0zWhz6SvLm for ; Fri, 06 Mar 2026 02:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRrXJ09lwz3n1d for ; Fri, 06 Mar 2026 02:51:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772765504; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=do2SWjpDZ6nGpPD7ApVHToPhzd86hXs6PfC+V0C5I2w=; b=FqUzVJMSml1DCgigTJxGDKhZF0k/FzJu7qdZAEqGwOzEhOsrW4mkc5pE0p28O3VlMNL8Af MDqvB/wwQHOzAQe/qn4NHFL/l6eZSWBkMJBk8dStZzBbSCogqjnR3ni32RX7LdMdNox946 00EsyeSAh5bzCxnjoAec3z9KrftAfV3C5gDxIK58DTJz3Zysn2SjoTnbFtDTN/RbC4pv78 7hjLTHCwqF5SxafxviLRLeg/bozMIaUW6Cvb+xM5dlyn8m2lLc/Hgr/Z71hMev0iTb7qvz 8i8CVRA7aL8AQksGzCK8WHQgijn0oQMgnCG8j0iiwPAjtjStlxDDjPHKY4wZjw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772765504; a=rsa-sha256; cv=none; b=qVy8xWBcX+VTmNM2oaJo7EOA+DwVpRbCE5eoHUmTHlZoyU9dOeK/AhlUfRCtsnfJCzwj8s jRQh2FzKTaCzr5CxUvUu8RoThiQKvyrk8iORRCAIXss+evdiXOk8ry7R6YJg3ThVIHBacb cOU2a/8lILApKduxDOK3zu80jzfEFR403lHy6r3w0TQJ/MG0+6+On1is9vsm/wt1KPEEIK fcch3JmStQ2SaaDBahNSB3p0ElfVAgAix65+muC5UrCOeHvtkxbAHWUXgQ2eKesOtghYeT VKrt472XJCS/CMau4S4H0d+TUN5nPqJaIbmZEL2rrh3pdHNxElAqdnoEBPw3vw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772765504; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=do2SWjpDZ6nGpPD7ApVHToPhzd86hXs6PfC+V0C5I2w=; b=doeI1U7602/YnnSx8LEhBQfD6WPOIYVYGFTlAqjbGWszk3DmQScUPZ7yz4XHJ/2+eYjHs4 haqMXCe4cscr5GLRQmj7SOGgIGgAJJdFGB/fwJH8tEI9Q0Yrk1jyIcoJLGuZRkjQO6dlUs z1Jjap8QYQyFqIUz+YtILgOBwuXhTXa0qLERKU6mYSDu6CtkJ2pk+8W/p2T/TDwwHJU3u7 9f9RWh+vT/NQcFJE0qQZZhSoifS6nM+Gwmf9DlJgmMefQgorteo8MAcjn4YPDk3XOTX5gB iMJSSNeM53E8RWhon8zg+ioSU/nediQDOGUMrmX+ncSYxDwMbwvQ32GyB6qg7g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRrXH6tpTz13wc for ; Fri, 06 Mar 2026 02:51:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3391b by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 02:51:43 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 551c4cb74a80 - main - iwlwifi: mld: move module_init() to SI_ORDER_SECOND List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 551c4cb74a807ceae55288bf273f5cfeb37c7c91 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 02:51:43 +0000 Message-Id: <69aa413f.3391b.12f726e4@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=551c4cb74a807ceae55288bf273f5cfeb37c7c91 commit 551c4cb74a807ceae55288bf273f5cfeb37c7c91 Author: Bjoern A. Zeeb AuthorDate: 2026-03-05 12:41:46 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-06 02:49:07 +0000 iwlwifi: mld: move module_init() to SI_ORDER_SECOND In FreeBSD the iwlwifi driver is a single kernel module. As for iwlwifi/mvm we need to make sure the common "iwlwifi drv" code is initialized before trying to register the mld sub-driver in order for lists, etc. in the registration code to be initialized. We do this by using an extended (FreeBSD specific) version of module_init which overrides the order parameter of the SYSINIT. Otherwise we can randomly (depending on SYSINIT run order) run into a NULL pointer deref panic. Sponsored by: The FreeBSD Foundation PR: 291120 MFC after: 3 days --- sys/contrib/dev/iwlwifi/mld/mld.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/contrib/dev/iwlwifi/mld/mld.c b/sys/contrib/dev/iwlwifi/mld/mld.c index 7b46ccc306ab..8075b886ddbf 100644 --- a/sys/contrib/dev/iwlwifi/mld/mld.c +++ b/sys/contrib/dev/iwlwifi/mld/mld.c @@ -44,7 +44,11 @@ static int __init iwl_mld_init(void) return ret; } +#if defined(__linux__) module_init(iwl_mld_init); +#elif defined(__FreeBSD__) +module_init_order(iwl_mld_init, SI_ORDER_SECOND); +#endif static void __exit iwl_mld_exit(void) { From nobody Fri Mar 6 02:51:45 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRrXK4B7sz6SvKW for ; Fri, 06 Mar 2026 02:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRrXK135gz3nDx for ; Fri, 06 Mar 2026 02:51:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772765505; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=QJRWJ6V29lxl5LuMs16S9ywuXtcQK0nX4+5BqdjJq9M=; b=SCLZ93X7hSj9PORhc7vp9z5m/hlto7u4szyZMwZ49ULcJTEJ1eiNftP0xoH6uFIvGQ8/oJ cu9PCsKbP/5hC4ULBe3C99VNgWVduyKuRuYu8Jq0VVt1GBusKe1g1RFM0519DeOX1kswD6 1fQ/gs/3POe+knK855FRIQq9czLnlyT9vj/QMaayVeJT3NzORar92M3Jbkr4lpPm6P8z1A OmKXhWfyW6dASkB+BxakjNHQkTzmTY6atFbshH+sZ/MkHgjUTuiWVe+G1zMrgBZACNfUQZ JBRRCYbldsOs1+wCeosetEsgUcCnRCuOWzhUEQ2JFdJU940ZKA1lqIyDSqqxNA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772765505; a=rsa-sha256; cv=none; b=voBYa/RNxZqFH9HwE0ygoQS3yPFLyhUh77qrC09H0urPfDTl8BQnHPyhcwaTogTMNWH+0U zgUJQy4d1JsfqE3igq8TMpIEyl/x27g+CzwCQK+eTv1HUbmOTwxVbVDfJDz4KByJCqyHyP Z+rTdN556+TWQeVo+ZgNldtV1PiTGpytilPEG9zjhYHM6B7lZIVBPfpdnv3H+KxNju4A47 64iy/3QiVwtCLd0Ax2G9pVff/CBvSBVC4lfR+aG7ziyPnQ7eLNRlp7WTpd0WKBDllvgwHJ ZtasTZYhQzyu8aIjdR8p4355Y0aliskQKyR/AG+sx49D4NlOZKAd2NGkNygfrQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772765505; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=QJRWJ6V29lxl5LuMs16S9ywuXtcQK0nX4+5BqdjJq9M=; b=vWNJAI5GXLLdxy9upLaPhKGq4bJErNR2Dk3q1FKK8yVmlMMwEDP2fKoIOVvIAx/yluJGK7 FRKWOjXuKyXXgChnUJLloIpbR4ogDOz0mu+uS9q1sT43VBApMCzVjPIL4uK6BbUrhxXy4S hUxH+58phx2Obkr3fEX5IJKgG7MACULMESGukCQOs3oL3+KrcpMzidnHsOQk03X43cOdZm 0dta6egj779DizlqOrKYSJs7OGnEGG41uUFRFmB8w0nH22RmQke5RA05+cE8SNDs9Kd5rl m6VfEN7q78HDT6zReA4XJL+YjqdkMTzyGRhfF5iGTQf3Nupytfzc2Ru3x9Qgaw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRrXK0XtFz13tv for ; Fri, 06 Mar 2026 02:51:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3421c by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 02:51:45 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 782fe2f8d904 - main - iwlwifi: adjust driver description List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 782fe2f8d90488a61ecdbe1d4b245900a88bee56 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 02:51:45 +0000 Message-Id: <69aa4141.3421c.7731f086@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=782fe2f8d90488a61ecdbe1d4b245900a88bee56 commit 782fe2f8d90488a61ecdbe1d4b245900a88bee56 Author: Bjoern A. Zeeb AuthorDate: 2026-03-05 19:40:15 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-06 02:49:30 +0000 iwlwifi: adjust driver description Adjust the module driver descriptions for mvm and mld to make it clear that this is not a driver for Linux but a Linux-based driver for FreeBSD. Cleanup surroundings. Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/contrib/dev/iwlwifi/mld/mld.c | 6 ++++++ sys/contrib/dev/iwlwifi/mvm/ops.c | 3 +-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/sys/contrib/dev/iwlwifi/mld/mld.c b/sys/contrib/dev/iwlwifi/mld/mld.c index 8075b886ddbf..3df9cabd34de 100644 --- a/sys/contrib/dev/iwlwifi/mld/mld.c +++ b/sys/contrib/dev/iwlwifi/mld/mld.c @@ -28,9 +28,15 @@ #include "iwl-nvm-parse.h" +#if defined(__linux__) #define DRV_DESCRIPTION "Intel(R) MLD wireless driver for Linux" +#elif defined(__FreeBSD__) +#define DRV_DESCRIPTION "Intel(R) MLD wireless Linux-based driver for FreeBSD" +#endif MODULE_DESCRIPTION(DRV_DESCRIPTION); +#if defined(__linux__) MODULE_LICENSE("GPL"); +#endif MODULE_IMPORT_NS("IWLWIFI"); static const struct iwl_op_mode_ops iwl_mld_ops; diff --git a/sys/contrib/dev/iwlwifi/mvm/ops.c b/sys/contrib/dev/iwlwifi/mvm/ops.c index 912fb6677a0d..2dee21163d4f 100644 --- a/sys/contrib/dev/iwlwifi/mvm/ops.c +++ b/sys/contrib/dev/iwlwifi/mvm/ops.c @@ -39,9 +39,8 @@ MODULE_DESCRIPTION(DRV_DESCRIPTION); MODULE_LICENSE("GPL"); #elif defined(__FreeBSD__) -#define DRV_DESCRIPTION "The new Intel(R) wireless AGN/AC/AX based driver for FreeBSD" +#define DRV_DESCRIPTION "The new Intel(R) wireless AGN/AC/AX Linux-based driver for FreeBSD" MODULE_DESCRIPTION(DRV_DESCRIPTION); -MODULE_LICENSE("BSD"); #endif MODULE_IMPORT_NS("IWLWIFI"); From nobody Fri Mar 6 02:51:46 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRrXL4n64z6SvPr for ; Fri, 06 Mar 2026 02:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRrXL1kzKz3n1q for ; Fri, 06 Mar 2026 02:51:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772765506; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AQyytWLkY3ByWG8EXBL+yqAw47oP1bbnY/RGMvf53vY=; b=uPjwKscnG6zImrmCFh5qAQ35WKHlYeskusSXOcjCbffD02wh+lxnsdD2jUfiWHs8ODqloX REhqC9XLa3mibrBQX0swD827u96eZZB3Eqgvdq0dLvCcW3hH23CZ8uXQ4zzMc+ST2w5N1q Gb1lwcVZsOXBIYoUWjM+ta2cLprUguVzsPbIgY+l0e4keUzpkGOBpiiTdBbBHtD3vPUz1g iYiV9enDMzDTN+pCvmhEX6BcQSIykiQtDMQpsLfx2vVHhzCfZZ0voFmv0XWAsPhszyU3jj jk6DDO63b2/Ps8GwRiEn4U0ZyEhdp66rZa46QGNMMlO/VEXc5kYcllFbcI8t3A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772765506; a=rsa-sha256; cv=none; b=BkGJsRaFJeJ5V/LZTGNTVYT3G+sPWClgkXcfYYzdUJMkMO0zYTxeZ7MvSrD2ihKV9J2oS+ I2ELK2H5/pVyvEaSpk+8m6BrYXL3kua+nBoTORIqeRL1MVqF76a+TBXTcdKJ7OBYB27mA/ IchmMyoRNSrM6e883HuAE7VGS3ERStPL8OcBpWpx2+WJ5aO9GPcM1KXjyfh9mFoEXVrK/t eSX2s904CQ6AIyRGo7FiuP7ZtRp5m0iGX4MXAm47TQXPop6SHB/KGkyFdPGUCX3BQphAVM 2Mxv5dQ9R1M1kLERlzQvtAp0hwzadqx9BZ98sL0DCZSVjGAT1ROg98vwscdUwA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772765506; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AQyytWLkY3ByWG8EXBL+yqAw47oP1bbnY/RGMvf53vY=; b=mHvXDJntHfEFVGWfCS9I2SWv/geSGSq+lzG++V4cKg93TF8CpB1Z09zQZkCj2rsOSEsncW oYFSsxRNmyEYWyqYdI5oxAcBRLza8OvMQhVeHFFnyYXmrK4iHLleJBFPPWW4uQpfPFwl07 wnRxyLk/cqlCr2bI603ZhyNx6irBaLT8INpQAIif8S5nV01WLz+uXKl8tatZ1sEZaTEOKM EPQIX1xC1dMshDYqzeEClSN0lqMp7PTFB4c8yCZkYeq7kePsF68f/+z9IhoDTpszkPaEI1 1pbYaoK9nDEibPvxuuia6rSHrD22TcKddyGJKwpQRxe1QGLnN5uzaStiVreFIA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRrXL1KGVz13wg for ; Fri, 06 Mar 2026 02:51:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 33e10 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 02:51:46 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 7db8503bda27 - main - iwlwifi: mld: add LINUXKPI_PARAM_PREFIX List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 7db8503bda2724ae145475c3260d581bb98613ad Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 02:51:46 +0000 Message-Id: <69aa4142.33e10.4b979ca0@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=7db8503bda2724ae145475c3260d581bb98613ad commit 7db8503bda2724ae145475c3260d581bb98613ad Author: Bjoern A. Zeeb AuthorDate: 2026-03-05 19:42:02 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-06 02:49:30 +0000 iwlwifi: mld: add LINUXKPI_PARAM_PREFIX Add a LINUXKPI_PARAM_PREFIX to mld to properly export the power_scheme module_param (sysctl). This is especially needed given mvm has the same parameter and we need to avoid a clash. Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/contrib/dev/iwlwifi/mld/mld.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/contrib/dev/iwlwifi/mld/mld.c b/sys/contrib/dev/iwlwifi/mld/mld.c index 3df9cabd34de..c2cabe855c01 100644 --- a/sys/contrib/dev/iwlwifi/mld/mld.c +++ b/sys/contrib/dev/iwlwifi/mld/mld.c @@ -2,6 +2,10 @@ /* * Copyright (C) 2024-2025 Intel Corporation */ +#if defined(__FreeBSD__) +#define LINUXKPI_PARAM_PREFIX iwlwifi_mld_ +#endif + #include #include From nobody Fri Mar 6 04:38:17 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRtvJ6FM8z6T4MX; Fri, 06 Mar 2026 04:38:20 +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 4fRtvJ3sP9z42Tq; Fri, 06 Mar 2026 04:38:20 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Authentication-Results: mx1.freebsd.org; none Received: from shw-obgw-4004b.ext.cloudfilter.net ([10.228.9.230]) by cmsmtp with ESMTPS id yL97v5785PzKyyMx9vMueF; Fri, 06 Mar 2026 04:38:19 +0000 Received: from spqr.komquats.com ([70.66.136.217]) by cmsmtp with ESMTPSA id yMx8vmdlPWCSlyMx8vgvpp; Fri, 06 Mar 2026 04:38:19 +0000 X-Auth-User: cschuber X-Authority-Analysis: v=2.4 cv=O7Y0fR9W c=1 sm=1 tr=0 ts=69aa5a3b a=h7br+8Ma+Xn9xscxy5znUg==:117 a=h7br+8Ma+Xn9xscxy5znUg==:17 a=kj9zAlcOel0A:10 a=Yq5XynenixoA:10 a=6I5d2MoRAAAA:8 a=EkcXrb_YAAAA:8 a=YxBL1-UpAAAA:8 a=_aXhMRKL7ny7GWJLJKwA: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 C45B42AF; Thu, 05 Mar 2026 20:38:17 -0800 (PST) Received: by slippy.cwsent.com (Postfix, from userid 1000) id BCA8F393; Thu, 05 Mar 2026 20:38:17 -0800 (PST) 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: "Bjoern A. Zeeb" cc: John Baldwin , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 54bf594851f6 - main - libc/quad: Switch to per-arch lists of symbols In-reply-to: References: <69a9d47b.1928a.7f6e7682@gitrepo.freebsd.org> Comments: In-reply-to "Bjoern A. Zeeb" message dated "Thu, 05 Mar 2026 21:39:16 +0000." List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 05 Mar 2026 20:38:17 -0800 Message-Id: <20260306043817.BCA8F393@slippy.cwsent.com> X-CMAE-Envelope: MS4xfL8GMN62pw/ktmY3D/5KUaxSD3+NVu2sY5/UAhLlLTwW0JSL2mSijVySAMefUbLoiQz0saVYArxxhvitlB9O63vmZShrb3NC3LocsRq8zYyNV6ee6cxw NnBwySHCihdX8V2FBalezy7H0pSh6xt2w19W3GK7lN2e1bjGYyA05xuKwzjb6KO8erOLpdzFCdY3mBNvKCdMCrwlyd/YGU0j4BYfRhlALEzgpxhcdkSievjy Clf+j6hchYvUwh+K7hQJnwozCynUYlVFgAQ8ZozCUbEpsb1ujTf19WWyGicfVQNGtJWbjUD11BOHd90KZx/PYg4XB1RtyGF1wAQcrX0HUrTZG6SeJVIcLON1 dfFTRQPI X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:16509, ipnet:3.96.0.0/15, country:US] X-Rspamd-Queue-Id: 4fRtvJ3sP9z42Tq X-Spamd-Bar: ---- In message , "Bjoern A. Zeeb " writes: > On Thu, 5 Mar 2026, John Baldwin wrote: > > > The branch main has been updated by jhb: > > > > URL: https://cgit.FreeBSD.org/src/commit/?id=54bf594851f671e231d2786cdacaf6 > 8f290ff738 > > > > commit 54bf594851f671e231d2786cdacaf68f290ff738 > > Author: John Baldwin > > AuthorDate: 2026-03-05 19:07:09 +0000 > > Commit: John Baldwin > > CommitDate: 2026-03-05 19:07:09 +0000 > > > > libc/quad: Switch to per-arch lists of symbols > > > > This more closely mirrors libc/quad/Makefile.inc and is easier to > > read. > > > > Reviewed by: brooks > > Differential Revision: https://reviews.freebsd.org/D55658 > > --- > > lib/libc/quad/Symbol.map | 43 +++++++++++++++++++------------------------ > > 1 file changed, 19 insertions(+), 24 deletions(-) > > I find this in an i386 buildworld (from universe): > > 4135 ===> lib/libc (obj,all,install) > 4136 :1336:2: error: unterminated conditional directive > 4137 1336 | #ifdef __i386__ > 4138 | ^ > 4139 1 error generated. > > I assume it's from this? > > Yes, seems there is an #endif missing. This explains my build issues. First, my krb5 and kerberos5 builds failed to build the 32-bit libraries. Removing --no-undefined in krb5, kerberos5 and libcom_err, got the build past the krb5/kerberos5 32-bit library builds, failing to build usr.bin/ldd32 with the same error. This results in a corrupted 32-bit libc.so. > > -- > Bjoern A. Zeeb r15:7 > -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org e**(i*pi)+1=0 From nobody Fri Mar 6 08:24:18 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fRzw23HCbz6TNfc for ; Fri, 06 Mar 2026 08:24: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fRzw22cdrz3L9D for ; Fri, 06 Mar 2026 08:24:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772785458; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=DvF5oLRx76LNGf2/RFD+N+cex1R/Osgj2CZIc6ZPb3E=; b=He/BOK2cH28uq4zm+nSO47kDV/SeHCqwqB3AvOPKwypapKWt2qnr7q3ezCpUc6vHKgfZhV kRG8j+1p7llDtJiEDS7U9oMjR/nDm9Lf3FnshWSKNoNBYK23HwxAxMLBA7k8Y2VIcqTSy5 IE7N2rd414C7DzV76By2ztnCW9ablh6Y6BAA44TpmCTrjQuwOtly7xGxqGUZKdPovnUKeU fi8fy1s9SOen7xVHGL8FGngGgP+i7ReCwip6R5KgE6aUwRLC68X5OrP0ZZEgaFcxmQRQsj bTs4ALowWgUYb8pHMX4QXrGnhnSnvCm4TK+3jZA7A+igeRn0AG9ySCqsef53IQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772785458; a=rsa-sha256; cv=none; b=VKDn9OgvP42fH9FAHxY3VPE3TG1mC5kmN9huKleG60kZW/qqMy8lA6xmWedK0XXnB15umA CZS2XaKgO0qxZbc3vmJscoEjPxUGXFfD1ITCPeb+iupZwOcEQzCmeHs/oGwM410H8MNG8m AFgxmxGSg3Z2zqrO4zUbgL6fm9QdS4wlISgwvb3n2WfglZFY0GgLGdchQtju5hnIzBNgzT mqIX9TQWoGKHr85YVfswGCAwHDKZtaapnPUhUSdpqQhdxZbePzpNFbII+taRcHlEXQ/L+n rgET8z9boMA+WusN2cvgb51Rhmg5Q/KGB+GjjQEX2BizhLa9mWS9/CGXtbsoIw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772785458; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=DvF5oLRx76LNGf2/RFD+N+cex1R/Osgj2CZIc6ZPb3E=; b=OJHzaEYTt2gDC80gLAlFMGt9MMASeIFZ3qaG21n5YpzP5e4WWLeZsJZQw0jmV9q/AaTnZl yefrMiNORuEutoHaZz7Kc4OBc5N7MBwRi45en+cYJUxr4E/1nVtZDLcgCY7HhzF76Q6tFR GFuLCi+BYaN4AUCVHKQ9OWgDcowo6Rcjawwv21Wmn2vh/OF1sHEcC/Q4D5w7AiKj0toGqJ lxrZGLRR25mdrmnUAPWQUQS6nlYGsFoxbVg0tmFA10/BQSUnARSvQl3ZYZK2weuBFJ38Gu rHrecFZjo2n99mSP7fro9dowc9/0kUi74JN3CCYEr9QrjNngI3RM+Gsd3eQtpQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fRzw222jXzGV for ; Fri, 06 Mar 2026 08:24:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 26f39 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 08:24:18 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Xin LI Subject: git: 8dd28e13e41b - main - libc/quad: fix missing closing #endif in Symbol.map List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: delphij X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8dd28e13e41b6200e58d6e99981ff8323cff3711 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 08:24:18 +0000 Message-Id: <69aa8f32.26f39.6c45e3d3@gitrepo.freebsd.org> The branch main has been updated by delphij: URL: https://cgit.FreeBSD.org/src/commit/?id=8dd28e13e41b6200e58d6e99981ff8323cff3711 commit 8dd28e13e41b6200e58d6e99981ff8323cff3711 Author: Xin LI AuthorDate: 2026-03-06 08:22:06 +0000 Commit: Xin LI CommitDate: 2026-03-06 08:22:06 +0000 libc/quad: fix missing closing #endif in Symbol.map Without this lib32 libc.so.7 would be missing critical symbols, including malloc / free and all syscall wrappers. --- lib/libc/quad/Symbol.map | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/libc/quad/Symbol.map b/lib/libc/quad/Symbol.map index c28f9a180704..251814cb238f 100644 --- a/lib/libc/quad/Symbol.map +++ b/lib/libc/quad/Symbol.map @@ -50,4 +50,5 @@ FBSD_1.0 { __udivdi3; __umoddi3; __xordi3; +#endif }; From nobody Fri Mar 6 09:04:20 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fS0pD5qK5z6TRmT for ; Fri, 06 Mar 2026 09: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fS0pD4tZnz3NWj for ; Fri, 06 Mar 2026 09:04:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772787860; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=R/sUJh+xnMfLtcqU/Cfwy6j/ku6d8yIh69a6fssw76Y=; b=i58wrSJwwonKx4gXZL/7ktmU2lwvKF1UGbLcXOoZgTBxj9yZT2RALraXq+f8+2kVT8rMn5 EJYtMjW9Z78X7yWvROT4Ivm5gCmhU45CX2vrrMvRMMSKK/jyfOLdooYzY0EFPAVvyHYsvw hUcnICjo0qXbHivJ4b+VMWDP9Rc5OpA9TghKokgTpPiTEttEhFxeNSF708AldtrzQlOXTo 6WWOCnds0nkLrt0e8LZVctcVu2lWJGqueq8c6HrF1M58lMzKUHcNkwEuE9rEatkHM1D3cZ NYV199Dh1in6q9h+1o+qBREQmgwvrkf8RyxHMqN7C2XBK1jABsWIHh+26wxk/A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772787860; a=rsa-sha256; cv=none; b=i/48l1hvrrrWq3AUw2DnLqkuQACp69nvlJCvm4ZKW618fMAXx+5Tf4aqZ0p5SGAmgKkq2J +hvSZ/ARF/0nfJL6gGm9/9LwnpzN9GagDF6mb7v5cuX4hHmQPbEgQu00u4H0MGR9uVAsah ceOHNZtziQy/2RsEliWeFuPMWXpM2sXgO5/i+vmcunDiOQC9knPVvTqwb2RA+PZmt4EQF5 25oNEvyfgkg2H3SeJafB4iKVNruNhEtiOlHLFCrwPXjrjR3vMehCkggV8m+qCcHx0EK0T1 2qI7L953nVHI3gKY8Si4+Ivz+trwi4JR32uldnoepZzCP7tl7xKFjkinBmIy0g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772787860; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=R/sUJh+xnMfLtcqU/Cfwy6j/ku6d8yIh69a6fssw76Y=; b=O+N7GEo7bdFmRUib3OLPzuweIYur+nvX7tpx6+AKohztg1MW20q0yxrsXkNrrGRAH8jBMV OPavUppCm2Tl5xYePdhOEMkru/1wl2EecJw2wc8JU/jhwZshn/0okssH75gTZOnAjTMt5+ Vs1hHyW8h+erz2UlKIMKs3n0gZ0ZwHm6/usAsEL4+ankVMdOjcvYzd9bz+W5iAKMpfI+Yy iGQpkIyzhPG50FEWP/3ZkbeuvNTUXULomcfQVu8fs6Xyn6Q4C52NRxYlDedJAz9lTulcWs 4nVtM4Mqzvrr3Vh8iDX+vnLk9xRogKsLpHD9ZZKrsEMIbZUusaC/mbYAXXPLGA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fS0pD4Tg3z1HJ for ; Fri, 06 Mar 2026 09:04:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3290a by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 09:04:20 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Peter Holm Subject: git: 05cbd5fc2b48 - main - stress2: Added a new test scenario List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 05cbd5fc2b481d6503c69be95fe9a6d9a287bc6d Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 09:04:20 +0000 Message-Id: <69aa9894.3290a.a8e8791@gitrepo.freebsd.org> The branch main has been updated by pho: URL: https://cgit.FreeBSD.org/src/commit/?id=05cbd5fc2b481d6503c69be95fe9a6d9a287bc6d commit 05cbd5fc2b481d6503c69be95fe9a6d9a287bc6d Author: Peter Holm AuthorDate: 2026-03-06 09:03:11 +0000 Commit: Peter Holm CommitDate: 2026-03-06 09:03:11 +0000 stress2: Added a new test scenario --- tools/test/stress2/misc/renameat2.sh | 116 +++++++++++++++++++++++++++++++++++ 1 file changed, 116 insertions(+) diff --git a/tools/test/stress2/misc/renameat2.sh b/tools/test/stress2/misc/renameat2.sh new file mode 100755 index 000000000000..8e75fabb321b --- /dev/null +++ b/tools/test/stress2/misc/renameat2.sh @@ -0,0 +1,116 @@ +#!/bin/sh + +# +# Copyright (c) 2026 Peter Holm +# +# SPDX-License-Identifier: BSD-2-Clause +# + +# Simple renameat2 test scenario + +[ `id -u ` -ne 0 ] && echo "Must be root!" && exit 1 + +. ../default.cfg +err=0 +prog=$(basename "$0" .sh) + +cat > /tmp/$prog.c < +#include +#include +#include +#include +#include + +int +main(void) +{ + int fd; + char *f1 = "f1"; + char *f2 = "f2"; + char *t1 = "t1"; + + if ((fd = open(f1, O_RDWR | O_CREAT, DEFFILEMODE)) == -1) + err(1, "open(%s)", f1); + close(fd); + if ((fd = open(f2, O_RDWR | O_CREAT, DEFFILEMODE)) == -1) + err(1, "open(%s)", f2); + close(fd); + + if (renameat2(AT_FDCWD, f1, AT_FDCWD, t1, AT_RENAME_NOREPLACE) == -1) + err(1, "renameat2(%s, %s)", f1, t1); + if (renameat2(AT_FDCWD, f2, AT_FDCWD, t1, AT_RENAME_NOREPLACE) == 0) + errx(1, "renameat2(%s, %s)", f2, t1); + if (errno != EEXIST && errno != EOPNOTSUPP) + err(1, "renameat2(%s, %s)", f2, t1); + if (unlink(f2) != 0) + err(1, "unlink(%s)", f2); + if (unlink(t1) != 0) + err(1, "unlink(%s)", t1); +} +EOF +cc -o /tmp/$prog -Wall -Wextra -O0 /tmp/$prog.c || exit 1 + +echo ufs +set -eu +mount | grep -q "on $mntpoint " && umount -f $mntpoint +mdconfig -l | grep -q md$mdstart && mdconfig -d -u $mdstart +mdconfig -s 1g -u $mdstart +newfs $newfs_flags /dev/md$mdstart > /dev/null +mount /dev/md$mdstart $mntpoint +set +e + +cd $mntpoint +/tmp/$prog || err=$((err+1)) +cd - +umount $mntpoint +mdconfig -d -u $mdstart + +echo tmpfs +mount -t tmpfs dummy $mntpoint +cd $mntpoint +/tmp/$prog || err=$((err+1)) +cd - +umount $mntpoint + +echo msdosfs +if [ -x /sbin/mount_msdosfs ]; then + mdconfig -a -t swap -s 1g -u $mdstart + gpart create -s bsd md$mdstart > /dev/null + gpart add -t freebsd-ufs md$mdstart > /dev/null + part=a + newfs_msdos -F 16 -b 8192 /dev/md${mdstart}$part > /dev/null 2>&1 + mount_msdosfs -m 777 /dev/md${mdstart}$part $mntpoint + + cd $mntpoint + /tmp/$prog || err=$((err+1)) + cd - + umount $mntpoint +fi +echo zfs +u1=$mdstart +u2=$((u1 + 1)) + +mdconfig -l | grep -q md$u1 && mdconfig -d -u $u1 +mdconfig -l | grep -q md$u2 && mdconfig -d -u $u2 + +mdconfig -s 1g -u $u1 +mdconfig -s 1g -u $u2 + +zpool list | egrep -q "^stress2_tank" && zpool destroy stress2_tank +[ -d /stress2_tank ] && rm -rf /stress2_tank +zpool create stress2_tank raidz md$u1 md$u2 +zfs create stress2_tank/test + +cd /stress2_tank/test +/tmp/$prog || err=$((err+1)) +cd - + +zfs umount stress2_tank/test +zfs destroy -r stress2_tank +zpool destroy stress2_tank +mdconfig -d -u $u1 +mdconfig -d -u $u2 + +rm -f /tmp/$prog /tmp/$prog.c +exit $err From nobody Fri Mar 6 09:04:21 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fS0pF6TKjz6TRL2 for ; Fri, 06 Mar 2026 09:04: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fS0pF5j4Tz3NWk for ; Fri, 06 Mar 2026 09:04:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772787861; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NK0Sm2t81VB+XowckLxRGL4PUxtj7xS6bmYod8xLTq0=; b=jEwsV9mWzlty+NtibAfh1cNCkG2LNh0WHDciZxhtZPQegTZ19yuAgzIUZjOxXIk87cKojS TYfms/oAqLRebtMI2583IS8Mpn7AMhHAJrhdHa6HWjiThDVyP2IUGrfD525iMcJMIXq0j5 jITRB/lRUsVT02USwiRcxiAucNE+Y7TlPwp2oKBvQjYXYq8RNLF5C0r34FiX3V+EDZYB9j nLpLLUHQzph56DO86pDno11XM5oeCK/a9DPHrznzx9UTH/DZ6gtQ6v3XZzIldAIDudB+o6 rH17hAW8RZ8PmCeMHSbqzGYQiEI+wcvww/9sc1URmjU8XNwC2yP6zGj6TXzQWA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772787861; a=rsa-sha256; cv=none; b=WUnUC13pE4e2nVRcapZq7z2ZW8Wq1lGxatMt78YYLlakE2M4t+U5UR4+9zCzL5uQTVvbVt elVyzP9vAK3n9iMH0BqVVhIT6FfCgkYfhoP6uwIwW86qBtLcxd3uy4QcKQg0mD4UJO85mw EQv+S4UNt5jTI2UKB+4UIGHgM9Hy0YY0Qzr06bTKUa9copxPOlJUj2LLuwjdbRo0lgFaL6 dYaI/rTntXYNy45UuhKaZPudLzNQMX9dk7HYxoEwgcL3TFoepscd6sAwmzucK0Hll8ekLY Rj//006EqDOA1piDLp+QOVLsqSpKZ95DGNBUfV8xz1+41jNX1163Eagmq3X/gQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772787861; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NK0Sm2t81VB+XowckLxRGL4PUxtj7xS6bmYod8xLTq0=; b=NtsxETp0Z/UGVmUdFrcn3fl4X6RPLgfjxPSzQqiTid6WK7SVgBMhsFPhyrN8HGEaNPKikt DEkOK24H6Vxh2UTDC+hJlfAuM0+q1l4K+YYKteawoo9ZcW2czgNp+hBIcfet7ya4FrxQS1 GUMk8xW0SKuHrgGJPw+JR4R0uYDsPYUOF+SOF68hw4PsGR0nvZ9JJPDsNO/7TArq5a3A53 8qGUohRa39hsLq2pXgekRmJUDynpjOcopksa1u3CO6y5NzjjExVcCBTwvj2krDahQCPDfD E1Lm894TUEnNuV9Q1QNDBZLQSPNCArDHeLCXQ/u7Y09czm7h4ez7KbNIKXMjhQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fS0pF5Cjpz1km for ; Fri, 06 Mar 2026 09:04:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 316c8 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 09:04:21 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Peter Holm Subject: git: b15dc3ff28db - main - stress2: Updated comments List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: b15dc3ff28dbb2c3f8eec51803dbca7569439773 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 09:04:21 +0000 Message-Id: <69aa9895.316c8.40ca6408@gitrepo.freebsd.org> The branch main has been updated by pho: URL: https://cgit.FreeBSD.org/src/commit/?id=b15dc3ff28dbb2c3f8eec51803dbca7569439773 commit b15dc3ff28dbb2c3f8eec51803dbca7569439773 Author: Peter Holm AuthorDate: 2026-03-06 09:03:53 +0000 Commit: Peter Holm CommitDate: 2026-03-06 09:03:53 +0000 stress2: Updated comments --- tools/test/stress2/misc/mmap41.sh | 3 ++- tools/test/stress2/misc/mmap45.sh | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/test/stress2/misc/mmap41.sh b/tools/test/stress2/misc/mmap41.sh index 5051681aaf31..a279604cd5b6 100755 --- a/tools/test/stress2/misc/mmap41.sh +++ b/tools/test/stress2/misc/mmap41.sh @@ -7,7 +7,8 @@ # # Based on code from https://syzkaller.appspot.com/text?tag=ReproC&x=15d9baada80000 -# No problems seen +# "panic: Bad tailq NEXT" seen: +# https://people.freebsd.org/~pho/stress/log/log0569.txt . ../default.cfg diff --git a/tools/test/stress2/misc/mmap45.sh b/tools/test/stress2/misc/mmap45.sh index 59450b41bb5e..549d1ea6f190 100755 --- a/tools/test/stress2/misc/mmap45.sh +++ b/tools/test/stress2/misc/mmap45.sh @@ -8,9 +8,10 @@ # Demonstrate issue described in: # [Bug 276002] nfscl: data corruption using both copy_file_range and mmap'd I/O +# Unfixed as of 20260306 # Issue seen: -# +# # 8994c8994 # < 0431020 10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f # --- From nobody Fri Mar 6 12:14:02 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fS51B0V2Qz6Th7s; Fri, 06 Mar 2026 12:14:06 +0000 (UTC) (envelope-from bzeeb-lists@lists.zabbadoz.net) Received: from mx-01.divo.sbone.de (legacy1.sbone.de [80.151.10.34]) (using TLSv1.3 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 "E7" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fS5195GF3z3gQJ; Fri, 06 Mar 2026 12:14:05 +0000 (UTC) (envelope-from bzeeb-lists@lists.zabbadoz.net) Authentication-Results: mx1.freebsd.org; none 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 088CFA64805; Fri, 06 Mar 2026 12:13:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=zabbadoz.net; s=20240622; t=1772799224; bh=//4+o2GG0Jb+vufZ+m01Iqtk5Yigt4pxiuo7+wvegbE=; h=Date:From:To:cc:Subject:In-Reply-To:References; b=hpL7fgEUjQynGABH2uD2VhyWajlqavftfB+RYDroy36TTZnSU203i5odB0OGRYTjJ J8tRwSRqjmdj/KiPQ/sDKUC8uJoN4fXbpRNN49agtWTx7Wl6DtcOuz4LFpfaBaXd2f s9T7u7G8IgTa/tX5uEH+wQh1aX/kFiA8yeqF6oLkRfcCzZOfPr6ZncRTdyFCmE6TTF zI5krDiBczXyIfdwy34s74oa1K1YZxI/HY+h49TY6wU/dynjbnyvGHYaslHpFkTKvf XdMUiaeqWDwlyCLQQhXbNVrzL8C1YMO4xn0WteI4IxXvDZWUe7PBFNnAbnjSEb9kYk WFlQc2zE5trQQ+OiXjI8aFPcLdPwSLevNgC/DF7PRsDdwLXJAvcqRY3DsUjth4EgGf XxA7hz0yo1Y4EJajGqVRs8PPQ/vbsC8iQv0NVNBgf+nuEdvIMWMlORNq3FlD5rn+AK kXTYxhdhpZzatqFmlDpBRz5i4/UC816V+2pXvGAx0a83ecD/MI4rcmvz7JK8WHLm7b KkOPsJtqfLicdh3eQikD+aVddZVQcQTbA4/QJrNUzWp5exLgup3QpPisIepC7pyMIi 6tnGNc5EAPIJEU/P7hBaJkW9fY+fsaff6j9AXZTMM7cRw1MyOxsXQ6h3PaYoPlfhsA fxgJoDxCKErBYIeDywJJTIqE= 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 3C89B2D029E7; Fri, 6 Mar 2026 12:14:03 +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 BT53xIaeltBI; Fri, 6 Mar 2026 12:14:02 +0000 (UTC) Received: from nv.t4-02.sbone.de (nv.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:22]) (using 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 4FA9F2D029D8; Fri, 6 Mar 2026 12:14:02 +0000 (UTC) Date: Fri, 6 Mar 2026 12:14:02 +0000 (UTC) From: "Bjoern A. Zeeb" To: Pouria Mousavizadeh Tehrani cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 0616521adc35 - main - ndp: Simplify and breakdown nd6_ra_input() In-Reply-To: <69a9c9f7.44455.6ac74e64@gitrepo.freebsd.org> Message-ID: <675310r6-oro4-119r-3s47-64opr41ro853@mnoonqbm.arg> References: <69a9c9f7.44455.6ac74e64@gitrepo.freebsd.org> X-OpenPGP-Key-Id: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset=US-ASCII X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:3320, ipnet:80.144.0.0/13, country:DE] X-Rspamd-Queue-Id: 4fS5195GF3z3gQJ X-Spamd-Bar: ---- On Thu, 5 Mar 2026, Pouria Mousavizadeh Tehrani wrote: > The branch main has been updated by pouria: > > URL: https://cgit.FreeBSD.org/src/commit/?id=0616521adc35cb252cb399f1147f103284f0f188 > > commit 0616521adc35cb252cb399f1147f103284f0f188 > Author: Pouria Mousavizadeh Tehrani > AuthorDate: 2026-03-05 18:01:30 +0000 > Commit: Pouria Mousavizadeh Tehrani > CommitDate: 2026-03-05 18:04:32 +0000 > > ndp: Simplify and breakdown nd6_ra_input() > > `nd6_ra_input()` is simplied to make it easier to add > additional options. > > Reviewed by: glebius > Differential Revision: https://reviews.freebsd.org/D55267 > --- > sys/netinet6/nd6.c | 8 +- > sys/netinet6/nd6_rtr.c | 300 +++++++++++++++++++++++++------------------------ > 2 files changed, 158 insertions(+), 150 deletions(-) I am not sure which change (this or GRAND) triggers it but this is new: Invoking IPv6 network device address event may sleep with 1 sleep inhibitors stack backtrace: #0 0xffffffff80c2e36c at witness_debugger+0x6c #1 0xffffffff80c2fc79 at witness_warn+0x4c9 #2 0xffffffff80df7a57 at in6_update_ifa+0xc67 #3 0xffffffff80e24f1f at in6_ifadd+0x30f #4 0xffffffff80e214d6 at nd6_ra_input+0x1066 #5 0xffffffff80df1520 at icmp6_input+0x5b0 #6 0xffffffff80e0be35 at ip6_input+0xbb5 #7 0xffffffff80d219a4 at netisr_dispatch_src+0xb4 #8 0xffffffff80d0376a at ether_demux+0x16a #9 0xffffffff80d04cde at ether_nh_input+0x3ce #10 0xffffffff80d219a4 at netisr_dispatch_src+0xb4 #11 0xffffffff80d03bb5 at ether_input+0xd5 #12 0xffffffff80d53d12 at ieee80211_vap_deliver_data+0x32 #13 0xffffffff80d87cbd at sta_input+0xc6d #14 0xffffffff80d6132c at ieee80211_input_mimo+0x20c #15 0xffffffff82f0f155 at lkpi_80211_lhw_rxq_task+0x135 #16 0xffffffff80c20042 at taskqueue_run_locked+0x1c2 #17 0xffffffff80c20f33 at taskqueue_thread_loop+0xd3 -- Bjoern A. Zeeb r15:7 From nobody Fri Mar 6 12:27:10 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fS5JG2bPJz6TjTB for ; Fri, 06 Mar 2026 12:27: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fS5JG20N8z3hLC for ; Fri, 06 Mar 2026 12:27:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772800030; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jjOPBdg5ibBPEJb8Mc5Ht6AiUm8A4kYtIyWMDiDreZY=; b=xbjOA9lgz3BMRes+2woqEcHWJlwoYJlHKDx3tvXVciesMzqpzzXDV530JSHQGQVCulGjNq NZRB8v+twkXJM06jf3IaLdCW2sbqeY2xTbRjiyY0nlJAQWN2CjcJt4DfxUH8sJArX0GVHD mWx14WuUZbxUJaFef9EL+pQe14sFPNA13Cft3Ei8mXAMr7CNTUL49cuAjV3nSm+QTzCCxD amtCwSNhmn640LFrEZP7O18vyzVl6FJzI5iGtLPo8FO+EXK0soAiQQtTcscBr2l17oGP9Y rRzHthfcZOJ5kCbXUZoe2igvoB2lMuU7rTRx10GQloxdrFwIf4V7iukxLDwgQQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772800030; a=rsa-sha256; cv=none; b=gR3JQnead7Jt1XFMo2NRJFfBn7HggejgKmVoKlztoJ2YnYj62hW30ko8qIlc6hT2oBAfIt VAyLKN2Z4dOB4OtfTCz7srmiMBxAp3ark8Anrs8n7qlhh3+BuS5AnEP8GtCWythUErgXTN aEiIAe2GvUiNDj+dvhWOq9DcXix5yszij0X6RFG36UiB0vX9YkOjMySbXm2/bEkVvMxOvm o2r2pWI8TqqhI0JzKDQo+R6HayI4r3ip5oAbo/q09Ezd16BvGHtst90T/wLyED+4cj+YQk waFvzuI9OcMp6k0jXOgePjxQb6PoIaQqXuHBJMOlfgER0MVDS5c0noMJl0PWdQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772800030; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jjOPBdg5ibBPEJb8Mc5Ht6AiUm8A4kYtIyWMDiDreZY=; b=wbKjD0KfEmA50h+udm2OtuiejzVlZ3S+5PiULgU3lhvUEMbQ8FUJeuUdWAEUp7H78mf+hm 6ofXwIWC2mDEbgbjCsdZJsrWPvvIwzExynelisvRMQVsjXvsAVwTiD7O1iEGaGzoBclgl7 HG6gcsgQoihAHxbn5rrpsmeE55yjXZajLveHkWXdluc0flgRx/SQIuTw81ytJS2aBQIlV3 lA0K3quuxa49rSXa6e9o3O9RhDw5Ggv/yHOVlW/YiE5aR1C/K7UoMTcGgGm5RH88u79pFi H4IkTNrlesJ8mOzG46rq6H4IMmqdofYePJollo6bxCqaX3st1MokcZ1TtkexBw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fS5JG1Y5cz6wW for ; Fri, 06 Mar 2026 12:27:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 45ee3 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 12:27:10 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: e85f221def71 - main - rc: virtual_oss: Silence potential hw.snd.default_unit error List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: e85f221def717660c9daf4c0616dfb9cdfb75827 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 12:27:10 +0000 Message-Id: <69aac81e.45ee3.57365b0@gitrepo.freebsd.org> The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=e85f221def717660c9daf4c0616dfb9cdfb75827 commit e85f221def717660c9daf4c0616dfb9cdfb75827 Author: Christos Margiolis AuthorDate: 2026-03-06 12:27:03 +0000 Commit: Christos Margiolis CommitDate: 2026-03-06 12:27:03 +0000 rc: virtual_oss: Silence potential hw.snd.default_unit error PR: 293582 Sponsored by: The FreeBSD Foundation MFC after: 1 week --- libexec/rc/rc.d/virtual_oss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libexec/rc/rc.d/virtual_oss b/libexec/rc/rc.d/virtual_oss index 42353a6c1520..d55b51463442 100644 --- a/libexec/rc/rc.d/virtual_oss +++ b/libexec/rc/rc.d/virtual_oss @@ -24,7 +24,7 @@ required_modules="cuse" configs= pidpath="/var/run/${name}" -default_unit=$(sysctl -n hw.snd.default_unit) +default_unit=$(sysctl -n hw.snd.default_unit 2> /dev/null) virtual_oss_default_args="\ -S \ -C 2 \ From nobody Fri Mar 6 12:30:59 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fS5PR0L40z6TjMl; Fri, 06 Mar 2026 12:31:39 +0000 (UTC) (envelope-from pouria@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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fS5PQ6b5pz3jpZ; Fri, 06 Mar 2026 12:31:38 +0000 (UTC) (envelope-from pouria@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772800298; 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=1+jLPtMQLPeHrE/5czNhV0yM8reqylHDDlXiCV/FKNs=; b=O+BCM0JLcVynQo9pOGb209JlABAvm7PnbA7fPpHXxuduNC6lkc3ZMOYVp+zdWZsJnQDVMn to3GqcNmO8xP5g8JaSuCZT1fEz5KOnSP5NeBhH4dP23q2y+h/NTLyzD3i4fsuBBxlufai8 QhE3x98ReXwtKgYZNBd203GtuIGn2gDR7r5ySWckvXwCfkfS92rbT95ak+nCeIwQq3kWbA Lk0/STuBFZSWkbDgal7p4dgXnSmNVUQXXhtmH4de4l2VN688+2Hu+6dHHnvAheT//br8Qb IyqxqFASTGZt/7/atfF9cPkbiCNdg0mP386Ff8VHCmfSNpM+Osd18vJ5mnUZ1w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772800298; a=rsa-sha256; cv=none; b=AjVa1rbMzp2LrzI1VxH8GG7rd61Cq4TdVrCFreNUyMgK/mjwm7cfwN5N1wBZaKlRLsLyZI ztNU4OPnMU3bAsV4tmSPXC5b2MVL4d3vwxVXWWusA38IaNkKt5wc9YjDY4xtTh6xsQ0ugc KbkktyeaLuT+uAje930BIUvtf6Lj+L1QN55BB83GGOtzTXn6p+41IJF0tLszuHIoh2DauI YmTj2oo/Jd0yT450DWb1aWEc4GmqYn7yAE/49cujmWV9TGfOjbNon4i63+NuhED/rVvAQ3 mToE0SgougfO53J/5tPCpR9DGr2rLhnS8/4hl7Q7DP853ciaDZR65n3tjX7maA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772800298; 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=1+jLPtMQLPeHrE/5czNhV0yM8reqylHDDlXiCV/FKNs=; b=D9eiKpBw373A5fGaZSq7MgR7bIb+ZxsHHAYZYnrcEqTKRCnd76dmMHyfEI15wNQW8VngbG N5iA8pGNBZzIoIvZ9FbEBVZhdqmHKRjSyxQ6WJAMGmaYzxdbtg7juPjOnSGdFz3/w9ein5 u2Q/tNPksULwpTtLKE01W+xPFY7+uWdI48H08g0OLvKKvjT1Y2LZId2dv4t37PTXkOmxjS H2cgZIXVfS4wkls2sRKBr1TrFN5dVR2ge0kaSPrr6I/+bJZq6JiAjYVVjFGqIEuavolnSU uiyvGMIb7+MP5iHWTaTdG5DTVvRRa3adf8S8Ds6O0mj2CHOnebjYmHZhQsaizw== Received: from nl.mail.spmzt.net (unknown [IPv6:2a01:e140:12:1::25]) (using TLSv1.3 with cipher TLS_AES_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: pouria) by smtp.freebsd.org (Postfix) with ESMTPSA id 4fS5PQ2WQQzwj1; Fri, 06 Mar 2026 12:31:38 +0000 (UTC) (envelope-from pouria@FreeBSD.org) Received: by nl.mail.spmzt.net (OpenSMTPD) with ESMTPSA id 576b072a (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Fri, 6 Mar 2026 16:01:22 +0330 (+0330) Message-ID: <81986377-51a0-457d-8665-2ca739170986@FreeBSD.org> Date: Fri, 6 Mar 2026 16:00:59 +0330 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: 0616521adc35 - main - ndp: Simplify and breakdown nd6_ra_input() To: "Bjoern A. Zeeb" References: <69a9c9f7.44455.6ac74e64@gitrepo.freebsd.org> <675310r6-oro4-119r-3s47-64opr41ro853@mnoonqbm.arg> Content-Language: en-US, fa-IR Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Pouria Mousavizadeh Tehrani In-Reply-To: <675310r6-oro4-119r-3s47-64opr41ro853@mnoonqbm.arg> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="------------rmPwUe9RYSCxp049ZgOrJYN3" This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --------------rmPwUe9RYSCxp049ZgOrJYN3 Content-Type: multipart/mixed; boundary="------------khl1g8jg48Ihb56704Ks81xv"; protected-headers="v1" Message-ID: <81986377-51a0-457d-8665-2ca739170986@FreeBSD.org> Date: Fri, 6 Mar 2026 16:00:59 +0330 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: 0616521adc35 - main - ndp: Simplify and breakdown nd6_ra_input() To: "Bjoern A. Zeeb" References: <69a9c9f7.44455.6ac74e64@gitrepo.freebsd.org> <675310r6-oro4-119r-3s47-64opr41ro853@mnoonqbm.arg> Content-Language: en-US, fa-IR Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Pouria Mousavizadeh Tehrani In-Reply-To: <675310r6-oro4-119r-3s47-64opr41ro853@mnoonqbm.arg> --------------khl1g8jg48Ihb56704Ks81xv Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: base64 SGksDQoNClRoaXMgaXMgcHJvYmFibHkgYmVjYXVzZSBvZiBEQUQuDQpQbGVhc2Ugc2VlIHN5 cy9uZXRpbmV0Ni9uZDZfbmJyLmM6MTI1Mg0KV2h5IG5vdz8NCkJlY2F1c2UgNmZlYjE2Yjc3 ZTdkZjQ3MGM2MzViYzNhZjY1ZDQ0OGZkMzdkZWIxMCB3YXMgY29tbWl0dGVkIA0KaW1tZWRp YXRlbHkgYWZ0ZXIgbXkgY29tbWl0Lg0KSSBzcG9rZSB3aXRoIEdsZWIgbGFzdCBuaWdodCBh bmQgd2UncmUgYXdhcmUgb2YgaXQuDQpTbyBGWUksIEknbSB3b3JraW5nIG9uIERBRCB0b28u DQoNCk9uIDMvNi8yNiAzOjQ0IFBNLCBCam9lcm4gQS4gWmVlYiB3cm90ZToNCj4gT24gVGh1 LCA1IE1hciAyMDI2LCBQb3VyaWEgTW91c2F2aXphZGVoIFRlaHJhbmkgd3JvdGU6DQo+IA0K Pj4gVGhlIGJyYW5jaCBtYWluIGhhcyBiZWVuIHVwZGF0ZWQgYnkgcG91cmlhOg0KPj4NCj4+ IFVSTDogaHR0cHM6Ly9jZ2l0LkZyZWVCU0Qub3JnL3NyYy9jb21taXQvPyANCj4+IGlkPTA2 MTY1MjFhZGMzNWNiMjUyY2IzOTlmMTE0N2YxMDMyODRmMGYxODgNCj4+DQo+PiBjb21taXQg MDYxNjUyMWFkYzM1Y2IyNTJjYjM5OWYxMTQ3ZjEwMzI4NGYwZjE4OA0KPj4gQXV0aG9yOsKg wqDCoMKgIFBvdXJpYSBNb3VzYXZpemFkZWggVGVocmFuaSA8cG91cmlhQEZyZWVCU0Qub3Jn Pg0KPj4gQXV0aG9yRGF0ZTogMjAyNi0wMy0wNSAxODowMTozMCArMDAwMA0KPj4gQ29tbWl0 OsKgwqDCoMKgIFBvdXJpYSBNb3VzYXZpemFkZWggVGVocmFuaSA8cG91cmlhQEZyZWVCU0Qu b3JnPg0KPj4gQ29tbWl0RGF0ZTogMjAyNi0wMy0wNSAxODowNDozMiArMDAwMA0KPj4NCj4+ IMKgwqAgbmRwOiBTaW1wbGlmeSBhbmQgYnJlYWtkb3duIG5kNl9yYV9pbnB1dCgpDQo+Pg0K Pj4gwqDCoCBgbmQ2X3JhX2lucHV0KClgIGlzIHNpbXBsaWVkIHRvIG1ha2UgaXQgZWFzaWVy IHRvIGFkZA0KPj4gwqDCoCBhZGRpdGlvbmFsIG9wdGlvbnMuDQo+Pg0KPj4gwqDCoCBSZXZp ZXdlZCBieTogZ2xlYml1cw0KPj4gwqDCoCBEaWZmZXJlbnRpYWwgUmV2aXNpb246IGh0dHBz Oi8vcmV2aWV3cy5mcmVlYnNkLm9yZy9ENTUyNjcNCj4+IC0tLQ0KPj4gc3lzL25ldGluZXQ2 L25kNi5jwqDCoMKgwqAgfMKgwqAgOCArLQ0KPj4gc3lzL25ldGluZXQ2L25kNl9ydHIuYyB8 IDMwMCArKysrKysrKysrKysrKysrKysrKysrKysgDQo+PiArLS0tLS0tLS0tLS0tLS0tLS0t LS0tLS0tDQo+PiAyIGZpbGVzIGNoYW5nZWQsIDE1OCBpbnNlcnRpb25zKCspLCAxNTAgZGVs ZXRpb25zKC0pDQo+IA0KPiANCj4gSSBhbSBub3Qgc3VyZSB3aGljaCBjaGFuZ2UgKHRoaXMg b3IgR1JBTkQpIHRyaWdnZXJzIGl0IGJ1dCB0aGlzIGlzIG5ldzoNCj4gDQo+IEludm9raW5n IElQdjYgbmV0d29yayBkZXZpY2UgYWRkcmVzcyBldmVudCBtYXkgc2xlZXAgd2l0aCAxIHNs ZWVwIA0KPiBpbmhpYml0b3JzDQo+IHN0YWNrIGJhY2t0cmFjZToNCj4gIzAgMHhmZmZmZmZm ZjgwYzJlMzZjIGF0IHdpdG5lc3NfZGVidWdnZXIrMHg2Yw0KPiAjMSAweGZmZmZmZmZmODBj MmZjNzkgYXQgd2l0bmVzc193YXJuKzB4NGM5DQo+ICMyIDB4ZmZmZmZmZmY4MGRmN2E1NyBh dCBpbjZfdXBkYXRlX2lmYSsweGM2Nw0KPiAjMyAweGZmZmZmZmZmODBlMjRmMWYgYXQgaW42 X2lmYWRkKzB4MzBmDQo+ICM0IDB4ZmZmZmZmZmY4MGUyMTRkNiBhdCBuZDZfcmFfaW5wdXQr MHgxMDY2DQo+ICM1IDB4ZmZmZmZmZmY4MGRmMTUyMCBhdCBpY21wNl9pbnB1dCsweDViMA0K PiAjNiAweGZmZmZmZmZmODBlMGJlMzUgYXQgaXA2X2lucHV0KzB4YmI1DQo+ICM3IDB4ZmZm ZmZmZmY4MGQyMTlhNCBhdCBuZXRpc3JfZGlzcGF0Y2hfc3JjKzB4YjQNCj4gIzggMHhmZmZm ZmZmZjgwZDAzNzZhIGF0IGV0aGVyX2RlbXV4KzB4MTZhDQo+ICM5IDB4ZmZmZmZmZmY4MGQw NGNkZSBhdCBldGhlcl9uaF9pbnB1dCsweDNjZQ0KPiAjMTAgMHhmZmZmZmZmZjgwZDIxOWE0 IGF0IG5ldGlzcl9kaXNwYXRjaF9zcmMrMHhiNA0KPiAjMTEgMHhmZmZmZmZmZjgwZDAzYmI1 IGF0IGV0aGVyX2lucHV0KzB4ZDUNCj4gIzEyIDB4ZmZmZmZmZmY4MGQ1M2QxMiBhdCBpZWVl ODAyMTFfdmFwX2RlbGl2ZXJfZGF0YSsweDMyDQo+ICMxMyAweGZmZmZmZmZmODBkODdjYmQg YXQgc3RhX2lucHV0KzB4YzZkDQo+ICMxNCAweGZmZmZmZmZmODBkNjEzMmMgYXQgaWVlZTgw MjExX2lucHV0X21pbW8rMHgyMGMNCj4gIzE1IDB4ZmZmZmZmZmY4MmYwZjE1NSBhdCBsa3Bp XzgwMjExX2xod19yeHFfdGFzaysweDEzNQ0KPiAjMTYgMHhmZmZmZmZmZjgwYzIwMDQyIGF0 IHRhc2txdWV1ZV9ydW5fbG9ja2VkKzB4MWMyDQo+ICMxNyAweGZmZmZmZmZmODBjMjBmMzMg YXQgdGFza3F1ZXVlX3RocmVhZF9sb29wKzB4ZDMNCj4gDQo+IA0KDQotLSANClBvdXJpYQ0K DQo= --------------khl1g8jg48Ihb56704Ks81xv-- --------------rmPwUe9RYSCxp049ZgOrJYN3 Content-Type: application/pgp-signature; name="OpenPGP_signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="OpenPGP_signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQSqt7cppfvJ816gj0lUwVnUeMwagAUCaarJAwAKCRBUwVnUeMwa gOTPAQC2ewq5gY3oOyFqi+qBZlNqFEDfYN8bQIvSeYIMsUFHxQEAgPh0Bz9BY5e5 RhHKVuP/E7u/a3JrKQ7FGaaW/T0/OAc= =86zb -----END PGP SIGNATURE----- --------------rmPwUe9RYSCxp049ZgOrJYN3-- From nobody Fri Mar 6 12:36:47 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fS5WM4R3Zz6Tk1F for ; Fri, 06 Mar 2026 12:36: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fS5WM45Plz3kcn for ; Fri, 06 Mar 2026 12:36:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772800607; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GdJ11poXcwOP+fZvrqbOHm4nFgIBaImd+L4PW4dY0Pk=; b=pELSixVLDQcb4ww4ifhc/YaDqhXthSIq9196ResAWrmZzOmeWBvS2GfyGiCGsgtKzkVuNo zj1jIU4JFcZpewmz7wJP5WDmu/Yr1dLpSJQndRmLLjFrps2yEy2YA+ODLIhND61nBrWvXn I3uzHkGt/KqnmO+Cqb2RrNve9jDE6ZAhYSmN+5gfhkQ9iRhlvCl9W3NZvh0j7QlX8hteDO dKkYVHRbsUWQJAiuSUt3mkbgldyDNby8NjEYlUirSW//W2o5TKFOK8rXPvsuu0bDdL0TGE l4qSaqYzrD8++y+uNCeFnLUS7ikASPhdBH5XwZKudbt8DxooxfvXdeyXR7NbvA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772800607; a=rsa-sha256; cv=none; b=ANzMz7kJiRCG4x/Dl6b1kvC8RGBU+cBt7rFrabKWimqCw+OhEjqf5GvlD000SDd9OG4IC3 +6BvmomrugOvAzaymvPUzI5Bopss7NrYYgMZ3mzGgJ+YaN2eCy8qaOLcZxuEjvPNXOgDe5 BhN9wXVmFHwp/uhZlWTSlPeShsn6+ES2ATyIs05C45zVZpPXayBpzAvpghPTpfTMfNzytz s3ZQQXMl0i3aoF19e6PMfGRncl8kDWhYu9E3Q27A7iPze5remECG2NwMrnfF+oFRjOh2fI LvN/n6jTGtASS6GwMfKWkhdMob+gg1vpiJag5wsSOymjtsaEbp4cSxReuE93Hw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772800607; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GdJ11poXcwOP+fZvrqbOHm4nFgIBaImd+L4PW4dY0Pk=; b=tXrofYy03Zm0zMcWHMjAniug82QdnaknZ2gsTB12SUm7sGzGYeYQWDT/+636KXIS4rfbyL 2QFtB1yMW1rf4/xS9LpqxfpfRH5fGwTKIq2r0AWio/unmDpUtQkN3IP02UzMGz+1xqiYg3 F9QUjdRNQ6M72/igrJhHQDrSEQxrIYSiInRmgNZ2u4j/HgP1zzGmuH45ycexJYOnczx1dC xmbHbb18mDBVlunYF4qTcm28x0ejCbtyho9o1xtaDtBsrRZCzkfy2NQbfgP+t+V5yKxx4t jGNRhJAU+H37ieIhHw/imduz04+kTIPai4OlBUr+DT33nhFTAyFC8VQCWWfVpA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fS5WM3YkXz77t for ; Fri, 06 Mar 2026 12:36:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 47cbe by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 12:36:47 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Pouria Mousavizadeh Tehrani Subject: git: 0951901814d1 - main - rtadvd: add multi pref64 support List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pouria X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0951901814d1def721ac9a4fc3657af5c9694228 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 12:36:47 +0000 Message-Id: <69aaca5f.47cbe.308c0abc@gitrepo.freebsd.org> The branch main has been updated by pouria: URL: https://cgit.FreeBSD.org/src/commit/?id=0951901814d1def721ac9a4fc3657af5c9694228 commit 0951901814d1def721ac9a4fc3657af5c9694228 Author: Pouria Mousavizadeh Tehrani AuthorDate: 2026-03-06 11:48:23 +0000 Commit: Pouria Mousavizadeh Tehrani CommitDate: 2026-03-06 12:35:09 +0000 rtadvd: add multi pref64 support Add support for multi pref64 in rtadvd and rtadvctl Reviewed By: zlei, bz Differential Revision: https://reviews.freebsd.org/D54636 --- usr.sbin/rtadvctl/rtadvctl.c | 46 ++++++++++++++ usr.sbin/rtadvd/config.c | 130 ++++++++++++++++++++++----------------- usr.sbin/rtadvd/config.h | 1 + usr.sbin/rtadvd/control_server.c | 56 +++++++++++++++++ usr.sbin/rtadvd/rtadvd.c | 8 ++- usr.sbin/rtadvd/rtadvd.conf.5 | 23 ++++++- usr.sbin/rtadvd/rtadvd.h | 3 +- 7 files changed, 204 insertions(+), 63 deletions(-) diff --git a/usr.sbin/rtadvctl/rtadvctl.c b/usr.sbin/rtadvctl/rtadvctl.c index 9fdb643cef10..201993ab06df 100644 --- a/usr.sbin/rtadvctl/rtadvctl.c +++ b/usr.sbin/rtadvctl/rtadvctl.c @@ -89,6 +89,7 @@ static int action_show_prefix(struct prefix *); static int action_show_rtinfo(struct rtinfo *); static int action_show_rdnss(void *); static int action_show_dnssl(void *); +static void action_show_pref64(void *); static int csock_client_open(struct sockinfo *); static size_t dname_labeldec(char *, size_t, const char *); @@ -414,6 +415,7 @@ action_show(int argc, char **argv) char argv_ifi_ra_timer[IFNAMSIZ + sizeof(":ifi_ra_timer=")]; char argv_rdnss[IFNAMSIZ + sizeof(":rdnss=")]; char argv_dnssl[IFNAMSIZ + sizeof(":dnssl=")]; + char argv_pref64[IFNAMSIZ + sizeof(":pref64=")]; char ssbuf[SSBUFLEN]; struct timespec now, ts0, ts; @@ -691,6 +693,21 @@ action_show(int argc, char **argv) action_show_dnssl(cp.cp_val); } + /* PREF64 information */ + sprintf(argv_pref64, "%s:pref64=", ifi->ifi_ifname); + action_argv = argv_pref64; + + error = action_propget(action_argv, &cp); + if (error) + continue; + + len = *((uint16_t *)cp.cp_val); + + if (len > 0) { + printf("\tPREF64:\n"); + action_show_pref64(cp.cp_val); + } + if (vflag < LOG_NOTICE) continue; @@ -896,6 +913,35 @@ action_show_dnssl(void *msg) return (0); } +static void +action_show_pref64(void *msg) +{ + struct pref64 *prf64; + uint16_t *prf64_cnt; + char ntopbuf[INET6_ADDRSTRLEN]; + char ssbuf[SSBUFLEN]; + char *p; + int i; + uint16_t prf64len; + + p = msg; + prf64_cnt = (uint16_t *)p; + p += sizeof(*prf64_cnt); + + for (i = 0; i < *prf64_cnt; i++) { + prf64 = (struct pref64 *)p; + + /* RFC 8781 Section 4: Map PLC values to prefix lengths */ + prf64len = (prf64->p64_plc == 0) ? 96 : 72 - (8 * prf64->p64_plc); + printf("\t %s/%d (ltime: %s)\n", + inet_ntop(AF_INET6, &prf64->p64_prefix, + ntopbuf, sizeof(ntopbuf)), + prf64len, sec2str(prf64->p64_sl, ssbuf)); + + p += sizeof(*prf64); + } +} + /* Decode domain name label encoding in RFC 1035 Section 3.1 */ static size_t dname_labeldec(char *dst, size_t dlen, const char *src) diff --git a/usr.sbin/rtadvd/config.c b/usr.sbin/rtadvd/config.c index 1b37d53c8b91..83b2efb68303 100644 --- a/usr.sbin/rtadvd/config.c +++ b/usr.sbin/rtadvd/config.c @@ -291,6 +291,7 @@ rm_rainfo(struct rainfo *rai) struct rdnss *rdn; struct rdnss_addr *rdna; struct dnssl *dns; + struct pref64 *prf64; struct rtinfo *rti; syslog(LOG_DEBUG, "<%s>: enter", __func__); @@ -325,6 +326,10 @@ rm_rainfo(struct rainfo *rai) TAILQ_REMOVE(&rai->rai_route, rti, rti_next); free(rti); } + while ((prf64 = TAILQ_FIRST(&rai->rai_pref64)) != NULL) { + TAILQ_REMOVE(&rai->rai_pref64, prf64, p64_next); + free(prf64); + } free(rai); syslog(LOG_DEBUG, "<%s>: leave", __func__); @@ -369,6 +374,7 @@ getconfig(struct ifinfo *ifi) TAILQ_INIT(&rai->rai_route); TAILQ_INIT(&rai->rai_rdnss); TAILQ_INIT(&rai->rai_dnssl); + TAILQ_INIT(&rai->rai_pref64); TAILQ_INIT(&rai->rai_soliciter); rai->rai_ifinfo = ifi; @@ -916,52 +922,62 @@ getconfig_free_dns: /* * handle pref64 */ - rai->rai_pref64.p64_enabled = false; + for (i = -1; i < MAXPREF64 ; i++) { + struct pref64 *prf64; + + makeentry(entbuf, sizeof(entbuf), i, "pref64"); + addr = (char *)agetstr(entbuf, &bp); + if (addr == NULL) + continue; + ELM_MALLOC(prf64, exit(1)); - if ((addr = (char *)agetstr("pref64", &bp))) { - if (inet_pton(AF_INET6, addr, &rai->rai_pref64.p64_prefix) != 1) { + if (inet_pton(AF_INET6, addr, &prf64->p64_prefix) != 1) { syslog(LOG_ERR, "<%s> inet_pton failed for %s", __func__, addr); - } else { - rai->rai_pref64.p64_enabled = true; - - switch (val64 = agetnum("pref64len")) { - case -1: - case 96: - rai->rai_pref64.p64_plc = 0; - break; - case 64: - rai->rai_pref64.p64_plc = 1; - break; - case 56: - rai->rai_pref64.p64_plc = 2; - break; - case 48: - rai->rai_pref64.p64_plc = 3; - break; - case 40: - rai->rai_pref64.p64_plc = 4; - break; - case 32: - rai->rai_pref64.p64_plc = 5; - break; - default: - syslog(LOG_ERR, "prefix length %" PRIi64 - "on %s is invalid; disabling PREF64", - val64, ifi->ifi_ifname); - rai->rai_pref64.p64_enabled = 0; - break; - } + goto getconfig_free_prf64; + } - /* This logic is from RFC 8781 section 4.1. */ - val64 = agetnum("pref64lifetime"); - if (val64 == -1) - val64 = rai->rai_lifetime * 3; - if (val64 > 65528) - val64 = 65528; - val64 = (val64 + 7) / 8; - rai->rai_pref64.p64_sl = (uint16_t) (uint64_t) val64; + makeentry(entbuf, sizeof(entbuf), i, "pref64len"); + MAYHAVE(val64, entbuf, 96); + switch (val64) { + case 96: + prf64->p64_plc = 0; + break; + case 64: + prf64->p64_plc = 1; + break; + case 56: + prf64->p64_plc = 2; + break; + case 48: + prf64->p64_plc = 3; + break; + case 40: + prf64->p64_plc = 4; + break; + case 32: + prf64->p64_plc = 5; + break; + default: + syslog(LOG_ERR, "PREF64 prefix length %" PRIi64 + "on %s is invalid; skipping", + val64, ifi->ifi_ifname); + goto getconfig_free_prf64; } + + makeentry(entbuf, sizeof(entbuf), i, "pref64lifetime"); + MAYHAVE(val64, entbuf, (rai->rai_lifetime * 3)); + /* This logic is from RFC 8781 section 4.1. */ + if (val64 > 65528) + val64 = 65528; + val64 = (val64 + 7) / 8; + prf64->p64_sl = (uint16_t)val64; + + /* link into chain */ + TAILQ_INSERT_TAIL(&rai->rai_pref64, prf64, p64_next); + continue; +getconfig_free_prf64: + free(prf64); } /* construct the sending packet */ @@ -1386,6 +1402,7 @@ make_packet(struct rainfo *rai) struct rdnss *rdn; struct nd_opt_dnssl *ndopt_dnssl; struct dnssl *dns; + struct pref64 *prf64; struct nd_opt_pref64 *ndopt_pref64; size_t len; struct prefix *pfx; @@ -1408,8 +1425,6 @@ make_packet(struct rainfo *rai) packlen += sizeof(struct nd_opt_prefix_info) * rai->rai_pfxs; if (rai->rai_linkmtu) packlen += sizeof(struct nd_opt_mtu); - if (rai->rai_pref64.p64_enabled) - packlen += sizeof(struct nd_opt_pref64); TAILQ_FOREACH(rti, &rai->rai_route, rti_next) packlen += sizeof(struct nd_opt_route_info) + @@ -1436,6 +1451,9 @@ make_packet(struct rainfo *rai) packlen += len; } + TAILQ_FOREACH(prf64, &rai->rai_pref64, p64_next) + packlen += sizeof(struct nd_opt_pref64); + /* allocate memory for the packet */ if ((buf = malloc(packlen)) == NULL) { syslog(LOG_ERR, @@ -1490,19 +1508,6 @@ make_packet(struct rainfo *rai) buf += sizeof(struct nd_opt_mtu); } - if (rai->rai_pref64.p64_enabled) { - ndopt_pref64 = (struct nd_opt_pref64 *)buf; - ndopt_pref64->nd_opt_pref64_type = ND_OPT_PREF64; - ndopt_pref64->nd_opt_pref64_len = 2; - ndopt_pref64->nd_opt_pref64_sl_plc = - (htons(rai->rai_pref64.p64_sl << 3)) | - htons((rai->rai_pref64.p64_plc & 0x7)); - memcpy(&ndopt_pref64->nd_opt_prefix[0], - &rai->rai_pref64.p64_prefix, - sizeof(ndopt_pref64->nd_opt_prefix)); - buf += sizeof(struct nd_opt_pref64); - } - TAILQ_FOREACH(pfx, &rai->rai_prefix, pfx_next) { uint32_t vltime, pltime; struct timespec now; @@ -1616,4 +1621,17 @@ make_packet(struct rainfo *rai) syslog(LOG_DEBUG, "<%s>: nd_opt_dnssl_len = %d", __func__, ndopt_dnssl->nd_opt_dnssl_len); } + + TAILQ_FOREACH(prf64, &rai->rai_pref64, p64_next) { + ndopt_pref64 = (struct nd_opt_pref64 *)buf; + ndopt_pref64->nd_opt_pref64_type = ND_OPT_PREF64; + ndopt_pref64->nd_opt_pref64_len = 2; + ndopt_pref64->nd_opt_pref64_sl_plc = + (htons(prf64->p64_sl << 3)) | + htons((prf64->p64_plc & 0x7)); + memcpy(&ndopt_pref64->nd_opt_prefix[0], + &prf64->p64_prefix, + sizeof(ndopt_pref64->nd_opt_prefix)); + buf += sizeof(struct nd_opt_pref64); + } } diff --git a/usr.sbin/rtadvd/config.h b/usr.sbin/rtadvd/config.h index cfea1821ca5e..d795aab066cd 100644 --- a/usr.sbin/rtadvd/config.h +++ b/usr.sbin/rtadvd/config.h @@ -52,3 +52,4 @@ extern void get_prefix(struct rainfo *); #define MAXROUTE 100 #define MAXRDNSSENT 100 #define MAXDNSSLENT 100 +#define MAXPREF64 100 diff --git a/usr.sbin/rtadvd/control_server.c b/usr.sbin/rtadvd/control_server.c index 60fdc5ca2ec0..e38045b0d574 100644 --- a/usr.sbin/rtadvd/control_server.c +++ b/usr.sbin/rtadvd/control_server.c @@ -80,6 +80,7 @@ static int cm_getprop_rai(struct ctrl_msg_pl *); static int cm_getprop_pfx(struct ctrl_msg_pl *); static int cm_getprop_rdnss(struct ctrl_msg_pl *); static int cm_getprop_dnssl(struct ctrl_msg_pl *); +static int cm_getprop_pref64(struct ctrl_msg_pl *); static int cm_getprop_rti(struct ctrl_msg_pl *); static int cm_setprop_reload(struct ctrl_msg_pl *); @@ -101,6 +102,7 @@ static struct dispatch_table { DEF_PL_HANDLER(pfx), DEF_PL_HANDLER(rdnss), DEF_PL_HANDLER(dnssl), + DEF_PL_HANDLER(pref64), }; static int @@ -516,6 +518,60 @@ cm_getprop_dnssl(struct ctrl_msg_pl *cp) return (0); } +static int +cm_getprop_pref64(struct ctrl_msg_pl *cp) +{ + struct ifinfo *ifi; + struct rainfo *rai; + struct pref64 *prf64; + char *p; + size_t len; + uint16_t *prf64_cnt; + + syslog(LOG_DEBUG, "<%s> enter", __func__); + + len = 0; + TAILQ_FOREACH(ifi, &ifilist, ifi_next) { + if (strcmp(cp->cp_ifname, ifi->ifi_ifname) == 0) + break; + } + if (ifi == NULL) { + syslog(LOG_ERR, "<%s> %s not found", __func__, + cp->cp_ifname); + return (1); + } + if (ifi->ifi_rainfo == NULL) { + syslog(LOG_ERR, "<%s> %s has no rainfo", __func__, + cp->cp_ifname); + return (1); + } + rai = ifi->ifi_rainfo; + + len = sizeof(*prf64_cnt); + TAILQ_FOREACH(prf64, &rai->rai_pref64, p64_next) + len += sizeof(*prf64); + + syslog(LOG_DEBUG, "<%s> len = %zu", __func__, len); + + p = malloc(len); + if (p == NULL) + exit(1); + memset(p, 0, len); + cp->cp_val = p; + + prf64_cnt = (uint16_t *)cp->cp_val; + p += sizeof(*prf64_cnt); + TAILQ_FOREACH(prf64, &rai->rai_pref64, p64_next) { + (*prf64_cnt)++; + memcpy(p, prf64, sizeof(*prf64)); + p += sizeof(*prf64); + } + cp->cp_val_len = p - cp->cp_val; + + return (0); +} + + int cm_getprop(struct ctrl_msg_pl *cp) { diff --git a/usr.sbin/rtadvd/rtadvd.c b/usr.sbin/rtadvd/rtadvd.c index fa5640afa96c..1eb8f12a7338 100644 --- a/usr.sbin/rtadvd/rtadvd.c +++ b/usr.sbin/rtadvd/rtadvd.c @@ -137,6 +137,7 @@ union nd_opt { #define NDOPT_FLAG_MTU (1 << 4) #define NDOPT_FLAG_RDNSS (1 << 5) #define NDOPT_FLAG_DNSSL (1 << 6) +#define NDOPT_FLAG_PREF64 (1 << 7) static uint32_t ndopt_flags[] = { [ND_OPT_SOURCE_LINKADDR] = NDOPT_FLAG_SRCLINKADDR, @@ -146,6 +147,7 @@ static uint32_t ndopt_flags[] = { [ND_OPT_MTU] = NDOPT_FLAG_MTU, [ND_OPT_RDNSS] = NDOPT_FLAG_RDNSS, [ND_OPT_DNSSL] = NDOPT_FLAG_DNSSL, + [ND_OPT_PREF64] = NDOPT_FLAG_PREF64, }; static void rtadvd_shutdown(void); @@ -1083,7 +1085,7 @@ ra_input(int len, struct nd_router_advert *nra, error = nd6_options((struct nd_opt_hdr *)(nra + 1), len - sizeof(struct nd_router_advert), &ndopts, NDOPT_FLAG_SRCLINKADDR | NDOPT_FLAG_PREFIXINFO | NDOPT_FLAG_MTU | - NDOPT_FLAG_RDNSS | NDOPT_FLAG_DNSSL); + NDOPT_FLAG_RDNSS | NDOPT_FLAG_DNSSL | NDOPT_FLAG_PREF64); if (error) { syslog(LOG_INFO, "<%s> ND option check failed for an RA from %s on %s", @@ -1428,7 +1430,8 @@ nd6_options(struct nd_opt_hdr *hdr, int limit, if (hdr->nd_opt_type > ND_OPT_MTU && hdr->nd_opt_type != ND_OPT_RDNSS && - hdr->nd_opt_type != ND_OPT_DNSSL) { + hdr->nd_opt_type != ND_OPT_DNSSL && + hdr->nd_opt_type != ND_OPT_PREF64) { syslog(LOG_INFO, "<%s> unknown ND option(type %d)", __func__, hdr->nd_opt_type); continue; @@ -1473,6 +1476,7 @@ skip: case ND_OPT_REDIRECTED_HEADER: case ND_OPT_RDNSS: case ND_OPT_DNSSL: + case ND_OPT_PREF64: break; /* we don't care about these options */ case ND_OPT_SOURCE_LINKADDR: case ND_OPT_MTU: diff --git a/usr.sbin/rtadvd/rtadvd.conf.5 b/usr.sbin/rtadvd/rtadvd.conf.5 index 8158d09f99cf..5af4865885c4 100644 --- a/usr.sbin/rtadvd/rtadvd.conf.5 +++ b/usr.sbin/rtadvd/rtadvd.conf.5 @@ -27,7 +27,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd June 4, 2011 +.Dd January 14, 2026 .Dt RTADVD.CONF 5 .Os .Sh NAME @@ -435,6 +435,21 @@ These items are optional. .Bl -tag -width indent .It Cm \&pref64 (str) The prefix to advertise in the PREF64 option. +Multiple PREF64 prefixes can be specified by seperating entries using +.Cm pref64 , +.Cm pref640 , +.Cm pref641 , +.Cm pref642 ... +options with corresponding +.Cm pref64len , +.Cm pref64len0 , +.Cm pref64len1 , +.Cm pref64len2 ... +entries. +This is also true for the +.Cm pref64lifetime +option. +Note that the maximum number of prefixes depends on the receiver side. .It Cm \&pref64len (num) The length of the PREF64 prefix. This must be 96, 64, 56, 48, 40, or 32. @@ -484,13 +499,15 @@ ef0:\\ .Pp The following example configures the .Li wlan0 -interface and adds two DNS servers and a DNS domain search options +interface and adds two DNS servers, a DNS domain search, +and a PREF64 prefix, using the default option lifetime values. .Bd -literal -offset indent wlan0:\\ :addr="2001:db8:ffff:1000::":prefixlen#64:\\ :rdnss="2001:db8:ffff::10,2001:db8:ffff::2:43":\\ - :dnssl="example.com": + :dnssl="example.com":\\ + :pref64="64:ff9b::": .Ed .Pp The following example presents the default values in an explicit manner. diff --git a/usr.sbin/rtadvd/rtadvd.h b/usr.sbin/rtadvd/rtadvd.h index 597fb2f47f0d..5ecfd1b56423 100644 --- a/usr.sbin/rtadvd/rtadvd.h +++ b/usr.sbin/rtadvd/rtadvd.h @@ -152,7 +152,6 @@ struct rdnss { struct pref64 { TAILQ_ENTRY(pref64) p64_next; - bool p64_enabled; uint16_t p64_plc; /* prefix length code */ uint16_t p64_sl; /* scaled lifetime */ struct in6_addr p64_prefix; @@ -227,7 +226,7 @@ struct rainfo { /* actual RA packet data and its length */ size_t rai_ra_datalen; char *rai_ra_data; - struct pref64 rai_pref64; /* PREF64 option */ + TAILQ_HEAD(, pref64) rai_pref64; /* PREF64 option */ /* info about soliciter */ TAILQ_HEAD(, soliciter) rai_soliciter; /* recent solication source */ From nobody Fri Mar 6 14:24:53 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fS7w63cZRz6Tsnm; Fri, 06 Mar 2026 14:24:54 +0000 (UTC) (envelope-from jhb@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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fS7w62Qsnz3w4k; Fri, 06 Mar 2026 14:24:54 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772807094; h=from:from:reply-to:subject: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=DWn9CGj3UhyVUQzO5rm7DIe0slLWIYFdN5VhahUBweM=; b=UwdGHFuB6DBQzV7g09kXdEvgy0I4cYANrOawgyc20jurri7RwkB+MNRBFIlaM6GLpeTu8A 4vE+kRm9GlClu9ewhECdPtyQMC8KouFwLnRkSuKhlzb0fv8iQdacnhtGVGVpagMPtdvWyO L7fT7FgemwJojngjhcI/RcQzGs4hkH36k+Li3wErbl5PaexrfjseI0MwnGWdyd6dECrUqo GwXEXxgWEcYUv+n5cz50ctsiIfcyX27+uXYO02EJB5m9GvZyeH7z9rueWnIi/U7d/NzD/H mi44R7NFR52UDvPWW5HH6jTKXFUjrbL4iIJrD647JbNd+wJghM3DK76GDVNP3Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772807094; a=rsa-sha256; cv=none; b=E/y9e25d/paJc6eavxsKhgTprMcTTEweQ2pQjo+nWIRF18yMB4H9XD3mTR/P1jCaEa3OT3 p+ZbZUSGp12VTYjVNJktBJzetzR6SfFY07qYLW6Ge6PrlVHDpIkCZz6d+5E7GDx7AEDef2 eZtmF0vWrhIle2zcFBv35G1nwGW3SUWjUy1k54qNmSeZmPhSU6PXTLRspodpnO0y6CKuGJ Z18PB0MB2GxjY/T+uKJ93Vu2GfTKDxBVFe16hPchtAenk6+u3jXbfi6C5v57vtUo9P2lpP JadDYD2oLTnJ1wpDi4LVJrO/9q3Gs3eQrFsLw98v34aE5MzAu/xG+XxaBQORvw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772807094; h=from:from:reply-to:subject: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=DWn9CGj3UhyVUQzO5rm7DIe0slLWIYFdN5VhahUBweM=; b=MfLHEJ543ZIngmbg2ZPVh1lplLEfrTwzdZX/OACaWv4kXdbnvoM6QuYXd4lzZNA64LwS0+ Z3tm4hkVfQn9pxRWCgrJJ1Lh73qCQHu5P6X7GUjWLSoDs+9kOZFRK9VE+ftuETo2FxtYSK DcYedc3z+0n5JvCC+PM4IbtXmpx7EbEbfiIZkxnmtHzjtIbp8p9sG66IKKd4TBKFerhWLk SlG1baqlNUNm6KHru6cYsPZpBa6bHmSR9AJf5BJaeJBhdkBhxfOq/DMN0ITn9TKOHltG+F y+c9xKyEovJad/rSvSZdJMSk3vlVWbz/lneWdXSJMVSjU8YWj/4ak5KAIkA+LA== Received: from [IPV6:2601:5c0:4202:5670:c17f:7f38:ee70:3c8a] (unknown [IPv6:2601:5c0:4202:5670:c17f:7f38:ee70:3c8a]) (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: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4fS7w60NHpzygQ; Fri, 06 Mar 2026 14:24:53 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: <2ee33b8f-afdc-4d76-a932-1551967b9107@FreeBSD.org> Date: Fri, 6 Mar 2026 09:24:53 -0500 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: 8dd28e13e41b - main - libc/quad: fix missing closing #endif in Symbol.map Content-Language: en-US To: Xin LI , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org References: <69aa8f32.26f39.6c45e3d3@gitrepo.freebsd.org> From: John Baldwin In-Reply-To: <69aa8f32.26f39.6c45e3d3@gitrepo.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 3/6/26 03:24, Xin LI wrote: > The branch main has been updated by delphij: > > URL: https://cgit.FreeBSD.org/src/commit/?id=8dd28e13e41b6200e58d6e99981ff8323cff3711 > > commit 8dd28e13e41b6200e58d6e99981ff8323cff3711 > Author: Xin LI > AuthorDate: 2026-03-06 08:22:06 +0000 > Commit: Xin LI > CommitDate: 2026-03-06 08:22:06 +0000 > > libc/quad: fix missing closing #endif in Symbol.map > > Without this lib32 libc.so.7 would be missing critical symbols, > including malloc / free and all syscall wrappers. Oof, my bad, thanks for fixing. > --- > lib/libc/quad/Symbol.map | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/lib/libc/quad/Symbol.map b/lib/libc/quad/Symbol.map > index c28f9a180704..251814cb238f 100644 > --- a/lib/libc/quad/Symbol.map > +++ b/lib/libc/quad/Symbol.map > @@ -50,4 +50,5 @@ FBSD_1.0 { > __udivdi3; > __umoddi3; > __xordi3; > +#endif > }; > -- John Baldwin From nobody Fri Mar 6 14:51:24 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fS8Vj06Hmz6TvYp for ; Fri, 06 Mar 2026 14:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fS8Vh6gXBz3xfn for ; Fri, 06 Mar 2026 14:51:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772808684; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tCkPE5rWyWu/Xv5htI3Ji6CuexI13th25vqAsQjuPcg=; b=vwYItQLnUIbGYtEa/UwPbimK1QZ2Gjk9tbpf8Z7JNzkRE6Sv4uG3LmH/W9wWfLaLq+pXV3 l6u8qu87ThKU2/tWiIFhYbBGwGb3ot7wV0UFLF2ZhfLjkLEeb96c3luoBOaOT+icCs50HV iUSvrX5ENgzar294rbJoF6RLczR0VfWXgdLA4UtB1j+uStruEIWLhw7ALyUMEphJ9AsTUD c1MTA8aaCdJ9FisNAgAP+GCDJf/Uckcym42PzilLF+qIRzbY2CUe2v1Vkh78tjKR2yZg2A kpdzCwn6es2hhAOX6HmW8bm3t+ydnZFOko4/y4rHpxTtn8LNrhqBzWnSzbTDbg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772808684; a=rsa-sha256; cv=none; b=Vzhrkb4e9eUwNtEM5aj6etdlDwbLb5UE7nCiMcNFQqWM0zBAsd/yNCDOCXXw0yn+gjNZ88 vEb2GjZxIYWVnpVn++aldAhS1RetJFTjzQwuYocMcQnEXg7m47DjkRhkhiuBwxsDHKADp9 ifHlrWF1S4j0wR4w/KSswvkwEXAYVIeu4vonPD1aA1xWTEYqIZlZhHI0oFKDkbmKucL0c8 u2W8y/jimoD5zqUtu2GVjH+yTmvr0wYftsPUtrfE/DaPOr3h964zfD3GXP+tlXfJux4Uti ZazcnNNwatsdhNRKppWACZp8Vh83Elbv9gIviCUXGCV2wL60fpl4qU6l22j5Fw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772808684; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tCkPE5rWyWu/Xv5htI3Ji6CuexI13th25vqAsQjuPcg=; b=ir+GWwCQf7HDtYqy0kxW6vUcpbTvv6ODq5rQjOKr/68R2YOUTHy/9/I5MkKwmYVUVxf7mz Q71rVDdZzEvEhO7ZnrGdNtHWVLCZHnJvgi/oP2lWLMut1ITrIaosiqD/B8kdjQfm/eeaY1 wmYhyjtnWndiGzqgDegWWr5syXYC2AdZOU4TT2XdUd7WA76JsxXVTf/acVFruANompmUBp O57oo4qyhVI8pCGZLfo+uiN3eJHoxcLLWHEbGjEiF2Y9cz3qLdQbbZf7hOU0JiaZPTRMCC ObJLQe+KrrffxSEihz7GKNIb2f4rwDF7agkV7M/C7UWXKPG93BP1jaUb+NyGBw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fS8Vh64y2zBrk for ; Fri, 06 Mar 2026 14:51:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 27c10 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 14:51:24 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 42e4df8b8531 - main - usr.bin: Exclude ELF Tool Chain cxxfilt build List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 42e4df8b853186190b61428f0bd0f923cc525033 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 14:51:24 +0000 Message-Id: <69aae9ec.27c10.5a44ca76@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=42e4df8b853186190b61428f0bd0f923cc525033 commit 42e4df8b853186190b61428f0bd0f923cc525033 Author: Ed Maste AuthorDate: 2026-03-06 14:47:53 +0000 Commit: Ed Maste CommitDate: 2026-03-06 14:50:54 +0000 usr.bin: Exclude ELF Tool Chain cxxfilt build when LLVM_BINUTILS is enabled (which is the default). PR: 293610 Fixes: 5d757312ad59 ("build: Retire LLVM_CXXFILT option") Sponsored by: The FreeBSD Foundation --- usr.bin/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.bin/Makefile b/usr.bin/Makefile index 125ecb6f05a0..d536f26ab0da 100644 --- a/usr.bin/Makefile +++ b/usr.bin/Makefile @@ -248,6 +248,7 @@ SUBDIR.${MK_TFTP}+= tftp # Only build the elftoolchain tools if we aren't using the LLVM ones. SUBDIR.${MK_TOOLCHAIN}+= addr2line SUBDIR.${MK_TOOLCHAIN}+= ar +SUBDIR.${MK_TOOLCHAIN}+= cxxfilt SUBDIR.${MK_TOOLCHAIN}+= nm SUBDIR.${MK_TOOLCHAIN}+= readelf SUBDIR.${MK_TOOLCHAIN}+= size @@ -255,7 +256,6 @@ SUBDIR.${MK_TOOLCHAIN}+= size SUBDIR.${MK_TOOLCHAIN}+= c89 SUBDIR.${MK_TOOLCHAIN}+= c99 SUBDIR.${MK_TOOLCHAIN}+= ctags -SUBDIR.${MK_TOOLCHAIN}+= cxxfilt # ELF Tool Chain elfcopy required for EFI objects (PR280771) SUBDIR.${MK_TOOLCHAIN}+= elfcopy SUBDIR.${MK_TOOLCHAIN}+= file2c From nobody Fri Mar 6 15:26:21 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fS9H14p8gz6TxcB for ; Fri, 06 Mar 2026 15:26: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fS9H148J2z42T1 for ; Fri, 06 Mar 2026 15:26:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772810781; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PdbIvgaAtF7Usp30KptHEEw5j3Fd18wmFAYp7xmirP4=; b=qe49409pzEE155tZvaET3Dov+d7E4o5pwWCQQmcPcGSi83Gs28Nn7e4SgZkDY337tvxHyn NFd4xxa4d2lxBJkon2McT1QQibAMfVjRSQXLDwFitnKv3wx5UUUPu1U7d/W0SVDzzEwEzM JHS5xiZMVRz3nd1+u50KDgN2bjEsjs9rpzlhclKDiMnnWFqxSLXpmhRf8QXpA3CTpkRzhj RbN0mOWIx78EE7qY63vyw0lgbpSwzaXzluakfsTI0DxPAeuGaMgU9KqxiSXiTH7wyM5eh4 10GW7qGwpj5A38NvMEYtcHCDLZqYG+MW42Jn0w8B00D7rFG+LmR/AwgYtr8F2Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772810781; a=rsa-sha256; cv=none; b=O6W5M3QdLbz0tTZQ0Z7vBQFeWpF53tk5Gwq+0ELsNSysiJkLXctaWC6w8OUB/dRMG1HA5m ANmvRT/kmbotVZvCkik0UBwmJpmfjP0dlKlLt/+49ENnCrURJclWh1CtwRrxEu3RvZos8u pi2d0Jwm1Qt6eYgFYnBECKPL8OpCrB10SIv2I9wWT3gfUq077r1Plfi79fhP7B2EpbRO/l UirogxT0E3HKDV6NErdDFx+Qdhc6dBmMgOerW4u7tv27CTHYy9wTWdkFeV+27yoipRhbPm drMVwNmTXa1vD5Zra/sgI/70KPbwXzI9+Zc78g6hVVryonD0m83W7FZUX2Dg0A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772810781; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PdbIvgaAtF7Usp30KptHEEw5j3Fd18wmFAYp7xmirP4=; b=IznEFC34j9aJS7fMZf7vlRk0lfvRl6G7PTbl7wmZm5QAIpvPxGX2+ODLranoBzpY27tNu6 CLagQ34ll9uCWBQBK3ptN46fb16uYDuCx1bPZ3OHIt84hkkXqfD6JY2vlhUj1QsbyX7AaM mxFnZ993mZqMD3E9HCErS4GoHA9UizB8xgeknui0XFrBRpMLkabqC9IviELDZYE48v/xnh UVnKTna+FvxR8uJbeDCRFGf0lkqS9uztv+d3FSNcnCc0oV+L+sWrzmCGnzMlQp0Qc27VKt 1yQjdFc0DqXpR7Aa2+8wiBhTe+iNb8XkoPJ6qRi8Db6HhnAPuZop65mT/bK5SA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fS9H13lBNzCdv for ; Fri, 06 Mar 2026 15:26:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 31731 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 15:26:21 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Gallatin Subject: git: f1e8b1aca543 - main - splice: optionally limit worker queues List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gallatin X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f1e8b1aca54312a2c7f0d22a83aaae44950dac6b Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 15:26:21 +0000 Message-Id: <69aaf21d.31731.62be3dc2@gitrepo.freebsd.org> The branch main has been updated by gallatin: URL: https://cgit.FreeBSD.org/src/commit/?id=f1e8b1aca54312a2c7f0d22a83aaae44950dac6b commit f1e8b1aca54312a2c7f0d22a83aaae44950dac6b Author: Andrew Gallatin AuthorDate: 2026-03-06 14:59:35 +0000 Commit: Andrew Gallatin CommitDate: 2026-03-06 15:14:23 +0000 splice: optionally limit worker queues Add a new tunable/sysctl (kern.ipc.splice.num_wq) which can be used to limit the number of splice worker queues as a way to limit splice cpu use. The default (-1) keeps the current behavior of running one worker for each core in the system. An administrator can set it to 0 (either via tunable, or before the first splice call via sysctl) to effectively disable splice, or some number smaller than the number of cores to limit splice thread use. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D55579 Sponsored by: Netflix --- sys/kern/uipc_socket.c | 50 +++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 43 insertions(+), 7 deletions(-) diff --git a/sys/kern/uipc_socket.c b/sys/kern/uipc_socket.c index f7c339784693..45290c29f629 100644 --- a/sys/kern/uipc_socket.c +++ b/sys/kern/uipc_socket.c @@ -336,6 +336,33 @@ SYSCTL_BOOL(_kern_ipc_splice, OID_AUTO, receive_stream, CTLFLAG_RWTUN, &splice_receive_stream, 0, "Use soreceive_stream() for stream splices"); +static int splice_num_wq = -1; +static int +sysctl_splice_num_wq(SYSCTL_HANDLER_ARGS) +{ + int error, new; + + new = splice_num_wq; + error = sysctl_handle_int(oidp, &new, 0, req); + if (error == 0 && req->newptr && new != splice_num_wq) { + if (!cold) + sx_xlock(&splice_init_lock); + if (new < -1 || new > mp_ncpus || + (new <= 0 && splice_init_state != 0)) { + error = EINVAL; + } else { + splice_num_wq = new; + } + if (!cold) + sx_xunlock(&splice_init_lock); + } + return (error); +} +SYSCTL_PROC(_kern_ipc_splice, OID_AUTO, num_wq, + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_MPSAFE, + &splice_num_wq, 0, sysctl_splice_num_wq, "IU", + "Number of splice worker queues"); + static uma_zone_t splice_zone; static struct proc *splice_proc; struct splice_wq { @@ -447,24 +474,36 @@ splice_init(void) return (0); } + if (splice_num_wq == -1) { + /* if no user preference, use all cores */ + splice_num_wq = mp_ncpus; + } else if (splice_num_wq == 0) { + /* allow user to disable */ + splice_init_state = -1; + sx_xunlock(&splice_init_lock); + return (ENXIO); + } else if (splice_num_wq > mp_ncpus) { + splice_num_wq = mp_ncpus; + } + splice_zone = uma_zcreate("splice", sizeof(struct so_splice), NULL, NULL, splice_zinit, splice_zfini, UMA_ALIGN_CACHE, 0); - splice_wq = mallocarray(mp_maxid + 1, sizeof(*splice_wq), M_TEMP, + splice_wq = mallocarray(mp_ncpus, sizeof(*splice_wq), M_TEMP, M_WAITOK | M_ZERO); /* * Initialize the workqueues to run the splice work. We create a * work queue for each CPU. */ - CPU_FOREACH(i) { + for (i = 0; i < mp_ncpus; i++) { STAILQ_INIT(&splice_wq[i].head); mtx_init(&splice_wq[i].mtx, "splice work queue", NULL, MTX_DEF); } /* Start kthreads for each workqueue. */ error = 0; - CPU_FOREACH(i) { + for (i = 0; i < mp_ncpus; i++) { error = kproc_kthread_add(splice_work_thread, &splice_wq[i], &splice_proc, &td, 0, 0, "so_splice", "thr_%d", i); if (error) { @@ -1631,10 +1670,7 @@ so_splice_alloc(off_t max) sp->src = NULL; sp->dst = NULL; sp->max = max > 0 ? max : -1; - do { - sp->wq_index = atomic_fetchadd_32(&splice_index, 1) % - (mp_maxid + 1); - } while (CPU_ABSENT(sp->wq_index)); + sp->wq_index = atomic_fetchadd_32(&splice_index, 1) % splice_num_wq; sp->state = SPLICE_INIT; TIMEOUT_TASK_INIT(taskqueue_thread, &sp->timeout, 0, so_splice_timeout, sp); From nobody Fri Mar 6 15:52:51 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fS9sb3d4Dz6T1D5 for ; Fri, 06 Mar 2026 15:52: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fS9sb2xBpz44SR for ; Fri, 06 Mar 2026 15:52:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772812371; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=D+f/PKsR2XaiZRX6CmrTghQyePLvzQuL51owB16fuek=; b=lCujJlFB4Ib7FfXEC2EkpMqIihqcpjs3j5DjWXoSGNlIQS5ESGk4o0tgTjVFwGQdOZ4lw4 Ylody+dTxb+aQLohb9Uw/TrO6mzUkVb5haj+IPb/qyE+sunZ1pemM2vWXaBNU9B6PxYa7Z pyGumWZnUfrwNlVxlpif6dxzHWxS24idejxJo+ya94B1b5A0OoPc6poSLGpQF87ZQHB6YH O4MekysZ0ld88drHed2nNSZv3nonHSEEShEDUxDMw7bKgjpBgRu2LSGmkjlJf/6is8owVa 9fIOi7SUPGbbxEL20QvKtK7L4NYddPhBXy4c+VapipXy6LNTP54M/EFmHx8Beg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772812371; a=rsa-sha256; cv=none; b=aDF6jxd7m7Ik3dZtzetTNXpuNsfK4PlZcZtWGlgUQNJNmnywNtZZhxoIv3P5C7bQtO8gpr FMWhshNrHV1LVUiG71+7vB8Ks8oDeDvqJ00WpmWeM+jzdyWgHKpXfm45pal2dWjI6oCXXb 6Oo1m+WjwNRPIVLcNUySXsGe4W3GbQXXV9/xTgmNhUx6z8uAm5rqKfb9+N3j4dG5mfaESY W1tOzrXvgAZXVL//icIsaoLjpY95rlOHkDIvrms1uNJZK/W7l4NZ1he0hSyF7uxJV5nPmo w464tsjfWDk4/e84VPV2v/nuex1HebeZ9vOJX3D7xBYpBGhE+qjihSLSQEbxlg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772812371; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=D+f/PKsR2XaiZRX6CmrTghQyePLvzQuL51owB16fuek=; b=BWS+1/gNvjXvb7ssgRgi/0M3c01yVN62QE5dHrOKlwPzbM07YlxyRRrv8HlMsdc6NXXJqu nGvWMdZ6qqlAZ9A9zM2gQYBjMuHEkvnJ61mgIgBROgJZdxOS1aJLfXte4OxLZgoqfdNqLP Iueke/j5jb4FB7Oe7yu52nZphk3H5jFCUGQ7ITUNxfrMOOnEkVoERnjsY4u8vac03y7E9r KxRqnif8Abs1mwNGfIaQKlBvbp+NJyfnL3aj4BJiN1H/Y4hNTojqmThm3MQpmjvu/cLCUZ euFYeYVdLXAzgKii5RIpSXL3sIQZ6qpLf39ReLsL2Ab6Z4B4TpVJ1lEszYQ64g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fS9sb2JpLzCkM for ; Fri, 06 Mar 2026 15:52:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 36d29 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 15:52:51 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 88dedd16ba65 - main - llvm-cxxfilt: Install as c++filt only with LLVM_BINUTILS List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 88dedd16ba659ea43bf5572a85e6f8151ee3fd87 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 15:52:51 +0000 Message-Id: <69aaf853.36d29.26801202@gitrepo.freebsd.org> The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=88dedd16ba659ea43bf5572a85e6f8151ee3fd87 commit 88dedd16ba659ea43bf5572a85e6f8151ee3fd87 Author: Ed Maste AuthorDate: 2026-03-06 15:49:22 +0000 Commit: Ed Maste CommitDate: 2026-03-06 15:52:37 +0000 llvm-cxxfilt: Install as c++filt only with LLVM_BINUTILS When building WITHOUT_LLVM_BINUTILS /usr/bin/c++filt is the one from ELF Tool Chain. PR: 293610 Fixes: 5d757312ad59 ("build: Retire LLVM_CXXFILT option") Sponsored by: The FreeBSD Foundation --- usr.bin/clang/llvm-cxxfilt/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/usr.bin/clang/llvm-cxxfilt/Makefile b/usr.bin/clang/llvm-cxxfilt/Makefile index 98cc5c09f4c4..f53503378ea8 100644 --- a/usr.bin/clang/llvm-cxxfilt/Makefile +++ b/usr.bin/clang/llvm-cxxfilt/Makefile @@ -22,7 +22,9 @@ DEPENDFILES+= ${TGHDRS:C/$/.d/} DPSRCS+= ${TGHDRS} CLEANFILES+= ${TGHDRS} ${TGHDRS:C/$/.d/} +.if ${MK_LLVM_BINUTILS} != "no" LINKS= ${BINDIR}/llvm-cxxfilt ${BINDIR}/c++filt MLINKS= llvm-cxxfilt.1 c++filt.1 +.endif .include "../llvm.prog.mk" From nobody Fri Mar 6 17:15:41 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSCj96BXBz6T6rK for ; Fri, 06 Mar 2026 17: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSCj92RHVz3GSf for ; Fri, 06 Mar 2026 17: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=1772817341; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yzl0ksdoX1/Vv+2MxQClhtKH6zvVfYzBpuQpweYoGfY=; b=CD3M83Cag/rYX822cIfK+ZMTWgpz2ovgigz0HUfxjiXZn3lXFPJMPKuza8aaWECpVD8J9B Sw21Iy4J4pLvyx+WnYC8vbLoNwLIAnhBF9FP/mUSwQ2ZNOmp2B9GCM/aYskDEu2VwsNfAV cRG8mnyPk6fm5J7NTcBbD9Ek4p5aWztw2EVUMa+R7486Eq7lf8JSlY5f54pQPTbJ+53dRi +Tp7DQEaMXFtj7BeMkeZ/A+JIYm2LDQrzXkIQueIEb61+tOXwy1ASJI8uy5EgjsSzKcafc yKpl9SjjHcgmjaSG6KVdFxLRAFqMSzlTawpNbmj5/Xo8Qb3WIbBWWyd0tcR+ZQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772817341; a=rsa-sha256; cv=none; b=oYVMhINmL5DtypNkAR5HnGqKgqCGyfayXb2db4tcsYBzYdpjOBP88QwJ14+BpVH9gYFV/1 qVCgeiS0Akk64nB66sNgddEinVo3EfqxyHTHjgGGgGdYrDS045ZB2a2hqFnscxeSgWXWxu oUDMetGz3CphDKL5rKZ1MQ8v9kR/PjzTMtr9ZanGPZLPjBquvQx2F9Wki+70BV+PsxMXPf 8KIX0bLq1gwMBZR+9TuHZezo8rRCQXrRMLu1x+qZejPFsYBfexSS8KvO2mmRnaoahbA5DD KrWl57aTR6ZC8EKDshRO7rt54WIyxovhmRvXiylCaWMeCuJeFhIMvKwesfZ+TA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772817341; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yzl0ksdoX1/Vv+2MxQClhtKH6zvVfYzBpuQpweYoGfY=; b=eyODZvwmEzaFWyAlbSBLoGHSMBZa8TbuWdtwxdzHMzj57y43eZIGL3R+Ltup7atUE44LPf Ll7qjtcEQCI11lGjJaGvOOOEPp1oftF+V1G0uq02tLgWBiha/onN5ZSdwWfizEN7jHRtb3 /RjmaA1+2KmuLWGyckqRUozGNdzUoq3iAdcYXvZ6zVDukW+sSGz1NXpmCb9E9V44LjZhk+ iWzmojOehJ4YSS14nwq2wcpD9mpHZUeaImO9/uEq/dZTE+5la2r4VAeiv7xhCxw4VnsDfb QCQ1fecnr8U1q/LchFLbWbw9hkM2MYXkF18IUJ91HbNrlf6LjWBUf4Wmcqop7A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSCj91VBrzXRQ for ; Fri, 06 Mar 2026 17:15:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3c3e0 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 17:15:41 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: c1567d49a832 - main - iwx: Re-activate the 32-bit boundary cross check on 64-bit architectures List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: c1567d49a8320fd23dff9dbce1186f2331538253 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 17:15:41 +0000 Message-Id: <69ab0bbd.3c3e0.72b84d3@gitrepo.freebsd.org> The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=c1567d49a8320fd23dff9dbce1186f2331538253 commit c1567d49a8320fd23dff9dbce1186f2331538253 Author: Olivier Certner AuthorDate: 2026-03-06 16:33:21 +0000 Commit: Olivier Certner CommitDate: 2026-03-06 17:14:25 +0000 iwx: Re-activate the 32-bit boundary cross check on 64-bit architectures __SIZEOF_*__ is in bytes, not in bits... Reported by: brooks Fixes: 35da55c28dbb ("iwx: Fix 32-bit compilation") MFC after: 1 minute MFC to: stable/15 Sponsored by: The FreeBSD Foundation --- sys/dev/iwx/if_iwx.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/dev/iwx/if_iwx.c b/sys/dev/iwx/if_iwx.c index ea1ba513734a..03ef775205e7 100644 --- a/sys/dev/iwx/if_iwx.c +++ b/sys/dev/iwx/if_iwx.c @@ -5819,7 +5819,7 @@ iwx_tx(struct iwx_softc *sc, struct mbuf *m, struct ieee80211_node *ni) desc->tbs[0].tb_len = htole16(IWX_FIRST_TB_SIZE); paddr = htole64(data->cmd_paddr); memcpy(&desc->tbs[0].addr, &paddr, sizeof(paddr)); -#if __SIZEOF_SIZE_T__ > 32 +#if __SIZEOF_SIZE_T__ > 4 if (data->cmd_paddr >> 32 != (data->cmd_paddr + le32toh(desc->tbs[0].tb_len)) >> 32) DPRINTF(("%s: TB0 crosses 32bit boundary\n", __func__)); @@ -5829,7 +5829,7 @@ iwx_tx(struct iwx_softc *sc, struct mbuf *m, struct ieee80211_node *ni) paddr = htole64(data->cmd_paddr + IWX_FIRST_TB_SIZE); memcpy(&desc->tbs[1].addr, &paddr, sizeof(paddr)); -#if __SIZEOF_SIZE_T__ > 32 +#if __SIZEOF_SIZE_T__ > 4 if (data->cmd_paddr >> 32 != (data->cmd_paddr + le32toh(desc->tbs[1].tb_len)) >> 32) DPRINTF(("%s: TB1 crosses 32bit boundary\n", __func__)); @@ -5841,7 +5841,7 @@ iwx_tx(struct iwx_softc *sc, struct mbuf *m, struct ieee80211_node *ni) desc->tbs[i + 2].tb_len = htole16(seg->ds_len); paddr = htole64(seg->ds_addr); memcpy(&desc->tbs[i + 2].addr, &paddr, sizeof(paddr)); -#if __SIZEOF_SIZE_T__ > 32 +#if __SIZEOF_SIZE_T__ > 4 if (data->cmd_paddr >> 32 != (data->cmd_paddr + le32toh(desc->tbs[i + 2].tb_len)) >> 32) DPRINTF(("%s: TB%d crosses 32bit boundary\n", __func__, From nobody Fri Mar 6 17:15:42 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSCjB3qBTz6T6kR for ; Fri, 06 Mar 2026 17:15: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSCjB2gTXz3GY4 for ; Fri, 06 Mar 2026 17: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=1772817342; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cZfF2ci3Dg3ycRWHLXapGNliX8+xyuApMMuLUrnpj3w=; b=AfXTU/rwwdjEqgJVn9AJUnvwbRpQXC159yYgz1CyO19BHesil+OOoSs1di7JoLd/0osBSc kKXpr4+qE7JrBW/GaSSALKrOIxD114PYi1q0plMkm0SbYFafW2+w1l/WEabh2NpYBFJKVl KHAOq+gscAGp8DBVRdU3ke+td8WlcVPza329uSR1Mv3WH29Q8LJW8Yd9AyJlKTvHk4NRiW JIxO0MR7gUAvMp3pZYCYMhOvTXnHS1kyAB9znFVJQ9H7DHZfnap84E99SsctBS4V9pLZR2 CKewZzuowiZIDiVAoD8o1MHyjwxl6BfsPtXK3721wZK5W3B9ywSG264ltVSngA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772817342; a=rsa-sha256; cv=none; b=GxmD8lO+nV4Fl60BHutTl1JwdsP0/3vjueqD/p/g1uZ3her1CU6sChIkoEQDjWqayrxzhI aanmIuvYT6YiNp5RandeOEBDR6tt9UWif68qHeixRoCCWva+lOtLKbGtNJiPR9FbI3TKJ3 AoYZe98gv6pD5HAeaNNuKFYgv7nSGwQgZ1RkL0/2Uo8S1Dzsx1REDjjcQu+6Ic10BXvp8O H45w5pou+iEsWy5MGLYddbsqUu4RToTEqVFurWGw+I/RgbsdA9T/38a6NWFUFOtSmG/p63 PHQQkhoH/A6V2+qDmpXVsZCNeS+hOHorDEeS3jq9r689Bl89xtCZT6MJ1YlD4w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772817342; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cZfF2ci3Dg3ycRWHLXapGNliX8+xyuApMMuLUrnpj3w=; b=I5oarVPo92rzidRrgCchwXEnrHsPSnyA2T6FWpdO9M9rh9isc6l1SicKjS6515W+ANeAxo nLWXYXelVLPANEU/u0C8Lh7kpIyvNgHbBNbf5wo9reAZdW2N6fFgrLYAe/V/X+B+J6MiiL fU6c1v8bxqlxVjeTmPLkYoZQc6ba4JTAWSvrc0wBvOPxHtidAO5rvpXOIXPxRYFHUFpMfd eqWj7mqLhNOW//3706HNO+EcPp3pOZLj9qCiX0hL1qqj/E0wp5O71UqqTjLInE8jzmdpqP 5LHRrmP72nR70lZNFfQ7rxnfbUWazsvtJdwFVG2agWLfUOXl24CF8V6WfGqRRg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSCjB2FhyzXMS for ; Fri, 06 Mar 2026 17:15:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3e2e4 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 17:15:42 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: af2c7d9f6452 - main - style.9: Encourage style changes when doing significant modifications List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: af2c7d9f6452f2281a832b03375910f99230f924 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 17:15:42 +0000 Message-Id: <69ab0bbe.3e2e4.5681b2ed@gitrepo.freebsd.org> The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=af2c7d9f6452f2281a832b03375910f99230f924 commit af2c7d9f6452f2281a832b03375910f99230f924 Author: Olivier Certner AuthorDate: 2025-10-03 12:05:46 +0000 Commit: Olivier Certner CommitDate: 2026-03-06 17:14:35 +0000 style.9: Encourage style changes when doing significant modifications The rule of allowing style changes when about half or more of a file (or group of files), coupled with the advice of avoiding stylistic changes, could be interpreted as forbidding most style changes, even in heavily modified functions. In order to rule out that interpretation and ease transition towards our prescribed style: 1. Clarify that avoiding stylistic changes concerns only "standalone" ones. 2. Actually encourage changing the style, and extend the cases where it is explicitly allowed to do so to any single logical unit as little as a function, keeping the existing "about half" of modified code as a rule of thumb. When point 2 above applies, encourage to commit pure style changes separately, and to add style-only commits to '.git-blame-ignore-revs'. Add a specific note ruling out "horizontal" style changes spanning unrelated directories in the whole tree, which make the merge (MFC) process more difficult. While here, be slightly more stringent on new kernel code. While here, regroup the paragraphs talking about style, and put them at the end (before the recent C++ section). While here, rephrase the requirement on third-party maintained code to be slightly less stringent. Reviewed by: jhb, imp Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52885 --- share/man/man9/style.9 | 52 +++++++++++++++++++++++++++++--------------------- 1 file changed, 30 insertions(+), 22 deletions(-) diff --git a/share/man/man9/style.9 b/share/man/man9/style.9 index c9c3af23864a..65636a8af828 100644 --- a/share/man/man9/style.9 +++ b/share/man/man9/style.9 @@ -446,14 +446,6 @@ Functions that are used locally in more than one module go into a separate header file, e.g., .Qq Pa extern.h . .Pp -In general code can be considered -.Dq "new code" -when it makes up about 50% or more of the file(s) involved. -This is enough -to break precedents in the existing code and use the current -.Nm -guidelines. -.Pp The kernel has a name associated with parameter types, e.g., in the kernel use: .Bd -literal @@ -877,20 +869,6 @@ That is, without regard to whether an option takes arguments or not. The alphabetical ordering should take into account the case ordering shown above. .Pp -New core kernel code should be reasonably compliant with the -.Nm -guides. -The guidelines for third-party maintained modules and device drivers are more -relaxed but at a minimum should be internally consistent with their style. -.Pp -Stylistic changes (including whitespace changes) are hard on the source -repository and are to be avoided without good reason. -Code that is approximately -.Fx -KNF -.Nm -compliant in the repository must not diverge from compliance. -.Pp Whenever possible, code should be run through a code checker (e.g., various static analyzers or .Nm cc Fl Wall ) @@ -917,6 +895,36 @@ Only use the annotation for the entire if statement, rather than individual clauses. Do not add these annotations without empirical evidence of the likelihood of the branch. +.Pp +New core kernel code should be compliant with the +.Nm +guides. +The guidelines for third-party maintained modules and device drivers are more +relaxed. +Their code is expected to at least be internally consistent with their style. +.Pp +Stylistic changes, including whitespace ones, complicate the work of downstream +consumers and may impair developers' ability to trace the history of some +changes. +Such standalone must be avoided, and should not span unrelated directories as +this increases the chances of conflicts when merging to stable and release +branches (MFCs). +On the other hand, when a significant portion, usually about a half, of some +logical unit of code, be it a function, group of functions, file or group of +files, is going to be modified, developers are encouraged to amend the style of +the whole unit as described in this document. +In this case, style changes to otherwise unmodified code should be committed +separately. +Style-only commits should be added to the file +.Pa .git-blame-ignore-revs +at the top of the source repository to hide them from +.Ql git blame . +Comments in this file indicate how to use it. +Code that is approximately +.Fx +KNF +.Nm +compliant in the repository must not diverge from compliance. .Ss C++ KNF style was originally defined as a style for C. C++ introduces several new idioms which do not have an existing corollary From nobody Fri Mar 6 17:32:11 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSD4J4rB7z6T7rZ for ; Fri, 06 Mar 2026 17:32: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSD4J2tZgz3J47 for ; Fri, 06 Mar 2026 17:32:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772818336; 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; bh=V+gGyl7+/BuByTo3n8k02p0/pOCIz6uhVYsYn2QMZDY=; b=DpgWqmEWurlKo+LCr94SpbJ5Cfn6VUS9F4Y1vsufia2nW4un2AJ9eHD/DqYOUoGwWO38py o+Ngbfyj/UstyEI2d1pOgpRK640knlK5VseQOzTcZH50AoUAdUcFkYeU5IYAy5E+Ui1BAc vDHTqIQ0nFvosCpDvriPBE6C4Hpnsm9V/vCIC1xwf8QnDbtq3GAm6hIw+PzD7+cjjZw97h uX6lBiodC90IE2PSdbijokvCGpOOSfrFdagYBNlhaqP/FD64ZDzjpniE/d+I/4Xz0YvN/e zWHk32URpeZfeg8SfsuFjkYnn9iMKkeVZJAAvdkShoFvwN2oSypyt4mrzzRUNQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772818336; a=rsa-sha256; cv=none; b=GbGMg1NaDt8qlv5af8SF5HKfxM4TL5ym7zyYwzOGSC33xdo7aTs9CqlBWbXuNK5c2l1huT 5UBv05SN43qaxf9gg5ig5LDr0z9UN+v1D+UrE8eCipKRnSlKsCP80lnJvIMD6VXHc3F7kp HCnuEG7gNKy/YfCWytRcxwuoosEg4rInSZnuwlDDw6qSO+q4/20wFOwlu0g1eyVSgy0V7J KqDBp2eyPgYvp4hS9K+yHdqBGjSrKzubFi16Eg5yxSd4uRFYjWcefjE+uZ2pKRe4pfiit7 /7IvHPsqpdyPUsqvrFOJ7Jm2wjNHBzXoyW9HGx4FfGKBcqYys5/vpEn6UXM/3w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772818336; 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; bh=V+gGyl7+/BuByTo3n8k02p0/pOCIz6uhVYsYn2QMZDY=; b=brsaheB+XJL5rF36Jp4zrB2oNVPcJ/JSdxCUctmUzP0KbR/yqKwiI39tVGmUqNfTg8D++X 2Djh17tsRoCmeFC+Ndb5hnl60rOyOmJTFzHEcq64MHZzSrBaVEHuOxjGwyX55WCwWefAi3 DMgQ5NnXjsMVjuWayxdGs51eveV4W4KAAqhpiT8c+Zwvsf6I7gzKyv1s4rc2K4618/LhED 7MRFfjUZSHq/0V8LJrv4Lm6X3s1wPeYFzKp7ZlAqjvTiZxPoetspQtabnpu+jPfwKGdQhm eUHNRii8j5TpFeZQrL9OiIsiqT4JAwwGOdRxAUc8VbVof9wJez/DMGFCOKy36g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSD4J2TMmzYNH for ; Fri, 06 Mar 2026 17:32:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 18db4 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 17:32:11 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Matt Delco From: Alexander Ziaee Subject: git: b3d9e5013f3e - main - nvme: Don't active memory space until all BARs are configured List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: b3d9e5013f3e5016ffbd3d3d6091194658af2b92 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 17:32:11 +0000 Message-Id: <69ab0f9b.18db4.5196b3f7@gitrepo.freebsd.org> The branch main has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=b3d9e5013f3e5016ffbd3d3d6091194658af2b92 commit b3d9e5013f3e5016ffbd3d3d6091194658af2b92 Author: Matt Delco AuthorDate: 2026-03-06 17:23:03 +0000 Commit: Alexander Ziaee CommitDate: 2026-03-06 17:28:41 +0000 nvme: Don't active memory space until all BARs are configured In the current current behavior the 2nd and 3rd BARs can be activated when they're configured with address zero. This change defers the activation of all BARs until after they've all been configured with an address. This enables FreeBSD on Google Compute Engine C4-LSSD Machines. Sponsored by: Google Tested by: NetApp (previous version) Reviewed by: gallatin, imp Discussed with: jrtc27 (improved error reporting) Differential Revision: https://reviews.freebsd.org/D55541 --- sys/dev/nvme/nvme_pci.c | 44 +++++++++++++++++++++++++++++++++++++------- 1 file changed, 37 insertions(+), 7 deletions(-) diff --git a/sys/dev/nvme/nvme_pci.c b/sys/dev/nvme/nvme_pci.c index 5784c6d1be96..74191df52058 100644 --- a/sys/dev/nvme/nvme_pci.c +++ b/sys/dev/nvme/nvme_pci.c @@ -151,24 +151,28 @@ nvme_pci_probe (device_t device) static int nvme_ctrlr_allocate_bar(struct nvme_controller *ctrlr) { + int error; + ctrlr->resource_id = PCIR_BAR(0); ctrlr->msix_table_resource_id = -1; ctrlr->msix_table_resource = NULL; ctrlr->msix_pba_resource_id = -1; ctrlr->msix_pba_resource = NULL; + /* + * Using RF_ACTIVE will set the Memory Space bit in the PCI command register. + * The remaining BARs will get mapped in before they've been programmed with + * an address. To avoid this we'll not set this flag and instead call + * bus_activate_resource() after all the BARs have been programmed. + */ ctrlr->resource = bus_alloc_resource_any(ctrlr->dev, SYS_RES_MEMORY, - &ctrlr->resource_id, RF_ACTIVE); + &ctrlr->resource_id, 0); if (ctrlr->resource == NULL) { nvme_printf(ctrlr, "unable to allocate pci resource\n"); return (ENOMEM); } - ctrlr->bus_tag = rman_get_bustag(ctrlr->resource); - ctrlr->bus_handle = rman_get_bushandle(ctrlr->resource); - ctrlr->regs = (struct nvme_registers *)ctrlr->bus_handle; - /* * The NVMe spec allows for the MSI-X tables to be placed behind * BAR 4 and/or 5, separate from the control/doorbell registers. @@ -180,7 +184,7 @@ nvme_ctrlr_allocate_bar(struct nvme_controller *ctrlr) if (ctrlr->msix_table_resource_id >= 0 && ctrlr->msix_table_resource_id != ctrlr->resource_id) { ctrlr->msix_table_resource = bus_alloc_resource_any(ctrlr->dev, - SYS_RES_MEMORY, &ctrlr->msix_table_resource_id, RF_ACTIVE); + SYS_RES_MEMORY, &ctrlr->msix_table_resource_id, 0); if (ctrlr->msix_table_resource == NULL) { nvme_printf(ctrlr, "unable to allocate msi-x table resource\n"); return (ENOMEM); @@ -190,13 +194,39 @@ nvme_ctrlr_allocate_bar(struct nvme_controller *ctrlr) ctrlr->msix_pba_resource_id != ctrlr->resource_id && ctrlr->msix_pba_resource_id != ctrlr->msix_table_resource_id) { ctrlr->msix_pba_resource = bus_alloc_resource_any(ctrlr->dev, - SYS_RES_MEMORY, &ctrlr->msix_pba_resource_id, RF_ACTIVE); + SYS_RES_MEMORY, &ctrlr->msix_pba_resource_id, 0); if (ctrlr->msix_pba_resource == NULL) { nvme_printf(ctrlr, "unable to allocate msi-x pba resource\n"); return (ENOMEM); } } + error = bus_activate_resource(ctrlr->dev, ctrlr->resource); + if (error) { + nvme_printf(ctrlr, "unable to activate pci resource: %d\n", error); + return (error); + } + if (ctrlr->msix_table_resource != NULL) { + error = bus_activate_resource(ctrlr->dev, ctrlr->msix_table_resource); + if (error) { + nvme_printf(ctrlr, "unable to activate msi-x table resource: %d\n", + error); + return (error); + } + } + if (ctrlr->msix_pba_resource != NULL) { + error = bus_activate_resource(ctrlr->dev, ctrlr->msix_pba_resource); + if (error) { + nvme_printf(ctrlr, "unable to activate msi-x pba resource: %d\n", + error); + return (error); + } + } + + ctrlr->bus_tag = rman_get_bustag(ctrlr->resource); + ctrlr->bus_handle = rman_get_bushandle(ctrlr->resource); + ctrlr->regs = (struct nvme_registers *)ctrlr->bus_handle; + return (0); } From nobody Fri Mar 6 19:51:33 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSH923FgRz6TMDr for ; Fri, 06 Mar 2026 19:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSH922f70z3WYy for ; Fri, 06 Mar 2026 19:51:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772826694; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kBRlFisaR/IeGfO1DiIrNtxg4IQnGiTmm/dyU0UuNxY=; b=sr2uYvjFWs0ir4UnrXa6sGbirXYlBRXhscWzLOxVxuWvNUbK3xS0MEDB3OskZc+T/VJmah R0TQi0H+LzF6hUX32yI4RMAWGj2qWrXbS6by2yqzyhixkOjSlpcdolCd0C4Ic+VZvJJ6VC 3nFbpPy2Gv6XVrk9eQ82C7e+1a//OuEHwaikXduyQSJi39yKvzPPEH8vWius9cpQgb2m/n 01AKQ6laaFqjAbWKGIKvLdAJ4LiWSLW7KiJn9swrAbFFgZ+YCy+ttn3wXeIIeNUlZjdRHv W/3B22Orb/rQPQ3yA/0NEp24qW2P+wiEc2t5KD1X/dFVX2JKO5F6hS5vy3xvCg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772826694; a=rsa-sha256; cv=none; b=Y9nHojx57JJFcVyYDzzJLdbBEIi1gGdnO1+PDKD24ERp6uHlxmMwVf2DPv/Ti6meBv2ATA Gh1pX8Bm4yL/JiwAFyxUi3c+6szjwF+FaJDsY3DXUwxCrjMHupPwpEFtN7wW3zIvkn3JtA L8l00EeEIIylsH6DfvygN6/SyIEyZ4aHNflBauKj4PEdAoxyiRsLVSPEcqsyCJFD+JFd/Y +QeCTugP64z4tM3fOnTyy6MSolj73OpY/atyM7eX6/s4hnm+XAKXxasQNAK1Vac5BrK7Yp bYwEWzdomteIffc5MpC71iYCNclP/6t/zJvDDUXL3INmyqgTFCAfI21Drby1iw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772826694; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kBRlFisaR/IeGfO1DiIrNtxg4IQnGiTmm/dyU0UuNxY=; b=EMB+MKJY+xyy1zLa27HBlDfDdC6CcErLW0hgSg4+CwkNbFbzCDzI8R4xuMnmU0ckBR++bZ fVgAoNztx/IjtZNfGDWGqdGjaFKTX05zcKuPcdTL7C75G7YyXZlNic9IXwIaSZqUsBZlpD 9cviCq7kia+/+E9mL2m5waV9Mtj6Eai7zMtojbn43skhGcIi2DDaQ4jazozvpyJb8hx7xr v+dE1aUoU4VK2Hmg1I3MYVy4U8vdGx3HdtYbSMEXbRLcbd3dBp5VYRBJqm/VCD3vqV26Xh tkjzLTnFTdM+HLlZoMomJO/DnqNcCPV0hUDFyQKfsruPbQJ24t9MQR1lbKJ0Pw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSH921zrkzcyB for ; Fri, 06 Mar 2026 19:51:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 24a35 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 19:51:33 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 95dd8736f846 - main - iwlwifi: update Intel's mvm/mld drivers List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 95dd8736f846dee1208fe4c306caf1b0baf3caba Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 19:51:33 +0000 Message-Id: <69ab3045.24a35.69e42842@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=95dd8736f846dee1208fe4c306caf1b0baf3caba commit 95dd8736f846dee1208fe4c306caf1b0baf3caba Merge: b3d9e5013f3e d2b84ec15626 Author: Bjoern A. Zeeb AuthorDate: 2026-03-06 10:45:07 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-06 19:48:01 +0000 iwlwifi: update Intel's mvm/mld drivers This version is based on git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 05f7e89ab9731565d8a62e3b5d1ec206485eeb0b ( tag: v6.19 ). Sponsored by: The FreeBSD Foundation MFC after: 3 days sys/contrib/dev/iwlwifi/cfg/22000.c | 1 - sys/contrib/dev/iwlwifi/cfg/8000.c | 1 - sys/contrib/dev/iwlwifi/cfg/9000.c | 1 - sys/contrib/dev/iwlwifi/cfg/ax210.c | 1 - sys/contrib/dev/iwlwifi/cfg/bz.c | 20 +- sys/contrib/dev/iwlwifi/cfg/dr.c | 14 +- sys/contrib/dev/iwlwifi/cfg/rf-fm.c | 1 + sys/contrib/dev/iwlwifi/cfg/rf-gf.c | 22 +- sys/contrib/dev/iwlwifi/cfg/rf-hr.c | 2 +- sys/contrib/dev/iwlwifi/cfg/rf-pe.c | 1 + sys/contrib/dev/iwlwifi/cfg/rf-wh.c | 24 + sys/contrib/dev/iwlwifi/cfg/sc.c | 19 +- sys/contrib/dev/iwlwifi/fw/acpi.c | 6 +- sys/contrib/dev/iwlwifi/fw/acpi.h | 3 +- sys/contrib/dev/iwlwifi/fw/api/alive.h | 2 +- sys/contrib/dev/iwlwifi/fw/api/cmdhdr.h | 4 +- sys/contrib/dev/iwlwifi/fw/api/coex.h | 4 +- sys/contrib/dev/iwlwifi/fw/api/commands.h | 2 +- sys/contrib/dev/iwlwifi/fw/api/d3.h | 113 +- sys/contrib/dev/iwlwifi/fw/api/datapath.h | 5 + sys/contrib/dev/iwlwifi/fw/api/dbg-tlv.h | 14 +- sys/contrib/dev/iwlwifi/fw/api/debug.h | 2 +- sys/contrib/dev/iwlwifi/fw/api/location.h | 8 +- sys/contrib/dev/iwlwifi/fw/api/mac-cfg.h | 3 + sys/contrib/dev/iwlwifi/fw/api/nvm-reg.h | 134 +- sys/contrib/dev/iwlwifi/fw/api/offload.h | 2 +- sys/contrib/dev/iwlwifi/fw/api/power.h | 39 +- sys/contrib/dev/iwlwifi/fw/api/rs.h | 35 + sys/contrib/dev/iwlwifi/fw/api/rx.h | 286 ++++ sys/contrib/dev/iwlwifi/fw/api/scan.h | 78 +- sys/contrib/dev/iwlwifi/fw/api/sta.h | 6 +- sys/contrib/dev/iwlwifi/fw/api/stats.h | 39 +- sys/contrib/dev/iwlwifi/fw/api/tx.h | 2 +- sys/contrib/dev/iwlwifi/fw/dbg.c | 43 +- sys/contrib/dev/iwlwifi/fw/dump.c | 54 +- sys/contrib/dev/iwlwifi/fw/error-dump.h | 7 +- sys/contrib/dev/iwlwifi/fw/file.h | 74 +- sys/contrib/dev/iwlwifi/fw/img.h | 12 +- sys/contrib/dev/iwlwifi/fw/pnvm.c | 81 +- sys/contrib/dev/iwlwifi/fw/regulatory.c | 79 +- sys/contrib/dev/iwlwifi/fw/regulatory.h | 1 - sys/contrib/dev/iwlwifi/fw/runtime.h | 24 +- sys/contrib/dev/iwlwifi/fw/uefi.c | 7 +- sys/contrib/dev/iwlwifi/iwl-config.h | 51 +- sys/contrib/dev/iwlwifi/iwl-dbg-tlv.h | 4 +- sys/contrib/dev/iwlwifi/iwl-drv.c | 72 +- sys/contrib/dev/iwlwifi/iwl-drv.h | 12 +- sys/contrib/dev/iwlwifi/iwl-io.c | 96 +- sys/contrib/dev/iwlwifi/iwl-io.h | 2 +- sys/contrib/dev/iwlwifi/iwl-modparams.h | 4 +- sys/contrib/dev/iwlwifi/iwl-nvm-parse.c | 82 +- sys/contrib/dev/iwlwifi/iwl-nvm-parse.h | 91 +- sys/contrib/dev/iwlwifi/iwl-op-mode.h | 1 + sys/contrib/dev/iwlwifi/iwl-trans.c | 79 +- sys/contrib/dev/iwlwifi/iwl-trans.h | 87 +- sys/contrib/dev/iwlwifi/mld/constants.h | 2 + sys/contrib/dev/iwlwifi/mld/d3.c | 557 ++++--- sys/contrib/dev/iwlwifi/mld/debugfs.c | 8 +- sys/contrib/dev/iwlwifi/mld/fw.c | 14 +- sys/contrib/dev/iwlwifi/mld/iface.c | 54 +- sys/contrib/dev/iwlwifi/mld/iface.h | 5 +- sys/contrib/dev/iwlwifi/mld/key.c | 38 + sys/contrib/dev/iwlwifi/mld/key.h | 7 + sys/contrib/dev/iwlwifi/mld/link.c | 50 +- sys/contrib/dev/iwlwifi/mld/link.h | 2 + sys/contrib/dev/iwlwifi/mld/mac80211.c | 124 +- sys/contrib/dev/iwlwifi/mld/mld.c | 5 + sys/contrib/dev/iwlwifi/mld/mld.h | 25 +- sys/contrib/dev/iwlwifi/mld/mlo.c | 122 +- sys/contrib/dev/iwlwifi/mld/notif.c | 5 +- sys/contrib/dev/iwlwifi/mld/ptp.c | 7 + sys/contrib/dev/iwlwifi/mld/regulatory.c | 28 +- sys/contrib/dev/iwlwifi/mld/roc.c | 14 +- sys/contrib/dev/iwlwifi/mld/rx.c | 1717 ++++++++++++---------- sys/contrib/dev/iwlwifi/mld/rx.h | 5 +- sys/contrib/dev/iwlwifi/mld/scan.c | 4 +- sys/contrib/dev/iwlwifi/mld/sta.c | 10 +- sys/contrib/dev/iwlwifi/mld/stats.c | 11 +- sys/contrib/dev/iwlwifi/mld/tlc.c | 75 +- sys/contrib/dev/iwlwifi/mvm/coex.c | 131 -- sys/contrib/dev/iwlwifi/mvm/constants.h | 20 +- sys/contrib/dev/iwlwifi/mvm/d3.c | 398 +---- sys/contrib/dev/iwlwifi/mvm/debugfs-vif.c | 94 -- sys/contrib/dev/iwlwifi/mvm/debugfs.c | 3 +- sys/contrib/dev/iwlwifi/mvm/fw.c | 17 +- sys/contrib/dev/iwlwifi/mvm/link.c | 809 ---------- sys/contrib/dev/iwlwifi/mvm/mac-ctxt.c | 51 +- sys/contrib/dev/iwlwifi/mvm/mac80211.c | 124 +- sys/contrib/dev/iwlwifi/mvm/mld-mac80211.c | 141 +- sys/contrib/dev/iwlwifi/mvm/mld-sta.c | 2 - sys/contrib/dev/iwlwifi/mvm/mvm.h | 136 +- sys/contrib/dev/iwlwifi/mvm/ops.c | 53 - sys/contrib/dev/iwlwifi/mvm/phy-ctxt.c | 24 +- sys/contrib/dev/iwlwifi/mvm/ptp.c | 7 + sys/contrib/dev/iwlwifi/mvm/rx.c | 135 +- sys/contrib/dev/iwlwifi/mvm/rxmq.c | 23 +- sys/contrib/dev/iwlwifi/mvm/scan.c | 101 -- sys/contrib/dev/iwlwifi/mvm/sta.c | 89 -- sys/contrib/dev/iwlwifi/mvm/sta.h | 24 - sys/contrib/dev/iwlwifi/mvm/time-event.c | 17 +- sys/contrib/dev/iwlwifi/mvm/tx.c | 8 +- sys/contrib/dev/iwlwifi/mvm/utils.c | 22 +- sys/contrib/dev/iwlwifi/pcie/drv.c | 19 +- sys/contrib/dev/iwlwifi/pcie/gen1_2/internal.h | 53 +- sys/contrib/dev/iwlwifi/pcie/gen1_2/trans-gen2.c | 6 +- sys/contrib/dev/iwlwifi/pcie/gen1_2/trans.c | 252 +++- sys/contrib/dev/iwlwifi/pcie/gen1_2/tx.c | 5 +- sys/contrib/dev/iwlwifi/tests/Makefile | 2 +- sys/contrib/dev/iwlwifi/tests/devinfo.c | 29 + 109 files changed, 3118 insertions(+), 4423 deletions(-) diff --cc sys/contrib/dev/iwlwifi/fw/api/rx.h index 2024b11c80d0,000000000000..dbac7de00142 mode 100644,000000..100644 --- a/sys/contrib/dev/iwlwifi/fw/api/rx.h +++ b/sys/contrib/dev/iwlwifi/fw/api/rx.h @@@ -1,1059 -1,0 +1,1345 @@@ +/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */ +/* + * Copyright (C) 2012-2014, 2018-2025 Intel Corporation + * Copyright (C) 2013-2015 Intel Mobile Communications GmbH + * Copyright (C) 2015-2017 Intel Deutschland GmbH + */ +#ifndef __iwl_fw_api_rx_h__ +#define __iwl_fw_api_rx_h__ + +/* API for pre-9000 hardware */ + +#define IWL_RX_INFO_PHY_CNT 8 +#define IWL_RX_INFO_ENERGY_ANT_ABC_IDX 1 +#define IWL_RX_INFO_ENERGY_ANT_A_MSK 0x000000ff +#define IWL_RX_INFO_ENERGY_ANT_B_MSK 0x0000ff00 +#define IWL_RX_INFO_ENERGY_ANT_A_POS 0 +#define IWL_RX_INFO_ENERGY_ANT_B_POS 8 +#define IWL_RX_INFO_ENERGY_ANT_C_POS 16 + +enum iwl_mac_context_info { + MAC_CONTEXT_INFO_NONE, + MAC_CONTEXT_INFO_GSCAN, +}; + +/** + * struct iwl_rx_phy_info - phy info + * (REPLY_RX_PHY_CMD = 0xc0) + * @non_cfg_phy_cnt: non configurable DSP phy data byte count + * @cfg_phy_cnt: configurable DSP phy data byte count + * @stat_id: configurable DSP phy data set ID + * @reserved1: reserved + * @system_timestamp: GP2 at on air rise + * @timestamp: TSF at on air rise + * @beacon_time_stamp: beacon at on-air rise + * @phy_flags: general phy flags: band, modulation, ... + * @channel: channel number + * @non_cfg_phy: for various implementations of non_cfg_phy + * @rate_n_flags: RATE_MCS_* + * @byte_count: frame's byte-count + * @frame_time: frame's time on the air, based on byte count and frame rate + * calculation + * @mac_active_msk: what MACs were active when the frame was received + * @mac_context_info: additional info on the context in which the frame was + * received as defined in &enum iwl_mac_context_info + * + * Before each Rx, the device sends this data. It contains PHY information + * about the reception of the packet. + */ +struct iwl_rx_phy_info { + u8 non_cfg_phy_cnt; + u8 cfg_phy_cnt; + u8 stat_id; + u8 reserved1; + __le32 system_timestamp; + __le64 timestamp; + __le32 beacon_time_stamp; + __le16 phy_flags; + __le16 channel; + __le32 non_cfg_phy[IWL_RX_INFO_PHY_CNT]; + __le32 rate_n_flags; + __le32 byte_count; + u8 mac_active_msk; + u8 mac_context_info; + __le16 frame_time; +} __packed; + +/* + * TCP offload Rx assist info + * + * bits 0:3 - reserved + * bits 4:7 - MIC CRC length + * bits 8:12 - MAC header length + * bit 13 - Padding indication + * bit 14 - A-AMSDU indication + * bit 15 - Offload enabled + */ +enum iwl_csum_rx_assist_info { + CSUM_RXA_RESERVED_MASK = 0x000f, + CSUM_RXA_MICSIZE_MASK = 0x00f0, + CSUM_RXA_HEADERLEN_MASK = 0x1f00, + CSUM_RXA_PADD = BIT(13), + CSUM_RXA_AMSDU = BIT(14), + CSUM_RXA_ENA = BIT(15) +}; + +/** + * struct iwl_rx_mpdu_res_start - phy info + * @byte_count: byte count of the frame + * @assist: see &enum iwl_csum_rx_assist_info + */ +struct iwl_rx_mpdu_res_start { + __le16 byte_count; + __le16 assist; +} __packed; /* _RX_MPDU_RES_START_API_S_VER_2 */ + +/** + * enum iwl_rx_phy_flags - to parse %iwl_rx_phy_info phy_flags + * @RX_RES_PHY_FLAGS_BAND_24: true if the packet was received on 2.4 band + * @RX_RES_PHY_FLAGS_MOD_CCK: modulation is CCK + * @RX_RES_PHY_FLAGS_SHORT_PREAMBLE: true if packet's preamble was short + * @RX_RES_PHY_FLAGS_NARROW_BAND: narrow band (<20 MHz) receive + * @RX_RES_PHY_FLAGS_ANTENNA: antenna on which the packet was received + * @RX_RES_PHY_FLAGS_ANTENNA_POS: antenna bit position + * @RX_RES_PHY_FLAGS_AGG: set if the packet was part of an A-MPDU + * @RX_RES_PHY_FLAGS_OFDM_HT: The frame was an HT frame + * @RX_RES_PHY_FLAGS_OFDM_GF: The frame used GF preamble + * @RX_RES_PHY_FLAGS_OFDM_VHT: The frame was a VHT frame + */ +enum iwl_rx_phy_flags { + RX_RES_PHY_FLAGS_BAND_24 = BIT(0), + RX_RES_PHY_FLAGS_MOD_CCK = BIT(1), + RX_RES_PHY_FLAGS_SHORT_PREAMBLE = BIT(2), + RX_RES_PHY_FLAGS_NARROW_BAND = BIT(3), + RX_RES_PHY_FLAGS_ANTENNA = (0x7 << 4), + RX_RES_PHY_FLAGS_ANTENNA_POS = 4, + RX_RES_PHY_FLAGS_AGG = BIT(7), + RX_RES_PHY_FLAGS_OFDM_HT = BIT(8), + RX_RES_PHY_FLAGS_OFDM_GF = BIT(9), + RX_RES_PHY_FLAGS_OFDM_VHT = BIT(10), +}; + +/** + * enum iwl_mvm_rx_status - written by fw for each Rx packet + * @RX_MPDU_RES_STATUS_CRC_OK: CRC is fine + * @RX_MPDU_RES_STATUS_OVERRUN_OK: there was no RXE overflow + * @RX_MPDU_RES_STATUS_SRC_STA_FOUND: station was found + * @RX_MPDU_RES_STATUS_KEY_VALID: key was valid + * @RX_MPDU_RES_STATUS_ICV_OK: ICV is fine, if not, the packet is destroyed + * @RX_MPDU_RES_STATUS_MIC_OK: used for CCM alg only. TKIP MIC is checked + * in the driver. + * @RX_MPDU_RES_STATUS_TTAK_OK: TTAK is fine + * @RX_MPDU_RES_STATUS_MNG_FRAME_REPLAY_ERR: valid for alg = CCM_CMAC or + * alg = CCM only. Checks replay attack for 11w frames. + * @RX_MPDU_RES_STATUS_SEC_NO_ENC: this frame is not encrypted + * @RX_MPDU_RES_STATUS_SEC_WEP_ENC: this frame is encrypted using WEP + * @RX_MPDU_RES_STATUS_SEC_CCM_ENC: this frame is encrypted using CCM + * @RX_MPDU_RES_STATUS_SEC_TKIP_ENC: this frame is encrypted using TKIP + * @RX_MPDU_RES_STATUS_SEC_EXT_ENC: this frame is encrypted using extension + * algorithm + * @RX_MPDU_RES_STATUS_SEC_CMAC_GMAC_ENC: this frame is protected using + * CMAC or GMAC + * @RX_MPDU_RES_STATUS_SEC_ENC_ERR: this frame couldn't be decrypted + * @RX_MPDU_RES_STATUS_SEC_ENC_MSK: bitmask of the encryption algorithm + * @RX_MPDU_RES_STATUS_DEC_DONE: this frame has been successfully decrypted + * @RX_MPDU_RES_STATUS_CSUM_DONE: checksum was done by the hw + * @RX_MPDU_RES_STATUS_CSUM_OK: checksum found no errors + * @RX_MPDU_RES_STATUS_STA_ID_MSK: station ID mask + * @RX_MDPU_RES_STATUS_STA_ID_SHIFT: station ID bit shift + */ +enum iwl_mvm_rx_status { + RX_MPDU_RES_STATUS_CRC_OK = BIT(0), + RX_MPDU_RES_STATUS_OVERRUN_OK = BIT(1), + RX_MPDU_RES_STATUS_SRC_STA_FOUND = BIT(2), + RX_MPDU_RES_STATUS_KEY_VALID = BIT(3), + RX_MPDU_RES_STATUS_ICV_OK = BIT(5), + RX_MPDU_RES_STATUS_MIC_OK = BIT(6), + RX_MPDU_RES_STATUS_TTAK_OK = BIT(7), + RX_MPDU_RES_STATUS_MNG_FRAME_REPLAY_ERR = BIT(7), + RX_MPDU_RES_STATUS_SEC_NO_ENC = (0 << 8), + RX_MPDU_RES_STATUS_SEC_WEP_ENC = (1 << 8), + RX_MPDU_RES_STATUS_SEC_CCM_ENC = (2 << 8), + RX_MPDU_RES_STATUS_SEC_TKIP_ENC = (3 << 8), + RX_MPDU_RES_STATUS_SEC_EXT_ENC = (4 << 8), + RX_MPDU_RES_STATUS_SEC_CMAC_GMAC_ENC = (6 << 8), + RX_MPDU_RES_STATUS_SEC_ENC_ERR = (7 << 8), + RX_MPDU_RES_STATUS_SEC_ENC_MSK = (7 << 8), + RX_MPDU_RES_STATUS_DEC_DONE = BIT(11), + RX_MPDU_RES_STATUS_CSUM_DONE = BIT(16), + RX_MPDU_RES_STATUS_CSUM_OK = BIT(17), + RX_MDPU_RES_STATUS_STA_ID_SHIFT = 24, + RX_MPDU_RES_STATUS_STA_ID_MSK = 0x1f << RX_MDPU_RES_STATUS_STA_ID_SHIFT, +}; + +/* 9000 series API */ +enum iwl_rx_mpdu_mac_flags1 { + IWL_RX_MDPU_MFLG1_ADDRTYPE_MASK = 0x03, + IWL_RX_MPDU_MFLG1_MIC_CRC_LEN_MASK = 0xf0, + /* shift should be 4, but the length is measured in 2-byte + * words, so shifting only by 3 gives a byte result + */ + IWL_RX_MPDU_MFLG1_MIC_CRC_LEN_SHIFT = 3, +}; + +enum iwl_rx_mpdu_mac_flags2 { + /* in 2-byte words */ + IWL_RX_MPDU_MFLG2_HDR_LEN_MASK = 0x1f, + IWL_RX_MPDU_MFLG2_PAD = 0x20, + IWL_RX_MPDU_MFLG2_AMSDU = 0x40, +}; + +enum iwl_rx_mpdu_amsdu_info { + IWL_RX_MPDU_AMSDU_SUBFRAME_IDX_MASK = 0x7f, + IWL_RX_MPDU_AMSDU_LAST_SUBFRAME = 0x80, +}; + +enum iwl_rx_mpdu_mac_phy_band { + /* whether or not this is MAC or LINK depends on the API */ + IWL_RX_MPDU_MAC_PHY_BAND_MAC_MASK = 0x0f, + IWL_RX_MPDU_MAC_PHY_BAND_LINK_MASK = 0x0f, + IWL_RX_MPDU_MAC_PHY_BAND_PHY_MASK = 0x30, + IWL_RX_MPDU_MAC_PHY_BAND_BAND_MASK = 0xc0, +}; + +enum iwl_rx_l3_proto_values { + IWL_RX_L3_TYPE_NONE, + IWL_RX_L3_TYPE_IPV4, + IWL_RX_L3_TYPE_IPV4_FRAG, + IWL_RX_L3_TYPE_IPV6_FRAG, + IWL_RX_L3_TYPE_IPV6, + IWL_RX_L3_TYPE_IPV6_IN_IPV4, + IWL_RX_L3_TYPE_ARP, + IWL_RX_L3_TYPE_EAPOL, +}; + +#define IWL_RX_L3_PROTO_POS 4 + +enum iwl_rx_l3l4_flags { + IWL_RX_L3L4_IP_HDR_CSUM_OK = BIT(0), + IWL_RX_L3L4_TCP_UDP_CSUM_OK = BIT(1), + IWL_RX_L3L4_TCP_FIN_SYN_RST_PSH = BIT(2), + IWL_RX_L3L4_TCP_ACK = BIT(3), + IWL_RX_L3L4_L3_PROTO_MASK = 0xf << IWL_RX_L3_PROTO_POS, + IWL_RX_L3L4_L4_PROTO_MASK = 0xf << 8, + IWL_RX_L3L4_RSS_HASH_MASK = 0xf << 12, +}; + +enum iwl_rx_mpdu_status { + IWL_RX_MPDU_STATUS_CRC_OK = BIT(0), + IWL_RX_MPDU_STATUS_OVERRUN_OK = BIT(1), + IWL_RX_MPDU_STATUS_SRC_STA_FOUND = BIT(2), + IWL_RX_MPDU_STATUS_KEY_VALID = BIT(3), + IWL_RX_MPDU_STATUS_ICV_OK = BIT(5), + IWL_RX_MPDU_STATUS_MIC_OK = BIT(6), + IWL_RX_MPDU_RES_STATUS_TTAK_OK = BIT(7), + /* overlayed since IWL_UCODE_TLV_API_DEPRECATE_TTAK */ + IWL_RX_MPDU_STATUS_REPLAY_ERROR = BIT(7), + IWL_RX_MPDU_STATUS_SEC_MASK = 0x7 << 8, + IWL_RX_MPDU_STATUS_SEC_UNKNOWN = IWL_RX_MPDU_STATUS_SEC_MASK, + IWL_RX_MPDU_STATUS_SEC_NONE = 0x0 << 8, + IWL_RX_MPDU_STATUS_SEC_WEP = 0x1 << 8, + IWL_RX_MPDU_STATUS_SEC_CCM = 0x2 << 8, + IWL_RX_MPDU_STATUS_SEC_TKIP = 0x3 << 8, + IWL_RX_MPDU_STATUS_SEC_EXT_ENC = 0x4 << 8, + IWL_RX_MPDU_STATUS_SEC_GCM = 0x5 << 8, +#if defined(__FreeBSD__) + IWL_RX_MPDU_STATUS_SEC_ENC_ERR = 0x7 << 8, +#endif + IWL_RX_MPDU_STATUS_DECRYPTED = BIT(11), + IWL_RX_MPDU_STATUS_ROBUST_MNG_FRAME = BIT(15), + + IWL_RX_MPDU_STATUS_DUPLICATE = BIT(22), + + IWL_RX_MPDU_STATUS_STA_ID = 0x1f000000, +}; + +#define IWL_RX_REORDER_DATA_INVALID_BAID 0x7f + +enum iwl_rx_mpdu_reorder_data { + IWL_RX_MPDU_REORDER_NSSN_MASK = 0x00000fff, + IWL_RX_MPDU_REORDER_SN_MASK = 0x00fff000, + IWL_RX_MPDU_REORDER_SN_SHIFT = 12, + IWL_RX_MPDU_REORDER_BAID_MASK = 0x7f000000, + IWL_RX_MPDU_REORDER_BAID_SHIFT = 24, + IWL_RX_MPDU_REORDER_BA_OLD_SN = 0x80000000, +}; + +enum iwl_rx_mpdu_phy_info { ++ IWL_RX_MPDU_PHY_EOF_INDICATION = BIT(0), + IWL_RX_MPDU_PHY_AMPDU = BIT(5), + IWL_RX_MPDU_PHY_AMPDU_TOGGLE = BIT(6), + IWL_RX_MPDU_PHY_SHORT_PREAMBLE = BIT(7), + /* short preamble is only for CCK, for non-CCK overridden by this */ + IWL_RX_MPDU_PHY_NCCK_ADDTL_NTFY = BIT(7), + IWL_RX_MPDU_PHY_TSF_OVERLOAD = BIT(8), +}; + +enum iwl_rx_mpdu_mac_info { + IWL_RX_MPDU_PHY_MAC_INDEX_MASK = 0x0f, + IWL_RX_MPDU_PHY_PHY_INDEX_MASK = 0xf0, +}; + +/* TSF overload low dword */ +enum iwl_rx_phy_he_data0 { + /* info type: HE any */ + IWL_RX_PHY_DATA0_HE_BEAM_CHNG = 0x00000001, + IWL_RX_PHY_DATA0_HE_UPLINK = 0x00000002, + IWL_RX_PHY_DATA0_HE_BSS_COLOR_MASK = 0x000000fc, + IWL_RX_PHY_DATA0_HE_SPATIAL_REUSE_MASK = 0x00000f00, + /* 1 bit reserved */ + IWL_RX_PHY_DATA0_HE_TXOP_DUR_MASK = 0x000fe000, + IWL_RX_PHY_DATA0_HE_LDPC_EXT_SYM = 0x00100000, + IWL_RX_PHY_DATA0_HE_PRE_FEC_PAD_MASK = 0x00600000, + IWL_RX_PHY_DATA0_HE_PE_DISAMBIG = 0x00800000, + IWL_RX_PHY_DATA0_HE_DOPPLER = 0x01000000, + /* 6 bits reserved */ + IWL_RX_PHY_DATA0_HE_DELIM_EOF = 0x80000000, +}; + +/* TSF overload low dword */ +enum iwl_rx_phy_eht_data0 { + /* info type: EHT any */ + IWL_RX_PHY_DATA0_EHT_VALIDATE = BIT(0), + IWL_RX_PHY_DATA0_EHT_UPLINK = BIT(1), + IWL_RX_PHY_DATA0_EHT_BSS_COLOR_MASK = 0x000000fc, + IWL_RX_PHY_DATA0_ETH_SPATIAL_REUSE_MASK = 0x00000f00, + IWL_RX_PHY_DATA0_EHT_PS160 = BIT(12), + IWL_RX_PHY_DATA0_EHT_TXOP_DUR_MASK = 0x000fe000, + IWL_RX_PHY_DATA0_EHT_LDPC_EXT_SYM = BIT(20), + IWL_RX_PHY_DATA0_EHT_PRE_FEC_PAD_MASK = 0x00600000, + IWL_RX_PHY_DATA0_EHT_PE_DISAMBIG = BIT(23), + IWL_RX_PHY_DATA0_EHT_BW320_SLOT = BIT(24), + IWL_RX_PHY_DATA0_EHT_SIGA_CRC_OK = BIT(25), + IWL_RX_PHY_DATA0_EHT_PHY_VER = 0x1c000000, + /* 2 bits reserved */ + IWL_RX_PHY_DATA0_EHT_DELIM_EOF = BIT(31), +}; + +enum iwl_rx_phy_info_type { + IWL_RX_PHY_INFO_TYPE_NONE = 0, + IWL_RX_PHY_INFO_TYPE_CCK = 1, + IWL_RX_PHY_INFO_TYPE_OFDM_LGCY = 2, + IWL_RX_PHY_INFO_TYPE_HT = 3, + IWL_RX_PHY_INFO_TYPE_VHT_SU = 4, + IWL_RX_PHY_INFO_TYPE_VHT_MU = 5, + IWL_RX_PHY_INFO_TYPE_HE_SU = 6, + IWL_RX_PHY_INFO_TYPE_HE_MU = 7, + IWL_RX_PHY_INFO_TYPE_HE_TB = 8, + IWL_RX_PHY_INFO_TYPE_HE_MU_EXT = 9, + IWL_RX_PHY_INFO_TYPE_HE_TB_EXT = 10, + IWL_RX_PHY_INFO_TYPE_EHT_MU = 11, + IWL_RX_PHY_INFO_TYPE_EHT_TB = 12, + IWL_RX_PHY_INFO_TYPE_EHT_MU_EXT = 13, + IWL_RX_PHY_INFO_TYPE_EHT_TB_EXT = 14, +}; + +/* TSF overload high dword */ +enum iwl_rx_phy_common_data1 { + /* + * check this first - if TSF overload is set, + * see &enum iwl_rx_phy_info_type + */ + IWL_RX_PHY_DATA1_INFO_TYPE_MASK = 0xf0000000, + + /* info type: HT/VHT/HE/EHT any */ + IWL_RX_PHY_DATA1_LSIG_LEN_MASK = 0x0fff0000, +}; + +/* TSF overload high dword For HE rates*/ +enum iwl_rx_phy_he_data1 { + /* info type: HE MU/MU-EXT */ + IWL_RX_PHY_DATA1_HE_MU_SIGB_COMPRESSION = 0x00000001, + IWL_RX_PHY_DATA1_HE_MU_SIBG_SYM_OR_USER_NUM_MASK = 0x0000001e, + + /* info type: HE any */ + IWL_RX_PHY_DATA1_HE_LTF_NUM_MASK = 0x000000e0, + IWL_RX_PHY_DATA1_HE_RU_ALLOC_SEC80 = 0x00000100, + /* trigger encoded */ + IWL_RX_PHY_DATA1_HE_RU_ALLOC_MASK = 0x0000fe00, + + /* info type: HE TB/TX-EXT */ + IWL_RX_PHY_DATA1_HE_TB_PILOT_TYPE = 0x00000001, + IWL_RX_PHY_DATA1_HE_TB_LOW_SS_MASK = 0x0000000e, +}; + +/* TSF overload high dword For EHT-MU/TB rates*/ +enum iwl_rx_phy_eht_data1 { + /* info type: EHT-MU */ + IWL_RX_PHY_DATA1_EHT_MU_NUM_SIG_SYM_USIGA2 = 0x0000001f, + /* info type: EHT-TB */ + IWL_RX_PHY_DATA1_EHT_TB_PILOT_TYPE = BIT(0), + IWL_RX_PHY_DATA1_EHT_TB_LOW_SS = 0x0000001e, + + /* info type: EHT any */ + /* number of EHT-LTF symbols 0 - 1 EHT-LTF, 1 - 2 EHT-LTFs, 2 - 4 EHT-LTFs, + * 3 - 6 EHT-LTFs, 4 - 8 EHT-LTFs */ + IWL_RX_PHY_DATA1_EHT_SIG_LTF_NUM = 0x000000e0, + IWL_RX_PHY_DATA1_EHT_RU_ALLOC_B0 = 0x00000100, + IWL_RX_PHY_DATA1_EHT_RU_ALLOC_B1_B7 = 0x0000fe00, +}; + +/* goes into Metadata DW 7 (Qu) or 8 (So or higher) */ +enum iwl_rx_phy_he_data2 { + /* info type: HE MU-EXT */ + /* the a1/a2/... is what the PHY/firmware calls the values */ + IWL_RX_PHY_DATA2_HE_MU_EXT_CH1_RU0 = 0x000000ff, /* a1 */ + IWL_RX_PHY_DATA2_HE_MU_EXT_CH1_RU2 = 0x0000ff00, /* a2 */ + IWL_RX_PHY_DATA2_HE_MU_EXT_CH2_RU0 = 0x00ff0000, /* b1 */ + IWL_RX_PHY_DATA2_HE_MU_EXT_CH2_RU2 = 0xff000000, /* b2 */ + + /* info type: HE TB-EXT */ + IWL_RX_PHY_DATA2_HE_TB_EXT_SPTL_REUSE1 = 0x0000000f, + IWL_RX_PHY_DATA2_HE_TB_EXT_SPTL_REUSE2 = 0x000000f0, + IWL_RX_PHY_DATA2_HE_TB_EXT_SPTL_REUSE3 = 0x00000f00, + IWL_RX_PHY_DATA2_HE_TB_EXT_SPTL_REUSE4 = 0x0000f000, +}; + +/* goes into Metadata DW 8 (Qu) or 7 (So or higher) */ +enum iwl_rx_phy_he_data3 { + /* info type: HE MU-EXT */ + IWL_RX_PHY_DATA3_HE_MU_EXT_CH1_RU1 = 0x000000ff, /* c1 */ + IWL_RX_PHY_DATA3_HE_MU_EXT_CH1_RU3 = 0x0000ff00, /* c2 */ + IWL_RX_PHY_DATA3_HE_MU_EXT_CH2_RU1 = 0x00ff0000, /* d1 */ + IWL_RX_PHY_DATA3_HE_MU_EXT_CH2_RU3 = 0xff000000, /* d2 */ +}; + +/* goes into Metadata DW 4 high 16 bits */ +enum iwl_rx_phy_he_he_data4 { + /* info type: HE MU-EXT */ + IWL_RX_PHY_DATA4_HE_MU_EXT_CH1_CTR_RU = 0x0001, + IWL_RX_PHY_DATA4_HE_MU_EXT_CH2_CTR_RU = 0x0002, + IWL_RX_PHY_DATA4_HE_MU_EXT_CH1_CRC_OK = 0x0004, + IWL_RX_PHY_DATA4_HE_MU_EXT_CH2_CRC_OK = 0x0008, + IWL_RX_PHY_DATA4_HE_MU_EXT_SIGB_MCS_MASK = 0x00f0, + IWL_RX_PHY_DATA4_HE_MU_EXT_SIGB_DCM = 0x0100, + IWL_RX_PHY_DATA4_HE_MU_EXT_PREAMBLE_PUNC_TYPE_MASK = 0x0600, +}; + +/* goes into Metadata DW 8 (Qu has no EHT) */ +enum iwl_rx_phy_eht_data2 { + /* info type: EHT-MU-EXT */ + IWL_RX_PHY_DATA2_EHT_MU_EXT_RU_ALLOC_A1 = 0x000001ff, + IWL_RX_PHY_DATA2_EHT_MU_EXT_RU_ALLOC_A2 = 0x0003fe00, + IWL_RX_PHY_DATA2_EHT_MU_EXT_RU_ALLOC_B1 = 0x07fc0000, + + /* info type: EHT-TB-EXT */ + IWL_RX_PHY_DATA2_EHT_TB_EXT_TRIG_SIGA1 = 0xffffffff, +}; + +/* goes into Metadata DW 7 (Qu has no EHT) */ +enum iwl_rx_phy_eht_data3 { + /* note: low 8 bits cannot be used */ + /* info type: EHT-MU-EXT */ + IWL_RX_PHY_DATA3_EHT_MU_EXT_RU_ALLOC_C1 = 0x0003fe00, + IWL_RX_PHY_DATA3_EHT_MU_EXT_RU_ALLOC_C2 = 0x07fc0000, +}; + +/* goes into Metadata DW 4 */ +enum iwl_rx_phy_eht_data4 { + /* info type: EHT-MU-EXT */ + IWL_RX_PHY_DATA4_EHT_MU_EXT_RU_ALLOC_D1 = 0x000001ff, + IWL_RX_PHY_DATA4_EHT_MU_EXT_RU_ALLOC_D2 = 0x0003fe00, + IWL_RX_PHY_DATA4_EHT_MU_EXT_SIGB_MCS = 0x000c0000, + IWL_RX_PHY_DATA4_EHT_MU_EXT_RU_ALLOC_B2 = 0x1ff00000, +}; + +/* goes into Metadata DW 16 */ +enum iwl_rx_phy_data5 { + /* info type: EHT any */ + IWL_RX_PHY_DATA5_EHT_TYPE_AND_COMP = 0x00000003, + /* info type: EHT-TB */ + IWL_RX_PHY_DATA5_EHT_TB_SPATIAL_REUSE1 = 0x0000003c, + IWL_RX_PHY_DATA5_EHT_TB_SPATIAL_REUSE2 = 0x000003c0, + /* info type: EHT-MU */ + IWL_RX_PHY_DATA5_EHT_MU_PUNC_CH_CODE = 0x0000007c, + IWL_RX_PHY_DATA5_EHT_MU_STA_ID_USR = 0x0003ff80, + IWL_RX_PHY_DATA5_EHT_MU_NUM_USR_NON_OFDMA = 0x001c0000, + IWL_RX_PHY_DATA5_EHT_MU_SPATIAL_CONF_USR_FIELD = 0x0fe00000, +}; + +/** + * struct iwl_rx_mpdu_desc_v1 - RX MPDU descriptor + */ +struct iwl_rx_mpdu_desc_v1 { + /* DW7 - carries rss_hash only when rpa_en == 1 */ + union { + /** + * @rss_hash: RSS hash value + */ + __le32 rss_hash; + + /** + * @phy_data2: depends on info type (see @phy_data1) + */ + __le32 phy_data2; + }; + + /* DW8 - carries filter_match only when rpa_en == 1 */ + union { + /** + * @filter_match: filter match value + */ + __le32 filter_match; + + /** + * @phy_data3: depends on info type (see @phy_data1) + */ + __le32 phy_data3; + }; + + /* DW9 */ + /** + * @rate_n_flags: RX rate/flags encoding + */ + __le32 rate_n_flags; + /* DW10 */ + /** + * @energy_a: energy chain A + */ + u8 energy_a; + /** + * @energy_b: energy chain B + */ + u8 energy_b; + /** + * @channel: channel number + */ + u8 channel; + /** + * @mac_context: MAC context mask + */ + u8 mac_context; + /* DW11 */ + /** + * @gp2_on_air_rise: GP2 timer value on air rise (INA) + */ + __le32 gp2_on_air_rise; + /* DW12 & DW13 */ + union { + /** + * @tsf_on_air_rise: + * TSF value on air rise (INA), only valid if + * %IWL_RX_MPDU_PHY_TSF_OVERLOAD isn't set + */ + __le64 tsf_on_air_rise; + + struct { + /** + * @phy_data0: depends on info_type, see @phy_data1 + */ + __le32 phy_data0; + /** + * @phy_data1: valid only if + * %IWL_RX_MPDU_PHY_TSF_OVERLOAD is set, + * see &enum iwl_rx_phy_common_data1 or + * &enum iwl_rx_phy_he_data1 or + * &enum iwl_rx_phy_eht_data1. + */ + __le32 phy_data1; + }; + }; +} __packed; /* RX_MPDU_RES_START_API_S_VER_4 */ + +/** + * struct iwl_rx_mpdu_desc_v3 - RX MPDU descriptor + */ +struct iwl_rx_mpdu_desc_v3 { + /* DW7 - carries filter_match only when rpa_en == 1 */ + union { + /** + * @filter_match: filter match value + */ + __le32 filter_match; + + /** + * @phy_data3: depends on info type (see @phy_data1) + */ + __le32 phy_data3; + }; + + /* DW8 - carries rss_hash only when rpa_en == 1 */ + union { + /** + * @rss_hash: RSS hash value + */ + __le32 rss_hash; + + /** + * @phy_data2: depends on info type (see @phy_data1) + */ + __le32 phy_data2; + }; + /* DW9 */ + /** + * @partial_hash: 31:0 ip/tcp header hash + * w/o some fields (such as IP SRC addr) + */ + __le32 partial_hash; + /* DW10 */ + /** + * @raw_xsum: raw xsum value + */ + __be16 raw_xsum; + /** + * @reserved_xsum: reserved high bits in the raw checksum + */ + __le16 reserved_xsum; + /* DW11 */ + /** + * @rate_n_flags: RX rate/flags encoding + */ + __le32 rate_n_flags; + /* DW12 */ + /** + * @energy_a: energy chain A + */ + u8 energy_a; + /** + * @energy_b: energy chain B + */ + u8 energy_b; + /** + * @channel: channel number + */ + u8 channel; + /** + * @mac_context: MAC context mask + */ + u8 mac_context; + /* DW13 */ + /** + * @gp2_on_air_rise: GP2 timer value on air rise (INA) + */ + __le32 gp2_on_air_rise; + /* DW14 & DW15 */ + union { + /** + * @tsf_on_air_rise: + * TSF value on air rise (INA), only valid if + * %IWL_RX_MPDU_PHY_TSF_OVERLOAD isn't set + */ + __le64 tsf_on_air_rise; + + struct { + /** + * @phy_data0: depends on info_type, see @phy_data1 + */ + __le32 phy_data0; + /** + * @phy_data1: valid only if + * %IWL_RX_MPDU_PHY_TSF_OVERLOAD is set, + * see &enum iwl_rx_phy_data1. + */ + __le32 phy_data1; + }; + }; + /* DW16 */ + /** + * @phy_data5: valid only if + * %IWL_RX_MPDU_PHY_TSF_OVERLOAD is set, + * see &enum iwl_rx_phy_data5. + */ + __le32 phy_data5; + /* DW17 */ + /** + * @reserved: reserved + */ + __le32 reserved[1]; +} __packed; /* RX_MPDU_RES_START_API_S_VER_3, + * RX_MPDU_RES_START_API_S_VER_5, + * RX_MPDU_RES_START_API_S_VER_6 + */ + +/** + * struct iwl_rx_mpdu_desc - RX MPDU descriptor + */ +struct iwl_rx_mpdu_desc { + /* DW2 */ + /** + * @mpdu_len: MPDU length + */ + __le16 mpdu_len; + /** + * @mac_flags1: &enum iwl_rx_mpdu_mac_flags1 + */ + u8 mac_flags1; + /** + * @mac_flags2: &enum iwl_rx_mpdu_mac_flags2 + */ + u8 mac_flags2; + /* DW3 */ + /** + * @amsdu_info: &enum iwl_rx_mpdu_amsdu_info + */ + u8 amsdu_info; + /** + * @phy_info: &enum iwl_rx_mpdu_phy_info + */ + __le16 phy_info; + /** + * @mac_phy_band: MAC/link ID, PHY ID, band; + * see &enum iwl_rx_mpdu_mac_phy_band + */ + u8 mac_phy_band; + /* DW4 */ + union { + struct { + /* carries csum data only when rpa_en == 1 */ + /** + * @raw_csum: raw checksum (alledgedly unreliable) + */ + __le16 raw_csum; + + union { + /** + * @l3l4_flags: &enum iwl_rx_l3l4_flags + */ + __le16 l3l4_flags; + + /** + * @phy_data4: depends on info type, see phy_data1 + */ + __le16 phy_data4; + }; + }; + /** + * @phy_eht_data4: depends on info type, see phy_data1 + */ + __le32 phy_eht_data4; + }; + /* DW5 */ + /** + * @status: &enum iwl_rx_mpdu_status + */ + __le32 status; + + /* DW6 */ + /** + * @reorder_data: &enum iwl_rx_mpdu_reorder_data + */ + __le32 reorder_data; + + union { + /** + * @v1: version 1 of the remaining RX descriptor, + * see &struct iwl_rx_mpdu_desc_v1 + */ + struct iwl_rx_mpdu_desc_v1 v1; + /** + * @v3: version 3 of the remaining RX descriptor, + * see &struct iwl_rx_mpdu_desc_v3 + */ + struct iwl_rx_mpdu_desc_v3 v3; + }; +} __packed; /* RX_MPDU_RES_START_API_S_VER_3, + * RX_MPDU_RES_START_API_S_VER_4, + * RX_MPDU_RES_START_API_S_VER_5, + * RX_MPDU_RES_START_API_S_VER_6 + */ + +#define IWL_RX_DESC_SIZE_V1 offsetofend(struct iwl_rx_mpdu_desc, v1) + +#define RX_NO_DATA_CHAIN_A_POS 0 +#define RX_NO_DATA_CHAIN_A_MSK (0xff << RX_NO_DATA_CHAIN_A_POS) +#define RX_NO_DATA_CHAIN_B_POS 8 +#define RX_NO_DATA_CHAIN_B_MSK (0xff << RX_NO_DATA_CHAIN_B_POS) +#define RX_NO_DATA_CHANNEL_POS 16 +#define RX_NO_DATA_CHANNEL_MSK (0xff << RX_NO_DATA_CHANNEL_POS) + +#define RX_NO_DATA_INFO_TYPE_POS 0 +#define RX_NO_DATA_INFO_TYPE_MSK (0xff << RX_NO_DATA_INFO_TYPE_POS) +#define RX_NO_DATA_INFO_TYPE_NONE 0 +#define RX_NO_DATA_INFO_TYPE_RX_ERR 1 +#define RX_NO_DATA_INFO_TYPE_NDP 2 +#define RX_NO_DATA_INFO_TYPE_MU_UNMATCHED 3 +#define RX_NO_DATA_INFO_TYPE_TB_UNMATCHED 4 + +#define RX_NO_DATA_INFO_ERR_POS 8 +#define RX_NO_DATA_INFO_ERR_MSK (0xff << RX_NO_DATA_INFO_ERR_POS) +#define RX_NO_DATA_INFO_ERR_NONE 0 +#define RX_NO_DATA_INFO_ERR_BAD_PLCP 1 +#define RX_NO_DATA_INFO_ERR_UNSUPPORTED_RATE 2 +#define RX_NO_DATA_INFO_ERR_NO_DELIM 3 +#define RX_NO_DATA_INFO_ERR_BAD_MAC_HDR 4 +#define RX_NO_DATA_INFO_LOW_ENERGY 5 + +#define RX_NO_DATA_FRAME_TIME_POS 0 +#define RX_NO_DATA_FRAME_TIME_MSK (0xfffff << RX_NO_DATA_FRAME_TIME_POS) + +#define RX_NO_DATA_RX_VEC0_HE_NSTS_MSK 0x03800000 +#define RX_NO_DATA_RX_VEC0_VHT_NSTS_MSK 0x38000000 +#define RX_NO_DATA_RX_VEC2_EHT_NSTS_MSK 0x00f00000 + +/* content of OFDM_RX_VECTOR_USIG_A1_OUT */ +enum iwl_rx_usig_a1 { + IWL_RX_USIG_A1_ENHANCED_WIFI_VER_ID = 0x00000007, + IWL_RX_USIG_A1_BANDWIDTH = 0x00000038, + IWL_RX_USIG_A1_UL_FLAG = 0x00000040, + IWL_RX_USIG_A1_BSS_COLOR = 0x00001f80, + IWL_RX_USIG_A1_TXOP_DURATION = 0x000fe000, + IWL_RX_USIG_A1_DISREGARD = 0x01f00000, + IWL_RX_USIG_A1_VALIDATE = 0x02000000, + IWL_RX_USIG_A1_EHT_BW320_SLOT = 0x04000000, + IWL_RX_USIG_A1_EHT_TYPE = 0x18000000, + IWL_RX_USIG_A1_RDY = 0x80000000, +}; + +/* content of OFDM_RX_VECTOR_USIG_A2_EHT_OUT */ +enum iwl_rx_usig_a2_eht { + IWL_RX_USIG_A2_EHT_PPDU_TYPE = 0x00000003, + IWL_RX_USIG_A2_EHT_USIG2_VALIDATE_B2 = 0x00000004, + IWL_RX_USIG_A2_EHT_PUNC_CHANNEL = 0x000000f8, + IWL_RX_USIG_A2_EHT_USIG2_VALIDATE_B8 = 0x00000100, + IWL_RX_USIG_A2_EHT_SIG_MCS = 0x00000600, + IWL_RX_USIG_A2_EHT_SIG_SYM_NUM = 0x0000f800, + IWL_RX_USIG_A2_EHT_TRIG_SPATIAL_REUSE_1 = 0x000f0000, + IWL_RX_USIG_A2_EHT_TRIG_SPATIAL_REUSE_2 = 0x00f00000, + IWL_RX_USIG_A2_EHT_TRIG_USIG2_DISREGARD = 0x1f000000, + IWL_RX_USIG_A2_EHT_CRC_OK = 0x40000000, + IWL_RX_USIG_A2_EHT_RDY = 0x80000000, +}; + +/** + * struct iwl_rx_no_data - RX no data descriptor + * @info: 7:0 frame type, 15:8 RX error type + * @rssi: 7:0 energy chain-A, + * 15:8 chain-B, measured at FINA time (FINA_ENERGY), 16:23 channel + * @on_air_rise_time: GP2 during on air rise + * @fr_time: frame time + * @rate: rate/mcs of frame + * @phy_info: &enum iwl_rx_phy_he_data0 or &enum iwl_rx_phy_eht_data0 + * based on &enum iwl_rx_phy_info_type + * @rx_vec: DW-12:9 raw RX vectors from DSP according to modulation type. + * for VHT: OFDM_RX_VECTOR_SIGA1_OUT, OFDM_RX_VECTOR_SIGA2_OUT + * for HE: OFDM_RX_VECTOR_HE_SIGA1_OUT, OFDM_RX_VECTOR_HE_SIGA2_OUT + */ +struct iwl_rx_no_data { + __le32 info; + __le32 rssi; + __le32 on_air_rise_time; + __le32 fr_time; + __le32 rate; + __le32 phy_info[2]; + __le32 rx_vec[2]; +} __packed; /* RX_NO_DATA_NTFY_API_S_VER_1, + RX_NO_DATA_NTFY_API_S_VER_2 */ + +/** + * struct iwl_rx_no_data_ver_3 - RX no data descriptor + * @info: 7:0 frame type, 15:8 RX error type + * @rssi: 7:0 energy chain-A, + * 15:8 chain-B, measured at FINA time (FINA_ENERGY), 16:23 channel + * @on_air_rise_time: GP2 during on air rise + * @fr_time: frame time + * @rate: rate/mcs of frame, format depends on the notification version + * @phy_info: &enum iwl_rx_phy_eht_data0 and &enum iwl_rx_phy_info_type + * @rx_vec: DW-12:9 raw RX vectors from DSP according to modulation type. + * for VHT: OFDM_RX_VECTOR_SIGA1_OUT, OFDM_RX_VECTOR_SIGA2_OUT + * for HE: OFDM_RX_VECTOR_HE_SIGA1_OUT, OFDM_RX_VECTOR_HE_SIGA2_OUT + * for EHT: OFDM_RX_VECTOR_USIG_A1_OUT, OFDM_RX_VECTOR_USIG_A2_EHT_OUT, + * OFDM_RX_VECTOR_EHT_OUT, OFDM_RX_VECTOR_EHT_USER_FIELD_OUT + */ +struct iwl_rx_no_data_ver_3 { + __le32 info; + __le32 rssi; + __le32 on_air_rise_time; + __le32 fr_time; + __le32 rate; + __le32 phy_info[2]; + __le32 rx_vec[4]; +} __packed; /* RX_NO_DATA_NTFY_API_S_VER_3, _VER_4 */ *** 18783 LINES SKIPPED *** From nobody Fri Mar 6 21:32:42 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSKPk1BS0z6TVct for ; Fri, 06 Mar 2026 21:32: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSKPk0Xwtz3kSJ for ; Fri, 06 Mar 2026 21:32:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772832762; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=fIQEjhv9Zqnih2XakQhgusDIZQ5HzzO8e2wPZ2Nfc/k=; b=WbBTbaOItIyDT2t1wuMiqepHZkRTqcEKhCfCRAbMPcFLo55zefgSx1t07Chn0D6r6bnOWm X9vKkcduxIhdBj4GTVle8kxJpEkfrm71DUfpnZfNj636+4OW9MakaBNwApWQ/XRJLDONZ7 mY2S5UibDREzw/stcvTWG3uP+5jtK0J8Z7X0mSTQTxPz26xLEMt1+9V6C4nzezCbEk9KH+ +PshDTq8CpnTeRWCyugmQGx/w+FeSW7BZq+LvBJJtiCqXgPrqR1cF3GEU9rOMB/BU5n3EI 33Aa4AgvEtkwFohlyP3dhr98gzNSk9w0+Ua9OaE4sbG8v86EiN27SCi0jLHhUw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772832762; a=rsa-sha256; cv=none; b=AxVcLyIivnxtBp8gsBbKxfJ66zo4DSMb8o+5zpVFZ1OdsM36GSIQophP+tcm1+n72yVj8z gpFoMMeDmi9Q9AhKpNwwRiML2vMT9D+7ip9ph9IUjY4px18HcboJWkAOPTxCopa6haT6DJ +6+bxaMC+ibQrgOkOS57RA37AWYZpKJ6M6lIRvcSbdaInHj7vH9RVaIo45x/HALhgr/38v it9W+kdopFWIUc0JQ+23F1fRM8LdJH/uuW9Z6JCm+xlZAWbFVMff85xxm05ISVdwnlvJ0O 06eSXyoIq5hiGsR3X8nqS9Vzs5f0gjgYVPQc8RiA5OZQF91W7F9iPt+kG8TpEA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772832762; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=fIQEjhv9Zqnih2XakQhgusDIZQ5HzzO8e2wPZ2Nfc/k=; b=SfFPgkneUyao+l56CZFfrivIeBB6cqH8S1iliWtUF2yXNEO4inifohx4cFLptPtHEEgVuM tEWCIht5eqIZjY36Vz5lWWwBSsYOYEptyw6uZhdfdkGzN3vUCFN7awPNZ+LeW69LcM9wMG bQoazlYQ867gABj73Oz2BxSOaq/iFeAYm3bmOrI9FsRk13hHE4wANwc0QHIxDX95OY/IAa 82Gy0FiRyfs1oiMrCRXjJ7kCXMepsHLBiBsAdG3j7laqdzSBvDlK0PEuCwtzvDqynV+esx 87x9b6yIy8xnV8bEdon5Cqi827ABeY+FoYoGjXQN7CjU9pnY2sMN7nPnv+UwUA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSKPk06Q2zfv9 for ; Fri, 06 Mar 2026 21:32:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3a4dd by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 21:32:42 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: ca25b1b26379 - main - devinfo: Support PCI DBSF and ACPI handles for -p List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: ca25b1b26379e27bf2bab7742a7b383ca0bfc7d2 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 21:32:42 +0000 Message-Id: <69ab47fa.3a4dd.2fdf82d0@gitrepo.freebsd.org> The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=ca25b1b26379e27bf2bab7742a7b383ca0bfc7d2 commit ca25b1b26379e27bf2bab7742a7b383ca0bfc7d2 Author: John Baldwin AuthorDate: 2026-03-06 20:36:05 +0000 Commit: John Baldwin CommitDate: 2026-03-06 20:36:05 +0000 devinfo: Support PCI DBSF and ACPI handles for -p When matching on a name of a device, match on ACPI handles and PCI selectors in addition to device names. This can be useful for matching on devices without an attached driver. For example: devinfo -p pci0:0:31:0 Reviewed by: imp Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D55673 --- usr.sbin/devinfo/devinfo.8 | 22 +++++++++++++++++- usr.sbin/devinfo/devinfo.c | 58 +++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 78 insertions(+), 2 deletions(-) diff --git a/usr.sbin/devinfo/devinfo.8 b/usr.sbin/devinfo/devinfo.8 index 8bf4f9d10e17..b8acdcf524ee 100644 --- a/usr.sbin/devinfo/devinfo.8 +++ b/usr.sbin/devinfo/devinfo.8 @@ -26,7 +26,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 28, 2025 +.Dd March 6, 2026 .Dt DEVINFO 8 .Os .Sh NAME @@ -53,6 +53,26 @@ The following options are accepted: Display the path of .Ar dev back to the root of the device tree. +.Ar dev +can either be a device name, +the absolute path of an ACPI handle +.Po must begin with a +.Dq \e +.Pc , +or a PCI selector +.Po +either +.Sy pci Ns Fa domain Ns : Ns Fa bus Ns : Ns Fa slot Ns : Ns Fa function +or +.Sy pci Ns Fa bus Ns : Ns Fa slot Ns : Ns Fa function +.Pc . +.Pp +If +.Fl v +is specified, +each device is output on a separate line including the device name and +additional verbose information; +otherwise, a space-separated list of device names is output. .It Fl r Causes hardware resource information .Pq such as IRQ, I/O ports, I/O memory addresses diff --git a/usr.sbin/devinfo/devinfo.c b/usr.sbin/devinfo/devinfo.c index 43d88481d903..bea082ba6285 100644 --- a/usr.sbin/devinfo/devinfo.c +++ b/usr.sbin/devinfo/devinfo.c @@ -275,13 +275,69 @@ print_device_path_entry(struct devinfo_dev *dev) printf("\n"); } +/* + * This assumes the string to be compared in *cp is either space or + * nul terminated. + */ +static bool +match_value(const char *cp, const char *name) +{ + const char *end; + size_t len; + + end = strchr(cp, ' '); + if (end == NULL) + return (strcmp(cp, name) == 0); + + if (end == cp) + return (false); + + /* NB: strncmp(3) would return zero if name matches a prefix. */ + len = end - cp; + return (strlen(name) == len && memcmp(name, cp, len) == 0); +} + +static bool +device_matches_name(struct devinfo_dev *dev, const char *name) +{ + const char *cp, *val; + + if (strcmp(dev->dd_name, name) == 0) + return (true); + + if (*dev->dd_location) { + /* Permit matches on the ACPI handle stored in location. */ + if (name[0] == '\\' && (cp = strstr(dev->dd_location, + "handle=\\")) != NULL) { + if (match_value(cp + strlen("handle="), name)) + return (true); + } + + /* Permit matches on the PCI dbsf stored in location. */ + if (strncmp(name, "pci", strlen("pci")) == 0 && + (cp = strstr(dev->dd_location, "dbsf=pci")) != NULL) { + cp += strlen("dbsf=pci"); + val = name + strlen("pci"); + if (match_value(cp, val)) + return (true); + + /* Also match on pci:: for domain 0. */ + if (strncmp(cp, "0:", strlen("0:")) == 0 && + match_value(cp + strlen("0:"), val)) + return (true); + } + } + + return (false); +} + static int print_device_path(struct devinfo_dev *dev, void *xname) { const char *name = xname; int rv; - if (strcmp(dev->dd_name, name) == 0) { + if (device_matches_name(dev, name)) { print_device_path_entry(dev); return (1); } From nobody Fri Mar 6 21:32:43 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSKPl3Wk8z6TVjM for ; Fri, 06 Mar 2026 21:32: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSKPl15lhz3kSL for ; Fri, 06 Mar 2026 21:32:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772832763; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rD12VLLzezxRvwzjzWpVykHEJ+RSOotGgJyoqQTRpig=; b=LbESwLhHxS6SeLrutWzDKthkDmQUmW1uF7xKNwGDZEn8wsUVxLefVtgCC7D4dU2/77wp8D i0MGR0B/Q2CxOlDKXCWTeAYW4h4tzUzMPXjHA3cZ9vHIwhR8a8cRm2y3sKHNaz8dENRErh du6jNWIOZfn7BcSTWigBxKyVSgV/PEGHvWnPYyyo4L0yACPkm7t0Uf3kTDbETzrcP6xohT o7MAw+Opqy7e1oJJQd7fYyG6Kp5jiGesaWOS8AfkFL7rqb01hgT6Os/+qXstMaMJFc+5Ap ly0Xl1eXIng5DwSKMiuJtyMlhg7ASRlhliZlBX+dQXRvBnrij+FAPaMmPHcdmw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772832763; a=rsa-sha256; cv=none; b=qjhqsTwL/9lofyHKTtxNpep+RPT0k9lbfbfhstQDjPk4anaw7+Z16IaMGjKvhR7uxNovZM K4vfDXiEyJ1hKts8+WS4m3da+eZh7ICPmbtd1hJuITURyGk9YbeQ5zJgGrLUHF8i27+6Um uTD9LZl/DODnC5QI53Y7iIr/1eYfkubI14r4g3t2T2k1iwwD39wIZlrEEsYbA37jlSpdYh hF0RtFFKWLhw0dg+470amGFyXPdYb8/+eMcZysUWkkLwbwCTOLJ8HAT4ChoTNFqKPxk/fs 5xNSNjN4JA0RFUmzYMumUiJP+R9OupMXt5lL88UclO+5wuPFb3EUMoEdZIhzjA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772832763; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rD12VLLzezxRvwzjzWpVykHEJ+RSOotGgJyoqQTRpig=; b=O0Z0QARsGUUZr0Ehx3g07GyxsUJqDTO9fKRZpDihLlQAZR9LbeJYqupeKOGxjm0dxUdoXL eJeNbmqdHUvzu3m3nU1uDrobxBKHyMX0RwhpyLf0BmbpY4Z3hAEDF2jZgDa4IQKCUXcMYi nlPBVbG6T2am2V9AozF5ATfakdR+uFpl6g1MFW7VwDMRoTjaVntcLqjOXhd9a7QiLIGAVd jEQCDXq2g/dPvE/OaGoAUAbhxxmQGde3KmlsgcjimokAPeF8FdjqpU+g78UlkE78OQfUaU YNp/k6ahiamk0ZVxxwF37I1FO/8fj0braT5DIevTD0mh1ihoGvD5lpVTjw5FlA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSKPl0gNQzgZ8 for ; Fri, 06 Mar 2026 21:32:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3aafa by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 21:32:43 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 1e4086d05297 - main - sys: Don't pass RF_ALLOCATED to bus_alloc_resource* List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 1e4086d05297b711081fe06933677925c5ee6232 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 21:32:43 +0000 Message-Id: <69ab47fb.3aafa.383d36be@gitrepo.freebsd.org> The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=1e4086d05297b711081fe06933677925c5ee6232 commit 1e4086d05297b711081fe06933677925c5ee6232 Author: John Baldwin AuthorDate: 2026-03-06 21:32:33 +0000 Commit: John Baldwin CommitDate: 2026-03-06 21:32:33 +0000 sys: Don't pass RF_ALLOCATED to bus_alloc_resource* This is a nop as eventually these flags are passed to rman_reserve_resource which unconditionally sets RF_ALLOCATED in the new flags for a region. However, it's really a layering violation to use RF_ALLOCATED in relation to struct resource objects outside of subr_rman.c as subr_rman.c uses this flag to manage it's internal tracking of allocated vs free regions. In addition, don't document this as a valid flag in the manual. I think the intention here was that if a caller didn't want to pass RF_ACTIVE or RF_SHAREABLE, they could pass RF_ALLOCATED instead of 0, but given the layering violation, I think it's best to just pass 0 instead in that case. NB: The bhnd bus uses RF_ALLOCATED (along with RF_ACTIVE) in a separate API to manage resource regions that are not struct resource objects (but a separate wrapper object). It would perhaps be cleaner if the chipc_retain_region and chipc_release_region functions used their own flag constants instead of reusing the rman(9) flags. Reviewed by: imp, kib Differential Revision: https://reviews.freebsd.org/D55683 --- share/man/man9/bus_alloc_resource.9 | 10 +++------- sys/arm/nvidia/tegra_pcie.c | 5 ++--- sys/x86/iommu/amd_drv.c | 2 +- 3 files changed, 6 insertions(+), 11 deletions(-) diff --git a/share/man/man9/bus_alloc_resource.9 b/share/man/man9/bus_alloc_resource.9 index 210abb3074e1..d69917d17ffd 100644 --- a/share/man/man9/bus_alloc_resource.9 +++ b/share/man/man9/bus_alloc_resource.9 @@ -26,7 +26,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 October 30, 2025 +.Dd March 6, 2026 .Dt BUS_ALLOC_RESOURCE 9 .Os .Sh NAME @@ -142,12 +142,8 @@ is used, if it is bigger than the default value. .It .Fa flags sets the flags for the resource. -You can set one or more of these flags: -.Bl -tag -width RF_SHAREABLE -.It Dv RF_ALLOCATED -resource has been reserved. -The resource still needs to be activated with -.Xr bus_activate_resource 9 . +You can set zero or more of these flags: +.Bl -tag -width RF_PREFETCHABLE .It Dv RF_ACTIVE activate resource atomically. .It Dv RF_PREFETCHABLE diff --git a/sys/arm/nvidia/tegra_pcie.c b/sys/arm/nvidia/tegra_pcie.c index ec272523df1b..c7a30965a5e5 100644 --- a/sys/arm/nvidia/tegra_pcie.c +++ b/sys/arm/nvidia/tegra_pcie.c @@ -1468,7 +1468,7 @@ tegra_pcib_attach(device_t dev) } /* * XXX - FIXME - * tag for config space is not filled when RF_ALLOCATED flag is used. + * tag for config space is not filled when RF_ACTIVE flag is not used. */ sc->bus_tag = rman_get_bustag(sc->pads_mem_res); @@ -1482,8 +1482,7 @@ tegra_pcib_attach(device_t dev) } rid = 2; - sc->cfg_mem_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY, &rid, - RF_ALLOCATED); + sc->cfg_mem_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY, &rid, 0); if (sc->cfg_mem_res == NULL) { device_printf(dev, "Cannot allocate config space memory\n"); rv = ENXIO; diff --git a/sys/x86/iommu/amd_drv.c b/sys/x86/iommu/amd_drv.c index bf7ac4b157c4..3a7b2819cbdd 100644 --- a/sys/x86/iommu/amd_drv.c +++ b/sys/x86/iommu/amd_drv.c @@ -494,7 +494,7 @@ amdiommu_attach(device_t dev) } sc->mmio_res = bus_alloc_resource(dev, SYS_RES_MEMORY, &sc->mmio_rid, sc->mmio_base, sc->mmio_base + sc->mmio_sz - 1, sc->mmio_sz, - RF_ALLOCATED | RF_ACTIVE | RF_SHAREABLE); + RF_ACTIVE | RF_SHAREABLE); if (sc->mmio_res == NULL) { device_printf(dev, "bus_alloc_resource %#jx-%#jx failed\n", From nobody Fri Mar 6 23:48:06 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSNPz0GfTz6Tgx5 for ; Fri, 06 Mar 2026 23:48: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSNPy6jcsz40Y1 for ; Fri, 06 Mar 2026 23:48:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772840887; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jekHGJ1h99PddeSq8pzvS4uPiJte1NyPaIL+zBn5hKs=; b=LY3ZfemcBlpotFwzxWLTXA4lixYZBIUuKonwUUq5ZK1IO1RahGqrettim5FCgh3cSxHQwl 7TBeqzYY4f+lljtXxZOCL00oYnpylD0crVg/0VxGw5ybUotkz2yk8Bk9yKvxAYJGsJ6aJi SrDPirdLKyf9hUADtegjbMWU43As5EDnKzy0MSYMJdsTa/2G0i585255MZykI6n4Ry+473 aNOM+ykF2h35ZPBwvSUtxqgcZl3uu2dbLV7/Pzjs+wm8ZudLAZe6hOZCl4RPA/mko2nIix tCAfmg5L3sbqAHA6kkEt1ArUVfljsdlPHMNA+BGujugKQwi1vfilJtBVkjKa2w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772840887; a=rsa-sha256; cv=none; b=fgNTQ9nqZPUDEC7DmfDtVLvSvaSKU9P0iDigdEUAkbeCdS+Tlq5iHooNCoFHQWC25DGmB2 5AtjEqnUWDrgRxAU27dLqOWw1Pcx/HV1iljzR5gUJLkZvPRN/DJ+yPU4nwn6jUQw0Wlnrf eFnP/yKRHS/ZsRRfRM1ein+PRzN9QJD/OGdkK0ai4By3gtbrZq8ajVrc2CL78/UvZy9ThK nRk49ImafbtwdK2ihEjqYUe/7AjZNIEaZY6ZjTASRSrVRcoMqP6zfjhpo8zngKkBPwvsRj ekv1nScU3zRciJRUvaHZ1cREI1wLc3zRoya3Y4FNGAYXNZzzyd6y565clnayUQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772840887; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jekHGJ1h99PddeSq8pzvS4uPiJte1NyPaIL+zBn5hKs=; b=elzavDAJaEbRopYEuXYWyUGfFkMJMLTouLEDPwtp5hnDnU9BF1NEvAvTIWLXJL2TYwqYfj 328OCS4pbKWVLBH8FGnFQtOuwyIwkYrXPb6lG3Q7mG9SttjKVEEY+wIH5u4Qds44kOdNKp oWeCeX3nXM4MNWGkhZEIY339A0AN13oRTxBvGafxqmMadAtSmiKiHun/4zC/stEJM2dpi8 khuznshZz9soh7L0wG9pR6qMPtnz3bqdLIHwK9STTeavQb3PAeQzdSggHWNIBbrgRA4I7g 0zx1K92G/Rlrcao9Oho961S3Ti11CYLGtg6bmcCz9w4auom8AiX6j+1qdjNUhA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSNPy624Qzk6D for ; Fri, 06 Mar 2026 23:48:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 44dfd by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 06 Mar 2026 23:48:06 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alexander Ziaee Subject: git: 74aec9f02d9d - main - ports.7: Document DEFAULT_VERSIONS List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 74aec9f02d9d8fbde250da1ecc881729c8baf489 Auto-Submitted: auto-generated Date: Fri, 06 Mar 2026 23:48:06 +0000 Message-Id: <69ab67b6.44dfd.4c6f2866@gitrepo.freebsd.org> The branch main has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=74aec9f02d9d8fbde250da1ecc881729c8baf489 commit 74aec9f02d9d8fbde250da1ecc881729c8baf489 Author: Alexander Ziaee AuthorDate: 2026-03-06 23:44:50 +0000 Commit: Alexander Ziaee CommitDate: 2026-03-06 23:47:20 +0000 ports.7: Document DEFAULT_VERSIONS MFC after: 3 days Co-authored-by: Adam Weinberger Differential Revision: https://reviews.freebsd.org/D55443 --- share/man/man7/ports.7 | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/share/man/man7/ports.7 b/share/man/man7/ports.7 index 318a19ba98c0..6e28f85da964 100644 --- a/share/man/man7/ports.7 +++ b/share/man/man7/ports.7 @@ -581,6 +581,10 @@ Additional to set when .Va WITH_DEBUG is set. +.It Va DEFAULT_VERSIONS +Override the default variant used for ports +with multiple concurrent versions in the tree, +such as database or compiler versions. .It Va WITH_CCACHE_BUILD .Pq Vt bool If set, enables the use of From nobody Sat Mar 7 03:59:33 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSV052zRbz6V1SF for ; Sat, 07 Mar 2026 03:59: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSV052WsNz3Gwv for ; Sat, 07 Mar 2026 03:59:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772855973; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4PT7+w3JMpwr04lrxlUZt3Iquk2kK08vkjcXmyZeiIU=; b=GgdFC8VPeT2Hs7SshN8JG2HpcTlv+uGyWS6xMvuCgLADDjQqekUU++qTN8F7D/3sq82Nd/ UWNg71PTNCmc5A+DgzDJH0NvYSoNRxosPTXl3Ulz1FX+f6mQPW9T9CcV3l6baqV1VLBONw leEzW8zupna86AS1kkcSobiFsgn/8W8HWVkXjBUrqSsTcGbF+VKp98vDcbpGgHBW1Sh39C uwybjxeniOeUZ+eGK+10dE8i3ZUv3PqRwO7l0ZskODPVV6DqgU6yYKmCCfmsFCSjKH55l6 sCq8Uv26IeUcvkSWef63mCho7YDqve2NFLBeHeuDW9OEiog9T0hu45G3VADxzg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772855973; a=rsa-sha256; cv=none; b=ZEYYUViiTePUl+hJbuldXVocwtNyCUDH0aT3e/pkr7moBGT8kl570n7S6q4HMdYO7yoWqJ xk6Lpvao0Bs43tLebG/Se5WDB8Z5oLoleXX6zJ66m1hxRQxUHy0APVvubPVDxTsD3J4Xhu rlbbtA0WQaPW2Ui6tOI8hVeXn56NjCCF0DceacakrkXm/T2wDR+wseWtmoxgovLJfsMy0/ 8L74UzAWWgtz0IMPlmlhscLb5JMYBZS6jfGR2QlheV4hKr/sgta+dno6jlxc7oW47Hi5Gf nP5lCnadVEDmxgUtS0gSxYzwSNf12wJh+MQiQoRnwGL5DbO0Crhz8MjrNGReLg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772855973; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4PT7+w3JMpwr04lrxlUZt3Iquk2kK08vkjcXmyZeiIU=; b=PAnEFzD9UVT0I3khblM1N48xcjCilphaVjt4Ja07fl1OFAZBuT3lcq/o0gLr14X/Mg42qL eqT+6u77wzlwpaF0lAZ2MqjWLYkFustfAx+m8gD0gAYemzAABI4C1eGEEg0nbFZAGzP+Ft sUmjSO9eCTqTwdrH+04NmSR8XClYHRWIgOwCvjGiUo+IrtBm71ycngNRboSFOZY8hnVt+r RHMtIwJislAW/jrD195mmMCaoBtDDFG5fMFvBdoCmzNoHUsW+fGYFNEOZK6yDmMcgMc6Gs s4n7KGabVvH4h6WAMrjb09VXR8X3c37pW5Lg5owNkEkhCwyaz3dMI3auBe8FKA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSV0524ZlzsWB for ; Sat, 07 Mar 2026 03:59:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3ae2b by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 03:59:33 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: fdc1f3450634 - main - x86: change signatures of ipi_{bitmap,swi}_handler() to take pointer List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: fdc1f34506346fd26db8bfb80ba69d1af844c53a Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 03:59:33 +0000 Message-Id: <69aba2a5.3ae2b.2e02c1b5@gitrepo.freebsd.org> The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=fdc1f34506346fd26db8bfb80ba69d1af844c53a commit fdc1f34506346fd26db8bfb80ba69d1af844c53a Author: Konstantin Belousov AuthorDate: 2026-02-27 03:54:06 +0000 Commit: Konstantin Belousov CommitDate: 2026-03-07 03:58:48 +0000 x86: change signatures of ipi_{bitmap,swi}_handler() to take pointer to the frame instead of the frame itself. It is some stretch of the amd64 ABI, and is not easily fullfilled when handlers are called from C and not asm. In particular, the struct frame is passed by value but is modified by callees, with the expectation that the caller will see the modifications. Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D55679 --- sys/amd64/amd64/apic_vector.S | 2 ++ sys/i386/i386/apic_vector.S | 4 ++-- sys/i386/i386/mp_machdep.c | 14 ++++++++++++++ sys/x86/include/x86_smp.h | 4 ++-- sys/x86/x86/mp_x86.c | 10 +++++----- sys/x86/xen/xen_apic.c | 4 ++-- 6 files changed, 27 insertions(+), 11 deletions(-) diff --git a/sys/amd64/amd64/apic_vector.S b/sys/amd64/amd64/apic_vector.S index 8691387a5a8e..c753ddbad9be 100644 --- a/sys/amd64/amd64/apic_vector.S +++ b/sys/amd64/amd64/apic_vector.S @@ -179,6 +179,7 @@ IDTVEC(spuriousint) INTR_HANDLER ipi_intr_bitmap_handler call as_lapic_eoi KMSAN_ENTER + movq %rsp,%rdi call ipi_bitmap_handler KMSAN_LEAVE jmp doreti @@ -220,6 +221,7 @@ IDTVEC(spuriousint) INTR_HANDLER ipi_swi call as_lapic_eoi KMSAN_ENTER + movq %rsp,%rdi call ipi_swi_handler KMSAN_LEAVE jmp doreti diff --git a/sys/i386/i386/apic_vector.S b/sys/i386/i386/apic_vector.S index 5d248409718d..0037f1c968fb 100644 --- a/sys/i386/i386/apic_vector.S +++ b/sys/i386/i386/apic_vector.S @@ -261,7 +261,7 @@ IDTVEC(ipi_intr_bitmap_handler) cld KENTER call as_lapic_eoi - movl $ipi_bitmap_handler, %eax + movl $ipi_bitmap_handler_i386, %eax call *%eax jmp doreti @@ -306,7 +306,7 @@ IDTVEC(ipi_swi) cld KENTER call as_lapic_eoi - movl $ipi_swi_handler, %eax + movl $ipi_swi_handler_i386, %eax call *%eax jmp doreti diff --git a/sys/i386/i386/mp_machdep.c b/sys/i386/i386/mp_machdep.c index 18ec0d83fad3..0913a0f70d14 100644 --- a/sys/i386/i386/mp_machdep.c +++ b/sys/i386/i386/mp_machdep.c @@ -736,3 +736,17 @@ invlcache_handler(void) wbinvd(); PCPU_SET(smp_tlb_done, generation); } + +void ipi_bitmap_handler_i386(struct trapframe frame); +void +ipi_bitmap_handler_i386(struct trapframe frame) +{ + ipi_bitmap_handler(&frame); +} + +void ipi_swi_handler_i386(struct trapframe frame); +void +ipi_swi_handler_i386(struct trapframe frame) +{ + ipi_swi_handler(&frame); +} diff --git a/sys/x86/include/x86_smp.h b/sys/x86/include/x86_smp.h index 045beb3b0f9a..3fa309df1be1 100644 --- a/sys/x86/include/x86_smp.h +++ b/sys/x86/include/x86_smp.h @@ -98,10 +98,10 @@ void init_secondary_tail(void); void init_secondary(void); void ipi_startup(int apic_id, int vector); void ipi_all_but_self(u_int ipi); -void ipi_bitmap_handler(struct trapframe frame); +void ipi_bitmap_handler(struct trapframe *frame); void ipi_cpu(int cpu, u_int ipi); int ipi_nmi_handler(void); -void ipi_swi_handler(struct trapframe frame); +void ipi_swi_handler(struct trapframe *frame); void ipi_selected(cpuset_t cpus, u_int ipi); void ipi_self_from_nmi(u_int vector); void set_interrupt_apic_ids(void); diff --git a/sys/x86/x86/mp_x86.c b/sys/x86/x86/mp_x86.c index 0c32657290a0..66ad23ee957c 100644 --- a/sys/x86/x86/mp_x86.c +++ b/sys/x86/x86/mp_x86.c @@ -1328,14 +1328,14 @@ ipi_send_cpu(int cpu, u_int ipi) } void -ipi_bitmap_handler(struct trapframe frame) +ipi_bitmap_handler(struct trapframe *frame) { struct trapframe *oldframe; struct thread *td; int cpu = PCPU_GET(cpuid); u_int ipi_bitmap; - kasan_mark(&frame, sizeof(frame), sizeof(frame), 0); + kasan_mark(frame, sizeof(*frame), sizeof(*frame), 0); td = curthread; ipi_bitmap = atomic_readandclear_int(&cpuid_to_pcpu[cpu]-> @@ -1353,7 +1353,7 @@ ipi_bitmap_handler(struct trapframe frame) td->td_intr_nesting_level++; oldframe = td->td_intr_frame; - td->td_intr_frame = &frame; + td->td_intr_frame = frame; #if defined(STACK) || defined(DDB) if (ipi_bitmap & (1 << IPI_TRACE)) stack_capture_intr(); @@ -1729,10 +1729,10 @@ cpuoff_handler(void) * Handle an IPI_SWI by waking delayed SWI thread. */ void -ipi_swi_handler(struct trapframe frame) +ipi_swi_handler(struct trapframe *frame) { - intr_event_handle(clk_intr_event, &frame); + intr_event_handle(clk_intr_event, frame); } /* diff --git a/sys/x86/xen/xen_apic.c b/sys/x86/xen/xen_apic.c index 43a253cc2860..c8760545c8e9 100644 --- a/sys/x86/xen/xen_apic.c +++ b/sys/x86/xen/xen_apic.c @@ -217,7 +217,7 @@ static int xen_ipi_bitmap_handler(void *arg) { - ipi_bitmap_handler(*curthread->td_intr_frame); + ipi_bitmap_handler(curthread->td_intr_frame); return (FILTER_HANDLED); } @@ -296,7 +296,7 @@ static int xen_ipi_swi_handler(void *arg) { - ipi_swi_handler(*curthread->td_intr_frame); + ipi_swi_handler(curthread->td_intr_frame); return (FILTER_HANDLED); } From nobody Sat Mar 7 07:51:19 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7W31Fmz6T2y5 for ; Sat, 07 Mar 2026 07:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSb7W2KVcz3d2n for ; Sat, 07 Mar 2026 07:51:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869879; 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; bh=2giNj2vfQ1VuU1I8Vjfa5C7d8tvPmTzYFGFFxvf15p0=; b=st4F7jCSy3oCQNsLkosKXPQeT5BYUFGuzCqWq2kKX+zjZR08R7cHQpB+AO/dGmoMqhD72f tGCvptKdjOzgQRKWaV7bCCDu1hqmPP0itVKcetlIbtU/hVQuzhOqeqr0UQRrmcx57AuGw9 hXT/E+qW8b70CLNZoHe3SZCyZI1pKa4WiUD31NoFC5ZBdho+PMMaUu0yXf55de63lt+Xz2 GcHLYwmm+QL+nnyD2V3QuLH/Ydtt+r6Au/jAxu6ADCPvY+xJdlw7AIu4EOz5dsRRhh4W5L DSM1wY763TW5Cjm+hkYwTUjmVlBs2jzCyif4zvSKZT5KlgujzkeVnvTtKeLpkg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772869879; a=rsa-sha256; cv=none; b=fGVHL+B5qVIO919UPHnQw3N5d2BJkHR4OihqygDm0bB61ZVsPRH2xefDagTVRBhdsq5oRo TF8bHZjPDb6vG8+DeDzQd0yFW4XJaycYKFkM3EbWCWNJC1gT/RJShUPrxJPBWxJ4VClDId i7maTuSFji0GwEtRqRGYemQEAkPmb/QZD6JvMtEJ83iALlSgIxTmFP543nE7BgWlu5mn3f i4qJaMMZ3+HQRd/ksKYGbjq0p9zyLlil3EWuEHrm7/5Su7Zsiqfx8z/s110gcR/H+I1iiy dRJVHrNTiEnrO5ECYMZIH03YwilwtcB9JTYQXzSX1MBk1UtXMXN1LBngQ0hp6g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869879; 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; bh=2giNj2vfQ1VuU1I8Vjfa5C7d8tvPmTzYFGFFxvf15p0=; b=wXzCHoajhU7eUVbepTKIuTC8XPqyPRDf+4Ia7T9MFKEraV8KdtL9qyQHqf4NXEQtX8MTfy VgscxtFvTgxDbjF1df6bkEYsaByIySN5RO6aiBd0KNWKbVsdtaUgzROJDdzsL1brgTM186 xC978dQq24FYstA8a5wXVNfMEjoq1B0w2GWbHIw1DuT5PvfxhxmtYJahtHN5OWx7K4rkgp o8gBqPjAh9/oC33qORbb/YvpWWAgtnbx7b1JLXheMdQ3vq5inSuHudsb5g+VGmkzvzj9+G ynBRx35s4ZureCZwDdFOjegDHI4M/hLoDHU0IPrWkEWzpAWD6kktAVUbMhsHEg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7W1lDtz10kl for ; Sat, 07 Mar 2026 07:51:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 23881 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 07:51:19 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Perdixky <3293789706@qq.com> From: Warner Losh Subject: git: 9f2eb94736ea - main - Add __unused workaround for linux/sys/types.h List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 9f2eb94736eaf9a86cef75fe54c43c64132ec312 Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 07:51:19 +0000 Message-Id: <69abd8f7.23881.1e686553@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=9f2eb94736eaf9a86cef75fe54c43c64132ec312 commit 9f2eb94736eaf9a86cef75fe54c43c64132ec312 Author: Perdixky <3293789706@qq.com> AuthorDate: 2026-03-05 12:26:03 +0000 Commit: Warner Losh CommitDate: 2026-03-07 07:51:14 +0000 Add __unused workaround for linux/sys/types.h Signed-off-by: Perdixky <3293789706@qq.com> Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/2063 --- tools/build/cross-build/include/linux/sys/types.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/build/cross-build/include/linux/sys/types.h b/tools/build/cross-build/include/linux/sys/types.h index 2e09cbb62271..8d5a798db11e 100644 --- a/tools/build/cross-build/include/linux/sys/types.h +++ b/tools/build/cross-build/include/linux/sys/types.h @@ -56,7 +56,10 @@ typedef uint16_t __uint16_t; typedef uint8_t __uint8_t; #endif +/* contains a member named __unused. */ +#include "../__unused_workaround_start.h" #include_next +#include "../__unused_workaround_end.h" /* * stddef.h for both gcc and clang will define __size_t when size_t has From nobody Sat Mar 7 07:51:20 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7Y2Ffzz6T319 for ; Sat, 07 Mar 2026 07:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSb7X631Bz3dQw for ; Sat, 07 Mar 2026 07:51:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869880; 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; bh=sP7Q5CH6AGRY7oBF82i/GKMDce6B7wriNNE2KS3Jzrc=; b=rfHXvcfFXSX2neGMvPBgKr1wVmldqBp9Pq6gLY3hganfYCVNaTk+023B8zRugIJqZ4bEAD BdgKgxl+OpZDWkt2twRg0HaXHzai19V3chjn96KlbwE+dRQpETb8Rs4ZaDg/OsEWsEqbvR Ps9iFPZu4mDydSQB4lmJWqp2OA+e9Y1CUbWotjTAMZ5k6obkuuei8uCF006CoJJSEBSKNN xFxmRhoG5IJepmDr/mTMlMAK1tUsrDM6G21LogFR4WhEj5Xd2IkAmZg5Bkf3Klq754X7rn dsM66XBhQQScEVJHI14fn4i0khMqpq+aYoJCN2IqSv7DKJj+u8GXuUUyFBOX5g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772869880; a=rsa-sha256; cv=none; b=xuYfYMyTlwmBJ0eT8Xi7YR4ocdhJm8zR4qgySoDzOJ+N0KCbM+UwX1BmoBg/Elzg60eUdL 8rUpAAngJbx2Mv3JJVV5YnF4oUfjmCZIl1zVoYoACJGXa0Kt3aLzwAJGsb5mZTXICwIIzU ScA05vizvVDLDWcnXNgkAB4HzT8+d1OzAECOjIf27viJ+oVuOqfyVQs9uFLuImjNnk9VUp r6+ta1j2xiNUXZevh1H9JnFUXzTYOO5HcoMaAgxJd+vjAM2ncP5RR6D4bseW8UhTssKhnJ 1Mnyrbu/vfio5N7/o2xWYuUbgOiJlAu74G1i1BKLy8tkAhUb2UTq2Rm71WFzMw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869880; 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; bh=sP7Q5CH6AGRY7oBF82i/GKMDce6B7wriNNE2KS3Jzrc=; b=DQdeM3bxfvfQ/c8ifB5vutrcgIMmGhTKNuOtziac9YXAy7hslektt7e1YvNRPBC86HnNme jUG3s8Ht2iDzSgZLTU3Qirc4m9xbQAiGZmfcxA7uYFA4SRXKoykISxpiiL7900vNH8RJwh H/kkrYAcEUnSLLLKsURckDAri9RoLNyZtvRDwqA0d4ittTuG/Hx/4qMHEYFNPL7vZUnVn/ pNbIInLOR3ier9t8jlXPnJ34O3TGcqUkKZxyJ4F62PbNICHViA9w7AMV72Hs3tnoKOMaVw FKYlEfurZuELU3crFYFy0V9f9jnKnGM1ZZSS9plAcgpQDZmm/9TjJzpX78slHA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7X2XWnzyy0 for ; Sat, 07 Mar 2026 07:51:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 23a88 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 07:51:20 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: tslight From: Warner Losh Subject: git: cecd12ac3b4d - main - use ASMC_FAN_FUNCS2 to avoid trying to read non-existent keys List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: cecd12ac3b4d98bd52dc0e802a4a38bc72f50e2c Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 07:51:20 +0000 Message-Id: <69abd8f8.23a88.50c6ac0b@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=cecd12ac3b4d98bd52dc0e802a4a38bc72f50e2c commit cecd12ac3b4d98bd52dc0e802a4a38bc72f50e2c Author: tslight AuthorDate: 2026-02-26 07:44:44 +0000 Commit: Warner Losh CommitDate: 2026-03-07 07:51:15 +0000 use ASMC_FAN_FUNCS2 to avoid trying to read non-existent keys Signed-off-by: tslight Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/2051 --- sys/dev/asmc/asmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/asmc/asmc.c b/sys/dev/asmc/asmc.c index 726d52874026..be2d0a118bda 100644 --- a/sys/dev/asmc/asmc.c +++ b/sys/dev/asmc/asmc.c @@ -305,7 +305,7 @@ static const struct asmc_model asmc_models[] = { { "MacBookPro11,4", "Apple SMC MacBook Pro Retina Core i7 (mid 2015, 15-inch)", - ASMC_SMS_FUNCS_DISABLED, ASMC_FAN_FUNCS, ASMC_LIGHT_FUNCS, + ASMC_SMS_FUNCS_DISABLED, ASMC_FAN_FUNCS2, ASMC_LIGHT_FUNCS, ASMC_MBP114_TEMPS, ASMC_MBP114_TEMPNAMES, ASMC_MBP114_TEMPDESCS }, From nobody Sat Mar 7 07:51:21 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7Z1CY9z6T33K for ; Sat, 07 Mar 2026 07:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSb7Y4qN9z3dHb for ; Sat, 07 Mar 2026 07:51:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869881; 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; bh=Bc/5GSWnu5enIQ4ZA70yqGZhn1Im0ekLxlFBng4QUEw=; b=tvMu7Y2xjDbsGKNIrw3BWbdSU+eXBkugukTB9K9TtAcyTZiqhf5pNAFeyBcO0WdisQ44Te NWepK1TrUKlsPo6x9FcXggBDUVQiBFo7S5GhpUpx/OZph0xVk1/bYlCsD1lX8ZsI/4ROB+ bbrtaf/qMdcBNsHP/bZYptHZkxB0mKjIfU05DbF5n9KjD0gGFeSt/bJPzAQBHxgnm18voj niu33g4HosCJc43JUQLmtkxmXbP614GhYzRhVJzcuhMN3M1SIDTss3a008ayiSu5QsspEP aKRCid/7ioibBHxvzqd67EHlFISzkgZtkbaGu6YPZPxsOCuR/9RnvrY75xsgJQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772869881; a=rsa-sha256; cv=none; b=aF85LesAv83VdLGRPejNxCw/8cibuliRb6oQCYe6e+tHbuJhRA/UY0x4alnbAn8BPD7uYu nSIXBSdFgEtoJNxVa4qMwmlw/gLfgEmHsH3LG86gubIYYo0KYoC9RAlvLuXS5d+bqSoaA7 XO/0onC2EGvTBxYIpbPvTL6pzBG5YqiSa1rVDlijPFjRR10BsTAiuX854odxvz4krxeNKG vg/zpTNu1daQ6fAJ9VBeCz0j2iddGm35n4egF9cPt0NwUCrEQG9fmUrmdgFzBUUwLsufDv Z0HC/fRMF0rZQhcuz7PCvPXNz1TmGORAOyHZDDjWw9vEje/rR15gwCNV/gDenA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869881; 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; bh=Bc/5GSWnu5enIQ4ZA70yqGZhn1Im0ekLxlFBng4QUEw=; b=QNNetNN85m9tjRUjG5Q9PZU8gk/I+T4ICn6OTOZY4xICE5+pR0sgqPIGP3B2YvatjZWlXu l7z9xN1reuQxyB9FFce7CHku2UPNEYHg6ikfABzyoUI17HfIhWu19GAsDXLyyX5hJDG5rG zNX/MbFPM9XIGXs4NAEQWLWPgiunnLaqxf/VH5B922leAP6Me9ksKkFZb+z8ROy0qid/6l JDTwCOyaFta3Obd+73lq165huhGKG25apeU3UhhcMSg52TTdF6px0l6AM3eMnlsSXDfed8 EjGUMY52UhUPz26XAAl+htk4yxyr0cHNRC1PF0XX1QGIj1O2dMzhjJnrOCCqDA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7Y3GWWz10Vb for ; Sat, 07 Mar 2026 07:51:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 23dae by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 07:51:21 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Minsoo Choo From: Warner Losh Subject: git: 75858ca528bf - main - Add .editorconfig List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 75858ca528bfdef7101ac493baa1b43616c4153c Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 07:51:21 +0000 Message-Id: <69abd8f9.23dae.41d7461e@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=75858ca528bfdef7101ac493baa1b43616c4153c commit 75858ca528bfdef7101ac493baa1b43616c4153c Author: Minsoo Choo AuthorDate: 2026-02-15 19:14:28 +0000 Commit: Warner Losh CommitDate: 2026-03-07 07:51:15 +0000 Add .editorconfig FreeBSD developers use different text editors or sometimes use GUI editors such as VSCode or Zed on different platforms for convinence. However, there is lack of unified config for those editors to follow style(9) including indent rules. Although most "modern" editors support .editorconfig out of box, basic editors such as vim needs a plugin for autoloading .editorconfig file. Sponsored by: The FreeBSD Foundation Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/2024 --- .editorconfig | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 000000000000..14970af1e2dd --- /dev/null +++ b/.editorconfig @@ -0,0 +1,23 @@ +[{contrib/**,**/contrib/**,kerberos5/**,krb5/**,crypto/**,sys/crypto/openssl/**}] +ignore = true + +[{*.{awk,c,dts,dtsi,dtso,h,mk,s,S},Makefile,Makefile.*}] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +indent_style = tab +indent_size = 8 + +[*.py] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +indent_style = space +indent_size = 4 + +[*.{yaml,yml}] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +indent_style = space +indent_size = 2 From nobody Sat Mar 7 07:51:18 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7b5Gzcz6T33R for ; Sat, 07 Mar 2026 07:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSb7b1sKvz3dWj for ; Sat, 07 Mar 2026 07:51:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869883; 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; bh=D+OUNyi++LWsQxoVgCs4K/JszyKbMM03aKRxqr6Km5g=; b=bwBqMvjNfqhNUECI8dtpTboxiDb2ROUcGG2QYVyh00XReOjFDiNT7MQTnfxjNiXRzqdiiZ CwypY1/YRwQr33EUNbeSdg+BxLvSnZIW/6balNDJOMGag4VQxj3JBw1bsgUAbsLwR/qvMq bMAGQpE3VTtNr68vJRCbWQh5gUfiefvt/ihejREoTFI0MB4OFtFbsAvTxC+mYysp9Tz8t2 btLF9EJTky99cmUt+zZh0tehWB+5m3psxZxU8vcywTgouqMkOAJRH7Gs+NVVmYoizPYdrN ihkTP3Gjr8tWgIYLVUNY/3FW8oCtUrFHNq/6NdrLRlyL201v/iiQINTKze/BLw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772869883; a=rsa-sha256; cv=none; b=MyEsFbVveyK2QEbH+/h5b533ugp0dCnCmtVHcsnVS4wQ4zxyok1QX+g0ofQnQodw66szJQ /Vtrvk5cd6CsPRJ03by76gpysP/xpdexO39fK0qBpQYwgLYs40zZ6H/Fr8UGytkfoxWXz9 lDskP6xD852OjOylxSlRTRSEalPSpmPu4aC3L/rLzlFrq2yrAurYOC+ODc7U8mntG3WzY5 aRIT+AFf1dxsZ3x8gd4qgSF+rk5b5TJc6cH8geG5daUqBO9B5KS/SF4+FXmeLib119n/fr MPkUlKcBGDmhOkFNrCjPJ3xcjy06gzZVCLU5KVqxIqGpMTiZ8rLEXJ3k6lsC4g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869883; 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; bh=D+OUNyi++LWsQxoVgCs4K/JszyKbMM03aKRxqr6Km5g=; b=Tjbu4gDGSJRj7N9fEJ2PDGdnW6tLznOv0A/jKqLjoOLp2m2Qzv+v1tcBJJDW3ZG0cq1w7e QGYb6PHC0X+7KivBYuxBVsnRk+5yibjlLQ3Hyeba9Nn7xuNk8SmBKj/iR3E1BT9ZkSdtqD hpoafvLSsboZ+S1otNzHPwryIyQfLotQbNQ7jiET0spQB/rpXcVXS/b7x9ntSluGCJvJbk +iHA18pPxQhM4SQC2PqMDSRdKMlylXP55w72La8/JusdP98zWoccm1u7jIGZAXZd7brzN6 dtQtimSu/RXajVJ/gyQ/MbW+nInBYPjp1GNTFuXg95T3AFboD8pY2ypLrfbJ1Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7b1MGnz10lZ for ; Sat, 07 Mar 2026 07:51:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 22553 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 07:51:18 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Jamie Landeg-Jones From: Warner Losh Subject: git: 9006a731bc95 - main - /bin/ps: Fix display of negative nice values on ARMv7/aarch64 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 9006a731bc951c5b62efc4bf75a0c5b42586d279 Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 07:51:18 +0000 Message-Id: <69abd8f6.22553.76e52a6f@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=9006a731bc951c5b62efc4bf75a0c5b42586d279 commit 9006a731bc951c5b62efc4bf75a0c5b42586d279 Author: Jamie Landeg-Jones AuthorDate: 2026-03-07 01:18:20 +0000 Commit: Warner Losh CommitDate: 2026-03-07 07:51:14 +0000 /bin/ps: Fix display of negative nice values on ARMv7/aarch64 On Arm-based systems (and maybe others), 'char' defaults to unsigned, causing negative nice values to be displayed incorrectly (e.g., 246 instead of -10). Explicitly using 'signed char' ensures consistent behaviour across architectures. [ tested on RPI2 and generic aarch64 qemu install ] Before: # /usr/bin/nice --10 ps -l | awk '(NR == 1 || $(NF-1) == "ps")' UID PID PPID C PRI NI VSZ RSS MWCHAN STAT TT TIME COMMAND 0 23606 22800 2 -32 246 5400 2544 - R<+ 0 0:00.06 ps -l After: # /usr/bin/nice --10 ps -l | awk '(NR == 1 || $(NF-1) == "ps")' UID PID PPID C PRI NI VSZ RSS MWCHAN STAT TT TIME COMMAND 0 23614 22800 3 -32 -10 5400 2544 - R<+ 0 0:00.05 ps -l Signed-off-by: Jamie Landeg-Jones Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/2064 --- bin/ps/keyword.c | 2 +- bin/ps/print.c | 3 +++ bin/ps/ps.h | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/bin/ps/keyword.c b/bin/ps/keyword.c index 0562fd2e4f9d..d7790f9f8c48 100644 --- a/bin/ps/keyword.c +++ b/bin/ps/keyword.c @@ -133,7 +133,7 @@ static VAR keywords[] = { {"mwchan", {NULL}, "MWCHAN", "wait-channel", LJUST, mwchan, 0, UNSPEC, NULL}, {"ni", {"nice"}, NULL, NULL, 0, NULL, 0, UNSPEC, NULL}, - {"nice", {NULL}, "NI", "nice", 0, kvar, KOFF(ki_nice), CHAR, "d"}, + {"nice", {NULL}, "NI", "nice", 0, kvar, KOFF(ki_nice), SCHAR, "d"}, {"nivcsw", {NULL}, "NIVCSW", "involuntary-context-switches", USER, rvar, ROFF(ru_nivcsw), LONG, "ld"}, {"nlwp", {NULL}, "NLWP", "threads", 0, kvar, KOFF(ki_numthreads), diff --git a/bin/ps/print.c b/bin/ps/print.c index f59e843effc1..9705d0c07419 100644 --- a/bin/ps/print.c +++ b/bin/ps/print.c @@ -754,6 +754,9 @@ printval(void *bp, const VAR *v) case CHAR: (void)asprintf(&str, ofmt, *(char *)bp); break; + case SCHAR: + (void)asprintf(&str, ofmt, *(signed char *)bp); + break; case UCHAR: (void)asprintf(&str, ofmt, *(u_char *)bp); break; diff --git a/bin/ps/ps.h b/bin/ps/ps.h index 065a4c1f1c54..8352f3450f93 100644 --- a/bin/ps/ps.h +++ b/bin/ps/ps.h @@ -33,7 +33,7 @@ #define UNLIMITED 0 /* unlimited terminal width */ enum type { UNSPEC, /* For output routines that don't care and aliases. */ - CHAR, UCHAR, SHORT, USHORT, INT, UINT, LONG, ULONG, KPTR, PGTOK }; + CHAR, SCHAR, UCHAR, SHORT, USHORT, INT, UINT, LONG, ULONG, KPTR, PGTOK }; typedef struct kinfo_str { STAILQ_ENTRY(kinfo_str) ks_next; From nobody Sat Mar 7 07:51:22 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7b3bhKz6T33M for ; Sat, 07 Mar 2026 07:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSb7Z4Qhfz3d3K for ; Sat, 07 Mar 2026 07:51:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869882; 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; bh=mcpVdq3wooCcEci0u8+UETiWVATZw3VZdWlYZIoi/zI=; b=uR6t6ZZW5nv7msvgZwmxbSYAdHnABw44PwLoobLcazI3RHfZRFLXaXVxnXXQOLjWKuyz/g jUggEkQpWb8JkKJ6lgMmexc3Qnf1WyUDuvA5lfvOa0f7NQ3bbVfP0iMGCHcCFCY0vNuXic cI0o+xJ5fkh4VGFfCvGgOJm8GJI9l5Y+1XcF3mdIVSg+RzVFLkOWHWkzdieQrYVh/rzHuv 0UGEdJnloCW7rroP0ZFlezeTI0l3ghGTjABcpUz+Q3wwUKXRdn84+yichAiLHPv5r9p0HS MKPMyvshAsVQePorse0v4ZHJ4WEculOGYuKl3eK2VteXiQtLrMk4riQauB44Qw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772869882; a=rsa-sha256; cv=none; b=vngIT9bVJmCjB89iHK75r0mbR7GtYxi9O7ZMT7iZYKSWO4cEWzzJpOMFhyFsCXjEbxuw5H jHESWRARvVFxByuOQB9EAdh0X9jqq0Gjka4pmcuTBP6TJBMa7Pi4JTt9fKClssWBEQAppK oT0fpgLdeGdudS4Dx1qGMDwfppGgGZgWVKHH6FkaEekmnrfyMRWg5tpZkSDlNcXSqD9PzN uHICRwzlyg5GcT41PzxNJm/iLKiNKhcOXrYqwkErN5C10Wjc/Obdu4+UV/ompMCM3W0PSf R1rwPjOxHWOJxZUCPHJxk8fw9p3lJqiXL4ptnqtIlzgCOt2TzLWUFKuIqn2pOA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869882; 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; bh=mcpVdq3wooCcEci0u8+UETiWVATZw3VZdWlYZIoi/zI=; b=jvGNAom27r8LkWlTumuUB8cBuVEnbu1PW1JYdVyzwOnOSDDQostCcT3B2Ajk+CC0CTqARh l8N6erckDBP/jr/78H/xEJOXHwk4Li4iS9Ct3mirPpPp3OoC3Ebtg3YtOHctrBvxnH9l9v 3zpeoc7/WGB6T516xAAqFSk/RNQ6Zkfd55NJb6URWmYU45yOSjx6BzFtI5cYtQTgQ8+kkE oO6Lvk74KESEUpsOyeg4SM0c/URv23e5VIsW9XuTpCyw3nlvP1/WlJBc3S0Zf3eEBKpD8c vY/5Pnuw7RARqQIFg5Xo0RWiXxKZib4fWyu4EoC868au1JyCAS2MiGM4PgOb0g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7Z3zM5z10Vc for ; Sat, 07 Mar 2026 07:51:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 24004 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 07:51:22 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Kalevi Kolttonen From: Warner Losh Subject: git: 3be98a0c86f9 - main - Fix hooks.sh comment typo List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 3be98a0c86f956604be58a14c6a9bfe2f25af2d8 Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 07:51:22 +0000 Message-Id: <69abd8fa.24004.62776a27@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=3be98a0c86f956604be58a14c6a9bfe2f25af2d8 commit 3be98a0c86f956604be58a14c6a9bfe2f25af2d8 Author: Kalevi Kolttonen AuthorDate: 2026-02-10 23:15:51 +0000 Commit: Warner Losh CommitDate: 2026-03-07 07:51:15 +0000 Fix hooks.sh comment typo Signed-off-by: Kalevi Kolttonen Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/2013 --- libexec/rc/hooks.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libexec/rc/hooks.sh b/libexec/rc/hooks.sh index af4aff3d6bc5..0c577d831101 100755 --- a/libexec/rc/hooks.sh +++ b/libexec/rc/hooks.sh @@ -71,7 +71,7 @@ if local_works > /dev/null 2>&1; then else _local=: fi -# for backwards compatability +# for backwards compatibility local=$_local From nobody Sat Mar 7 07:51:23 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7c0B9Pz6T2k2 for ; Sat, 07 Mar 2026 07:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSb7b59YLz3dWq for ; Sat, 07 Mar 2026 07:51:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869883; 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; bh=kAP/6EDLjG9OWwxEmM5y8IJeGbKNlCUayqhOzxrEbGg=; b=Wp8jpfLVr1/W+84FkGtYRq7wP6oecxVLzeZ4Qhdp72EUvOsm1K0Q97qhIcP0duJlnRvk/Z d9E3CqoljfW3trzCG9CWOu9eW0AQSfkFIA1lPuk2or35V3FQ3U2ndogBTFyWGaV70eqB3l h76Nl++pBNe7zFM65dvTNwLh9gAaYnj3pYwzG/DND4CU04u2YnmyFBy3Ou785PJOq66Z17 6olktZQ5uXuQ0WyQBT+220mQ7DmUGo7cTpixqYImi0Ca3IPFsY0GX3r9NcAAe1ANiy/ycF uaGBwZJEKWuPIXh4LRtn/IrRHHIjLx55HcGtv3BRdW0JHd4utD4NOuobXHK7ug== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772869883; a=rsa-sha256; cv=none; b=pOO/lpT0D+cLeIZdKYBkXU5czO8DXwrE+avdVufw6mX34+A6vrJ0b553CkDNBDbH9HD8H0 DigH+FkbywECmAIFRhobaYnepWUbFDaOmEBEKMf48BaD6jwa0rrXhUQ0AXIqQ0xxoOFq+S r/Gou5T5vN2joF7pPOpPyMa/Xfvg2emyJaP5JOoHQ1romWthijUX55EAV2Hi4HNuVLKuXZ 755g/01+H2z02RsFx/g2YeA0E68mUUYQi9BRRcYcX2o+A3UpjwWB46jF+hOWEriPKVyglN i0R11JyvUDCEsCAKenPbpzkTEjcnQJgqumtF2FL8WPaoaRxyfgXKg2IV6TfCvA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869883; 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; bh=kAP/6EDLjG9OWwxEmM5y8IJeGbKNlCUayqhOzxrEbGg=; b=mAJe7+D+DKuRawCN7MpVadkN/yT+fc2c82/isT+35+2DgkNkqMHK/BNEogm93hMcA/8hmI 64t0Ln8e6RciqZ3n+RzjgqfKSLFbFVZT0bIbU0rWHeGPUfiztnAO1BSJfg+WYhT8l7BJs+ r4IYjUG8twZubBAp3qdC3kLHyavxZfqtSfRMcVAcFocDtgF1JwvjmH277YTcLhZ4EMxv90 W3F5noU3aubOtLnBjmHHINtsCeT+BTYI1wBQV4/2dYq8pNeIZn0bSABQNzhbxPIzVhV217 xeif3Ne/bKiV1RHBSLs4OVvGpRg+U2vpVCZsxAb/VkI5MZgRTyqE3OSodjH/zw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7b4h2gz10rL for ; Sat, 07 Mar 2026 07:51:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 23a39 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 07:51:23 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Kalevi Kolttonen From: Warner Losh Subject: git: d7922c3d2391 - main - Fix debug.sh comment typo List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: d7922c3d2391c6db3dac77fa491d53e080162c79 Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 07:51:23 +0000 Message-Id: <69abd8fb.23a39.56e23af8@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=d7922c3d2391c6db3dac77fa491d53e080162c79 commit d7922c3d2391c6db3dac77fa491d53e080162c79 Author: Kalevi Kolttonen AuthorDate: 2026-02-10 23:02:49 +0000 Commit: Warner Losh CommitDate: 2026-03-07 07:51:15 +0000 Fix debug.sh comment typo Signed-off-by: Kalevi Kolttonen Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/2012 --- libexec/rc/debug.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libexec/rc/debug.sh b/libexec/rc/debug.sh index 4284a6e3b5fb..ea46e9a99c0c 100755 --- a/libexec/rc/debug.sh +++ b/libexec/rc/debug.sh @@ -439,7 +439,7 @@ DebugShell() { return 0 } -# For backwards compatability +# For backwards compatibility Debug() { case "${DEBUG_SH:-$DEBUG}" in "") ;; From nobody Sat Mar 7 07:51:24 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7d0nJ5z6T38P for ; Sat, 07 Mar 2026 07:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSb7c5y2hz3dnG for ; Sat, 07 Mar 2026 07:51:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869884; 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; bh=53G4m5Fn7Da8OvIjF3cHw71dwRrzqOcDqgSRPf/5vAU=; b=i0ejqIkpS9dXUKI7y+VH562dtJDQX7C23YJdJcsKqqOi40y5A0Xe8JQQmMOF/Rh5aOz7JI BGIjVxNOMfwn4QzTJfZO/GxFoPG0L2jABuftyAX1MeJVmonY8lkdpPAwGZD31FLV46yW88 YjdrQgn3DX6t2VNQZQu914ZyrQ9q6m2N+q4oekP5K5gL2Zkj78340zlwv0DzJ9/1yE09Xm aLBmy+CYIebYuwKApa3RvkbSPbWgiGrS451wo5955w+ItRoP+xl6N3KZgWwbBxw6o6MWgf O5YkLm421a9SY/hzGHb7ihxhafmBxqh1iUr4qmN+1spl09OHeI2lEBWhqW+Wqw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772869884; a=rsa-sha256; cv=none; b=mWXd1juwQ4mFTL5tDT4F9FVnLbidwnHQ4hmqmXptKumTCF/TvS6tVnMh+BDTuTU1PtsNVn t+6mkJ7F7oaPQyCRRGzt/NYOZtrXlb7YR/1tpVJ9va9vxXqVVxw3AlIPJ/ihUPbiI2/qvN KZD047cU2jqkFgaMr47py//Eg2eZn3D1VX1VvL331iAPaPlrE4k6LzYUIMuugbRaSA2Xv+ +dhoaVnhnUD7xQMMlnbwPTSG1WiWurwTSEZw1ZRnwuSaq759HO7TNTaL5lAdJq6mvkcOrY y/+FDhSfqSxhC86n0mMQL+shpwTbNzUJMam5jg368hfVRP0namNaLbWQ7TXbpw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869884; 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; bh=53G4m5Fn7Da8OvIjF3cHw71dwRrzqOcDqgSRPf/5vAU=; b=Ke3JMpMRbI9snT4ksivTvs1khtlQjrnsAuwrLCTYRhJfJhzS+dPSHkFUDa5Cny1/K/Ktox 8XRtitUA6Iii2/UowMfM/s4tjs98OVhKHPH3quZV4WzmvDWPvG7RdT74BHyqX2FF3GveCu DqRVdI3QEzs/3V6BY2VcRPx3at1Km64k71OdMXBNUb6r3TyNGDyIKNNGUipsK7zVixf3lG Pv9uXVhNW4wTpBF1ErVzQuuqwkr3QQi9ckH23riDrn7e2g/32h2zVNHLA13DE2x4Ldm66J NcpX53KuADPPF+JtOX5n3AkaRPGXqN6Fqq9sKiIlWhX2hSn+XOsLUB9pACQsHw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7c5RsHzyy3 for ; Sat, 07 Mar 2026 07:51:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 22edc by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 07:51:24 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: tslight From: Warner Losh Subject: git: 16c82e28404e - main - Add ASMC support for Macbook Pro 8,3 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 16c82e28404ec959a7335ceae1d4f43881a50d9e Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 07:51:24 +0000 Message-Id: <69abd8fc.22edc.3d1af6e2@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=16c82e28404ec959a7335ceae1d4f43881a50d9e commit 16c82e28404ec959a7335ceae1d4f43881a50d9e Author: tslight AuthorDate: 2026-01-27 16:44:40 +0000 Commit: Warner Losh CommitDate: 2026-03-07 07:51:15 +0000 Add ASMC support for Macbook Pro 8,3 Signed-off-by: tslight Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1992 --- sys/dev/asmc/asmc.c | 6 ++++++ sys/dev/asmc/asmcvar.h | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 39 insertions(+) diff --git a/sys/dev/asmc/asmc.c b/sys/dev/asmc/asmc.c index be2d0a118bda..17a282ce0b97 100644 --- a/sys/dev/asmc/asmc.c +++ b/sys/dev/asmc/asmc.c @@ -279,6 +279,12 @@ static const struct asmc_model asmc_models[] = { ASMC_MBP82_TEMPS, ASMC_MBP82_TEMPNAMES, ASMC_MBP82_TEMPDESCS }, + { + "MacBookPro8,3", "Apple SMC MacBook Pro (early 2011, 17-inch)", + ASMC_SMS_FUNCS, ASMC_FAN_FUNCS2, ASMC_LIGHT_FUNCS, + ASMC_MBP83_TEMPS, ASMC_MBP83_TEMPNAMES, ASMC_MBP83_TEMPDESCS + }, + { "MacBookPro9,1", "Apple SMC MacBook Pro (mid 2012, 15-inch)", ASMC_SMS_FUNCS_DISABLED, ASMC_FAN_FUNCS, ASMC_LIGHT_FUNCS, diff --git a/sys/dev/asmc/asmcvar.h b/sys/dev/asmc/asmcvar.h index 5afc1012849c..95a117f59533 100644 --- a/sys/dev/asmc/asmcvar.h +++ b/sys/dev/asmc/asmcvar.h @@ -335,6 +335,39 @@ struct asmc_softc { "TMBS", "TP0P", "TPCD", "TW0P", "Th1H", \ "Th2H", "Tm0P", "Ts0P", "Ts0S" } +#define ASMC_MBP83_TEMPS { "ALSL", "F0Ac", "F1Ac", "IB0R", "IC0R", \ + "ID0R", "IG0R", "IO0R", "PCPC", "PCPG", \ + "PCPT", "PD0R", "TB1T", "TB2T", "TC0C", \ + "TC0D", "TC0P", "TC1C", "TC2C", "TC3C", \ + "TC4C", "TG0D", "TG0P", "THSP", "TP0P", \ + "TPCD", "Th1H", "Th2H", "Tm0P", "Ts0P", \ + "VC0C", "VD0R", "VG0C", "VN0C", "VP0R", NULL } + +#define ASMC_MBP83_TEMPNAMES { "ambient_light", "fan_leftside", "fan_rightside", \ + "battery_current", "cpu_vcorevtt", "dc_current", \ + "gpu_voltage", "other", "cpu_package_core", \ + "cpu_package_gpu", "cpu_package_total", "dc_in", \ + "battery_1", "battery_2", "cpu_die_digital", \ + "cpu_die_analog", "cpu_proximity", "cpu_core_1", \ + "cpu_core_2", "cpu_core_3", "cpu_core_4", "gpu_die_analog", \ + "gpu_proximity", "thunderbolt", "platform_controller", \ + "pch_die_digital", "right_fin_stack", "left_fin_stack", \ + "dc_in_air_flow", "palm_rest", "cpu_vcore", "dc_in_voltage", \ + "gpu_vcore", "intel_gpu_vcore", "pbus_voltage" } + +#define ASMC_MBP83_TEMPDESCS { "Ambient Light", "Fan Leftside", "Fan Rightside", \ + "Battery BMON Current", "CPU VcoreVTT", "DC In AMON Current", \ + "GPU Voltage", "Other 5V 3V", "CPU Package Core", \ + "CPU Package GPU", "CPU Package Total", "DC In", \ + "Battery Sensor 1", "Battery Sensor 2", "CPU Die Digital", \ + "CPU Die Analog", "CPU Proximity", "CPU Core 1 DTS", \ + "CPU Core 2 DTS", "CPU Core 3 DTS", "CPU Core 4 DTS", \ + "GPU Die Analog", "GPU Proximity", "Thunderbolt Proximity", \ + "Platform Controller Hub", "PCH Die Digital", \ + "Right Fin Stack Proximity", "Left Fin Stack Proximity", \ + "DC In Proximity Air Flow", "Palm Rest", "CPU VCore", \ + "DC In Voltage", "GPU VCore", "Intel GPU VCore", "PBus Voltage" } + #define ASMC_MBP91_TEMPS { "TA0P", "TB0T", "TB1T", "TB2T", "TC0E", \ "TC0F", "TC0P", "TC1C", "TC2C", "TC3C", \ "TC4C", "TCGC", "TCSA", "TCXC", "TG0D", \ From nobody Sat Mar 7 07:51:25 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7f38cKz6T31M for ; Sat, 07 Mar 2026 07:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSb7d6Z0pz3dNY for ; Sat, 07 Mar 2026 07:51:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869885; 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; bh=jluR2oCqBGKXOkKewvWvMNMZD9A3ekkqpWJ7f3wwNjc=; b=xC/DyLUqM5NM3ez4GfPCvsssVBwSKy7XSLA5uLmSYARX86fuabTYWHQayfljTaLD8u3JOM MaxOneOCF0mBaEob/ZW5HbMOiMbLK/jaLVl5u/b9Ze3DlvPEijvTTlrGk+rXEvxzDRRkai nAPrtQRg1i7DMy4122tF0S2bxraPkkuXAbn8R+van0YjaweQ7GbEjoGXYlWnAfitpyx/U5 4fSOlGpFDIUoJwKg+RdQvZy45FSwnQh2tLIpvWZ4gAc4/lNyfRll1JcZ1igOM4WvRkSREL AzY/NjYROh6UilBs9n5SbkyoDZQNX6xBxi2FwBU+sGuzc+3AQFvwOZjlN1SyAQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772869885; a=rsa-sha256; cv=none; b=JlWgLr6jGZvY1y1wCKJJtEwRZCfCCtMAL8DOoE23J3QMH4Rtbx7Fsu7LjGIfAcNDilgxIg zhACLcBOqSzkuVd5y3nlIioP3ts9GmsKG9WXQkUPdIDIz7MZe+l6v4y0QPhzDA9BYhB9mF 3mUTlXtuqJf/IJNE3so3UE+nOvAzUm7kPNGnNbKuRsblTSjx6ih0buZZi3j3u+cvkGbrQg xxn+XIDneebZV7SMZM5x99+zxuOfUqO/QWisTFsVfpBYbInwZv+qAqlBWOJPlWc6nAirTO dXS+xbalBWXf0zfbK7ESBXnvN+WlUjM72hoqrbhKXIBmaIzf1AzLAcAlgegE4g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869885; 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; bh=jluR2oCqBGKXOkKewvWvMNMZD9A3ekkqpWJ7f3wwNjc=; b=Xq5mmg6Yq/QwUQd9SxJIKQexx5hI1yzkvmqwzHBVaS9xAAX4PWLh/rjs8EnLeU1+C0nn5A Dst/6FrQlVhNt8JhIHn3gTs3R6E6h54Nt47EvV3U/f9HTA+0KU2NSJgX7eaNLZHtuQBHIf 9IWlXMqkfgD7ijRJZv+6htfRNjNeauD7QT5XJNXoH4j7iN61zmTRTK8hrcIgpYq8iRVU/s dNGQLsdOxTzqxvpaBzFxRqgAdReqEvC290EASL26dRkTFhS0RPBWSlDSZSqcSsm2ma14Cb zEuAE/7BD6bI+uBYTveA+pGvvxsF1pyRYhr5ba5yVmu59umelueexOcHj9hukg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7d5zgcz10kw for ; Sat, 07 Mar 2026 07:51:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 23d45 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 07:51:25 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: NVSRahul From: Warner Losh Subject: git: 3570b19d74ed - main - uuidgen: generate UUIDs in bounded batches to respect kernel limit List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 3570b19d74ed94dcc7fac2dcbf42b378bc72362e Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 07:51:25 +0000 Message-Id: <69abd8fd.23d45.61b5f1e@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=3570b19d74ed94dcc7fac2dcbf42b378bc72362e commit 3570b19d74ed94dcc7fac2dcbf42b378bc72362e Author: NVSRahul AuthorDate: 2026-01-13 05:52:06 +0000 Commit: Warner Losh CommitDate: 2026-03-07 07:51:16 +0000 uuidgen: generate UUIDs in bounded batches to respect kernel limit The uuidgen(2) system call enforces a hard upper limit of 2048 UUIDs per invocation. uuidgen(1) previously attempted to generate arbitrary counts in a single call and allocated memory accordingly, leading to EINVAL errors, unnecessary memory usage, and potential overflow risks. Generate UUIDs in fixed-size batches, streaming output incrementally while preserving existing semantics. Mirror the kernel limit explicitly since it is not exposed via a public interface. Signed-off-by: NVSRahul Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1965 --- bin/uuidgen/uuidgen.1 | 4 --- bin/uuidgen/uuidgen.c | 85 ++++++++++++++++++++++++++++----------------------- sys/kern/kern_uuid.c | 2 +- sys/sys/uuid.h | 6 ++++ 4 files changed, 53 insertions(+), 44 deletions(-) diff --git a/bin/uuidgen/uuidgen.1 b/bin/uuidgen/uuidgen.1 index f7911b408f36..f88ea8d8631d 100644 --- a/bin/uuidgen/uuidgen.1 +++ b/bin/uuidgen/uuidgen.1 @@ -56,10 +56,6 @@ This option controls creation of compact UUID (without hyphen). .It Fl n This option controls the number of identifiers generated. By default, multiple identifiers are generated in batch. -The upper hard limit is 2048 -.Po see -.Xr uuidgen 2 -.Pc . .It Fl o Redirect output to .Ar filename diff --git a/bin/uuidgen/uuidgen.c b/bin/uuidgen/uuidgen.c index 3e2c0324a959..bcb7a45b665d 100644 --- a/bin/uuidgen/uuidgen.c +++ b/bin/uuidgen/uuidgen.c @@ -26,7 +26,9 @@ * */ +#include #include +#include #include #include @@ -156,46 +158,51 @@ main(int argc, char *argv[]) if (count == -1) count = 1; - store = (uuid_t *)malloc(sizeof(uuid_t) * count); - if (store == NULL) - err(1, "malloc()"); - - if (!iterate) { - /* Get them all in a single batch */ - if (version == 1) { - if (uuidgen(store, count) != 0) - err(1, "uuidgen()"); - } else if (version == 4) { - if (uuidgen_v4(store, count) != 0) - err(1, "uuidgen_v4()"); - } else { - err(1, "unsupported version"); - } - } else { - uuid = store; - for (i = 0; i < count; i++) { - if (version == 1) { - if (uuidgen(uuid++, 1) != 0) - err(1, "uuidgen()"); - } else if (version == 4) { - if (uuidgen_v4(uuid++, 1) != 0) - err(1, "uuidgen_v4()"); - } else { - err(1, "unsupported version"); - } - } - } - - uuid = store; - while (count--) { - tostring(uuid++, &p, &status); - if (status != uuid_s_ok) - err(1, "cannot stringify a UUID"); - fprintf(fp, "%s\n", p); - free(p); - } + store = calloc(MIN(count, UUIDGEN_BATCH_MAX), sizeof(uuid_t)); + if (store == NULL) + err(1, "calloc()"); + + while (count > 0) { + int batch = (count > UUIDGEN_BATCH_MAX) ? UUIDGEN_BATCH_MAX : count; + + if (!iterate) { + if (version == 1) { + if (uuidgen(store, batch) != 0) + err(1, "uuidgen()"); + } else if (version == 4) { + if (uuidgen_v4(store, batch) != 0) + err(1, "uuidgen_v4()"); + } else { + err(1, "unsupported version"); + } + } else { + uuid = store; + for (i = 0; i < batch; i++) { + if (version == 1) { + if (uuidgen(uuid++, 1) != 0) + err(1, "uuidgen()"); + } else if (version == 4) { + if (uuidgen_v4(uuid++, 1) != 0) + err(1, "uuidgen_v4()"); + } else { + err(1, "unsupported version"); + } + } + } + + uuid = store; + for (i = 0; i < batch; i++) { + tostring(uuid++, &p, &status); + if (status != uuid_s_ok) + err(1, "cannot stringify a UUID"); + fprintf(fp, "%s\n", p); + free(p); + } + + count -= batch; + } + free(store); - free(store); if (fp != stdout) fclose(fp); return (0); diff --git a/sys/kern/kern_uuid.c b/sys/kern/kern_uuid.c index fb27f7bbf736..136242ca2087 100644 --- a/sys/kern/kern_uuid.c +++ b/sys/kern/kern_uuid.c @@ -186,7 +186,7 @@ sys_uuidgen(struct thread *td, struct uuidgen_args *uap) * like to have some sort of upper-bound that's less than 2G :-) * XXX probably needs to be tunable. */ - if (uap->count < 1 || uap->count > 2048) + if (uap->count < 1 || uap->count > UUIDGEN_BATCH_MAX) return (EINVAL); count = uap->count; diff --git a/sys/sys/uuid.h b/sys/sys/uuid.h index 5fc5e61457de..3694988ccf5c 100644 --- a/sys/sys/uuid.h +++ b/sys/sys/uuid.h @@ -34,6 +34,12 @@ /* Length of a node address (an IEEE 802 address). */ #define _UUID_NODE_LEN 6 +/* + * The kernel imposes a limit on the number of UUIDs generated per call + * to avoid unbounded allocations. + */ +#define UUIDGEN_BATCH_MAX 2048 + /* * See also: * http://www.opengroup.org/dce/info/draft-leach-uuids-guids-01.txt From nobody Sat Mar 7 07:51:26 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7g3QB9z6T3QF for ; Sat, 07 Mar 2026 07:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSb7f6yD3z3dfG for ; Sat, 07 Mar 2026 07:51:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869887; 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; bh=27yoyhVY1uNDVyVtx5LkSr33Ai9C9a5ox2S6vDoyxpM=; b=orG2e9gKe0hKwwtWRWsXPxrirXNq17Cl1YY6RXrty281/rnGW+q/OMmtg+2v865jj/aIK8 ur9/p3km8In8J6x35NpMFNitZ6ud1JrGHYwlxi6jXX43FedJBV51bpunk0U5npUxJUK7ow h0CazaCjgzcQSP6NVqq8Zk9Xiz2m5pcKweE3jjc3VIIcEKp8onyT8K9Z5YZ0/T3J2zLH8U X9ZxFkJs7vHVxZWLsbb1bJEoAvTW3dLRhzuTmOWwXNNcnAd03s2By4UhwPiWy4rg3CNGjv yjRspdGam34QvYcatm9nrgu/zVUv1HMiedXyDcLY2r8XfhWO8dWi4dUS58uqGg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772869887; a=rsa-sha256; cv=none; b=XASpHVeYIf+Q/8rHP2n2jTj8MqBeRrDALnYEMviq0EL5PX+ApUGJMY9yDyKEZMq09//oTF pr8srpnAWswvFBBXIDTfY098SGvFS2MVRhhArFmPdZIgPlBOD9GySOBc4BCqPZVqPcK9xQ aJ4NyeET3gSYK85J4i5af1P9yJgiyetjcjDTmMt+DMVy24Gg5OuAU3+FYIMJIL3TukWxfw yWMMXywvpP27CB5j/S3fsyDMIOpW51k2fwMggX56QCUmVXtwHQK/vgTABj7iD0ccRVjPN/ nQLAPLS0BaNB/IzyaDXmF4tiqvxK3Qa3i+fgClKv/PgXwfyhgRP/2FR8I63iXw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869887; 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; bh=27yoyhVY1uNDVyVtx5LkSr33Ai9C9a5ox2S6vDoyxpM=; b=hDrOvFpQ9Wy4REZFoux3dsihlnT8L5tsiJQJf4j510kH0VOQD9fnN4h9Kmk6tSb6bl0jFE sGa7zYpoPrAaLRtTOK88HsXtq50oLEDu1l4g3wbhLvzDeJaXskSR93qmfvD1rk4cUv2MQW anTu2ltmSqgGlfpYVS2AMKPbFA1fnM0lYHOamPOlNQUVGPTZUvK0MWiYGvKJSkBO13gjTD MUltRfgdxTs8zDqoeFI1DV/Do1dOVv7Bpq50eWZmmtX/UAMnuIW21FdvucGwafMBXCggLa 8/6Dx2eshR701YVuQ4iXCzrnxYb02G9UiIaMKQXWce5OZSUjmzOrZ7L/6SvMFg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7f6YKpz10lf for ; Sat, 07 Mar 2026 07:51:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 22ee1 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 07:51:26 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: YangWen From: Warner Losh Subject: git: cb69951f7ee6 - main - fsck_msdosfs: reduce the scope of dentry deletion List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: cb69951f7ee68c51ce465dba9b0d2f661c567c4b Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 07:51:26 +0000 Message-Id: <69abd8fe.22ee1.37ed7ff9@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=cb69951f7ee68c51ce465dba9b0d2f661c567c4b commit cb69951f7ee68c51ce465dba9b0d2f661c567c4b Author: YangWen AuthorDate: 2025-05-07 15:39:30 +0000 Commit: Warner Losh CommitDate: 2026-03-07 07:51:16 +0000 fsck_msdosfs: reduce the scope of dentry deletion When dentry flag is ATTR_VOLUME because of 1 bit flip(from 0x10 to 0x18), removede function will delete all dentry from invalid dentry postion, so some normal dentries will be deleted in the same cluster.Unfortunately, these normal directories and files will not be visible to the user after wo do fsck_msdos Signed-off-by: YangWen Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1694 --- sbin/fsck_msdosfs/dir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/fsck_msdosfs/dir.c b/sbin/fsck_msdosfs/dir.c index 2d7e4bcdc38f..de3d950c9611 100644 --- a/sbin/fsck_msdosfs/dir.c +++ b/sbin/fsck_msdosfs/dir.c @@ -769,7 +769,7 @@ readDosDirSection(struct fat_descriptor *fat, struct dosDirEntry *dir) if (vallfn || invlfn) { mod |= removede(fat, invlfn ? invlfn : vallfn, p, - invlfn ? invcl : valcl, -1, 0, + invlfn ? invcl : valcl, cl, cl, fullpath(dir), 2); vallfn = NULL; invlfn = NULL; From nobody Sat Mar 7 07:51:28 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7h41JVz6T3QN for ; Sat, 07 Mar 2026 07:51: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSb7h11Rfz3dlK for ; Sat, 07 Mar 2026 07:51:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869888; 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; bh=byhqhRZcjDB858lIBu+Ug1V4LrW87MMDStUZfl7JfD0=; b=LGOxpJ4Sp7fa4nBqHdPK8++cXLa34NBvbpU3Krjhzelt3voQE7KZgSi70HasFit0J4ifXs MhTC6r/6rm/fJDpXAJtf4fFowcKxvA8IVD5MHD6PyjsxyvlS+b5j4JQZL9sK9j4K8qJD2z gatTYO5uHD627bIpHBjvkAv24UKGN113hJXg+nyoBD6rMACji97m1SQljY6tqOHiRHxjLG FiD8FXoM0piaEx34rvjFPQmXeJB5Q8en0bH5AWyeFXNzGcxQ5Ih6RqqdlhGTo6lV9NBDCx uMxq3zFdn/rNjn+TvDJt4waLcbtcNH++qZKAeX36QF6M81SB+HjHFO2nJmnv9Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772869888; a=rsa-sha256; cv=none; b=HjLqHd6MxDhyW77jGo7z/hS251xKUfBxyzaS0AcIFCeg2Z/mYQ2RtILa9sCM33eglgtZ5x vsMRWGEEW7zsPMYtv1YnoTjADaawdh/dpYOcLKjNhvQNtwRnIJs7lF1l09hra0o8Wwp1I2 dvAl3Zxn5J60lm0NjQ/ZLiDNO8f0YObApL5zZTiaFazEiiCagk17d92alpuYSFMl/ImVO5 ZgKvfUsIdq8PmNTfIgEcsoWg5IZfHiJPDNzcJhtUsARpzQkOwF/vmmzVIEngJMXEpMvN+D ybgrXGKUrEw/OoymGl5P6FQtCgMEK+gsVN+Pq2yJKQH2XDReqQoKdprgLQV4Vw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772869888; 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; bh=byhqhRZcjDB858lIBu+Ug1V4LrW87MMDStUZfl7JfD0=; b=EhkNelJtPQQNKPKd6i4G/2lQ4xy15wJueOtoiciHHxt8otkORZ8i5tg1mK3WnWU0iiX2Jv WXbkera7ywvPa6k0GXgtb5UlPLhsfA83Z4y8F+re/b0jBhDlF2pEra7SlYFEoC56Cb0XAJ Xkirn02WnIAEOTMUgPiFPsbqLliVmN+/zOF0jXXiKrmiT8x87Wq7+5CJZNYQIGZYTZfxNL ozlqGPljrBG3vP8vMT2WaLDvFyKvu2nUCbCElJ3EzEb20S1DUM1frvW/VvAwTBLOhwvRSk eEagYsVAyiPEtPc1/5b79b/9vQnVSFIJ3gknF1KS5jAXO4VR7Vkl+cq69IUtew== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSb7h0G5Mz10ns for ; Sat, 07 Mar 2026 07:51:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 2166b by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 07:51:28 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Samvel Khalatyan From: Warner Losh Subject: git: 895a97c875a0 - main - rc.d/zfs: align zfs mount verbosity in host and jail environments List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 895a97c875a0f3fed3d4399762f6262b5a4aedb9 Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 07:51:28 +0000 Message-Id: <69abd900.2166b.5919d7a8@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=895a97c875a0f3fed3d4399762f6262b5a4aedb9 commit 895a97c875a0f3fed3d4399762f6262b5a4aedb9 Author: Samvel Khalatyan AuthorDate: 2026-02-18 17:00:13 +0000 Commit: Warner Losh CommitDate: 2026-03-07 07:51:16 +0000 rc.d/zfs: align zfs mount verbosity in host and jail environments ZFS script runs different startup seqneces depending on where it runs: on the host (`zfs_start_main()`) or in a jail (`zfs_start_jail()`): - `zfs_start_main()` mounts ZFS datasets in verbose mode `zfs mount -va` - `zfs_start_jail()` mounts ZFS datasets silently `zfs mount -a`. This change aligns the verbose levels. NO_ISSUE Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/2030 --- libexec/rc/rc.d/zfs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libexec/rc/rc.d/zfs b/libexec/rc/rc.d/zfs index 99156332e47b..7c8c3af28d31 100755 --- a/libexec/rc/rc.d/zfs +++ b/libexec/rc/rc.d/zfs @@ -19,7 +19,7 @@ required_modules="zfs" zfs_start_jail() { if check_jail mount_allowed; then - zfs mount -a + zfs mount -va fi } From nobody Sat Mar 7 15:21:32 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSn70705Fz6Tdbm for ; Sat, 07 Mar 2026 15: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSn706V5Mz3TSX for ; Sat, 07 Mar 2026 15: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=1772896892; 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; bh=F6hEvXVmDFrZaUUFYLmBxy8DDY0zGMjEhuopqtjAEhU=; b=lZHnHGSWC0jvHcZvGj0njFhAUngT7HVU7X3M+KXAsLUy8sE8+KncOFXtP8DzhOXh0rYf66 4Mww71dqrRmQbqFeWcOjK9ApvdHdTx2pphLaUYBxULvlZrSaYFyIdBYXoxOMN0330z31NA ogOahkxEwda/3NJl2CaLA31rH9UZwKa1tKti6dvdEYL+BpL2mmnxCzyaNn3r/A8bt7OYSx +SovXbOD20WUxm0ZuWnWQ8/hhaO+oo5OnzCfuRgvDxK16VrQvzHCBP0HsWqN+TwiVvcqIv 8JzuQYq+cE+W5j4+ZRk8jVnhIIwz+3qNi7jrxDnSifza7S3eXUEEfqbfMY84+A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772896892; a=rsa-sha256; cv=none; b=a2o19UHGH/cr7Z3LFitmo3+baDXSrq1C63ryqmosl5kgfXwoktnibf1kbf0s54mPVOsoxH T3/+7/4REL4W90Z4Get7v7e5FBGtTDTrrh3LKK1NkwltD5zFy65nRspOTmDIdmS5ZYPw36 PEu/a9cRia0OJ0tUTcnXNEENyUC+EKzA5WXSQOlqqYnUJ/t+CKMjT06AR5Fo/W0MAlIBES gk8G0SWPnIX4Bj9aWGjkSBU2ZVEwrCCtStmfbYtMR3AKc+0ajdheD0q5ZMS22v8KCJeejJ ex2i+W5iXzrCNlLQMjPSVP0xCKEJ0hxxhJ64JaCKrOizL7+Q5ta1/4JxPjkjFQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772896892; 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; bh=F6hEvXVmDFrZaUUFYLmBxy8DDY0zGMjEhuopqtjAEhU=; b=rpb6X2JI55GkRqeTbUDh5u6EP/xCLPnkxdbG5e2/RLCyI/PjCgNJsbzQ4ZzzV5LiVJzsW+ 6aSdRDYsIL4/V9xLqIThB/iu563z4et9SL+jJY4y46IN6HDyPB12U8P58iUIrQat7tIXFk jUnLCWO1h1IrBzrYh4Rzzqq7dLLVJTJOZLtaKsNQmaJvBHpICjCvBMX9dvzvjLev9W6LiG WXwDD7mRKkQjiW44CrXZCwopLXYo/lpzfzOqWittBYNMgf5p3zUyxrnuDZhsI7ybVx45hB yjC0J7t5rxMtsIuw6R0O3i+X7hT1ltXIa6m5tbI39ChbWUpQiOBZObOrQvrdAA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSn705mBNzKG for ; Sat, 07 Mar 2026 15:21:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3b88b by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 15:21:32 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Ali Mashtizadeh From: Warner Losh Subject: git: e409e51f8396 - main - hwpmc: Remove left over k7, xscale and p4 references pmc List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: e409e51f83963beaeb95eec82c5f43e44545d6b9 Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 15:21:32 +0000 Message-Id: <69ac427c.3b88b.511cc8b5@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=e409e51f83963beaeb95eec82c5f43e44545d6b9 commit e409e51f83963beaeb95eec82c5f43e44545d6b9 Author: Ali Mashtizadeh AuthorDate: 2026-02-20 21:05:41 +0000 Commit: Warner Losh CommitDate: 2026-03-07 15:17:43 +0000 hwpmc: Remove left over k7, xscale and p4 references pmc Support for these processors was removed a few years ago, but a few references remain that should be removed. Sponsored by: Netflix Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/2039 --- sys/amd64/include/pmc_mdep.h | 1 - sys/i386/include/pmc_mdep.h | 4 +--- sys/sys/pmc.h | 2 -- 3 files changed, 1 insertion(+), 6 deletions(-) diff --git a/sys/amd64/include/pmc_mdep.h b/sys/amd64/include/pmc_mdep.h index 24b785312a16..c44dd066f827 100644 --- a/sys/amd64/include/pmc_mdep.h +++ b/sys/amd64/include/pmc_mdep.h @@ -65,7 +65,6 @@ struct pmc_mdep; * TSC The timestamp counter * K8 AMD Athlon64 and Opteron PMCs in 64 bit mode. * IBS AMD IBS - * PIV Intel P4/HTT and P4/EMT64 * IAP Intel Core/Core2/Atom CPUs in 64 bits mode. * IAF Intel fixed-function PMCs in Core2 and later CPUs. * UCP Intel Uncore programmable PMCs. diff --git a/sys/i386/include/pmc_mdep.h b/sys/i386/include/pmc_mdep.h index 31eded611a1e..618df8daebef 100644 --- a/sys/i386/include/pmc_mdep.h +++ b/sys/i386/include/pmc_mdep.h @@ -41,7 +41,6 @@ struct pmc_mdep; * On the i386 platform we support the following PMCs. * * TSC The timestamp counter - * K7 AMD Athlon XP/MP and other 32 bit processors. * K8 AMD Athlon64 and Opteron PMCs in 32 bit mode. * IBS AMD IBS * IAP Intel Core/Core2/Atom programmable PMCs. @@ -50,7 +49,7 @@ struct pmc_mdep; * UCF Intel Uncore fixed-function PMCs. */ -#include /* K7 and K8 */ +#include #include #include #include @@ -62,7 +61,6 @@ struct pmc_mdep; * IAF, IAP, UCF and UCP. */ #define PMC_MDEP_CLASS_INDEX_TSC 1 -#define PMC_MDEP_CLASS_INDEX_K7 2 #define PMC_MDEP_CLASS_INDEX_K8 2 #define PMC_MDEP_CLASS_INDEX_IBS 3 #define PMC_MDEP_CLASS_INDEX_IAP 2 diff --git a/sys/sys/pmc.h b/sys/sys/pmc.h index 28484eed187e..7640a9b96c84 100644 --- a/sys/sys/pmc.h +++ b/sys/sys/pmc.h @@ -110,7 +110,6 @@ extern char pmc_cpuid[PMC_CPUID_LEN]; __PMC_CPU(INTEL_EMERALD_RAPIDS, 0xA0, "Intel Emerald Rapids") \ __PMC_CPU(INTEL_ALDERLAKEN, 0xA1, "Intel AlderlakeN") \ __PMC_CPU(INTEL_GRANITE_RAPIDS, 0xA2, "Intel Granite Rapids") \ - __PMC_CPU(INTEL_XSCALE, 0x100, "Intel XScale") \ __PMC_CPU(PPC_7450, 0x300, "PowerPC MPC7450") \ __PMC_CPU(PPC_E500, 0x340, "PowerPC e500 Core") \ __PMC_CPU(PPC_970, 0x380, "IBM PowerPC 970") \ @@ -146,7 +145,6 @@ enum pmc_cputype { __PMC_CLASS(IAP, 0x07, "Intel Core...Atom, programmable") \ __PMC_CLASS(UCF, 0x08, "Intel Uncore fixed function") \ __PMC_CLASS(UCP, 0x09, "Intel Uncore programmable") \ - __PMC_CLASS(XSCALE, 0x0A, "Intel XScale counters") \ __PMC_CLASS(PPC7450, 0x0D, "Motorola MPC7450 class") \ __PMC_CLASS(PPC970, 0x0E, "IBM PowerPC 970 class") \ __PMC_CLASS(SOFT, 0x0F, "Software events") \ From nobody Sat Mar 7 15:27:52 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSnGK0QvTz6TdpG for ; Sat, 07 Mar 2026 15:27: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSnGJ6qFMz3Vfy for ; Sat, 07 Mar 2026 15:27:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772897273; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9xUAc9rhqOZclIsNkdHfjyk6fc6pPicORe/oC52xwAU=; b=H8S6FAoKgdpOMruqZMjt4+UbJGX/Pk0+A/s3+TEOJVuUQ0qGEft4ysAvh6DDG3lPWTufBb yyEnbe3eCK9ApvEeuKq7TIPb8hfwgUm2POwbPFg6JteM6Y+z/3OklAAS9ewOU7OCPYBWdQ NF9qa8ltQGQdNso1s+UKmecDzLwFfFnl+CjzdFtlp/5+x8f68dP+E5aN0YWqolQee/iyYd /jxm3aoUxFaSTKE6TYuFhzJhCNFRJhBxItMPjvQaYt6yoy5wVLGGnBPfbwNNfuuikdQIs1 b6cA2FBG+v/BXdImlFTiHeiXRbui9+54Mfg58y9jxatXx6qgOo5sRin4vqQlkg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772897273; a=rsa-sha256; cv=none; b=Ppt01eN9NeUIZTgRJv9cgA9YAg5Y8mJuOePnsDto/FpYS5oTliybnQfgjsxB0tjW60voOr N+UxQgVp7emrsFw6rthlymS9J1gLUSjlsssNa5Nvh/B7HsOH0qcOfMyAtVkfj0kEUWkOW5 JMBMI9rHYslz+U+tKjqil6cxkcMd5MmIRHmYN3oLcSgJ9AJX5g3l4gHpl3PmDlhp1bWDBH WDGk6qML+R+bo2w5s8F4tWVSf31WuJrdls57RvIe/dXx6to+P8NlnnshAuKM6BM5Zk9TWb R0jG/4D4jm5vlhCfQIagRHGCFixx17+qWhe+Qi88mXU5isPd4afFGPddtDFunQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772897273; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9xUAc9rhqOZclIsNkdHfjyk6fc6pPicORe/oC52xwAU=; b=XrTiU85KSjWvcKR1J9WiM32AuTD+S5TDv/kKxUGNo4/NigpYIzAOAk1JsNZvoGwpaAJN3l TWsTmPk/ZFwoieRT0gq1d+Sx1hCp9hbeKpX3pzjS7mjKycwyKFdqXN+dDenujen6ffYvPr vs0yzHQboxOaDF30DL6aR/I4aoKtWORsAmeN+75P1duDPMMUZ1/tNd/lb1mUJsfYbKD8BH Qfjen34Jv0mu2MzyCdlRq4FvVL4q/pniMMAorLrcMPuahIeu4QPU118CkT9ihCC4Lq/RU+ rsdZXzrdFFadlBo50IdbEhZ3U4jpCcYuG4yfbeA/rOpTdLxQCi3PCtxxu3NBGw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSnGJ6NkVz90 for ; Sat, 07 Mar 2026 15:27:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3b694 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 15:27:52 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Pouria Mousavizadeh Tehrani Subject: git: cdad55809ef5 - main - acpi_system76: Support for acpi-controlled buttons on System76 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pouria X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: cdad55809ef59239c3bbdc841ed307db68bb3971 Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 15:27:52 +0000 Message-Id: <69ac43f8.3b694.a8b5285@gitrepo.freebsd.org> The branch main has been updated by pouria: URL: https://cgit.FreeBSD.org/src/commit/?id=cdad55809ef59239c3bbdc841ed307db68bb3971 commit cdad55809ef59239c3bbdc841ed307db68bb3971 Author: Pouria Mousavizadeh Tehrani AuthorDate: 2026-03-06 17:15:49 +0000 Commit: Pouria Mousavizadeh Tehrani CommitDate: 2026-03-07 15:27:08 +0000 acpi_system76: Support for acpi-controlled buttons on System76 Add acpi_system76 for handling acpi-controlled buttons on System76 Laptops. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D55694 --- sys/conf/files | 1 + sys/dev/acpi_support/acpi_system76.c | 359 ++++++++++++++++++++++++++++++++ sys/modules/acpi/Makefile | 1 + sys/modules/acpi/acpi_system76/Makefile | 7 + sys/x86/conf/NOTES | 3 + 5 files changed, 371 insertions(+) diff --git a/sys/conf/files b/sys/conf/files index 632fddef2cb5..ceff5c9d6c16 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -744,6 +744,7 @@ dev/acpi_support/acpi_ibm.c optional acpi_ibm acpi dev/acpi_support/acpi_panasonic.c optional acpi_panasonic acpi dev/acpi_support/acpi_sbl_wmi.c optional acpi_sbl_wmi acpi dev/acpi_support/acpi_sony.c optional acpi_sony acpi +dev/acpi_support/acpi_system76.c optional acpi_system76 acpi dev/acpi_support/acpi_toshiba.c optional acpi_toshiba acpi dev/acpi_support/atk0110.c optional aibs acpi dev/acpica/Osd/OsdDebug.c optional acpi diff --git a/sys/dev/acpi_support/acpi_system76.c b/sys/dev/acpi_support/acpi_system76.c new file mode 100644 index 000000000000..916a9a61f471 --- /dev/null +++ b/sys/dev/acpi_support/acpi_system76.c @@ -0,0 +1,359 @@ +/*- + * SPDX-License-Identifier: BSD-2-Clause + * + * Copyright (c) 2026 Pouria Mousavizadeh Tehrani + * All rights reserved. + * + * 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 AUTHOR 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 AUTHOR 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 + +#define _COMPONENT ACPI_OEM +ACPI_MODULE_NAME("system76") + +static char *system76_ids[] = { "17761776", NULL }; +ACPI_SERIAL_DECL(system76, "System76 ACPI management"); + +struct acpi_ctrl { + int val; + bool exists; +}; + +struct acpi_system76_softc { + device_t dev; + ACPI_HANDLE handle; + + struct acpi_ctrl kbb, /* S76_CTRL_KBB */ + kbc; /* S76_CTRL_KBC */ + + struct sysctl_ctx_list sysctl_ctx; + struct sysctl_oid *sysctl_tree; +}; + +static int acpi_system76_probe(device_t); +static int acpi_system76_attach(device_t); +static int acpi_system76_detach(device_t); +static void acpi_system76_init(struct acpi_system76_softc *); +static struct acpi_ctrl * + acpi_system76_ctrl_map(struct acpi_system76_softc *, int); +static int acpi_system76_update(struct acpi_system76_softc *, int, bool); +static int acpi_system76_sysctl_handler(SYSCTL_HANDLER_ARGS); +static void acpi_system76_notify_handler(ACPI_HANDLE, uint32_t, void *); +static void acpi_system76_check(struct acpi_system76_softc *); + +/* methods */ +#define S76_CTRL_KBB 1 /* Keyboard Brightness */ +#define S76_CTRL_KBC 2 /* Keyboard Color */ +#define S76_CTRL_MAX 3 + +struct s76_ctrl_table { + char *name; + char *get_method; +#define S76_CTRL_GKBB "\\_SB.S76D.GKBB" +#define S76_CTRL_GKBC "\\_SB.S76D.GKBC" + + char *set_method; +#define S76_CTRL_SKBB "\\_SB.S76D.SKBB" +#define S76_CTRL_SKBC "\\_SB.S76D.SKBC" + + char *desc; +}; + +static const struct s76_ctrl_table s76_sysctl_table[] = { + [S76_CTRL_KBB] = { + .name = "keyboard_backlight", + .get_method = S76_CTRL_GKBB, + .set_method = S76_CTRL_SKBB, + .desc = "Keyboard Backlight", + }, + [S76_CTRL_KBC] = { + .name = "keyboard_color", + .get_method = S76_CTRL_GKBC, + .set_method = S76_CTRL_SKBC, + .desc = "Keyboard Color", + }, +}; + +static device_method_t acpi_system76_methods[] = { + DEVMETHOD(device_probe, acpi_system76_probe), + DEVMETHOD(device_attach, acpi_system76_attach), + DEVMETHOD(device_detach, acpi_system76_detach), + + DEVMETHOD_END +}; + +/* Notify event */ +#define ACPI_NOTIFY_BACKLIGHT_CHANGED 0x80 +#define ACPI_NOTIFY_COLOR_TOGGLE 0x81 +#define ACPI_NOTIFY_COLOR_DOWN 0x82 +#define ACPI_NOTIFY_COLOR_UP 0x83 +#define ACPI_NOTIFY_COLOR_CHANGED 0x84 + +static driver_t acpi_system76_driver = { + "acpi_system76", + acpi_system76_methods, + sizeof(struct acpi_system76_softc) +}; + +/* + * Returns corresponding acpi_ctrl of softc from method + */ +static struct acpi_ctrl * +acpi_system76_ctrl_map(struct acpi_system76_softc *sc, int method) +{ + + switch (method) { + case S76_CTRL_KBB: + return (&sc->kbb); + break; + case S76_CTRL_KBC: + return (&sc->kbc); + break; + default: + device_printf(sc->dev, "Driver received unknown method\n"); + return (NULL); + } +} + +static int +acpi_system76_update(struct acpi_system76_softc *sc, int method, bool set) +{ + struct acpi_ctrl *ctrl; + ACPI_STATUS status; + + ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); + ACPI_SERIAL_ASSERT(system76); + + if ((ctrl = acpi_system76_ctrl_map(sc, method)) == NULL) + return (EINVAL); + + if (set) + status = acpi_SetInteger(sc->handle, s76_sysctl_table[method].set_method, + ctrl->val); + else + status = acpi_GetInteger(sc->handle, s76_sysctl_table[method].get_method, + &ctrl->val); + if (ACPI_FAILURE(status)) { + device_printf(sc->dev, "Couldn't query method (%s)\n", + s76_sysctl_table[method].name); + return (status); + } + + return (0); +} + +static void +acpi_system76_notify_update(void *arg) +{ + struct acpi_system76_softc *sc; + int method; + + ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); + + sc = (struct acpi_system76_softc *)device_get_softc(arg); + + ACPI_SERIAL_BEGIN(system76); + for (method = 1; method < S76_CTRL_MAX; method++) + acpi_system76_update(sc, method, false); + ACPI_SERIAL_END(system76); +} + +static void +acpi_system76_check(struct acpi_system76_softc *sc) +{ + struct acpi_ctrl *ctrl; + int method; + + ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); + ACPI_SERIAL_ASSERT(system76); + + for (method = 1; method < S76_CTRL_MAX; method++) { + if ((ctrl = acpi_system76_ctrl_map(sc, method)) == NULL) + continue; + + if (ACPI_FAILURE(acpi_GetInteger(sc->handle, + s76_sysctl_table[method].get_method, &ctrl->val))) { + ctrl->exists = false; + device_printf(sc->dev, "Driver can't control %s\n", + s76_sysctl_table[method].desc); + } else { + ctrl->exists = true; + acpi_system76_update(sc, method, false); + } + } +} + +static void +acpi_system76_notify_handler(ACPI_HANDLE handle, uint32_t notify, void *ctx) +{ + + ACPI_FUNCTION_TRACE_U32((char *)(uintptr_t)__func__, notify); + + switch (notify) { + case ACPI_NOTIFY_BACKLIGHT_CHANGED: + case ACPI_NOTIFY_COLOR_TOGGLE: + case ACPI_NOTIFY_COLOR_DOWN: + case ACPI_NOTIFY_COLOR_UP: + case ACPI_NOTIFY_COLOR_CHANGED: + AcpiOsExecute(OSL_NOTIFY_HANDLER, + acpi_system76_notify_update, ctx); + break; + default: + break; + } +} + +static int +acpi_system76_sysctl_handler(SYSCTL_HANDLER_ARGS) +{ + struct acpi_ctrl *ctrl; + struct acpi_system76_softc *sc; + int val, method, error; + + ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); + + sc = (struct acpi_system76_softc *)oidp->oid_arg1; + method = oidp->oid_arg2; + if ((ctrl = acpi_system76_ctrl_map(sc, method)) == NULL) + return (EINVAL); + + val = ctrl->val; + error = sysctl_handle_int(oidp, &val, 0, req); + if (error != 0) { + device_printf(sc->dev, "Driver query failed\n"); + return (error); + } + if (req->newptr == NULL) + return (error); + + /* Input validation */ + switch (method) { + case S76_CTRL_KBB: + if (val > UINT8_MAX || val < 0) + return (EINVAL); + break; + case S76_CTRL_KBC: + if (val >= (1 << 24) || val < 0) + return (EINVAL); + break; + default: + break; + } + + ctrl->val = val; + + ACPI_SERIAL_BEGIN(system76); + error = acpi_system76_update(sc, method, true); + ACPI_SERIAL_END(system76); + return (error); +} + +static void +acpi_system76_init(struct acpi_system76_softc *sc) +{ + struct acpi_softc *acpi_sc; + struct acpi_ctrl *ctrl; + uint32_t method; + + ACPI_SERIAL_ASSERT(system76); + + acpi_system76_check(sc); + acpi_sc = acpi_device_get_parent_softc(sc->dev); + sysctl_ctx_init(&sc->sysctl_ctx); + sc->sysctl_tree = SYSCTL_ADD_NODE(&sc->sysctl_ctx, + SYSCTL_CHILDREN(acpi_sc->acpi_sysctl_tree), OID_AUTO, "s76", + CTLFLAG_RD | CTLFLAG_MPSAFE, 0, "system76 control"); + + for (method = 1; method < S76_CTRL_MAX; method++) { + if ((ctrl = acpi_system76_ctrl_map(sc, method)) == NULL) + continue; + + if (!ctrl->exists) + continue; + + SYSCTL_ADD_PROC(&sc->sysctl_ctx, + SYSCTL_CHILDREN(sc->sysctl_tree), OID_AUTO, s76_sysctl_table[method].name, + CTLTYPE_UINT | CTLFLAG_RW | CTLFLAG_ANYBODY | CTLFLAG_MPSAFE, + sc, method, acpi_system76_sysctl_handler, "IU", s76_sysctl_table[method].desc); + } +} + +static int +acpi_system76_attach(device_t dev) +{ + struct acpi_system76_softc *sc; + + ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); + + sc = device_get_softc(dev); + sc->dev = dev; + sc->handle = acpi_get_handle(dev); + + AcpiInstallNotifyHandler(sc->handle, ACPI_DEVICE_NOTIFY, + acpi_system76_notify_handler, dev); + + ACPI_SERIAL_BEGIN(system76); + acpi_system76_init(sc); + ACPI_SERIAL_END(system76); + + return (0); +} + +static int +acpi_system76_detach(device_t dev) +{ + struct acpi_system76_softc *sc; + + sc = device_get_softc(dev); + if (sysctl_ctx_free(&sc->sysctl_ctx) != 0) + return (EBUSY); + + return (0); +} + +static int +acpi_system76_probe(device_t dev) +{ + int rv; + + if (acpi_disabled("system76") || device_get_unit(dev) > 1) + return (ENXIO); + rv = ACPI_ID_PROBE(device_get_parent(dev), dev, system76_ids, NULL); + if (rv > 0) { + return (rv); + } + + return (BUS_PROBE_VENDOR); +} + +DRIVER_MODULE(acpi_system76, acpi, acpi_system76_driver, 0, 0); +MODULE_VERSION(acpi_system76, 1); +MODULE_DEPEND(acpi_system76, acpi, 1, 1, 1); diff --git a/sys/modules/acpi/Makefile b/sys/modules/acpi/Makefile index 5040187e906f..265e6bd6cdcb 100644 --- a/sys/modules/acpi/Makefile +++ b/sys/modules/acpi/Makefile @@ -9,6 +9,7 @@ SUBDIR= \ acpi_panasonic \ acpi_sbl_wmi \ acpi_sony \ + acpi_system76 \ acpi_toshiba \ acpi_video \ acpi_wmi \ diff --git a/sys/modules/acpi/acpi_system76/Makefile b/sys/modules/acpi/acpi_system76/Makefile new file mode 100644 index 000000000000..86d2c91e712d --- /dev/null +++ b/sys/modules/acpi/acpi_system76/Makefile @@ -0,0 +1,7 @@ +.PATH: ${SRCTOP}/sys/dev/acpi_support + +KMOD= acpi_system76 +CFLAGS+=-I${SRCTOP}/sys/dev/acpi_support +SRCS= acpi_system76.c opt_acpi.h acpi_if.h device_if.h bus_if.h + +.include diff --git a/sys/x86/conf/NOTES b/sys/x86/conf/NOTES index 501d4159b129..877cbb3beb7f 100644 --- a/sys/x86/conf/NOTES +++ b/sys/x86/conf/NOTES @@ -178,6 +178,9 @@ device acpi_sbl_wmi # ACPI Sony extra (LCD brightness) device acpi_sony +# ACPI System76 extra (Keyboard brightness, Keyboard color) +device acpi_system76 + # ACPI Toshiba Extras (LCD backlight/brightness, video output, etc.) device acpi_toshiba From nobody Sat Mar 7 19:23:50 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fStVZ22CPz6TxcT for ; Sat, 07 Mar 2026 19:23: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fStVZ1L4hz3yfX for ; Sat, 07 Mar 2026 19:23:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772911430; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=SRVItLgIGS5yU4jlmDVuj873zhMlPF8z08dEeS3lEZk=; b=t06MyzQz/7LMoFUJA8F0lbYA6bGkHbOsk7QEZr09ltfADpXvreK+F//9CBWZkXe/dREEvo FkaGDLpcUKMpCZ7KX3Fn4+tiUSpnLMRNAfd6VytEFZ0364wIWZbVf0iiTiW1QNfy0uwPFx HKYnkszXF9w8B5r+UQvvFnESDdH5pq9DoFuvkN7x7A/hN5sXZfU+HBXaAXxz0d0qciersV bLv+KD/SPiXnfjBlVCoVZaKllqgZ/yS9qYgFsw0DZ6I8JWT1oPEmh2n4RdSGZ7UlP3aO/8 pX0aKlauoj+1qwF7MlEBU5c8yP3cpjzTEH71zAcbSaogLs8vI9id4UWpuLaaeg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772911430; a=rsa-sha256; cv=none; b=wIcUjgqOuukJpzODrkfIzA8az5H7Nd7gzAe+zmmJNhW9XJm+5f7Sr7aoCS9VJQvmPJtmBr VLBME6ZEaFF+HHBS3ReOpN2sf6MB3UmiD7B3veyJ4I/IcaHf+8ju+eW7EV9P3ruNDMCB+h pgmama88HySFjwDcMMAPggoXz/zWGuliOCTcY3hSp7WwvX2Cx9wxpBFopRvRXUX7ZokgI1 ClNJyBI0+vrp2jALtCvdJntw7oLpl4Nv6354uj+/KSCR67mxGYLNRiekd6T+PDhiIeqB7t hiuczcQ7SaCg9FxZxPjOvn4hclSsvmI6rJXL9fFRJ5iTwC7RNu4W8LhmJBwKww== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772911430; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=SRVItLgIGS5yU4jlmDVuj873zhMlPF8z08dEeS3lEZk=; b=SzaMPVoQ5ebbLcXOyPuiaZkkC3nG9DHUQ68jL4LKg+kOkj9e6YMCEJuXTpqWujPuTGaS+9 DadPz7WhUBANLvLEV5fegCNynbC03Tn+MDpuv5jTv3s6uFlj3UCD3m1maLKLzfxPn3fo3c De2v0sHGq1cDNnkN3dZWWPmsJm79nz2TNvwdN2GNWMEgGCcEYgcvHCZtfJdQ/GBnkXqIAg Ep83wKKdLagcQnrcWVbzqtW1PI3EM7tf/xp5Mh3VKorwtTjTw4dsrORhEldaz8mArOYt1Q /B3WwjaDCp0GS6Lo4MgGCDyfbnreB3XsQIcbAlel2xp4ZQWNQTop1Tz6hHBD9Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fStVZ0k3pz6KD for ; Sat, 07 Mar 2026 19:23:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 250e5 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 19:23:50 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Pouria Mousavizadeh Tehrani Subject: git: fa4f625ed854 - main - acpi_system76: unbreak LINT List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pouria X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: fa4f625ed854cec2d7657783b955426fce8ff9ba Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 19:23:50 +0000 Message-Id: <69ac7b46.250e5.986d69e@gitrepo.freebsd.org> The branch main has been updated by pouria: URL: https://cgit.FreeBSD.org/src/commit/?id=fa4f625ed854cec2d7657783b955426fce8ff9ba commit fa4f625ed854cec2d7657783b955426fce8ff9ba Author: Pouria Mousavizadeh Tehrani AuthorDate: 2026-03-07 19:15:40 +0000 Commit: Pouria Mousavizadeh Tehrani CommitDate: 2026-03-07 19:22:24 +0000 acpi_system76: unbreak LINT Reported by: tinderbox Fixes: cdad55809ef5 ("acpi_system76: Support for ...") Differential Revision: https://reviews.freebsd.org/D55694 --- sys/dev/acpi_support/acpi_system76.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/dev/acpi_support/acpi_system76.c b/sys/dev/acpi_support/acpi_system76.c index 916a9a61f471..c20725f0174e 100644 --- a/sys/dev/acpi_support/acpi_system76.c +++ b/sys/dev/acpi_support/acpi_system76.c @@ -26,12 +26,14 @@ * SUCH DAMAGE. */ +#include "opt_acpi.h" #include #include #include #include #include +#include #include #include From nobody Sat Mar 7 23:13:16 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fSzbJ6QwFz6TX0F for ; Sat, 07 Mar 2026 23:13: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fSzbJ486vz3NF5 for ; Sat, 07 Mar 2026 23:13:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772925196; 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; bh=9PhQSSPjmrTjvCTUDnisxXAGCWjbOHLVgWLlFI3kBC0=; b=kDZVehqMn8fIN0AjExqYrVoIts7a25pU1pojhj2p/SHjr//9olLrsD0EYxZC1Yi+D/kGuG cWYhJ7JZfkC/9KB1MNW4+p/3vZXUEthTFRoMEoXyvwiYUJA61exczqBoZj8MPMO9JguOxI LNEw1PkRcAcoIWH3V1JMrhhM4vBKpb3i2mXq0GD7JvkGdW8KoKVmSAp6bjKWOI4kRyhiv8 IQouCUYelXttkka2Srny+bUx56eoXKSr9TPs93SgDWAv54NQ/PlDJbeZeNwiF4HiJ/sqyZ 0D+u3Djv3eSRhPJapd7neRiF60ek6oK1qeqw1k2m4XNPM1MZlTYZpmTINX85hA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772925196; a=rsa-sha256; cv=none; b=iqmt85hWE43fZdj/ZzJwcfC/fz4WXApgwX/b47U3cwKVG15kdtCPO1GPsCCG6MaPxPEGxa /PlbsNbajYZdHthj4I5wBzNDr8T3EI7XcJiPMV6KJtxKmqaMhVQuxR6xSqebYddcGh4OH0 pocZMiJCC7hg9G1t11ncBc0uJIeLr3Qa9uSOrp+gqctWQXsGpas2TqFLwaLUs++BftoKRx CfianfexHJzFJsepC6IX/13pcneAyRGfIrdfa96uph29zI7sUm2W04rIMJUvuOnJb9PRQA Xj+1xBlWVVkMKmjYwBVgHpGsB8jXz06xU3fZImF9IRSJ0RqFLoqW/O/d49a97g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772925196; 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; bh=9PhQSSPjmrTjvCTUDnisxXAGCWjbOHLVgWLlFI3kBC0=; b=F3/MTj3aP7IwuvOxKA4lA0S7xsozZVzrpKJHeB/gb2HxC6UjLP855wkU4lPaJtFkzIO5PE Mzpa9Zn/QqzjVsQR3NqmRgYJ1s57huzzRqxbYwz74GtEU/a+mIX8ZjOJxSlhoGUVojDX0c QVOAAn7boIREbVg+T9JloMFxail+VRrBOjguidsKi3ag6JhLktz0f/zpIZy3SNvPLzfKUe 03P3DhnQu7fmYSdYqKhRNO2tSViXbufV/kZ3UetjOpA8C8ZN3TZkLSsxjJsE3t9q/Q9aHW 42tX77vb80vxi4DoNlh5SCsV8JRijiuXmu4WBle5kziDpt4CX+5pXp5DoNVoOw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fSzbJ3fLMzDVF for ; Sat, 07 Mar 2026 23:13:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 438df by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 23:13:16 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Strahinja =?utf-8?Q?Stani=C5=A1?==?utf-8?Q?i=C4=87?= From: Robert Clausecker Subject: git: 2a4e3112c811 - main - libc/riscv64: temporarily disable strnlen() implementation until a fix is developed List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: fuz X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2a4e3112c811b9892e14e15cfd23538e7e47329c Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 23:13:16 +0000 Message-Id: <69acb10c.438df.132c4ea0@gitrepo.freebsd.org> The branch main has been updated by fuz: URL: https://cgit.FreeBSD.org/src/commit/?id=2a4e3112c811b9892e14e15cfd23538e7e47329c commit 2a4e3112c811b9892e14e15cfd23538e7e47329c Author: Strahinja Stanišić AuthorDate: 2026-03-07 21:59:25 +0000 Commit: Robert Clausecker CommitDate: 2026-03-07 22:11:11 +0000 libc/riscv64: temporarily disable strnlen() implementation until a fix is developed strnlen() doesn't seem to cope well with a length argument such that string pointer plus length overflows past the end of the address space. Reviewed by: fuz MFC after: 1 week PR: 293353, 293296 Differential Revision: https://reviews.freebsd.org/D55714 --- lib/libc/riscv/string/Makefile.inc | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/libc/riscv/string/Makefile.inc b/lib/libc/riscv/string/Makefile.inc index 6dae6b2cb62d..ce965833cb27 100644 --- a/lib/libc/riscv/string/Makefile.inc +++ b/lib/libc/riscv/string/Makefile.inc @@ -5,6 +5,5 @@ MDSRCS+= \ memcpy.S \ memset.S \ strlen.S \ - strnlen.S \ strchrnul.S \ strrchr.S From nobody Sat Mar 7 23:34:24 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fT03h1P5Bz6TYT4 for ; Sat, 07 Mar 2026 23:34: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fT03h0ZBtz3PxC for ; Sat, 07 Mar 2026 23:34:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772926464; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kTggxdKXYrxTLTyPadQpDkOEOjrW8BUwmdhKurdZU6g=; b=lZhdnrLeMn9FthwBoDfaxKciIPI4tpB5Bcnk1lbn8BAbj/DZlNyXN4baiAnHb9KXW5pRDx M9bFpx2HhT75Q/s1fy1lDTEWTHbAQ8NTnFNF1gNrOfRJ/IfSTlIaHDTXyUY2VMKZ1KMxHh NAHHsyVGSVRxgfHlQMPDmdLp+ZDJPdVrfz9Hb1Y8Z2NMxsarna6WTZXjUYYznFYy4/4IZK ErKDHml9B4dfYs2zWl31f41f505EF79YBP2fKAkRSwFJQiVhmWH1X6fpVwdK3rZD0sTUdy 0sPKF65oHSGR/sgZLqkVMppVuyNpUuQGGQuR4igWSqRip1hhHT+nPvXr0Qqh0A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772926464; a=rsa-sha256; cv=none; b=ELe5TIJx12kFZyUTAKNm4NzjJOFDNd9a5d2rBf3OgY8ayhhKjh5ccuWfuXBWvaTaTifscj dI7TP896rGwgsoTlfv3lWuNagA6RvyjNifEIskeldi8klp4oiLZX8k4SkNy/9cRcO9Cmqd 3ZlJOSbqDihHxe6LKXeQoGhXWpGE2hFuTNUQco4yn1xDzwFaduMpB8ICPV1TPahtoNq1BF mylrXsMpVhrapE+f0TGJKT4mKX6Jeu+3YQRhaNvoOg/XajScoYBubFQMQi/S3bzksgAnJf RyYFz607pLGof2Pvj6rARbQbqSzx+w/ikTq/we8KyfHfWe0Y6e+JjCFfzHjZLg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772926464; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kTggxdKXYrxTLTyPadQpDkOEOjrW8BUwmdhKurdZU6g=; b=BbG/wZEsL7b37rKBqSr01oUDn9/EEJR6yBMaqF1GYPUbfuSvGJklySdCfwzgggUyDdkx29 +S53BN7CQ3liF2iDsZ0WK6p1dM9P+kup87AMIojo67blWmxIjwmImaGHfhfABanZ02B+lN Rliwgx+8hMqoylXOWw4vhGFmnLlE6JyyiGugkgSiNeGSmAVr3UJD8UbmgejtwZnSrh2K1A lqoCiS49RCzL9YcejFsoSR5mPg+wshNKJK+KjQfdeBQpbbWUNZznu6sVgQjThFQdNkDzkG OsWfe0iF3d7XNOxCOUiZBkCPmZo0VyJjU5/GLfNgBZWOtH7oxDKHtAKu0zI02Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fT03h06lFzTwY for ; Sat, 07 Mar 2026 23:34:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 45056 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 23:34:24 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Robert Clausecker Subject: git: b5514e1c6d9e - main - depend-cleanup.sh: rebuild strnlen.o on riscv64 if it came from strnlen.S List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: fuz X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b5514e1c6d9e7ec09b299a983d1ce32852e0d9dc Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 23:34:24 +0000 Message-Id: <69acb600.45056.3518dc17@gitrepo.freebsd.org> The branch main has been updated by fuz: URL: https://cgit.FreeBSD.org/src/commit/?id=b5514e1c6d9e7ec09b299a983d1ce32852e0d9dc commit b5514e1c6d9e7ec09b299a983d1ce32852e0d9dc Author: Robert Clausecker AuthorDate: 2026-03-07 23:14:25 +0000 Commit: Robert Clausecker CommitDate: 2026-03-07 23:33:53 +0000 depend-cleanup.sh: rebuild strnlen.o on riscv64 if it came from strnlen.S We have to switch back to the previous rule once the temporary build fix has been replaced with a permanent fix. MFC after: 1 week See also: 2a4e3112c811b9892e14e15cfd23538e7e47329c PR: 293353, 293296 --- tools/build/depend-cleanup.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index 89b98abe7c4d..e9c02d015368 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -349,7 +349,7 @@ if [ ${MACHINE} = riscv ]; then clean_dep lib/libc memcpy c # 20251031 5a52f0704435 libc: scalar strnlen() in RISC-V assembly - clean_dep lib/libc strnlen c + #clean_dep lib/libc strnlen c # 20251031 08af0bbc9c7d libc: scalar strchrnul() in RISC-V assembly clean_dep lib/libc strchrnul c @@ -357,6 +357,9 @@ if [ ${MACHINE} = riscv ]; then # 20251031 b5dbf3de5611 libc/riscv64: implement bcopy() and bzero() through memcpy() and memset() clean_dep lib/libc bcopy c "libc.string.bcopy.c" clean_dep lib/libc bzero c "libc.string.bzero.c" + + # 20260307 2a4e3112c811 libc/riscv64: temporarily disable strnlen() implementation until a fix is developed + clean_dep lib/libc strnlen S fi if [ ${MACHINE_ARCH} = "aarch64" ]; then From nobody Sat Mar 7 23:46:36 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fT0Km1bytz6TZ8r for ; Sat, 07 Mar 2026 23:46: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fT0Km0hGfz3RWD for ; Sat, 07 Mar 2026 23:46:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772927196; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qSOHgOFIXdXFCVQiVj4CAdfx3RZouqyVOETi6ZTjA7g=; b=Tr7CXE3SlMePqCTi7T2pBbEjdInb3njrCbt+o0ak9gt2ATa2KQ4aHiUje2HS8xNRAzgs7c qeACh+zF/f24rL61pyXl3efUpUldY6Ds9D0CniskZn4RxUXNGcqgywaVO94yiSvaAgBIhn e98qkaBH4CSdNIUJ2KMbG1xkw032RNNBGQroN/y+7nuIqWQ7N3M3JQmrm5UA/SWVKWXms0 1PxWnVcFTRJCOlIG7BZaITvDwX84mdUxc0203MAikTeQfvjWn50FDrxTd/IU4qT8CP4Khy Xt68yCds2HvJdUPHOkD7LYouS28Ys1oAZzhAVOMmz7ySxdreNA9MP+ItwSIMAw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772927196; a=rsa-sha256; cv=none; b=BT9TBXXDK0YhsSGag0cxmDNSfbRywWIQ5+Tw52d4V349145qu4qMW4SWaJF4e8eWfSuxXd wuki92nmfj9/NHj2Vnu4vGY7kNWcGgEVPA0MHaohRB1xEDQonSIVNUd0+/pph6N2kdKeS1 kkiRqgvBbkNLLAqpsaB88w00DGXm4RPryT9DOrKFdZpnnZZdStyGJXDru02Noi15OoaRvf fFTW+uctlHjSvgPqtD4gr2gquqtzTA6cG6vipMPyfhEkghqX7gppU9svN/sEvrH7FyNWmF bHWSpO3W3NwFBIdiBVUGQ3qnKfcJ8VK7DoeQwoVoOAY65PMnqGrHwl9PJ1LV2g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772927196; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qSOHgOFIXdXFCVQiVj4CAdfx3RZouqyVOETi6ZTjA7g=; b=xw6GNCwdfEfSuVoNcgoJhxfYCD9Yw9ec0rlXMhs7xEjfgl6nZqDhuQOsaYM338B1BpgLRA juhsr3Kn6qxPAdAwssKsnhmnQ/xGyUSieIdQ3Rgn3mM0XEr3BJJkUl1RSC/Jyqhhiwkm9s HsHxdMWCSh6bzYpXbC4xwOH9ffGB6dMIbsIZewF6L8b/4AOr/fTAx8S+hNz7M9LI7GNAJr IpUiV1hod1uHUYs57L+lXLPoU+qDwdZYi0v22Bm4ubAQ0n7PWamA4aIKP2uSt/nOCYaXCD +xou9kjwQ/xOAajjkN6wrtnewgW7pOg6dpcLmyj9ka4NGT/CHwwJcJ/+Hfz6fg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fT0Km0FvnzVYq for ; Sat, 07 Mar 2026 23:46:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 46f17 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 23:46:36 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: 3a410851bf02 - main - virtual_oss: Use virtual_oss_delay_ns() to avoid duplication List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 3a410851bf02c247e71bcd06fdeec2706c6b6070 Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 23:46:36 +0000 Message-Id: <69acb8dc.46f17.2d4e13b5@gitrepo.freebsd.org> The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=3a410851bf02c247e71bcd06fdeec2706c6b6070 commit 3a410851bf02c247e71bcd06fdeec2706c6b6070 Author: Christos Margiolis AuthorDate: 2026-03-07 23:46:25 +0000 Commit: Christos Margiolis CommitDate: 2026-03-07 23:46:25 +0000 virtual_oss: Use virtual_oss_delay_ns() to avoid duplication Sponsored by: The FreeBSD Foundation MFC after: 1 week --- usr.sbin/virtual_oss/virtual_oss/virtual_oss.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/usr.sbin/virtual_oss/virtual_oss/virtual_oss.c b/usr.sbin/virtual_oss/virtual_oss/virtual_oss.c index a663f029ef17..5554ddb9a592 100644 --- a/usr.sbin/virtual_oss/virtual_oss/virtual_oss.c +++ b/usr.sbin/virtual_oss/virtual_oss/virtual_oss.c @@ -64,10 +64,7 @@ virtual_oss_wait(void) nsec = ts.tv_sec * 1000000000ULL + ts.tv_nsec; - /* TODO use virtual_oss_delay_ns() */ - delay = voss_dsp_samples; - delay *= 1000000000ULL; - delay /= voss_dsp_sample_rate; + delay = virtual_oss_delay_ns(); usleep((delay - (nsec % delay)) / 1000); } From nobody Sat Mar 7 23:46:37 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fT0Kn25Gnz6TZFD for ; Sat, 07 Mar 2026 23:46: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fT0Kn1VPxz3RP7 for ; Sat, 07 Mar 2026 23:46:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772927197; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=l/GkThPIYRjsbhfwdgGo7r9qpyT9GQTlzbLey55fixk=; b=FRztx3gkaQFYvkaC5bKA/zWOjkLXRX7oKIw9YiZ7/dHV4PLnPPW2wGY9rPyODd00n6Sgqy LDRFBTMkurNHf/tPnLV+UUNT/9vAl5QzokLrr8vqUIAegb+xXQyKcv5HDMVzxycXeLaKe0 x6SbkqQRZ66yKj1aJSVaPYEcITa9GNSGmzhSp3LTuTlDx2qv7tfFSF+hIOTAP6ttbCjfPa 4+y7W14yBuIBGady/hEWLituTLDwPucEGz6os9bHZ8YWKhPs0iDqvZtyiqChPiMr/yccjt 5k2xFIofm6hYdG1UVA+PHY/CZiHPLSbT4ax1E70e6BckHCtxZ49eI1VRNslDVw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772927197; a=rsa-sha256; cv=none; b=kSqwhRkcgbczRpS5aFrU6DVME84ftIjySAciV/1iweLlii2bgBOGnqfU4HPI5LxVH+a8vP qAlraZuj5SNjGYEcNP7v7/KNNDMBQ9b8P9vL2shkY22RyuDCf9d+oIq2Wi+JXy3svzIqVu OijGmwWRmc0c2t0BcFXqqq0bj5Wnzk4u6kcoFLzdpyOiN6k6mScgojzt0k/2zvAXtXhAtP ktW37RUal+zo3CANRwXMzlXBnvD2EPyZ6Hee//AerNwzcY7Qp4rsCU9854d8wcH/CXyK4V 4oAubEuCzGBLgSls6dQtVv5h61WDTfoTnqPY1nkGs6fRAiYUrLU1+F/pyuLv6Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772927197; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=l/GkThPIYRjsbhfwdgGo7r9qpyT9GQTlzbLey55fixk=; b=jxpoSgRu2FfaERBENfk9HDMU/4gH7enE44Q8ERrSoyKfY8QwUAT5+xa6IJX7JbkMRKCPrR rd8PSmJneSFzXQ3aV8B9JPmodnA7Jp5CbGREtnyHCfjN3wHLCCZwdTuREU+MFH/3x9cAWE qhPSc20GOrljGSCrADA48PrlmrDQGpVEkN4ug8hLYEA3fyh2Uam5FjZyWF/EYPitX/diBG tXvmdop2gCLdEYbbAgt4mILwoXEOZjSXI8uFlz0KhsS/8JpMMnqth9ztCGhemZmjBT0DJl XiqwunNA0cCTu0ZXWXUda2jLXBgobzuCMqiRIQnf2tm8zy5TP/1y4ctfJ47Ahw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fT0Kn14DDzVcD for ; Sat, 07 Mar 2026 23:46:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 4643b by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 07 Mar 2026 23:46:37 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: e75c8faf277d - main - virtual_oss: Use virtual_oss_timestamp() to avoid duplication List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: e75c8faf277dded0a80d469cb8182583716a2211 Auto-Submitted: auto-generated Date: Sat, 07 Mar 2026 23:46:37 +0000 Message-Id: <69acb8dd.4643b.44fc0e3b@gitrepo.freebsd.org> The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=e75c8faf277dded0a80d469cb8182583716a2211 commit e75c8faf277dded0a80d469cb8182583716a2211 Author: Christos Margiolis AuthorDate: 2026-03-07 23:46:28 +0000 Commit: Christos Margiolis CommitDate: 2026-03-07 23:46:28 +0000 virtual_oss: Use virtual_oss_timestamp() to avoid duplication Sponsored by: The FreeBSD Foundation MFC after: 1 week --- usr.sbin/virtual_oss/virtual_oss/virtual_oss.c | 29 ++++++++++++-------------- 1 file changed, 13 insertions(+), 16 deletions(-) diff --git a/usr.sbin/virtual_oss/virtual_oss/virtual_oss.c b/usr.sbin/virtual_oss/virtual_oss/virtual_oss.c index 5554ddb9a592..1d95c87d57b1 100644 --- a/usr.sbin/virtual_oss/virtual_oss/virtual_oss.c +++ b/usr.sbin/virtual_oss/virtual_oss/virtual_oss.c @@ -41,6 +41,18 @@ #include "backend.h" #include "int.h" +uint64_t +virtual_oss_timestamp(void) +{ + struct timespec ts; + uint64_t nsec; + + clock_gettime(CLOCK_MONOTONIC, &ts); + + nsec = ts.tv_sec * 1000000000ULL + ts.tv_nsec; + return (nsec); +} + uint64_t virtual_oss_delay_ns(void) { @@ -56,31 +68,16 @@ virtual_oss_delay_ns(void) void virtual_oss_wait(void) { - struct timespec ts; uint64_t delay; uint64_t nsec; - clock_gettime(CLOCK_MONOTONIC, &ts); - - nsec = ts.tv_sec * 1000000000ULL + ts.tv_nsec; + nsec = virtual_oss_timestamp(); delay = virtual_oss_delay_ns(); usleep((delay - (nsec % delay)) / 1000); } -uint64_t -virtual_oss_timestamp(void) -{ - struct timespec ts; - uint64_t nsec; - - clock_gettime(CLOCK_MONOTONIC, &ts); - - nsec = ts.tv_sec * 1000000000ULL + ts.tv_nsec; - return (nsec); -} - static size_t vclient_read_linear(struct virtual_client *pvc, struct virtual_ring *pvr, int64_t *dst, size_t total) __requires_exclusive(atomic_mtx) From nobody Sun Mar 8 00:06:19 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fT0mX1pnmz6TbYC for ; Sun, 08 Mar 2026 00:06: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fT0mW4qGwz3VPY for ; Sun, 08 Mar 2026 00:06:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772928379; 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; bh=wPc/oPxjSEK5es3MvMKnlqFche0sSq7OLkd+wo9SPgk=; b=ywAbe7da+M6JkExsuyeNBSmJ88k745GbOD3Or/pJYUDyBfTb5HRecqy2KsTROVWue4uM0k gN0ZPwfMSkA9dlWdKt8WNp7rPL6whjatHCMvUMxgqDugQSM8VdTJT6jt94Ncugt0u43Kqc NCKfdVjmQZiQizyHKnilM+2ma78M1ZBC8CafXohNWqoZ35qFwH7+mtZZjnG6/lh54sJ/t9 73/EYC3+HNRb93/HscUoDyvsuodg0yrpCQUWLkPQRq6DUvXxW0aNErmPn6QRNOSMVkh/A0 zWUhS3Mq0u6Z/toFFCFK5f45af6a9crLU5aDHYlczTFbvMWvi1pAGR2hNU15Yg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772928379; a=rsa-sha256; cv=none; b=kr9yQzjsDqUce6SZnjSORvCkXEQKWFNfUCLKz/U89n2Ij2R1Q5IqeBnKabK1pXZBeBLVIC LKqsK2tDWaxiVvUkjS+APbEnU0HHxxFSzV89b+6BB9cJhLV2Aem0edUOsHWRBo5t6OTP9p rLmcK7c+/5EfOq27uIiu0wXMEJLmy2w7g+9QG5ydJJSvny7e8v9JQNKgKoHCIRiZJOxk4L o1av95PeR4R6+tMquQnGAfc1h8TcFOzK2w27eSWSXW5uphYmLUT76HYOWEhgqZtwKyykeg 0NGfeiKHRUXg0sJwYCQqiCSxkq/n4zYsL4lC+u+WhTjNgzFCIZvZJCHxcbUHJA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772928379; 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; bh=wPc/oPxjSEK5es3MvMKnlqFche0sSq7OLkd+wo9SPgk=; b=sI1DSiWCcSnYsx8xLXFgvaJ7osfrCs2HMY5/GP3mBY25yyja7LKK0zWtNmh69Tczw/4lTb nnnYB20pjpkmRCSl/+P9VpnQV6bUvjLTZ3AGg6fGVykkC/BwlFK1YCzmdDyxMvezcZanzq oK8hYfmhin89sIZTKmC54lazmLFqZOuNpaVoXa6JaTn3V3qrBq0D1RmG24/Bq3oQ8gCNJO rmazZUahfA7fs/efMfgsZ7s8x8MDAVUvfNMZR+LMrpKABa5gG0g1osCIQCLF9KgYt8T9IS 7nY5YFe9v7dIUYPM0HQ57K1J/q1z4lQyjV8u7UM0zzLZuD7G8id83hfyAswwyw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fT0mW4McBzX6R for ; Sun, 08 Mar 2026 00:06:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 46f4f by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sun, 08 Mar 2026 00:06:19 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Cc: Marian Cingel From: Warner Losh Subject: git: 756500fa4b1e - main - kern.post.mk: Replace "mkdir -p" with "install -d" List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 756500fa4b1ed0807e16c9063f27031544cd7706 Auto-Submitted: auto-generated Date: Sun, 08 Mar 2026 00:06:19 +0000 Message-Id: <69acbd7b.46f4f.148616da@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=756500fa4b1ed0807e16c9063f27031544cd7706 commit 756500fa4b1ed0807e16c9063f27031544cd7706 Author: Marian Cingel AuthorDate: 2026-01-13 17:48:04 +0000 Commit: Warner Losh CommitDate: 2026-03-08 00:06:15 +0000 kern.post.mk: Replace "mkdir -p" with "install -d" to create the 'dir' entry in METALOG Signed-off-by: Marian Cingel Reviewed by: imp, kevans Pull Request: https://github.com/freebsd/freebsd-src/pull/1967 --- sys/conf/kern.post.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/conf/kern.post.mk b/sys/conf/kern.post.mk index 343abc5853f7..7216393dbdf1 100644 --- a/sys/conf/kern.post.mk +++ b/sys/conf/kern.post.mk @@ -457,7 +457,7 @@ kernel-install: .PHONY ${INSTALL} -p -m ${KMODMODE} -o ${KMODOWN} -g ${KMODGRP} ${KERNEL_KO}.debug ${DESTDIR}${KERN_DEBUGDIR}${KODIR}/ ${INSTALL} -m ${KMODMODE} -o ${KMODOWN} -g ${KMODGRP} \ $S/tools/kernel-gdb.py ${DESTDIR}${KERN_DEBUGDIR}${KODIR}/${KERNEL_KO}-gdb.py - mkdir -p ${DESTDIR}${KERN_DEBUGDIR}${KODIR}/gdb + ${INSTALL} -d -o ${KMODOWN} -g ${KMODGRP} ${DESTDIR}${KERN_DEBUGDIR}${KODIR}/gdb .for file in ${GDB_FILES} ${INSTALL} -m ${KMODMODE} -o ${KMODOWN} -g ${KMODGRP} \ $S/tools/gdb/${file} ${DESTDIR}${KERN_DEBUGDIR}${KODIR}/gdb/${file} From nobody Sun Mar 8 13:19:43 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fTLN017pMz6T7qw for ; Sun, 08 Mar 2026 13:19: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fTLMz6KWWz3WVD for ; Sun, 08 Mar 2026 13:19:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772975983; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9vV5uKQvZfJSDmcSpR3b/F8kLGzK/OPI654IhiwdxMY=; b=NkJK6V7S+8jjDqKf23STK0KMf6ulqS3iUFOfmWyMR8iJd83hwKJAE7Z0iIFE53/cwvxSu0 Ho62ZZNv8ZC4EoezdwpdURJxMM51dVZ+XVh+vMby6VOdXScX2zPKjs/WdVvDapbFrqxitk gRq+zvAHpuqklYFWVUqlx59hqli30lqiSkCZivlMaObopU8w/e4+TUgQpyCo1kYmA66Q+Y H2aSbWe6DkYr8TiKbW83W9NQLpd8AEtUhkWMSixjO75y2zjxTqFdeakIO8TJBrnqN97WTL z8e6idTJhCvzwp7m+ct0zRg9/awASgjn6JZM3gaHmPbYcL6in/q4ActKs93s6A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772975983; a=rsa-sha256; cv=none; b=Ttas82cmG6KRD3qQ9yYGKnN7Sj8NoAJgsHg5VnuWwuhW2SG2XxFEhcucm7c4TKGj1NIeeE HKPog/k/bw36Z7SCl/v7FuPKbWHk/SU7VYtFZla9+nSp8ENE+KC0w+llutkR7+otOqTdY1 x01IbwO0xaJGv/Gjy2JDoR9eN0h2YIqnvYZ/MDVz14d2uUo9p+TzLBOQbJtbsUGkKutTYg tg/wLYH6cbj6NqCWaJ6tKNFwWGgXWjVRq2AABnpci/48guTZQgki+colivgr4txQOUvwwE 99ZIeIAd0WE4piF0CnzGTVPPWnpqjx5qXyNsWcyB72iS95SvYTU+1g9n/4IPFw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772975983; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9vV5uKQvZfJSDmcSpR3b/F8kLGzK/OPI654IhiwdxMY=; b=EB2Ihf4zKaGyd26CnZLo5EE8LWGlJZ5iaR+mPFvz0wHXMcPiuL1xHwlt370A1pJ9C6J63z MtenS5B+iGrQtC7nzp67Z6FBlHS/YT2edtkukzIdZQXwrFpKtqbLcQSIZTx9x9+P+Vb2LE 03oZ7En8sOnEZkoZAixqEZf9499yrPauXnPHcYqXYz4CKPLUDHxHzy5a7KVHHDculhsg4A pqKz5TmnXq+Y0wsttIKv7xTgNbrBB7ISoUtmng3HBuXEIsKtslP4YlZit1VAdTOYvptau6 FhaapmEWKJaMHtDcYbs7nSKKbgDwjqrRWSWZ+xR4/3/ciDzBYc0H4JiAbpynQA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fTLMz5ZzQzwtF for ; Sun, 08 Mar 2026 13:19:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 25e83 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sun, 08 Mar 2026 13:19:43 +0000 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=B8rg?=rav Subject: git: 9c9f27e8af28 - main - tzcode: Record merge of 2025b List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 9c9f27e8af285d778a312be2f8002c4404c1e77d Auto-Submitted: auto-generated Date: Sun, 08 Mar 2026 13:19:43 +0000 Message-Id: <69ad776f.25e83.2d9a1f93@gitrepo.freebsd.org> The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=9c9f27e8af285d778a312be2f8002c4404c1e77d commit 9c9f27e8af285d778a312be2f8002c4404c1e77d Merge: 756500fa4b1e 76d3e9d6b360 Author: Dag-Erling Smørgrav AuthorDate: 2026-03-08 13:17:57 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2026-03-08 13:17:57 +0000 tzcode: Record merge of 2025b Fixes: 967a49a21a27 ("Update tzcode to 2025b") From nobody Sun Mar 8 16:25:28 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fTQVL3P2Gz6TPZ4; Sun, 08 Mar 2026 16:25:30 +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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fTQVL2pgmz3q2j; Sun, 08 Mar 2026 16:25:30 +0000 (UTC) (envelope-from des@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772987130; 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=RcGoAh05gUyT8INmpbxnTuKZvFfKgD70zQtx1ME6caM=; b=bj/GVEKccBhSJJgxAYRRQYeifQd2rqasW5xUHgLtzErHMe+d/77rGOtRNgfmG1r2o12wro n8xfS55xahbTWKM6waTIvfWJxCO6ZgmzkajRuvWO6cnnjLVJrayCv63MNNmtPfwDq8iBgW ZfoAos5gbEQHdZsYlSq7cI5SAVX5EtpT7GgH8eE+46GBGZw3KnDN9d27qg8eLmpKB6qg0+ /RGJgH42f11XrTog8DD6u5nQw+kfszRnsnljFsfnpLCe3KoTpOp7c7aJQE9aeymF+CNJPZ 71QPg2ek0Ps1iUDe3BWGIgxaMcl54jCK6pW9nfjmXZo4MklG8v2DipNb2e45nA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772987130; a=rsa-sha256; cv=none; b=yx+nsg/7KOpQ9N60eJ+6qYVuJcSc/HqbiZzNXVB+Vc7P4NkpUSrHwJ1ZYnWVl39iM9QqYO 7Vt0n02mqfOUYk3YRSUy+q/tb7w8bL+V+TI4wtVsAVUUwAqHuLRevioEijFHly79megad7 xbDipbFKRm960ywQEL1GGGRlar6YAFShmzAGhol9jLeHlIUaOjWc5Uz/0rD+naXesMzflN ckT0PPZeIyjM2m5LU1rwOuxP/DZGUTVSFufRKXtsItQ8m8lhMw6FYljAOSGl/0ml7YMXd8 O0hjHEDIBqHoHdyHT2e+Oiy53XAWZavzbNkwTNKTf/rdPWkgr3mNjIVSz4VZ1A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772987130; 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=RcGoAh05gUyT8INmpbxnTuKZvFfKgD70zQtx1ME6caM=; b=VRJzvPWsc8QVU+2lmrBKeJEGyJRdGkbcrrP750u0j37FnhZ32DSR7Wtrega1mFOmSc6YCd OMY6FAJ4nbuTgNjO+8piMRPdNYyuj3NCMUbYoLryeEruLgiarBGgoQpSBahOm1c0zguR6F bS8Kpa+XeBrsL5VrvSEd6Dm5kJlNQRO/z8Carj1Fnt9ITStTHOcc/XbAPdoZ0AkvO11cKD fhJZwZAAW3fmDRu1cxfGqi5zPhwnxrzRUUnbNrArCal1LXcP96+LD/8SFgDArMyl3EDWw9 O378Zbqu8gmo659mj3JOv4pYHx7vMWDr0rejGmpG3GMOmWHlf2UyempVYzmU7g== Received: from ltc.des.dev (lfbn-nan-1-698-103.w86-236.abo.wanadoo.fr [86.236.35.103]) (using TLSv1.3 with cipher TLS_AES_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 4fTQVL19RFz14vZ; Sun, 08 Mar 2026 16:25:30 +0000 (UTC) (envelope-from des@freebsd.org) Received: by ltc.des.dev (Postfix, from userid 1001) id 27E3F1236CC; Sun, 08 Mar 2026 17:25:28 +0100 (CET) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Ed Maste Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org, Hans Rosenfeld Subject: Re: git: 2a514d377b37 - main - bhyve/virtio-scsi: Preallocate all I/O requests In-Reply-To: <69a86c2c.3eae0.6544adfe@gitrepo.freebsd.org> (Ed Maste's message of "Wed, 04 Mar 2026 17:30:20 +0000") References: <69a86c2c.3eae0.6544adfe@gitrepo.freebsd.org> User-Agent: Gnus/5.13 (Gnus v5.13) Date: Sun, 08 Mar 2026 17:25:28 +0100 Message-ID: <86zf4igufb.fsf@ltc.des.dev> List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Ed Maste writes: > + assert(iov_to_buf(req->vsr_iov_in, req->vsr_niov_in, > + (void **)&req->vsr_cmd_rd) =3D=3D VTSCSI_IN_HEADER_LEN(q->vsq_sc)); This assertion breaks the gcc build. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@FreeBSD.org From nobody Sun Mar 8 17:07:33 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fTRQs3rdPz6TSmp for ; Sun, 08 Mar 2026 17:07: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fTRQs38F9z3vd5 for ; Sun, 08 Mar 2026 17:07:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772989653; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=dKdUzirvCzxUz/LDe+IgzGcABACxRXbuDEl5l4OkrvY=; b=tJ1TOaR4vX9LoFCqFNFFT/PoMVfv1VupDJTY5VtCkP5fPrRrtzJu7FU0b6UK/p+KFUOMFZ uwSP+4gkpfIPaoboX7wTKooxHuEeqQ7en58rXi/GKyUSU2mfDFpORdVaNyggdDc0OPeDjK WQKBvwsLioC/x8Pd/ZVVkhv6feZyQknBmbbb0ihjxWizY1B+nSDY6SPOUqOtkArK90uXKf +HVo7Xbn3jeGQgrD+iB2bp5lZPHjWJTk0q2ST5txsLIPgsg+fLJztOIfs9vkujiynDZtIW dEy7MfpCAUyWmgc31FbU67XAHShQFRUzyiqeHKsbWm2357EOgm7FXCV1xXE7WQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772989653; a=rsa-sha256; cv=none; b=ckoDrZ1gXwUJMrxHlG9WwrmwnsGMM2088x/G2PUSCHOP5iitrAyVHqIPKNb092Eb3BfTi5 XM6+kyrSnYbMj1E7kjedVoDL7OiIuF5Pu2OR9bolXe7u0wdhbOZwFQbtV95QOq/tN08wCh njnCMMwfYumO2IxzvyeT2I/6Xi05nGlvScSHtC6tTxYxdXFGwRFkEKizIKI6QnhtWv6WYn Wojulvhwty31UT03Zc0ETTGXaBfOHXPLmM3Paq7VkU8BKy9paqnSQtBWRaE5oHIKe/iNI1 umhO1T5O8rKYL3NBy+TZmy2ywKutMRnG1/1/jre1KsyYFMV7Ki1+W/nPwTmjIQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772989653; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=dKdUzirvCzxUz/LDe+IgzGcABACxRXbuDEl5l4OkrvY=; b=blHz2jtmWAAk3kIPk53tvIXsXPhpcF2fv8gTS8JavHSbgdL6Twtvlq4pD5ZkgovWzkqSi3 Ob926CRvGx9p/DaRyeiw9Fnad7gDQDtkmJ3gKDE3mZUe8pBKC1sSsdNh698Zo1gLCWPwtq 7DQZgGm+U1EG2Htm9O/bH1Rk8iYV03zQ8n9wDVtqPljqZcciGYyhJkH0etXD3Brcow4LEF C4PBs/10xEu/opQFRYC6Os+C3/PHtnsCbQjZtcRZXWUmpL+l7m8Y8KANSeth+01T7E0Gvj hEdz1pNzZI3ThxjOILWSuUONkW9s0FIslYxStyBzlxX4UAkp1KQIuBpEDVLrzw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fTRQs2gvrz141Z for ; Sun, 08 Mar 2026 17:07:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 433ce by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sun, 08 Mar 2026 17:07:33 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 53c69fd933dc - main - LinuxKPI: 802.11: lkpi_sta_auth_to_scan() fail graciously on lsta == NULL List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 53c69fd933dc49f69d5603fb27ce51064ebe681e Auto-Submitted: auto-generated Date: Sun, 08 Mar 2026 17:07:33 +0000 Message-Id: <69adacd5.433ce.68a3fd9c@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=53c69fd933dc49f69d5603fb27ce51064ebe681e commit 53c69fd933dc49f69d5603fb27ce51064ebe681e Author: Bjoern A. Zeeb AuthorDate: 2026-03-08 12:48:51 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-08 13:49:52 +0000 LinuxKPI: 802.11: lkpi_sta_auth_to_scan() fail graciously on lsta == NULL Usually after a firmware crash, we see reports of crashes in lkpi_sta_auth_to_scan(). One of the last ones was in the PR mentioned below. These crashes are often attributed as the problem while the real problem happened before. At this point try avoid the NULL pointer and to fail graciously if lvif->iv_bss (lsta) is no longer set. This way users have a chance to possibly recover using netif restart wlan0 rather than dealing with a panic. See if this helps us to better track down the original problems rather than the follow-up crash. On a debug kernel the KASSERT should normally have caught that condition as well but we see panics on page faults were the log line was there but then the lsta->ni deref has happened, which is after the KASSERT. I have not checked if this is a reordering problem or if the people reporting had IEEE80211_DEBUG on but not INVARIANTS. Sponsored by: The FreeBSD Foundation PR: 286219 #c11 MFC after: 3 days --- sys/compat/linuxkpi/common/src/linux_80211.c | 26 +++++++++++++++++++------- 1 file changed, 19 insertions(+), 7 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 63f92b8afb2b..01347586ef63 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -3215,16 +3215,28 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int wiphy_lock(hw->wiphy); LKPI_80211_LVIF_LOCK(lvif); -#ifdef LINUXKPI_DEBUG_80211 - /* XXX-BZ KASSERT later; state going down so no action. */ - if (lvif->lvif_bss == NULL) - ic_printf(vap->iv_ic, "%s:%d: lvif %p vap %p iv_bss %p lvif_bss %p " - "lvif_bss->ni %p synched %d\n", __func__, __LINE__, + /* + * XXX-BZ KASSERT later; state going down so no action in theory + * but try to avoid a NULL-pointer derref for now and gracefully + * fail for non-debug kernels. + */ + if (lvif->lvif_bss == NULL) { + ic_printf(vap->iv_ic, "%s:%d: ERROR: lvif %p vap %p iv_bss %p " + "lvif_bss %p lvif_bss->ni %p synched %d; " + "expect follow-up problems\n", __func__, __LINE__, lvif, vap, vap->iv_bss, lvif->lvif_bss, (lvif->lvif_bss != NULL) ? lvif->lvif_bss->ni : NULL, lvif->lvif_bss_synched); -#endif - + LKPI_80211_LVIF_UNLOCK(lvif); + /* + * This will likely lead to a firmware crash (if there + * was not one before already) and need a + * ieee80211_restart_hw() but still better than a panic + * for users as they can at least recover. + */ + error = ENOTRECOVERABLE; + goto out; + } lsta = lvif->lvif_bss; LKPI_80211_LVIF_UNLOCK(lvif); KASSERT(lsta != NULL && lsta->ni != NULL, ("%s: lsta %p ni %p " From nobody Sun Mar 8 17:07:34 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fTRQt6P0tz6TSDQ for ; Sun, 08 Mar 2026 17:07: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fTRQt4Dqpz3vNv for ; Sun, 08 Mar 2026 17:07:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772989654; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=88ZgkqfowQEiomeAjAM9ouopph+AWkV982BNwFgVF2g=; b=WMeYktly8NbHP9bW4dpRP8UL4PEtzURBbM5io2Pb711mhCj3xj6caMOdfe1WofbJq3Xb5J wBhdpoXd1zd8fLaZrQBFkeO58M8/RVVon9h46xiGvKREEh/QI7/Q2Yp94Rvlqh9+RWv5g2 xW64DHsFOUZyEGkDTDrnPfqdadNicLvm1Ve7ug1nVzFlgHeQZ/zLhXwjCBxZSa+B75IHDo VflBfH1KkmjORM28r1K3PhssxGooAEJah909Oty/ptslKq6QtPAljc2cfbuIKKo0G7lwKC GJ/9tlZ4vgzP31Op5LZB6TG73XhLkyDMMvqGePy/PJxxHXJtIsdK0wc5C0wOiw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772989654; a=rsa-sha256; cv=none; b=O83Y0f5Zs3izj+ZvDZq/ublECUSwUsAp92AqxY8Db++UiKX2ims40DmrTm7tiduh9mQNDJ yvLX8fKKoyLsDgrtV36M+Q8/uCcbgkJXe/j1MWo/M5Oi3iuRn3xgTvTMIjn6u1vjqdqLck j88LPYOBV3aGasLkDiigyEVmmUIpq1uwBTLXB8Ed1EukYvmsGtENv5v2pybrf/8VGMu8mM fE9gXFxlMDDXHVN/QMNG0sJpNUgow6nmpnj8r4tb9JF19NQ5Ce8x25gTNyuhV5QHpa3cW7 wULHt9cDenAKl++SKdEKlN+M4wVCGBBLOvVc8JSZdnKEVlJ5Gn1FmBS5My7R1w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772989654; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=88ZgkqfowQEiomeAjAM9ouopph+AWkV982BNwFgVF2g=; b=DRRC7B1dw4P51LhQNDgauBI1jOlrEjtGGTctB2qGKkVlkijcMC+84AtXQGlLP8U0CQYKRc gcUcVQyAtJMO2VlwsvpvbFh0lRxwxHXpRBXz5mS8wKoGPFYKVgf+nXtte2Lt/K/efkTYCd fWZ95J1jpiQYeIMXqoyUsC9IYczPCzz1F8SmTs2xcAFwr8Abq3XaJkXdfUcE7svEUZ3eew 5UJE9ib20trWG7Dcha21142WD2kKYWYYju3K8RVufRGOTwZG1ji9cq8P7GJL1amDq/0EAT ZIk/anBfZ8NnBEm+NPXB3nmrvweLbTPwBX5RRDGjfQdEvC/Ly+vzT76RdFv8tw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fTRQt34c4z13Vf for ; Sun, 08 Mar 2026 17:07:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 45bf4 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sun, 08 Mar 2026 17:07:34 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bjoern A. Zeeb Subject: git: 6cfd2b93e680 - main - net80211: fix VHT160/80P80/80 chanwidth selection in the "40-" case List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: 6cfd2b93e68061c7831016b91c2e308d01658764 Auto-Submitted: auto-generated Date: Sun, 08 Mar 2026 17:07:34 +0000 Message-Id: <69adacd6.45bf4.3cc0e7a1@gitrepo.freebsd.org> The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=6cfd2b93e68061c7831016b91c2e308d01658764 commit 6cfd2b93e68061c7831016b91c2e308d01658764 Author: Bjoern A. Zeeb AuthorDate: 2026-03-08 00:57:33 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-03-08 13:50:02 +0000 net80211: fix VHT160/80P80/80 chanwidth selection in the "40-" case Depending on the base channel ni_vht_chan2 - ni_vht_chan1 can be negative. Apply abs() as indicated in the comments right above | CCFS1 - CCFS0 | = 8 or > 16 in order to fix the channel width selection. Sponsored by: The FreeBSD Foundation PR: 293645 Fixes: 4bf049bfeefd9 MFC after: 3 days Reviewed by: adrian Differential Revision: https://reviews.freebsd.org/D55717 --- sys/net80211/ieee80211_ht.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/net80211/ieee80211_ht.c b/sys/net80211/ieee80211_ht.c index 38568674a792..9b2b0df33785 100644 --- a/sys/net80211/ieee80211_ht.c +++ b/sys/net80211/ieee80211_ht.c @@ -34,6 +34,7 @@ #include #include +#include #include #include #include @@ -2038,11 +2039,11 @@ do { \ } /* CCFS1 > 0 and | CCFS1 - CCFS0 | = 8 */ - if (ni->ni_vht_chan2 > 0 && (ni->ni_vht_chan2 - ni->ni_vht_chan1) == 8) + if (ni->ni_vht_chan2 > 0 && abs(ni->ni_vht_chan2 - ni->ni_vht_chan1) == 8) can_vht160 = can_vht80 = true; /* CCFS1 > 0 and | CCFS1 - CCFS0 | > 16 */ - if (ni->ni_vht_chan2 > 0 && (ni->ni_vht_chan2 - ni->ni_vht_chan1) > 16) + if (ni->ni_vht_chan2 > 0 && abs(ni->ni_vht_chan2 - ni->ni_vht_chan1) > 16) can_vht80p80 = can_vht80 = true; /* CFFS1 == 0 */ From nobody Sun Mar 8 17:39:50 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fTS8C6419z6TVWy; Sun, 08 Mar 2026 17:39:55 +0000 (UTC) (envelope-from herbert@gojira.at) Received: from fout-a6-smtp.messagingengine.com (fout-a6-smtp.messagingengine.com [103.168.172.149]) (using TLSv1.3 with cipher TLS_AES_256_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 4fTS8B4pJ4z40vD; Sun, 08 Mar 2026 17:39:54 +0000 (UTC) (envelope-from herbert@gojira.at) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gojira.at header.s=fm1 header.b="G/Y69qwQ"; dkim=pass header.d=messagingengine.com header.s=fm1 header.b=fvh4K4E6; dmarc=none; spf=pass (mx1.freebsd.org: domain of herbert@gojira.at designates 103.168.172.149 as permitted sender) smtp.mailfrom=herbert@gojira.at Received: from phl-compute-11.internal (phl-compute-11.internal [10.202.2.51]) by mailfout.phl.internal (Postfix) with ESMTP id CACCFEC056C; Sun, 8 Mar 2026 13:39:53 -0400 (EDT) Received: from phl-frontend-03 ([10.202.2.162]) by phl-compute-11.internal (MEProxy); Sun, 08 Mar 2026 13:39:53 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gojira.at; h=cc :cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm1; t=1772991593; x=1773077993; bh=nfgTfyS7b7 VHrhQDIv0K2NreHnFyNs41tg+ZUjVnXWM=; b=G/Y69qwQ8NU+T15w+VDJotH+/Z 56AU88OV9/JiWkqQk6qEzwzaM8e6gnWPJarEa4knAdwXDGYZUIiGeePUY4KzVFA3 KeYJ9Yfe9/vQ+05Q7HvSVKIDl6LLp8JzrrOtVQ7oedaD/u+w0Qd7k4ENZrZ/PRRo o9KlD0T+hDZw9+U9UT1Eh6acIC/2T3qm/PTRZTSvw0jVxFrwJ9lv7bsJfpOX8xGL Td3hcHWB+/p/oabub/vLZb8SQ4f2n9LbzZJ7YYNmCUveKf8iUsV4gt6R28eYlMUq y5SswoiQ5/78OKu2DmX4xbHaWateGT3hH6b85F/8tm8fsdv9iZgVdOJ6B7BQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1772991593; x=1773077993; bh=nfgTfyS7b7VHrhQDIv0K2NreHnFyNs41tg+ ZUjVnXWM=; b=fvh4K4E6Ag/SiaUYSohLZfQ3y03pzC9NNjBcWQZrl9wu+Ws0BD4 5iMYTBp4y+h2B7idcWxdziCOfAnQLoDj0BhZg71BKvyZ9JZvfhHI4gdk6WeFuy5N X0808xfZz1w8BFL055p6yrRv8xviGhlsZoDpsBHq592Nq6Qc1nLSFW95BH3iCt7P EhODdsuz7v66EH1wW98qqEN2Udk3UF7diQ6ds+dyWaQKBAx/w/n1rO3Sp21U73WY UU52BUCzbXa7SPQU1WVsTEbrttz2twkJ1lXmbVb+2DqciGNnI//N/slET7B4gPia oxRF5fbGI6tIZr8yghyLsrfkLGpULBD2t0g== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefgedrtddtgddvjeehkeduucetufdoteggodetrf dotffvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceu rghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujf gurhepfffkhffvvefujghffgggtgesthdtredttdervdenucfhrhhomhepfdfjvghrsggv rhhtucflrdcuufhkuhhhrhgrfdcuoehhvghrsggvrhhtsehgohhjihhrrgdrrghtqeenuc ggtffrrghtthgvrhhnpeefhfehffegvdehuedtuefgkeefieffieejhfeggeekgeevjeeg feffgeeglefhtdenucffohhmrghinhepfhhrvggvsghsugdrohhrghenucevlhhushhtvg hrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehhvghrsggvrhhtsehgohhj ihhrrgdrrghtpdhnsggprhgtphhtthhopeegpdhmohguvgepshhmthhpohhuthdprhgtph htthhopegrnhgurhgvfiesfhhrvggvsghsugdrohhrghdprhgtphhtthhopehsrhgtqdgt ohhmmhhithhtvghrshesfhhrvggvsghsugdrohhrghdprhgtphhtthhopeguvghvqdgtoh hmmhhithhsqdhsrhgtqdgrlhhlsehfrhgvvggsshgurdhorhhgpdhrtghpthhtohepuggv vhdqtghomhhmihhtshdqshhrtgdqmhgrihhnsehfrhgvvggsshgurdhorhhg X-ME-Proxy: Feedback-ID: i64fe486c:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sun, 8 Mar 2026 13:39:52 -0400 (EDT) Date: Sun, 08 Mar 2026 18:39:50 +0100 Message-ID: <87ecludxuh.wl-herbert@gojira.at> From: "Herbert J. Skuhra" To: Andrew Turner Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: c499ad6f997c - main - virtio: Use bus_dma for ring and indirect buffer allocations In-Reply-To: <69a71c75.40215.43f39fc6@gitrepo.freebsd.org> References: <69a71c75.40215.43f39fc6@gitrepo.freebsd.org> User-Agent: Wanderlust/2.15.9 (Almost Unreal) Emacs/31.0 Mule/6.0 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-Spamd-Result: default: False [-2.60 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; MID_CONTAINS_FROM(1.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-0.996]; R_SPF_ALLOW(-0.20)[+ip4:103.168.172.128/27]; R_DKIM_ALLOW(-0.20)[gojira.at:s=fm1,messagingengine.com:s=fm1]; RCVD_IN_DNSWL_LOW(-0.10)[103.168.172.149:from]; MIME_GOOD(-0.10)[text/plain]; ARC_NA(0.00)[]; ASN(0.00)[asn:151847, ipnet:103.168.172.0/24, country:AU]; DWL_DNSWL_NONE(0.00)[messagingengine.com:dkim]; MIME_TRACE(0.00)[0:+]; TO_DN_SOME(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[]; DMARC_NA(0.00)[gojira.at]; TO_MATCH_ENVRCPT_ALL(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; RCPT_COUNT_THREE(0.00)[4]; RCVD_TLS_LAST(0.00)[]; MLMMJ_DEST(0.00)[dev-commits-src-all@FreeBSD.org,dev-commits-src-main@FreeBSD.org]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[gojira.at:+,messagingengine.com:+] X-Rspamd-Queue-Id: 4fTS8B4pJ4z40vD X-Spamd-Bar: -- On Tue, 03 Mar 2026 18:37:57 +0100, Andrew Turner wrote: > > The branch main has been updated by andrew: > > URL: https://cgit.FreeBSD.org/src/commit/?id=c499ad6f997c8c5f61c88925e6d1e826d0c0f6c4 > > commit c499ad6f997c8c5f61c88925e6d1e826d0c0f6c4 > Author: Sarah Walker > AuthorDate: 2026-03-03 16:08:11 +0000 > Commit: Andrew Turner > CommitDate: 2026-03-03 16:29:15 +0000 > > virtio: Use bus_dma for ring and indirect buffer allocations > > While the majority of virtio platforms will be fully coherent, some may > require cache maintenance or other specific device memory handling (eg for > secure partitioning). Using bus_dma allows for these usecases. > > The virtio buffers are marked as coherent; this should ensure that sync > calls are no-ops in the common cases. > > Reviewed by: andrew > Sponsored by: Arm Ltd > Differential Revision: https://reviews.freebsd.org/D54959 > --- > sys/dev/virtio/virtio_ring.h | 27 ++++-- > sys/dev/virtio/virtqueue.c | 216 +++++++++++++++++++++++++++++++++++++------ > 2 files changed, 209 insertions(+), 34 deletions(-) After this change I see a lot of "kernel: vtnet0: watchdog timeout on queue xx" errors on amd64 (arm64 seems to be OK). Reverting this commit resolves the issue. From nobody Sun Mar 8 19:35:44 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fTVjr6Dmjz6TfNW for ; Sun, 08 Mar 2026 19:35: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fTVjr5gDMz47XV for ; Sun, 08 Mar 2026 19:35:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772998544; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+hIL/oPrP+BBEgSx3KCGjh5m7d2d6QWHyV8ovj/56aA=; b=ZNNhCt++HZ1MFiZjBQ7ttZCvnt+Q6KKenS4eCpcSHiQ8OoB+kDsbdntj3f4AIeNI7y7NLW jTHyyX6r6s5MqPpOn6mYRlepTafXr5s7N2WLGOb5LcnOcSFyYhNncAboW7SuwStmutHFsm LT4KNC/oTSri7rqNfIQM0t+Jy5jHPCUfnTVNIlW1dBuaRRDvuzzHqfqv3TAX3bjP46+V+1 po26yYQnkXl0Zg1hY/G9q+sdsOcUrvxhxBAKH76UWxYh7LqAyVGzsq5MrP6+bjN4S+SYpy tC98Y+uUNNsF7BCY9gGcyN7DoOqo8/drGEutZ9a5em6B76ya/sL0u0bQIJzWmg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772998544; a=rsa-sha256; cv=none; b=dsC1DP9xj8Ebr+P4LB1DXgnUMR/HGTrCCisfM1sxLHSsglUnDx/FTCYQ+b4LACmBwrG3Hz tjmZQ8jDWK8XqT4dYWhDl8Yao10Ai0LP+aFs01wHdtydeg4TcJ1U5cV2qWECLttykbZKCF L3TEwEzSm8ayIvwSFPZO/egS93H0yLLDs/ooOypJniDMqqE063HTFR2NC/KTja1gbJLaPu w4GZ2k7d75Howo0RvzP/HFCInVoqAUagfC8zvDbyXyZSVwBPLl4mkU+jJ/NIn7LUVwYY+a 8nb0pjAW8NKihGSGSCHqBl9dEglRlUagnEAgqS6SxzGgK5Rfh3ujsmIMJmp6ow== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772998544; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+hIL/oPrP+BBEgSx3KCGjh5m7d2d6QWHyV8ovj/56aA=; b=D2SU3WJiQEGEp89Z9HsShKDoplsr3DXJ9zF8pVhhLOuCer2LlfffrR0cMH2oTEWUigaDtO B7aOnw/UsR87rSgBC0JeMuZwCZG6eTrrZCQiJAi69h5YuLPpA//DMED64S//pi5s9l8NaN z60tzgtDOAo4XMButiYHZbnYbR78zMrtAO/MRx/qOD7ucHegTtjuVV7VdNCLL2FitIUAT7 f65Ff70j+gdBhX6zTHTgPR6yimlMbeEXSD1Qhaw9k0ssbSleyYiqA/IgBcskS2thyJfu7j kD9ciP9sqyI8n0HhdkC9kYxN6X8oaJXw8UHq2zR+Ol0xmLStxEHQFWgqpR2FMg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fTVjr5FsKz17lV for ; Sun, 08 Mar 2026 19:35:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 24cb6 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sun, 08 Mar 2026 19:35:44 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Navdeep Parhar Subject: git: 164bddf01b57 - main - cxgbe: Shrink the size of csum_types List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 164bddf01b5718c6aec73be112b4dada78934c68 Auto-Submitted: auto-generated Date: Sun, 08 Mar 2026 19:35:44 +0000 Message-Id: <69adcf90.24cb6.4cad65dc@gitrepo.freebsd.org> The branch main has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=164bddf01b5718c6aec73be112b4dada78934c68 commit 164bddf01b5718c6aec73be112b4dada78934c68 Author: Navdeep Parhar AuthorDate: 2026-03-08 19:34:32 +0000 Commit: Navdeep Parhar CommitDate: 2026-03-08 19:34:47 +0000 cxgbe: Shrink the size of csum_types The checksum types fit in 4b and don't need a full 32b int. MFC after: 1 week Sponsored by: Chelsio Communications --- sys/dev/cxgbe/t4_sge.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/cxgbe/t4_sge.c b/sys/dev/cxgbe/t4_sge.c index af18b3019760..a9243ff121a6 100644 --- a/sys/dev/cxgbe/t4_sge.c +++ b/sys/dev/cxgbe/t4_sge.c @@ -5469,7 +5469,7 @@ csum_to_ctrl(struct adapter *sc, struct mbuf *m) uint64_t ctrl; int csum_type, l2hlen, l3hlen; int x, y; - static const int csum_types[3][2] = { + static const uint8_t csum_types[3][2] = { {TX_CSUM_TCPIP, TX_CSUM_TCPIP6}, {TX_CSUM_UDPIP, TX_CSUM_UDPIP6}, {TX_CSUM_IP, 0} From nobody Sun Mar 8 21:56:09 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fTYr12t5sz6Trjl for ; Sun, 08 Mar 2026 21:56:17 +0000 (UTC) (envelope-from ahmadkhalifa570@gmail.com) Received: from mail-yw1-x1131.google.com (mail-yw1-x1131.google.com [IPv6:2607:f8b0:4864:20::1131]) (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 4fTYqz3ZDTz3TpF for ; Sun, 08 Mar 2026 21:56:15 +0000 (UTC) (envelope-from ahmadkhalifa570@gmail.com) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20230601 header.b=mkCSyqwF; dmarc=pass (policy=none) header.from=gmail.com; arc=pass ("google.com:s=arc-20240605:i=1"); spf=pass (mx1.freebsd.org: domain of ahmadkhalifa570@gmail.com designates 2607:f8b0:4864:20::1131 as permitted sender) smtp.mailfrom=ahmadkhalifa570@gmail.com Received: by mail-yw1-x1131.google.com with SMTP id 00721157ae682-79860421382so105062697b3.0 for ; Sun, 08 Mar 2026 14:56:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1773006970; cv=none; d=google.com; s=arc-20240605; b=Br30vj/hjotluOzy37dKbmEezhNadBLx2sxL0VBj6eL301/DBV5dIoAOUcw4buQDlt BCiLocopc0rqjYQBB7Ve+MrpERbghYgDA3wkS88MvOlPEz222W1gz5fEzWBCjQYxDkyH gNBWn0CCeFGlTIYvlItghfbLGkmbG6YrRq0X6b1tiP5DtMzi8SvJarAJm25UIUwt5Omg aRsJovsf8mw2uNdxDT3ua6l5RCiO7+VStMK1nUq5XliL8RjJo9lqblnhUblMV2y3D7GS vOQwo7jYn9nOQyG6RShNZbB4KsOOTCyOWmXY3gVsZ6l47dGHw+YTDJQNjF4KuRTx4Klx 2cOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:in-reply-to:references:from :mime-version:dkim-signature; bh=bQlFMYKSggdl/NLIYTnfKwwLjM6FxeW+5BUXNhFIOz4=; fh=oPdnJq8RXC1k6d8mp98Tcmx5K9ukm/8HQRh+qCgq4uc=; b=CRH09sM6zNA5F/s8FK7OiIWSkyljPqmdextBW9A007J9QiRv7g+rXQifWH296WSgvX 5ZW+Jqt4mLnVrxAbBuzEQrZIUueCzDpg66uH0DaEtqTBtDc6jfnsy5qFYgKhkhI5ZFH1 knI4fqAgNJmIasqdqTdRSPsLA6ZWzx8BRn3+wCp0W+RSEgGV9C827bqn0wyoayMp8SS7 MM8szfNp2pfbkJQQcBRTq5q+VB3yKwhW9WX3Tewh88GZ5QTH6SNbeWw7oVyEILljly4l nJ9sifwsTQouu2um1+RLGkwFJQx586dskJZwxIuKh8cH5+6+lyuDHrR3hRoMt860gzEr nEVA==; darn=freebsd.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1773006970; x=1773611770; darn=freebsd.org; h=cc:to:subject:message-id:date:in-reply-to:references:from :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=bQlFMYKSggdl/NLIYTnfKwwLjM6FxeW+5BUXNhFIOz4=; b=mkCSyqwFCFQxgv9zMPLn7UsDiinjda0WCKcJJSfs0i+riAfE5RPJprdq9Pt1lzlB+f ay3cJHI+kOXP3nysG/+z9i3YH6gwTGrNp+ON9fYoJk8SC4cZcGVxFKb9QnGLq85F73wk WuIl2Voz68M8chVIG7qwJvJkKu1FYm7ps+NRoe9UQc9jcDqGgwfDzuWatJsfuC7ImqOI dpMnqR4o28vQQLspGvyM6L8Evb3+u9sTsorB8b96d2j1ijNbdmOZgq4jV0xLn8dy9uEF essCRE+JKwB5pnE5wLDvELwvoPgWXm6FXoXUi2wP2BWSzcHNpCZk3bEeriKBsV84ilHy caqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1773006970; x=1773611770; h=cc:to:subject:message-id:date:in-reply-to:references:from :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=bQlFMYKSggdl/NLIYTnfKwwLjM6FxeW+5BUXNhFIOz4=; b=Wy0ipbnuC59lYEWEDL8lp4hCm5o5Y7YZtAohcwrA7nlqNg2e83Kl+HN0DEqs+5UF4h h5nKPz4WaZd9zBxOAsnaYBs6ILUlVUzVLfpIqg4PFVQaPuKzZSNpUSo2ZK9FFWNPFfZm VT9iTos/LPd0kwS+bMPLf5AzzK4MGhYvq67rKZx9lS5cHKz7XWmzqNVABOqyZaXV+qW2 7WjtQtwYsldTt5J9o+biGdNwRk2WWXoa73mpTlH3MqcRpR5YLYnnbNueY5U3Jgdz562U EZGj0nRHESLT6rORNAOsbXI27i4WHGYaZn8rC8VEUlI0zRwJpzSBqTxiw5mMyDqD5xka f6ew== X-Forwarded-Encrypted: i=1; AJvYcCVJB7NV4mjdVH61Wx8POx5FBGzV136QVsvjZmY9hyHXjk3LagQBY2jOfzEbBTlolSLKfn0dMm3x7RZMUH9HUXRYPdKymw==@freebsd.org X-Gm-Message-State: AOJu0Yy9j4eNbko6qhkEp7aCnhBKOLGFoYpUfbnozWe84u7YZpYQt6gJ NtJy+JWYYdvR0Mfuqa21PKeKr1iHQyeNLZiKEA6yZbaJW2OC+XUJbXK2pTQsMnpNl0OH9P3006C rUuKHkfZMp3hw+yVrhPvNehhL2RmFn2s= X-Gm-Gg: ATEYQzyh66pHWH5db7gKHcDGDiHSaa3YbG/M/PQBzfIdBuz50apUDRWytGbDPM7D7ts 0LAHJi2wjIZPFE43yMJSHb38GNJm9RJwL4t8yfthzPj4zH3ROyONZLlLax5zvShMY94WaBS20lb ccIbS+cShnJDhfkj2UI3BGNpAUJH1aAjVTM2sQLQmaVr2FZjtyXqLI2pKqA3dQJIuolYqg/h3W+ wjvRJ7/8kqdeBBzuE6d2LNkV4eK5Yp81zJFaWoMu+pwOt5mxN/yDWuaT8Ihy+SvOzNWwA8Mb49G fs6q3mL9kg== X-Received: by 2002:a05:690c:c531:b0:798:6c28:dd58 with SMTP id 00721157ae682-798dd6cdc04mr84772257b3.24.1773006969667; Sun, 08 Mar 2026 14:56:09 -0700 (PDT) Received: from 490177373942 named unknown by gmailapi.google.com with HTTPREST; Sun, 8 Mar 2026 14:56:09 -0700 Received: from 490177373942 named unknown by gmailapi.google.com with HTTPREST; Sun, 8 Mar 2026 14:56:09 -0700 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org Mime-Version: 1.0 From: Ahmad Khalifa X-Mailer: aerc 0.21.0 References: <69a88413.1be02.24089406@gitrepo.freebsd.org> In-Reply-To: <69a88413.1be02.24089406@gitrepo.freebsd.org> Date: Sun, 8 Mar 2026 14:56:09 -0700 X-Gm-Features: AaiRm50djMIDvT3evrEdAICSSCH6tGq3jF5Tn156BLQ7t__3I0OjKA6_5_ODPpM Message-ID: Subject: Re: git: 858f53dd43ec - main - Makefile.inc1: Don't force LLVM_BINUTILS off for cross-tools To: Ed Maste Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: text/plain; charset="UTF-8" X-Spamd-Result: default: False [-4.49 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_LONG(-1.00)[-1.000]; ARC_ALLOW(-1.00)[google.com:s=arc-20240605:i=1]; NEURAL_HAM_SHORT(-0.99)[-0.993]; MV_CASE(0.50)[]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20230601]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36:c]; MIME_GOOD(-0.10)[text/plain]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; FREEMAIL_ENVFROM(0.00)[gmail.com]; RCVD_COUNT_THREE(0.00)[3]; FREEMAIL_FROM(0.00)[gmail.com]; TO_DN_SOME(0.00)[]; FROM_HAS_DN(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCPT_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_SOME(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; PREVIOUSLY_DELIVERED(0.00)[dev-commits-src-main@freebsd.org]; MID_RHS_MATCH_FROMTLD(0.00)[]; MLMMJ_DEST(0.00)[dev-commits-src-main@freebsd.org]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::1131:from] X-Rspamd-Queue-Id: 4fTYqz3ZDTz3TpF X-Spamd-Bar: ---- On Wed Mar 4, 2026 at 9:12 PM +0200, Ed Maste wrote: > The branch main has been updated by emaste: > > URL: https://cgit.FreeBSD.org/src/commit/?id=858f53dd43ecb84cf2597229e9dbda2f242d9dd6 > > commit 858f53dd43ecb84cf2597229e9dbda2f242d9dd6 > Author: Ed Maste > AuthorDate: 2026-03-04 15:06:26 +0000 > Commit: Ed Maste > CommitDate: 2026-03-04 19:10:48 +0000 > > Makefile.inc1: Don't force LLVM_BINUTILS off for cross-tools > > Because of this setting we were still using ELF Tool Chain tools for > buildworld. The sets of binary utilities are largely equivalent and > this went unnoticed after commit 1cae7121c667 ("Enable LLVM_BINUTILS > by default"). > > This was discovered recently because ELF Tool Chain objcopy produces > standalone debug files without phdrs and this caused an issue with a > 3rd party ELF parser [1]. Remove the forced setting so that we use > LLVM's binutils to build the system. llvm-objcopy doesn't get built during cross-tools, which results in cross builds not having objcopy. Not sure if just specifying llvm-objcopy under cross-tools would fix it, haven't had the time to check. See https://github.com/freebsd/freebsd-src/actions/runs/22685122750 Thanks. > > [1] https://sourceware.org/bugzilla/show_bug.cgi?id=33876 > > Reviewed by: imp, jhb > Sponsored by: The FreeBSD Foundation > Differential Revision: https://reviews.freebsd.org/D55650 > --- > Makefile.inc1 | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/Makefile.inc1 b/Makefile.inc1 > index c4696abae8cd..8a1958902db5 100644 > --- a/Makefile.inc1 > +++ b/Makefile.inc1 > @@ -808,7 +808,6 @@ XMAKE= ${BMAKE} \ > TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \ > MK_CLANG=${MK_CLANG_BOOTSTRAP} \ > MK_LLDB=no \ > - MK_LLVM_BINUTILS=no \ > MK_TESTS=no > > # kernel-tools stage From nobody Sun Mar 8 22:11:26 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fTZ9V278Fz6Tt9S for ; Sun, 08 Mar 2026 22:11: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" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fTZ9V1fSVz3VvJ for ; Sun, 08 Mar 2026 22:11:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1773007886; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=njgMHzPP+ZNuYh3haiSohBGuABfk/XIhFQMoaSSF+9o=; b=tZ2nRwTzcGX1D7MNe8orUWRFRlmRmaFP+7D5gwXxxM5GGZB/kRo2waWdgOPFYQQ3w37Kpz 2sve/6o9BjmiXz4ZeYGaOw4CQerOfcHM82aUPw8EUyQfCqkR5MH6wzaZn1MvZu24PCl6SO dcSf3oT+h8/sGMxCpOqiIbDp8DwdYX6zYngB0G7uZ9uBOfNb+cxdBjn3RttTbfhLQXbMHQ 0BCnZ72b1k3Is5eWoy0JKL9wapYegjTn5VDtozc978pB9GNmeo14d72PtoDDVXAzT2/HZV XmyM86UWrUSN1PaK7lgufrRzfBAjFvKF3jL0ACUtZhsHGOcuMUqfUIR2WDVoNg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1773007886; a=rsa-sha256; cv=none; b=rh3KZRVQSezMSUER8ZK3WCtl1M03aM1FMv54XSaxaCnVQSOj6CfFqOxaamoAzvC4VLlHHZ uXoZBoLSVS7WiJFVofKaqCADoO2JOdi9+lMLsmnl7J97v30kk0ydhED/VOoOVO/r1mPB67 bgJ+RZ1q/m2b91DEOMZN9lqAViOqOKk6ZsuayyDp2TureSmFzCz6gHgIqMhAZFMNoRMhfC LBXPBcXrs7UzFWmSm4S7E/0MiERTFl8KPdCK5OR+cmYXvxWlnZ8zKnnKynZZ1SSlOrXN81 9MFkCdoLJz47P4y6IcPIXdskchQf5lxRw1CCYUCYZ1Cncu6fuTYTUPsCwVVNLg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1773007886; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=njgMHzPP+ZNuYh3haiSohBGuABfk/XIhFQMoaSSF+9o=; b=w4P0/OY1Sh+3QcOyHMRVHbubceJlig0HQq+U54MIek7G9ir8s4gYJzfCEDDFtTvycahr0l U86eTkoryPwvOaEpLKGQIs2BtsYwczkKlK8sEWodsv7TR2p5UeZbQn46QoVP2V1N66RBPe wktwgXrFuUHJh453eBv4xYEbNIT+hHQ/jhZSgKh+JRFGzWH/e15N4QKDXxmrVqB1Qh5ulB dMKDdaExu2oGWVPmKAfbXCTO06EhpcdHMUJty4hbhIozhiSOEJrWDuDaq5TExyTtMu7UpN xhnLQHWtVnPIzHi1IMI17R7/RzEWmqRtFUbLwblBarSx7mF+kF9PXju73pzrYw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fTZ9V0fWCz1CVN for ; Sun, 08 Mar 2026 22:11:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3ebf6 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sun, 08 Mar 2026 22:11:26 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Rick Macklem Subject: git: 016570c4463d - main - nfs_clstate.c: Handle the same stateid case correctly List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rmacklem X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 016570c4463d5908953355ee1cf9a385ad9601b4 Auto-Submitted: auto-generated Date: Sun, 08 Mar 2026 22:11:26 +0000 Message-Id: <69adf40e.3ebf6.2b8653f0@gitrepo.freebsd.org> The branch main has been updated by rmacklem: URL: https://cgit.FreeBSD.org/src/commit/?id=016570c4463d5908953355ee1cf9a385ad9601b4 commit 016570c4463d5908953355ee1cf9a385ad9601b4 Author: Rick Macklem AuthorDate: 2026-03-08 21:09:36 +0000 Commit: Rick Macklem CommitDate: 2026-03-08 21:09:36 +0000 nfs_clstate.c: Handle the same stateid case correctly When an NFSv4.1/4.2 sarver upgrades a read delegation to a write delegation, it does not need to change the delegation's stateid. Without this patch, a DELEGRETURN of the stateid was done for the case where the delegation stateid had not changed. This return was bogus, since the delegation stateid now represents the new write delegation. This patch fixes the priblem by checking for "same stateid" and only doing the DELEGRETURN when it is not the same. PR: 289711 Tested by: Peter Much MFC after: 2 weeks --- sys/fs/nfsclient/nfs_clstate.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/sys/fs/nfsclient/nfs_clstate.c b/sys/fs/nfsclient/nfs_clstate.c index 712d49c7160c..6dc97142b77f 100644 --- a/sys/fs/nfsclient/nfs_clstate.c +++ b/sys/fs/nfsclient/nfs_clstate.c @@ -433,9 +433,11 @@ nfscl_deleg(mount_t mp, struct nfsclclient *clp, u_int8_t *nfhp, { struct nfscldeleg *tdp; struct nfsmount *nmp; + bool trydelegret; KASSERT(mp != NULL, ("nfscl_deleg: mp NULL")); nmp = VFSTONFS(mp); + trydelegret = false; /* * Since a delegation might be added to the mount, @@ -467,6 +469,9 @@ nfscl_deleg(mount_t mp, struct nfsclclient *clp, u_int8_t *nfhp, * Read delegation. Otherwise, return the new delegation. */ if (dp != NULL) { + if (NFSBCMP(dp->nfsdl_stateid.other, + tdp->nfsdl_stateid.other, NFSX_STATEIDOTHER)) + trydelegret = true; if ((dp->nfsdl_flags & NFSCLDL_WRITE) != 0 && (tdp->nfsdl_flags & NFSCLDL_READ) != 0) { TAILQ_REMOVE(&clp->nfsc_deleg, tdp, nfsdl_list); @@ -485,7 +490,8 @@ nfscl_deleg(mount_t mp, struct nfsclclient *clp, u_int8_t *nfhp, } NFSUNLOCKCLSTATE(); if (tdp != NULL) { - nfscl_trydelegreturn(tdp, cred, nmp, p); + if (trydelegret) + nfscl_trydelegreturn(tdp, cred, nmp, p); free(tdp, M_NFSCLDELEG); } return (0);