aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnton Blanchard <anton@samba.org>2010-01-11 19:50:14 -0500
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2010-02-03 01:39:48 -0500
commit5be3492f972b73051ead7ecbac6fb9efd1e8e0ec (patch)
treec0c66a38665af53673792246f21198c119e8c7d4
parent61c03ddbdff2e080702521bc1b757854ca58c46a (diff)
powerpc: Mark some variables in the page fault path __read_mostly
Using perf to trace L1 dcache misses and dumping data addresses I found a few variables taking a lot of misses. Since they are almost never written, they should go into the __read_mostly section. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-rw-r--r--arch/powerpc/kernel/traps.c14
-rw-r--r--arch/powerpc/xmon/xmon.c2
2 files changed, 8 insertions, 8 deletions
diff --git a/arch/powerpc/kernel/traps.c b/arch/powerpc/kernel/traps.c
index d069ff8a7e03..4588d1eb18d2 100644
--- a/arch/powerpc/kernel/traps.c
+++ b/arch/powerpc/kernel/traps.c
@@ -60,13 +60,13 @@
60#endif 60#endif
61 61
62#if defined(CONFIG_DEBUGGER) || defined(CONFIG_KEXEC) 62#if defined(CONFIG_DEBUGGER) || defined(CONFIG_KEXEC)
63int (*__debugger)(struct pt_regs *regs); 63int (*__debugger)(struct pt_regs *regs) __read_mostly;
64int (*__debugger_ipi)(struct pt_regs *regs); 64int (*__debugger_ipi)(struct pt_regs *regs) __read_mostly;
65int (*__debugger_bpt)(struct pt_regs *regs); 65int (*__debugger_bpt)(struct pt_regs *regs) __read_mostly;
66int (*__debugger_sstep)(struct pt_regs *regs); 66int (*__debugger_sstep)(struct pt_regs *regs) __read_mostly;
67int (*__debugger_iabr_match)(struct pt_regs *regs); 67int (*__debugger_iabr_match)(struct pt_regs *regs) __read_mostly;
68int (*__debugger_dabr_match)(struct pt_regs *regs); 68int (*__debugger_dabr_match)(struct pt_regs *regs) __read_mostly;
69int (*__debugger_fault_handler)(struct pt_regs *regs); 69int (*__debugger_fault_handler)(struct pt_regs *regs) __read_mostly;
70 70
71EXPORT_SYMBOL(__debugger); 71EXPORT_SYMBOL(__debugger);
72EXPORT_SYMBOL(__debugger_ipi); 72EXPORT_SYMBOL(__debugger_ipi);
diff --git a/arch/powerpc/xmon/xmon.c b/arch/powerpc/xmon/xmon.c
index 4e6152c13764..8bad7d5f32af 100644
--- a/arch/powerpc/xmon/xmon.c
+++ b/arch/powerpc/xmon/xmon.c
@@ -61,7 +61,7 @@ static int xmon_owner;
61static int xmon_gate; 61static int xmon_gate;
62#endif /* CONFIG_SMP */ 62#endif /* CONFIG_SMP */
63 63
64static unsigned long in_xmon = 0; 64static unsigned long in_xmon __read_mostly = 0;
65 65
66static unsigned long adrs; 66static unsigned long adrs;
67static int size = 1; 67static int size = 1;