Re: [PATCH] x86/speculation: Clean up various Spectre related details

From: Ingo Molnar
Date: Sun Feb 11 2018 - 14:43:14 EST



* David Woodhouse <dwmw2@xxxxxxxxxxxxx> wrote:

>
>
> On Sun, 2018-02-11 at 19:50 +0100, Ingo Molnar wrote:
> >
> > From 82c2b2f29691143a05181333f387e786646aa28b Mon Sep 17 00:00:00 2001
> > From: Ingo Molnar <mingo@xxxxxxxxxx>
> > Date: Sat, 10 Feb 2018 11:51:57 +0100
> > Subject: [PATCH] x86/speculation: Clean up various Spectre related details
> >
> > Harmonize all the Spectre messages so that a:
> >
> >     dmesg | grep -i spectre
> >
> > ... gives us most Spectre related kernel boot messages.
> >
> > Also fix a few other details:
> >
> >  - clarify a comment about firmware speculation control
> >
> >  - s/KPTI/PTI
> >
> >  - remove various line-breaks that made the code uglier
> >
> > Cc: Andy Lutomirski <luto@xxxxxxxxxx>
> > Cc: Arjan van de Ven <arjan@xxxxxxxxxxxxxxx>
> > Cc: Borislav Petkov <bp@xxxxxxxxx>
> > Cc: Dan Williams <dan.j.williams@xxxxxxxxx>
> > Cc: Dave Hansen <dave.hansen@xxxxxxxxxxxxxxx>
> > Cc: David Woodhouse <dwmw2@xxxxxxxxxxxxx>
> > Cc: David Woodhouse <dwmw@xxxxxxxxxxxx>
> > Cc: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
> > Cc: Josh Poimboeuf <jpoimboe@xxxxxxxxxx>
> > Cc: Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx>
> > Cc: Peter Zijlstra <peterz@xxxxxxxxxxxxx>
> > Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx>
> > Signed-off-by: Ingo Molnar <mingo@xxxxxxxxxx>
>
>
>
> Acked-by: David Woodhouse <dwmw@xxxxxxxxxxxx>

Thanks, added.

> with a couple of comments:
>
>
> -        * If neither SMEP or KPTI are available, there is a risk of
> +        * If neither SMEP or PTI are available, there is a risk of
>
> Make that 'neither SMEP nor PTI' while you're at it though please;
> that's bugged me a couple of times in passing.

Ok, fixed that too.

>
> And should these say 'Spectre v2' not just 'Spectre'?

Yeah, you are probably right, but I didn't want to make the messages too specific
- do we really know that this is the end of Spectre-style speculation holes?

Thanks,

Ingo