On Tue, Jun 27, 2017 at 12:10:13PM +0800, Peter Xu wrote: [...] > + > +static const TypeInfo migration_type = { > + .name = TYPE_MIGRATION, > + .parent = TYPE_DEVICE,
As TYPE_MIGRATION isn't really a device and we're using TYPE_DEVICE just to reuse the global property system, maybe we should add a comment here explaining that? It would also be interesting to explain the TYPE_DEVICE features we do not use. e.g.: the device is not created using qdev_create(), it is never attached to any bus, and it is never realized. (But I don't think this should require a series respin. The comment may be sent as a follow-up patch.) > + .class_init = migration_class_init, > + .class_size = sizeof(MigrationClass), > + .instance_size = sizeof(MigrationState), > + .instance_init = migration_instance_init, > +}; > + [...] -- Eduardo