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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C5FB8C25B50 for ; Tue, 24 Jan 2023 00:56:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232479AbjAXA4X (ORCPT ); Mon, 23 Jan 2023 19:56:23 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37288 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231559AbjAXA4V (ORCPT ); Mon, 23 Jan 2023 19:56:21 -0500 Received: from out2.migadu.com (out2.migadu.com [188.165.223.204]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0ED0B1A972 for ; Mon, 23 Jan 2023 16:56:20 -0800 (PST) Date: Tue, 24 Jan 2023 00:56:11 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1674521779; 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=MOqp2XFlnHGFMJtO0tmCKwbMW2UjfrBeLXOpbSiE3+w=; b=gHyHuIqqHwyEJIYUKODisWBVyERQsnbw4WLc+N+eJrJobDfJJ/FChKDtyshxY/Dsq7GUCn hrmf+zijbRQhtkIeX+WR/fOK5rNXAgOM5rY1fMphMd7Q6YxAbM3YVX/bUcOse8KCDsy672 ZYnCikcVKLEwV8effANAk4BGQUZR9ts= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Oliver Upton To: Ben Gardon Cc: Ricardo Koller , pbonzini@redhat.com, maz@kernel.org, yuzenghui@huawei.com, dmatlack@google.com, kvm@vger.kernel.org, kvmarm@lists.linux.dev, qperret@google.com, catalin.marinas@arm.com, andrew.jones@linux.dev, seanjc@google.com, alexandru.elisei@arm.com, suzuki.poulose@arm.com, eric.auger@redhat.com, gshan@redhat.com, reijiw@google.com, rananta@google.com, ricarkol@gmail.com Subject: Re: [PATCH 1/9] KVM: arm64: Add KVM_PGTABLE_WALK_REMOVED into ctx->flags Message-ID: References: <20230113035000.480021-1-ricarkol@google.com> <20230113035000.480021-2-ricarkol@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Migadu-Flow: FLOW_OUT Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org On Mon, Jan 23, 2023 at 04:51:16PM -0800, Ben Gardon wrote: > On Thu, Jan 12, 2023 at 7:50 PM Ricardo Koller wrote: > > > > Add a flag to kvm_pgtable_visit_ctx, KVM_PGTABLE_WALK_REMOVED, to > > indicate that the walk is on a removed table not accesible to the HW > > page-table walker. Then use it to avoid doing break-before-make or > > performing CMOs (Cache Maintenance Operations) when mapping a removed > > Nit: Should this say unmapping? Or are we actually going to use this > to map memory ? I think the *_REMOVED term feels weird as it relates to constructing a page table. It'd be better if we instead added flags to describe the operations we intend to elide (i.e. CMOs and TLBIs). That way the implementation is generic enough that we can repurpose it for other use cases. -- Thanks, Oliver