From 196b200d0f19c41730db439c62db9b39e424f21f Mon Sep 17 00:00:00 2001 From: Ophestra Date: Thu, 12 Mar 2026 01:14:03 +0900 Subject: container: expose priority and SCHED_OTHER policy The more explicit API removes the arbitrary limit preventing use of SCHED_OTHER (referred to as SCHED_NORMAL in the kernel). This change also exposes priority value to set. Signed-off-by: Ophestra --- container/std/syscall.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'container/std') diff --git a/container/std/syscall.go b/container/std/syscall.go index 8ebf33d4..61c54877 100644 --- a/container/std/syscall.go +++ b/container/std/syscall.go @@ -134,7 +134,7 @@ func (policy SchedPolicy) GetPriorityMax() (Int, error) { 0, 0, ) schedPriority[policy][0] = Int(priority) - if schedPriority[policy][0] < 0 { + if errno != 0 { schedPriorityErr[policy][0] = errno } }) @@ -151,10 +151,9 @@ func (policy SchedPolicy) GetPriorityMin() (Int, error) { 0, 0, ) schedPriority[policy][1] = Int(priority) - if schedPriority[policy][1] < 0 { + if errno != 0 { schedPriorityErr[policy][1] = errno } }) return schedPriority[policy][1], schedPriorityErr[policy][1] - } -- cgit v1.3.1