Skip to contentSkip to conversation

staging: speakup: main: Fix line over 80 characters warning

PATCH In review Gamze POLAT 2 participants 2 messages Feb 19, 2015 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: speakup: main: Fix line over 80 characters warning

WARNING:line over 80 characters and simple_strtoul is obsolete, use kstrtoul instead
checkpatch.pl warning

---
 drivers/staging/speakup/main.c | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)
drivers/staging/speakup/main.c +7 -4
index e9f0c15..fde26b3 100644
@@ -423,7 +423,8 @@ static void announce_edge(struct vc_data *vc, int msg_id)
 	if (spk_bleeps & 1)
 		bleep(spk_y);
 	if ((spk_bleeps & 2) && (msg_id < edge_quiet))
-		synth_printf("%s\n", spk_msg_get(MSG_EDGE_MSGS_START + msg_id - 1));
+		synth_printf("%s\n", spk_msg_get(MSG_EDGE_MSGS_START + msg_id
+					- 1));
 }
 
 static void speak_char(u_char ch)
@@ -1131,7 +1132,8 @@ static void spkup_write(const char *in_buf, int count)
 	if (in_count > 2 && rep_count > 2) {
 		if (last_type & CH_RPT) {
 			synth_printf(" ");
-			synth_printf(spk_msg_get(MSG_REPEAT_DESC2), ++rep_count);
+			synth_printf(spk_msg_get(MSG_REPEAT_DESC2), ++rep_count
+					);
 			synth_printf(" ");
 		}
 		rep_count = 0;
@@ -1847,7 +1849,8 @@ static void speakup_win_set(struct vc_data *vc)
 			win_right = spk_x;
 		}
 		snprintf(info, sizeof(info), spk_msg_get(MSG_WINDOW_BOUNDARY),
-			 (win_start) ? spk_msg_get(MSG_END) : spk_msg_get(MSG_START),
+			 (win_start) ? spk_msg_get(MSG_END) : spk_msg_get(MSG_S
+				 TART),
 			 (int)spk_y + 1, (int)spk_x + 1);
 	}
 	synth_printf("%s\n", info);
@@ -1930,7 +1933,7 @@ oops:
 		return 1;
 	}
 
-	goto_pos = simple_strtoul(goto_buf, &cp, 10);
+	goto_pos = simple_kstrtoul(goto_buf, &cp, 10);
 
 	if (*cp == 'x') {
 		if (*goto_buf < '0')
Signature · 1 line
2.1.0
#1 lore raw
Quoted 3 lines · Gamze POLAT

WARNING:line over 80 characters and simple_strtoul is obsolete, use kstrtoul instead
checkpatch.pl warning

These are very different issues. Fixing a line over 80 characters problem is easy, while the kstrtoul issue requires careful analysis of the behavior of the code (you can see a patch from Navya earlier today about this). So they should be in different patches.

drivers/staging/speakup/main.c oops: · line 1936

Quoted 6 lines
drivers/staging/speakup/main.c +1 -1
@@ -1930,7 +1933,7 @@ oops:
 		return 1;
 	}
 
-	goto_pos = simple_strtoul(goto_buf, &cp, 10);
+	goto_pos = simple_kstrtoul(goto_buf, &cp, 10);

There is no such function as simple_kstrtoul. This suggests that you did not compile your kernel before submitting your patch., or at least that when you compiled the kernel, you did not compile this file. Check if you have a file ending in .o that corresponds to this .c file. If not, then you didn't actually compile this one. It may be helpful to try make and then the pathname of the file with .c replaced by .o.

julia