linux/drivers/misc/mic/cosm
Arnd Bergmann 6051e79bbf misc: mic: fix passing the current time
I noticed that the mic driver passes a 'struct timespec64' as part of
a message into an attached device, where it is used to set the current
system time.

This won't actually work if one of the two sides runs a 32-bit kernel and
the other runs a 64-bit kernel, since the structure layout is different
between the two.

I found this while replacing calls to the deprecated do_settimeofday64()
interface with the modern ktime_get_real_ts() variant, but it seems
appropriate to address both at the same time here.

To make sure we have a sane structure, let's define our own structure
using the layout of the 64-bit kernel.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-07-07 17:44:52 +02:00
..
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
cosm_debugfs.c misc: mic: Fix randconfig build error 2015-10-17 21:42:29 -07:00
cosm_main.c misc: mic: Fix crash when MIC reset is invoked in RESET_FAILED state 2016-02-07 22:53:40 -08:00
cosm_main.h misc: mic: fix passing the current time 2018-07-07 17:44:52 +02:00
cosm_scif_server.c misc: mic: fix passing the current time 2018-07-07 17:44:52 +02:00
cosm_sysfs.c