提交 e54adde6 编写于 作者: E Eduardo Habkost 提交者: Paolo Bonzini

accel: Create AccelType typedef

Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com>
Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
上级 a1a9cb0c
......@@ -40,13 +40,15 @@ static int tcg_init(MachineClass *mc)
return 0;
}
static struct {
typedef struct AccelType {
const char *opt_name;
const char *name;
int (*available)(void);
int (*init)(MachineClass *mc);
bool *allowed;
} accel_list[] = {
} AccelType;
static AccelType accel_list[] = {
{ "tcg", "tcg", tcg_available, tcg_init, &tcg_allowed },
{ "xen", "Xen", xen_available, xen_init, &xen_allowed },
{ "kvm", "KVM", kvm_available, kvm_init, &kvm_allowed },
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册