diff options
| author | gingerBill <gingerBill@users.noreply.github.com> | 2026-02-11 17:53:16 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-02-11 17:53:16 +0000 |
| commit | 355b8a8c83badc64d23dbb34ea00bb89ac9245db (patch) | |
| tree | 1103d5bde2dd10c28a81f2104d9c17fa0f4c3166 /core/sys | |
| parent | b5bf28dc47dd1c32a45ba0bbedcbcef80409b798 (diff) | |
| parent | 1a37f4eb0cc792783784fca216c79e3f02a3234e (diff) | |
Merge pull request #6245 from odin-lang/new_os
`core:os/os2` -> `core:os` integration
Diffstat (limited to 'core/sys')
| -rw-r--r-- | core/sys/linux/sys.odin | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/core/sys/linux/sys.odin b/core/sys/linux/sys.odin index 392761e1d..6e9c8ab91 100644 --- a/core/sys/linux/sys.odin +++ b/core/sys/linux/sys.odin @@ -2616,9 +2616,9 @@ futex :: proc{ If you are running on a system with less than 128 cores you can use `linux.Cpu_Set` as the type for the mask argument. Otherwise use an array of integers. */ -sched_setaffinity :: proc "contextless" (pid: Pid, cpusetsize: uint, mask: rawptr) -> (Errno) { +sched_setaffinity :: proc "contextless" (pid: Pid, cpusetsize: uint, mask: rawptr) -> (int, Errno) { ret := syscall(SYS_sched_setaffinity, pid, cpusetsize, mask) - return Errno(-ret) + return errno_unwrap(ret, int) } /* @@ -2628,9 +2628,9 @@ sched_setaffinity :: proc "contextless" (pid: Pid, cpusetsize: uint, mask: rawpt If you are running on a system with less than 128 cores you can use `linux.Cpu_Set` as the type for the mask argument. Otherwise use an array of integers. */ -sched_getaffinity :: proc "contextless" (pid: Pid, cpusetsize: uint, mask: rawptr) -> (Errno) { +sched_getaffinity :: proc "contextless" (pid: Pid, cpusetsize: uint, mask: rawptr) -> (int, Errno) { ret := syscall(SYS_sched_getaffinity, pid, cpusetsize, mask) - return Errno(-ret) + return errno_unwrap(ret, int) } // TODO(flysand): set_thread_area |