From nobody Wed Dec 21 18:49:43 2022 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 4NcjD84fK4z1Gl9c; Wed, 21 Dec 2022 18:49: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4NcjD81VSrz46DV; Wed, 21 Dec 2022 18:49:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1671648584; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cWripmEJaSYcM5qbGtnX5Iz5OBZk1XU48QkqBqpKlaE=; b=F7UDT8fR3mPBL3UTOCNxazcH5MH5BDpqZx0Cg5zdBXLwVwzfsC+biINJEpDQ/rCCEOJq2s NkglcyM5y1PfGv534aTdH+Xo845O9GrVnH5FAA57+eHW9AUkF3ftl7lAmKkujHej9yDZwK jI4gkk/9C0oWthbl1RUq2iSJ4ScwnrP1L/82GS9k01gJYl8889FyZJg7eGFru9MlOvfJNX Q9Hc6t8lKLVsNGQgDwnPygrjVyq4Y4vw3gehNK1xhRdpc+I4xfkT0UT9diejvfFxyLSbDm qAlwo0JqTfp65mKuM4Diz30xX5GErFSrEUKZ28kjvkEjISx3Qlw3Qbepxy8wsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1671648584; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cWripmEJaSYcM5qbGtnX5Iz5OBZk1XU48QkqBqpKlaE=; b=Rdv5rb5bIxo6JyfWSFnU7avPAGDPQaoiTwxq11ir7Kx1w1gs7WKBQe6ruZaWwYWr2dcQE6 gZ5+amCU8v/5bEo6lWDIvIUJ2aMWGGwwtYm2IjJG4MOBWk06okGRxCka/SIX0265j2I1hs 8QPxkYk2MOR18Az+n4DB2Stl2BCt2/69jWBypZ7st0USo8+KZgB8/Zj7d71VXVf8uX9UzW TabjVa3eYrb4n7yByspyEl0mGKPnbxC+VkyOMj3Vd8qQz82H/HscPNBxlEUak7w6b88jtp oMY6MHJvTfbK8jt2ZNTpNtyCPoj49uVFy99b6+g7FoAsuYsif02ue+XiM2lZMg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1671648584; a=rsa-sha256; cv=none; b=wcFLmpNEBAl+8Id7h/RqTou7fz6auKbRgHXncTJ4RB04glqtulml8VFiqPeuBLFRvXfkUr QfGdc3dA4ek83uuWXCiykKfSAo8SfuZvtohm191gTHLIxT2RM3lKSkj6tELBFxJ/PxT5lv Ipo6AVIC89px9xYE2g99uD2Kg+twx0C5CkJeqtTU6rBjJF1RRYTug+ojlq171Hgc5yiaf+ PqJWT1TcyPQrhzbQJsvwP2aWDRsFV9+nImifv/LO8rWWF/FBF6RErPZVU7Yuq8d5uDTPJ4 c64ek3I46zacLEcyttjUGjlXTNud7QHwWWjGSPWK07QmQN8FQamu8EdmDG90Tg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4NcjD80YLRzQP2; Wed, 21 Dec 2022 18:49:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 2BLInhwe084619; Wed, 21 Dec 2022 18:49:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2BLInhWD084618; Wed, 21 Dec 2022 18:49:43 GMT (envelope-from git) Date: Wed, 21 Dec 2022 18:49:43 GMT Message-Id: <202212211849.2BLInhWD084618@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 1aa6d44decb3 - main - Disable -Wzero-length-bounds for the kernel for GCC 12. 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: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: 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: 1aa6d44decb33ce3eab0efe5336b75fa2dfa3733 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=1aa6d44decb33ce3eab0efe5336b75fa2dfa3733 commit 1aa6d44decb33ce3eab0efe5336b75fa2dfa3733 Author: John Baldwin AuthorDate: 2022-12-21 18:47:08 +0000 Commit: John Baldwin CommitDate: 2022-12-21 18:48:15 +0000 Disable -Wzero-length-bounds for the kernel for GCC 12. The mlx5 driver and some other OFED bits use a somewhat dubious pattern of: struct foo { uint64_t arg[0]; /* Real members of a struct */ }; The code then treats 'arg' as if it were really a kind of union such that foo.arg[N] functions similarly to (uint64_t *)foo[N]. This uses of foo.arg[N] then trigger this warning. No real bugs were found by this warning though, so just turn it off globally. Reviewed by: hselasky, kib Differential Revision: https://reviews.freebsd.org/D37630 --- sys/conf/kern.mk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/conf/kern.mk b/sys/conf/kern.mk index 5231a289981e..65cf86375cce 100644 --- a/sys/conf/kern.mk +++ b/sys/conf/kern.mk @@ -79,7 +79,8 @@ CWARNEXTRA+= -Wno-address-of-packed-member \ -Wno-error=alloca-larger-than= .if ${COMPILER_VERSION} >= 120100 CWARNEXTRA+= -Wno-error=nonnull \ - -Wno-dangling-pointer + -Wno-dangling-pointer \ + -Wno-zero-length-bounds .endif .endif