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 92FFBECAAD8 for ; Wed, 14 Sep 2022 11:09:54 +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=onTM1u4brxzceXsNRGUcekFszuIqEIpTIiQ7vrKJhJE=; b=NzBhxNv88mS1pt myI3S3ssW1IFgexK00Vt0emuicQsD7+noD7k5ZyMWkVAZZ+tMaXhzsP1WXZRf9LVrI+obzBShJ8ck pHuLkfth8hvhUhFCcmVQnxigypNCwqI6ICR5xA1T9WrxwFk9LalrHSfl0CLxZssh764qkmO16iMLb m667YaaTtQawpBV2RYzfAB7uyMqo7mYYSvgH116NApvSjAp0ETv607xHN3dAk0qt87CxyaKfv8trF zkQNs/YwDLjABJwZSUU8wRx5wwkLjQDUmTMgxbV/BxZ9CEvnaCQNhROZsvRQnrFQNi4APYh8+usxX fA92U/VcqV67YFMAdsHA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oYQFo-00FdsB-0C; Wed, 14 Sep 2022 11:08:28 +0000 Received: from out1.migadu.com ([91.121.223.63]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oYQFj-00Fdj8-F2 for linux-arm-kernel@lists.infradead.org; Wed, 14 Sep 2022 11:08:26 +0000 Date: Wed, 14 Sep 2022 12:08:15 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1663153697; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=4icdTTwMOEDl/FiFqEWnD1meNX7EE2LU8zEMLkINvBI=; b=W6EdHTzE6hL8xf2xCXTgPfAWhGW726ekqZCMjg7k35lyEBz7Tt3ZmzHp0iwg7+fHlaXFD6 dahkLcn8Jn4N+5PEv8i7exrmNXbsNqkC/YGp9Dh5q1LGzRfEanP4LFGy9xYjWbimwNLn43 LcJIWApPaRoNmrdDX3GsRJLYLkQNYHs= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Oliver Upton 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, catalin.marinas@arm.com, will@kernel.org, wanghaibin.wang@huawei.com, pbonzini@redhat.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-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: linux.dev X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220914_040824_689694_BF13D0DD X-CRM114-Status: UNSURE ( 9.43 ) X-CRM114-Notice: Please train this message. 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 Reviewed-by: Oliver Upton Marc or Paolo, do one of you want to pick this patch up? Looks like a good fix. -- Thanks, Oliver _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel