SceKernelThreadMgr: Difference between revisions

From Vita Development Wiki
Jump to navigation Jump to search
(→‎SceThreadmgrForDriver_B4A05763: Add description and prototype)
 
(376 intermediate revisions by 5 users not shown)
Line 1: Line 1:
PS Vita supports multi-threading in the non-secure kernel but not in the secure kernel. There is no user/POSIX threads; all threads are implemented as kernel threads and [[SceKernelThreadMgr#Processes|processes]] are functionally the same as threads. Threads can be specified to run on a specific core with the CPU affinity mask option when creating the thread and by default threads can run on any core. The kernel process can also run on any core. Additionally, the secure kernel can also run on any core.


PSVita supports multi-threading in the non-secure kernel but not the secure kernel. There is no user/POSIX threads; all threads are implemented as kernel threads and [[SceKernelThreadMgr#Processes|processes]] are the functionally the same as threads. Threads can be specified to run on a specific core with the CPU affinity mask option when creating the thread and by default, threads can run on any core. The kernel process can also run on any core. Additionally, the secure kernel can also run on any core.
== Module ==


== Module ==
This module exists only in non-secure world. The SELF can be found in <code> os0:kd/threadmgr.skprx</code>.
This module exists only in non-secure world. The SELF can be found in <code> os0:kd/threadmgr.skprx</code>.
=== Known NIDs ===


{| class="wikitable"
{| class="wikitable"
! Version !! Name !! World !! Privilege !! NID
! Version !! World !! Privilege
|-
|-
| 1.69 || SceKernelThreadMgr || Non-secure || Kernel || 0xA09CFA5C
| 0.990-3.65 || Non-secure || Kernel
|-
| 3.57 || SceKernelThreadMgr || Non-secure || Kernel || 0x21530BE9
|-
| 3.60 || SceKernelThreadMgr || Non-secure || Kernel || 0xF46ED7B2
|-
| 3.65 || SceKernelThreadMgr || Non-secure || Kernel || 0x23A1B482
|}
|}


== Libraries ==
== Libraries ==
This module is accessible by usermode.


=== Known NIDs ===
=== Known NIDs ===
Line 28: Line 19:
! Version !! Name !! World !! Visibility !! NID
! Version !! Name !! World !! Visibility !! NID
|-
|-
| 1.69-3.60 || [[SceKernelThreadMgr#SceThreadmgrForDriver|SceThreadmgrForDriver]] || Non-secure || Kernel || 0xE2C40624
| 0.920-3.60 || [[SceKernelThreadMgr#SceThreadmgrForDriver|SceThreadmgrForDriver]] || Non-secure || Kernel || 0xE2C40624
|-
|-
| 1.69-3.60 || [[SceKernelThreadMgr#SceThreadmgrForKernel|SceThreadmgrForKernel]] || Non-secure || Kernel || 0xA8CA0EFD
| 0.920-3.60 || [[SceKernelThreadMgr#SceThreadmgrForKernel|SceThreadmgrForKernel]] || Non-secure || Kernel || 0xA8CA0EFD
|-
|-
| 3.65-3.67 || [[SceKernelThreadMgr#SceThreadmgrForKernel|SceThreadmgrForKernel]] || Non-secure || Kernel || 0x7F8593BA
| 3.63-3.67 || [[SceKernelThreadMgr#SceThreadmgrForKernel|SceThreadmgrForKernel]] || Non-secure || Kernel || 0x7F8593BA
|-
|-
| 3.60 || [[SceKernelThreadMgr#SceThreadmgrCoredumpTime|SceThreadmgrCoredumpTime]] || Non-secure || User || 0x5E8D0E22
| 3.60 || [[SceKernelThreadMgr#SceThreadmgrCoredumpTime|SceThreadmgrCoredumpTime]] || Non-secure || User || 0x5E8D0E22
|-
|-
| 1.69-3.60 || [[SceKernelThreadMgr#SceThreadmgr|SceThreadmgr]] || Non-secure || User || 0x859A24B1
| 0.920-3.60 || [[SceKernelThreadMgr#SceThreadmgr|SceThreadmgr]] || Non-secure || User || 0x859A24B1
|}
|}


== Possible function names according to SceTestBridge ==
== Types ==
 
=== Class Types ===
 
<source lang="C">


<source>
// this is a generic type which is not specific for SceKernelThreadMgr. It is used in class creation in many modules.
sceTestBridgeThreadMgrCallCoredumpHandler -> ??
typedef struct SceObjectBase {
sceTestBridgeThreadMgrClearThreadMgrTestMode -> ??
uint32_t sce_reserved[2]; //[0] seems to be SceKernelObject*
sceTestBridgeThreadMgrDeleteStopThreadEvf -> ??
uint32_t data[];
sceTestBridgeThreadMgrExitDeleteThreadInSyscall -> sceKernelExitDeleteThread
} SceObjectBase;
sceTestBridgeThreadMgrFastMutexLockUnlock -> ??
sceTestBridgeThreadMgrFastMutexShowStat -> ??
sceTestBridgeThreadMgrFastMutexStart -> ??
sceTestBridgeThreadMgrFastMutexStop -> ??
sceTestBridgeThreadMgrGetLwMutexInfoAll -> looks like _sceKernelGetLwMutexInfoById
sceTestBridgeThreadMgrIsCoredumpHandlerRegistered
sceTestBridgeThreadMgrRegisterCoredumpHandler -> sceCoredumpRegisterCoredumpHandler
sceTestBridgeThreadMgrResumeThread -> sceKernelResumeThreadForVM
sceTestBridgeThreadMgrRunningInSyscall -> ??
sceTestBridgeThreadMgrSetAndDeleteSuspendThreadEvf -> ??
sceTestBridgeThreadMgrSetThreadMgrTestMode -> ??
sceTestBridgeThreadMgrSpawnPriorityThread -> ??
sceTestBridgeThreadMgrStopThread -> sceKernelStopThreadForKernel
sceTestBridgeThreadMgrSuspendThread -> sceKernelSuspendThreadForVM
sceTestBridgeThreadMgrUnregisterCoredumpHandler -> sceCoredumpUnregisterCoredumpHandler
sceTestBridgeThreadMgrWaitInSyscall -> ??
sceTestBridgeThreadMgrWaitInSyscall2 -> ??
sceTestbridgeApi -> ??
</source>


== SceThreadmgrForDriver ==
typedef struct _SceCacheObj {
  SceObjectBase base;
  int unk8;
  int unkC;
} SceCacheObj;


=== sceKernelWaitThreadEndCBForDriver ===
typedef struct _SceWaitableObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0x9EF4F62C
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
} SceWaitableObj;


=== sceKernelWaitThreadEndForDriver ===
typedef struct _SceFastMutexObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0x3E20216F
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceFastMutexObj;
 
typedef struct _SceAlarmObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceAlarmObj;
 
typedef struct _SceDelayObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceDelayObj;


=== sceKernelWaitEventFlagCBForDriver ===
typedef struct _SceLwMutexObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0x8A35F714
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int attr_20;
  int unk24;
  int unk28;
  int initCount_2C;
  SceKernelLwMutexWork* work_30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceLwMutexObj;


=== sceKernelWaitEventFlagForDriver ===
typedef struct _SceCondObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0x0C1D3F20
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int attr_20;
  int unk24;
  SceKernelCondOptParam* option_28;
  SceUID mutexId_2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceCondObj;


=== sceKernelWaitEventCBForDriver ===
typedef struct _SceEventFlagObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0x360C655C
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int attr_20;
  int unk24;
  int bits_28;
  int bits_2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceEventFlagObj;


=== sceKernelWaitEventForDriver ===
typedef struct _SceLwCondObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0xC529EA32
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceLwCondObj;


=== sceKernelUnregisterThreadEventHandlerForDriver ===
typedef struct _SceMsgPipeObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0x2C8ED6F0
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceMsgPipeObj;


=== sceKernelUnregisterCallbackFromEventAllForDriver ===
typedef struct _SceMutexObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0x8DADBD16
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int attr_20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int initCount_38;
  int initCount_3C;
  int unk40;
  int ceilingPriority_44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceMutexObj;


=== sceKernelUnregisterCallbackFromEventForDriver ===
typedef struct _SceRWLockObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0x2E48D81C
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceRWLockObj;


=== sceKernelUnlockWriteRWLockForDriver ===
typedef struct SceKernelSemaOptParam {
{| class="wikitable"
/** Size of the ::SceKernelSemaOptParam structure. */
! Version !! NID
SceSize size;
|-
} SceKernelSemaOptParam;
| 3.60 || 0x94A73797
|}


=== sceKernelUnlockReadRWLockForDriver ===
typedef struct _SceSemaObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0xDE1B9EEE
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int attr_20;
  int unk24;
  SceKernelSemaOptParam* option_28;
  int initVal_2C;
  int maxVal_30;
  int initVal_34;
  int unk_38;
  int unk_3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceSemaObj;


=== sceKernelTryLockWriteRWLockForDriver ===
typedef struct _SceSimpleEventObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0xA96F2E5A
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceSimpleEventObj;


=== sceKernelTryLockReadRWLockForDriver ===
typedef struct _SceTimerObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0xFC2B5A50
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceTimerObj;


=== sceKernelStopTimerForDriver ===
typedef struct _SceCpuTimerObj {
{| class="wikitable"
  SceObjectBase base;
! Version !! NID
  int unk8;
|-
  int unkC;
| 3.60 || 0x474F214B
  int unk10;
|}
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
} SceCpuTimerObj;


=== sceKernelStartTimerForDriver ===
typedef int (*SceKernelCallbackFunction)(int notifyId, int notifyCount, int notifyArg, void *common);
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x84C4CE4D
|}


=== sceKernelSignalSemaForDriver ===
typedef struct _SceCallbackObj
{| class="wikitable"
{
! Version !! NID
  SceObjectBase base;
|-
  int unk8;
| 3.60 || 0xD270498B
  int unkC;
|}
  int unk10;
  int unk14;
  int unk18;
  int attr_1C;
  int unk20;
  int unk24;
  SceKernelCallbackFunction func_28;
  int unk2C;
  int unk30;
  int unk34;
  void *arg_38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceCallbackObj;


=== sceKernelSignalCondAllForDriver ===
typedef struct _SceRegisterCallbackObj
{| class="wikitable"
{
! Version !! NID
  SceObjectBase base;
|-
  int unk8;
| 3.60 || 0x6EC78CD0
  int unkC;
|}
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
} SceRegisterCallbackObj;


=== sceKernelSetTimerTimeWideForDriver ===
typedef struct _SceThreadObj
{| class="wikitable"
{
! Version !! NID
  SceObjectBase base;
|-
  int unk8;
| 3.60 || 0x85195A16
  int unkC;
|}
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int attr_unk20;
  int unk_24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  SceUID pid_60;
  int unk_64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
  int unk80;
  int unk84;
  int unk88;
  int unk8C;
  int unk90;
  int unk94;
  int unk98;
  int unk9C;
  int unkA0;
  int unkA4;
  int unkA8;
  int unkAC;
  int unkB0;
  int unkB4;
  int unkB8;
  int unkBC;
  int unkC0;
  int unkC4;
  int unkC8;
  int attr_CC;
  int attr_D0;
  int priority_D4;
  int priority_D8;
  int unk_DC;
  int priority_E0;
  int unk_E4;
  int unkE8;
  int unkEC;
  int unkF0;
  int unkF4;
  int unkF8;
  int unkFC;
  int unk100;
  int unk104;
  int unk108;
  int unk10C;
  int unk110;
  int unk114;
  int unk118;
  int unk11C;
  int unk120;
  int unk124;
  int unk128;
  int unk12C;
  int unk130;
  int unk134;
  int unk138;
  int unk13C;
  int unk140;
  int unk144;
  int unk148;
  int unk14C;
  int unk150;
  int unk154;
  int unk158;
  int unk15C;
  int unk160;
  int unk164;
  int unk168;
  int unk16C;
  int unk170;
  int unk174;
  int unk178;
  int unk17C;
  int unk180;
  int unk184;
  int unk188;
  int unk18C;
  int unk190;
  int unk194;
  int unk198;
  int unk19C;
  int unk1A0;
  int unk1A4;
  int unk1A8;
  int unk1AC;
  int unk1B0;
  int unk1B4;
  int unk1B8;
  int unk1BC;
  int unk1C0;
  int unk1C4;
  int unk1C8;
  int unk1CC;
  int unk1D0;
  int unk1D4;
  int unk1D8;
  int unk1DC;
  int unk1E0;
  int unk1E4;
  int unk1E8;
  int unk1EC;
  int unk1F0;
  int unk1F4;
  int unk1F8;
  int unk1FC;
} SceThreadObj;


=== sceKernelSetEventFlagForDriver ===
typedef struct _SceThreadEventObj
{| class="wikitable"
{
! Version !! NID
  SceObjectBase base;
|-
  int unk8;
| 3.60 || 0xD4780C3E
  int unkC;
|}
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceThreadEventObj;


=== sceKernelSetEventForDriver ===
typedef struct _SceWorkQueueObj
{| class="wikitable"
{
! Version !! NID
  SceObjectBase base;
|-
  int unk8;
| 3.60 || 0x9EA3A45C
  int unkC;
|}
  int unk10;
  int unk14;
  int atomic_lock;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  unsigned long long obj_counter;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  SceUID sema_uid;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceWorkQueueObj;


=== sceKernelRunWithStackForDriver ===
typedef int (*SceKernelWorkQueueWorkFunction)(void *args);
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xE54FD746
|}


This takes a function and runs it exclusively on the current core on its own stack.
typedef struct _SceWorkTaskObj
{
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int atomic_lock;
  int unk1C;
  int unk20;
  int unk24;
  SceWorkQueueObj *queue_obj;
  int unk2C;
  int unk30;
  int unk34;
  SceUID task_uid;
  int unk3C;
  unsigned long long obj_counter;
  int unk48;
  int unk4C;
  int some_flag;
  int unk54;
  SceUID work_queue_uid;
  SceKernelWorkQueueWorkFunction func;
  void *args;
  SceUID current_thread_uid;
  int unk68;
  int unk6C;
  int unk70;
  SceUID pid;
  int unk78;
  int unk7C;
} SceWorkTaskObj;


<source lang="c">
typedef struct _SceExcpObj
// stack_size should be 0x2000
{
int sceKernelRunWithStackForDriver(int stack_size, void *func, void *args);
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceExcpObj;
 
typedef struct _SceEventObj
{
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
} SceEventObj;
</source>
</source>


=== sceKernelRegisterCallbackToEventForDriver ===
=== ThreadMgr types ===
{| class="wikitable"
 
! Version !! NID
For <code>SceProcessObj</code>, see [[SceProcessmgr#Types|SceProcessmgr page]].
|-
| 3.60 || 0x832A7E0C
|}


=== sceKernelPulseEventWithNotifyCallbackForDriver ===
<source lang="C">
{| class="wikitable"
typedef struct SceKernelFastMutex {
! Version !! NID
SceUInt8 data[0x40];
|-
} SceKernelFastMutex;
| 3.60 || 0x714A107A
|}


=== sceKernelPulseEventForDriver ===
typedef struct IntrRequest {
{| class="wikitable"
struct IntrRequest *next;
! Version !! NID
int type;      // In 0-3, 8-0x14, 0x18-0x19
|-
int from_cache; // 0 = alloc from heap, otherwise comes from Threadmgr link list
| 3.60 || 0x2427C81B
int padding;
|}
int arguments[4];
} IntrRequest;


=== sceKernelPollSemaForDriver ===
typedef struct ThreadMgrCpuCB { // size is 0x880-bytes
{| class="wikitable"
ThreadCB *pRunningThreadCB;
! Version !! NID
ThreadCB *pNextRunningThreadCB;
|-
int data_0x08;
| 3.60 || 0x4FDDFE24
struct {
|}
SceUID pid;
SceUID thid;
} current[2];
SceUInt32 currentThreadPriority;
struct {
ThreadCB *next;
ThreadCB *prev;
} standbyList;
SceKernelSpinlock lock;
int unk_2C[2];
ThreadCB *pIdleThreadCB; // idle thread for this CPU
SceUInt64 unk_38;
IntrRequest *intrRequestQueue;
int unk_44;
void *SwitchStackBlock_base; // 0x1000 size - idk what for
SceUInt8 unk_4C[0x14];
SceUInt32 priorityQueueBitmap[0x20 / sizeof(SceUInt32)];
struct {
ThreadCB *next;
ThreadCB *prev;
} priorityQueue[0x100];
} ThreadMgrCpuCB;


=== sceKernelPollEventFlagForDriver ===
typedef struct SceKernelThreadmgrPrivate { // size is 0x28B8-bytes
{| class="wikitable"
ThreadMgrCpuCB cpuCB[4];
! Version !! NID
SceKernelSpinlock threadMgrCBLock;
|-
SceUInt8 data[0x6B4];
| 3.60 || 0x76C6555B
} SceKernelThreadmgrPrivate;
|}


=== sceKernelNotifyCallbackForDriver ===
typedef struct SceKernelThreadStatus { // size is 0x100
{| class="wikitable"
int mode; // kernel:0, user:1
! Version !! NID
|-
| 3.60 || 0xC3E00919
|}


=== sceKernelGetTimerTimeWideForDriver ===
unsigned int reg[0xF];
{| class="wikitable"
 
! Version !! NID
unsigned int cpsr_kern;
|-
int unk_0x44; // maybe DACR for user
| 3.60 || 0xC1286004
int unk_0x48; // maybe DACR for kernel
|}
int unk_0x4C; // ex:0xF00000


=== sceKernelGetTimerBaseWideForDriver ===
int unk_0x50;
{| class="wikitable"
void *ptr_0x54;        // maybe user tls?
! Version !! NID
unsigned int TTBR1;
|-
unsigned int unk_0x5C; // maybe cpu ctx
| 3.60 || 0xA6D11DD3
|}


=== sceKernelGetThreadmgrUIDClassForDriver ===
int unk_0x60;
{| class="wikitable"
unsigned int ptr_0x64; // maybe paddr
! Version !! NID
int unk_0x68;
|-
int unk_0x6C;
| 3.60 || 0x0A20775A
|}


=== sceKernelGetThreadTLSAddrForDriver ===
int unk_0x70;
{| class="wikitable"
int unk_0x74;
! Version !! NID
int unk_0x78;
|-
int unk_0x7C;
| 3.60 || 0x66EEA46A
|}


=== sceKernelGetThreadStackFreeSizeForDriver ===
int unk_0x80;
{| class="wikitable"
int unk_0x84;
! Version !! NID
int unk_0x88;
|-
int unk_0x8C;
| 3.60 || 0x7B278A0B
|}


=== sceKernelGetThreadCpuAffinityMaskForDriver ===
int unk_0x90;
{| class="wikitable"
int unk_0x94;
! Version !! NID
int unk_0x98;
|-
int unk_0x9C;
| 3.60 || 0x83DC703D
|}


=== sceKernelGetCallbackCountForDriver ===
int unk_0xA0;
{| class="wikitable"
int unk_0xA4;
! Version !! NID
int unk_0xA8; // ex:0x8F5
|-
int unk_0xAC;
| 3.60 || 0x0892D8DF
|}


=== sceKernelEnqueueWorkQueueForDriver ===
unsigned int DFAR;
{| class="wikitable"
int unk_0xB4;
! Version !! NID
int unk_0xB8; // ex:0x2000, some size?
|-
int unk_0xBC; // ex:user(0xFF), kernel(0xF0)? maybe?
| 3.60 || 0xE50E1185
 
|}
const void *pc;
unsigned int cpsr;
unsigned int unk_0xC8; // fpcr?
int unk_0xCC;
 
int unk_0xD0;
int unk_0xD4;
int unk_0xD8;
int unk_0xDC;


=== sceKernelDeleteThreadForDriver ===
int unk_0xE0;
{| class="wikitable"
int unk_0xE4;
! Version !! NID
int unk_0xE8;
|-
int unk_0xEC;
| 3.60 || 0xAC834F3F
|}


=== sceKernelDeleteSemaForDriver ===
int unk_0xF0;
{| class="wikitable"
int unk_0xF4;
! Version !! NID
int unk_0xF8;
|-
int unk_0xFC;
| 3.60 || 0x16A35E58
} SceKernelThreadStatus;
|}


=== sceKernelDeleteMutexForDriver ===
typedef struct SceKernelThreadFloatRegister { // size is 0x100
{| class="wikitable"
union {
! Version !! NID
unsigned int s_reg_i[0x40];
|-
float        s_reg_f[0x40];
| 3.60 || 0x0A912340
uint64_t    d_reg_i[0x20];
|}
double      d_reg_f[0x20];
};
} SceKernelThreadFloatRegister;


<source lang="C">int sceKernelDeleteMutexForDriver(SceUID mutexid);</source>
typedef struct SceKernelThreadNeonInfo { // size is 0x120
SceKernelThreadFloatRegister float_register;
unsigned int fpscr;
unsigned int fpexc;
unsigned int unk_0x108;
unsigned int unk_0x10C;
unsigned int unk_0x110;
unsigned int unk_0x114;
unsigned int unk_0x118;
unsigned int unk_0x11C;
} SceKernelThreadNeonInfo;


=== sceKernelDeleteEventFlagForDriver ===
typedef struct SceKernelThreadRegisterInfo { // size is 0x60
{| class="wikitable"
unsigned int reg[0xD];
! Version !! NID
unsigned int unk_0x34;
|-
unsigned int unk_0x38; // ex:0xB90B45
| 3.60 || 0x71ECB352
unsigned int fpscr;
|}
unsigned int unk_0x40;
unsigned int unk_0x44;
unsigned int unk_0x48;
unsigned int unk_0x4C;
unsigned int sp;
unsigned int lr;
unsigned int pc;
unsigned int cpsr;
} SceKernelThreadRegisterInfo;


=== sceKernelCreateThreadForDriver ===
typedef struct SceKernelThreadInfoInternal { // size is 0x128
{| class="wikitable"
SceSize size;
! Version !! NID
SceUID thid_user;
|-
SceUID processId;
| 3.60 || 0xC6674E7D
|}


=== sceKernelCreateSimpleEventForDriver ===
// offset:0xC
{| class="wikitable"
char name[0x20];
! Version !! NID
int pad_0x2C;
|-
| 3.60 || 0x357A8177
|}


=== sceKernelCreateMutexForDriver ===
// offset:0x30
{| class="wikitable"
SceUInt attr;
! Version !! NID
int status;
|-
SceKernelThreadEntry entry;
| 3.60 || 0xFBAA026E
void *stack;
|}
 
// offset:0x40
SceSize        stackSize;
int unk_0x44;
int unk_0x48;
void *kernel_stack;
 
// offset:0x50
SceSize kernel_stack_size;
int unk_0x54;
int unk_0x58;
int unk_0x5C;


<source lang="C">int sceKernelCreateMutexForDriver(const char *name, SceUInt attr, int initCount, SceKernelMutexOptParam *option);</source>
// offset:0x60
int unk_0x60;
int unk_0x64;
int unk_0x68;
void *ptr_0x6C; // kernel tls?


=== sceKernelCreateEventFlagForDriver ===
// offset:0x70
{| class="wikitable"
int unk_0x70;
! Version !! NID
int unk_0x74;
|-
int initPriority;
| 3.60 || 0x4336BAA4
int currentPriority;
|}


=== sceKernelClearEventFlagForDriver ===
// offset:0x80
{| class="wikitable"
int initCpuAffinityMask;
! Version !! NID
int currentCpuAffinityMask;
|-
int unk_0x88;
| 3.60 || 0x4F1DA3BE
int currentCpuId;
|}


=== sceKernelClearEventForDriver ===
// offset:0x90
{| class="wikitable"
int lastExecutedCpuId;
! Version !! NID
int waitType; // maybe
|-
int unk_0x98;
| 3.60 || 0x9C335818
SceKernelSysClock runClocks;
|}


=== sceKernelChangeThreadPriorityForDriver ===
int exitStatus;
{| class="wikitable"
int unk_0xA8; // IsThreadDebugSuspended
! Version !! NID
SceUInt    intrPreemptCount;
|-
| 3.60 || 0x63DAB420
|}


=== sceKernelCancelCallbackForDriver ===
// offset:0xB0
{| class="wikitable"
SceUInt    threadPreemptCount;
! Version !! NID
SceUInt    threadReleaseCount;
|-
SceUID      fNotifyCallback;
| 3.60 || 0xC040EC1C
int        reserved;
|}


=== sceKernelCancelMsgPipeForDriver ===
SceKernelThreadStatus *pStatus;
{| class="wikitable"
SceKernelThreadNeonInfo *pNeonInfo;
! Version !! NID
SceKernelThreadRegisterInfo *pUserRegisterInfo; // Is it set only when cause(0x10009)?
|-
int unk_0xCC;
| 3.60 || 0x9D6A2311
|}


=== sceKernelCreateMsgPipeForDriver ===
void *pUserTLS;
{| class="wikitable"
int unk_0xD4;
! Version !! NID
int unk_0xD8;
|-
void *ptr_0xDC;
| 3.60 || 0xBF631145
|}


=== sceKernelDeleteMsgPipeForDriver ===
int unk_0xE0;
{| class="wikitable"
int unk_0xE4;
! Version !! NID
int unk_0xE8;
|-
int unk_0xEC;
| 3.60 || 0xB3453F88
|}


=== sceKernelSendMsgPipeVectorForDriver ===
int unk_0xF0;
{| class="wikitable"
int unk_0xF4;
! Version !! NID
int unk_0xF8;
|-
int unk_0xFC;
| 3.60 || 0x67DD3BAD
|}


=== sceKernelTryReceiveMsgPipeVectorForDriver ===
void *ptr_0x100;
{| class="wikitable"
int unk_0x104;
! Version !! NID
int unk_0x108;
|-
int unk_0x10C;
| 3.60 || 0xCE09221A
|}


=== sceKernelTrySendMsgPipeVectorForDriver ===
int unk_0x110;
{| class="wikitable"
int unk_0x114;
! Version !! NID
int unk_0x118;
|-
int unk_0x11C;
| 3.60 || 0x4CF1BE58
|}


=== sceKernelIsThreadDebugSuspendedForDriver ===
int unk_0x120;
{| class="wikitable"
int unk_0x124;
! Version !! NID
} __attribute__((packed)) SceKernelThreadInfoInternal;
|-
| 0.990-3.60 || 0xA0B1AB21
|}


It seems to be used to get the cause state at the time of process crash.
/** @name Basic thread functions
*/
/*@{*/


used By SceCoredump.
/**
* @defgroup Thread attributes
* Defining thread attributes
* Specified in attr argument of sceKernelCreateThread()
*/
/*@{*/
#define SCE_KERNEL_THREAD_ATTR_NOUSE_VFP (0x01000000U) /**< Do not use VFP */
#define SCE_KERNEL_THREAD_ATTR_VM                      (0x04000000U)          /**< (Unofficial name) Virtual Machine thread (can use ForVM functions on it) */
/*@}*/


<source lang="C">
/**
/**
  * @param[in]  thid        thread id (kernel uid)
  * @defgroup Thread priority
  * @return      suspend state, else < 0 on error.
  * Defining thread priorities
  */
  */
int sceKernelIsThreadDebugSuspendedForDriver(SceUID thid);
/*@{*/
</source>
#define SCE_KERNEL_HIGHEST_PRIORITY_USER (64) /**< Highest priority of user mode threads */
#define SCE_KERNEL_LOWEST_PRIORITY_USER (191) /**< Lowest priority of user mode threads */


=== sceKernelDebugResumeThreadForDriver ===
#define SCE_KERNEL_DEFAULT_PRIORITY ((SceInt32)0x10000100) /**< Default priority (whole system) */
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.60 || 0xEC8343DF
|}


=== sceKernelResumeThreadForDriver ===
#define SCE_KERNEL_INDIVIDUAL_QUEUE_HIGHEST_PRIORITY (64) /**< Highest priority of individual queue area */
{| class="wikitable"
#define SCE_KERNEL_INDIVIDUAL_QUEUE_LOWEST_PRIORITY (127) /**< Lowest priority of individual queue area */
! Version !! NID
#define SCE_KERNEL_COMMON_QUEUE_HIGHEST_PRIORITY (128) /**< Highest priority of common queue area */
|-
#define SCE_KERNEL_COMMON_QUEUE_LOWEST_PRIORITY (191) /**< Lowest priority of common queue area */
| 0.990-3.60 || 0xE3CE20AA
|}


=== sceKernelCreateRemoteThreadForDriver ===
/**
{| class="wikitable"
* Default priority (for users)
! Version !! NID
* The default priority for game applications is converted to 160 internally.
|-
* You can also specify the default value ± offset (SCE_KERNEL_DEFAULT_PRIORITY_USER-10).
| 0.990-3.60 || 0xC8E57BB4
*/
|}
#define SCE_KERNEL_DEFAULT_PRIORITY_USER SCE_KERNEL_DEFAULT_PRIORITY
 
=== sceKernelGetThreadIdListForDriver ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xEA7B8AEF
|}


This function is used to query and obtain the number of thread within a process.
#define SCE_KERNEL_CURRENT_THREAD_PRIORITY (0) /**< The priority of the currently executing thread */
/*@}*/


<source lang="C">
/**
/**
  * @brief      Retreive a list of all threads belonging to a process.
  * @defgroup Thread stack size
  * @param[in]  pid        The process to query.
  * Defining thread stack size
* @param[out]  ids        The list of thread ids. Can be NULL if output is not required.
* @param[in]  n          The max number of thread ids to copy out.
* @param[out]  copy_count  The number of thread ids copied.
* @return      The number of threads within the process, else < 0 on error.
  */
  */
int sceKernelGetThreadIdListForDriver(SceUID pid, SceUID *ids, int n, int *copy_count);
/*@{*/
</source>
#define SCE_KERNEL_STACK_SIZE_MAX SCE_KERNEL_1MiB /**< Maximum stack size */
#define SCE_KERNEL_STACK_SIZE_MIN SCE_KERNEL_4KiB /**< Minimum stack size */
 
#define SCE_KERNEL_STACK_SIZE_DEFAULT SCE_KERNEL_STACK_SIZE_MIN /**< Default stack size */
#define SCE_KERNEL_STACK_SIZE_DEFAULT_USER_MAIN (0x00040000) /**< Default stack size of user main thread (byte) */


=== sceKernelGetThreadCpuRegistersForDriver ===
#define SCE_KERNEL_THREAD_STACK_SIZE_MAX SCE_KERNEL_32MiB /**< Maximum stack size */
{| class="wikitable"
#define SCE_KERNEL_THREAD_STACK_SIZE_MIN SCE_KERNEL_4KiB /**< Minimum stack size */
! Version !! NID
|-
| 3.60 || 0x5022689D
|}


This function is used to get the state of the registers for a SUSPENDED thread. It returns the registers in a two part structure. It's uncertian what the difference is between the two parts. It seems like its a user/kernel separation, but it's uncertain. It could also be a current/exception difference, but it is unconvincing. In normal usage on a suspended thread it seems to be the user aspect that contains valid values. When you query a suspended thread that has no had the opportunity to start yet, the kernel side is filled.
#define SCE_KERNEL_THREAD_STACK_SIZE_DEFAULT SCE_KERNEL_THREAD_STACK_SIZE_MIN /**< Default stack size */
#define SCE_KERNEL_THREAD_STACK_SIZE_DEFAULT_USER_MAIN SCE_KERNEL_256KiB /**< Default stack size of user main thread (byte) */
/*@}*/


<source lang="C">
/**
/** Structure representing all ARM registers */
* @defgroup Thread state
typedef struct ArmCpuRegisters
* Defining thread state
{
*/
    uint32_t    r0;
/*@{*/
    uint32_t    r1;
#define SCE_KERNEL_THREAD_STATUS_RUNNING (0x00000001U) /**< RUNNING status */
    uint32_t    r2;
#define SCE_KERNEL_THREAD_STATUS_READY (0x00000002U) /**< READY status */
    uint32_t    r3;
#define SCE_KERNEL_THREAD_STATUS_STANDBY (0x00000004U) /**< STANDBY status */
    uint32_t    r4;
#define SCE_KERNEL_THREAD_STATUS_WAITING (0x00000008U) /**< WAITING status */
    uint32_t    r5;
#define SCE_KERNEL_THREAD_STATUS_DORMANT (0x00000010U) /**< DORMANT status */
    uint32_t    r6;
#define SCE_KERNEL_THREAD_STATUS_DELETED (0x00000020U) /**< DELETED status */
    uint32_t    r7;
#define SCE_KERNEL_THREAD_STATUS_DEAD (0x00000040U) /**< DEAD status */
    uint32_t    r8;
#define SCE_KERNEL_THREAD_STATUS_STAGNANT (0x00000080U) /**< STAGNANT status */
    uint32_t    r9;
#define SCE_KERNEL_THREAD_STATUS_SUSPENDED (0x00000100U) /**< SUSPENDED status */
    uint32_t    r10;
    uint32_t    r11;
    uint32_t    r12;
    uint32_t    sp;
    uint32_t    lr;
    uint32_t    pc;
    uint32_t    cpsr;
    uint32_t    unk;
} ArmCpuRegisters;


/** Structure containing a threads register states. */
#define SCE_KERNEL_THREAD_STATUS_MASK (0x0000ffffU) /**< Valid thread state mask */
typedef struct ThreadCpuRegisters
/*@}*/
{
    /** Set of registers used for user mode. */
    ArmCpuRegisters user;
    /** Set of registers used for kernel mode. */
    ArmCpuRegisters kernel;
} ThreadCpuRegisters;


/**
/**
  * @brief      Query the state of the registers for a suspended thread.
  * @defgroup Thread wait type
*
  * Defining thread wait types
* The registers returned are the user/kernel set for the requested thread.
* It's not certain that user/kernel is correct representation, instead it could be current/exception.
* The thread provided must be suspended for this function to succeed.
  *
* @param[in]  thid        The thread to query.
* @param[out]  registers  The set of registers belonging to the thread.
* @return      Zero on success, else < 0 on error.
  */
  */
int sceKernelGetThreadCpuRegistersForDriver(SceUID thid, ThreadCpuRegisters *registers);
/*@{*/
</source>
#if SCE_PSP2_SDK_VERSION < 0x01000000
#define SCE_KERNEL_WAITTYPE_DELAY (0x00000001) /**< Thread delay */
#define SCE_KERNEL_WAITTYPE_WAITTHEND (0x00000002) /**< End of thread */
#define SCE_KERNEL_WAITTYPE_EVENTFLAG (0x00000004) /**< Event flag */
#define SCE_KERNEL_WAITTYPE_MUTEX (0x00000008) /**< Mutex */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX (0x00000010) /**< Fast mutex */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_SPIN (0x00000020) /**< Fast mutex (spin) */
#define SCE_KERNEL_WAITTYPE_SEMAPHORE (0x00000040) /**< Semaphore */
#define SCE_KERNEL_WAITTYPE_EVENT (0x00000080) /**< Single event */
#define SCE_KERNEL_WAITTYPE_COND (0x00000100) /**< Condition variable */
#define SCE_KERNEL_WAITTYPE_MSG_PIPE (0x00000200) /**< Message pipe */
#define SCE_KERNEL_WAITTYPE_RW_LOCK (0x00000400) /**< Reader / writer lock */
#define SCE_KERNEL_WAITTYPE_SIGNAL (0x00000800) /**< Signal */
#define SCE_KERNEL_WAITTYPE_LW_MUTEX (0x00001000) /**< Lightweight mutex */
#define SCE_KERNEL_WAITTYPE_LW_COND (0x00002000) /**< Lightweight condition variable */
#define SCE_KERNEL_WAITTYPE_MP_EVENTS (0x00008000) /**< Event multiplexing */


=== sceKernelChangeThreadSuspendStatusForDriver ===
#define SCE_KERNEL_WAITTYPE_DELAY_CB (0x00010001) /**< With thread delay callback check */
{| class="wikitable"
#define SCE_KERNEL_WAITTYPE_WAITTHEND_CB (0x00010002) /**< With thread termination callback check */
! Version !! NID
#define SCE_KERNEL_WAITTYPE_EVENTFLAG_CB (0x00010004) /**< With event flag callback check */
|-
#define SCE_KERNEL_WAITTYPE_MUTEX_CB (0x00010008) /**< With mutex callback check */
| 3.60 || 0x04C6764B
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_CB (0x00010010) /**< With fast mutex callback check */
|}
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_SPIN_CB (0x00010020) /**< With fast mutex (spin) callback check */
#define SCE_KERNEL_WAITTYPE_SEMAPHORE_CB (0x00010040) /**< With semaphore callback check */
#define SCE_KERNEL_WAITTYPE_EVENT_CB (0x00010080) /**< With single event callback check */
#define SCE_KERNEL_WAITTYPE_COND_CB (0x00010100) /**< With condition variable callback check */
#define SCE_KERNEL_WAITTYPE_MSG_PIPE_CB (0x00010200) /**< With message pipe callback check */
#define SCE_KERNEL_WAITTYPE_RW_LOCK_CB (0x00010400) /**< With reader / writer lock callback check */
#define SCE_KERNEL_WAITTYPE_SIGNAL_CB (0x00010800) /**< With signal callback check */
#define SCE_KERNEL_WAITTYPE_LW_MUTEX_CB (0x00011000) /**< With lightweight mutex callback check */
#define SCE_KERNEL_WAITTYPE_LW_COND_CB (0x00012000) /**< With lightweight condition variable callback check */
#define SCE_KERNEL_WAITTYPE_MP_EVENTS_CB (0x00018000) /**< With event multiplexing callback check */
#else
#define SCE_KERNEL_WAITTYPE_DELAY (0x00000001U) /**< Thread delay */
#define SCE_KERNEL_WAITTYPE_WAITTHEND (0x00000002U) /**< End of thread */
#define SCE_KERNEL_WAITTYPE_SIGNAL (0x00000004U) /**< Signal */
#define SCE_KERNEL_WAITTYPE_WAITTHSUSPEND (0x00000008U) /**< Suspend thread */
#define SCE_KERNEL_WAITTYPE_EVENTFLAG (0x00000010U) /**< Event flag */
#define SCE_KERNEL_WAITTYPE_SEMAPHORE (0x00000020U) /**< Semaphore */
#define SCE_KERNEL_WAITTYPE_MUTEX (0x00000040U) /**< Mutex */
#define SCE_KERNEL_WAITTYPE_RW_LOCK (0x00000080U) /**< Reader / writer lock */
#define SCE_KERNEL_WAITTYPE_COND_SIGNAL (0x00000100U) /**< Condition variable (signal) */
#define SCE_KERNEL_WAITTYPE_COND_MUTEX (0x00000200U) /**< Condition variable (mutex) */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX (0x00001000U) /**< Fast mutex */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_SPIN (0x00002000U) /**< Fast mutex (spin) */
#define SCE_KERNEL_WAITTYPE_EVENT (0x00010000U) /**< Single event */
#define SCE_KERNEL_WAITTYPE_MP_EVENTS (0x00020000U) /**< Event multiplexing */
#define SCE_KERNEL_WAITTYPE_MSG_PIPE (0x00040000U) /**< Message pipe */
#define SCE_KERNEL_WAITTYPE_LW_MUTEX (0x00100000U) /**< Lightweight mutex */
#define SCE_KERNEL_WAITTYPE_LW_COND_SIGNAL (0x00200000U) /**< Lightweight condition variable (signal) */
#define SCE_KERNEL_WAITTYPE_LW_COND_LW_MUTEX (0x00400000U) /**< Lightweight condition variable (mutex) */


This function 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.
#define SCE_KERNEL_WAITTYPE_DELAY_CB (0x80000001U) /**< With thread delay callback check */
#define SCE_KERNEL_WAITTYPE_WAITTHEND_CB (0x80000002U) /**< With thread termination callback check */
#define SCE_KERNEL_WAITTYPE_SIGNAL_CB (0x80000004U) /**< With signal callback check */
#define SCE_KERNEL_WAITTYPE_WAITTHSUSPEND_CB (0x80000008U) /**< With suspend thread callback check */
#define SCE_KERNEL_WAITTYPE_EVENTFLAG_CB (0x80000010U) /**< With event flag callback check */
#define SCE_KERNEL_WAITTYPE_SEMAPHORE_CB (0x80000020U) /**< With semaphore callback check */
#define SCE_KERNEL_WAITTYPE_MUTEX_CB (0x80000040U) /**< With mutex callback check */
#define SCE_KERNEL_WAITTYPE_RW_LOCK_CB (0x80000080U) /**< With reader / writer lock callback check */
#define SCE_KERNEL_WAITTYPE_COND_SIGNAL_CB (0x80000100U) /**< With condition variable (signal) callback check */
#define SCE_KERNEL_WAITTYPE_COND_MUTEX_CB (0x80000200U) /**< With condition variable (mutex) callback check */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_CB (0x80001000U) /**< With fast mutex callback check */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_SPIN_CB (0x80002000U) /**< With fast mutex (spin) callback check */
#define SCE_KERNEL_WAITTYPE_EVENT_CB (0x80010000U) /**< With single event callback check */
#define SCE_KERNEL_WAITTYPE_MP_EVENTS_CB (0x80020000U) /**< With event multiplexing callback check */
#define SCE_KERNEL_WAITTYPE_MSG_PIPE_CB (0x80040000U) /**< With message pipe callback check */
#define SCE_KERNEL_WAITTYPE_LW_MUTEX_CB (0x80100000U) /**< With lightweight mutex callback check */
#define SCE_KERNEL_WAITTYPE_LW_COND_SIGNAL_CB (0x80200000U) /**< With lightweight condition variable (signal) callback check */
#define SCE_KERNEL_WAITTYPE_LW_COND_LW_MUTEX_CB (0x80400000U) /**< With lightweight condition variable (mutex) callback check */
#endif
/*@}*/


<source lang="C">
/**
/**
  * @brief       Change the thread suspension status to another value.
* @defgroup UID
* Thread ID definition
*/
/*@{*/
#define SCE_KERNEL_THREAD_ID_SELF (0) /**< UID representing own thread */
/*@}*/
 
/**
* @defgroup UID class
* Class definition of UID managed by thread manager (for User)
*/
/*@{*/
#define SCE_KERNEL_THREADMGR_UID_CLASS_THREAD (1) /**< Thread class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_SEMA (2) /**< Semaphore class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_EVENT_FLAG (3) /**< Event flag class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_MUTEX (4) /**< Mutex class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_COND (5) /**< Condition variable class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_TIMER (6) /**< Timer class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_MSG_PIPE (7) /**< Message pipe class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_CALLBACK (8) /**< Callback class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_THREAD_EVENT (9) /**< Thread event class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_LW_MUTEX (10) /**< Lightweight mutex class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_LW_COND (11) /**< Lightweight condition variable class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_RW_LOCK (12) /**< Reader / writer lock class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_SIMPLE_EVENT (13) /**< Simple event class */
/*@}*/
 
/**
* @defgroup CPU affinity mask
* CPU affinity mask definition
*/
/*@{*/
/**
  * @brief Default CPU affinity mask
  *
  *
  * More research needs to be done to find out exactly what each status actually means. Some examples of useful scenarios:
  * If the default CPU affinity mask is specified for a thread,
  * When handling an exception changing the status to 0x1002 (on a newly suspended thread) will stop the kernel rethrowing the same exception.
* the CPU affinity mask specified for the process to which it belongs is inherited.
  * When resuming a suspended thread changing the status to 2 will allow it to resume.
*/
#define SCE_KERNEL_THREAD_CPU_AFFINITY_MASK_DEFAULT (0)
/*@}*/
 
/**
* @brief Thread entry type
*
* Thread entry function type. Specify to sceKernelCreateThread().
* The argument block of the thread given by the argument of sceKernelStartThread() is copied onto the
  * stack of the started thread, and is received from the started thread through the argument of the entry function.
*
  * When a thread entry function is terminated with return, the thread terminates,
* and the return value of the entry function becomes the termination status of that thread.
* The thread exit status can be obtained with sceKernelWaitThreadEnd() or
* sceKernelGetThreadExitStatus() if the thread is not deleted.
  *
  *
  * @param[in]  thid    The thread to change.
  * @param argSize The argument size given by sceKernelStartThread() is passed.
  * @param[in]  status  The new status for suspension.
  * @param pArgBlock The address on the stack where the argument block given by sceKernelStartThread() is copied is passed.
  * @return     Zero on success, else < 0 on error.
  * @return Thread exit status
  */
  */
int sceKernelChangeThreadSuspendStatusForDriver(SceUID thid, int status);
typedef SceInt32 (*SceKernelThreadEntry)(SceSize argSize, void *pArgBlock);
</source>


=== sceKernelChangeActiveCpuMaskForDriver ===
/**
{| class="wikitable"
* @brief Stack change function type
! Version !! NID
*
|-
* The type of function to call when the stack changes. Specify to sceKernelCallWithChangeStack().
| 1.69-3.60 || 0x001173F8
*
|}
* With sceKernelCallWithChangeStack(), the stack is switched as soon as the stack change function is called.
* As soon as the stack change function ends with return, it returns to the original stack.
*
* @param pArg Arbitrary pointer to pass to stack change function
* @return Return value of sceKernelCallWithChangeStack()
*/
typedef SceInt32 (*SceKernelChangeStackFunction)(void *pArg);


=== sceKernelGetThreadCurrentPriorityForDriver ===
/**
{| class="wikitable"
* @brief Thread additional data
! Version !! NID
*
|-
* This structure is used to store additional data given when creating a thread with sceKernelCreateThread().
| 1.69-3.60 || 0x01414F0B
*
|}
* Provided for future expansion.
*
*/
typedef struct _SceKernelThreadOptParam { // Min size is 4 bytes. Max size is 0x14 bytes.
SceSize size; /**< Size of this structure (sizeof(SceKernelThreadOptParam)) */
SceUInt32 attr; /**< A bit pattern that specifies valid members in a structure */
SceUInt32          kStackMemType;
SceUInt32          uStackMemType;
SceUInt32          uTLSMemType;
SceUInt32          uStackMemid;
SceUInt32          data_0x18;
} SceKernelThreadOptParam;


=== sceKernelCreateCallbackForDriver ===
/**
{| class="wikitable"
* @brief Thread information structure
! Version !! NID
*
|-
* A structure used to store thread information with sceKernelGetThreadInfo().
| 1.69-3.60 || 0x1C41614C
*/
|}
typedef struct _SceKernelThreadInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelThreadInfo)) */
SceUID processId; /**< Process ID to which the thread belongs */
char name[SCE_UID_NAMELEN+1]; /**< Thread name */
SceUInt32 attr; /**< Thread attributes */
SceUInt32 status; /**< Thread state */
SceKernelThreadEntry entry; /**< Thread entry function address */
void *pStack; /**< Thread stack address (bottom) */
SceSize stackSize; /**< Thread stack size */
SceInt32 initPriority; /**< Thread initial priority */
SceInt32 currentPriority; /**< Thread current priority */
SceInt32 initCpuAffinityMask; /**< Thread initial CPU affinity mask */
SceInt32 currentCpuAffinityMask; /**< Thread current CPU affinity mask */
SceInt32 currentCpuId; /**< CPU number to which the thread currently belongs */
SceInt32 lastExecutedCpuId; /**< CPU number to which the thread was last executed */
SceUInt32 waitType; /**< Type when the thread is waiting */
SceUID waitId; /**< UID of the target synchronization object when the thread is waiting */
SceInt32 exitStatus; /**< Thread exit status */
SceKernelSysClock runClocks; /**< Time (in microseconds) executed since the thread was created */
SceUInt32 intrPreemptCount; /**< Number of times the thread was preempted by interrupt handling */
SceUInt32 threadPreemptCount; /**< Number of times the thread has been preempted by other thread operations */
SceUInt32 threadReleaseCount; /**< Number of times the thread has relinquished execution */
SceInt32 changeCpuCount; /**< Number of CPUs to which the thread is moved */
SceInt32 fNotifyCallback; /**< A flag indicating whether the thread is notified of the callback */
SceInt32 reserved; /**< Reserved area */
} SceKernelThreadInfo;
 
/**
* @brief Thread operating status on each CPU
*
* This structure is used by sceKernelGetThreadRunStatus() to obtain the operating status of threads on each CPU.
*
*/
typedef struct _SceKernelThreadRunStatus {
SceSize size; /**< Size of this structure (sizeof(SceKernelThreadRunStatus)) */
struct {
SceUID processId; /**< Process ID to which the running thread belongs */
SceUID threadId; /**< Thread ID being executed */
SceInt32 priority; /**< Priority of the running thread */
} cpuInfo[SCE_KERNEL_MAX_CPU]; /**< Information about individual CPUs */
} SceKernelThreadRunStatus;


=== sceKernelWaitThreadEndCB_089ForDriver ===
/**
{| class="wikitable"
* @brief System state
! Version !! NID
*
|-
* This structure is used to get the system status with sceKernelGetSystemInfo().
| 1.69 || 0x0373C5E3
*
|-
*/
| 3.60 || not present
typedef struct _SceKernelSystemInfo {
|}
SceSize size; /**< Size of this structure (sizeof(SceKernelSystemInfo)) */
SceUInt32 activeCpuMask; /**< Currently available CPU mask */
struct {
SceKernelSysClock idleClock; /**< Time when there was no thread to execute */
SceUInt32 comesOutOfIdleCount; /**< Number of transitions from a state where there is no thread to execute to another state */
SceUInt32 threadSwitchCount; /**< Number of context switches that occurred */
} cpuInfo[SCE_KERNEL_MAX_CPU]; /**< Information about individual CPUs */
} SceKernelSystemInfo;


=== sceKernelDeleteCallbackForDriver ===
/*@}*//* Basic thread functions */
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x3A7E17F6
|}


=== sceKernelExitThreadForDriver ===
/** @name VFP exception
{| class="wikitable"
*/
! Version !! NID
/*@{*/
|-
| 1.69-3.60 || 0x0C8A38E1
|}


=== sceKernelLockMutex_089ForDriver ===
/**
{| class="wikitable"
* @defgroup Defining VFP exceptions
! Version !! NID
* Bit pattern that specifies a VFP exception
|-
*/
| 1.69-3.60 || 0x16AC80C5
/*@{*/
|}
#define SCE_KERNEL_VFP_EXCEPTION_MASK_QCE (0x08000000U) /**< QCE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_IDE (0x00000080U) /**< IDE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_IXE (0x00000010U) /**< IXE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_UFE (0x00000008U) /**< UFE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_OFE (0x00000004U) /**< OFE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_DZE (0x00000002U) /**< DZE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_IOE (0x00000001U) /**< IOE flag interrupt enable */
 
/**
* Valid VFP exception mask
*/
#define SCE_KERNEL_VFP_EXCEPTION_MASK_ALL (SCE_KERNEL_VFP_EXCEPTION_MASK_QCE | SCE_KERNEL_VFP_EXCEPTION_MASK_IDE | \
SCE_KERNEL_VFP_EXCEPTION_MASK_IXE | SCE_KERNEL_VFP_EXCEPTION_MASK_UFE | \
SCE_KERNEL_VFP_EXCEPTION_MASK_OFE | SCE_KERNEL_VFP_EXCEPTION_MASK_DZE | \
SCE_KERNEL_VFP_EXCEPTION_MASK_IOE)
/*@}*/


<source lang="C">int sceKernelLockMutex_089ForDriver(SceUID mutex_id, int unk1, int unk2);</source>
/*@}*//* VFP exception */


=== sceKernelExitDeleteThreadForDriver ===
/** @name Common to synchronization
{| class="wikitable"
*/
! Version !! NID
/*@{*/
|-
| 1.69-3.60 || 0x1D17DECF
|}


=== sceKernelUnlockMutex_089ForDriver ===
/**
{| class="wikitable"
* @defgroup Synchronization object common attributes
! Version !! NID
* Attributes that can be set in common with synchronization objects
|-
*/
| 1.69-3.60 || 0x1E82E5D0
/*@{*/
|}
#define SCE_KERNEL_ATTR_SINGLE (0x00000000U) /**< Multiple threads cannot wait simultaneously (event flags only) */
#define SCE_KERNEL_ATTR_MULTI (0x00001000U) /**< Multiple threads can wait at the same time (event flags only) */
#define SCE_KERNEL_ATTR_TH_FIFO (0x00000000U) /**< Waiting thread queuing is FIFO */
#define SCE_KERNEL_ATTR_TH_PRIO (0x00002000U) /**< Queues for waiting threads are ordered by thread priority */
#define SCE_KERNEL_ATTR_MS_FIFO (0x00000000U) /**< Unused */
#define SCE_KERNEL_ATTR_MS_PRIO (0x00000000U) /**< Unused */
#define SCE_KERNEL_ATTR_OPENABLE (0x00000080U) /**< Object can be referenced */
/*@}*/


<source lang="C">int sceKernelUnlockMutex_089ForDriver(SceUID mutex_id, int unk1);</source>
/**
* @defgroup Referencing synchronization objects
* Definitions for references to synchronization objects
*/
/*@{*/
#define SCE_KERNEL_OPEN_LIMIT_MAX (127) /**< Maximum value that can be specified when limiting the number of simultaneous references of synchronization objects */
/*@}*/


=== sceKernelStartThread_089ForDriver ===
/*@}*//* Common to synchronization */
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x21F5419B
|}


=== sceKernelTryLockMutex_089ForDriver ===
/** @name Callback
{| class="wikitable"
*/
! Version !! NID
/*@{*/
|-
| 1.69-3.60 || 0x270993A6
|}


=== sceKernelGetSystemTimeLowForDriver ===
/**
{| class="wikitable"
* @brief Callback function type
! Version !! NID
*
|-
* After the callback function is notified by sceKernelNotifyCallback(), the callback function
| 1.69-3.60 || 0x47F6DE49
* confirms the notification by sceKernelCheckCallback() or executes a waiting function with a
|}
* function to check for notifications such as sceKernelWaitSemaCB().
* It is possible to delete your own registration by returning a value other than 0 as the return value of the callback function.
*
* Note
* - The callback function is called as the context of the thread that generated the callback.
*  In other words, the callback function can be called only by the callback generated by the own thread by the explicit callback
*  check by sceKernelCheckCallback() or the wait function with callback check such as sceKernelWaitSemaCB(). is. To receive
*  the callback notification, the thread that generated the callback must use sceKernelCheckCallback(), sceKernelWaitSemaCB(), etc.
* - The sceKernelCheckCallback() and sceKernelDeleteCallback() functions cannot be used inside the callback function.
*  In addition, if you call a wait function with CB such as sceKernelWaitSemaCB() function in the callback function, nesting occurs, causing a stack overflow.
*  Avoid processing that waits for more callbacks in the callback function.
*
* @param notifyId When a callback is notified from an event that registered a callback with sceKernelRegisterCallbackToEvent(),
* the identifier of the notification source event is passed.
* If not notified from the event, SCE_UID_INVALID_UID is passed.
* @param notifyCount Number of callback notifications until this callback function is executed is passed.
* @param notifyArg Argument given by sceKernelNotifyCallback() is passed.
* @param pCommon Argument given by sceKernelCreateCallback() is passed.
* @retval 0 Normal
* @retval Non-zero value Remove this callback
*/
typedef SceInt32 (*SceKernelCallbackFunction)(SceUID notifyId, SceInt32 notifyCount, SceInt32 notifyArg, void *pCommon);


=== sceKernelDelayThreadForDriver ===
/**
{| class="wikitable"
* @brief Callback state
! Version !! NID
*
|-
* This structure is used to get the callback status with sceKernelGetCallbackInfo().
| 1.69-3.60 || 0x4B675D05
*/
|}
typedef struct _SceKernelCallbackInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelCallbackInfo) */
SceUID callbackId; /**< Callback identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Name of the callback specified with sceKernelCreateCallback() */
SceUInt32 attr; /**< Callback attribute specified by sceKernelCreateCallback() */
SceUID threadId; /**< Identifier of the thread to which the callback belongs */
SceKernelCallbackFunction callbackFunc; /**< Callback function registered with sceKernelCreateCallback() */
SceUID notifyId; /**< Caller notification source identifier */
SceInt32 notifyCount; /**< Number of times sceKernelNotifyCallback() has been executed for this callback that is still delayed without the callback function being called */
SceInt32 notifyArg; /**< Argument given by sceKernelNotifyCallback() for this callback */
void *pCommon; /**< pCommon argument registered with sceKernelCreateCallback() */
} SceKernelCallbackInfo;


=== sceKernelGetMutexInfo_089ForDriver ===
/*@}*//* Callback */
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x69B78A12
|}


<source lang="C">int sceKernelGetMutexInfo_089ForDriver(SceUID mutexid, SceKernelMutexInfo *info);</source>
/** @name Thread event
*/
/*@{*/


=== sceKernelCancelMutex_089ForDriver ===
/**
{| class="wikitable"
* @defgroup Thread event handler type
! Version !! NID
* Defining thread events that trigger thread event handlers
|-
*/
| 1.69-3.60 || 0x7204B846
/*@{*/
|}
#define SCE_KERNEL_THREAD_EVENT_TYPE_START (0x04) /**< Thread start event */
#define SCE_KERNEL_THREAD_EVENT_TYPE_EXIT (0x08) /**< Thread end event */


=== sceKernelChangeCurrentThreadAttrForDriver ===
/**
{| class="wikitable"
* Valid thread event mask
! Version !! NID
*/
|-
#define SCE_KERNEL_THREAD_EVENT_TYPE_ALL (SCE_KERNEL_THREAD_EVENT_TYPE_START | SCE_KERNEL_THREAD_EVENT_TYPE_EXIT)
| 1.69-3.60 || 0x751C9B7A
/*@}*/
|}


=== sceKernelDelayThreadCBForDriver ===
/**
{| class="wikitable"
* @defgroup Thread specification for thread event handler
! Version !! NID
* Thread specification macro in sceKernelRegisterThreadEventHandler()
|-
*/
| 1.69-3.60 || 0x9C0180E1
/*@{*/
|}
#define SCE_KERNEL_THREAD_ID_USER ((SceUID)0xfffffff0) /**< Specify all user threads */
/*@}*/
 
/**
* @brief Thread event handler type
*
* Thread event handler type.
* @param type The thread event handler call cause is passed.
* - SCE_KERNEL_THREAD_EVENT_TYPE_START: thread started
* - SCE_KERNEL_THREAD_EVENT_TYPE_EXIT : thread terminated
* @param threadId Identifier of the thread that caused the thread event handler to be called is passed.
* @param arg Argument when calling the thread event handler is passed.
* @param pCommon pCommon specified in sceKernelRegisterThreadEventHandler() is passed as it is.
* @retval SCE_OK Success
* @retval Any value other than SCE_OK Remove this thread event handler
*/
typedef SceInt32 (*SceKernelThreadEventHandler)(SceInt32 type, SceUID threadId, SceInt32 arg, void *pCommon);


=== sceKernelLockMutexCB_089ForDriver ===
/*@}*//* Thread event */
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0xD06F2886
|}


=== sceKernelCheckWaitableStatusForDriver ===
/** @name An event
{| class="wikitable"
*/
! Version !! NID
/*@{*/
|-
| 1.69-3.60 || 0xD9BD74EB
|}


=== sceKernelCheckCallbackForDriver ===
/**
{| class="wikitable"
* @defgroup Event object attributes
! Version !! NID
* Definition of attributes to be specified when creating an event object
|-
*/
| 1.69-3.60 || 0xE53E41F6
/*@{*/
|}
#define SCE_KERNEL_EVENT_ATTR_MANUAL_RESET (0x00000000U) /**< Each bit of the event remains in the event notification state until it is manually transitioned to the event non notification state. */
#define SCE_KERNEL_EVENT_ATTR_AUTO_RESET (0x00000100U) /**< Each bit of the event automatically returns to the event non notification state when one waiting thread is woken up. */


=== sceKernelWaitThreadEnd_089ForDriver ===
#define SCE_KERNEL_ATTR_NOTIFY_CB_ALL (0x00000000U) /**< When an event is notified, all callbacks registered in the event object are notified. */
{| class="wikitable"
#define SCE_KERNEL_ATTR_NOTIFY_CB_WAKEUP_ONLY (0x00000800U) /**< When an event is notified, only the callback of the thread that is waiting for the event and wakes up among the callbacks registered in the event object is notified. */
! Version !! NID
/*@}*/
|-
| 1.69-3.60 || 0xF3489EF4
|}


=== sceKernelGetSystemTimeWideForDriver ===
/**
{| class="wikitable"
* @defgroup Event type
! Version !! NID
* Definition of event to be notified
|-
*/
| 1.69-3.60 || 0xF4EE4FA9
/*@{*/
|}
#define SCE_KERNEL_EVENT_IN (0x00000001U) /* Input event */
#define SCE_KERNEL_EVENT_OUT (0x00000002U) /* Output event */
#define SCE_KERNEL_EVENT_CREATE (0x00000004U) /* Generate event */
#define SCE_KERNEL_EVENT_DELETE (0x00000008U) /* Delete event */
#define SCE_KERNEL_EVENT_ERROR (0x00000010U) /* Error event */
#define SCE_KERNEL_EVENT_OPEN (0x00000100U) /* Reference event */
#define SCE_KERNEL_EVENT_CLOSE (0x00000200U) /* Reference end event */
#define SCE_KERNEL_EVENT_TIMER (0x00008000U) /* Timer event */
#define SCE_KERNEL_EVENT_DATA_EXIST (0x00010000U) /* Event that is notified when data exists in the message pipe buffer (level trigger) */


=== sceKernelGetThreadInfoForDriver ===
#define SCE_KERNEL_EVENT_USER_DEFINED_MASK (0xff000000U) /* User-defined event mask */
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.60 || 0x283807E2
|}


<source lang="c"> int sceKernelGetThreadInfoForDriver(SceUID thid, SceKernelThreadInfo *info)</source>
/*@}*/


=== sceKernelInitializeFastMutexForDriver ===
/**
{| class="wikitable"
* @brief Event object state
! Version !! NID
*
|-
* This structure is used to acquire the event object status with sceKernelGetEventInfo().
| 1.69-3.60 || 0xAF8E1266
*/
|}
typedef struct _SceKernelEventInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelEventInfo)) */
SceUID eventId; /**< Event object identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Name of the event specified when creating the event object */
SceUInt32 attr; /**< Event attributes specified when creating the event object */
SceUInt32 eventPattern; /**< Bit pattern of the current event */
SceUInt64 userData; /**< User data added to the last notified event */
SceUInt32 numWaitThreads; /**< Number of threads waiting for the event object */
SceInt32 reserved[1]; /**< Reserved area */
} SceKernelEventInfo;


<source lang="c"> int sceKernelInitializeFastMutexForDriver(void* mutex, const char* name, int unk0, int unk1)</source>
/**
* @defgroup Standby mode for event object multiple standby
* Definition of standby mode specified in sceKernelWaitMultipleEvents()
*/
/*@{*/
#define SCE_KERNEL_EVENT_WAIT_MODE_OR (0x00000001U) /**< Wait until one of the waits specified in the event wait condition list is met */
#define SCE_KERNEL_EVENT_WAIT_MODE_AND (0x00000002U) /**< Wait until all waits specified in the event wait condition list are satisfied */
/*@}*/


=== sceKernelLockFastMutexForDriver ===
/**
{| class="wikitable"
* @brief Structure for event wait condition list
! Version !! NID
*
|-
* Structure for event waiting condition list passed to sceKernelWaitMultipleEvents().
| 1.69-3.60 || 0x70627F3A
*/
|}
typedef struct _SceKernelWaitEvent {
SceUID eventId; /**< Event object identifier */
SceUInt32 eventPattern; /**< Pattern of events to wait */
} SceKernelWaitEvent;


<source lang="c"> int sceKernelLockFastMutexForDriver(void* mutex)</source>
/**
* @brief Structure for event waiting result acquisition list
*
* Structure for event waiting result acquisition list to be passed to sceKernelWaitMultipleEvents().
*/
typedef struct _SceKernelResultEvent {
SceUID eventId; /**< Event object identifier */
SceInt32 result; /**< Wait result (equivalent to return value of sceKernelWaitEvent()) */
SceUInt32 resultPattern; /**< Event pattern when waiting completes */
SceInt32 reserved[1]; /**< Reserved area */
SceUInt64 userData; /**< User data received when waiting completed */
} SceKernelResultEvent;


=== sceKernelUnlockFastMutexForDriver ===
/*@}*//* An event */
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0xDB395782
|}


<source lang="c"> int sceKernelUnlockFastMutexForDriver(void* mutex)</source>
/**
* @name Event flag
*/
/*@{*/


=== sceKernelDeleteFastMutexForDriver ===
/**
{| class="wikitable"
* @defgroup Event flag attributes
! Version !! NID
* Definition of attributes to be specified when generating eventflags
|-
*/
| 1.69-3.60 || 0x11FE84A1
/*@{*/
|}
#define SCE_KERNEL_EVF_ATTR_TH_FIFO SCE_KERNEL_ATTR_TH_FIFO /**< Event flag waiting thread queuing is FIFO */
#define SCE_KERNEL_EVF_ATTR_TH_PRIO SCE_KERNEL_ATTR_TH_PRIO /**< Event flag waiting threads are queued in order of thread priority. */
#define SCE_KERNEL_EVF_ATTR_SINGLE SCE_KERNEL_ATTR_SINGLE /**< Multiple threads cannot wait at the same time */
#define SCE_KERNEL_EVF_ATTR_MULTI SCE_KERNEL_ATTR_MULTI /**< Multiple threads can wait at the same time */
/*@}*/


<source lang="c"> int sceKernelDeleteFastMutexForDriver(void* mutex)</source>
/**
* @defgroup Event flag wait mode
* Definition of standby mode specified for eventflag standby
*/
/*@{*/
#define SCE_KERNEL_EVF_WAITMODE_AND (0x00000000U) /**< Waiting for AND */
#define SCE_KERNEL_EVF_WAITMODE_OR (0x00000001U) /**< Waiting for OR */
#define SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL (0x00000002U) /**< Clear all bits after waiting */
#define SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT (0x00000004U) /**< After waiting, clear the bit specified in bitPattern */
/*@}*/


=== sceKernelSignalCondToForDriver ===
/**
{| class="wikitable"
* @brief Additional data for event flag
! Version !! NID
*
|-
* This structure is used to store additional data to be given when creating an event flag with sceKernelCreateEventFlag().
| 1.69-3.60 || 0x61533DA9
*
|}
* 将来の拡張のために用意されています。
*
*/
typedef struct _SceKernelEventFlagOptParam {
SceSize size; /**< Size of this structure (sizeof(SceKernelEventFlagOptParam)) */
} SceKernelEventFlagOptParam;


<source lang="c"> int sceKernelSignalCondToForDriver(SceUID condId, SceUID threadId)</source>
/**
* @brief Event flag status
*
* This structure is used to acquire the event flag status with sceKernelGetEventFlagInfo().
*
*/
typedef struct _SceKernelEventFlagInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelEventFlagInfo)) */
SceUID evfId; /**< Event flag identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Name of the eventflag specified by sceKernelCreateEventFlag() */
SceUInt32 attr; /**< Event flag attribute specified by sceKernelCreateEventFlag() */
SceUInt32 initPattern; /**< Initial bit pattern of event flag */
SceUInt32 currentPattern; /**< Current bit pattern of event flag */
SceUInt32 numWaitThreads; /**< Number of threads waiting for an event */
} SceKernelEventFlagInfo;


=== sceKernelCreateCondForDriver ===
/*@}*//* Event flag */
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0xDB6CD34A
|}


<source lang="c"> SceUID sceKernelCreateCondForDriver(const char *name, SceUInt attr, SceUID mutexId, const SceKernelCondOptParam *option)</source>
/**
* @name Semaphore
*/
/*@{*/


=== sceKernelWaitCondForDriver ===
/**
{| class="wikitable"
* @defgroup Semaphore attributes
! Version !! NID
* Definition of attributes to be specified when creating a semaphore
|-
*/
| 1.69-3.60 || 0xCC7E027D
/*@{*/
|}
#define SCE_KERNEL_SEMA_ATTR_TH_FIFO SCE_KERNEL_ATTR_TH_FIFO /**< Semaphore waiting thread queuing is FIFO */
#define SCE_KERNEL_SEMA_ATTR_TH_PRIO SCE_KERNEL_ATTR_TH_PRIO /**< Semaphore waiting thread queuing is ordered by thread priority */
/*@}*/


<source lang="c"> int sceKernelWaitCondForDriver(SceUID condId, unsigned int *timeout)</source>
/**
* @brief Additional semaphore data
*
* This structure is used to store additional data given when creating a semaphore with sceKernelCreateSema().
*
* Provided for future expansion.
*
*/
typedef struct _SceKernelSemaOptParam {
SceSize size; /**< Size of this structure (sizeof(SceKernelSemaOptParam)) */
} SceKernelSemaOptParam;


=== sceKernelReceiveMsgPipeVectorForDriver ===
/**
{| class="wikitable"
* @brief Semaphore state
! Version !! NID
*
|-
* This structure is used to get the semaphore status with sceKernelGetSemaInfo().
| 1.69-3.60 || 0xDA1F256B
*
|}
*/
typedef struct _SceKernelSemaInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelSemaInfo)) */
SceUID semaId; /**< Semaphore identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Name of the semaphore specified by sceKernelCreateSema() */
SceUInt32 attr; /**< Semaphore attributes specified with sceKernelCreateSema() */
SceInt32 initCount; /**< Initial number of semaphores specified by sceKernelCreateSema() */
SceInt32 currentCount; /**< Current number of semaphore resources */
SceInt32 maxCount; /**< Maximum number of semaphore resources specified by sceKernelCreateSema() */
SceInt32 numWaitThreads; /**< Number of threads waiting for the semaphore */
} SceKernelSemaInfo;


=== sceKernelReceiveMsgPipeVectorCBForDriver ===
/*@}*//* Semaphore */
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0xDA5C9AC6
|}


=== sceKernelGetThreadIdForDriver ===
/**
{| class="wikitable"
* @name Mutex
! Version !! NID
*/
|-
/*@{*/
| 1.69-3.60 || 0x59D06540
|}


<source lang="c"> SceUID sceKernelGetThreadIdForDriver(void);</source>
/**
* @defgroup Mutex attribute
* Definition of attributes to be specified when creating a mutex
*/
/*@{*/
#define SCE_KERNEL_MUTEX_ATTR_TH_FIFO SCE_KERNEL_ATTR_TH_FIFO /**< Mutex wait thread queuing is FIFO */
#define SCE_KERNEL_MUTEX_ATTR_TH_PRIO SCE_KERNEL_ATTR_TH_PRIO /**< Mutes waiting threads are queued in order of thread priority */
#define SCE_KERNEL_MUTEX_ATTR_RECURSIVE (0x00000002U) /**< Mutex can be recursively locked */
#define SCE_KERNEL_MUTEX_ATTR_CEILING (0x00000004U) /**< Use the mutex priority sealing function */
/*@}*/


=== sceKernelDeleteCondForDriver ===
/**
{| class="wikitable"
* @brief Mutex additional data
! Version !! NID
*
|-
* This structure is used to store additional data given when creating mutexes with sceKernelCreateMutex().
| 1.69-3.60 || 0xAEE0D27C
*
|}
* Provided for future expansion.
*
*/
typedef struct _SceKernelMutexOptParam {
SceSize size; /**< Size of this structure (sizeof(SceKernelMutexOptParam)) */
SceInt32 ceilingPriority; /**< Priority ceiling priority */
} SceKernelMutexOptParam;
 
/**
* @brief Mutex state
*
* This structure is used to get the mutex status with sceKernelGetMutexInfo().
*
*/
typedef struct _SceKernelMutexInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelMutexInfo)) */
SceUID mutexId; /**< Mutex identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Name of the mutex specified by sceKernelCreateMutex() */
SceUInt32 attr; /**< Mutex attributes specified with sceKernelCreateMutex() */
SceInt32 initCount; /**< Initial lock count of mutex specified by sceKernelCreateMutex() */
SceInt32 currentCount; /**< Current number of mutex locks */
SceUID currentOwnerId; /**< Identifier of the thread that currently owns the mutex */
SceUInt32 numWaitThreads; /**< Number of threads waiting for the mutex */
SceInt32 ceilingPriority; /**< Priority ceiling priority (0 if priority ceiling function is not used) */
} SceKernelMutexInfo;


<source lang="c"> int sceKernelDeleteCondForDriver(SceUID cid);</source>
/*@}*//* Mutex */


=== sceKernelCreateSemaForDriver ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x30E93C31
|}


<source lang="C">
/**
/**
* Creates a new semaphore
  * @name Lightweight mutex
*
  * @par Example:
* @code
* int semaid;
* semaid = sceKernelCreateSemaForDriver("MySema", 0, 1, 1, 0);
* @endcode
*
* @param name - Specifies the name of the sema
* @param attr - Sema attribute flags (normally set to 0)
* @param initVal - Sema initial value
* @param maxVal - Sema maximum value
* @param option - Sema options (normally set to 0)
* @return A semaphore id
  */
  */
SceUID sceKernelCreateSemaForDriver(const char *name, SceUInt attr, int initVal, int maxVal, SceKernelSemaOptParam *option);
/*@{*/
</source>


=== sceKernelWaitSemaCBForDriver ===
/**
{| class="wikitable"
* @defgroup Lightweight mutex attribute
! Version !! NID
* Definition of attributes to be specified when creating a lightweight mutex
|-
*/
| 1.69-3.60 || 0xF55E4D86
/*@{*/
|}
#define SCE_KERNEL_LW_MUTEX_ATTR_TH_FIFO SCE_KERNEL_ATTR_TH_FIFO /**< Lightweight mutex wait thread queuing is FIFO */
#define SCE_KERNEL_LW_MUTEX_ATTR_TH_PRIO SCE_KERNEL_ATTR_TH_PRIO /**< Queues for lightweight mutex wait threads are ordered by thread priority */
#define SCE_KERNEL_LW_MUTEX_ATTR_RECURSIVE (0x00000002U)          /**< Lightweight mutex can be recursively locked */
/*@}*/


<source lang="C">
/**
/**
  * Lock a semaphore
  * @brief Light mutex work area
*
* A structure used to store work areas used by lightweight mutexes.
* The lightweight mutex work area must be reserved in the user memory space.
* All operations on the lightweight mutex are performed via the SceKernelLwMutexWork structure.
  *
  *
  * @par Example:
  * Since the SceKernelLwMutexWork structure is used as a work area by the kernel, after creating
  * @code
  * a lightweight mutex with sceKernelCreateLwMutex(), the user program must not directly
  * sceKernelWaitSemaCBForDriver(sema_id, 1, 0);
  * reference / manage the contents until it is deleted with sceKernelDeleteLwMutex(). The address cannot be moved.
* @endcode
  *
  *
  * @param sema_id - The sema id returned from ::sceKernelCreateSemaForDriver
  * The SceKernelLwMutexWork structure must be arranged with 8-byte alignment on the memory.
* @param signal - The value to wait for (i.e. if 1 then wait till reaches a signal state of 1)
* @param timeout - Timeout in microseconds (assumed).
  *
  *
* @return < 0 on error.
  */
  */
int sceKernelWaitSemaCBForDriver(SceUID sema_id, int signal, SceUInt *timeout);
typedef struct _SceKernelLwMutexWork {
</source>
SceInt64 data[4]; /**< Light mutex work area */
} SceKernelLwMutexWork;


=== sceKernelWaitSemaForDriver ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x3C8B55A9
|}
<source lang="C">
/**
/**
  * Lock a semaphore
  * @brief Additional data for lightweight mutex
  *
  *
  * @par Example:
  * This structure is used to store additional data given when creating a lightweight mutex with sceKernelCreateLwMutex().
* @code
* sceKernelWaitSemaForDriver(sema_id, 1, 0);
* @endcode
  *
  *
  * @param sema_id - The sema id returned from ::sceKernelCreateSemaForDriver
  * Provided for future expansion.
* @param signal - The value to wait for (i.e. if 1 then wait till reaches a signal state of 1)
* @param timeout - Timeout in microseconds (assumed).
  *
  *
* @return < 0 on error.
  */
  */
int sceKernelWaitSemaForDriver(SceUID sema_id, int signal, SceUInt *timeout);
typedef struct _SceKernelLwMutexOptParam {
</source>
SceSize size; /**< Size of this structure (sizeof(SceKernelLwMutexOptParam)) */
} SceKernelLwMutexOptParam;


=== sceKernelSignalCondForDriver ===
/**
{| class="wikitable"
* @brief Light mutex state
! Version !! NID
*
|-
* A structure used to obtain the status of a lightweight mutex with sceKernelGetLwMutexInfo().
| 1.69-3.60 || 0xAC616150
*
|}
*/
typedef struct _SceKernelLwMutexInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelLwMutexInfo)) */
SceUID uid; /**< Lightweight mutex identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Name of the mutex specified by sceKernelCreateLwMutex() */
SceUInt32 attr; /**< Mutex attributes specified with sceKernelCreateLwMutex() */
SceKernelLwMutexWork *pWork; /**< Mutex work area specified by sceKernelCreateLwMutex() */
SceInt32 initCount; /**< Initial number of lw mutex locks specified by sceKernelCreateLwMutex() */
SceInt32 currentCount; /**< Current lock count of lightweight mutex */
SceUID currentOwnerId; /**< Identifier of the thread that currently owns the lightweight mutex */
SceUInt32 numWaitThreads; /**< Number of threads waiting for the lightweight mutex */
} SceKernelLwMutexInfo;


<source lang="C">int sceKernelSignalCondForDriver(SceUID condId);</source>
/*@}*//* Lightweight mutex */


=== sceKernelChangeThreadCpuAffinityMaskForDriver ===
/** @name Condition variable
{| class="wikitable"
*/
! Version !! NID
/*@{*/
|-
| 1.69-3.60 || 0x6D0733A8
|}


<code>derived from sceKernelChangeThreadCpuAffinityMask</code>
/**
* @defgroup Condition variable attributes
* Defining attributes to be specified when creating a condition variable
*/
/*@{*/
#define SCE_KERNEL_COND_ATTR_TH_FIFO SCE_KERNEL_ATTR_TH_FIFO /**< Condition variable wait thread queuing is FIFO */
#define SCE_KERNEL_COND_ATTR_TH_PRIO SCE_KERNEL_ATTR_TH_PRIO /**< Condition variable wait thread queuing is in order of thread priority */
/*@}*/


<source lang="C">
/**
// uid - thread uid
* @brief Additional data for condition variables
int sceKernelChangeThreadCpuAffinityMaskForDriver(SceUID uid, int mask);
*
</source>
* This structure is used to store additional data given when creating a condition variable with sceKernelCreateCond().
*
* Provided for future expansion.
*
*/
typedef struct _SceKernelCondOptParam {
SceSize size; /**< Size of this structure (sizeof(SceKernelMutexOptParam)) */
} SceKernelCondOptParam;


=== sceKernelSetPermissionForDriver ===
/**
{| class="wikitable"
* @brief Condition variable state
! Version !! NID
*
|-
* This structure is used to acquire the condition variable status with sceKernelGetCondInfo().
| 1.69-3.60 || 0x02EEDF17
*
|}
*/
typedef struct _SceKernelCondInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelCondInfo)) */
SceUID condId; /**< Condition variable identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Condition variable name specified in sceKernelCreateCond() */
SceUInt32 attr; /**< Condition variable attribute specified in sceKernelCreateCond() */
SceUID mutexId; /**< Mutex associated with the condition variable specified by sceKernelCreateCond() */
SceUInt32 numWaitThreads; /**< Number of threads waiting for the condition variable */
} SceKernelCondInfo;


<source lang="C">
/*@}*//* Condition variable */
// return value is previous value
int sceKernelSetPermissionForDriver(int value);
</source>


=== sceKernelGetProcessIdForDriver ===
/** @name Lightweight condition variable
{| class="wikitable"
*/
! Version !! NID
/*@{*/
|-
| 1.69-3.60 || 0x9DCB4B7A
|}


Returns the process ID.
/**
* @defgroup Lightweight condition variable attributes
* Definition of attributes to be specified when creating lightweight condition variables
*/
/*@{*/
#define SCE_KERNEL_LW_COND_ATTR_TH_FIFO SCE_KERNEL_ATTR_TH_FIFO /**< Lightweight condition variable waiting thread queuing is FIFO */
#define SCE_KERNEL_LW_COND_ATTR_TH_PRIO SCE_KERNEL_ATTR_TH_PRIO /**< Lightweight condition variable waiting thread queuing is ordered by thread priority */
/*@}*/


<source lang="C">SceUID sceKernelGetProcessIdForDriver(void);</source>
/**
* @brief Lightweight condition variable work area
*
* A structure used to store the work area used by the lightweight condition variable.
* The work area for lightweight condition variables must be allocated in the user memory space.
* All operations on lightweight condition variables are done via the SceKernelLwCondWork structure.
*
* Since the SceKernelLwCondWork structure is used as a work area by the kernel, once a
* lightweight condition variable is created with sceKernelCreateLwCond(), the contents must not be directly
* referenced / operated by the user program until it is deleted with sceKernelDeleteLwCond(). The address cannot be moved.
*/
typedef struct _SceKernelLwCondWork {
SceInt32 data[4]; /**< Lightweight condition variable work area */
} SceKernelLwCondWork;


=== sceKernelSetProcessIdToTLSForDriver ===
/**
{| class="wikitable"
* @brief Additional data for lightweight condition variables
! Version !! NID
*
|-
* This structure is used to store additional data given when creating a lightweight condition variable with sceKernelCreateLwCond().
| 1.69-3.60 || 0x0486F239
*
|}
* Provided for future expansion.
*
*/
typedef struct _SceKernelLwCondOptParam {
SceSize size; /**< Size of this structure (sizeof(SceKernelLwCondOptParam)) */
} SceKernelLwCondOptParam;


Sets given pid into TLS.
/**
* @brief Lightweight condition variable state
*
* sceKernelGetLwCondInfo() is a structure used to obtain the status of a lightweight condition variable.
*
*/
typedef struct _SceKernelLwCondInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelLwCondInfo)) */
SceUID uid; /**< Lightweight condition variable identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Name of the lightweight condition variable specified with sceKernelCreateLwCond() */
SceUInt32 attr; /**< Attributes of lightweight condition variable specified by sceKernelCreateLwCond() */
SceKernelLwCondWork *pWork; /**< Work area of lightweight condition variable specified by sceKernelCreateLwCond() */
SceKernelLwMutexWork *pLwMutex; /**< Lightweight mutex work area associated with the lightweight condition variable specified by sceKernelCreateLwCond() */
SceUInt32 numWaitThreads; /**< Number of threads waiting for lightweight condition variables */
} SceKernelLwCondInfo;


<source lang="C">
/*@}*//* Lightweight condition variable */
// return value is previous value
SceUID sceKernelSetProcessIdToTLSForDriver(SceUID pid);
</source>


=== sceKernelGetProcessIdFromTLSForDriver ===
/** @name Timer
{| class="wikitable"
*/
! Version !! NID
/*@{*/
|-
| 1.69-3.60 || 0xFA54D49A
|}


Gets pid from TLS.
/**
* @defgroup Type of timer event notification
* Defining timer event notification types
*/
/*@{*/
#define SCE_KERNEL_TIMER_TYPE_SET_EVENT (0) /**< Timer is notified by set type event */
#define SCE_KERNEL_TIMER_TYPE_PULSE_EVENT (1) /**< Timer is notified by pulse type event */
/*@}*/


<source lang="C">
/**
// return value is previous value
* @brief Additional data for timer
SceUID sceKernelGetProcessIdFromTLSForDriver();
*
</source>
* This structure is used to store additional data given when a timer is created with sceKernelCreateTimer().
*
* Provided for future expansion.
*/
typedef struct _SceKernelTimerOptParam {
SceSize size; /**< Size of this structure (sizeof(SceKernelTimerOptParam)) */
} SceKernelTimerOptParam;


=== sceKernelRegisterTimerForDriver ===
/**
{| class="wikitable"
* @brief Timer information
! Version !! NID
*
|-
* Timer information acquisition structure.
| 3.60 || 0xC58DF384
*/
|}
typedef struct _SceKernelTimerInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelTimerInfo)) */
SceUID timerId; /**< Timer identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Timer name specified by sceKernelCreateTimer() */
SceUInt32 attr; /**< Timer attribute specified by sceKernelCreateTimer() */
SceInt32 fActive; /**< Timer start flag (if 1, counter is running) */
SceKernelSysClock baseTime; /**< Timer reference process time */
SceKernelSysClock currentTime; /**< Timer current time */
SceKernelSysClock schedule; /**< Timer next scheduled event notification time (if an event is set) */
SceKernelSysClock interval; /**< Timer event notification interval specified by sceKernelSetTimerEvent() */
SceInt32 type; /**< Timer event notification type specified by sceKernelSetTimerEvent() */
SceInt32 fRepeat; /**< Timer repeat flag specified by sceKernelSetTimerEvent() (1: periodic timer) */
SceUInt32 numWaitThreads; /**< Number of threads waiting for timer */
SceInt32 reserved[1]; /**< Reserved area */
} SceKernelTimerInfo;


// seen: unk = 2 so maybe UDCD bus
/*@}*//* Timer */


<source lang="C">int sceKernelRegisterTimerForDriver(char *name, void *function, int unk);</source>
/** @name Simple event
*/
/*@{*/


== SceThreadmgrForKernel ==
/**
* @brief Simple event additional data
*
* This structure is used to store additional data given when a simple event is generated with sceKernelCreateSimpleEvent().
*
* Provided for future expansion.
*
*/
typedef struct _SceKernelSimpleEventOptParam {
SceSize size; /**< Size of this structure (sizeof(SceKernelSimpleEventOptParam)) */
} SceKernelSimpleEventOptParam;


=== sceKernelSignalSemaForKernel ===
/*@}*//* Simple event */
{| class="wikitable"
 
! Version !! NID
/** @name Message pipe
|-
*/
| 3.60 || 0xD270498B
/*@{*/
|}
 
/**
* @defgroup Message pipe attributes
* Defining message pipe attributes
*/
/*@{*/
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_PRIO_S (0x00000001U) /**< The queue of the message sender's waiting thread is FIFO */
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_PRIO_R (0x00000002U) /**< The queue of the message receiver standby thread is FIFO */
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_PRIO (SCE_KERNEL_MSG_PIPE_ATTR_TH_PRIO_S | SCE_KERNEL_MSG_PIPE_ATTR_TH_PRIO_R) /**< Message queuing wait thread queuing is FIFO */


=== sceKernelDeleteEventFlagForKernel ===
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_FIFO_S (0x00000004U) /**< Queues for waiting threads on the message sender side are in order of thread priority */
{| class="wikitable"
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_FIFO_R (0x00000008U) /**< Queues for message receiver standby threads are ordered by thread priority */
! Version !! NID
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_FIFO (SCE_KERNEL_MSG_PIPE_ATTR_TH_FIFO_S | SCE_KERNEL_MSG_PIPE_ATTR_TH_FIFO_R) /**< Queues for message send / receive waiting threads are ordered by thread priority */
|-
/*@}*/
| 0.990 || 0x71ECB352
|-
| 3.60 || not present but exists in ForDriver
|}


=== sceKernelDeleteSemaForKernel ===
/**
{| class="wikitable"
* @defgroup Message pipe wait mode
! Version !! NID
* Message pipe wait mode
|-
*/
| 0.990-3.60 || 0x16A35E58
/*@{*/
|}
#define SCE_KERNEL_MSG_PIPE_MODE_ASAP (0x00000000U) /**< Complete if you can send and receive even 1 byte of data */
#define SCE_KERNEL_MSG_PIPE_MODE_FULL (0x00000001U) /**< Complete when all data of the specified size has been sent and received */


=== sceKernelStopThreadForKernel ===
#define SCE_KERNEL_MSG_PIPE_MODE_WAIT (0x00000000U) /**< Block threads until send / receive processing is complete (synchronous mode) */
{| class="wikitable"
#define SCE_KERNEL_MSG_PIPE_MODE_DONT_WAIT (0x00000010U) /**< Issue a send / receive request and return immediately (asynchronous mode) */
! Version !! NID
|-
| 0.990-3.60 || 0x150AEF74
|}


=== sceKernelSuspendThreadForKernel ===
#define SCE_KERNEL_MSG_PIPE_MODE_DONT_REMOVE (0x00000100U) /**< Do not delete received data from the pipe (peak processing) */
{| class="wikitable"
/*@}*/
! Version !! NID
|-
| 0.990-3.60 || 0xAEEE955F
|}


=== sceKernelCpuScanThreadForProcessmgrForKernel ===
/**
{| class="wikitable"
* @defgroup Message pipe type
! Version !! NID
* Defining the pipe buffer type for a message pipe
|-
* Specify which budget to get memory from
| 0.990-3.60 || 0x3B4B8293
*/
|}
/*@{*/
#define SCE_KERNEL_MSG_PIPE_TYPE_USER_MAIN (64) /**< User main area */
#define SCE_KERNEL_MSG_PIPE_TYPE_USER_CDRAM (66) /**< User CDRAM area (not mounted) */
/*@}*/
 
/**
* @defgroup Message pipe optional attributes
* Macros that can be specified in the attr member of SceKernelMsgPipeOptParam
*/
/*@{*/
#define SCE_KERNEL_MSG_PIPE_OPT_ATTR_OPEN_LIMITATION (0x00000100U) /**< Specify openLimit */
/*@}*/


=== sceKernelGetProcessIdForKernel ===
/**
{| class="wikitable"
* Buffer information for message pipe discontinuous data transmission / reception
! Version !! NID
*
|-
* sceKernelSendMsgPipeVector(), sceKernelSendMsgPipeVectorCB(), sceKernelTrySendMsgPipeVector(),
| 1.69-3.60 || 0x9DCB4B7A
* sceKernelReceiveMsgPipeVector(), sceKernelReceiveMsgPipeVectorCB(), sceKernelTryReceiveMsgPipeVector()
|}
* are used to transmit and receive data.
* This structure specifies a single contiguous memory range.
*
* Specify the base address in pBase.
* Specify the size (byte) in bufSize.
*
*/
typedef struct _SceKernelMsgPipeVector {
void *pBase; /**< Buffer base address */
SceSize bufSize; /**< Buffer size */
} SceKernelMsgPipeVector;


Returns the process ID.
/**
* @brief Message pipe status
*
* This structure is used to get the message pipe status with sceKernelGetMsgPipeInfo().
*
*/
typedef struct _SceKernelMsgPipeInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelMsgPipeInfo)) */
SceUID msgPipeId; /**< Message pipe identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Name of the message pipe specified with sceKernelCreateMsgPipe() */
SceUInt32 attr; /**< Message pipe attribute specified by sceKernelCreateMsgPipe() */
SceSize bufferSize; /**< Total size of message pipe pipe buffer (bytes) */
SceSize freeSize; /**< Empty pipe buffer size of message pipe (byte) */
SceUInt32 numSendWaitThreads; /**< Number of threads waiting to be sent */
SceUInt32 numReceiveWaitThreads; /**< Number of threads waiting to receive */
} SceKernelMsgPipeInfo;


<source lang="C">SceUID sceKernelGetProcessIdForKernel(void);</source>
/**
* @brief Additional data for the message pipe
*
* This structure is used to store additional data given when creating a message pipe with sceKernelCreateMsgPipe().
*
* Specify a bit pattern that represents a valid member in attr.
* The following macros can be specified by logical OR.
* - SCE_KERNEL_MSG_PIPE_OPT_ATTR_OPEN_LIMITATION: Specify the maximum number that can be referenced simultaneously with sceKernelOpenMsgPipe() (openLimit)
*
* In openLimit, the maximum number of simultaneous references by sceKernelOpenMsgPipe() can be specified.
* The maximum number that can be specified is (0..SCE_KERNEL_OPEN_LIMIT_MAX (127)).
* If not specified, the number of simultaneous references is not limited.
*
* Be sure to call sizeof(SceKernelMsgPipeOptParam) for size.
*
*/
typedef struct _SceKernelMsgPipeOptParam {
SceSize size; /**< Size of this structure (sizeof(SceKernelMsgPipeOptParam)) */
SceUInt32 attr; /**< A bit pattern that specifies a valid member of a structure */
SceInt32 reserved[2]; /**< Reserved area */
SceUInt32 openLimit; /**< Maximum number that can be referenced simultaneously with sceKernelOpenMsgPipe() (0..SCE_KERNEL_OPEN_LIMIT_MAX (127)) can be specified. If not specified, unlimited */
} SceKernelMsgPipeOptParam;


=== sceKernelChangeActiveCpuMaskForKernel ===
/*@}*//* Message pipe */
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x001173F8
|-
| 3.60 || not present, but exists in ForDriver
|}


=== sceKernelGetThreadCurrentPriorityForKernel ===
/** @name Reader / writer lock
{| class="wikitable"
*/
! Version !! NID
/*@{*/
|-
 
| 1.69 || 0x01414F0B
/**
|-
* @defgroup Reader / writer lock attribute
| 3.60 || not present, but exists in ForDriver
* Definition of attributes to be specified when creating a reader / writer lock
|}
*/
/*@{*/
#define SCE_KERNEL_RW_LOCK_ATTR_TH_FIFO SCE_KERNEL_ATTR_TH_FIFO /**< Reader / writer lock waiting thread queuing is FIFO */
#define SCE_KERNEL_RW_LOCK_ATTR_TH_PRIO SCE_KERNEL_ATTR_TH_PRIO /**< Queued reader / writer lock waiting threads are ordered by thread priority */
#define SCE_KERNEL_RW_LOCK_ATTR_RECURSIVE (0x00000002U) /**< Reader / writer lock can be recursively locked */
#define SCE_KERNEL_RW_LOCK_ATTR_CEILING (0x00000004U) /**< Use the priority sealing function when the reader / writer lock is locked (not implemented) */
/*@}*/


=== sceKernelWaitThreadEndCB_089ForKernel ===
/**
{| class="wikitable"
* @defgroup Reader / writer lock cancel flag
! Version !! NID
* Definition of flag to be specified when canceling reader / writer lock
|-
*/
| 1.69 || 0x0373C5E3
/*@{*/
|-
#define SCE_KERNEL_RW_LOCK_CANCEL_WITH_WRITE_LOCK (1) /**< Acquire light lock atomically after cancellation */
| 3.60 || not present
/*@}*/
|}


=== sceKernelExitThreadForKernel ===
/**
{| class="wikitable"
* @brief  Additional data for reader / writer lock
! Version !! NID
*
|-
* This structure is used to store additional data given when creating a reader / writer lock with sceKernelCreateRWLock().
| 1.69 || 0x0C8A38E1
*
|-
* Provided for future expansion.
| 3.60 || not present, but exists in ForDriver
*
|}
*/
typedef struct _SceKernelRWLockOptParam {
SceSize size; /**< Size of this structure (sizeof(SceKernelRWLockOptParam)) */
} SceKernelRWLockOptParam;


=== sceKernelLockMutex_089ForKernel ===
/**
{| class="wikitable"
* @brief  Reader / writer lock status
! Version !! NID
*
|-
* This structure is used to acquire the reader / writer lock status with sceKernelGetRWLockInfo().
| 1.69-3.60 || 0x16AC80C5
*
|}
*/
typedef struct _SceKernelRWLockInfo {
SceSize size; /**< Size of this structure (sizeof(SceKernelRWLockInfo)) */
SceUID rwLockId; /**< Reader / writer lock identifier */
char name[SCE_UID_NAMELEN + 1]; /**< Name of reader / writer lock specified by sceKernelCreateRWLock() */
SceUInt32 attr; /**< Reader / writer lock attribute specified by sceKernelCreateRWLock() */
SceInt32 lockCount; /**< Current number of locks of reader / writer lock */
SceUID writeOwnerId; /**< Identifier of the thread that currently holds (owns) the reader / writer lock */
SceUInt32 numReadWaitThreads; /**< Number of threads waiting for reader / writer lock with read lock */
SceUInt32 numWriteWaitThreads; /**< Number of threads waiting for reader / writer lock with write lock */
} SceKernelRWLockInfo;


<source lang="C">int sceKernelLockMutex_089ForKernel(SceUID mutex_id, int unk1, int unk2);</source>
/*@}*//* Reader / writer lock */


=== sceKernelExitDeleteThreadForKernel ===
typedef struct SceKernelWorkqueueCreateInfo { // size is 0x40-bytes
{| class="wikitable"
SceSize size;
! Version !! NID
SceUID wqueue_id;
|-
char name[0x20];
| 1.69 || 0x1D17DECF
SceInt32 unk_0x28;
|-
SceInt32 unk_0x2C;
| 3.60 || not present, but exists in ForDriver
SceInt32 unk_0x30;
|}
SceInt32 unk_0x34;
SceInt32 unk_0x38;
SceInt32 unk_0x3C;
} SceKernelWorkqueueCreateInfo;
 
typedef struct SceKernelWorktaskCreateInfo { // size is 0x34-bytes
SceSize size;
SceUID wtask_id;
char name[0x20];
const void *func;
void *argp;
SceUID wqueue_id;
} SceKernelWorktaskCreateInfo;


=== sceKernelUnlockMutex_089ForKernel ===
typedef struct SceThreadmgrForDriver_E605ED7A_t { // size is 0x58-bytes
{| class="wikitable"
SceSize size;
! Version !! NID
SceUID wtaskId;
|-
SceUID processId;
| 1.69-3.60 || 0x1E82E5D0
SceInt32 unk_0x0C;
|}
char name[0x20];
const void *func;
void *argp;
SceUID wqueue_id;
SceUID unk_0x3C;
SceUID unk_0x40;
void *unk_0x44;
SceInt32 unk_0x48;
SceInt32 unk_0x4C;
SceUID processId2;
SceInt32 unk_0x54;
} SceThreadmgrForDriver_E605ED7A_t;


<source lang="C">int sceKernelUnlockMutex_089ForKernel(SceUID mutex_id, int unk1);</source>


=== sceKernelStartThread_089ForKernel ===
#define SCE_KERNEL_WORKQUEUE_HAS_THREAD_NUMBER    (1 << 0)
{| class="wikitable"
#define SCE_KERNEL_WORKQUEUE_HAS_PRIORITY          (1 << 1)
! Version !! NID
#define SCE_KERNEL_WORKQUEUE_HAS_STACK_SIZE        (1 << 2)
|-
#define SCE_KERNEL_WORKQUEUE_HAS_CPU_AFFINITY_MASK (1 << 3)
| 1.69 || 0x21F5419B
|-
| 3.60 || not present, but exists in ForDriver
|}


=== sceKernelTryLockMutex_089ForKernel ===
typedef struct SceKernelCreateWorkQueueParam {
{| class="wikitable"
SceSize;
! Version !! NID
SceUInt32 nThread;
|-
SceUInt32 initPriority;
| 1.69 || 0x270993A6
SceSize stackSize;
|-
SceUInt32 cpuAffinityMask;
| 3.60 || not present, but exists in ForDriver
} SceKernelCreateWorkQueueParam;
|}
</source>


=== sceKernelDelayThreadForKernel ===
== Possible function names according to SceTestBridge ==
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x4B675D05
|-
| 3.60 || not present, but exists in ForDriver
|}


=== sceKernelGetMutexInfo_089ForKernel ===
<source>
{| class="wikitable"
sceTestBridgeThreadMgrCallCoredumpHandler -> ??
! Version !! NID
sceTestBridgeThreadMgrClearThreadMgrTestMode -> sceKernelClearThreadMgrTestModeForKernel
sceTestBridgeThreadMgrDeleteStopThreadEvf -> ??
sceTestBridgeThreadMgrExitDeleteThreadInSyscall -> sceKernelExitDeleteThread
sceTestBridgeThreadMgrFastMutexLockUnlock -> ??
sceTestBridgeThreadMgrFastMutexShowStat -> ??
sceTestBridgeThreadMgrFastMutexStart -> ??
sceTestBridgeThreadMgrFastMutexStop -> ??
sceTestBridgeThreadMgrGetLwMutexInfoAll -> looks like _sceKernelGetLwMutexInfoById
sceTestBridgeThreadMgrIsCoredumpHandlerRegistered
sceTestBridgeThreadMgrRegisterCoredumpHandler -> sceCoredumpRegisterCoredumpHandler
sceTestBridgeThreadMgrResumeThread -> sceKernelResumeThreadForVM
sceTestBridgeThreadMgrRunningInSyscall -> ??
sceTestBridgeThreadMgrSetAndDeleteSuspendThreadEvf -> ??
sceTestBridgeThreadMgrSetThreadMgrTestMode -> sceKernelSetThreadMgrTestModeForKernel
sceTestBridgeThreadMgrSpawnPriorityThread -> ??
sceTestBridgeThreadMgrStopThread -> sceKernelStopThreadForKernel
sceTestBridgeThreadMgrSuspendThread -> sceKernelSuspendThreadForVM
sceTestBridgeThreadMgrUnregisterCoredumpHandler -> sceCoredumpUnregisterCoredumpHandler
sceTestBridgeThreadMgrWaitInSyscall -> ??
sceTestBridgeThreadMgrWaitInSyscall2 -> ??
sceTestbridgeApi -> ??
</source>
 
== Thread Priority ==
 
Basic Priority Table
 
{| class="wikitable"
! General Priority !! Internal Priority !! Description
|-
| 0 || - || Current running thread priority
|-
|-
| 1.69 || 0x69B78A12
| < 0x100000E0 || - || Error with 0x80028023
|-
| >= 0x10000120 || - || Error with 0x80028023
|-
| 0x10000100 || 0xA0 || For GAME Process without some thread attr
|-
| 0x10000100 || 0x60 || For GAME Process
|-
| 0x10000100 || 0x60 || For MiniApp Process
|-
| 0x10000100 || 0x60 || For Shell Process
|-
|-
| 3.60 || not present, but exists in ForDriver
| 0x10000100 || 0x60 || For Kernel Process
|}
|}


=== sceKernelCancelMutex_089ForKernel ===
Internal Priority Table
 
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Allowed Internal Priority !! Description
|-
| 0x40 - 0xBF || For User GAME Process
|-
| 0x40 - 0xFB || For User non-GAME Process (Kernel, shell, miniapp)
|-
|-
| 1.69 || 0x7204B846
| 1 - 0xFB || For non-User Process
|}
|}


=== sceKernelChangeCurrentThreadAttrForKernel ===
== Threadmgr SGI events ==
 
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Event !! Description
|-
| 0x0 || changeThreadCpuAffinityMask
|-
|-
| 1.69 || 0x751C9B7A
| 0x1 || changeThreadPriority
|-
| 0x2 || changeThreadPriorityAndCpuAffinityMask
|-
| 0x3 || atomic core orr
|-
| 0x4-0x7 || N/A
|-
| 0x8 || debugSuspendThread
|-
| 0x9 || stopThread
|-
| 0xA || suspendThreadForVM
|-
| 0xB || setCpuRegisterForDebugger
|-
| 0xC || getCpuRegisterForDebugger
|-
| 0xD || setVfpRegisterForDebugger
|-
| 0xE || getVfpRegisterForDebugger
|-
| 0xF || N/A
|-
| 0x10 || pmonThreadChangeEnableCounter
|-
| 0x11 || pmonThreadSetCounter
|-
| 0x12 || pmonThreadGetCounter
|-
| 0x13 || some msgpipe function?
|-
| 0x14 || some msgpipe function?
|-
| 0x15-0x17 || N/A
|-
| 0x18 || DTrace XCall Async
|-
| 0x18 || DTrace XCall Sync
|}
|}


=== sceKernelDelayThreadCBForKernel ===
== SceThreadmgrForDriver ==
 
=== sceKernelSetEventWithNotifyCallbackForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9C0180E1
| 0.995 || not present. Present in ForKernel. [[SceKernelThreadMgr#sceKernelSetEventWithNotifyCallbackForKernel]]
|-
| 3.60 || 0xB7DF3EDF
|}
|}


=== sceKernelLockMutexCB_089ForKernel ===
=== sceKernelRegisterKTLSForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD06F2886
| 0.990.000-3.740.011 || 0xB645C7EF
|}
|}


=== sceKernelCheckWaitableStatusForKernel ===
Temp name was sceKernelAllocateKTLSForDriver. <code>sceKernelAllocateKTLS</code> symbol is present in old SCE modules but <code>sceKernelRegisterKTLS</code> is more suitable and used more often.
{| class="wikitable"
 
! Version !! NID
<source lang="C">
|-
typedef void SceKernelKTLSFreeCallback(void* ktls_data, void* pUserdata);
| 1.69 || 0xD9BD74EB
 
|}
/**
* @brief Registers a kernel TLS slot.
*
* There are 8 KTLS slots available. However, slot 0 and 1 cannot be accessed via the KTLS API.
* Thus, only 6 slots can be registered and used by external callers.
*
* @param[in]      size            Size of the KTLS data to allocate
* @param[in,opt]  freeCb          Callback invoked when the KTLS data of a thread is freed (during thread termination)
* @param[in,opt]  pUserdata      User-provided data passed to freeCb
* @retval (>=0) KTLS index of the registered slot
* @retval      (<0) Error code
* @note If no free KTLS slots are available, SCE_KERNEL_ERROR_KERNEL_TLS_FULL (0x80028081) is returned.
*/
SceInt32 sceKernelRegisterKTLSForDriver(SceSize size, SceKernelKTLSFreeCallback* freeCb, void* pUserdata);
</source>


=== sceKernelCheckCallbackForKernel ===
=== sceKernelUnregisterKTLSForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xE53E41F6
| 0.990.000-3.740.011 || 0x8C3C1F78
|}
|}


=== sceKernelWaitThreadEnd_089ForKernel ===
<source lang="C">
{| class="wikitable"
/**
! Version !! NID
* @brief Unregisters a Kernel TLS slot.
|-
*
| 1.69 || 0xF3489EF4
* @param[in]  index          KTLS index returned by sceKernelRegisterKTLS()
|}
* @retval SCE_OK Success
* @retval      (<0) Error code
* @note A KTLS index can only be unregistered if no thread has KTLS data allocated for this index.
*      Otherwise, error SCE_KERNEL_ERROR_KERNEL_TLS_BUSY (0x80028083) is returned.
*/
SceInt32 sceKernelUnregisterKTLSForDriver(SceInt32 index);
</source>


=== sceKernelCreateMutexForKernel ===
=== SceThreadmgrForDriver_89CA5698 ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0xFBAA026E
| 0.990.000-3.740.011 || 0x89CA5698
|}
|}


<source lang="C">int sceKernelCreateMutexForKernel(const char *name, SceUInt attr, int initCount, SceKernelMutexOptParam *option);</source>
<source lang="C">
/**
* @brief Returns the pointer to KTLS data from a slot.
*
* @param[in]  index          KTLS index returned by sceKernelRegisterKTLS()
* @param[in]  thid            ID of the thread whose KTLS data should be retrieved, or 0 for the current thread
* @param[in]  allocate        Controls behavior if the KTLS data for the slot has not been allocated yet for this thread:
*                                SCE_TRUE => allocate and return the new allocation
*                                SCE_FALSE => don't allocate; return NULL
* @retval non-NULL        Pointer to the KTLS data
* @retval      NULL            Error / KTLS data is not allocated (if allocate == SCE_FALSE)
*/
ScePVoid SceThreadmgrForDriver_89CA5698(SceInt32 index, SceUID thid, SceBool allocate);
</source>


=== sceKernelDeleteMutexForKernel ===
=== SceThreadmgrForDriver_3A72C6D8 ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x0A912340
| 0.990.000-3.740.011 || 0x3A72C6D8
|}
|}


<source lang="C">int sceKernelDeleteMutexForKernel(SceUID mutexid);</source>
Wrapper for [[SceKernelThreadMgr#SceThreadmgrForDriver_89CA5698]].


=== sceKernelRunWithStackForKernel ===
<source lang="C">
ScePVoid SceThreadmgrForDriver_3A72C6D8(SceInt32 index) {
    return SceThreadmgrForDriver_89CA5698(index, 0, SCE_TRUE);
}
</source>


=== sceKernelPMonSetControlRegisterForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0xE54FD746
| 0.990.000-2.060.011 || not present. Present in [[#SceThreadmgrForKernel]].
|-
| 2.100.081-3.740.011 || 0x1AAFA818
|}
|}


This takes a function and runs it exclusively on the current core on its own stack.
=== sceKernelPMonSetUserEnableRegisterForDriver ===
 
<source lang="c">
// stack_size should be 0x2000
int sceKernelRunWithStackForKernel(int stack_size, void *func, void *args);
</source>
 
=== Run Exclusively 2 ===
 
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 3.60 || 0xA2C801A5
| 0.990.000-2.060.011 || not present. Present in [[#SceThreadmgrForKernel]].
|-
| 2.100.081-3.740.011 || 0x5053B005
|}
|}


<source lang="c">
=== sceKernelWaitThreadEndCBForDriver ===
// stack_size should be 0x2000
int run_exclusively_2(int stack_size, void *func, void *args);
</source>
 
=== sceKernelWaitSemaCBForKernel ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 3.60 || 0x3c8b55a9
| 3.60 || 0x9EF4F62C
|}
|}


=== sceKernelGetFaultingProcessForKernel ===
=== sceKernelWaitThreadEndForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 3.60 || 0xD8B9AC8D
| 3.60 || 0x3E20216F
|-
| 3.65-3.67 || 0x6C1F092F
|}
|}


=== SceThreadmgrForKernel_E0833C77 ===
=== sceKernelWaitEventFlagCBForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 3.57 || not present, added on 3.60
| 3.60 || 0x8A35F714
|-
| 3.60 || 0xE0833C77
|}
|}


== SceThreadmgr ==
=== sceKernelWaitEventFlagForDriver ===
 
=== sceKernelUnregisterThreadEventHandler ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 3.60 || 0x2C8ED6F0
| 0.931-3.60 || 0x0C1D3F20
|}
|}


=== sceKernelChangeActiveCpuMask ===
<source lang="C">
/**
* @brief Event flag wait
*
* This system call waits for the event flag specified by evfId to be set according to the wait release condition specified by waitMode.
* If the event flag specified by evfId already satisfies the wait release condition specified by waitMode,
* the issuing thread continues execution without transitioning to the waiting state (WAITING).
*
* When SCE_KERNEL_EVF_WAITMODE_AND is specified for waitMode, it waits until all the bits specified by bitPattern become 1.
* If SCE_KERNEL_EVF_WAITMODE_OR is specified for waitMode, wait until one of the bits specified in bitPattern becomes 1.
* If SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL is additionally specified for waitMode, all the eventflag bits
* are cleared to 0 when the wait release condition is satisfied and this thread is released.
* If SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT is additionally specified for waitMode, the bit specified
* by bitPattern is cleared to 0 when the wait release condition is satisfied and this thread is released.
*
* The event flag value is returned to pResultPat in the following cases. NULL can be specified if no value is required.
* - If the wait release condition is satisfied (SCE_OK is returned),
*  the event flag value before clearing by specifying SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL,
*  SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT is returned immediately after the condition is satisfied.
* - After exiting the wait state, the event flag value just before exiting from the wait state is returned when
*  exiting except when the wait release condition is satisfied (when SCE_KERNEL_ERROR_WAIT_CANCEL,
*  SCE_KERNEL_ERROR_WAIT_DELETE, SCE_KERNEL_ERROR_WAIT_TIMEOUT errors are returned).
*  When canceling with sceKernelCancelEventFlag(), the eventflag value set at the time of cancellation is returned.
*
* When pTimeout is specified, the timeout operation specified in microseconds is set.
* If pTimeout is NULL, timeout operation is not performed.
* Note that if pTimeout is specified, the value pointed to by pTimeout is updated when the system call ends.
* If the condition is met within the time, it is updated with the remaining time. If not established,
* the value pointed to by pTimeout is updated with 0. In this case, error SCE_KERNEL_ERROR_WAIT_TIMEOUT is returned.
*
* Another thread cannot execute sceKernelWaitEventFlag() and sceKernelPollEventFlag() for an event flag with
* the SCE_KERNEL_EVF_ATTR_SINGLE attribute that already has a waiting thread.
* In this case, an error is returned immediately to the thread that executed sceKernelWaitEventFlag() or sceKernelPollEventFlag() later.
*
* If multiple threads are waiting for an event flag with the SCE_KERNEL_EVF_ATTR_MULTI attribute, a thread queue is created.
* In this case, a single sceKernelSetEventFlag() may release the waiting status of multiple threads.
*
* In the case of the event flag of the SCE_KERNEL_EVF_ATTR_TH_FIFO attribute, the thread queue is
* arranged in the order in which it waits first.
* In the event flag of the SCE_KERNEL_EVF_ATTR_TH_PRIO attribute, the thread with the highest
* priority among the waiting threads starts first and is arranged in the order of thread priority.
*
* If there is a thread with SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL specified or SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT specified in the
* queue and the wait release condition for that thread is satisfied, the event flag is cleared at the same time as the wait release.
* Threads that are lined up behind the thread that has specified SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL or SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT
* will see the event flag after being cleared, so the wait may not be released.
*
* @param evfId Specifies the identifier of the event flag to wait for.
* @param bitPattern Specify the comparison value with the eventflag.
* @param waitMode Specifies the wait mode. Specify one of the following:
*                      - SCE_KERNEL_EVF_WAITMODE_AND: Waiting for AND
*                      - SCE_KERNEL_EVF_WAITMODE_OR : Wait for OR
*                      In addition, you can optionally add either of the following specifications as a logical sum.
*                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL: After waiting, clear all bits
*                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT: After waiting, clear the bit specified in bitPattern
* @param pResultPat Specifies a pointer to the SceUInt32 type variable that receives the eventflag value when waiting is established.
*                      If NULL is specified, the event flag value is not received.
* @param pTimeout Specify a pointer to the SceUInt32 type variable that stores the upper limit (microseconds) of the waiting time.
*                      If NULL is specified, wait indefinitely. When the wait condition is satisfied, the remaining time is returned.
* @retval SCE_OK Success
* @retval (<0) Error code
*/
SceInt32 sceKernelWaitEventFlagForDriver(SceUID evfId, SceUInt32 bitPattern, SceUInt32 waitMode, SceUInt32 *pResultPat, SceUInt32 *pTimeout);
</source>
 
=== sceKernelWaitEventCBForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x001173F8
| 3.60 || 0x360C655C
|}
|}


=== sceKernelGetThreadCurrentPriority ===
=== sceKernelWaitEventForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x01414F0B
| 3.60 || 0xC529EA32
|}
|}


=== sceKernelWaitThreadEndCB_089 ===
<source lang="C">int sceKernelWaitEventForDriver(SceUID eventId, SceUInt32 waitPattern, SceUInt32 *pResultPattern, SceUInt64 *pUserData, SceUInt32 *pTimeout);</source>
 
=== sceKernelUnregisterThreadEventHandlerForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x0373C5E3
| 3.60 || 0x2C8ED6F0
|}
|}


=== sceKernelGetCallbackCount ===
=== sceKernelUnregisterCallbackFromEventAllForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x038644D5
| 3.60 || 0x8DADBD16
|}
|}


=== _sceKernelTryReceiveMsgPipeVector ===
=== sceKernelUnregisterCallbackFromEventForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x03CFCF00
| 3.60 || 0x2E48D81C
|}
|}


=== sceKernelCloseMutex ===
=== sceKernelUnlockWriteRWLockForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x03E23AF6
| 3.60 || 0x94A73797
|}
|}
=== _sceKernelGetSemaInfo ===
 
=== sceKernelUnlockReadRWLockForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x0402C633
| 3.60 || 0xDE1B9EEE
|}
|}
=== _sceKernelWaitCond ===
 
=== sceKernelTryLockWriteRWLockForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x040795C7
| 3.60 || 0xA96F2E5A
|}
|}
=== _sceKernelWaitMultipleEventsCB ===
 
=== sceKernelTryLockReadRWLockForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x0558B7C1
| 3.60 || 0xFC2B5A50
|}
|}
=== _sceKernelGetCondInfo ===
 
=== sceKernelStopTimerForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x05C51CE1
| 3.60 || 0x474F214B
|}
|}
=== _sceKernelSignalLwCondAll ===
 
<source lang="C">int sceKernelStopTimerForDriver(SceUID timerId);</source>
 
=== sceKernelStartTimerForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x07D2584A
| 3.60 || 0x84C4CE4D
|}
|}
=== sceKernelGetActiveCpuMask ===
 
<source lang="C">int sceKernelStartTimerForDriver(SceUID timerId);</source>
 
=== sceKernelSignalSemaForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x0C3CBB8B
| 3.60 || 0xD270498B
|}
|}
=== sceKernelExitThread ===
 
=== sceKernelSignalCondAllForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x0C8A38E1
| 3.60 || 0x6EC78CD0
|}
|}


=== _sceKernelCreateSema ===
=== sceKernelSetTimerTimeWideForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x0D76458E
| 3.60 || 0x85195A16
|}
|}
=== sceKernelOpenMsgPipe ===
 
=== sceKernelSetEventFlagForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x0E1CB9F6
| 0.931 || in ForKernel
|}
=== _sceKernelSignalCondAll ===
{| class="wikitable"
|-
|-
! Version !! NID
| 3.60 || 0xD4780C3E
|-
| 1.69 || 0x0F11545D
|}
|}
=== _sceKernelGetEventFlagInfo ===
 
=== sceKernelSetEventForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x106C216F
| 3.60 || 0x9EA3A45C
|}
|}
=== _sceKernelSetEventWithNotifyCallback ===
 
=== _sceKernelExtendKernelStackWideForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x118F646E
| 3.60 || 0xE54FD746
|}
|}
=== sceKernelSignalCondTo ===
 
Temp name was sceKernelRunWithStackForDriver.
 
This takes a function and runs it exclusively on the current core on its own stack.
 
<source lang="c">
// stack_size should be 0x2000
int _sceKernelExtendKernelStackWideForDriver(int stack_size, void *func, void *args);
</source>
 
=== sceKernelExtendKernelStackWideForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x1269F4EC
| 3.60 || 0xA2C801A5
|}
|}
=== _sceKernelUnlockMutex ===
 
Temp name was sceKernelRunWithStack2ForDriver.
 
<source lang="c">
// stack_size should be 0x2000
SceInt64 sceKernelExtendKernelStackWideForDriver(int stack_size, void *func, void *args);
</source>
 
=== sceKernelRegisterCallbackToEventForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x12948A63
| 3.60 || 0x832A7E0C
|}
|}
=== sceKernelCloseMsgPipe ===
 
=== sceKernelPulseEventWithNotifyCallbackForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x1305A065
| 3.60 || 0x714A107A
|}
|}
=== _sceKernelCancelTimer ===
 
=== sceKernelPulseEventForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x13117B21
| 3.60 || 0x2427C81B
|}
|}
=== sceKernelChangeThreadCpuAffinityMask ===
 
=== sceKernelPollSemaForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x15129174
| 3.60 || 0x4FDDFE24
|}
|}
=== _sceKernelDeleteThread ===
 
=== sceKernelPollEventFlagForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x151E0020
| 0.990-3.60 || 0x76C6555B
|}
|}
=== sceKernelCloseCond ===
 
<source lang="C">
/**
* @brief Event flag polling
*
* Polls the event flag specified by evfId.
*
* sceKernelPollEventFlag() is a system call that removes the function to enter standby state from sceKernelWaitEventFlag().
* Unlike sceKernelWaitEventFlag(), an error (SCE_KERNEL_ERROR_EVF_COND) is returned immediately if the wait release condition is not satisfied.
* In this case, SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL / SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT specification is ignored.
*
* @param evfId Specify the event flag identifier to be polled.
* @param bitPattern Specify the comparison value with the eventflag.
* @param waitMode Specify the wait mode. Specify one of the following:
*                      - SCE_KERNEL_EVF_WAITMODE_AND: Waiting for AND
*                      - SCE_KERNEL_EVF_WAITMODE_OR : Wait for OR
*                      In addition, you can optionally add one of the following specifications as a logical sum.
*                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL: Clear all bits after waiting
*                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT: After waiting, clear the bit specified in bitPattern
* @param pResultPat Specify a pointer to the SceUInt32 type variable that receives the eventflag value when waiting is established.
* @retval SCE_OK Success
* @retval (<0) Error code
*/
SceInt32 sceKernelPollEventFlagForDriver(SceUID evfId, SceUInt32 bitPattern, SceUInt32 waitMode, SceUInt32 *pResultPat);
</source>
 
=== sceKernelNotifyCallbackForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x15C690E0
| 3.60 || 0xC3E00919
|}
|}
=== sceKernelLockMutex_089 ===
 
=== sceKernelGetTimerTimeWideForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x16AC80C5
| 3.60 || 0xC1286004
|}
|}


<source lang="C">int sceKernelLockMutex_089(SceUID mutex_id, int unk1, int unk2);</source>
<source lang="C">SceUInt64 sceKernelGetTimerTimeWideForDriver(SceUID timerId);</source>


=== _sceKernelDeleteEventFlag ===
=== sceKernelGetTimerBaseWideForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x16C93704
| 3.60 || 0xA6D11DD3
|}
|}
=== _sceKernelOpenMsgPipe ===
 
<source lang="C">SceUInt64 sceKernelGetTimerBaseWideForDriver(SceUID timerId);</source>
 
=== sceKernelGetThreadmgrUIDClassForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x16EC5B7C
| 3.60 || 0x0A20775A
|}
|}
=== sceKernelUnregisterCallbackFromEvent ===
 
=== sceKernelGetThreadTLSAddrForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x18462B11
| 3.60 || 0x66EEA46A
|}
|}
=== _sceKernelWaitLwCond ===
 
=== sceKernelGetThreadStackFreeSizeForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x18C65756
| 3.60 || 0x7B278A0B
|}
|}
=== _sceKernelCancelCallback ===
 
=== sceKernelGetThreadCpuAffinityMaskForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x19A0C1B6
| 3.60 || 0x83DC703D
|}
|}
=== sceKernelUnlockMutex ===
 
=== sceKernelGetCallbackCountForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x1A372EC8
| 3.60 || 0x0892D8DF
|}
|}
=== _sceKernelCancelMutex ===
 
=== sceKernelCreateWorkQueueForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x1B74CB89
| 3.60 || 0x771522C6
|}
|}
=== sceKernelDeleteThread ===
 
<source lang="C">SceUID sceKernelCreateWorkQueueForDriver(const char *name, SceUInt32 flags, const SceKernelCreateWorkQueueParam *opt);</source>
 
=== sceKernelScheduleWorkTaskForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x1BBDE3D9
| 3.60 || 0xE50E1185
|}
|}
=== _sceKernelCancelSema ===
 
<source lang="C">SceUID sceKernelScheduleWorkTaskForDriver(SceUID wqueue_id, const char *name, const void *wtask_func, void *argp);</source>
 
=== sceKernelGetWorkqueueCreateInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x1CAF805D
| 3.60 || 0xB92709C4
|}
|}
=== sceKernelExitDeleteThread ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetWorkqueueCreateInfo(SceUID wqueue_id, SceKernelWorkqueueCreateInfo *info);</source>
 
=== sceKernelGetWorktaskCreateInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x1D17DECF
| 3.60 || 0x0B604A3C
|}
|}


=== sceKernelUnlockMutex_089 ===
This is a guessed name.
 
<source lang="C">int sceKernelGetWorktaskCreateInfo(SceUID wtask_id, SceKernelWorktaskCreateInfo *info);</source>
 
=== sceKernelGetWorkqueueInfoVectorForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x1E82E5D0
| 3.60 || 0x920EA1CA
|}
|}


<source lang="C">int sceKernelUnlockMutex_089(SceUID mutex_id, int unk1);</source>
This is a guessed name.
 
<source lang="C">int sceKernelGetWorkqueueInfoVector(int vis_level, void *dst, SceSize dst_size, SceUInt32 *nInfo);</source>


=== _sceKernelWaitMultipleEvents ===
=== sceKernelGetProcWorkqueueInfoVectorForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x200CC503
| 3.60 || 0x8C8A76EF
|}
|}
=== sceKernelTryLockWriteRWLock ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetProcWorkqueueInfoVector(SceUID pid, int vis_level, void *dst, SceSize dst_size, SceUInt32 *nInfo);</source>
 
=== sceKernelGetWorktaskInfoVectorForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x206CBB66
| 3.60 || 0xE605ED7A
|}
|}
=== sceKernelDeleteSimpleEvent ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetWorktaskInfoVector(int vis_level, SceThreadmgrForDriver_E605ED7A_t *dst, SceSize dst_size, SceUInt32 *nInfo);</source>
 
=== sceKernelGetProcWorktaskInfoVectorForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x208CFE28
| 3.60 || 0xB4CED111
|}
|}
=== _sceKernelPollSema ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetProcWorktaskInfoVector(SceUID pid, int vis_level, SceThreadmgrForDriver_E605ED7A_t *dst, SceSize dst_size, SceUInt32 *nInfo);</source>
 
=== sceKernelWaitWorktaskForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x20AF286A
| 3.60 || 0x12FC0FAB
|}
|}
=== _sceKernelGetThreadCpuAffinityMask ===
 
This is a guessed name.
 
<source lang="C">int sceKernelWaitWorktask(SceUID wtask_id, SceInt32 *timeout);</source>
 
=== sceKernelWaitWorktask2ForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x212E6C35
| 3.60 || 0xB247EC4B
|}
|}
=== _sceKernelGetTimerEventRemainingTime ===
 
This is a guessed name.
 
with user stack overflow detect?
 
<source lang="C">int sceKernelWaitWorktask2(SceUID wtask_id, SceInt32 *timeout);</source>
 
=== sceKernelDeleteThreadForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x215FD24D
| 1.69-3.60 || 0xAC834F3F
|}
|}
=== _sceKernelCloseMutex ===
 
<source lang="C">
/**
* @brief Delete thread
*
* Deletes the thread specified by threadId.
*
* Accordingly, the stack area and thread management area are released. The target thread must be in the DORMANT state.
*
* Since the own thread cannot be in the DORMANT state, it cannot be set as the target thread
* (this results in an SCE_KERNEL_ERROR_NOT_DORMANT error).
* Use sceKernelExitDeleteThread() to delete your own thread.
*
* @param threadId Specify the identifier of the thread to be deleted.
* @retval SCE_OK Success
* @retval Negative value Error code
*/
SceInt32 sceKernelDeleteThreadForDriver(
SceUID threadId
);
</source>
 
=== sceKernelDeleteSemaForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x21716C81
| 3.60 || 0x16A35E58
|}
|}
=== _sceKernelPollEvent ===
 
=== sceKernelDeleteMutexForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x21C7913E
| 3.60 || 0x0A912340
|}
|}
=== sceKernelStartThread_089 ===
 
<source lang="C">int sceKernelDeleteMutexForDriver(SceUID mutexid);</source>
 
=== sceKernelCloseEventFlagForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x21F5419B
| 0.931-3.60 || 0x71ECB352
|}
|}


=== _sceKernelCloseTimer ===
Temp name was sceKernelDeleteEventFlagForDriver.
 
=== sceKernelCreateThreadForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x22605E63
| 1.69-3.60 || 0xC6674E7D
|}
|}
=== _sceKernelExitCallback ===
 
<source lang="C">
/**
* @brief Thread generation that operates in the address space of its own process
*
* A thread that operates in the address space of its own process is created.
*
* Allocate a thread management area for the thread to be created, perform initialization, and secure a stack area.
* The thread information to be created is specified as an argument, and the thread identifier (UID) is returned as the return value.
*
* The generated thread is in the DORMANT state.
*
* @param pName Specifies the name of the thread.
* The name of the thread does not have to be unique because it is
* used by the operator to identify it when debugging. The maximum name length is 31 bytes.
* @param entry Specify the entry address of the thread. The thread entry point function
* can receive memory block data with two arguments.
* The argument is given by sceKernelStartThread() described later.
* The thread is terminated by returning from this function, and the return value of the function is the thread termination status.
* @param initPriority Specifies the initial priority of the thread. The smaller the number, the higher the priority.
* The range from SCE_KERNEL_HIGHEST_PRIORITY_USER (= 64) to SCE_KERNEL_LOWEST_PRIORITY_USER (= 191) can be used.
* By specifying SCE_KERNEL_DEFAULT_PRIORITY_USER, you can specify the default priority of the process to which the thread belongs.
* For the default priority, it is also possible to specify with SCE_KERNEL_DEFAULT_PRIORITY_USER ± offset.
* @param stackSize Specify the required stack size of the thread in bytes. The argument block given by
* sceKernelStartThread () is copied onto the stack, so specify the stack size with this margin in mind.
* An error will occur if a stack size less than 4 KiB is specified.
* @param attr You can specify multiple thread attributes by logical OR.
* @param cpuAffinityMask Specifies the initial CPU affinity mask for the thread.
* A thread can run only on the thread specified in the CPU affinity mask.
* The CPU affinity mask can be specified by the logical sum of the following macros.
* - SCE_KERNEL_CPU_MASK_USER_0
* - SCE_KERNEL_CPU_MASK_USER_1
* - SCE_KERNEL_CPU_MASK_USER_2
* The following macros are also available to represent all available CPUs.
* - SCE_KERNEL_CPU_MASK_USER_ALL
* @param pOptParam Argument for future expansion. Please specify NULL. Max size is 0x14.
* @retval Positive value Thread identifier (UID)
* @retval Negative value Error code
*/
SceUID sceKernelCreateThreadForDriver(
const char *pName,
SceKernelThreadEntry entry,
SceInt32 initPriority,
SceSize stackSize,
SceUInt32 attr,
SceInt32 cpuAffinityMask,
const SceKernelThreadOptParam *pOptParam
);
</source>
 
=== sceKernelCreateSimpleEventForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x2682E6ED
| 3.60 || 0x357A8177
|}
|}
=== sceKernelTryLockMutex_089 ===
 
=== sceKernelCreateMutexForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x270993A6
| 3.60 || 0xFBAA026E
|}
|}


=== sceKernelSetTimerTimeWide ===
<source lang="C">SceUID sceKernelCreateMutexForDriver(const char *pName, SceUInt attr, int initCount, const SceKernelMutexOptParam *pOptParam);</source>
 
=== sceKernelCreateEventFlagForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x273B4A4D
| 0.990-3.60 || 0x4336BAA4
|}
|}
=== _sceKernelOpenCond ===
 
<source lang="C">
/**
* @brief Event flag generation
*
* Generate an event flag and set the initial value of the event flag. Returns the identifier of the generated event flag as a return value.
*
* @param pName Specifies the name of the eventflag.
*                      The name of the eventflag does not need to be unique because it is used only for the purpose of operator
*                      identification when debugging without interprocess communication.
*                      However, if the SCE_KERNEL_ATTR_OPENABLE attribute is specified for attr,
*                      a unique name must be specified in the system.
*                      The maximum name length is 31 bytes.
* @param attr Specifies the event flag attribute.
*                      Specify the queue order from one of the following.
*                      - SCE_KERNEL_EVF_ATTR_TH_FIFO: Waiting thread queuing is FIFO
*                      - SCE_KERNEL_EVF_ATTR_TH_PRIO: Waiting thread queuing is based on the priority of threads.
*                      Specify whether to wait for multiple threads from either of the following.
*                      - SCE_KERNEL_EVF_ATTR_SINGLE: Multiple threads cannot wait simultaneously
*                      - SCE_KERNEL_EVF_ATTR_MULTI: To generate an event flag that can be referenced by
*                      sceKernelOpenEventFlag() that allows multiple threads to wait simultaneously, specify the following:
*                      - SCE_KERNEL_ATTR_OPENABLE
* @param initPattern Specifies the initial value of the eventflag.
* @param pOptParam Argument for future expansion. Please specify NULL.
* @retval (>=0) Event flag identifier (UID)
* @retval (<0) Error code
*/
SceUID sceKernelCreateEventFlagForDriver(const char *pName, SceUInt32 attr, SceUInt32 initPattern, const SceKernelEventFlagOptParam *pOptParam);
</source>
 
=== sceKernelClearEventFlagForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x27DD11EA
| 3.60 || 0x4F1DA3BE
|}
|}
=== _sceKernelGetThreadmgrUIDClass ===
 
=== sceKernelClearEventForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x27EE191B
| 3.60 || 0x9C335818
|}
|}
=== sceKernelOpenMutex_089 ===
 
<source lang="C">int sceKernelClearEventForDriver(SceUID eventId,SceUInt32 clearPattern);</source>
 
=== sceKernelChangeThreadPriority2ForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x2928D2EC
| 3.60 || 0x63DAB420
|}
|}
=== _sceKernelCancelEvent ===
 
Temp name was sceKernelChangeThreadPriorityForDriver.
 
=== sceKernelCancelCallbackForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x29483405
| 3.60 || 0xC040EC1C
|}
|}
=== _sceKernelCreateMsgPipeWithLR ===
 
=== sceKernelCancelMsgPipeForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x2AAC8BFD
| 3.60 || 0x9D6A2311
|}
|}
=== _sceKernelUnlockLwMutex ===
 
=== sceKernelCreateMsgPipeForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x2ABC41DF
| 3.60 || 0xBF631145
|}
|}
=== _sceKernelGetMsgPipeCreatorId ===
 
=== sceKernelDeleteMsgPipeForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x2B751F95
| 3.60 || 0xB3453F88
|}
|}
=== sceKernelCancelCallback ===
 
=== sceKernelSendMsgPipeVectorForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x30741EF2
| 3.60 || 0x67DD3BAD
|}
|}
=== sceKernelSetEvent ===
 
=== sceKernelTryReceiveMsgPipeVectorForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x324218CD
| 3.60 || 0xCE09221A
|}
|}
=== _sceKernelGetTimerBaseWide ===
 
=== sceKernelTrySendMsgPipeVectorForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x370E147B
| 3.60 || 0x4CF1BE58
|}
|}
=== _sceKernelGetThreadContextForVM ===
 
=== sceKernelIsThreadDebugSuspendedForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x377094D5
| 0.990-3.60 || 0xA0B1AB21
|}
|}
=== _sceKernelCreateEventFlag ===
 
Used by SceCoredump maybe to get the state at the time of process crash.
 
<source lang="C">
/**
* @param[in]  thid        thread id (kernel uid)
* @return      suspend state, else < 0 on error.
*/
int sceKernelIsThreadDebugSuspendedForDriver(SceUID thid);
</source>
 
=== sceKernelDebugResumeThreadForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x38AA5E8E
| 0.990-3.60 || 0xEC8343DF
|}
|}
=== _sceKernelSetTimerTimeWide ===
 
=== sceKernelResumeThreadForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x39364623
| 0.990-3.60 || 0xE3CE20AA
|}
|}
=== _sceKernelWaitThreadEndCB_0910 ===
 
=== sceKernelCreateRemoteThreadForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x394BCCF2
| 0.990-3.65 || 0xC8E57BB4
|}
|}
=== _sceKernelSignalCondTo ===
 
Some value are allowed if Thread name is "ScePsp2SwuCui".
 
<source lang="C">
/**
* @brief Thread generation that does not operate in the address space of its own process
*
* A thread that does not operate in the address space of its own process is created.
*
* Allocate a thread management area for the thread to be created, perform initialization, and secure a stack area.
* The thread information to be created is specified as an argument, and the thread identifier (UID) is returned as the return value.
*
* The generated thread is in the DORMANT state.
*
* @param pid Specifies the ID of the process the thread belongs to.
* @param pName Specifies the name of the thread.
* The name of the thread does not have to be unique because it is
* used by the operator to identify it when debugging. The maximum name length is 31 bytes.
* @param entry Specify the entry address of the thread. The thread entry point function
* can receive memory block data with two arguments.
* The argument is given by sceKernelStartThread() described later.
* The thread is terminated by returning from this function, and the return value of the function is the thread termination status.
* @param initPriority Specifies the initial priority of the thread. The smaller the number, the higher the priority.
* The range from SCE_KERNEL_HIGHEST_PRIORITY_USER (= 64) to SCE_KERNEL_LOWEST_PRIORITY_USER (= 191) can be used.
* By specifying SCE_KERNEL_DEFAULT_PRIORITY_USER, you can specify the default priority of the process to which the thread belongs.
* For the default priority, it is also possible to specify with SCE_KERNEL_DEFAULT_PRIORITY_USER ± offset.
* @param stackSize Specify the required stack size of the thread in bytes. The argument block given by
* sceKernelStartThread () is copied onto the stack, so specify the stack size with this margin in mind.
* An error will occur if a stack size less than 4 KiB is specified.
* @param attr You can specify multiple thread attributes by logical OR.
* @param cpuAffinityMask Specifies the initial CPU affinity mask for the thread.
* A thread can run only on the thread specified in the CPU affinity mask.
* The CPU affinity mask can be specified by the logical sum of the following macros.
* - SCE_KERNEL_CPU_MASK_USER_0
* - SCE_KERNEL_CPU_MASK_USER_1
* - SCE_KERNEL_CPU_MASK_USER_2
* The following macros are also available to represent all available CPUs.
* - SCE_KERNEL_CPU_MASK_USER_ALL
* @param pOptParam Argument for future expansion. Please specify NULL. Max size is 0x14.
* @retval Positive value Thread identifier (UID)
* @retval Negative value Error code
*/
SceUID sceKernelCreateRemoteThreadForDriver(
SceUID pid,
const char *pName,
SceKernelThreadEntry entry,
SceInt32 initPriority,
SceSize stackSize,
SceUInt32 attr,
SceInt32 cpuAffinityMask,
const SceKernelThreadOptParam *pOptParam
);
</source>
 
=== sceKernelGetThreadIdListForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x3C00071F
| 0.990.000-3.740.011 || 0xEA7B8AEF
|}
|}
=== _sceKernelReceiveMsgPipeVector ===
 
This function is used to query and obtain the number of threads within a process.
 
<source lang="C">
/**
* @brief      Retrieve a list of all threads belonging to a process.
* @param[in]  pid        The process to query.
* @param[out]  ids        The list of thread IDs. Can be NULL if output is not required.
* @param[in]  n          The max number of thread IDs to copy out.
* @param[out]  copy_count  The number of thread IDs copied.
* @return      The number of threads within the process, else < 0 on error.
*/
int sceKernelGetThreadIdListForDriver(SceUID pid, SceUID *ids, int n, int *copy_count);
</source>
 
=== sceKernelGetThreadCpuRegistersForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x3DD9E4AB
| 3.60 || 0x5022689D
|}
|}
=== _sceKernelPulseEventWithNotifyCallback ===
 
{| class="wikitable"
This function is used to get the state of the registers for a SUSPENDED thread. It returns the registers in a two part structure. It is uncertain what the difference is between the two parts. It seems like it is a usermode/kernel separation. It could also be a current/exception difference. In normal usage on a suspended thread it seems to be the usermode aspect that contains valid values. When you query a suspended thread that has no had the opportunity to start yet, the kernel side is filled.
|-
 
! Version !! NID
<source lang="C">
|-
/** Structure representing all ARM registers */
| 1.69 || 0x3E49D3F1
typedef struct ArmCpuRegisters {
|}
    uint32_t    r0;
=== sceKernelUnlockReadRWLock ===
    uint32_t    r1;
    uint32_t    r2;
    uint32_t    r3;
    uint32_t    r4;
    uint32_t    r5;
    uint32_t    r6;
    uint32_t    r7;
    uint32_t    r8;
    uint32_t    r9;
    uint32_t    r10;
    uint32_t    r11;
    uint32_t    r12;
    uint32_t    sp;
    uint32_t    lr;
    uint32_t    pc;
    uint32_t    cpsr;
    uint32_t    fpscr;
} ArmCpuRegisters;
 
/** Structure containing a threads register states. */
typedef struct ThreadCpuRegisters {
    ArmCpuRegisters entry[2];
} ThreadCpuRegisters;
 
/**
* @brief      Query the state of the registers for a suspended thread.
*
* The registers returned are the usermode/kernel set for the requested thread.
* It is uncertain if usermode/kernel is correct representation and instead it could be current/exception.
* The thread provided must be suspended for this function to succeed.
*
* @param[in]  thid        The thread to query.
* @param[out]  registers  The set of registers belonging to the thread.
* @return      Zero on success, else < 0 on error.
*/
int sceKernelGetThreadCpuRegistersForDriver(SceUID thid, ThreadCpuRegisters *registers);
</source>
 
=== sceKernelChangeThreadSuspendStatusForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x3EF91145
| 3.60 || 0x04C6764B
|}
|}
=== sceKernelGetTimerTimeWide ===
 
{| class="wikitable"
This function 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.
|-
 
<source lang="C">
/**
* @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 sceKernelChangeThreadSuspendStatusForDriver(SceUID thid, int status);
</source>
 
=== sceKernelChangeActiveCpuMaskForDriver ===
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x3EFD3165
| 1.69-3.60 || 0x001173F8
|}
|}
=== _sceKernelCreateCallback ===
 
=== sceKernelGetThreadCurrentPriorityForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x3F42E175
| 1.69-3.60 || 0x01414F0B
|}
|}
=== _sceKernelWaitEventFlagCB ===
 
=== sceKernelCreateCallbackForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x401E0C68
| 1.69-3.60 || 0x1C41614C
|}
|}
=== _sceKernelSetEventFlag ===
 
=== sceKernelWaitThreadEndCB_089ForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
|-
|-
! Version !! NID
| 1.69 || 0x0373C5E3
|-
|-
| 1.69 || 0x438917E4
| 3.60 || not present
|}
|}
=== _sceKernelWaitCondCB ===
 
=== sceKernelDeleteCallbackForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x452B0AB3
| 1.69-3.60 || 0x3A7E17F6
|}
|}
=== _sceKernelWaitSema ===
 
=== sceKernelExitThreadForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x45389B6B
| 1.69-3.60 || 0x0C8A38E1
|}
|}
=== sceKernelGetSystemTimeLow ===
 
<source lang="C">
/**
* @brief End of own thread
*
* Terminates the own thread normally and shifts to the DORMANT state.
* sceKernelExitThread() is a system call that does not return to the context of the issuer.
*
* Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
* However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
* The mutex is unlocked and not deleted.
*
* When the terminated thread is restarted with sceKernelStartThread(), the information included in the thread
* management area, such as thread priority, is reset.
* It will not inherit the one at the end.
*
* When a thread exits, exitStatus becomes the exit status of that thread.
*
* If the thread is terminated by a return from the entry function without using
* sceKernelExitThread(), the return value of the entry function becomes the termination status.
*
* The end status of a thread can be obtained by sceKernelGetThreadExitStatus() and sceKernelGetThreadInfo(),
* and when another thread waits for the end of the thread by sceKernelWaitThreadEnd(), it can be obtained by the return value.
*
* The thread exit status is saved while the thread exits and is in the DORMANT state,
* but the value is lost if the thread is restarted or deleted with sceKernelStartThread().
*
* @param exitStatus Specify the value to be set for the termination status of the local thread.
* @retval Negative value Error code
*/
SceInt32 sceKernelExitThreadForDriver(
SceInt32 exitStatus
);
</source>
 
=== sceKernelLockMutex_089ForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x47F6DE49
| 0.990-3.60 || 0x16AC80C5
|}
|}


=== sceKernelStartTimer ===
<source lang="C">int sceKernelLockMutex_089ForDriver(SceUID mutex_id, int unk1, int unk2);</source>
 
=== sceKernelExitDeleteThreadForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x48091E0C
| 1.69-3.60 || 0x1D17DECF
|}
=== sceKernelDelayThread ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x4B675D05
|}
|}


=== _sceKernelClearEvent ===
<source lang="C">
/**
* @brief End and delete own thread
*
* Terminates the own thread normally and deletes it.
* sceKernelExitDeleteThread() is a system call that does not return to the context of the issuer.
*
* Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
* However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
* The mutex is unlocked and not deleted.
*
* When a thread exits, exitStatus becomes the exit status of that thread (sceKernelExitDeleteThread()
* directly deletes the thread without going through the DORMANT state.
* (It cannot be obtained by sceKernelGetThreadInfo(). The end status can be obtained by the return
* value only when waiting for the end of the thread by sceKernelWaitThreadEnd().)
*
* @param exitStatus Specify the value to be set for the termination status of the local thread.
* @retval Negative value Error code
*/
SceInt32 sceKernelExitDeleteThreadForDriver(
SceInt32 exitStatus
);
</source>
 
=== sceKernelUnlockMutex_089ForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x4B7F47DC
| 0.990-3.60 || 0x1E82E5D0
|}
|}
=== __sceKernelCreateLwMutex ===
 
<source lang="C">int sceKernelUnlockMutex_089ForDriver(SceUID mutex_id, int unk1);</source>
 
=== sceKernelStartThread_089ForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x4BB3154A
| 1.69-3.60 || 0x21F5419B
|}
|}


<source lang="C">
<source lang="C">
typedef struct sceKernelCreateLwMutex_opt //size is 0x10
/**
{
* @brief Thread activation
  int initCount;
*
  const SceKernelLwMutexOptParam* pOptParam;
* Starts the thread specified by threadId and puts it in READY state.
  uint32_t unk_8;
*
  uint32_t unk_C;
* The argument block specified by argSize and argBlock is copied onto the thread stack, argSize is
} sceKernelCreateLwMutex_opt;
* passed directly to the first argument of the thread entry function, and the second argument of
 
* the entry function is the argument copied onto the stack. The block address is passed.
int __sceKernelCreateLwMutex(SceKernelLwMutexWork *pWork, const char *pName, unsigned int attr, sceKernelCreateLwMutex_opt* opt);
*
* This system call does not queue activation requests. In other words, if the target thread is not
* in the DORMANT state, an SCE_KERNEL_ERROR_NOT_DORMANT error is returned to the calling thread.
*
* @param threadId Specify the identifier of the thread to be started.
* @param argSize Specify the size (byte) of the argument to be passed to the thread.
* @param pArgBlock Specify the address of the argument to be passed to the thread.
* @retval SCE_OK Success
* @retval Negative value Error code
*/
SceInt32 sceKernelStartThread_089ForDriver(
SceUID threadId,
SceSize argSize,
const void *pArgBlock
);
</source>
</source>


=== sceKernelClearEventFlag ===
=== sceKernelTryLockMutex_089ForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x4CB87CA7
| 1.69-3.60 || 0x270993A6
|}
|}
=== _sceKernelReceiveMsgPipeVectorCB ===
 
=== sceKernelGetSystemTimeLowForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x4DBF648E
| 1.69-3.60 || 0x47F6DE49
|}
|}
=== _sceKernelNotifyCallback ===
 
=== sceKernelDelayThreadForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x4DF8B624
| 1.69-3.60 || 0x4B675D05
|}
|}
=== _sceKernelWaitEvent ===
 
=== sceKernelGetMutexInfo_089ForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x4E0EA70D
| 1.69-3.60 || 0x69B78A12
|}
|}
=== sceKernelOpenSimpleEvent ===
 
<source lang="C">int sceKernelGetMutexInfo_089ForDriver(SceUID mutexid, SceKernelMutexInfo *info);</source>
 
=== sceKernelCancelMutex_089ForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x4E1E4DF8
| 1.69-3.60 || 0x7204B846
|}
|}
=== sceKernelGetThreadStackFreeSize ===
 
=== sceKernelChangeCurrentThreadAttrForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x4F8A3DA0
| 1.69-3.60 || 0x751C9B7A
|}
|}
=== _sceKernelWaitSignal ===
 
=== sceKernelDelayThreadCBForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x50407BF4
| 1.69-3.60 || 0x9C0180E1
|}
|}
=== _sceKernelTryLockWriteRWLock ===
 
=== sceKernelLockMutexCB_089ForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x52DD3322
| 1.69-3.60 || 0xD06F2886
|}
|}
=== sceKernelOpenMutex ===
 
=== sceKernelCheckWaitableStatusForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x52E17182
| 1.69-3.60 || 0xD9BD74EB
|}
|}
=== sceKernelDeleteEventFlag ===
 
=== sceKernelCheckCallbackForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x5840162C
| 1.69-3.60 || 0xE53E41F6
|}
|}
=== _sceKernelUnregisterCallbackFromEventAll ===
 
=== sceKernelWaitThreadEnd_089ForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
|-
|-
! Version !! NID
| 1.69 || 0xF3489EF4
|-
|-
| 1.69 || 0x5B5650C7
| 3.60 || not present
|}
|}
=== _sceKernelUnlockWriteRWLock ===
 
=== sceKernelGetSystemTimeWideForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x5B746A69
| 1.69-3.60 || 0xF4EE4FA9
|}
|}
=== _sceKernelGetCallbackCount ===
 
=== sceKernelGetThreadInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x5D06FF09
| 0.990-3.60 || 0x283807E2
|}
|}
=== _sceKernelLockReadRWLockCB ===
 
<source lang="c"> int sceKernelGetThreadInfoForDriver(SceUID thid, SceKernelThreadInfo *info)</source>
 
=== sceKernelInitializeFastMutexForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x5D86D763
| 0.990-3.60 || 0xAF8E1266
|}
|}
=== sceKernelGetTimerBaseWide ===
 
<source lang="c">int sceKernelInitializeFastMutexForDriver(void* mutex, const char* name, uint32_t attr, int unk)</source>
 
=== sceKernelLockFastMutexForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x5DBC1960
| 1.69-3.60 || 0x70627F3A
|}
|}
=== _sceKernelSendMsgPipeVector ===
 
<source lang="c"> int sceKernelLockFastMutexForDriver(void* mutex)</source>
 
=== sceKernelUnlockFastMutexForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x5E65E454
| 1.69-3.60 || 0xDB395782
|}
|}
=== _sceKernelWaitExceptionCB ===
 
<source lang="c"> int sceKernelUnlockFastMutexForDriver(void* mutex)</source>
 
=== sceKernelFinalizeFastMutexForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x5E7876F2
| 0.990-3.60 || 0x11FE84A1
|}
|}
=== sceKernelResumeThreadForVM ===
 
Temp name was sceKernelDeleteFastMutexForDriver.
 
<source lang="c"> int sceKernelFinalizeFastMutexForDriver(void* mutex)</source>
 
=== sceKernelSignalCondToForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x5E93840E
| 1.69-3.60 || 0x61533DA9
|}
|}
=== _sceKernelCloseCond ===
 
<source lang="c"> int sceKernelSignalCondToForDriver(SceUID condId, SceUID threadId)</source>
 
=== sceKernelCreateCondForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x650CE348
| 1.69-3.60 || 0xDB6CD34A
|}
|}
=== _sceKernelPMonCpuGetCounter ===
 
<source lang="c"> SceUID sceKernelCreateCondForDriver(const char *name, SceUInt attr, SceUID mutexId, const SceKernelCondOptParam *option)</source>
 
=== sceKernelWaitCondForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x667A4649
| 1.69-3.60 || 0xCC7E027D
|}
|}
=== _sceKernelGetActiveCpuMask ===
 
<source lang="c"> int sceKernelWaitCondForDriver(SceUID condId, unsigned int *timeout)</source>
 
=== sceKernelReceiveMsgPipeVectorForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x67FDA21B
| 1.69-3.60 || 0xDA1F256B
|}
|}
=== _sceKernelDeleteCallback ===
 
=== sceKernelReceiveMsgPipeVectorCBForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x68D0FA79
| 1.69-3.60 || 0xDA5C9AC6
|}
|}
=== sceKernelGetMutexInfo_089 ===
 
=== sceKernelGetThreadIdForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0x69B78A12
| 1.69-3.60 || 0x59D06540
|}
|}


=== _sceKernelPMonThreadGetCounter ===
<source lang="c"> SceUID sceKernelGetThreadIdForDriver(void);</source>
 
=== sceKernelDeleteCondForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x6B9711AC
| 1.69-3.60 || 0xAEE0D27C
|}
|}
=== _sceKernelGetLwCondInfo ===
 
<source lang="c"> int sceKernelDeleteCondForDriver(SceUID cid);</source>
 
=== sceKernelCreateSemaForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x6C79F2F2
| 1.69-3.60 || 0x30E93C31
|}
=== sceKernelSignalCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x6ED2E2DC
|-
| 3.60 || 0x6ED2E2DC
|}
|}


=== _sceKernelSignalLwCondTo ===
<source lang="C">
/**
* Creates a new semaphore
*
* @par Example:
* @code
* int semaid;
* semaid = sceKernelCreateSemaForDriver("MySema", 0, 1, 1, 0);
* @endcode
*
* @param name - Specifies the name of the sema
* @param attr - Sema attribute flags (normally set to 0)
* @param initVal - Sema initial value
* @param maxVal - Sema maximum value
* @param option - Sema options (normally set to 0)
* @return A semaphore id
*/
SceUID sceKernelCreateSemaForDriver(const char *name, SceUInt attr, int initVal, int maxVal, SceKernelSemaOptParam *option);
</source>
 
=== sceKernelWaitSemaCBForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x6F1A4A2E
| 1.69-3.60 || 0xF55E4D86
|}
|}
=== _sceKernelGetTimerTime ===
 
{| class="wikitable"
<source lang="C">
|-
/**
! Version !! NID
* Lock a semaphore
|-
*
| 1.69 || 0x6F2C41BA
* @par Example:
|}
* @code
=== _sceKernelWaitException ===
* sceKernelWaitSemaCBForDriver(sema_id, 1, 0);
{| class="wikitable"
* @endcode
|-
*
* @param sema_id - The sema id returned from ::sceKernelCreateSemaForDriver
* @param signal - The value to wait for (i.e. if 1 then wait till reaches a signal state of 1)
* @param timeout - Timeout in microseconds (assumed).
*
* @return < 0 on error.
*/
int sceKernelWaitSemaCBForDriver(SceUID sema_id, int signal, SceUInt *timeout);
</source>
 
=== sceKernelWaitSemaForDriver ===
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x6F7C4DE6
| 1.69-3.60 || 0x3C8B55A9
|}
|}
=== _sceKernelGetEventPattern ===
 
<source lang="C">
/**
* Lock a semaphore
*
* @par Example:
* @code
* sceKernelWaitSemaForDriver(sema_id, 1, 0);
* @endcode
*
* @param sema_id - The sema id returned from ::sceKernelCreateSemaForDriver
* @param signal - The value to wait for (i.e. if 1 then wait till reaches a signal state of 1)
* @param timeout - Timeout in microseconds (assumed).
*
* @return < 0 on error.
*/
int sceKernelWaitSemaForDriver(SceUID sema_id, int signal, SceUInt *timeout);
</source>
 
=== sceKernelSignalCondForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x70358258
| 1.69-3.60 || 0xAC616150
|}
|}
=== sceKernelGetMsgPipeCreatorId ===
 
{| class="wikitable"
<source lang="C">int sceKernelSignalCondForDriver(SceUID condId);</source>
|-
 
=== sceKernelChangeThreadCpuAffinityMaskForDriver ===
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x70E2A6D2
| 1.69-3.60 || 0x6D0733A8
|}
|}
=== _sceKernelSuspendThreadForVM ===
 
<source lang="C">
/**
* @brief Thread CPU affinity mask setting
*
* Change the CPU affinity mask of the thread specified by threadId to cpuAffinityMask.
* A thread can run only on the CPU specified by the CPU affinity mask.
*
* If the CPU affinity mask of a running thread is changed and cannot be executed on the current CPU, the thread is dispatched immediately.
* As a result of scheduling, if a higher priority thread is running on the newly executable CPU, it is made to wait in the READY state.
*
* However, if the dispatch is disabled, the CPU affinity mask is changed immediately,
* but the rescheduling process is delayed until dispatch is permitted.
*
* @param threadId Specify the identifier of the thread whose CPU affinity mask is to be changed.
* You can specify your own thread with SCE_KERNEL_THREAD_ID_SELF.
* @param cpuAffinityMask Specify the CPU affinity mask after the change.
* The CPU affinity mask is expressed by the logical OR of the following macros.
* - SCE_KERNEL_CPU_MASK_USER_0
* - SCE_KERNEL_CPU_MASK_USER_1
* - SCE_KERNEL_CPU_MASK_USER_2
* The following macros are also available to specify all available CPUs.
* - SCE_KERNEL_CPU_MASK_USER_ALL
* @retval Positive value CPU affinity mask before change
* @retval Negative value Error code
*/
SceInt32 sceKernelChangeThreadCpuAffinityMaskForDriver(
SceUID threadId,
SceInt32 cpuAffinityMask
);
</source>
 
=== sceKernelSetThreadAccessLevelForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x7192B01C
| 1.69-3.65 || 0x02EEDF17
|}
|}
=== sceKernelCancelMutex_089 ===
 
Temp name was sceKernelSetPermissionForDriver.
 
<source lang="C">
// return value is previous value
int sceKernelSetThreadAccessLevelForDriver(int value);
</source>
 
=== sceKernelGetProcessIdForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x7204B846
| 1.69-3.60 || 0x9DCB4B7A
|}
|}
=== _sceKernelWaitLwCondCB ===
 
Returns the process ID.
 
<source lang="C">SceUID sceKernelGetProcessIdForDriver(void);</source>
 
=== sceKernelSetImpersonateIdForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x72DBB96B
| 1.69-3.60 || 0x0486F239
|}
|}
=== sceKernelTryLockMutex ===
 
{| class="wikitable"
This is a guessed name. Temp name was sceKernelSetProcessIdToTLSForDriver.
|-
 
Sets impersonation ID for the current thread.
 
Impersonation ID is used for access checks in e.g. [[SceIofilemgr]].
 
<source lang="C">
// Returns the previous impersonation ID
ScePID sceKernelSetImpersonateIdForDriver(ScePID pid);
</source>
 
=== sceKernelGetImpersonateIdForDriver ===
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x72FC1F54
| 1.69-3.60 || 0xFA54D49A
|}
|}
=== sceKernelChangeCurrentThreadAttr ===
 
This is a guessed name. Temp name was sceKernelGetProcessIdFromTLSForDriver.
 
Returns the current thread's impersonation ID.
 
Used by [[SceIofilemgr]], which calls the returned value <code>impersonateId</code>.
 
<source lang="C">
ScePID sceKernelGetImpersonateIdForDriver(void);
</source>
 
=== sceKernelRegisterTimerForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
|-
|-
! Version !! NID
| 0.990 || also in ForKernel
|-
|-
| 1.69 || 0x751C9B7A
| 3.60 || 0xC58DF384
|}
|}
=== _sceKernelDeleteLwCond ===
 
// seen: unk = 0, 2 so maybe UDCD bus
 
<source lang="C">int sceKernelRegisterTimerForDriver(char *name, SceUInt32 time, void *function, int unk);</source>
 
=== sceKernelRegisterTimerWithOptForDriver ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
|-
|-
! Version !! NID
| 0.990 || also in ForKernel
|-
|-
| 1.69 || 0x75FCF058
| 0.990-3.60 || 0x10517330
|}
|}
=== sceKernelOpenCond ===
 
This is a guessed name.
 
<source lang="C">
typedef struct SceKernelRegisterTimerOpt {
    SceUInt32 time;
    char *log_buffer_start;
} SceKernelRegisterTimerOpt;
 
int sceKernelRegisterTimerWithOptForDriver(char *name, SceKernelRegisterTimerOpt *pOpt, void *function, int unk);
</source>
 
=== sceKernelCreateRWLockForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x76BDA02F
| 0.990-3.60 || 0x04150799
|}
|}
=== sceKernelRegisterCallbackToEvent ===
 
=== sceKernelCreateTimerForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x76FB37E9
| 3.60 || 0x90656C98
|}
|}
=== _sceKernelSignalCond ===
 
<source lang="C">SceUID sceKernelCreateTimerForDriver(const char *name, int attr, void *pOpt);</source>
 
=== sceKernelDelayThreadUnkCBForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x79889DAC
| 3.60 || 0x2B60B793
|}
|}
=== _sceKernelCreateTimer ===
 
=== sceKernelDelayThreadUnkForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x79BA0A6D
| 3.60 || 0xE9A99C50
|}
|}
=== _sceKernelGetMsgPipeInfo ===
 
<source lang="C">int sceKernelDelayThreadUnkForDriver(SceUInt32 nsec, SceUInt32 *some_time);</source>
 
=== sceKernelGetTHBPForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x7AE31060
| 0.990-3.60 || 0x453B764A
|}
|}
=== sceKernelClearEvent ===
 
Used by [[SceDeci4pSDbgp]].
 
Get <b>t</b>hread <b>h</b>ardware <b>b</b>reak <b>p</b>oint.
 
<source lang="C">int sceKernelGetTHBPForDriver(SceUID thid, SceUInt32 a2, int *a3, int *a4);</source>
 
=== sceKernelSetTHBPForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x7B2A4B28
| 0.990-3.60 || 0x385831A1
|}
|}
=== _sceKernelUnlockReadRWLock ===
 
<source lang="C">int sceKernelSetTHBPForDriver(SceUID pid, SceUInt32 a2, int a3, int a4);</source>
 
=== SceThreadmgrForDriver_86DAE59B ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x7D16FB3B
| 3.60 || 0x86DAE59B
|}
|}
=== _sceKernelWaitEventCB ===
 
A guessed name is sceKernelGetAllowedCpuAffinityMaskForDriver.
 
Get global CPU affinity mask.
 
<source lang="C">int SceThreadmgrForDriver_86DAE59B(void);</source>
 
=== sceKernelCancelAlarmForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x7D483C33
| 0.990-3.60 || 0x44CCF310
|}
|}
=== _sceKernelLockReadRWLock ===
 
Used in [[SceCtrl]], [[SceTouch]].
 
<source lang="C">int sceKernelCancelAlarmForDriver(SceUID uid_or_pid);</source>
 
=== sceKernelDebugSuspendThreadForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x7EB9E8B5
| 3.60 || 0xFB3706CB
|}
|}
=== _sceKernelLockMutex ===
 
<source lang="C">int sceKernelDebugSuspendThreadForDriver(SceUID threadId, SceUInt32 status);</source>
 
=== sceKernelGetEventFlagInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x7FA945AD
| 3.60 || 0x612277C9
|}
|}
=== _sceKernelGetThreadExitStatus_0940 ===
 
<source lang="C">int sceKernelGetEventFlagInfoForDriver(SceUID uid, SceKernelEventFlagInfo *pInfo);</source>
 
=== sceKernelGetThreadInfoForDebuggerForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x800BB137
| 0.990-3.60 || 0xDD8D9429
|}
|}
=== _sceKernelLockWriteRWLock ===
 
This is a guessed name. Old name was sceKernelGetThreadInfoInternalForDriver.
 
<source lang="C">int sceKernelGetThreadInfoForDebuggerForDriver(SceUID thid, int a2, SceKernelThreadInfoInternal *pInfo);</source>
 
=== sceKernelGetVfpRegisterForDebuggerForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x80191FAA
| 3.60 || 0x5CDE387A
|}
|}
=== _sceKernelGetSystemInfo ===
 
Temp name was sceKernelGetThreadFloatRegisterForDriver.
 
<source lang="C">int sceKernelGetVfpRegisterForDebuggerForDriver(SceUID thid, SceKernelThreadFloatRegister *pRegister);</source>
 
=== sceKernelGetUserThreadIdForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x80544E0C
| 3.60 || 0xF311808F
|}
|}
=== _sceKernelDeleteSema ===
 
This is a guessed name.
 
<source lang="C">SceUID sceKernelGetUserThreadIdForDriver(SceUID thid_kern);</source>
 
=== sceKernelGetSemaInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x855F49D5
| 3.60 || 0xC99DCF0D
|}
|}
=== _sceKernelOpenTimer ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetSemaInfoForDriver(SceUID semaid, SceKernelSemaInfo *info);</source>
 
=== sceKernelGetEventFlagInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x8564E008
| 3.60 || 0x612277C9
|}
|}
=== _sceKernelGetTimerBase ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetEventFlagInfoForDriver(SceUID evfid, SceKernelEventFlagInfo *info);</source>
 
=== sceKernelGetLwMutexInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x865DA482
| 3.60 || 0x15287EF6
|}
|}
=== sceKernelPollSema ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetLwMutexInfoForDriver(SceUID lwmtxid, SceKernelLwMutexInfo *info);</source>
 
=== sceKernelGetMsgPipeInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x866EF048
| 3.60 || 0x207E0E18
|}
|}
=== _sceKernelGetCallbackInfo ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetMsgPipeInfoForDriver(SceUID msgpipe_id, SceKernelMsgPipeInfo *info);</source>
 
=== sceKernelGetLwCondInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x86761234
| 3.60 || 0xC2AFFBD0
|}
|}
=== sceKernelStopTimer ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetLwCondInfoForDriver(SceUID lwcond_id, SceKernelLwCondInfo *info);</source>
 
=== sceKernelGetThreadExitStatusForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x869E9F20
| 3.60 || 0x70131EA5
|}
|}
=== sceKernelDeleteCond ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetThreadExitStatusForDriver(SceUID thid, SceInt32 *status);</source>
 
=== SceThreadmgrForDriver_032E8F73 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x879E6EBD
| 3.60 || 0x032E8F73
|}
|}
=== sceKernelUnregisterCallbackFromEventAll ===
 
=== sceKernelGetLwMutexInfoAllProcForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x888A7361
| 3.60 || 0x069D8A20
|}
|}
=== _sceKernelGetRWLockInfo ===
 
=== SceThreadmgrForDriver_09346D1A ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x8CE3AFC7
| 3.60 || 0x09346D1A
|}
|}
=== sceKernelPulseEvent ===
 
=== SceThreadmgrForDriver_0A4AD37A ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x8D27BAD6
| 3.60 || 0x0A4AD37A
|}
|}
=== _sceKernelCancelEventWithSetPattern ===
 
=== sceKernelGetEventPatternForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x8E68E870
| 3.60 || 0x0C6BCB8C
|}
|}
=== _sceKernelSignalSema ===
 
=== SceThreadmgrForDriver_0D0644DA ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x8E9A0400
| 3.60 || 0x0D0644DA
|}
|}
=== _sceKernelDeleteLwMutex ===
 
=== SceThreadmgrForDriver_0EB0ABF0 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x91262C5F
| 3.60 || 0x0EB0ABF0
|}
|}
=== _sceKernelDeleteTimer ===
 
=== SceThreadmgrForDriver_1096042E ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x921A043D
| 3.60-3.65 || 0x1096042E
|}
|}
=== _sceKernelCreateMutex ===
 
On success, returns SCE_TRUE if specified thread has the Common Dialog attribute (0x4000), and SCE_FALSE otherwise.
 
A possible name is <code>sceKernelIsCdlgThread</code>
 
<source lang="c">
SceInt32 SceThreadmgrForDriver_1096042E(SceUID thid);
</source>
 
=== SceThreadmgrForDriver_1378F6EF ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x92667AE5
| 3.60 || 0x1378F6EF
|}
|}
=== _sceKernelCreateLwCond ===
 
=== sceKernelGetCurrentThreadVfpExceptionForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x940B9EBE
| 3.60 || 0x14F8167C
|}
|}
=== sceKernelCloseEventFlag ===
 
=== SceThreadmgrForDriver_154F2C2A_waitWorkQueue ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9A68F547
| 3.60 || 0x154F2C2A
|}
|}
=== _sceKernelSetEvent ===
 
=== sceKernelGetTimerInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9A92C33F
| 3.60 || 0x19F3E92A
|}
|}
=== _sceKernelDeleteRWLock ===
 
<source lang="C">int sceKernelGetTimerInfoForDriver(SceUID timerId, void *pInfo);</source>
 
=== SceThreadmgrForDriver_20C228E4 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9AA387DF
| 3.60 || 0x20C228E4
|}
|}
=== _sceKernelGetTimerTimeWide ===
 
=== sceKernelGetMutexInfoAllProcForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9AC39954
| 3.60 || 0x2322A2F3
|}
|}
=== _sceKernelRegisterCallbackToEvent ===
 
=== SceThreadmgrForDriver_25AB8F6B ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9B1922F2
| 3.60 || 0x25AB8F6B
|}
|}
=== sceKernelDelayThreadCB ===
 
=== SceThreadmgrForDriver_2828F884 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9C0180E1
| 3.60 || 0x2828F884
|}
|}
=== _sceKernelCreateSimpleEvent ===
 
=== sceKernelDeleteSimpleEventForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9C187FAD
| 3.60 || 0x2BDE3B40
|}
|}
=== _sceKernelLockLwMutex ===
 
=== SceThreadmgrForDriver_2E95B628 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9C572180
| 3.60 || 0x2E95B628
|}
|}
=== _sceKernelChangeThreadCpuAffinityMask ===
 
=== SceThreadmgrForDriver_2F9F75AA ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9C921F8D
| 3.60 || 0x2F9F75AA
|}
|}
=== _sceKernelOpenMutex ===
 
=== SceThreadmgrForDriver_2FC0FFF6 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9D291788
| 3.60 || 0x2FC0FFF6
|}
|}
=== sceKernelGetProcessId ===
 
=== sceKernelDeleteRWLockForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0x9DCB4B7A
| 3.60 || 0x32452017
|}
|}
=== sceKernelCloseSema ===
 
=== sceKernelGetTimerEventRemainingTimeForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xA2D81F9E
| 3.60 || 0x3634FFE6
|}
|}
=== sceKernelCloseMutex_089 ===
 
<source lang="C">int sceKernelGetTimerEventRemainingTimeForDriver(SceUID timerId, SceUInt64 *time);</source>
 
=== SceThreadmgrForDriver_36F8E58A ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xA35427EE
| 3.60 || 0x36F8E58A
|}
|}
=== sceKernelNotifyCallback ===
 
=== sceKernelGetRWLockInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xA4683592
| 3.60 || 0x374C3267
|}
|}
=== _sceKernelCloseMsgPipe ===
 
=== threadmgrGpuExceptionHandlerForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xAA888831
| 3.60 || 0x37F51E91
|}
|}
=== sceKernelDeleteTimer ===
 
=== sceKernelChangeThreadPriorityAndCpuAffinityMaskForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xAB1E42C4
| 3.60 || 0x3857C94E
|}
|}
=== _sceKernelGetTimerInfo ===
 
=== SceThreadmgrForDriver_3A72C6D8 ===
{| class="wikitable"
{| class="wikitable"
! Version !! NID
|-
|-
| 3.60 || 0x3A72C6D8
|}
=== SceThreadmgrForDriver_3C297724 ===
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xAC7FE4F3
| 3.60 || 0x3C297724
|}
|}
=== sceKernelCloseTimer ===
 
=== SceThreadmgrForDriver_3F5E1D56 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xACE60E4A
| 3.60 || 0x3F5E1D56
|}
|}
=== _sceKernelCreateRWLock ===
 
=== SceThreadmgrForDriver_419E6736 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xB1877F5E
| 3.60 || 0x419E6736
|}
|}
=== sceKernelCreateCallback ===
 
=== SceThreadmgrForDriver_477F7C8A ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xB19CF7E9
| 3.60 || 0x477F7C8A
|}
|}
=== _sceKernelGetThreadInfo ===
 
=== SceThreadmgrForDriver_47F26712 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0xB373D8A1
| 3.60 || 0x47F26712
|}
|}
Used to unregister a Threadmgr interrupt handler. See [[SceKernelThreadMgr#SceThreadmgrForDriver_6C2E3A49|SceThreadmgrForDriver_6C2E3A49]].


<source lang="c">
<source lang="c">
typedef struct get_thread_info_opt
//Pass same slot and kind as to SceThreadmgrForDriver_6C2E3A49.
{
int SceThreadmgrForDriver_47F26712(unsigned slot, unsigned kind);
  uint32_t size; // size of SceKernelThreadInfo
  uint32_t unk;
}get_thread_info_opt;
 
int _sceKernelGetThreadInfo(SceUID thid, SceKernelThreadInfo *info, get_thread_info_opt* opt)
</source>
</source>


=== _sceKernelTrySendMsgPipeVector ===
=== SceThreadmgrForDriver_48C06CD6_waitWorkQueue ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xB3D600AB
| 3.60 || 0x48C06CD6
|}
|}
=== sceKernelUnlockWriteRWLock ===
 
=== sceKernelSetVfpRegisterForDebuggerForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xB4151397
| 3.60 || 0x49A0B679
|}
|}
=== _sceKernelGetThreadStackFreeSize ===
 
=== SceThreadmgrForDriver_4A038803 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xB5EC061A
| 3.60 || 0x4A038803
|}
|}
=== _sceKernelDeleteMsgPipe ===
 
=== SceThreadmgrForDriver_4DE77569 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xB6D50FCC
| 3.60 || 0x4DE77569
|}
|}
=== sceKernelOpenTimer ===
 
=== SceThreadmgrForDriver_5311CFB5 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xB6E286E7
| 0.990.000-3.740.011 || 0x5311CFB5
|}
|}
=== _sceKernelGetSystemTime ===
 
Registers exception handler.
 
Used by [[SceAppMgr]].
 
<source lang="C">int SceThreadmgrForDriver_5311CFB5(int (* handler)(SceUID pid, SceUID thid, int cause_flag, void *argp), void *argp);</source>
 
=== SceThreadmgrForDriver_54566860 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xB70EBAE9
| 3.60 || 0x54566860
|}
|}
=== _sceKernelChangeThreadVfpException ===
 
=== sceKernelCountWaitingThreadsProcForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xB8F165B4
| 3.60-3.65 || 0x54E1AF04
|}
|}
=== _sceKernelOpenSema ===
 
Count the number of threads from a specified process waiting on a Waitable object.
 
<source lang="c">
SceSSize sceKernelCountWaitingThreadsProcForDriver(ScePID processId, SceUID waitableId);
</source>
 
=== SceThreadmgrForDriver_555CA6BB ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xB96FED7D
| 3.60 || 0x555CA6BB
|}
|}
=== _sceKernelGetThreadTLSAddr ===
 
=== SceThreadmgrForDriver_56C18B11 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xBACA6891
| 3.60 || 0x56C18B11
|}
|}
=== sceKernelOpenEventFlag ===
 
=== SceThreadmgrForDriver_5870C73A ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xBC19F8A1
| 3.60 || 0x5870C73A
|}
|}
=== _sceKernelTryLockMutex ===
 
=== SceThreadmgrForDriver_5D8F88B1 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xBCFB867F
| 3.60 || 0x5D8F88B1
|}
|}
=== sceKernelChangeThreadPriority ===
 
=== sceKernelSetCpuRegisterForDebuggerForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xBD0139F2
| 3.60 || 0x64E89DE9
|}
|}
=== sceKernelCreateThreadForUser ===
 
=== sceKernelGetRWLockInfoAllProcForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC0FAF6A3
| 3.60 || 0x6624E612
|}
|}
=== _sceKernelSendSignal ===
 
=== SceThreadmgrForDriver_6657429E ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC21FC992
| 3.60 || 0x6657429E
|}
|}
=== _sceKernelCloseRWLock ===
 
=== SceThreadmgrForDriver_67022B18 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC239DBCC
| 3.60 || 0x67022B18
|}
|}
=== sceKernelSignalCondAll ===
 
=== SceThreadmgrForDriver_6C2E3A49 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC2E7AC22
| 3.60 || 0x6C2E3A49
|}
|}
=== _sceKernelStartThread ===
 
Register a Threadmgr interrupt handler.
 
<source lang="c">
//Specify 0 or 1 for slot.
//Specify one of the following for kind, to select which "interrupt" the handler is registered for:
// 0 -> Thread events (To determine event, check argp->unk0: 1 = DeleteThread, 2 = StartThread)
// 1 -> Vfp
// 2 -> Gpu Exception
// 3 -> Stack overflow
// 4 -> Syscall Error - Illegal Context
// 5 -> Syscall Error - Critical Usage
// 6 -> Syscall Error - Illegal Number
// 7 -> ApiDeclareSuicide (unknown what this is for)
int SceThreadmgrForDriver_6C2E3A49(unsigned slot, unsigned kind, void (*handler)(int args, void* argp));
</source>
 
=== SceThreadmgrForDriver_6D4C1EB7 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC30B1745
| 3.60 || 0x6D4C1EB7
|}
|}
=== _sceKernelSignalLwCond ===
 
=== SceThreadmgrForDriver_738FF63D ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC37F6983
| 3.60 || 0x738FF63D
|}
|}
=== _sceKernelStartTimer ===
 
=== sceKernelTryLockFastMutexForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC3ED6E4A
| 3.60 || 0x741F4707
|}
|}
=== _sceKernelCloseSimpleEvent ===
 
<source lang="C">int sceKernelTryLockFastMutexForDriver(void *pFastMutex);</source>
 
=== SceThreadmgrForDriver_767CA30C ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC6FFE335
| 3.60 || 0x767CA30C
|}
|}
=== _sceKernelGetThreadRunStatus ===
 
=== sceKernelCancelRWLockForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC7FB5497
| 3.60 || 0x7A4EF925
|}
|}
=== sceKernelGetThreadmgrUIDClass ===
 
=== SceThreadmgrForDriver_7D12344A ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC9678F7F
| 3.60 || 0x7D12344A
|}
|}
=== _sceKernelStopTimer ===
 
=== SceThreadmgrForDriver_7E280B69 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xC96F4269
| 3.60 || 0x7E280B69
|}
|}
=== sceKernelDeleteMutex ===
 
=== SceThreadmgrForDriver_84EB1EA4 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xCB78710D
| 3.60 || 0x84EB1EA4
|}
|}
=== sceKernelOpenSema ===
 
=== SceThreadmgrForDriver_85F4DC8C ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xCBE235C7
| 3.60 || 0x85F4DC8C
|}
|}
=== _sceKernelCreateCond ===
 
=== sceKernelCancelSemaForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xCC14FA59
| 3.60 || 0x8760C8ED
|}
|}
=== sceKernelChangeThreadVfpException ===
 
=== SceThreadmgrForDriver_88206D29 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xCC18FBAE
| 3.60 || 0x88206D29
|}
|}
=== sceKernelOpenRWLock ===
 
=== SceThreadmgrForDriver_89CA5698 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xCE510196
| 3.60 || 0x89CA5698
|}
|}
=== _sceKernelCancelMsgPipe ===
 
=== SceThreadmgrForDriver_8C3C1F78 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xCE769C83
| 3.60 || 0x8C3C1F78
|}
|}
=== _sceKernelWaitSignalCB ===
 
=== SceThreadmgrForDriver_8C48E53B ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xCEA3FC52
| 3.60 || 0x8C48E53B
|}
|}
=== _sceKernelCancelRWLock ===
 
=== sceKernelIsUserModeThreadForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD004EA15
| 3.60 || 0x91382762
|}
|}
=== sceKernelLockMutexCB_089 ===
 
=== sceKernelDeleteTimerForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD06F2886
| 3.60 || 0x91A8F38B
|}
|}
=== _sceKernelGetThreadExitStatus ===
 
<source lang="C">int sceKernelDeleteTimerForDriver(SceUID timerId);</source>
 
=== sceKernelSetTimerEventForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD3210C08
| 3.60 || 0x92A3DCDD
|}
|}
=== _sceKernelWaitThreadEnd_0910 ===
 
<source lang="C">int sceKernelSetTimerEventForDriver(SceUID timerId, int type, SceUInt64 *time, SceBool repeat);</source>
 
=== SceThreadmgrForDriver_995F32E1 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD38231C9
| 3.60 || 0x995F32E1
|}
|}
=== sceKernelDeleteCallback ===
 
=== SceThreadmgrForDriver_A64B00F6 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD469676B
| 3.60 || 0xA64B00F6
|}
|}
=== _sceKernelSetThreadContextForVM ===
 
=== SceThreadmgrForDriver_A90B1E01 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD4785C41
| 3.60 || 0xA90B1E01
|}
|}
=== sceKernelSendSignal ===
 
=== SceThreadmgrForDriver_AB977C72 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD4C367B2
| 3.60-3.65 || 0xAB977C72
|}
|}
=== _sceKernelDeleteCond ===
 
Reads the <code>currentAttr</code> field of the active thread into <code>*pAttr</code>.
 
A potential name for this function is <code>sceKernelGetCurrentThreadAttr</code>.
 
<source lang="c">
SceInt32 SceThreadmgrForDriver_AB977C72(SceUInt32 *pAttr);
</source>
 
=== SceThreadmgrForDriver_AF302193 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD99F51D3
| 3.60 || 0xAF302193
|}
|}
=== sceKernelCheckWaitableStatus ===
 
=== SceThreadmgrForDriver_B4A05763 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD9BD74EB
| 3.60 || 0xB4A05763
|}
|}
=== _sceKernelGetLwCondInfoById ===
 
{| class="wikitable"
Registers the low-power idle loop. Used by [[SceLowio]].
|-
 
Once registered, the idle threads will execute this function instead of the basic idle loop.
 
To get a better understanding, note that the idle threads' code is equivalent to:
<source lang="c">
/* N.B.: lpidle_ptr is set by calling SceThreadmgrForDriver_B4A05763 */
 
while (lpidle_ptr == NULL) {
    __disable_irq(); /* cpsid i */
    __WFI();
    __enable_irq();  /* cpsie i */
}
/* This should never return! */
lpidle_ptr();
</source>
 
<source lang="C">
void SceThreadmgrForDriver_B4A05763( void (*low_power_idle_loop)(void) );
</source>
 
=== sceKernelGetWaitingThreadListForDriver ===
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xD9E78D30
| 3.60 || 0xB5C782A3
|}
|}
=== _sceKernelPollEventFlag ===
 
=== SceThreadmgrForDriver_B6DA4669 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xDAB1B1C8
| 3.60 || 0xB6DA4669
|}
|}
=== sceKernelDeleteSema ===
 
=== sceKernelCancelEventForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xDB32948A
| 3.60 || 0xB6FA8305
|}
|}
=== _sceKernelLockMutexCB ===
 
=== SceThreadmgrForDriver_C03799E2 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xDB9F5333
| 3.60 || 0xC03799E2
|}
|}
=== _sceKernelLockWriteRWLockCB ===
 
=== SceThreadmgrForDriver_C2DA6286 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xDBD09B09
| 3.60 || 0xC2DA6286
|}
|}
=== _sceKernelOpenRWLock ===
 
=== SceThreadmgrForDriver_C327CA7C ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xDFCEE5AB
| 3.60 || 0xC327CA7C
|}
|}
=== _sceKernelDeleteMutex ===
 
=== SceThreadmgrForDriver_C4456EC9 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xE0A6D759
| 3.60 || 0xC4456EC9
|}
|}
=== _sceKernelSetTimerEvent ===
 
=== SceThreadmgrForDriver_C6741986 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xE2C0BFEF
| 3.60 || 0xC6741986
|}
|}
=== _sceKernelOpenSimpleEvent ===
 
=== SceThreadmgrForDriver_C7F5FFE0 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xE326EA7A
| 3.60 || 0xC7F5FFE0
|}
|}
=== sceKernelCheckCallback ===
 
=== SceThreadmgrForDriver_CA704239 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xE53E41F6
| 3.60 || 0xCA704239
|}
|}
=== _sceKernelChangeThreadPriority ===
 
=== sceKernelGetTimerTimeForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xE61C2B06
| 3.60 || 0xCB795E13
|}
|}
=== sceKernelSignalSema ===
 
<source lang="C">int sceKernelGetTimerTimeForDriver(SceUID timerId, SceUInt64 *time);</source>
 
=== SceThreadmgrForDriver_CBA7FAAA ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xE6B761D1
| 3.60 || 0xCBA7FAAA
|}
|}
=== sceKernelDeleteRWLock ===
 
=== SceThreadmgrForDriver_CFA2FFAF ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xE73649CA
| 3.60 || 0xCFA2FFAF
|}
|}
=== sceKernelDeleteMsgPipe ===
 
=== SceThreadmgrForDriver_D0262C55 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xE78BCCF7
| 3.60 || 0xD0262C55
|}
|}
=== _sceKernelCloseSema ===
 
=== sceKernelPollEventForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xE8C03447
| 3.60 || 0xD08C71C6
|}
|}
=== _sceKernelGetMutexInfo ===
 
=== SceThreadmgrForDriver_D1FBDFA6 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69-3.60 || 0xE8CC3DF0
| 3.60 || 0xD1FBDFA6
|}
|}


<source lang="C">
=== SceThreadmgrForDriver_D26BFF26 ===
typedef struct _sceKernelGetMutexInfo_opt
{
  int unk_0;
  int unk_4;
}_sceKernelGetMutexInfo_opt;
 
int _sceKernelGetMutexInfo(SceUID mutexid, SceKernelMutexInfo *info, _sceKernelGetMutexInfo_opt* opt);</source>
 
=== _sceKernelWaitThreadEnd ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xEA5C52F5
| 3.60 || 0xD26BFF26
|}
|}
=== _sceKernelTryLockReadRWLock ===
 
=== sceKernelGetTimerBaseForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xEB9054B2
| 3.60 || 0xD41F53D4
|}
|}
=== sceKernelSetEventFlag ===
 
<source lang="C">int sceKernelGetTimerBaseForDriver(SceUID timerId, SceUInt64 *result);</source>
 
=== SceThreadmgrForDriver_D7455187 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xEC94DFF7
| 3.60 || 0xD7455187
|}
|}
=== sceKernelTryLockReadRWLock ===
 
=== SceThreadmgrForDriver_D74F66BD ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xEFDDA456
| 3.60 || 0xD74F66BD
|}
|}
=== _sceKernelClearEventFlag ===
 
=== sceKernelGetFastMutexInfoForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xF0526CE2
| 3.60 || 0xD7AF2E58
|}
|}
=== sceKernelGetThreadCpuAffinityMask ===
 
This is a guessed name.
 
<source lang="C">int sceKernelGetFastMutexInfoForDriver(void *pFastMutex, void *pInfo);</source>
 
=== sceKernelSetTimerTimeForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xF1AE5654
| 3.60 || 0xD978D16F
|}
|}
=== sceKernelWaitThreadEnd_089 ===
 
<source lang="C">int sceKernelSetTimerTimeForDriver(SceUID timerId, SceUInt64 *time);</source>
 
=== sceKernelChangeThreadPriorityForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xF3489EF4
| 3.60 || 0xDA1544D1
|}
|}
=== sceKernelGetSystemTimeWide ===
 
=== sceKernelUIDInheritedEventClassInitForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xF4EE4FA9
| 3.60 || 0xDBB77032
|}
|}
=== _sceKernelPulseEvent ===
 
=== SceThreadmgrForDriver_E0C7BCBB ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xF6A0FE84
| 3.60 || 0xE0C7BCBB
|}
|}
=== _sceKernelCloseEventFlag ===
 
=== SceThreadmgrForDriver_E2B57231 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xF6CFB4F1
| 3.60 || 0xE2B57231
|}
|}
=== _sceKernelSendMsgPipeVectorCB ===
 
=== sceKernelCancelEventWithSetPatternForDriver ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xF6D515DC
| 3.60 || 0xE5CAD3E2
|}
|}
=== _sceKernelDeleteSimpleEvent ===
 
=== SceThreadmgrForDriver_E6D80698 ===
{| class="wikitable"
{| class="wikitable"
|-
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xF7413EC7
| 3.60 || 0xE6D80698
|}
|}
=== _sceKernelCancelEventFlag ===
 
{| class="wikitable"
=== SceThreadmgrForDriver_E938FB20 ===
|-
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xF76F3056
| 3.60 || 0xE938FB20
|}
|}
=== _sceKernelWaitSemaCB ===
 
{| class="wikitable"
=== SceThreadmgrForDriver_E9E50096 ===
|-
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xF8E06784
| 3.60 || 0xE9E50096
|}
|}
=== _sceKernelWaitThreadEndCB ===
 
{| class="wikitable"
=== sceKernelCancelEventFlagForDriver ===
|-
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xFA3D4491
| 3.60 || 0xEA211225
|}
|}
=== _sceKernelOpenEventFlag ===
 
{| class="wikitable"
=== sceKernelCancelTimerForDriver ===
|-
{| class="wikitable"
! Version !! NID
! Version !! NID
|-
|-
| 1.69 || 0xFA64FB37
| 3.60 || 0xF285C94F
|}
|}
=== _sceKernelUnregisterCallbackFromEvent ===
 
{| class="wikitable"
<source lang="C">int sceKernelCancelTimerForDriver(SceUID timerId, SceUInt32 *a2);</source>
|-
 
! Version !! NID
=== SceThreadmgrForDriver_F2C9DC97 ===
|-
{| class="wikitable"
| 1.69 || 0xFB66565E
! Version !! NID
|}
|-
=== _sceKernelWaitEventFlag ===
| 3.60 || 0xF2C9DC97
{| class="wikitable"
|}
|-
 
! Version !! NID
=== sceKernelChangeThreadVfpExceptionForDriver ===
|-
{| class="wikitable"
| 1.69 || 0xFCE2F728
! Version !! NID
|}
|-
=== sceKernelCloseRWLock ===
| 3.60 || 0xF4C81683
{| class="wikitable"
|}
|-
 
! Version !! NID
=== SceThreadmgrForDriver_F5074173 ===
|-
{| class="wikitable"
| 1.69 || 0xFD5BD5C1
! Version !! NID
|}
|-
=== _sceKernelGetLwMutexInfoById ===
| 3.60 || 0xF5074173
{| class="wikitable"
|}
|-
 
! Version !! NID
=== SceThreadmgrForDriver_F8A6013B ===
|-
{| class="wikitable"
| 1.69 || 0xFEC9E946
! Version !! NID
|-
| 3.60 || 0xF8A6013B
|}
 
=== SceThreadmgrForDriver_F96FE0D5 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xF96FE0D5
|}
 
=== SceThreadmgrForDriver_FD6150D5 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xFD6150D5
|}
 
=== SceThreadmgrForDriver_FD87586C ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xFD87586C
|}
 
=== sceKernelGetCallbackInfoForDriver ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xFDC044AC
|}
 
=== SceThreadmgrForDriver_FF8DA217 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xFF8DA217
|}
 
== SceThreadmgrForKernel ==
 
=== sceKernelCpuScanThreadForProcessmgrForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.65 || 0x01369E06
|}
 
=== sceKernelSetDTraceThreadCBEnableForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xBE5247A2
|-
| 3.65 || 0x0AE9C713
|}
 
=== sceKernelSetSyslibtraceThreadCBEnableForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x5A410D2B
|-
| 3.65 || 0x4F2B45DC
|}
 
=== sceKernelSetThreadMgrTestModeForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.65 || 0x1394E856
|}
 
=== sceKernelClearThreadMgrTestModeForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.65 || 0x5D270A94
|}
 
=== sceKernelThreadMgrProcessCreateForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.65 || 0xB46502E6
|}
 
=== sceKernelThreadMgrProcessDeleteAfterPUIDCloseForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xF282AE42
|-
| 3.65 || 0x5A23A1BE
|}
 
=== sceKernelThreadMgrProcessDeleteBeforePUIDCloseForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x1928DFBB
|-
| 3.65 || 0x205506FC
|}
 
=== sceKernelRegisterKTLSForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990.000-1.692.000 || 0xB645C7EF
|-
| 1.80-3.740.011 || not present. Still present in [[#SceThreadmgrForDriver]].
|}
 
Temp name was sceKernelAllocateKTLSForKernel.
 
See [[#sceKernelRegisterKTLSForDriver]].
 
=== sceKernelUnregisterKTLSForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990.000-1.692.000 || 0x8C3C1F78
|-
| 1.80-3.740.011 || not present. Still present in [[#SceThreadmgrForDriver]].
|}
 
See [[#sceKernelUnregisterKTLSForDriver]].
 
=== SceThreadmgrForKernel_89CA5698 ===
{| class="wikitable"
! Version !! NID
|-
| 0.990.000-1.692.000 || 0x89CA5698
|-
| 1.80-3.740.011 || not present. Still present in [[#SceThreadmgrForDriver]].
|}
 
See [[#SceThreadmgrForDriver_89CA5698]].
 
=== SceThreadmgrForKernel_3A72C6D8 ===
{| class="wikitable"
! Version !! NID
|-
| 0.990.000-1.692.000 || 0x3A72C6D8
|-
| 1.80-3.740.011 || not present. Still present in [[#SceThreadmgrForDriver]].
|}
 
See [[#SceThreadmgrForDriver_3A72C6D8]].
 
=== sceKernelSetEventWithNotifyCallbackForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.995 || 0xB7DF3EDF
|-
| 3.60 || not present. Moved to ForDriver. [[SceKernelThreadMgr#sceKernelSetEventWithNotifyCallbackForDriver]]
|}
 
=== sceKernelSetEventFlagForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.931 || 0xD4780C3E
|-
| 3.60 || in ForDriver
|}
 
=== SceThreadmgrForKernel_05F5306C ===
{| class="wikitable"
! Version !! NID
|-
| 0.990 || 0x05F5306C
|-
| 3.60 || not present
|}
 
Uses [[KBL_Param#DIP_Switches|DIP switch]] 216.
 
=== SceThreadmgrForKernel_CA84C603 ===
{| class="wikitable"
! Version !! NID
|-
| 0.990 || 0xCA84C603
|-
| 3.60 || not present
|}
 
Uses [[KBL_Param#DIP_Switches|DIP switch]] 216.
 
=== sceKernelGetDefaultCpuAffinityMaskForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990 || not present
|-
| 3.60 || 0x091322E5
|-
| 3.65 || 0xD9C097DD
|}
 
=== sceKernelDebugSuspendThreadForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.931-0.990 || 0xFB3706CB
|-
| 3.60 || not present
|}
 
<source lang="C">int sceKernelDebugSuspendThreadForKernel(SceUID threadId, SceUInt32 status);</source>
 
=== SceThreadmgrForKernel_86DAE59B ===
{| class="wikitable"
! Version !! NID
|-
| 0.931-0.990 || 0x86DAE59B
|-
| 3.60 || not present
|}
 
Get maybe current CPU mask.
 
<source lang="C">int SceThreadmgrForKernel_86DAE59B(void);</source>
 
=== sceKernelGetCurrentThreadUnkInfoForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.931-0.990 || 0x332E127C
|-
| 3.60 || To ForDriver
|}
 
Get some current thread information.
 
<source lang="C">int sceKernelGetCurrentThreadUnkInfoForKernel(void);</source>
 
=== SceThreadmgrForKernel_33E85E9E ===
{| class="wikitable"
! Version !! NID
|-
| 0.931-3.60 || 0x33E85E9E
|}
 
<source lang="C">
typedef struct SceThreadmgrForKernel_33E85E9E_buf { // size is 0x34 on FW 0.990
  SceSize size; // Size of this structure
  char unk[0x30];
} SceThreadmgrForKernel_33E85E9E_buf;
 
int SceThreadmgrForKernel_33E85E9E(SceThreadmgrForKernel_33E85E9E_buf *buf);
</source>
 
=== sceKernelPMonThreadSetEventForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.60 || 0x6ECCDCBD
|}
 
=== sceKernelPMonSetControlRegisterForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990.000-2.060.011 || 0x1AAFA818
|-
| 2.100.081-3.740.011 || not present. Moved to [[#SceThreadmgrForDriver]].
|}
 
See [[#sceKernelPMonSetControlRegisterForDriver]].
 
=== sceKernelPMonSetUserEnableRegisterForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990.000-2.060.011 || 0x5053B005
|-
| 2.100.081-3.740.011 || not present. Moved to [[#SceThreadmgrForDriver]].
|}
 
See [[#sceKernelPMonSetUserEnableRegisterForDriver]].
 
=== sceKernelPMonThreadSetEnableCounterForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990.000-3.610.011 || 0x72E5DA4E
|-
| 3.630.011-3.740.011 || 0x7F831213
|}
 
=== sceKernelPMonThreadSetCounterForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990.000-3.610.011 || 0xD2BE5EFB
|-
| 3.630.011-3.740.011 || 0x7B3368F1
|}
 
=== sceKernelPMonThreadClearEnableCounterForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990.000-3.610.011 || 0x43D13895
|-
| 3.630.011-3.740.011 || 0x1D2A6815
|}
 
=== sceKernelGetThreadIdListForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990.000-1.692.000 || 0xEA7B8AEF
|-
| 1.80-3.740.011 || not present. Still present in [[SceThreadmgrForDriver]].
|}
 
See [[#sceKernelGetThreadIdListForDriver]].
 
=== sceKernelCreateTimerForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990 || 0x90656C98
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
<source lang="C">int sceKernelCreateTimerForKernel(const char *name, uint32_t attr);</source>
 
=== sceKernelLockMutex_089ForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x16AC80C5
|}
 
<source lang="C">int sceKernelLockMutex_089ForKernel(SceUID mutex_id, int unk1, int unk2);</source>
 
=== sceKernelUnlockMutex_089ForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.60 || 0x1E82E5D0
|}
 
<source lang="C">int sceKernelUnlockMutex_089ForKernel(SceUID mutex_id, int unk1);</source>
 
=== sceKernelLockMutexCB_089ForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0xD06F2886
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelTryLockMutex_089ForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x270993A6
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelCreateMutexForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0xFBAA026E
|}
 
<source lang="C">SceUID sceKernelCreateMutexForKernel(const char *pName, SceUInt attr, int initCount, const SceKernelMutexOptParam *pOptParam);</source>
 
=== sceKernelDeleteMutexForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x0A912340
|}
 
<source lang="C">int sceKernelDeleteMutexForKernel(SceUID mutexid);</source>
 
=== sceKernelGetMutexInfo_089ForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x69B78A12
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
<source lang="C">int sceKernelGetMutexInfo_089ForKernel(SceUID mutexid, SceKernelMutexInfo *info);</source>
 
=== sceKernelCancelMutex_089ForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x7204B846
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelSetThreadAccessLevelForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.60 || 0x02EEDF17
|}
 
Temp name was sceKernelSetPermissionForKernel.
 
<source lang="C">
// return value is previous value
int sceKernelSetThreadAccessLevelForKernel(int value);
</source>
 
=== sceKernelCreateSemaForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.60 || 0x30E93C31
|}
 
<source lang="C">
/**
* Creates a new semaphore
*
* @par Example:
* @code
* int semaid;
* semaid = sceKernelCreateSemaForKernel("MySema", 0, 1, 1, 0);
* @endcode
*
* @param name - Specifies the name of the sema
* @param attr - Sema attribute flags (normally set to 0)
* @param initVal - Sema initial value
* @param maxVal - Sema maximum value
* @param option - Sema options (normally set to 0)
* @return A semaphore id
*/
SceUID sceKernelCreateSemaForKernel(const char *name, SceUInt attr, int initVal, int maxVal, SceKernelSemaOptParam *option);
</source>
 
=== sceKernelSignalSemaForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xD270498B
|}
 
=== sceKernelWaitSemaForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x3C8B55A9
|}
 
<source lang="C">
/**
* Lock a semaphore
*
* @par Example:
* @code
* sceKernelWaitSemaForKernel(sema_id, 1, 0);
* @endcode
*
* @param sema_id - The sema id returned from ::sceKernelCreateSemaForKernel
* @param signal - The value to wait for (i.e. if 1 then wait till reaches a signal state of 1)
* @param timeout - Timeout in microseconds (assumed).
*
* @return < 0 on error.
*/
int sceKernelWaitSemaForKernel(SceUID sema_id, int signal, SceUInt *timeout);
</source>
 
=== sceKernelDeleteSemaForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.60 || 0x16A35E58
|}
 
=== sceKernelStartThread_089ForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-1.69 || 0x21F5419B
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
<source lang="C">
/**
* @brief Thread activation
*
* Starts the thread specified by threadId and puts it in READY state.
*
* The argument block specified by argSize and argBlock is copied onto the thread stack, argSize is
* passed directly to the first argument of the thread entry function, and the second argument of
* the entry function is the argument copied onto the stack. The block address is passed.
*
* This system call does not queue activation requests. In other words, if the target thread is not
* in the DORMANT state, an SCE_KERNEL_ERROR_NOT_DORMANT error is returned to the calling thread.
*
* @param threadId Specify the identifier of the thread to be started.
* @param argSize Specify the size (byte) of the argument to be passed to the thread.
* @param pArgBlock Specify the address of the argument to be passed to the thread.
* @retval SCE_OK Success
* @retval Negative value Error code
*/
SceInt32 sceKernelStartThread_089ForKernel(
SceUID threadId,
SceSize argSize,
const void *pArgBlock
);
</source>
 
=== sceKernelWaitThreadEnd_089ForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0xF3489EF4
|-
| 3.60 || not present
|}
 
=== sceKernelDelayThreadForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x4B675D05
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelDelayThreadUnkCBForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990 || 0x2B60B793
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelDelayThreadUnkForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990 || 0xE9A99C50
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelStopThreadForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.60 || 0x150AEF74
|}
 
=== sceKernelSuspendThreadForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.931-3.60 || 0xAEEE955F
|}
 
<source lang="C">
// semaId must be strictly between 0 and 255
int sceKernelSuspendThreadForKernel(SceUID threadId, SceUID semaId);
</source>
 
=== sceKernelWaitThreadEndCB_089ForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x0373C5E3
|-
| 3.60 || not present
|}
 
=== sceKernelExitThreadForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x0C8A38E1
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
<source lang="C">
/**
* @brief End of own thread
*
* Terminates the own thread normally and shifts to the DORMANT state.
* sceKernelExitThread() is a system call that does not return to the context of the issuer.
*
* Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
* However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
* The mutex is unlocked and not deleted.
*
* When the terminated thread is restarted with sceKernelStartThread(), the information included in the thread
* management area, such as thread priority, is reset.
* It will not inherit the one at the end.
*
* When a thread exits, exitStatus becomes the exit status of that thread.
*
* If the thread is terminated by a return from the entry function without using
* sceKernelExitThread(), the return value of the entry function becomes the termination status.
*
* The end status of a thread can be obtained by sceKernelGetThreadExitStatus() and sceKernelGetThreadInfo(),
* and when another thread waits for the end of the thread by sceKernelWaitThreadEnd(), it can be obtained by the return value.
*
* The thread exit status is saved while the thread exits and is in the DORMANT state,
* but the value is lost if the thread is restarted or deleted with sceKernelStartThread().
*
* @param exitStatus Specify the value to be set for the termination status of the local thread.
* @retval Negative value Error code
*/
SceInt32 sceKernelExitThreadForKernel(
SceInt32 exitStatus
);
</source>
 
=== sceKernelExitDeleteThreadForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x1D17DECF
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
<source lang="C">
/**
* @brief End and delete own thread
*
* Terminates the own thread normally and deletes it.
* sceKernelExitDeleteThread() is a system call that does not return to the context of the issuer.
*
* Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
* However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
* The mutex is unlocked and not deleted.
*
* When a thread exits, exitStatus becomes the exit status of that thread (sceKernelExitDeleteThread()
* directly deletes the thread without going through the DORMANT state.
* (It cannot be obtained by sceKernelGetThreadInfo(). The end status can be obtained by the return
* value only when waiting for the end of the thread by sceKernelWaitThreadEnd().)
*
* @param exitStatus Specify the value to be set for the termination status of the local thread.
* @retval Negative value Error code
*/
SceInt32 sceKernelExitDeleteThreadForKernel(
SceInt32 exitStatus
);
</source>
 
=== sceKernelDelayThreadCBForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x9C0180E1
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelGetThreadCurrentPriorityForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x01414F0B
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelChangeCurrentThreadAttrForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x751C9B7A
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelCpuScanThreadForProcessmgrForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.60 || 0x3B4B8293
|}
 
<source lang="C">int sceKernelCpuScanThreadForProcessmgrForKernel(void *a1);</source>
 
=== sceKernelGetProcessIdForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.931-1.69 || 0x9DCB4B7A
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
Returns the process ID.
 
<source lang="C">SceUID sceKernelGetProcessIdForKernel(void);</source>
 
=== sceKernelChangeActiveCpuMaskForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0x001173F8
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelCheckWaitableStatusForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0xD9BD74EB
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== sceKernelCheckCallbackForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69 || 0xE53E41F6
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
=== _sceKernelExtendKernelStackWideForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.60 || 0xE54FD746
|}
 
Temp name was sceKernelRunWithStackForKernel.
 
This takes a function and runs it exclusively on the current core on its own stack.
 
<source lang="c">
// stack_size should be 0x2000
int _sceKernelExtendKernelStackWideForKernel(int stack_size, void *func, void *args);
</source>
 
=== sceKernelExtendKernelStackWideForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-1.69 || 0xA2C801A5
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
Temp name was sceKernelRunWithStack2ForKernel.
 
<source lang="c">
// stack_size should be 0x2000
SceInt64 sceKernelExtendKernelStackWideForKernel(int stack_size, void *func, void *args);
</source>
 
=== sceKernelExtendKernelStackWide2ForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990 || 0x236AF33A
|-
| 3.60 || unk
|}
 
<source lang="c">
// stack_size should be 0x2000
int sceKernelExtendKernelStackWide2ForKernel(int stack_size, void *func, void *args);
</source>
 
=== sceKernelGetThreadContextInfoForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.931-3.60 || 0xD8B9AC8D
|-
| 3.65-3.67 || 0x6C1F092F
|}
 
Temp name was sceKernelGetFaultingProcessForKernel.
 
Returns information about the thread currently scheduled on caller CPU.
 
This function can be called from an exception or interrupt handler, in which case it returns information about the thread that was interrupted.
 
<source lang="C">
struct SceKernelThreadContextInfo { // Previous name: SceKernelFaultingProcessInfo
    ScePID processId; //<! GUID of the process the currently scheduled thread
    SceUID threadId;  //<! GUID of the thread currently scheduled
};
 
SceInt32 sceKernelGetThreadContextInfoForKernel(struct SceKernelThreadContextInfo * pInfo);
</source>
 
=== sceKernelCloseEventFlagForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 0.990 || 0x71ECB352
|-
| 3.60 || not present. Moved to ForDriver.
|}
 
Temp name was sceKernelDeleteEventFlagForKernel.
 
See [[#sceKernelCloseEventFlagForDriver]].
 
=== SceThreadmgrForKernel_E0833C77 ===
{| class="wikitable"
! Version !! NID
|-
| 0.990-3.57 || not present. Added on FW 3.60.
|-
| 3.60 || 0xE0833C77
|}
 
=== sceKernelSetThreadMgrTestModeForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x333B26AD
|}
 
<source lang="C">int sceKernelSetThreadMgrTestModeForKernel(void);</source>
 
=== sceKernelClearThreadMgrTestModeForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0xE00333A6
|}
 
<source lang="C">int sceKernelClearThreadMgrTestModeForKernel(void);</source>
 
=== sceKernelSetThreadDebugCallbackForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x41CF346A
|}
 
This is a guessed name.
 
<source lang="C">
typedef struct SceThreadDebugCallbackParam {
union {
struct {
SceKernelThreadEntry entry;
SceUID thid;
SceUID pid;
} create;
struct {
SceUID  pid;
SceUID  thid;
SceSize argc;
void  *argp;
} start;
};
} SceThreadDebugCallbackParam;
 
typedef int (* SceKernelThreadDebugCallback)(int a1, int a2, SceThreadDebugCallbackParam param);
 
int (* sceKernelSetThreadDebugCallback)(SceKernelThreadDebugCallback callback);
</source>
 
Code example:
<source lang="C">
int sceKernelThreadDebugCallback(int a1, int a2, SceThreadDebugCallbackParam param){
// start thread
if (a1 == 2 && a2 == 4) {
ksceDebugPrintf(
"%s:start pid:0x%08X thid:0x%08X argc:0x%08X argp:0x%08X\n",
__FUNCTION__, param.start.pid, param.start.thid, param.start.argc, param.start.argp
);
} else if (a1 == 0 && a2 == 3) { // create thread
} else if (a1 == 7 && a2 == 3) { // some timer (in SceThreadmgrTimer handler)
} else if (a1 == 6 && a2 == 1) { // unknown (in SceThreadmgrForDriver_44CCF310)
} else if (a1 == 1 && a2 == 2) { // delete thread (In sub_81000D78)
}
return 0;
}
</source>
 
=== SceThreadmgrForKernel_000DF999 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x000DF999
|}
 
=== sceKernelGetCpuRegisterForDebuggerForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x09444C33
|}
 
<source lang="C">int sceKernelGetCpuRegisterForDebuggerForKernel(SceUID threadId, void *pInfo);</source>
 
=== SceThreadmgrForKernel_09CEAAA4 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x09CEAAA4
|}
 
=== SceThreadmgrForKernel_14ADCC1F ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x14ADCC1F
|}
 
=== SceThreadmgrForKernel_15AAB4F9 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x15AAB4F9
|}
 
=== sceKernelWaitThreadSuspendForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x17A4E56B
|}
 
<source lang="C">int sceKernelWaitThreadSuspendForKernel(SceUID threadId, SceUInt32 *timeout);</source>
 
=== SceThreadmgrForKernel_2EC8E376 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x2EC8E376
|}
 
=== sceKernelGetThreadNameListProcForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x315869B6
|}
 
=== SceThreadmgrForKernel_3CD03673 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x3CD03673
|}
 
=== SceThreadmgrForKernel_41BCA03A ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x41BCA03A
|}
 
=== SceThreadmgrForKernel_4679280D ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x4679280D
|}
 
=== sceKernelDTraceAsyncXCallForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x4C3887B4
|}
 
This is a guessed name.
 
<source lang="C">int sceKernelDTraceAsyncXCallForKernel(SceUInt32 targetCpu, int (* callback)(void *argp), void *argp, SceSize arg_len);</source>
 
=== sceKernelGetVfpRegisterForDebuggerForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x5785D18E
|}
 
=== sceKernelDTraceSyncXCallForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x5AB30D35
|}
 
This is a guessed name.
 
<source lang="C">int sceKernelDTraceSyncXCallForKernel(SceUInt32 targetCpu, int (* callback)(void *argp), void *argp);</source>
 
=== SceThreadmgrForKernel_766028E7 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x766028E7
|}
 
=== SceThreadmgrForKernel_796D3A65 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x796D3A65
|}
 
=== SceThreadmgrForKernel_82F080A8 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x82F080A8
|}
 
=== sceKernelSetVfpRegisterForDebuggerForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x87B3D598
|}
 
=== SceThreadmgrForKernel_88D5BC33 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x88D5BC33
|}
 
=== SceThreadmgrForKernel_8B6F201E ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x8B6F201E
|}
 
sceKernelStopThread with arg 0x40000000.
 
=== SceThreadmgrForKernel_8F3E9E35 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x8F3E9E35
|}
 
=== SceThreadmgrForKernel_97780FA6 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x97780FA6
|}
 
=== SceThreadmgrForKernel_9C96317A ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x9C96317A
|}
 
=== SceThreadmgrForKernel_9F5ECAD5 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x9F5ECAD5
|}
 
=== SceThreadmgrForKernel_A1939BC9 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xA1939BC9
|}
 
=== SceThreadmgrForKernel_A4127F82 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xA4127F82
|}
 
=== SceThreadmgrForKernel_AEA9213B ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xAEA9213B
|}
 
=== sceKernelSetCpuRegisterForDebuggerForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xC75A4609
|}
 
=== SceThreadmgrForKernel_CC1D6D9F ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xCC1D6D9F
|}
 
=== SceThreadmgrForKernel_CE99E69C ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xCE99E69C
|}
 
=== SceThreadmgrForKernel_D8117AFB ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xD8117AFB
|}
 
=== SceThreadmgrForKernel_DBE2EE32 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xDBE2EE32
|}
 
=== SceThreadmgrForKernel_E3CE20AA ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xE3CE20AA
|}
 
=== SceThreadmgrForKernel_E92C1784 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xE92C1784
|}
 
sceKernelWaitThreadSuspend with arg 0
 
=== sceKernelIssueSimpleIntrRequestForKernel ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xF74B7E34
|}
 
=== SceThreadmgrForKernel_F9BD4A0D ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xF9BD4A0D
|}
 
=== SceThreadmgrForKernel_FA53F581 ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0xFA53F581
|}
 
== SceThreadmgr ==
 
=== _sceKernelCloseTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x22605E63
|-
| 3.60 || not present
|}
 
=== _sceKernelCloseMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x21716C81
|-
| 3.60 || not present
|}
 
=== _sceKernelPollSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x20AF286A
|-
| 3.60 || not present
|}
 
=== _sceKernelCancelCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x19A0C1B6
|-
| 3.60 || not present
|}
 
=== _sceKernelOpenMsgPipe ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x16EC5B7C
|-
| 3.60 || not present
|}
 
=== _sceKernelDeleteEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x16C93704
|-
| 3.60 || not present
|}
 
=== _sceKernelDeleteThread ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x151E0020
|-
| 3.60 || not present
|}
 
Simply calls [[SceKernelThreadMgr#sceKernelDeleteThread|sceKernelDeleteThread()]];
 
<source lang="C">
/**
* @brief Delete thread
*
* Deletes the thread specified by threadId.
*
* Accordingly, the stack area and thread management area are released. The target thread must be in the DORMANT state.
*
* Since the own thread cannot be in the DORMANT state, it cannot be set as the target thread
* (this results in an SCE_KERNEL_ERROR_NOT_DORMANT error).
* Use sceKernelExitDeleteThread() to delete your own thread.
*
* @param threadId Specify the identifier of the thread to be deleted.
* @retval SCE_OK Success
* @retval Negative value Error code
*/
SceInt32 _sceKernelDeleteThread(
SceUID threadId
);
</source>
 
=== _sceKernelUnlockMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x12948A63
|-
| 3.60 || not present
|}
 
=== sceKernelGetActiveCpuMask ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x0C3CBB8B
|-
| 3.60 || not present
|}
 
=== _sceKernelSignalCondAll ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x0F11545D
|-
| 3.60 || not present
|}
 
=== sceKernelUnregisterThreadEventHandler ===
{| class="wikitable"
! Version !! NID
|-
| 3.60 || 0x2C8ED6F0
|}
 
=== sceKernelChangeActiveCpuMask ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x001173F8
|}
 
=== sceKernelGetThreadCurrentPriority ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x01414F0B
|}
 
=== sceKernelWaitThreadEndCB_089 ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x0373C5E3
|}
 
=== sceKernelGetCallbackCount ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x038644D5
|}
 
=== _sceKernelTryReceiveMsgPipeVector ===
{| class="wikitable"
! Version !! NID
|-
| 1.69-3.60 || 0x03CFCF00
|}
 
=== sceKernelCloseMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x03E23AF6
|}
 
=== _sceKernelGetSemaInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x0402C633
|}
 
=== _sceKernelWaitCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x040795C7
|}
 
=== _sceKernelWaitMultipleEventsCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x0558B7C1
|}
 
=== _sceKernelGetCondInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x05C51CE1
|}
 
=== _sceKernelSignalLwCondAll ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x07D2584A
|}
 
=== sceKernelExitThread ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x0C8A38E1
|}
 
<source lang="C">
/**
* @brief End of own thread
*
* Terminates the own thread normally and shifts to the DORMANT state.
* sceKernelExitThread() is a system call that does not return to the context of the issuer.
*
* Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
* However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
* The mutex is unlocked and not deleted.
*
* When the terminated thread is restarted with sceKernelStartThread(), the information included in the thread
* management area, such as thread priority, is reset.
* It will not inherit the one at the end.
*
* When a thread exits, exitStatus becomes the exit status of that thread.
*
* If the thread is terminated by a return from the entry function without using
* sceKernelExitThread(), the return value of the entry function becomes the termination status.
*
* The end status of a thread can be obtained by sceKernelGetThreadExitStatus() and sceKernelGetThreadInfo(),
* and when another thread waits for the end of the thread by sceKernelWaitThreadEnd(), it can be obtained by the return value.
*
* The thread exit status is saved while the thread exits and is in the DORMANT state,
* but the value is lost if the thread is restarted or deleted with sceKernelStartThread().
*
* @param exitStatus Specify the value to be set for the termination status of the local thread.
* @retval Negative value Error code
*/
SceInt32 sceKernelExitThread(
SceInt32 exitStatus
);
</source>
 
=== _sceKernelCreateSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x0D76458E
|}
 
=== sceKernelOpenMsgPipe ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x0E1CB9F6
|}
 
=== _sceKernelGetEventFlagInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x106C216F
|}
 
=== _sceKernelSetEventWithNotifyCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x118F646E
|}
 
=== sceKernelSignalCondTo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x1269F4EC
|}
 
=== sceKernelCloseMsgPipe ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x1305A065
|}
 
=== _sceKernelCancelTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x13117B21
|}
 
=== sceKernelChangeThreadCpuAffinityMask ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x15129174
|}
 
<source lang="C">
/**
* @brief Thread CPU affinity mask setting
*
* Change the CPU affinity mask of the thread specified by threadId to cpuAffinityMask.
* A thread can run only on the CPU specified by the CPU affinity mask.
*
* If the CPU affinity mask of a running thread is changed and cannot be executed on the current CPU, the thread is dispatched immediately.
* As a result of scheduling, if a higher priority thread is running on the newly executable CPU, it is made to wait in the READY state.
*
* However, if the dispatch is disabled, the CPU affinity mask is changed immediately,
* but the rescheduling process is delayed until dispatch is permitted.
*
* @param threadId Specify the identifier of the thread whose CPU affinity mask is to be changed.
* You can specify your own thread with SCE_KERNEL_THREAD_ID_SELF.
* @param cpuAffinityMask Specify the CPU affinity mask after the change.
* The CPU affinity mask is expressed by the logical OR of the following macros.
* - SCE_KERNEL_CPU_MASK_USER_0
* - SCE_KERNEL_CPU_MASK_USER_1
* - SCE_KERNEL_CPU_MASK_USER_2
* The following macros are also available to specify all available CPUs.
* - SCE_KERNEL_CPU_MASK_USER_ALL
* @retval Positive value CPU affinity mask before change
* @retval Negative value Error code
*/
SceInt32 sceKernelChangeThreadCpuAffinityMask(
SceUID threadId,
SceInt32 cpuAffinityMask
);
</source>
 
=== sceKernelCloseCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x15C690E0
|}
 
=== sceKernelLockMutex_089 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x16AC80C5
|}
 
<source lang="C">int sceKernelLockMutex_089(SceUID mutex_id, int unk1, int unk2);</source>
 
=== sceKernelUnregisterCallbackFromEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x18462B11
|}
 
=== _sceKernelWaitLwCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x18C65756
|}
 
=== sceKernelUnlockMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x1A372EC8
|}
 
=== _sceKernelCancelMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x1B74CB89
|}
 
=== sceKernelDeleteThread ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x1BBDE3D9
|}
 
<source lang="C">
/**
* @brief Delete thread
*
* Deletes the thread specified by threadId.
*
* Accordingly, the stack area and thread management area are released. The target thread must be in the DORMANT state.
*
* Since the own thread cannot be in the DORMANT state, it cannot be set as the target thread
* (this results in an SCE_KERNEL_ERROR_NOT_DORMANT error).
* Use sceKernelExitDeleteThread() to delete your own thread.
*
* @param threadId Specify the identifier of the thread to be deleted.
* @retval SCE_OK Success
* @retval Negative value Error code
*/
SceInt32 sceKernelDeleteThread(
SceUID threadId
);
</source>
 
=== _sceKernelCancelSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x1CAF805D
|}
 
=== sceKernelExitDeleteThread ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x1D17DECF
|}
 
<source lang="C">
/**
* @brief End and delete own thread
*
* Terminates the own thread normally and deletes it.
* sceKernelExitDeleteThread() is a system call that does not return to the context of the issuer.
*
* Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
* However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
* The mutex is unlocked and not deleted.
*
* When a thread exits, exitStatus becomes the exit status of that thread (sceKernelExitDeleteThread()
* directly deletes the thread without going through the DORMANT state.
* (It cannot be obtained by sceKernelGetThreadInfo(). The end status can be obtained by the return
* value only when waiting for the end of the thread by sceKernelWaitThreadEnd().)
*
* @param exitStatus Specify the value to be set for the termination status of the local thread.
* @retval Negative value Error code
*/
SceInt32 sceKernelExitDeleteThread(
SceInt32 exitStatus
);
</source>
 
=== sceKernelUnlockMutex_089 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x1E82E5D0
|}
 
<source lang="C">int sceKernelUnlockMutex_089(SceUID mutex_id, int unk1);</source>
 
=== _sceKernelWaitMultipleEvents ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x200CC503
|}
 
=== sceKernelTryLockWriteRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x206CBB66
|}
 
=== sceKernelDeleteSimpleEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x208CFE28
|}
 
=== _sceKernelGetThreadCpuAffinityMask ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x212E6C35
|}
 
=== _sceKernelGetTimerEventRemainingTime ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x215FD24D
|}
 
=== _sceKernelPollEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x21C7913E
|}
 
=== sceKernelStartThread_089 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x21F5419B
|}
 
<source lang="C">
/**
* @brief Thread activation
*
* Starts the thread specified by threadId and puts it in READY state.
*
* The argument block specified by argSize and argBlock is copied onto the thread stack, argSize is
* passed directly to the first argument of the thread entry function, and the second argument of
* the entry function is the argument copied onto the stack. The block address is passed.
*
* This system call does not queue activation requests. In other words, if the target thread is not
* in the DORMANT state, an SCE_KERNEL_ERROR_NOT_DORMANT error is returned to the calling thread.
*
* @param threadId Specify the identifier of the thread to be started.
* @param argSize Specify the size (byte) of the argument to be passed to the thread.
* @param pArgBlock Specify the address of the argument to be passed to the thread.
* @retval SCE_OK Success
* @retval Negative value Error code
*/
SceInt32 sceKernelStartThread_089(
SceUID threadId,
SceSize argSize,
const void *pArgBlock
);
</source>
 
=== _sceKernelExitCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x2682E6ED
|}
 
=== sceKernelTryLockMutex_089 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x270993A6
|}
 
=== sceKernelSetTimerTimeWide ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x273B4A4D
|}
 
<source lang="C">int sceKernelSetTimerTimeWide(SceUID timerId, SceUInt64 time);</source>
 
=== _sceKernelOpenCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x27DD11EA
|}
 
=== _sceKernelGetThreadmgrUIDClass ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x27EE191B
|}
 
=== sceKernelOpenMutex_089 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x2928D2EC
|}
 
=== _sceKernelCancelEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x29483405
|}
 
=== _sceKernelCreateMsgPipeWithLR ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x2AAC8BFD
|}
 
<source lang="C">
typedef struct SceKernelCreateMsgPipeSyscallArgs { // size is 0x10-bytes
  SceSize bufSize;
  void *opt;
  void *lr;
  int padding_0x0C:
} SceKernelCreateMsgPipeSyscallArgs;
 
int _sceKernelCreateMsgPipeWithLR(const char *name, int type, int attr, SceKernelCreateMsgPipeSyscallArgs *args);
</source>
 
=== _sceKernelUnlockLwMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x2ABC41DF
|}
 
=== _sceKernelGetMsgPipeCreatorId ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x2B751F95
|}
 
=== sceKernelCancelCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x30741EF2
|}
 
=== sceKernelSetEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x324218CD
|}
 
=== _sceKernelGetTimerBaseWide ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x370E147B
|}
 
=== _sceKernelGetThreadContextForVM ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x377094D5
|}
 
=== _sceKernelCreateEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x38AA5E8E
|}
 
<source lang="C">
/**
* @brief Event flag generation
*
* Generate an event flag and set the initial value of the event flag. Returns the identifier of the generated event flag as a return value.
*
* @param pName Specifies the name of the eventflag.
*                      The name of the eventflag does not need to be unique because it is used only for the purpose of operator
*                      identification when debugging without interprocess communication.
*                      However, if the SCE_KERNEL_ATTR_OPENABLE attribute is specified for attr,
*                      a unique name must be specified in the system.
*                      The maximum name length is 31 bytes.
* @param attr Specifies the event flag attribute.
*                      Specify the queue order from one of the following.
*                      - SCE_KERNEL_EVF_ATTR_TH_FIFO: Waiting thread queuing is FIFO
*                      - SCE_KERNEL_EVF_ATTR_TH_PRIO: Waiting thread queuing is based on the priority of threads.
*                      Specify whether to wait for multiple threads from either of the following.
*                      - SCE_KERNEL_EVF_ATTR_SINGLE: Multiple threads cannot wait simultaneously
*                      - SCE_KERNEL_EVF_ATTR_MULTI: To generate an event flag that can be referenced by
*                      sceKernelOpenEventFlag() that allows multiple threads to wait simultaneously, specify the following:
*                      - SCE_KERNEL_ATTR_OPENABLE
* @param initPattern Specifies the initial value of the eventflag.
* @param pOptParam Argument for future expansion. Please specify NULL.
* @retval (>=0) Event flag identifier (UID)
* @retval (<0) Error code
*/
SceUID _sceKernelCreateEventFlag(const char *pName, SceUInt32 attr, SceUInt32 initPattern, const SceKernelEventFlagOptParam *pOptParam);
</source>
 
=== _sceKernelSetTimerTimeWide ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x39364623
|}
 
=== _sceKernelWaitThreadEndCB_0910 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x394BCCF2
|}
 
=== _sceKernelSignalCondTo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x3C00071F
|}
 
=== _sceKernelReceiveMsgPipeVector ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x3DD9E4AB
|}
 
=== _sceKernelPulseEventWithNotifyCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x3E49D3F1
|}
 
=== sceKernelUnlockReadRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x3EF91145
|}
 
=== sceKernelGetTimerTimeWide ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x3EFD3165
|}
 
<source lang="C">SceUInt64 sceKernelGetTimerTimeWide(SceUID timerId);</source>
 
=== _sceKernelCreateCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x3F42E175
|}
 
=== _sceKernelWaitEventFlagCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x401E0C68
|}
 
=== _sceKernelSetEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x438917E4
|}
 
=== _sceKernelWaitCondCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x452B0AB3
|}
 
=== _sceKernelWaitSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x45389B6B
|}
 
=== sceKernelGetSystemTimeLow ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x47F6DE49
|}
 
=== sceKernelStartTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x48091E0C
|}
 
<source lang="C">int sceKernelStartTimer(SceUID timerId);</source>
 
=== sceKernelDelayThread ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x4B675D05
|}
 
=== _sceKernelClearEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x4B7F47DC
|}
 
=== __sceKernelCreateLwMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x4BB3154A
|}
 
<source lang="C">
typedef struct sceKernelCreateLwMutex_opt //size is 0x10
{
  int initCount;
  const SceKernelLwMutexOptParam* pOptParam;
  uint32_t unk_8;
  uint32_t unk_C;
} sceKernelCreateLwMutex_opt;
 
int __sceKernelCreateLwMutex(SceKernelLwMutexWork *pWork, const char *pName, unsigned int attr, sceKernelCreateLwMutex_opt* opt);
</source>
 
=== sceKernelClearEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x4CB87CA7
|}
 
=== _sceKernelReceiveMsgPipeVectorCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x4DBF648E
|}
 
=== _sceKernelNotifyCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x4DF8B624
|}
 
=== _sceKernelWaitEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x4E0EA70D
|}
 
=== sceKernelOpenSimpleEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x4E1E4DF8
|}
 
=== sceKernelGetThreadStackFreeSize ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x4F8A3DA0
|}
 
=== _sceKernelWaitSignal ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x50407BF4
|}
 
=== _sceKernelTryLockWriteRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x52DD3322
|}
 
=== sceKernelOpenMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x52E17182
|}
 
=== sceKernelDeleteEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x5840162C
|}
 
=== _sceKernelUnregisterCallbackFromEventAll ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x5B5650C7
|}
 
=== _sceKernelUnlockWriteRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x5B746A69
|}
 
=== _sceKernelGetCallbackCount ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x5D06FF09
|}
 
=== _sceKernelLockReadRWLockCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x5D86D763
|}
 
=== sceKernelGetTimerBaseWide ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x5DBC1960
|}
 
<source lang="C">SceUInt64 sceKernelGetTimerBaseWide(SceUID timerId);</source>
 
=== _sceKernelSendMsgPipeVector ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x5E65E454
|}
 
=== _sceKernelWaitExceptionCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x5E7876F2
|}
 
=== sceKernelResumeThreadForVM ===
{| class="wikitable"
|-
! Version !! NID
|-
| 0.931-1.61 || not present
|-
| 1.660.011-2.120.011 || 0x5E93840E
|-
| 2.50-3.740.011 || not present
|}
 
=== _sceKernelCloseCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x650CE348
|}
 
=== _sceKernelPMonCpuGetCounter ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x667A4649
|}
 
=== _sceKernelGetActiveCpuMask ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x67FDA21B
|}
 
=== _sceKernelDeleteCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x68D0FA79
|}
 
=== sceKernelGetMutexInfo_089 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x69B78A12
|}
 
<source lang="C">int sceKernelGetMutexInfo_089(SceUID mutexid, SceKernelMutexInfo *info);</source>
 
=== _sceKernelPMonThreadGetCounter ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x6B9711AC
|}
 
=== _sceKernelGetLwCondInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x6C79F2F2
|}
 
=== sceKernelSignalCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x6ED2E2DC
|}
 
=== _sceKernelSignalLwCondTo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x6F1A4A2E
|}
 
=== _sceKernelGetTimerTime ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x6F2C41BA
|}
 
=== _sceKernelWaitException ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x6F7C4DE6
|}
 
=== _sceKernelGetEventPattern ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x70358258
|}
 
=== sceKernelGetMsgPipeCreatorId ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x70E2A6D2
|}
 
=== _sceKernelSuspendThreadForVM ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.000.071-1.810.021 || 0x7192B01C
|-
| 2.000.081-3.740.011 || not present
|}
 
=== sceKernelCancelMutex_089 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x7204B846
|}
 
=== _sceKernelWaitLwCondCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x72DBB96B
|}
 
=== sceKernelTryLockMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x72FC1F54
|}
 
=== sceKernelChangeCurrentThreadAttr ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x751C9B7A
|}
 
=== _sceKernelDeleteLwCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x75FCF058
|}
 
=== sceKernelOpenCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x76BDA02F
|}
 
=== sceKernelRegisterCallbackToEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x76FB37E9
|}
 
=== _sceKernelSignalCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x79889DAC
|}
 
=== _sceKernelCreateTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x79BA0A6D
|}
 
=== _sceKernelGetMsgPipeInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x7AE31060
|}
 
=== sceKernelClearEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x7B2A4B28
|}
 
<source lang="C">SceInt32 sceKernelClearEvent(SceUID eventId, SceUInt32 clearPattern);</source>
 
=== _sceKernelUnlockReadRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x7D16FB3B
|}
 
=== _sceKernelWaitEventCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x7D483C33
|}
 
=== _sceKernelLockReadRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x7EB9E8B5
|}
 
=== _sceKernelLockMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x7FA945AD
|}
 
=== _sceKernelGetThreadExitStatus_0940 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x800BB137
|}
 
=== _sceKernelLockWriteRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x80191FAA
|}
 
=== _sceKernelGetSystemInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x80544E0C
|}
 
=== _sceKernelDeleteSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x855F49D5
|}
 
=== _sceKernelOpenTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x8564E008
|}
 
=== _sceKernelGetTimerBase ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x865DA482
|}
 
=== sceKernelPollSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x866EF048
|}
 
=== _sceKernelGetCallbackInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x86761234
|}
 
=== sceKernelStopTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x869E9F20
|}
 
<source lang="C">int sceKernelStopTimer(SceUID timerId);</source>
 
=== sceKernelDeleteCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x879E6EBD
|}
 
=== sceKernelUnregisterCallbackFromEventAll ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x888A7361
|}
 
=== _sceKernelGetRWLockInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x8CE3AFC7
|}
 
=== sceKernelPulseEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x8D27BAD6
|}
 
=== _sceKernelCancelEventWithSetPattern ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x8E68E870
|}
 
=== _sceKernelSignalSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x8E9A0400
|}
 
=== _sceKernelDeleteLwMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x91262C5F
|}
 
=== _sceKernelDeleteTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x921A043D
|}
 
=== _sceKernelCreateMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x92667AE5
|}
 
<source lang="C">
SceUID _sceKernelCreateMutex(const char *pName, SceUInt32 attr, SceInt32 initCount, const SceKernelMutexOptParam *pOptParam);
</source>
 
=== _sceKernelCreateLwCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x940B9EBE
|}
 
=== sceKernelCloseEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x9A68F547
|}
 
=== _sceKernelSetEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x9A92C33F
|}
 
=== _sceKernelDeleteRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x9AA387DF
|}
 
=== _sceKernelGetTimerTimeWide ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x9AC39954
|}
 
=== _sceKernelRegisterCallbackToEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x9B1922F2
|}
 
=== sceKernelDelayThreadCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x9C0180E1
|}
 
=== _sceKernelCreateSimpleEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x9C187FAD
|}
 
=== _sceKernelLockLwMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x9C572180
|}
 
=== _sceKernelChangeThreadCpuAffinityMask ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x9C921F8D
|}
 
Simply calls sceKernelChangeThreadCpuAffinityMask().
 
<source lang="C">
/**
* @brief Thread CPU affinity mask setting
*
* Change the CPU affinity mask of the thread specified by threadId to cpuAffinityMask.
* A thread can run only on the CPU specified by the CPU affinity mask.
*
* If the CPU affinity mask of a running thread is changed and cannot be executed on the current CPU, the thread is dispatched immediately.
* As a result of scheduling, if a higher priority thread is running on the newly executable CPU, it is made to wait in the READY state.
*
* However, if the dispatch is disabled, the CPU affinity mask is changed immediately,
* but the rescheduling process is delayed until dispatch is permitted.
*
* @param threadId Specify the identifier of the thread whose CPU affinity mask is to be changed.
* You can specify your own thread with SCE_KERNEL_THREAD_ID_SELF.
* @param cpuAffinityMask Specify the CPU affinity mask after the change.
* The CPU affinity mask is expressed by the logical OR of the following macros.
* - SCE_KERNEL_CPU_MASK_USER_0
* - SCE_KERNEL_CPU_MASK_USER_1
* - SCE_KERNEL_CPU_MASK_USER_2
* The following macros are also available to specify all available CPUs.
* - SCE_KERNEL_CPU_MASK_USER_ALL
* @retval Positive value CPU affinity mask before change
* @retval Negative value Error code
*/
SceInt32 _sceKernelChangeThreadCpuAffinityMask(
SceUID threadId,
SceInt32 cpuAffinityMask
);
</source>
 
=== _sceKernelOpenMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0x9D291788
|}
 
=== sceKernelGetProcessId ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0x9DCB4B7A
|}
 
=== sceKernelCloseSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xA2D81F9E
|}
 
=== sceKernelCloseMutex_089 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xA35427EE
|}
 
=== sceKernelNotifyCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xA4683592
|}
 
=== _sceKernelCloseMsgPipe ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xAA888831
|}
 
=== sceKernelDeleteTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xAB1E42C4
|}
 
<source lang="C">int sceKernelDeleteTimer(SceUID timerId);</source>
 
=== _sceKernelGetTimerInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xAC7FE4F3
|}
 
=== sceKernelCloseTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xACE60E4A
|}
 
<source lang="C">int sceKernelCloseTimer(SceUID timerId);</source>
 
=== _sceKernelCreateRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xB1877F5E
|}
 
=== sceKernelCreateCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xB19CF7E9
|}
 
=== _sceKernelGetThreadInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0xB373D8A1
|}
 
<source lang="c">
typedef struct get_thread_info_opt
{
  uint32_t size; // size of SceKernelThreadInfo
  uint32_t unk;
}get_thread_info_opt;
 
int _sceKernelGetThreadInfo(SceUID thid, SceKernelThreadInfo *info, get_thread_info_opt* opt)
</source>
 
=== _sceKernelTrySendMsgPipeVector ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xB3D600AB
|}
 
=== sceKernelUnlockWriteRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xB4151397
|}
 
=== _sceKernelGetThreadStackFreeSize ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xB5EC061A
|}
 
=== _sceKernelDeleteMsgPipe ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xB6D50FCC
|}
 
=== sceKernelOpenTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xB6E286E7
|}
 
<source lang="C">SceUID sceKernelOpenTimer(const char *name);</source>
 
=== _sceKernelGetSystemTime ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xB70EBAE9
|}
 
=== _sceKernelChangeThreadVfpException ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xB8F165B4
|}
 
=== _sceKernelOpenSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xB96FED7D
|}
 
=== _sceKernelGetThreadTLSAddr ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xBACA6891
|}
 
=== sceKernelOpenEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xBC19F8A1
|}
 
=== _sceKernelTryLockMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xBCFB867F
|}
 
=== sceKernelChangeThreadPriority ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xBD0139F2
|}
 
=== sceKernelCreateThreadForUser ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0xC0FAF6A3
|}
 
<source lang="C">
/**
* @brief Thread generation that operates in the address space of its own process
*
* A thread that operates in the address space of its own process is created.
*
* Allocate a thread management area for the thread to be created, perform initialization, and secure a stack area.
* The thread information to be created is specified as an argument, and the thread identifier (UID) is returned as the return value.
*
* The generated thread is in the DORMANT state.
*
* @param pName Specifies the name of the thread.
* The name of the thread does not have to be unique because it is
* used by the operator to identify it when debugging. The maximum name length is 31 bytes.
* @param entry Specify the entry address of the thread. The thread entry point function
* can receive memory block data with two arguments.
* The argument is given by sceKernelStartThread() described later.
* The thread is terminated by returning from this function, and the return value of the function is the thread termination status.
* @param initPriority Specifies the initial priority of the thread. The smaller the number, the higher the priority.
* The range from SCE_KERNEL_HIGHEST_PRIORITY_USER (= 64) to SCE_KERNEL_LOWEST_PRIORITY_USER (= 191) can be used.
* By specifying SCE_KERNEL_DEFAULT_PRIORITY_USER, you can specify the default priority of the process to which the thread belongs.
* For the default priority, it is also possible to specify with SCE_KERNEL_DEFAULT_PRIORITY_USER ± offset.
* @param stackSize Specify the required stack size of the thread in bytes. The argument block given by
* sceKernelStartThread () is copied onto the stack, so specify the stack size with this margin in mind.
* An error will occur if a stack size less than 4 KiB is specified.
* @param attr You can specify multiple thread attributes by logical OR.
* @param cpuAffinityMask Specifies the initial CPU affinity mask for the thread.
* A thread can run only on the thread specified in the CPU affinity mask.
* The CPU affinity mask can be specified by the logical sum of the following macros.
* - SCE_KERNEL_CPU_MASK_USER_0
* - SCE_KERNEL_CPU_MASK_USER_1
* - SCE_KERNEL_CPU_MASK_USER_2
* The following macros are also available to represent all available CPUs.
* - SCE_KERNEL_CPU_MASK_USER_ALL
* @param pOptParam Argument for future expansion. Please specify NULL. Max size is 0x14.
* @retval Positive value Thread identifier (UID)
* @retval Negative value Error code
*/
SceUID sceKernelCreateThreadForUser(
const char *pName,
SceKernelThreadEntry entry,
SceInt32 initPriority,
SceSize stackSize,
SceUInt32 attr,
SceInt32 cpuAffinityMask,
const SceKernelThreadOptParam *pOptParam
);
</source>
 
=== _sceKernelSendSignal ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xC21FC992
|}
 
=== _sceKernelCloseRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xC239DBCC
|}
 
=== sceKernelSignalCondAll ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xC2E7AC22
|}
 
=== _sceKernelStartThread ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xC30B1745
|}
 
<source lang="C">
/**
* @brief Thread activation
*
* Starts the thread specified by threadId and puts it in READY state.
*
* The argument block specified by argSize and argBlock is copied onto the thread stack, argSize is
* passed directly to the first argument of the thread entry function, and the second argument of
* the entry function is the argument copied onto the stack. The block address is passed.
*
* This system call does not queue activation requests. In other words, if the target thread is not
* in the DORMANT state, an SCE_KERNEL_ERROR_NOT_DORMANT error is returned to the calling thread.
*
* @param threadId Specify the identifier of the thread to be started.
* @param argSize Specify the size (byte) of the argument to be passed to the thread.
* @param pArgBlock Specify the address of the argument to be passed to the thread.
* @retval SCE_OK Success
* @retval Negative value Error code
*/
SceInt32 _sceKernelStartThread(
SceUID threadId,
SceSize argSize,
const void *pArgBlock
);
</source>
 
=== _sceKernelSignalLwCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xC37F6983
|}
 
=== _sceKernelStartTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xC3ED6E4A
|}
 
=== _sceKernelCloseSimpleEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xC6FFE335
|}
 
=== _sceKernelGetThreadRunStatus ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xC7FB5497
|}
 
=== sceKernelGetThreadmgrUIDClass ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xC9678F7F
|}
 
=== _sceKernelStopTimer ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xC96F4269
|}
 
=== sceKernelDeleteMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xCB78710D
|}
 
=== sceKernelOpenSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xCBE235C7
|}
 
=== _sceKernelCreateCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xCC14FA59
|}
 
=== sceKernelChangeThreadVfpException ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xCC18FBAE
|}
 
=== sceKernelOpenRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xCE510196
|}
 
=== _sceKernelCancelMsgPipe ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xCE769C83
|}
 
=== _sceKernelWaitSignalCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xCEA3FC52
|}
 
=== _sceKernelCancelRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xD004EA15
|}
 
=== sceKernelLockMutexCB_089 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0xD06F2886
|}
 
=== _sceKernelGetThreadExitStatus ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xD3210C08
|}
 
=== _sceKernelWaitThreadEnd_0910 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xD38231C9
|}
 
=== sceKernelDeleteCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xD469676B
|}
 
=== _sceKernelSetThreadContextForVM ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xD4785C41
|}
 
=== sceKernelSendSignal ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xD4C367B2
|}
 
=== _sceKernelDeleteCond ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xD99F51D3
|}
 
=== sceKernelCheckWaitableStatus ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0xD9BD74EB
|}
 
=== _sceKernelGetLwCondInfoById ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xD9E78D30
|}
 
=== _sceKernelPollEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xDAB1B1C8
|}
 
<source lang="C">
/**
* @brief Event flag polling
*
* Polls the event flag specified by evfId.
*
* sceKernelPollEventFlag() is a system call that removes the function to enter standby state from sceKernelWaitEventFlag().
* Unlike sceKernelWaitEventFlag(), an error (SCE_KERNEL_ERROR_EVF_COND) is returned immediately if the wait release condition is not satisfied.
* In this case, SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL / SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT specification is ignored.
*
* @param evfId Specify the event flag identifier to be polled.
* @param bitPattern Specify the comparison value with the eventflag.
* @param waitMode Specify the wait mode. Specify one of the following:
*                      - SCE_KERNEL_EVF_WAITMODE_AND: Waiting for AND
*                      - SCE_KERNEL_EVF_WAITMODE_OR : Wait for OR
*                      In addition, you can optionally add one of the following specifications as a logical sum.
*                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL: Clear all bits after waiting
*                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT: After waiting, clear the bit specified in bitPattern
* @param pResultPat Specify a pointer to the SceUInt32 type variable that receives the eventflag value when waiting is established.
* @retval SCE_OK Success
* @retval (<0) Error code
*/
SceInt32 _sceKernelPollEventFlag(SceUID evfId, SceUInt32 bitPattern, SceUInt32 waitMode, SceUInt32 *pResultPat);
</source>
 
=== sceKernelDeleteSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xDB32948A
|}
 
=== _sceKernelLockMutexCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xDB9F5333
|}
 
=== _sceKernelLockWriteRWLockCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xDBD09B09
|}
 
=== _sceKernelOpenRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xDFCEE5AB
|}
 
=== _sceKernelDeleteMutex ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xE0A6D759
|}
 
=== _sceKernelSetTimerEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xE2C0BFEF
|}
 
=== _sceKernelOpenSimpleEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xE326EA7A
|}
 
=== sceKernelCheckCallback ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0xE53E41F6
|}
 
=== _sceKernelChangeThreadPriority ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xE61C2B06
|}
 
=== sceKernelSignalSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xE6B761D1
|}
 
=== sceKernelDeleteRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xE73649CA
|}
 
=== sceKernelDeleteMsgPipe ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xE78BCCF7
|}
 
=== _sceKernelCloseSema ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xE8C03447
|}
 
=== _sceKernelGetMutexInfo ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0xE8CC3DF0
|}
 
<source lang="C">
int _sceKernelGetMutexInfo(SceUID mutexid, SceKernelMutexInfo *pInfo, SceKernelMutexOptParam* pOpt);
</source>
 
=== _sceKernelWaitThreadEnd ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xEA5C52F5
|}
 
=== _sceKernelTryLockReadRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xEB9054B2
|}
 
=== sceKernelSetEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xEC94DFF7
|}
 
=== sceKernelTryLockReadRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xEFDDA456
|}
 
=== _sceKernelClearEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xF0526CE2
|}
 
=== sceKernelGetThreadCpuAffinityMask ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xF1AE5654
|}
 
=== sceKernelWaitThreadEnd_089 ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0xF3489EF4
|}
 
=== sceKernelGetSystemTimeWide ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69-3.60 || 0xF4EE4FA9
|}
 
=== _sceKernelPulseEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xF6A0FE84
|}
 
=== _sceKernelCloseEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xF6CFB4F1
|}
 
=== _sceKernelSendMsgPipeVectorCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xF6D515DC
|}
 
=== _sceKernelDeleteSimpleEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xF7413EC7
|}
 
=== _sceKernelCancelEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xF76F3056
|}
 
=== _sceKernelWaitSemaCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xF8E06784
|}
 
=== _sceKernelWaitThreadEndCB ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xFA3D4491
|}
 
=== _sceKernelOpenEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xFA64FB37
|}
 
=== _sceKernelUnregisterCallbackFromEvent ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xFB66565E
|}
 
=== _sceKernelWaitEventFlag ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xFCE2F728
|}
 
<source lang="C">
/**
* @brief Event flag wait
*
* This system call waits for the event flag specified by evfId to be set according to the wait release condition specified by waitMode.
* If the event flag specified by evfId already satisfies the wait release condition specified by waitMode,
* the issuing thread continues execution without transitioning to the waiting state (WAITING).
*
* When SCE_KERNEL_EVF_WAITMODE_AND is specified for waitMode, it waits until all the bits specified by bitPattern become 1.
* If SCE_KERNEL_EVF_WAITMODE_OR is specified for waitMode, wait until one of the bits specified in bitPattern becomes 1.
* If SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL is additionally specified for waitMode, all the eventflag bits
* are cleared to 0 when the wait release condition is satisfied and this thread is released.
* If SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT is additionally specified for waitMode, the bit specified
* by bitPattern is cleared to 0 when the wait release condition is satisfied and this thread is released.
*
* The event flag value is returned to pResultPat in the following cases. NULL can be specified if no value is required.
* - If the wait release condition is satisfied (SCE_OK is returned),
*  the event flag value before clearing by specifying SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL,
*  SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT is returned immediately after the condition is satisfied.
* - After exiting the wait state, the event flag value just before exiting from the wait state is returned when
*  exiting except when the wait release condition is satisfied (when SCE_KERNEL_ERROR_WAIT_CANCEL,
*  SCE_KERNEL_ERROR_WAIT_DELETE, SCE_KERNEL_ERROR_WAIT_TIMEOUT errors are returned).
*  When canceling with sceKernelCancelEventFlag(), the eventflag value set at the time of cancellation is returned.
*
* When pTimeout is specified, the timeout operation specified in microseconds is set.
* If pTimeout is NULL, timeout operation is not performed.
* Note that if pTimeout is specified, the value pointed to by pTimeout is updated when the system call ends.
* If the condition is met within the time, it is updated with the remaining time. If not established,
* the value pointed to by pTimeout is updated with 0. In this case, error SCE_KERNEL_ERROR_WAIT_TIMEOUT is returned.
*
* Another thread cannot execute sceKernelWaitEventFlag() and sceKernelPollEventFlag() for an event flag with
* the SCE_KERNEL_EVF_ATTR_SINGLE attribute that already has a waiting thread.
* In this case, an error is returned immediately to the thread that executed sceKernelWaitEventFlag() or sceKernelPollEventFlag() later.
*
* If multiple threads are waiting for an event flag with the SCE_KERNEL_EVF_ATTR_MULTI attribute, a thread queue is created.
* In this case, a single sceKernelSetEventFlag() may release the waiting status of multiple threads.
*
* In the case of the event flag of the SCE_KERNEL_EVF_ATTR_TH_FIFO attribute, the thread queue is
* arranged in the order in which it waits first.
* In the event flag of the SCE_KERNEL_EVF_ATTR_TH_PRIO attribute, the thread with the highest
* priority among the waiting threads starts first and is arranged in the order of thread priority.
*
* If there is a thread with SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL specified or SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT specified in the
* queue and the wait release condition for that thread is satisfied, the event flag is cleared at the same time as the wait release.
* Threads that are lined up behind the thread that has specified SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL or SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT
* will see the event flag after being cleared, so the wait may not be released.
*
* @param evfId Specifies the identifier of the event flag to wait for.
* @param bitPattern Specify the comparison value with the eventflag.
* @param waitMode Specifies the wait mode. Specify one of the following:
*                      - SCE_KERNEL_EVF_WAITMODE_AND: Waiting for AND
*                      - SCE_KERNEL_EVF_WAITMODE_OR : Wait for OR
*                      In addition, you can optionally add either of the following specifications as a logical sum.
*                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL: After waiting, clear all bits
*                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT: After waiting, clear the bit specified in bitPattern
* @param pResultPat Specifies a pointer to the SceUInt32 type variable that receives the eventflag value when waiting is established.
*                      If NULL is specified, the event flag value is not received.
* @param pTimeout Specify a pointer to the SceUInt32 type variable that stores the upper limit (microseconds) of the waiting time.
*                      If NULL is specified, wait indefinitely. When the wait condition is satisfied, the remaining time is returned.
* @retval SCE_OK Success
* @retval (<0) Error code
*/
SceInt32 _sceKernelWaitEventFlag(SceUID evfId, SceUInt32 bitPattern, SceUInt32 waitMode, SceUInt32 *pResultPat, SceUInt32 *pTimeout);
</source>
 
=== sceKernelCloseRWLock ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xFD5BD5C1
|}
 
=== _sceKernelGetLwMutexInfoById ===
{| class="wikitable"
|-
! Version !! NID
|-
| 1.69 || 0xFEC9E946
|}
|}
=== sceKernelCloseSimpleEvent ===
=== sceKernelCloseSimpleEvent ===
{| class="wikitable"
{| class="wikitable"
Line 3,048: Line 8,575:
| 1.69 || 0xFEF4CA53
| 1.69 || 0xFEF4CA53
|}
|}
=== _sceKernelSetTimerTime ===
=== _sceKernelSetTimerTime ===
{| class="wikitable"
{| class="wikitable"
Line 3,060: Line 8,588:
|-
|-
! Version !! NID
! Version !! NID
|-
| 0.990 || not present
|-
|-
| 3.60 || 0xCE6B49D8
| 3.60 || 0xCE6B49D8
Line 3,065: Line 8,595:


<source lang="C">
<source lang="C">
struct sceKernelRegisterThreadEventHandlerOpt
typedef struct sceKernelRegisterThreadEventHandlerOpt { // size is 0x10 on FW 3.60
{
   SceKernelThreadEventHandler *handler;
   void *handler;
   void *common;
   int num1;
   int reserved0;
   int reserved0;
   int reserved1;
   int reserved1;
};
} sceKernelRegisterThreadEventHandlerOpt;


int _sceKernelRegisterThreadEventHandler(char *name, SceUID uid, uint32_t num0, sceKernelRegisterThreadEventHandlerOpt *opt);
int _sceKernelRegisterThreadEventHandler(char *name, SceUID thread_id, SceUInt32 mask, sceKernelRegisterThreadEventHandlerOpt *pOpt);
</source>
</source>


Line 3,085: Line 8,614:
|}
|}


<source lang="C">
/**
* @brief End of own thread
*
* Terminates the own thread normally and shifts to the DORMANT state.
* sceKernelExitThread() is a system call that does not return to the context of the issuer.
*
* Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
* However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
* The mutex is unlocked and not deleted.
*
* When the terminated thread is restarted with sceKernelStartThread(), the information included in the thread
* management area, such as thread priority, is reset.
* It will not inherit the one at the end.
*
* When a thread exits, exitStatus becomes the exit status of that thread.
*
* If the thread is terminated by a return from the entry function without using
* sceKernelExitThread(), the return value of the entry function becomes the termination status.
*
* The end status of a thread can be obtained by sceKernelGetThreadExitStatus() and sceKernelGetThreadInfo(),
* and when another thread waits for the end of the thread by sceKernelWaitThreadEnd(), it can be obtained by the return value.
*
* The thread exit status is saved while the thread exits and is in the DORMANT state,
* but the value is lost if the thread is restarted or deleted with sceKernelStartThread().
*
* @param exitStatus Specify the value to be set for the termination status of the local thread.
* @retval Negative value Error code
*/
SceInt32 sceKernelExitThread(
SceInt32 exitStatus
);
</source>


[[Category:ARM]]
[[Category:Kernel]]
[[Category:Modules]]
[[Category:Modules]]
[[Category:Kernel]]
[[Category:Library]]

Latest revision as of 09:37, 18 September 2024

PS Vita supports multi-threading in the non-secure kernel but not in the secure kernel. There is no user/POSIX threads; all threads are implemented as kernel threads and processes are functionally the same as threads. Threads can be specified to run on a specific core with the CPU affinity mask option when creating the thread and by default threads can run on any core. The kernel process can also run on any core. Additionally, the secure kernel can also run on any core.

Module

This module exists only in non-secure world. The SELF can be found in os0:kd/threadmgr.skprx.

Version World Privilege
0.990-3.65 Non-secure Kernel

Libraries

Known NIDs

Version Name World Visibility NID
0.920-3.60 SceThreadmgrForDriver Non-secure Kernel 0xE2C40624
0.920-3.60 SceThreadmgrForKernel Non-secure Kernel 0xA8CA0EFD
3.63-3.67 SceThreadmgrForKernel Non-secure Kernel 0x7F8593BA
3.60 SceThreadmgrCoredumpTime Non-secure User 0x5E8D0E22
0.920-3.60 SceThreadmgr Non-secure User 0x859A24B1

Types

Class Types


// this is a generic type which is not specific for SceKernelThreadMgr. It is used in class creation in many modules.
typedef struct SceObjectBase {
	uint32_t sce_reserved[2]; //[0] seems to be SceKernelObject*
	uint32_t data[];
} SceObjectBase;

typedef struct _SceCacheObj {
  SceObjectBase base;
  int unk8;
  int unkC;
} SceCacheObj;

typedef struct _SceWaitableObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
} SceWaitableObj;

typedef struct _SceFastMutexObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceFastMutexObj;

typedef struct _SceAlarmObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceAlarmObj;

typedef struct _SceDelayObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceDelayObj;

typedef struct _SceLwMutexObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int attr_20;
  int unk24;
  int unk28;
  int initCount_2C;
  SceKernelLwMutexWork* work_30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceLwMutexObj;

typedef struct _SceCondObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int attr_20;
  int unk24;
  SceKernelCondOptParam* option_28;
  SceUID mutexId_2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceCondObj;

typedef struct _SceEventFlagObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int attr_20;
  int unk24;
  int bits_28;
  int bits_2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceEventFlagObj;

typedef struct _SceLwCondObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceLwCondObj;

typedef struct _SceMsgPipeObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceMsgPipeObj;

typedef struct _SceMutexObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int attr_20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int initCount_38;
  int initCount_3C;
  int unk40;
  int ceilingPriority_44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceMutexObj;

typedef struct _SceRWLockObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceRWLockObj;

typedef struct SceKernelSemaOptParam {
	/** Size of the ::SceKernelSemaOptParam structure. */
	SceSize 	size;
} SceKernelSemaOptParam;

typedef struct _SceSemaObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int attr_20;
  int unk24;
  SceKernelSemaOptParam* option_28;
  int initVal_2C;
  int maxVal_30;
  int initVal_34;
  int unk_38;
  int unk_3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceSemaObj;

typedef struct _SceSimpleEventObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceSimpleEventObj;

typedef struct _SceTimerObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceTimerObj;

typedef struct _SceCpuTimerObj {
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
} SceCpuTimerObj;

typedef int (*SceKernelCallbackFunction)(int notifyId, int notifyCount, int notifyArg, void *common);

typedef struct _SceCallbackObj
{
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int attr_1C;
  int unk20;
  int unk24;
  SceKernelCallbackFunction func_28;
  int unk2C;
  int unk30;
  int unk34;
  void *arg_38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceCallbackObj;

typedef struct _SceRegisterCallbackObj
{
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
} SceRegisterCallbackObj;

typedef struct _SceThreadObj
{
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int attr_unk20;
  int unk_24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  SceUID pid_60;
  int unk_64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
  int unk80;
  int unk84;
  int unk88;
  int unk8C;
  int unk90;
  int unk94;
  int unk98;
  int unk9C;
  int unkA0;
  int unkA4;
  int unkA8;
  int unkAC;
  int unkB0;
  int unkB4;
  int unkB8;
  int unkBC;
  int unkC0;
  int unkC4;
  int unkC8;
  int attr_CC;
  int attr_D0;
  int priority_D4;
  int priority_D8;
  int unk_DC;
  int priority_E0;
  int unk_E4;
  int unkE8;
  int unkEC;
  int unkF0;
  int unkF4;
  int unkF8;
  int unkFC;
  int unk100;
  int unk104;
  int unk108;
  int unk10C;
  int unk110;
  int unk114;
  int unk118;
  int unk11C;
  int unk120;
  int unk124;
  int unk128;
  int unk12C;
  int unk130;
  int unk134;
  int unk138;
  int unk13C;
  int unk140;
  int unk144;
  int unk148;
  int unk14C;
  int unk150;
  int unk154;
  int unk158;
  int unk15C;
  int unk160;
  int unk164;
  int unk168;
  int unk16C;
  int unk170;
  int unk174;
  int unk178;
  int unk17C;
  int unk180;
  int unk184;
  int unk188;
  int unk18C;
  int unk190;
  int unk194;
  int unk198;
  int unk19C;
  int unk1A0;
  int unk1A4;
  int unk1A8;
  int unk1AC;
  int unk1B0;
  int unk1B4;
  int unk1B8;
  int unk1BC;
  int unk1C0;
  int unk1C4;
  int unk1C8;
  int unk1CC;
  int unk1D0;
  int unk1D4;
  int unk1D8;
  int unk1DC;
  int unk1E0;
  int unk1E4;
  int unk1E8;
  int unk1EC;
  int unk1F0;
  int unk1F4;
  int unk1F8;
  int unk1FC;
} SceThreadObj;

typedef struct _SceThreadEventObj
{
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceThreadEventObj;

typedef struct _SceWorkQueueObj
{
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int atomic_lock;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  unsigned long long obj_counter;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  SceUID sema_uid;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceWorkQueueObj;

typedef int (*SceKernelWorkQueueWorkFunction)(void *args);

typedef struct _SceWorkTaskObj
{
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int atomic_lock;
  int unk1C;
  int unk20;
  int unk24;
  SceWorkQueueObj *queue_obj;
  int unk2C;
  int unk30;
  int unk34;
  SceUID task_uid;
  int unk3C;
  unsigned long long obj_counter;
  int unk48;
  int unk4C;
  int some_flag;
  int unk54;
  SceUID work_queue_uid;
  SceKernelWorkQueueWorkFunction func;
  void *args;
  SceUID current_thread_uid;
  int unk68;
  int unk6C;
  int unk70;
  SceUID pid;
  int unk78;
  int unk7C;
} SceWorkTaskObj;

typedef struct _SceExcpObj
{
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
  int unk38;
  int unk3C;
  int unk40;
  int unk44;
  int unk48;
  int unk4C;
  int unk50;
  int unk54;
  int unk58;
  int unk5C;
  int unk60;
  int unk64;
  int unk68;
  int unk6C;
  int unk70;
  int unk74;
  int unk78;
  int unk7C;
} SceExcpObj;

typedef struct _SceEventObj
{
  SceObjectBase base;
  int unk8;
  int unkC;
  int unk10;
  int unk14;
  int unk18;
  int unk1C;
  int unk20;
  int unk24;
  int unk28;
  int unk2C;
  int unk30;
  int unk34;
} SceEventObj;

ThreadMgr types

For SceProcessObj, see SceProcessmgr page.

typedef struct SceKernelFastMutex {
	SceUInt8 data[0x40];
} SceKernelFastMutex;

typedef struct IntrRequest {
	struct IntrRequest *next;
	int type;       // In 0-3, 8-0x14, 0x18-0x19
	int from_cache; // 0 = alloc from heap, otherwise comes from Threadmgr link list
	int padding;
	int arguments[4];
} IntrRequest;

typedef struct ThreadMgrCpuCB { // size is 0x880-bytes
	ThreadCB *pRunningThreadCB;
	ThreadCB *pNextRunningThreadCB;
	int data_0x08;
	struct {
		SceUID pid;
		SceUID thid;
	} current[2];
	SceUInt32 currentThreadPriority;
	struct {
		ThreadCB *next;
		ThreadCB *prev;
	} standbyList;
	SceKernelSpinlock lock;
	int unk_2C[2];
	ThreadCB *pIdleThreadCB; // idle thread for this CPU
	SceUInt64 unk_38;
	IntrRequest *intrRequestQueue;
	int unk_44;
	void *SwitchStackBlock_base; // 0x1000 size - idk what for
	SceUInt8 unk_4C[0x14];
	SceUInt32 priorityQueueBitmap[0x20 / sizeof(SceUInt32)];
	struct {
		ThreadCB *next;
		ThreadCB *prev;
	} priorityQueue[0x100];
} ThreadMgrCpuCB;

typedef struct SceKernelThreadmgrPrivate { // size is 0x28B8-bytes
	ThreadMgrCpuCB cpuCB[4];
	SceKernelSpinlock threadMgrCBLock;
	SceUInt8 data[0x6B4];
} SceKernelThreadmgrPrivate;

typedef struct SceKernelThreadStatus { // size is 0x100
	int mode; // kernel:0, user:1

	unsigned int reg[0xF];

	unsigned int cpsr_kern;
	int unk_0x44; // maybe DACR for user
	int unk_0x48; // maybe DACR for kernel
	int unk_0x4C; // ex:0xF00000

	int unk_0x50;
	void *ptr_0x54;        // maybe user tls?
	unsigned int TTBR1;
	unsigned int unk_0x5C; // maybe cpu ctx

	int unk_0x60;
	unsigned int ptr_0x64; // maybe paddr
	int unk_0x68;
	int unk_0x6C;

	int unk_0x70;
	int unk_0x74;
	int unk_0x78;
	int unk_0x7C;

	int unk_0x80;
	int unk_0x84;
	int unk_0x88;
	int unk_0x8C;

	int unk_0x90;
	int unk_0x94;
	int unk_0x98;
	int unk_0x9C;

	int unk_0xA0;
	int unk_0xA4;
	int unk_0xA8; // ex:0x8F5
	int unk_0xAC;

	unsigned int DFAR;
	int unk_0xB4;
	int unk_0xB8; // ex:0x2000, some size?
	int unk_0xBC; // ex:user(0xFF), kernel(0xF0)? maybe?

	const void *pc;
	unsigned int cpsr;
	unsigned int unk_0xC8; // fpcr?
	int unk_0xCC;

	int unk_0xD0;
	int unk_0xD4;
	int unk_0xD8;
	int unk_0xDC;

	int unk_0xE0;
	int unk_0xE4;
	int unk_0xE8;
	int unk_0xEC;

	int unk_0xF0;
	int unk_0xF4;
	int unk_0xF8;
	int unk_0xFC;
} SceKernelThreadStatus;

typedef struct SceKernelThreadFloatRegister { // size is 0x100
	union {
		unsigned int s_reg_i[0x40];
		float        s_reg_f[0x40];
		uint64_t     d_reg_i[0x20];
		double       d_reg_f[0x20];
	};
} SceKernelThreadFloatRegister;

typedef struct SceKernelThreadNeonInfo { // size is 0x120
	SceKernelThreadFloatRegister float_register;
	unsigned int fpscr;
	unsigned int fpexc;
	unsigned int unk_0x108;
	unsigned int unk_0x10C;
	unsigned int unk_0x110;
	unsigned int unk_0x114;
	unsigned int unk_0x118;
	unsigned int unk_0x11C;
} SceKernelThreadNeonInfo;

typedef struct SceKernelThreadRegisterInfo { // size is 0x60
	unsigned int reg[0xD];
	unsigned int unk_0x34;
	unsigned int unk_0x38; // ex:0xB90B45
	unsigned int fpscr;
	unsigned int unk_0x40;
	unsigned int unk_0x44;
	unsigned int unk_0x48;
	unsigned int unk_0x4C;
	unsigned int sp;
	unsigned int lr;
	unsigned int pc;
	unsigned int cpsr;
} SceKernelThreadRegisterInfo;

typedef struct SceKernelThreadInfoInternal { // size is 0x128
	SceSize size;
	SceUID thid_user;
	SceUID processId;

	// offset:0xC
	char name[0x20];
	int pad_0x2C;

	// offset:0x30
	SceUInt attr;
	int status;
	SceKernelThreadEntry entry;
	void *stack;

	// offset:0x40
	SceSize         stackSize;
	int unk_0x44;
	int unk_0x48;
	void *kernel_stack;

	// offset:0x50
	SceSize kernel_stack_size;
	int unk_0x54;
	int unk_0x58;
	int unk_0x5C;

	// offset:0x60
	int unk_0x60;
	int unk_0x64;
	int unk_0x68;
	void *ptr_0x6C; // kernel tls?

	// offset:0x70
	int unk_0x70;
	int unk_0x74;
	int initPriority;
	int currentPriority;

	// offset:0x80
	int initCpuAffinityMask;
	int currentCpuAffinityMask;
	int unk_0x88;
	int currentCpuId;

	// offset:0x90
	int lastExecutedCpuId;
	int waitType; // maybe
	int unk_0x98;
	SceKernelSysClock runClocks;

	int exitStatus;
	int unk_0xA8; // IsThreadDebugSuspended
	SceUInt     intrPreemptCount;

	// offset:0xB0
	SceUInt     threadPreemptCount;
	SceUInt     threadReleaseCount;
	SceUID      fNotifyCallback;
	int         reserved;

	SceKernelThreadStatus *pStatus;
	SceKernelThreadNeonInfo *pNeonInfo;
	SceKernelThreadRegisterInfo *pUserRegisterInfo; // Is it set only when cause(0x10009)?
	int unk_0xCC;

	void *pUserTLS;
	int unk_0xD4;
	int unk_0xD8;
	void *ptr_0xDC;

	int unk_0xE0;
	int unk_0xE4;
	int unk_0xE8;
	int unk_0xEC;

	int unk_0xF0;
	int unk_0xF4;
	int unk_0xF8;
	int unk_0xFC;

	void *ptr_0x100;
	int unk_0x104;
	int unk_0x108;
	int unk_0x10C;

	int unk_0x110;
	int unk_0x114;
	int unk_0x118;
	int unk_0x11C;

	int unk_0x120;
	int unk_0x124;
} __attribute__((packed)) SceKernelThreadInfoInternal;

/** @name	Basic thread functions
 */
/*@{*/

/**
 * @defgroup	Thread attributes
 * Defining thread attributes
 * Specified in attr argument of sceKernelCreateThread()
 */
/*@{*/
#define SCE_KERNEL_THREAD_ATTR_NOUSE_VFP		(0x01000000U)		/**< Do not use VFP */
#define SCE_KERNEL_THREAD_ATTR_VM                       (0x04000000U)           /**< (Unofficial name) Virtual Machine thread (can use ForVM functions on it) */
/*@}*/

/**
 * @defgroup	Thread priority
 * Defining thread priorities
 */
/*@{*/
#define SCE_KERNEL_HIGHEST_PRIORITY_USER		(64)		/**< Highest priority of user mode threads */
#define SCE_KERNEL_LOWEST_PRIORITY_USER			(191)		/**< Lowest priority of user mode threads */

#define SCE_KERNEL_DEFAULT_PRIORITY			((SceInt32)0x10000100)		/**< Default priority (whole system) */

#define SCE_KERNEL_INDIVIDUAL_QUEUE_HIGHEST_PRIORITY	(64)		/**< Highest priority of individual queue area */
#define SCE_KERNEL_INDIVIDUAL_QUEUE_LOWEST_PRIORITY	(127)		/**< Lowest priority of individual queue area */
#define SCE_KERNEL_COMMON_QUEUE_HIGHEST_PRIORITY	(128)		/**< Highest priority of common queue area */
#define SCE_KERNEL_COMMON_QUEUE_LOWEST_PRIORITY		(191)		/**< Lowest priority of common queue area */

/**
 * Default priority (for users)
 * The default priority for game applications is converted to 160 internally.
 * You can also specify the default value ± offset (SCE_KERNEL_DEFAULT_PRIORITY_USER-10).
 */
#define SCE_KERNEL_DEFAULT_PRIORITY_USER		SCE_KERNEL_DEFAULT_PRIORITY

#define SCE_KERNEL_CURRENT_THREAD_PRIORITY		(0)		/**< The priority of the currently executing thread */
/*@}*/

/**
 * @defgroup	Thread stack size
 * Defining thread stack size
 */
/*@{*/
#define SCE_KERNEL_STACK_SIZE_MAX			SCE_KERNEL_1MiB				/**< Maximum stack size */
#define SCE_KERNEL_STACK_SIZE_MIN			SCE_KERNEL_4KiB				/**< Minimum stack size */

#define SCE_KERNEL_STACK_SIZE_DEFAULT			SCE_KERNEL_STACK_SIZE_MIN		/**< Default stack size */
#define SCE_KERNEL_STACK_SIZE_DEFAULT_USER_MAIN		(0x00040000)				/**< Default stack size of user main thread (byte) */

#define SCE_KERNEL_THREAD_STACK_SIZE_MAX		SCE_KERNEL_32MiB			/**< Maximum stack size */
#define SCE_KERNEL_THREAD_STACK_SIZE_MIN		SCE_KERNEL_4KiB				/**< Minimum stack size */

#define SCE_KERNEL_THREAD_STACK_SIZE_DEFAULT		SCE_KERNEL_THREAD_STACK_SIZE_MIN	/**< Default stack size */
#define SCE_KERNEL_THREAD_STACK_SIZE_DEFAULT_USER_MAIN	SCE_KERNEL_256KiB			/**< Default stack size of user main thread (byte) */
/*@}*/

/**
 * @defgroup	Thread state
 * Defining thread state
 */
/*@{*/
#define SCE_KERNEL_THREAD_STATUS_RUNNING		(0x00000001U)	/**< RUNNING status */
#define SCE_KERNEL_THREAD_STATUS_READY			(0x00000002U)	/**< READY status */
#define SCE_KERNEL_THREAD_STATUS_STANDBY		(0x00000004U)	/**< STANDBY status */
#define SCE_KERNEL_THREAD_STATUS_WAITING		(0x00000008U)	/**< WAITING status */
#define SCE_KERNEL_THREAD_STATUS_DORMANT		(0x00000010U)	/**< DORMANT status */
#define SCE_KERNEL_THREAD_STATUS_DELETED		(0x00000020U)	/**< DELETED status */
#define SCE_KERNEL_THREAD_STATUS_DEAD			(0x00000040U)	/**< DEAD status */
#define SCE_KERNEL_THREAD_STATUS_STAGNANT		(0x00000080U)	/**< STAGNANT status */
#define SCE_KERNEL_THREAD_STATUS_SUSPENDED		(0x00000100U)	/**< SUSPENDED status */

#define SCE_KERNEL_THREAD_STATUS_MASK			(0x0000ffffU)	/**< Valid thread state mask */
/*@}*/

/**
 * @defgroup	Thread wait type
 * Defining thread wait types
 */
/*@{*/
#if SCE_PSP2_SDK_VERSION < 0x01000000
#define SCE_KERNEL_WAITTYPE_DELAY			(0x00000001)	/**< Thread delay */
#define SCE_KERNEL_WAITTYPE_WAITTHEND			(0x00000002)	/**< End of thread */
#define SCE_KERNEL_WAITTYPE_EVENTFLAG			(0x00000004)	/**< Event flag */
#define SCE_KERNEL_WAITTYPE_MUTEX			(0x00000008)	/**< Mutex */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX			(0x00000010)	/**< Fast mutex */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_SPIN		(0x00000020)	/**< Fast mutex (spin) */
#define SCE_KERNEL_WAITTYPE_SEMAPHORE			(0x00000040)	/**< Semaphore */
#define SCE_KERNEL_WAITTYPE_EVENT			(0x00000080)	/**< Single event */
#define SCE_KERNEL_WAITTYPE_COND			(0x00000100)	/**< Condition variable */
#define SCE_KERNEL_WAITTYPE_MSG_PIPE			(0x00000200)	/**< Message pipe */
#define	SCE_KERNEL_WAITTYPE_RW_LOCK			(0x00000400)	/**< Reader / writer lock */
#define SCE_KERNEL_WAITTYPE_SIGNAL			(0x00000800)	/**< Signal */
#define SCE_KERNEL_WAITTYPE_LW_MUTEX			(0x00001000)	/**< Lightweight mutex */
#define SCE_KERNEL_WAITTYPE_LW_COND			(0x00002000)	/**< Lightweight condition variable */
#define SCE_KERNEL_WAITTYPE_MP_EVENTS			(0x00008000)	/**< Event multiplexing */

#define SCE_KERNEL_WAITTYPE_DELAY_CB			(0x00010001)	/**< With thread delay callback check */
#define SCE_KERNEL_WAITTYPE_WAITTHEND_CB		(0x00010002)	/**< With thread termination callback check */
#define SCE_KERNEL_WAITTYPE_EVENTFLAG_CB		(0x00010004)	/**< With event flag callback check */
#define SCE_KERNEL_WAITTYPE_MUTEX_CB			(0x00010008)	/**< With mutex callback check */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_CB		(0x00010010)	/**< With fast mutex callback check */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_SPIN_CB		(0x00010020)	/**< With fast mutex (spin) callback check */
#define SCE_KERNEL_WAITTYPE_SEMAPHORE_CB		(0x00010040)	/**< With semaphore callback check */
#define SCE_KERNEL_WAITTYPE_EVENT_CB			(0x00010080)	/**< With single event callback check */
#define SCE_KERNEL_WAITTYPE_COND_CB			(0x00010100)	/**< With condition variable callback check */
#define SCE_KERNEL_WAITTYPE_MSG_PIPE_CB			(0x00010200)	/**< With message pipe callback check */
#define	SCE_KERNEL_WAITTYPE_RW_LOCK_CB			(0x00010400)	/**< With reader / writer lock callback check */
#define SCE_KERNEL_WAITTYPE_SIGNAL_CB			(0x00010800)	/**< With signal callback check */
#define SCE_KERNEL_WAITTYPE_LW_MUTEX_CB			(0x00011000)	/**< With lightweight mutex callback check */
#define SCE_KERNEL_WAITTYPE_LW_COND_CB			(0x00012000)	/**< With lightweight condition variable callback check */
#define SCE_KERNEL_WAITTYPE_MP_EVENTS_CB		(0x00018000)	/**< With event multiplexing callback check */
#else
#define SCE_KERNEL_WAITTYPE_DELAY			(0x00000001U)	/**< Thread delay */
#define SCE_KERNEL_WAITTYPE_WAITTHEND			(0x00000002U)	/**< End of thread */
#define SCE_KERNEL_WAITTYPE_SIGNAL			(0x00000004U)	/**< Signal */
#define SCE_KERNEL_WAITTYPE_WAITTHSUSPEND		(0x00000008U)	/**< Suspend thread */
#define SCE_KERNEL_WAITTYPE_EVENTFLAG			(0x00000010U)	/**< Event flag */
#define SCE_KERNEL_WAITTYPE_SEMAPHORE			(0x00000020U)	/**< Semaphore */
#define SCE_KERNEL_WAITTYPE_MUTEX			(0x00000040U)	/**< Mutex */
#define SCE_KERNEL_WAITTYPE_RW_LOCK			(0x00000080U)	/**< Reader / writer lock */
#define SCE_KERNEL_WAITTYPE_COND_SIGNAL			(0x00000100U)	/**< Condition variable (signal) */
#define SCE_KERNEL_WAITTYPE_COND_MUTEX			(0x00000200U)	/**< Condition variable (mutex) */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX			(0x00001000U)	/**< Fast mutex */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_SPIN		(0x00002000U)	/**< Fast mutex (spin) */
#define SCE_KERNEL_WAITTYPE_EVENT			(0x00010000U)	/**< Single event */
#define SCE_KERNEL_WAITTYPE_MP_EVENTS			(0x00020000U)	/**< Event multiplexing */
#define SCE_KERNEL_WAITTYPE_MSG_PIPE			(0x00040000U)	/**< Message pipe */
#define SCE_KERNEL_WAITTYPE_LW_MUTEX			(0x00100000U)	/**< Lightweight mutex */
#define SCE_KERNEL_WAITTYPE_LW_COND_SIGNAL		(0x00200000U)	/**< Lightweight condition variable (signal) */
#define SCE_KERNEL_WAITTYPE_LW_COND_LW_MUTEX		(0x00400000U)	/**< Lightweight condition variable (mutex) */

#define SCE_KERNEL_WAITTYPE_DELAY_CB			(0x80000001U)	/**< With thread delay callback check */
#define SCE_KERNEL_WAITTYPE_WAITTHEND_CB		(0x80000002U)	/**< With thread termination callback check */
#define SCE_KERNEL_WAITTYPE_SIGNAL_CB			(0x80000004U)	/**< With signal callback check */
#define SCE_KERNEL_WAITTYPE_WAITTHSUSPEND_CB		(0x80000008U)	/**< With suspend thread callback check */
#define SCE_KERNEL_WAITTYPE_EVENTFLAG_CB		(0x80000010U)	/**< With event flag callback check */
#define SCE_KERNEL_WAITTYPE_SEMAPHORE_CB		(0x80000020U)	/**< With semaphore callback check */
#define SCE_KERNEL_WAITTYPE_MUTEX_CB			(0x80000040U)	/**< With mutex callback check */
#define SCE_KERNEL_WAITTYPE_RW_LOCK_CB			(0x80000080U)	/**< With reader / writer lock callback check */
#define SCE_KERNEL_WAITTYPE_COND_SIGNAL_CB		(0x80000100U)	/**< With condition variable (signal) callback check */
#define SCE_KERNEL_WAITTYPE_COND_MUTEX_CB		(0x80000200U)	/**< With condition variable (mutex) callback check */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_CB		(0x80001000U)	/**< With fast mutex callback check */
#define SCE_KERNEL_WAITTYPE_FAST_MUTEX_SPIN_CB		(0x80002000U)	/**< With fast mutex (spin) callback check */
#define SCE_KERNEL_WAITTYPE_EVENT_CB			(0x80010000U)	/**< With single event callback check */
#define SCE_KERNEL_WAITTYPE_MP_EVENTS_CB		(0x80020000U)	/**< With event multiplexing callback check */
#define SCE_KERNEL_WAITTYPE_MSG_PIPE_CB			(0x80040000U)	/**< With message pipe callback check */
#define SCE_KERNEL_WAITTYPE_LW_MUTEX_CB			(0x80100000U)	/**< With lightweight mutex callback check */
#define SCE_KERNEL_WAITTYPE_LW_COND_SIGNAL_CB		(0x80200000U)	/**< With lightweight condition variable (signal) callback check */
#define SCE_KERNEL_WAITTYPE_LW_COND_LW_MUTEX_CB		(0x80400000U)	/**< With lightweight condition variable (mutex) callback check */
#endif
/*@}*/

/**
 * @defgroup	UID
 * Thread ID definition
 */
/*@{*/
#define SCE_KERNEL_THREAD_ID_SELF			(0)	/**< UID representing own thread */
/*@}*/

/**
 * @defgroup	UID class
 * Class definition of UID managed by thread manager (for User)
 */
/*@{*/
#define SCE_KERNEL_THREADMGR_UID_CLASS_THREAD		(1)	/**< Thread class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_SEMA		(2)	/**< Semaphore class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_EVENT_FLAG	(3)	/**< Event flag class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_MUTEX		(4)	/**< Mutex class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_COND		(5)	/**< Condition variable class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_TIMER		(6)	/**< Timer class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_MSG_PIPE		(7)	/**< Message pipe class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_CALLBACK		(8)	/**< Callback class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_THREAD_EVENT	(9)	/**< Thread event class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_LW_MUTEX		(10)	/**< Lightweight mutex class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_LW_COND		(11)	/**< Lightweight condition variable class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_RW_LOCK		(12)	/**< Reader / writer lock class */
#define SCE_KERNEL_THREADMGR_UID_CLASS_SIMPLE_EVENT	(13)	/**< Simple event class */
/*@}*/

/**
 * @defgroup	CPU affinity mask
 * CPU affinity mask definition
 */
/*@{*/
/**
 * @brief Default CPU affinity mask
 *
 * If the default CPU affinity mask is specified for a thread,
 * the CPU affinity mask specified for the process to which it belongs is inherited.
 */
#define SCE_KERNEL_THREAD_CPU_AFFINITY_MASK_DEFAULT	(0)
/*@}*/

/**
 * @brief Thread entry type
 *
 * Thread entry function type. Specify to sceKernelCreateThread().
 * The argument block of the thread given by the argument of sceKernelStartThread() is copied onto the
 * stack of the started thread, and is received from the started thread through the argument of the entry function.
 *
 * When a thread entry function is terminated with return, the thread terminates,
 * and the return value of the entry function becomes the termination status of that thread.
 * The thread exit status can be obtained with sceKernelWaitThreadEnd() or
 * sceKernelGetThreadExitStatus() if the thread is not deleted.
 *
 * @param	argSize		The argument size given by sceKernelStartThread() is passed.
 * @param	pArgBlock	The address on the stack where the argument block given by sceKernelStartThread() is copied is passed.
 * @return	Thread exit status
 */
typedef SceInt32	(*SceKernelThreadEntry)(SceSize argSize, void *pArgBlock);

/**
 * @brief Stack change function type
 *
 * The type of function to call when the stack changes. Specify to sceKernelCallWithChangeStack().
 *
 * With sceKernelCallWithChangeStack(), the stack is switched as soon as the stack change function is called.
 * As soon as the stack change function ends with return, it returns to the original stack.
 *
 * @param	pArg	Arbitrary pointer to pass to stack change function
 * @return	Return value of sceKernelCallWithChangeStack()
 */
typedef SceInt32	(*SceKernelChangeStackFunction)(void *pArg);

/**
 * @brief Thread additional data
 *
 * This structure is used to store additional data given when creating a thread with sceKernelCreateThread().
 *
 * Provided for future expansion.
 *
 */
typedef struct _SceKernelThreadOptParam { // Min size is 4 bytes. Max size is 0x14 bytes.
	SceSize				size;			/**< Size of this structure (sizeof(SceKernelThreadOptParam)) */
	SceUInt32			attr;			/**< A bit pattern that specifies valid members in a structure */
	SceUInt32           kStackMemType;
	SceUInt32           uStackMemType;
	SceUInt32           uTLSMemType;
	SceUInt32           uStackMemid;
	SceUInt32           data_0x18;
} SceKernelThreadOptParam;

/**
 * @brief Thread information structure
 *
 * A structure used to store thread information with sceKernelGetThreadInfo().
 */
typedef struct _SceKernelThreadInfo {
	SceSize				size;				/**< Size of this structure (sizeof(SceKernelThreadInfo)) */
	SceUID				processId;			/**< Process ID to which the thread belongs */
	char				name[SCE_UID_NAMELEN+1];	/**< Thread name */
	SceUInt32			attr;				/**< Thread attributes */
	SceUInt32			status;				/**< Thread state */
	SceKernelThreadEntry		entry;				/**< Thread entry function address */
	void				*pStack;			/**< Thread stack address (bottom) */
	SceSize				stackSize;			/**< Thread stack size */
	SceInt32			initPriority;			/**< Thread initial priority */
	SceInt32			currentPriority;		/**< Thread current priority */
	SceInt32			initCpuAffinityMask;		/**< Thread initial CPU affinity mask */
	SceInt32			currentCpuAffinityMask;		/**< Thread current CPU affinity mask */
	SceInt32			currentCpuId;			/**< CPU number to which the thread currently belongs */
	SceInt32			lastExecutedCpuId;		/**< CPU number to which the thread was last executed */
	SceUInt32			waitType;			/**< Type when the thread is waiting */
	SceUID				waitId;				/**< UID of the target synchronization object when the thread is waiting */
	SceInt32			exitStatus;			/**< Thread exit status */
	SceKernelSysClock		runClocks;			/**< Time (in microseconds) executed since the thread was created */
	SceUInt32			intrPreemptCount;		/**< Number of times the thread was preempted by interrupt handling */
	SceUInt32			threadPreemptCount;		/**< Number of times the thread has been preempted by other thread operations */
	SceUInt32			threadReleaseCount;		/**< Number of times the thread has relinquished execution */
	SceInt32			changeCpuCount;			/**< Number of CPUs to which the thread is moved */
	SceInt32			fNotifyCallback;		/**< A flag indicating whether the thread is notified of the callback */
	SceInt32			reserved;			/**< Reserved area */
} SceKernelThreadInfo;

/**
 * @brief Thread operating status on each CPU
 *
 * This structure is used by sceKernelGetThreadRunStatus() to obtain the operating status of threads on each CPU.
 *
 */
typedef struct _SceKernelThreadRunStatus {
	SceSize		size;			/**< Size of this structure (sizeof(SceKernelThreadRunStatus)) */
	struct {
		SceUID		processId;		/**< Process ID to which the running thread belongs */
		SceUID		threadId;		/**< Thread ID being executed */
		SceInt32	priority;		/**< Priority of the running thread */
	} cpuInfo[SCE_KERNEL_MAX_CPU];		/**< Information about individual CPUs */
} SceKernelThreadRunStatus;

/**
 * @brief System state
 *
 * This structure is used to get the system status with sceKernelGetSystemInfo().
 *
 */
typedef struct _SceKernelSystemInfo {
	SceSize			size;				/**< Size of this structure (sizeof(SceKernelSystemInfo)) */
	SceUInt32		activeCpuMask;			/**< Currently available CPU mask */
	struct	{
		SceKernelSysClock	idleClock;			/**< Time when there was no thread to execute */
		SceUInt32		comesOutOfIdleCount;		/**< Number of transitions from a state where there is no thread to execute to another state */
		SceUInt32		threadSwitchCount;		/**< Number of context switches that occurred */
	} cpuInfo[SCE_KERNEL_MAX_CPU];				/**< Information about individual CPUs */
} SceKernelSystemInfo;

/*@}*//* Basic thread functions */

/** @name	VFP exception
 */
/*@{*/

/**
 * @defgroup	Defining VFP exceptions
 * Bit pattern that specifies a VFP exception
 */
/*@{*/
#define SCE_KERNEL_VFP_EXCEPTION_MASK_QCE		(0x08000000U)		/**< QCE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_IDE		(0x00000080U)		/**< IDE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_IXE		(0x00000010U)		/**< IXE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_UFE		(0x00000008U)		/**< UFE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_OFE		(0x00000004U)		/**< OFE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_DZE		(0x00000002U)		/**< DZE flag interrupt enable */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_IOE		(0x00000001U)		/**< IOE flag interrupt enable */

/**
 * Valid VFP exception mask
 */
#define SCE_KERNEL_VFP_EXCEPTION_MASK_ALL	(SCE_KERNEL_VFP_EXCEPTION_MASK_QCE | SCE_KERNEL_VFP_EXCEPTION_MASK_IDE | \
						SCE_KERNEL_VFP_EXCEPTION_MASK_IXE | SCE_KERNEL_VFP_EXCEPTION_MASK_UFE | \
						SCE_KERNEL_VFP_EXCEPTION_MASK_OFE | SCE_KERNEL_VFP_EXCEPTION_MASK_DZE | \
						SCE_KERNEL_VFP_EXCEPTION_MASK_IOE)
/*@}*/

/*@}*//* VFP exception */

/** @name	Common to synchronization
 */
/*@{*/

/**
 * @defgroup	Synchronization object common attributes
 * Attributes that can be set in common with synchronization objects
 */
/*@{*/
#define SCE_KERNEL_ATTR_SINGLE			(0x00000000U)	/**< Multiple threads cannot wait simultaneously (event flags only) */
#define SCE_KERNEL_ATTR_MULTI			(0x00001000U)	/**< Multiple threads can wait at the same time (event flags only) */
#define SCE_KERNEL_ATTR_TH_FIFO			(0x00000000U)	/**< Waiting thread queuing is FIFO */
#define SCE_KERNEL_ATTR_TH_PRIO			(0x00002000U)	/**< Queues for waiting threads are ordered by thread priority */
#define SCE_KERNEL_ATTR_MS_FIFO			(0x00000000U)	/**< Unused */
#define SCE_KERNEL_ATTR_MS_PRIO			(0x00000000U)	/**< Unused */
#define SCE_KERNEL_ATTR_OPENABLE		(0x00000080U)	/**< Object can be referenced */
/*@}*/

/**
 * @defgroup	Referencing synchronization objects
 * Definitions for references to synchronization objects
 */
/*@{*/
#define SCE_KERNEL_OPEN_LIMIT_MAX	(127)	/**< Maximum value that can be specified when limiting the number of simultaneous references of synchronization objects */
/*@}*/

/*@}*//* Common to synchronization */

/** @name	Callback
 */
/*@{*/

/**
 * @brief Callback function type
 *
 * After the callback function is notified by sceKernelNotifyCallback(), the callback function
 * confirms the notification by sceKernelCheckCallback() or executes a waiting function with a
 * function to check for notifications such as sceKernelWaitSemaCB().
 * It is possible to delete your own registration by returning a value other than 0 as the return value of the callback function.
 *
 * Note
 * - The callback function is called as the context of the thread that generated the callback.
 *   In other words, the callback function can be called only by the callback generated by the own thread by the explicit callback
 *   check by sceKernelCheckCallback() or the wait function with callback check such as sceKernelWaitSemaCB(). is. To receive
 *   the callback notification, the thread that generated the callback must use sceKernelCheckCallback(), sceKernelWaitSemaCB(), etc.
 * - The sceKernelCheckCallback() and sceKernelDeleteCallback() functions cannot be used inside the callback function.
 *   In addition, if you call a wait function with CB such as sceKernelWaitSemaCB() function in the callback function, nesting occurs, causing a stack overflow.
 *   Avoid processing that waits for more callbacks in the callback function.
 *
 * @param	notifyId		When a callback is notified from an event that registered a callback with sceKernelRegisterCallbackToEvent(),
 *					the identifier of the notification source event is passed.
 *					If not notified from the event, SCE_UID_INVALID_UID is passed.
 * @param	notifyCount		Number of callback notifications until this callback function is executed is passed.
 * @param	notifyArg		Argument given by sceKernelNotifyCallback() is passed.
 * @param	pCommon			Argument given by sceKernelCreateCallback() is passed.
 * @retval	0			Normal
 * @retval	Non-zero value		Remove this callback
 */
typedef SceInt32	(*SceKernelCallbackFunction)(SceUID notifyId, SceInt32 notifyCount, SceInt32 notifyArg, void *pCommon);

/**
 * @brief Callback state
 *
 * This structure is used to get the callback status with sceKernelGetCallbackInfo().
 */
typedef struct _SceKernelCallbackInfo {
	SceSize		size;				/**< Size of this structure (sizeof(SceKernelCallbackInfo) */
	SceUID		callbackId;			/**< Callback identifier */
	char		name[SCE_UID_NAMELEN + 1];	/**< Name of the callback specified with sceKernelCreateCallback() */
	SceUInt32	attr;				/**< Callback attribute specified by sceKernelCreateCallback() */
	SceUID		threadId;			/**< Identifier of the thread to which the callback belongs */
	SceKernelCallbackFunction	callbackFunc;	/**< Callback function registered with sceKernelCreateCallback() */
	SceUID		notifyId;			/**< Caller notification source identifier */
	SceInt32	notifyCount;			/**< Number of times sceKernelNotifyCallback() has been executed for this callback that is still delayed without the callback function being called */
	SceInt32	notifyArg;			/**< Argument given by sceKernelNotifyCallback() for this callback */
	void		*pCommon;			/**< pCommon argument registered with sceKernelCreateCallback() */
} SceKernelCallbackInfo;

/*@}*//* Callback */

/** @name	Thread event
 */
/*@{*/

/**
 * @defgroup	Thread event handler type
 * Defining thread events that trigger thread event handlers
 */
/*@{*/
#define SCE_KERNEL_THREAD_EVENT_TYPE_START		(0x04)	/**< Thread start event */
#define SCE_KERNEL_THREAD_EVENT_TYPE_EXIT		(0x08)	/**< Thread end event */

/**
 * Valid thread event mask
 */
#define SCE_KERNEL_THREAD_EVENT_TYPE_ALL		(SCE_KERNEL_THREAD_EVENT_TYPE_START | SCE_KERNEL_THREAD_EVENT_TYPE_EXIT)
/*@}*/

/**
 * @defgroup	Thread specification for thread event handler
 * Thread specification macro in sceKernelRegisterThreadEventHandler()
 */
/*@{*/
#define SCE_KERNEL_THREAD_ID_USER	((SceUID)0xfffffff0)	/**< Specify all user threads */
/*@}*/

/**
 * @brief Thread event handler type
 *
 * Thread event handler type.
 * @param	type		The thread event handler call cause is passed.
 *				- SCE_KERNEL_THREAD_EVENT_TYPE_START: thread started
 *				- SCE_KERNEL_THREAD_EVENT_TYPE_EXIT : thread terminated
 * @param	threadId	Identifier of the thread that caused the thread event handler to be called is passed.
 * @param	arg		Argument when calling the thread event handler is passed.
 * @param	pCommon		pCommon specified in sceKernelRegisterThreadEventHandler() is passed as it is.
 * @retval	SCE_OK		Success
 * @retval	Any value other than SCE_OK	Remove this thread event handler
 */
typedef SceInt32	(*SceKernelThreadEventHandler)(SceInt32 type, SceUID threadId, SceInt32 arg, void *pCommon);

/*@}*//* Thread event */

/** @name	An event
 */
/*@{*/

/**
 * @defgroup	Event object attributes
 * Definition of attributes to be specified when creating an event object
 */
/*@{*/
#define SCE_KERNEL_EVENT_ATTR_MANUAL_RESET	(0x00000000U)	/**< Each bit of the event remains in the event notification state until it is manually transitioned to the event non notification state. */
#define SCE_KERNEL_EVENT_ATTR_AUTO_RESET	(0x00000100U)	/**< Each bit of the event automatically returns to the event non notification state when one waiting thread is woken up. */

#define SCE_KERNEL_ATTR_NOTIFY_CB_ALL		(0x00000000U)	/**< When an event is notified, all callbacks registered in the event object are notified. */
#define SCE_KERNEL_ATTR_NOTIFY_CB_WAKEUP_ONLY	(0x00000800U)	/**< When an event is notified, only the callback of the thread that is waiting for the event and wakes up among the callbacks registered in the event object is notified. */
/*@}*/

/**
 * @defgroup	Event type
 * Definition of event to be notified
 */
/*@{*/
#define SCE_KERNEL_EVENT_IN			(0x00000001U)	/* Input event */
#define SCE_KERNEL_EVENT_OUT			(0x00000002U)	/* Output event */
#define SCE_KERNEL_EVENT_CREATE			(0x00000004U)	/* Generate event */
#define SCE_KERNEL_EVENT_DELETE			(0x00000008U)	/* Delete event */
#define SCE_KERNEL_EVENT_ERROR			(0x00000010U)	/* Error event */
#define SCE_KERNEL_EVENT_OPEN			(0x00000100U)	/* Reference event */
#define SCE_KERNEL_EVENT_CLOSE			(0x00000200U)	/* Reference end event */
#define SCE_KERNEL_EVENT_TIMER			(0x00008000U)	/* Timer event */
#define SCE_KERNEL_EVENT_DATA_EXIST		(0x00010000U)	/* Event that is notified when data exists in the message pipe buffer (level trigger) */

#define SCE_KERNEL_EVENT_USER_DEFINED_MASK	(0xff000000U)	/* User-defined event mask */

/*@}*/

/**
 * @brief Event object state
 *
 * This structure is used to acquire the event object status with sceKernelGetEventInfo().
 */
typedef struct _SceKernelEventInfo {
	SceSize		size;					/**< Size of this structure (sizeof(SceKernelEventInfo)) */
	SceUID		eventId;				/**< Event object identifier */
	char		name[SCE_UID_NAMELEN + 1];		/**< Name of the event specified when creating the event object */
	SceUInt32	attr;					/**< Event attributes specified when creating the event object */
	SceUInt32	eventPattern;				/**< Bit pattern of the current event */
	SceUInt64	userData;				/**< User data added to the last notified event */
	SceUInt32	numWaitThreads;				/**< Number of threads waiting for the event object */
	SceInt32	reserved[1];				/**< Reserved area */
} SceKernelEventInfo;

/**
 * @defgroup	Standby mode for event object multiple standby
 * Definition of standby mode specified in sceKernelWaitMultipleEvents()
 */
/*@{*/
#define SCE_KERNEL_EVENT_WAIT_MODE_OR	(0x00000001U)	/**< Wait until one of the waits specified in the event wait condition list is met */
#define SCE_KERNEL_EVENT_WAIT_MODE_AND	(0x00000002U)	/**< Wait until all waits specified in the event wait condition list are satisfied */
/*@}*/

/**
 * @brief Structure for event wait condition list
 *
 * Structure for event waiting condition list passed to sceKernelWaitMultipleEvents().
 */
typedef struct	_SceKernelWaitEvent {
	SceUID		eventId;			/**< Event object identifier */
	SceUInt32	eventPattern;			/**< Pattern of events to wait */
} SceKernelWaitEvent;

/**
 * @brief Structure for event waiting result acquisition list
 *
 * Structure for event waiting result acquisition list to be passed to sceKernelWaitMultipleEvents().
 */
typedef struct	_SceKernelResultEvent {
	SceUID		eventId;			/**< Event object identifier */
	SceInt32	result;				/**< Wait result (equivalent to return value of sceKernelWaitEvent()) */
	SceUInt32	resultPattern;			/**< Event pattern when waiting completes */
	SceInt32	reserved[1];			/**< Reserved area */
	SceUInt64	userData;			/**< User data received when waiting completed */
} SceKernelResultEvent;

/*@}*//* An event */

/**
 * @name	Event flag
 */
/*@{*/

/**
 * @defgroup	Event flag attributes
 * Definition of attributes to be specified when generating eventflags
 */
/*@{*/
#define SCE_KERNEL_EVF_ATTR_TH_FIFO		SCE_KERNEL_ATTR_TH_FIFO		/**< Event flag waiting thread queuing is FIFO */
#define SCE_KERNEL_EVF_ATTR_TH_PRIO		SCE_KERNEL_ATTR_TH_PRIO		/**< Event flag waiting threads are queued in order of thread priority. */
#define SCE_KERNEL_EVF_ATTR_SINGLE		SCE_KERNEL_ATTR_SINGLE		/**< Multiple threads cannot wait at the same time */
#define SCE_KERNEL_EVF_ATTR_MULTI		SCE_KERNEL_ATTR_MULTI		/**< Multiple threads can wait at the same time */
/*@}*/

/**
 * @defgroup	Event flag wait mode
 * Definition of standby mode specified for eventflag standby
 */
/*@{*/
#define SCE_KERNEL_EVF_WAITMODE_AND		(0x00000000U)	/**< Waiting for AND */
#define SCE_KERNEL_EVF_WAITMODE_OR		(0x00000001U)	/**< Waiting for OR */
#define SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL	(0x00000002U)	/**< Clear all bits after waiting */
#define SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT	(0x00000004U)	/**< After waiting, clear the bit specified in bitPattern */
/*@}*/

/**
 * @brief Additional data for event flag
 *
 * This structure is used to store additional data to be given when creating an event flag with sceKernelCreateEventFlag().
 *
 * 将来の拡張のために用意されています。
 *
 */
typedef struct _SceKernelEventFlagOptParam {
	SceSize	size;						/**< Size of this structure (sizeof(SceKernelEventFlagOptParam)) */
} SceKernelEventFlagOptParam;

/**
 * @brief Event flag status
 *
 * This structure is used to acquire the event flag status with sceKernelGetEventFlagInfo().
 *
 */
typedef struct _SceKernelEventFlagInfo {
	SceSize		size;					/**< Size of this structure (sizeof(SceKernelEventFlagInfo)) */
	SceUID		evfId;					/**< Event flag identifier */
	char		name[SCE_UID_NAMELEN + 1];		/**< Name of the eventflag specified by sceKernelCreateEventFlag() */
	SceUInt32	attr;					/**< Event flag attribute specified by sceKernelCreateEventFlag() */
	SceUInt32	initPattern;				/**< Initial bit pattern of event flag */
	SceUInt32	currentPattern;				/**< Current bit pattern of event flag */
	SceUInt32	numWaitThreads;				/**< Number of threads waiting for an event */
} SceKernelEventFlagInfo;

/*@}*//* Event flag */

/**
 * @name	Semaphore
 */
/*@{*/

/**
 * @defgroup	Semaphore attributes
 * Definition of attributes to be specified when creating a semaphore
 */
/*@{*/
#define SCE_KERNEL_SEMA_ATTR_TH_FIFO		SCE_KERNEL_ATTR_TH_FIFO		/**< Semaphore waiting thread queuing is FIFO */
#define SCE_KERNEL_SEMA_ATTR_TH_PRIO		SCE_KERNEL_ATTR_TH_PRIO		/**< Semaphore waiting thread queuing is ordered by thread priority */
/*@}*/

/**
 * @brief Additional semaphore data
 *
 * This structure is used to store additional data given when creating a semaphore with sceKernelCreateSema().
 *
 * Provided for future expansion.
 *
 */
typedef struct _SceKernelSemaOptParam {
	SceSize	size;			/**< Size of this structure (sizeof(SceKernelSemaOptParam)) */
} SceKernelSemaOptParam;

/**
 * @brief Semaphore state
 *
 * This structure is used to get the semaphore status with sceKernelGetSemaInfo().
 *
 */
typedef struct _SceKernelSemaInfo {
	SceSize		size;					/**< Size of this structure (sizeof(SceKernelSemaInfo)) */
	SceUID		semaId;					/**< Semaphore identifier */
	char		name[SCE_UID_NAMELEN + 1];		/**< Name of the semaphore specified by sceKernelCreateSema() */
	SceUInt32	attr;					/**< Semaphore attributes specified with sceKernelCreateSema() */
	SceInt32	initCount;				/**< Initial number of semaphores specified by sceKernelCreateSema() */
	SceInt32	currentCount;				/**< Current number of semaphore resources */
	SceInt32	maxCount;				/**< Maximum number of semaphore resources specified by sceKernelCreateSema() */
	SceInt32	numWaitThreads;				/**< Number of threads waiting for the semaphore */
} SceKernelSemaInfo;

/*@}*//* Semaphore */

/**
 * @name	Mutex
 */
/*@{*/

/**
 * @defgroup	Mutex attribute
 * Definition of attributes to be specified when creating a mutex
 */
/*@{*/
#define SCE_KERNEL_MUTEX_ATTR_TH_FIFO		SCE_KERNEL_ATTR_TH_FIFO		/**< Mutex wait thread queuing is FIFO */
#define SCE_KERNEL_MUTEX_ATTR_TH_PRIO		SCE_KERNEL_ATTR_TH_PRIO		/**< Mutes waiting threads are queued in order of thread priority */
#define SCE_KERNEL_MUTEX_ATTR_RECURSIVE		(0x00000002U)			/**< Mutex can be recursively locked */
#define SCE_KERNEL_MUTEX_ATTR_CEILING		(0x00000004U)			/**< Use the mutex priority sealing function */
/*@}*/

/**
 * @brief Mutex additional data
 *
 * This structure is used to store additional data given when creating mutexes with sceKernelCreateMutex().
 *
 * Provided for future expansion.
 *
 */
typedef struct _SceKernelMutexOptParam {
	SceSize		size;			/**< Size of this structure (sizeof(SceKernelMutexOptParam)) */
	SceInt32	ceilingPriority;	/**< Priority ceiling priority */
} SceKernelMutexOptParam;

/**
 * @brief Mutex state
 *
 * This structure is used to get the mutex status with sceKernelGetMutexInfo().
 *
 */
typedef struct _SceKernelMutexInfo {
	SceSize		size;					/**< Size of this structure (sizeof(SceKernelMutexInfo)) */
	SceUID		mutexId;				/**< Mutex identifier */
	char		name[SCE_UID_NAMELEN + 1];		/**< Name of the mutex specified by sceKernelCreateMutex() */
	SceUInt32	attr;					/**< Mutex attributes specified with sceKernelCreateMutex() */
	SceInt32	initCount;				/**< Initial lock count of mutex specified by sceKernelCreateMutex() */
	SceInt32	currentCount;				/**< Current number of mutex locks */
	SceUID		currentOwnerId;				/**< Identifier of the thread that currently owns the mutex */
	SceUInt32	numWaitThreads;				/**< Number of threads waiting for the mutex */
	SceInt32	ceilingPriority;			/**< Priority ceiling priority (0 if priority ceiling function is not used) */
} SceKernelMutexInfo;

/*@}*//* Mutex */


/**
 * @name	Lightweight mutex
 */
/*@{*/

/**
 * @defgroup	Lightweight mutex attribute
 * Definition of attributes to be specified when creating a lightweight mutex
 */
/*@{*/
#define SCE_KERNEL_LW_MUTEX_ATTR_TH_FIFO		SCE_KERNEL_ATTR_TH_FIFO	/**< Lightweight mutex wait thread queuing is FIFO */
#define SCE_KERNEL_LW_MUTEX_ATTR_TH_PRIO		SCE_KERNEL_ATTR_TH_PRIO	/**< Queues for lightweight mutex wait threads are ordered by thread priority */
#define SCE_KERNEL_LW_MUTEX_ATTR_RECURSIVE		(0x00000002U)           /**< Lightweight mutex can be recursively locked */
/*@}*/

/**
 * @brief Light mutex work area
 *
 * A structure used to store work areas used by lightweight mutexes.
 * The lightweight mutex work area must be reserved in the user memory space.
 * All operations on the lightweight mutex are performed via the SceKernelLwMutexWork structure.
 *
 * Since the SceKernelLwMutexWork structure is used as a work area by the kernel, after creating
 * a lightweight mutex with sceKernelCreateLwMutex(), the user program must not directly
 * reference / manage the contents until it is deleted with sceKernelDeleteLwMutex(). The address cannot be moved.
 *
 * The SceKernelLwMutexWork structure must be arranged with 8-byte alignment on the memory.
 *
 */
typedef struct	_SceKernelLwMutexWork {
	SceInt64	data[4];				/**< Light mutex work area */
} SceKernelLwMutexWork;

/**
 * @brief Additional data for lightweight mutex
 *
 * This structure is used to store additional data given when creating a lightweight mutex with sceKernelCreateLwMutex().
 *
 * Provided for future expansion.
 *
 */
typedef struct _SceKernelLwMutexOptParam {
	SceSize	size;						/**< Size of this structure (sizeof(SceKernelLwMutexOptParam)) */
} SceKernelLwMutexOptParam;

/**
 * @brief Light mutex state
 *
 * A structure used to obtain the status of a lightweight mutex with sceKernelGetLwMutexInfo().
 *
 */
typedef struct _SceKernelLwMutexInfo {
	SceSize			size;					/**< Size of this structure (sizeof(SceKernelLwMutexInfo)) */
	SceUID			uid;					/**< Lightweight mutex identifier */
	char			name[SCE_UID_NAMELEN + 1];		/**< Name of the mutex specified by sceKernelCreateLwMutex() */
	SceUInt32		attr;					/**< Mutex attributes specified with sceKernelCreateLwMutex() */
	SceKernelLwMutexWork	*pWork;					/**< Mutex work area specified by sceKernelCreateLwMutex() */
	SceInt32		initCount;				/**< Initial number of lw mutex locks specified by sceKernelCreateLwMutex() */
	SceInt32		currentCount;				/**< Current lock count of lightweight mutex */
	SceUID			currentOwnerId;				/**< Identifier of the thread that currently owns the lightweight mutex */
	SceUInt32		numWaitThreads;				/**< Number of threads waiting for the lightweight mutex */
} SceKernelLwMutexInfo;

/*@}*//* Lightweight mutex */

/** @name	Condition variable
 */
/*@{*/

/**
 * @defgroup	Condition variable attributes
 * Defining attributes to be specified when creating a condition variable
 */
/*@{*/
#define SCE_KERNEL_COND_ATTR_TH_FIFO		SCE_KERNEL_ATTR_TH_FIFO		/**< Condition variable wait thread queuing is FIFO */
#define SCE_KERNEL_COND_ATTR_TH_PRIO		SCE_KERNEL_ATTR_TH_PRIO		/**< Condition variable wait thread queuing is in order of thread priority */
/*@}*/

/**
 * @brief Additional data for condition variables
 *
 * This structure is used to store additional data given when creating a condition variable with sceKernelCreateCond().
 *
 * Provided for future expansion.
 *
 */
typedef struct _SceKernelCondOptParam {
	SceSize	size;						/**< Size of this structure (sizeof(SceKernelMutexOptParam)) */
} SceKernelCondOptParam;

/**
 * @brief Condition variable state
 *
 * This structure is used to acquire the condition variable status with sceKernelGetCondInfo().
 *
 */
typedef struct _SceKernelCondInfo {
	SceSize		size;					/**< Size of this structure (sizeof(SceKernelCondInfo)) */
	SceUID		condId;					/**< Condition variable identifier */
	char		name[SCE_UID_NAMELEN + 1];		/**< Condition variable name specified in sceKernelCreateCond() */
	SceUInt32	attr;					/**< Condition variable attribute specified in sceKernelCreateCond() */
	SceUID		mutexId;				/**< Mutex associated with the condition variable specified by sceKernelCreateCond() */
	SceUInt32	numWaitThreads;				/**< Number of threads waiting for the condition variable */
} SceKernelCondInfo;

/*@}*//* Condition variable */

/** @name	Lightweight condition variable
 */
/*@{*/

/**
 * @defgroup	Lightweight condition variable attributes
 * Definition of attributes to be specified when creating lightweight condition variables
 */
/*@{*/
#define SCE_KERNEL_LW_COND_ATTR_TH_FIFO		SCE_KERNEL_ATTR_TH_FIFO		/**< Lightweight condition variable waiting thread queuing is FIFO */
#define SCE_KERNEL_LW_COND_ATTR_TH_PRIO		SCE_KERNEL_ATTR_TH_PRIO		/**< Lightweight condition variable waiting thread queuing is ordered by thread priority */
/*@}*/

/**
 * @brief Lightweight condition variable work area
 *
 * A structure used to store the work area used by the lightweight condition variable.
 * The work area for lightweight condition variables must be allocated in the user memory space.
 * All operations on lightweight condition variables are done via the SceKernelLwCondWork structure.
 *
 * Since the SceKernelLwCondWork structure is used as a work area by the kernel, once a
 * lightweight condition variable is created with sceKernelCreateLwCond(), the contents must not be directly
 * referenced / operated by the user program until it is deleted with sceKernelDeleteLwCond(). The address cannot be moved.
 */
typedef struct	_SceKernelLwCondWork {
	SceInt32	data[4];				/**< Lightweight condition variable work area */
} SceKernelLwCondWork;

/**
 * @brief Additional data for lightweight condition variables
 *
 * This structure is used to store additional data given when creating a lightweight condition variable with sceKernelCreateLwCond().
 *
 * Provided for future expansion.
 *
 */
typedef struct _SceKernelLwCondOptParam {
	SceSize	size;						/**< Size of this structure (sizeof(SceKernelLwCondOptParam)) */
} SceKernelLwCondOptParam;

/**
 * @brief Lightweight condition variable state
 *
 * sceKernelGetLwCondInfo() is a structure used to obtain the status of a lightweight condition variable.
 *
 */
typedef struct _SceKernelLwCondInfo {
	SceSize			size;				/**< Size of this structure (sizeof(SceKernelLwCondInfo)) */
	SceUID			uid;				/**< Lightweight condition variable identifier */
	char			name[SCE_UID_NAMELEN + 1];	/**< Name of the lightweight condition variable specified with sceKernelCreateLwCond() */
	SceUInt32		attr;				/**< Attributes of lightweight condition variable specified by sceKernelCreateLwCond() */
	SceKernelLwCondWork	*pWork;				/**< Work area of lightweight condition variable specified by sceKernelCreateLwCond() */
	SceKernelLwMutexWork	*pLwMutex;			/**< Lightweight mutex work area associated with the lightweight condition variable specified by sceKernelCreateLwCond() */
	SceUInt32		numWaitThreads;			/**< Number of threads waiting for lightweight condition variables */
} SceKernelLwCondInfo;

/*@}*//* Lightweight condition variable */

/** @name	Timer
 */
/*@{*/

/**
 * @defgroup	Type of timer event notification
 * Defining timer event notification types
 */
/*@{*/
#define SCE_KERNEL_TIMER_TYPE_SET_EVENT		(0)	/**< Timer is notified by set type event */
#define SCE_KERNEL_TIMER_TYPE_PULSE_EVENT	(1)	/**< Timer is notified by pulse type event */
/*@}*/

/**
 * @brief Additional data for timer
 *
 * This structure is used to store additional data given when a timer is created with sceKernelCreateTimer().
 *
 * Provided for future expansion.
 */
typedef struct	_SceKernelTimerOptParam {
	SceSize				size;			/**< Size of this structure (sizeof(SceKernelTimerOptParam)) */
} SceKernelTimerOptParam;

/**
 * @brief Timer information
 *
 * Timer information acquisition structure.
 */
typedef struct	_SceKernelTimerInfo {
	SceSize			size;				/**< Size of this structure (sizeof(SceKernelTimerInfo)) */
	SceUID			timerId;			/**< Timer identifier */
	char			name[SCE_UID_NAMELEN + 1];	/**< Timer name specified by sceKernelCreateTimer() */
	SceUInt32		attr;				/**< Timer attribute specified by sceKernelCreateTimer() */
	SceInt32		fActive;			/**< Timer start flag (if 1, counter is running) */
	SceKernelSysClock	baseTime;			/**< Timer reference process time */
	SceKernelSysClock	currentTime;			/**< Timer current time */
	SceKernelSysClock	schedule;			/**< Timer next scheduled event notification time (if an event is set) */
	SceKernelSysClock	interval;			/**< Timer event notification interval specified by sceKernelSetTimerEvent() */
	SceInt32		type;				/**< Timer event notification type specified by sceKernelSetTimerEvent() */
	SceInt32		fRepeat;			/**< Timer repeat flag specified by sceKernelSetTimerEvent() (1: periodic timer) */
	SceUInt32		numWaitThreads;			/**< Number of threads waiting for timer */
	SceInt32		reserved[1];			/**< Reserved area */
} SceKernelTimerInfo;

/*@}*//* Timer */

/** @name	Simple event
 */
/*@{*/

/**
 * @brief Simple event additional data
 *
 * This structure is used to store additional data given when a simple event is generated with sceKernelCreateSimpleEvent().
 *
 * Provided for future expansion.
 *
 */
typedef struct _SceKernelSimpleEventOptParam {
	SceSize	size;				/**< Size of this structure (sizeof(SceKernelSimpleEventOptParam)) */
} SceKernelSimpleEventOptParam;

/*@}*//* Simple event */

/** @name	Message pipe
 */
/*@{*/

/**
 * @defgroup	Message pipe attributes
 * Defining message pipe attributes
 */
/*@{*/
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_PRIO_S	(0x00000001U)	/**< The queue of the message sender's waiting thread is FIFO */
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_PRIO_R	(0x00000002U)	/**< The queue of the message receiver standby thread is FIFO */
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_PRIO	(SCE_KERNEL_MSG_PIPE_ATTR_TH_PRIO_S | SCE_KERNEL_MSG_PIPE_ATTR_TH_PRIO_R)	/**< Message queuing wait thread queuing is FIFO */

#define SCE_KERNEL_MSG_PIPE_ATTR_TH_FIFO_S	(0x00000004U)	/**< Queues for waiting threads on the message sender side are in order of thread priority */
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_FIFO_R	(0x00000008U)	/**< Queues for message receiver standby threads are ordered by thread priority */
#define SCE_KERNEL_MSG_PIPE_ATTR_TH_FIFO	(SCE_KERNEL_MSG_PIPE_ATTR_TH_FIFO_S | SCE_KERNEL_MSG_PIPE_ATTR_TH_FIFO_R)	/**< Queues for message send / receive waiting threads are ordered by thread priority */
/*@}*/

/**
 * @defgroup	Message pipe wait mode
 * Message pipe wait mode
 */
/*@{*/
#define SCE_KERNEL_MSG_PIPE_MODE_ASAP			(0x00000000U)	/**< Complete if you can send and receive even 1 byte of data */
#define SCE_KERNEL_MSG_PIPE_MODE_FULL			(0x00000001U)	/**< Complete when all data of the specified size has been sent and received */

#define SCE_KERNEL_MSG_PIPE_MODE_WAIT			(0x00000000U)	/**< Block threads until send / receive processing is complete (synchronous mode) */
#define SCE_KERNEL_MSG_PIPE_MODE_DONT_WAIT		(0x00000010U)	/**< Issue a send / receive request and return immediately (asynchronous mode) */

#define SCE_KERNEL_MSG_PIPE_MODE_DONT_REMOVE		(0x00000100U)	/**< Do not delete received data from the pipe (peak processing) */
/*@}*/

/**
 * @defgroup	Message pipe type
 * Defining the pipe buffer type for a message pipe
 * Specify which budget to get memory from
 */
/*@{*/
#define SCE_KERNEL_MSG_PIPE_TYPE_USER_MAIN		(64)		/**< User main area */
#define SCE_KERNEL_MSG_PIPE_TYPE_USER_CDRAM		(66)		/**< User CDRAM area (not mounted) */
/*@}*/

/**
 * @defgroup	Message pipe optional attributes
 * Macros that can be specified in the attr member of SceKernelMsgPipeOptParam
 */
/*@{*/
#define SCE_KERNEL_MSG_PIPE_OPT_ATTR_OPEN_LIMITATION	(0x00000100U)	/**< Specify openLimit */
/*@}*/

/**
 * Buffer information for message pipe discontinuous data transmission / reception
 *
 * sceKernelSendMsgPipeVector(), sceKernelSendMsgPipeVectorCB(), sceKernelTrySendMsgPipeVector(),
 * sceKernelReceiveMsgPipeVector(), sceKernelReceiveMsgPipeVectorCB(), sceKernelTryReceiveMsgPipeVector()
 * are used to transmit and receive data.
 * This structure specifies a single contiguous memory range.
 *
 * Specify the base address in pBase.
 * Specify the size (byte) in bufSize.
 *
 */
typedef struct _SceKernelMsgPipeVector {
	void		*pBase;		/**< Buffer base address */
	SceSize		bufSize;	/**< Buffer size */
} SceKernelMsgPipeVector;

/**
 * @brief Message pipe status
 *
 * This structure is used to get the message pipe status with sceKernelGetMsgPipeInfo().
 *
 */
typedef struct	_SceKernelMsgPipeInfo {
	SceSize			size;				/**< Size of this structure (sizeof(SceKernelMsgPipeInfo)) */
	SceUID			msgPipeId;			/**< Message pipe identifier */
	char			name[SCE_UID_NAMELEN + 1];	/**< Name of the message pipe specified with sceKernelCreateMsgPipe() */
	SceUInt32		attr;				/**< Message pipe attribute specified by sceKernelCreateMsgPipe() */
	SceSize			bufferSize;			/**< Total size of message pipe pipe buffer (bytes) */
	SceSize			freeSize;			/**< Empty pipe buffer size of message pipe (byte) */
	SceUInt32		numSendWaitThreads;		/**< Number of threads waiting to be sent */
	SceUInt32		numReceiveWaitThreads;		/**< Number of threads waiting to receive */
} SceKernelMsgPipeInfo;

/**
 * @brief Additional data for the message pipe
 *
 * This structure is used to store additional data given when creating a message pipe with sceKernelCreateMsgPipe().
 *
 * Specify a bit pattern that represents a valid member in attr.
 * The following macros can be specified by logical OR.
 * - SCE_KERNEL_MSG_PIPE_OPT_ATTR_OPEN_LIMITATION: Specify the maximum number that can be referenced simultaneously with sceKernelOpenMsgPipe() (openLimit)
 *
 * In openLimit, the maximum number of simultaneous references by sceKernelOpenMsgPipe() can be specified.
 * The maximum number that can be specified is (0..SCE_KERNEL_OPEN_LIMIT_MAX (127)).
 * If not specified, the number of simultaneous references is not limited.
 *
 * Be sure to call sizeof(SceKernelMsgPipeOptParam) for size.
 *
 */
typedef struct _SceKernelMsgPipeOptParam {
	SceSize			size;		/**< Size of this structure (sizeof(SceKernelMsgPipeOptParam)) */
	SceUInt32		attr;		/**< A bit pattern that specifies a valid member of a structure */
	SceInt32		reserved[2];	/**< Reserved area */
	SceUInt32		openLimit;	/**< Maximum number that can be referenced simultaneously with sceKernelOpenMsgPipe() (0..SCE_KERNEL_OPEN_LIMIT_MAX (127)) can be specified. If not specified, unlimited */
} SceKernelMsgPipeOptParam;

/*@}*//* Message pipe */

/** @name	Reader / writer lock
 */
/*@{*/

/**
 * @defgroup	Reader / writer lock attribute
 * Definition of attributes to be specified when creating a reader / writer lock
 */
/*@{*/
#define SCE_KERNEL_RW_LOCK_ATTR_TH_FIFO		SCE_KERNEL_ATTR_TH_FIFO	/**< Reader / writer lock waiting thread queuing is FIFO */
#define SCE_KERNEL_RW_LOCK_ATTR_TH_PRIO		SCE_KERNEL_ATTR_TH_PRIO	/**< Queued reader / writer lock waiting threads are ordered by thread priority */
#define	SCE_KERNEL_RW_LOCK_ATTR_RECURSIVE	(0x00000002U)		/**< Reader / writer lock can be recursively locked */
#define SCE_KERNEL_RW_LOCK_ATTR_CEILING		(0x00000004U)		/**< Use the priority sealing function when the reader / writer lock is locked (not implemented) */
/*@}*/

/**
 * @defgroup	Reader / writer lock cancel flag
 * Definition of flag to be specified when canceling reader / writer lock
 */
/*@{*/
#define	SCE_KERNEL_RW_LOCK_CANCEL_WITH_WRITE_LOCK	(1)	/**< Acquire light lock atomically after cancellation */
/*@}*/

/**
 * @brief  Additional data for reader / writer lock
 *
 * This structure is used to store additional data given when creating a reader / writer lock with sceKernelCreateRWLock().
 *
 * Provided for future expansion.
 *
 */
typedef struct _SceKernelRWLockOptParam {
	SceSize	size;				/**< Size of this structure (sizeof(SceKernelRWLockOptParam)) */
} SceKernelRWLockOptParam;

/**
 * @brief  Reader / writer lock status
 *
 * This structure is used to acquire the reader / writer lock status with sceKernelGetRWLockInfo().
 *
 */
typedef struct _SceKernelRWLockInfo {
	SceSize		size;					/**< Size of this structure (sizeof(SceKernelRWLockInfo)) */
	SceUID		rwLockId;				/**< Reader / writer lock identifier */
	char		name[SCE_UID_NAMELEN + 1];		/**< Name of reader / writer lock specified by sceKernelCreateRWLock() */
	SceUInt32	attr;					/**< Reader / writer lock attribute specified by sceKernelCreateRWLock() */
	SceInt32	lockCount;				/**< Current number of locks of reader / writer lock */
	SceUID		writeOwnerId;				/**< Identifier of the thread that currently holds (owns) the reader / writer lock */
	SceUInt32	numReadWaitThreads;			/**< Number of threads waiting for reader / writer lock with read lock */
	SceUInt32	numWriteWaitThreads;			/**< Number of threads waiting for reader / writer lock with write lock */
} SceKernelRWLockInfo;

/*@}*//* Reader / writer lock */

typedef struct SceKernelWorkqueueCreateInfo { // size is 0x40-bytes
	SceSize size;
	SceUID wqueue_id;
	char name[0x20];
	SceInt32 unk_0x28;
	SceInt32 unk_0x2C;
	SceInt32 unk_0x30;
	SceInt32 unk_0x34;
	SceInt32 unk_0x38;
	SceInt32 unk_0x3C;
} SceKernelWorkqueueCreateInfo;

typedef struct SceKernelWorktaskCreateInfo { // size is 0x34-bytes
	SceSize size;
	SceUID wtask_id;
	char name[0x20];
	const void *func;
	void *argp;
	SceUID wqueue_id;
} SceKernelWorktaskCreateInfo;

typedef struct SceThreadmgrForDriver_E605ED7A_t { // size is 0x58-bytes
	SceSize size;
	SceUID wtaskId;
	SceUID processId;
	SceInt32 unk_0x0C;
	char name[0x20];
	const void *func;
	void *argp;
	SceUID wqueue_id;
	SceUID unk_0x3C;
	SceUID unk_0x40;
	void *unk_0x44;
	SceInt32 unk_0x48;
	SceInt32 unk_0x4C;
	SceUID processId2;
	SceInt32 unk_0x54;
} SceThreadmgrForDriver_E605ED7A_t;


#define SCE_KERNEL_WORKQUEUE_HAS_THREAD_NUMBER     (1 << 0)
#define SCE_KERNEL_WORKQUEUE_HAS_PRIORITY          (1 << 1)
#define SCE_KERNEL_WORKQUEUE_HAS_STACK_SIZE        (1 << 2)
#define SCE_KERNEL_WORKQUEUE_HAS_CPU_AFFINITY_MASK (1 << 3)

typedef struct SceKernelCreateWorkQueueParam {
	SceSize;
	SceUInt32 nThread;
	SceUInt32 initPriority;
	SceSize stackSize;
	SceUInt32 cpuAffinityMask;
} SceKernelCreateWorkQueueParam;

Possible function names according to SceTestBridge

sceTestBridgeThreadMgrCallCoredumpHandler -> ??
sceTestBridgeThreadMgrClearThreadMgrTestMode -> sceKernelClearThreadMgrTestModeForKernel
sceTestBridgeThreadMgrDeleteStopThreadEvf -> ??
sceTestBridgeThreadMgrExitDeleteThreadInSyscall -> sceKernelExitDeleteThread
sceTestBridgeThreadMgrFastMutexLockUnlock -> ??
sceTestBridgeThreadMgrFastMutexShowStat -> ??
sceTestBridgeThreadMgrFastMutexStart -> ??
sceTestBridgeThreadMgrFastMutexStop -> ??
sceTestBridgeThreadMgrGetLwMutexInfoAll -> looks like _sceKernelGetLwMutexInfoById
sceTestBridgeThreadMgrIsCoredumpHandlerRegistered
sceTestBridgeThreadMgrRegisterCoredumpHandler -> sceCoredumpRegisterCoredumpHandler
sceTestBridgeThreadMgrResumeThread -> sceKernelResumeThreadForVM
sceTestBridgeThreadMgrRunningInSyscall -> ??
sceTestBridgeThreadMgrSetAndDeleteSuspendThreadEvf -> ??
sceTestBridgeThreadMgrSetThreadMgrTestMode -> sceKernelSetThreadMgrTestModeForKernel
sceTestBridgeThreadMgrSpawnPriorityThread -> ??
sceTestBridgeThreadMgrStopThread -> sceKernelStopThreadForKernel
sceTestBridgeThreadMgrSuspendThread -> sceKernelSuspendThreadForVM
sceTestBridgeThreadMgrUnregisterCoredumpHandler -> sceCoredumpUnregisterCoredumpHandler
sceTestBridgeThreadMgrWaitInSyscall -> ??
sceTestBridgeThreadMgrWaitInSyscall2 -> ??
sceTestbridgeApi -> ??

Thread Priority

Basic Priority Table

General Priority Internal Priority Description
0 - Current running thread priority
< 0x100000E0 - Error with 0x80028023
>= 0x10000120 - Error with 0x80028023
0x10000100 0xA0 For GAME Process without some thread attr
0x10000100 0x60 For GAME Process
0x10000100 0x60 For MiniApp Process
0x10000100 0x60 For Shell Process
0x10000100 0x60 For Kernel Process

Internal Priority Table

Allowed Internal Priority Description
0x40 - 0xBF For User GAME Process
0x40 - 0xFB For User non-GAME Process (Kernel, shell, miniapp)
1 - 0xFB For non-User Process

Threadmgr SGI events

Event Description
0x0 changeThreadCpuAffinityMask
0x1 changeThreadPriority
0x2 changeThreadPriorityAndCpuAffinityMask
0x3 atomic core orr
0x4-0x7 N/A
0x8 debugSuspendThread
0x9 stopThread
0xA suspendThreadForVM
0xB setCpuRegisterForDebugger
0xC getCpuRegisterForDebugger
0xD setVfpRegisterForDebugger
0xE getVfpRegisterForDebugger
0xF N/A
0x10 pmonThreadChangeEnableCounter
0x11 pmonThreadSetCounter
0x12 pmonThreadGetCounter
0x13 some msgpipe function?
0x14 some msgpipe function?
0x15-0x17 N/A
0x18 DTrace XCall Async
0x18 DTrace XCall Sync

SceThreadmgrForDriver

sceKernelSetEventWithNotifyCallbackForDriver

Version NID
0.995 not present. Present in ForKernel. SceKernelThreadMgr#sceKernelSetEventWithNotifyCallbackForKernel
3.60 0xB7DF3EDF

sceKernelRegisterKTLSForDriver

Version NID
0.990.000-3.740.011 0xB645C7EF

Temp name was sceKernelAllocateKTLSForDriver. sceKernelAllocateKTLS symbol is present in old SCE modules but sceKernelRegisterKTLS is more suitable and used more often.

typedef void SceKernelKTLSFreeCallback(void* ktls_data, void* pUserdata);

/**
 * @brief Registers a kernel TLS slot.
 *
 * There are 8 KTLS slots available. However, slot 0 and 1 cannot be accessed via the KTLS API.
 * Thus, only 6 slots can be registered and used by external callers.
 *
 * @param[in]       size            Size of the KTLS data to allocate
 * @param[in,opt]   freeCb          Callback invoked when the KTLS data of a thread is freed (during thread termination)
 * @param[in,opt]   pUserdata       User-provided data passed to freeCb
 * @retval	(>=0)		KTLS index of the registered slot
 * @retval      (<0)		Error code
 * @note If no free KTLS slots are available, SCE_KERNEL_ERROR_KERNEL_TLS_FULL (0x80028081) is returned.
 */
SceInt32 sceKernelRegisterKTLSForDriver(SceSize size, SceKernelKTLSFreeCallback* freeCb, void* pUserdata);

sceKernelUnregisterKTLSForDriver

Version NID
0.990.000-3.740.011 0x8C3C1F78
/**
 * @brief Unregisters a Kernel TLS slot.
 *
 * @param[in]   index           KTLS index returned by sceKernelRegisterKTLS()
 * @retval	SCE_OK		Success
 * @retval      (<0)		Error code
 * @note A KTLS index can only be unregistered if no thread has KTLS data allocated for this index.
 *       Otherwise, error SCE_KERNEL_ERROR_KERNEL_TLS_BUSY (0x80028083) is returned.
 */
SceInt32 sceKernelUnregisterKTLSForDriver(SceInt32 index);

SceThreadmgrForDriver_89CA5698

Version NID
0.990.000-3.740.011 0x89CA5698
/**
 * @brief Returns the pointer to KTLS data from a slot.
 *
 * @param[in]   index           KTLS index returned by sceKernelRegisterKTLS()
 * @param[in]   thid            ID of the thread whose KTLS data should be retrieved, or 0 for the current thread
 * @param[in]   allocate        Controls behavior if the KTLS data for the slot has not been allocated yet for this thread:
 *                                 SCE_TRUE => allocate and return the new allocation
 *                                 SCE_FALSE => don't allocate; return NULL
 * @retval	non-NULL        Pointer to the KTLS data
 * @retval      NULL            Error / KTLS data is not allocated (if allocate == SCE_FALSE)
 */
ScePVoid SceThreadmgrForDriver_89CA5698(SceInt32 index, SceUID thid, SceBool allocate);

SceThreadmgrForDriver_3A72C6D8

Version NID
0.990.000-3.740.011 0x3A72C6D8

Wrapper for SceKernelThreadMgr#SceThreadmgrForDriver_89CA5698.

ScePVoid SceThreadmgrForDriver_3A72C6D8(SceInt32 index) {
    return SceThreadmgrForDriver_89CA5698(index, 0, SCE_TRUE);
}

sceKernelPMonSetControlRegisterForDriver

Version NID
0.990.000-2.060.011 not present. Present in #SceThreadmgrForKernel.
2.100.081-3.740.011 0x1AAFA818

sceKernelPMonSetUserEnableRegisterForDriver

Version NID
0.990.000-2.060.011 not present. Present in #SceThreadmgrForKernel.
2.100.081-3.740.011 0x5053B005

sceKernelWaitThreadEndCBForDriver

Version NID
3.60 0x9EF4F62C

sceKernelWaitThreadEndForDriver

Version NID
3.60 0x3E20216F

sceKernelWaitEventFlagCBForDriver

Version NID
3.60 0x8A35F714

sceKernelWaitEventFlagForDriver

Version NID
0.931-3.60 0x0C1D3F20
/**
 * @brief Event flag wait
 *
 * This system call waits for the event flag specified by evfId to be set according to the wait release condition specified by waitMode.
 * If the event flag specified by evfId already satisfies the wait release condition specified by waitMode,
 * the issuing thread continues execution without transitioning to the waiting state (WAITING).
 *
 * When SCE_KERNEL_EVF_WAITMODE_AND is specified for waitMode, it waits until all the bits specified by bitPattern become 1.
 * If SCE_KERNEL_EVF_WAITMODE_OR is specified for waitMode, wait until one of the bits specified in bitPattern becomes 1.
 * If SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL is additionally specified for waitMode, all the eventflag bits
 * are cleared to 0 when the wait release condition is satisfied and this thread is released.
 * If SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT is additionally specified for waitMode, the bit specified
 * by bitPattern is cleared to 0 when the wait release condition is satisfied and this thread is released.
 *
 * The event flag value is returned to pResultPat in the following cases. NULL can be specified if no value is required.
 * - If the wait release condition is satisfied (SCE_OK is returned),
 *   the event flag value before clearing by specifying SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL,
 *   SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT is returned immediately after the condition is satisfied.
 * - After exiting the wait state, the event flag value just before exiting from the wait state is returned when
 *   exiting except when the wait release condition is satisfied (when SCE_KERNEL_ERROR_WAIT_CANCEL,
 *   SCE_KERNEL_ERROR_WAIT_DELETE, SCE_KERNEL_ERROR_WAIT_TIMEOUT errors are returned).
 *   When canceling with sceKernelCancelEventFlag(), the eventflag value set at the time of cancellation is returned.
 *
 * When pTimeout is specified, the timeout operation specified in microseconds is set.
 * If pTimeout is NULL, timeout operation is not performed.
 * Note that if pTimeout is specified, the value pointed to by pTimeout is updated when the system call ends.
 * If the condition is met within the time, it is updated with the remaining time. If not established,
 * the value pointed to by pTimeout is updated with 0. In this case, error SCE_KERNEL_ERROR_WAIT_TIMEOUT is returned.
 *
 * Another thread cannot execute sceKernelWaitEventFlag() and sceKernelPollEventFlag() for an event flag with
 * the SCE_KERNEL_EVF_ATTR_SINGLE attribute that already has a waiting thread.
 * In this case, an error is returned immediately to the thread that executed sceKernelWaitEventFlag() or sceKernelPollEventFlag() later.
 *
 * If multiple threads are waiting for an event flag with the SCE_KERNEL_EVF_ATTR_MULTI attribute, a thread queue is created.
 * In this case, a single sceKernelSetEventFlag() may release the waiting status of multiple threads.
 *
 * In the case of the event flag of the SCE_KERNEL_EVF_ATTR_TH_FIFO attribute, the thread queue is
 * arranged in the order in which it waits first.
 * In the event flag of the SCE_KERNEL_EVF_ATTR_TH_PRIO attribute, the thread with the highest
 * priority among the waiting threads starts first and is arranged in the order of thread priority.
 *
 * If there is a thread with SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL specified or SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT specified in the
 * queue and the wait release condition for that thread is satisfied, the event flag is cleared at the same time as the wait release.
 * Threads that are lined up behind the thread that has specified SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL or SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT
 * will see the event flag after being cleared, so the wait may not be released.
 *
 * @param	evfId		Specifies the identifier of the event flag to wait for.
 * @param	bitPattern	Specify the comparison value with the eventflag.
 * @param	waitMode	Specifies the wait mode. Specify one of the following:
 *                      - SCE_KERNEL_EVF_WAITMODE_AND: Waiting for AND
 *                      - SCE_KERNEL_EVF_WAITMODE_OR : Wait for OR
 *                      In addition, you can optionally add either of the following specifications as a logical sum.
 *                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL: After waiting, clear all bits
 *                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT: After waiting, clear the bit specified in bitPattern
 * @param	pResultPat	Specifies a pointer to the SceUInt32 type variable that receives the eventflag value when waiting is established.
 *                      If NULL is specified, the event flag value is not received.
 * @param	pTimeout	Specify a pointer to the SceUInt32 type variable that stores the upper limit (microseconds) of the waiting time.
 *                      If NULL is specified, wait indefinitely. When the wait condition is satisfied, the remaining time is returned.
 * @retval	SCE_OK		Success
 * @retval	(<0)		Error code
 */
SceInt32 sceKernelWaitEventFlagForDriver(SceUID evfId, SceUInt32 bitPattern, SceUInt32 waitMode, SceUInt32 *pResultPat, SceUInt32 *pTimeout);

sceKernelWaitEventCBForDriver

Version NID
3.60 0x360C655C

sceKernelWaitEventForDriver

Version NID
3.60 0xC529EA32
int sceKernelWaitEventForDriver(SceUID eventId, SceUInt32 waitPattern, SceUInt32 *pResultPattern, SceUInt64 *pUserData, SceUInt32 *pTimeout);

sceKernelUnregisterThreadEventHandlerForDriver

Version NID
3.60 0x2C8ED6F0

sceKernelUnregisterCallbackFromEventAllForDriver

Version NID
3.60 0x8DADBD16

sceKernelUnregisterCallbackFromEventForDriver

Version NID
3.60 0x2E48D81C

sceKernelUnlockWriteRWLockForDriver

Version NID
3.60 0x94A73797

sceKernelUnlockReadRWLockForDriver

Version NID
3.60 0xDE1B9EEE

sceKernelTryLockWriteRWLockForDriver

Version NID
3.60 0xA96F2E5A

sceKernelTryLockReadRWLockForDriver

Version NID
3.60 0xFC2B5A50

sceKernelStopTimerForDriver

Version NID
3.60 0x474F214B
int sceKernelStopTimerForDriver(SceUID timerId);

sceKernelStartTimerForDriver

Version NID
3.60 0x84C4CE4D
int sceKernelStartTimerForDriver(SceUID timerId);

sceKernelSignalSemaForDriver

Version NID
3.60 0xD270498B

sceKernelSignalCondAllForDriver

Version NID
3.60 0x6EC78CD0

sceKernelSetTimerTimeWideForDriver

Version NID
3.60 0x85195A16

sceKernelSetEventFlagForDriver

Version NID
0.931 in ForKernel
3.60 0xD4780C3E

sceKernelSetEventForDriver

Version NID
3.60 0x9EA3A45C

_sceKernelExtendKernelStackWideForDriver

Version NID
3.60 0xE54FD746

Temp name was sceKernelRunWithStackForDriver.

This takes a function and runs it exclusively on the current core on its own stack.

// stack_size should be 0x2000
int _sceKernelExtendKernelStackWideForDriver(int stack_size, void *func, void *args);

sceKernelExtendKernelStackWideForDriver

Version NID
3.60 0xA2C801A5

Temp name was sceKernelRunWithStack2ForDriver.

// stack_size should be 0x2000
SceInt64 sceKernelExtendKernelStackWideForDriver(int stack_size, void *func, void *args);

sceKernelRegisterCallbackToEventForDriver

Version NID
3.60 0x832A7E0C

sceKernelPulseEventWithNotifyCallbackForDriver

Version NID
3.60 0x714A107A

sceKernelPulseEventForDriver

Version NID
3.60 0x2427C81B

sceKernelPollSemaForDriver

Version NID
3.60 0x4FDDFE24

sceKernelPollEventFlagForDriver

Version NID
0.990-3.60 0x76C6555B
/**
 * @brief Event flag polling
 *
 * Polls the event flag specified by evfId.
 *
 * sceKernelPollEventFlag() is a system call that removes the function to enter standby state from sceKernelWaitEventFlag().
 * Unlike sceKernelWaitEventFlag(), an error (SCE_KERNEL_ERROR_EVF_COND) is returned immediately if the wait release condition is not satisfied.
 * In this case, SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL / SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT specification is ignored.
 *
 * @param	evfId		Specify the event flag identifier to be polled.
 * @param	bitPattern	Specify the comparison value with the eventflag.
 * @param	waitMode	Specify the wait mode. Specify one of the following:
 *                      - SCE_KERNEL_EVF_WAITMODE_AND: Waiting for AND
 *                      - SCE_KERNEL_EVF_WAITMODE_OR : Wait for OR
 *                      In addition, you can optionally add one of the following specifications as a logical sum.
 *                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL: Clear all bits after waiting
 *                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT: After waiting, clear the bit specified in bitPattern
 * @param	pResultPat	Specify a pointer to the SceUInt32 type variable that receives the eventflag value when waiting is established.
 * @retval	SCE_OK		Success
 * @retval	(<0)		Error code
 */
SceInt32 sceKernelPollEventFlagForDriver(SceUID evfId, SceUInt32 bitPattern, SceUInt32 waitMode, SceUInt32 *pResultPat);

sceKernelNotifyCallbackForDriver

Version NID
3.60 0xC3E00919

sceKernelGetTimerTimeWideForDriver

Version NID
3.60 0xC1286004
SceUInt64 sceKernelGetTimerTimeWideForDriver(SceUID timerId);

sceKernelGetTimerBaseWideForDriver

Version NID
3.60 0xA6D11DD3
SceUInt64 sceKernelGetTimerBaseWideForDriver(SceUID timerId);

sceKernelGetThreadmgrUIDClassForDriver

Version NID
3.60 0x0A20775A

sceKernelGetThreadTLSAddrForDriver

Version NID
3.60 0x66EEA46A

sceKernelGetThreadStackFreeSizeForDriver

Version NID
3.60 0x7B278A0B

sceKernelGetThreadCpuAffinityMaskForDriver

Version NID
3.60 0x83DC703D

sceKernelGetCallbackCountForDriver

Version NID
3.60 0x0892D8DF

sceKernelCreateWorkQueueForDriver

Version NID
3.60 0x771522C6
SceUID sceKernelCreateWorkQueueForDriver(const char *name, SceUInt32 flags, const SceKernelCreateWorkQueueParam *opt);

sceKernelScheduleWorkTaskForDriver

Version NID
3.60 0xE50E1185
SceUID sceKernelScheduleWorkTaskForDriver(SceUID wqueue_id, const char *name, const void *wtask_func, void *argp);

sceKernelGetWorkqueueCreateInfoForDriver

Version NID
3.60 0xB92709C4

This is a guessed name.

int sceKernelGetWorkqueueCreateInfo(SceUID wqueue_id, SceKernelWorkqueueCreateInfo *info);

sceKernelGetWorktaskCreateInfoForDriver

Version NID
3.60 0x0B604A3C

This is a guessed name.

int sceKernelGetWorktaskCreateInfo(SceUID wtask_id, SceKernelWorktaskCreateInfo *info);

sceKernelGetWorkqueueInfoVectorForDriver

Version NID
3.60 0x920EA1CA

This is a guessed name.

int sceKernelGetWorkqueueInfoVector(int vis_level, void *dst, SceSize dst_size, SceUInt32 *nInfo);

sceKernelGetProcWorkqueueInfoVectorForDriver

Version NID
3.60 0x8C8A76EF

This is a guessed name.

int sceKernelGetProcWorkqueueInfoVector(SceUID pid, int vis_level, void *dst, SceSize dst_size, SceUInt32 *nInfo);

sceKernelGetWorktaskInfoVectorForDriver

Version NID
3.60 0xE605ED7A

This is a guessed name.

int sceKernelGetWorktaskInfoVector(int vis_level, SceThreadmgrForDriver_E605ED7A_t *dst, SceSize dst_size, SceUInt32 *nInfo);

sceKernelGetProcWorktaskInfoVectorForDriver

Version NID
3.60 0xB4CED111

This is a guessed name.

int sceKernelGetProcWorktaskInfoVector(SceUID pid, int vis_level, SceThreadmgrForDriver_E605ED7A_t *dst, SceSize dst_size, SceUInt32 *nInfo);

sceKernelWaitWorktaskForDriver

Version NID
3.60 0x12FC0FAB

This is a guessed name.

int sceKernelWaitWorktask(SceUID wtask_id, SceInt32 *timeout);

sceKernelWaitWorktask2ForDriver

Version NID
3.60 0xB247EC4B

This is a guessed name.

with user stack overflow detect?

int sceKernelWaitWorktask2(SceUID wtask_id, SceInt32 *timeout);

sceKernelDeleteThreadForDriver

Version NID
1.69-3.60 0xAC834F3F
/**
 * @brief Delete thread
 *
 * Deletes the thread specified by threadId.
 *
 * Accordingly, the stack area and thread management area are released. The target thread must be in the DORMANT state.
 *
 * Since the own thread cannot be in the DORMANT state, it cannot be set as the target thread
 * (this results in an SCE_KERNEL_ERROR_NOT_DORMANT error).
 * Use sceKernelExitDeleteThread() to delete your own thread.
 *
 * @param	threadId	Specify the identifier of the thread to be deleted.
 * @retval	SCE_OK		Success
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelDeleteThreadForDriver(
	SceUID	threadId
);

sceKernelDeleteSemaForDriver

Version NID
3.60 0x16A35E58

sceKernelDeleteMutexForDriver

Version NID
3.60 0x0A912340
int sceKernelDeleteMutexForDriver(SceUID mutexid);

sceKernelCloseEventFlagForDriver

Version NID
0.931-3.60 0x71ECB352

Temp name was sceKernelDeleteEventFlagForDriver.

sceKernelCreateThreadForDriver

Version NID
1.69-3.60 0xC6674E7D
/**
 * @brief Thread generation that operates in the address space of its own process
 *
 * A thread that operates in the address space of its own process is created.
 *
 * Allocate a thread management area for the thread to be created, perform initialization, and secure a stack area.
 * The thread information to be created is specified as an argument, and the thread identifier (UID) is returned as the return value.
 *
 * The generated thread is in the DORMANT state.
 *
 * @param	pName		Specifies the name of the thread.
 *				The name of the thread does not have to be unique because it is
 *				used by the operator to identify it when debugging. The maximum name length is 31 bytes.
 * @param	entry		Specify the entry address of the thread. The thread entry point function
 * 				can receive memory block data with two arguments.
 *				The argument is given by sceKernelStartThread() described later.
 *				The thread is terminated by returning from this function, and the return value of the function is the thread termination status.
 * @param	initPriority	Specifies the initial priority of the thread. The smaller the number, the higher the priority.
 *				The range from SCE_KERNEL_HIGHEST_PRIORITY_USER (= 64) to SCE_KERNEL_LOWEST_PRIORITY_USER (= 191) can be used.
 *				By specifying SCE_KERNEL_DEFAULT_PRIORITY_USER, you can specify the default priority of the process to which the thread belongs.
 *				For the default priority, it is also possible to specify with SCE_KERNEL_DEFAULT_PRIORITY_USER ± offset.
 * @param	stackSize	Specify the required stack size of the thread in bytes. The argument block given by
 *				sceKernelStartThread () is copied onto the stack, so specify the stack size with this margin in mind.
 *				An error will occur if a stack size less than 4 KiB is specified.
 * @param	attr		You can specify multiple thread attributes by logical OR.
 * @param	cpuAffinityMask	Specifies the initial CPU affinity mask for the thread.
 *				A thread can run only on the thread specified in the CPU affinity mask.
 *				The CPU affinity mask can be specified by the logical sum of the following macros.
 *				- SCE_KERNEL_CPU_MASK_USER_0
 *				- SCE_KERNEL_CPU_MASK_USER_1
 *				- SCE_KERNEL_CPU_MASK_USER_2
 *				The following macros are also available to represent all available CPUs.
 *				- SCE_KERNEL_CPU_MASK_USER_ALL
 * @param	pOptParam	Argument for future expansion. Please specify NULL. Max size is 0x14.
 * @retval	Positive value	Thread identifier (UID)
 * @retval	Negative value	Error code
 */
SceUID	sceKernelCreateThreadForDriver(
	const char	*pName,
	SceKernelThreadEntry		entry,
	SceInt32	initPriority,
	SceSize		stackSize,
	SceUInt32	attr,
	SceInt32	cpuAffinityMask,
	const SceKernelThreadOptParam	*pOptParam
);

sceKernelCreateSimpleEventForDriver

Version NID
3.60 0x357A8177

sceKernelCreateMutexForDriver

Version NID
3.60 0xFBAA026E
SceUID sceKernelCreateMutexForDriver(const char *pName, SceUInt attr, int initCount, const SceKernelMutexOptParam *pOptParam);

sceKernelCreateEventFlagForDriver

Version NID
0.990-3.60 0x4336BAA4
/**
 * @brief Event flag generation
 *
 * Generate an event flag and set the initial value of the event flag. Returns the identifier of the generated event flag as a return value.
 *
 * @param	pName		Specifies the name of the eventflag.
 *                      The name of the eventflag does not need to be unique because it is used only for the purpose of operator
 *                      identification when debugging without interprocess communication.
 *                      However, if the SCE_KERNEL_ATTR_OPENABLE attribute is specified for attr,
 *                      a unique name must be specified in the system.
 *                      The maximum name length is 31 bytes.
 * @param	attr		Specifies the event flag attribute.
 *                      Specify the queue order from one of the following.
 *                      - SCE_KERNEL_EVF_ATTR_TH_FIFO: Waiting thread queuing is FIFO
 *                      - SCE_KERNEL_EVF_ATTR_TH_PRIO: Waiting thread queuing is based on the priority of threads.
 *                      Specify whether to wait for multiple threads from either of the following.
 *                      - SCE_KERNEL_EVF_ATTR_SINGLE: Multiple threads cannot wait simultaneously
 *                      - SCE_KERNEL_EVF_ATTR_MULTI: To generate an event flag that can be referenced by
 *                      sceKernelOpenEventFlag() that allows multiple threads to wait simultaneously, specify the following:
 *                      - SCE_KERNEL_ATTR_OPENABLE
 * @param	initPattern	Specifies the initial value of the eventflag.
 * @param	pOptParam	Argument for future expansion. Please specify NULL.
 * @retval	(>=0)		Event flag identifier (UID)
 * @retval	(<0)		Error code
 */
SceUID sceKernelCreateEventFlagForDriver(const char *pName, SceUInt32 attr, SceUInt32 initPattern, const SceKernelEventFlagOptParam *pOptParam);

sceKernelClearEventFlagForDriver

Version NID
3.60 0x4F1DA3BE

sceKernelClearEventForDriver

Version NID
3.60 0x9C335818
int sceKernelClearEventForDriver(SceUID eventId,SceUInt32 clearPattern);

sceKernelChangeThreadPriority2ForDriver

Version NID
3.60 0x63DAB420

Temp name was sceKernelChangeThreadPriorityForDriver.

sceKernelCancelCallbackForDriver

Version NID
3.60 0xC040EC1C

sceKernelCancelMsgPipeForDriver

Version NID
3.60 0x9D6A2311

sceKernelCreateMsgPipeForDriver

Version NID
3.60 0xBF631145

sceKernelDeleteMsgPipeForDriver

Version NID
3.60 0xB3453F88

sceKernelSendMsgPipeVectorForDriver

Version NID
3.60 0x67DD3BAD

sceKernelTryReceiveMsgPipeVectorForDriver

Version NID
3.60 0xCE09221A

sceKernelTrySendMsgPipeVectorForDriver

Version NID
3.60 0x4CF1BE58

sceKernelIsThreadDebugSuspendedForDriver

Version NID
0.990-3.60 0xA0B1AB21

Used by SceCoredump maybe to get the state at the time of process crash.

/**
 * @param[in]   thid        thread id (kernel uid)
 * @return      suspend state, else < 0 on error.
 */
int sceKernelIsThreadDebugSuspendedForDriver(SceUID thid);

sceKernelDebugResumeThreadForDriver

Version NID
0.990-3.60 0xEC8343DF

sceKernelResumeThreadForDriver

Version NID
0.990-3.60 0xE3CE20AA

sceKernelCreateRemoteThreadForDriver

Version NID
0.990-3.65 0xC8E57BB4

Some value are allowed if Thread name is "ScePsp2SwuCui".

/**
 * @brief Thread generation that does not operate in the address space of its own process
 *
 * A thread that does not operate in the address space of its own process is created.
 *
 * Allocate a thread management area for the thread to be created, perform initialization, and secure a stack area.
 * The thread information to be created is specified as an argument, and the thread identifier (UID) is returned as the return value.
 *
 * The generated thread is in the DORMANT state.
 *
 * @param	pid		Specifies the ID of the process the thread belongs to.
 * @param	pName		Specifies the name of the thread.
 *				The name of the thread does not have to be unique because it is
 *				used by the operator to identify it when debugging. The maximum name length is 31 bytes.
 * @param	entry		Specify the entry address of the thread. The thread entry point function
 * 				can receive memory block data with two arguments.
 *				The argument is given by sceKernelStartThread() described later.
 *				The thread is terminated by returning from this function, and the return value of the function is the thread termination status.
 * @param	initPriority	Specifies the initial priority of the thread. The smaller the number, the higher the priority.
 *				The range from SCE_KERNEL_HIGHEST_PRIORITY_USER (= 64) to SCE_KERNEL_LOWEST_PRIORITY_USER (= 191) can be used.
 *				By specifying SCE_KERNEL_DEFAULT_PRIORITY_USER, you can specify the default priority of the process to which the thread belongs.
 *				For the default priority, it is also possible to specify with SCE_KERNEL_DEFAULT_PRIORITY_USER ± offset.
 * @param	stackSize	Specify the required stack size of the thread in bytes. The argument block given by
 *				sceKernelStartThread () is copied onto the stack, so specify the stack size with this margin in mind.
 *				An error will occur if a stack size less than 4 KiB is specified.
 * @param	attr		You can specify multiple thread attributes by logical OR.
 * @param	cpuAffinityMask	Specifies the initial CPU affinity mask for the thread.
 *				A thread can run only on the thread specified in the CPU affinity mask.
 *				The CPU affinity mask can be specified by the logical sum of the following macros.
 *				- SCE_KERNEL_CPU_MASK_USER_0
 *				- SCE_KERNEL_CPU_MASK_USER_1
 *				- SCE_KERNEL_CPU_MASK_USER_2
 *				The following macros are also available to represent all available CPUs.
 *				- SCE_KERNEL_CPU_MASK_USER_ALL
 * @param	pOptParam	Argument for future expansion. Please specify NULL. Max size is 0x14.
 * @retval	Positive value	Thread identifier (UID)
 * @retval	Negative value	Error code
 */
SceUID	sceKernelCreateRemoteThreadForDriver(
	SceUID		pid,
	const char	*pName,
	SceKernelThreadEntry		entry,
	SceInt32	initPriority,
	SceSize		stackSize,
	SceUInt32	attr,
	SceInt32	cpuAffinityMask,
	const SceKernelThreadOptParam	*pOptParam
);

sceKernelGetThreadIdListForDriver

Version NID
0.990.000-3.740.011 0xEA7B8AEF

This function is used to query and obtain the number of threads within a process.

/**
 * @brief       Retrieve a list of all threads belonging to a process.
 * @param[in]   pid         The process to query.
 * @param[out]  ids         The list of thread IDs. Can be NULL if output is not required.
 * @param[in]   n           The max number of thread IDs to copy out.
 * @param[out]  copy_count  The number of thread IDs copied.
 * @return      The number of threads within the process, else < 0 on error.
 */
int sceKernelGetThreadIdListForDriver(SceUID pid, SceUID *ids, int n, int *copy_count);

sceKernelGetThreadCpuRegistersForDriver

Version NID
3.60 0x5022689D

This function is used to get the state of the registers for a SUSPENDED thread. It returns the registers in a two part structure. It is uncertain what the difference is between the two parts. It seems like it is a usermode/kernel separation. It could also be a current/exception difference. In normal usage on a suspended thread it seems to be the usermode aspect that contains valid values. When you query a suspended thread that has no had the opportunity to start yet, the kernel side is filled.

/** Structure representing all ARM registers */
typedef struct ArmCpuRegisters {
    uint32_t    r0;
    uint32_t    r1;
    uint32_t    r2;
    uint32_t    r3;
    uint32_t    r4;
    uint32_t    r5;
    uint32_t    r6;
    uint32_t    r7;
    uint32_t    r8;
    uint32_t    r9;
    uint32_t    r10;
    uint32_t    r11;
    uint32_t    r12;
    uint32_t    sp;
    uint32_t    lr;
    uint32_t    pc;
    uint32_t    cpsr;
    uint32_t    fpscr;
} ArmCpuRegisters;

/** Structure containing a threads register states. */
typedef struct ThreadCpuRegisters {
    ArmCpuRegisters entry[2];
} ThreadCpuRegisters;

/**
 * @brief       Query the state of the registers for a suspended thread.
 *
 * The registers returned are the usermode/kernel set for the requested thread.
 * It is uncertain if usermode/kernel is correct representation and instead it could be current/exception.
 * The thread provided must be suspended for this function to succeed.
 *
 * @param[in]   thid        The thread to query.
 * @param[out]  registers   The set of registers belonging to the thread.
 * @return      Zero on success, else < 0 on error.
 */
int sceKernelGetThreadCpuRegistersForDriver(SceUID thid, ThreadCpuRegisters *registers);

sceKernelChangeThreadSuspendStatusForDriver

Version NID
3.60 0x04C6764B

This function 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.

/**
 * @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 sceKernelChangeThreadSuspendStatusForDriver(SceUID thid, int status);

sceKernelChangeActiveCpuMaskForDriver

Version NID
1.69-3.60 0x001173F8

sceKernelGetThreadCurrentPriorityForDriver

Version NID
1.69-3.60 0x01414F0B

sceKernelCreateCallbackForDriver

Version NID
1.69-3.60 0x1C41614C

sceKernelWaitThreadEndCB_089ForDriver

Version NID
1.69 0x0373C5E3
3.60 not present

sceKernelDeleteCallbackForDriver

Version NID
1.69-3.60 0x3A7E17F6

sceKernelExitThreadForDriver

Version NID
1.69-3.60 0x0C8A38E1
/**
 * @brief End of own thread
 *
 * Terminates the own thread normally and shifts to the DORMANT state.
 * sceKernelExitThread() is a system call that does not return to the context of the issuer.
 *
 * Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
 * However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
 * The mutex is unlocked and not deleted.
 *
 * When the terminated thread is restarted with sceKernelStartThread(), the information included in the thread
 * management area, such as thread priority, is reset.
 * It will not inherit the one at the end.
 *
 * When a thread exits, exitStatus becomes the exit status of that thread.
 *
 * If the thread is terminated by a return from the entry function without using
 * sceKernelExitThread(), the return value of the entry function becomes the termination status.
 *
 * The end status of a thread can be obtained by sceKernelGetThreadExitStatus() and sceKernelGetThreadInfo(),
 * and when another thread waits for the end of the thread by sceKernelWaitThreadEnd(), it can be obtained by the return value.
 *
 * The thread exit status is saved while the thread exits and is in the DORMANT state,
 * but the value is lost if the thread is restarted or deleted with sceKernelStartThread().
 *
 * @param	exitStatus	Specify the value to be set for the termination status of the local thread.
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelExitThreadForDriver(
	SceInt32	exitStatus
);

sceKernelLockMutex_089ForDriver

Version NID
0.990-3.60 0x16AC80C5
int sceKernelLockMutex_089ForDriver(SceUID mutex_id, int unk1, int unk2);

sceKernelExitDeleteThreadForDriver

Version NID
1.69-3.60 0x1D17DECF
/**
 * @brief End and delete own thread
 *
 * Terminates the own thread normally and deletes it.
 * sceKernelExitDeleteThread() is a system call that does not return to the context of the issuer.
 *
 * Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
 * However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
 * The mutex is unlocked and not deleted.
 *
 * When a thread exits, exitStatus becomes the exit status of that thread (sceKernelExitDeleteThread()
 * directly deletes the thread without going through the DORMANT state.
 * (It cannot be obtained by sceKernelGetThreadInfo(). The end status can be obtained by the return
 * value only when waiting for the end of the thread by sceKernelWaitThreadEnd().)
 *
 * @param	exitStatus	Specify the value to be set for the termination status of the local thread.
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelExitDeleteThreadForDriver(
	SceInt32	exitStatus
);

sceKernelUnlockMutex_089ForDriver

Version NID
0.990-3.60 0x1E82E5D0
int sceKernelUnlockMutex_089ForDriver(SceUID mutex_id, int unk1);

sceKernelStartThread_089ForDriver

Version NID
1.69-3.60 0x21F5419B
/**
 * @brief Thread activation
 *
 * Starts the thread specified by threadId and puts it in READY state.
 *
 * The argument block specified by argSize and argBlock is copied onto the thread stack, argSize is
 * passed directly to the first argument of the thread entry function, and the second argument of
 * the entry function is the argument copied onto the stack. The block address is passed.
 *
 * This system call does not queue activation requests. In other words, if the target thread is not
 * in the DORMANT state, an SCE_KERNEL_ERROR_NOT_DORMANT error is returned to the calling thread.
 *
 * @param	threadId	Specify the identifier of the thread to be started.
 * @param	argSize		Specify the size (byte) of the argument to be passed to the thread.
 * @param	pArgBlock	Specify the address of the argument to be passed to the thread.
 * @retval	SCE_OK		Success
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelStartThread_089ForDriver(
	SceUID		threadId,
	SceSize		argSize,
	const void	*pArgBlock
);

sceKernelTryLockMutex_089ForDriver

Version NID
1.69-3.60 0x270993A6

sceKernelGetSystemTimeLowForDriver

Version NID
1.69-3.60 0x47F6DE49

sceKernelDelayThreadForDriver

Version NID
1.69-3.60 0x4B675D05

sceKernelGetMutexInfo_089ForDriver

Version NID
1.69-3.60 0x69B78A12
int sceKernelGetMutexInfo_089ForDriver(SceUID mutexid, SceKernelMutexInfo *info);

sceKernelCancelMutex_089ForDriver

Version NID
1.69-3.60 0x7204B846

sceKernelChangeCurrentThreadAttrForDriver

Version NID
1.69-3.60 0x751C9B7A

sceKernelDelayThreadCBForDriver

Version NID
1.69-3.60 0x9C0180E1

sceKernelLockMutexCB_089ForDriver

Version NID
1.69-3.60 0xD06F2886

sceKernelCheckWaitableStatusForDriver

Version NID
1.69-3.60 0xD9BD74EB

sceKernelCheckCallbackForDriver

Version NID
1.69-3.60 0xE53E41F6

sceKernelWaitThreadEnd_089ForDriver

Version NID
1.69 0xF3489EF4
3.60 not present

sceKernelGetSystemTimeWideForDriver

Version NID
1.69-3.60 0xF4EE4FA9

sceKernelGetThreadInfoForDriver

Version NID
0.990-3.60 0x283807E2
 int sceKernelGetThreadInfoForDriver(SceUID thid, SceKernelThreadInfo *info)

sceKernelInitializeFastMutexForDriver

Version NID
0.990-3.60 0xAF8E1266
int sceKernelInitializeFastMutexForDriver(void* mutex, const char* name, uint32_t attr, int unk)

sceKernelLockFastMutexForDriver

Version NID
1.69-3.60 0x70627F3A
 int sceKernelLockFastMutexForDriver(void* mutex)

sceKernelUnlockFastMutexForDriver

Version NID
1.69-3.60 0xDB395782
 int sceKernelUnlockFastMutexForDriver(void* mutex)

sceKernelFinalizeFastMutexForDriver

Version NID
0.990-3.60 0x11FE84A1

Temp name was sceKernelDeleteFastMutexForDriver.

 int sceKernelFinalizeFastMutexForDriver(void* mutex)

sceKernelSignalCondToForDriver

Version NID
1.69-3.60 0x61533DA9
 int sceKernelSignalCondToForDriver(SceUID condId, SceUID threadId)

sceKernelCreateCondForDriver

Version NID
1.69-3.60 0xDB6CD34A
 SceUID sceKernelCreateCondForDriver(const char *name, SceUInt attr, SceUID mutexId, const SceKernelCondOptParam *option)

sceKernelWaitCondForDriver

Version NID
1.69-3.60 0xCC7E027D
 int sceKernelWaitCondForDriver(SceUID condId, unsigned int *timeout)

sceKernelReceiveMsgPipeVectorForDriver

Version NID
1.69-3.60 0xDA1F256B

sceKernelReceiveMsgPipeVectorCBForDriver

Version NID
1.69-3.60 0xDA5C9AC6

sceKernelGetThreadIdForDriver

Version NID
1.69-3.60 0x59D06540
 SceUID sceKernelGetThreadIdForDriver(void);

sceKernelDeleteCondForDriver

Version NID
1.69-3.60 0xAEE0D27C
 int sceKernelDeleteCondForDriver(SceUID cid);

sceKernelCreateSemaForDriver

Version NID
1.69-3.60 0x30E93C31
/**
 * Creates a new semaphore
 *
 * @par Example:
 * @code
 * int semaid;
 * semaid = sceKernelCreateSemaForDriver("MySema", 0, 1, 1, 0);
 * @endcode
 *
 * @param name - Specifies the name of the sema
 * @param attr - Sema attribute flags (normally set to 0)
 * @param initVal - Sema initial value
 * @param maxVal - Sema maximum value
 * @param option - Sema options (normally set to 0)
 * @return A semaphore id
 */
SceUID sceKernelCreateSemaForDriver(const char *name, SceUInt attr, int initVal, int maxVal, SceKernelSemaOptParam *option);

sceKernelWaitSemaCBForDriver

Version NID
1.69-3.60 0xF55E4D86
/**
 * Lock a semaphore
 *
 * @par Example:
 * @code
 * sceKernelWaitSemaCBForDriver(sema_id, 1, 0);
 * @endcode
 *
 * @param sema_id - The sema id returned from ::sceKernelCreateSemaForDriver
 * @param signal - The value to wait for (i.e. if 1 then wait till reaches a signal state of 1)
 * @param timeout - Timeout in microseconds (assumed).
 *
 * @return < 0 on error.
 */
int sceKernelWaitSemaCBForDriver(SceUID sema_id, int signal, SceUInt *timeout);

sceKernelWaitSemaForDriver

Version NID
1.69-3.60 0x3C8B55A9
/**
 * Lock a semaphore
 *
 * @par Example:
 * @code
 * sceKernelWaitSemaForDriver(sema_id, 1, 0);
 * @endcode
 *
 * @param sema_id - The sema id returned from ::sceKernelCreateSemaForDriver
 * @param signal - The value to wait for (i.e. if 1 then wait till reaches a signal state of 1)
 * @param timeout - Timeout in microseconds (assumed).
 *
 * @return < 0 on error.
 */
int sceKernelWaitSemaForDriver(SceUID sema_id, int signal, SceUInt *timeout);

sceKernelSignalCondForDriver

Version NID
1.69-3.60 0xAC616150
int sceKernelSignalCondForDriver(SceUID condId);

sceKernelChangeThreadCpuAffinityMaskForDriver

Version NID
1.69-3.60 0x6D0733A8
/**
 * @brief Thread CPU affinity mask setting
 *
 * Change the CPU affinity mask of the thread specified by threadId to cpuAffinityMask.
 * A thread can run only on the CPU specified by the CPU affinity mask.
 *
 * If the CPU affinity mask of a running thread is changed and cannot be executed on the current CPU, the thread is dispatched immediately.
 * As a result of scheduling, if a higher priority thread is running on the newly executable CPU, it is made to wait in the READY state.
 *
 * However, if the dispatch is disabled, the CPU affinity mask is changed immediately,
 * but the rescheduling process is delayed until dispatch is permitted.
 *
 * @param	threadId	Specify the identifier of the thread whose CPU affinity mask is to be changed.
 *				You can specify your own thread with SCE_KERNEL_THREAD_ID_SELF.
 * @param	cpuAffinityMask	Specify the CPU affinity mask after the change.
 *				The CPU affinity mask is expressed by the logical OR of the following macros.
 *				- SCE_KERNEL_CPU_MASK_USER_0
 *				- SCE_KERNEL_CPU_MASK_USER_1
 *				- SCE_KERNEL_CPU_MASK_USER_2
 *				The following macros are also available to specify all available CPUs.
 *				- SCE_KERNEL_CPU_MASK_USER_ALL
 * @retval	Positive value	CPU affinity mask before change
 * @retval	Negative value	Error code
 */
SceInt32 sceKernelChangeThreadCpuAffinityMaskForDriver(
	SceUID		threadId,
	SceInt32	cpuAffinityMask
);

sceKernelSetThreadAccessLevelForDriver

Version NID
1.69-3.65 0x02EEDF17

Temp name was sceKernelSetPermissionForDriver.

// return value is previous value
int sceKernelSetThreadAccessLevelForDriver(int value);

sceKernelGetProcessIdForDriver

Version NID
1.69-3.60 0x9DCB4B7A

Returns the process ID.

SceUID sceKernelGetProcessIdForDriver(void);

sceKernelSetImpersonateIdForDriver

Version NID
1.69-3.60 0x0486F239

This is a guessed name. Temp name was sceKernelSetProcessIdToTLSForDriver.

Sets impersonation ID for the current thread.

Impersonation ID is used for access checks in e.g. SceIofilemgr.

// Returns the previous impersonation ID
ScePID sceKernelSetImpersonateIdForDriver(ScePID pid);

sceKernelGetImpersonateIdForDriver

Version NID
1.69-3.60 0xFA54D49A

This is a guessed name. Temp name was sceKernelGetProcessIdFromTLSForDriver.

Returns the current thread's impersonation ID.

Used by SceIofilemgr, which calls the returned value impersonateId.

ScePID sceKernelGetImpersonateIdForDriver(void);

sceKernelRegisterTimerForDriver

Version NID
0.990 also in ForKernel
3.60 0xC58DF384

// seen: unk = 0, 2 so maybe UDCD bus

int sceKernelRegisterTimerForDriver(char *name, SceUInt32 time, void *function, int unk);

sceKernelRegisterTimerWithOptForDriver

Version NID
0.990 also in ForKernel
0.990-3.60 0x10517330

This is a guessed name.

typedef struct SceKernelRegisterTimerOpt {
    SceUInt32 time;
    char *log_buffer_start;
} SceKernelRegisterTimerOpt;

int sceKernelRegisterTimerWithOptForDriver(char *name, SceKernelRegisterTimerOpt *pOpt, void *function, int unk);

sceKernelCreateRWLockForDriver

Version NID
0.990-3.60 0x04150799

sceKernelCreateTimerForDriver

Version NID
3.60 0x90656C98
SceUID sceKernelCreateTimerForDriver(const char *name, int attr, void *pOpt);

sceKernelDelayThreadUnkCBForDriver

Version NID
3.60 0x2B60B793

sceKernelDelayThreadUnkForDriver

Version NID
3.60 0xE9A99C50
int sceKernelDelayThreadUnkForDriver(SceUInt32 nsec, SceUInt32 *some_time);

sceKernelGetTHBPForDriver

Version NID
0.990-3.60 0x453B764A

Used by SceDeci4pSDbgp.

Get thread hardware break point.

int sceKernelGetTHBPForDriver(SceUID thid, SceUInt32 a2, int *a3, int *a4);

sceKernelSetTHBPForDriver

Version NID
0.990-3.60 0x385831A1
int sceKernelSetTHBPForDriver(SceUID pid, SceUInt32 a2, int a3, int a4);

SceThreadmgrForDriver_86DAE59B

Version NID
3.60 0x86DAE59B

A guessed name is sceKernelGetAllowedCpuAffinityMaskForDriver.

Get global CPU affinity mask.

int SceThreadmgrForDriver_86DAE59B(void);

sceKernelCancelAlarmForDriver

Version NID
0.990-3.60 0x44CCF310

Used in SceCtrl, SceTouch.

int sceKernelCancelAlarmForDriver(SceUID uid_or_pid);

sceKernelDebugSuspendThreadForDriver

Version NID
3.60 0xFB3706CB
int sceKernelDebugSuspendThreadForDriver(SceUID threadId, SceUInt32 status);

sceKernelGetEventFlagInfoForDriver

Version NID
3.60 0x612277C9
int sceKernelGetEventFlagInfoForDriver(SceUID uid, SceKernelEventFlagInfo *pInfo);

sceKernelGetThreadInfoForDebuggerForDriver

Version NID
0.990-3.60 0xDD8D9429

This is a guessed name. Old name was sceKernelGetThreadInfoInternalForDriver.

int sceKernelGetThreadInfoForDebuggerForDriver(SceUID thid, int a2, SceKernelThreadInfoInternal *pInfo);

sceKernelGetVfpRegisterForDebuggerForDriver

Version NID
3.60 0x5CDE387A

Temp name was sceKernelGetThreadFloatRegisterForDriver.

int sceKernelGetVfpRegisterForDebuggerForDriver(SceUID thid, SceKernelThreadFloatRegister *pRegister);

sceKernelGetUserThreadIdForDriver

Version NID
3.60 0xF311808F

This is a guessed name.

SceUID sceKernelGetUserThreadIdForDriver(SceUID thid_kern);

sceKernelGetSemaInfoForDriver

Version NID
3.60 0xC99DCF0D

This is a guessed name.

int sceKernelGetSemaInfoForDriver(SceUID semaid, SceKernelSemaInfo *info);

sceKernelGetEventFlagInfoForDriver

Version NID
3.60 0x612277C9

This is a guessed name.

int sceKernelGetEventFlagInfoForDriver(SceUID evfid, SceKernelEventFlagInfo *info);

sceKernelGetLwMutexInfoForDriver

Version NID
3.60 0x15287EF6

This is a guessed name.

int sceKernelGetLwMutexInfoForDriver(SceUID lwmtxid, SceKernelLwMutexInfo *info);

sceKernelGetMsgPipeInfoForDriver

Version NID
3.60 0x207E0E18

This is a guessed name.

int sceKernelGetMsgPipeInfoForDriver(SceUID msgpipe_id, SceKernelMsgPipeInfo *info);

sceKernelGetLwCondInfoForDriver

Version NID
3.60 0xC2AFFBD0

This is a guessed name.

int sceKernelGetLwCondInfoForDriver(SceUID lwcond_id, SceKernelLwCondInfo *info);

sceKernelGetThreadExitStatusForDriver

Version NID
3.60 0x70131EA5

This is a guessed name.

int sceKernelGetThreadExitStatusForDriver(SceUID thid, SceInt32 *status);

SceThreadmgrForDriver_032E8F73

Version NID
3.60 0x032E8F73

sceKernelGetLwMutexInfoAllProcForDriver

Version NID
3.60 0x069D8A20

SceThreadmgrForDriver_09346D1A

Version NID
3.60 0x09346D1A

SceThreadmgrForDriver_0A4AD37A

Version NID
3.60 0x0A4AD37A

sceKernelGetEventPatternForDriver

Version NID
3.60 0x0C6BCB8C

SceThreadmgrForDriver_0D0644DA

Version NID
3.60 0x0D0644DA

SceThreadmgrForDriver_0EB0ABF0

Version NID
3.60 0x0EB0ABF0

SceThreadmgrForDriver_1096042E

Version NID
3.60-3.65 0x1096042E

On success, returns SCE_TRUE if specified thread has the Common Dialog attribute (0x4000), and SCE_FALSE otherwise.

A possible name is sceKernelIsCdlgThread

SceInt32 SceThreadmgrForDriver_1096042E(SceUID thid);

SceThreadmgrForDriver_1378F6EF

Version NID
3.60 0x1378F6EF

sceKernelGetCurrentThreadVfpExceptionForDriver

Version NID
3.60 0x14F8167C

SceThreadmgrForDriver_154F2C2A_waitWorkQueue

Version NID
3.60 0x154F2C2A

sceKernelGetTimerInfoForDriver

Version NID
3.60 0x19F3E92A
int sceKernelGetTimerInfoForDriver(SceUID timerId, void *pInfo);

SceThreadmgrForDriver_20C228E4

Version NID
3.60 0x20C228E4

sceKernelGetMutexInfoAllProcForDriver

Version NID
3.60 0x2322A2F3

SceThreadmgrForDriver_25AB8F6B

Version NID
3.60 0x25AB8F6B

SceThreadmgrForDriver_2828F884

Version NID
3.60 0x2828F884

sceKernelDeleteSimpleEventForDriver

Version NID
3.60 0x2BDE3B40

SceThreadmgrForDriver_2E95B628

Version NID
3.60 0x2E95B628

SceThreadmgrForDriver_2F9F75AA

Version NID
3.60 0x2F9F75AA

SceThreadmgrForDriver_2FC0FFF6

Version NID
3.60 0x2FC0FFF6

sceKernelDeleteRWLockForDriver

Version NID
3.60 0x32452017

sceKernelGetTimerEventRemainingTimeForDriver

Version NID
3.60 0x3634FFE6
int sceKernelGetTimerEventRemainingTimeForDriver(SceUID timerId, SceUInt64 *time);

SceThreadmgrForDriver_36F8E58A

Version NID
3.60 0x36F8E58A

sceKernelGetRWLockInfoForDriver

Version NID
3.60 0x374C3267

threadmgrGpuExceptionHandlerForDriver

Version NID
3.60 0x37F51E91

sceKernelChangeThreadPriorityAndCpuAffinityMaskForDriver

Version NID
3.60 0x3857C94E

SceThreadmgrForDriver_3A72C6D8

Version NID
3.60 0x3A72C6D8

SceThreadmgrForDriver_3C297724

Version NID
3.60 0x3C297724

SceThreadmgrForDriver_3F5E1D56

Version NID
3.60 0x3F5E1D56

SceThreadmgrForDriver_419E6736

Version NID
3.60 0x419E6736

SceThreadmgrForDriver_477F7C8A

Version NID
3.60 0x477F7C8A

SceThreadmgrForDriver_47F26712

Version NID
3.60 0x47F26712

Used to unregister a Threadmgr interrupt handler. See SceThreadmgrForDriver_6C2E3A49.

//Pass same slot and kind as to SceThreadmgrForDriver_6C2E3A49.
int SceThreadmgrForDriver_47F26712(unsigned slot, unsigned kind);

SceThreadmgrForDriver_48C06CD6_waitWorkQueue

Version NID
3.60 0x48C06CD6

sceKernelSetVfpRegisterForDebuggerForDriver

Version NID
3.60 0x49A0B679

SceThreadmgrForDriver_4A038803

Version NID
3.60 0x4A038803

SceThreadmgrForDriver_4DE77569

Version NID
3.60 0x4DE77569

SceThreadmgrForDriver_5311CFB5

Version NID
0.990.000-3.740.011 0x5311CFB5

Registers exception handler.

Used by SceAppMgr.

int SceThreadmgrForDriver_5311CFB5(int (* handler)(SceUID pid, SceUID thid, int cause_flag, void *argp), void *argp);

SceThreadmgrForDriver_54566860

Version NID
3.60 0x54566860

sceKernelCountWaitingThreadsProcForDriver

Version NID
3.60-3.65 0x54E1AF04

Count the number of threads from a specified process waiting on a Waitable object.

SceSSize sceKernelCountWaitingThreadsProcForDriver(ScePID processId, SceUID waitableId);

SceThreadmgrForDriver_555CA6BB

Version NID
3.60 0x555CA6BB

SceThreadmgrForDriver_56C18B11

Version NID
3.60 0x56C18B11

SceThreadmgrForDriver_5870C73A

Version NID
3.60 0x5870C73A

SceThreadmgrForDriver_5D8F88B1

Version NID
3.60 0x5D8F88B1

sceKernelSetCpuRegisterForDebuggerForDriver

Version NID
3.60 0x64E89DE9

sceKernelGetRWLockInfoAllProcForDriver

Version NID
3.60 0x6624E612

SceThreadmgrForDriver_6657429E

Version NID
3.60 0x6657429E

SceThreadmgrForDriver_67022B18

Version NID
3.60 0x67022B18

SceThreadmgrForDriver_6C2E3A49

Version NID
3.60 0x6C2E3A49

Register a Threadmgr interrupt handler.

//Specify 0 or 1 for slot.
//Specify one of the following for kind, to select which "interrupt" the handler is registered for:
// 0 -> Thread events (To determine event, check argp->unk0: 1 = DeleteThread, 2 = StartThread)
// 1 -> Vfp
// 2 -> Gpu Exception
// 3 -> Stack overflow
// 4 -> Syscall Error - Illegal Context
// 5 -> Syscall Error - Critical Usage
// 6 -> Syscall Error - Illegal Number
// 7 -> ApiDeclareSuicide (unknown what this is for)
int SceThreadmgrForDriver_6C2E3A49(unsigned slot, unsigned kind, void (*handler)(int args, void* argp));

SceThreadmgrForDriver_6D4C1EB7

Version NID
3.60 0x6D4C1EB7

SceThreadmgrForDriver_738FF63D

Version NID
3.60 0x738FF63D

sceKernelTryLockFastMutexForDriver

Version NID
3.60 0x741F4707
int sceKernelTryLockFastMutexForDriver(void *pFastMutex);

SceThreadmgrForDriver_767CA30C

Version NID
3.60 0x767CA30C

sceKernelCancelRWLockForDriver

Version NID
3.60 0x7A4EF925

SceThreadmgrForDriver_7D12344A

Version NID
3.60 0x7D12344A

SceThreadmgrForDriver_7E280B69

Version NID
3.60 0x7E280B69

SceThreadmgrForDriver_84EB1EA4

Version NID
3.60 0x84EB1EA4

SceThreadmgrForDriver_85F4DC8C

Version NID
3.60 0x85F4DC8C

sceKernelCancelSemaForDriver

Version NID
3.60 0x8760C8ED

SceThreadmgrForDriver_88206D29

Version NID
3.60 0x88206D29

SceThreadmgrForDriver_89CA5698

Version NID
3.60 0x89CA5698

SceThreadmgrForDriver_8C3C1F78

Version NID
3.60 0x8C3C1F78

SceThreadmgrForDriver_8C48E53B

Version NID
3.60 0x8C48E53B

sceKernelIsUserModeThreadForDriver

Version NID
3.60 0x91382762

sceKernelDeleteTimerForDriver

Version NID
3.60 0x91A8F38B
int sceKernelDeleteTimerForDriver(SceUID timerId);

sceKernelSetTimerEventForDriver

Version NID
3.60 0x92A3DCDD
int sceKernelSetTimerEventForDriver(SceUID timerId, int type, SceUInt64 *time, SceBool repeat);

SceThreadmgrForDriver_995F32E1

Version NID
3.60 0x995F32E1

SceThreadmgrForDriver_A64B00F6

Version NID
3.60 0xA64B00F6

SceThreadmgrForDriver_A90B1E01

Version NID
3.60 0xA90B1E01

SceThreadmgrForDriver_AB977C72

Version NID
3.60-3.65 0xAB977C72

Reads the currentAttr field of the active thread into *pAttr.

A potential name for this function is sceKernelGetCurrentThreadAttr.

SceInt32 SceThreadmgrForDriver_AB977C72(SceUInt32 *pAttr);

SceThreadmgrForDriver_AF302193

Version NID
3.60 0xAF302193

SceThreadmgrForDriver_B4A05763

Version NID
3.60 0xB4A05763

Registers the low-power idle loop. Used by SceLowio.

Once registered, the idle threads will execute this function instead of the basic idle loop.

To get a better understanding, note that the idle threads' code is equivalent to:

/* N.B.: lpidle_ptr is set by calling SceThreadmgrForDriver_B4A05763 */

while (lpidle_ptr == NULL) {
    __disable_irq(); /* cpsid i */
    __WFI();
    __enable_irq();  /* cpsie i */
}
/* This should never return! */
lpidle_ptr();
void SceThreadmgrForDriver_B4A05763( void (*low_power_idle_loop)(void) );

sceKernelGetWaitingThreadListForDriver

Version NID
3.60 0xB5C782A3

SceThreadmgrForDriver_B6DA4669

Version NID
3.60 0xB6DA4669

sceKernelCancelEventForDriver

Version NID
3.60 0xB6FA8305

SceThreadmgrForDriver_C03799E2

Version NID
3.60 0xC03799E2

SceThreadmgrForDriver_C2DA6286

Version NID
3.60 0xC2DA6286

SceThreadmgrForDriver_C327CA7C

Version NID
3.60 0xC327CA7C

SceThreadmgrForDriver_C4456EC9

Version NID
3.60 0xC4456EC9

SceThreadmgrForDriver_C6741986

Version NID
3.60 0xC6741986

SceThreadmgrForDriver_C7F5FFE0

Version NID
3.60 0xC7F5FFE0

SceThreadmgrForDriver_CA704239

Version NID
3.60 0xCA704239

sceKernelGetTimerTimeForDriver

Version NID
3.60 0xCB795E13
int sceKernelGetTimerTimeForDriver(SceUID timerId, SceUInt64 *time);

SceThreadmgrForDriver_CBA7FAAA

Version NID
3.60 0xCBA7FAAA

SceThreadmgrForDriver_CFA2FFAF

Version NID
3.60 0xCFA2FFAF

SceThreadmgrForDriver_D0262C55

Version NID
3.60 0xD0262C55

sceKernelPollEventForDriver

Version NID
3.60 0xD08C71C6

SceThreadmgrForDriver_D1FBDFA6

Version NID
3.60 0xD1FBDFA6

SceThreadmgrForDriver_D26BFF26

Version NID
3.60 0xD26BFF26

sceKernelGetTimerBaseForDriver

Version NID
3.60 0xD41F53D4
int sceKernelGetTimerBaseForDriver(SceUID timerId, SceUInt64 *result);

SceThreadmgrForDriver_D7455187

Version NID
3.60 0xD7455187

SceThreadmgrForDriver_D74F66BD

Version NID
3.60 0xD74F66BD

sceKernelGetFastMutexInfoForDriver

Version NID
3.60 0xD7AF2E58

This is a guessed name.

int sceKernelGetFastMutexInfoForDriver(void *pFastMutex, void *pInfo);

sceKernelSetTimerTimeForDriver

Version NID
3.60 0xD978D16F
int sceKernelSetTimerTimeForDriver(SceUID timerId, SceUInt64 *time);

sceKernelChangeThreadPriorityForDriver

Version NID
3.60 0xDA1544D1

sceKernelUIDInheritedEventClassInitForDriver

Version NID
3.60 0xDBB77032

SceThreadmgrForDriver_E0C7BCBB

Version NID
3.60 0xE0C7BCBB

SceThreadmgrForDriver_E2B57231

Version NID
3.60 0xE2B57231

sceKernelCancelEventWithSetPatternForDriver

Version NID
3.60 0xE5CAD3E2

SceThreadmgrForDriver_E6D80698

Version NID
3.60 0xE6D80698

SceThreadmgrForDriver_E938FB20

Version NID
3.60 0xE938FB20

SceThreadmgrForDriver_E9E50096

Version NID
3.60 0xE9E50096

sceKernelCancelEventFlagForDriver

Version NID
3.60 0xEA211225

sceKernelCancelTimerForDriver

Version NID
3.60 0xF285C94F
int sceKernelCancelTimerForDriver(SceUID timerId, SceUInt32 *a2);

SceThreadmgrForDriver_F2C9DC97

Version NID
3.60 0xF2C9DC97

sceKernelChangeThreadVfpExceptionForDriver

Version NID
3.60 0xF4C81683

SceThreadmgrForDriver_F5074173

Version NID
3.60 0xF5074173

SceThreadmgrForDriver_F8A6013B

Version NID
3.60 0xF8A6013B

SceThreadmgrForDriver_F96FE0D5

Version NID
3.60 0xF96FE0D5

SceThreadmgrForDriver_FD6150D5

Version NID
3.60 0xFD6150D5

SceThreadmgrForDriver_FD87586C

Version NID
3.60 0xFD87586C

sceKernelGetCallbackInfoForDriver

Version NID
3.60 0xFDC044AC

SceThreadmgrForDriver_FF8DA217

Version NID
3.60 0xFF8DA217

SceThreadmgrForKernel

sceKernelCpuScanThreadForProcessmgrForKernel

Version NID
3.65 0x01369E06

sceKernelSetDTraceThreadCBEnableForKernel

Version NID
3.60 0xBE5247A2
3.65 0x0AE9C713

sceKernelSetSyslibtraceThreadCBEnableForKernel

Version NID
3.60 0x5A410D2B
3.65 0x4F2B45DC

sceKernelSetThreadMgrTestModeForKernel

Version NID
3.65 0x1394E856

sceKernelClearThreadMgrTestModeForKernel

Version NID
3.65 0x5D270A94

sceKernelThreadMgrProcessCreateForKernel

Version NID
3.65 0xB46502E6

sceKernelThreadMgrProcessDeleteAfterPUIDCloseForKernel

Version NID
3.60 0xF282AE42
3.65 0x5A23A1BE

sceKernelThreadMgrProcessDeleteBeforePUIDCloseForKernel

Version NID
3.60 0x1928DFBB
3.65 0x205506FC

sceKernelRegisterKTLSForKernel

Version NID
0.990.000-1.692.000 0xB645C7EF
1.80-3.740.011 not present. Still present in #SceThreadmgrForDriver.

Temp name was sceKernelAllocateKTLSForKernel.

See #sceKernelRegisterKTLSForDriver.

sceKernelUnregisterKTLSForKernel

Version NID
0.990.000-1.692.000 0x8C3C1F78
1.80-3.740.011 not present. Still present in #SceThreadmgrForDriver.

See #sceKernelUnregisterKTLSForDriver.

SceThreadmgrForKernel_89CA5698

Version NID
0.990.000-1.692.000 0x89CA5698
1.80-3.740.011 not present. Still present in #SceThreadmgrForDriver.

See #SceThreadmgrForDriver_89CA5698.

SceThreadmgrForKernel_3A72C6D8

Version NID
0.990.000-1.692.000 0x3A72C6D8
1.80-3.740.011 not present. Still present in #SceThreadmgrForDriver.

See #SceThreadmgrForDriver_3A72C6D8.

sceKernelSetEventWithNotifyCallbackForKernel

Version NID
0.995 0xB7DF3EDF
3.60 not present. Moved to ForDriver. SceKernelThreadMgr#sceKernelSetEventWithNotifyCallbackForDriver

sceKernelSetEventFlagForKernel

Version NID
0.931 0xD4780C3E
3.60 in ForDriver

SceThreadmgrForKernel_05F5306C

Version NID
0.990 0x05F5306C
3.60 not present

Uses DIP switch 216.

SceThreadmgrForKernel_CA84C603

Version NID
0.990 0xCA84C603
3.60 not present

Uses DIP switch 216.

sceKernelGetDefaultCpuAffinityMaskForKernel

Version NID
0.990 not present
3.60 0x091322E5
3.65 0xD9C097DD

sceKernelDebugSuspendThreadForKernel

Version NID
0.931-0.990 0xFB3706CB
3.60 not present
int sceKernelDebugSuspendThreadForKernel(SceUID threadId, SceUInt32 status);

SceThreadmgrForKernel_86DAE59B

Version NID
0.931-0.990 0x86DAE59B
3.60 not present

Get maybe current CPU mask.

int SceThreadmgrForKernel_86DAE59B(void);

sceKernelGetCurrentThreadUnkInfoForKernel

Version NID
0.931-0.990 0x332E127C
3.60 To ForDriver

Get some current thread information.

int sceKernelGetCurrentThreadUnkInfoForKernel(void);

SceThreadmgrForKernel_33E85E9E

Version NID
0.931-3.60 0x33E85E9E
typedef struct SceThreadmgrForKernel_33E85E9E_buf { // size is 0x34 on FW 0.990
  SceSize size; // Size of this structure
  char unk[0x30];
} SceThreadmgrForKernel_33E85E9E_buf;

int SceThreadmgrForKernel_33E85E9E(SceThreadmgrForKernel_33E85E9E_buf *buf);

sceKernelPMonThreadSetEventForKernel

Version NID
0.990-3.60 0x6ECCDCBD

sceKernelPMonSetControlRegisterForKernel

Version NID
0.990.000-2.060.011 0x1AAFA818
2.100.081-3.740.011 not present. Moved to #SceThreadmgrForDriver.

See #sceKernelPMonSetControlRegisterForDriver.

sceKernelPMonSetUserEnableRegisterForKernel

Version NID
0.990.000-2.060.011 0x5053B005
2.100.081-3.740.011 not present. Moved to #SceThreadmgrForDriver.

See #sceKernelPMonSetUserEnableRegisterForDriver.

sceKernelPMonThreadSetEnableCounterForKernel

Version NID
0.990.000-3.610.011 0x72E5DA4E
3.630.011-3.740.011 0x7F831213

sceKernelPMonThreadSetCounterForKernel

Version NID
0.990.000-3.610.011 0xD2BE5EFB
3.630.011-3.740.011 0x7B3368F1

sceKernelPMonThreadClearEnableCounterForKernel

Version NID
0.990.000-3.610.011 0x43D13895
3.630.011-3.740.011 0x1D2A6815

sceKernelGetThreadIdListForKernel

Version NID
0.990.000-1.692.000 0xEA7B8AEF
1.80-3.740.011 not present. Still present in SceThreadmgrForDriver.

See #sceKernelGetThreadIdListForDriver.

sceKernelCreateTimerForKernel

Version NID
0.990 0x90656C98
3.60 not present. Moved to ForDriver.
int sceKernelCreateTimerForKernel(const char *name, uint32_t attr);

sceKernelLockMutex_089ForKernel

Version NID
1.69-3.60 0x16AC80C5
int sceKernelLockMutex_089ForKernel(SceUID mutex_id, int unk1, int unk2);

sceKernelUnlockMutex_089ForKernel

Version NID
0.990-3.60 0x1E82E5D0
int sceKernelUnlockMutex_089ForKernel(SceUID mutex_id, int unk1);

sceKernelLockMutexCB_089ForKernel

Version NID
1.69 0xD06F2886
3.60 not present. Moved to ForDriver.

sceKernelTryLockMutex_089ForKernel

Version NID
1.69 0x270993A6
3.60 not present. Moved to ForDriver.

sceKernelCreateMutexForKernel

Version NID
1.69-3.60 0xFBAA026E
SceUID sceKernelCreateMutexForKernel(const char *pName, SceUInt attr, int initCount, const SceKernelMutexOptParam *pOptParam);

sceKernelDeleteMutexForKernel

Version NID
1.69-3.60 0x0A912340
int sceKernelDeleteMutexForKernel(SceUID mutexid);

sceKernelGetMutexInfo_089ForKernel

Version NID
1.69 0x69B78A12
3.60 not present. Moved to ForDriver.
int sceKernelGetMutexInfo_089ForKernel(SceUID mutexid, SceKernelMutexInfo *info);

sceKernelCancelMutex_089ForKernel

Version NID
1.69 0x7204B846
3.60 not present. Moved to ForDriver.

sceKernelSetThreadAccessLevelForKernel

Version NID
0.990-3.60 0x02EEDF17

Temp name was sceKernelSetPermissionForKernel.

// return value is previous value
int sceKernelSetThreadAccessLevelForKernel(int value);

sceKernelCreateSemaForKernel

Version NID
0.990-3.60 0x30E93C31
/**
 * Creates a new semaphore
 *
 * @par Example:
 * @code
 * int semaid;
 * semaid = sceKernelCreateSemaForKernel("MySema", 0, 1, 1, 0);
 * @endcode
 *
 * @param name - Specifies the name of the sema
 * @param attr - Sema attribute flags (normally set to 0)
 * @param initVal - Sema initial value
 * @param maxVal - Sema maximum value
 * @param option - Sema options (normally set to 0)
 * @return A semaphore id
 */
SceUID sceKernelCreateSemaForKernel(const char *name, SceUInt attr, int initVal, int maxVal, SceKernelSemaOptParam *option);

sceKernelSignalSemaForKernel

Version NID
3.60 0xD270498B

sceKernelWaitSemaForKernel

Version NID
3.60 0x3C8B55A9
/**
 * Lock a semaphore
 *
 * @par Example:
 * @code
 * sceKernelWaitSemaForKernel(sema_id, 1, 0);
 * @endcode
 *
 * @param sema_id - The sema id returned from ::sceKernelCreateSemaForKernel
 * @param signal - The value to wait for (i.e. if 1 then wait till reaches a signal state of 1)
 * @param timeout - Timeout in microseconds (assumed).
 *
 * @return < 0 on error.
 */
int sceKernelWaitSemaForKernel(SceUID sema_id, int signal, SceUInt *timeout);

sceKernelDeleteSemaForKernel

Version NID
0.990-3.60 0x16A35E58

sceKernelStartThread_089ForKernel

Version NID
0.990-1.69 0x21F5419B
3.60 not present. Moved to ForDriver.
/**
 * @brief Thread activation
 *
 * Starts the thread specified by threadId and puts it in READY state.
 *
 * The argument block specified by argSize and argBlock is copied onto the thread stack, argSize is
 * passed directly to the first argument of the thread entry function, and the second argument of
 * the entry function is the argument copied onto the stack. The block address is passed.
 *
 * This system call does not queue activation requests. In other words, if the target thread is not
 * in the DORMANT state, an SCE_KERNEL_ERROR_NOT_DORMANT error is returned to the calling thread.
 *
 * @param	threadId	Specify the identifier of the thread to be started.
 * @param	argSize		Specify the size (byte) of the argument to be passed to the thread.
 * @param	pArgBlock	Specify the address of the argument to be passed to the thread.
 * @retval	SCE_OK		Success
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelStartThread_089ForKernel(
	SceUID		threadId,
	SceSize		argSize,
	const void	*pArgBlock
);

sceKernelWaitThreadEnd_089ForKernel

Version NID
1.69 0xF3489EF4
3.60 not present

sceKernelDelayThreadForKernel

Version NID
1.69 0x4B675D05
3.60 not present. Moved to ForDriver.

sceKernelDelayThreadUnkCBForKernel

Version NID
0.990 0x2B60B793
3.60 not present. Moved to ForDriver.

sceKernelDelayThreadUnkForKernel

Version NID
0.990 0xE9A99C50
3.60 not present. Moved to ForDriver.

sceKernelStopThreadForKernel

Version NID
0.990-3.60 0x150AEF74

sceKernelSuspendThreadForKernel

Version NID
0.931-3.60 0xAEEE955F
// semaId must be strictly between 0 and 255
int sceKernelSuspendThreadForKernel(SceUID threadId, SceUID semaId);

sceKernelWaitThreadEndCB_089ForKernel

Version NID
1.69 0x0373C5E3
3.60 not present

sceKernelExitThreadForKernel

Version NID
1.69 0x0C8A38E1
3.60 not present. Moved to ForDriver.
/**
 * @brief End of own thread
 *
 * Terminates the own thread normally and shifts to the DORMANT state.
 * sceKernelExitThread() is a system call that does not return to the context of the issuer.
 *
 * Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
 * However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
 * The mutex is unlocked and not deleted.
 *
 * When the terminated thread is restarted with sceKernelStartThread(), the information included in the thread
 * management area, such as thread priority, is reset.
 * It will not inherit the one at the end.
 *
 * When a thread exits, exitStatus becomes the exit status of that thread.
 *
 * If the thread is terminated by a return from the entry function without using
 * sceKernelExitThread(), the return value of the entry function becomes the termination status.
 *
 * The end status of a thread can be obtained by sceKernelGetThreadExitStatus() and sceKernelGetThreadInfo(),
 * and when another thread waits for the end of the thread by sceKernelWaitThreadEnd(), it can be obtained by the return value.
 *
 * The thread exit status is saved while the thread exits and is in the DORMANT state,
 * but the value is lost if the thread is restarted or deleted with sceKernelStartThread().
 *
 * @param	exitStatus	Specify the value to be set for the termination status of the local thread.
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelExitThreadForKernel(
	SceInt32	exitStatus
);

sceKernelExitDeleteThreadForKernel

Version NID
1.69 0x1D17DECF
3.60 not present. Moved to ForDriver.
/**
 * @brief End and delete own thread
 *
 * Terminates the own thread normally and deletes it.
 * sceKernelExitDeleteThread() is a system call that does not return to the context of the issuer.
 *
 * Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
 * However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
 * The mutex is unlocked and not deleted.
 *
 * When a thread exits, exitStatus becomes the exit status of that thread (sceKernelExitDeleteThread()
 * directly deletes the thread without going through the DORMANT state.
 * (It cannot be obtained by sceKernelGetThreadInfo(). The end status can be obtained by the return
 * value only when waiting for the end of the thread by sceKernelWaitThreadEnd().)
 *
 * @param	exitStatus	Specify the value to be set for the termination status of the local thread.
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelExitDeleteThreadForKernel(
	SceInt32	exitStatus
);

sceKernelDelayThreadCBForKernel

Version NID
1.69 0x9C0180E1
3.60 not present. Moved to ForDriver.

sceKernelGetThreadCurrentPriorityForKernel

Version NID
1.69 0x01414F0B
3.60 not present. Moved to ForDriver.

sceKernelChangeCurrentThreadAttrForKernel

Version NID
1.69 0x751C9B7A
3.60 not present. Moved to ForDriver.

sceKernelCpuScanThreadForProcessmgrForKernel

Version NID
0.990-3.60 0x3B4B8293
int sceKernelCpuScanThreadForProcessmgrForKernel(void *a1);

sceKernelGetProcessIdForKernel

Version NID
0.931-1.69 0x9DCB4B7A
3.60 not present. Moved to ForDriver.

Returns the process ID.

SceUID sceKernelGetProcessIdForKernel(void);

sceKernelChangeActiveCpuMaskForKernel

Version NID
1.69 0x001173F8
3.60 not present. Moved to ForDriver.

sceKernelCheckWaitableStatusForKernel

Version NID
1.69 0xD9BD74EB
3.60 not present. Moved to ForDriver.

sceKernelCheckCallbackForKernel

Version NID
1.69 0xE53E41F6
3.60 not present. Moved to ForDriver.

_sceKernelExtendKernelStackWideForKernel

Version NID
0.990-3.60 0xE54FD746

Temp name was sceKernelRunWithStackForKernel.

This takes a function and runs it exclusively on the current core on its own stack.

// stack_size should be 0x2000
int _sceKernelExtendKernelStackWideForKernel(int stack_size, void *func, void *args);

sceKernelExtendKernelStackWideForKernel

Version NID
0.990-1.69 0xA2C801A5
3.60 not present. Moved to ForDriver.

Temp name was sceKernelRunWithStack2ForKernel.

// stack_size should be 0x2000
SceInt64 sceKernelExtendKernelStackWideForKernel(int stack_size, void *func, void *args);

sceKernelExtendKernelStackWide2ForKernel

Version NID
0.990 0x236AF33A
3.60 unk
// stack_size should be 0x2000
int sceKernelExtendKernelStackWide2ForKernel(int stack_size, void *func, void *args);

sceKernelGetThreadContextInfoForKernel

Version NID
0.931-3.60 0xD8B9AC8D
3.65-3.67 0x6C1F092F

Temp name was sceKernelGetFaultingProcessForKernel.

Returns information about the thread currently scheduled on caller CPU.

This function can be called from an exception or interrupt handler, in which case it returns information about the thread that was interrupted.

struct SceKernelThreadContextInfo { // Previous name: SceKernelFaultingProcessInfo
    ScePID processId; //<! GUID of the process the currently scheduled thread
    SceUID threadId;  //<! GUID of the thread currently scheduled
};

SceInt32 sceKernelGetThreadContextInfoForKernel(struct SceKernelThreadContextInfo * pInfo);

sceKernelCloseEventFlagForKernel

Version NID
0.990 0x71ECB352
3.60 not present. Moved to ForDriver.

Temp name was sceKernelDeleteEventFlagForKernel.

See #sceKernelCloseEventFlagForDriver.

SceThreadmgrForKernel_E0833C77

Version NID
0.990-3.57 not present. Added on FW 3.60.
3.60 0xE0833C77

sceKernelSetThreadMgrTestModeForKernel

Version NID
1.69-3.60 0x333B26AD
int sceKernelSetThreadMgrTestModeForKernel(void);

sceKernelClearThreadMgrTestModeForKernel

Version NID
1.69-3.60 0xE00333A6
int sceKernelClearThreadMgrTestModeForKernel(void);

sceKernelSetThreadDebugCallbackForKernel

Version NID
3.60 0x41CF346A

This is a guessed name.

typedef struct SceThreadDebugCallbackParam {
	union {
		struct {
			SceKernelThreadEntry entry;
			SceUID thid;
			SceUID pid;
		} create;
		struct {
			SceUID  pid;
			SceUID  thid;
			SceSize argc;
			void   *argp;
		} start;
	};
} SceThreadDebugCallbackParam;

typedef int (* SceKernelThreadDebugCallback)(int a1, int a2, SceThreadDebugCallbackParam param);

int (* sceKernelSetThreadDebugCallback)(SceKernelThreadDebugCallback callback);

Code example:

int sceKernelThreadDebugCallback(int a1, int a2, SceThreadDebugCallbackParam param){
	// start thread
	if (a1 == 2 && a2 == 4) {
		ksceDebugPrintf(
			"%s:start pid:0x%08X thid:0x%08X argc:0x%08X argp:0x%08X\n",
			__FUNCTION__, param.start.pid, param.start.thid, param.start.argc, param.start.argp
		);
	} else if (a1 == 0 && a2 == 3) { // create thread
	} else if (a1 == 7 && a2 == 3) { // some timer (in SceThreadmgrTimer handler)
	} else if (a1 == 6 && a2 == 1) { // unknown (in SceThreadmgrForDriver_44CCF310)
	} else if (a1 == 1 && a2 == 2) { // delete thread (In sub_81000D78)
	}
	return 0;
}

SceThreadmgrForKernel_000DF999

Version NID
3.60 0x000DF999

sceKernelGetCpuRegisterForDebuggerForKernel

Version NID
3.60 0x09444C33
int sceKernelGetCpuRegisterForDebuggerForKernel(SceUID threadId, void *pInfo);

SceThreadmgrForKernel_09CEAAA4

Version NID
3.60 0x09CEAAA4

SceThreadmgrForKernel_14ADCC1F

Version NID
3.60 0x14ADCC1F

SceThreadmgrForKernel_15AAB4F9

Version NID
3.60 0x15AAB4F9

sceKernelWaitThreadSuspendForKernel

Version NID
3.60 0x17A4E56B
int sceKernelWaitThreadSuspendForKernel(SceUID threadId, SceUInt32 *timeout);

SceThreadmgrForKernel_2EC8E376

Version NID
3.60 0x2EC8E376

sceKernelGetThreadNameListProcForKernel

Version NID
3.60 0x315869B6

SceThreadmgrForKernel_3CD03673

Version NID
3.60 0x3CD03673

SceThreadmgrForKernel_41BCA03A

Version NID
3.60 0x41BCA03A

SceThreadmgrForKernel_4679280D

Version NID
3.60 0x4679280D

sceKernelDTraceAsyncXCallForKernel

Version NID
3.60 0x4C3887B4

This is a guessed name.

int sceKernelDTraceAsyncXCallForKernel(SceUInt32 targetCpu, int (* callback)(void *argp), void *argp, SceSize arg_len);

sceKernelGetVfpRegisterForDebuggerForKernel

Version NID
3.60 0x5785D18E

sceKernelDTraceSyncXCallForKernel

Version NID
3.60 0x5AB30D35

This is a guessed name.

int sceKernelDTraceSyncXCallForKernel(SceUInt32 targetCpu, int (* callback)(void *argp), void *argp);

SceThreadmgrForKernel_766028E7

Version NID
3.60 0x766028E7

SceThreadmgrForKernel_796D3A65

Version NID
3.60 0x796D3A65

SceThreadmgrForKernel_82F080A8

Version NID
3.60 0x82F080A8

sceKernelSetVfpRegisterForDebuggerForKernel

Version NID
3.60 0x87B3D598

SceThreadmgrForKernel_88D5BC33

Version NID
3.60 0x88D5BC33

SceThreadmgrForKernel_8B6F201E

Version NID
3.60 0x8B6F201E

sceKernelStopThread with arg 0x40000000.

SceThreadmgrForKernel_8F3E9E35

Version NID
3.60 0x8F3E9E35

SceThreadmgrForKernel_97780FA6

Version NID
3.60 0x97780FA6

SceThreadmgrForKernel_9C96317A

Version NID
3.60 0x9C96317A

SceThreadmgrForKernel_9F5ECAD5

Version NID
3.60 0x9F5ECAD5

SceThreadmgrForKernel_A1939BC9

Version NID
3.60 0xA1939BC9

SceThreadmgrForKernel_A4127F82

Version NID
3.60 0xA4127F82

SceThreadmgrForKernel_AEA9213B

Version NID
3.60 0xAEA9213B

sceKernelSetCpuRegisterForDebuggerForKernel

Version NID
3.60 0xC75A4609

SceThreadmgrForKernel_CC1D6D9F

Version NID
3.60 0xCC1D6D9F

SceThreadmgrForKernel_CE99E69C

Version NID
3.60 0xCE99E69C

SceThreadmgrForKernel_D8117AFB

Version NID
3.60 0xD8117AFB

SceThreadmgrForKernel_DBE2EE32

Version NID
3.60 0xDBE2EE32

SceThreadmgrForKernel_E3CE20AA

Version NID
3.60 0xE3CE20AA

SceThreadmgrForKernel_E92C1784

Version NID
3.60 0xE92C1784

sceKernelWaitThreadSuspend with arg 0

sceKernelIssueSimpleIntrRequestForKernel

Version NID
3.60 0xF74B7E34

SceThreadmgrForKernel_F9BD4A0D

Version NID
3.60 0xF9BD4A0D

SceThreadmgrForKernel_FA53F581

Version NID
3.60 0xFA53F581

SceThreadmgr

_sceKernelCloseTimer

Version NID
1.69 0x22605E63
3.60 not present

_sceKernelCloseMutex

Version NID
1.69 0x21716C81
3.60 not present

_sceKernelPollSema

Version NID
1.69 0x20AF286A
3.60 not present

_sceKernelCancelCallback

Version NID
1.69 0x19A0C1B6
3.60 not present

_sceKernelOpenMsgPipe

Version NID
1.69 0x16EC5B7C
3.60 not present

_sceKernelDeleteEventFlag

Version NID
1.69 0x16C93704
3.60 not present

_sceKernelDeleteThread

Version NID
1.69 0x151E0020
3.60 not present

Simply calls sceKernelDeleteThread();

/**
 * @brief Delete thread
 *
 * Deletes the thread specified by threadId.
 *
 * Accordingly, the stack area and thread management area are released. The target thread must be in the DORMANT state.
 *
 * Since the own thread cannot be in the DORMANT state, it cannot be set as the target thread
 * (this results in an SCE_KERNEL_ERROR_NOT_DORMANT error).
 * Use sceKernelExitDeleteThread() to delete your own thread.
 *
 * @param	threadId	Specify the identifier of the thread to be deleted.
 * @retval	SCE_OK		Success
 * @retval	Negative value	Error code
 */
SceInt32	_sceKernelDeleteThread(
	SceUID	threadId
);

_sceKernelUnlockMutex

Version NID
1.69 0x12948A63
3.60 not present

sceKernelGetActiveCpuMask

Version NID
1.69 0x0C3CBB8B
3.60 not present

_sceKernelSignalCondAll

Version NID
1.69 0x0F11545D
3.60 not present

sceKernelUnregisterThreadEventHandler

Version NID
3.60 0x2C8ED6F0

sceKernelChangeActiveCpuMask

Version NID
1.69-3.60 0x001173F8

sceKernelGetThreadCurrentPriority

Version NID
1.69-3.60 0x01414F0B

sceKernelWaitThreadEndCB_089

Version NID
1.69-3.60 0x0373C5E3

sceKernelGetCallbackCount

Version NID
1.69-3.60 0x038644D5

_sceKernelTryReceiveMsgPipeVector

Version NID
1.69-3.60 0x03CFCF00

sceKernelCloseMutex

Version NID
1.69-3.60 0x03E23AF6

_sceKernelGetSemaInfo

Version NID
1.69-3.60 0x0402C633

_sceKernelWaitCond

Version NID
1.69-3.60 0x040795C7

_sceKernelWaitMultipleEventsCB

Version NID
1.69-3.60 0x0558B7C1

_sceKernelGetCondInfo

Version NID
1.69-3.60 0x05C51CE1

_sceKernelSignalLwCondAll

Version NID
1.69-3.60 0x07D2584A

sceKernelExitThread

Version NID
1.69-3.60 0x0C8A38E1
/**
 * @brief End of own thread
 *
 * Terminates the own thread normally and shifts to the DORMANT state.
 * sceKernelExitThread() is a system call that does not return to the context of the issuer.
 *
 * Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
 * However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
 * The mutex is unlocked and not deleted.
 *
 * When the terminated thread is restarted with sceKernelStartThread(), the information included in the thread
 * management area, such as thread priority, is reset.
 * It will not inherit the one at the end.
 *
 * When a thread exits, exitStatus becomes the exit status of that thread.
 *
 * If the thread is terminated by a return from the entry function without using
 * sceKernelExitThread(), the return value of the entry function becomes the termination status.
 *
 * The end status of a thread can be obtained by sceKernelGetThreadExitStatus() and sceKernelGetThreadInfo(),
 * and when another thread waits for the end of the thread by sceKernelWaitThreadEnd(), it can be obtained by the return value.
 *
 * The thread exit status is saved while the thread exits and is in the DORMANT state,
 * but the value is lost if the thread is restarted or deleted with sceKernelStartThread().
 *
 * @param	exitStatus	Specify the value to be set for the termination status of the local thread.
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelExitThread(
	SceInt32	exitStatus
);

_sceKernelCreateSema

Version NID
1.69-3.60 0x0D76458E

sceKernelOpenMsgPipe

Version NID
1.69-3.60 0x0E1CB9F6

_sceKernelGetEventFlagInfo

Version NID
1.69-3.60 0x106C216F

_sceKernelSetEventWithNotifyCallback

Version NID
1.69-3.60 0x118F646E

sceKernelSignalCondTo

Version NID
1.69-3.60 0x1269F4EC

sceKernelCloseMsgPipe

Version NID
1.69-3.60 0x1305A065

_sceKernelCancelTimer

Version NID
1.69-3.60 0x13117B21

sceKernelChangeThreadCpuAffinityMask

Version NID
1.69-3.60 0x15129174
/**
 * @brief Thread CPU affinity mask setting
 *
 * Change the CPU affinity mask of the thread specified by threadId to cpuAffinityMask.
 * A thread can run only on the CPU specified by the CPU affinity mask.
 *
 * If the CPU affinity mask of a running thread is changed and cannot be executed on the current CPU, the thread is dispatched immediately.
 * As a result of scheduling, if a higher priority thread is running on the newly executable CPU, it is made to wait in the READY state.
 *
 * However, if the dispatch is disabled, the CPU affinity mask is changed immediately,
 * but the rescheduling process is delayed until dispatch is permitted.
 *
 * @param	threadId	Specify the identifier of the thread whose CPU affinity mask is to be changed.
 *				You can specify your own thread with SCE_KERNEL_THREAD_ID_SELF.
 * @param	cpuAffinityMask	Specify the CPU affinity mask after the change.
 *				The CPU affinity mask is expressed by the logical OR of the following macros.
 *				- SCE_KERNEL_CPU_MASK_USER_0
 *				- SCE_KERNEL_CPU_MASK_USER_1
 *				- SCE_KERNEL_CPU_MASK_USER_2
 *				The following macros are also available to specify all available CPUs.
 *				- SCE_KERNEL_CPU_MASK_USER_ALL
 * @retval	Positive value	CPU affinity mask before change
 * @retval	Negative value	Error code
 */
SceInt32 sceKernelChangeThreadCpuAffinityMask(
	SceUID		threadId,
	SceInt32	cpuAffinityMask
);

sceKernelCloseCond

Version NID
1.69-3.60 0x15C690E0

sceKernelLockMutex_089

Version NID
1.69-3.60 0x16AC80C5
int sceKernelLockMutex_089(SceUID mutex_id, int unk1, int unk2);

sceKernelUnregisterCallbackFromEvent

Version NID
1.69-3.60 0x18462B11

_sceKernelWaitLwCond

Version NID
1.69-3.60 0x18C65756

sceKernelUnlockMutex

Version NID
1.69-3.60 0x1A372EC8

_sceKernelCancelMutex

Version NID
1.69-3.60 0x1B74CB89

sceKernelDeleteThread

Version NID
1.69-3.60 0x1BBDE3D9
/**
 * @brief Delete thread
 *
 * Deletes the thread specified by threadId.
 *
 * Accordingly, the stack area and thread management area are released. The target thread must be in the DORMANT state.
 *
 * Since the own thread cannot be in the DORMANT state, it cannot be set as the target thread
 * (this results in an SCE_KERNEL_ERROR_NOT_DORMANT error).
 * Use sceKernelExitDeleteThread() to delete your own thread.
 *
 * @param	threadId	Specify the identifier of the thread to be deleted.
 * @retval	SCE_OK		Success
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelDeleteThread(
	SceUID	threadId
);

_sceKernelCancelSema

Version NID
1.69-3.60 0x1CAF805D

sceKernelExitDeleteThread

Version NID
1.69-3.60 0x1D17DECF
/**
 * @brief End and delete own thread
 *
 * Terminates the own thread normally and deletes it.
 * sceKernelExitDeleteThread() is a system call that does not return to the context of the issuer.
 *
 * Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
 * However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
 * The mutex is unlocked and not deleted.
 *
 * When a thread exits, exitStatus becomes the exit status of that thread (sceKernelExitDeleteThread()
 * directly deletes the thread without going through the DORMANT state.
 * (It cannot be obtained by sceKernelGetThreadInfo(). The end status can be obtained by the return
 * value only when waiting for the end of the thread by sceKernelWaitThreadEnd().)
 *
 * @param	exitStatus	Specify the value to be set for the termination status of the local thread.
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelExitDeleteThread(
	SceInt32	exitStatus
);

sceKernelUnlockMutex_089

Version NID
1.69-3.60 0x1E82E5D0
int sceKernelUnlockMutex_089(SceUID mutex_id, int unk1);

_sceKernelWaitMultipleEvents

Version NID
1.69-3.60 0x200CC503

sceKernelTryLockWriteRWLock

Version NID
1.69-3.60 0x206CBB66

sceKernelDeleteSimpleEvent

Version NID
1.69-3.60 0x208CFE28

_sceKernelGetThreadCpuAffinityMask

Version NID
1.69-3.60 0x212E6C35

_sceKernelGetTimerEventRemainingTime

Version NID
1.69-3.60 0x215FD24D

_sceKernelPollEvent

Version NID
1.69-3.60 0x21C7913E

sceKernelStartThread_089

Version NID
1.69-3.60 0x21F5419B
/**
 * @brief Thread activation
 *
 * Starts the thread specified by threadId and puts it in READY state.
 *
 * The argument block specified by argSize and argBlock is copied onto the thread stack, argSize is
 * passed directly to the first argument of the thread entry function, and the second argument of
 * the entry function is the argument copied onto the stack. The block address is passed.
 *
 * This system call does not queue activation requests. In other words, if the target thread is not
 * in the DORMANT state, an SCE_KERNEL_ERROR_NOT_DORMANT error is returned to the calling thread.
 *
 * @param	threadId	Specify the identifier of the thread to be started.
 * @param	argSize		Specify the size (byte) of the argument to be passed to the thread.
 * @param	pArgBlock	Specify the address of the argument to be passed to the thread.
 * @retval	SCE_OK		Success
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelStartThread_089(
	SceUID		threadId,
	SceSize		argSize,
	const void	*pArgBlock
);

_sceKernelExitCallback

Version NID
1.69 0x2682E6ED

sceKernelTryLockMutex_089

Version NID
1.69-3.60 0x270993A6

sceKernelSetTimerTimeWide

Version NID
1.69 0x273B4A4D
int sceKernelSetTimerTimeWide(SceUID timerId, SceUInt64 time);

_sceKernelOpenCond

Version NID
1.69 0x27DD11EA

_sceKernelGetThreadmgrUIDClass

Version NID
1.69 0x27EE191B

sceKernelOpenMutex_089

Version NID
1.69 0x2928D2EC

_sceKernelCancelEvent

Version NID
1.69 0x29483405

_sceKernelCreateMsgPipeWithLR

Version NID
1.69 0x2AAC8BFD
typedef struct SceKernelCreateMsgPipeSyscallArgs { // size is 0x10-bytes
  SceSize bufSize;
  void *opt;
  void *lr;
  int padding_0x0C:
} SceKernelCreateMsgPipeSyscallArgs;

int _sceKernelCreateMsgPipeWithLR(const char *name, int type, int attr, SceKernelCreateMsgPipeSyscallArgs *args);

_sceKernelUnlockLwMutex

Version NID
1.69 0x2ABC41DF

_sceKernelGetMsgPipeCreatorId

Version NID
1.69 0x2B751F95

sceKernelCancelCallback

Version NID
1.69 0x30741EF2

sceKernelSetEvent

Version NID
1.69 0x324218CD

_sceKernelGetTimerBaseWide

Version NID
1.69 0x370E147B

_sceKernelGetThreadContextForVM

Version NID
1.69 0x377094D5

_sceKernelCreateEventFlag

Version NID
1.69 0x38AA5E8E
/**
 * @brief Event flag generation
 *
 * Generate an event flag and set the initial value of the event flag. Returns the identifier of the generated event flag as a return value.
 *
 * @param	pName		Specifies the name of the eventflag.
 *                      The name of the eventflag does not need to be unique because it is used only for the purpose of operator
 *                      identification when debugging without interprocess communication.
 *                      However, if the SCE_KERNEL_ATTR_OPENABLE attribute is specified for attr,
 *                      a unique name must be specified in the system.
 *                      The maximum name length is 31 bytes.
 * @param	attr		Specifies the event flag attribute.
 *                      Specify the queue order from one of the following.
 *                      - SCE_KERNEL_EVF_ATTR_TH_FIFO: Waiting thread queuing is FIFO
 *                      - SCE_KERNEL_EVF_ATTR_TH_PRIO: Waiting thread queuing is based on the priority of threads.
 *                      Specify whether to wait for multiple threads from either of the following.
 *                      - SCE_KERNEL_EVF_ATTR_SINGLE: Multiple threads cannot wait simultaneously
 *                      - SCE_KERNEL_EVF_ATTR_MULTI: To generate an event flag that can be referenced by
 *                      sceKernelOpenEventFlag() that allows multiple threads to wait simultaneously, specify the following:
 *                      - SCE_KERNEL_ATTR_OPENABLE
 * @param	initPattern	Specifies the initial value of the eventflag.
 * @param	pOptParam	Argument for future expansion. Please specify NULL.
 * @retval	(>=0)		Event flag identifier (UID)
 * @retval	(<0)		Error code
 */
SceUID _sceKernelCreateEventFlag(const char *pName, SceUInt32 attr, SceUInt32 initPattern, const SceKernelEventFlagOptParam *pOptParam);

_sceKernelSetTimerTimeWide

Version NID
1.69 0x39364623

_sceKernelWaitThreadEndCB_0910

Version NID
1.69 0x394BCCF2

_sceKernelSignalCondTo

Version NID
1.69 0x3C00071F

_sceKernelReceiveMsgPipeVector

Version NID
1.69 0x3DD9E4AB

_sceKernelPulseEventWithNotifyCallback

Version NID
1.69 0x3E49D3F1

sceKernelUnlockReadRWLock

Version NID
1.69 0x3EF91145

sceKernelGetTimerTimeWide

Version NID
1.69 0x3EFD3165
SceUInt64 sceKernelGetTimerTimeWide(SceUID timerId);

_sceKernelCreateCallback

Version NID
1.69 0x3F42E175

_sceKernelWaitEventFlagCB

Version NID
1.69 0x401E0C68

_sceKernelSetEventFlag

Version NID
1.69 0x438917E4

_sceKernelWaitCondCB

Version NID
1.69 0x452B0AB3

_sceKernelWaitSema

Version NID
1.69 0x45389B6B

sceKernelGetSystemTimeLow

Version NID
1.69-3.60 0x47F6DE49

sceKernelStartTimer

Version NID
1.69 0x48091E0C
int sceKernelStartTimer(SceUID timerId);

sceKernelDelayThread

Version NID
1.69-3.60 0x4B675D05

_sceKernelClearEvent

Version NID
1.69 0x4B7F47DC

__sceKernelCreateLwMutex

Version NID
1.69-3.60 0x4BB3154A
typedef struct sceKernelCreateLwMutex_opt //size is 0x10
{
  int initCount;
  const SceKernelLwMutexOptParam* pOptParam;
  uint32_t unk_8;
  uint32_t unk_C;
} sceKernelCreateLwMutex_opt;

int __sceKernelCreateLwMutex(SceKernelLwMutexWork *pWork, const char *pName, unsigned int attr, sceKernelCreateLwMutex_opt* opt);

sceKernelClearEventFlag

Version NID
1.69 0x4CB87CA7

_sceKernelReceiveMsgPipeVectorCB

Version NID
1.69 0x4DBF648E

_sceKernelNotifyCallback

Version NID
1.69 0x4DF8B624

_sceKernelWaitEvent

Version NID
1.69 0x4E0EA70D

sceKernelOpenSimpleEvent

Version NID
1.69 0x4E1E4DF8

sceKernelGetThreadStackFreeSize

Version NID
1.69 0x4F8A3DA0

_sceKernelWaitSignal

Version NID
1.69 0x50407BF4

_sceKernelTryLockWriteRWLock

Version NID
1.69 0x52DD3322

sceKernelOpenMutex

Version NID
1.69 0x52E17182

sceKernelDeleteEventFlag

Version NID
1.69 0x5840162C

_sceKernelUnregisterCallbackFromEventAll

Version NID
1.69 0x5B5650C7

_sceKernelUnlockWriteRWLock

Version NID
1.69 0x5B746A69

_sceKernelGetCallbackCount

Version NID
1.69 0x5D06FF09

_sceKernelLockReadRWLockCB

Version NID
1.69 0x5D86D763

sceKernelGetTimerBaseWide

Version NID
1.69 0x5DBC1960
SceUInt64 sceKernelGetTimerBaseWide(SceUID timerId);

_sceKernelSendMsgPipeVector

Version NID
1.69 0x5E65E454

_sceKernelWaitExceptionCB

Version NID
1.69 0x5E7876F2

sceKernelResumeThreadForVM

Version NID
0.931-1.61 not present
1.660.011-2.120.011 0x5E93840E
2.50-3.740.011 not present

_sceKernelCloseCond

Version NID
1.69 0x650CE348

_sceKernelPMonCpuGetCounter

Version NID
1.69 0x667A4649

_sceKernelGetActiveCpuMask

Version NID
1.69 0x67FDA21B

_sceKernelDeleteCallback

Version NID
1.69 0x68D0FA79

sceKernelGetMutexInfo_089

Version NID
1.69-3.60 0x69B78A12
int sceKernelGetMutexInfo_089(SceUID mutexid, SceKernelMutexInfo *info);

_sceKernelPMonThreadGetCounter

Version NID
1.69 0x6B9711AC

_sceKernelGetLwCondInfo

Version NID
1.69 0x6C79F2F2

sceKernelSignalCond

Version NID
1.69-3.60 0x6ED2E2DC

_sceKernelSignalLwCondTo

Version NID
1.69 0x6F1A4A2E

_sceKernelGetTimerTime

Version NID
1.69 0x6F2C41BA

_sceKernelWaitException

Version NID
1.69 0x6F7C4DE6

_sceKernelGetEventPattern

Version NID
1.69 0x70358258

sceKernelGetMsgPipeCreatorId

Version NID
1.69 0x70E2A6D2

_sceKernelSuspendThreadForVM

Version NID
1.000.071-1.810.021 0x7192B01C
2.000.081-3.740.011 not present

sceKernelCancelMutex_089

Version NID
1.69-3.60 0x7204B846

_sceKernelWaitLwCondCB

Version NID
1.69 0x72DBB96B

sceKernelTryLockMutex

Version NID
1.69 0x72FC1F54

sceKernelChangeCurrentThreadAttr

Version NID
1.69-3.60 0x751C9B7A

_sceKernelDeleteLwCond

Version NID
1.69 0x75FCF058

sceKernelOpenCond

Version NID
1.69 0x76BDA02F

sceKernelRegisterCallbackToEvent

Version NID
1.69 0x76FB37E9

_sceKernelSignalCond

Version NID
1.69 0x79889DAC

_sceKernelCreateTimer

Version NID
1.69 0x79BA0A6D

_sceKernelGetMsgPipeInfo

Version NID
1.69 0x7AE31060

sceKernelClearEvent

Version NID
1.69 0x7B2A4B28
SceInt32 sceKernelClearEvent(SceUID eventId, SceUInt32 clearPattern);

_sceKernelUnlockReadRWLock

Version NID
1.69 0x7D16FB3B

_sceKernelWaitEventCB

Version NID
1.69 0x7D483C33

_sceKernelLockReadRWLock

Version NID
1.69 0x7EB9E8B5

_sceKernelLockMutex

Version NID
1.69 0x7FA945AD

_sceKernelGetThreadExitStatus_0940

Version NID
1.69 0x800BB137

_sceKernelLockWriteRWLock

Version NID
1.69 0x80191FAA

_sceKernelGetSystemInfo

Version NID
1.69 0x80544E0C

_sceKernelDeleteSema

Version NID
1.69 0x855F49D5

_sceKernelOpenTimer

Version NID
1.69 0x8564E008

_sceKernelGetTimerBase

Version NID
1.69 0x865DA482

sceKernelPollSema

Version NID
1.69 0x866EF048

_sceKernelGetCallbackInfo

Version NID
1.69 0x86761234

sceKernelStopTimer

Version NID
1.69 0x869E9F20
int sceKernelStopTimer(SceUID timerId);

sceKernelDeleteCond

Version NID
1.69 0x879E6EBD

sceKernelUnregisterCallbackFromEventAll

Version NID
1.69 0x888A7361

_sceKernelGetRWLockInfo

Version NID
1.69 0x8CE3AFC7

sceKernelPulseEvent

Version NID
1.69 0x8D27BAD6

_sceKernelCancelEventWithSetPattern

Version NID
1.69 0x8E68E870

_sceKernelSignalSema

Version NID
1.69 0x8E9A0400

_sceKernelDeleteLwMutex

Version NID
1.69 0x91262C5F

_sceKernelDeleteTimer

Version NID
1.69 0x921A043D

_sceKernelCreateMutex

Version NID
1.69 0x92667AE5
SceUID	_sceKernelCreateMutex(const char *pName, SceUInt32 attr, SceInt32 initCount, const SceKernelMutexOptParam *pOptParam);

_sceKernelCreateLwCond

Version NID
1.69 0x940B9EBE

sceKernelCloseEventFlag

Version NID
1.69 0x9A68F547

_sceKernelSetEvent

Version NID
1.69 0x9A92C33F

_sceKernelDeleteRWLock

Version NID
1.69 0x9AA387DF

_sceKernelGetTimerTimeWide

Version NID
1.69 0x9AC39954

_sceKernelRegisterCallbackToEvent

Version NID
1.69 0x9B1922F2

sceKernelDelayThreadCB

Version NID
1.69-3.60 0x9C0180E1

_sceKernelCreateSimpleEvent

Version NID
1.69 0x9C187FAD

_sceKernelLockLwMutex

Version NID
1.69 0x9C572180

_sceKernelChangeThreadCpuAffinityMask

Version NID
1.69 0x9C921F8D

Simply calls sceKernelChangeThreadCpuAffinityMask().

/**
 * @brief Thread CPU affinity mask setting
 *
 * Change the CPU affinity mask of the thread specified by threadId to cpuAffinityMask.
 * A thread can run only on the CPU specified by the CPU affinity mask.
 *
 * If the CPU affinity mask of a running thread is changed and cannot be executed on the current CPU, the thread is dispatched immediately.
 * As a result of scheduling, if a higher priority thread is running on the newly executable CPU, it is made to wait in the READY state.
 *
 * However, if the dispatch is disabled, the CPU affinity mask is changed immediately,
 * but the rescheduling process is delayed until dispatch is permitted.
 *
 * @param	threadId	Specify the identifier of the thread whose CPU affinity mask is to be changed.
 *				You can specify your own thread with SCE_KERNEL_THREAD_ID_SELF.
 * @param	cpuAffinityMask	Specify the CPU affinity mask after the change.
 *				The CPU affinity mask is expressed by the logical OR of the following macros.
 *				- SCE_KERNEL_CPU_MASK_USER_0
 *				- SCE_KERNEL_CPU_MASK_USER_1
 *				- SCE_KERNEL_CPU_MASK_USER_2
 *				The following macros are also available to specify all available CPUs.
 *				- SCE_KERNEL_CPU_MASK_USER_ALL
 * @retval	Positive value	CPU affinity mask before change
 * @retval	Negative value	Error code
 */
SceInt32 _sceKernelChangeThreadCpuAffinityMask(
	SceUID		threadId,
	SceInt32	cpuAffinityMask
);

_sceKernelOpenMutex

Version NID
1.69 0x9D291788

sceKernelGetProcessId

Version NID
1.69-3.60 0x9DCB4B7A

sceKernelCloseSema

Version NID
1.69 0xA2D81F9E

sceKernelCloseMutex_089

Version NID
1.69 0xA35427EE

sceKernelNotifyCallback

Version NID
1.69 0xA4683592

_sceKernelCloseMsgPipe

Version NID
1.69 0xAA888831

sceKernelDeleteTimer

Version NID
1.69 0xAB1E42C4
int sceKernelDeleteTimer(SceUID timerId);

_sceKernelGetTimerInfo

Version NID
1.69 0xAC7FE4F3

sceKernelCloseTimer

Version NID
1.69 0xACE60E4A
int sceKernelCloseTimer(SceUID timerId);

_sceKernelCreateRWLock

Version NID
1.69 0xB1877F5E

sceKernelCreateCallback

Version NID
1.69 0xB19CF7E9

_sceKernelGetThreadInfo

Version NID
1.69-3.60 0xB373D8A1
typedef struct get_thread_info_opt
{
   uint32_t size; // size of SceKernelThreadInfo
   uint32_t unk;
}get_thread_info_opt;

int _sceKernelGetThreadInfo(SceUID thid, SceKernelThreadInfo *info, get_thread_info_opt* opt)

_sceKernelTrySendMsgPipeVector

Version NID
1.69 0xB3D600AB

sceKernelUnlockWriteRWLock

Version NID
1.69 0xB4151397

_sceKernelGetThreadStackFreeSize

Version NID
1.69 0xB5EC061A

_sceKernelDeleteMsgPipe

Version NID
1.69 0xB6D50FCC

sceKernelOpenTimer

Version NID
1.69 0xB6E286E7
SceUID sceKernelOpenTimer(const char *name);

_sceKernelGetSystemTime

Version NID
1.69 0xB70EBAE9

_sceKernelChangeThreadVfpException

Version NID
1.69 0xB8F165B4

_sceKernelOpenSema

Version NID
1.69 0xB96FED7D

_sceKernelGetThreadTLSAddr

Version NID
1.69 0xBACA6891

sceKernelOpenEventFlag

Version NID
1.69 0xBC19F8A1

_sceKernelTryLockMutex

Version NID
1.69 0xBCFB867F

sceKernelChangeThreadPriority

Version NID
1.69 0xBD0139F2

sceKernelCreateThreadForUser

Version NID
1.69-3.60 0xC0FAF6A3
/**
 * @brief Thread generation that operates in the address space of its own process
 *
 * A thread that operates in the address space of its own process is created.
 *
 * Allocate a thread management area for the thread to be created, perform initialization, and secure a stack area.
 * The thread information to be created is specified as an argument, and the thread identifier (UID) is returned as the return value.
 *
 * The generated thread is in the DORMANT state.
 *
 * @param	pName		Specifies the name of the thread.
 *				The name of the thread does not have to be unique because it is
 *				used by the operator to identify it when debugging. The maximum name length is 31 bytes.
 * @param	entry		Specify the entry address of the thread. The thread entry point function
 * 				can receive memory block data with two arguments.
 *				The argument is given by sceKernelStartThread() described later.
 *				The thread is terminated by returning from this function, and the return value of the function is the thread termination status.
 * @param	initPriority	Specifies the initial priority of the thread. The smaller the number, the higher the priority.
 *				The range from SCE_KERNEL_HIGHEST_PRIORITY_USER (= 64) to SCE_KERNEL_LOWEST_PRIORITY_USER (= 191) can be used.
 *				By specifying SCE_KERNEL_DEFAULT_PRIORITY_USER, you can specify the default priority of the process to which the thread belongs.
 *				For the default priority, it is also possible to specify with SCE_KERNEL_DEFAULT_PRIORITY_USER ± offset.
 * @param	stackSize	Specify the required stack size of the thread in bytes. The argument block given by
 *				sceKernelStartThread () is copied onto the stack, so specify the stack size with this margin in mind.
 *				An error will occur if a stack size less than 4 KiB is specified.
 * @param	attr		You can specify multiple thread attributes by logical OR.
 * @param	cpuAffinityMask	Specifies the initial CPU affinity mask for the thread.
 *				A thread can run only on the thread specified in the CPU affinity mask.
 *				The CPU affinity mask can be specified by the logical sum of the following macros.
 *				- SCE_KERNEL_CPU_MASK_USER_0
 *				- SCE_KERNEL_CPU_MASK_USER_1
 *				- SCE_KERNEL_CPU_MASK_USER_2
 *				The following macros are also available to represent all available CPUs.
 *				- SCE_KERNEL_CPU_MASK_USER_ALL
 * @param	pOptParam	Argument for future expansion. Please specify NULL. Max size is 0x14.
 * @retval	Positive value	Thread identifier (UID)
 * @retval	Negative value	Error code
 */
SceUID	sceKernelCreateThreadForUser(
	const char	*pName,
	SceKernelThreadEntry		entry,
	SceInt32	initPriority,
	SceSize		stackSize,
	SceUInt32	attr,
	SceInt32	cpuAffinityMask,
	const SceKernelThreadOptParam	*pOptParam
);

_sceKernelSendSignal

Version NID
1.69 0xC21FC992

_sceKernelCloseRWLock

Version NID
1.69 0xC239DBCC

sceKernelSignalCondAll

Version NID
1.69 0xC2E7AC22

_sceKernelStartThread

Version NID
1.69 0xC30B1745
/**
 * @brief Thread activation
 *
 * Starts the thread specified by threadId and puts it in READY state.
 *
 * The argument block specified by argSize and argBlock is copied onto the thread stack, argSize is
 * passed directly to the first argument of the thread entry function, and the second argument of
 * the entry function is the argument copied onto the stack. The block address is passed.
 *
 * This system call does not queue activation requests. In other words, if the target thread is not
 * in the DORMANT state, an SCE_KERNEL_ERROR_NOT_DORMANT error is returned to the calling thread.
 *
 * @param	threadId	Specify the identifier of the thread to be started.
 * @param	argSize		Specify the size (byte) of the argument to be passed to the thread.
 * @param	pArgBlock	Specify the address of the argument to be passed to the thread.
 * @retval	SCE_OK		Success
 * @retval	Negative value	Error code
 */
SceInt32	_sceKernelStartThread(
	SceUID		threadId,
	SceSize		argSize,
	const void	*pArgBlock
);

_sceKernelSignalLwCond

Version NID
1.69 0xC37F6983

_sceKernelStartTimer

Version NID
1.69 0xC3ED6E4A

_sceKernelCloseSimpleEvent

Version NID
1.69 0xC6FFE335

_sceKernelGetThreadRunStatus

Version NID
1.69 0xC7FB5497

sceKernelGetThreadmgrUIDClass

Version NID
1.69 0xC9678F7F

_sceKernelStopTimer

Version NID
1.69 0xC96F4269

sceKernelDeleteMutex

Version NID
1.69 0xCB78710D

sceKernelOpenSema

Version NID
1.69 0xCBE235C7

_sceKernelCreateCond

Version NID
1.69 0xCC14FA59

sceKernelChangeThreadVfpException

Version NID
1.69 0xCC18FBAE

sceKernelOpenRWLock

Version NID
1.69 0xCE510196

_sceKernelCancelMsgPipe

Version NID
1.69 0xCE769C83

_sceKernelWaitSignalCB

Version NID
1.69 0xCEA3FC52

_sceKernelCancelRWLock

Version NID
1.69 0xD004EA15

sceKernelLockMutexCB_089

Version NID
1.69-3.60 0xD06F2886

_sceKernelGetThreadExitStatus

Version NID
1.69 0xD3210C08

_sceKernelWaitThreadEnd_0910

Version NID
1.69 0xD38231C9

sceKernelDeleteCallback

Version NID
1.69 0xD469676B

_sceKernelSetThreadContextForVM

Version NID
1.69 0xD4785C41

sceKernelSendSignal

Version NID
1.69 0xD4C367B2

_sceKernelDeleteCond

Version NID
1.69 0xD99F51D3

sceKernelCheckWaitableStatus

Version NID
1.69-3.60 0xD9BD74EB

_sceKernelGetLwCondInfoById

Version NID
1.69 0xD9E78D30

_sceKernelPollEventFlag

Version NID
1.69 0xDAB1B1C8
/**
 * @brief Event flag polling
 *
 * Polls the event flag specified by evfId.
 *
 * sceKernelPollEventFlag() is a system call that removes the function to enter standby state from sceKernelWaitEventFlag().
 * Unlike sceKernelWaitEventFlag(), an error (SCE_KERNEL_ERROR_EVF_COND) is returned immediately if the wait release condition is not satisfied.
 * In this case, SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL / SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT specification is ignored.
 *
 * @param	evfId		Specify the event flag identifier to be polled.
 * @param	bitPattern	Specify the comparison value with the eventflag.
 * @param	waitMode	Specify the wait mode. Specify one of the following:
 *                      - SCE_KERNEL_EVF_WAITMODE_AND: Waiting for AND
 *                      - SCE_KERNEL_EVF_WAITMODE_OR : Wait for OR
 *                      In addition, you can optionally add one of the following specifications as a logical sum.
 *                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL: Clear all bits after waiting
 *                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT: After waiting, clear the bit specified in bitPattern
 * @param	pResultPat	Specify a pointer to the SceUInt32 type variable that receives the eventflag value when waiting is established.
 * @retval	SCE_OK		Success
 * @retval	(<0)		Error code
 */
SceInt32 _sceKernelPollEventFlag(SceUID evfId, SceUInt32 bitPattern, SceUInt32 waitMode, SceUInt32 *pResultPat);

sceKernelDeleteSema

Version NID
1.69 0xDB32948A

_sceKernelLockMutexCB

Version NID
1.69 0xDB9F5333

_sceKernelLockWriteRWLockCB

Version NID
1.69 0xDBD09B09

_sceKernelOpenRWLock

Version NID
1.69 0xDFCEE5AB

_sceKernelDeleteMutex

Version NID
1.69 0xE0A6D759

_sceKernelSetTimerEvent

Version NID
1.69 0xE2C0BFEF

_sceKernelOpenSimpleEvent

Version NID
1.69 0xE326EA7A

sceKernelCheckCallback

Version NID
1.69-3.60 0xE53E41F6

_sceKernelChangeThreadPriority

Version NID
1.69 0xE61C2B06

sceKernelSignalSema

Version NID
1.69 0xE6B761D1

sceKernelDeleteRWLock

Version NID
1.69 0xE73649CA

sceKernelDeleteMsgPipe

Version NID
1.69 0xE78BCCF7

_sceKernelCloseSema

Version NID
1.69 0xE8C03447

_sceKernelGetMutexInfo

Version NID
1.69-3.60 0xE8CC3DF0
int _sceKernelGetMutexInfo(SceUID mutexid, SceKernelMutexInfo *pInfo, SceKernelMutexOptParam* pOpt);

_sceKernelWaitThreadEnd

Version NID
1.69 0xEA5C52F5

_sceKernelTryLockReadRWLock

Version NID
1.69 0xEB9054B2

sceKernelSetEventFlag

Version NID
1.69 0xEC94DFF7

sceKernelTryLockReadRWLock

Version NID
1.69 0xEFDDA456

_sceKernelClearEventFlag

Version NID
1.69 0xF0526CE2

sceKernelGetThreadCpuAffinityMask

Version NID
1.69 0xF1AE5654

sceKernelWaitThreadEnd_089

Version NID
1.69-3.60 0xF3489EF4

sceKernelGetSystemTimeWide

Version NID
1.69-3.60 0xF4EE4FA9

_sceKernelPulseEvent

Version NID
1.69 0xF6A0FE84

_sceKernelCloseEventFlag

Version NID
1.69 0xF6CFB4F1

_sceKernelSendMsgPipeVectorCB

Version NID
1.69 0xF6D515DC

_sceKernelDeleteSimpleEvent

Version NID
1.69 0xF7413EC7

_sceKernelCancelEventFlag

Version NID
1.69 0xF76F3056

_sceKernelWaitSemaCB

Version NID
1.69 0xF8E06784

_sceKernelWaitThreadEndCB

Version NID
1.69 0xFA3D4491

_sceKernelOpenEventFlag

Version NID
1.69 0xFA64FB37

_sceKernelUnregisterCallbackFromEvent

Version NID
1.69 0xFB66565E

_sceKernelWaitEventFlag

Version NID
1.69 0xFCE2F728
/**
 * @brief Event flag wait
 *
 * This system call waits for the event flag specified by evfId to be set according to the wait release condition specified by waitMode.
 * If the event flag specified by evfId already satisfies the wait release condition specified by waitMode,
 * the issuing thread continues execution without transitioning to the waiting state (WAITING).
 *
 * When SCE_KERNEL_EVF_WAITMODE_AND is specified for waitMode, it waits until all the bits specified by bitPattern become 1.
 * If SCE_KERNEL_EVF_WAITMODE_OR is specified for waitMode, wait until one of the bits specified in bitPattern becomes 1.
 * If SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL is additionally specified for waitMode, all the eventflag bits
 * are cleared to 0 when the wait release condition is satisfied and this thread is released.
 * If SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT is additionally specified for waitMode, the bit specified
 * by bitPattern is cleared to 0 when the wait release condition is satisfied and this thread is released.
 *
 * The event flag value is returned to pResultPat in the following cases. NULL can be specified if no value is required.
 * - If the wait release condition is satisfied (SCE_OK is returned),
 *   the event flag value before clearing by specifying SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL,
 *   SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT is returned immediately after the condition is satisfied.
 * - After exiting the wait state, the event flag value just before exiting from the wait state is returned when
 *   exiting except when the wait release condition is satisfied (when SCE_KERNEL_ERROR_WAIT_CANCEL,
 *   SCE_KERNEL_ERROR_WAIT_DELETE, SCE_KERNEL_ERROR_WAIT_TIMEOUT errors are returned).
 *   When canceling with sceKernelCancelEventFlag(), the eventflag value set at the time of cancellation is returned.
 *
 * When pTimeout is specified, the timeout operation specified in microseconds is set.
 * If pTimeout is NULL, timeout operation is not performed.
 * Note that if pTimeout is specified, the value pointed to by pTimeout is updated when the system call ends.
 * If the condition is met within the time, it is updated with the remaining time. If not established,
 * the value pointed to by pTimeout is updated with 0. In this case, error SCE_KERNEL_ERROR_WAIT_TIMEOUT is returned.
 *
 * Another thread cannot execute sceKernelWaitEventFlag() and sceKernelPollEventFlag() for an event flag with
 * the SCE_KERNEL_EVF_ATTR_SINGLE attribute that already has a waiting thread.
 * In this case, an error is returned immediately to the thread that executed sceKernelWaitEventFlag() or sceKernelPollEventFlag() later.
 *
 * If multiple threads are waiting for an event flag with the SCE_KERNEL_EVF_ATTR_MULTI attribute, a thread queue is created.
 * In this case, a single sceKernelSetEventFlag() may release the waiting status of multiple threads.
 *
 * In the case of the event flag of the SCE_KERNEL_EVF_ATTR_TH_FIFO attribute, the thread queue is
 * arranged in the order in which it waits first.
 * In the event flag of the SCE_KERNEL_EVF_ATTR_TH_PRIO attribute, the thread with the highest
 * priority among the waiting threads starts first and is arranged in the order of thread priority.
 *
 * If there is a thread with SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL specified or SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT specified in the
 * queue and the wait release condition for that thread is satisfied, the event flag is cleared at the same time as the wait release.
 * Threads that are lined up behind the thread that has specified SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL or SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT
 * will see the event flag after being cleared, so the wait may not be released.
 *
 * @param	evfId		Specifies the identifier of the event flag to wait for.
 * @param	bitPattern	Specify the comparison value with the eventflag.
 * @param	waitMode	Specifies the wait mode. Specify one of the following:
 *                      - SCE_KERNEL_EVF_WAITMODE_AND: Waiting for AND
 *                      - SCE_KERNEL_EVF_WAITMODE_OR : Wait for OR
 *                      In addition, you can optionally add either of the following specifications as a logical sum.
 *                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_ALL: After waiting, clear all bits
 *                      - SCE_KERNEL_EVF_WAITMODE_CLEAR_PAT: After waiting, clear the bit specified in bitPattern
 * @param	pResultPat	Specifies a pointer to the SceUInt32 type variable that receives the eventflag value when waiting is established.
 *                      If NULL is specified, the event flag value is not received.
 * @param	pTimeout	Specify a pointer to the SceUInt32 type variable that stores the upper limit (microseconds) of the waiting time.
 *                      If NULL is specified, wait indefinitely. When the wait condition is satisfied, the remaining time is returned.
 * @retval	SCE_OK		Success
 * @retval	(<0)		Error code
 */
SceInt32 _sceKernelWaitEventFlag(SceUID evfId, SceUInt32 bitPattern, SceUInt32 waitMode, SceUInt32 *pResultPat, SceUInt32 *pTimeout);

sceKernelCloseRWLock

Version NID
1.69 0xFD5BD5C1

_sceKernelGetLwMutexInfoById

Version NID
1.69 0xFEC9E946

sceKernelCloseSimpleEvent

Version NID
1.69 0xFEF4CA53

_sceKernelSetTimerTime

Version NID
1.69 0xFF738CD9

_sceKernelRegisterThreadEventHandler

Version NID
0.990 not present
3.60 0xCE6B49D8
typedef struct sceKernelRegisterThreadEventHandlerOpt { // size is 0x10 on FW 3.60
  SceKernelThreadEventHandler *handler;
  void *common;
  int reserved0;
  int reserved1;
} sceKernelRegisterThreadEventHandlerOpt;

int _sceKernelRegisterThreadEventHandler(char *name, SceUID thread_id, SceUInt32 mask, sceKernelRegisterThreadEventHandlerOpt *pOpt);

SceThreadmgrCoredumpTime

sceKernelExitThread

Version NID
3.60 0x0C8A38E1
/**
 * @brief End of own thread
 *
 * Terminates the own thread normally and shifts to the DORMANT state.
 * sceKernelExitThread() is a system call that does not return to the context of the issuer.
 *
 * Resources (memory, semaphores, etc.) acquired by the terminating thread are not automatically released.
 * However, for mutexes only, mutexes that have been locked by the terminating thread are automatically unlocked.
 * The mutex is unlocked and not deleted.
 *
 * When the terminated thread is restarted with sceKernelStartThread(), the information included in the thread
 * management area, such as thread priority, is reset.
 * It will not inherit the one at the end.
 *
 * When a thread exits, exitStatus becomes the exit status of that thread.
 *
 * If the thread is terminated by a return from the entry function without using
 * sceKernelExitThread(), the return value of the entry function becomes the termination status.
 *
 * The end status of a thread can be obtained by sceKernelGetThreadExitStatus() and sceKernelGetThreadInfo(),
 * and when another thread waits for the end of the thread by sceKernelWaitThreadEnd(), it can be obtained by the return value.
 *
 * The thread exit status is saved while the thread exits and is in the DORMANT state,
 * but the value is lost if the thread is restarted or deleted with sceKernelStartThread().
 *
 * @param	exitStatus	Specify the value to be set for the termination status of the local thread.
 * @retval	Negative value	Error code
 */
SceInt32	sceKernelExitThread(
	SceInt32	exitStatus
);