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 5E60EF3380E for ; Tue, 17 Mar 2026 08:20:43 +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=AXuM9p4n5thvCAqywXqxRDyN8lwIU8bUlx5hHokH3k0=; b=vVOv5ARhqxPMXCX44aacwbROyr 3l5sVICiRRwT4vDLYLaSwJL/PiKO7fzqHYbG+Mird1S6CE16yeiBJZOFVKcxzC3TaGHhJHQBbI269 ufZUOOrX25hRn3RQyjftRns3mWOvb4XeMlhsZfSX9TJbjpafoENPeu+keEf2oELHE0pwTZTtRGASN UQen11ia+fk5hve/ak7wyjsAwJ34gh/SZlOKs8SKFo6I949P/GdghC9s0ZIuRQLjyQRbA4ZsFLLDy YyJJI94u0/M0ZaT1o9X4+awT1/VVmEqSLuKTcHA8yKFzq5xIVykNc0QqNywTIx25Km6LPVMwNmfvO meiQfgSQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux)) id 1w2PfM-00000005ifO-18hd; Tue, 17 Mar 2026 08:20:40 +0000 Received: from tor.source.kernel.org ([2600:3c04:e001:324:0:1991:8:25]) by bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux)) id 1w2PfK-00000005ieY-3Dvn for linux-arm-kernel@lists.infradead.org; Tue, 17 Mar 2026 08:20:38 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by tor.source.kernel.org (Postfix) with ESMTP id D682E6132E; Tue, 17 Mar 2026 08:20:37 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 852C1C2BC9E; Tue, 17 Mar 2026 08:20:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1773735637; bh=VQNGXk1va0JojLCa5FTgduK6/uhqV70yDcBBQE/5J40=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=L2kTCLKJqOS5HvcFUgK480t6dsocDP43k7dp9YZ4h3bO+TaOUQ6TxqzWDPQSy9sAg cgc6Vxu2E2kx/JdVdZNzd7o8fJ5MU/DyPHfI7J8H188DI4B8Fi568eGIrIPWsEAcn1 ir9C2S5TKU6Bo8nUHWwEnSkI52KvNSLf/ws0gqR81LBB4+tIjiRKCIzNvpTrYf6N1w ZbCFYayAtr1aW5t6CQBLNeMTLQFNk14XqoLUelLRdytMfYZeWGCtB02ZalIGu/fnJe 43EW4CDNsVsoYFwUdcUs9TDhGBT1D9uT3l3O8v0tnLXHgH1GXXK0Ur2uLaCvacoo7k U4HFMjgCFGFxA== Received: from sofa.misterjones.org ([185.219.108.64] helo=goblin-girl.misterjones.org) by disco-boy.misterjones.org with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1w2PfG-00000002jEv-3Wqu; Tue, 17 Mar 2026 08:20:34 +0000 Date: Tue, 17 Mar 2026 08:20:34 +0000 Message-ID: <86v7eu6f59.wl-maz@kernel.org> From: Marc Zyngier To: Fuad Tabba Cc: Oliver Upton , Joey Gouly , Suzuki K Poulose , Zenghui Yu , Catalin Marinas , Will Deacon , "KERNEL VIRTUAL MACHINE FOR ARM64 KVM/arm64" , "KERNEL VIRTUAL MACHINE FOR ARM64 KVM/arm64" , open list Subject: Re: [PATCH 00/10] KVM: arm64: Adopt scoped resource management (guard) for EL1 and EL2 In-Reply-To: <20260316-tabba-el2_guard-v1-0-456875a2c6db@google.com> References: <20260316-tabba-el2_guard-v1-0-456875a2c6db@google.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/30.1 (aarch64-unknown-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: 185.219.108.64 X-SA-Exim-Rcpt-To: tabba@google.com, oupton@kernel.org, joey.gouly@arm.com, suzuki.poulose@arm.com, yuzenghui@huawei.com, catalin.marinas@arm.com, will@kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev, linux-kernel@vger.kernel.org X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false 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, 16 Mar 2026 17:35:21 +0000, Fuad Tabba wrote: > > Hi everyone, > > I stumbled upon a lock leak while reviewing Sebastien's recent GIC Hardening > series [1] on an early error path. It reminded me that we've run into this exact > kind of bug pretty often while working on pKVM. Since we're going to be > hopefully upstream even more pKVM code soon, I'd like to try and fix this > pattern once and for all. I'm of the opposite opinion. I'd rather convert things as code gets modified, because this otherwise makes backporting patches a real pain (we have been through that exercise with the irq stack, and it wasn't an enjoyable experience). So while I'm not opposed to this in general, I'd rather see it as a prefix for new features, instead of a standalone series. [...] > There are definitely other parts of the KVM codebase that could benefit from > this (especially the vGIC), but I'm stopping here for now to see what everyone > thinks of the approach before touching anything else. The vgic is specially difficult to convert because of some of the constructs that take a lock in a function and release it in another, defeating the scope-based locking. I'll have a look at the series anyway. Thanks, M. -- Without deviation from the norm, progress is not possible.