Merge r7485 from trunk

git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.3.x@7734 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Bart Van Assche
2018-11-04 04:45:18 +00:00
parent 2435b37937
commit 9c255254f1

View File

@@ -15707,7 +15707,7 @@ static void __scst_update_latency_stats(struct scst_cmd *cmd,
int64_t deltac;
#endif
if (stat && stat->last_update) {
if (stat && ktime_to_ns(stat->last_update) != 0) {
delta = ktime_to_ns(ktime_sub(now, stat->last_update));
if (delta < 0 || delta > NSEC_PER_SEC) {
printk_once(KERN_INFO "%d: ignoring large time delta %lld\n",