Kernel/x86 - Added SSE/FPU state saving, not fully tested
[tpg/acess2.git] / Kernel / arch / x86 / include / proc.h
index 73bddbb..9ecd98b 100644 (file)
@@ -5,8 +5,6 @@
 #ifndef _PROC_H
 #define _PROC_H
 
-#include <threads_int.h>
-
 // === TYPES ==
 typedef struct sTSS {
        Uint32  Link;
@@ -23,6 +21,29 @@ typedef struct sTSS {
        Uint16  Resvd, IOPB;    // IO Permissions Bitmap
 } __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>
+
 #define USER_MAX       KERNEL_BASE
 
 #endif

UCC git Repository :: git.ucc.asn.au