From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0F2D3C433E9 for ; Thu, 14 Jan 2021 13:29:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id DD97623A5F for ; Thu, 14 Jan 2021 13:29:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729055AbhANN25 (ORCPT ); Thu, 14 Jan 2021 08:28:57 -0500 Received: from mail.skyhub.de ([5.9.137.197]:52306 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729028AbhANN24 (ORCPT ); Thu, 14 Jan 2021 08:28:56 -0500 Received: from zn.tnic (p200300ec2f1aa9000d5c8ff8171504e8.dip0.t-ipconnect.de [IPv6:2003:ec:2f1a:a900:d5c:8ff8:1715:4e8]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 1DA2F1EC04F3; Thu, 14 Jan 2021 14:28:15 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1610630895; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=Gsx3hXRw+pWKKzqut1Ush7pyeSMmp2ZCnERRJ1prroQ=; b=F4XklBpuOo2kav+B+Hj/WlCU2yiyhQVshdz0xeJoNAAPK8BiaQI8qNIfPsfOaEDNBUjh+3 HhoaRWIRvLPVwFlEHE03osTFDF7+sZTo7UJTYzNVtn54egCQzmAwwVMgaPM+SZolKuKnfB 1kwj9tzbs+roaO+KJee2+FO/goS9SAM= Date: Thu, 14 Jan 2021 14:28:09 +0100 From: Borislav Petkov To: Peter Zijlstra Cc: Nick Desaulniers , Josh Poimboeuf , Mark Brown , Andy Lutomirski , Thomas Gleixner , Ingo Molnar , Fangrui Song , Arnd Bergmann , Jonathan Corbet , "maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , "H. Peter Anvin" , Nathan Chancellor , Miguel Ojeda , Jiri Slaby , Joe Perches , Linux Doc Mailing List , LKML , clang-built-linux Subject: [PATCH] x86/entry: Remove put_ret_addr_in_rdi THUNK macro argument Message-ID: <20210114132809.GC12284@zn.tnic> References: <20210112115421.GB13086@zn.tnic> <20210112194625.4181814-1-ndesaulniers@google.com> <20210112210154.GI4646@sirena.org.uk> <20210113165923.acvycpcu5tzksbbi@treble> <20210114103928.GB12284@zn.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 14, 2021 at 12:36:45PM +0100, Peter Zijlstra wrote: > And while looking, I suppose we can delete the put_ret_addr_in_rdi crud, > but that's another patch. --- From: Borislav Petkov Date: Thu, 14 Jan 2021 14:25:35 +0100 Subject: [PATCH] x86/entry: Remove put_ret_addr_in_rdi THUNK macro argument That logic is unused since 320100a5ffe5 ("x86/entry: Remove the TRACE_IRQS cruft") Remove it. Suggested-by: Peter Zijlstra Signed-off-by: Borislav Petkov --- arch/x86/entry/thunk_64.S | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/arch/x86/entry/thunk_64.S b/arch/x86/entry/thunk_64.S index c9a9fbf1655f..496b11ec469d 100644 --- a/arch/x86/entry/thunk_64.S +++ b/arch/x86/entry/thunk_64.S @@ -10,7 +10,7 @@ #include /* rdi: arg1 ... normal C conventions. rax is saved/restored. */ - .macro THUNK name, func, put_ret_addr_in_rdi=0 + .macro THUNK name, func SYM_FUNC_START_NOALIGN(\name) pushq %rbp movq %rsp, %rbp @@ -25,11 +25,6 @@ SYM_FUNC_START_NOALIGN(\name) pushq %r10 pushq %r11 - .if \put_ret_addr_in_rdi - /* 8(%rbp) is return addr on stack */ - movq 8(%rbp), %rdi - .endif - call \func jmp __thunk_restore SYM_FUNC_END(\name) -- 2.29.2 -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette