#ifndef _PROC_H
#define _PROC_H
-#include <threads.h>
-
-// === CONSTANTS ===
-#define GETMSG_IGNORE ((void*)-1)
-
-// === TYPES ===
-
+// === TYPES ==
typedef struct sTSS {
Uint32 Link;
Uint32 ESP0, SS0;
Uint32 ES, CS, DS, SS, FS, GS;
Uint32 LDTR;
Uint16 Resvd, IOPB; // IO Permissions Bitmap
-} tTSS;
+} __attribute__((packed)) tTSS;
+
+typedef struct {
+ #if USE_PAE
+ Uint PDPT[4];
+ #else
+ Uint32 CR3;
+ #endif
+} tMemoryState;
+
+// 512 bytes, 16 byte aligned
+typedef struct sSSEState
+{
+ char data[512];
+} tSSEState;
+
+typedef struct {
+ Uint EIP, ESP;
+ Uint32 UserCS, UserEIP;
+ tSSEState *SSE;
+ int bSSEModified;
+} tTaskState;
+
+#include <threads_int.h>
-// === FUNCTIONS ===
-extern void Proc_Start();
-extern int Proc_Clone(Uint *Err, Uint Flags);
+#define USER_MAX KERNEL_BASE
#endif