qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 7/7] hw/pci: convert PCI bus to use "hotplug-dev


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH 7/7] hw/pci: convert PCI bus to use "hotplug-device" interface.
Date: Mon, 09 Dec 2013 15:36:35 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130923 Thunderbird/17.0.9

Il 09/12/2013 15:14, Igor Mammedov ha scritto:
>> > 
>> > Makes sense.  realize() for the "plug" handler, and qdev_unplug for the
>> > unplug handler, I guess.
> Just to be sure, I've meant not DEVICE.realize() but each device specific
> one.

If it's each specific device, then why should the hotplug handler link
be in DeviceState?

I think it should be in device_set_realized.

> qdev_unplug() might work for now, but I haven't checked all devices that
> might use interface and if it would break anything. Ideally it should be
> in device's unrealize() complementing realize() part.
> 
> I'd wait till all buses converted to new interface before attempting to
> generalize current plug/unplug call pathes though.

I agree that adding a default behavior for no link probably requires
conversion of all buses.  However, looking for the link in the generic
code can be done now.

Paolo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]