From nobody Tue Jul 26 18:00:29 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 4Lsl7f0tslz4Wh7S; Tue, 26 Jul 2022 18:00: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Lsl7f0BGkz3jwk; Tue, 26 Jul 2022 18:00:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1658858430; 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=IFp5QouWR4BieGEXds8FIgvkFiPXnB+y7YV6XzVsUJw=; b=HQpQ5utqd5kJUtafAFxb3SY+9Jm/O1d6BtLJyGVKAeU5NHvL1EsxAwoTn+U2tvzog1DWjg lr+6pAxWTgV3aJwxSgPlHkB2P3yIStAds+mN5tLrmqEuWxjZdeQ2Wg+ckcMaLy8UsK0JhJ 4NyNk0XLJFEcPA1aPelZDbE3vF2mroe+C0l9MVZVesPv3Gv5T2RwAmCnJPdPSqcGWkno15 FOhspcoleWPTu6iB28NpR2tVcX+higDZNvYzaPhJS0TQ5s3KBCXF8sTFktc+XVobkVu2M+ M3XM0BNKTAoBq6d47oOIs0VtxyZz8jiY+jy5tdqmxDmGthd2B3e0NOjOUNjvzQ== 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 4Lsl7d5hhdzmJM; Tue, 26 Jul 2022 18:00:29 +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 26QI0TRt005798; Tue, 26 Jul 2022 18:00:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 26QI0Tgb005797; Tue, 26 Jul 2022 18:00:29 GMT (envelope-from git) Date: Tue, 26 Jul 2022 18:00:29 GMT Message-Id: <202207261800.26QI0Tgb005797@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dimitry Andric Subject: git: a6c803048fd8 - main - Adjust function definitions in xen's control.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/main X-Git-Reftype: branch X-Git-Commit: a6c803048fd8d4209fb1d52cd3c455a6752109b7 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1658858430; 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=IFp5QouWR4BieGEXds8FIgvkFiPXnB+y7YV6XzVsUJw=; b=HtziX/iRStU5KXUqxSl0mMtcIduPUun/tSlkaqmf5QLyeOOTSIXoy2nRRfPwCdX2wWrupz qIbp/CP5oKB5UZ6RThnaZKc1y0gX86whuMIa+h/0px+5UJ/56fXfDqf1b8x4lDLlFzZ9BC xAv9ze+VY8flDkf3aDkzGK93XWcoL9MXOFTubQ6WV/yJ6H9N+dbxgnnYTmcszXtZ02jb/J i3/Bj7VyD9mAjUT9N1ueuuDpaGNnaY8lUaleOUyGC5ycMjf5BT796WcTJMvpj1aSwaNwyj pNseS7aybOLvuRyHcgFo9/M5IURYN4FXZo6taeIkWTB6flV2T86LUZPU/G03ww== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1658858430; a=rsa-sha256; cv=none; b=Txqh0KaU/LkntY96pPspnTGk5116uGTViPthh5ZHodBwKSWalIQBxI9b+x2Z+SFdrPECOP VQKvvAkLPPng2MfNmGMa4p0K90Ehrl2UHrdTNuRUnETCLMVRCJeSr1DupuX6q79RGWEiMu M8UoFlAGy6HWEqHaE04Xp2p0aXCbtdGESJglTZXrBoWc8IxeaVsFZ5SlD1GvpW3K5A/ta0 Z3FMHEGw94QYZRhsJSWdx4c1IshdnyCqvts8VFe5qtvmjCTpvAvrx6xNsShNNIii34C+8M Gtj0BlN7UhDiMOrYBgM5FqRZ6yXUFUxQSuxIS8mBh6YVdXYdPnjm+bSduj+IDQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=a6c803048fd8d4209fb1d52cd3c455a6752109b7 commit a6c803048fd8d4209fb1d52cd3c455a6752109b7 Author: Dimitry Andric AuthorDate: 2022-07-26 12:11:09 +0000 Commit: Dimitry Andric CommitDate: 2022-07-26 17:59:55 +0000 Adjust function definitions in xen's control.c to avoid clang 15 warnings With clang 15, the following -Werror warnings are produced: sys/dev/xen/control/control.c:188:15: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] xctrl_poweroff() ^ void sys/dev/xen/control/control.c:194:13: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] xctrl_reboot() ^ void sys/dev/xen/control/control.c:207:14: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] xctrl_suspend() ^ void sys/dev/xen/control/control.c:344:12: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] xctrl_crash() ^ void This is because xctrl_poweroff(), xctrl_reboot(), xctrl_suspend(), and xctrl_crash() are declared with (void) argument lists, but defined with empty argument lists. Make the definitions match the declarations. MFC after: 3 days --- sys/dev/xen/control/control.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sys/dev/xen/control/control.c b/sys/dev/xen/control/control.c index 2a539c724046..c3408b6fb58a 100644 --- a/sys/dev/xen/control/control.c +++ b/sys/dev/xen/control/control.c @@ -185,26 +185,26 @@ struct xctrl_softc { /*------------------------------ Event Handlers ------------------------------*/ static void -xctrl_poweroff() +xctrl_poweroff(void) { shutdown_nice(RB_POWEROFF|RB_HALT); } static void -xctrl_reboot() +xctrl_reboot(void) { shutdown_nice(0); } #if !defined(__amd64__) && !defined(__i386__) static void -xctrl_suspend() +xctrl_suspend(void) { printf("WARNING: xen/control: Suspend not supported!\n"); } #else /* __amd64__ || __i386__ */ static void -xctrl_suspend() +xctrl_suspend(void) { #ifdef SMP cpuset_t cpu_suspend_map; @@ -341,7 +341,7 @@ xctrl_suspend() #endif /* __amd64__ || __i386__ */ static void -xctrl_crash() +xctrl_crash(void) { panic("Xen directed crash"); }