11 #include "../kernel/event.h"
12 #include "../sf/service.h"
13 #include "../services/ncm_types.h"
20 PmLaunchFlag_SignalOnExit = (1 << 0),
21 PmLaunchFlag_SignalOnStart = (1 << 1),
22 PmLaunchFlag_SignalOnCrash = (1 << 2),
23 PmLaunchFlag_SignalOnDebug = (1 << 3),
24 PmLaunchFlag_StartSuspended = (1 << 4),
28 PmLaunchFlagOld_SignalOnExit = (1 << 0),
29 PmLaunchFlagOld_StartSuspended = (1 << 1),
30 PmLaunchFlagOld_SignalOnCrash = (1 << 2),
31 PmLaunchFlagOld_DisableAslr = (1 << 3),
34 PmLaunchFlagOld_SignalOnStart = (1 << 5),
39 PmProcessEvent_None = 0,
40 PmProcessEvent_Exit = 1,
41 PmProcessEvent_Start = 2,
42 PmProcessEvent_Crash = 3,
43 PmProcessEvent_DebugStart = 4,
44 PmProcessEvent_DebugBreak = 5,
65 u32 transfer_memory_count;
116 Result pmdmntGetJitDebugProcessIdList(
u32* out_count,
u64* out_pids,
size_t max_pids);
118 Result pmdmntGetProcessId(
u64* pid_out,
u64 program_id);
120 Result pmdmntGetApplicationProcessId(
u64* pid_out);
121 Result pmdmntHookToCreateApplicationProcess(
Event* out);
123 Result pmdmntGetProgramId(
u64* program_id_out,
u64 pid);
125 Result pminfoGetProgramId(
u64* program_id_out,
u64 pid);
130 Result pmshellTerminateProcess(
u64 processID);
131 Result pmshellTerminateProgram(
u64 program_id);
135 Result pmshellClearJitDebugOccured(
u64 pid);
136 Result pmshellNotifyBootFinished(
void);
137 Result pmshellGetApplicationProcessIdForShell(
u64* pid_out);
138 Result pmshellBoostSystemMemoryResourceLimit(
u64 boost_size);
139 Result pmshellBoostApplicationThreadResourceLimit(
void);
140 Result pmshellBoostSystemThreadResourceLimit(
void);
Result pmbmInitialize(void)
Initialize pm:bm.
void pmdmntExit(void)
Exit pm:dmnt.
Service * pmshellGetServiceSession(void)
Gets the Service object for the actual pm:shell service session.
void pmshellExit(void)
Exit pm:shell.
Result pmbmSetMaintenanceBoot(void)
Sets the PmBootMode to PmBootMode_Maintenance.
Service * pmdmntGetServiceSession(void)
Gets the Service object for the actual pm:dmnt service session.
PmBootMode
BootMode.
Definition: pm.h:54
@ PmBootMode_SafeMode
SafeMode.
Definition: pm.h:57
@ PmBootMode_Maintenance
Maintenance.
Definition: pm.h:56
@ PmBootMode_Normal
Normal.
Definition: pm.h:55
Service * pminfoGetServiceSession(void)
Gets the Service object for the actual pm:info service session.
void pminfoExit(void)
Exit pm:info.
PmLaunchFlag
LaunchFlag.
Definition: pm.h:16
@ PmLaunchFlag_None
PmLaunchFlag_* should be used on [5.0.0+].
Definition: pm.h:17
@ PmLaunchFlagOld_SignalOnDebug
PmLaunchFlagOld_SignalOnStart is only available on [2.0.0+].
Definition: pm.h:32
@ PmLaunchFlag_DisableAslr
PmLaunchFlagOld_* should be used on [1.0.0-4.1.0].
Definition: pm.h:25
PmProcessEvent
ProcessEvent.
Definition: pm.h:38
Result pmbmGetBootMode(PmBootMode *out)
Gets the PmBootMode.
Result pminfoInitialize(void)
Initialize pm:info.
void pmbmExit(void)
Exit pm:bm.
Result pmshellInitialize(void)
Initialize pm:shell.
Result pmdmntInitialize(void)
Initialize pm:dmnt.
Service * pmbmGetServiceSession(void)
Gets the Service object for the actual pm:bm service session.
Kernel-mode event structure.
Definition: event.h:13
ProgramLocation.
Definition: ncm_types.h:173
ProcessEventInfo.
Definition: pm.h:48
ResourceLimitValues.
Definition: pm.h:61
Service object structure.
Definition: service.h:14
uint64_t u64
64-bit unsigned integer.
Definition: types.h:22
u32 Result
Function error code result type.
Definition: types.h:44
uint32_t u32
32-bit unsigned integer.
Definition: types.h:21