Add NS_RebootSystem
This commit is contained in:
parent
a4210af6c2
commit
a087e33414
@ -45,4 +45,7 @@ Result NS_RebootToTitle(u8 mediatype, u64 titleid);
|
||||
* @param titleid ID of the title to terminate.
|
||||
* @param timeout Timeout in nanoseconds. Pass 0 if not required.
|
||||
*/
|
||||
Result NS_TerminateProcessTID(u64 titleid, u64 timeout);
|
||||
Result NS_TerminateProcessTID(u64 titleid, u64 timeout);
|
||||
|
||||
/// Reboots the system
|
||||
Result NS_RebootSystem(void);
|
@ -116,3 +116,15 @@ Result NS_TerminateProcessTID(u64 titleid, u64 timeout)
|
||||
|
||||
return (Result)cmdbuf[1];
|
||||
}
|
||||
|
||||
Result NS_RebootSystem(void)
|
||||
{
|
||||
Result ret = 0;
|
||||
u32 *cmdbuf = getThreadCommandBuffer();
|
||||
|
||||
cmdbuf[0] = IPC_MakeHeader(0x16,0,0); // 0x160000
|
||||
|
||||
if(R_FAILED(ret = svcSendSyncRequest(nsHandle)))return ret;
|
||||
|
||||
return (Result)cmdbuf[1];
|
||||
}
|
Loading…
Reference in New Issue
Block a user