Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D8940C00140 for ; Tue, 2 Aug 2022 11:40:02 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.379265.612572 (Exim 4.92) (envelope-from ) id 1oIqFT-0004R6-MD; Tue, 02 Aug 2022 11:39:43 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 379265.612572; Tue, 02 Aug 2022 11:39:43 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oIqFT-0004Qz-Je; Tue, 02 Aug 2022 11:39:43 +0000 Received: by outflank-mailman (input) for mailman id 379265; Tue, 02 Aug 2022 11:39:41 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oIqFR-0004Qt-MR for xen-devel@lists.xenproject.org; Tue, 02 Aug 2022 11:39:41 +0000 Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id c93962d7-1257-11ed-bd2d-47488cf2e6aa; Tue, 02 Aug 2022 13:39:39 +0200 (CEST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 3A5095C010B; Tue, 2 Aug 2022 07:39:36 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Tue, 02 Aug 2022 07:39:36 -0400 Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 2 Aug 2022 07:39:34 -0400 (EDT) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: c93962d7-1257-11ed-bd2d-47488cf2e6aa DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= invisiblethingslab.com; h=cc:cc:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm3; t=1659440376; x= 1659526776; bh=YWv9qomqIrVSkbEgIJOPxGBO+lGKFBqYCcjNcgu+s6I=; b=K oSujEucYoRUcctOOxMPVqzCXG9F9CUPCzHJiIvpeD5G2+D9jRDr7s16npvblht3h xgJJGufEiMGeUuPM49sphPupGcgGjiqtGoef95bsLxGXxlTbcJpJwZ/o7hPUTbNy q2W6VG2+NK3b4SPdJsb+fIfQlitjtIE01Ms/K5p/NsjY+b5fv4sXlYDRSXQHn44i 3cxnoNzn1M7phlf6wloiNaNhCPG6rldc7OpZbRDsY3PlIC6GGmW7KG49R60Qzbel JaibW2MvMQh9DAGgxfszQ+zhnzSsAqWN71L47z9hY4/gdlMpOnWycAo6tc+9Qf+o AqWxWZDBb2ch3b/UNq5JQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:date:date:feedback-id :feedback-id:from:from:in-reply-to:in-reply-to:message-id :mime-version:references:reply-to:sender:subject:subject:to:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; t=1659440376; x=1659526776; bh=YWv9qomqIrVSkbEgIJOPxGBO+lGK FBqYCcjNcgu+s6I=; b=raxmK9bJhIclE4CdwP53L3qCLTz280Ttx8Iz65IXdwyp oxetghgQ2m0D1GvvZEgqwglh0Kx8OKQWQwD8loVO5xvndREBhIR5XibP+alIP5t6 Qm8EyVjx79it2oDzuKuJ4HfK4sPQr3zlMgpGPZYTfsL0BBUdk/gZi/BxOUz6jbbV 3BLKRcVxGr2s/EY2a/LIK1bVT9jBPNx+P0wi+saVoMRSHZoy1sQNOWDmcU6iNVO6 Y0dCJF8OfXxpIsQtei8WcJMMEI+SP7BtW2Ifq9TDrNUdaZc3OlcoXhet0Mk/n/eR QmFmiyUPbRGoa6BU3fW+ZiPlBkltNwMq3iemFtzpOQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrvddvhedggeduucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvfevuffkfhggtggujgesghdtreertddtjeenucfhrhhomhepofgrrhgv khcuofgrrhgtiiihkhhofihskhhiqdfikphrvggtkhhiuceomhgrrhhmrghrvghksehinh hvihhsihgslhgvthhhihhnghhslhgrsgdrtghomheqnecuggftrfgrthhtvghrnhepgfdu leetfeevhfefheeiteeliefhjefhleduveetteekveettddvgeeuteefjedunecuvehluh hsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepmhgrrhhmrghrvghk sehinhhvihhsihgslhgvthhhihhnghhslhgrsgdrtghomh X-ME-Proxy: Feedback-ID: i1568416f:Fastmail Date: Tue, 2 Aug 2022 13:39:31 +0200 From: Marek =?utf-8?Q?Marczykowski-G=C3=B3recki?= To: Daniel =?utf-8?B?UC4gQmVycmFuZ8Op?= Cc: Julien Grall , Michal =?utf-8?B?UHLDrXZvem7DrWs=?= , Oleksandr Tyshchenko , xen-devel@lists.xenproject.org, libvir-list@redhat.com, Anthony PERARD , Oleksandr Tyshchenko Subject: Re: [libvirt PATCH] libxl: Fix build with recent Xen that introduces new disk backend type Message-ID: References: <20220729155024.3327364-1-olekstysh@gmail.com> <7444eeec-5a7c-6a18-ffde-cb32528a0e20@xen.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="amSIcO9h4A3vNWt5" Content-Disposition: inline In-Reply-To: --amSIcO9h4A3vNWt5 Content-Type: text/plain; protected-headers=v1; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Date: Tue, 2 Aug 2022 13:39:31 +0200 From: Marek =?utf-8?Q?Marczykowski-G=C3=B3recki?= To: Daniel =?utf-8?B?UC4gQmVycmFuZ8Op?= Cc: Julien Grall , Michal =?utf-8?B?UHLDrXZvem7DrWs=?= , Oleksandr Tyshchenko , xen-devel@lists.xenproject.org, libvir-list@redhat.com, Anthony PERARD , Oleksandr Tyshchenko Subject: Re: [libvirt PATCH] libxl: Fix build with recent Xen that introduces new disk backend type On Mon, Aug 01, 2022 at 10:36:07AM +0100, Daniel P. Berrang=C3=A9 wrote: > Generally we want to see errors triggered from new enums arriving, > as it can be a sign that libvirt code needs a semantic change in > order to continue operating correctly. It isn't always correct > to assume that the 'default' case gives the correct behaviour. Isn't that the exact purpose of 'default' label? If use of 'default' means "any of the other 5 specific values, but lets save some characters to not name them explicitly", then IMHO better to name them explicitly... I can see a value of -Werror=3Dswitch-enum when adding new (internal) enum value, to find all the cases where code needs to be adjusted, but even then a grep is probably sufficient enough. On the other hand, if there are cases where indeed all the values of (internal API) enum needs to be handled explicitly, maybe simply omit 'default' label and use -Werror=3Dswitch? Anyway, if tracking all the enums values of all the used 3rd-party APIs is desirable (like, noticing when libxl adds new disk type), then it probably should be a separate CI job, not the default devel build. Otherwise breakages like this will happen from time to time, and will be annoyed for people on involved in specific code part at all. As a short term fix, maybe Xen's CI can build libvirt with -Wno-error=3Dswitch-enum? --=20 Best Regards, Marek Marczykowski-G=C3=B3recki Invisible Things Lab --amSIcO9h4A3vNWt5 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEhrpukzGPukRmQqkK24/THMrX1ywFAmLpDPIACgkQ24/THMrX 1ywoQwf/e7IEk2U+3R7CZUtfnwVyv/QTfT2IKwqkJfSi6U9WrODSXKms9L89pPkN yR+O9i6J0kacfT/VTrqYr91xF/8NC4cdiidlt2cCrr3Nu1HyAuO32zGBxU9YeUz9 WkU2R02B2A0lhREUjpfPpUMXhHiRXL8r8jOob+mIpE/yp+YX4TfapkG05o04e2i4 7VKDFOZD+XogFxzio2C4TmIpZlPpjSDZXsSO3fhGux9jj7LKyX+Y/z289wEfbUw+ XO/gWFokSzzVNV1p5FYW/nkGuaF7/95jnjdeDXsRKIJQRPmhXx0/P4uK9ZhUFFiK jfPVr01LhDvXGIP9xiHdvKHWCUWBRg== =BUwU -----END PGP SIGNATURE----- --amSIcO9h4A3vNWt5--