Re: [PATCH] SVM: forbid guest to execute monitor/mwait

Avi Kivity
2007-03-22T07:38:12Z

Joerg Roedel wrote:
> From: Joerg Roedel <joerg.roedel-5C7GfCeVMHo@public.gmane.org>
>
> This patch forbids the guest to execute monitor/mwait instructions on
> SVM. This is necessary because the guest can execute these instructions
> if they are available even if the kvm cpuid doesn't report its
> existence.
>
>

You're intercepting the instructions unconditionally. What about the
case where cpuid does report monitor/mwait support? The guest can
legitimately use them then.

--
Do not meddle in the internals of kernels, for they are subtle and quick to panic.