Commit 8324c3d5 authored by Zenghui Yu's avatar Zenghui Yu Committed by Marc Zyngier

KVM: arm/arm64: Comments cleanup in mmu.c

Some comments in virt/kvm/arm/mmu.c are outdated. Update them to
reflect the current state of the code.
Signed-off-by: default avatarZenghui Yu <yuzenghui@huawei.com>
Reviewed-by: default avatarSuzuki K Poulose <suzuki.poulose@arm.com>
[maz: commit message tidy-up]
Signed-off-by: default avatarMarc Zyngier <marc.zyngier@arm.com>
parent d9ea27a3
...@@ -102,8 +102,7 @@ static bool kvm_is_device_pfn(unsigned long pfn) ...@@ -102,8 +102,7 @@ static bool kvm_is_device_pfn(unsigned long pfn)
* @addr: IPA * @addr: IPA
* @pmd: pmd pointer for IPA * @pmd: pmd pointer for IPA
* *
* Function clears a PMD entry, flushes addr 1st and 2nd stage TLBs. Marks all * Function clears a PMD entry, flushes addr 1st and 2nd stage TLBs.
* pages in the range dirty.
*/ */
static void stage2_dissolve_pmd(struct kvm *kvm, phys_addr_t addr, pmd_t *pmd) 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) ...@@ -121,8 +120,7 @@ static void stage2_dissolve_pmd(struct kvm *kvm, phys_addr_t addr, pmd_t *pmd)
* @addr: IPA * @addr: IPA
* @pud: pud pointer for IPA * @pud: pud pointer for IPA
* *
* Function clears a PUD entry, flushes addr 1st and 2nd stage TLBs. Marks all * Function clears a PUD entry, flushes addr 1st and 2nd stage TLBs.
* pages in the range dirty.
*/ */
static void stage2_dissolve_pud(struct kvm *kvm, phys_addr_t addr, pud_t *pudp) 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, ...@@ -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_alloc_stage2_pgd - allocate level-1 table for stage-2 translation.
* @kvm: The KVM struct pointer for the VM. * @kvm: The KVM struct pointer for the VM.
* *
* Allocates only the stage-2 HW PGD level table(s) (can support either full * Allocates only the stage-2 HW PGD level table(s) of size defined by
* 40-bit input addresses or limited to 32-bit input addresses). Clears the * stage2_pgd_size(kvm).
* allocated pages.
* *
* Note we don't need locking here as this is only called when the VM is * Note we don't need locking here as this is only called when the VM is
* created, which can only be done once. * created, which can only be done once.
...@@ -1478,13 +1475,11 @@ static void stage2_wp_pmds(struct kvm *kvm, pud_t *pud, ...@@ -1478,13 +1475,11 @@ static void stage2_wp_pmds(struct kvm *kvm, pud_t *pud,
} }
/** /**
* stage2_wp_puds - write protect PGD range * stage2_wp_puds - write protect PGD range
* @pgd: pointer to pgd entry * @pgd: pointer to pgd entry
* @addr: range start address * @addr: range start address
* @end: range end address * @end: range end address
* */
* Process PUD entries, for a huge PUD we cause a panic.
*/
static void stage2_wp_puds(struct kvm *kvm, pgd_t *pgd, static void stage2_wp_puds(struct kvm *kvm, pgd_t *pgd,
phys_addr_t addr, phys_addr_t end) phys_addr_t addr, phys_addr_t end)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment