scsi: 3ware: fix 32-bit time calculations
twl_aen_queue_event/twa_aen_queue_event, we use do_gettimeofday() to read the lower 32 bits of the current time in seconds, to pass them to the TW_IOCTL_GET_NEXT_EVENT ioctl or the 3ware_aen_read sysfs file. This will overflow on all architectures in year 2106, there is not much we can do about that without breaking the ABI. User space has 90 years to learn to deal with it, so it's probably ok. I'm changing it to use ktime_get_real_seconds() with a comment to document what happens when. Signed-off-by: NArnd Bergmann <arnd@arndb.de> Acked-by: NAdam Radford <aradford@gmail.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
Showing
想要评论请 注册 或 登录