Input: elo - fix style issues
Subsystems (2)
PATCH v2 1/4 Input: elo - fix style issues
Fix array constness and spacing issues reported by checkpatch.
Signed-off-by Josh Law <[email protected]>
--- drivers/input/touchscreen/elo.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/input/touchscreen/elo.c +2 -2
@@ -257,7 +257,7 @@ static int elo_command_10(struct elo *elo, unsigned char *packet)static int elo_setup_10 (struct elo *elo) { -static const char *elo_types[] = {"Accu" ,"Dura" ,"Intelli" ,"Carroll" }; +static const char *const elo_types[] = {"Accu" ,"Dura" ,"Intelli" ,"Carroll" };struct input_dev *dev = elo->dev;unsigned char packet[ELO10_PACKET_LEN ] = {ELO10_ID_CMD };
@@ -273,7 +273,7 @@ static int elo_setup_10(struct elo *elo)dev_info (&elo->serio->dev,"%sTouch touchscreen, fw: %02x.%02x, features: 0x%02x, controller: 0x%02x\n" , - elo_types[(packet[1 ] -'0' ) &0x03 ], + elo_types[(packet[1 ] -'0' ) &0x03 ], packet[5 ], packet[4 ], packet[3 ], packet[7 ]);return 0 ;
Signature · 1 line
2.43.0
Dmitry Torokhov
maintainerHi Josh,
Quoted 3 lines · Josh Law
Fix array constness and spacing issues reported by checkpatch.
Signed-off-by Josh Law <[email protected]>
Why the difference between From: and Signed-off-by?
Quoted 18 lines
--- drivers/input/touchscreen/elo.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)drivers/input/touchscreen/elo.c +1
-1@@ -257,7 +257,7 @@ static int elo_command_10(struct elo *elo, unsigned char *packet)static int elo_setup_10 (struct elo *elo) { -static const char *elo_types[] = {"Accu" ,"Dura" ,"Intelli" ,"Carroll" }; +static const char *const elo_types[] = {"Accu" ,"Dura" ,"Intelli" ,"Carroll" };struct input_dev *dev = elo->dev;unsigned char packet[ELO10_PACKET_LEN ] = {ELO10_ID_CMD };
drivers/input/touchscreen/elo.c static int elo_setup_10(struct elo *elo) · line 279
Quoted 8 lines
drivers/input/touchscreen/elo.c +1
-1@@ -273,7 +273,7 @@ static int elo_setup_10(struct elo *elo)dev_info (&elo->serio->dev,"%sTouch touchscreen, fw: %02x.%02x, features: 0x%02x, controller: 0x%02x\n" , - elo_types[(packet[1 ] -'0' ) &0x03 ], + elo_types[(packet[1 ] -'0' ) &0x03 ], packet[5 ], packet[4 ], packet[3 ], packet[7 ]);return 0 ;
Thanks.
Signature · 1 line
Dmitry
2 Mar 2026 00:25:16 Dmitry Torokhov <[email protected]>:
Quoted 34 lines
Hi Josh,
Quoted 3 lines · Josh Law
Fix array constness and spacing issues reported by checkpatch.
Signed-off-by Josh Law <[email protected]>Why the difference between From: and Signed-off-by?
Quoted 25 lines
---
drivers/input/touchscreen/elo.c| 4 ++--1 file changed, 2 insertions(+), 2 deletions(-)drivers/input/touchscreen/elo.c +2
-2@@ -257,7 +257,7 @@ static int elo_command_10(struct elo *elo, unsigned char *packet)static int elo_setup_10 (struct elo *elo) { - static const char *elo_types[] = { "Accu", "Dura", "Intelli", "Carroll" }; + static const char * const elo_types[] = { "Accu", "Dura", "Intelli", "Carroll" }; struct input_dev *dev = elo->dev; unsigned char packet[ELO10_PACKET_LEN] = { ELO10_ID_CMD };@@ -273,7 +273,7 @@ static int elo_setup_10(struct elo *elo) dev_info(&elo->serio->dev, "%sTouch touchscreen, fw: %02x.%02x, features: 0x%02x, controller: 0x%02x\n", - elo_types[(packet[1] -'0') & 0x03], + elo_types[(packet[1] - '0') & 0x03], packet[5], packet[4], packet[3], packet[7]);
Quoted 6 lines
drivers/input/touchscreen/elo.c static int elo_setup_10(struct elo *elo) · line 279
Quoted 1 line
drivers/input/touchscreen/elo.c +0
-0return 0;Thanks.
--
Dmitry
Sorry, because my main email can't send emails and I prefer to use my objecting.org email
V/R