srv:

The interface snx::ctr::srv of srv.swipc, the service srv:. 3 commands; the handlers are in src/3ds/services.

CTR word-ordered commands, not Switch HIPC/CMIF.

RegisterClient srv.swipc

command 0x1: request 0x00010002, response 0x00010040

Request

WordContents
0header 0x00010002: command 0x1, 0 normal words, 2 translated
10x20: the calling process's ID follows
2process: the caller's process ID, which the kernel writes over the client's word

Response

WordContents
0header 0x00010040: command 0x1, 1 normal word, 0 translated
1the result: 0 for success. A failed command's response is the header and the result alone

Handler

uint32_t snx_ctr_srv_RegisterClient(SnxCtrIpc* c, uint32_t a_process)

srv.c, line 10

EnableNotification srv.swipc

command 0x2: request 0x00020000, response 0x00020042

Request

WordContents
0header 0x00020000: command 0x2, 0 normal words, 0 translated

Response

WordContents
0header 0x00020042: command 0x2, 1 normal word, 2 translated
1the result: 0 for success. A failed command's response is the header and the result alone
20x0: copied handle, 1
3semaphore: handle<copy>

Handler

uint32_t snx_ctr_srv_EnableNotification(SnxCtrIpc* c, uint32_t* a_semaphore)

srv.c, line 18

GetServiceHandle srv.swipc

command 0x5: request 0x00050100, response 0x00050042

Request

WordContents
0header 0x00050100: command 0x5, 4 normal words, 0 translated
1name, bytes 0-3: bytes<8>
2name, bytes 4-7: bytes<8>
3length: u32
4flags: u32

Response

WordContents
0header 0x00050042: command 0x5, 1 normal word, 2 translated
1the result: 0 for success. A failed command's response is the header and the result alone
20x10: moved handle, 1
3session: handle<move, session>

Handler

uint32_t snx_ctr_srv_GetServiceHandle(SnxCtrIpc* c, const uint8_t* a_name, uint32_t a_length, uint32_t a_flags, uint32_t* a_session)

srv.c, line 28


Made from ScarletNX's Sail at 166ad3910f80. The schemas and the handlers are ScarletNX's (GPL-3.0-or-later).