Difference between revisions of "SceSblSsSmComm"

From Vita Development Wiki
Jump to navigation Jump to search
Line 72: Line 72:
 
! Version !! NID
 
! Version !! NID
 
|-
 
|-
| 0.940-3.60 || 0x0631F8ED
+
| 0.931-3.60 || 0x0631F8ED
 
|}
 
|}
  
 
This function calls [[SceSblSsSmComm#sceSblSmCommCallFuncForKernel|sceSblSmCommCallFuncForKernel]] with <code>-1</code> as <code>command_id</code> and then calls [[SceSblSmschedProxy#sceSblSmSchedProxyWaitForKernel|sceSblSmSchedProxyWaitForKernel]].
 
This function calls [[SceSblSsSmComm#sceSblSmCommCallFuncForKernel|sceSblSmCommCallFuncForKernel]] with <code>-1</code> as <code>command_id</code> and then calls [[SceSblSmschedProxy#sceSblSmSchedProxyWaitForKernel|sceSblSmSchedProxyWaitForKernel]].
  
<source lang="c">int sceSblSmCommStopSmForKernel(int id, int result[2]);</source>
+
<source lang="c">int sceSblSmCommStopSmForKernel(SceSmSchedRequestId req_id, status_handler* result);</source>
 +
 
 +
=== sceSblSmCommStopCommForKernel ===
 +
{| class="wikitable"
 +
|-
 +
! Version !! NID
 +
|-
 +
| 0.931 || 0xC35FB95A
 +
|}
 +
 
 +
<source lang="C">int sceSblSmCommStopCommForKernel(SceSmSchedRequestId req_id);</source>
  
 
=== sceSblSmCommStartSmFromDataForKernel ===
 
=== sceSblSmCommStartSmFromDataForKernel ===
Line 87: Line 97:
 
|}
 
|}
  
<source lang="c">
+
<source lang="c">int sceSblSmCommStartSmFromDataForKernel(SceBool priority, const char *sm_self_data, int sm_self_size, int cmd_id, SceSblSmCommContext130 *ctx_130, SceSmSchedRequestId *req_id);</source>
// Priority is binary: 1 = low, 0 = high. Running a high priority SM module while
 
// a low priority one is currently running will [[F00D Processor|suspend]] it.
 
int sceSblSmCommStartSmFromDataForKernel(int priority, const char *sm_self_data, int sm_self_size, int cmd_id, SceSblSmCommContext130 *ctx_130, int* id);
 
</source>
 
  
 
=== sceSblSmCommStartSmForKernel ===
 
=== sceSblSmCommStartSmForKernel ===
 +
{| class="wikitable"
 +
|-
 +
! Version !! NID
 +
|-
 +
| 0.931-3.60 || 0x7863A0CC
 +
|}
 +
 +
Priority is binary: 1 = low, 0 = high. Running a high priority SM module while a low priority one is currently running will [[F00D Processor|suspend]] the low one.
 +
 +
<source lang="c">int sceSblSmCommStartSmForKernel(SceBool priority, void *sm_self, SceBool some_bool, SceSblSmCommContext130* ctx_130, SceSmSchedRequestId *req_id);</source>
 +
 +
=== sceSblSmCommStartSm_ForKernel ===
 
{| class="wikitable"
 
{| class="wikitable"
 
|-
 
|-
Line 99: Line 117:
 
|-
 
|-
 
| 0.931-1.69 || 0x992BB9DB
 
| 0.931-1.69 || 0x992BB9DB
|-
 
| 3.60 || 0x7863A0CC
 
 
|}
 
|}
  
cmd_id is the F00D command ID. For exemple in 0.940 ss_mgr.skprx, when loading "os0:sm/qaf_sm.self", cmd_id = -1, 0, 1, 4, 5, 6, 7.
+
<source lang="c">int sceSblSmCommStartSm_ForKernel(SceBool priority, const char *path, SceBool some_bool, SceSblSmCommContext130* ctx_130, SceSmSchedRequestId *req_id);</source>
 
 
<source lang="c">
 
// Priority is binary: 1 = low, 0 = high. Running a high priority SM module while
 
// a low priority one is currently running will [[F00D Processor|suspend]] the low one.
 
int sceSblSmCommStartSmForKernel(int priority, char* sm_path, int cmd_id, SceSblSmCommContext130* ctx_130, int* id);
 
</source>
 
  
 
=== sceSblSmCommCallFuncForKernel ===
 
=== sceSblSmCommCallFuncForKernel ===
Line 118: Line 128:
 
|}
 
|}
  
