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 A758AC54EE9 for ; Thu, 8 Sep 2022 13:30:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=SYxYEfhmUEvpIGa5+XeOFtkVopmZsKqQc68z3x/9/H4=; b=MHJVIzxkAWMbFe KU8KWJiBvq4XVT4hN1irpNuXq6jVTU6euWJ6twBSUofxWkBPBzBaz+G6RNX89CjvIyPTxyI2awwwk nxb43Si5nQ/1GPwXQeZxtiTYVvkcqbtlMeV7rlJje85VdCI5bLEzIP0n5rpkoysNR6xwOfcuxoM38 iRgCiXu07a9vp7pqy7JkDUXIUMQA12T6UR09YMg92mtf/J8IRIQ39LRnyvZeD6AwkMPFk13M+B34z dVNeH9jxuJOmm9mgDdPWQWNU0jKI2og+sHGcxXm2m0UmQ5lEdq5prlK7KCbdLdvEu0wauPAVR/J9y 8hGCjRPUD1B0QKy66i9g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oWHad-003q1b-H0; Thu, 08 Sep 2022 13:29:07 +0000 Received: from ams.source.kernel.org ([145.40.68.75]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oWHaa-003pyD-4l for linux-arm-kernel@lists.infradead.org; Thu, 08 Sep 2022 13:29:05 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id C90D6B82075; Thu, 8 Sep 2022 13:29:02 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0CCA9C433D6; Thu, 8 Sep 2022 13:28:58 +0000 (UTC) Date: Thu, 8 Sep 2022 14:28:55 +0100 From: Catalin Marinas To: Zenghui Yu Cc: kvmarm@lists.cs.columbia.edu, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, maz@kernel.org, james.morse@arm.com, alexandru.elisei@arm.com, suzuki.poulose@arm.com, oliver.upton@linux.dev, will@kernel.org, wanghaibin.wang@huawei.com Subject: Re: [PATCH] KVM: arm64: Use kmemleak_free_part_phys() to unregister hyp_mem_base Message-ID: References: <20220908130659.2021-1-yuzenghui@huawei.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20220908130659.2021-1-yuzenghui@huawei.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220908_062904_347668_5B84014F X-CRM114-Status: GOOD ( 11.69 ) 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: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Sep 08, 2022 at 09:06:59PM +0800, Zenghui Yu wrote: > With commit 0c24e061196c ("mm: kmemleak: add rbtree and store physical > address for objects allocated with PA"), kmemleak started to put the > objects allocated with physical address onto object_phys_tree_root tree. > The kmemleak_free_part() therefore no longer worked as expected on > physically allocated objects (hyp_mem_base in this case) as it attempted to > search and remove things in object_tree_root tree. > > Fix it by using kmemleak_free_part_phys() to unregister hyp_mem_base. This > fixes an immediate crash when booting a KVM host in protected mode with > kmemleak enabled. > > Signed-off-by: Zenghui Yu Acked-by: Catalin Marinas _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel