Skip to contentSkip to conversation

drm/msm: Use 64-bit timekeeping

PATCH Superseded Tina Ruchandani 1 participant 1 message Apr 13, 2016

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/msm: Use 64-bit timekeeping

'struct timespec' uses a 32-bit seconds which will overflow in year 2038 and beyond. This patch replaces timespec with timespec64. The code is correct as is - the patch is merely part of a larger attempt to remove all 32-bit timekeeping variables (timespec, timeval, time_t) from the kernel.

---
 drivers/gpu/drm/msm/msm_drv.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/msm/msm_drv.c +2 -2
index c03b967..b095085 100644
@@ -717,8 +717,8 @@ int msm_wait_fence(struct drm_device *dev, uint32_t fence,
 			remaining_jiffies = 0;
 		} else {
 			ktime_t rem = ktime_sub(*timeout, now);
-			struct timespec ts = ktime_to_timespec(rem);
-			remaining_jiffies = timespec_to_jiffies(&ts);
+			struct timespec64 ts = ktime_to_timespec64(rem);
+			remaining_jiffies = timespec64_to_jiffies(&ts);
 		}
 
 		if (interruptible)
Signature · 1 line
2.8.0.rc3.226.g39d4020