From db929b878b26a0ebc8a8b2e74be9e6bcf87a8b2e Mon Sep 17 00:00:00 2001 From: Bin Lu Date: Tue, 10 Apr 2018 14:07:09 +0800 Subject: [PATCH] Skip pstate detection on Arm Signed-off-by: Bin Lu --- source/pstate/pstate.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/source/pstate/pstate.go b/source/pstate/pstate.go index 5e7de7095..bc5c69a9a 100644 --- a/source/pstate/pstate.go +++ b/source/pstate/pstate.go @@ -19,6 +19,7 @@ package pstate import ( "fmt" "io/ioutil" + "runtime" ) // Source implements FeatureSource. @@ -31,6 +32,13 @@ func (s Source) Name() string { return "pstate" } func (s Source) Discover() ([]string, error) { features := []string{} + // On Arm platform, the frequency boost mechanism is software-based. + // So skip pstate detection on Arm. + switch runtime.GOARCH { + case "arm64": + return features, nil + } + // Only looking for turbo boost for now... bytes, err := ioutil.ReadFile("/sys/devices/system/cpu/intel_pstate/no_turbo") if err != nil {