|
@@ -144,6 +144,13 @@ static bool bad_spectre_microcode(struct cpuinfo_x86 *c)
|
|
{
|
|
{
|
|
int i;
|
|
int i;
|
|
|
|
|
|
|
|
+ /*
|
|
|
|
+ * We know that the hypervisor lie to us on the microcode version so
|
|
|
|
+ * we may as well hope that it is running the correct version.
|
|
|
|
+ */
|
|
|
|
+ if (cpu_has(c, X86_FEATURE_HYPERVISOR))
|
|
|
|
+ return false;
|
|
|
|
+
|
|
for (i = 0; i < ARRAY_SIZE(spectre_bad_microcodes); i++) {
|
|
for (i = 0; i < ARRAY_SIZE(spectre_bad_microcodes); i++) {
|
|
if (c->x86_model == spectre_bad_microcodes[i].model &&
|
|
if (c->x86_model == spectre_bad_microcodes[i].model &&
|
|
c->x86_stepping == spectre_bad_microcodes[i].stepping)
|
|
c->x86_stepping == spectre_bad_microcodes[i].stepping)
|