From nobody Fri Jul 29 18:48:42 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Lvc3v3qmnz4Y26H; Fri, 29 Jul 2022 18:48: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Lvc3t4f0Xz3tXN; Fri, 29 Jul 2022 18:48:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1659120522; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=80WXOSgPxR74mDLBJtxMe0UbfqFG/4CwmvBuf6j+1XM=; b=kwf/bEo8+DfRR58jqejNXi96b9f3xMkhG16WjQN1DaSD4hqTQosfd2OvS3pE2Ki4if6pN0 AHCTtFnL1+A1J5ed1Dn8i1YI6Dp4TI50heNOHCdsIEqlxYFL3FZXn3r8IdFo5jDDHv6IrS dywSXQObt4JcMzsGhtXYDA2rb7mRtEwGXrg0OwCUSl6cR8QkWVp9cUalh9PmSdMqXCxhcY iO/U84/soRPVjCWSKG1ozTFfh9LaX/PK284N8suCVbmVSoHLaJMnElQS7/2H44Zr9FkkNh ZLeaIwN6blPkT9xDkVi0TSpdpCDHRg+Wxf8VfKo32ju6MTkyryraLKM1On2ZRw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Lvc3t3bv2zmB9; Fri, 29 Jul 2022 18:48:42 +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 26TImgCd025730; Fri, 29 Jul 2022 18:48:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 26TImgiX025729; Fri, 29 Jul 2022 18:48:42 GMT (envelope-from git) Date: Fri, 29 Jul 2022 18:48:42 GMT Message-Id: <202207291848.26TImgiX025729@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dimitry Andric Subject: git: b59fd9264f9e - stable/12 - Adjust function definitions in kern_cons.c to avoid clang 15 warnings List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dim X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: b59fd9264f9eb11a99b0fa4ce73fc5d75df48d37 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1659120522; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=80WXOSgPxR74mDLBJtxMe0UbfqFG/4CwmvBuf6j+1XM=; b=eezLqX7Is4pEz0VH7XtxMEN4GqwM7L/lqPmdyTrV1FL1Z65DCxpxXYm7HC7oTSuKAe4zba tFzvEadfn/aXX/2HMM4wCSh157+wdSPNzu6dRHOJ+c7hUCPCBh+c8ECWDex/LAI3QuGJbh vYZITY3biMvUfY/h5rvdygBByUO23obeatkdrvgL6zcSENaHwP1y7ERqAND3YwpdEmMjVA lOLWKQYF+dJKK4zZgDrXHhxi+GjEm9v0q6f9npq6dpXpUrNls16cJDc5HaZdH9hNxMSIEb x9ggX/0eqPCcQMIni6ke74ztYW5mbXXQFbeVl3gDqOELy+oDLXhlcUZVETk8mQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1659120522; a=rsa-sha256; cv=none; b=Xs1P4D8g6XMj6F1C+QSMRAdWAYhnskK9mgZXtZ8mdGoz+np1hZSCRaltj2OH3Fs4QpmTRZ 3RT85r7c6w4JGYeEZ7EjX+nni0cBTm1COpEP8Q/Y32/A815sQaH7eydskZJN488ME5BI2Q nLprKE2Y20w3COpUvr9AEX90Wr8WqXOLlT7UQpLFamwyv+7fLlLc2YSQ6KOeCYAvny0he1 2dPZv9zQsNnlPXwXhbbFbzPI5OmQ3D4hizBN2+xIYboF+6pHb+zZq9oLGoJcsQIFcmAzZm oivKOos1rOiIEYA43TmcbGVRnnOyfVdv7HRC57cRwi4g7rne4EPuhLUmMF8fQw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/12 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=b59fd9264f9eb11a99b0fa4ce73fc5d75df48d37 commit b59fd9264f9eb11a99b0fa4ce73fc5d75df48d37 Author: Dimitry Andric AuthorDate: 2022-07-26 14:03:35 +0000 Commit: Dimitry Andric CommitDate: 2022-07-29 18:44:21 +0000 Adjust function definitions in kern_cons.c to avoid clang 15 warnings With clang 15, the following -Werror warnings are produced: sys/kern/kern_cons.c:201:14: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] cninit_finish() ^ void sys/kern/kern_cons.c:376:7: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] cngrab() ^ void sys/kern/kern_cons.c:389:9: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] cnungrab() ^ void sys/kern/kern_cons.c:402:9: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] cnresume() ^ void This is because cninit_finish(), cngrab(), cnungrab(), and cnresume() are declared with (void) argument lists, but defined with empty argument lists. Make the definitions match the declarations. MFC after: 3 days (cherry picked from commit 9806e82a23924f32dc5976bc8687fbbe293a140b) --- sys/kern/kern_cons.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/kern/kern_cons.c b/sys/kern/kern_cons.c index e937ea7f21ca..19ee88f42cac 100644 --- a/sys/kern/kern_cons.c +++ b/sys/kern/kern_cons.c @@ -172,7 +172,7 @@ cninit(void) } void -cninit_finish() +cninit_finish(void) { console_pausing = 0; } @@ -344,7 +344,7 @@ SYSCTL_PROC(_kern, OID_AUTO, console, CTLTYPE_STRING|CTLFLAG_RW, 0, 0, sysctl_kern_console, "A", "Console device control"); void -cngrab() +cngrab(void) { struct cn_device *cnd; struct consdev *cn; @@ -357,7 +357,7 @@ cngrab() } void -cnungrab() +cnungrab(void) { struct cn_device *cnd; struct consdev *cn; @@ -370,7 +370,7 @@ cnungrab() } void -cnresume() +cnresume(void) { struct cn_device *cnd; struct consdev *cn;