aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/golang.org/x/sys/unix/dev_aix_ppc.go
diff options
context:
space:
mode:
authorTyler Davis <tydavis@gmail.com>2021-02-15 20:47:30 +0000
committerTyler Davis <tydavis@gmail.com>2021-02-15 20:47:30 +0000
commita687ebabb6589ebb36a9c385f583a19ac462b831 (patch)
tree4112f2272dfe6df7f106819c1381ab59d7ea5d2f /vendor/golang.org/x/sys/unix/dev_aix_ppc.go
parentf22b6da3c7964a23d93269b6c5de9f322c3837a8 (diff)
downloaddnstracker-a687ebabb6589ebb36a9c385f583a19ac462b831.tar.gz
dnstracker-a687ebabb6589ebb36a9c385f583a19ac462b831.zip
Update go modules for 1.15
Diffstat (limited to 'vendor/golang.org/x/sys/unix/dev_aix_ppc.go')
-rw-r--r--vendor/golang.org/x/sys/unix/dev_aix_ppc.go27
1 files changed, 27 insertions, 0 deletions
diff --git a/vendor/golang.org/x/sys/unix/dev_aix_ppc.go b/vendor/golang.org/x/sys/unix/dev_aix_ppc.go
new file mode 100644
index 0000000..5e5fb45
--- /dev/null
+++ b/vendor/golang.org/x/sys/unix/dev_aix_ppc.go
@@ -0,0 +1,27 @@
+// Copyright 2018 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build aix
+// +build ppc
+
+// Functions to access/create device major and minor numbers matching the
+// encoding used by AIX.
+
+package unix
+
+// Major returns the major component of a Linux device number.
+func Major(dev uint64) uint32 {
+ return uint32((dev >> 16) & 0xffff)
+}
+
+// Minor returns the minor component of a Linux device number.
+func Minor(dev uint64) uint32 {
+ return uint32(dev & 0xffff)
+}
+
+// Mkdev returns a Linux device number generated from the given major and minor
+// components.
+func Mkdev(major, minor uint32) uint64 {
+ return uint64(((major) << 16) | (minor))
+}