Commit Graph

633 Commits

Author SHA1 Message Date
Tobias Klauser
b4e8571b14 cpu: fix build for GOARCH=ppc64{,le} on GOOS!=linux
The current implementation for ppc64{,le} only supports linux (through
HWCaps read from /proc/self/auxv) and fails to build e.g. on
aix/ppc64.

Change-Id: I5e1efe75c781fd08bc7bbe797df88295726ba62b
Reviewed-on: https://go-review.googlesource.com/c/162798
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-02-21 07:52:27 +00:00
Bryan C. Mills
629670e5ac windows: gofmt -w windows/security_windows.go
x/sys/unix is vendored into the standard library, and the commit hook
for the standard library requires files to be gofmt-clean.

Updates golang/go#26924

Change-Id: I22a994062bcdbebe8a1fe1ae0ed4606837f03079
Reviewed-on: https://go-review.googlesource.com/c/162990
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-02-20 15:41:26 +00:00
Bryan C. Mills
90b0e4468f unix: do not invoke Mkfifo with a relative path in a read-only directory
Updates golang/go#28387

Change-Id: Ibcdc3f9cb3dc43b86b7e7d3539ed592219e54aba
Reviewed-on: https://go-review.googlesource.com/c/162987
Run-TryBot: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-02-19 20:33:50 +00:00
Michael Munday
153ac47618 cpu: unexport HWCap and HWCap2
These are an implementation detail and should not have been
exported. This only affects Linux on platforms other than 386 and
amd64.

Fixes golang/go#30255.

Change-Id: Ib23b42a7309fd6093b6b9d8b6628de222a3928be
Reviewed-on: https://go-review.googlesource.com/c/163004
Run-TryBot: Michael Munday <mike.munday@ibm.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2019-02-19 09:28:55 +00:00
Michael Munday
d0b11bdaac cpu: fix auxval parsing on big-endian systems
The words in auxval are encoded in native byte order.

I haven't added a test. This fix will be tested when s390x support
is added to the package.

Change-Id: I276f833660e6906c319995798faf9054ffc69461
Reviewed-on: https://go-review.googlesource.com/c/162902
Run-TryBot: Michael Munday <mike.munday@ibm.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2019-02-15 14:29:49 +00:00
Tobias Klauser
e77772198c cpu: fix build for GOARCH=arm64 on GOOS!=linux
The current implementation for arm64 only supports linux (through HWCaps
read from /proc/self/auxv) and fails to build e.g. on darwin/arm64.

Fixes golang/go#30237

Change-Id: I9f32a285760795441a829b0a81b2d5aff04e2dc4
Reviewed-on: https://go-review.googlesource.com/c/162797
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-02-14 21:44:11 +00:00
Visweswara R
983097b1a8 unix: replace Perl script references in "README.md" with Go programs
Update references to mksyscall*.pl and mksysnum*.pl Perl scripts in
"README.md" with mksyscall*.go and mksysnum*.go Go programs.

Updates golang/go#27779

Change-Id: Ide3f5d9894c91aa6103d6bbe5ec64a47c969daa7
Reviewed-on: https://go-review.googlesource.com/c/162278
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2019-02-13 12:17:43 +00:00
Visweswara R
cea5d2f6b4 unix: replace "mksyscall_solaris.pl" script with a Go program
Port mksyscall_solaris.pl Perl script to mksyscall_solaris.go.
mkall.sh script is modified to run mksyscall_solaris.go. Running
mkall.sh does not generate any git diff besides the command
name in comments of generated files.

Updates golang/go#27779

Change-Id: I773c9732a882780400a06f578c00e455e133231b
Reviewed-on: https://go-review.googlesource.com/c/162277
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2019-02-13 11:57:55 +00:00
Josh Bleecher Snyder
3b52091055 unix: add ClockGettime on darwin/amd64
Updates golang/go#25633

Change-Id: I20ff2d0cda642fb7b155d3ae06499e8c0ef0a2b2
Reviewed-on: https://go-review.googlesource.com/c/161721
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-02-09 17:36:11 +00:00
Josh Bleecher Snyder
f54c5e0abf unix: update zsysnum_darwin_amd64 for macOS 10.14
Change-Id: I77f491029a8f2e37ffbda3d0f50795287d6cd641
Reviewed-on: https://go-review.googlesource.com/c/161720
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-02-09 17:35:27 +00:00
Josh Bleecher Snyder
446ad8e35c unix: require GOOS be set in mksyscall
If you don't set GOOS and you try to regenerate
the darwin files, it appears to succeed.
However, because libc was not selected,
it generates broken code.

