drivers: staging: speakup: fix sparse "warning: expression using sizeof bool"
PATCH 1/1 drivers: staging: speakup: fix sparse "warning: expression using sizeof bool"
Changed bool to u8 to get rid of sparse warning.
--- drivers/staging/speakup/fakekey.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/speakup/fakekey.c +1 -1
@@ -28,7 +28,7 @@#define PRESSED 1#define RELEASED 0 -static DEFINE_PER_CPU(bool, reporting_keystroke); +static DEFINE_PER_CPU(u8, reporting_keystroke);static struct input_dev *virt_keyboard;
Signature · 1 line
2.0.5
Quoted 1 line · Witos
Changed bool to u8 to get rid of sparse warning.
but i am not getting this warning. which version of sparse are you using?
and why you have sent the same patch two times?
regards
sudip
Quoted 2 lines
Signed-off-by Piotr Witoslawski <[email protected]>
Quoted 4 lines · Sudip Mukherjee
Quoted 1 line · Witos
Changed bool to u8 to get rid of sparse warning.
but i am not getting this warning. which version of sparse are you using?
sparse 0.5.0, see: http://yarchive.net/comp/linux/bool.html
Quoted 1 line
and why you have sent the same patch two times?
sorry my mistake, first time I wanted send it to myself, I forgot that I filled CC list.
Quoted 6 lines
regards
sudipQuoted 2 lines
Signed-off-by Piotr Witoslawski <[email protected]>
Quoted 7 lines · Piotr Witosławski
Quoted 4 lines · Sudip Mukherjee
Quoted 1 line · Witos
Changed bool to u8 to get rid of sparse warning.
but i am not getting this warning. which version of sparse are you using?
sparse 0.5.0, see: http://yarchive.net/comp/linux/bool.html
looks like you have done quite a lot of research on it .. :) i am using 0.5.0-22-gd92353b, and my sparse is not showing me this warning.
regards
sudip
Quoted 12 lines
Quoted 2 lines
and why you have sent the same patch two times?
sorry my mistake, first time I wanted send it to myself, I forgot that I filled CC list.
Quoted 6 lines
regards
sudipQuoted 2 lines
Signed-off-by Piotr Witoslawski <[email protected]>
Re: [PATCH] drivers: staging: speakup: fix sparse "warning: expression using sizeof bool"[email protected],
Quoted 11 lines · Sudip Mukherjee
Quoted 7 lines · Piotr Witosławski
Quoted 4 lines · Sudip Mukherjee
Quoted 1 line · Witos
Changed bool to u8 to get rid of sparse warning.
but i am not getting this warning. which version of sparse are you using?
sparse 0.5.0, see: http://yarchive.net/comp/linux/bool.html
looks like you have done quite a lot of research on it .. :) i am using 0.5.0-22-gd92353b, and my sparse is not showing me this warning.
Checked it on the git source, it was moved from default
to the -Wsizeof-bool flag with commit: 2667c2d4ab3342b54283d16f1d62e6d715f3b373. That's why I got the warning and you didn't. If you turn on this flag, you'll get it. It's not really anything important, I'm doing a patch for the eudyptula-challange, if you don't accept it, I'll find sth else in drivers/staging.
Quoted 15 lines
regards
sudipQuoted 12 lines
Quoted 2 lines
and why you have sent the same patch two times?
sorry my mistake, first time I wanted send it to myself, I forgot that I filled CC list.
Quoted 6 lines
regards
sudipQuoted 2 lines
Signed-off-by Piotr Witoslawski <[email protected]>
Greg Kroah-Hartman
maintainerQuoted 12 lines · Witos
Changed bool to u8 to get rid of sparse warning.
Signed-off-by Piotr Witoslawski <[email protected]>--- drivers/staging/speakup/fakekey.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/staging/speakup/fakekey.c +0
-0
drivers/staging/speakup/fakekey.c line 31
Quoted 5 lines
drivers/staging/speakup/fakekey.c +1
-1@@ -28,7 +28,7 @@#define PRESSED 1#define RELEASED 0 -static DEFINE_PER_CPU(bool, reporting_keystroke); +static DEFINE_PER_CPU(u8, reporting_keystroke);
Why send this twice?
And again, I don't think this is fixing anything, what is wrong with this code?
confused,
greg k-h