Kernel/SVC: Partially implemented svcExitProcess.

Terminating processes with ready threads is not currently implemented and will assert. It is currently unknown how the 3DS kernel stops ready threads or threads running in another core.
This commit is contained in:
Subv 2017-12-15 10:58:09 -05:00
parent 4b4e1861c7
commit 1856aa7b32
3 changed files with 41 additions and 1 deletions

View file

@ -49,6 +49,8 @@ union ProcessFlags {
BitField<12, 1, u16> loaded_high; ///< Application loaded high (not at 0x00100000).
};
enum class ProcessStatus { Created, Running, Exited };
class ResourceLimit;
struct MemoryRegionInfo;
@ -122,6 +124,8 @@ public:
u16 kernel_version = 0;
/// The default CPU for this process, threads are scheduled on this cpu by default.
u8 ideal_processor = 0;
/// Current status of the process
ProcessStatus status;
/// The id of this process
u32 process_id = next_process_id++;