On Wed, 18 Apr 2018 11:56:03 -0300
Eduardo Habkost <ehabk...@redhat.com> wrote:

> On Wed, Apr 18, 2018 at 04:28:03PM +0200, Igor Mammedov wrote:
> > By default MachineClass::get_hotplug_handler is NULL and concrete board
> > should set it to it's own handler.
> > Considering there isn't any default handler, drop saving empty
> > MachineClass::get_hotplug_handler in child class and make PC code
> > consistent with spapr/s390x boards.
> > 
> > We can bring this back when actual usecase surfaces and do it
> > consistently across boards that use get_hotplug_handler().
> > 
> > Suggested-by: David Gibson <da...@gibson.dropbear.id.au>
> > Signed-off-by: Igor Mammedov <imamm...@redhat.com>  
> 
> Reviewed-by: Eduardo Habkost <ehabk...@redhat.com>
> 
> 
> [...]
> > @@ -2344,7 +2341,6 @@ static void pc_machine_class_init(ObjectClass *oc, 
> > void *data)
> >      HotplugHandlerClass *hc = HOTPLUG_HANDLER_CLASS(oc);
> >      NMIClass *nc = NMI_CLASS(oc);
> >  
> > -    pcmc->get_hotplug_handler = mc->get_hotplug_handler;  
> 
> What about assert(!mc->get_hotplug_handler) just before
> overwriting it?
I'll make it patch on top of series to make sure that
every board that sets get_hotplug_handler will do it
consistently.


Reply via email to