mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 09:43:56 -06:00
usb: hook unplug into qdev, cleanups + fixes.
Hook into DeviceInfo->exit(). handle_destroy() must not free the state struct, this is handled by the new usb_qdev_exit() function now. qdev_free(usb_device) works now. Fix usb hub to qdev_free() all connected devices on unplug. Unplugging a usb hub works now. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
e3936fa574
commit
a8e662b547
8 changed files with 56 additions and 15 deletions
|
@ -389,7 +389,6 @@ static void usb_wacom_handle_destroy(USBDevice *dev)
|
|||
USBWacomState *s = (USBWacomState *) dev;
|
||||
|
||||
qemu_remove_mouse_event_handler(s->eh_entry);
|
||||
qemu_free(s);
|
||||
}
|
||||
|
||||
static int usb_wacom_initfn(USBDevice *dev)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue