diff options
| author | Amlal <amlalelmahrouss@icloud.com> | 2024-12-15 23:10:37 +0100 |
|---|---|---|
| committer | Amlal <amlalelmahrouss@icloud.com> | 2024-12-15 23:10:37 +0100 |
| commit | 6e17212bee66c76a82787e32f50962c95c9b3044 (patch) | |
| tree | fe08241af97aff521785b97e10d2b2f1993ec8de | |
| parent | ffbb5761fa5beeb7b166d401615acbde28a37fa3 (diff) | |
IMPL: dev/ZKAKit/src/HardwareThreadScheduler.cc: Only increment timer
when thread is busy.
IMPL: dev/ZKAKit/FirmwareKit/EFI/EFI.h: Use EFI_FINAL instead of raw
final keyword for C compat.
Signed-off-by: Amlal <amlalelmahrouss@icloud.com>
| -rw-r--r-- | dev/ZKAKit/FirmwareKit/EFI/EFI.h | 9 | ||||
| -rw-r--r-- | dev/ZKAKit/src/HardwareThreadScheduler.cc | 2 |
2 files changed, 7 insertions, 4 deletions
diff --git a/dev/ZKAKit/FirmwareKit/EFI/EFI.h b/dev/ZKAKit/FirmwareKit/EFI/EFI.h index a6b74b53..befa4e87 100644 --- a/dev/ZKAKit/FirmwareKit/EFI/EFI.h +++ b/dev/ZKAKit/FirmwareKit/EFI/EFI.h @@ -8,7 +8,7 @@ #define FIRMWARE_KIT_EFI_H /** -@brief Implementation of EFI protocols. +@brief Implementation of the main EFI protocols. */ #include <NewKit/Defines.h> @@ -25,6 +25,8 @@ using namespace Kernel; #define OUT #define OPTIONAL +#define EFI_FINAL final + // Forward decls struct EfiTableHeader; @@ -75,6 +77,7 @@ typedef UInt64(EFI_API* EfiLoadFile)(EfiLoadFileProtocol* Self, VoidPtr Buffer); typedef UInt64(EFI_API* EfiCopyMem)(VoidPtr DstBuf, VoidPtr SrcBuf, SizeT Length); + typedef UInt64(EFI_API* EfiSetMem)(VoidPtr DstBuf, Char Byte, SizeT Length); typedef UInt64(EFI_API* EfiHandleProtocol)(EfiHandlePtr Handle, EfiGUID* Guid, VoidPtr* Device); @@ -458,7 +461,7 @@ typedef UInt64(EFI_API* EfiGetMemoryMap)(UInt32* MapSize, /** * @brief GUID type, something you can also find in CFKit. */ -typedef struct EfiGUID final +typedef struct EfiGUID EFI_FINAL { UInt32 Data1; UInt16 Data2; @@ -778,7 +781,7 @@ typedef struct EfiTime } \ } -struct EfiFileInfo final +struct EfiFileInfo EFI_FINAL { /// @brief Structure size. UInt64 Size; diff --git a/dev/ZKAKit/src/HardwareThreadScheduler.cc b/dev/ZKAKit/src/HardwareThreadScheduler.cc index 99b4a7ff..e93b2284 100644 --- a/dev/ZKAKit/src/HardwareThreadScheduler.cc +++ b/dev/ZKAKit/src/HardwareThreadScheduler.cc @@ -63,7 +63,7 @@ namespace Kernel { STATIC Int64 busy_timer = 0U; - if (busy_timer > this->fPTime) + if (fBusy && busy_timer > this->fPTime) { busy_timer = 0U; fBusy = No; |
