From: Andi Kleen <andi@firstfloor.org> To: x86@kernel.org Cc: linux-kernel@vger.kernel.org, Andi Kleen <ak@linux.intel.com> Subject: [PATCH 2/2] x86/spectre: Add missing family 6 check to microcode check Date: Fri, 24 Aug 2018 10:03:51 -0700 Message-ID: <20180824170351.34874-2-andi@firstfloor.org> (raw) In-Reply-To: <20180824170351.34874-1-andi@firstfloor.org> From: Andi Kleen <ak@linux.intel.com> The check for Spectre microcodes did not check for family 6, only the model numbers. Add a family 6 check too just to avoid ambiguity with other families. Signed-off-by: Andi Kleen <ak@linux.intel.com> --- arch/x86/kernel/cpu/intel.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/x86/kernel/cpu/intel.c b/arch/x86/kernel/cpu/intel.c index 401e8c133108..fc3c07fe7df5 100644 --- a/arch/x86/kernel/cpu/intel.c +++ b/arch/x86/kernel/cpu/intel.c @@ -150,6 +150,9 @@ static bool bad_spectre_microcode(struct cpuinfo_x86 *c) if (cpu_has(c, X86_FEATURE_HYPERVISOR)) return false; + if (c->x86 != 6) + return false; + for (i = 0; i < ARRAY_SIZE(spectre_bad_microcodes); i++) { if (c->x86_model == spectre_bad_microcodes[i].model && c->x86_stepping == spectre_bad_microcodes[i].stepping) -- 2.17.1
next prev parent reply index Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top 2018-08-24 17:03 [PATCH 1/2] x86/speculation/l1tf: Increase l1tf memory limit for Nehalem+ Andi Kleen 2018-08-24 17:03 ` Andi Kleen [this message] 2018-08-27 8:34 ` [tip:x86/urgent] x86/spectre: Add missing family 6 check to microcode check tip-bot for Andi Kleen
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20180824170351.34874-2-andi@firstfloor.org \ --to=andi@firstfloor.org \ --cc=ak@linux.intel.com \ --cc=linux-kernel@vger.kernel.org \ --cc=x86@kernel.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
LKML Archive on lore.kernel.org Archives are clonable: git clone --mirror https://lore.kernel.org/lkml/0 lkml/git/0.git git clone --mirror https://lore.kernel.org/lkml/1 lkml/git/1.git git clone --mirror https://lore.kernel.org/lkml/2 lkml/git/2.git git clone --mirror https://lore.kernel.org/lkml/3 lkml/git/3.git git clone --mirror https://lore.kernel.org/lkml/4 lkml/git/4.git git clone --mirror https://lore.kernel.org/lkml/5 lkml/git/5.git git clone --mirror https://lore.kernel.org/lkml/6 lkml/git/6.git git clone --mirror https://lore.kernel.org/lkml/7 lkml/git/7.git git clone --mirror https://lore.kernel.org/lkml/8 lkml/git/8.git git clone --mirror https://lore.kernel.org/lkml/9 lkml/git/9.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 lkml lkml/ https://lore.kernel.org/lkml \ linux-kernel@vger.kernel.org public-inbox-index lkml Example config snippet for mirrors Newsgroup available over NNTP: nntp://nntp.lore.kernel.org/org.kernel.vger.linux-kernel AGPL code for this site: git clone https://public-inbox.org/public-inbox.git