Change-Id: I20fb4f51dcc539a03b6c6ed03ce39b78d5987d41
Reviewed-on: https://go-review.googlesource.com/c/161719
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-02-09 17:34:53 +00:00
Tobias Klauser
41f3e65849 unix/linux: update Dockerfile to glibc 2.29 and Go 1.12beta2
Drop the manually defined *_XDP constants which were added to glibc.
Install python3 instead of python because glibc's confugure script now
requires at least 3.4.

Change-Id: Ic19ff4d8aa4dbadeb5438e331ccafeafc2cc9925
Reviewed-on: https://go-review.googlesource.com/c/160957
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-02-04 20:37:06 +00:00
Jason A. Donenfeld
980327fe3c windows: Implement WaitForMultipleObjects
This is a very classic and highly useful Windows API that I'm surprised
it's still not here.

Change-Id: If54319099cd94dd727126c579dd5a681979321cd
Reviewed-on: https://go-review.googlesource.com/c/160937
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alex Brainman <alex.brainman@gmail.com>
2019-02-04 10:32:48 +00:00
Visweswara R
7ae0202eb7 unix: set 100644 mode on mksyscall_aix_ppc64.go
Change mode of mksyscall_aix_ppc64.go to 644.

Change-Id: Icebc0944a739b58111f5420ec2f0850b348f1fee
Reviewed-on: https://go-review.googlesource.com/c/160918
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-02-03 05:02:04 +00:00
Tobias Klauser
afcc84fd75 unix: add RND* ioctl consts on Linux
Change-Id: I79c721d0f4fe097daf096dc7404675aa3048bf6a
Reviewed-on: https://go-review.googlesource.com/c/160757
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-02-01 15:26:29 +00:00
Tobias Klauser
2970a3744d cpu: detect RDRAND and RDSEED instructions on x86
Change-Id: I2d0094d64ba12f888758aeebdb43aed353ddeeb9
Reviewed-on: https://go-review.googlesource.com/c/160577
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-02-01 07:34:06 +00:00
Tobias Klauser
aca44879d5 unix: add ioctl wrappers to get and set RTC time on Linux
Add IoctlGetRTCTime and IoctlSetRTCTime to get and set the RTC time via
the RTC_RD_TIME and RTC_SET_TIME ioctls.

Change-Id: I63190026be39746599c2cd7116603d4a1d5bd695
Reviewed-on: https://go-review.googlesource.com/c/160397
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-01-30 15:09:45 +00:00
two
302c3dd5f1 unix: fix misspellings
Change-Id: I4e1facc318d87fdd2abca1de040fdcb25680339e
GitHub-Last-Rev: bfebe23528
GitHub-Pull-Request: golang/sys#30
Reviewed-on: https://go-review.googlesource.com/c/159597
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-01-29 07:53:46 +00:00
Tobias Klauser
d57399882c unix: regenerate sysnum files for freebsd/arm64 and netbsd/arm64
The zsysnum_{freebsd,netbsd}_arm64.go files were generated before
mksysnum was converted to Go in CL 152677. Regenerate them to adjust the
comment specifying the command used for generation.

Change-Id: I8f00249848fe20e388f255e9e615da1e0727c140
Reviewed-on: https://go-review.googlesource.com/c/159778
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-01-29 07:23:52 +00:00
Tobias Klauser
b90733256f unix: use glibc release branch in Dockerfile
It shouldn't make a difference for generating types and consts, but
let's use the glibc release branch anyway.

Fixes golang/go#29873

Change-Id: I15a3df250f5ae6181b2d036a10e0523ebe44ac3f
Reviewed-on: https://go-review.googlesource.com/c/158997
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-01-24 10:00:55 +00:00
Visweswara R
c6b37f3e92 unix: replace "mksyscall_aix_ppc64.pl" script with a Go program
Port mksyscall_aix_ppc64.pl Perl script to mksyscall_aix_ppc64.go.
mkall.sh script is modified to run mksyscall.go. Running
mkall.sh does not generate any git diff besides the command
name in comments of generated files.

Updates golang/go#27779

Change-Id: Ie888c0df470dcfc75034faa12cf3422b2d426629
Reviewed-on: https://go-review.googlesource.com/c/158699
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2019-01-23 07:42:12 +00:00
Tobias Klauser
054c452bb7 unix: add socket error queue constants and types from linux/errqueue.h
Also add additional packet timestamping constants and types defined
in the same header.

