Skip to content

Commit

Permalink
KVM: PPC: e500: fix allocation size error on g2h_tlb1_map
Browse files Browse the repository at this point in the history
We were only allocating half the bytes we need, which was made more
obvious by a recent fix to the memset in  clear_tlb1_bitmap().

Signed-off-by: Scott Wood <scottwood@freescale.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
Cc: stable@vger.kernel.org
  • Loading branch information
Scott Wood authored and Alexander Graf committed Oct 5, 2012
1 parent 70bddfe commit e400e72
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/powerpc/kvm/e500_tlb.c
Original file line number Diff line number Diff line change
Expand Up @@ -1385,7 +1385,7 @@ int kvmppc_e500_tlb_init(struct kvmppc_vcpu_e500 *vcpu_e500)
if (!vcpu_e500->gtlb_priv[1])
goto err;

vcpu_e500->g2h_tlb1_map = kzalloc(sizeof(unsigned int) *
vcpu_e500->g2h_tlb1_map = kzalloc(sizeof(u64) *
vcpu_e500->gtlb_params[1].entries,
GFP_KERNEL);
if (!vcpu_e500->g2h_tlb1_map)
Expand Down

0 comments on commit e400e72

Please sign in to comment.