summaryrefslogtreecommitdiffstats
path: root/include/asm-um
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-um')
-rw-r--r--include/asm-um/processor-generic.h5
-rw-r--r--include/asm-um/processor-i386.h7
-rw-r--r--include/asm-um/processor-x86_64.h12
3 files changed, 16 insertions, 8 deletions
diff --git a/include/asm-um/processor-generic.h b/include/asm-um/processor-generic.h
index b953b1ad3b02..b2fc94fbc2d9 100644
--- a/include/asm-um/processor-generic.h
+++ b/include/asm-um/processor-generic.h
@@ -24,9 +24,6 @@ struct thread_struct {
int forking;
int nsyscalls;
struct pt_regs regs;
- unsigned long cr2;
- int err;
- unsigned long trap_no;
int singlestep_syscall;
void *fault_addr;
void *fault_catcher;
@@ -74,8 +71,6 @@ struct thread_struct {
.forking = 0, \
.nsyscalls = 0, \
.regs = EMPTY_REGS, \
- .cr2 = 0, \
- .err = 0, \
.fault_addr = NULL, \
.prev_sched = NULL, \
.temp_stack = 0, \
diff --git a/include/asm-um/processor-i386.h b/include/asm-um/processor-i386.h
index 2deb8f1adbf1..431bad3ae9d7 100644
--- a/include/asm-um/processor-i386.h
+++ b/include/asm-um/processor-i386.h
@@ -9,13 +9,18 @@
extern int host_has_xmm;
extern int host_has_cmov;
+/* include faultinfo structure */
+#include "sysdep/faultinfo.h"
+
struct arch_thread {
unsigned long debugregs[8];
int debugregs_seq;
+ struct faultinfo faultinfo;
};
#define INIT_ARCH_THREAD { .debugregs = { [ 0 ... 7 ] = 0 }, \
- .debugregs_seq = 0 }
+ .debugregs_seq = 0, \
+ .faultinfo = { 0, 0, 0 } }
#include "asm/arch/user.h"
diff --git a/include/asm-um/processor-x86_64.h b/include/asm-um/processor-x86_64.h
index a1ae3a4cd938..0beb9a42ae05 100644
--- a/include/asm-um/processor-x86_64.h
+++ b/include/asm-um/processor-x86_64.h
@@ -7,9 +7,13 @@
#ifndef __UM_PROCESSOR_X86_64_H
#define __UM_PROCESSOR_X86_64_H
-#include "asm/arch/user.h"
+/* include faultinfo structure */
+#include "sysdep/faultinfo.h"
struct arch_thread {
+ unsigned long debugregs[8];
+ int debugregs_seq;
+ struct faultinfo faultinfo;
};
/* REP NOP (PAUSE) is a good thing to insert into busy-wait loops. */
@@ -20,7 +24,11 @@ extern inline void rep_nop(void)
#define cpu_relax() rep_nop()
-#define INIT_ARCH_THREAD { }
+#define INIT_ARCH_THREAD { .debugregs = { [ 0 ... 7 ] = 0 }, \
+ .debugregs_seq = 0, \
+ .faultinfo = { 0, 0, 0 } }
+
+#include "asm/arch/user.h"
#define current_text_addr() \
({ void *pc; __asm__("movq $1f,%0\n1:":"=g" (pc)); pc; })