Change-Id: I4280f925b46e229f4c3a83a7fee4612592314016
Reviewed-on: https://go-review.googlesource.com/c/158761
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-01-22 07:17:31 +00:00
Maya Rashish
770c60269b unix: add netbsd/arm64 files.
This isn't a real generation, it's mostly a copy of the amd64
files, due to difficulties in generation.

There should be little to no differences between netbsd 64bit
archs.

Change-Id: I1c7b25cfef87220c827018e73695e5ca08987156
GitHub-Last-Rev: 043207b2c2
GitHub-Pull-Request: golang/sys#27
Reviewed-on: https://go-review.googlesource.com/c/155738
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-01-21 09:02:51 +00:00
Tobias Klauser
11f53e0313 unix: use int8 for RawSockaddrUnix.Path on linux/riscv64
On linux/riscv64, char defaults to unsigned, so explicitly make
RawSockaddrUnix.Path signed.

Patch by Ryan O'Leary.

Updates golang/go#27532

Change-Id: If99a3953462ad98f61d8fafcda3ebb71b44e6018
Reviewed-on: https://go-review.googlesource.com/c/157900
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-01-16 16:14:47 +00:00
Tobias Klauser
e5ecc2a674 unix: use Renameat2 to implement Renameat on linux/riscv64
On linux/riscv64, the renameat syscall no longer exists and has been
superseded by renameat2. Use Renameat2 to implement Renameat on
linux/riscv64.

Based on a patch by Ryan O'Leary.

Updates golang/go#27532

Change-Id: I7c60c7f824750408265f67397b8ac1fa7226f425
Reviewed-on: https://go-review.googlesource.com/c/157899
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-01-16 15:12:25 +00:00
Tobias Klauser
5552a988b7 unix: add Renameat on dragonfly
Also add a test now that all unices have Renameat.

Change-Id: I9098662569e9910122dc686559bbd04be06328fa
Reviewed-on: https://go-review.googlesource.com/c/157898
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-01-16 15:07:22 +00:00
Tobias Klauser
a457fd0364 unix: add Signalfd on linux
Also add the SFD_* constants and SignalfdSiginfo type.

Change-Id: I3415c212b85c9d5a940ba2bf70f43739a2630d78
Reviewed-on: https://go-review.googlesource.com/c/157897
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-01-15 15:29:22 +00:00
Sebastian Schmidt
2be5172556 unix: add ClockNanosleep and TIMER_ABSTIME
This adds the ClockNanosleep syscall and the TIMER_* constants;
currently only TIMER_ABSTIME for specifying an absolute timestamp.

Change-Id: Ic8d857eb92818529aadab569cd8646a19bb9c055
Reviewed-on: https://go-review.googlesource.com/c/157658
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2019-01-14 13:03:36 +00:00
Tobias Klauser
48ac38b7c8 unix: get *BSD syscalls.master files using HTTPS
Use the https:// URLs to get syscalls.master for freebsd, openbsd and
dragonfly. For netbsd, keep using the http:// URL since HTTPS is not
supported.

Change-Id: Ibcbd19d5e3b4585552ea65dcdc742c2e7bfce944
Reviewed-on: https://go-review.googlesource.com/c/157057
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-01-09 14:50:17 +00:00
Visweswara R
7fbe1cd0fc unix: replace "mksyscall_aix_ppc.pl" script with a Go program
Port mksyscall_aix_ppc.pl Perl script to mksyscall_aix_ppc.go.
mkall.sh script is modified to run mksyscall.go. Running
mkall.sh does not generate any git diff besides the command
name in comments of generated files.

Updates golang/go#27779

Change-Id: I57b0e5f9fe44dadd96d0e512046bb63e8e1b9f66
Reviewed-on: https://go-review.googlesource.com/c/156778
Reviewed-by: Clément Chigot <clement.chigot@atos.net>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-01-08 10:45:31 +00:00
Carlos Eduardo Seo
20be8e55dc cpu: add linux/ppc64x
Port from Go internal/cpu.

Fixes golang/go#25185

Change-Id: Id3cac18da6ffec9d10df755c4032ce3068ab634d
Reviewed-on: https://go-review.googlesource.com/c/152938
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-01-07 17:34:14 +00:00
Visweswara R
cb59ee3660 plan9: replace "mksyscall.pl" with Go program
Modify unix/mksyscall.go to support plan9.
This does not generate any git diff besides the
command name in comments of generated files and
addition of +build tags.

