Commit 28bcb112 authored by Heiko Carstens's avatar Heiko Carstens Committed by Avi Kivity

KVM: fix compile warnings on s390

CC      arch/s390/kvm/../../../virt/kvm/kvm_main.o
arch/s390/kvm/../../../virt/kvm/kvm_main.c: In function '__kvm_set_memory_region':
arch/s390/kvm/../../../virt/kvm/kvm_main.c:485: warning: unused variable 'j'
arch/s390/kvm/../../../virt/kvm/kvm_main.c:484: warning: unused variable 'lpages'
arch/s390/kvm/../../../virt/kvm/kvm_main.c:483: warning: unused variable 'ugfn'

Cc: Carsten Otte <cotte@de.ibm.com>
Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: default avatarMarcelo Tosatti <mtosatti@redhat.com>
parent 0a79b009
...@@ -1091,9 +1091,8 @@ int __kvm_set_memory_region(struct kvm *kvm, ...@@ -1091,9 +1091,8 @@ int __kvm_set_memory_region(struct kvm *kvm,
{ {
int r; int r;
gfn_t base_gfn; gfn_t base_gfn;
unsigned long npages, ugfn; unsigned long npages;
int lpages; unsigned long i;
unsigned long i, j;
struct kvm_memory_slot *memslot; struct kvm_memory_slot *memslot;
struct kvm_memory_slot old, new; struct kvm_memory_slot old, new;
...@@ -1171,6 +1170,9 @@ int __kvm_set_memory_region(struct kvm *kvm, ...@@ -1171,6 +1170,9 @@ int __kvm_set_memory_region(struct kvm *kvm,
goto skip_lpage; goto skip_lpage;
for (i = 0; i < KVM_NR_PAGE_SIZES - 1; ++i) { for (i = 0; i < KVM_NR_PAGE_SIZES - 1; ++i) {
unsigned long ugfn;
unsigned long j;
int lpages;
int level = i + 2; int level = i + 2;
/* Avoid unused variable warning if no large pages */ /* Avoid unused variable warning if no large pages */
......
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