Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp492405imm; Wed, 11 Jul 2018 06:10:46 -0700 (PDT) X-Google-Smtp-Source: AAOMgpfVUAS+1QI1NTxgoHJVLFm1l2BwGzHDzqymuVA09dU3IBRjjsKex87/GyUENzM33ANRfaTA X-Received: by 2002:a63:f:: with SMTP id 15-v6mr20488915pga.430.1531314646076; Wed, 11 Jul 2018 06:10:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531314646; cv=none; d=google.com; s=arc-20160816; b=jvogPiHOEweNbeuh8fSVNSe0aPmQVrFkf6YENdYU9/BThUILgXbuALOvPSEm+jeHg5 zJgpUp8tCNCQLp/6pjnTk7OZnF/JQKnhilLj+TfMK/4Zjt3HWD+nRwsT2u+NH3qGJjn+ aTAzNr6eTwUjxQZeXLoCHHtnXWqqVbvuzLCH71SuJbuMTzoXSctc1TnEQZ/gP75ABMZp jWzyIw4KHF05wAApF5LpLf5iJMBGSRGJSC2qmCeFQnR016lLWMYv/wrnzaj9Ys8YIb1W Qk7Hhqxieguxt6CDNnnpXqLf0mLR2iRmEJ/7PyIcqY2RGl8r713BHUQk1bnTn5i6pyfh wb9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:arc-authentication-results; bh=nq3ofU81wFFWhZ7945ifsHlLg8Cp21kDNmtJw+4IGLM=; b=rP2Cu/8MinITG3nGfhZ6s1Ln16C1VMp6wHS9hcOqMk6sZ/3WnGcDbVAmV64TliooHV tS25kffExvQpCK3sk+g75PSy2kl3MsMXg+rfUu573S7Ty6CEzd5k7dCS4b9K91Pp468t f1vgY1xFsARFcJ5PKI+YShwOp292THsws/1tRuRUUqiC7t6QfPsV3xcyK9N8K2AyZ7he C945uWS7Fy7FHwDNNCvqzIWVDrDWijrCziOKOHr7hbg1s7vknPQwvghsrB9BLoPgfyt8 DsVoJjcw+UV2NJoPODtm9ZTUgphVCAzNGpbZOwidJybQZ1qFUHliw6LzI9CH+ScNT+Zz +AQg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t21-v6si18702885pgb.553.2018.07.11.06.10.30; Wed, 11 Jul 2018 06:10:46 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387709AbeGKNHV (ORCPT + 99 others); Wed, 11 Jul 2018 09:07:21 -0400 Received: from foss.arm.com ([217.140.101.70]:35348 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726453AbeGKNHV (ORCPT ); Wed, 11 Jul 2018 09:07:21 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id C9EC47A9; Wed, 11 Jul 2018 06:03:06 -0700 (PDT) Received: from [10.1.206.73] (en101.cambridge.arm.com [10.1.206.73]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 45BC03F5AD; Wed, 11 Jul 2018 06:03:05 -0700 (PDT) Subject: Re: [PATCH v5 3/7] KVM: arm64: Support dirty page tracking for PUD hugepages To: Punit Agrawal , kvmarm@lists.cs.columbia.edu Cc: linux-arm-kernel@lists.infradead.org, marc.zyngier@arm.com, christoffer.dall@arm.com, linux-kernel@vger.kernel.org, will.deacon@arm.com, Russell King , Catalin Marinas References: <20180709143835.28971-1-punit.agrawal@arm.com> <20180709144124.29164-1-punit.agrawal@arm.com> <20180709144124.29164-3-punit.agrawal@arm.com> From: Suzuki K Poulose Message-ID: Date: Wed, 11 Jul 2018 14:03:02 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 MIME-Version: 1.0 In-Reply-To: <20180709144124.29164-3-punit.agrawal@arm.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 09/07/18 15:41, Punit Agrawal wrote: > In preparation for creating PUD hugepages at stage 2, add support for > write protecting PUD hugepages when they are encountered. Write > protecting guest tables is used to track dirty pages when migrating > VMs. > > Also, provide trivial implementations of required kvm_s2pud_* helpers > to allow sharing of code with arm32. > > Signed-off-by: Punit Agrawal > Reviewed-by: Christoffer Dall > Cc: Marc Zyngier > Cc: Russell King > Cc: Catalin Marinas > Cc: Will Deacon > --- > arch/arm/include/asm/kvm_mmu.h | 16 ++++++++++++++++ > arch/arm64/include/asm/kvm_mmu.h | 10 ++++++++++ > virt/kvm/arm/mmu.c | 11 +++++++---- > 3 files changed, 33 insertions(+), 4 deletions(-) > > diff --git a/arch/arm/include/asm/kvm_mmu.h b/arch/arm/include/asm/kvm_mmu.h > index d095c2d0b284..c23722f75d5c 100644 > --- a/arch/arm/include/asm/kvm_mmu.h > +++ b/arch/arm/include/asm/kvm_mmu.h > @@ -80,6 +80,22 @@ void kvm_clear_hyp_idmap(void); > > #define kvm_pmd_mkhuge(pmd) pmd_mkhuge(pmd) > > +/* > + * The following kvm_*pud*() functionas are provided strictly to allow nit: s/functionas/functions/ Reviewed-by: Suzuki K Poulose