Revision 35112e41 target-i386/cpu.c

b/target-i386/cpu.c
675 675
    env->cpuid_version |= ((value & 0xf) << 4) | ((value >> 4) << 16);
676 676
}
677 677

  
678
static void x86_cpuid_version_get_stepping(Object *obj, Visitor *v,
679
                                           void *opaque, const char *name,
680
                                           Error **errp)
681
{
682
    X86CPU *cpu = X86_CPU(obj);
683
    CPUX86State *env = &cpu->env;
684
    int64_t value;
685

  
686
    value = env->cpuid_version & 0xf;
687
    visit_type_int(v, &value, name, errp);
688
}
689

  
678 690
static void x86_cpuid_version_set_stepping(Object *obj, Visitor *v,
679 691
                                           void *opaque, const char *name,
680 692
                                           Error **errp)
......
1570 1582
                        x86_cpuid_version_get_model,
1571 1583
                        x86_cpuid_version_set_model, NULL, NULL, NULL);
1572 1584
    object_property_add(obj, "stepping", "int",
1573
                        NULL,
1585
                        x86_cpuid_version_get_stepping,
1574 1586
                        x86_cpuid_version_set_stepping, NULL, NULL, NULL);
1575 1587
    object_property_add_str(obj, "model-id",
1576 1588
                            NULL,

Also available in: Unified diff