Skip to contentSkip to conversation

usb: ftdi-elan: fix possible condition with no effect (if == else)

PATCH New Hariprasad Kelam 1 participant 1 message May 25, 2019 USB

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 usb: ftdi-elan: fix possible condition with no effect (if == else)

fix below warning reported by coccicheck

./drivers/usb/misc/ftdi-elan.c:2026:11-13: WARNING: possible condition with no effect (if == else)

---
 drivers/usb/misc/ftdi-elan.c | 7 -------
 1 file changed, 7 deletions(-)
drivers/usb/misc/ftdi-elan.c +0 -7
index 257efac..cdee3af 100644
@@ -2023,13 +2023,6 @@ static int ftdi_elan_synchronize(struct usb_ftdi *ftdi)
 						goto read;
 					} else
 						goto reset;
-				} else if (s1 == 0x31 && s2 == 0x60) {
-					if (read_stop-- > 0) {
-						goto read;
-					} else {
-						dev_err(&ftdi->udev->dev, "retry limit reached\n");
-						continue;
-					}
 				} else {
 					if (read_stop-- > 0) {
 						goto read;
Signature · 1 line
2.7.4