From: Colin Ian King Date: Tue, 7 Nov 2017 11:45:27 +0000 (+0000) Subject: USB: adutux: remove redundant variable minor X-Git-Tag: v3.16.79~10 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=669ddcc72d26dc8a6e8df7b4d1f0fa896b9748d2;p=thirdparty%2Fkernel%2Fstable.git USB: adutux: remove redundant variable minor commit 8444efc4a052332d643ed5c8aebcca148c7de032 upstream. Variable minor is being assigned but never read, hence it is redundant and can be removed. Cleans up clang warning: drivers/usb/misc/adutux.c:770:2: warning: Value stored to 'minor' is never read Signed-off-by: Colin Ian King Signed-off-by: Greg Kroah-Hartman [bwh: Backported to 3.16 so that commit 44efc269db79 "USB: adutux: fix use-after-free on disconnect" applies cleanly] Signed-off-by: Ben Hutchings --- diff --git a/drivers/usb/misc/adutux.c b/drivers/usb/misc/adutux.c index 5cfaf69bc62f8..f6f7372dd2fb1 100644 --- a/drivers/usb/misc/adutux.c +++ b/drivers/usb/misc/adutux.c @@ -796,13 +796,11 @@ error: static void adu_disconnect(struct usb_interface *interface) { struct adu_device *dev; - int minor; dev = usb_get_intfdata(interface); mutex_lock(&dev->mtx); /* not interruptible */ dev->udev = NULL; /* poison */ - minor = dev->minor; usb_deregister_dev(interface, &adu_class); mutex_unlock(&dev->mtx);