<source lang="c">int sceSblSmCommCallFuncForKernel(int sm_id, int service_id, int *pResponse, void *pData, SceSize data_size);</source>
+
<source lang="c">int sceSblSmCommCallFuncForKernel(SceSmSchedRequestId req_id, SceUInt32 func_id, int *pResponse, void *pData, SceSize dataSize);</source>
 +
 
 +
=== sceSblSmCommCallFunc_ForKernel ===
 +
{| class="wikitable"
 +
|-
 +
! Version !! NID
 +
|-
 +
| 0.931 || 0x4960DF9E
 +
|}
 +
 
 +
<source lang="c">
 +
typedef struct sceSblSmCommCallFunc_Param {
 +
    void *pData;
 +
    SceSize dataSize;
 +
} sceSblSmCommCallFunc_Param;
 +
 
 +
int sceSblSmCommCallFunc_ForKernel(SceSmSchedRequestId req_id, SceUInt32 func_id, int *pResponse, sceSblSmCommCallFunc_Param *pParam);
 +
</source>
  
 
== SceSblSsSmComm ==
 
== SceSblSsSmComm ==
Line 129: Line 156:
 
! Version !! NID
 
! Version !! NID
 
|-
 
|-
| 0.940-1.69 || 0x0631F8ED
+
| 0.931-1.69 || 0x0631F8ED
 +
|}
 +
 
 +
=== sceSblSmCommStartSm ===
 +
{| class="wikitable"
 +
|-
 +
! Version !! NID
 +
|-
 +
| 0.931 || 0x7863A0CC
 
|}
 
|}
  
Line 137: Line 172:
 
! Version !! NID
 
! Version !! NID
 
|-
 
|-
| 0.940-1.69 || 0x992BB9DB
+
| 0.931-1.69 || 0x992BB9DB
 +
|}
 +
 
 +
=== sceSblSmCommCallFunc ===
 +
{| class="wikitable"
 +
! Version !! NID
 +
|-
 +
| 0.931 || 0xDB9FC204
 
|}
 
|}
  
Line 145: Line 187:
 
! Version !! NID
 
! Version !! NID
 
|-
 
|-
| 0.940-1.69 || 0x4960DF9E
+
| 0.931-1.69 || 0x4960DF9E
 
|}
 
|}
  
    sceSblSmCommStopComm 0xC35FB95A
+
=== sceSblSmCommStopComm ===
 +
{| class="wikitable"
 +
|-
 +
! Version !! NID
 +
|-
 +
| 0.931 || 0xC35FB95A
 +
|}
  
  
 
[[Category:Modules]]
 
[[Category:Modules]]
 
[[Category:Kernel]]
 
[[Category:Kernel]]

Revision as of 01:33, 5 June 2020

SceSblSsSmComm is a kernel module that is primary responsible for sending F00D commands.

Module

Known NIDs

Version Name World Privilege NID
1.69 SceSblSsSmComm Non-secure Kernel 0xA6A2A041
3.57 SceSblSsSmComm Non-secure Kernel 0x301EDC39
3.60 SceSblSsSmComm Non-secure Kernel 0xBB4B5D92

Libraries

Known NIDs

Version Name World Visibility NID
1.69-3.60 SceSblSmCommForKernel Non-secure Kernel 0xCD3C89B6
1.69 SceSblSsSmComm Non-secure User 0xD8DC7847

Types

