diff options
| author | Amlal El Mahrouss <amlal.elmahrouss@icloud.com> | 2024-12-26 21:19:14 +0100 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal.elmahrouss@icloud.com> | 2024-12-26 21:19:14 +0100 |
| commit | 486425ed00acec134f8799bdde64bfd093c5fb55 (patch) | |
| tree | 5104af49b56f39d0b14941d76f9d6d746cd1677b /dev/Boot/BootKit/Thread.h | |
| parent | c0f7f3f300d603d355fc7ec5be317afe1f0ee1b6 (diff) | |
IMPL: A lot of new changes, see details.
Signed-off-by: Amlal El Mahrouss <amlal.elmahrouss@icloud.com>
Diffstat (limited to 'dev/Boot/BootKit/Thread.h')
| -rw-r--r-- | dev/Boot/BootKit/Thread.h | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/dev/Boot/BootKit/Thread.h b/dev/Boot/BootKit/Thread.h new file mode 100644 index 00000000..42991d17 --- /dev/null +++ b/dev/Boot/BootKit/Thread.h @@ -0,0 +1,44 @@ +/* ------------------------------------------- + + Copyright (C) 2024, Theater Quality Inc, all rights reserved. + +------------------------------------------- */ + +#pragma once + +#include <KernelKit/PE.h> +#include <KernelKit/MSDOS.h> +#include <FirmwareKit/Handover.h> + +namespace Boot +{ + using namespace Kernel; + + class BThread; + + /// @brief Program loader class + /// @package nl.zeta.boot.api + class BThread final + { + public: + explicit BThread() = delete; + ~BThread() = default; + + explicit BThread(Kernel::VoidPtr blob); + + BThread& operator=(const BThread&) = default; + BThread(const BThread&) = default; + + Int32 Start(HEL::BootInfoHeader* handover, BOOL is_own_stack); + void SetName(const char* name); + const char* GetName(); + bool IsValid(); + + private: + Char fBlobName[255] = {"BootThread"}; + VoidPtr fStartAddress{nullptr}; + VoidPtr fBlob{nullptr}; + UInt8* fStack{nullptr}; + HEL::BootInfoHeader* fHandover{nullptr}; + }; +} // namespace Boot |
