Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp3060564img; Mon, 25 Mar 2019 02:59:42 -0700 (PDT) X-Google-Smtp-Source: APXvYqzeUwINPXh2UcoYsPkhamj+/XD0WirfTXOAxgINlCtJJ5LB/0zr9BtZAMXuId1n+8CMYjeU X-Received: by 2002:a63:fe0a:: with SMTP id p10mr18000454pgh.86.1553507981963; Mon, 25 Mar 2019 02:59:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1553507981; cv=none; d=google.com; s=arc-20160816; b=Kmbgwkzk90YiULThiFnOXXRk2lhgVk60LghcF7dZJIccA0Ldm3+E/8fO2NZBkcsxxr a5qyAIYuDaN6e43vEHTLdKPZUTL/yEPv3StefxknDL1iridD+ZLvqPIRMpFhQbzBZmeL K2mYRyXbW9VylgB/vFzRqimgvyxonbYfqdW4J1ozSKl5rWL0zjoyGIljqdeLSqaNXz4r SKCBCDLyCplzxmlq9GxRHosR0WuJ1ItfC32Un1N4Dl3OjxEM3TUKa09a7oIwMn0UN32t Oki/8Ql09+wVLepH91fMOF/QMTwB2p4pq6XxgxZsDm62xqno4bHNqRhUI2UCVmCpoRwT YD4g== 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; bh=rAloQoGb6Y8sLZChD/bR9WgMi2fgDtm5G32khUbSI/0=; b=J9lqSMr90u7iSvGj7hIbtwVj000yzIkbrp8qAbnjitFI26o+1492WW20h1ggdzB/Xt B49vUAxXrVgK6rjwG9l2Do5HA8mSA+VF5641Q1NrYEVQdnLA2oYqGwlv5rpuIzpFLC3K rqP2CFj+aWfSz6AIvnVRU3R6r3bq1kyr1UmlawjPdlOeW37aBLY0tIHwkC/ytwGGOj/E sD0tYl+RCgFWNWmtP/hWSEnTFY6HGyh57MIuWt/8jATNaxVn6453zZ6esiMRM+UJanRq HpPIvG2h3uGyfQM9mVi++Uelg516NxSkcSjmuo7HYQuwWaWcRKV4uN3IGq2CSYuO9Tc3 GWyA== 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 e2si6565583plt.197.2019.03.25.02.59.26; Mon, 25 Mar 2019 02:59:41 -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 S1730499AbfCYJ6Q (ORCPT + 99 others); Mon, 25 Mar 2019 05:58:16 -0400 Received: from usa-sjc-mx-foss1.foss.arm.com ([217.140.101.70]:44160 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730250AbfCYJ6P (ORCPT ); Mon, 25 Mar 2019 05:58:15 -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 3980715AB; Mon, 25 Mar 2019 02:58:15 -0700 (PDT) Received: from [10.1.196.93] (en101.cambridge.arm.com [10.1.196.93]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id E47C53F614; Mon, 25 Mar 2019 02:58:11 -0700 (PDT) Subject: Re: [PATCH] KVM: arm/arm64: Comments cleanup in mmu.c To: yuzenghui@huawei.com, christoffer.dall@arm.com, marc.zyngier@arm.com Cc: james.morse@arm.com, julien.thierry@arm.com, wanghaibin.wang@huawei.com, kvmarm@lists.cs.columbia.edu, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org References: <1553500925-26000-1-git-send-email-yuzenghui@huawei.com> From: Suzuki K Poulose Message-ID: <194b5370-0ed2-5dbd-9a5d-e20e4f8413ec@arm.com> Date: Mon, 25 Mar 2019 09:58:09 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.1 MIME-Version: 1.0 In-Reply-To: <1553500925-26000-1-git-send-email-yuzenghui@huawei.com> Content-Type: text/plain; charset=utf-8; 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 25/03/2019 08:02, Zenghui Yu wrote: > Some comments in virt/kvm/arm/mmu.c are outdated and incorrect. > Get rid of these comments, to keep the code&comment correct and > current as a whole. > > Only a cleanup here, no functional change. > > Signed-off-by: Zenghui Yu > --- > virt/kvm/arm/mmu.c | 23 +++++++++-------------- > 1 file changed, 9 insertions(+), 14 deletions(-) > > diff --git a/virt/kvm/arm/mmu.c b/virt/kvm/arm/mmu.c > index ffd7acd..0a6efe7 100644 > --- a/virt/kvm/arm/mmu.c > +++ b/virt/kvm/arm/mmu.c > @@ -102,8 +102,7 @@ static bool kvm_is_device_pfn(unsigned long pfn) > * @addr: IPA > * @pmd: pmd pointer for IPA > * > - * Function clears a PMD entry, flushes addr 1st and 2nd stage TLBs. Marks all > - * pages in the range dirty. > + * Function clears a PMD entry, flushes addr 1st and 2nd stage TLBs. > */ > static void stage2_dissolve_pmd(struct kvm *kvm, phys_addr_t addr, pmd_t *pmd) > { > @@ -121,8 +120,7 @@ static void stage2_dissolve_pmd(struct kvm *kvm, phys_addr_t addr, pmd_t *pmd) > * @addr: IPA > * @pud: pud pointer for IPA > * > - * Function clears a PUD entry, flushes addr 1st and 2nd stage TLBs. Marks all > - * pages in the range dirty. > + * Function clears a PUD entry, flushes addr 1st and 2nd stage TLBs. > */ > static void stage2_dissolve_pud(struct kvm *kvm, phys_addr_t addr, pud_t *pudp) > { > @@ -899,9 +897,8 @@ int create_hyp_exec_mappings(phys_addr_t phys_addr, size_t size, > * kvm_alloc_stage2_pgd - allocate level-1 table for stage-2 translation. > * @kvm: The KVM struct pointer for the VM. > * > - * Allocates only the stage-2 HW PGD level table(s) (can support either full > - * 40-bit input addresses or limited to 32-bit input addresses). Clears the > - * allocated pages. > + * Allocates only the stage-2 HW PGD level table(s) of size defined by > + * stage2_pgd_size(kvm). > * > * Note we don't need locking here as this is only called when the VM is > * created, which can only be done once. > @@ -1451,13 +1448,11 @@ static void stage2_wp_pmds(struct kvm *kvm, pud_t *pud, > } > > /** > - * stage2_wp_puds - write protect PGD range > - * @pgd: pointer to pgd entry > - * @addr: range start address > - * @end: range end address > - * > - * Process PUD entries, for a huge PUD we cause a panic. > - */ > + * stage2_wp_puds - write protect PGD range > + * @pgd: pointer to pgd entry > + * @addr: range start address > + * @end: range end address > + */ Reviewed-by: Suzuki K Poulose