diff options
| author | Brian Gerst <brgerst@gmail.com> | 2010-07-17 09:03:27 -0400 |
|---|---|---|
| committer | H. Peter Anvin <hpa@zytor.com> | 2010-07-22 00:23:40 -0400 |
| commit | cfaa71ee9794472598d3966c3315cd6bd8f953d3 (patch) | |
| tree | 77991fa2648ffcb8bdcb7d76b9e896393402143d | |
| parent | 8c06585d6431addadd94903843dfbcd315b42d4e (diff) | |
x86: Use symbolic MSR names
Use symbolic MSR names instead of hardcoding the MSR index.
Signed-off-by: Brian Gerst <brgerst@gmail.com>
LKML-Reference: <1279371808-24804-2-git-send-email-brgerst@gmail.com>
Reviewed-by: Pekka Enberg <penberg@cs.helsinki.fi>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
| -rw-r--r-- | arch/x86/kernel/acpi/realmode/wakeup.S | 2 | ||||
| -rw-r--r-- | arch/x86/kernel/verify_cpu_64.S | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/arch/x86/kernel/acpi/realmode/wakeup.S b/arch/x86/kernel/acpi/realmode/wakeup.S index 580b4e296010..28595d6df47c 100644 --- a/arch/x86/kernel/acpi/realmode/wakeup.S +++ b/arch/x86/kernel/acpi/realmode/wakeup.S | |||
| @@ -104,7 +104,7 @@ _start: | |||
| 104 | movl %eax, %ecx | 104 | movl %eax, %ecx |
| 105 | orl %edx, %ecx | 105 | orl %edx, %ecx |
| 106 | jz 1f | 106 | jz 1f |
| 107 | movl $0xc0000080, %ecx | 107 | movl $MSR_EFER, %ecx |
| 108 | wrmsr | 108 | wrmsr |
| 109 | 1: | 109 | 1: |
| 110 | 110 | ||
diff --git a/arch/x86/kernel/verify_cpu_64.S b/arch/x86/kernel/verify_cpu_64.S index 45b6f8a975a1..56a8c2a867d9 100644 --- a/arch/x86/kernel/verify_cpu_64.S +++ b/arch/x86/kernel/verify_cpu_64.S | |||
| @@ -31,6 +31,7 @@ | |||
| 31 | */ | 31 | */ |
| 32 | 32 | ||
| 33 | #include <asm/cpufeature.h> | 33 | #include <asm/cpufeature.h> |
| 34 | #include <asm/msr-index.h> | ||
| 34 | 35 | ||
| 35 | verify_cpu: | 36 | verify_cpu: |
| 36 | pushfl # Save caller passed flags | 37 | pushfl # Save caller passed flags |
| @@ -88,7 +89,7 @@ verify_cpu_sse_test: | |||
| 88 | je verify_cpu_sse_ok | 89 | je verify_cpu_sse_ok |
| 89 | test %di,%di | 90 | test %di,%di |
| 90 | jz verify_cpu_no_longmode # only try to force SSE on AMD | 91 | jz verify_cpu_no_longmode # only try to force SSE on AMD |
| 91 | movl $0xc0010015,%ecx # HWCR | 92 | movl $MSR_K7_HWCR,%ecx |
| 92 | rdmsr | 93 | rdmsr |
| 93 | btr $15,%eax # enable SSE | 94 | btr $15,%eax # enable SSE |
| 94 | wrmsr | 95 | wrmsr |
