From patchwork Thu Jun 23 01:49:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chen Zhongjin X-Patchwork-Id: 12891680 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id F0B24C43334 for ; Thu, 23 Jun 2022 02:03:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=QXOLd1cPhVfYsU0+bOkalZT+zFuCHECel4jr/gIJLs0=; b=KDXPtdvlfWOa0G fNaCyAztOXFRW8WcRMuXt9W1Xh0z/EWwHEd2Z7MQatyeA8fzrNcn9llcdzyGxGIOTP147sDnD/NnR zfpv9AetD2iRR0AsoAuu5m9nXThycSlVNn4gJyF0p5hLAEfAJRLjlMFYGJoR/j6WOJqq178IOmlid Dk5mOCJlLHsDglNfGLzZc0YK/4dvhur6WnWFy3IqcM9yPjWzysyM/Q6qKyBKpsarNFEcHlIIaOkwR RkUjrgWs9G2TzHMGCggiMr0IDMyy/kIVP9BhhPriDI6H1n+WS0F8Bg4pr0oa8iaaBqU7E+6gjDL5c dWK2H3gUsmYc53j+KKWA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1o4CAd-00Cp51-5u; Thu, 23 Jun 2022 02:02:12 +0000 Received: from casper.infradead.org ([2001:8b0:10b:1236::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1o4C0w-00CkDL-RN for linux-arm-kernel@bombadil.infradead.org; Thu, 23 Jun 2022 01:52:10 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=Content-Type:MIME-Version:References: In-Reply-To:Message-ID:Date:Subject:CC:To:From:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=yi3S/ZJJwR7646IkS2I3NeGtAdyri0qjMZiBBojMj98=; b=qUuSmmt1VQVJm/Vi72bZ9XkGzk DTrsM/aqqdDFfoPdRl6eXFWgL6Un41X/9whow+c3fVpHSPOVC74HB/1pJMDURGVlKPga/waNrvGhp j+Ex88ZEOR7g3urJ2wke8BQ2MgN2zmKRpgn/0qy6jNBzxvAtvQXjiqy7R2eEMJ/qyNtshmX7BXdO3 4mrMtYWEt2ZIfZh0A4eVv0/2hqurgZjMp9j0sio6HzfvPx8xHo4rtNviuHOfdAEdnyYJSOfIgq+Sh E7EKETuNNham7xEqFnop2PJJnJ5Pwzmh+FcjZDRXvhGGMr5Jbocie9vhW73DIZN8cQgdRdV4g/g6A RcrleZQg==; Received: from szxga02-in.huawei.com ([45.249.212.188]) by casper.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1o4C0q-007V4y-0I for linux-arm-kernel@lists.infradead.org; Thu, 23 Jun 2022 01:52:09 +0000 Received: from dggpemm500022.china.huawei.com (unknown [172.30.72.53]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4LT39F19rvzkWVh; Thu, 23 Jun 2022 09:50:09 +0800 (CST) Received: from dggpemm500013.china.huawei.com (7.185.36.172) by dggpemm500022.china.huawei.com (7.185.36.162) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Thu, 23 Jun 2022 09:51:51 +0800 Received: from ubuntu1804.huawei.com (10.67.175.36) by dggpemm500013.china.huawei.com (7.185.36.172) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Thu, 23 Jun 2022 09:51:50 +0800 From: Chen Zhongjin To: , , , , , CC: , , , , , , , , , , , , , , Subject: [PATCH v6 26/33] arm64: crypto: Remove unnecessary stackframe Date: Thu, 23 Jun 2022 09:49:10 +0800 Message-ID: <20220623014917.199563-27-chenzhongjin@huawei.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220623014917.199563-1-chenzhongjin@huawei.com> References: <20220623014917.199563-1-chenzhongjin@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.67.175.36] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To dggpemm500013.china.huawei.com (7.185.36.172) X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220623_025204_512564_0B87FE0B X-CRM114-Status: UNSURE ( 6.47 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The way sha256_block_neon restore the stackframe confuses objtool. But it turns out this function is a leaf function and does not use FP nor LR as scratch register. Do not create a stackframe in this function as it is not necessary. Signed-off-by: Julien Thierry Signed-off-by: Chen Zhongjin --- arch/arm64/crypto/sha512-armv8.pl | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/arch/arm64/crypto/sha512-armv8.pl b/arch/arm64/crypto/sha512-armv8.pl index 1882c4110026..6e2a96e05c5a 100644 --- a/arch/arm64/crypto/sha512-armv8.pl +++ b/arch/arm64/crypto/sha512-armv8.pl @@ -648,8 +648,6 @@ $code.=<<___; .align 4 sha256_block_neon: .Lneon_entry: - stp x29, x30, [sp, #-16]! - mov x29, sp sub sp,sp,#16*4 adr $Ktbl,K256 @@ -736,8 +734,7 @@ $code.=<<___; mov $Xfer,sp b.ne .L_00_48 - ldr x29,[x29] - add sp,sp,#16*4+16 + add sp,sp,#16*4 ret .size sha256_block_neon,.-sha256_block_neon ___