Re: [PATCH -v3] KVM: MCE: Add MCE support to KVM

2009-05-26 Thread Avi Kivity
Jan Kiszka wrote: Well, if I look at the definition of MCI_STATUS_VAL as (1UL<<63), something tells me: "Hey, only use me on 64-bit hosts!" But I have no clue about details of this stuff, and from a second glance at it is seems to include at least some parts that are valid on 32-bit as well.

Re: [PATCH -v3] KVM: MCE: Add MCE support to KVM

2009-05-25 Thread Jan Kiszka
Jan Kiszka wrote: > Avi Kivity wrote: >> Jan Kiszka wrote: >>> Avi Kivity wrote: >>> Huang Ying wrote: > The related MSRs are emulated. MCE capability is exported via > extension KVM_CAP_MCE and ioctl KVM_X86_GET_MCE_CAP_SUPPORTED. A new > vcpu ioctl command KVM_X86_SET

Re: [PATCH -v3] KVM: MCE: Add MCE support to KVM

2009-05-25 Thread Jan Kiszka
Avi Kivity wrote: > Jan Kiszka wrote: >> Avi Kivity wrote: >> >>> Huang Ying wrote: >>> The related MSRs are emulated. MCE capability is exported via extension KVM_CAP_MCE and ioctl KVM_X86_GET_MCE_CAP_SUPPORTED. A new vcpu ioctl command KVM_X86_SETUP_MCE is used to setup MCE

Re: [PATCH -v3] KVM: MCE: Add MCE support to KVM

2009-05-25 Thread Avi Kivity
Jan Kiszka wrote: Avi Kivity wrote: Huang Ying wrote: The related MSRs are emulated. MCE capability is exported via extension KVM_CAP_MCE and ioctl KVM_X86_GET_MCE_CAP_SUPPORTED. A new vcpu ioctl command KVM_X86_SETUP_MCE is used to setup MCE emulation such as the mcg_cap. MCE is injec

Re: [PATCH -v3] KVM: MCE: Add MCE support to KVM

2009-05-25 Thread Jan Kiszka
Avi Kivity wrote: > Huang Ying wrote: >> The related MSRs are emulated. MCE capability is exported via >> extension KVM_CAP_MCE and ioctl KVM_X86_GET_MCE_CAP_SUPPORTED. A new >> vcpu ioctl command KVM_X86_SETUP_MCE is used to setup MCE emulation >> such as the mcg_cap. MCE is injected via vcpu ioc

Re: [PATCH -v3] KVM: MCE: Add MCE support to KVM

2009-05-17 Thread Avi Kivity
Huang Ying wrote: The related MSRs are emulated. MCE capability is exported via extension KVM_CAP_MCE and ioctl KVM_X86_GET_MCE_CAP_SUPPORTED. A new vcpu ioctl command KVM_X86_SETUP_MCE is used to setup MCE emulation such as the mcg_cap. MCE is injected via vcpu ioctl command KVM_X86_SET_MCE. Ex

Re: [PATCH -v3] KVM: MCE: Add MCE support to KVM

2009-05-11 Thread Huang Ying
On Mon, 2009-05-11 at 17:05 +0800, Jaswinder Singh Rajput wrote: > On Mon, 2009-05-11 at 16:48 +0800, Huang Ying wrote: > > +int kvm_get_msr_common(struct kvm_vcpu *vcpu, u32 msr, u64 *pdata) > > +{ > > + u64 data; > > + > > + switch (msr) { > > + case 0xc0010010: /* SYSCFG */ > > + case 0x

Re: [PATCH -v3] KVM: MCE: Add MCE support to KVM

2009-05-11 Thread Jaswinder Singh Rajput
On Mon, 2009-05-11 at 16:48 +0800, Huang Ying wrote: > +int kvm_get_msr_common(struct kvm_vcpu *vcpu, u32 msr, u64 *pdata) > +{ > + u64 data; > + > + switch (msr) { > + case 0xc0010010: /* SYSCFG */ > + case 0xc0010015: /* HWCR */ You can replace this with : + case MSR_K8_SY

[PATCH -v3] KVM: MCE: Add MCE support to KVM

2009-05-11 Thread Huang Ying
The related MSRs are emulated. MCE capability is exported via extension KVM_CAP_MCE and ioctl KVM_X86_GET_MCE_CAP_SUPPORTED. A new vcpu ioctl command KVM_X86_SETUP_MCE is used to setup MCE emulation such as the mcg_cap. MCE is injected via vcpu ioctl command KVM_X86_SET_MCE. Extended machine-check

[PATCH -v3] KVM: MCE: Add MCE support to KVM

2009-05-03 Thread Huang Ying
The related MSRs are emulated. MCE capability is exported via extension KVM_CAP_MCE and ioctl KVM_X86_GET_MCE_CAP_SUPPORTED. A new vcpu ioctl command KVM_X86_SETUP_MCE is used to setup MCE emulation such as the mcg_cap. MCE is injected via vcpu ioctl command KVM_X86_SET_MCE. Extended machine-check