mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2024-12-18 08:22:04 +00:00
kern: KWorkerTaskManager no longer tracks id
This commit is contained in:
parent
44d10da7b8
commit
252486913b
3 changed files with 4 additions and 8 deletions
|
@ -33,7 +33,6 @@ namespace ams::kern {
|
|||
KWorkerTask *m_head_task;
|
||||
KWorkerTask *m_tail_task;
|
||||
KThread *m_thread;
|
||||
WorkerType m_type;
|
||||
bool m_active;
|
||||
private:
|
||||
static void ThreadFunction(uintptr_t arg);
|
||||
|
@ -42,9 +41,9 @@ namespace ams::kern {
|
|||
KWorkerTask *GetTask();
|
||||
void AddTask(KWorkerTask *task);
|
||||
public:
|
||||
constexpr KWorkerTaskManager() : m_head_task(), m_tail_task(), m_thread(), m_type(WorkerType_Count), m_active() { /* ... */ }
|
||||
constexpr KWorkerTaskManager() : m_head_task(), m_tail_task(), m_thread(), m_active() { /* ... */ }
|
||||
|
||||
NOINLINE void Initialize(WorkerType wt, s32 priority);
|
||||
NOINLINE void Initialize(s32 priority);
|
||||
static void AddTask(WorkerType type, KWorkerTask *task);
|
||||
};
|
||||
|
||||
|
|
|
@ -17,10 +17,7 @@
|
|||
|
||||
namespace ams::kern {
|
||||
|
||||
void KWorkerTaskManager::Initialize(WorkerType wt, s32 priority) {
|
||||
/* Set type, other members already initialized in constructor. */
|
||||
m_type = wt;
|
||||
|
||||
void KWorkerTaskManager::Initialize(s32 priority) {
|
||||
/* Reserve a thread from the system limit. */
|
||||
MESOSPHERE_ABORT_UNLESS(Kernel::GetSystemResourceLimit().Reserve(ams::svc::LimitableResource_ThreadCountMax, 1));
|
||||
|
||||
|
|
|
@ -117,7 +117,7 @@ namespace ams::kern {
|
|||
/* Perform more core-0 specific initialization. */
|
||||
if (core_id == 0) {
|
||||
/* Initialize the exit worker manager, so that threads and processes may exit cleanly. */
|
||||
Kernel::GetWorkerTaskManager(KWorkerTaskManager::WorkerType_Exit).Initialize(KWorkerTaskManager::WorkerType_Exit, KWorkerTaskManager::ExitWorkerPriority);
|
||||
Kernel::GetWorkerTaskManager(KWorkerTaskManager::WorkerType_Exit).Initialize(KWorkerTaskManager::ExitWorkerPriority);
|
||||
|
||||
/* Setup so that we may sleep later, and reserve memory for secure applets. */
|
||||
KSystemControl::InitializePhase2();
|
||||
|
|
Loading…
Reference in a new issue