diff options
| author | Amlal <amlal@zka.com> | 2024-07-20 08:43:16 +0200 |
|---|---|---|
| committer | Amlal <amlal@zka.com> | 2024-07-20 08:43:16 +0200 |
| commit | 650fee520f526d9cd5ffa75735bd94d5140dd247 (patch) | |
| tree | 5967c57a2e754c0f46bccfba40a915a680dcaa10 /SCI/ErrorTypes.hxx | |
| parent | 81b284cacb03b34ae259c485ac874b02c8ecba69 (diff) | |
[IMP] See below.
- Revoke OTA flag for now inside bootloader (newosldr #4)
- Rework Comm as SCI (System Call Interface) (newoskrnl #3)
- Rework and fix some parts of the scheduler (newoskrnl #2)
- Return from thread when region is zero (newosldr #1)
- Separate allocation functions and c++ runtime from each other. (DDK #5)
- Rename kHartStandard to kStandard (newoskrnl #6)
Signed-off-by: Amlal <amlal@zka.com>
Diffstat (limited to 'SCI/ErrorTypes.hxx')
| -rw-r--r-- | SCI/ErrorTypes.hxx | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/SCI/ErrorTypes.hxx b/SCI/ErrorTypes.hxx new file mode 100644 index 00000000..7ab31215 --- /dev/null +++ b/SCI/ErrorTypes.hxx @@ -0,0 +1,52 @@ +/* ------------------------------------------- + + Copyright ZKA Technologies + +------------------------------------------- */ + +#pragma once + +#include <SCI/StandardInterface.hxx> + +#ifdef __KERNEL__ +#error !!! including header in kernel mode !!! +#endif // __KERNEL__ + +#define ErrLocalIsOk() (kLastError == kErrorSuccess) +#define ErrLocalFailed() (kLastError != kErrorSuccess) +#define ErrLocal() (kLastError) + +typedef SInt32 HError; + +inline constexpr HError kErrorSuccess = 0; +inline constexpr HError kErrorExecutable = 33; +inline constexpr HError kErrorExecutableLib = 34; +inline constexpr HError kErrorFileNotFound = 35; +inline constexpr HError kErrorDirectoryNotFound = 36; +inline constexpr HError kErrorDiskReadOnly = 37; +inline constexpr HError kErrorDiskIsFull = 38; +inline constexpr HError kErrorProcessFault = 39; +inline constexpr HError kErrorSocketHangUp = 40; +inline constexpr HError kErrorThreadLocalStorage = 41; +inline constexpr HError kErrorMath = 42; +inline constexpr HError kErrorNoNetwork = 43; +inline constexpr HError kErrorHeapOutOfMemory = 44; +inline constexpr HError kErrorNoSuchDisk = 45; +inline constexpr HError kErrorFileExists = 46; +inline constexpr HError kErrorFormatFailed = 47; +inline constexpr HError kErrorNetworkTimeout = 48; +inline constexpr HError kErrorInternal = 49; +inline constexpr HError kErrorForkAlreadyExists = 50; +inline constexpr HError kErrorOutOfTeamSlot = 51; +inline constexpr HError kErrorHeapNotPresent = 52; +inline constexpr HError kErrorNoEntrypoint = 53; +inline constexpr HError kErrorDiskIsCorrupted = 54; +inline constexpr HError kErrorDisk = 55; +inline constexpr HError kErrorInvalidData = 56; +inline constexpr HError kErrorAsync = 57; +inline constexpr HError kErrorNonBlocking = 58; +inline constexpr HError kErrorIPC = 59; +inline constexpr HError kErrorSign = 60; +inline constexpr HError kErrorUnimplemented = 0; + +inline HError kLastError = 0; |
