summaryrefslogtreecommitdiffhomepage
path: root/pkg/cpuid
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2020-06-18 16:07:05 +0000
committergVisor bot <gvisor-bot@google.com>2020-06-18 16:07:05 +0000
commit9de68043457262a32956e7f51ebc4a5f2c0f5c8b (patch)
treeef623d89ec7fd80cf2c35c53b47868ad1b5cac39 /pkg/cpuid
parent356e6b7c281e4da83b1b2e0316b3131f2833ed19 (diff)
parent3970c127434817304f67a2ad192cbe8094ad3353 (diff)
Merge release-20200608.0-83-g3970c1274 (automated)
Diffstat (limited to 'pkg/cpuid')
-rw-r--r--pkg/cpuid/cpuid_arm64.go5
-rw-r--r--pkg/cpuid/cpuid_x86.go7
2 files changed, 6 insertions, 6 deletions
diff --git a/pkg/cpuid/cpuid_arm64.go b/pkg/cpuid/cpuid_arm64.go
index 08381c1c0..ac7bb6774 100644
--- a/pkg/cpuid/cpuid_arm64.go
+++ b/pkg/cpuid/cpuid_arm64.go
@@ -312,8 +312,9 @@ func HostFeatureSet() *FeatureSet {
}
}
-// Reads bogomips from host /proc/cpuinfo. Must run before whitelisting.
-// This value is used to create the fake /proc/cpuinfo from a FeatureSet.
+// Reads bogomips from host /proc/cpuinfo. Must run before syscall filter
+// installation. This value is used to create the fake /proc/cpuinfo from a
+// FeatureSet.
func initCPUInfo() {
cpuinfob, err := ioutil.ReadFile("/proc/cpuinfo")
if err != nil {
diff --git a/pkg/cpuid/cpuid_x86.go b/pkg/cpuid/cpuid_x86.go
index 562f8f405..17a89c00d 100644
--- a/pkg/cpuid/cpuid_x86.go
+++ b/pkg/cpuid/cpuid_x86.go
@@ -1057,9 +1057,9 @@ func HostFeatureSet() *FeatureSet {
}
}
-// Reads max cpu frequency from host /proc/cpuinfo. Must run before
-// whitelisting. This value is used to create the fake /proc/cpuinfo from a
-// FeatureSet.
+// Reads max cpu frequency from host /proc/cpuinfo. Must run before syscall
+// filter installation. This value is used to create the fake /proc/cpuinfo
+// from a FeatureSet.
func initCPUFreq() {
cpuinfob, err := ioutil.ReadFile("/proc/cpuinfo")
if err != nil {
@@ -1106,7 +1106,6 @@ func initFeaturesFromString() {
}
func init() {
- // initCpuFreq must be run before whitelists are enabled.
initCPUFreq()
initFeaturesFromString()
}