diff options
author | Andrew Morton <akpm@linux-foundation.org> | 2007-07-01 15:06:48 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-01 15:29:44 -0400 |
commit | 84288ad89e9736c7478e138f247397b9ab7a9d28 (patch) | |
tree | 99f7757516d3d9fe85a16560d09479b5a29b0cbf /arch/i386 | |
parent | 5ebffd7c05391693b71d3326c8c78ff82f728ed0 (diff) |
i386: mtrr crash fix
Commit 3ebad5905609476a4ff1151a66b21d9794009961 ("[PATCH] x86: Save and
restore the fixed-range MTRRs of the BSP when suspending") added mtrr
operations without verifying that the CPU has MTRRs. Crashes transmeta
CPUs.
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: <linux@horizon.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/i386')
-rw-r--r-- | arch/i386/kernel/cpu/mtrr/generic.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/i386/kernel/cpu/mtrr/generic.c b/arch/i386/kernel/cpu/mtrr/generic.c index 5a551fb7ea7b..f6e46943e6ef 100644 --- a/arch/i386/kernel/cpu/mtrr/generic.c +++ b/arch/i386/kernel/cpu/mtrr/generic.c | |||
@@ -65,7 +65,8 @@ get_fixed_ranges(mtrr_type * frs) | |||
65 | 65 | ||
66 | void mtrr_save_fixed_ranges(void *info) | 66 | void mtrr_save_fixed_ranges(void *info) |
67 | { | 67 | { |
68 | get_fixed_ranges(mtrr_state.fixed_ranges); | 68 | if (cpu_has_mtrr) |
69 | get_fixed_ranges(mtrr_state.fixed_ranges); | ||
69 | } | 70 | } |
70 | 71 | ||
71 | static void print_fixed(unsigned base, unsigned step, const mtrr_type*types) | 72 | static void print_fixed(unsigned base, unsigned step, const mtrr_type*types) |