From dcd82cd1c249fb85bad3da5d2a07a116cd65a22b Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Wed, 16 May 2012 08:37:17 -0700 Subject: [PATCH] USB: serial: fix up reset_resume callback If the usb-serial driver doesn't have a reset_resume callback, then we need to tell the USB core that it doesn't, and it needs to rebind the device. Thanks to Alan for pointing out my mistake, and providing the fix. Reported-by: Alan Stern Signed-off-by: Greg Kroah-Hartman --- drivers/usb/serial/usb-serial.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/usb/serial/usb-serial.c b/drivers/usb/serial/usb-serial.c index 846506f..6a1b609 100644 --- a/drivers/usb/serial/usb-serial.c +++ b/drivers/usb/serial/usb-serial.c @@ -1176,8 +1176,10 @@ static int usb_serial_reset_resume(struct usb_interface *intf) serial->suspending = 0; if (serial->type->reset_resume) rv = serial->type->reset_resume(serial); - else - rv = usb_serial_generic_resume(serial); + else { + rv = -EOPNOTSUPP; + intf->needs_binding = 1; + } return rv; } -- 2.7.4