Skip to contentSkip to conversation

usb: ftdi-elan: remove variable l

PATCH New Colin Ian King 1 participant 1 message Nov 11, 2022

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 usb: ftdi-elan: remove variable l

Variable l is just being accumulated and it's never used anywhere else. The variable and the addition are redundant so remove it.

---
 drivers/usb/misc/ftdi-elan.c | 2 --
 1 file changed, 2 deletions(-)
drivers/usb/misc/ftdi-elan.c +0 -2
index 33b35788bd0b..8ce191e3a4c0 100644
@@ -1624,7 +1624,6 @@ wait:if (ftdi->disconnected > 0) {
 			char data[30 *3 + 4];
 			char *d = data;
 			int m = (sizeof(data) - 1) / 3 - 1;
-			int l = 0;
 			struct u132_target *target = &ftdi->target[ed];
 			struct u132_command *command = &ftdi->command[
 				COMMAND_MASK & ftdi->command_next];
@@ -1647,7 +1646,6 @@ wait:if (ftdi->disconnected > 0) {
 				} else if (i++ < m) {
 					int w = sprintf(d, " %02X", *b++);
 					d += w;
-					l += w;
 				} else
 					d += sprintf(d, " ..");
 			}
Signature · 1 line
2.38.1