Skip to content

Commit

Permalink
KVM: PPC: BookE: Use vma_pages function
Browse files Browse the repository at this point in the history
Use vma_pages function on vma object instead of explicit computation.
Found by coccinelle spatch "api/vma_pages.cocci"

Signed-off-by: Thomas Meyer <[email protected]>
Signed-off-by: Paul Mackerras <[email protected]>
  • Loading branch information
thomasmey authored and paulusmack committed Oct 14, 2017
1 parent 4bb817e commit 4bdcb70
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/powerpc/kvm/e500_mmu_host.c
Original file line number Diff line number Diff line change
Expand Up @@ -377,7 +377,7 @@ static inline int kvmppc_e500_shadow_map(struct kvmppc_vcpu_e500 *vcpu_e500,

start = vma->vm_pgoff;
end = start +
((vma->vm_end - vma->vm_start) >> PAGE_SHIFT);
vma_pages(vma);

pfn = start + ((hva - vma->vm_start) >> PAGE_SHIFT);

Expand Down

0 comments on commit 4bdcb70

Please sign in to comment.