| 1 | + | #include <stdint.h> |
| 2 | + | #include <stdbool.h> |
| 3 | + | |
| 4 | + | static inline __forceinline void WaitForInterrupt() { |
| 5 | + | #if defined(_M_X64) || defined(_M_IX86) |
| 6 | + | __halt(); |
| 7 | + | #elif defined(_M_ARM) || defined(_M_ARM64) |
| 8 | + | __wfi(); |
| 9 | + | #else |
| 10 | + | #error "Unsupported architecture" |
| 11 | + | #endif |
| 12 | + | } |
| 13 | + | |
| 14 | + | uint32_t PocMain(void** FunctionTableOut, void** FunctionTableIn) { |
| 15 | + | // We don't want to return back to the boot application. |
| 16 | + | while (1) WaitForInterrupt(); |
| 17 | + | return 0xC00000BBL; // STATUS_NOT_SUPPORTED |
| 18 | + | } |