Re: [Qemu-devel] [PATCH v2] Release usb devices on shutdown and usb_del command

2010-05-21 Thread Markus Armbruster
David S. Ahern daah...@cisco.com writes: On 05/19/2010 12:10 PM, Shahar Havivi wrote: When closig Vm or removing usb on guest via usb_del monitor command, qemu does not return the control to the host, the user have to unplug and plug the device in order to use it on the host. v2: added

Re: [Qemu-devel] [PATCH v2] Release usb devices on shutdown and usb_del command

2010-05-21 Thread Gerd Hoffmann
Hi, What about the existing callbacks? Could handle_destroy do? For hot-unplug it should do. --- a/vl.c +++ b/vl.c @@ -3914,6 +3914,7 @@ int main(int argc, char **argv, char **envp) main_loop(); quit_timers(); net_cleanup(); +usb_cleanup(); return 0; }

Re: [Qemu-devel] [PATCH v2] Release usb devices on shutdown and usb_del command

2010-05-21 Thread David S. Ahern
On 05/21/2010 1:33 AM, Markus Armbruster wrote: Note: usbdevice_init() is not for general initialization, just for dealing with the legacy -usbdevice command line. Perhaps the comment before usbdevice_create is misleading or has some conversion not completed? Right now even devices entered

Re: [Qemu-devel] [PATCH v2] Release usb devices on shutdown and usb_del command

2010-05-21 Thread Markus Armbruster
David S. Ahern daah...@cisco.com writes: On 05/21/2010 1:33 AM, Markus Armbruster wrote: Note: usbdevice_init() is not for general initialization, just for dealing with the legacy -usbdevice command line. Perhaps the comment before usbdevice_create is misleading or has some conversion not

[Qemu-devel] [PATCH v2] Release usb devices on shutdown and usb_del command

2010-05-19 Thread Shahar Havivi
When closig Vm or removing usb on guest via usb_del monitor command, qemu does not return the control to the host, the user have to unplug and plug the device in order to use it on the host. v2: added empty methods to usb-bsd and usb-stub. release usb devices when main is out. Signed-off-by:

Re: [Qemu-devel] [PATCH v2] Release usb devices on shutdown and usb_del command

2010-05-19 Thread David S. Ahern
On 05/19/2010 12:10 PM, Shahar Havivi wrote: When closig Vm or removing usb on guest via usb_del monitor command, qemu does not return the control to the host, the user have to unplug and plug the device in order to use it on the host. v2: added empty methods to usb-bsd and usb-stub.