gpu: nvgpu: fix posix hr timestamp

Fix the high reslution timestamp API in posix timer unit to return
arch specific high resolution counter value.  For userspace, continue
using the timer based implementaion.

BUG 2677936

Change-Id: I1b2015668089e6a80ee1fe4e5fa460ee896a8cec
Signed-off-by: ajesh <akv@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/2176484
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Shashank Singh <shashsingh@nvidia.com>
Reviewed-by: Vaibhav Kachore <vkachore@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
ajesh
2019-08-16 10:33:17 +05:30
committed by mobile promotions
parent 31bc60f76c
commit 69837a8956
3 changed files with 7 additions and 5 deletions

View File

@@ -249,11 +249,7 @@ s64 nvgpu_current_time_ns(void)
u64 nvgpu_hr_timestamp(void)
{
s64 count;
count = nvgpu_current_time_us();
return nvgpu_safe_cast_s64_to_u64(count);
return nvgpu_get_cycles();
}
u64 nvgpu_hr_timestamp_us(void)