usb-storage: Remove redundant assignments
authorluo penghao <luo.penghao@zte.com.cn>
Thu, 30 Dec 2021 06:38:19 +0000 (06:38 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 30 Dec 2021 11:10:17 +0000 (12:10 +0100)
The assignments in these two places will be overwritten, so they
should be deleted.

The clang_analyzer complains as follows:

drivers/usb/storage/sierra_ms.c:

Value stored to 'retries' is never read
Value stored to 'result' is never read

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: luo penghao <luo.penghao@zte.com.cn>
Link: https://lore.kernel.org/r/20211230063819.586428-1-luo.penghao@zte.com.cn
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/storage/sierra_ms.c

index b9f78ef..0774ba2 100644 (file)
@@ -130,8 +130,6 @@ int sierra_ms_init(struct us_data *us)
        struct swoc_info *swocInfo;
        struct usb_device *udev;
 
-       retries = 3;
-       result = 0;
        udev = us->pusb_dev;
 
        /* Force Modem mode */