From nobody Mon Sep 15 21:44:08 2025 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 4cQdpb234xz685rV for ; Mon, 15 Sep 2025 21:44:23 +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 4cQdpb08sTz3P84 for ; Mon, 15 Sep 2025 21:44:23 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pj1-x1029.google.com with SMTP id 98e67ed59e1d1-32dc6616f7dso3581379a91.1 for ; Mon, 15 Sep 2025 14:44:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1757972661; x=1758577461; darn=freebsd.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=ruKDfFtNRskvG2+OP7WSMtGiYD21uyK/2+J3o5Su2pg=; b=Gf1cJlEci+c1qbqw0zEn4YkWX8QwzUutDovBUWq8WTA6UYCDHlSJqtfYBvg9bahlYv Iexr8kgxM0u5N8mg3cjQ4Ckee3TM2VrrC4zIXAiI5s0NCY2RNFRdWHnWICTte2W5s6Ff zvanAF09Nk4PYYmdHkiU/nLC42RXoyje0Ps8xBOdUNOxN06MQYOR6sPHi9kvxhmdSHoi vtbmrgx7tK7Yn0Xw4SbZbUntcqE9TYpqBerCACILyY9zAVePC5oeAWnknCYuoHLyk38N lbDF83/F6GTSVJRmkvZTI03S6Gn+Eyz+fzWuDxNA/01RZkzbmW8bEeWH6LK2X6DUoA4j nReA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1757972661; x=1758577461; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ruKDfFtNRskvG2+OP7WSMtGiYD21uyK/2+J3o5Su2pg=; b=sS8OYXDl0xzcgh79QW4FqIX3XDukFCb0OKoEYhr1Ubt3f5ZVB+nVJrDFsACHI0sdT7 oCRZdxScdjUQ1DmapuFZVeTndtqIPU7/VQA1Cxej10Lk+be+9Rk3L8NjN820MAqsF2Gm pAVF0qOywoPSNCXG9oKh8xjXIy/huSN21TC+H6dUUEOdmPujHbxe2q5hGq0xn2OcF7dP IiFX8V7lUOUYvsh02JFdzoNnvifKBDuQBL55SsnAa9l+5euHxXU/9aU/HaaxVG51E/77 a7atM4OmqtacQVSHzyW7xbjng8QjsfGov1GuY8nMgXw9S0JSUB4ogcgMIkDXP0Jeteyj SfVQ== X-Forwarded-Encrypted: i=1; AJvYcCUEmB+Rbp3d7o0cyyXMt/hIAJSyOEXKvHNAG+szeKDVBQdLh0anWOWw7YlEO1g3x1wNYo2fYwNXKol3UpkNcAk8oPKCBw==@freebsd.org X-Gm-Message-State: AOJu0YxozUnCbOUaChYYtZrySfOtUD6zdHC9QI9gGVVYfkNPRjaMYyVF ZCInOXSvSxA7E5kPtVki6OowHj3AfYCVseiS+/mpdUN5aFgyls8RmkJn0GT8yLbtB0hd3JrmxkZ iTASSAhVcljQRdKGy5hujlBDviME/LrXNtzlhyLm9gxvaMLixo38HLf4= X-Gm-Gg: ASbGncshNlWyb74Zoj2MqaogknmsCriGTyVdtWUMyZ8P+/Q61arVTfU81KIvdyjm7fq q5hNLi0bV+2M/ppnUyN/dpbfyyMxAguGKIrFYr/eWTft2cBcPZ1HRsawz1Z3K1yC88IIdGc9oaq 00g8o7Q9atowYWjAeorasS5pyLhoeuu2iD17Ht5O0nJh3Xk91eWktt1SWHPows/20ewm+pBsNEt 8+5IQjIIHvtBvC9bcEsmTb2uQfzJ/Zs8mCCG7z5BUcFF9TNag== X-Google-Smtp-Source: AGHT+IEC1Pl7WKurBGNvpSwBPTJv0jjb1b5CLlBwKtcoZuzdLESPS+XqGaWS7NXUAIQ4BY3MaJtoJ3NdYCkKwhBUthk= X-Received: by 2002:a17:90b:4cc9:b0:32e:59ef:f403 with SMTP id 98e67ed59e1d1-32e59f01354mr7409891a91.17.1757972660668; Mon, 15 Sep 2025 14:44:20 -0700 (PDT) List-Id: Commit messages for 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: <202509150304.58F34BWJ035102@gitrepo.freebsd.org> In-Reply-To: From: Warner Losh Date: Mon, 15 Sep 2025 15:44:08 -0600 X-Gm-Features: Ac12FXybeel4qYdHNfURW_7Wcqwos95JmqPCiZq0fQ_MurWuHmAUoy7iMF3ekkA Message-ID: Subject: Re: git: 5e0a4859f28a - main - iwlwifi: Don't compile for gcc before 14 To: "Bjoern A. Zeeb" Cc: Warner Losh , =?UTF-8?B?SmVhbi1Tw6liYXN0aWVuIFDDqWRyb24=?= , src-committers , "" , "" Content-Type: multipart/alternative; boundary="000000000000f6dd5e063edde708" X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4cQdpb08sTz3P84 --000000000000f6dd5e063edde708 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, Sep 15, 2025 at 3:32=E2=80=AFPM Bjoern A. Zeeb wro= te: > On Mon, 15 Sep 2025, Warner Losh wrote: > > > On Mon, Sep 15, 2025, 1:26=E2=80=AFPM Bjoern A. Zeeb w= rote: > > > >> On Mon, 15 Sep 2025, Warner Losh wrote: > >> > >>> The branch main has been updated by imp: > >>> > >>> URL: > >> > https://cgit.FreeBSD.org/src/commit/?id=3D5e0a4859f28ad4869f7a73faf42debc= 355a370bf > >>> > >>> commit 5e0a4859f28ad4869f7a73faf42debc355a370bf > >>> Author: Warner Losh > >>> AuthorDate: 2025-09-14 18:03:16 +0000 > >>> Commit: Warner Losh > >>> CommitDate: 2025-09-15 03:03:45 +0000 > >>> > >>> iwlwifi: Don't compile for gcc before 14 > >>> > >>> gcc 13 and earlier don't have __builtin_bitcountg. The linux wifi > kpi > >>> uses this unconditionally. While in this one use, it might not be > >>> needed, I opted to not compile iwlwifi when building gcc12 or 13 > >> rather > >>> than risk breaking it for everbody else. > >>> > >>> With this change gcc12 builds the kernel. Maybe this will stop > jenkins > >>> email for every commit I make. > >>> > >>> Sponsored by: Netflix > >>> --- > >>> sys/modules/Makefile | 3 +++ > >>> 1 file changed, 3 insertions(+) > >>> > >>> diff --git a/sys/modules/Makefile b/sys/modules/Makefile > >>> index 5315d518afd8..f9fdbca78869 100644 > >>> --- a/sys/modules/Makefile > >>> +++ b/sys/modules/Makefile > >>> @@ -576,7 +576,10 @@ _mlx5ib=3D mlx5ib > >>> ${MACHINE_CPUARCH} =3D=3D "i386" > >>> _ena=3D ena > >>> _gve=3D gve > >>> +# gcc13 and earlier lack __builtin_bitcountg used by linux emulation > >> > >> (a) I beleive there is no __builtin_bitcountg but you mean > >> __builtin_popcountg > >> both here and in the commit message. > >> > > > > Yes. > > > > (b) That was introduced in 7cbc4d875971860d941cc15d7f42e6cfeffbfe66 for > DRM > >> > >> (c) There is no direct use in any LinuxKPI based wireless driver: > >> % grep -r __builtin_popcountg sys/contrib/dev > >> % > >> > >> (4) iwlwifi only uses HWEIGHT32, which was changed by the aforemention= ed > >> commit > >> in LinuxKPI. > >> > > > > Yes. I noticed all that. Didn't see a trivial way to fix it right. > > > > (5) Please do it right and in the place where it is actually defined to > be > >> used, > >> in LinuxKPI, and not here as it can be easily fixed there with an > >> #ifdef or > >> otherwise as there were alternatives on the review if I remember > >> correctly. > >> > > > > Knock yourselves out. I was tired of the CI jobs whining and this was t= he > > easiest way to make that stop. I've got too many things on my plate to > > refine this more. If you want to support older gcc for this driver, > that's > > up to you. The ci jobs have been failing for weeks if not longer > > Okay, will do. > > But gcc12/13 had been whining for months on a lot of things constantly. > I really don't know how a day to do it right would have made a difference= . > I thought this was right since I didn't see a good way to backport the macros to gcc12/13, but your point is well taken. But at the same time, I had a few minutes and this was the last thing in the way. Had there been a bunch more, I'd likely have gotten reviews for everything. Warner --000000000000f6dd5e063edde708 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


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

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

Okay, will do.

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


--000000000000f6dd5e063edde708--