~dannf/qemu-linaro/qemu-highbank-ppa

« back to all changes in this revision

Viewing changes to hw/sga.c

  • Committer: Steve Langasek
  • Date: 2012-03-15 21:13:19 UTC
  • mfrom: (0.1.15)
  • Revision ID: steve.langasek@canonical.com-20120315211319-f1j3ot1ihx30b2s9
New upstream release

Show diffs side-by-side

added added

removed removed

Lines of Context:
42
42
}
43
43
static void sga_class_initfn(ObjectClass *klass, void *data)
44
44
{
 
45
    DeviceClass *dc = DEVICE_CLASS(klass);
45
46
    ISADeviceClass *ic = ISA_DEVICE_CLASS(klass);
46
47
    ic->init = sga_initfn;
 
48
    dc->desc = "Serial Graphics Adapter";
47
49
}
48
50
 
49
 
static DeviceInfo sga_info = {
50
 
    .name    = "sga",
51
 
    .desc    = "Serial Graphics Adapter",
52
 
    .size    = sizeof(ISASGAState),
53
 
    .class_init         = sga_class_initfn,
 
51
static TypeInfo sga_info = {
 
52
    .name          = "sga",
 
53
    .parent        = TYPE_ISA_DEVICE,
 
54
    .instance_size = sizeof(ISASGAState),
 
55
    .class_init    = sga_class_initfn,
54
56
};
55
57
 
56
 
static void sga_register(void)
 
58
static void sga_register_types(void)
57
59
{
58
 
      isa_qdev_register(&sga_info);
 
60
    type_register_static(&sga_info);
59
61
}
60
62
 
61
 
device_init(sga_register);
 
63
type_init(sga_register_types)