aboutsummaryrefslogtreecommitdiffstats
path: root/arch/i386/lib
diff options
context:
space:
mode:
authorAdrian Bunk <bunk@stusta.de>2007-02-19 19:07:13 -0500
committerDave Jones <davej@redhat.com>2007-02-20 14:29:37 -0500
commitb44755cfaa72e7ed3d831a946bb4e7dfe7548966 (patch)
tree251cf0ab5aa9c39bab3f0981ab96021b5523bee3 /arch/i386/lib
parent48ac3271e52d23ee987da93f80d20f6bec8e6717 (diff)
{rd,wr}msr_on_cpu SMP=n optimization
Let's save a few bytes in the CONFIG_SMP=n case. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Dave Jones <davej@redhat.com>
Diffstat (limited to 'arch/i386/lib')
-rw-r--r--arch/i386/lib/Makefile2
-rw-r--r--arch/i386/lib/msr-on-cpu.c12
2 files changed, 1 insertions, 13 deletions
diff --git a/arch/i386/lib/Makefile b/arch/i386/lib/Makefile
index 0d41223472c2..22d8ac5815f0 100644
--- a/arch/i386/lib/Makefile
+++ b/arch/i386/lib/Makefile
@@ -8,4 +8,4 @@ lib-y = checksum.o delay.o usercopy.o getuser.o putuser.o memcpy.o strstr.o \
8 8
9lib-$(CONFIG_X86_USE_3DNOW) += mmx.o 9lib-$(CONFIG_X86_USE_3DNOW) += mmx.o
10 10
11obj-y = msr-on-cpu.o 11obj-$(CONFIG_SMP) += msr-on-cpu.o
diff --git a/arch/i386/lib/msr-on-cpu.c b/arch/i386/lib/msr-on-cpu.c
index 2092ea15ba85..1c46bda409ff 100644
--- a/arch/i386/lib/msr-on-cpu.c
+++ b/arch/i386/lib/msr-on-cpu.c
@@ -3,7 +3,6 @@
3#include <linux/smp.h> 3#include <linux/smp.h>
4#include <asm/msr.h> 4#include <asm/msr.h>
5 5
6#ifdef CONFIG_SMP
7struct msr_info { 6struct msr_info {
8 u32 msr_no; 7 u32 msr_no;
9 u32 l, h; 8 u32 l, h;
@@ -54,17 +53,6 @@ void wrmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 l, u32 h)
54 } 53 }
55 preempt_enable(); 54 preempt_enable();
56} 55}
57#else
58void rdmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 *l, u32 *h)
59{
60 rdmsr(msr_no, *l, *h);
61}
62
63void wrmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 l, u32 h)
64{
65 wrmsr(msr_no, l, h);
66}
67#endif
68 56
69EXPORT_SYMBOL(rdmsr_on_cpu); 57EXPORT_SYMBOL(rdmsr_on_cpu);
70EXPORT_SYMBOL(wrmsr_on_cpu); 58EXPORT_SYMBOL(wrmsr_on_cpu);