element sizes in input_event struct on riscv32
From: Antonios Salios
Date: Thu Dec 14 2023 - 05:11:29 EST
Hi all.
I'm having trouble getting evdev to run in a simulated Buildroot
environment on riscv32. Evtest (and the x11 driver) seems to be
receiving garbage data from input devices.
Analyzing the input_event struct shows that the kernel uses 32-bit (aka
__kernel_ulong_t) values for __sec & __usec.
Evtest on the other hand interprets these variables as 64-bit time_t
values in a timeval struct, resulting in a mismatch between the kernel
and userspace.
What would be the correct size for these values on a 32-bit
architecture that uses 64-bit time_t values?
Kind regards
--
Antonios Salios
Student Employee
MachineWare GmbH | www.machineware.de
Hühnermarkt 19, 52062 Aachen, Germany
Amtsgericht Aachen HRB25734
Geschäftsführung
Lukas Jünger
Dr.-Ing. Jan Henrik Weinstock