diff options
Diffstat (limited to 'drivers/gpu/nvgpu/common/linux/timers.c')
-rw-r--r-- | drivers/gpu/nvgpu/common/linux/timers.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/common/linux/timers.c b/drivers/gpu/nvgpu/common/linux/timers.c index d0004aa5..41b55543 100644 --- a/drivers/gpu/nvgpu/common/linux/timers.c +++ b/drivers/gpu/nvgpu/common/linux/timers.c | |||
@@ -241,3 +241,18 @@ s64 nvgpu_current_time_ms(void) | |||
241 | { | 241 | { |
242 | return ktime_to_ms(ktime_get()); | 242 | return ktime_to_ms(ktime_get()); |
243 | } | 243 | } |
244 | |||
245 | /** | ||
246 | * nvgpu_hr_timestamp - Opaque 'high resolution' time stamp. | ||
247 | * | ||
248 | * Return a "high resolution" time stamp. It does not really matter exactly what | ||
249 | * it is, so long as it generally returns unique values and monotonically | ||
250 | * increases - wrap around _is_ possible though in a system running for long | ||
251 | * enough. | ||
252 | * | ||
253 | * Note: what high resolution means is system dependent. | ||
254 | */ | ||
255 | u64 nvgpu_hr_timestamp(void) | ||
256 | { | ||
257 | return get_cycles(); | ||
258 | } | ||