diff options
author | Ben Kochie <superq@gmail.com> | 2020-06-06 09:00:09 +0200 |
---|---|---|
committer | Ben Kochie <superq@gmail.com> | 2020-06-14 14:18:13 +0200 |
commit | baa7ab732f34409d617fdab0b8eefa5e8dc4eaf6 (patch) | |
tree | fc340b9e9e66b653ef3d833a2bdd08d84ecdd6d4 | |
parent | 2cefe3d769b161388fe3635a7243cffaac803d43 (diff) | |
download | prometheus_node_collector-baa7ab732f34409d617fdab0b8eefa5e8dc4eaf6.tar.bz2 prometheus_node_collector-baa7ab732f34409d617fdab0b8eefa5e8dc4eaf6.tar.xz prometheus_node_collector-baa7ab732f34409d617fdab0b8eefa5e8dc4eaf6.zip |
Update prometheus/procfs
Fixes: https://github.com/prometheus/node_exporter/issues/1721
Signed-off-by: Ben Kochie <superq@gmail.com>
51 files changed, 2699 insertions, 292 deletions
diff --git a/collector/fixtures/sys.ttar b/collector/fixtures/sys.ttar index a4550a5..3e52c60 100644 --- a/collector/fixtures/sys.ttar +++ b/collector/fixtures/sys.ttar | |||
@@ -1756,6 +1756,17 @@ Lines: 1 | |||
1756 | 0 | 1756 | 0 |
1757 | Mode: 644 | 1757 | Mode: 644 |
1758 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 1758 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
1759 | Path: sys/devices/pci0000:00/0000:00:0d.0/ata4/host3/target3:0:0/3:0:0:0/block/sdb/bcache/writeback_rate_debug | ||
1760 | Lines: 7 | ||
1761 | rate: 1.1M/sec | ||
1762 | dirty: 20.4G | ||
1763 | target: 20.4G | ||
1764 | proportional: 427.5k | ||
1765 | integral: 790.0k | ||
1766 | change: 321.5k/sec | ||
1767 | next io: 17ms | ||
1768 | Mode: 644 | ||
1769 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
1759 | Directory: sys/devices/pci0000:00/0000:00:0d.0/ata5 | 1770 | Directory: sys/devices/pci0000:00/0000:00:0d.0/ata5 |
1760 | Mode: 755 | 1771 | Mode: 755 |
1761 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 1772 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
@@ -20,7 +20,7 @@ require ( | |||
20 | github.com/prometheus/client_golang v1.6.0 | 20 | github.com/prometheus/client_golang v1.6.0 |
21 | github.com/prometheus/client_model v0.2.0 | 21 | github.com/prometheus/client_model v0.2.0 |
22 | github.com/prometheus/common v0.10.0 | 22 | github.com/prometheus/common v0.10.0 |
23 | github.com/prometheus/procfs v0.0.11 | 23 | github.com/prometheus/procfs v0.1.3 |
24 | github.com/siebenmann/go-kstat v0.0.0-20200303194639-4e8294f9e9d5 | 24 | github.com/siebenmann/go-kstat v0.0.0-20200303194639-4e8294f9e9d5 |
25 | github.com/soundcloud/go-runit v0.0.0-20150630195641-06ad41a06c4a | 25 | github.com/soundcloud/go-runit v0.0.0-20150630195641-06ad41a06c4a |
26 | go.uber.org/multierr v1.5.0 // indirect | 26 | go.uber.org/multierr v1.5.0 // indirect |
@@ -28,7 +28,7 @@ require ( | |||
28 | golang.org/x/lint v0.0.0-20200302205851-738671d3881b // indirect | 28 | golang.org/x/lint v0.0.0-20200302205851-738671d3881b // indirect |
29 | golang.org/x/net v0.0.0-20200513185701-a91f0712d120 // indirect | 29 | golang.org/x/net v0.0.0-20200513185701-a91f0712d120 // indirect |
30 | golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a // indirect | 30 | golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a // indirect |
31 | golang.org/x/sys v0.0.0-20200523222454-059865788121 | 31 | golang.org/x/sys v0.0.0-20200602225109-6fdc65e7d980 |
32 | golang.org/x/tools v0.0.0-20200513201620-d5fe73897c97 // indirect | 32 | golang.org/x/tools v0.0.0-20200513201620-d5fe73897c97 // indirect |
33 | gopkg.in/alecthomas/kingpin.v2 v2.2.6 | 33 | gopkg.in/alecthomas/kingpin.v2 v2.2.6 |
34 | gopkg.in/yaml.v2 v2.3.0 | 34 | gopkg.in/yaml.v2 v2.3.0 |
@@ -289,6 +289,8 @@ github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsT | |||
289 | github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= | 289 | github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= |
290 | github.com/prometheus/procfs v0.0.11 h1:DhHlBtkHWPYi8O2y31JkK0TF+DGM+51OopZjH/Ia5qI= | 290 | github.com/prometheus/procfs v0.0.11 h1:DhHlBtkHWPYi8O2y31JkK0TF+DGM+51OopZjH/Ia5qI= |
291 | github.com/prometheus/procfs v0.0.11/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= | 291 | github.com/prometheus/procfs v0.0.11/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= |
292 | github.com/prometheus/procfs v0.1.3 h1:F0+tqvhOksq22sc6iCHF5WGlWjdwj92p0udFh1VFBS8= | ||
293 | github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= | ||
292 | github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= | 294 | github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= |
293 | github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= | 295 | github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= |
294 | github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= | 296 | github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= |
@@ -432,8 +434,8 @@ golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7w | |||
432 | golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= | 434 | golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= |
433 | golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= | 435 | golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= |
434 | golang.org/x/sys v0.0.0-20200420163511-1957bb5e6d1f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= | 436 | golang.org/x/sys v0.0.0-20200420163511-1957bb5e6d1f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= |
435 | golang.org/x/sys v0.0.0-20200523222454-059865788121 h1:rITEj+UZHYC927n8GT97eC3zrpzXdb/voyeOuVKS46o= | 437 | golang.org/x/sys v0.0.0-20200602225109-6fdc65e7d980 h1:OjiUf46hAmXblsZdnoSXsEUSKU8r1UEzcL5RVZ4gO9Y= |
436 | golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= | 438 | golang.org/x/sys v0.0.0-20200602225109-6fdc65e7d980/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= |
437 | golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= | 439 | golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= |
438 | golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs= | 440 | golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs= |
439 | golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= | 441 | golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= |
diff --git a/vendor/github.com/prometheus/procfs/Makefile.common b/vendor/github.com/prometheus/procfs/Makefile.common index b978dfc..9320176 100644 --- a/vendor/github.com/prometheus/procfs/Makefile.common +++ b/vendor/github.com/prometheus/procfs/Makefile.common | |||
@@ -150,6 +150,17 @@ else | |||
150 | $(GO) get $(GOOPTS) -t ./... | 150 | $(GO) get $(GOOPTS) -t ./... |
151 | endif | 151 | endif |
152 | 152 | ||
153 | .PHONY: update-go-deps | ||
154 | update-go-deps: | ||
155 | @echo ">> updating Go dependencies" | ||
156 | @for m in $$($(GO) list -mod=readonly -m -f '{{ if and (not .Indirect) (not .Main)}}{{.Path}}{{end}}' all); do \ | ||
157 | $(GO) get $$m; \ | ||
158 | done | ||
159 | GO111MODULE=$(GO111MODULE) $(GO) mod tidy | ||
160 | ifneq (,$(wildcard vendor)) | ||
161 | GO111MODULE=$(GO111MODULE) $(GO) mod vendor | ||
162 | endif | ||
163 | |||
153 | .PHONY: common-test-short | 164 | .PHONY: common-test-short |
154 | common-test-short: $(GOTEST_DIR) | 165 | common-test-short: $(GOTEST_DIR) |
155 | @echo ">> running short tests" | 166 | @echo ">> running short tests" |
diff --git a/vendor/github.com/prometheus/procfs/bcache/bcache.go b/vendor/github.com/prometheus/procfs/bcache/bcache.go index df724ed..1176a55 100644 --- a/vendor/github.com/prometheus/procfs/bcache/bcache.go +++ b/vendor/github.com/prometheus/procfs/bcache/bcache.go | |||
@@ -43,10 +43,11 @@ type BcacheStats struct { // nolint:golint | |||
43 | 43 | ||
44 | // BdevStats contains statistics for one backing device. | 44 | // BdevStats contains statistics for one backing device. |
45 | type BdevStats struct { | 45 | type BdevStats struct { |
46 | Name string | 46 | Name string |
47 | DirtyData uint64 | 47 | DirtyData uint64 |
48 | FiveMin PeriodStats | 48 | FiveMin PeriodStats |
49 | Total PeriodStats | 49 | Total PeriodStats |
50 | WritebackRateDebug WritebackRateDebugStats | ||
50 | } | 51 | } |
51 | 52 | ||
52 | // CacheStats contains statistics for one cache device. | 53 | // CacheStats contains statistics for one cache device. |
@@ -82,3 +83,14 @@ type PeriodStats struct { | |||
82 | CacheMisses uint64 | 83 | CacheMisses uint64 |
83 | CacheReadaheads uint64 | 84 | CacheReadaheads uint64 |
84 | } | 85 | } |
86 | |||
87 | // WritebackRateDebugStats contains bcache writeback statistics. | ||
88 | type WritebackRateDebugStats struct { | ||
89 | Rate uint64 | ||
90 | Dirty uint64 | ||
91 | Target uint64 | ||
92 | Proportional int64 | ||
93 | Integral int64 | ||
94 | Change int64 | ||
95 | NextIO int64 | ||
96 | } | ||
diff --git a/vendor/github.com/prometheus/procfs/bcache/get.go b/vendor/github.com/prometheus/procfs/bcache/get.go index 67fcf8b..c4747ea 100644 --- a/vendor/github.com/prometheus/procfs/bcache/get.go +++ b/vendor/github.com/prometheus/procfs/bcache/get.go | |||
@@ -174,6 +174,17 @@ func dehumanize(hbytes []byte) (uint64, error) { | |||
174 | return res, nil | 174 | return res, nil |
175 | } | 175 | } |
176 | 176 | ||
177 | func dehumanizeSigned(str string) (int64, error) { | ||
178 | value, err := dehumanize([]byte(strings.TrimPrefix(str, "-"))) | ||
179 | if err != nil { | ||
180 | return 0, err | ||
181 | } | ||
182 | if strings.HasPrefix(str, "-") { | ||
183 | return int64(-value), nil | ||
184 | } | ||
185 | return int64(value), nil | ||
186 | } | ||
187 | |||
177 | type parser struct { | 188 | type parser struct { |
178 | uuidPath string | 189 | uuidPath string |
179 | subDir string | 190 | subDir string |
@@ -232,6 +243,72 @@ func parsePriorityStats(line string, ps *PriorityStats) error { | |||
232 | return nil | 243 | return nil |
233 | } | 244 | } |
234 | 245 | ||
246 | // ParseWritebackRateDebug parses lines from the writeback_rate_debug file. | ||
247 | func parseWritebackRateDebug(line string, wrd *WritebackRateDebugStats) error { | ||
248 | switch { | ||
249 | case strings.HasPrefix(line, "rate:"): | ||
250 | fields := strings.Fields(line) | ||
251 | rawValue := fields[len(fields)-1] | ||
252 | valueStr := strings.TrimSuffix(rawValue, "/sec") | ||
253 | value, err := dehumanize([]byte(valueStr)) | ||
254 | if err != nil { | ||
255 | return err | ||
256 | } | ||
257 | wrd.Rate = value | ||
258 | case strings.HasPrefix(line, "dirty:"): | ||
259 | fields := strings.Fields(line) | ||
260 | valueStr := fields[len(fields)-1] | ||
261 | value, err := dehumanize([]byte(valueStr)) | ||
262 | if err != nil { | ||
263 | return err | ||
264 | } | ||
265 | wrd.Dirty = value | ||
266 | case strings.HasPrefix(line, "target:"): | ||
267 | fields := strings.Fields(line) | ||
268 | valueStr := fields[len(fields)-1] | ||
269 | value, err := dehumanize([]byte(valueStr)) | ||
270 | if err != nil { | ||
271 | return err | ||
272 | } | ||
273 | wrd.Target = value | ||
274 | case strings.HasPrefix(line, "proportional:"): | ||
275 | fields := strings.Fields(line) | ||
276 | valueStr := fields[len(fields)-1] | ||
277 | value, err := dehumanizeSigned(valueStr) | ||
278 | if err != nil { | ||
279 | return err | ||
280 | } | ||
281 | wrd.Proportional = value | ||
282 | case strings.HasPrefix(line, "integral:"): | ||
283 | fields := strings.Fields(line) | ||
284 | valueStr := fields[len(fields)-1] | ||
285 | value, err := dehumanizeSigned(valueStr) | ||
286 | if err != nil { | ||
287 | return err | ||
288 | } | ||
289 | wrd.Integral = value | ||
290 | case strings.HasPrefix(line, "change:"): | ||
291 | fields := strings.Fields(line) | ||
292 | rawValue := fields[len(fields)-1] | ||
293 | valueStr := strings.TrimSuffix(rawValue, "/sec") | ||
294 | value, err := dehumanizeSigned(valueStr) | ||
295 | if err != nil { | ||
296 | return err | ||
297 | } | ||
298 | wrd.Change = value | ||
299 | case strings.HasPrefix(line, "next io:"): | ||
300 | fields := strings.Fields(line) | ||
301 | rawValue := fields[len(fields)-1] | ||
302 | valueStr := strings.TrimSuffix(rawValue, "ms") | ||
303 | value, err := strconv.ParseInt(valueStr, 10, 64) | ||
304 | if err != nil { | ||
305 | return err | ||
306 | } | ||
307 | wrd.NextIO = value | ||
308 | } | ||
309 | return nil | ||
310 | } | ||
311 | |||
235 | func (p *parser) getPriorityStats() PriorityStats { | 312 | func (p *parser) getPriorityStats() PriorityStats { |
236 | var res PriorityStats | 313 | var res PriorityStats |
237 | 314 | ||
@@ -263,6 +340,35 @@ func (p *parser) getPriorityStats() PriorityStats { | |||
263 | return res | 340 | return res |
264 | } | 341 | } |
265 | 342 | ||
343 | func (p *parser) getWritebackRateDebug() WritebackRateDebugStats { | ||
344 | var res WritebackRateDebugStats | ||
345 | |||
346 | if p.err != nil { | ||
347 | return res | ||
348 | } | ||
349 | path := path.Join(p.currentDir, "writeback_rate_debug") | ||
350 | file, err := os.Open(path) | ||
351 | if err != nil { | ||
352 | p.err = fmt.Errorf("failed to read: %s", path) | ||
353 | return res | ||
354 | } | ||
355 | defer file.Close() | ||
356 | |||
357 | scanner := bufio.NewScanner(file) | ||
358 | for scanner.Scan() { | ||
359 | err = parseWritebackRateDebug(scanner.Text(), &res) | ||
360 | if err != nil { | ||
361 | p.err = fmt.Errorf("failed to parse: %s (%s)", path, err) | ||
362 | return res | ||
363 | } | ||
364 | } | ||
365 | if err := scanner.Err(); err != nil { | ||
366 | p.err = fmt.Errorf("failed to parse: %s (%s)", path, err) | ||
367 | return res | ||
368 | } | ||
369 | return res | ||
370 | } | ||
371 | |||
266 | // GetStats collects from sysfs files data tied to one bcache ID. | 372 | // GetStats collects from sysfs files data tied to one bcache ID. |
267 | func GetStats(uuidPath string, priorityStats bool) (*Stats, error) { | 373 | func GetStats(uuidPath string, priorityStats bool) (*Stats, error) { |
268 | var bs Stats | 374 | var bs Stats |
@@ -339,6 +445,9 @@ func GetStats(uuidPath string, priorityStats bool) (*Stats, error) { | |||
339 | par.setSubDir(bds.Name) | 445 | par.setSubDir(bds.Name) |
340 | bds.DirtyData = par.readValue("dirty_data") | 446 | bds.DirtyData = par.readValue("dirty_data") |
341 | 447 | ||
448 | wrd := par.getWritebackRateDebug() | ||
449 | bds.WritebackRateDebug = wrd | ||
450 | |||
342 | // dir <uuidPath>/<bds.Name>/stats_five_minute | 451 | // dir <uuidPath>/<bds.Name>/stats_five_minute |
343 | par.setSubDir(bds.Name, "stats_five_minute") | 452 | par.setSubDir(bds.Name, "stats_five_minute") |
344 | bds.FiveMin.Bypassed = par.readValue("bypassed") | 453 | bds.FiveMin.Bypassed = par.readValue("bypassed") |
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo.go b/vendor/github.com/prometheus/procfs/cpuinfo.go index 2e02215..31d42f7 100644 --- a/vendor/github.com/prometheus/procfs/cpuinfo.go +++ b/vendor/github.com/prometheus/procfs/cpuinfo.go | |||
@@ -11,11 +11,15 @@ | |||
11 | // See the License for the specific language governing permissions and | 11 | // See the License for the specific language governing permissions and |
12 | // limitations under the License. | 12 | // limitations under the License. |
13 | 13 | ||
14 | // +build linux | ||
15 | |||
14 | package procfs | 16 | package procfs |
15 | 17 | ||
16 | import ( | 18 | import ( |
17 | "bufio" | 19 | "bufio" |
18 | "bytes" | 20 | "bytes" |
21 | "errors" | ||
22 | "regexp" | ||
19 | "strconv" | 23 | "strconv" |
20 | "strings" | 24 | "strings" |
21 | 25 | ||
@@ -52,6 +56,11 @@ type CPUInfo struct { | |||
52 | PowerManagement string | 56 | PowerManagement string |
53 | } | 57 | } |
54 | 58 | ||
59 | var ( | ||
60 | cpuinfoClockRegexp = regexp.MustCompile(`([\d.]+)`) | ||
61 | cpuinfoS390XProcessorRegexp = regexp.MustCompile(`^processor\s+(\d+):.*`) | ||
62 | ) | ||
63 | |||
55 | // CPUInfo returns information about current system CPUs. | 64 | // CPUInfo returns information about current system CPUs. |
56 | // See https://www.kernel.org/doc/Documentation/filesystems/proc.txt | 65 | // See https://www.kernel.org/doc/Documentation/filesystems/proc.txt |
57 | func (fs FS) CPUInfo() ([]CPUInfo, error) { | 66 | func (fs FS) CPUInfo() ([]CPUInfo, error) { |
@@ -62,14 +71,26 @@ func (fs FS) CPUInfo() ([]CPUInfo, error) { | |||
62 | return parseCPUInfo(data) | 71 | return parseCPUInfo(data) |
63 | } | 72 | } |
64 | 73 | ||
65 | // parseCPUInfo parses data from /proc/cpuinfo | 74 | func parseCPUInfoX86(info []byte) ([]CPUInfo, error) { |
66 | func parseCPUInfo(info []byte) ([]CPUInfo, error) { | ||
67 | cpuinfo := []CPUInfo{} | ||
68 | i := -1 | ||
69 | scanner := bufio.NewScanner(bytes.NewReader(info)) | 75 | scanner := bufio.NewScanner(bytes.NewReader(info)) |
76 | |||
77 | // find the first "processor" line | ||
78 | firstLine := firstNonEmptyLine(scanner) | ||
79 | if !strings.HasPrefix(firstLine, "processor") || !strings.Contains(firstLine, ":") { | ||
80 | return nil, errors.New("invalid cpuinfo file: " + firstLine) | ||
81 | } | ||
82 | field := strings.SplitN(firstLine, ": ", 2) | ||
83 | v, err := strconv.ParseUint(field[1], 0, 32) | ||
84 | if err != nil { | ||
85 | return nil, err | ||
86 | } | ||
87 | firstcpu := CPUInfo{Processor: uint(v)} | ||
88 | cpuinfo := []CPUInfo{firstcpu} | ||
89 | i := 0 | ||
90 | |||
70 | for scanner.Scan() { | 91 | for scanner.Scan() { |
71 | line := scanner.Text() | 92 | line := scanner.Text() |
72 | if strings.TrimSpace(line) == "" { | 93 | if !strings.Contains(line, ":") { |
73 | continue | 94 | continue |
74 | } | 95 | } |
75 | field := strings.SplitN(line, ": ", 2) | 96 | field := strings.SplitN(line, ": ", 2) |
@@ -82,7 +103,7 @@ func parseCPUInfo(info []byte) ([]CPUInfo, error) { | |||
82 | return nil, err | 103 | return nil, err |
83 | } | 104 | } |
84 | cpuinfo[i].Processor = uint(v) | 105 | cpuinfo[i].Processor = uint(v) |
85 | case "vendor_id": | 106 | case "vendor", "vendor_id": |
86 | cpuinfo[i].VendorID = field[1] | 107 | cpuinfo[i].VendorID = field[1] |
87 | case "cpu family": | 108 | case "cpu family": |
88 | cpuinfo[i].CPUFamily = field[1] | 109 | cpuinfo[i].CPUFamily = field[1] |
@@ -163,5 +184,237 @@ func parseCPUInfo(info []byte) ([]CPUInfo, error) { | |||
163 | } | 184 | } |
164 | } | 185 | } |
165 | return cpuinfo, nil | 186 | return cpuinfo, nil |
187 | } | ||
188 | |||
189 | func parseCPUInfoARM(info []byte) ([]CPUInfo, error) { | ||
190 | scanner := bufio.NewScanner(bytes.NewReader(info)) | ||
191 | |||
192 | firstLine := firstNonEmptyLine(scanner) | ||
193 | match, _ := regexp.MatchString("^[Pp]rocessor", firstLine) | ||
194 | if !match || !strings.Contains(firstLine, ":") { | ||
195 | return nil, errors.New("invalid cpuinfo file: " + firstLine) | ||
196 | } | ||
197 | field := strings.SplitN(firstLine, ": ", 2) | ||
198 | cpuinfo := []CPUInfo{} | ||
199 | featuresLine := "" | ||
200 | commonCPUInfo := CPUInfo{} | ||
201 | i := 0 | ||
202 | if strings.TrimSpace(field[0]) == "Processor" { | ||
203 | commonCPUInfo = CPUInfo{ModelName: field[1]} | ||
204 | i = -1 | ||
205 | } else { | ||
206 | v, err := strconv.ParseUint(field[1], 0, 32) | ||
207 | if err != nil { | ||
208 | return nil, err | ||
209 | } | ||
210 | firstcpu := CPUInfo{Processor: uint(v)} | ||
211 | cpuinfo = []CPUInfo{firstcpu} | ||
212 | } | ||
213 | |||
214 | for scanner.Scan() { | ||
215 | line := scanner.Text() | ||
216 | if !strings.Contains(line, ":") { | ||
217 | continue | ||
218 | } | ||
219 | field := strings.SplitN(line, ": ", 2) | ||
220 | switch strings.TrimSpace(field[0]) { | ||
221 | case "processor": | ||
222 | cpuinfo = append(cpuinfo, commonCPUInfo) // start of the next processor | ||
223 | i++ | ||
224 | v, err := strconv.ParseUint(field[1], 0, 32) | ||
225 | if err != nil { | ||
226 | return nil, err | ||
227 | } | ||
228 | cpuinfo[i].Processor = uint(v) | ||
229 | case "BogoMIPS": | ||
230 | if i == -1 { | ||
231 | cpuinfo = append(cpuinfo, commonCPUInfo) // There is only one processor | ||
232 | i++ | ||
233 | cpuinfo[i].Processor = 0 | ||
234 | } | ||
235 | v, err := strconv.ParseFloat(field[1], 64) | ||
236 | if err != nil { | ||
237 | return nil, err | ||
238 | } | ||
239 | cpuinfo[i].BogoMips = v | ||
240 | case "Features": | ||
241 | featuresLine = line | ||
242 | case "model name": | ||
243 | cpuinfo[i].ModelName = field[1] | ||
244 | } | ||
245 | } | ||
246 | fields := strings.SplitN(featuresLine, ": ", 2) | ||
247 | for i := range cpuinfo { | ||
248 | cpuinfo[i].Flags = strings.Fields(fields[1]) | ||
249 | } | ||
250 | return cpuinfo, nil | ||
251 | |||
252 | } | ||
253 | |||
254 | func parseCPUInfoS390X(info []byte) ([]CPUInfo, error) { | ||
255 | scanner := bufio.NewScanner(bytes.NewReader(info)) | ||
256 | |||
257 | firstLine := firstNonEmptyLine(scanner) | ||
258 | if !strings.HasPrefix(firstLine, "vendor_id") || !strings.Contains(firstLine, ":") { | ||
259 | return nil, errors.New("invalid cpuinfo file: " + firstLine) | ||
260 | } | ||
261 | field := strings.SplitN(firstLine, ": ", 2) | ||
262 | cpuinfo := []CPUInfo{} | ||
263 | commonCPUInfo := CPUInfo{VendorID: field[1]} | ||
264 | |||
265 | for scanner.Scan() { | ||
266 | line := scanner.Text() | ||
267 | if !strings.Contains(line, ":") { | ||
268 | continue | ||
269 | } | ||
270 | field := strings.SplitN(line, ": ", 2) | ||
271 | switch strings.TrimSpace(field[0]) { | ||
272 | case "bogomips per cpu": | ||
273 | v, err := strconv.ParseFloat(field[1], 64) | ||
274 | if err != nil { | ||
275 | return nil, err | ||
276 | } | ||
277 | commonCPUInfo.BogoMips = v | ||
278 | case "features": | ||
279 | commonCPUInfo.Flags = strings.Fields(field[1]) | ||
280 | } | ||
281 | if strings.HasPrefix(line, "processor") { | ||
282 | match := cpuinfoS390XProcessorRegexp.FindStringSubmatch(line) | ||
283 | if len(match) < 2 { | ||
284 | return nil, errors.New("Invalid line found in cpuinfo: " + line) | ||
285 | } | ||
286 | cpu := commonCPUInfo | ||
287 | v, err := strconv.ParseUint(match[1], 0, 32) | ||
288 | if err != nil { | ||
289 | return nil, err | ||
290 | } | ||
291 | cpu.Processor = uint(v) | ||
292 | cpuinfo = append(cpuinfo, cpu) | ||
293 | } | ||
294 | if strings.HasPrefix(line, "cpu number") { | ||
295 | break | ||
296 | } | ||
297 | } | ||
298 | |||
299 | i := 0 | ||
300 | for scanner.Scan() { | ||
301 | line := scanner.Text() | ||
302 | if !strings.Contains(line, ":") { | ||
303 | continue | ||
304 | } | ||
305 | field := strings.SplitN(line, ": ", 2) | ||
306 | switch strings.TrimSpace(field[0]) { | ||
307 | case "cpu number": | ||
308 | i++ | ||
309 | case "cpu MHz dynamic": | ||
310 | clock := cpuinfoClockRegexp.FindString(strings.TrimSpace(field[1])) | ||
311 | v, err := strconv.ParseFloat(clock, 64) | ||
312 | if err != nil { | ||
313 | return nil, err | ||
314 | } | ||
315 | cpuinfo[i].CPUMHz = v | ||
316 | } | ||
317 | } | ||
318 | |||
319 | return cpuinfo, nil | ||
320 | } | ||
321 | |||
322 | func parseCPUInfoMips(info []byte) ([]CPUInfo, error) { | ||
323 | scanner := bufio.NewScanner(bytes.NewReader(info)) | ||
324 | |||
325 | // find the first "processor" line | ||
326 | firstLine := firstNonEmptyLine(scanner) | ||
327 | if !strings.HasPrefix(firstLine, "system type") || !strings.Contains(firstLine, ":") { | ||
328 | return nil, errors.New("invalid cpuinfo file: " + firstLine) | ||
329 | } | ||
330 | field := strings.SplitN(firstLine, ": ", 2) | ||
331 | cpuinfo := []CPUInfo{} | ||
332 | systemType := field[1] | ||
333 | |||
334 | i := 0 | ||
335 | |||
336 | for scanner.Scan() { | ||
337 | line := scanner.Text() | ||
338 | if !strings.Contains(line, ":") { | ||
339 | continue | ||
340 | } | ||
341 | field := strings.SplitN(line, ": ", 2) | ||
342 | switch strings.TrimSpace(field[0]) { | ||
343 | case "processor": | ||
344 | v, err := strconv.ParseUint(field[1], 0, 32) | ||
345 | if err != nil { | ||
346 | return nil, err | ||
347 | } | ||
348 | i = int(v) | ||
349 | cpuinfo = append(cpuinfo, CPUInfo{}) // start of the next processor | ||
350 | cpuinfo[i].Processor = uint(v) | ||
351 | cpuinfo[i].VendorID = systemType | ||
352 | case "cpu model": | ||
353 | cpuinfo[i].ModelName = field[1] | ||
354 | case "BogoMIPS": | ||
355 | v, err := strconv.ParseFloat(field[1], 64) | ||
356 | if err != nil { | ||
357 | return nil, err | ||
358 | } | ||
359 | cpuinfo[i].BogoMips = v | ||
360 | } | ||
361 | } | ||
362 | return cpuinfo, nil | ||
363 | } | ||
364 | |||
365 | func parseCPUInfoPPC(info []byte) ([]CPUInfo, error) { | ||
366 | scanner := bufio.NewScanner(bytes.NewReader(info)) | ||
367 | |||
368 | firstLine := firstNonEmptyLine(scanner) | ||
369 | if !strings.HasPrefix(firstLine, "processor") || !strings.Contains(firstLine, ":") { | ||
370 | return nil, errors.New("invalid cpuinfo file: " + firstLine) | ||
371 | } | ||
372 | field := strings.SplitN(firstLine, ": ", 2) | ||
373 | v, err := strconv.ParseUint(field[1], 0, 32) | ||
374 | if err != nil { | ||
375 | return nil, err | ||
376 | } | ||
377 | firstcpu := CPUInfo{Processor: uint(v)} | ||
378 | cpuinfo := []CPUInfo{firstcpu} | ||
379 | i := 0 | ||
380 | |||
381 | for scanner.Scan() { | ||
382 | line := scanner.Text() | ||
383 | if !strings.Contains(line, ":") { | ||
384 | continue | ||
385 | } | ||
386 | field := strings.SplitN(line, ": ", 2) | ||
387 | switch strings.TrimSpace(field[0]) { | ||
388 | case "processor": | ||
389 | cpuinfo = append(cpuinfo, CPUInfo{}) // start of the next processor | ||
390 | i++ | ||
391 | v, err := strconv.ParseUint(field[1], 0, 32) | ||
392 | if err != nil { | ||
393 | return nil, err | ||
394 | } | ||
395 | cpuinfo[i].Processor = uint(v) | ||
396 | case "cpu": | ||
397 | cpuinfo[i].VendorID = field[1] | ||
398 | case "clock": | ||
399 | clock := cpuinfoClockRegexp.FindString(strings.TrimSpace(field[1])) | ||
400 | v, err := strconv.ParseFloat(clock, 64) | ||
401 | if err != nil { | ||
402 | return nil, err | ||
403 | } | ||
404 | cpuinfo[i].CPUMHz = v | ||
405 | } | ||
406 | } | ||
407 | return cpuinfo, nil | ||
408 | } | ||
166 | 409 | ||
410 | // firstNonEmptyLine advances the scanner to the first non-empty line | ||
411 | // and returns the contents of that line | ||
412 | func firstNonEmptyLine(scanner *bufio.Scanner) string { | ||
413 | for scanner.Scan() { | ||
414 | line := scanner.Text() | ||
415 | if strings.TrimSpace(line) != "" { | ||
416 | return line | ||
417 | } | ||
418 | } | ||
419 | return "" | ||
167 | } | 420 | } |
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_arm.go b/vendor/github.com/prometheus/procfs/cpuinfo_arm.go new file mode 100644 index 0000000..8355507 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/cpuinfo_arm.go | |||
@@ -0,0 +1,18 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build linux | ||
15 | |||
16 | package procfs | ||
17 | |||
18 | var parseCPUInfo = parseCPUInfoARM | ||
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_arm64.go b/vendor/github.com/prometheus/procfs/cpuinfo_arm64.go new file mode 100644 index 0000000..4f5d172 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/cpuinfo_arm64.go | |||
@@ -0,0 +1,19 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build linux | ||
15 | // +build arm64 | ||
16 | |||
17 | package procfs | ||
18 | |||
19 | var parseCPUInfo = parseCPUInfoARM | ||
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_default.go b/vendor/github.com/prometheus/procfs/cpuinfo_default.go new file mode 100644 index 0000000..d5bedf9 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/cpuinfo_default.go | |||
@@ -0,0 +1,19 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build linux | ||
15 | // +build 386 amd64 | ||
16 | |||
17 | package procfs | ||
18 | |||
19 | var parseCPUInfo = parseCPUInfoX86 | ||
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_mips.go b/vendor/github.com/prometheus/procfs/cpuinfo_mips.go new file mode 100644 index 0000000..22d93f8 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/cpuinfo_mips.go | |||
@@ -0,0 +1,18 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build linux | ||
15 | |||
16 | package procfs | ||
17 | |||
18 | var parseCPUInfo = parseCPUInfoMips | ||
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_mips64.go b/vendor/github.com/prometheus/procfs/cpuinfo_mips64.go new file mode 100644 index 0000000..22d93f8 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/cpuinfo_mips64.go | |||
@@ -0,0 +1,18 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build linux | ||
15 | |||
16 | package procfs | ||
17 | |||
18 | var parseCPUInfo = parseCPUInfoMips | ||
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_mips64le.go b/vendor/github.com/prometheus/procfs/cpuinfo_mips64le.go new file mode 100644 index 0000000..22d93f8 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/cpuinfo_mips64le.go | |||
@@ -0,0 +1,18 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build linux | ||
15 | |||
16 | package procfs | ||
17 | |||
18 | var parseCPUInfo = parseCPUInfoMips | ||
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_mipsle.go b/vendor/github.com/prometheus/procfs/cpuinfo_mipsle.go new file mode 100644 index 0000000..22d93f8 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/cpuinfo_mipsle.go | |||
@@ -0,0 +1,18 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build linux | ||
15 | |||
16 | package procfs | ||
17 | |||
18 | var parseCPUInfo = parseCPUInfoMips | ||
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_ppc64.go b/vendor/github.com/prometheus/procfs/cpuinfo_ppc64.go new file mode 100644 index 0000000..64aee9c --- /dev/null +++ b/vendor/github.com/prometheus/procfs/cpuinfo_ppc64.go | |||
@@ -0,0 +1,18 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build linux | ||
15 | |||
16 | package procfs | ||
17 | |||
18 | var parseCPUInfo = parseCPUInfoPPC | ||
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_ppc64le.go b/vendor/github.com/prometheus/procfs/cpuinfo_ppc64le.go new file mode 100644 index 0000000..64aee9c --- /dev/null +++ b/vendor/github.com/prometheus/procfs/cpuinfo_ppc64le.go | |||
@@ -0,0 +1,18 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build linux | ||
15 | |||
16 | package procfs | ||
17 | |||
18 | var parseCPUInfo = parseCPUInfoPPC | ||
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_s390x.go b/vendor/github.com/prometheus/procfs/cpuinfo_s390x.go new file mode 100644 index 0000000..26814ee --- /dev/null +++ b/vendor/github.com/prometheus/procfs/cpuinfo_s390x.go | |||
@@ -0,0 +1,18 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build linux | ||
15 | |||
16 | package procfs | ||
17 | |||
18 | var parseCPUInfo = parseCPUInfoS390X | ||
diff --git a/vendor/github.com/prometheus/procfs/fixtures.ttar b/vendor/github.com/prometheus/procfs/fixtures.ttar index 45a7321..868c857 100644 --- a/vendor/github.com/prometheus/procfs/fixtures.ttar +++ b/vendor/github.com/prometheus/procfs/fixtures.ttar | |||
@@ -173,6 +173,283 @@ Lines: 1 | |||
173 | 411605849 93680043 79 | 173 | 411605849 93680043 79 |
174 | Mode: 644 | 174 | Mode: 644 |
175 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 175 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
176 | Path: fixtures/proc/26231/smaps | ||
177 | Lines: 252 | ||
178 | 00400000-00cb1000 r-xp 00000000 fd:01 952273 /bin/alertmanager | ||
179 | Size: 8900 kB | ||
180 | KernelPageSize: 4 kB | ||
181 | MMUPageSize: 4 kB | ||
182 | Rss: 2952 kB | ||
183 | Pss: 2952 kB | ||
184 | Shared_Clean: 0 kB | ||
185 | Shared_Dirty: 0 kB | ||
186 | Private_Clean: 2952 kB | ||
187 | Private_Dirty: 0 kB | ||
188 | Referenced: 2864 kB | ||
189 | Anonymous: 0 kB | ||
190 | LazyFree: 0 kB | ||
191 | AnonHugePages: 0 kB | ||
192 | ShmemPmdMapped: 0 kB | ||
193 | Shared_Hugetlb: 0 kB | ||
194 | Private_Hugetlb: 0 kB | ||
195 | Swap: 0 kB | ||
196 | SwapPss: 0 kB | ||
197 | Locked: 0 kB | ||
198 | VmFlags: rd ex mr mw me dw sd | ||
199 | 00cb1000-016b0000 r--p 008b1000 fd:01 952273 /bin/alertmanager | ||
200 | Size: 10236 kB | ||
201 | KernelPageSize: 4 kB | ||
202 | MMUPageSize: 4 kB | ||
203 | Rss: 6152 kB | ||
204 | Pss: 6152 kB | ||
205 | Shared_Clean: 0 kB | ||
206 | Shared_Dirty: 0 kB | ||
207 | Private_Clean: 6152 kB | ||
208 | Private_Dirty: 0 kB | ||
209 | Referenced: 5308 kB | ||
210 | Anonymous: 0 kB | ||
211 | LazyFree: 0 kB | ||
212 | AnonHugePages: 0 kB | ||
213 | ShmemPmdMapped: 0 kB | ||
214 | Shared_Hugetlb: 0 kB | ||
215 | Private_Hugetlb: 0 kB | ||
216 | Swap: 0 kB | ||
217 | SwapPss: 0 kB | ||
218 | Locked: 0 kB | ||
219 | VmFlags: rd mr mw me dw sd | ||
220 | 016b0000-0171a000 rw-p 012b0000 fd:01 952273 /bin/alertmanager | ||
221 | Size: 424 kB | ||
222 | KernelPageSize: 4 kB | ||
223 | MMUPageSize: 4 kB | ||
224 | Rss: 176 kB | ||
225 | Pss: 176 kB | ||
226 | Shared_Clean: 0 kB | ||
227 | Shared_Dirty: 0 kB | ||
228 | Private_Clean: 84 kB | ||
229 | Private_Dirty: 92 kB | ||
230 | Referenced: 176 kB | ||
231 | Anonymous: 92 kB | ||
232 | LazyFree: 0 kB | ||
233 | AnonHugePages: 0 kB | ||
234 | ShmemPmdMapped: 0 kB | ||
235 | Shared_Hugetlb: 0 kB | ||
236 | Private_Hugetlb: 0 kB | ||
237 | Swap: 12 kB | ||
238 | SwapPss: 12 kB | ||
239 | Locked: 0 kB | ||
240 | VmFlags: rd wr mr mw me dw ac sd | ||
241 | 0171a000-0173f000 rw-p 00000000 00:00 0 | ||
242 | Size: 148 kB | ||
243 | KernelPageSize: 4 kB | ||
244 | MMUPageSize: 4 kB | ||
245 | Rss: 76 kB | ||
246 | Pss: 76 kB | ||
247 | Shared_Clean: 0 kB | ||
248 | Shared_Dirty: 0 kB | ||
249 | Private_Clean: 0 kB | ||
250 | Private_Dirty: 76 kB | ||
251 | Referenced: 76 kB | ||
252 | Anonymous: 76 kB | ||
253 | LazyFree: 0 kB | ||
254 | AnonHugePages: 0 kB | ||
255 | ShmemPmdMapped: 0 kB | ||
256 | Shared_Hugetlb: 0 kB | ||
257 | Private_Hugetlb: 0 kB | ||
258 | Swap: 0 kB | ||
259 | SwapPss: 0 kB | ||
260 | Locked: 0 kB | ||
261 | VmFlags: rd wr mr mw me ac sd | ||
262 | c000000000-c000400000 rw-p 00000000 00:00 0 | ||
263 | Size: 4096 kB | ||
264 | KernelPageSize: 4 kB | ||
265 | MMUPageSize: 4 kB | ||
266 | Rss: 2564 kB | ||
267 | Pss: 2564 kB | ||
268 | Shared_Clean: 0 kB | ||
269 | Shared_Dirty: 0 kB | ||
270 | Private_Clean: 20 kB | ||
271 | Private_Dirty: 2544 kB | ||
272 | Referenced: 2544 kB | ||
273 | Anonymous: 2564 kB | ||
274 | LazyFree: 0 kB | ||
275 | AnonHugePages: 0 kB | ||
276 | ShmemPmdMapped: 0 kB | ||
277 | Shared_Hugetlb: 0 kB | ||
278 | Private_Hugetlb: 0 kB | ||
279 | Swap: 1100 kB | ||
280 | SwapPss: 1100 kB | ||
281 | Locked: 0 kB | ||
282 | VmFlags: rd wr mr mw me ac sd | ||
283 | c000400000-c001600000 rw-p 00000000 00:00 0 | ||
284 | Size: 18432 kB | ||
285 | KernelPageSize: 4 kB | ||
286 | MMUPageSize: 4 kB | ||
287 | Rss: 16024 kB | ||
288 | Pss: 16024 kB | ||
289 | Shared_Clean: 0 kB | ||
290 | Shared_Dirty: 0 kB | ||
291 | Private_Clean: 5864 kB | ||
292 | Private_Dirty: 10160 kB | ||
293 | Referenced: 11944 kB | ||
294 | Anonymous: 16024 kB | ||
295 | LazyFree: 5848 kB | ||
296 | AnonHugePages: 0 kB | ||
297 | ShmemPmdMapped: 0 kB | ||
298 | Shared_Hugetlb: 0 kB | ||
299 | Private_Hugetlb: 0 kB | ||
300 | Swap: 440 kB | ||
301 | SwapPss: 440 kB | ||
302 | Locked: 0 kB | ||
303 | VmFlags: rd wr mr mw me ac sd nh | ||
304 | c001600000-c004000000 rw-p 00000000 00:00 0 | ||
305 | Size: 43008 kB | ||
306 | KernelPageSize: 4 kB | ||
307 | MMUPageSize: 4 kB | ||
308 | Rss: 0 kB | ||
309 | Pss: 0 kB | ||
310 | Shared_Clean: 0 kB | ||
311 | Shared_Dirty: 0 kB | ||
312 | Private_Clean: 0 kB | ||
313 | Private_Dirty: 0 kB | ||
314 | Referenced: 0 kB | ||
315 | Anonymous: 0 kB | ||
316 | LazyFree: 0 kB | ||
317 | AnonHugePages: 0 kB | ||
318 | ShmemPmdMapped: 0 kB | ||
319 | Shared_Hugetlb: 0 kB | ||
320 | Private_Hugetlb: 0 kB | ||
321 | Swap: 0 kB | ||
322 | SwapPss: 0 kB | ||
323 | Locked: 0 kB | ||
324 | VmFlags: rd wr mr mw me ac sd | ||
325 | 7f0ab95ca000-7f0abbb7b000 rw-p 00000000 00:00 0 | ||
326 | Size: 38596 kB | ||
327 | KernelPageSize: 4 kB | ||
328 | MMUPageSize: 4 kB | ||
329 | Rss: 1992 kB | ||
330 | Pss: 1992 kB | ||
331 | Shared_Clean: 0 kB | ||
332 | Shared_Dirty: 0 kB | ||
333 | Private_Clean: 476 kB | ||
334 | Private_Dirty: 1516 kB | ||
335 | Referenced: 1828 kB | ||
336 | Anonymous: 1992 kB | ||
337 | LazyFree: 0 kB | ||
338 | AnonHugePages: 0 kB | ||
339 | ShmemPmdMapped: 0 kB | ||
340 | Shared_Hugetlb: 0 kB | ||
341 | Private_Hugetlb: 0 kB | ||
342 | Swap: 384 kB | ||
343 | SwapPss: 384 kB | ||
344 | Locked: 0 kB | ||
345 | VmFlags: rd wr mr mw me ac sd | ||
346 | 7ffc07ecf000-7ffc07ef0000 rw-p 00000000 00:00 0 [stack] | ||
347 | Size: 132 kB | ||
348 | KernelPageSize: 4 kB | ||
349 | MMUPageSize: 4 kB | ||
350 | Rss: 8 kB | ||
351 | Pss: 8 kB | ||
352 | Shared_Clean: 0 kB | ||
353 | Shared_Dirty: 0 kB | ||
354 | Private_Clean: 0 kB | ||
355 | Private_Dirty: 8 kB | ||
356 | Referenced: 8 kB | ||
357 | Anonymous: 8 kB | ||
358 | LazyFree: 0 kB | ||
359 | AnonHugePages: 0 kB | ||
360 | ShmemPmdMapped: 0 kB | ||
361 | Shared_Hugetlb: 0 kB | ||
362 | Private_Hugetlb: 0 kB | ||
363 | Swap: 4 kB | ||
364 | SwapPss: 4 kB | ||
365 | Locked: 0 kB | ||
366 | VmFlags: rd wr mr mw me gd ac | ||
367 | 7ffc07f9e000-7ffc07fa1000 r--p 00000000 00:00 0 [vvar] | ||
368 | Size: 12 kB | ||
369 | KernelPageSize: 4 kB | ||
370 | MMUPageSize: 4 kB | ||
371 | Rss: 0 kB | ||
372 | Pss: 0 kB | ||
373 | Shared_Clean: 0 kB | ||
374 | Shared_Dirty: 0 kB | ||
375 | Private_Clean: 0 kB | ||
376 | Private_Dirty: 0 kB | ||
377 | Referenced: 0 kB | ||
378 | Anonymous: 0 kB | ||
379 | LazyFree: 0 kB | ||
380 | AnonHugePages: 0 kB | ||
381 | ShmemPmdMapped: 0 kB | ||
382 | Shared_Hugetlb: 0 kB | ||
383 | Private_Hugetlb: 0 kB | ||
384 | Swap: 0 kB | ||
385 | SwapPss: 0 kB | ||
386 | Locked: 0 kB | ||
387 | VmFlags: rd mr pf io de dd sd | ||
388 | 7ffc07fa1000-7ffc07fa3000 r-xp 00000000 00:00 0 [vdso] | ||
389 | Size: 8 kB | ||
390 | KernelPageSize: 4 kB | ||
391 | MMUPageSize: 4 kB | ||
392 | Rss: 4 kB | ||
393 | Pss: 0 kB | ||
394 | Shared_Clean: 4 kB | ||
395 | Shared_Dirty: 0 kB | ||
396 | Private_Clean: 0 kB | ||
397 | Private_Dirty: 0 kB | ||
398 | Referenced: 4 kB | ||
399 | Anonymous: 0 kB | ||
400 | LazyFree: 0 kB | ||
401 | AnonHugePages: 0 kB | ||
402 | ShmemPmdMapped: 0 kB | ||
403 | Shared_Hugetlb: 0 kB | ||
404 | Private_Hugetlb: 0 kB | ||
405 | Swap: 0 kB | ||
406 | SwapPss: 0 kB | ||
407 | Locked: 0 kB | ||
408 | VmFlags: rd ex mr mw me de sd | ||
409 | ffffffffff600000-ffffffffff601000 r-xp 00000000 00:00 0 [vsyscall] | ||
410 | Size: 4 kB | ||
411 | KernelPageSize: 4 kB | ||
412 | MMUPageSize: 4 kB | ||
413 | Rss: 0 kB | ||
414 | Pss: 0 kB | ||
415 | Shared_Clean: 0 kB | ||
416 | Shared_Dirty: 0 kB | ||
417 | Private_Clean: 0 kB | ||
418 | Private_Dirty: 0 kB | ||
419 | Referenced: 0 kB | ||
420 | Anonymous: 0 kB | ||
421 | LazyFree: 0 kB | ||
422 | AnonHugePages: 0 kB | ||
423 | ShmemPmdMapped: 0 kB | ||
424 | Shared_Hugetlb: 0 kB | ||
425 | Private_Hugetlb: 0 kB | ||
426 | Swap: 0 kB | ||
427 | SwapPss: 0 kB | ||
428 | Locked: 0 kB | ||
429 | VmFlags: rd ex | ||
430 | Mode: 644 | ||
431 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
432 | Path: fixtures/proc/26231/smaps_rollup | ||
433 | Lines: 17 | ||
434 | 00400000-ffffffffff601000 ---p 00000000 00:00 0 [rollup] | ||
435 | Rss: 29948 kB | ||
436 | Pss: 29944 kB | ||
437 | Shared_Clean: 4 kB | ||
438 | Shared_Dirty: 0 kB | ||
439 | Private_Clean: 15548 kB | ||
440 | Private_Dirty: 14396 kB | ||
441 | Referenced: 24752 kB | ||
442 | Anonymous: 20756 kB | ||
443 | LazyFree: 5848 kB | ||
444 | AnonHugePages: 0 kB | ||
445 | ShmemPmdMapped: 0 kB | ||
446 | Shared_Hugetlb: 0 kB | ||
447 | Private_Hugetlb: 0 kB | ||
448 | Swap: 1940 kB | ||
449 | SwapPss: 1940 kB | ||
450 | Locked: 0 kB | ||
451 | Mode: 644 | ||
452 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
176 | Path: fixtures/proc/26231/stat | 453 | Path: fixtures/proc/26231/stat |
177 | Lines: 1 | 454 | Lines: 1 |
178 | 26231 (vim) R 5392 7446 5392 34835 7446 4218880 32533 309516 26 82 1677 44 158 99 20 0 1 0 82375 56274944 1981 18446744073709551615 4194304 6294284 140736914091744 140736914087944 139965136429984 0 0 12288 1870679807 0 0 0 17 0 0 0 31 0 0 8391624 8481048 16420864 140736914093252 140736914093279 140736914093279 140736914096107 0 | 455 | 26231 (vim) R 5392 7446 5392 34835 7446 4218880 32533 309516 26 82 1677 44 158 99 20 0 1 0 82375 56274944 1981 18446744073709551615 4194304 6294284 140736914091744 140736914087944 139965136429984 0 0 12288 1870679807 0 0 0 17 0 0 0 31 0 0 8391624 8481048 16420864 140736914093252 140736914093279 140736914093279 140736914096107 0 |
@@ -235,6 +512,11 @@ voluntary_ctxt_switches: 4742839 | |||
235 | nonvoluntary_ctxt_switches: 1727500 | 512 | nonvoluntary_ctxt_switches: 1727500 |
236 | Mode: 644 | 513 | Mode: 644 |
237 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 514 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
515 | Path: fixtures/proc/26231/wchan | ||
516 | Lines: 1 | ||
517 | poll_schedule_timeoutEOF | ||
518 | Mode: 664 | ||
519 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
238 | Directory: fixtures/proc/26232 | 520 | Directory: fixtures/proc/26232 |
239 | Mode: 755 | 521 | Mode: 755 |
240 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 522 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
@@ -310,6 +592,11 @@ Lines: 1 | |||
310 | 33 (ata_sff) S 2 0 0 0 -1 69238880 0 0 0 0 0 0 0 0 0 -20 1 0 5 0 0 18446744073709551615 0 0 0 0 0 0 0 2147483647 0 18446744073709551615 0 0 17 1 0 0 0 0 0 0 0 0 0 0 0 0 0 | 592 | 33 (ata_sff) S 2 0 0 0 -1 69238880 0 0 0 0 0 0 0 0 0 -20 1 0 5 0 0 18446744073709551615 0 0 0 0 0 0 0 2147483647 0 18446744073709551615 0 0 17 1 0 0 0 0 0 0 0 0 0 0 0 0 0 |
311 | Mode: 644 | 593 | Mode: 644 |
312 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 594 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
595 | Path: fixtures/proc/26232/wchan | ||
596 | Lines: 1 | ||
597 | 0EOF | ||
598 | Mode: 664 | ||
599 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
313 | Directory: fixtures/proc/26233 | 600 | Directory: fixtures/proc/26233 |
314 | Mode: 755 | 601 | Mode: 755 |
315 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 602 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
@@ -1554,7 +1841,7 @@ max keysize : 32 | |||
1554 | Mode: 444 | 1841 | Mode: 444 |
1555 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 1842 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
1556 | Path: fixtures/proc/diskstats | 1843 | Path: fixtures/proc/diskstats |
1557 | Lines: 49 | 1844 | Lines: 52 |
1558 | 1 0 ram0 0 0 0 0 0 0 0 0 0 0 0 | 1845 | 1 0 ram0 0 0 0 0 0 0 0 0 0 0 0 |
1559 | 1 1 ram1 0 0 0 0 0 0 0 0 0 0 0 | 1846 | 1 1 ram1 0 0 0 0 0 0 0 0 0 0 0 |
1560 | 1 2 ram2 0 0 0 0 0 0 0 0 0 0 0 | 1847 | 1 2 ram2 0 0 0 0 0 0 0 0 0 0 0 |
@@ -1604,11 +1891,45 @@ Lines: 49 | |||
1604 | 8 0 sdb 326552 841 9657779 84 41822 2895 1972905 5007 0 60730 67070 68851 0 1925173784 11130 | 1891 | 8 0 sdb 326552 841 9657779 84 41822 2895 1972905 5007 0 60730 67070 68851 0 1925173784 11130 |
1605 | 8 1 sdb1 231 3 34466 4 24 23 106 0 0 64 64 0 0 0 0 | 1892 | 8 1 sdb1 231 3 34466 4 24 23 106 0 0 64 64 0 0 0 0 |
1606 | 8 2 sdb2 326310 838 9622281 67 40726 2872 1972799 4924 0 58250 64567 68851 0 1925173784 11130 | 1893 | 8 2 sdb2 326310 838 9622281 67 40726 2872 1972799 4924 0 58250 64567 68851 0 1925173784 11130 |
1894 | 8 0 sdc 14202 71 579164 21861 2995 1589 180500 40875 0 11628 55200 0 0 0 0 127 182 | ||
1895 | 8 1 sdc1 1027 0 13795 5021 2 0 4096 3 0 690 4579 0 0 0 0 0 0 | ||
1896 | 8 2 sdc2 13126 71 561749 16802 2830 1589 176404 40620 0 10931 50449 0 0 0 0 0 0 | ||
1607 | Mode: 664 | 1897 | Mode: 664 |
1608 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 1898 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
1609 | Directory: fixtures/proc/fs | 1899 | Directory: fixtures/proc/fs |
1610 | Mode: 755 | 1900 | Mode: 755 |
1611 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 1901 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
1902 | Directory: fixtures/proc/fs/fscache | ||
1903 | Mode: 755 | ||
1904 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
1905 | Path: fixtures/proc/fs/fscache/stats | ||
1906 | Lines: 24 | ||
1907 | FS-Cache statistics | ||
1908 | Cookies: idx=3 dat=67877 spc=0 | ||
1909 | Objects: alc=67473 nal=0 avl=67473 ded=388 | ||
1910 | ChkAux : non=12 ok=33 upd=44 obs=55 | ||
1911 | Pages : mrk=547164 unc=364577 | ||
1912 | Acquire: n=67880 nul=98 noc=25 ok=67780 nbf=39 oom=26 | ||
1913 | Lookups: n=67473 neg=67470 pos=58 crt=67473 tmo=85 | ||
1914 | Invals : n=14 run=13 | ||
1915 | Updates: n=7 nul=3 run=8 | ||
1916 | Relinqs: n=394 nul=1 wcr=2 rtr=3 | ||
1917 | AttrChg: n=6 ok=5 nbf=4 oom=3 run=2 | ||
1918 | Allocs : n=20 ok=19 wt=18 nbf=17 int=16 | ||
1919 | Allocs : ops=15 owt=14 abt=13 | ||
1920 | Retrvls: n=151959 ok=82823 wt=23467 nod=69136 nbf=15 int=69 oom=43 | ||
1921 | Retrvls: ops=151959 owt=42747 abt=44 | ||
1922 | Stores : n=225565 ok=225565 agn=12 nbf=13 oom=14 | ||
1923 | Stores : ops=69156 run=294721 pgs=225565 rxd=225565 olm=43 | ||
1924 | VmScan : nos=364512 gon=2 bsy=43 can=12 wt=66 | ||
1925 | Ops : pend=42753 run=221129 enq=628798 can=11 rej=88 | ||
1926 | Ops : ini=377538 dfr=27 rel=377538 gc=37 | ||
1927 | CacheOp: alo=1 luo=2 luc=3 gro=4 | ||
1928 | CacheOp: inv=5 upo=6 dro=7 pto=8 atc=9 syn=10 | ||
1929 | CacheOp: rap=11 ras=12 alp=13 als=14 wrp=15 ucp=16 dsp=17 | ||
1930 | CacheEv: nsp=18 stl=19 rtr=20 cul=21EOF | ||
1931 | Mode: 644 | ||
1932 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
1612 | Directory: fixtures/proc/fs/xfs | 1933 | Directory: fixtures/proc/fs/xfs |
1613 | Mode: 755 | 1934 | Mode: 755 |
1614 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 1935 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
@@ -2025,6 +2346,32 @@ Mode: 644 | |||
2025 | Directory: fixtures/proc/sys | 2346 | Directory: fixtures/proc/sys |
2026 | Mode: 775 | 2347 | Mode: 775 |
2027 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 2348 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
2349 | Directory: fixtures/proc/sys/kernel | ||
2350 | Mode: 775 | ||
2351 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2352 | Directory: fixtures/proc/sys/kernel/random | ||
2353 | Mode: 755 | ||
2354 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2355 | Path: fixtures/proc/sys/kernel/random/entropy_avail | ||
2356 | Lines: 1 | ||
2357 | 3943 | ||
2358 | Mode: 644 | ||
2359 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2360 | Path: fixtures/proc/sys/kernel/random/poolsize | ||
2361 | Lines: 1 | ||
2362 | 4096 | ||
2363 | Mode: 644 | ||
2364 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2365 | Path: fixtures/proc/sys/kernel/random/urandom_min_reseed_secs | ||
2366 | Lines: 1 | ||
2367 | 60 | ||
2368 | Mode: 644 | ||
2369 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2370 | Path: fixtures/proc/sys/kernel/random/write_wakeup_threshold | ||
2371 | Lines: 1 | ||
2372 | 3072 | ||
2373 | Mode: 644 | ||
2374 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2028 | Directory: fixtures/proc/sys/vm | 2375 | Directory: fixtures/proc/sys/vm |
2029 | Mode: 775 | 2376 | Mode: 775 |
2030 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 2377 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
@@ -2526,6 +2873,237 @@ Mode: 664 | |||
2526 | Directory: fixtures/sys/block/sda | 2873 | Directory: fixtures/sys/block/sda |
2527 | Mode: 775 | 2874 | Mode: 775 |
2528 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 2875 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
2876 | Directory: fixtures/sys/block/sda/queue | ||
2877 | Mode: 755 | ||
2878 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2879 | Path: fixtures/sys/block/sda/queue/add_random | ||
2880 | Lines: 1 | ||
2881 | 1 | ||
2882 | Mode: 644 | ||
2883 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2884 | Path: fixtures/sys/block/sda/queue/chunk_sectors | ||
2885 | Lines: 1 | ||
2886 | 0 | ||
2887 | Mode: 444 | ||
2888 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2889 | Path: fixtures/sys/block/sda/queue/dax | ||
2890 | Lines: 1 | ||
2891 | 0 | ||
2892 | Mode: 444 | ||
2893 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2894 | Path: fixtures/sys/block/sda/queue/discard_granularity | ||
2895 | Lines: 1 | ||
2896 | 0 | ||
2897 | Mode: 444 | ||
2898 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2899 | Path: fixtures/sys/block/sda/queue/discard_max_bytes | ||
2900 | Lines: 1 | ||
2901 | 0 | ||
2902 | Mode: 644 | ||
2903 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2904 | Path: fixtures/sys/block/sda/queue/discard_max_hw_bytes | ||
2905 | Lines: 1 | ||
2906 | 0 | ||
2907 | Mode: 444 | ||
2908 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2909 | Path: fixtures/sys/block/sda/queue/discard_zeroes_data | ||
2910 | Lines: 1 | ||
2911 | 0 | ||
2912 | Mode: 444 | ||
2913 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2914 | Path: fixtures/sys/block/sda/queue/fua | ||
2915 | Lines: 1 | ||
2916 | 0 | ||
2917 | Mode: 444 | ||
2918 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2919 | Path: fixtures/sys/block/sda/queue/hw_sector_size | ||
2920 | Lines: 1 | ||
2921 | 512 | ||
2922 | Mode: 444 | ||
2923 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2924 | Path: fixtures/sys/block/sda/queue/io_poll | ||
2925 | Lines: 1 | ||
2926 | 0 | ||
2927 | Mode: 644 | ||
2928 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2929 | Path: fixtures/sys/block/sda/queue/io_poll_delay | ||
2930 | Lines: 1 | ||
2931 | -1 | ||
2932 | Mode: 644 | ||
2933 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2934 | Path: fixtures/sys/block/sda/queue/io_timeout | ||
2935 | Lines: 1 | ||
2936 | 30000 | ||
2937 | Mode: 644 | ||
2938 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2939 | Directory: fixtures/sys/block/sda/queue/iosched | ||
2940 | Mode: 755 | ||
2941 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2942 | Path: fixtures/sys/block/sda/queue/iosched/back_seek_max | ||
2943 | Lines: 1 | ||
2944 | 16384 | ||
2945 | Mode: 644 | ||
2946 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2947 | Path: fixtures/sys/block/sda/queue/iosched/back_seek_penalty | ||
2948 | Lines: 1 | ||
2949 | 2 | ||
2950 | Mode: 644 | ||
2951 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2952 | Path: fixtures/sys/block/sda/queue/iosched/fifo_expire_async | ||
2953 | Lines: 1 | ||
2954 | 250 | ||
2955 | Mode: 644 | ||
2956 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2957 | Path: fixtures/sys/block/sda/queue/iosched/fifo_expire_sync | ||
2958 | Lines: 1 | ||
2959 | 125 | ||
2960 | Mode: 644 | ||
2961 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2962 | Path: fixtures/sys/block/sda/queue/iosched/low_latency | ||
2963 | Lines: 1 | ||
2964 | 1 | ||
2965 | Mode: 644 | ||
2966 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2967 | Path: fixtures/sys/block/sda/queue/iosched/max_budget | ||
2968 | Lines: 1 | ||
2969 | 0 | ||
2970 | Mode: 644 | ||
2971 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2972 | Path: fixtures/sys/block/sda/queue/iosched/slice_idle | ||
2973 | Lines: 1 | ||
2974 | 8 | ||
2975 | Mode: 644 | ||
2976 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2977 | Path: fixtures/sys/block/sda/queue/iosched/slice_idle_us | ||
2978 | Lines: 1 | ||
2979 | 8000 | ||
2980 | Mode: 644 | ||
2981 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2982 | Path: fixtures/sys/block/sda/queue/iosched/strict_guarantees | ||
2983 | Lines: 1 | ||
2984 | 0 | ||
2985 | Mode: 644 | ||
2986 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2987 | Path: fixtures/sys/block/sda/queue/iosched/timeout_sync | ||
2988 | Lines: 1 | ||
2989 | 125 | ||
2990 | Mode: 644 | ||
2991 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2992 | Path: fixtures/sys/block/sda/queue/iostats | ||
2993 | Lines: 1 | ||
2994 | 1 | ||
2995 | Mode: 644 | ||
2996 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2997 | Path: fixtures/sys/block/sda/queue/logical_block_size | ||
2998 | Lines: 1 | ||
2999 | 512 | ||
3000 | Mode: 444 | ||
3001 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3002 | Path: fixtures/sys/block/sda/queue/max_discard_segments | ||
3003 | Lines: 1 | ||
3004 | 1 | ||
3005 | Mode: 444 | ||
3006 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3007 | Path: fixtures/sys/block/sda/queue/max_hw_sectors_kb | ||
3008 | Lines: 1 | ||
3009 | 32767 | ||
3010 | Mode: 444 | ||
3011 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3012 | Path: fixtures/sys/block/sda/queue/max_integrity_segments | ||
3013 | Lines: 1 | ||
3014 | 0 | ||
3015 | Mode: 444 | ||
3016 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3017 | Path: fixtures/sys/block/sda/queue/max_sectors_kb | ||
3018 | Lines: 1 | ||
3019 | 1280 | ||
3020 | Mode: 644 | ||
3021 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3022 | Path: fixtures/sys/block/sda/queue/max_segment_size | ||
3023 | Lines: 1 | ||
3024 | 65536 | ||
3025 | Mode: 444 | ||
3026 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3027 | Path: fixtures/sys/block/sda/queue/max_segments | ||
3028 | Lines: 1 | ||
3029 | 168 | ||
3030 | Mode: 444 | ||
3031 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3032 | Path: fixtures/sys/block/sda/queue/minimum_io_size | ||
3033 | Lines: 1 | ||
3034 | 512 | ||
3035 | Mode: 444 | ||
3036 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3037 | Path: fixtures/sys/block/sda/queue/nomerges | ||
3038 | Lines: 1 | ||
3039 | 0 | ||
3040 | Mode: 644 | ||
3041 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3042 | Path: fixtures/sys/block/sda/queue/nr_requests | ||
3043 | Lines: 1 | ||
3044 | 64 | ||
3045 | Mode: 644 | ||
3046 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3047 | Path: fixtures/sys/block/sda/queue/nr_zones | ||
3048 | Lines: 1 | ||
3049 | 0 | ||
3050 | Mode: 444 | ||
3051 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3052 | Path: fixtures/sys/block/sda/queue/optimal_io_size | ||
3053 | Lines: 1 | ||
3054 | 0 | ||
3055 | Mode: 444 | ||
3056 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3057 | Path: fixtures/sys/block/sda/queue/physical_block_size | ||
3058 | Lines: 1 | ||
3059 | 512 | ||
3060 | Mode: 444 | ||
3061 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3062 | Path: fixtures/sys/block/sda/queue/read_ahead_kb | ||
3063 | Lines: 1 | ||
3064 | 128 | ||
3065 | Mode: 644 | ||
3066 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3067 | Path: fixtures/sys/block/sda/queue/rotational | ||
3068 | Lines: 1 | ||
3069 | 1 | ||
3070 | Mode: 644 | ||
3071 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3072 | Path: fixtures/sys/block/sda/queue/rq_affinity | ||
3073 | Lines: 1 | ||
3074 | 1 | ||
3075 | Mode: 644 | ||
3076 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3077 | Path: fixtures/sys/block/sda/queue/scheduler | ||
3078 | Lines: 1 | ||
3079 | mq-deadline kyber [bfq] none | ||
3080 | Mode: 644 | ||
3081 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3082 | Path: fixtures/sys/block/sda/queue/wbt_lat_usec | ||
3083 | Lines: 1 | ||
3084 | 75000 | ||
3085 | Mode: 644 | ||
3086 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3087 | Path: fixtures/sys/block/sda/queue/write_cache | ||
3088 | Lines: 1 | ||
3089 | write back | ||
3090 | Mode: 644 | ||
3091 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3092 | Path: fixtures/sys/block/sda/queue/write_same_max_bytes | ||
3093 | Lines: 1 | ||
3094 | 0 | ||
3095 | Mode: 444 | ||
3096 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3097 | Path: fixtures/sys/block/sda/queue/write_zeroes_max_bytes | ||
3098 | Lines: 1 | ||
3099 | 0 | ||
3100 | Mode: 444 | ||
3101 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3102 | Path: fixtures/sys/block/sda/queue/zoned | ||
3103 | Lines: 1 | ||
3104 | none | ||
3105 | Mode: 444 | ||
3106 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2529 | Path: fixtures/sys/block/sda/stat | 3107 | Path: fixtures/sys/block/sda/stat |
2530 | Lines: 1 | 3108 | Lines: 1 |
2531 | 9652963 396792 759304206 412943 8422549 6731723 286915323 13947418 0 5658367 19174573 1 2 3 12 | 3109 | 9652963 396792 759304206 412943 8422549 6731723 286915323 13947418 0 5658367 19174573 1 2 3 12 |
@@ -2534,6 +3112,140 @@ Mode: 664 | |||
2534 | Directory: fixtures/sys/class | 3112 | Directory: fixtures/sys/class |
2535 | Mode: 775 | 3113 | Mode: 775 |
2536 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 3114 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
3115 | Directory: fixtures/sys/class/fc_host | ||
3116 | Mode: 755 | ||
3117 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3118 | Directory: fixtures/sys/class/fc_host/host0 | ||
3119 | Mode: 755 | ||
3120 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3121 | Path: fixtures/sys/class/fc_host/host0/dev_loss_tmo | ||
3122 | Lines: 1 | ||
3123 | 30 | ||
3124 | Mode: 644 | ||
3125 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3126 | Path: fixtures/sys/class/fc_host/host0/fabric_name | ||
3127 | Lines: 1 | ||
3128 | 0x0 | ||
3129 | Mode: 644 | ||
3130 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3131 | Path: fixtures/sys/class/fc_host/host0/node_name | ||
3132 | Lines: 1 | ||
3133 | 0x2000e0071bce95f2 | ||
3134 | Mode: 644 | ||
3135 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3136 | Path: fixtures/sys/class/fc_host/host0/port_id | ||
3137 | Lines: 1 | ||
3138 | 0x000002 | ||
3139 | Mode: 644 | ||
3140 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3141 | Path: fixtures/sys/class/fc_host/host0/port_name | ||
3142 | Lines: 1 | ||
3143 | 0x1000e0071bce95f2 | ||
3144 | Mode: 644 | ||
3145 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3146 | Path: fixtures/sys/class/fc_host/host0/port_state | ||
3147 | Lines: 1 | ||
3148 | Online | ||
3149 | Mode: 644 | ||
3150 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3151 | Path: fixtures/sys/class/fc_host/host0/port_type | ||
3152 | Lines: 1 | ||
3153 | Point-To-Point (direct nport connection) | ||
3154 | Mode: 644 | ||
3155 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3156 | Path: fixtures/sys/class/fc_host/host0/speed | ||
3157 | Lines: 1 | ||
3158 | 16 Gbit | ||
3159 | Mode: 644 | ||
3160 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3161 | Directory: fixtures/sys/class/fc_host/host0/statistics | ||
3162 | Mode: 755 | ||
3163 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3164 | Path: fixtures/sys/class/fc_host/host0/statistics/dumped_frames | ||
3165 | Lines: 1 | ||
3166 | 0xffffffffffffffff | ||
3167 | Mode: 644 | ||
3168 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3169 | Path: fixtures/sys/class/fc_host/host0/statistics/error_frames | ||
3170 | Lines: 1 | ||
3171 | 0x0 | ||
3172 | Mode: 644 | ||
3173 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3174 | Path: fixtures/sys/class/fc_host/host0/statistics/fcp_packet_aborts | ||
3175 | Lines: 1 | ||
3176 | 0x13 | ||
3177 | Mode: 644 | ||
3178 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3179 | Path: fixtures/sys/class/fc_host/host0/statistics/invalid_crc_count | ||
3180 | Lines: 1 | ||
3181 | 0x2 | ||
3182 | Mode: 644 | ||
3183 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3184 | Path: fixtures/sys/class/fc_host/host0/statistics/invalid_tx_word_count | ||
3185 | Lines: 1 | ||
3186 | 0x8 | ||
3187 | Mode: 644 | ||
3188 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3189 | Path: fixtures/sys/class/fc_host/host0/statistics/link_failure_count | ||
3190 | Lines: 1 | ||
3191 | 0x9 | ||
3192 | Mode: 644 | ||
3193 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3194 | Path: fixtures/sys/class/fc_host/host0/statistics/loss_of_signal_count | ||
3195 | Lines: 1 | ||
3196 | 0x11 | ||
3197 | Mode: 644 | ||
3198 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3199 | Path: fixtures/sys/class/fc_host/host0/statistics/loss_of_sync_count | ||
3200 | Lines: 1 | ||
3201 | 0x10 | ||
3202 | Mode: 644 | ||
3203 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3204 | Path: fixtures/sys/class/fc_host/host0/statistics/nos_count | ||
3205 | Lines: 1 | ||
3206 | 0x12 | ||
3207 | Mode: 644 | ||
3208 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3209 | Path: fixtures/sys/class/fc_host/host0/statistics/rx_frames | ||
3210 | Lines: 1 | ||
3211 | 0x3 | ||
3212 | Mode: 644 | ||
3213 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3214 | Path: fixtures/sys/class/fc_host/host0/statistics/rx_words | ||
3215 | Lines: 1 | ||
3216 | 0x4 | ||
3217 | Mode: 644 | ||
3218 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3219 | Path: fixtures/sys/class/fc_host/host0/statistics/seconds_since_last_reset | ||
3220 | Lines: 1 | ||
3221 | 0x7 | ||
3222 | Mode: 644 | ||
3223 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3224 | Path: fixtures/sys/class/fc_host/host0/statistics/tx_frames | ||
3225 | Lines: 1 | ||
3226 | 0x5 | ||
3227 | Mode: 644 | ||
3228 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3229 | Path: fixtures/sys/class/fc_host/host0/statistics/tx_words | ||
3230 | Lines: 1 | ||
3231 | 0x6 | ||
3232 | Mode: 644 | ||
3233 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3234 | Path: fixtures/sys/class/fc_host/host0/supported_classes | ||
3235 | Lines: 1 | ||
3236 | Class 3 | ||
3237 | Mode: 644 | ||
3238 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3239 | Path: fixtures/sys/class/fc_host/host0/supported_speeds | ||
3240 | Lines: 1 | ||
3241 | 4 Gbit, 8 Gbit, 16 Gbit | ||
3242 | Mode: 644 | ||
3243 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
3244 | Path: fixtures/sys/class/fc_host/host0/symbolic_name | ||
3245 | Lines: 1 | ||
3246 | Emulex SN1100E2P FV12.4.270.3 DV12.4.0.0. HN:gotest. OS:Linux | ||
3247 | Mode: 644 | ||
3248 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2537 | Directory: fixtures/sys/class/infiniband | 3249 | Directory: fixtures/sys/class/infiniband |
2538 | Mode: 755 | 3250 | Mode: 755 |
2539 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 3251 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
@@ -2564,6 +3276,11 @@ Mode: 755 | |||
2564 | Directory: fixtures/sys/class/infiniband/mlx4_0/ports/1/counters | 3276 | Directory: fixtures/sys/class/infiniband/mlx4_0/ports/1/counters |
2565 | Mode: 755 | 3277 | Mode: 755 |
2566 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 3278 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
3279 | Path: fixtures/sys/class/infiniband/mlx4_0/ports/1/counters/VL15_dropped | ||
3280 | Lines: 1 | ||
3281 | 0 | ||
3282 | Mode: 664 | ||
3283 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2567 | Path: fixtures/sys/class/infiniband/mlx4_0/ports/1/counters/excessive_buffer_overrun_errors | 3284 | Path: fixtures/sys/class/infiniband/mlx4_0/ports/1/counters/excessive_buffer_overrun_errors |
2568 | Lines: 1 | 3285 | Lines: 1 |
2569 | 0 | 3286 | 0 |
@@ -2665,6 +3382,11 @@ Mode: 755 | |||
2665 | Directory: fixtures/sys/class/infiniband/mlx4_0/ports/2/counters | 3382 | Directory: fixtures/sys/class/infiniband/mlx4_0/ports/2/counters |
2666 | Mode: 755 | 3383 | Mode: 755 |
2667 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 3384 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
3385 | Path: fixtures/sys/class/infiniband/mlx4_0/ports/2/counters/VL15_dropped | ||
3386 | Lines: 1 | ||
3387 | 0 | ||
3388 | Mode: 664 | ||
3389 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
2668 | Path: fixtures/sys/class/infiniband/mlx4_0/ports/2/counters/excessive_buffer_overrun_errors | 3390 | Path: fixtures/sys/class/infiniband/mlx4_0/ports/2/counters/excessive_buffer_overrun_errors |
2669 | Lines: 1 | 3391 | Lines: 1 |
2670 | 0 | 3392 | 0 |
@@ -3109,7 +3831,7 @@ Mode: 664 | |||
3109 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 3831 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
3110 | Path: fixtures/sys/class/thermal/thermal_zone1/temp | 3832 | Path: fixtures/sys/class/thermal/thermal_zone1/temp |
3111 | Lines: 1 | 3833 | Lines: 1 |
3112 | 44000 | 3834 | -44000 |
3113 | Mode: 664 | 3835 | Mode: 664 |
3114 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 3836 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
3115 | Path: fixtures/sys/class/thermal/thermal_zone1/type | 3837 | Path: fixtures/sys/class/thermal/thermal_zone1/type |
@@ -4287,6 +5009,17 @@ Lines: 1 | |||
4287 | 0 | 5009 | 0 |
4288 | Mode: 644 | 5010 | Mode: 644 |
4289 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | 5011 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
5012 | Path: fixtures/sys/fs/bcache/deaddd54-c735-46d5-868e-f331c5fd7c74/bdev0/writeback_rate_debug | ||
5013 | Lines: 7 | ||
5014 | rate: 1.1M/sec | ||
5015 | dirty: 20.4G | ||
5016 | target: 20.4G | ||
5017 | proportional: 427.5k | ||
5018 | integral: 790.0k | ||
5019 | change: 321.5k/sec | ||
5020 | next io: 17ms | ||
5021 | Mode: 644 | ||
5022 | # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
4290 | Path: fixtures/sys/fs/bcache/deaddd54-c735-46d5-868e-f331c5fd7c74/btree_cache_size | 5023 | Path: fixtures/sys/fs/bcache/deaddd54-c735-46d5-868e-f331c5fd7c74/btree_cache_size |
4291 | Lines: 1 | 5024 | Lines: 1 |
4292 | 0 | 5025 | 0 |
diff --git a/vendor/github.com/prometheus/procfs/fscache.go b/vendor/github.com/prometheus/procfs/fscache.go new file mode 100644 index 0000000..8783cf3 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/fscache.go | |||
@@ -0,0 +1,422 @@ | |||
1 | // Copyright 2019 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | package procfs | ||
15 | |||
16 | import ( | ||
17 | "bufio" | ||
18 | "bytes" | ||
19 | "fmt" | ||
20 | "io" | ||
21 | "strconv" | ||
22 | "strings" | ||
23 | |||
24 | "github.com/prometheus/procfs/internal/util" | ||
25 | ) | ||
26 | |||
27 | // Fscacheinfo represents fscache statistics. | ||
28 | type Fscacheinfo struct { | ||
29 | // Number of index cookies allocated | ||
30 | IndexCookiesAllocated uint64 | ||
31 | // data storage cookies allocated | ||
32 | DataStorageCookiesAllocated uint64 | ||
33 | // Number of special cookies allocated | ||
34 | SpecialCookiesAllocated uint64 | ||
35 | // Number of objects allocated | ||
36 | ObjectsAllocated uint64 | ||
37 | // Number of object allocation failures | ||
38 | ObjectAllocationsFailure uint64 | ||
39 | // Number of objects that reached the available state | ||
40 | ObjectsAvailable uint64 | ||
41 | // Number of objects that reached the dead state | ||
42 | ObjectsDead uint64 | ||
43 | // Number of objects that didn't have a coherency check | ||
44 | ObjectsWithoutCoherencyCheck uint64 | ||
45 | // Number of objects that passed a coherency check | ||
46 | ObjectsWithCoherencyCheck uint64 | ||
47 | // Number of objects that needed a coherency data update | ||
48 | ObjectsNeedCoherencyCheckUpdate uint64 | ||
49 | // Number of objects that were declared obsolete | ||
50 | ObjectsDeclaredObsolete uint64 | ||
51 | // Number of pages marked as being cached | ||
52 | PagesMarkedAsBeingCached uint64 | ||
53 | // Number of uncache page requests seen | ||
54 | UncachePagesRequestSeen uint64 | ||
55 | // Number of acquire cookie requests seen | ||
56 | AcquireCookiesRequestSeen uint64 | ||
57 | // Number of acq reqs given a NULL parent | ||
58 | AcquireRequestsWithNullParent uint64 | ||
59 | // Number of acq reqs rejected due to no cache available | ||
60 | AcquireRequestsRejectedNoCacheAvailable uint64 | ||
61 | // Number of acq reqs succeeded | ||
62 | AcquireRequestsSucceeded uint64 | ||
63 | // Number of acq reqs rejected due to error | ||
64 | AcquireRequestsRejectedDueToError uint64 | ||
65 | // Number of acq reqs failed on ENOMEM | ||
66 | AcquireRequestsFailedDueToEnomem uint64 | ||
67 | // Number of lookup calls made on cache backends | ||
68 | LookupsNumber uint64 | ||
69 | // Number of negative lookups made | ||
70 | LookupsNegative uint64 | ||
71 | // Number of positive lookups made | ||
72 | LookupsPositive uint64 | ||
73 | // Number of objects created by lookup | ||
74 | ObjectsCreatedByLookup uint64 | ||
75 | // Number of lookups timed out and requeued | ||
76 | LookupsTimedOutAndRequed uint64 | ||
77 | InvalidationsNumber uint64 | ||
78 | InvalidationsRunning uint64 | ||
79 | // Number of update cookie requests seen | ||
80 | UpdateCookieRequestSeen uint64 | ||
81 | // Number of upd reqs given a NULL parent | ||
82 | UpdateRequestsWithNullParent uint64 | ||
83 | // Number of upd reqs granted CPU time | ||
84 | UpdateRequestsRunning uint64 | ||
85 | // Number of relinquish cookie requests seen | ||
86 | RelinquishCookiesRequestSeen uint64 | ||
87 | // Number of rlq reqs given a NULL parent | ||
88 | RelinquishCookiesWithNullParent uint64 | ||
89 | // Number of rlq reqs waited on completion of creation | ||
90 | RelinquishRequestsWaitingCompleteCreation uint64 | ||
91 | // Relinqs rtr | ||
92 | RelinquishRetries uint64 | ||
93 | // Number of attribute changed requests seen | ||
94 | AttributeChangedRequestsSeen uint64 | ||
95 | // Number of attr changed requests queued | ||
96 | AttributeChangedRequestsQueued uint64 | ||
97 | // Number of attr changed rejected -ENOBUFS | ||
98 | AttributeChangedRejectDueToEnobufs uint64 | ||
99 | // Number of attr changed failed -ENOMEM | ||
100 | AttributeChangedFailedDueToEnomem uint64 | ||
101 | // Number of attr changed ops given CPU time | ||
102 | AttributeChangedOps uint64 | ||
103 | // Number of allocation requests seen | ||
104 | AllocationRequestsSeen uint64 | ||
105 | // Number of successful alloc reqs | ||
106 | AllocationOkRequests uint64 | ||
107 | // Number of alloc reqs that waited on lookup completion | ||
108 | AllocationWaitingOnLookup uint64 | ||
109 | // Number of alloc reqs rejected -ENOBUFS | ||
110 | AllocationsRejectedDueToEnobufs uint64 | ||
111 | // Number of alloc reqs aborted -ERESTARTSYS | ||
112 | AllocationsAbortedDueToErestartsys uint64 | ||
113 | // Number of alloc reqs submitted | ||
114 | AllocationOperationsSubmitted uint64 | ||
115 | // Number of alloc reqs waited for CPU time | ||
116 | AllocationsWaitedForCPU uint64 | ||
117 | // Number of alloc reqs aborted due to object death | ||
118 | AllocationsAbortedDueToObjectDeath uint64 | ||
119 | // Number of retrieval (read) requests seen | ||
120 | RetrievalsReadRequests uint64 | ||
121 | // Number of successful retr reqs | ||
122 | RetrievalsOk uint64 | ||
123 | // Number of retr reqs that waited on lookup completion | ||
124 | RetrievalsWaitingLookupCompletion uint64 | ||
125 | // Number of retr reqs returned -ENODATA | ||
126 | RetrievalsReturnedEnodata uint64 | ||
127 | // Number of retr reqs rejected -ENOBUFS | ||
128 | RetrievalsRejectedDueToEnobufs uint64 | ||
129 | // Number of retr reqs aborted -ERESTARTSYS | ||
130 | RetrievalsAbortedDueToErestartsys uint64 | ||
131 | // Number of retr reqs failed -ENOMEM | ||
132 | RetrievalsFailedDueToEnomem uint64 | ||
133 | // Number of retr reqs submitted | ||
134 | RetrievalsRequests uint64 | ||
135 | // Number of retr reqs waited for CPU time | ||
136 | RetrievalsWaitingCPU uint64 | ||
137 | // Number of retr reqs aborted due to object death | ||
138 | RetrievalsAbortedDueToObjectDeath uint64 | ||
139 | // Number of storage (write) requests seen | ||
140 | StoreWriteRequests uint64 | ||
141 | // Number of successful store reqs | ||
142 | StoreSuccessfulRequests uint64 | ||
143 | // Number of store reqs on a page already pending storage | ||
144 | StoreRequestsOnPendingStorage uint64 | ||
145 | // Number of store reqs rejected -ENOBUFS | ||
146 | StoreRequestsRejectedDueToEnobufs uint64 | ||
147 | // Number of store reqs failed -ENOMEM | ||
148 | StoreRequestsFailedDueToEnomem uint64 | ||
149 | // Number of store reqs submitted | ||
150 | StoreRequestsSubmitted uint64 | ||
151 | // Number of store reqs granted CPU time | ||
152 | StoreRequestsRunning uint64 | ||
153 | // Number of pages given store req processing time | ||
154 | StorePagesWithRequestsProcessing uint64 | ||
155 | // Number of store reqs deleted from tracking tree | ||
156 | StoreRequestsDeleted uint64 | ||
157 | // Number of store reqs over store limit | ||
158 | StoreRequestsOverStoreLimit uint64 | ||
159 | // Number of release reqs against pages with no pending store | ||
160 | ReleaseRequestsAgainstPagesWithNoPendingStorage uint64 | ||
161 | // Number of release reqs against pages stored by time lock granted | ||
162 | ReleaseRequestsAgainstPagesStoredByTimeLockGranted uint64 | ||
163 | // Number of release reqs ignored due to in-progress store | ||
164 | ReleaseRequestsIgnoredDueToInProgressStore uint64 | ||
165 | // Number of page stores cancelled due to release req | ||
166 | PageStoresCancelledByReleaseRequests uint64 | ||
167 | VmscanWaiting uint64 | ||
168 | // Number of times async ops added to pending queues | ||
169 | OpsPending uint64 | ||
170 | // Number of times async ops given CPU time | ||
171 | OpsRunning uint64 | ||
172 | // Number of times async ops queued for processing | ||
173 | OpsEnqueued uint64 | ||
174 | // Number of async ops cancelled | ||
175 | OpsCancelled uint64 | ||
176 | // Number of async ops rejected due to object lookup/create failure | ||
177 | OpsRejected uint64 | ||
178 | // Number of async ops initialised | ||
179 | OpsInitialised uint64 | ||
180 | // Number of async ops queued for deferred release | ||
181 | OpsDeferred uint64 | ||
182 | // Number of async ops released (should equal ini=N when idle) | ||
183 | OpsReleased uint64 | ||
184 | // Number of deferred-release async ops garbage collected | ||
185 | OpsGarbageCollected uint64 | ||
186 | // Number of in-progress alloc_object() cache ops | ||
187 | CacheopAllocationsinProgress uint64 | ||
188 | // Number of in-progress lookup_object() cache ops | ||
189 | CacheopLookupObjectInProgress uint64 | ||
190 | // Number of in-progress lookup_complete() cache ops | ||
191 | CacheopLookupCompleteInPorgress uint64 | ||
192 | // Number of in-progress grab_object() cache ops | ||
193 | CacheopGrabObjectInProgress uint64 | ||
194 | CacheopInvalidations uint64 | ||
195 | // Number of in-progress update_object() cache ops | ||
196 | CacheopUpdateObjectInProgress uint64 | ||
197 | // Number of in-progress drop_object() cache ops | ||
198 | CacheopDropObjectInProgress uint64 | ||
199 | // Number of in-progress put_object() cache ops | ||
200 | CacheopPutObjectInProgress uint64 | ||
201 | // Number of in-progress attr_changed() cache ops | ||
202 | CacheopAttributeChangeInProgress uint64 | ||
203 | // Number of in-progress sync_cache() cache ops | ||
204 | CacheopSyncCacheInProgress uint64 | ||
205 | // Number of in-progress read_or_alloc_page() cache ops | ||
206 | CacheopReadOrAllocPageInProgress uint64 | ||
207 | // Number of in-progress read_or_alloc_pages() cache ops | ||
208 | CacheopReadOrAllocPagesInProgress uint64 | ||
209 | // Number of in-progress allocate_page() cache ops | ||
210 | CacheopAllocatePageInProgress uint64 | ||
211 | // Number of in-progress allocate_pages() cache ops | ||
212 | CacheopAllocatePagesInProgress uint64 | ||
213 | // Number of in-progress write_page() cache ops | ||
214 | CacheopWritePagesInProgress uint64 | ||
215 | // Number of in-progress uncache_page() cache ops | ||
216 | CacheopUncachePagesInProgress uint64 | ||
217 | // Number of in-progress dissociate_pages() cache ops | ||
218 | CacheopDissociatePagesInProgress uint64 | ||
219 | // Number of object lookups/creations rejected due to lack of space | ||
220 | CacheevLookupsAndCreationsRejectedLackSpace uint64 | ||
221 | // Number of stale objects deleted | ||
222 | CacheevStaleObjectsDeleted uint64 | ||
223 | // Number of objects retired when relinquished | ||
224 | CacheevRetiredWhenReliquished uint64 | ||
225 | // Number of objects culled | ||
226 | CacheevObjectsCulled uint64 | ||
227 | } | ||
228 | |||
229 | // Fscacheinfo returns information about current fscache statistics. | ||
230 | // See https://www.kernel.org/doc/Documentation/filesystems/caching/fscache.txt | ||
231 | func (fs FS) Fscacheinfo() (Fscacheinfo, error) { | ||
232 | b, err := util.ReadFileNoStat(fs.proc.Path("fs/fscache/stats")) | ||
233 | if err != nil { | ||
234 | return Fscacheinfo{}, err | ||
235 | } | ||
236 | |||
237 | m, err := parseFscacheinfo(bytes.NewReader(b)) | ||
238 | if err != nil { | ||
239 | return Fscacheinfo{}, fmt.Errorf("failed to parse Fscacheinfo: %v", err) | ||
240 | } | ||
241 | |||
242 | return *m, nil | ||
243 | } | ||
244 | |||
245 | func setFSCacheFields(fields []string, setFields ...*uint64) error { | ||
246 | var err error | ||
247 | if len(fields) < len(setFields) { | ||
248 | return fmt.Errorf("Insufficient number of fields, expected %v, got %v", len(setFields), len(fields)) | ||
249 | } | ||
250 | |||
251 | for i := range setFields { | ||
252 | *setFields[i], err = strconv.ParseUint(strings.Split(fields[i], "=")[1], 0, 64) | ||
253 | if err != nil { | ||
254 | return err | ||
255 | } | ||
256 | } | ||
257 | return nil | ||
258 | } | ||
259 | |||
260 | func parseFscacheinfo(r io.Reader) (*Fscacheinfo, error) { | ||
261 | var m Fscacheinfo | ||
262 | s := bufio.NewScanner(r) | ||
263 | for s.Scan() { | ||
264 | fields := strings.Fields(s.Text()) | ||
265 | if len(fields) < 2 { | ||
266 | return nil, fmt.Errorf("malformed Fscacheinfo line: %q", s.Text()) | ||
267 | } | ||
268 | |||
269 | switch fields[0] { | ||
270 | case "Cookies:": | ||
271 | err := setFSCacheFields(fields[1:], &m.IndexCookiesAllocated, &m.DataStorageCookiesAllocated, | ||
272 | &m.SpecialCookiesAllocated) | ||
273 | if err != nil { | ||
274 | return &m, err | ||
275 | } | ||
276 | case "Objects:": | ||
277 | err := setFSCacheFields(fields[1:], &m.ObjectsAllocated, &m.ObjectAllocationsFailure, | ||
278 | &m.ObjectsAvailable, &m.ObjectsDead) | ||
279 | if err != nil { | ||
280 | return &m, err | ||
281 | } | ||
282 | case "ChkAux": | ||
283 | err := setFSCacheFields(fields[2:], &m.ObjectsWithoutCoherencyCheck, &m.ObjectsWithCoherencyCheck, | ||
284 | &m.ObjectsNeedCoherencyCheckUpdate, &m.ObjectsDeclaredObsolete) | ||
285 | if err != nil { | ||
286 | return &m, err | ||
287 | } | ||
288 | case "Pages": | ||
289 | err := setFSCacheFields(fields[2:], &m.PagesMarkedAsBeingCached, &m.UncachePagesRequestSeen) | ||
290 | if err != nil { | ||
291 | return &m, err | ||
292 | } | ||
293 | case "Acquire:": | ||
294 | err := setFSCacheFields(fields[1:], &m.AcquireCookiesRequestSeen, &m.AcquireRequestsWithNullParent, | ||
295 | &m.AcquireRequestsRejectedNoCacheAvailable, &m.AcquireRequestsSucceeded, &m.AcquireRequestsRejectedDueToError, | ||
296 | &m.AcquireRequestsFailedDueToEnomem) | ||
297 | if err != nil { | ||
298 | return &m, err | ||
299 | } | ||
300 | case "Lookups:": | ||
301 | err := setFSCacheFields(fields[1:], &m.LookupsNumber, &m.LookupsNegative, &m.LookupsPositive, | ||
302 | &m.ObjectsCreatedByLookup, &m.LookupsTimedOutAndRequed) | ||
303 | if err != nil { | ||
304 | return &m, err | ||
305 | } | ||
306 | case "Invals": | ||
307 | err := setFSCacheFields(fields[2:], &m.InvalidationsNumber, &m.InvalidationsRunning) | ||
308 | if err != nil { | ||
309 | return &m, err | ||
310 | } | ||
311 | case "Updates:": | ||
312 | err := setFSCacheFields(fields[1:], &m.UpdateCookieRequestSeen, &m.UpdateRequestsWithNullParent, | ||
313 | &m.UpdateRequestsRunning) | ||
314 | if err != nil { | ||
315 | return &m, err | ||
316 | } | ||
317 | case "Relinqs:": | ||
318 | err := setFSCacheFields(fields[1:], &m.RelinquishCookiesRequestSeen, &m.RelinquishCookiesWithNullParent, | ||
319 | &m.RelinquishRequestsWaitingCompleteCreation, &m.RelinquishRetries) | ||
320 | if err != nil { | ||
321 | return &m, err | ||
322 | } | ||
323 | case "AttrChg:": | ||
324 | err := setFSCacheFields(fields[1:], &m.AttributeChangedRequestsSeen, &m.AttributeChangedRequestsQueued, | ||
325 | &m.AttributeChangedRejectDueToEnobufs, &m.AttributeChangedFailedDueToEnomem, &m.AttributeChangedOps) | ||
326 | if err != nil { | ||
327 | return &m, err | ||
328 | } | ||
329 | case "Allocs": | ||
330 | if strings.Split(fields[2], "=")[0] == "n" { | ||
331 | err := setFSCacheFields(fields[2:], &m.AllocationRequestsSeen, &m.AllocationOkRequests, | ||
332 | &m.AllocationWaitingOnLookup, &m.AllocationsRejectedDueToEnobufs, &m.AllocationsAbortedDueToErestartsys) | ||
333 | if err != nil { | ||
334 | return &m, err | ||
335 | } | ||
336 | } else { | ||
337 | err := setFSCacheFields(fields[2:], &m.AllocationOperationsSubmitted, &m.AllocationsWaitedForCPU, | ||
338 | &m.AllocationsAbortedDueToObjectDeath) | ||
339 | if err != nil { | ||
340 | return &m, err | ||
341 | } | ||
342 | } | ||
343 | case "Retrvls:": | ||
344 | if strings.Split(fields[1], "=")[0] == "n" { | ||
345 | err := setFSCacheFields(fields[1:], &m.RetrievalsReadRequests, &m.RetrievalsOk, &m.RetrievalsWaitingLookupCompletion, | ||
346 | &m.RetrievalsReturnedEnodata, &m.RetrievalsRejectedDueToEnobufs, &m.RetrievalsAbortedDueToErestartsys, | ||
347 | &m.RetrievalsFailedDueToEnomem) | ||
348 | if err != nil { | ||
349 | return &m, err | ||
350 | } | ||
351 | } else { | ||
352 | err := setFSCacheFields(fields[1:], &m.RetrievalsRequests, &m.RetrievalsWaitingCPU, &m.RetrievalsAbortedDueToObjectDeath) | ||
353 | if err != nil { | ||
354 | return &m, err | ||
355 | } | ||
356 | } | ||
357 | case "Stores": | ||
358 | if strings.Split(fields[2], "=")[0] == "n" { | ||
359 | err := setFSCacheFields(fields[2:], &m.StoreWriteRequests, &m.StoreSuccessfulRequests, | ||
360 | &m.StoreRequestsOnPendingStorage, &m.StoreRequestsRejectedDueToEnobufs, &m.StoreRequestsFailedDueToEnomem) | ||
361 | if err != nil { | ||
362 | return &m, err | ||
363 | } | ||
364 | } else { | ||
365 | err := setFSCacheFields(fields[2:], &m.StoreRequestsSubmitted, &m.StoreRequestsRunning, | ||
366 | &m.StorePagesWithRequestsProcessing, &m.StoreRequestsDeleted, &m.StoreRequestsOverStoreLimit) | ||
367 | if err != nil { | ||
368 | return &m, err | ||
369 | } | ||
370 | } | ||
371 | case "VmScan": | ||
372 | err := setFSCacheFields(fields[2:], &m.ReleaseRequestsAgainstPagesWithNoPendingStorage, | ||
373 | &m.ReleaseRequestsAgainstPagesStoredByTimeLockGranted, &m.ReleaseRequestsIgnoredDueToInProgressStore, | ||
374 | &m.PageStoresCancelledByReleaseRequests, &m.VmscanWaiting) | ||
375 | if err != nil { | ||
376 | return &m, err | ||
377 | } | ||
378 | case "Ops": | ||
379 | if strings.Split(fields[2], "=")[0] == "pend" { | ||
380 | err := setFSCacheFields(fields[2:], &m.OpsPending, &m.OpsRunning, &m.OpsEnqueued, &m.OpsCancelled, &m.OpsRejected) | ||
381 | if err != nil { | ||
382 | return &m, err | ||
383 | } | ||
384 | } else { | ||
385 | err := setFSCacheFields(fields[2:], &m.OpsInitialised, &m.OpsDeferred, &m.OpsReleased, &m.OpsGarbageCollected) | ||
386 | if err != nil { | ||
387 | return &m, err | ||
388 | } | ||
389 | } | ||
390 | case "CacheOp:": | ||
391 | if strings.Split(fields[1], "=")[0] == "alo" { | ||
392 | err := setFSCacheFields(fields[1:], &m.CacheopAllocationsinProgress, &m.CacheopLookupObjectInProgress, | ||
393 | &m.CacheopLookupCompleteInPorgress, &m.CacheopGrabObjectInProgress) | ||
394 | if err != nil { | ||
395 | return &m, err | ||
396 | } | ||
397 | } else if strings.Split(fields[1], "=")[0] == "inv" { | ||
398 | err := setFSCacheFields(fields[1:], &m.CacheopInvalidations, &m.CacheopUpdateObjectInProgress, | ||
399 | &m.CacheopDropObjectInProgress, &m.CacheopPutObjectInProgress, &m.CacheopAttributeChangeInProgress, | ||
400 | &m.CacheopSyncCacheInProgress) | ||
401 | if err != nil { | ||
402 | return &m, err | ||
403 | } | ||
404 | } else { | ||
405 | err := setFSCacheFields(fields[1:], &m.CacheopReadOrAllocPageInProgress, &m.CacheopReadOrAllocPagesInProgress, | ||
406 | &m.CacheopAllocatePageInProgress, &m.CacheopAllocatePagesInProgress, &m.CacheopWritePagesInProgress, | ||
407 | &m.CacheopUncachePagesInProgress, &m.CacheopDissociatePagesInProgress) | ||
408 | if err != nil { | ||
409 | return &m, err | ||
410 | } | ||
411 | } | ||
412 | case "CacheEv:": | ||
413 | err := setFSCacheFields(fields[1:], &m.CacheevLookupsAndCreationsRejectedLackSpace, &m.CacheevStaleObjectsDeleted, | ||
414 | &m.CacheevRetiredWhenReliquished, &m.CacheevObjectsCulled) | ||
415 | if err != nil { | ||
416 | return &m, err | ||
417 | } | ||
418 | } | ||
419 | } | ||
420 | |||
421 | return &m, nil | ||
422 | } | ||
diff --git a/vendor/github.com/prometheus/procfs/internal/util/parse.go b/vendor/github.com/prometheus/procfs/internal/util/parse.go index 755591d..22cb07a 100644 --- a/vendor/github.com/prometheus/procfs/internal/util/parse.go +++ b/vendor/github.com/prometheus/procfs/internal/util/parse.go | |||
@@ -73,6 +73,15 @@ func ReadUintFromFile(path string) (uint64, error) { | |||
73 | return strconv.ParseUint(strings.TrimSpace(string(data)), 10, 64) | 73 | return strconv.ParseUint(strings.TrimSpace(string(data)), 10, 64) |
74 | } | 74 | } |
75 | 75 | ||
76 | // ReadIntFromFile reads a file and attempts to parse a int64 from it. | ||
77 | func ReadIntFromFile(path string) (int64, error) { | ||
78 | data, err := ioutil.ReadFile(path) | ||
79 | if err != nil { | ||
80 | return 0, err | ||
81 | } | ||
82 | return strconv.ParseInt(strings.TrimSpace(string(data)), 10, 64) | ||
83 | } | ||
84 | |||
76 | // ParseBool parses a string into a boolean pointer. | 85 | // ParseBool parses a string into a boolean pointer. |
77 | func ParseBool(b string) *bool { | 86 | func ParseBool(b string) *bool { |
78 | var truth bool | 87 | var truth bool |
diff --git a/vendor/github.com/prometheus/procfs/kernel_random.go b/vendor/github.com/prometheus/procfs/kernel_random.go new file mode 100644 index 0000000..beefdf0 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/kernel_random.go | |||
@@ -0,0 +1,62 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build !windows | ||
15 | |||
16 | package procfs | ||
17 | |||
18 | import ( | ||
19 | "os" | ||
20 | |||
21 | "github.com/prometheus/procfs/internal/util" | ||
22 | ) | ||
23 | |||
24 | // KernelRandom contains information about to the kernel's random number generator. | ||
25 | type KernelRandom struct { | ||
26 | // EntropyAvaliable gives the available entropy, in bits. | ||
27 | EntropyAvaliable *uint64 | ||
28 | // PoolSize gives the size of the entropy pool, in bytes. | ||
29 | PoolSize *uint64 | ||
30 | // URandomMinReseedSeconds is the number of seconds after which the DRNG will be reseeded. | ||
31 | URandomMinReseedSeconds *uint64 | ||
32 | // WriteWakeupThreshold the number of bits of entropy below which we wake up processes | ||
33 | // that do a select(2) or poll(2) for write access to /dev/random. | ||
34 | WriteWakeupThreshold *uint64 | ||
35 | // ReadWakeupThreshold is the number of bits of entropy required for waking up processes that sleep | ||
36 | // waiting for entropy from /dev/random. | ||
37 | ReadWakeupThreshold *uint64 | ||
38 | } | ||
39 | |||
40 | // KernelRandom returns values from /proc/sys/kernel/random. | ||
41 | func (fs FS) KernelRandom() (KernelRandom, error) { | ||
42 | random := KernelRandom{} | ||
43 | |||
44 | for file, p := range map[string]**uint64{ | ||
45 | "entropy_avail": &random.EntropyAvaliable, | ||
46 | "poolsize": &random.PoolSize, | ||
47 | "urandom_min_reseed_secs": &random.URandomMinReseedSeconds, | ||
48 | "write_wakeup_threshold": &random.WriteWakeupThreshold, | ||
49 | "read_wakeup_threshold": &random.ReadWakeupThreshold, | ||
50 | } { | ||
51 | val, err := util.ReadUintFromFile(fs.proc.Path("sys", "kernel", "random", file)) | ||
52 | if os.IsNotExist(err) { | ||
53 | continue | ||
54 | } | ||
55 | if err != nil { | ||
56 | return random, err | ||
57 | } | ||
58 | *p = &val | ||
59 | } | ||
60 | |||
61 | return random, nil | ||
62 | } | ||
diff --git a/vendor/github.com/prometheus/procfs/mdstat.go b/vendor/github.com/prometheus/procfs/mdstat.go index 2af3ada..3e9362a 100644 --- a/vendor/github.com/prometheus/procfs/mdstat.go +++ b/vendor/github.com/prometheus/procfs/mdstat.go | |||
@@ -52,7 +52,7 @@ type MDStat struct { | |||
52 | func (fs FS) MDStat() ([]MDStat, error) { | 52 | func (fs FS) MDStat() ([]MDStat, error) { |
53 | data, err := ioutil.ReadFile(fs.proc.Path("mdstat")) | 53 | data, err := ioutil.ReadFile(fs.proc.Path("mdstat")) |
54 | if err != nil { | 54 | if err != nil { |
55 | return nil, fmt.Errorf("error parsing mdstat %s: %s", fs.proc.Path("mdstat"), err) | 55 | return nil, err |
56 | } | 56 | } |
57 | mdstat, err := parseMDStat(data) | 57 | mdstat, err := parseMDStat(data) |
58 | if err != nil { | 58 | if err != nil { |
diff --git a/vendor/github.com/prometheus/procfs/mountinfo.go b/vendor/github.com/prometheus/procfs/mountinfo.go index 9471136..59f4d50 100644 --- a/vendor/github.com/prometheus/procfs/mountinfo.go +++ b/vendor/github.com/prometheus/procfs/mountinfo.go | |||
@@ -77,7 +77,7 @@ func parseMountInfoString(mountString string) (*MountInfo, error) { | |||
77 | 77 | ||
78 | mountInfo := strings.Split(mountString, " ") | 78 | mountInfo := strings.Split(mountString, " ") |
79 | mountInfoLength := len(mountInfo) | 79 | mountInfoLength := len(mountInfo) |
80 | if mountInfoLength < 11 { | 80 | if mountInfoLength < 10 { |
81 | return nil, fmt.Errorf("couldn't find enough fields in mount string: %s", mountString) | 81 | return nil, fmt.Errorf("couldn't find enough fields in mount string: %s", mountString) |
82 | } | 82 | } |
83 | 83 | ||
@@ -144,7 +144,7 @@ func mountOptionsParseOptionalFields(o []string) (map[string]string, error) { | |||
144 | return optionalFields, nil | 144 | return optionalFields, nil |
145 | } | 145 | } |
146 | 146 | ||
147 | // Parses the mount options, superblock options. | 147 | // mountOptionsParser parses the mount options, superblock options. |
148 | func mountOptionsParser(mountOptions string) map[string]string { | 148 | func mountOptionsParser(mountOptions string) map[string]string { |
149 | opts := make(map[string]string) | 149 | opts := make(map[string]string) |
150 | options := strings.Split(mountOptions, ",") | 150 | options := strings.Split(mountOptions, ",") |
@@ -161,7 +161,7 @@ func mountOptionsParser(mountOptions string) map[string]string { | |||
161 | return opts | 161 | return opts |
162 | } | 162 | } |
163 | 163 | ||
164 | // Retrieves mountinfo information from `/proc/self/mountinfo`. | 164 | // GetMounts retrieves mountinfo information from `/proc/self/mountinfo`. |
165 | func GetMounts() ([]*MountInfo, error) { | 165 | func GetMounts() ([]*MountInfo, error) { |
166 | data, err := util.ReadFileNoStat("/proc/self/mountinfo") | 166 | data, err := util.ReadFileNoStat("/proc/self/mountinfo") |
167 | if err != nil { | 167 | if err != nil { |
@@ -170,7 +170,7 @@ func GetMounts() ([]*MountInfo, error) { | |||
170 | return parseMountInfo(data) | 170 | return parseMountInfo(data) |
171 | } | 171 | } |
172 | 172 | ||
173 | // Retrieves mountinfo information from a processes' `/proc/<pid>/mountinfo`. | 173 | // GetProcMounts retrieves mountinfo information from a processes' `/proc/<pid>/mountinfo`. |
174 | func GetProcMounts(pid int) ([]*MountInfo, error) { | 174 | func GetProcMounts(pid int) ([]*MountInfo, error) { |
175 | data, err := util.ReadFileNoStat(fmt.Sprintf("/proc/%d/mountinfo", pid)) | 175 | data, err := util.ReadFileNoStat(fmt.Sprintf("/proc/%d/mountinfo", pid)) |
176 | if err != nil { | 176 | if err != nil { |
diff --git a/vendor/github.com/prometheus/procfs/mountstats.go b/vendor/github.com/prometheus/procfs/mountstats.go index 35b2ef3..861ced9 100644 --- a/vendor/github.com/prometheus/procfs/mountstats.go +++ b/vendor/github.com/prometheus/procfs/mountstats.go | |||
@@ -186,6 +186,8 @@ type NFSOperationStats struct { | |||
186 | CumulativeTotalResponseMilliseconds uint64 | 186 | CumulativeTotalResponseMilliseconds uint64 |
187 | // Duration from when a request was enqueued to when it was completely handled. | 187 | // Duration from when a request was enqueued to when it was completely handled. |
188 | CumulativeTotalRequestMilliseconds uint64 | 188 | CumulativeTotalRequestMilliseconds uint64 |
189 | // The count of operations that complete with tk_status < 0. These statuses usually indicate error conditions. | ||
190 | Errors uint64 | ||
189 | } | 191 | } |
190 | 192 | ||
191 | // A NFSTransportStats contains statistics for the NFS mount RPC requests and | 193 | // A NFSTransportStats contains statistics for the NFS mount RPC requests and |
@@ -494,8 +496,8 @@ func parseNFSEventsStats(ss []string) (*NFSEventsStats, error) { | |||
494 | // line is reached. | 496 | // line is reached. |
495 | func parseNFSOperationStats(s *bufio.Scanner) ([]NFSOperationStats, error) { | 497 | func parseNFSOperationStats(s *bufio.Scanner) ([]NFSOperationStats, error) { |
496 | const ( | 498 | const ( |
497 | // Number of expected fields in each per-operation statistics set | 499 | // Minimum number of expected fields in each per-operation statistics set |
498 | numFields = 9 | 500 | minFields = 9 |
499 | ) | 501 | ) |
500 | 502 | ||
501 | var ops []NFSOperationStats | 503 | var ops []NFSOperationStats |
@@ -508,12 +510,12 @@ func parseNFSOperationStats(s *bufio.Scanner) ([]NFSOperationStats, error) { | |||
508 | break | 510 | break |
509 | } | 511 | } |
510 | 512 | ||
511 | if len(ss) != numFields { | 513 | if len(ss) < minFields { |
512 | return nil, fmt.Errorf("invalid NFS per-operations stats: %v", ss) | 514 | return nil, fmt.Errorf("invalid NFS per-operations stats: %v", ss) |
513 | } | 515 | } |
514 | 516 | ||
515 | // Skip string operation name for integers | 517 | // Skip string operation name for integers |
516 | ns := make([]uint64, 0, numFields-1) | 518 | ns := make([]uint64, 0, minFields-1) |
517 | for _, st := range ss[1:] { | 519 | for _, st := range ss[1:] { |
518 | n, err := strconv.ParseUint(st, 10, 64) | 520 | n, err := strconv.ParseUint(st, 10, 64) |
519 | if err != nil { | 521 | if err != nil { |
@@ -523,7 +525,7 @@ func parseNFSOperationStats(s *bufio.Scanner) ([]NFSOperationStats, error) { | |||
523 | ns = append(ns, n) | 525 | ns = append(ns, n) |
524 | } | 526 | } |
525 | 527 | ||
526 | ops = append(ops, NFSOperationStats{ | 528 | opStats := NFSOperationStats{ |
527 | Operation: strings.TrimSuffix(ss[0], ":"), | 529 | Operation: strings.TrimSuffix(ss[0], ":"), |
528 | Requests: ns[0], | 530 | Requests: ns[0], |
529 | Transmissions: ns[1], | 531 | Transmissions: ns[1], |
@@ -533,7 +535,13 @@ func parseNFSOperationStats(s *bufio.Scanner) ([]NFSOperationStats, error) { | |||
533 | CumulativeQueueMilliseconds: ns[5], | 535 | CumulativeQueueMilliseconds: ns[5], |
534 | CumulativeTotalResponseMilliseconds: ns[6], | 536 | CumulativeTotalResponseMilliseconds: ns[6], |
535 | CumulativeTotalRequestMilliseconds: ns[7], | 537 | CumulativeTotalRequestMilliseconds: ns[7], |
536 | }) | 538 | } |
539 | |||
540 | if len(ns) > 8 { | ||
541 | opStats.Errors = ns[8] | ||
542 | } | ||
543 | |||
544 | ops = append(ops, opStats) | ||
537 | } | 545 | } |
538 | 546 | ||
539 | return ops, s.Err() | 547 | return ops, s.Err() |
diff --git a/vendor/github.com/prometheus/procfs/net_conntrackstat.go b/vendor/github.com/prometheus/procfs/net_conntrackstat.go index 1e27c83..b637be9 100644 --- a/vendor/github.com/prometheus/procfs/net_conntrackstat.go +++ b/vendor/github.com/prometheus/procfs/net_conntrackstat.go | |||
@@ -38,7 +38,7 @@ type ConntrackStatEntry struct { | |||
38 | SearchRestart uint64 | 38 | SearchRestart uint64 |
39 | } | 39 | } |
40 | 40 | ||
41 | // Retrieves netfilter's conntrack statistics, split by CPU cores | 41 | // ConntrackStat retrieves netfilter's conntrack statistics, split by CPU cores |
42 | func (fs FS) ConntrackStat() ([]ConntrackStatEntry, error) { | 42 | func (fs FS) ConntrackStat() ([]ConntrackStatEntry, error) { |
43 | return readConntrackStat(fs.proc.Path("net", "stat", "nf_conntrack")) | 43 | return readConntrackStat(fs.proc.Path("net", "stat", "nf_conntrack")) |
44 | } | 44 | } |
diff --git a/vendor/github.com/prometheus/procfs/proc.go b/vendor/github.com/prometheus/procfs/proc.go index 330e472..9f97b6e 100644 --- a/vendor/github.com/prometheus/procfs/proc.go +++ b/vendor/github.com/prometheus/procfs/proc.go | |||
@@ -134,6 +134,27 @@ func (p Proc) CmdLine() ([]string, error) { | |||
134 | return strings.Split(string(bytes.TrimRight(data, string("\x00"))), string(byte(0))), nil | 134 | return strings.Split(string(bytes.TrimRight(data, string("\x00"))), string(byte(0))), nil |
135 | } | 135 | } |
136 | 136 | ||
137 | // Wchan returns the wchan (wait channel) of a process. | ||
138 | func (p Proc) Wchan() (string, error) { | ||
139 | f, err := os.Open(p.path("wchan")) | ||
140 | if err != nil { | ||
141 | return "", err | ||
142 | } | ||
143 | defer f.Close() | ||
144 | |||
145 | data, err := ioutil.ReadAll(f) | ||
146 | if err != nil { | ||
147 | return "", err | ||
148 | } | ||
149 | |||
150 | wchan := string(data) | ||
151 | if wchan == "" || wchan == "0" { | ||
152 | return "", nil | ||
153 | } | ||
154 | |||
155 | return wchan, nil | ||
156 | } | ||
157 | |||
137 | // Comm returns the command name of a process. | 158 | // Comm returns the command name of a process. |
138 | func (p Proc) Comm() (string, error) { | 159 | func (p Proc) Comm() (string, error) { |
139 | data, err := util.ReadFileNoStat(p.path("comm")) | 160 | data, err := util.ReadFileNoStat(p.path("comm")) |
diff --git a/vendor/github.com/prometheus/procfs/proc_cgroup.go b/vendor/github.com/prometheus/procfs/proc_cgroup.go new file mode 100644 index 0000000..4abd464 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/proc_cgroup.go | |||
@@ -0,0 +1,98 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | package procfs | ||
15 | |||
16 | import ( | ||
17 | "bufio" | ||
18 | "bytes" | ||
19 | "fmt" | ||
20 | "strconv" | ||
21 | "strings" | ||
22 | |||
23 | "github.com/prometheus/procfs/internal/util" | ||
24 | ) | ||
25 | |||
26 | // Cgroup models one line from /proc/[pid]/cgroup. Each Cgroup struct describes the the placement of a PID inside a | ||
27 | // specific control hierarchy. The kernel has two cgroup APIs, v1 and v2. v1 has one hierarchy per available resource | ||
28 | // controller, while v2 has one unified hierarchy shared by all controllers. Regardless of v1 or v2, all hierarchies | ||
29 | // contain all running processes, so the question answerable with a Cgroup struct is 'where is this process in | ||
30 | // this hierarchy' (where==what path on the specific cgroupfs). By prefixing this path with the mount point of | ||
31 | // *this specific* hierarchy, you can locate the relevant pseudo-files needed to read/set the data for this PID | ||
32 | // in this hierarchy | ||
33 | // | ||
34 | // Also see http://man7.org/linux/man-pages/man7/cgroups.7.html | ||
35 | type Cgroup struct { | ||
36 | // HierarchyID that can be matched to a named hierarchy using /proc/cgroups. Cgroups V2 only has one | ||
37 | // hierarchy, so HierarchyID is always 0. For cgroups v1 this is a unique ID number | ||
38 | HierarchyID int | ||
39 | // Controllers using this hierarchy of processes. Controllers are also known as subsystems. For | ||
40 | // Cgroups V2 this may be empty, as all active controllers use the same hierarchy | ||
41 | Controllers []string | ||
42 | // Path of this control group, relative to the mount point of the cgroupfs representing this specific | ||
43 | // hierarchy | ||
44 | Path string | ||
45 | } | ||
46 | |||
47 | // parseCgroupString parses each line of the /proc/[pid]/cgroup file | ||
48 | // Line format is hierarchyID:[controller1,controller2]:path | ||
49 | func parseCgroupString(cgroupStr string) (*Cgroup, error) { | ||
50 | var err error | ||
51 | |||
52 | fields := strings.Split(cgroupStr, ":") | ||
53 | if len(fields) < 3 { | ||
54 | return nil, fmt.Errorf("at least 3 fields required, found %d fields in cgroup string: %s", len(fields), cgroupStr) | ||
55 | } | ||
56 | |||
57 | cgroup := &Cgroup{ | ||
58 | Path: fields[2], | ||
59 | Controllers: nil, | ||
60 | } | ||
61 | cgroup.HierarchyID, err = strconv.Atoi(fields[0]) | ||
62 | if err != nil { | ||
63 | return nil, fmt.Errorf("failed to parse hierarchy ID") | ||
64 | } | ||
65 | if fields[1] != "" { | ||
66 | ssNames := strings.Split(fields[1], ",") | ||
67 | cgroup.Controllers = append(cgroup.Controllers, ssNames...) | ||
68 | } | ||
69 | return cgroup, nil | ||
70 | } | ||
71 | |||
72 | // parseCgroups reads each line of the /proc/[pid]/cgroup file | ||
73 | func parseCgroups(data []byte) ([]Cgroup, error) { | ||
74 | var cgroups []Cgroup | ||
75 | scanner := bufio.NewScanner(bytes.NewReader(data)) | ||
76 | for scanner.Scan() { | ||
77 | mountString := scanner.Text() | ||
78 | parsedMounts, err := parseCgroupString(mountString) | ||
79 | if err != nil { | ||
80 | return nil, err | ||
81 | } | ||
82 | cgroups = append(cgroups, *parsedMounts) | ||
83 | } | ||
84 | |||
85 | err := scanner.Err() | ||
86 | return cgroups, err | ||
87 | } | ||
88 | |||
89 | // Cgroups reads from /proc/<pid>/cgroups and returns a []*Cgroup struct locating this PID in each process | ||
90 | // control hierarchy running on this system. On every system (v1 and v2), all hierarchies contain all processes, | ||
91 | // so the len of the returned struct is equal to the number of active hierarchies on this system | ||
92 | func (p Proc) Cgroups() ([]Cgroup, error) { | ||
93 | data, err := util.ReadFileNoStat(fmt.Sprintf("/proc/%d/cgroup", p.PID)) | ||
94 | if err != nil { | ||
95 | return nil, err | ||
96 | } | ||
97 | return parseCgroups(data) | ||
98 | } | ||
diff --git a/vendor/github.com/prometheus/procfs/proc_fdinfo.go b/vendor/github.com/prometheus/procfs/proc_fdinfo.go index 0c9c402..a76ca70 100644 --- a/vendor/github.com/prometheus/procfs/proc_fdinfo.go +++ b/vendor/github.com/prometheus/procfs/proc_fdinfo.go | |||
@@ -41,7 +41,7 @@ type ProcFDInfo struct { | |||
41 | Flags string | 41 | Flags string |
42 | // Mount point ID | 42 | // Mount point ID |
43 | MntID string | 43 | MntID string |
44 | // List of inotify lines (structed) in the fdinfo file (kernel 3.8+ only) | 44 | // List of inotify lines (structured) in the fdinfo file (kernel 3.8+ only) |
45 | InotifyInfos []InotifyInfo | 45 | InotifyInfos []InotifyInfo |
46 | } | 46 | } |
47 | 47 | ||
diff --git a/vendor/github.com/prometheus/procfs/proc_maps.go b/vendor/github.com/prometheus/procfs/proc_maps.go index 28d5c6e..1d7772d 100644 --- a/vendor/github.com/prometheus/procfs/proc_maps.go +++ b/vendor/github.com/prometheus/procfs/proc_maps.go | |||
@@ -11,7 +11,7 @@ | |||
11 | // See the License for the specific language governing permissions and | 11 | // See the License for the specific language governing permissions and |
12 | // limitations under the License. | 12 | // limitations under the License. |
13 | 13 | ||
14 | // +build !windows | 14 | // +build aix darwin dragonfly freebsd linux netbsd openbsd solaris |
15 | 15 | ||
16 | package procfs | 16 | package procfs |
17 | 17 | ||
@@ -25,6 +25,7 @@ import ( | |||
25 | "golang.org/x/sys/unix" | 25 | "golang.org/x/sys/unix" |
26 | ) | 26 | ) |
27 | 27 | ||
28 | // ProcMapPermissions contains permission settings read from /proc/[pid]/maps | ||
28 | type ProcMapPermissions struct { | 29 | type ProcMapPermissions struct { |
29 | // mapping has the [R]ead flag set | 30 | // mapping has the [R]ead flag set |
30 | Read bool | 31 | Read bool |
diff --git a/vendor/github.com/prometheus/procfs/proc_smaps.go b/vendor/github.com/prometheus/procfs/proc_smaps.go new file mode 100644 index 0000000..a576a72 --- /dev/null +++ b/vendor/github.com/prometheus/procfs/proc_smaps.go | |||
@@ -0,0 +1,165 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build !windows | ||
15 | |||
16 | package procfs | ||
17 | |||
18 | import ( | ||
19 | "bufio" | ||
20 | "errors" | ||
21 | "fmt" | ||
22 | "os" | ||
23 | "regexp" | ||
24 | "strconv" | ||
25 | "strings" | ||
26 | |||
27 | "github.com/prometheus/procfs/internal/util" | ||
28 | ) | ||
29 | |||
30 | var ( | ||
31 | // match the header line before each mapped zone in /proc/pid/smaps | ||
32 | procSMapsHeaderLine = regexp.MustCompile(`^[a-f0-9].*$`) | ||
33 | ) | ||
34 | |||
35 | type ProcSMapsRollup struct { | ||
36 | // Amount of the mapping that is currently resident in RAM | ||
37 | Rss uint64 | ||
38 | // Process's proportional share of this mapping | ||
39 | Pss uint64 | ||
40 | // Size in bytes of clean shared pages | ||
41 | SharedClean uint64 | ||
42 | // Size in bytes of dirty shared pages | ||
43 | SharedDirty uint64 | ||
44 | // Size in bytes of clean private pages | ||
45 | PrivateClean uint64 | ||
46 | // Size in bytes of dirty private pages | ||
47 | PrivateDirty uint64 | ||
48 | // Amount of memory currently marked as referenced or accessed | ||
49 | Referenced uint64 | ||
50 | // Amount of memory that does not belong to any file | ||
51 | Anonymous uint64 | ||
52 | // Amount would-be-anonymous memory currently on swap | ||
53 | Swap uint64 | ||
54 | // Process's proportional memory on swap | ||
55 | SwapPss uint64 | ||
56 | } | ||
57 | |||
58 | // ProcSMapsRollup reads from /proc/[pid]/smaps_rollup to get summed memory information of the | ||
59 | // process. | ||
60 | // | ||
61 | // If smaps_rollup does not exists (require kernel >= 4.15), the content of /proc/pid/smaps will | ||
62 | // we read and summed. | ||
63 | func (p Proc) ProcSMapsRollup() (ProcSMapsRollup, error) { | ||
64 | data, err := util.ReadFileNoStat(p.path("smaps_rollup")) | ||
65 | if err != nil && os.IsNotExist(err) { | ||
66 | return p.procSMapsRollupManual() | ||
67 | } | ||
68 | if err != nil { | ||
69 | return ProcSMapsRollup{}, err | ||
70 | } | ||
71 | |||
72 | lines := strings.Split(string(data), "\n") | ||
73 | smaps := ProcSMapsRollup{} | ||
74 | |||
75 | // skip first line which don't contains information we need | ||
76 | lines = lines[1:] | ||
77 | for _, line := range lines { | ||
78 | if line == "" { | ||
79 | continue | ||
80 | } | ||
81 | |||
82 | if err := smaps.parseLine(line); err != nil { | ||
83 | return ProcSMapsRollup{}, err | ||
84 | } | ||
85 | } | ||
86 | |||
87 | return smaps, nil | ||
88 | } | ||
89 | |||
90 | // Read /proc/pid/smaps and do the roll-up in Go code. | ||
91 | func (p Proc) procSMapsRollupManual() (ProcSMapsRollup, error) { | ||
92 | file, err := os.Open(p.path("smaps")) | ||
93 | if err != nil { | ||
94 | return ProcSMapsRollup{}, err | ||
95 | } | ||
96 | defer file.Close() | ||
97 | |||
98 | smaps := ProcSMapsRollup{} | ||
99 | scan := bufio.NewScanner(file) | ||
100 | |||
101 | for scan.Scan() { | ||
102 | line := scan.Text() | ||
103 | |||
104 | if procSMapsHeaderLine.MatchString(line) { | ||
105 | continue | ||
106 | } | ||
107 | |||
108 | if err := smaps.parseLine(line); err != nil { | ||
109 | return ProcSMapsRollup{}, err | ||
110 | } | ||
111 | } | ||
112 | |||
113 | return smaps, nil | ||
114 | } | ||
115 | |||
116 | func (s *ProcSMapsRollup) parseLine(line string) error { | ||
117 | kv := strings.SplitN(line, ":", 2) | ||
118 | if len(kv) != 2 { | ||
119 | fmt.Println(line) | ||
120 | return errors.New("invalid net/dev line, missing colon") | ||
121 | } | ||
122 | |||
123 | k := kv[0] | ||
124 | if k == "VmFlags" { | ||
125 | return nil | ||
126 | } | ||
127 | |||
128 | v := strings.TrimSpace(kv[1]) | ||
129 | v = strings.TrimRight(v, " kB") | ||
130 | |||
131 | vKBytes, err := strconv.ParseUint(v, 10, 64) | ||
132 | if err != nil { | ||
133 | return err | ||
134 | } | ||
135 | vBytes := vKBytes * 1024 | ||
136 | |||
137 | s.addValue(k, v, vKBytes, vBytes) | ||
138 | |||
139 | return nil | ||
140 | } | ||
141 | |||
142 | func (s *ProcSMapsRollup) addValue(k string, vString string, vUint uint64, vUintBytes uint64) { | ||
143 | switch k { | ||
144 | case "Rss": | ||
145 | s.Rss += vUintBytes | ||
146 | case "Pss": | ||
147 | s.Pss += vUintBytes | ||
148 | case "Shared_Clean": | ||
149 | s.SharedClean += vUintBytes | ||
150 | case "Shared_Dirty": | ||
151 | s.SharedDirty += vUintBytes | ||
152 | case "Private_Clean": | ||
153 | s.PrivateClean += vUintBytes | ||
154 | case "Private_Dirty": | ||
155 | s.PrivateDirty += vUintBytes | ||
156 | case "Referenced": | ||
157 | s.Referenced += vUintBytes | ||
158 | case "Anonymous": | ||
159 | s.Anonymous += vUintBytes | ||
160 | case "Swap": | ||
161 | s.Swap += vUintBytes | ||
162 | case "SwapPss": | ||
163 | s.SwapPss += vUintBytes | ||
164 | } | ||
165 | } | ||
diff --git a/vendor/github.com/prometheus/procfs/sysfs/class_fibrechannel.go b/vendor/github.com/prometheus/procfs/sysfs/class_fibrechannel.go new file mode 100644 index 0000000..d57ff9c --- /dev/null +++ b/vendor/github.com/prometheus/procfs/sysfs/class_fibrechannel.go | |||
@@ -0,0 +1,249 @@ | |||
1 | // Copyright 2020 The Prometheus Authors | ||
2 | // Licensed under the Apache License, Version 2.0 (the "License"); | ||
3 | // you may not use this file except in compliance with the License. | ||
4 | // You may obtain a copy of the License at | ||
5 | // | ||
6 | // http://www.apache.org/licenses/LICENSE-2.0 | ||
7 | // | ||
8 | // Unless required by applicable law or agreed to in writing, software | ||
9 | // distributed under the License is distributed on an "AS IS" BASIS, | ||
10 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
11 | // See the License for the specific language governing permissions and | ||
12 | // limitations under the License. | ||
13 | |||
14 | // +build !windows | ||
15 | |||
16 | package sysfs | ||
17 | |||
18 | import ( | ||
19 | "fmt" | ||
20 | "io/ioutil" | ||
21 | "os" | ||
22 | "path/filepath" | ||
23 | |||
24 | "github.com/prometheus/procfs/internal/util" | ||
25 | ) | ||
26 | |||
27 | const fibrechannelClassPath = "class/fc_host" | ||
28 | |||
29 | type FibreChannelCounters struct { | ||
30 | DumpedFrames uint64 // /sys/class/fc_host/<Name>/statistics/dumped_frames | ||
31 | ErrorFrames uint64 // /sys/class/fc_host/<Name>/statistics/error_frames | ||
32 | InvalidCRCCount uint64 // /sys/class/fc_host/<Name>/statistics/invalid_crc_count | ||
33 | RXFrames uint64 // /sys/class/fc_host/<Name>/statistics/rx_frames | ||
34 | RXWords uint64 // /sys/class/fc_host/<Name>/statistics/rx_words | ||
35 | TXFrames uint64 // /sys/class/fc_host/<Name>/statistics/tx_frames | ||
36 | TXWords uint64 // /sys/class/fc_host/<Name>/statistics/tx_words | ||
37 | SecondsSinceLastReset uint64 // /sys/class/fc_host/<Name>/statistics/seconds_since_last_reset | ||
38 | InvalidTXWordCount uint64 // /sys/class/fc_host/<Name>/statistics/invalid_tx_word_count | ||
39 | LinkFailureCount uint64 // /sys/class/fc_host/<Name>/statistics/link_failure_count | ||
40 | LossOfSyncCount uint64 // /sys/class/fc_host/<Name>/statistics/loss_of_sync_count | ||
41 | LossOfSignalCount uint64 // /sys/class/fc_host/<Name>/statistics/loss_of_signal_count | ||
42 | NosCount uint64 // /sys/class/fc_host/<Name>/statistics/nos_count | ||
43 | FCPPacketAborts uint64 // / sys/class/fc_host/<Name>/statistics/fcp_packet_aborts | ||
44 | } | ||
45 | |||
46 | type FibreChannelHost struct { | ||
47 | Name string // /sys/class/fc_host/<Name> | ||
48 | Speed string // /sys/class/fc_host/<Name>/speed | ||
49 | PortState string // /sys/class/fc_host/<Name>/port_state | ||
50 | PortType string // /sys/class/fc_host/<Name>/port_type | ||
51 | SymbolicName string // /sys/class/fc_host/<Name>/symbolic_name | ||
52 | NodeName string // /sys/class/fc_host/<Name>/node_name | ||
53 | PortID string // /sys/class/fc_host/<Name>/port_id | ||
54 | PortName string // /sys/class/fc_host/<Name>/port_name | ||
55 | FabricName string // /sys/class/fc_host/<Name>/fabric_name | ||
56 | DevLossTMO string // /sys/class/fc_host/<Name>/dev_loss_tmo | ||
57 | SupportedClasses string // /sys/class/fc_host/<Name>/supported_classes | ||
58 | SupportedSpeeds string // /sys/class/fc_host/<Name>/supported_speeds | ||
59 | Counters FibreChannelCounters // /sys/class/fc_host/<Name>/statistics/* | ||
60 | } | ||
61 | |||
62 | type FibreChannelClass map[string]FibreChannelHost | ||
63 | |||
64 | // FibreChannelClass parses everything in /sys/class/fc_host. | ||
65 | func (fs FS) FibreChannelClass() (FibreChannelClass, error) { | ||
66 | path := fs.sys.Path(fibrechannelClassPath) | ||
67 | |||
68 | dirs, err := ioutil.ReadDir(path) | ||
69 | if err != nil { | ||
70 | return nil, err | ||
71 | } | ||
72 | |||
73 | fcc := make(FibreChannelClass, len(dirs)) | ||
74 | for _, d := range dirs { | ||
75 | host, err := fs.parseFibreChannelHost(d.Name()) | ||
76 | if err != nil { | ||
77 | return nil, err | ||
78 | } | ||
79 | |||
80 | fcc[host.Name] = *host | ||
81 | } | ||
82 | |||
83 | return fcc, nil | ||
84 | } | ||
85 | |||
86 | // Parse a single FC host | ||
87 | func (fs FS) parseFibreChannelHost(name string) (*FibreChannelHost, error) { | ||
88 | path := fs.sys.Path(fibrechannelClassPath, name) | ||
89 | host := FibreChannelHost{Name: name} | ||
90 | |||
91 | for _, f := range [...]string{"speed", "port_state", "port_type", "node_name", "port_id", "port_name", "fabric_name", "dev_loss_tmo", "symbolic_name", "supported_classes", "supported_speeds"} { | ||
92 | name := filepath.Join(path, f) | ||
93 | value, err := util.SysReadFile(name) | ||
94 | if err != nil { | ||
95 | return nil, fmt.Errorf("failed to read file %q: %v", name, err) | ||
96 | } | ||
97 | |||
98 | switch f { | ||
99 | case "speed": | ||
100 | host.Speed = value | ||
101 | case "port_state": | ||
102 | host.PortState = value | ||
103 | case "port_type": | ||
104 | host.PortType = value | ||
105 | case "node_name": | ||
106 | if len(value) > 2 { | ||
107 | value = value[2:] | ||
108 | } | ||
109 | host.NodeName = value | ||
110 | case "port_id": | ||
111 | if len(value) > 2 { | ||
112 | value = value[2:] | ||
113 | } | ||
114 | host.PortID = value | ||
115 | case "port_name": | ||
116 | if len(value) > 2 { | ||
117 | value = value[2:] | ||
118 | } | ||
119 | host.PortName = value | ||
120 | case "fabric_name": | ||
121 | if len(value) > 2 { | ||
122 | value = value[2:] | ||
123 | } | ||
124 | host.FabricName = value | ||
125 | case "dev_loss_tmo": | ||
126 | host.DevLossTMO = value | ||
127 | case "supported_classes": | ||
128 | host.SupportedClasses = value | ||
129 | case "supported_speeds": | ||
130 | host.SupportedSpeeds = value | ||
131 | case "symbolic_name": | ||
132 | host.SymbolicName = value | ||
133 | } | ||
134 | } | ||
135 | |||
136 | counters, err := parseFibreChannelStatistics(path) | ||
137 | if err != nil { | ||
138 | return nil, err | ||
139 | } | ||
140 | host.Counters = *counters | ||
141 | |||
142 | return &host, nil | ||
143 | } | ||
144 | |||
145 | // parseFibreChannelStatistics parses metrics from a single FC host. | ||
146 | func parseFibreChannelStatistics(hostPath string) (*FibreChannelCounters, error) { | ||
147 | var counters FibreChannelCounters | ||
148 | |||
149 | path := filepath.Join(hostPath, "statistics") | ||
150 | files, err := ioutil.ReadDir(path) | ||
151 | if err != nil { | ||
152 | return nil, err | ||
153 | } | ||
154 | |||
155 | for _, f := range files { | ||
156 | if !f.Mode().IsRegular() || f.Name() == "reset_statistics" { | ||
157 | continue | ||
158 | } | ||
159 | |||
160 | name := filepath.Join(path, f.Name()) | ||
161 | value, err := util.SysReadFile(name) | ||
162 | if err != nil { | ||
163 | // there are some write-only files in this directory; we can safely skip over them | ||
164 | if os.IsNotExist(err) || err.Error() == "operation not supported" || err.Error() == "invalid argument" { | ||
165 | continue | ||
166 | } | ||
167 | return nil, fmt.Errorf("failed to read file %q: %v", name, err) | ||
168 | } | ||
169 | |||
170 | vp := util.NewValueParser(value) | ||
171 | |||
172 | // Below switch was automatically generated. Don't need everything in there yet, so the unwanted bits are commented out. | ||
173 | switch f.Name() { | ||
174 | case "dumped_frames": | ||
175 | counters.DumpedFrames = *vp.PUInt64() | ||
176 | case "error_frames": | ||
177 | counters.ErrorFrames = *vp.PUInt64() | ||
178 | /* | ||
179 | case "fc_no_free_exch": | ||
180 | counters.FcNoFreeExch = *vp.PUInt64() | ||
181 | case "fc_no_free_exch_xid": | ||
182 | counters.FcNoFreeExchXid = *vp.PUInt64() | ||
183 | case "fc_non_bls_resp": | ||
184 | counters.FcNonBlsResp = *vp.PUInt64() | ||
185 | case "fc_seq_not_found": | ||
186 | counters.FcSeqNotFound = *vp.PUInt64() | ||
187 | case "fc_xid_busy": | ||
188 | counters.FcXidBusy = *vp.PUInt64() | ||
189 | case "fc_xid_not_found": | ||
190 | counters.FcXidNotFound = *vp.PUInt64() | ||
191 | case "fcp_control_requests": | ||
192 | counters.FcpControlRequests = *vp.PUInt64() | ||
193 | case "fcp_frame_alloc_failures": | ||
194 | counters.FcpFrameAllocFailures = *vp.PUInt64() | ||
195 | case "fcp_input_megabytes": | ||
196 | counters.FcpInputMegabytes = *vp.PUInt64() | ||
197 | case "fcp_input_requests": | ||
198 | counters.FcpInputRequests = *vp.PUInt64() | ||
199 | case "fcp_output_megabytes": | ||
200 | counters.FcpOutputMegabytes = *vp.PUInt64() | ||
201 | case "fcp_output_requests": | ||
202 | counters.FcpOutputRequests = *vp.PUInt64() | ||
203 | */ | ||
204 | case "fcp_packet_aborts": | ||
205 | counters.FCPPacketAborts = *vp.PUInt64() | ||
206 | /* | ||
207 | case "fcp_packet_alloc_failures": | ||
208 | counters.FcpPacketAllocFailures = *vp.PUInt64() | ||
209 | */ | ||
210 | case "invalid_tx_word_count": | ||
211 | counters.InvalidTXWordCount = *vp.PUInt64() | ||
212 | case "invalid_crc_count": | ||
213 | counters.InvalidCRCCount = *vp.PUInt64() | ||
214 | case "link_failure_count": | ||
215 | counters.LinkFailureCount = *vp.PUInt64() | ||
216 | /* | ||
217 | case "lip_count": | ||
218 | counters.LipCount = *vp.PUInt64() | ||
219 | */ | ||
220 | case "loss_of_signal_count": | ||
221 | counters.LossOfSignalCount = *vp.PUInt64() | ||
222 | case "loss_of_sync_count": | ||
223 | counters.LossOfSyncCount = *vp.PUInt64() | ||
224 | case "nos_count": | ||
225 | counters.NosCount = *vp.PUInt64() | ||
226 | /* | ||
227 | case "prim_seq_protocol_err_count": | ||
228 | counters.PrimSeqProtocolErrCount = *vp.PUInt64() | ||
229 | */ | ||
230 | case "rx_frames": | ||
231 | counters.RXFrames = *vp.PUInt64() | ||
232 | case "rx_words": | ||
233 | counters.RXWords = *vp.PUInt64() | ||
234 | case "seconds_since_last_reset": | ||
235 | counters.SecondsSinceLastReset = *vp.PUInt64() | ||
236 | case "tx_frames": | ||
237 | counters.TXFrames = *vp.PUInt64() | ||
238 | case "tx_words": | ||
239 | counters.TXWords = *vp.PUInt64() | ||
240 | } | ||
241 | |||
242 | if err := vp.Err(); err != nil { | ||
243 | return nil, err | ||
244 | } | ||
245 | |||
246 | } | ||
247 | |||
248 | return &counters, nil | ||
249 | } | ||
diff --git a/vendor/github.com/prometheus/procfs/sysfs/class_infiniband.go b/vendor/github.com/prometheus/procfs/sysfs/class_infiniband.go index be900fa..0826e1c 100644 --- a/vendor/github.com/prometheus/procfs/sysfs/class_infiniband.go +++ b/vendor/github.com/prometheus/procfs/sysfs/class_infiniband.go | |||
@@ -42,22 +42,26 @@ type InfiniBandCounters struct { | |||
42 | LegacyPortXmitData64 *uint64 // counters_ext/port_xmit_data_64 | 42 | LegacyPortXmitData64 *uint64 // counters_ext/port_xmit_data_64 |
43 | LegacyPortXmitPackets64 *uint64 // counters_ext/port_xmit_packets_64 | 43 | LegacyPortXmitPackets64 *uint64 // counters_ext/port_xmit_packets_64 |
44 | 44 | ||
45 | LinkDowned *uint64 // counters/link_downed | 45 | LinkDowned *uint64 // counters/link_downed |
46 | LinkErrorRecovery *uint64 // counters/link_error_recovery | 46 | LinkErrorRecovery *uint64 // counters/link_error_recovery |
47 | MulticastRcvPackets *uint64 // counters/multicast_rcv_packets | 47 | MulticastRcvPackets *uint64 // counters/multicast_rcv_packets |
48 | MulticastXmitPackets *uint64 // counters/multicast_xmit_packets | 48 | MulticastXmitPackets *uint64 // counters/multicast_xmit_packets |
49 | PortRcvConstraintErrors *uint64 // counters/port_rcv_constraint_errors | 49 | PortRcvConstraintErrors *uint64 // counters/port_rcv_constraint_errors |
50 | PortRcvData *uint64 // counters/port_rcv_data | 50 | PortRcvData *uint64 // counters/port_rcv_data |
51 | PortRcvDiscards *uint64 // counters/port_rcv_discards | 51 | PortRcvDiscards *uint64 // counters/port_rcv_discards |
52 | PortRcvErrors *uint64 // counters/port_rcv_errors | 52 | PortRcvErrors *uint64 // counters/port_rcv_errors |
53 | PortRcvPackets *uint64 // counters/port_rcv_packets | 53 | PortRcvPackets *uint64 // counters/port_rcv_packets |
54 | PortXmitConstraintErrors *uint64 // counters/port_xmit_constraint_errors | 54 | PortRcvRemotePhysicalErrors *uint64 // counters/port_rcv_remote_physical_errors |
55 | PortXmitData *uint64 // counters/port_xmit_data | 55 | PortRcvSwitchRelayErrors *uint64 // counters/port_rcv_switch_relay_errors |
56 | PortXmitDiscards *uint64 // counters/port_xmit_discards | 56 | PortXmitConstraintErrors *uint64 // counters/port_xmit_constraint_errors |
57 | PortXmitPackets *uint64 // counters/port_xmit_packets | 57 | PortXmitData *uint64 // counters/port_xmit_data |
58 | PortXmitWait *uint64 // counters/port_xmit_wait | 58 | PortXmitDiscards *uint64 // counters/port_xmit_discards |
59 | UnicastRcvPackets *uint64 // counters/unicast_rcv_packets | 59 | PortXmitPackets *uint64 // counters/port_xmit_packets |
60 | UnicastXmitPackets *uint64 // counters/unicast_xmit_packets | 60 | PortXmitWait *uint64 // counters/port_xmit_wait |
61 | SymbolError *uint64 // counters/symbol_error | ||
62 | UnicastRcvPackets *uint64 // counters/unicast_rcv_packets | ||
63 | UnicastXmitPackets *uint64 // counters/unicast_xmit_packets | ||
64 | VL15Dropped *uint64 // counters/VL15_dropped | ||
61 | } | 65 | } |
62 | 66 | ||
63 | // InfiniBandPort contains info from files in | 67 | // InfiniBandPort contains info from files in |
@@ -287,6 +291,10 @@ func parseInfiniBandCounters(portPath string) (*InfiniBandCounters, error) { | |||
287 | counters.PortRcvErrors = vp.PUInt64() | 291 | counters.PortRcvErrors = vp.PUInt64() |
288 | case "port_rcv_packets": | 292 | case "port_rcv_packets": |
289 | counters.PortRcvPackets = vp.PUInt64() | 293 | counters.PortRcvPackets = vp.PUInt64() |
294 | case "port_rcv_remote_physical_errors": | ||
295 | counters.PortRcvRemotePhysicalErrors = vp.PUInt64() | ||
296 | case "port_rcv_switch_relay_errors": | ||
297 | counters.PortRcvSwitchRelayErrors = vp.PUInt64() | ||
290 | case "port_xmit_constraint_errors": | 298 | case "port_xmit_constraint_errors": |
291 | counters.PortXmitConstraintErrors = vp.PUInt64() | 299 | counters.PortXmitConstraintErrors = vp.PUInt64() |
292 | case "port_xmit_data": | 300 | case "port_xmit_data": |
@@ -300,10 +308,14 @@ func parseInfiniBandCounters(portPath string) (*InfiniBandCounters, error) { | |||
300 | counters.PortXmitPackets = vp.PUInt64() | 308 | counters.PortXmitPackets = vp.PUInt64() |
301 | case "port_xmit_wait": | 309 | case "port_xmit_wait": |
302 | counters.PortXmitWait = vp.PUInt64() | 310 | counters.PortXmitWait = vp.PUInt64() |
311 | case "symbol_error": | ||
312 | counters.SymbolError = vp.PUInt64() | ||
303 | case "unicast_rcv_packets": | 313 | case "unicast_rcv_packets": |
304 | counters.UnicastRcvPackets = vp.PUInt64() | 314 | counters.UnicastRcvPackets = vp.PUInt64() |
305 | case "unicast_xmit_packets": | 315 | case "unicast_xmit_packets": |
306 | counters.UnicastXmitPackets = vp.PUInt64() | 316 | counters.UnicastXmitPackets = vp.PUInt64() |
317 | case "VL15_dropped": | ||
318 | counters.VL15Dropped = vp.PUInt64() | ||
307 | } | 319 | } |
308 | 320 | ||
309 | if err := vp.Err(); err != nil { | 321 | if err := vp.Err(); err != nil { |
diff --git a/vendor/github.com/prometheus/procfs/sysfs/class_power_supply.go b/vendor/github.com/prometheus/procfs/sysfs/class_power_supply.go index d12e913..dceec9e 100644 --- a/vendor/github.com/prometheus/procfs/sysfs/class_power_supply.go +++ b/vendor/github.com/prometheus/procfs/sysfs/class_power_supply.go | |||
@@ -110,7 +110,7 @@ func (fs FS) PowerSupplyClass() (PowerSupplyClass, error) { | |||
110 | 110 | ||
111 | dirs, err := ioutil.ReadDir(path) | 111 | dirs, err := ioutil.ReadDir(path) |
112 | if err != nil { | 112 | if err != nil { |
113 | return nil, fmt.Errorf("failed to list power supplies at %q: %v", path, err) | 113 | return nil, err |
114 | } | 114 | } |
115 | 115 | ||
116 | psc := make(PowerSupplyClass, len(dirs)) | 116 | psc := make(PowerSupplyClass, len(dirs)) |
diff --git a/vendor/github.com/prometheus/procfs/sysfs/class_thermal.go b/vendor/github.com/prometheus/procfs/sysfs/class_thermal.go index cfe11ad..493a531 100644 --- a/vendor/github.com/prometheus/procfs/sysfs/class_thermal.go +++ b/vendor/github.com/prometheus/procfs/sysfs/class_thermal.go | |||
@@ -16,9 +16,11 @@ | |||
16 | package sysfs | 16 | package sysfs |
17 | 17 | ||
18 | import ( | 18 | import ( |
19 | "errors" | ||
19 | "os" | 20 | "os" |
20 | "path/filepath" | 21 | "path/filepath" |
21 | "strings" | 22 | "strings" |
23 | "syscall" | ||
22 | 24 | ||
23 | "github.com/prometheus/procfs/internal/util" | 25 | "github.com/prometheus/procfs/internal/util" |
24 | ) | 26 | ) |
@@ -29,7 +31,7 @@ import ( | |||
29 | type ClassThermalZoneStats struct { | 31 | type ClassThermalZoneStats struct { |
30 | Name string // The name of the zone from the directory structure. | 32 | Name string // The name of the zone from the directory structure. |
31 | Type string // The type of thermal zone. | 33 | Type string // The type of thermal zone. |
32 | Temp uint64 // Temperature in millidegree Celsius. | 34 | Temp int64 // Temperature in millidegree Celsius. |
33 | Policy string // One of the various thermal governors used for a particular zone. | 35 | Policy string // One of the various thermal governors used for a particular zone. |
34 | Mode *bool // Optional: One of the predefined values in [enabled, disabled]. | 36 | Mode *bool // Optional: One of the predefined values in [enabled, disabled]. |
35 | Passive *uint64 // Optional: millidegrees Celsius. (0 for disabled, > 1000 for enabled+value) | 37 | Passive *uint64 // Optional: millidegrees Celsius. (0 for disabled, > 1000 for enabled+value) |
@@ -39,20 +41,20 @@ type ClassThermalZoneStats struct { | |||
39 | func (fs FS) ClassThermalZoneStats() ([]ClassThermalZoneStats, error) { | 41 | func (fs FS) ClassThermalZoneStats() ([]ClassThermalZoneStats, error) { |
40 | zones, err := filepath.Glob(fs.sys.Path("class/thermal/thermal_zone[0-9]*")) | 42 | zones, err := filepath.Glob(fs.sys.Path("class/thermal/thermal_zone[0-9]*")) |
41 | if err != nil { | 43 | if err != nil { |
42 | return []ClassThermalZoneStats{}, err | 44 | return nil, err |
43 | } | 45 | } |
44 | 46 | ||
45 | var zoneStats = ClassThermalZoneStats{} | 47 | stats := make([]ClassThermalZoneStats, 0, len(zones)) |
46 | stats := make([]ClassThermalZoneStats, len(zones)) | 48 | for _, zone := range zones { |
47 | for i, zone := range zones { | 49 | zoneStats, err := parseClassThermalZone(zone) |
48 | zoneName := strings.TrimPrefix(filepath.Base(zone), "thermal_zone") | ||
49 | |||
50 | zoneStats, err = parseClassThermalZone(zone) | ||
51 | if err != nil { | 50 | if err != nil { |
52 | return []ClassThermalZoneStats{}, err | 51 | if errors.Is(err, syscall.ENODATA) { |
52 | continue | ||
53 | } | ||
54 | return nil, err | ||
53 | } | 55 | } |
54 | zoneStats.Name = zoneName | 56 | zoneStats.Name = strings.TrimPrefix(filepath.Base(zone), "thermal_zone") |
55 | stats[i] = zoneStats | 57 | stats = append(stats, zoneStats) |
56 | } | 58 | } |
57 | return stats, nil | 59 | return stats, nil |
58 | } | 60 | } |
@@ -67,7 +69,7 @@ func parseClassThermalZone(zone string) (ClassThermalZoneStats, error) { | |||
67 | if err != nil { | 69 | if err != nil { |
68 | return ClassThermalZoneStats{}, err | 70 | return ClassThermalZoneStats{}, err |
69 | } | 71 | } |
70 | zoneTemp, err := util.ReadUintFromFile(filepath.Join(zone, "temp")) | 72 | zoneTemp, err := util.ReadIntFromFile(filepath.Join(zone, "temp")) |
71 | if err != nil { | 73 | if err != nil { |
72 | return ClassThermalZoneStats{}, err | 74 | return ClassThermalZoneStats{}, err |
73 | } | 75 | } |
diff --git a/vendor/golang.org/x/sys/unix/syscall_linux.go b/vendor/golang.org/x/sys/unix/syscall_linux.go index 942a4bb..7b7c727 100644 --- a/vendor/golang.org/x/sys/unix/syscall_linux.go +++ b/vendor/golang.org/x/sys/unix/syscall_linux.go | |||
@@ -97,6 +97,12 @@ func IoctlSetRTCTime(fd int, value *RTCTime) error { | |||
97 | return err | 97 | return err |
98 | } | 98 | } |
99 | 99 | ||
100 | func IoctlSetRTCWkAlrm(fd int, value *RTCWkAlrm) error { | ||
101 | err := ioctl(fd, RTC_WKALM_SET, uintptr(unsafe.Pointer(value))) | ||
102 | runtime.KeepAlive(value) | ||
103 | return err | ||
104 | } | ||
105 | |||
100 | func IoctlGetUint32(fd int, req uint) (uint32, error) { | 106 | func IoctlGetUint32(fd int, req uint) (uint32, error) { |
101 | var value uint32 | 107 | var value uint32 |
102 | err := ioctl(fd, req, uintptr(unsafe.Pointer(&value))) | 108 | err := ioctl(fd, req, uintptr(unsafe.Pointer(&value))) |
@@ -109,6 +115,12 @@ func IoctlGetRTCTime(fd int) (*RTCTime, error) { | |||
109 | return &value, err | 115 | return &value, err |
110 | } | 116 | } |
111 | 117 | ||
118 | func IoctlGetRTCWkAlrm(fd int) (*RTCWkAlrm, error) { | ||
119 | var value RTCWkAlrm | ||
120 | err := ioctl(fd, RTC_WKALM_RD, uintptr(unsafe.Pointer(&value))) | ||
121 | return &value, err | ||
122 | } | ||
123 | |||
112 | //sys Linkat(olddirfd int, oldpath string, newdirfd int, newpath string, flags int) (err error) | 124 | //sys Linkat(olddirfd int, oldpath string, newdirfd int, newpath string, flags int) (err error) |
113 | 125 | ||
114 | func Link(oldpath string, newpath string) (err error) { | 126 | func Link(oldpath string, newpath string) (err error) { |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux.go b/vendor/golang.org/x/sys/unix/zerrors_linux.go index 6e3cfec..f8bd50c 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux.go | |||
@@ -160,78 +160,28 @@ const ( | |||
160 | BPF_A = 0x10 | 160 | BPF_A = 0x10 |
161 | BPF_ABS = 0x20 | 161 | BPF_ABS = 0x20 |
162 | BPF_ADD = 0x0 | 162 | BPF_ADD = 0x0 |
163 | BPF_ADJ_ROOM_ENCAP_L2_MASK = 0xff | ||
164 | BPF_ADJ_ROOM_ENCAP_L2_SHIFT = 0x38 | ||
165 | BPF_ALU = 0x4 | 163 | BPF_ALU = 0x4 |
166 | BPF_ALU64 = 0x7 | 164 | BPF_ALU64 = 0x7 |
167 | BPF_AND = 0x50 | 165 | BPF_AND = 0x50 |
168 | BPF_ANY = 0x0 | ||
169 | BPF_ARSH = 0xc0 | 166 | BPF_ARSH = 0xc0 |
170 | BPF_B = 0x10 | 167 | BPF_B = 0x10 |
171 | BPF_BUILD_ID_SIZE = 0x14 | 168 | BPF_BUILD_ID_SIZE = 0x14 |
172 | BPF_CALL = 0x80 | 169 | BPF_CALL = 0x80 |
173 | BPF_DEVCG_ACC_MKNOD = 0x1 | ||
174 | BPF_DEVCG_ACC_READ = 0x2 | ||
175 | BPF_DEVCG_ACC_WRITE = 0x4 | ||
176 | BPF_DEVCG_DEV_BLOCK = 0x1 | ||
177 | BPF_DEVCG_DEV_CHAR = 0x2 | ||
178 | BPF_DIV = 0x30 | 170 | BPF_DIV = 0x30 |
179 | BPF_DW = 0x18 | 171 | BPF_DW = 0x18 |
180 | BPF_END = 0xd0 | 172 | BPF_END = 0xd0 |
181 | BPF_EXIST = 0x2 | ||
182 | BPF_EXIT = 0x90 | 173 | BPF_EXIT = 0x90 |
183 | BPF_FLOW_DISSECTOR_F_PARSE_1ST_FRAG = 0x1 | ||
184 | BPF_FLOW_DISSECTOR_F_STOP_AT_ENCAP = 0x4 | ||
185 | BPF_FLOW_DISSECTOR_F_STOP_AT_FLOW_LABEL = 0x2 | ||
186 | BPF_FROM_BE = 0x8 | 174 | BPF_FROM_BE = 0x8 |
187 | BPF_FROM_LE = 0x0 | 175 | BPF_FROM_LE = 0x0 |
188 | BPF_FS_MAGIC = 0xcafe4a11 | 176 | BPF_FS_MAGIC = 0xcafe4a11 |
189 | BPF_F_ADJ_ROOM_ENCAP_L3_IPV4 = 0x2 | ||
190 | BPF_F_ADJ_ROOM_ENCAP_L3_IPV6 = 0x4 | ||
191 | BPF_F_ADJ_ROOM_ENCAP_L4_GRE = 0x8 | ||
192 | BPF_F_ADJ_ROOM_ENCAP_L4_UDP = 0x10 | ||
193 | BPF_F_ADJ_ROOM_FIXED_GSO = 0x1 | ||
194 | BPF_F_ALLOW_MULTI = 0x2 | 177 | BPF_F_ALLOW_MULTI = 0x2 |
195 | BPF_F_ALLOW_OVERRIDE = 0x1 | 178 | BPF_F_ALLOW_OVERRIDE = 0x1 |
196 | BPF_F_ANY_ALIGNMENT = 0x2 | 179 | BPF_F_ANY_ALIGNMENT = 0x2 |
197 | BPF_F_CLONE = 0x200 | ||
198 | BPF_F_CTXLEN_MASK = 0xfffff00000000 | ||
199 | BPF_F_CURRENT_CPU = 0xffffffff | ||
200 | BPF_F_CURRENT_NETNS = -0x1 | ||
201 | BPF_F_DONT_FRAGMENT = 0x4 | ||
202 | BPF_F_FAST_STACK_CMP = 0x200 | ||
203 | BPF_F_HDR_FIELD_MASK = 0xf | ||
204 | BPF_F_INDEX_MASK = 0xffffffff | ||
205 | BPF_F_INGRESS = 0x1 | ||
206 | BPF_F_INVALIDATE_HASH = 0x2 | ||
207 | BPF_F_LOCK = 0x4 | ||
208 | BPF_F_MARK_ENFORCE = 0x40 | ||
209 | BPF_F_MARK_MANGLED_0 = 0x20 | ||
210 | BPF_F_MMAPABLE = 0x400 | ||
211 | BPF_F_NO_COMMON_LRU = 0x2 | ||
212 | BPF_F_NO_PREALLOC = 0x1 | ||
213 | BPF_F_NUMA_NODE = 0x4 | ||
214 | BPF_F_PSEUDO_HDR = 0x10 | ||
215 | BPF_F_QUERY_EFFECTIVE = 0x1 | 180 | BPF_F_QUERY_EFFECTIVE = 0x1 |
216 | BPF_F_RDONLY = 0x8 | ||
217 | BPF_F_RDONLY_PROG = 0x80 | ||
218 | BPF_F_RECOMPUTE_CSUM = 0x1 | ||
219 | BPF_F_REPLACE = 0x4 | 181 | BPF_F_REPLACE = 0x4 |
220 | BPF_F_REUSE_STACKID = 0x400 | ||
221 | BPF_F_SEQ_NUMBER = 0x8 | ||
222 | BPF_F_SKIP_FIELD_MASK = 0xff | ||
223 | BPF_F_STACK_BUILD_ID = 0x20 | ||
224 | BPF_F_STRICT_ALIGNMENT = 0x1 | 182 | BPF_F_STRICT_ALIGNMENT = 0x1 |
225 | BPF_F_SYSCTL_BASE_NAME = 0x1 | ||
226 | BPF_F_TEST_RND_HI32 = 0x4 | 183 | BPF_F_TEST_RND_HI32 = 0x4 |
227 | BPF_F_TEST_STATE_FREQ = 0x8 | 184 | BPF_F_TEST_STATE_FREQ = 0x8 |
228 | BPF_F_TUNINFO_IPV6 = 0x1 | ||
229 | BPF_F_USER_BUILD_ID = 0x800 | ||
230 | BPF_F_USER_STACK = 0x100 | ||
231 | BPF_F_WRONLY = 0x10 | ||
232 | BPF_F_WRONLY_PROG = 0x100 | ||
233 | BPF_F_ZERO_CSUM_TX = 0x2 | ||
234 | BPF_F_ZERO_SEED = 0x40 | ||
235 | BPF_H = 0x8 | 185 | BPF_H = 0x8 |
236 | BPF_IMM = 0x0 | 186 | BPF_IMM = 0x0 |
237 | BPF_IND = 0x40 | 187 | BPF_IND = 0x40 |
@@ -267,7 +217,6 @@ const ( | |||
267 | BPF_MUL = 0x20 | 217 | BPF_MUL = 0x20 |
268 | BPF_NEG = 0x80 | 218 | BPF_NEG = 0x80 |
269 | BPF_NET_OFF = -0x100000 | 219 | BPF_NET_OFF = -0x100000 |
270 | BPF_NOEXIST = 0x1 | ||
271 | BPF_OBJ_NAME_LEN = 0x10 | 220 | BPF_OBJ_NAME_LEN = 0x10 |
272 | BPF_OR = 0x40 | 221 | BPF_OR = 0x40 |
273 | BPF_PSEUDO_CALL = 0x1 | 222 | BPF_PSEUDO_CALL = 0x1 |
@@ -275,12 +224,6 @@ const ( | |||
275 | BPF_PSEUDO_MAP_VALUE = 0x2 | 224 | BPF_PSEUDO_MAP_VALUE = 0x2 |
276 | BPF_RET = 0x6 | 225 | BPF_RET = 0x6 |
277 | BPF_RSH = 0x70 | 226 | BPF_RSH = 0x70 |
278 | BPF_SK_STORAGE_GET_F_CREATE = 0x1 | ||
279 | BPF_SOCK_OPS_ALL_CB_FLAGS = 0xf | ||
280 | BPF_SOCK_OPS_RETRANS_CB_FLAG = 0x2 | ||
281 | BPF_SOCK_OPS_RTO_CB_FLAG = 0x1 | ||
282 | BPF_SOCK_OPS_RTT_CB_FLAG = 0x8 | ||
283 | BPF_SOCK_OPS_STATE_CB_FLAG = 0x4 | ||
284 | BPF_ST = 0x2 | 227 | BPF_ST = 0x2 |
285 | BPF_STX = 0x3 | 228 | BPF_STX = 0x3 |
286 | BPF_SUB = 0x10 | 229 | BPF_SUB = 0x10 |
@@ -378,12 +321,14 @@ const ( | |||
378 | CLOCK_TXINT = 0x3 | 321 | CLOCK_TXINT = 0x3 |
379 | CLONE_ARGS_SIZE_VER0 = 0x40 | 322 | CLONE_ARGS_SIZE_VER0 = 0x40 |
380 | CLONE_ARGS_SIZE_VER1 = 0x50 | 323 | CLONE_ARGS_SIZE_VER1 = 0x50 |
324 | CLONE_ARGS_SIZE_VER2 = 0x58 | ||
381 | CLONE_CHILD_CLEARTID = 0x200000 | 325 | CLONE_CHILD_CLEARTID = 0x200000 |
382 | CLONE_CHILD_SETTID = 0x1000000 | 326 | CLONE_CHILD_SETTID = 0x1000000 |
383 | CLONE_CLEAR_SIGHAND = 0x100000000 | 327 | CLONE_CLEAR_SIGHAND = 0x100000000 |
384 | CLONE_DETACHED = 0x400000 | 328 | CLONE_DETACHED = 0x400000 |
385 | CLONE_FILES = 0x400 | 329 | CLONE_FILES = 0x400 |
386 | CLONE_FS = 0x200 | 330 | CLONE_FS = 0x200 |
331 | CLONE_INTO_CGROUP = 0x200000000 | ||
387 | CLONE_IO = 0x80000000 | 332 | CLONE_IO = 0x80000000 |
388 | CLONE_NEWCGROUP = 0x2000000 | 333 | CLONE_NEWCGROUP = 0x2000000 |
389 | CLONE_NEWIPC = 0x8000000 | 334 | CLONE_NEWIPC = 0x8000000 |
@@ -598,7 +543,9 @@ const ( | |||
598 | FAN_DELETE = 0x200 | 543 | FAN_DELETE = 0x200 |
599 | FAN_DELETE_SELF = 0x400 | 544 | FAN_DELETE_SELF = 0x400 |
600 | FAN_DENY = 0x2 | 545 | FAN_DENY = 0x2 |
546 | FAN_DIR_MODIFY = 0x80000 | ||
601 | FAN_ENABLE_AUDIT = 0x40 | 547 | FAN_ENABLE_AUDIT = 0x40 |
548 | FAN_EVENT_INFO_TYPE_DFID_NAME = 0x2 | ||
602 | FAN_EVENT_INFO_TYPE_FID = 0x1 | 549 | FAN_EVENT_INFO_TYPE_FID = 0x1 |
603 | FAN_EVENT_METADATA_LEN = 0x18 | 550 | FAN_EVENT_METADATA_LEN = 0x18 |
604 | FAN_EVENT_ON_CHILD = 0x8000000 | 551 | FAN_EVENT_ON_CHILD = 0x8000000 |
@@ -2108,8 +2055,6 @@ const ( | |||
2108 | TCOFLUSH = 0x1 | 2055 | TCOFLUSH = 0x1 |
2109 | TCOOFF = 0x0 | 2056 | TCOOFF = 0x0 |
2110 | TCOON = 0x1 | 2057 | TCOON = 0x1 |
2111 | TCP_BPF_IW = 0x3e9 | ||
2112 | TCP_BPF_SNDCWND_CLAMP = 0x3ea | ||
2113 | TCP_CC_INFO = 0x1a | 2058 | TCP_CC_INFO = 0x1a |
2114 | TCP_CM_INQ = 0x24 | 2059 | TCP_CM_INQ = 0x24 |
2115 | TCP_CONGESTION = 0xd | 2060 | TCP_CONGESTION = 0xd |
@@ -2384,8 +2329,9 @@ const ( | |||
2384 | XDP_COPY = 0x2 | 2329 | XDP_COPY = 0x2 |
2385 | XDP_FLAGS_DRV_MODE = 0x4 | 2330 | XDP_FLAGS_DRV_MODE = 0x4 |
2386 | XDP_FLAGS_HW_MODE = 0x8 | 2331 | XDP_FLAGS_HW_MODE = 0x8 |
2387 | XDP_FLAGS_MASK = 0xf | 2332 | XDP_FLAGS_MASK = 0x1f |
2388 | XDP_FLAGS_MODES = 0xe | 2333 | XDP_FLAGS_MODES = 0xe |
2334 | XDP_FLAGS_REPLACE = 0x10 | ||
2389 | XDP_FLAGS_SKB_MODE = 0x2 | 2335 | XDP_FLAGS_SKB_MODE = 0x2 |
2390 | XDP_FLAGS_UPDATE_IF_NOEXIST = 0x1 | 2336 | XDP_FLAGS_UPDATE_IF_NOEXIST = 0x1 |
2391 | XDP_MMAP_OFFSETS = 0x1 | 2337 | XDP_MMAP_OFFSETS = 0x1 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_386.go b/vendor/golang.org/x/sys/unix/zerrors_linux_386.go index 5e97411..8d207b0 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_386.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_386.go | |||
@@ -75,6 +75,7 @@ const ( | |||
75 | FP_XSTATE_MAGIC2 = 0x46505845 | 75 | FP_XSTATE_MAGIC2 = 0x46505845 |
76 | FS_IOC_ENABLE_VERITY = 0x40806685 | 76 | FS_IOC_ENABLE_VERITY = 0x40806685 |
77 | FS_IOC_GETFLAGS = 0x80046601 | 77 | FS_IOC_GETFLAGS = 0x80046601 |
78 | FS_IOC_GET_ENCRYPTION_NONCE = 0x8010661b | ||
78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 | 79 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 |
79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 | 80 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 |
80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 | 81 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go index 47a57fe..c4bf9cb 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go | |||
@@ -75,6 +75,7 @@ const ( | |||
75 | FP_XSTATE_MAGIC2 = 0x46505845 | 75 | FP_XSTATE_MAGIC2 = 0x46505845 |
76 | FS_IOC_ENABLE_VERITY = 0x40806685 | 76 | FS_IOC_ENABLE_VERITY = 0x40806685 |
77 | FS_IOC_GETFLAGS = 0x80086601 | 77 | FS_IOC_GETFLAGS = 0x80086601 |
78 | FS_IOC_GET_ENCRYPTION_NONCE = 0x8010661b | ||
78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 | 79 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 |
79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 | 80 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 |
80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 | 81 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go b/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go index df2eea4..0cab052 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go | |||
@@ -74,6 +74,7 @@ const ( | |||
74 | FLUSHO = 0x1000 | 74 | FLUSHO = 0x1000 |
75 | FS_IOC_ENABLE_VERITY = 0x40806685 | 75 | FS_IOC_ENABLE_VERITY = 0x40806685 |
76 | FS_IOC_GETFLAGS = 0x80046601 | 76 | FS_IOC_GETFLAGS = 0x80046601 |
77 | FS_IOC_GET_ENCRYPTION_NONCE = 0x8010661b | ||
77 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 | 78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 |
78 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 | 79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 |
79 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 | 80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go index 4e12142..370d0a7 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go | |||
@@ -77,6 +77,7 @@ const ( | |||
77 | FPSIMD_MAGIC = 0x46508001 | 77 | FPSIMD_MAGIC = 0x46508001 |
78 | FS_IOC_ENABLE_VERITY = 0x40806685 | 78 | FS_IOC_ENABLE_VERITY = 0x40806685 |
79 | FS_IOC_GETFLAGS = 0x80086601 | 79 | FS_IOC_GETFLAGS = 0x80086601 |
80 | FS_IOC_GET_ENCRYPTION_NONCE = 0x8010661b | ||
80 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 | 81 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 |
81 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 | 82 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 |
82 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 | 83 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go index a23b080..fbf2f31 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go | |||
@@ -74,6 +74,7 @@ const ( | |||
74 | FLUSHO = 0x2000 | 74 | FLUSHO = 0x2000 |
75 | FS_IOC_ENABLE_VERITY = 0x80806685 | 75 | FS_IOC_ENABLE_VERITY = 0x80806685 |
76 | FS_IOC_GETFLAGS = 0x40046601 | 76 | FS_IOC_GETFLAGS = 0x40046601 |
77 | FS_IOC_GET_ENCRYPTION_NONCE = 0x4010661b | ||
77 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 | 78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 |
78 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 | 79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 |
79 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 | 80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go index a5a921e..25e74b3 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go | |||
@@ -74,6 +74,7 @@ const ( | |||
74 | FLUSHO = 0x2000 | 74 | FLUSHO = 0x2000 |
75 | FS_IOC_ENABLE_VERITY = 0x80806685 | 75 | FS_IOC_ENABLE_VERITY = 0x80806685 |
76 | FS_IOC_GETFLAGS = 0x40086601 | 76 | FS_IOC_GETFLAGS = 0x40086601 |
77 | FS_IOC_GET_ENCRYPTION_NONCE = 0x4010661b | ||
77 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 | 78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 |
78 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 | 79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 |
79 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 | 80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go index d088e19..4ecc0bc 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go | |||
@@ -74,6 +74,7 @@ const ( | |||
74 | FLUSHO = 0x2000 | 74 | FLUSHO = 0x2000 |
75 | FS_IOC_ENABLE_VERITY = 0x80806685 | 75 | FS_IOC_ENABLE_VERITY = 0x80806685 |
76 | FS_IOC_GETFLAGS = 0x40086601 | 76 | FS_IOC_GETFLAGS = 0x40086601 |
77 | FS_IOC_GET_ENCRYPTION_NONCE = 0x4010661b | ||
77 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 | 78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 |
78 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 | 79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 |
79 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 | 80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go index 0ddf9d5..dfb8f88 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go | |||
@@ -74,6 +74,7 @@ const ( | |||
74 | FLUSHO = 0x2000 | 74 | FLUSHO = 0x2000 |
75 | FS_IOC_ENABLE_VERITY = 0x80806685 | 75 | FS_IOC_ENABLE_VERITY = 0x80806685 |
76 | FS_IOC_GETFLAGS = 0x40046601 | 76 | FS_IOC_GETFLAGS = 0x40046601 |
77 | FS_IOC_GET_ENCRYPTION_NONCE = 0x4010661b | ||
77 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 | 78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 |
78 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 | 79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 |
79 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 | 80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go index a93ffc1..72d8dad 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go | |||
@@ -74,6 +74,7 @@ const ( | |||
74 | FLUSHO = 0x800000 | 74 | FLUSHO = 0x800000 |
75 | FS_IOC_ENABLE_VERITY = 0x80806685 | 75 | FS_IOC_ENABLE_VERITY = 0x80806685 |
76 | FS_IOC_GETFLAGS = 0x40086601 | 76 | FS_IOC_GETFLAGS = 0x40086601 |
77 | FS_IOC_GET_ENCRYPTION_NONCE = 0x4010661b | ||
77 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 | 78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 |
78 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 | 79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 |
79 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 | 80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go index c1ea48b..ca0e7b5 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go | |||
@@ -74,6 +74,7 @@ const ( | |||
74 | FLUSHO = 0x800000 | 74 | FLUSHO = 0x800000 |
75 | FS_IOC_ENABLE_VERITY = 0x80806685 | 75 | FS_IOC_ENABLE_VERITY = 0x80806685 |
76 | FS_IOC_GETFLAGS = 0x40086601 | 76 | FS_IOC_GETFLAGS = 0x40086601 |
77 | FS_IOC_GET_ENCRYPTION_NONCE = 0x4010661b | ||
77 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 | 78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 |
78 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 | 79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 |
79 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 | 80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go index 7def950..147511a 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go | |||
@@ -74,6 +74,7 @@ const ( | |||
74 | FLUSHO = 0x1000 | 74 | FLUSHO = 0x1000 |
75 | FS_IOC_ENABLE_VERITY = 0x40806685 | 75 | FS_IOC_ENABLE_VERITY = 0x40806685 |
76 | FS_IOC_GETFLAGS = 0x80086601 | 76 | FS_IOC_GETFLAGS = 0x80086601 |
77 | FS_IOC_GET_ENCRYPTION_NONCE = 0x8010661b | ||
77 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 | 78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 |
78 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 | 79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 |
79 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 | 80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go b/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go index d39293c..517349d 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go | |||
@@ -74,6 +74,7 @@ const ( | |||
74 | FLUSHO = 0x1000 | 74 | FLUSHO = 0x1000 |
75 | FS_IOC_ENABLE_VERITY = 0x40806685 | 75 | FS_IOC_ENABLE_VERITY = 0x40806685 |
76 | FS_IOC_GETFLAGS = 0x80086601 | 76 | FS_IOC_GETFLAGS = 0x80086601 |
77 | FS_IOC_GET_ENCRYPTION_NONCE = 0x8010661b | ||
77 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 | 78 | FS_IOC_GET_ENCRYPTION_POLICY = 0x400c6615 |
78 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 | 79 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x40106614 |
79 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 | 80 | FS_IOC_SET_ENCRYPTION_POLICY = 0x800c6613 |
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go index 3ff3ec6..0948224 100644 --- a/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go +++ b/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go | |||
@@ -78,6 +78,7 @@ const ( | |||
78 | FLUSHO = 0x1000 | 78 | FLUSHO = 0x1000 |
79 | FS_IOC_ENABLE_VERITY = 0x80806685 | 79 | FS_IOC_ENABLE_VERITY = 0x80806685 |
80 | FS_IOC_GETFLAGS = 0x40086601 | 80 | FS_IOC_GETFLAGS = 0x40086601 |
81 | FS_IOC_GET_ENCRYPTION_NONCE = 0x4010661b | ||
81 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 | 82 | FS_IOC_GET_ENCRYPTION_POLICY = 0x800c6615 |
82 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 | 83 | FS_IOC_GET_ENCRYPTION_PWSALT = 0x80106614 |
83 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 | 84 | FS_IOC_SET_ENCRYPTION_POLICY = 0x400c6613 |
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux.go b/vendor/golang.org/x/sys/unix/ztypes_linux.go index 416f776..27d67ac 100644 --- a/vendor/golang.org/x/sys/unix/ztypes_linux.go +++ b/vendor/golang.org/x/sys/unix/ztypes_linux.go | |||
@@ -1871,175 +1871,249 @@ const ( | |||
1871 | ) | 1871 | ) |
1872 | 1872 | ||
1873 | const ( | 1873 | const ( |
1874 | BPF_REG_0 = 0x0 | 1874 | BPF_REG_0 = 0x0 |
1875 | BPF_REG_1 = 0x1 | 1875 | BPF_REG_1 = 0x1 |
1876 | BPF_REG_2 = 0x2 | 1876 | BPF_REG_2 = 0x2 |
1877 | BPF_REG_3 = 0x3 | 1877 | BPF_REG_3 = 0x3 |
1878 | BPF_REG_4 = 0x4 | 1878 | BPF_REG_4 = 0x4 |
1879 | BPF_REG_5 = 0x5 | 1879 | BPF_REG_5 = 0x5 |
1880 | BPF_REG_6 = 0x6 | 1880 | BPF_REG_6 = 0x6 |
1881 | BPF_REG_7 = 0x7 | 1881 | BPF_REG_7 = 0x7 |
1882 | BPF_REG_8 = 0x8 | 1882 | BPF_REG_8 = 0x8 |
1883 | BPF_REG_9 = 0x9 | 1883 | BPF_REG_9 = 0x9 |
1884 | BPF_REG_10 = 0xa | 1884 | BPF_REG_10 = 0xa |
1885 | BPF_MAP_CREATE = 0x0 | 1885 | BPF_MAP_CREATE = 0x0 |
1886 | BPF_MAP_LOOKUP_ELEM = 0x1 | 1886 | BPF_MAP_LOOKUP_ELEM = 0x1 |
1887 | BPF_MAP_UPDATE_ELEM = 0x2 | 1887 | BPF_MAP_UPDATE_ELEM = 0x2 |
1888 | BPF_MAP_DELETE_ELEM = 0x3 | 1888 | BPF_MAP_DELETE_ELEM = 0x3 |
1889 | BPF_MAP_GET_NEXT_KEY = 0x4 | 1889 | BPF_MAP_GET_NEXT_KEY = 0x4 |
1890 | BPF_PROG_LOAD = 0x5 | 1890 | BPF_PROG_LOAD = 0x5 |
1891 | BPF_OBJ_PIN = 0x6 | 1891 | BPF_OBJ_PIN = 0x6 |
1892 | BPF_OBJ_GET = 0x7 | 1892 | BPF_OBJ_GET = 0x7 |
1893 | BPF_PROG_ATTACH = 0x8 | 1893 | BPF_PROG_ATTACH = 0x8 |
1894 | BPF_PROG_DETACH = 0x9 | 1894 | BPF_PROG_DETACH = 0x9 |
1895 | BPF_PROG_TEST_RUN = 0xa | 1895 | BPF_PROG_TEST_RUN = 0xa |
1896 | BPF_PROG_GET_NEXT_ID = 0xb | 1896 | BPF_PROG_GET_NEXT_ID = 0xb |
1897 | BPF_MAP_GET_NEXT_ID = 0xc | 1897 | BPF_MAP_GET_NEXT_ID = 0xc |
1898 | BPF_PROG_GET_FD_BY_ID = 0xd | 1898 | BPF_PROG_GET_FD_BY_ID = 0xd |
1899 | BPF_MAP_GET_FD_BY_ID = 0xe | 1899 | BPF_MAP_GET_FD_BY_ID = 0xe |
1900 | BPF_OBJ_GET_INFO_BY_FD = 0xf | 1900 | BPF_OBJ_GET_INFO_BY_FD = 0xf |
1901 | BPF_PROG_QUERY = 0x10 | 1901 | BPF_PROG_QUERY = 0x10 |
1902 | BPF_RAW_TRACEPOINT_OPEN = 0x11 | 1902 | BPF_RAW_TRACEPOINT_OPEN = 0x11 |
1903 | BPF_BTF_LOAD = 0x12 | 1903 | BPF_BTF_LOAD = 0x12 |
1904 | BPF_BTF_GET_FD_BY_ID = 0x13 | 1904 | BPF_BTF_GET_FD_BY_ID = 0x13 |
1905 | BPF_TASK_FD_QUERY = 0x14 | 1905 | BPF_TASK_FD_QUERY = 0x14 |
1906 | BPF_MAP_LOOKUP_AND_DELETE_ELEM = 0x15 | 1906 | BPF_MAP_LOOKUP_AND_DELETE_ELEM = 0x15 |
1907 | BPF_MAP_FREEZE = 0x16 | 1907 | BPF_MAP_FREEZE = 0x16 |
1908 | BPF_BTF_GET_NEXT_ID = 0x17 | 1908 | BPF_BTF_GET_NEXT_ID = 0x17 |
1909 | BPF_MAP_TYPE_UNSPEC = 0x0 | 1909 | BPF_MAP_LOOKUP_BATCH = 0x18 |
1910 | BPF_MAP_TYPE_HASH = 0x1 | 1910 | BPF_MAP_LOOKUP_AND_DELETE_BATCH = 0x19 |
1911 | BPF_MAP_TYPE_ARRAY = 0x2 | 1911 | BPF_MAP_UPDATE_BATCH = 0x1a |
1912 | BPF_MAP_TYPE_PROG_ARRAY = 0x3 | 1912 | BPF_MAP_DELETE_BATCH = 0x1b |
1913 | BPF_MAP_TYPE_PERF_EVENT_ARRAY = 0x4 | 1913 | BPF_LINK_CREATE = 0x1c |
1914 | BPF_MAP_TYPE_PERCPU_HASH = 0x5 | 1914 | BPF_LINK_UPDATE = 0x1d |
1915 | BPF_MAP_TYPE_PERCPU_ARRAY = 0x6 | 1915 | BPF_MAP_TYPE_UNSPEC = 0x0 |
1916 | BPF_MAP_TYPE_STACK_TRACE = 0x7 | 1916 | BPF_MAP_TYPE_HASH = 0x1 |
1917 | BPF_MAP_TYPE_CGROUP_ARRAY = 0x8 | 1917 | BPF_MAP_TYPE_ARRAY = 0x2 |
1918 | BPF_MAP_TYPE_LRU_HASH = 0x9 | 1918 | BPF_MAP_TYPE_PROG_ARRAY = 0x3 |
1919 | BPF_MAP_TYPE_LRU_PERCPU_HASH = 0xa | 1919 | BPF_MAP_TYPE_PERF_EVENT_ARRAY = 0x4 |
1920 | BPF_MAP_TYPE_LPM_TRIE = 0xb | 1920 | BPF_MAP_TYPE_PERCPU_HASH = 0x5 |
1921 | BPF_MAP_TYPE_ARRAY_OF_MAPS = 0xc | 1921 | BPF_MAP_TYPE_PERCPU_ARRAY = 0x6 |
1922 | BPF_MAP_TYPE_HASH_OF_MAPS = 0xd | 1922 | BPF_MAP_TYPE_STACK_TRACE = 0x7 |
1923 | BPF_MAP_TYPE_DEVMAP = 0xe | 1923 | BPF_MAP_TYPE_CGROUP_ARRAY = 0x8 |
1924 | BPF_MAP_TYPE_SOCKMAP = 0xf | 1924 | BPF_MAP_TYPE_LRU_HASH = 0x9 |
1925 | BPF_MAP_TYPE_CPUMAP = 0x10 | 1925 | BPF_MAP_TYPE_LRU_PERCPU_HASH = 0xa |
1926 | BPF_MAP_TYPE_XSKMAP = 0x11 | 1926 | BPF_MAP_TYPE_LPM_TRIE = 0xb |
1927 | BPF_MAP_TYPE_SOCKHASH = 0x12 | 1927 | BPF_MAP_TYPE_ARRAY_OF_MAPS = 0xc |
1928 | BPF_MAP_TYPE_CGROUP_STORAGE = 0x13 | 1928 | BPF_MAP_TYPE_HASH_OF_MAPS = 0xd |
1929 | BPF_MAP_TYPE_REUSEPORT_SOCKARRAY = 0x14 | 1929 | BPF_MAP_TYPE_DEVMAP = 0xe |
1930 | BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE = 0x15 | 1930 | BPF_MAP_TYPE_SOCKMAP = 0xf |
1931 | BPF_MAP_TYPE_QUEUE = 0x16 | 1931 | BPF_MAP_TYPE_CPUMAP = 0x10 |
1932 | BPF_MAP_TYPE_STACK = 0x17 | 1932 | BPF_MAP_TYPE_XSKMAP = 0x11 |
1933 | BPF_MAP_TYPE_SK_STORAGE = 0x18 | 1933 | BPF_MAP_TYPE_SOCKHASH = 0x12 |
1934 | BPF_MAP_TYPE_DEVMAP_HASH = 0x19 | 1934 | BPF_MAP_TYPE_CGROUP_STORAGE = 0x13 |
1935 | BPF_PROG_TYPE_UNSPEC = 0x0 | 1935 | BPF_MAP_TYPE_REUSEPORT_SOCKARRAY = 0x14 |
1936 | BPF_PROG_TYPE_SOCKET_FILTER = 0x1 | 1936 | BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE = 0x15 |
1937 | BPF_PROG_TYPE_KPROBE = 0x2 | 1937 | BPF_MAP_TYPE_QUEUE = 0x16 |
1938 | BPF_PROG_TYPE_SCHED_CLS = 0x3 | 1938 | BPF_MAP_TYPE_STACK = 0x17 |
1939 | BPF_PROG_TYPE_SCHED_ACT = 0x4 | 1939 | BPF_MAP_TYPE_SK_STORAGE = 0x18 |
1940 | BPF_PROG_TYPE_TRACEPOINT = 0x5 | 1940 | BPF_MAP_TYPE_DEVMAP_HASH = 0x19 |
1941 | BPF_PROG_TYPE_XDP = 0x6 | 1941 | BPF_MAP_TYPE_STRUCT_OPS = 0x1a |
1942 | BPF_PROG_TYPE_PERF_EVENT = 0x7 | 1942 | BPF_PROG_TYPE_UNSPEC = 0x0 |
1943 | BPF_PROG_TYPE_CGROUP_SKB = 0x8 | 1943 | BPF_PROG_TYPE_SOCKET_FILTER = 0x1 |
1944 | BPF_PROG_TYPE_CGROUP_SOCK = 0x9 | 1944 | BPF_PROG_TYPE_KPROBE = 0x2 |
1945 | BPF_PROG_TYPE_LWT_IN = 0xa | 1945 | BPF_PROG_TYPE_SCHED_CLS = 0x3 |
1946 | BPF_PROG_TYPE_LWT_OUT = 0xb | 1946 | BPF_PROG_TYPE_SCHED_ACT = 0x4 |
1947 | BPF_PROG_TYPE_LWT_XMIT = 0xc | 1947 | BPF_PROG_TYPE_TRACEPOINT = 0x5 |
1948 | BPF_PROG_TYPE_SOCK_OPS = 0xd | 1948 | BPF_PROG_TYPE_XDP = 0x6 |
1949 | BPF_PROG_TYPE_SK_SKB = 0xe | 1949 | BPF_PROG_TYPE_PERF_EVENT = 0x7 |
1950 | BPF_PROG_TYPE_CGROUP_DEVICE = 0xf | 1950 | BPF_PROG_TYPE_CGROUP_SKB = 0x8 |
1951 | BPF_PROG_TYPE_SK_MSG = 0x10 | 1951 | BPF_PROG_TYPE_CGROUP_SOCK = 0x9 |
1952 | BPF_PROG_TYPE_RAW_TRACEPOINT = 0x11 | 1952 | BPF_PROG_TYPE_LWT_IN = 0xa |
1953 | BPF_PROG_TYPE_CGROUP_SOCK_ADDR = 0x12 | 1953 | BPF_PROG_TYPE_LWT_OUT = 0xb |
1954 | BPF_PROG_TYPE_LWT_SEG6LOCAL = 0x13 | 1954 | BPF_PROG_TYPE_LWT_XMIT = 0xc |
1955 | BPF_PROG_TYPE_LIRC_MODE2 = 0x14 | 1955 | BPF_PROG_TYPE_SOCK_OPS = 0xd |
1956 | BPF_PROG_TYPE_SK_REUSEPORT = 0x15 | 1956 | BPF_PROG_TYPE_SK_SKB = 0xe |
1957 | BPF_PROG_TYPE_FLOW_DISSECTOR = 0x16 | 1957 | BPF_PROG_TYPE_CGROUP_DEVICE = 0xf |
1958 | BPF_PROG_TYPE_CGROUP_SYSCTL = 0x17 | 1958 | BPF_PROG_TYPE_SK_MSG = 0x10 |
1959 | BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLE = 0x18 | 1959 | BPF_PROG_TYPE_RAW_TRACEPOINT = 0x11 |
1960 | BPF_PROG_TYPE_CGROUP_SOCKOPT = 0x19 | 1960 | BPF_PROG_TYPE_CGROUP_SOCK_ADDR = 0x12 |
1961 | BPF_PROG_TYPE_TRACING = 0x1a | 1961 | BPF_PROG_TYPE_LWT_SEG6LOCAL = 0x13 |
1962 | BPF_CGROUP_INET_INGRESS = 0x0 | 1962 | BPF_PROG_TYPE_LIRC_MODE2 = 0x14 |
1963 | BPF_CGROUP_INET_EGRESS = 0x1 | 1963 | BPF_PROG_TYPE_SK_REUSEPORT = 0x15 |
1964 | BPF_CGROUP_INET_SOCK_CREATE = 0x2 | 1964 | BPF_PROG_TYPE_FLOW_DISSECTOR = 0x16 |
1965 | BPF_CGROUP_SOCK_OPS = 0x3 | 1965 | BPF_PROG_TYPE_CGROUP_SYSCTL = 0x17 |
1966 | BPF_SK_SKB_STREAM_PARSER = 0x4 | 1966 | BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLE = 0x18 |
1967 | BPF_SK_SKB_STREAM_VERDICT = 0x5 | 1967 | BPF_PROG_TYPE_CGROUP_SOCKOPT = 0x19 |
1968 | BPF_CGROUP_DEVICE = 0x6 | 1968 | BPF_PROG_TYPE_TRACING = 0x1a |
1969 | BPF_SK_MSG_VERDICT = 0x7 | 1969 | BPF_PROG_TYPE_STRUCT_OPS = 0x1b |
1970 | BPF_CGROUP_INET4_BIND = 0x8 | 1970 | BPF_PROG_TYPE_EXT = 0x1c |
1971 | BPF_CGROUP_INET6_BIND = 0x9 | 1971 | BPF_PROG_TYPE_LSM = 0x1d |
1972 | BPF_CGROUP_INET4_CONNECT = 0xa | 1972 | BPF_CGROUP_INET_INGRESS = 0x0 |
1973 | BPF_CGROUP_INET6_CONNECT = 0xb | 1973 | BPF_CGROUP_INET_EGRESS = 0x1 |
1974 | BPF_CGROUP_INET4_POST_BIND = 0xc | 1974 | BPF_CGROUP_INET_SOCK_CREATE = 0x2 |
1975 | BPF_CGROUP_INET6_POST_BIND = 0xd | 1975 | BPF_CGROUP_SOCK_OPS = 0x3 |
1976 | BPF_CGROUP_UDP4_SENDMSG = 0xe | 1976 | BPF_SK_SKB_STREAM_PARSER = 0x4 |
1977 | BPF_CGROUP_UDP6_SENDMSG = 0xf | 1977 | BPF_SK_SKB_STREAM_VERDICT = 0x5 |
1978 | BPF_LIRC_MODE2 = 0x10 | 1978 | BPF_CGROUP_DEVICE = 0x6 |
1979 | BPF_FLOW_DISSECTOR = 0x11 | 1979 | BPF_SK_MSG_VERDICT = 0x7 |
1980 | BPF_CGROUP_SYSCTL = 0x12 | 1980 | BPF_CGROUP_INET4_BIND = 0x8 |
1981 | BPF_CGROUP_UDP4_RECVMSG = 0x13 | 1981 | BPF_CGROUP_INET6_BIND = 0x9 |
1982 | BPF_CGROUP_UDP6_RECVMSG = 0x14 | 1982 | BPF_CGROUP_INET4_CONNECT = 0xa |
1983 | BPF_CGROUP_GETSOCKOPT = 0x15 | 1983 | BPF_CGROUP_INET6_CONNECT = 0xb |
1984 | BPF_CGROUP_SETSOCKOPT = 0x16 | 1984 | BPF_CGROUP_INET4_POST_BIND = 0xc |
1985 | BPF_TRACE_RAW_TP = 0x17 | 1985 | BPF_CGROUP_INET6_POST_BIND = 0xd |
1986 | BPF_TRACE_FENTRY = 0x18 | 1986 | BPF_CGROUP_UDP4_SENDMSG = 0xe |
1987 | BPF_TRACE_FEXIT = 0x19 | 1987 | BPF_CGROUP_UDP6_SENDMSG = 0xf |
1988 | BPF_STACK_BUILD_ID_EMPTY = 0x0 | 1988 | BPF_LIRC_MODE2 = 0x10 |
1989 | BPF_STACK_BUILD_ID_VALID = 0x1 | 1989 | BPF_FLOW_DISSECTOR = 0x11 |
1990 | BPF_STACK_BUILD_ID_IP = 0x2 | 1990 | BPF_CGROUP_SYSCTL = 0x12 |
1991 | BPF_ADJ_ROOM_NET = 0x0 | 1991 | BPF_CGROUP_UDP4_RECVMSG = 0x13 |
1992 | BPF_ADJ_ROOM_MAC = 0x1 | 1992 | BPF_CGROUP_UDP6_RECVMSG = 0x14 |
1993 | BPF_HDR_START_MAC = 0x0 | 1993 | BPF_CGROUP_GETSOCKOPT = 0x15 |
1994 | BPF_HDR_START_NET = 0x1 | 1994 | BPF_CGROUP_SETSOCKOPT = 0x16 |
1995 | BPF_LWT_ENCAP_SEG6 = 0x0 | 1995 | BPF_TRACE_RAW_TP = 0x17 |
1996 | BPF_LWT_ENCAP_SEG6_INLINE = 0x1 | 1996 | BPF_TRACE_FENTRY = 0x18 |
1997 | BPF_LWT_ENCAP_IP = 0x2 | 1997 | BPF_TRACE_FEXIT = 0x19 |
1998 | BPF_OK = 0x0 | 1998 | BPF_MODIFY_RETURN = 0x1a |
1999 | BPF_DROP = 0x2 | 1999 | BPF_LSM_MAC = 0x1b |
2000 | BPF_REDIRECT = 0x7 | 2000 | BPF_ANY = 0x0 |
2001 | BPF_LWT_REROUTE = 0x80 | 2001 | BPF_NOEXIST = 0x1 |
2002 | BPF_SOCK_OPS_VOID = 0x0 | 2002 | BPF_EXIST = 0x2 |
2003 | BPF_SOCK_OPS_TIMEOUT_INIT = 0x1 | 2003 | BPF_F_LOCK = 0x4 |
2004 | BPF_SOCK_OPS_RWND_INIT = 0x2 | 2004 | BPF_F_NO_PREALLOC = 0x1 |
2005 | BPF_SOCK_OPS_TCP_CONNECT_CB = 0x3 | 2005 | BPF_F_NO_COMMON_LRU = 0x2 |
2006 | BPF_SOCK_OPS_ACTIVE_ESTABLISHED_CB = 0x4 | 2006 | BPF_F_NUMA_NODE = 0x4 |
2007 | BPF_SOCK_OPS_PASSIVE_ESTABLISHED_CB = 0x5 | 2007 | BPF_F_RDONLY = 0x8 |
2008 | BPF_SOCK_OPS_NEEDS_ECN = 0x6 | 2008 | BPF_F_WRONLY = 0x10 |
2009 | BPF_SOCK_OPS_BASE_RTT = 0x7 | 2009 | BPF_F_STACK_BUILD_ID = 0x20 |
2010 | BPF_SOCK_OPS_RTO_CB = 0x8 | 2010 | BPF_F_ZERO_SEED = 0x40 |
2011 | BPF_SOCK_OPS_RETRANS_CB = 0x9 | 2011 | BPF_F_RDONLY_PROG = 0x80 |
2012 | BPF_SOCK_OPS_STATE_CB = 0xa | 2012 | BPF_F_WRONLY_PROG = 0x100 |
2013 | BPF_SOCK_OPS_TCP_LISTEN_CB = 0xb | 2013 | BPF_F_CLONE = 0x200 |
2014 | BPF_SOCK_OPS_RTT_CB = 0xc | 2014 | BPF_F_MMAPABLE = 0x400 |
2015 | BPF_TCP_ESTABLISHED = 0x1 | 2015 | BPF_STACK_BUILD_ID_EMPTY = 0x0 |
2016 | BPF_TCP_SYN_SENT = 0x2 | 2016 | BPF_STACK_BUILD_ID_VALID = 0x1 |
2017 | BPF_TCP_SYN_RECV = 0x3 | 2017 | BPF_STACK_BUILD_ID_IP = 0x2 |
2018 | BPF_TCP_FIN_WAIT1 = 0x4 | 2018 | BPF_F_RECOMPUTE_CSUM = 0x1 |
2019 | BPF_TCP_FIN_WAIT2 = 0x5 | 2019 | BPF_F_INVALIDATE_HASH = 0x2 |
2020 | BPF_TCP_TIME_WAIT = 0x6 | 2020 | BPF_F_HDR_FIELD_MASK = 0xf |
2021 | BPF_TCP_CLOSE = 0x7 | 2021 | BPF_F_PSEUDO_HDR = 0x10 |
2022 | BPF_TCP_CLOSE_WAIT = 0x8 | 2022 | BPF_F_MARK_MANGLED_0 = 0x20 |
2023 | BPF_TCP_LAST_ACK = 0x9 | 2023 | BPF_F_MARK_ENFORCE = 0x40 |
2024 | BPF_TCP_LISTEN = 0xa | 2024 | BPF_F_INGRESS = 0x1 |
2025 | BPF_TCP_CLOSING = 0xb | 2025 | BPF_F_TUNINFO_IPV6 = 0x1 |
2026 | BPF_TCP_NEW_SYN_RECV = 0xc | 2026 | BPF_F_SKIP_FIELD_MASK = 0xff |
2027 | BPF_TCP_MAX_STATES = 0xd | 2027 | BPF_F_USER_STACK = 0x100 |
2028 | BPF_FIB_LKUP_RET_SUCCESS = 0x0 | 2028 | BPF_F_FAST_STACK_CMP = 0x200 |
2029 | BPF_FIB_LKUP_RET_BLACKHOLE = 0x1 | 2029 | BPF_F_REUSE_STACKID = 0x400 |
2030 | BPF_FIB_LKUP_RET_UNREACHABLE = 0x2 | 2030 | BPF_F_USER_BUILD_ID = 0x800 |
2031 | BPF_FIB_LKUP_RET_PROHIBIT = 0x3 | 2031 | BPF_F_ZERO_CSUM_TX = 0x2 |
2032 | BPF_FIB_LKUP_RET_NOT_FWDED = 0x4 | 2032 | BPF_F_DONT_FRAGMENT = 0x4 |
2033 | BPF_FIB_LKUP_RET_FWD_DISABLED = 0x5 | 2033 | BPF_F_SEQ_NUMBER = 0x8 |
2034 | BPF_FIB_LKUP_RET_UNSUPP_LWT = 0x6 | 2034 | BPF_F_INDEX_MASK = 0xffffffff |
2035 | BPF_FIB_LKUP_RET_NO_NEIGH = 0x7 | 2035 | BPF_F_CURRENT_CPU = 0xffffffff |
2036 | BPF_FIB_LKUP_RET_FRAG_NEEDED = 0x8 | 2036 | BPF_F_CTXLEN_MASK = 0xfffff00000000 |
2037 | BPF_FD_TYPE_RAW_TRACEPOINT = 0x0 | 2037 | BPF_F_CURRENT_NETNS = -0x1 |
2038 | BPF_FD_TYPE_TRACEPOINT = 0x1 | 2038 | BPF_F_ADJ_ROOM_FIXED_GSO = 0x1 |
2039 | BPF_FD_TYPE_KPROBE = 0x2 | 2039 | BPF_F_ADJ_ROOM_ENCAP_L3_IPV4 = 0x2 |
2040 | BPF_FD_TYPE_KRETPROBE = 0x3 | 2040 | BPF_F_ADJ_ROOM_ENCAP_L3_IPV6 = 0x4 |
2041 | BPF_FD_TYPE_UPROBE = 0x4 | 2041 | BPF_F_ADJ_ROOM_ENCAP_L4_GRE = 0x8 |
2042 | BPF_FD_TYPE_URETPROBE = 0x5 | 2042 | BPF_F_ADJ_ROOM_ENCAP_L4_UDP = 0x10 |
2043 | BPF_ADJ_ROOM_ENCAP_L2_MASK = 0xff | ||
2044 | BPF_ADJ_ROOM_ENCAP_L2_SHIFT = 0x38 | ||
2045 | BPF_F_SYSCTL_BASE_NAME = 0x1 | ||
2046 | BPF_SK_STORAGE_GET_F_CREATE = 0x1 | ||
2047 | BPF_F_GET_BRANCH_RECORDS_SIZE = 0x1 | ||
2048 | BPF_ADJ_ROOM_NET = 0x0 | ||
2049 | BPF_ADJ_ROOM_MAC = 0x1 | ||
2050 | BPF_HDR_START_MAC = 0x0 | ||
2051 | BPF_HDR_START_NET = 0x1 | ||
2052 | BPF_LWT_ENCAP_SEG6 = 0x0 | ||
2053 | BPF_LWT_ENCAP_SEG6_INLINE = 0x1 | ||
2054 | BPF_LWT_ENCAP_IP = 0x2 | ||
2055 | BPF_OK = 0x0 | ||
2056 | BPF_DROP = 0x2 | ||
2057 | BPF_REDIRECT = 0x7 | ||
2058 | BPF_LWT_REROUTE = 0x80 | ||
2059 | BPF_SOCK_OPS_RTO_CB_FLAG = 0x1 | ||
2060 | BPF_SOCK_OPS_RETRANS_CB_FLAG = 0x2 | ||
2061 | BPF_SOCK_OPS_STATE_CB_FLAG = 0x4 | ||
2062 | BPF_SOCK_OPS_RTT_CB_FLAG = 0x8 | ||
2063 | BPF_SOCK_OPS_ALL_CB_FLAGS = 0xf | ||
2064 | BPF_SOCK_OPS_VOID = 0x0 | ||
2065 | BPF_SOCK_OPS_TIMEOUT_INIT = 0x1 | ||
2066 | BPF_SOCK_OPS_RWND_INIT = 0x2 | ||
2067 | BPF_SOCK_OPS_TCP_CONNECT_CB = 0x3 | ||
2068 | BPF_SOCK_OPS_ACTIVE_ESTABLISHED_CB = 0x4 | ||
2069 | BPF_SOCK_OPS_PASSIVE_ESTABLISHED_CB = 0x5 | ||
2070 | BPF_SOCK_OPS_NEEDS_ECN = 0x6 | ||
2071 | BPF_SOCK_OPS_BASE_RTT = 0x7 | ||
2072 | BPF_SOCK_OPS_RTO_CB = 0x8 | ||
2073 | BPF_SOCK_OPS_RETRANS_CB = 0x9 | ||
2074 | BPF_SOCK_OPS_STATE_CB = 0xa | ||
2075 | BPF_SOCK_OPS_TCP_LISTEN_CB = 0xb | ||
2076 | BPF_SOCK_OPS_RTT_CB = 0xc | ||
2077 | BPF_TCP_ESTABLISHED = 0x1 | ||
2078 | BPF_TCP_SYN_SENT = 0x2 | ||
2079 | BPF_TCP_SYN_RECV = 0x3 | ||
2080 | BPF_TCP_FIN_WAIT1 = 0x4 | ||
2081 | BPF_TCP_FIN_WAIT2 = 0x5 | ||
2082 | BPF_TCP_TIME_WAIT = 0x6 | ||
2083 | BPF_TCP_CLOSE = 0x7 | ||
2084 | BPF_TCP_CLOSE_WAIT = 0x8 | ||
2085 | BPF_TCP_LAST_ACK = 0x9 | ||
2086 | BPF_TCP_LISTEN = 0xa | ||
2087 | BPF_TCP_CLOSING = 0xb | ||
2088 | BPF_TCP_NEW_SYN_RECV = 0xc | ||
2089 | BPF_TCP_MAX_STATES = 0xd | ||
2090 | TCP_BPF_IW = 0x3e9 | ||
2091 | TCP_BPF_SNDCWND_CLAMP = 0x3ea | ||
2092 | BPF_DEVCG_ACC_MKNOD = 0x1 | ||
2093 | BPF_DEVCG_ACC_READ = 0x2 | ||
2094 | BPF_DEVCG_ACC_WRITE = 0x4 | ||
2095 | BPF_DEVCG_DEV_BLOCK = 0x1 | ||
2096 | BPF_DEVCG_DEV_CHAR = 0x2 | ||
2097 | BPF_FIB_LOOKUP_DIRECT = 0x1 | ||
2098 | BPF_FIB_LOOKUP_OUTPUT = 0x2 | ||
2099 | BPF_FIB_LKUP_RET_SUCCESS = 0x0 | ||
2100 | BPF_FIB_LKUP_RET_BLACKHOLE = 0x1 | ||
2101 | BPF_FIB_LKUP_RET_UNREACHABLE = 0x2 | ||
2102 | BPF_FIB_LKUP_RET_PROHIBIT = 0x3 | ||
2103 | BPF_FIB_LKUP_RET_NOT_FWDED = 0x4 | ||
2104 | BPF_FIB_LKUP_RET_FWD_DISABLED = 0x5 | ||
2105 | BPF_FIB_LKUP_RET_UNSUPP_LWT = 0x6 | ||
2106 | BPF_FIB_LKUP_RET_NO_NEIGH = 0x7 | ||
2107 | BPF_FIB_LKUP_RET_FRAG_NEEDED = 0x8 | ||
2108 | BPF_FD_TYPE_RAW_TRACEPOINT = 0x0 | ||
2109 | BPF_FD_TYPE_TRACEPOINT = 0x1 | ||
2110 | BPF_FD_TYPE_KPROBE = 0x2 | ||
2111 | BPF_FD_TYPE_KRETPROBE = 0x3 | ||
2112 | BPF_FD_TYPE_UPROBE = 0x4 | ||
2113 | BPF_FD_TYPE_URETPROBE = 0x5 | ||
2114 | BPF_FLOW_DISSECTOR_F_PARSE_1ST_FRAG = 0x1 | ||
2115 | BPF_FLOW_DISSECTOR_F_STOP_AT_FLOW_LABEL = 0x2 | ||
2116 | BPF_FLOW_DISSECTOR_F_STOP_AT_ENCAP = 0x4 | ||
2043 | ) | 2117 | ) |
2044 | 2118 | ||
2045 | const ( | 2119 | const ( |
@@ -2205,7 +2279,7 @@ const ( | |||
2205 | DEVLINK_CMD_DPIPE_ENTRIES_GET = 0x20 | 2279 | DEVLINK_CMD_DPIPE_ENTRIES_GET = 0x20 |
2206 | DEVLINK_CMD_DPIPE_HEADERS_GET = 0x21 | 2280 | DEVLINK_CMD_DPIPE_HEADERS_GET = 0x21 |
2207 | DEVLINK_CMD_DPIPE_TABLE_COUNTERS_SET = 0x22 | 2281 | DEVLINK_CMD_DPIPE_TABLE_COUNTERS_SET = 0x22 |
2208 | DEVLINK_CMD_MAX = 0x44 | 2282 | DEVLINK_CMD_MAX = 0x48 |
2209 | DEVLINK_PORT_TYPE_NOTSET = 0x0 | 2283 | DEVLINK_PORT_TYPE_NOTSET = 0x0 |
2210 | DEVLINK_PORT_TYPE_AUTO = 0x1 | 2284 | DEVLINK_PORT_TYPE_AUTO = 0x1 |
2211 | DEVLINK_PORT_TYPE_ETH = 0x2 | 2285 | DEVLINK_PORT_TYPE_ETH = 0x2 |
@@ -2285,7 +2359,7 @@ const ( | |||
2285 | DEVLINK_ATTR_DPIPE_FIELD_MAPPING_TYPE = 0x3c | 2359 | DEVLINK_ATTR_DPIPE_FIELD_MAPPING_TYPE = 0x3c |
2286 | DEVLINK_ATTR_PAD = 0x3d | 2360 | DEVLINK_ATTR_PAD = 0x3d |
2287 | DEVLINK_ATTR_ESWITCH_ENCAP_MODE = 0x3e | 2361 | DEVLINK_ATTR_ESWITCH_ENCAP_MODE = 0x3e |
2288 | DEVLINK_ATTR_MAX = 0x8c | 2362 | DEVLINK_ATTR_MAX = 0x90 |
2289 | DEVLINK_DPIPE_FIELD_MAPPING_TYPE_NONE = 0x0 | 2363 | DEVLINK_DPIPE_FIELD_MAPPING_TYPE_NONE = 0x0 |
2290 | DEVLINK_DPIPE_FIELD_MAPPING_TYPE_IFINDEX = 0x1 | 2364 | DEVLINK_DPIPE_FIELD_MAPPING_TYPE_IFINDEX = 0x1 |
2291 | DEVLINK_DPIPE_MATCH_TYPE_FIELD_EXACT = 0x0 | 2365 | DEVLINK_DPIPE_MATCH_TYPE_FIELD_EXACT = 0x0 |
diff --git a/vendor/modules.txt b/vendor/modules.txt index 50c44d6..7d451f0 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt | |||
@@ -81,7 +81,7 @@ github.com/prometheus/common/model | |||
81 | github.com/prometheus/common/promlog | 81 | github.com/prometheus/common/promlog |
82 | github.com/prometheus/common/promlog/flag | 82 | github.com/prometheus/common/promlog/flag |
83 | github.com/prometheus/common/version | 83 | github.com/prometheus/common/version |
84 | # github.com/prometheus/procfs v0.0.11 | 84 | # github.com/prometheus/procfs v0.1.3 |
85 | ## explicit | 85 | ## explicit |
86 | github.com/prometheus/procfs | 86 | github.com/prometheus/procfs |
87 | github.com/prometheus/procfs/bcache | 87 | github.com/prometheus/procfs/bcache |
@@ -123,7 +123,7 @@ golang.org/x/net/trace | |||
123 | # golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a | 123 | # golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a |
124 | ## explicit | 124 | ## explicit |
125 | golang.org/x/sync/errgroup | 125 | golang.org/x/sync/errgroup |
126 | # golang.org/x/sys v0.0.0-20200523222454-059865788121 | 126 | # golang.org/x/sys v0.0.0-20200602225109-6fdc65e7d980 |
127 | ## explicit | 127 | ## explicit |
128 | golang.org/x/sys/internal/unsafeheader | 128 | golang.org/x/sys/internal/unsafeheader |
129 | golang.org/x/sys/unix | 129 | golang.org/x/sys/unix |