From: Peter Zijlstra <peterz@infradead.org>
To: David Woodhouse <dwmw2@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>,
Josh Poimboeuf <jpoimboe@redhat.com>,
linux-kernel@vger.kernel.org, Dave Hansen <dave.hansen@intel.com>,
Ashok Raj <ashok.raj@intel.com>,
Tim Chen <tim.c.chen@linux.intel.com>,
Andy Lutomirski <luto@kernel.org>,
Linus Torvalds <torvalds@linux-foundation.org>,
Greg KH <gregkh@linuxfoundation.org>,
Andrea Arcangeli <aarcange@redhat.com>,
Andi Kleen <ak@linux.intel.com>,
Arjan Van De Ven <arjan.van.de.ven@intel.com>,
Dan Williams <dan.j.williams@intel.com>,
Paolo Bonzini <pbonzini@redhat.com>,
Jun Nakajima <jun.nakajima@intel.com>,
Asit Mallick <asit.k.mallick@intel.com>
Subject: Re: [PATCH 4/7] x86,nospec: Annotate indirect calls/jumps
Date: Thu, 1 Feb 2018 16:11:36 +0100 [thread overview]
Message-ID: <20180201151136.GX2249@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <1517496926.18619.315.camel@infradead.org>
On Thu, Feb 01, 2018 at 02:55:26PM +0000, David Woodhouse wrote:
>
>
> On Thu, 2018-02-01 at 15:34 +0100, Peter Zijlstra wrote:
> >
> > * These are the bare retpoline primitives for indirect jmp and call.
> > * Do not use these directly; they only exist to make the ALTERNATIVE
> > * invocation below less ugly.
> > @@ -102,9 +114,9 @@
> > .macro JMP_NOSPEC reg:req
> > #ifdef CONFIG_RETPOLINE
> > ANNOTATE_NOSPEC_ALTERNATIVE
> > - ALTERNATIVE_2 __stringify(jmp *\reg), \
> > + ALTERNATIVE_2 __stringify(ANNOTATE_RETPOLINE_SAFE; jmp *\reg), \
> > __stringify(RETPOLINE_JMP \reg), X86_FEATURE_RETPOLINE, \
> > - __stringify(lfence; jmp *\reg), X86_FEATURE_RETPOLINE_AMD
> > + __stringify(lfence; ANNOTATE_RETPOLINE_SAFE; jmp *\reg), X86_FEATURE_RETPOLINE_AMD
> > #else
> > jmp *\reg
> > #endif
>
> The first one, yes. But the second one for the AMD retpoline is
> redundant, isn't it? Objtool isn't going to look there.
It was when I wrote it.. lemme try again.
next prev parent reply other threads:[~2018-02-01 15:11 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-01 14:34 [PATCH 0/7] objtool: retpoline validation Peter Zijlstra
2018-02-01 14:34 ` [PATCH 1/7] objtool: Use existing global variables for options Peter Zijlstra
2018-02-01 14:34 ` [PATCH 2/7] objtool: Add retpoline validation Peter Zijlstra
2018-02-01 14:34 ` [PATCH 3/7] objtool: Add module specific retpoline rules Peter Zijlstra
2018-02-01 14:34 ` [PATCH 4/7] x86,nospec: Annotate indirect calls/jumps Peter Zijlstra
2018-02-01 14:55 ` David Woodhouse
2018-02-01 15:11 ` Peter Zijlstra [this message]
2018-02-01 15:13 ` Peter Zijlstra
2018-02-01 15:21 ` Josh Poimboeuf
2018-02-01 15:30 ` Peter Zijlstra
2018-02-01 14:34 ` [PATCH 5/7] x86/paravirt: Annotate indirect calls Peter Zijlstra
2018-02-01 14:34 ` [PATCH 6/7] x86: Annotate indirect jump in head_64.S Peter Zijlstra
2018-02-01 14:34 ` [PATCH 7/7] x86,sme: Annotate indirect call Peter Zijlstra
2018-02-01 15:28 ` [PATCH 0/7] objtool: retpoline validation Josh Poimboeuf
2018-02-01 15:32 ` David Woodhouse
2018-02-01 15:40 ` Peter Zijlstra
2018-02-01 16:51 ` David Woodhouse
2018-02-01 17:14 ` Peter Zijlstra
2018-02-01 17:43 ` Josh Poimboeuf
2018-02-01 18:16 ` Tim Chen
2018-02-06 21:23 ` David Woodhouse
2018-02-01 15:32 ` Peter Zijlstra
2018-02-01 19:36 ` Peter Zijlstra
2018-02-01 15:50 ` Josh Poimboeuf
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=20180201151136.GX2249@hirez.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=aarcange@redhat.com \
--cc=ak@linux.intel.com \
--cc=arjan.van.de.ven@intel.com \
--cc=ashok.raj@intel.com \
--cc=asit.k.mallick@intel.com \
--cc=dan.j.williams@intel.com \
--cc=dave.hansen@intel.com \
--cc=dwmw2@infradead.org \
--cc=gregkh@linuxfoundation.org \
--cc=jpoimboe@redhat.com \
--cc=jun.nakajima@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=luto@kernel.org \
--cc=pbonzini@redhat.com \
--cc=tglx@linutronix.de \
--cc=tim.c.chen@linux.intel.com \
--cc=torvalds@linux-foundation.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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome