Skip to content

Commit

Permalink
KVM: PPC: Initialize linears with zeros
Browse files Browse the repository at this point in the history
RMAs and HPT preallocated spaces should be zeroed, so we don't accidently
leak information from previous VM executions.

Signed-off-by: Alexander Graf <agraf@suse.de>
Acked-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Avi Kivity <avi@redhat.com>
  • Loading branch information
Alexander Graf authored and Avi Kivity committed Mar 5, 2012
1 parent b4e7061 commit b7f5d01
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions arch/powerpc/kvm/book3s_hv_builtin.c
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,7 @@ static struct kvmppc_linear_info *kvm_alloc_linear(int type)
break;
}
spin_unlock(&linear_lock);
memset(ri->base_virt, 0, ri->npages << PAGE_SHIFT);
return ri;
}

Expand Down

0 comments on commit b7f5d01

Please sign in to comment.