mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2025-01-31 04:03:44 +01:00
ProcessManager: Stub ProcessTracking code.
This commit is contained in:
parent
0459bcee74
commit
3d2c3e1fe1
@ -6,6 +6,9 @@
|
||||
#include <switch.h>
|
||||
#include <stratosphere.hpp>
|
||||
|
||||
#include "pm_boot_mode.hpp"
|
||||
#include "pm_process_track.hpp"
|
||||
|
||||
extern "C" {
|
||||
extern u32 __start__;
|
||||
|
||||
@ -82,10 +85,14 @@ int main(int argc, char **argv)
|
||||
{
|
||||
consoleDebugInit(debugDevice_SVC);
|
||||
|
||||
/* Initialize and spawn the Process Tracking thread. */
|
||||
ProcessTracking::Initialize();
|
||||
|
||||
/* TODO: What's a good timeout value to use here? */
|
||||
WaitableManager *server_manager = new WaitableManager(U64_MAX);
|
||||
|
||||
/* TODO: Create services. */
|
||||
server_manager->add_waitable(new ServiceServer<BootModeService>("pm:bm", 4));
|
||||
|
||||
/* Loop forever, servicing our services. */
|
||||
server_manager->process();
|
||||
|
15
stratosphere/pm/source/pm_process_track.cpp
Normal file
15
stratosphere/pm/source/pm_process_track.cpp
Normal file
@ -0,0 +1,15 @@
|
||||
#include <switch.h>
|
||||
#include "pm_process_track.hpp"
|
||||
|
||||
void ProcessTracking::Initialize() {
|
||||
/* TODO: Setup ResourceLimit values, create MainLoop thread. */
|
||||
}
|
||||
|
||||
void ProcessTracking::MainLoop() {
|
||||
/* TODO */
|
||||
while (true) {
|
||||
/* PM, as a sysmodule, is basically just a while loop. */
|
||||
|
||||
/* This is what while loop. */
|
||||
}
|
||||
}
|
8
stratosphere/pm/source/pm_process_track.hpp
Normal file
8
stratosphere/pm/source/pm_process_track.hpp
Normal file
@ -0,0 +1,8 @@
|
||||
#pragma once
|
||||
#include <switch.h>
|
||||
|
||||
class ProcessTracking {
|
||||
public:
|
||||
static void Initialize();
|
||||
static void MainLoop();
|
||||
};
|
Loading…
x
Reference in New Issue
Block a user