From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from atuin.qyliss.net (localhost [IPv6:::1]) by atuin.qyliss.net (Postfix) with ESMTP id 55BDE3FF3; Sun, 21 Sep 2025 08:56:19 +0000 (UTC) Received: by atuin.qyliss.net (Postfix, from userid 993) id 56DB73FE8; Sun, 21 Sep 2025 08:56:17 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on atuin.qyliss.net X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DMARC_MISSING,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=4.0.1 Received: from fhigh-a6-smtp.messagingengine.com (fhigh-a6-smtp.messagingengine.com [103.168.172.157]) by atuin.qyliss.net (Postfix) with ESMTPS id 455783FE0 for ; Sun, 21 Sep 2025 08:56:16 +0000 (UTC) Received: from phl-compute-04.internal (phl-compute-04.internal [10.202.2.44]) by mailfhigh.phl.internal (Postfix) with ESMTP id 6798E14000F0; Sun, 21 Sep 2025 04:56:15 -0400 (EDT) Received: from phl-mailfrontend-02 ([10.202.2.163]) by phl-compute-04.internal (MEProxy); Sun, 21 Sep 2025 04:56:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alyssa.is; h=cc :cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm3; t=1758444975; x=1758531375; bh=QnXH3WBRhA 3GAhQ/ZaUmqWz55NIQ/JIkNohZuVrt9Zg=; b=I5jL2CKwmC4auVIVjqZtLY2SME RwUgVHS64wdPFWwhY7LJUVXClR2Mh+/o8XJVmWqZB3PPL4o67dA3+iPeSWxp/PkO xczbuWHGuM41rcT+xKTVNrI+e47NaNg3whb2h0FRlndQsue6VvthNIJX72NucXT/ mI34AslFOY5eHf+t/K+sc0e/UoUWWyU8X3ERV8pNZhmRbk0npzcll/RC6x/2DWtm 9aEkT10KubZKGfepv0HJQ7R/JeZh7ULq3M8fjlBsEqlOuzMWLChuZzZxo5jhkYsX 56f7jqt2g+aUDc4UvoLu0eivxhwhZW9nS6s0NufJDrZWus8MfYeB84b5dWJQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1758444975; x=1758531375; bh=QnXH3WBRhA3GAhQ/ZaUmqWz55NIQ/JIkNoh ZuVrt9Zg=; b=oWuno0PSIw54TtrEYuppLP5QFYihhHgCMvY6E8u60ncFhaxbAhA l9tpju496rljZ3HoderMQTiXljU6E46X9RsaIJj5kciWKOvj0IHmlIynhrsCnEYx JD94RFLWMl30Ik5doqlIv/N68KlJRHrikBMNGsx/alnCCSAjCTRCNZqvmkm8itnC X0X5l/DZLZVDxVFeNphaSAYLLvgj71xv61JivdwZ7jON6jwiU4WXzppHhDj8SDDU jA5LyzTefX2DkBMLlqMTmXkzti9qldChQUKdl1HTRgLUq2ObtcUQwW2JzPqH38Md BniqgNuS5aEHWvdulq9BpgN8PMa9XmKXovg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtdeggdehgeehgecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpuffrtefokffrpgfnqfghnecuuegr ihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjug hrpefhvfevufgjfhffkfggtgesghdtreertddttdenucfhrhhomheptehlhihsshgrucft ohhsshcuoehhihesrghlhihsshgrrdhisheqnecuggftrfgrthhtvghrnhepieduffeuie elgfetgfdttddtkeekheekgfehkedufeevteegfeeiffetvdetueevnecuvehluhhsthgv rhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhephhhisegrlhihshhsrgdrih hspdhnsggprhgtphhtthhopedvpdhmohguvgepshhmthhpohhuthdprhgtphhtthhopegu vghmihhosggvnhhouhhrsehgmhgrihhlrdgtohhmpdhrtghpthhtohepuggvvhgvlhessh hpvggtthhruhhmqdhoshdrohhrgh X-ME-Proxy: Feedback-ID: i12284293:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sun, 21 Sep 2025 04:56:14 -0400 (EDT) Received: by mbp.qyliss.net (Postfix, from userid 1000) id 07CD52003869; Sun, 21 Sep 2025 10:55:54 +0200 (CEST) From: Alyssa Ross To: Demi Marie Obenour Subject: Re: [PATCH] tools/start-vmm: Add additional warning options In-Reply-To: <4c1306e9-1042-4fd7-8e9b-e6f341950021@gmail.com> References: <20250918-more-c-warnings-1-v1-1-5fe4eaff8a30@gmail.com> <87tt0yslm3.fsf@alyssa.is> <4c1306e9-1042-4fd7-8e9b-e6f341950021@gmail.com> Date: Sun, 21 Sep 2025 10:55:52 +0200 Message-ID: <87frcguquf.fsf@alyssa.is> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Message-ID-Hash: XPUDNBNOPM3ZCPIZV3Q5MYIM5IRSR2R2 X-Message-ID-Hash: XPUDNBNOPM3ZCPIZV3Q5MYIM5IRSR2R2 X-MailFrom: hi@alyssa.is X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-devel.spectrum-os.org-0; header-match-devel.spectrum-os.org-1; header-match-devel.spectrum-os.org-2; header-match-devel.spectrum-os.org-3; header-match-devel.spectrum-os.org-4; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Spectrum OS Development X-Mailman-Version: 3.3.9 Precedence: list List-Id: Patches and low-level development discussion Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Demi Marie Obenour writes: > On 9/19/25 07:55, Alyssa Ross wrote: >> Demi Marie Obenour writes: >>=20 >>> This detected a missing prototype. >>> >>> No functional change. >>> >>> Signed-off-by: Demi Marie Obenour >>> --- >>> tools/meson.build | 2 ++ >>> tools/start-vmm/ch.h | 1 + >>> 2 files changed, 3 insertions(+) >>> >>> diff --git a/tools/meson.build b/tools/meson.build >>> index 9cebd03e323531fca7600cacf120161a98de16c5..8262f3e01d7bd56561306d7= dd4650a22ca40ebe7 100644 >>> --- a/tools/meson.build >>> +++ b/tools/meson.build >>> @@ -9,6 +9,8 @@ project('spectrum-tools', 'c', >>> }) >>>=20=20 >>> add_project_arguments('-Wno-error=3Dattributes', language : 'c') >>> +add_project_arguments('-Werror=3Dmissing-prototypes', language : 'c') >>> +add_project_arguments('-Werror=3Dmissing-declarations', language : 'c') >>>=20=20 >>> if get_option('host') >>> add_languages('rust') >>> diff --git a/tools/start-vmm/ch.h b/tools/start-vmm/ch.h >>> index 7230913ef0abf41a4f712ac4a543c7f7fdecec0f..5431365e6e2894cdebae22a= 9a44e2ccf1222e0d2 100644 >>> --- a/tools/start-vmm/ch.h >>> +++ b/tools/start-vmm/ch.h >>> @@ -8,3 +8,4 @@ struct net_config { >>> char id[18]; >>> uint8_t mac[6]; >>> }; >>> +struct net_config net_setup(const char name[static 1], int name_len); >>=20 >> Why do we need to declare this in a C header? It's only used from Rust. > > Ideally the Rust declarations would be generated from the C ones > using bindgen. Also, this catches genuine bugs on the C side. What bugs? Implicit definitions are already disallowed, aren't they? --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRV/neXydHjZma5XLJbRZGEIw/wogUCaM+9mAAKCRBbRZGEIw/w ogeQAQC8xhq/iNLyTElzi8Nx7w59UYcYKrNAEgF6eHK/I3cf2wEA8CStrfY8gnvz B1y+QZ4WvmPQS8kVvrFwlQVp2JdCags= =zPlJ -----END PGP SIGNATURE----- --=-=-=--