diff --git a/nx/include/switch/kernel/svc.h b/nx/include/switch/kernel/svc.h index e8d8e71f..7b2d477f 100644 --- a/nx/include/switch/kernel/svc.h +++ b/nx/include/switch/kernel/svc.h @@ -544,19 +544,6 @@ Result svcUnmapPhysicalMemory(void *address, u64 size); ///@} -///@name Process and thread management -///@{ - -/** - * @brief Configures the pause/unpause status of a thread. - * @return Result code. - * @note Syscall number 0x32. - * @warning This is a privileged syscall. Use \ref envIsSyscallHinted to check if it is available. - */ -Result svcSetThreadActivity(Handle thread, bool paused); - -///@} - ///@name Resource Limit Management ///@{ @@ -578,6 +565,18 @@ Result svcGetResourceLimitCurrentValue(u64 *out, Handle reslimit_h, LimitableRes ///@} +///@name Process and thread management +///@{ + +/** + * @brief Configures the pause/unpause status of a thread. + * @return Result code. + * @note Syscall number 0x32. + */ +Result svcSetThreadActivity(Handle thread, bool paused); + +///@} + ///@name Inter-process communication (IPC) ///@{ diff --git a/nx/include/switch/kernel/thread.h b/nx/include/switch/kernel/thread.h index da146b29..80e0972d 100644 --- a/nx/include/switch/kernel/thread.h +++ b/nx/include/switch/kernel/thread.h @@ -21,7 +21,7 @@ typedef struct { * @param entry Entrypoint of the thread. * @param arg Argument to pass to the entrypoint. * @param stack_sz Stack size (rounded up to page alignment). - * @param prio Thread priority (0x00~0x3F); 0x2C is the usual priority of the main thread. + * @param prio Thread priority (0x00~0x3F); 0x2C is the usual priority of the main thread, 0x3B is a special priority on cores 0..2 that enables preemptive multithreading (0x3F on core 3). * @param cpuid ID of the core on which to create the thread (0~3); or -2 to use the default core for the current process. * @return Result code. */ @@ -54,7 +54,6 @@ Result threadClose(Thread* t); * @brief Pauses the execution of a thread. * @param t Thread information structure. * @return Result code. - * @warning This is a privileged operation; in normal circumstances applications cannot use this function. */ Result threadPause(Thread* t); @@ -62,6 +61,5 @@ Result threadPause(Thread* t); * @brief Resumes the execution of a thread, after having been paused. * @param t Thread information structure. * @return Result code. - * @warning This is a privileged operation; in normal circumstances applications cannot use this function. */ Result threadResume(Thread* t);