aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/m32r/include/asm/asm-offsets.h1
-rw-r--r--arch/m32r/include/asm/thread_info.h13
-rw-r--r--arch/m32r/kernel/asm-offsets.c15
-rw-r--r--arch/m32r/kernel/entry.S1
4 files changed, 17 insertions, 13 deletions
diff --git a/arch/m32r/include/asm/asm-offsets.h b/arch/m32r/include/asm/asm-offsets.h
new file mode 100644
index 000000000000..d370ee36a182
--- /dev/null
+++ b/arch/m32r/include/asm/asm-offsets.h
@@ -0,0 +1 @@
#include <generated/asm-offsets.h>
diff --git a/arch/m32r/include/asm/thread_info.h b/arch/m32r/include/asm/thread_info.h
index 32422d0211c3..034d1ab13029 100644
--- a/arch/m32r/include/asm/thread_info.h
+++ b/arch/m32r/include/asm/thread_info.h
@@ -38,18 +38,7 @@ struct thread_info {
38 __u8 supervisor_stack[0]; 38 __u8 supervisor_stack[0];
39}; 39};
40 40
41#else /* !__ASSEMBLY__ */ 41#endif /* !__ASSEMBLY__ */
42
43/* offsets into the thread_info struct for assembly code access */
44#define TI_TASK 0x00000000
45#define TI_EXEC_DOMAIN 0x00000004
46#define TI_FLAGS 0x00000008
47#define TI_STATUS 0x0000000C
48#define TI_CPU 0x00000010
49#define TI_PRE_COUNT 0x00000014
50#define TI_ADDR_LIMIT 0x00000018
51
52#endif
53 42
54#define THREAD_SIZE (PAGE_SIZE << 1) 43#define THREAD_SIZE (PAGE_SIZE << 1)
55#define THREAD_SIZE_ORDER 1 44#define THREAD_SIZE_ORDER 1
diff --git a/arch/m32r/kernel/asm-offsets.c b/arch/m32r/kernel/asm-offsets.c
index 9e263112a6e2..cd3d2fc9c8df 100644
--- a/arch/m32r/kernel/asm-offsets.c
+++ b/arch/m32r/kernel/asm-offsets.c
@@ -1 +1,14 @@
1/* Dummy asm-offsets.c file. Required by kbuild and ready to be used - hint! */ 1#include <linux/thread_info.h>
2#include <linux/kbuild.h>
3
4int foo(void)
5{
6 OFFSET(TI_TASK, thread_info, task);
7 OFFSET(TI_FLAGS, thread_info, flags);
8 OFFSET(TI_STATUS, thread_info, status);
9 OFFSET(TI_CPU, thread_info, cpu);
10 OFFSET(TI_PRE_COUNT, thread_info, preempt_count);
11 OFFSET(TI_ADDR_LIMIT, thread_info, addr_limit);
12
13 return 0;
14}
diff --git a/arch/m32r/kernel/entry.S b/arch/m32r/kernel/entry.S
index 7c3db9940ce1..c639bfa32232 100644
--- a/arch/m32r/kernel/entry.S
+++ b/arch/m32r/kernel/entry.S
@@ -65,6 +65,7 @@
65#include <asm/page.h> 65#include <asm/page.h>
66#include <asm/m32r.h> 66#include <asm/m32r.h>
67#include <asm/mmu_context.h> 67#include <asm/mmu_context.h>
68#include <asm/asm-offsets.h>
68 69
69#if !defined(CONFIG_MMU) 70#if !defined(CONFIG_MMU)
70#define sys_madvise sys_ni_syscall 71#define sys_madvise sys_ni_syscall