Commit-ID: 88c6f8a3977cc35997b47e2f99f080a15559c1eb Gitweb: https://git.kernel.org/tip/88c6f8a3977cc35997b47e2f99f080a15559c1eb Author: Joerg Roedel <jroedel@xxxxxxx> AuthorDate: Tue, 7 Aug 2018 12:24:29 +0200 Committer: Thomas Gleixner <tglx@xxxxxxxxxxxxx> CommitDate: Tue, 7 Aug 2018 18:51:22 +0200 x86/mm/pti: Fix 32 bit PCID check The check uses the wrong operator and causes false positive warnings in the kernel log on some systems. Fixes: 5e8105950a8b3 ('x86/mm/pti: Add Warning when booting on a PCID capable CPU') Signed-off-by: Joerg Roedel <jroedel@xxxxxxx> Signed-off-by: Thomas Gleixner <tglx@xxxxxxxxxxxxx> Cc: "H . Peter Anvin" <hpa@xxxxxxxxx> Cc: linux-mm@xxxxxxxxx Cc: Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx> Cc: Andy Lutomirski <luto@xxxxxxxxxx> Cc: Dave Hansen <dave.hansen@xxxxxxxxx> Cc: Josh Poimboeuf <jpoimboe@xxxxxxxxxx> Cc: Juergen Gross <jgross@xxxxxxxx> Cc: Peter Zijlstra <peterz@xxxxxxxxxxxxx> Cc: Borislav Petkov <bp@xxxxxxxxx> Cc: Jiri Kosina <jkosina@xxxxxxx> Cc: Boris Ostrovsky <boris.ostrovsky@xxxxxxxxxx> Cc: Brian Gerst <brgerst@xxxxxxxxx> Cc: David Laight <David.Laight@xxxxxxxxxx> Cc: Denys Vlasenko <dvlasenk@xxxxxxxxxx> Cc: Eduardo Valentin <eduval@xxxxxxxxxx> Cc: Greg KH <gregkh@xxxxxxxxxxxxxxxxxxx> Cc: Will Deacon <will.deacon@xxxxxxx> Cc: aliguori@xxxxxxxxxx Cc: daniel.gruss@xxxxxxxxxxxxxx Cc: hughd@xxxxxxxxxx Cc: keescook@xxxxxxxxxx Cc: Andrea Arcangeli <aarcange@xxxxxxxxxx> Cc: Waiman Long <llong@xxxxxxxxxx> Cc: Pavel Machek <pavel@xxxxxx> Cc: "David H . Gutteridge" <dhgutteridge@xxxxxxxxxxxx> Cc: joro@xxxxxxxxxx Link: https://lkml.kernel.org/r/1533637471-30953-2-git-send-email-joro@xxxxxxxxxx --- arch/x86/mm/pti.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/mm/pti.c b/arch/x86/mm/pti.c index ef8db6ffc836..113ba14a03d8 100644 --- a/arch/x86/mm/pti.c +++ b/arch/x86/mm/pti.c @@ -549,7 +549,7 @@ void __init pti_init(void) * supported on 32 bit anyway. To print the warning we need to * check with cpuid directly again. */ - if (cpuid_ecx(0x1) && BIT(17)) { + if (cpuid_ecx(0x1) & BIT(17)) { /* Use printk to work around pr_fmt() */ printk(KERN_WARNING "\n"); printk(KERN_WARNING "************************************************************\n"); -- To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html