Changeset View
Changeset View
Standalone View
Standalone View
sysutils/docker-freebsd/files/patch-daemon_stats_collector__unix.go
- This file was added.
Property | Old Value | New Value |
---|---|---|
fbsd:nokeywords | null | yes \ No newline at end of property |
svn:eol-style | null | native \ No newline at end of property |
svn:mime-type | null | text/plain \ No newline at end of property |
--- daemon/stats/collector_unix.go.orig 2019-10-07 21:12:15 UTC | |||||
+++ daemon/stats/collector_unix.go | |||||
@@ -7,15 +7,11 @@ import ( | |||||
"os" | |||||
"strconv" | |||||
"strings" | |||||
- | |||||
- "github.com/opencontainers/runc/libcontainer/system" | |||||
- "golang.org/x/sys/unix" | |||||
) | |||||
// platformNewStatsCollector performs platform specific initialisation of the | |||||
// Collector structure. | |||||
func platformNewStatsCollector(s *Collector) { | |||||
- s.clockTicksPerSecond = uint64(system.GetClockTicks()) | |||||
} | |||||
const nanoSecondsPerSecond = 1e9 | |||||
@@ -66,10 +62,5 @@ func (s *Collector) getSystemCPUUsage() (uint64, error | |||||
} | |||||
func (s *Collector) getNumberOnlineCPUs() (uint32, error) { | |||||
- var cpuset unix.CPUSet | |||||
- err := unix.SchedGetaffinity(0, &cpuset) | |||||
- if err != nil { | |||||
- return 0, err | |||||
- } | |||||
- return uint32(cpuset.Count()), nil | |||||
+ return 0, nil | |||||
} |