Skip to content

Commit

Permalink
KVM: PPC: e500: MMU API: fix leak of shared_tlb_pages
Browse files Browse the repository at this point in the history
This was found by kmemleak.

Signed-off-by: Scott Wood <scottwood@freescale.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
  • Loading branch information
Scott Wood authored and Alexander Graf committed Oct 5, 2012
1 parent e400e72 commit adbb48a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arch/powerpc/kvm/e500_tlb.c
Original file line number Diff line number Diff line change
Expand Up @@ -1134,6 +1134,8 @@ static void free_gtlb(struct kvmppc_vcpu_e500 *vcpu_e500)
}

vcpu_e500->num_shared_tlb_pages = 0;

kfree(vcpu_e500->shared_tlb_pages);
vcpu_e500->shared_tlb_pages = NULL;
} else {
kfree(vcpu_e500->gtlb_arch);
Expand Down

0 comments on commit adbb48a

Please sign in to comment.