]> git.baikalelectronics.ru Git - kernel.git/commit
Input: input_event - fix struct padding on sparc64
authorArnd Bergmann <arnd@arndb.de>
Fri, 13 Dec 2019 22:06:58 +0000 (14:06 -0800)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Fri, 13 Dec 2019 23:00:36 +0000 (15:00 -0800)
commitb7c595d29204e73052b42725e9b2c648dc108108
tree9781ad354610754e1c7c459f9b661156f6ebaa7d
parentc2b37865239deba222fcdb5a889909afebd74a94
Input: input_event - fix struct padding on sparc64

Going through all uses of timeval, I noticed that we screwed up
input_event in the previous attempts to fix it:

The time fields now match between kernel and user space, but all following
fields are in the wrong place.

Add the required padding that is implied by the glibc timeval definition
to fix the layout, and use a struct initializer to avoid leaking kernel
stack data.

Fixes: e64fc1aa7a84 ("Input: input_event - fix the CONFIG_SPARC64 mixup")
Fixes: 596612904f9b ("Input: input_event - provide override for sparc64")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Link: https://lore.kernel.org/r/20191213204936.3643476-2-arnd@arndb.de
Cc: stable@vger.kernel.org
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
drivers/input/evdev.c
drivers/input/misc/uinput.c
include/uapi/linux/input.h