Tobias Klauser
696d3420cc
unix: gofmt after CL 621375
...
Change-Id: Ibcd776913317d3b38b418190fa93c6eae52ffc0d
Reviewed-on: https://go-review.googlesource.com/c/sys/+/621955
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Auto-Submit: Tobias Klauser <tobias.klauser@gmail.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
2024-10-24 15:37:41 +00:00
Yaroslav Kolomiiets
60d787735c
unix: add PTP_PF_* constants on Linux
...
These represent valid values for PtpPinDesc.Func.
They are defined as enum, thus not emitted from mkerrors.sh.
Change-Id: Ibac22d56214fa0f64a4095dfc000692a5e5e994a
GitHub-Last-Rev: e7990b0882
GitHub-Pull-Request: golang/sys#229
Reviewed-on: https://go-review.googlesource.com/c/sys/+/621735
Reviewed-by: Michael Pratt <mpratt@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
2024-10-23 15:19:30 +00:00
Yaroslav Kolomiiets
256d1dfe8f
unix: add PTP IOCTLs on Linux
...
The IOCTLs are used for interacting with PTP-specific functions of NIC and time card drivers.
Description:
https://netdevconf.info/0x18/docs/netdev-0x18-paper39-talk-slides/netdev-intro-ptp-api.pdf
Change-Id: If50d605958e5cee451146cf68cc95a3704917512
GitHub-Last-Rev: 44fac1cb1a
GitHub-Pull-Request: golang/sys#225
Reviewed-on: https://go-review.googlesource.com/c/sys/+/621375
Reviewed-by: Michael Pratt <mpratt@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2024-10-21 18:42:12 +00:00
mertakman
adbb8bbcaf
windows/mkwinsyscall: use syscall.SyscallN instead of syscall.Syscall{6,9,12,15}
...
Replace syscall.Syscall6, Syscall9, Syscall12, and Syscall15 with syscall.SyscallN for Go 1.18+. This simplifies system calls by allowing the exact number of arguments needed, eliminating zero padding and reducing potential errors.
Updated TestSyscallXGeneration to TestSyscallNGeneration to verify correct SyscallN generation for different argument counts.
Change-Id: Icd6662b591d7548e367b88f34243f5529e177eab
GitHub-Last-Rev: c06fca1aa4
GitHub-Pull-Request: golang/sys#219
Reviewed-on: https://go-review.googlesource.com/c/sys/+/614082
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Alex Brainman <alex.brainman@gmail.com >
Reviewed-by: Quim Muntal <quimmuntal@gmail.com >
2024-10-21 13:42:39 +00:00
Yaroslav Kolomiiets
a57fdb8507
unix: add IoctlGetHwTstamp/IoctlGetHwTstamp on Linux
...
Add the ioctls to get/set the hardware timestamping configuration
(SIOCSHWTSTAMP and SIOCGHWTSTAMP) along with relevant symbols.
The usage is described in
https://www.kernel.org/doc/Documentation/networking/timestamping.txt
Change-Id: Ib7509feaf28218aeae497eff9ca6c0a532aa73c0
GitHub-Last-Rev: 47dc9dfec2
GitHub-Pull-Request: golang/sys#224
Reviewed-on: https://go-review.googlesource.com/c/sys/+/620376
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
2024-10-16 17:41:25 +00:00
Guoqi Chen
3932916d5c
unix: switch to Ubuntu 24.10 in Dockerfile
...
ubuntu 24.04 introduced support for qemu-loongarch64, and ubuntu 24.10
introduced support for the cross-compiler gcc-loongarch64-linux-gnu, so
we can temporarily switch to ubuntu 24.10 to discard the extra links
introduced by loong64 and switch to it when the next ubuntu LTS version
is released.
Change-Id: I96de123df0cf50d6ba0331eeb02fc1e8c48ce304
Reviewed-on: https://go-review.googlesource.com/c/sys/+/618075
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Meidan Li <limeidan@loongson.cn >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2024-10-14 16:58:48 +00:00
cuishuang
2dfefb6832
all: execute gofmt
...
Change-Id: I55aef760145df773be30d567c9e989f46a3e79dc
Reviewed-on: https://go-review.googlesource.com/c/sys/+/618898
Auto-Submit: Tobias Klauser <tobias.klauser@gmail.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Michael Knyszek <mknyszek@google.com >
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com >
2024-10-11 18:38:43 +00:00
Yaroslav Kolomiiets
e5eee7e480
unix: add IoctlGetEthtoolTsInfo on Linux
...
The function fetches ethtool timestamping and PHC association for a
network interface. Its primary usage is to query the mapping between
the interface and its corresponding PTP clock number in /dev/ptp𝑛.
Change-Id: Id09466b3b43056c628593d4d2e05d77ec8d8082b
GitHub-Last-Rev: 3743a3a650
GitHub-Pull-Request: golang/sys#222
Reviewed-on: https://go-review.googlesource.com/c/sys/+/619335
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com >
Auto-Submit: Ian Lance Taylor <iant@golang.org >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
2024-10-11 16:50:38 +00:00
Yaroslav Kolomiiets
fe162bad74
unix: add ClockSettime on Linux
...
The syscall clock_settime(3) is used to set the time on the specified
clock. It is a counterpart to clock_gettime(3) which is already
exposed as ClockGettime here.
Fixes golang/go#69830
Change-Id: I6145c915754f31e3c50f6a11568eb9d5ba12a778
GitHub-Last-Rev: 5b15f129cc
GitHub-Pull-Request: golang/sys#221
Reviewed-on: https://go-review.googlesource.com/c/sys/+/619255
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2024-10-10 19:53:43 +00:00
qmuntal
7143f4a4e1
windows: manually initialize NewNTUnicodeString
...
The `RtlInitUnicodeString` syscall can be avoided by manually
initializing the `NTUnicodeString`.
The process is described in [WdmlibRtlInitUnicodeStringEx](https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/wdmsec/nf-wdmsec-wdmlibrtlinitunicodestringex ).
The less syscalls, the better. It also makes the function faster:
```
goos: windows
goarch: amd64
pkg: golang.org/x/sys/windows
cpu: Intel(R) Core(TM) i7-10850H CPU @ 2.70GHz
│ old.txt │ new.txt │
│ sec/op │ sec/op vs base │
NewNTUnicodeString-12 181.05n ± 15% 96.32n ± 11% -46.80% (p=0.000 n=10)
```
Change-Id: Iaf079acdcc2024cdca6b6b649a711f6be99c5b87
Reviewed-on: https://go-review.googlesource.com/c/sys/+/618175
Reviewed-by: Damien Neil <dneil@google.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2024-10-07 19:17:02 +00:00
Mateusz Poliwczak
23b0dabe63
unix: mark vgetrandom as non-escaping
...
For golang/go#69577
Change-Id: Id1942d252c813126aa2f110e3f426714db73b9c7
GitHub-Last-Rev: 10e6a30b78
GitHub-Pull-Request: golang/sys#220
Reviewed-on: https://go-review.googlesource.com/c/sys/+/616795
Reviewed-by: Ian Lance Taylor <iant@google.com >
Auto-Submit: 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 >
Reviewed-by: Jason Donenfeld <Jason@zx2c4.com >
v0.26.0
2024-10-01 18:16:15 +00:00
John Troy
cbf0eb65e7
unix: fix grep syntax to work on non-GNU greps
...
CL 432835 changed two grep commands in unix/mkerrors.sh in such a way
that is incompatible with AIX's grep, which, unlike GNU grep, does not
support extended regular expressions without the -E flag. The intent of
this PR is to restore the egrep behavior by invoking grep as grep -E.
My assumption is that GNU grep is not meant to be a requirement to run
mkerrors.sh, and given that, grep -E looks like the most cross-platform
approach.
Example of current (incorrect) behavior on AIX:
bash-5.2$ printf 'SIGHUP\nSIGMAX64\nSIGTERM' | grep -v 'SIGSTKSIZE\|SIGSTKSZ\|SIGRT\|SIGMAX64'
SIGHUP
SIGMAX64
SIGTERM
Behavior before CL 432835:
bash-5.2$ printf 'SIGHUP\nSIGMAX64\nSIGTERM' | egrep -v '(SIGSTKSIZE|SIGSTKSZ|SIGRT|SIGMAX64)'
SIGHUP
SIGTERM
Behavior of proposed change:
bash-5.2$ printf 'SIGHUP\nSIGMAX64\nSIGTERM' | grep -E -v '(SIGSTKSIZE|SIGSTKSZ|SIGRT|SIGMAX64)'
SIGHUP
SIGTERM
OpenBSD's grep behaves the same as AIX for the above commands, which is
why I cast this as GNU vs. non-GNU. I haven't tested any other
implementations.
Fixes golang/go#69365
Change-Id: I009353ee630463475a5c131d019f59c5e69efd34
GitHub-Last-Rev: e1166046e1
GitHub-Pull-Request: golang/sys#217
Reviewed-on: https://go-review.googlesource.com/c/sys/+/615755
Reviewed-by: Michael Knyszek <mknyszek@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2024-09-30 12:38:50 +00:00
Mauri de Souza Meneguzzo
e7397b9a65
unix: update to Linux 6.11
...
Change-Id: I1cc777822da1b557e69634faade8e24d06c00ce8
GitHub-Last-Rev: d09238ecd0
GitHub-Pull-Request: golang/sys#218
Reviewed-on: https://go-review.googlesource.com/c/sys/+/613855
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com >
Reviewed-by: Michael Knyszek <mknyszek@google.com >
2024-09-30 12:37:56 +00:00
Jason A. Donenfeld
981de40f5c
unix: use vDSO for getrandom() on linux
...
With CL 614835 adding support in the runtime for calling into the
getrandom() vDSO function, wire up x/sys/unix's Getrandom() function to
it, so that callers can benefit from the increased speed and shared
vDSO state with the runtime.
Updates golang/go#69577 .
Change-Id: I17734409982c51bb984a6337f4ffa8f60414ebee
Reviewed-on: https://go-review.googlesource.com/c/sys/+/615335
Reviewed-by: Michael Pratt <mpratt@google.com >
Reviewed-by: David Chase <drchase@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2024-09-28 01:26:00 +00:00
Leo Antunes
48aad76ed3
linux: add tcp_cc_info and its related types
...
Add the ability to retrieve congestion control information from a socket via TCP_CC_INFO.
Fixes golang/go#68232
Change-Id: I2ea15928ec0e3192b670759bab4b659e62be553b
GitHub-Last-Rev: b8b8c44f1f
GitHub-Pull-Request: golang/sys#200
Reviewed-on: https://go-review.googlesource.com/c/sys/+/595676
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Carlos Amedee <carlos@golang.org >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
2024-09-17 15:50:50 +00:00
cuishuang
d58f986c89
all: fix some typos in comment
...
Change-Id: I40f9866661bad30ee2f4be2e9d0beee54db860b3
Reviewed-on: https://go-review.googlesource.com/c/sys/+/611775
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
Commit-Queue: Ian Lance Taylor <iant@google.com >
Auto-Submit: Dmitri Shuralyov <dmitshur@golang.org >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org >
TryBot-Result: Gopher Robot <gobot@golang.org >
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2024-09-09 19:33:19 +00:00
Tobias Klauser
30de3524c2
unix: fix Test{Fd,}Xattr failure on NetBSD
...
On NetBSD the namespace of an xattr is stored separately from the name
and isn't returned by Listxattr and Flistxattr. Like on FreeBSD, strip
the namespace before checking the returned xattrs.
Fixes golang/go#69313
Fixes golang/go#69314
Change-Id: I7f2393cc63f9860332c0e07a51f3b9d32911e892
Cq-Include-Trybots: luci.golang.try:x_sys-gotip-netbsd-arm64
Reviewed-on: https://go-review.googlesource.com/c/sys/+/611695
Auto-Submit: Tobias Klauser <tobias.klauser@gmail.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Benny Siegert <bsiegert@gmail.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Commit-Queue: Ian Lance Taylor <iant@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
2024-09-09 01:37:35 +00:00
Dmitri Shuralyov
68ed59b20b
windows/svc: fix printf(var) mistake detected by latest printf checker
...
For golang/go#69267 .
Change-Id: Ie240b5c826bb96c0e2021a7e99a3c0f973f0a0e1
Reviewed-on: https://go-review.googlesource.com/c/sys/+/610940
Reviewed-by: Tim King <taking@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 >
2024-09-06 16:31:18 +00:00
Tobias Klauser
c08bc6e187
unix: update Go to 1.23.0
...
Change-Id: Ifd0f3aefd3699871fc875c8628aa4105b2c85f13
Reviewed-on: https://go-review.googlesource.com/c/sys/+/610016
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Auto-Submit: Tobias Klauser <tobias.klauser@gmail.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
2024-09-06 13:14:59 +00:00
James Tucker
a43b625d3c
windows: add SIO_UDP_NETRESET constant
...
In order to get BSD like behavior with regard to ICMP, it is necessary
to set SIO_UDP_NETRESET as well as SIO_UDP_CONNRESET.
Updates golang/go#68614
Change-Id: Ibdf5b6ea6bc08a9d3a0aeac9037864670cf765c0
Reviewed-on: https://go-review.googlesource.com/c/sys/+/609295
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
Reviewed-by: Funda Secgin <fundasecgin38@gmail.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Alex Brainman <alex.brainman@gmail.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
v0.25.0
2024-09-04 13:19:09 +00:00
Ayman Bagabas
ed67b1566a
windows: add console codepage api
...
Add setter/getter for console input/output codepages. This is useful to set the console expected codepage instead of converting it to UTF-16 before writing.
Change-Id: Ie0465708e7cf68d776e23dbbeeca7bcb4db7d2bf
GitHub-Last-Rev: 93c06e27a0
GitHub-Pull-Request: golang/sys#206
Reviewed-on: https://go-review.googlesource.com/c/sys/+/599395
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Alex Brainman <alex.brainman@gmail.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
Reviewed-by: Michael Pratt <mpratt@google.com >
2024-08-28 07:55:29 +00:00
Ian Lance Taylor
9cb830b23e
unix: add missing import to syscall_hurd.go
...
CL 471119 added a reference to the unsafe package,
but didn't add the import.
Change-Id: Ibb8097df0444d8e83ba08e4ca2b5df98844fccf4
Reviewed-on: https://go-review.googlesource.com/c/sys/+/607976
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Commit-Queue: Ian Lance Taylor <iant@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2024-08-23 19:08:35 +00:00
Eli Lindsey
71132f5fbd
unix: add POLLRDHUP to FreeBSD
...
POLLRDHUP is a poll(2) event applicable to stream sockets that notifies
when a remote peer closes a connection.
Change-Id: I03a192426f89bbd08fb27dda2716ffb888043c92
Reviewed-on: https://go-review.googlesource.com/c/sys/+/607797
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2024-08-23 18:12:53 +00:00
Mark Ryan
3283fc3f61
cpu: add support for detecting RISC-V extensions
...
Add a RISCV64 variable to cpu that indicates both the presence
of RISC-V extensions and performance information about the underlying
RISC-V cores. The variable is only populated with non false values on
Linux. The detection code first attempts to use the riscv_hwprobe
syscall introduced in Linux 6.4, falling back to HWCAP if riscv_hwprobe
is not supported. The patch can detect the C, V, Zba, Zbb and Zbs
extensions. V, Zba, Zbb and Zbs can only be detected on a 6.5 kernel
or later (without backports).
Updates golang/go#61416
Change-Id: I40f92724ee3d337c06bdc559ff0b18a8f6bfda9f
Reviewed-on: https://go-review.googlesource.com/c/sys/+/605815
Reviewed-by: Cherry Mui <cherryyz@google.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Joel Sing <joel@sing.id.au >
Reviewed-by: Meng Zhuo <mengzhuo1203@gmail.com >
2024-08-23 10:43:34 +00:00
Ian Lance Taylor
29e55b2fd3
unix: use os.Executable rather than os.Args[0] in tests
...
Change-Id: I67a063d747c6e34dcd0292fdb3a9a0d965a6e133
Reviewed-on: https://go-review.googlesource.com/c/sys/+/607875
Commit-Queue: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Michael Knyszek <mknyszek@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
2024-08-22 21:01:30 +00:00
Ian Lance Taylor
a8c5219b5e
unix: rename XDPUmemReg field back to Size
...
When the Linux-specific XDPUmemReg struct was originally added
(CL 136695) the only field with a prefix was chunk_size,
so cgo rewrote the field to Size. Later Linux added a tx_metadata_len
field, which caused cgo to to leave the chunk_size field as Chunk_size
(CL 577975).
However, existing code, specifically gvisor, refers to the field
as Size. So go back to Size so that existing code will continue
to work.
This does unfortunately mean that people who used the struct since CL
577975 in April, 2024 will have to adapt. There doesn't seem to be a
perfect solution here. But we've had Size since September, 2018,
so let's stick with that.
Change-Id: Ib11edfbf98ce3a9e1a909194f200a39ddfe6f8e0
Reviewed-on: https://go-review.googlesource.com/c/sys/+/607876
Reviewed-by: Ian Lance Taylor <iant@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Run-TryBot: Ian Lance Taylor <iant@golang.org >
TryBot-Result: Gopher Robot <gobot@golang.org >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Michael Knyszek <mknyszek@google.com >
2024-08-22 21:00:49 +00:00
database64128
59665e5b43
unix: add Connectx for darwin
...
connectx(2) can be used to initiate a connection with TCP Fast Open.
Change-Id: I113ee4dede7df1c01e16a0c07fec2b384b266cb0
GitHub-Last-Rev: 31665b9ad3
GitHub-Pull-Request: golang/sys#215
Reviewed-on: https://go-review.googlesource.com/c/sys/+/606155
Auto-Submit: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2024-08-20 16:08:27 +00:00
Joon Lee
a0c72efe2d
unix: add f_flag member flags on z/OS
...
This change adds the constants `ST_RDONLY` and `ST_NOSUID` to a z/OS-specific file.
Change-Id: Ifb78124d93b60a10f10b8169d1bb73dce074e760
GitHub-Last-Rev: 952cf1bc7f
GitHub-Pull-Request: golang/sys#214
Reviewed-on: https://go-review.googlesource.com/c/sys/+/606877
Reviewed-by: Cherry Mui <cherryyz@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2024-08-19 21:41:29 +00:00
Meng Zhuo
c64c51db65
unix: update riscv64 hwprobe to Linux kernel 6.10
...
Change-Id: Ic74816df459b17302a3ba746060b49e987e5da5c
Reviewed-on: https://go-review.googlesource.com/c/sys/+/604435
Reviewed-by: Mark Ryan <markdryan@rivosinc.com >
Reviewed-by: Carlos Amedee <carlos@golang.org >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2024-08-16 23:42:36 +00:00
Mauri de Souza Meneguzzo
da77c6b1d1
unix: sync minimum Linux Kernel version with requirements page
...
Change-Id: I306728f5bf19955177365fd9afcc4c8678b6f81f
GitHub-Last-Rev: cf6f9c7b19
GitHub-Pull-Request: golang/sys#213
Reviewed-on: https://go-review.googlesource.com/c/sys/+/604136
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Carlos Amedee <carlos@golang.org >
Auto-Submit: Ian Lance Taylor <iant@google.com >
2024-08-12 17:41:49 +00:00
Mauri de Souza Meneguzzo
914deed708
unix: add missing ETHTOOL_FLAG_ constants
...
Some constants were removed in CL 600516 that included changes for the
Linux kernel 6.10.
This kernel version moved C defines to an enum ethtool_header_flags that
was not picked up by the mkall.sh script.
For enums, there is a perl script that needs to be run manually, and the
output must be added by hand to the list of constants in unix/linux/types.go.
See https://elixir.bootlin.com/linux/v6.10.3/source/include/uapi/linux/ethtool_netlink.h#L120
Fixes golang/go#68761
Change-Id: Idb189886d257d0fe66a4e832757a469e17f86c34
GitHub-Last-Rev: 08b8ef571d
GitHub-Pull-Request: golang/sys#212
Reviewed-on: https://go-review.googlesource.com/c/sys/+/604098
Reviewed-by: Ian Lance Taylor <iant@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
v0.24.0
2024-08-07 23:18:19 +00:00
database64128
4c7077ec60
windows: add enums for IpAdapterUnicastAddress
...
These are for the enum fields in IpAdapterUnicastAddress.
Change-Id: Ibcb6ce674ab41a94dbe46d394f035208a94b6dae
GitHub-Last-Rev: 1837ff9c32
GitHub-Pull-Request: golang/sys#204
Reviewed-on: https://go-review.googlesource.com/c/sys/+/598895
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Alex Brainman <alex.brainman@gmail.com >
Reviewed-by: Michael Knyszek <mknyszek@google.com >
Reviewed-by: David Chase <drchase@google.com >
2024-08-07 08:50:18 +00:00
Alex Brainman
29298aaa6a
windows: delete TestGetKeyboardLayout
...
According to
https://learn.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-getforegroundwindow
GetForegroundWindow can return nil in some circumstances. So
GetForegroundWindow cannot be used in the TestGetKeyboardLayout.
Just delete the test for now.
Fixes golang/go#68671
Change-Id: I7e05ac2f19b1a6310a3f7f690c6d02b0d1f5571e
Reviewed-on: https://go-review.googlesource.com/c/sys/+/602335
Reviewed-by: Cherry Mui <cherryyz@google.com >
Reviewed-by: David Chase <drchase@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Ayman Bagabas <ayman.bagabas@gmail.com >
2024-08-05 20:31:40 +00:00
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 >
v0.23.0
2024-08-03 07:06:10 +00:00
Mauri de Souza Meneguzzo
cde4660eb9
unix: add linux mseal system call
...
The mseal system call was added in Linux 6.10.
See https://lwn.net/Articles/954936 .
Change-Id: Ic812a5d784effbc1f362045ffeb6f7e50ee5f8bb
GitHub-Last-Rev: de3924e954
GitHub-Pull-Request: golang/sys#209
Reviewed-on: https://go-review.googlesource.com/c/sys/+/600518
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Michael Knyszek <mknyszek@google.com >
2024-07-29 14:24:59 +00:00
Mauri de Souza Meneguzzo
31ef9e726f
unix: update to Linux kernel 6.10
...
Change-Id: I87cac997e5fad645ae04b8a808063389fc468e5a
GitHub-Last-Rev: 3104aafba8
GitHub-Pull-Request: golang/sys#207
Reviewed-on: https://go-review.googlesource.com/c/sys/+/600516
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
Auto-Submit: Dmitri Shuralyov <dmitshur@golang.org >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2024-07-24 16:33:01 +00:00
Mauri de Souza Meneguzzo
d03a807229
unix: update glibc to 2.40
...
Change-Id: I691cc18fe046600a6192c492cf573c8223aa573e
GitHub-Last-Rev: 7a25e88e86
GitHub-Pull-Request: golang/sys#208
Reviewed-on: https://go-review.googlesource.com/c/sys/+/600517
Reviewed-by: Ian Lance Taylor <iant@google.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
2024-07-24 15:35:55 +00:00
Ayman Bagabas
beb594982d
windows: correctly generate GetAce syscall
...
GetAce expects a failretval==0, and we shouldn't call GetLastError on
error.
For golang/go#66850
Change-Id: I812d71b066d56e8285324e70b8b5b5fb42b5ce35
GitHub-Last-Rev: 40cf7508de
GitHub-Pull-Request: golang/sys#205
Reviewed-on: https://go-review.googlesource.com/c/sys/+/599295
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
Reviewed-by: Alex Brainman <alex.brainman@gmail.com >
Auto-Submit: Dmitri Shuralyov <dmitshur@google.com >
2024-07-22 20:52:27 +00:00
Hernan Martinez
7bb0bf703b
cpu: add Int8 matrix multiplication instructions CPU feature flag for ARM64
...
References:
5bbd9b2498/arch/arm64/include/uapi/asm/hwcap.h (L75C9-L75C31)
https://developer.arm.com/documentation/ddi0601/2024-03/AArch64-Registers/ID-AA64ISAR1-EL1--AArch64-Instruction-Set-Attribute-Register-1
Change-Id: Ic4e1cf2c23097c7e8695453b6d0b335756d474bc
Reviewed-on: https://go-review.googlesource.com/c/sys/+/595678
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Auto-Submit: Ian Lance Taylor <iant@golang.org >
Reviewed-by: Cherry Mui <cherryyz@google.com >
2024-07-17 17:57:00 +00:00
Ayman Bagabas
bce4cf76d8
windows: add GetKeyboardLayout & ToUnicodeEx
...
These are used along with GetForegroundWindow and GetWindowThreadProcessId to determine the current user layout and translate the base key the user has pressed.
Change-Id: Ib833ba7ab54213d83e889ff74c5bc0ace5edbe95
GitHub-Last-Rev: 2afe9976a2
GitHub-Pull-Request: golang/sys#188
Reviewed-on: https://go-review.googlesource.com/c/sys/+/574755
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
Reviewed-by: Than McIntosh <thanm@google.com >
Reviewed-by: Alex Brainman <alex.brainman@gmail.com >
Reviewed-by: Ayman Bagabas <ayman.bagabas@gmail.com >
2024-07-17 07:58:31 +00:00
database64128
0eac9b5475
windows: add flags for GetAdaptersAddresses
...
This commit adds all missing flags for GetAdaptersAddresses.
Change-Id: I874623b6ac77af4ced49205493258e118a4f1b26
GitHub-Last-Rev: 384c92a280
GitHub-Pull-Request: golang/sys#203
Reviewed-on: https://go-review.googlesource.com/c/sys/+/597915
Reviewed-by: Alex Brainman <alex.brainman@gmail.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
Reviewed-by: Than McIntosh <thanm@google.com >
2024-07-17 07:47:25 +00:00
Roland Shoemaker
0c18c88c71
cpu: add DIT option and hwcap DIT support
...
Follow-up to https://go.dev/cl/597377 , add a option for DIT so it can be
set via GODEBUG, and add hwcap support for Linux.
Change-Id: Ib094b520edea9c099d37f121b09d02b31644a433
Reviewed-on: https://go-review.googlesource.com/c/sys/+/598719
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2024-07-17 01:04:09 +00:00
Russ Cox
dce4e64e66
LICENSE: update per Google Legal
...
Very minor tweaks:
- Remove (c) pseudosymbol.
- Remove "All Rights Reserved."
- Change "Google Inc." (no longer exists) to "Google LLC".
[git-generate]
echo '
,s/\(c\) //
,s/ All rights reserved.//
,s/Google Inc./Google LLC/
w
q
' | sam -d LICENSE
Change-Id: I9373310143631467badd0131416d741b02c9bd10
Reviewed-on: https://go-review.googlesource.com/c/sys/+/598528
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Auto-Submit: Russ Cox <rsc@golang.org >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2024-07-16 16:11:15 +00:00
Ian Lance Taylor
ee0e627958
unix: skip TestIoctlFileDedupeRange on EOPNOTSUPP error
...
Fixes golang/go#68372
Change-Id: Id3b8fb920b1458e39e7370195591183ee7e450ff
Reviewed-on: https://go-review.googlesource.com/c/sys/+/597555
Reviewed-by: Cherry Mui <cherryyz@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Commit-Queue: Ian Lance Taylor <iant@google.com >
2024-07-11 23:28:22 +00:00
Roland Shoemaker
47fe916942
cpu: add support for DIT detection
...
Change-Id: I9f0991da9684ebd297e40a754e34130c418c34d0
Reviewed-on: https://go-review.googlesource.com/c/sys/+/597377
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2024-07-11 16:45:38 +00:00
Koichi Shiraishi
4cafe5c66f
unix: implements RenamexNp and RenameatxNp for darwin
...
Fixes golang/go#48425
Change-Id: Ib3619863e238eadf09da479bd2e1e47d9ab6f274
Reviewed-on: https://go-review.googlesource.com/c/sys/+/361958
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2024-07-09 14:51:42 +00:00
Edoardo Spadolini
faed7ec264
unix: add PthreadChdir and PthreadFchdir on darwin
...
Fixes golang/go#68226
Change-Id: I92052e2319e4edde21b5e1e47ddb5b261d81448a
GitHub-Last-Rev: bc02d6d44b
GitHub-Pull-Request: golang/sys#201
Reviewed-on: https://go-review.googlesource.com/c/sys/+/595677
Auto-Submit: Ian Lance Taylor <iant@google.com >
Reviewed-by: Cherry Mui <cherryyz@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
v0.22.0
2024-07-03 02:01:09 +00:00
Nuno Cruces
c892bb7ec2
unix: fix MmapPtr test failing on OpenBSD
...
OpenBSD apparently doesn't allow unmapping address space if part of the region is already unmapped.
This tweaks the test so that munmapping twice no longer happens.
Fixes golang/go#68181
Change-Id: I588255f5e10ec015dbb7188eac79cee6be570680
GitHub-Last-Rev: 2535abd892
GitHub-Pull-Request: golang/sys#199
Cq-Include-Trybots: luci.golang.try:go1.22-openbsd-amd64
Reviewed-on: https://go-review.googlesource.com/c/sys/+/595095
TryBot-Bypass: Ian Lance Taylor <iant@golang.org >
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
Auto-Submit: Ian Lance Taylor <iant@golang.org >
2024-06-26 17:48:03 +00:00
Nuno Cruces
a0ef40af1f
unix: fix MremapPtr test failing on NetBSD
...
NetBSD apparently doesn't allow remapping into used address space.
This means that the test that uses mremap to move a mmapped page
into a new address should first mmap (to reserve)
then munmap (to free) the destination.
Fixes golang/go#68180
Change-Id: If66b67e7166ca4dc4331a8cfc3e3a285416e9849
GitHub-Last-Rev: 92058c2f25
GitHub-Pull-Request: golang/sys#198
Cq-Include-Trybots: luci.golang.try:x_sys-gotip-netbsd-amd64
Reviewed-on: https://go-review.googlesource.com/c/sys/+/594756
Reviewed-by: Ian Lance Taylor <iant@google.com >
Reviewed-by: Joedian Reid <joedian@google.com >
Auto-Submit: Dmitri Shuralyov <dmitshur@golang.org >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
2024-06-26 14:54:58 +00:00
Nuno Cruces
daa239428c
unix: add unsafe mmap, munmap, mremap
...
Fixes golang/go#56123
Change-Id: I63a7a6fb3a5b1bb556ac19d76a1e0b04a03ebcfa
GitHub-Last-Rev: 39dbc8e308
GitHub-Pull-Request: golang/sys#197
Reviewed-on: https://go-review.googlesource.com/c/sys/+/592415
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com >
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com >
Auto-Submit: Dmitri Shuralyov <dmitshur@google.com >
Reviewed-by: Ian Lance Taylor <iant@google.com >
2024-06-25 00:37:56 +00:00