aboutsummaryrefslogtreecommitdiff
path: root/arch/sparc/kernel/traps_64.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2009-04-01 01:47:10 -0700
committerDavid S. Miller <davem@davemloft.net>2009-06-16 04:56:11 -0700
commit5a5488d3bb9a23d9884572e5d85dfeefe8749d3d (patch)
treeafa8db75cdf771257cd5541ed80a606df60f9cf8 /arch/sparc/kernel/traps_64.c
parent19f0fa3fb3499d8c5fb861933959f546d05fc202 (diff)
downloadlinux-linaro-stable-5a5488d3bb9a23d9884572e5d85dfeefe8749d3d.tar.gz
sparc64: Store per-cpu offset in trap_block[]
Surprisingly this actually makes LOAD_PER_CPU_BASE() a little more efficient. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/kernel/traps_64.c')
-rw-r--r--arch/sparc/kernel/traps_64.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/sparc/kernel/traps_64.c b/arch/sparc/kernel/traps_64.c
index d809c4ebb48f..d073aabf65ed 100644
--- a/arch/sparc/kernel/traps_64.c
+++ b/arch/sparc/kernel/traps_64.c
@@ -2509,6 +2509,7 @@ void do_getpsr(struct pt_regs *regs)
}
struct trap_per_cpu trap_block[NR_CPUS];
+EXPORT_SYMBOL(trap_block);
/* This can get invoked before sched_init() so play it super safe
* and use hard_smp_processor_id().
@@ -2592,7 +2593,9 @@ void __init trap_init(void)
(TRAP_PER_CPU_RESUM_QMASK !=
offsetof(struct trap_per_cpu, resum_qmask)) ||
(TRAP_PER_CPU_NONRESUM_QMASK !=
- offsetof(struct trap_per_cpu, nonresum_qmask)))
+ offsetof(struct trap_per_cpu, nonresum_qmask)) ||
+ (TRAP_PER_CPU_PER_CPU_BASE !=
+ offsetof(struct trap_per_cpu, __per_cpu_base)))
trap_per_cpu_offsets_are_bolixed_dave();
if ((TSB_CONFIG_TSB !=