From nobody Wed May 03 00:29:55 2023 X-Original-To: dev-commits-src-branches@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Q9yWl69pDz48Nf2; Wed, 3 May 2023 00:29: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Q9yWl5ZvHz3nJq; Wed, 3 May 2023 00:29:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1683073795; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WFXBG049ncBSfLwgHkmMwWyjC5sOQnhZPtZHh08UBrE=; b=btGv3RIyxhhh1OlmsUa5wxAbUiVPohKmIpXFgxkeJCnQFRgxRtppY1lIayIDtZClaKTl+4 kkhHg0lJHRw3DVtvR2kedYULVm+Cqn3eoPGpbDEzsmFg/p3A/oTz/6sCKbXZ174thLdThp qk/Go7/2tsr4TH4U6zfZqPdkvD3xBCnTqST0cESgS8Vl5iEmc0FaIb7RXNiOQmtk0S5FLW 0dSe+szKw6o0wh28ddpscpcPxjoNzjm2ilG5otdXPIFdU5N9ea6UC2ZNMljyElDA97iLNq BZWVV/sHhWERc2F8AZ9famgj8bxuGbt0D3uHOicdyOg3lfnteJbNVGdFOQVcBg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1683073795; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WFXBG049ncBSfLwgHkmMwWyjC5sOQnhZPtZHh08UBrE=; b=egyTTWEfLDvSBd8dS5ZRIw7nIxEIRqARPvObiDIYfF8QDZNtHEVHIJ8Dqng/+5sJvtrXY3 yCgv2/+rMBv7+I4C4CORY9EHdsLoa8VodBWUchd6iNslFUdXDi9EoeW0wV7eAqTLuUd4FN LZT8osbu3pybMysz9gcAL86bCCCVsGE8iCDSkRmY3UrM6mbBKgBYhpJ3qljEoAsC8UT0cA bvKP9H65L1owR1O5XefqySitFqNgHd03NGXjhp6KMByw5N1ijIFPxoEwxwf93LmW37UT6u Hi89j03+vyY5+ehSIotdsyy0dj5fhQZ9LI3Vhw9XvURUEYyi9NZdfHSHIaGwXw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1683073795; a=rsa-sha256; cv=none; b=IktfXdTAgn11b5zKfL5y7cuqiqw0OSxEnB5nhhkcaU24MMFDeGOWY15e+TrhngZxmWA8EQ c4insNsQ4swBbRDPqqoDg7EK4yOMnVf2sLYIet/O5irW0txJK8YJKcjnjGh957BOOzn7/i fXMq+AI0rQa8/tUkR3p2uuKTtrQqV54E12xChXOmfW4QUOpyaTX4Zd2XHero7whpn73cj+ aj48+8etK/ncPXXmMHy678GKNnYHc8tjq021xDGpF3Pdxd0uYYHFTp/3EAVdo4pIze6/VL uaxbbixXIGmV+Z6XIZnv30rlo7fiY+U5KHw5vVXpRr+nOEHXYNMASlyY3mR+xQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Q9yWl4Q0Lz18Ww; Wed, 3 May 2023 00:29:55 +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 3430TtNI072310; Wed, 3 May 2023 00:29:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 3430TtqZ072309; Wed, 3 May 2023 00:29:55 GMT (envelope-from git) Date: Wed, 3 May 2023 00:29:55 GMT Message-Id: <202305030029.3430TtqZ072309@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: a5cc1f650ca3 - stable/13 - sys: Stop enabling -Wnested-externs. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: a5cc1f650ca30144badf10fbd5c37f0fe7d7c36b Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=a5cc1f650ca30144badf10fbd5c37f0fe7d7c36b commit a5cc1f650ca30144badf10fbd5c37f0fe7d7c36b Author: John Baldwin AuthorDate: 2023-03-22 19:35:09 +0000 Commit: John Baldwin CommitDate: 2023-05-03 00:19:51 +0000 sys: Stop enabling -Wnested-externs. clang doesn't implement this warning, so violations are only caught by GCC. It is also no longer a common practice to use this as it was in the original BSD code, so the need for the warning is not as important as when it was used to do cleanups 20 years ago. A recent commit (c3179891f897d840f578a5139839fcacb587c96d) triggers this warning on GCC, but that commit uses nested externs purposefully. Reviewed by: markj, emaste Differential Revision: https://reviews.freebsd.org/D39214 (cherry picked from commit 4ffeb3b88ed228e72e13abe1be888c77c6ede95d) --- sys/conf/kern.mk | 2 +- sys/conf/kern.pre.mk | 1 - sys/conf/kmod.mk | 3 +-- sys/modules/pms/Makefile | 1 - 4 files changed, 2 insertions(+), 5 deletions(-) diff --git a/sys/conf/kern.mk b/sys/conf/kern.mk index 281c49c7c850..d37d80793929 100644 --- a/sys/conf/kern.mk +++ b/sys/conf/kern.mk @@ -3,7 +3,7 @@ # # Warning flags for compiling the kernel and components of the kernel: # -CWARNFLAGS?= -Wall -Wnested-externs -Wstrict-prototypes \ +CWARNFLAGS?= -Wall -Wstrict-prototypes \ -Wmissing-prototypes -Wpointer-arith -Wcast-qual \ -Wundef -Wno-pointer-sign ${FORMAT_EXTENSIONS} \ -Wmissing-include-dirs -fdiagnostics-show-option \ diff --git a/sys/conf/kern.pre.mk b/sys/conf/kern.pre.mk index a12aff2c2816..3105d2c32c8f 100644 --- a/sys/conf/kern.pre.mk +++ b/sys/conf/kern.pre.mk @@ -246,7 +246,6 @@ CDDL_CFLAGS= \ -Wno-duplicate-decl-specifier \ -Wno-missing-braces \ -Wno-missing-prototypes \ - -Wno-nested-externs \ -Wno-parentheses \ -Wno-pointer-arith \ -Wno-strict-prototypes \ diff --git a/sys/conf/kmod.mk b/sys/conf/kmod.mk index 134b150af1d9..a952e3190dec 100644 --- a/sys/conf/kmod.mk +++ b/sys/conf/kmod.mk @@ -550,8 +550,7 @@ OPENZFS_CFLAGS= \ -I${SYSDIR}/cddl/compat/opensolaris \ -I${SYSDIR}/cddl/contrib/opensolaris/uts/common \ -include ${ZINCDIR}/os/freebsd/spl/sys/ccompile.h -OPENZFS_CWARNFLAGS= \ - -Wno-nested-externs +OPENZFS_CWARNFLAGS= .include .include diff --git a/sys/modules/pms/Makefile b/sys/modules/pms/Makefile index 4dc00b75ff6f..3219b3e0e4a3 100644 --- a/sys/modules/pms/Makefile +++ b/sys/modules/pms/Makefile @@ -22,7 +22,6 @@ CFLAGS+=-fms-extensions CFLAGS+=-Wredundant-decls CFLAGS+=-Wunused-variable -CFLAGS+=-Wnested-externs CFLAGS+=-Woverflow CFLAGS+=-Wmissing-prototypes CFLAGS+=-Wparentheses