[media] cpia2_usb: drop bogus interface-release call

Message ID 20180307094936.9140-1-johan@kernel.org (mailing list archive)
State Accepted, archived
Delegated to: Hans Verkuil
Headers

Commit Message

Johan Hovold March 7, 2018, 9:49 a.m. UTC
  Drop bogus call to usb_driver_release_interface() from the disconnect()
callback. As the interface is already being unbound at this point,
usb_driver_release_interface() simply returns early.

Signed-off-by: Johan Hovold <johan@kernel.org>
---
 drivers/media/usb/cpia2/cpia2_usb.c | 3 ---
 1 file changed, 3 deletions(-)
  

Comments

Greg KH March 7, 2018, 2:57 p.m. UTC | #1
On Wed, Mar 07, 2018 at 10:49:36AM +0100, Johan Hovold wrote:
> Drop bogus call to usb_driver_release_interface() from the disconnect()
> callback. As the interface is already being unbound at this point,
> usb_driver_release_interface() simply returns early.
> 
> Signed-off-by: Johan Hovold <johan@kernel.org>

Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  

Patch

diff --git a/drivers/media/usb/cpia2/cpia2_usb.c b/drivers/media/usb/cpia2/cpia2_usb.c
index f3a1e5b1e57c..b51fc372ca25 100644
--- a/drivers/media/usb/cpia2/cpia2_usb.c
+++ b/drivers/media/usb/cpia2/cpia2_usb.c
@@ -910,9 +910,6 @@  static void cpia2_usb_disconnect(struct usb_interface *intf)
 		wake_up_interruptible(&cam->wq_stream);
 	}
 
-	DBG("Releasing interface\n");
-	usb_driver_release_interface(&cpia2_driver, intf);
-
 	LOG("CPiA2 camera disconnected.\n");
 }