diff options
author | Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com> | 2008-08-19 11:28:23 -0400 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2008-08-19 11:35:27 -0400 |
commit | c85e2031eb55381a5e2f0f66c2e1d62ecd58eb85 (patch) | |
tree | e735cd01a23f2f3341e4f5adc341ae36fd169e39 /drivers/input | |
parent | 0cc1fe2238e458ebe2d52f035ccc6f3d2ecc9ca1 (diff) |
Input: evdev - fix printf() format for sizeof
commit f2afa7711f8585ffc088ba538b9a510e0d5dca12 ("Input: paper over a bug in
Synaptics X driver") introduced a compiler warning on 64-bit platforms, as
sizeof() returns a size_t, not an (unsigned) int:
| drivers/input/evdev.c: In function 'handle_eviocgbit':
| drivers/input/evdev.c:684: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'
Use the proper `z' modifier for size_t, and make the printf() formats for the
sizes unsigned while we're at it.
Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input')
-rw-r--r-- | drivers/input/evdev.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/input/evdev.c b/drivers/input/evdev.c index a92d81567559..3524bef62be6 100644 --- a/drivers/input/evdev.c +++ b/drivers/input/evdev.c | |||
@@ -677,8 +677,8 @@ static int handle_eviocgbit(struct input_dev *dev, unsigned int cmd, void __user | |||
677 | len = OLD_KEY_MAX; | 677 | len = OLD_KEY_MAX; |
678 | if (printk_timed_ratelimit(&keymax_warn_time, 10 * 1000)) | 678 | if (printk_timed_ratelimit(&keymax_warn_time, 10 * 1000)) |
679 | printk(KERN_WARNING | 679 | printk(KERN_WARNING |
680 | "evdev.c(EVIOCGBIT): Suspicious buffer size %d, " | 680 | "evdev.c(EVIOCGBIT): Suspicious buffer size %u, " |
681 | "limiting output to %d bytes. See " | 681 | "limiting output to %zu bytes. See " |
682 | "http://userweb.kernel.org/~dtor/eviocgbit-bug.html\n", | 682 | "http://userweb.kernel.org/~dtor/eviocgbit-bug.html\n", |
683 | OLD_KEY_MAX, | 683 | OLD_KEY_MAX, |
684 | BITS_TO_LONGS(OLD_KEY_MAX) * sizeof(long)); | 684 | BITS_TO_LONGS(OLD_KEY_MAX) * sizeof(long)); |