/* example of caller_self_info
char data[0x90] =
{
   0x01,0x00,0x00,0x00, 0x00,0x00,0x08,0x28, // KBL program-authority-id
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x80,0x00,0x00,0x00, 0xC0,0x00,0xF0,0x00,
   0x00,0x00,0x00,0x00, 0xFF,0xFF,0xFF,0xFF,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x80,0x09,0x80,0x03, 0x00,0x00,0xC3,0x00,
   0x00,0x00,0x80,0x09, 0x80,0x00,0x00,0x00,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x00,0x00,0x00,0x00, 0xFF,0xFF,0xFF,0xFF,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
   0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,
}; */

typedef struct SceSblSmCommContext130 // size is 0x130 as its name indicates
{
   uint32_t unk_0;
   uint32_t self_type; // kernel = 0, user = 1, SM = 2
   SceSelfAuthInfo caller_self_info; // can be obtained with sceKernelGetSelfAuthInfoForKernel
   SceSelfAuthInfo called_self_info; // set by F00D in F00D SceSblSmCommContext130 response
   uint32_t pathId; // can be obtained with sceSblACMgrGetMediaTypeForKernel or sceIoGetMediaTypeForDriver
   uint32_t unk_12C; // if (kbl_param->boot_type_1 & 0x40) == true set unk_12C to 1, else set to 0xA
} SceSblSmCommContext130;

SceSblSmCommForKernel

sceSblSmCommStopSmForKernel

Version NID
0.931-3.60 0x0631F8ED

This function calls sceSblSmCommCallFuncForKernel with -1 as command_id and then calls sceSblSmSchedProxyWaitForKernel.

int sceSblSmCommStopSmForKernel(SceSmSchedRequestId req_id, status_handler* result);

sceSblSmCommStopCommForKernel

Version NID
0.931 0xC35FB95A
int sceSblSmCommStopCommForKernel(SceSmSchedRequestId req_id);

sceSblSmCommStartSmFromDataForKernel

Version NID
3.60 0x039C73B1
int sceSblSmCommStartSmFromDataForKernel(SceBool priority, const char *sm_self_data, int sm_self_size, int cmd_id, SceSblSmCommContext130 *ctx_130, SceSmSchedRequestId *req_id);

sceSblSmCommStartSmForKernel

Version NID
0.931-3.60 0x7863A0CC

Priority is binary: 1 = low, 0 = high. Running a high priority SM module while a low priority one is currently running will suspend the low one.

int sceSblSmCommStartSmForKernel(SceBool priority, void *sm_self, SceBool some_bool, SceSblSmCommContext130* ctx_130, SceSmSchedRequestId *req_id);

sceSblSmCommStartSm_ForKernel

Version NID
0.931-1.69 0x992BB9DB
int sceSblSmCommStartSm_ForKernel(SceBool priority, const char *path, SceBool some_bool, SceSblSmCommContext130* ctx_130, SceSmSchedRequestId *req_id);

sceSblSmCommCallFuncForKernel

Version NID
0.931-3.60 0xDB9FC204
int sceSblSmCommCallFuncForKernel(SceSmSchedRequestId req_id, SceUInt32 func_id, int *pResponse, void *pData, SceSize dataSize);

sceSblSmCommCallFunc_ForKernel

Version NID
0.931 0x4960DF9E
typedef struct sceSblSmCommCallFunc_Param {
    void *pData;
    SceSize dataSize;
} sceSblSmCommCallFunc_Param;

int sceSblSmCommCallFunc_ForKernel(SceSmSchedRequestId req_id, SceUInt32 func_id, int *pResponse, sceSblSmCommCallFunc_Param *pParam);

SceSblSsSmComm

This library is present on 1.69 but is not present on 3.60.

sceSblSmCommStopSm

Version NID
0.931-1.69 0x0631F8ED

sceSblSmCommStartSm

Version NID
0.931 0x7863A0CC

sceSblSmCommStartSm_

Version NID
0.931-1.69 0x992BB9DB

sceSblSmCommCallFunc

Version NID
0.931 0xDB9FC204

sceSblSmCommCallFunc_

Version NID
0.931-1.69 0x4960DF9E

sceSblSmCommStopComm

Version NID
0.931 0xC35FB95A