On Thu, Mar 19, 2015 at 06:17:48PM +0100, Denys Vlasenko wrote: > FIXUP_TOP_OF_STACK is only necessary because we don't save %r11 > to pt_regs->r11 on SYSCALL64 fast path, but we want ptrace to see > it populated. > > Bite the bullet, add a single additional PUSH insn, and remove > FIXUP_TOP_OF_STACK. > > RESTORE_TOP_OF_STACK is already a nop. Remove it too. > > On SandyBridge CPU, it does not get slower: > measured 54.22 ns per getpid syscall before and after last two changes > on defconfig kernel. > > Signed-off-by: Denys Vlasenko <dvlas...@redhat.com> > CC: Linus Torvalds <torva...@linux-foundation.org> > CC: Steven Rostedt <rost...@goodmis.org> > CC: Ingo Molnar <mi...@kernel.org> > CC: Borislav Petkov <b...@alien8.de> > CC: "H. Peter Anvin" <h...@zytor.com> > CC: Andy Lutomirski <l...@amacapital.net> > CC: Oleg Nesterov <o...@redhat.com> > CC: Frederic Weisbecker <fweis...@gmail.com> > CC: Alexei Starovoitov <a...@plumgrid.com> > CC: Will Drewry <w...@chromium.org> > CC: Kees Cook <keesc...@chromium.org> > CC: x...@kernel.org > CC: linux-kernel@vger.kernel.org > --- > arch/x86/kernel/entry_64.S | 35 ++--------------------------------- > 1 file changed, 2 insertions(+), 33 deletions(-)
Nice diffstat. Acked-by: Borislav Petkov <b...@suse.de> -- Regards/Gruss, Boris. ECO tip #101: Trim your mails when you reply. -- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/