The number of mce_banks needs to be multiplied by 4 in order to actually reference all of the entries. Signed-off-by: Dean Nelson <dnelson@xxxxxxxxxx> --- qemu-kvm-x86.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/qemu-kvm-x86.c b/qemu-kvm-x86.c index fd974b3..7fd82fb 100644 --- a/qemu-kvm-x86.c +++ b/qemu-kvm-x86.c @@ -975,7 +975,7 @@ void kvm_arch_load_regs(CPUState *env, int level) } else if (level == KVM_PUT_FULL_STATE) { kvm_msr_entry_set(&msrs[n++], MSR_MCG_STATUS, env->mcg_status); kvm_msr_entry_set(&msrs[n++], MSR_MCG_CTL, env->mcg_ctl); - for (i = 0; i < (env->mcg_cap & 0xff); i++) { + for (i = 0; i < (env->mcg_cap & 0xff) * 4; i++) { kvm_msr_entry_set(&msrs[n++], MSR_MC0_CTL + i, env->mce_banks[i]); } } -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html