Re: [RFT] Fix for unhandled msr c0000081 problems under Intel cpus

Avi Kivity
2006-12-14T09:22:44Z

Michael Riepe wrote:
> Oh well...
>
> I was wondering which stupid piece of sh^H^Hcode generated so many wrong
> rdmsr instructions without looking at the CPU feature flags. So I
> grepped through the linux kernel and glibc sources as well as some other
> likely suspects and found - nothing.
>
> Guess what? It's qemu!
>
> In qemu-kvm.c (around line 329 in save_regs()) it starts to call
> kvm_get_msrs(), and one of the MSRs it wants to read is MSR_STAR. When I
> removed MSR_STAR from the list (which fortunately has no consequences on
> my Core Duo), the messages were gone.
>

Yes, you're right.

I'll commit the previous patch (which is correct, even if no guest
actually uses syscall), and teach qemu not to read MSR_STAR when it
isn't available.

--
error compiling committee.c: too many arguments to function