AnyPS5/core/libs/prx/libkernel/System/src
David 1ba0a81820 feat(libkernel): implement getpriority for the guest process
PS5MC (PPSA99420, Kodi 22) imports getpriority (miQ1wVwSexE) from
libkernel.prx, one reference, next to chflags in its import order.
Predicted stop once the imports ahead of it are covered (not a run):

  FAIL: unresolved ELF import miQ1wVwSexE from libkernel.prx

The NID is computed with tools/nid_names.py and matches aerolib.

Follows FreeBSD 11.4 sys/kern/kern_resource.c sys_getpriority
(8c639945a44588f6cfdddfb057bb5aad88735da0) for the only guest process,
taken to run at nice 0 and to lead its own process group (as kill and
setsid already assume): PRIO_PROCESS and PRIO_PGRP with 0 or its pid,
and PRIO_USER with 0 or its uid 0, return 0; other ids give ESRCH and
an unknown which gives EINVAL. getpriority is a bare system call in
FreeBSD's libc (lib/libc/sys/Symbol.map), so errno is left unchanged
on success.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
(cherry picked from commit 63262245d274342b693fda146ae9feca3752b6e3)
2026-10-14 10:23:41 +13:00
..
Coredump.cpp feat(libkernel): answer the coredump user-file attach calls 2026-10-13 20:11:39 +05:30
Exception.cpp fix(libkernel): keep raises off unregistered threads and clamp the handler's MXCSR 2026-10-11 11:12:02 +02:00
Login.cpp fix(libkernel): resolve getlogin_r from the effective host account 2026-10-12 01:39:07 +02:00
Notification.cpp fix(libkernel): keep sceKernelDebugOutText off a redirected guest stderr 2026-10-12 17:53:41 +03:00
Process.cpp feat(libkernel): implement getpriority for the guest process 2026-10-14 10:23:41 +13:00
Rtld.cpp build(windows): guard NOMINMAX in Rtld.cpp 2026-10-07 15:00:08 +02:00
Sandbox.cpp feat(libkernel): implement sceKernelGetFsSandboxRandomWord 2026-10-08 21:39:11 +02:00
Sanitizer.cpp feat(libSceDbgThreadSanitizer): declare the TSan annotation calls and report the sanitizer disabled 2026-10-13 02:12:05 -04:00
SignalSets.cpp feat(libkernel): implement sigsetjmp 2026-10-11 11:23:10 +00:00
Signals.cpp feat(libkernel): implement sigpending 2026-10-13 13:30:35 +05:30
SoftwareVersion.cpp feat(libkernel): implement sceKernelGetAllowedSdkVersionOnSystem 2026-10-11 03:48:47 -04:00
SystemConfiguration.cpp feat(libkernel): report hw.model from sysctl 2026-10-12 16:18:42 -04:00
ThermalSensors.cpp feat(libkernel): report the host SoC and CPU temperature 2026-10-13 16:30:07 +02:00
UserContext.cpp feat(libkernel): implement getcontext, setcontext and makecontext 2026-10-11 13:00:38 +03:00