summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/time
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/sentry/time')
-rw-r--r--pkg/sentry/time/BUILD1
-rw-r--r--pkg/sentry/time/sampler_arm64.go4
2 files changed, 2 insertions, 3 deletions
diff --git a/pkg/sentry/time/BUILD b/pkg/sentry/time/BUILD
index 36d999c47..c21971322 100644
--- a/pkg/sentry/time/BUILD
+++ b/pkg/sentry/time/BUILD
@@ -39,7 +39,6 @@ go_library(
"//pkg/log",
"//pkg/metric",
"//pkg/sync",
- "//pkg/syserror",
"@org_golang_x_sys//unix:go_default_library",
],
)
diff --git a/pkg/sentry/time/sampler_arm64.go b/pkg/sentry/time/sampler_arm64.go
index 3560e66ae..9b8c9a480 100644
--- a/pkg/sentry/time/sampler_arm64.go
+++ b/pkg/sentry/time/sampler_arm64.go
@@ -30,9 +30,9 @@ func getDefaultArchOverheadCycles() TSCValue {
// frqRatio. defaultOverheadCycles of ARM equals to that on
// x86 devided by frqRatio
cntfrq := getCNTFRQ()
- frqRatio := 1000000000 / cntfrq
+ frqRatio := 1000000000 / float64(cntfrq)
overheadCycles := (1 * 1000) / frqRatio
- return overheadCycles
+ return TSCValue(overheadCycles)
}
// defaultOverheadTSC is the default estimated syscall overhead in TSC cycles.