cpu: unexport HWCap and HWCap2

These are an implementation detail and should not have been
exported. This only affects Linux on platforms other than 386 and
amd64.

Fixes golang/go#30255.

Change-Id: Ib23b42a7309fd6093b6b9d8b6628de222a3928be
Reviewed-on: https://go-review.googlesource.com/c/163004
Run-TryBot: Michael Munday <mike.munday@ibm.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
This commit is contained in:
Michael Munday
2019-02-19 09:28:55 +00:00
parent d0b11bdaac
commit 153ac47618
3 changed files with 32 additions and 32 deletions
+4 -4
View File
@@ -22,8 +22,8 @@ const (
// For those platforms don't have a 'cpuid' equivalent we use HWCAP/HWCAP2
// These are initialized in cpu_$GOARCH.go
// and should not be changed after they are initialized.
var HWCap uint
var HWCap2 uint
var hwCap uint
var hwCap2 uint
func init() {
buf, err := ioutil.ReadFile(procAuxv)
@@ -46,9 +46,9 @@ func init() {
}
switch tag {
case _AT_HWCAP:
HWCap = val
hwCap = val
case _AT_HWCAP2:
HWCap2 = val
hwCap2 = val
}
}
doinit()