Skip to content

Commit

Permalink
KVM: X86: Remove FNAME(update_pte)
Browse files Browse the repository at this point in the history
Its solo caller is changed to use FNAME(prefetch_gpte) directly.

Signed-off-by: Lai Jiangshan <laijs@linux.alibaba.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Message-Id: <20210918005636.3675-9-jiangshanlai@gmail.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
  • Loading branch information
Lai Jiangshan authored and Paolo Bonzini committed Sep 30, 2021
1 parent 5591c06 commit cc2a8e6
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions arch/x86/kvm/mmu/paging_tmpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -589,14 +589,6 @@ FNAME(prefetch_gpte)(struct kvm_vcpu *vcpu, struct kvm_mmu_page *sp,
return true;
}

static void FNAME(update_pte)(struct kvm_vcpu *vcpu, struct kvm_mmu_page *sp,
u64 *spte, const void *pte)
{
pt_element_t gpte = *(const pt_element_t *)pte;

FNAME(prefetch_gpte)(vcpu, sp, spte, gpte, false);
}

static bool FNAME(gpte_changed)(struct kvm_vcpu *vcpu,
struct guest_walker *gw, int level)
{
Expand Down Expand Up @@ -1007,7 +999,7 @@ static void FNAME(invlpg)(struct kvm_vcpu *vcpu, gva_t gva, hpa_t root_hpa)
sizeof(pt_element_t)))
break;

FNAME(update_pte)(vcpu, sp, sptep, &gpte);
FNAME(prefetch_gpte)(vcpu, sp, sptep, gpte, false);
}

if (!is_shadow_present_pte(*sptep) || !sp->unsync_children)
Expand Down

0 comments on commit cc2a8e6

Please sign in to comment.