aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/asm-offsets.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/kernel/asm-offsets.c')
-rw-r--r--arch/powerpc/kernel/asm-offsets.c17
1 files changed, 16 insertions, 1 deletions
diff --git a/arch/powerpc/kernel/asm-offsets.c b/arch/powerpc/kernel/asm-offsets.c
index 7ee84968087b..d06f378597bb 100644
--- a/arch/powerpc/kernel/asm-offsets.c
+++ b/arch/powerpc/kernel/asm-offsets.c
@@ -40,9 +40,10 @@
40#ifdef CONFIG_PPC64 40#ifdef CONFIG_PPC64
41#include <asm/paca.h> 41#include <asm/paca.h>
42#include <asm/lppaca.h> 42#include <asm/lppaca.h>
43#include <asm/iseries/hv_lp_event.h>
44#include <asm/cache.h> 43#include <asm/cache.h>
45#include <asm/compat.h> 44#include <asm/compat.h>
45#include <asm/mmu.h>
46#include <asm/hvcall.h>
46#endif 47#endif
47 48
48#define DEFINE(sym, val) \ 49#define DEFINE(sym, val) \
@@ -136,11 +137,18 @@ int main(void)
136 DEFINE(PACA_STARTPURR, offsetof(struct paca_struct, startpurr)); 137 DEFINE(PACA_STARTPURR, offsetof(struct paca_struct, startpurr));
137 DEFINE(PACA_USER_TIME, offsetof(struct paca_struct, user_time)); 138 DEFINE(PACA_USER_TIME, offsetof(struct paca_struct, user_time));
138 DEFINE(PACA_SYSTEM_TIME, offsetof(struct paca_struct, system_time)); 139 DEFINE(PACA_SYSTEM_TIME, offsetof(struct paca_struct, system_time));
140 DEFINE(PACA_SLBSHADOWPTR, offsetof(struct paca_struct, slb_shadow_ptr));
141 DEFINE(PACA_DATA_OFFSET, offsetof(struct paca_struct, data_offset));
139 142
143 DEFINE(SLBSHADOW_STACKVSID,
144 offsetof(struct slb_shadow, save_area[SLB_NUM_BOLTED - 1].vsid));
145 DEFINE(SLBSHADOW_STACKESID,
146 offsetof(struct slb_shadow, save_area[SLB_NUM_BOLTED - 1].esid));
140 DEFINE(LPPACASRR0, offsetof(struct lppaca, saved_srr0)); 147 DEFINE(LPPACASRR0, offsetof(struct lppaca, saved_srr0));
141 DEFINE(LPPACASRR1, offsetof(struct lppaca, saved_srr1)); 148 DEFINE(LPPACASRR1, offsetof(struct lppaca, saved_srr1));
142 DEFINE(LPPACAANYINT, offsetof(struct lppaca, int_dword.any_int)); 149 DEFINE(LPPACAANYINT, offsetof(struct lppaca, int_dword.any_int));
143 DEFINE(LPPACADECRINT, offsetof(struct lppaca, int_dword.fields.decr_int)); 150 DEFINE(LPPACADECRINT, offsetof(struct lppaca, int_dword.fields.decr_int));
151 DEFINE(SLBSHADOW_SAVEAREA, offsetof(struct slb_shadow, save_area));
144#endif /* CONFIG_PPC64 */ 152#endif /* CONFIG_PPC64 */
145 153
146 /* RTAS */ 154 /* RTAS */
@@ -159,6 +167,12 @@ int main(void)
159 /* Create extra stack space for SRR0 and SRR1 when calling prom/rtas. */ 167 /* Create extra stack space for SRR0 and SRR1 when calling prom/rtas. */
160 DEFINE(PROM_FRAME_SIZE, STACK_FRAME_OVERHEAD + sizeof(struct pt_regs) + 16); 168 DEFINE(PROM_FRAME_SIZE, STACK_FRAME_OVERHEAD + sizeof(struct pt_regs) + 16);
161 DEFINE(RTAS_FRAME_SIZE, STACK_FRAME_OVERHEAD + sizeof(struct pt_regs) + 16); 169 DEFINE(RTAS_FRAME_SIZE, STACK_FRAME_OVERHEAD + sizeof(struct pt_regs) + 16);
170
171 /* hcall statistics */
172 DEFINE(HCALL_STAT_SIZE, sizeof(struct hcall_stats));
173 DEFINE(HCALL_STAT_CALLS, offsetof(struct hcall_stats, num_calls));
174 DEFINE(HCALL_STAT_TB, offsetof(struct hcall_stats, tb_total));
175 DEFINE(HCALL_STAT_PURR, offsetof(struct hcall_stats, purr_total));
162#endif /* CONFIG_PPC64 */ 176#endif /* CONFIG_PPC64 */
163 DEFINE(GPR0, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, gpr[0])); 177 DEFINE(GPR0, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, gpr[0]));
164 DEFINE(GPR1, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, gpr[1])); 178 DEFINE(GPR1, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, gpr[1]));
@@ -240,6 +254,7 @@ int main(void)
240 DEFINE(CPU_SPEC_PVR_VALUE, offsetof(struct cpu_spec, pvr_value)); 254 DEFINE(CPU_SPEC_PVR_VALUE, offsetof(struct cpu_spec, pvr_value));
241 DEFINE(CPU_SPEC_FEATURES, offsetof(struct cpu_spec, cpu_features)); 255 DEFINE(CPU_SPEC_FEATURES, offsetof(struct cpu_spec, cpu_features));
242 DEFINE(CPU_SPEC_SETUP, offsetof(struct cpu_spec, cpu_setup)); 256 DEFINE(CPU_SPEC_SETUP, offsetof(struct cpu_spec, cpu_setup));
257 DEFINE(CPU_SPEC_RESTORE, offsetof(struct cpu_spec, cpu_restore));
243 258
244#ifndef CONFIG_PPC64 259#ifndef CONFIG_PPC64
245 DEFINE(pbe_address, offsetof(struct pbe, address)); 260 DEFINE(pbe_address, offsetof(struct pbe, address));