On 2017-05-27 20:46 Christian Zigotzky wrote:
Just for info
Mac-on-Linux/KVM PR works without any problems on my P.A. Semi PA6T PPC64 SMP
CPU.
Yes, the P.A. Semi PA6T is a 64-bit processor (PPC64), so that's why.
On my Power Mac G5, Motorola 7450 Dual 800 MHz, I only get the
/lib/modules/4.11.0/arch/powerpc/kvm/kvm.ko modules. The G4
(PPC7400/7410 as well as PPC7440/7450) is only a 32-bit processor
(PPC32). So that's why I cannot find a kvm-pr modules or such.
Relevant lines im my kernel .config:
root@G4QS:~# cat /boot/config-4.11.0 | grep KVM
CONFIG_KVM_GUEST=y
CONFIG_HAVE_KVM_EVENTFD=y
CONFIG_KVM_MMIO=y
CONFIG_KVM_VFIO=y
CONFIG_HAVE_KVM_IRQ_BYPASS=y
CONFIG_KVM=y
CONFIG_KVM_BOOK3S_HANDLER=y
CONFIG_KVM_BOOK3S_32_HANDLER=y
CONFIG_KVM_BOOK3S_PR_POSSIBLE=y
CONFIG_KVM_BOOK3S_32=m
This is a non-SMP kernel. When I want SMP, CONFIG_KVM is not available.
From the kernel config help:
> CONFIG_KVM_BOOK3S_32:
>
> Support running unmodified book3s_32 guest kernels
> in virtual machines on book3s_32 host processors.
>
> This module provides access to the hardware capabilities through
> a character device node named /dev/kvm.
>
> If unsure, say N.
>
> Symbol: KVM_BOOK3S_32 [=m]
> Type : tristate
> Prompt: KVM support for PowerPC book3s_32 processors
> Location:
> -> Virtualization (VIRTUALIZATION [=y])
> Defined at arch/powerpc/kvm/Kconfig:49
> Depends on: VIRTUALIZATION [=y] && PPC_BOOK3S_32 [=y] && !SMP [=n]
&& !PTE_64BIT [=n]
> Selects: KVM [=y] && KVM_BOOK3S_32_HANDLER [=y] &&
KVM_BOOK3S_PR_POSSIBLE [=y]
As you can see it says !SMP.
So now I looked for KVM-PM:
> Symbol: KVM_BOOK3S_64_PR [=n]
> Type : tristate
> Prompt: KVM support without using hypervisor mode in host
> Location:
> -> Virtualization (VIRTUALIZATION [=y])
> -> KVM support for PowerPC book3s_64 processors (KVM_BOOK3S_64
[=n])
> Defined at arch/powerpc/kvm/Kconfig:100
> Depends on: VIRTUALIZATION [=y] && KVM_BOOK3S_64 [=n]
> Selects: KVM_BOOK3S_PR_POSSIBLE [=y]
Interesting. As you can see, this is exclusively for 64-bit systems
(BOOK3S_64), not for 32-bit systems (BOOK3S_32).
What I do have is this:
> Symbol: KVM_BOOK3S_PR_POSSIBLE [=y]
> Type : boolean
> Defined at arch/powerpc/kvm/Kconfig:41
> Depends on: VIRTUALIZATION [=y]
> Selects: KVM_MMIO [=y] && MMU_NOTIFIER [=y]
> Selected by: KVM_BOOK3S_32 [=m] && VIRTUALIZATION [=y] &&
PPC_BOOK3S_32 [=y] && !SMP [=n] && !PTE_64BIT [=n] || KVM_BOOK3S_64 [=n]
&& VIRTUALIZATION [=y] && PPC_BOOK3S_64 [=n] && !KVM_BOOK3S_HV_POSSIBLE
[=n] || KVM_BOOK3S_64_PR [=n] && VIRTUALIZATION [=y] && KVM_BOOK3S_64 [=n]
But this doesn't help much... PPC32 just cannot have KVM-PR (yet)...
Cheers,
Linux User #330250