• Arnd Bergmann's avatar
    scsi: smartpqi: fix time handling · ed10858e
    Arnd Bergmann authored
    When we have turned off RTC support, the smartpqi driver fails to build:
    
    ERROR: "rtc_time64_to_tm" [drivers/scsi/smartpqi/smartpqi.ko] undefined!
    
    This is easily avoided by using the generic 'struct tm' based helper rather
    than the RTC specific one. While fixing this, I noticed that even though
    the driver uses time64_t for storing seconds, it gets them from the
    old 32-bit struct timeval. To address this, we can simplify the code
    by calling ktime_get_real_seconds() directly.
    
    Fixes: 6c223761 ("smartpqi: initial commit of Microsemi smartpqi driver")
    Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
    Acked-by: default avatarDon Brace <don.brace@microsemi.com>
    Signed-off-by: Martin K. Petersen's avatarMartin K. Petersen <martin.petersen@oracle.com>
    ed10858e
Name
Last commit
Last update
..
Kconfig Loading commit data...
Makefile Loading commit data...
smartpqi.h Loading commit data...
smartpqi_init.c Loading commit data...
smartpqi_sas_transport.c Loading commit data...
smartpqi_sis.c Loading commit data...
smartpqi_sis.h Loading commit data...