* [PATCH] staging: speakup: Replace simple_strtoul with kstrtoul
@ 2018-03-08 19:49 Nishka Dasgupta
2018-03-08 19:53 ` Samuel Thibault
0 siblings, 1 reply; 7+ messages in thread
From: Nishka Dasgupta @ 2018-03-08 19:49 UTC (permalink / raw)
To: gregkh, w.d.hubbs, chris, kirk, samuel.thibault, outreachy-kernel
Cc: Nishka Dasgupta
Replace simple_strtoul with kstrtoul. Issue found with checkpatch.
Signed-off-by: Nishka Dasgupta <nishka.dasgupta_ug18@ashoka.edu.in>
---
drivers/staging/speakup/varhandlers.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/staging/speakup/varhandlers.c b/drivers/staging/speakup/varhandlers.c
index 3214055..e27bd5c 100644
--- a/drivers/staging/speakup/varhandlers.c
+++ b/drivers/staging/speakup/varhandlers.c
@@ -327,8 +327,9 @@ char *spk_strlwr(char *s)
char *spk_s2uchar(char *start, char *dest)
{
int val;
+ unsigned long v = 0;
- val = simple_strtoul(skip_spaces(start), &start, 10);
+ val = kstrtoul(skip_spaces(start), 10, &v);
if (*start == ',')
start++;
*dest = (u_char)val;
--
1.9.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] staging: speakup: Replace simple_strtoul with kstrtoul
2018-03-08 19:49 [PATCH] staging: speakup: Replace simple_strtoul with kstrtoul Nishka Dasgupta
@ 2018-03-08 19:53 ` Samuel Thibault
2018-03-08 20:03 ` [PATCH] staging: speakup: Replace simple_strtoul with Nishka Dasgupta
0 siblings, 1 reply; 7+ messages in thread
From: Samuel Thibault @ 2018-03-08 19:53 UTC (permalink / raw)
To: Nishka Dasgupta; +Cc: gregkh, w.d.hubbs, chris, kirk, outreachy-kernel
Nishka Dasgupta, on ven. 09 mars 2018 01:19:12 +0530, wrote:
> Replace simple_strtoul with kstrtoul. Issue found with checkpatch.
Again, they are not the same, we need start to be updated.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] staging: speakup: Replace simple_strtoul with
2018-03-08 19:53 ` Samuel Thibault
@ 2018-03-08 20:03 ` Nishka Dasgupta
2018-03-08 20:48 ` Samuel Thibault
0 siblings, 1 reply; 7+ messages in thread
From: Nishka Dasgupta @ 2018-03-08 20:03 UTC (permalink / raw)
To: samuel.thibault; +Cc: gregkh, w.d.hubbs, chris, kirk, outreachy-kernel
>Nishka Dasgupta, on ven. 09 mars 2018 01:19:12 +0530 wrote:
>>Replace simple_strtoul with kstrtoul. Issue found with checkpatch.
>
>Again, they are not the same, we need start to be updated.
>
>Samuel
I am so sorry for sending the same buggy fix multiple times. Thank you
for the clarification. I will avoid kstrtoul warnings in future.
While we are on the topic of speakup, should I also stay clear of the
checkpatch warnings in keyhelp.c:102 and keyhelp.c:743 to add a
KERN_<LEVEL> signifier in the printk() commands on those lines?
Thank you for your time.
Regards,
Nishka Dasgupta
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] staging: speakup: Replace simple_strtoul with
2018-03-08 20:03 ` [PATCH] staging: speakup: Replace simple_strtoul with Nishka Dasgupta
@ 2018-03-08 20:48 ` Samuel Thibault
2018-03-08 21:15 ` Nishka Dasgupta
0 siblings, 1 reply; 7+ messages in thread
From: Samuel Thibault @ 2018-03-08 20:48 UTC (permalink / raw)
To: Nishka Dasgupta; +Cc: gregkh, w.d.hubbs, chris, kirk, outreachy-kernel
Nishka Dasgupta, on ven. 09 mars 2018 01:33:45 +0530, wrote:
> While we are on the topic of speakup, should I also stay clear of the
> checkpatch warnings in keyhelp.c:102 and keyhelp.c:743 to add a
> KERN_<LEVEL> signifier in the printk() commands on those lines?
That should be fine.
Samuel
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] staging: speakup: Replace simple_strtoul with
2018-03-08 20:48 ` Samuel Thibault
@ 2018-03-08 21:15 ` Nishka Dasgupta
2018-03-08 21:16 ` Samuel Thibault
2018-03-08 21:19 ` [Outreachy kernel] " Julia Lawall
0 siblings, 2 replies; 7+ messages in thread
From: Nishka Dasgupta @ 2018-03-08 21:15 UTC (permalink / raw)
To: Samuel Thibault
Cc: outreachy-kernel, gregkh, William Hubbs, Christopher Brannon, kirk
On Fri, Mar 9, 2018 at 2:18 AM, Samuel Thibault
<samuel.thibault@ens-lyon.org> wrote:
> Nishka Dasgupta, on ven. 09 mars 2018 01:33:45 +0530, wrote:
>> While we are on the topic of speakup, should I also stay clear of the
>> checkpatch warnings in keyhelp.c:102 and keyhelp.c:743 to add a
>> KERN_<LEVEL> signifier in the printk() commands on those lines?
>
> That should be fine.
What Kernel message should I include within the printk statements, if
any? KERN_DEBUG,
KERN_EMERG, KERN_ALERT, KERN_CRIT, KERN_ERR, KERN_WARNING, KERN_NOTICE,
or KERN_INFO?
Thanking you,
Nishka Dasgupta
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] staging: speakup: Replace simple_strtoul with
2018-03-08 21:15 ` Nishka Dasgupta
@ 2018-03-08 21:16 ` Samuel Thibault
2018-03-08 21:19 ` [Outreachy kernel] " Julia Lawall
1 sibling, 0 replies; 7+ messages in thread
From: Samuel Thibault @ 2018-03-08 21:16 UTC (permalink / raw)
To: Nishka Dasgupta
Cc: outreachy-kernel, gregkh, William Hubbs, Christopher Brannon, kirk
Nishka Dasgupta, on ven. 09 mars 2018 02:45:18 +0530, wrote:
> On Fri, Mar 9, 2018 at 2:18 AM, Samuel Thibault
> <samuel.thibault@ens-lyon.org> wrote:
> > Nishka Dasgupta, on ven. 09 mars 2018 01:33:45 +0530, wrote:
> >> While we are on the topic of speakup, should I also stay clear of the
> >> checkpatch warnings in keyhelp.c:102 and keyhelp.c:743 to add a
> >> KERN_<LEVEL> signifier in the printk() commands on those lines?
> >
> > That should be fine.
>
> What Kernel message should I include within the printk statements, if
> any? KERN_DEBUG,
> KERN_EMERG, KERN_ALERT, KERN_CRIT, KERN_ERR, KERN_WARNING, KERN_NOTICE,
> or KERN_INFO?
That depends on the message.
Samuel
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Outreachy kernel] Re: [PATCH] staging: speakup: Replace simple_strtoul with
2018-03-08 21:15 ` Nishka Dasgupta
2018-03-08 21:16 ` Samuel Thibault
@ 2018-03-08 21:19 ` Julia Lawall
1 sibling, 0 replies; 7+ messages in thread
From: Julia Lawall @ 2018-03-08 21:19 UTC (permalink / raw)
To: Nishka Dasgupta
Cc: Samuel Thibault, outreachy-kernel, gregkh, William Hubbs,
Christopher Brannon, kirk
On Fri, 9 Mar 2018, Nishka Dasgupta wrote:
> On Fri, Mar 9, 2018 at 2:18 AM, Samuel Thibault
> <samuel.thibault@ens-lyon.org> wrote:
> > Nishka Dasgupta, on ven. 09 mars 2018 01:33:45 +0530, wrote:
> >> While we are on the topic of speakup, should I also stay clear of the
> >> checkpatch warnings in keyhelp.c:102 and keyhelp.c:743 to add a
> >> KERN_<LEVEL> signifier in the printk() commands on those lines?
> >
> > That should be fine.
>
> What Kernel message should I include within the printk statements, if
> any? KERN_DEBUG,
> KERN_EMERG, KERN_ALERT, KERN_CRIT, KERN_ERR, KERN_WARNING, KERN_NOTICE,
> or KERN_INFO?
You could pick a few and see what seems best to you, and then see what
feedback you get on the patch.
julia
>
> Thanking you,
> Nishka Dasgupta
>
> --
> You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to outreachy-kernel+unsubscribe@googlegroups.com.
> To post to this group, send email to outreachy-kernel@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/CAC4%2B%2BKCd3fAuzm3Pbz5oZEF%3DN9amgAd3tsBRgPzT1d39CGLF6A%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.
>
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2018-03-08 21:19 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-08 19:49 [PATCH] staging: speakup: Replace simple_strtoul with kstrtoul Nishka Dasgupta
2018-03-08 19:53 ` Samuel Thibault
2018-03-08 20:03 ` [PATCH] staging: speakup: Replace simple_strtoul with Nishka Dasgupta
2018-03-08 20:48 ` Samuel Thibault
2018-03-08 21:15 ` Nishka Dasgupta
2018-03-08 21:16 ` Samuel Thibault
2018-03-08 21:19 ` [Outreachy kernel] " Julia Lawall
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.