Updates golang/go#27779

Change-Id: I359a80d1c08837d92a7095e5235867c29a2d2a60
Reviewed-on: https://go-review.googlesource.com/c/156157
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2019-01-07 07:01:47 +00:00
Keith Randall
1775db3f06 unix: make Fcntl* routines use libSystem on Darwin
Missed this one.

Update golang/go#17490.

Change-Id: I5ab2197f9981b712b37d3060f72209bebcadf291
Reviewed-on: https://go-review.googlesource.com/c/156346
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-01-06 19:24:25 +00:00
Visweswara R
badf558520 plan9: remove "use" function and calls from generated code.
Update mksyscall.pl to skip generating calls to "use".

See issue https://golang.org/issue/16607
and CL https://golang.org/cl/36616

Change-Id: Id36614fce5d98a8538edf4f4a7276e650b99b839
Reviewed-on: https://go-review.googlesource.com/c/156437
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>
2019-01-05 16:57:16 +00:00
Tobias Klauser
82a175fd15 unix/linux: update Dockerfile to Linux Kernel 4.20
Change-Id: Iadc92b5afd18a5c1df0bc42b0d6f52f0b768b47a
Reviewed-on: https://go-review.googlesource.com/c/155979
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-01-02 15:56:01 +00:00
Tobias Klauser
a91c4d227e unix: add support for freebsd/arm64
This wasn't actually generated on freebsd/arm64 yet. It's mostly a copy
of the amd64 files for now.

Updates golang/go#24715

Change-Id: If24c3c5803a4708f0b26d738f690cbea1694ca88
Reviewed-on: https://go-review.googlesource.com/c/155978
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-01-02 15:55:44 +00:00
Anthony Fok
9a3f9b0469 unix: fix Fstatat by using fillStat_t on linux/mips64x
The stat structure on linux/mips64x differ between C library and the kernel,
as described in the stat(2) man page.

Fstat, Lstat and Stat on linux/mips64x already converts the stat structure
using a fillStat_t function, very similar to __xstat_conv in GLIBC.
Doing the same for Fstatat before calling SYS_NEWFSTATAT fixes the
"Fstatat: returned stat does not match Stat/Lstat" error in TestFstatat.

Fixes golang/go#29401

Change-Id: I0b2a7b274acc3c7c9fc7ae2afe722dd6225da383
Reviewed-on: https://go-review.googlesource.com/c/155747
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2018-12-28 14:41:15 +00:00
Aleksa Sarai
c6cbdbf9e6 unix: mksysnum: correct +build restriction
Previously the +build line was taken as a package comment, due to how Go
handles cases like the following:

  // +build <foo>
  package foo

And thus caused build failures because of package name conflict issues.

Fixes: https://golang.org/cl/152677

Change-Id: I7360ee100a739b00beaa1337b0408bb06fa240a6
GitHub-Last-Rev: b67a58691f3a5be12f2c5c510fbb4bd95fdd6e05
GitHub-Pull-Request: golang/sys#28
Reviewed-on: https://go-review.googlesource.com/c/155748
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2018-12-28 12:02:56 +00:00
Visweswara R
367055b3f9 unix: replace mksysnum_*.pl scripts with Go program
Port mksysnum_{(open|net|free)bsd,dragonfly,darwin}.pl Perl
scripts to mksysnum.go.

mkall.sh script is modified to run mksysnum.go. Running
./mkall.sh generates no git diff besides command name and
function prototype in comments of generated files.

Updates golang/go#27779

Change-Id: I534734a9c7fda186ca133ba19e14481e55832be1
Reviewed-on: https://go-review.googlesource.com/c/152677
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2018-12-28 11:21:25 +00:00
Tobias Klauser
b4a75ba826 unix: generate linux/sparc64 go files using Docker
With cgo supporting sparc64 as of CL 102555 and CL 132155, the Docker
based build system can be used to generate file for linux/sparc64 as
well.

Updates golang/go#15282

Change-Id: I109e55f39d3229b24b0029c42074e439c6c54dc8
Reviewed-on: https://go-review.googlesource.com/c/102655
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2018-12-21 14:31:28 +00:00
itchyny
a79f1b1907 unix: fix unused import in syscall_darwin_386.go
Fix a compile error due to unused import introduced by CL 154663.

