Skip to contentSkip to conversation

Input: elo - fix style issues

PATCH In review Josh Law 2 participants 3 messages Feb 28 – Mar 2

Subsystems (2)
lore
Share & tools
lore

Josh Law

author
#0 lore raw

PATCH v2 1/4 Input: elo - fix style issues

Fix array constness and spacing issues reported by checkpatch.

---
 drivers/input/touchscreen/elo.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/input/touchscreen/elo.c +2 -2
index 434b9b47e964..40ae132cde21 100644
@@ -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
maintainer
#1 lore raw

Hi Josh,

Quoted 3 lines · Josh Law

Fix array constness and spacing issues reported by checkpatch.

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
index 434b9b47e964..40ae132cde21 100644
@@ -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
author
#2 lore raw

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.

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
index 434b9b47e964..40ae132cde21 100644
@@ -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 -0
     return 0;

Thanks.

--
Dmitry

Sorry, because my main email can't send emails and I prefer to use my objecting.org email

V/R