aboutsummaryrefslogtreecommitdiff
path: root/usb-linux.c
diff options
context:
space:
mode:
authorShahar Havivi <shaharh@redhat.com>2010-06-16 15:15:37 +0300
committerAurelien Jarno <aurelien@aurel32.net>2010-06-30 22:51:09 +0200
commit00ff227a328f02cdb0913c51bc46457c50351c79 (patch)
tree03d1cbd31fab0204480a15cc1419b2b912c95881 /usb-linux.c
parent03c71553ad735068e2bf166e629026fc78dbb4b9 (diff)
Return usb device to host on usb_del command
Signed-off-by: Shahar Havivi <shaharh@redhat.com> Acked-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Diffstat (limited to 'usb-linux.c')
-rw-r--r--usb-linux.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/usb-linux.c b/usb-linux.c
index 88273ff479..22a85e3101 100644
--- a/usb-linux.c
+++ b/usb-linux.c
@@ -991,6 +991,7 @@ static int usb_host_close(USBHostDevice *dev)
async_complete(dev);
dev->closing = 0;
usb_device_detach(&dev->dev);
+ ioctl(dev->fd, USBDEVFS_RESET);
close(dev->fd);
dev->fd = -1;
return 0;