Tested with TestPoll extracted from syscall_linux_test.go. Once Poll is
supported on all OSes this test can be moved to syscall_unix_test.go.
Change-Id: I61ec50c5ea7d6db43f7688ed925d6ed26a6bbc3a
Reviewed-on: https://go-review.googlesource.com/73650
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
For pairs of GOARCH values that can execute each other's binaries on
the same system, such as 386 and amd64, add the definitions and
functions required to fetch and set registers when debugging either
variant.
Fixesgolang/go#9739
Change-Id: I7896ddef7d341ffaee56614ebd080dc38c708ed4
Reviewed-on: https://go-review.googlesource.com/73555
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Follow CL 20022 and consistently use single space after a period in
documentation.
Generated with:
$ perl -i -npe 's,^(\s*// .+[a-z]\.) +([A-Z]),$1 $2,' $(git grep -l -E '^\s*//(.+\.) +([A-Z])')
Change-Id: Ia29ad823668f060e81293e848a79fc4b4857d94b
Reviewed-on: https://go-review.googlesource.com/73530
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Tested with TestPoll extracted from syscall_linux_test.go. Once Poll is
supported on all OSes this test can be moved to syscall_unix_test.go.
Change-Id: I03f4396be2e190770abb219c1c5324ca55bcfa27
Reviewed-on: https://go-review.googlesource.com/73430
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Tested with TestPoll extracted from syscall_linux_test.go. Once Poll is
supported on all OSes this test can be moved to syscall_unix_test.go.
Change-Id: I56ee0124a04c64e3ea51a1653901f2f4277983e6
Reviewed-on: https://go-review.googlesource.com/73370
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Tested with TestPoll extracted from syscall_linux_test.go. Once Poll is
supported on all OSes this test can be moved to syscall_unix_test.go.
Change-Id: Ia57e3a92e6a50cb22edde8a31e1c4e70d894dc4c
Reviewed-on: https://go-review.googlesource.com/73310
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
All the implementations of NsecToTimespec and NsecToTimeval were the
same other than types. Write a single version that uses
GOARCH/GOOS-specific setTimespec and setTimeval functions to handle the
types.
The logic in NsecToTimespec and NsecToTimeval caused times before 1970
to have a negative usec/nsec. The Linux kernel requires that usec
contain a positive number; for consistency, we do this for both
NsecToTimespec and NsecToTimeval.
Follow CL 30826 which did the same for syscall.
Change-Id: Id6c6f4fef8450251447d1a5b01f35c2a36b5aeb1
Reviewed-on: https://go-review.googlesource.com/73170
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Add a test for UtimesNanoAt which makes sure the timestamp of a symlink
is updated.
Change-Id: I819e43db1d390fb37f011b34e58ff9d3d06595f1
Reviewed-on: https://go-review.googlesource.com/72377
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
All implementations of these functions are identical.
Follow CL 30819 which did the same for syscall.
Change-Id: I3c78f05ea12251306f3e100a006d266154a5238e
Reviewed-on: https://go-review.googlesource.com/72378
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
To be used e.g. in
2e60d5b8c8
Change-Id: If79ffec9021dc79375c861a0ddd9dd443adb4692
Reviewed-on: https://go-review.googlesource.com/72375
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
They might be used as special values in struct Timespec. See
http://man7.org/linux/man-pages/man2/utimensat.2.html for details.
Change-Id: I1c2d6d7731ca7f077d033e51ee6421a4f2cfbb89
Reviewed-on: https://go-review.googlesource.com/72376
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Follow CL 70590 which did the same for syscall.
unix.Select uses SYS_PSELECT6 on arm64 and mipx64x, however this
syscall expects its 5th argument to be of type Timespec (with seconds
and nanoseconds) instead of type Timeval (with seconds and microseconds)
This leads to the timeout being too short by a factor of 1000.
This CL fixes this by adjusting the timeout argument accordingly,
similarly to how glibc does it for architectures where neither
SYS_SELECT nor SYS__NEWSELECT are available. It also makes Pselect
generaly available on linux.
Updates golang/go#22246
Change-Id: I69f8821a40c59ee469b8a986d784a4db8727ee9a
Reviewed-on: https://go-review.googlesource.com/70610
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Add the MNT_* flags to be used e.g. with Getfsstat on FreeBSD.
Change-Id: I1afb50f715f447f85b4ece3d3fead8b9ce79c4f6
Reviewed-on: https://go-review.googlesource.com/70250
Reviewed-by: Matt Layher <mdlayher@gmail.com>
Run-TryBot: Matt Layher <mdlayher@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Since CL 10087 build tags for GOOS and GOARCH are emitted by
mksysctl_openbsd.go but the generated file is always written to
zsysctl_openbsd.go.
Adjust mkall.sh to write to GOOS/GOARCH specific files and create a
zsysctl_openbsd_${GOARCH}.go file for each GOARCH supported on openbsd.
Change-Id: Id2a7b2815081f024de0ca87ba870a672bab32d24
Reviewed-on: https://go-review.googlesource.com/68870
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Analog to the runtime package, Select should be using newselect
instead of select. This change addresses this problem and regenerates
zsyscall_linux_* for ppc64 and ppc64le.
Updates golang/go#21946
Change-Id: I7ed5c2490ba2ce556f143f8e8377572ab345f7b8
Reviewed-on: https://go-review.googlesource.com/65091
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Lynn Boger <laboger@linux.vnet.ibm.com>
When adding Mprotect to TestMmap in CL 56172, PROT_WRITE was implicitly
assumed to also include PROT_READ. This is not necessarily true on all
OSes and makes TestMmap crash on openbsd/386.
As suggested my Mikio Hara fix it by also setting PROT_READ on the
memory mapping.
Fixesgolang/go#21962
Change-Id: Ia789ab8b31f8dec0c3db23cc950ccdd4aab3db05
Reviewed-on: https://go-review.googlesource.com/65230
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
CL 62111 removed the _SC_PAGESIZE definition from the types_*.go files
but did not re-generate ztypes_solaris_amd64.go. Do so now to get rid of
_SC_PAGESIZE there as well.
Change-Id: Icde4366f4b7a92e8a89170ad00ff2b807e7655e1
Reviewed-on: https://go-review.googlesource.com/64350
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Add Major, Minor and Mkdev functions for converting device numbers to
their major/minor components and vice versa.
Use the respective functions provided by the Solaris libc instead of
reimplementing them.
Test the conversion function with some well-known static device numbers
for devices which should be present on any Solaris system.
Re-generated files on OpenIndiana Hipster 2017.04 (SunOS 5.11) which
also added some previously missing error constants.
Change-Id: Ief9ea973d91c24956571eb8fafc8a4525b0f5b90
Reviewed-on: https://go-review.googlesource.com/64390
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Add the Msync function on solaris/amd64.
Change-Id: Idde0f9e693f924fef471acb42afb84e83c4cee76
Reviewed-on: https://go-review.googlesource.com/64370
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Add Major, Minor and Mkdev functions for converting devices numbers to
their major/minor components and vice versa.
The functions follow the behavior of the macros defined in OpenBSD's
sys/types.h header. However, the parameter and return types are changed
to match the existing implementations of these functions.
Test the conversion macros with some well-known device numbers.
Updates golang/go#8106
Change-Id: Ia50b7ccab18ff7c7e9dd77ddc7e4aa6cf5c79963
Reviewed-on: https://go-review.googlesource.com/63070
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Follow CL 63090 and change the Makedev function on Darwin and *BSD to
convert to uint64 before shifting/masking. This avoids a potential
overflow.
Change-Id: I5b566329695cc5edcf82f0ff2366033011b0625b
Reviewed-on: https://go-review.googlesource.com/63112
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Daniel Swarbrick reports the following go vet warning after CL 50550:
.../dev_linux.go:38: (major & 0xfffff000) (32 bits) too small for shift of 32
Fix it by converting major and minor to uint64 before the bitwise-and.
Change-Id: If37540be81f2c78a58fd5e5dcce7b770ce7b8afe
Reviewed-on: https://go-review.googlesource.com/63090
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Add Major, Minor and Mkdev functions for converting devices numbers to
their major/minor components and vice versa.
The functions follow the behavior of the macros defined in FreeBSD's
sys/types.h header. However, the parameter and return types are changed
to match the existing implementations of these functions.
Because FreeBSD dynamically allocates major/minor device numbers through
devfs at runtime, testing the conversion macros against well-known
device numbers is not possible.
Updates golang/go#8106
Change-Id: I9874e63f388cfc5c0d5cc47d4d0f6ccc489b28f2
Reviewed-on: https://go-review.googlesource.com/61631
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Add Major, Minor and Mkdev functions for converting devices numbers to
their major/minor components and vice versa.
The functions follow the behavior of the macros defined in DragonFlyBSD's
sys/types.h header. However, the parameter and return types are changed
to match the existing implementations of these functions.
Test the conversion macros with some well-known device numbers.
Updates golang/go#8106
Change-Id: I84c128dff3108821caaa75dcec620cf5bdb1f32d
Reviewed-on: https://go-review.googlesource.com/61630
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This change updates the Linux symbols to correspond to v4.13 of the
kernel and v2.26 of glibc. To get everything building correctly, newer
versions of the build tools are required. Instead of trying to get an
Ubuntu 17.10 docker image working, we just add Artful sources to
/etc/apt/sources.list to get a similar effect.
Now that the kernel UAPI is updated, FS_MAX_KEY_SIZE and fscrypt_key no
longer need to be manually declared, as they are now in the proper
kernel headers.
Change-Id: I5f14c99fd70b43dbb8b44e05f53e4e9f09c9a345
Reviewed-on: https://go-review.googlesource.com/61771
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Change https://go-review.googlesource.com/c/sys/+/56172 did not run
./mkall.sh after modifying syscall_linux.go. This change simply runs
./mkall.sh to correctly generate the modified files.
Note that the previous change simply reordered a few functions, so the
functions are simply reordered in the generated files.
Change-Id: I2d819f9ca4ae0e59e67e42d04bb6e6513b3c6c45
Reviewed-on: https://go-review.googlesource.com/61750
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Add Major, Minor and Mkdev functions for converting devices numbers to
their major/minor components and vice versa.
The functions follow the behavior of the macros defined in NetBSD's
sys/types.h header. However, the parameter and return types are changed
to match the existing implementations of these functions.
Test the conversion macros with some well-known device numbers.
Updates golang/go#8106
Change-Id: I536d6d2622f6fe9be3c1ed3beb266745fe4bfb6e
Reviewed-on: https://go-review.googlesource.com/60970
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Add Major, Minor and Mkdev functions for converting devices numbers to
their major/minor components and vice versa.
The functions follow the behavior of the macros defined in Darwin's
sys/types.h header. However, the parameter and return types are changed
to match the respective Linux implementation of these functions.
Test the conversion macros with some well-known static device numbers
for devices which should be present on any Darwin system.
Updates golang/go#8106
Change-Id: I1862be64684cc1b5a53e15a883819571e368cb2b
Reviewed-on: https://go-review.googlesource.com/60610
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit relaxes SendmsgN behavior of introducing a dummy 1-byte
payload when sending ancillary-only messages.
The fake payload is not needed for SOCK_DGRAM type sockets, and actually
breaks interoperability with other fd-passing software (journald is one
known example). This introduces an additional check to avoid injecting
dummy payload in such case.
Backport of https://go.googlesource.com/go/+/93da0b6e66f24c4c307e0df37ceb102a33306174
Full reference at https:/golang.org/issue/6476#issue-51285243
Change-Id: I7cf00a1c7cde75fe62e00b98ccba6ac8469b0493
Reviewed-on: https://go-review.googlesource.com/60190
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Generic netlink is a generalized netlink family which enables a series
of different communication channels to be multiplexed on a single
netlink family.
For more information, please see: https://lwn.net/Articles/208755/.
Fixesgolang/go#21682.
Change-Id: I2095150e06471f4a0e1322fba669573aa8f0a9b1
Reviewed-on: https://go-review.googlesource.com/59931
Run-TryBot: Matt Layher <mdlayher@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
I falsely assumed that enum values would be generated automatically,
but now realize that the previous values I added were actually generated
from preprocessor define statements.
This change adds some missing values I intended to add in CL 59050.
Fixesgolang/go#21623.
Change-Id: I3c40c8454ee1d323e1e4e014febe0874e859a378
Reviewed-on: https://go-review.googlesource.com/59090
Run-TryBot: Matt Layher <mdlayher@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Taskstats is a netlink-based interface for sending per-task and
per-process statistics from the kernel to userspace.
For more information, please see:
https://www.kernel.org/doc/Documentation/accounting/taskstats.txt.
Fixesgolang/go#21616.
Change-Id: I7d4b8035aa8e993074d61911d9a8c3a3e61c9b2e
Reviewed-on: https://go-review.googlesource.com/59050
Run-TryBot: Matt Layher <mdlayher@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Make Madvice, Mlock, Mlockall, Mprotect, Msync, Munlock and Munlockall
available equally on all BSD flavors. NetBSD was previously lacking
SYS_MSYNC, so add it.
Reorder the //sys function prototype alphabetically and clean up already
implemented syscalls everywhere.
Also add tests for Mprotect, Msync and Madvice - now that they're
available on all unix platforms.
Fixesgolang/go#18513
Change-Id: I0eb502d72c7e991f191fb96225ef04e8297d8b8d
Reviewed-on: https://go-review.googlesource.com/56172
Run-TryBot: Daniel Martí <mvdan@mvdan.cc>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Daniel Martí <mvdan@mvdan.cc>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Follow CL golang.org/cl/55690 (which did the same for syscall) and fix
the definition of AT_FDCWD on dragonfly/amd64.
Change-Id: I2c44a0f84308697d3dbac9b78c4a3dce973f88ba
Reviewed-on: https://go-review.googlesource.com/55691
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Follow golang.org/cl/55130 and add the utimensat syscall on *BSD. Use it
in UtimesNano and UtimesNanoAt (which is added on *BSD, akin to the
already existing implementation on Linux and Solaris).
Also add AT_FDCWD and AT_SYMLINK_NOFOLLOW where they are missing. These
might be used with UtimesNanoAt.
In order to be able to generate the syscalls, also add two missing
$GOOS_$GOARCH patterns to mkall.sh. As a side effect, some additional
syscalls are added for openbsd/arm.
Change-Id: I85351098002209f8454ec328cef0cfe9d12c5214
Reviewed-on: https://go-review.googlesource.com/55071
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Fixes: golang/go#21410
Change-Id: Ie1971f7d6e0cfe405603e94c538a15dd5f467392
Reviewed-on: https://go-review.googlesource.com/55230
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Fixesgolang/go#21375
Change-Id: Ibb33df9d71eb3a935a1f8f9f0ad1f180211e8ce4
Reviewed-on: https://go-review.googlesource.com/54390
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Follow golang.org/cl/50450 and add the Faccessat, Fchmodat, Fchownat,
Linkat, Mkdirat, Openat, Readlinkat, Renameat, Symlinkat and Unlinkat
functions (to conform to POSIX.1-2008) for darwin/arm and darwin/amd64.
Also add the missing AT_* constants.
Generated on Mac OS 10.11 (Darwin 15.6.0). This also regenerates the
syscall numbers for arm and arm64 akin to golang.org/cl/14151
Also fix the mksysnum call in mkall.sh to work for darwin/arm.
Fixesgolang/go#14457
Change-Id: Ia3c36dbca9e6f1e4873afdfafcc4f7d8050644f9
Reviewed-on: https://go-review.googlesource.com/54271
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Add the MNT_* constants used for the Mount and Umount functions on
Darwin.
Generated on Mac OS 10.11 (Darwin 15.6.0). This also brings
zerrors_darwin_{arm,arm64} up to date with constants which are already
present for 386 and amd64.
Fixesgolang/go#9891
Change-Id: Id77847a2fb805a759aa0f5b36e8954b764e699a5
Reviewed-on: https://go-review.googlesource.com/54210
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This copies over some files from the main repo to make the
GOOS=openbsd GOARCH=arm go install and go test -c work.
No clue whether it actually works or not, though. We don't have
builders anymore for this port.
But once this compiles, we'll at least be able to use constants from
the x/sys/unix package from x/net without regressing x/net's support
for openbsd/arm. (If anybody uses openbsd/arm)
Fixesgolang/go#10826
Change-Id: Id821e2011bcd2d3720652be44ac09e4ce4d2a3a3
Reviewed-on: https://go-review.googlesource.com/54053
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Rob Pike <r@golang.org>
Reviewed-by: Joel Sing <joel@sing.id.au>
Re-run mkall.sh on FreeBSD-11.1-RELEASE armv6 for Capsicum consts and
POSIX.1-2008 path relative *at() syscalls.
Add errors_freebsd_arm.go generated semi-automatically using:
https://gist.github.com/paulzhol/c6d54dc2baf2a6bd204b343a15459661
Similar to https://golang.org/cl/51570. In order to handle C enum based
constants that mkerrors.sh missed.
Use fix from https://golang.org/cl/53639 to run Capsicum tests only on amd64.
Fixesgolang/go#21136
Change-Id: I9681b033531090e6b1c5e2446a442deb39cf3066
Reviewed-on: https://go-review.googlesource.com/53691
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Add IoctlGetInt/IoctlSetInt, IoctlGetTermios/IoctlSetTermios and
IoctlGetWinsize/IoctlSetWinsize on FreeBSD. These are similar to the
already existing implementations on Linux, Darwin and Solaris.
Generated on FreeBSD 10.11-RELEASE.
Change-Id: I79b273032cfeb719ec5550ac15635fd9f3231469
Reviewed-on: https://go-review.googlesource.com/52710
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Add IoctlGetInt/IoctlSetInt, IoctlGetTermios/IoctlSetTermios and
IoctlGetWinsize/IoctlSetWinsize on Darwin. These are similar to the
already existing implementations on Linux and Solaris.
Generated on Mac OS 10.11 (Darwin 15.6.0).
Change-Id: I2d4cc957c840836fcc2ccb71c67631420f4a2eb1
Reviewed-on: https://go-review.googlesource.com/52410
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Add the Faccessat, Fchmodat, Fchownat, Linkat, Mkdirat, Readlinkat,
Renameat, Symlinkat and Unlinkat functions (to conform to POSIX.1-2008)
and also add the missing AT_* constants.
Generated on FreeBSD 10.11-RELEASE for freebsd/amd64 and freebsd/386.
Change-Id: I1aea155d5375cfd6b38662018ccb5b834151b982
Reviewed-on: https://go-review.googlesource.com/52070
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Capsicum support was added by https://golang.org/cl/47290, but only for
amd64. This broke the freebsd/386 build which was subsequently fixed by
http://golang.org/cl/51270. However, even with this fix the tests still
fail to build due to the missing Capsicum functions and types.
Fix the build/test on freebsd/386 for real by re-running mkall.sh on
FreeBSD 11.1-RELEASE (inside VirtualBox) to get all the Capsicum
functions and types.
Some zerrors constants were removed or converted to enums in the FreeBSD
headers. Manually move them to a dedicated file. Do the same for amd64,
where these constants were removed by accident in
https://golang.org/cl/47290.
Updates golang/go#21136
Change-Id: I54fe2c4567674b07dedad677756369a43a1f0ef6
Reviewed-on: https://go-review.googlesource.com/51570
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
The packet_mreq structure is used on Linux to modify the behavior
of packet sockets using setsockopt. See 'man 7 packet' for more
details.
Change-Id: I34e5b99a6b6eb1f23d49a9c9f25ce7b77121c8f0
Reviewed-on: https://go-review.googlesource.com/51710
Run-TryBot: Matt Layher <mdlayher@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Add the SizeofIovec constant corresponding to type Iovec.
Change-Id: Icde241b8cac3bc89806f0081a4021598bf0ef7cf
Reviewed-on: https://go-review.googlesource.com/51730
Reviewed-by: Matt Layher <mdlayher@gmail.com>
Run-TryBot: Matt Layher <mdlayher@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>