Joel Sing
aa1c4c8554
unix: provide Mount on openbsd
...
Note that Mount is already provided for both darwin and linux, with
differing signatures.
Change-Id: Iaddae1769e436aad5125b78e31b2d62d22e45b16
Reviewed-on: https://go-review.googlesource.com/c/sys/+/595735
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Michael Knyszek <mknyszek@google.com >
2024-08-03 07:06:10 +00:00
Josh Rickmar
f0c7190c5e
unix: remove extra trailing newlines in zsyscall_openbsd_*.go
...
These newlines are written by mksyscall.go but should not appear in the final
generated files once the output is passed through gofmt. This is done by
mkall.sh but I had written a custom script just to generate these openbsd
zsyscall files in CL 468095.
Running the mksyscall.go output through gofmt fixes this issue.
Fixes golang/go#64820
Change-Id: I1b1bf55145bd5a5208e091ded24a973f953c479f
GitHub-Last-Rev: 514272bd56a9bfbcf1ff1e787aece426e235da37
GitHub-Pull-Request: golang/sys#183
Reviewed-on: https://go-review.googlesource.com/c/sys/+/551715
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com >
Reviewed-by: Carlos Amedee <carlos@golang.org >
Run-TryBot: Jorropo <jorropo.pgm@gmail.com >
TryBot-Result: Gopher Robot <gobot@golang.org >
Reviewed-by: Than McIntosh <thanm@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2023-12-21 14:55:30 +00:00
Josh Rickmar
ec230dae7f
unix: use fcntl(2) libc stub on OpenBSD
...
Future OpenBSD releases will remove the syscall(2) interface.
This converts the Fcntl functions to use fcntl(2) from libc,
rather than indirectly through syscall(2).
Updates golang/go#63900 .
Change-Id: I50c3b91cb40245653c772e65b0b15c625974bebe
GitHub-Last-Rev: 9c62104c43c63885d0cb4b198eb8c029bc644fa6
GitHub-Pull-Request: golang/sys#179
Reviewed-on: https://go-review.googlesource.com/c/sys/+/538995
Reviewed-by: Bryan Mills <bcmills@google.com >
Reviewed-by: Joel Sing <joel@sing.id.au >
Reviewed-by: Cherry Mui <cherryyz@google.com >
Run-TryBot: Joel Sing <joel@sing.id.au >
TryBot-Result: Gopher Robot <gobot@golang.org >
Reviewed-by: Mauri de Souza Meneguzzo <mauri870@gmail.com >
2023-11-06 12:49:47 +00:00
Joel Sing
cb378ae1ff
syscall: call getfsstat via libc on openbsd
...
On openbsd, call getfsstat directly via libc, instead of calling it
via syscall.Syscall.
Updates golang/go#63900
Change-Id: I99a3555b3207754b107dbabf63440569fca93eea
Reviewed-on: https://go-review.googlesource.com/c/sys/+/538976
Reviewed-by: Cherry Mui <cherryyz@google.com >
Run-TryBot: Joel Sing <joel@sing.id.au >
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com >
Reviewed-by: Josh Rickmar <jrick@zettaport.com >
Reviewed-by: Bryan Mills <bcmills@google.com >
TryBot-Result: Gopher Robot <gobot@golang.org >
2023-11-03 11:48:45 +00:00
Josh Rickmar
661d749b94
unix: use libc stubs for OpenBSD pledge+unveil
...
Future OpenBSD releases will remove the syscall(2) interface.
This converts the Pledge and Unveil calls to use pledge(2) and
unveil(2) from libc, rather than indirectly through syscall(2).
Updates golang/go#63900 .
Change-Id: I61e22d8f52f16c8f5e4c0717acae0d5bf4271503
GitHub-Last-Rev: ebc0461460297de6d4f677a48d3a361d7e620df0
GitHub-Pull-Request: golang/sys#146
Reviewed-on: https://go-review.googlesource.com/c/sys/+/468095
Reviewed-by: Cherry Mui <cherryyz@google.com >
Reviewed-by: Mauri de Souza Meneguzzo <mauri870@gmail.com >
Reviewed-by: Joel Sing <joel@sing.id.au >
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com >
Run-TryBot: Joel Sing <joel@sing.id.au >
TryBot-Result: Gopher Robot <gobot@golang.org >
Reviewed-by: Aaron Bieber <aaron@bolddaemon.com >
Reviewed-by: Bryan Mills <bcmills@google.com >
2023-11-03 07:50:05 +00:00
Dmitri Shuralyov
1bfbee0e20
all: update go directive to 1.18
...
Done with:
go get go@1.18
go mod tidy
go fix ./...
Using go1.21.3.
Also update code generators to use only the new go:build lines,
not the old +build ones.
For golang/go#60268 .
Change-Id: I6aabc42efb6ab3329981100e1db2263aac5e92a6
Reviewed-on: https://go-review.googlesource.com/c/sys/+/534222
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
Auto-Submit: Dmitri Shuralyov <dmitshur@golang.org >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2023-10-11 21:54:30 +00:00
Tobias Klauser
2964e1e4b1
unix: remove unused readlen and writelen
...
These were originally added when copying over files from package
syscall. However, their use was removed in CL 129500043. New ports kept
adding these wrappers without using them. They are still unused, so
remove them.
Change-Id: I2ffffe98a5c999d23b63d1f04ee4ad8f807ee736
Reviewed-on: https://go-review.googlesource.com/c/sys/+/531356
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Than McIntosh <thanm@google.com >
Auto-Submit: Tobias Klauser <tobias.klauser@gmail.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2023-09-28 17:55:56 +00:00
Alvar Penning
81c8a6c06d
unix: add Getresuid and Getresgid for OpenBSD
...
Addresses golang/go#60483 for OpenBSD.
This change was successfully tested on amd64 and adjusted accordingly for the other architectures.
Change-Id: Id63cca342d81d2cc5854eb2923ca7e66bfaa91bf
GitHub-Last-Rev: cff11701438edc20bef2961bb73bf9c6ea81b4a1
GitHub-Pull-Request: golang/sys#160
Reviewed-on: https://go-review.googlesource.com/c/sys/+/500655
Reviewed-by: David Chase <drchase@google.com >
Run-TryBot: Ian Lance Taylor <iant@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Run-TryBot: Ian Lance Taylor <iant@golang.org >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com >
TryBot-Result: Gopher Robot <gobot@golang.org >
2023-06-05 16:39:39 +00:00
Ian Lance Taylor
ff18efa0a3
unix: change Setrlimit/Prlimit to always call syscall functions
...
As of Go 1.21 syscall.Setrlimit and syscall.prlimit can affect
starting a new process, by restoring the original NOFILE rlimit.
That is recorded locally in the syscall package, so just always
call the syscall functions.
For golang/go#46279
Change-Id: I2f3dafe5562a7dde1297bad6f5d34a80af5d620b
Reviewed-on: https://go-review.googlesource.com/c/sys/+/476695
Run-TryBot: Ian Lance Taylor <iant@golang.org >
Run-TryBot: Ian Lance Taylor <iant@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
TryBot-Result: Gopher Robot <gobot@golang.org >
Reviewed-by: Bryan Mills <bcmills@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
2023-03-15 21:12:13 +00:00
Dmitri Goutnik
b13f40e221
unix: add ioctlPtr with unsafe.Pointer arg on other unices
...
This is a followup for CL 340915 that adds ioctlPtr for all other
UNIX-like platforms.
For golang/go#44834
Change-Id: I0ecf84e53f13e5a8da736b3ba7f643262596d23c
Reviewed-on: https://go-review.googlesource.com/c/sys/+/469315
Reviewed-by: Matthew Dempsky <mdempsky@google.com >
Run-TryBot: Dmitri Goutnik <dgoutnik@gmail.com >
TryBot-Result: Gopher Robot <gobot@golang.org >
Reviewed-by: Bryan Mills <bcmills@google.com >
2023-02-21 11:26:31 +00:00
Tobias Klauser
cffae8ece4
unix: add ClockGettime on *bsd and solaris
...
The same wrapper is already implemented on linux and darwin.
Change-Id: Ia986fdfc28767356451d157e53f11e8d9ca86f2c
Reviewed-on: https://go-review.googlesource.com/c/sys/+/456795
TryBot-Result: Gopher Robot <gobot@golang.org >
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Than McIntosh <thanm@google.com >
Auto-Submit: Tobias Klauser <tobias.klauser@gmail.com >
2022-12-13 14:01:47 +00:00
Joel Sing
a970992b06
unix: add support for openbsd/riscv64
...
Updates golang/go#55999
Change-Id: I2ea76f72faaddc46da0c37650de702bc7e90eea2
Reviewed-on: https://go-review.googlesource.com/c/sys/+/439976
TryBot-Result: Gopher Robot <gobot@golang.org >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Bryan Mills <bcmills@google.com >
Run-TryBot: Joel Sing <joel@sing.id.au >
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com >
2022-10-10 17:02:16 +00:00