mirror of https://github.com/torvalds/linux.git
When suspending, save_processor_state() calls mtrr_save_fixed_ranges()
to save fixed-range MTRRs.
On platforms without fixed-range MTRRs like the ACRN hypervisor which
has removed fixed-range MTRR emulation, accessing these MSRs will
trigger an unchecked MSR access error. Make sure fixed-range MTRRs are
supported before access to prevent such error.
Since mtrr_state.have_fixed is only set when MTRRs are present and
enabled, checking the CPU feature flag in mtrr_save_fixed_ranges() is
unnecessary.
Fixes:
|
||
|---|---|---|
| .. | ||
| Makefile | ||
| amd.c | ||
| centaur.c | ||
| cleanup.c | ||
| cyrix.c | ||
| generic.c | ||
| if.c | ||
| legacy.c | ||
| mtrr.c | ||
| mtrr.h | ||