summaryrefslogtreecommitdiff
path: root/Source/Kernel/TaskManager/V86/V86Thread.class.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Kernel/TaskManager/V86/V86Thread.class.h')
-rw-r--r--Source/Kernel/TaskManager/V86/V86Thread.class.h25
1 files changed, 16 insertions, 9 deletions
diff --git a/Source/Kernel/TaskManager/V86/V86Thread.class.h b/Source/Kernel/TaskManager/V86/V86Thread.class.h
index 591bea6..7ca55b1 100644
--- a/Source/Kernel/TaskManager/V86/V86Thread.class.h
+++ b/Source/Kernel/TaskManager/V86/V86Thread.class.h
@@ -3,16 +3,22 @@
#include <TaskManager/Thread.class.h>
-struct v86_retval_t {
- registers_t *regs;
- bool finished;
-};
-
struct v86_function_t {
u16int size;
u8int data[];
};
+struct v86_regs_t {
+ u16int ax, bx, cx, dx, di, si;
+ u16int cs, ds, es, fs, gs, ss;
+ u16int ip, sp;
+} __attribute__((packed));
+
+struct v86_retval_t {
+ v86_regs_t *regs;
+ bool finished;
+};
+
#define V86_STACKSIZE 1024
#define EFLAGS_IF 0x200
@@ -26,12 +32,13 @@ class V86Thread : public Thread {
v86_retval_t* m_ret;
- bool m_if; //V86 IF flag
+ bool m_if, m_continueOnIret; //V86 IF flag
+
+ void setup();
- static void runV86(V86Thread* t, u32int data, u32int ss, u32int cs);
-
public:
- V86Thread(v86_function_t* entry, v86_retval_t* ret, u32int data);
+ V86Thread(v86_function_t* entry, v86_retval_t* ret);
+ V86Thread(u8int int_no, v86_retval_t* ret);
bool handleV86GPF(registers_t *regs);
void handleException(registers_t *regs, int no);