Change-Id: I2a732380c35cd98dfff36289f5d72fd7d7222205
GitHub-Last-Rev: 5c7065d26c
GitHub-Pull-Request: golang/sys#26
Reviewed-on: https://go-review.googlesource.com/c/155460
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2018-12-21 13:50:38 +00:00
Keith Randall
8ff4e546d4 unix: add space to generated code
Change-Id: Iab98581ade90ffb6c9faa29d4a45558498fff82a
Reviewed-on: https://go-review.googlesource.com/c/155398
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2018-12-21 06:54:08 +00:00
Keith Randall
9fbf701fc3 unix: reverse default for 1.11/1.12 split
Make 1.11 the explicitly named case, and 1.12 the default.

Change-Id: Ic3674860eb9e8a5bb1cf1da12c5ac583cc0b0633
Reviewed-on: https://go-review.googlesource.com/c/155397
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2018-12-21 06:53:00 +00:00
Keith Randall
36ca6f176f unix: add Sendfile test
There wasn't one. I was mucking around with the Sendfile internals in
CL 154663 so I need one to make sure I didn't break anything.

Change-Id: I38b25de4995831680fdac440dfa7f26542d2624f
Reviewed-on: https://go-review.googlesource.com/c/154664
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2018-12-21 06:52:52 +00:00
Alberto Donizetti
b00e65af1d unix/linux: set 100644 mode on mksysnum.go
Change mode of mksysnum.go to 644.

I also checked all the other files with 755 mode, to verify that no
other Go file has this issue. After this change, only .sh and .pl
files are executable:

  $ git ls-files -s * | grep 100755
  100755 9f73c60660 0	plan9/mkall.sh
  100755 85309c4a5b 0	plan9/mkerrors.sh
  100755 252e89e14d 0	plan9/mksyscall.pl
  100755 3c3ab05810 0	plan9/mksysnum_plan9.sh
  100755 f8dab7511d 0	unix/mkall.sh
  100755 955dd50f9a 0	unix/mkerrors.sh
  100755 c44de8d310 0	unix/mksyscall_aix_ppc.pl
  100755 53df26bb93 0	unix/mksyscall_aix_ppc64.pl
  100755 a354df5a6b 0	unix/mksyscall_solaris.pl
  100755 20632e1460 0	unix/mksysctl_openbsd.pl
  100755 5453c53b19 0	unix/mksysnum_darwin.pl
  100755 6804f41216 0	unix/mksysnum_dragonfly.pl
  100755 198993d095 0	unix/mksysnum_freebsd.pl
  100755 85988b140b 0	unix/mksysnum_netbsd.pl
  100755 84edf60ca1 0	unix/mksysnum_openbsd.pl

Fixes golang/go#29369

Change-Id: I66eae4cec07806ea6289e229819aef8dbbad9335
Reviewed-on: https://go-review.googlesource.com/c/155417
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
2018-12-20 20:41:20 +00:00
Keith Randall
7c4c994c65 unix: remove raw syscall from Sendfile
Update golang/go#17490

Change-Id: Iaec54b8ffda1a24d4c8b5671185d570fb8683155
Reviewed-on: https://go-review.googlesource.com/c/154663
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2018-12-20 18:20:59 +00:00
Keith Randall
8588221f65 unix: remove raw syscall from getAttrList
Update golang/go#17490

Change-Id: I55ea10ce2eb5fb1c0518a57900e78e5f0a29b893
Reviewed-on: https://go-review.googlesource.com/c/154662
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2018-12-20 18:20:16 +00:00
Keith Randall
22c30cd1f7 unix: remove raw syscall from getattrlistTimes
Update golang/go#17490

Change-Id: I29feed5ddea976b39bd4c43bd1ff5942f47df083
Reviewed-on: https://go-review.googlesource.com/c/154661
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2018-12-20 18:19:19 +00:00
Keith Randall
4dcd0b7660 unix: remove raw syscall from Getfsstat
Use libc version instead.

Update golang/go#17490

Change-Id: Ibcedccb9715961904d12fc85f69a7139b6c26658
Reviewed-on: https://go-review.googlesource.com/c/154660
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2018-12-20 18:18:36 +00:00
Keith Randall
54d2441686 unix: remove Getdirentries on iOS
This system call doesn't exist on iOS.

Update golang/go#28984

Change-Id: I92eb6fd3eb263863a31338bc18c9826a2242434b
Reviewed-on: https://go-review.googlesource.com/c/154659
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2018-12-20 18:17:18 +00:00