idletime: fix potential divide-by-zero

Signed-off-by: Jens Axboe <axboe@fb.com>
diff --git a/idletime.c b/idletime.c
index c0bc0bf..bc80976 100644
--- a/idletime.c
+++ b/idletime.c
@@ -336,7 +336,10 @@
 		/* calculate idleness */
 		if (ipc.cali_mean != 0.0) {
 			runt = utime_since(&ipt->tps, &ipt->tpe);
-			ipt->idleness = ipt->loops * ipc.cali_mean / runt;
+			if (runt)
+				ipt->idleness = ipt->loops * ipc.cali_mean / runt;
+			else
+				ipt->idleness = 0.0;
 		} else
 			ipt->idleness = 0.0;
 	}