powerpc/kvm: Fix VSID usage in 64-bit "PR" KVM
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Fri, 23 Mar 2012 00:21:14 +0000 (11:21 +1100)
committerAlexander Graf <agraf@suse.de>
Wed, 16 May 2012 13:02:11 +0000 (15:02 +0200)
commitffe3649282946547f1b938e02c0228aead407a18
treebc95604d39cdefb135adc60c03fabffda4557604
parent32c7dbfd479e73684b0d23fcb0a5cb04f19d86f4
powerpc/kvm: Fix VSID usage in 64-bit "PR" KVM

The code forgot to scramble the VSIDs the way we normally do
and was basically using the "proto VSID" directly with the MMU.

This means that in practice, KVM used random VSIDs that could
collide with segments used by other user space programs.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
[agraf: simplify ppc32 case]
Signed-off-by: Alexander Graf <agraf@suse.de>
arch/powerpc/include/asm/kvm_book3s.h
arch/powerpc/kvm/book3s_64_mmu_host.c