Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755029AbcLNIiX (ORCPT ); Wed, 14 Dec 2016 03:38:23 -0500 Received: from terminus.zytor.com ([198.137.202.10]:37280 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753184AbcLNIiU (ORCPT ); Wed, 14 Dec 2016 03:38:20 -0500 Date: Wed, 14 Dec 2016 00:36:58 -0800 From: tip-bot for Josh Poimboeuf Message-ID: Cc: linux-kernel@vger.kernel.org, hpa@zytor.com, bp@alien8.de, tglx@linutronix.de, torvalds@linux-foundation.org, peterz@infradead.org, luto@kernel.org, jpoimboe@redhat.com, mingo@kernel.org, brgerst@gmail.com, dvlasenk@redhat.com Reply-To: peterz@infradead.org, torvalds@linux-foundation.org, luto@kernel.org, linux-kernel@vger.kernel.org, hpa@zytor.com, bp@alien8.de, tglx@linutronix.de, mingo@kernel.org, brgerst@gmail.com, dvlasenk@redhat.com, jpoimboe@redhat.com In-Reply-To: <4d8a1952759721d42d1e62ba9e4a7e3ac5df8574.1481685203.git.jpoimboe@redhat.com> References: <4d8a1952759721d42d1e62ba9e4a7e3ac5df8574.1481685203.git.jpoimboe@redhat.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:x86/urgent] x86/boot/64: Use 'push' instead of 'call' in start_cpu() Git-Commit-ID: ec2d86a9b646d93f1948569f368e2c6f5449e6c7 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1731 Lines: 42 Commit-ID: ec2d86a9b646d93f1948569f368e2c6f5449e6c7 Gitweb: http://git.kernel.org/tip/ec2d86a9b646d93f1948569f368e2c6f5449e6c7 Author: Josh Poimboeuf AuthorDate: Tue, 13 Dec 2016 21:25:35 -0600 Committer: Ingo Molnar CommitDate: Wed, 14 Dec 2016 08:48:05 +0100 x86/boot/64: Use 'push' instead of 'call' in start_cpu() start_cpu() pushes a text address on the stack so that stack traces from idle tasks will show start_cpu() at the end. But it uses a call instruction to do that, which is rather obtuse. Use a straightforward push instead. Suggested-by: Borislav Petkov Signed-off-by: Josh Poimboeuf Cc: Andy Lutomirski Cc: Brian Gerst Cc: Denys Vlasenko Cc: H. Peter Anvin Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Link: http://lkml.kernel.org/r/4d8a1952759721d42d1e62ba9e4a7e3ac5df8574.1481685203.git.jpoimboe@redhat.com Signed-off-by: Ingo Molnar --- arch/x86/kernel/head_64.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/kernel/head_64.S b/arch/x86/kernel/head_64.S index 90de288..1facaf4 100644 --- a/arch/x86/kernel/head_64.S +++ b/arch/x86/kernel/head_64.S @@ -298,7 +298,7 @@ ENTRY(start_cpu) * REX.W + FF /5 JMP m16:64 Jump far, absolute indirect, * address given in m16:64. */ - call 1f # put return address on stack for unwinder + pushq $1f # put return address on stack for unwinder 1: xorq %rbp, %rbp # clear frame pointer movq initial_code(%rip), %rax pushq $__KERNEL_CS # set correct cs