From mboxrd@z Thu Jan 1 00:00:00 1970 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 E3676C3DA4B for ; Mon, 15 Jul 2024 14:40:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:MIME-Version: References:In-Reply-To:Subject:Cc:To:From:Message-ID:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=T8ILzMU1aqfGvJmh5KK4MZd5qKodcoeru5RvHUFkh0E=; b=svdWTusiVME81pylMf047Dny6l RsukUH+e1schjZfe9mYEzD5uBazzTs9uGIp3Fnkz5KXNpwTa7SvHYZkaF0VhLq552SLVn387bowag 5yKCzAsbvAxdNT8WMuNoyz3oV7SD3p1pwtIEgwVEIo4oRzh1UDxvxq4igA5BrFiKhsSkYh7vjgc7P lbtdclUyj+sw7Tk6ElejxBWaTdL7GEeNaFmIre5HNeTMhghlOSOE02qJWzGHKh2GV+cB7Rkm9X0mB RgoznimzKOYYuJx2xIWVbTn2Bzs0vERxCfpoWvL4qT/17p1v7mL9w/gWhaEu2bVQfYK/jcjnKZtfV 0W9Irz/w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sTMsY-00000007Pbt-1BxY; Mon, 15 Jul 2024 14:40:38 +0000 Received: from sin.source.kernel.org ([2604:1380:40e1:4800::1]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sTMsE-00000007PW2-3OdZ for linux-arm-kernel@lists.infradead.org; Mon, 15 Jul 2024 14:40:20 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by sin.source.kernel.org (Postfix) with ESMTP id 2317DCE0FCB; Mon, 15 Jul 2024 14:40:16 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6686CC32782; Mon, 15 Jul 2024 14:40:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1721054415; bh=gw2ndcYzWrXcWwfMvNwsIdrsWIYeYw1572YOxUCWSHc=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=OQMK0Q757KBbSEG6i8nNQN1Jc32yl0zvJ0OnXj446cwAZatYwfT+TICs9NGttRj2n mCYfSBrmIvm3h30AasxhFILcwx+n8hffsjhuiV62hYTHWsr6K+D7wBZyw4JNtPko0p tRvAjs151m7ke0WhKGsx0reosTqNL+Bb0WbYJ3lvB996YCPUHSBvMY3nfM6bje5/nB 3UBVzLqo/ZNNVKTTqTFQ/usp6Aty+lw5oJXRLPs72+LaTCrT4ZRkh8juIilcyLUH+3 eiTsYLXgavQ11tYofAQsd9RuuR//KxLoWCDtfVzNC0dwCFUgVNUc31sY2+b3fgNBZU dJhoDI9jWuY6A== Received: from 82-132-225-32.dab.02.net ([82.132.225.32] helo=wait-a-minute.misterjones.org) by disco-boy.misterjones.org with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1sTMs9-00CXag-1d; Mon, 15 Jul 2024 15:40:13 +0100 Date: Mon, 15 Jul 2024 15:40:10 +0100 Message-ID: <875xt667n9.wl-maz@kernel.org> From: Marc Zyngier To: Sebastian Ott Cc: linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev, linux-kernel@vger.kernel.org, Oliver Upton , James Morse , Suzuki K Poulose , Catalin Marinas , Will Deacon , Zenghui Yu Subject: Re: [PATCH 1/3] KVM: arm64: fix override-init warnings in W=1 builds In-Reply-To: <3b882ac0-fd2c-35df-38d7-b89cf073bcc3@redhat.com> References: <20240712110332.10970-1-sebott@redhat.com> <20240712110332.10970-2-sebott@redhat.com> <8734oep96j.wl-maz@kernel.org> <3b882ac0-fd2c-35df-38d7-b89cf073bcc3@redhat.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM-LB/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL-LB/10.8 EasyPG/1.0.0 Emacs/28.2 (x86_64-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-SA-Exim-Connect-IP: 82.132.225.32 X-SA-Exim-Rcpt-To: sebott@redhat.com, linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev, linux-kernel@vger.kernel.org, oliver.upton@linux.dev, james.morse@arm.com, suzuki.poulose@arm.com, catalin.marinas@arm.com, will@kernel.org, yuzenghui@huawei.com X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240715_074019_222320_A5795135 X-CRM114-Status: GOOD ( 19.48 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Mon, 15 Jul 2024 11:28:06 +0100, Sebastian Ott wrote: > > On Fri, 12 Jul 2024, Marc Zyngier wrote: > > On Fri, 12 Jul 2024 12:03:30 +0100, > > Sebastian Ott wrote: > >> > >> -static const exit_handler_fn hyp_exit_handlers[] = { > >> - [0 ... ESR_ELx_EC_MAX] = NULL, > >> +static const exit_handler_fn hyp_exit_handlers[ESR_ELx_EC_MAX + 1] = { > > > > Is this really any better? I don't think so. It makes the intent > > disappear instead of making it explicit. Intent matters *a lot*. > > I'm not claiming that it's an improvement to the code. Silencing pointless warnings should never have priority over keeping the code maintainable and understandable. I hope we can agree we are not in the business of making the kernel *worse* than it already is on that front, right? I like good tooling as much as the next kernel tinkerer. But W=1 is, in its current form, quite the opposite. Mark posted a link to a 5 year old thread, showing a number of ways compilers could use extra annotation to lift the multiple initialisation ambiguity. This approach has seen no traction, which is a bit sad. > But yea, I see your point. How about disabling that flag in the > makefile? Yes, that'd be a reasonable workaround until someone fixes the toolchains. I see that Loongarch is already doing it for the exact same purpose. Thanks, M. -- Without deviation from the norm, progress is not possible.