diff options
author | Davee | 2018-10-31 07:28:57 +0000 |
---|---|---|
committer | devnoname120 | 2018-11-03 11:59:52 +0100 |
commit | 8cf5898db90a89f552a5dae19146faff31627b87 (patch) | |
tree | 1a0c0440c4129c2a6a6df3eb4c9d8b103551c388 /include | |
parent | switch naming ksceKernelProcessResume to ksceKernelResumeProcess (diff) | |
download | vds-libraries-8cf5898db90a89f552a5dae19146faff31627b87.tar.gz |
add ksceKernelChangeThreadSuspendStatus
This service allows you to change the status of a suspended thread. Most of the valid suspend bits are unknown, but some can be used to prevent the kernel rethrowing exceptions or pull threads into the running/ready state.
Diffstat (limited to 'include')
-rw-r--r-- | include/kernel/kernel/threadmgr.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/include/kernel/kernel/threadmgr.h b/include/kernel/kernel/threadmgr.h index 9f36da0..779da1e 100644 --- a/include/kernel/kernel/threadmgr.h +++ b/include/kernel/kernel/threadmgr.h @@ -908,6 +908,20 @@ typedef struct ThreadCpuRegisters */ int sceKernelGetThreadCpuRegisters(SceUID thid, ThreadCpuRegisters *registers); + +/** + * @brief Change the thread suspension status to another value. + * + * More research needs to be done to find out exactly what each status actually means. Some examples of useful scenarios: + * When handling an exception changing the status to 0x1002 (on a newly suspended thread) will stop the kernel rethrowing the same exception. + * When resuming a suspended thread changing the status to 2 will allow it to resume. + * + * @param[in] thid The thread to change. + * @param[in] status The new status for suspension. + * @return Zero on success, else < 0 on error. + */ +int sceKernelChangeThreadSuspendStatus(SceUID thid, int status); + #ifdef __cplusplus } #endif |