From patchwork Mon Jul 15 07:20:23 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jia He X-Patchwork-Id: 13732997 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 C1D59C3DA4A for ; Mon, 15 Jul 2024 07:21:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=lrCl8xwHDrO7fTvx4/AvLlNvIBioCIv7RWWfQjGEYqk=; b=KeeNnCP/o2YND9lKJcvIAgKGBR lL36O6qCq8+1JSF5CUiaAPK0POmJ9TZMh7Vld+aUiSPK7it1jSPQv2YiQr4LVxZwTxTeZRX2pCgrh WwYmYUeJv1rHYlCTN6cHYcPHdq5G719gjtIYxkwjyJv4/K9GrIXEPiOAISH5GUimyk96oMQ5kPZKI W3ORyf38+9j7ArRySZo93znz5BA9gcMythuhX9gJRFcLk9X/adr0ap/VeRzv7wF58yzrd3WCBAhPF UkvwNgMzbBYBrT04SGtz7A5lNOb3CeVq0WDkQcuH7PuS/VeAa4rxyZlAyRrxluvJR9sfCGUwndPSV VGnAt8yg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sTG14-000000069Sj-1Hhc; Mon, 15 Jul 2024 07:20:58 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sTG0k-000000069MH-49LI for linux-arm-kernel@lists.infradead.org; Mon, 15 Jul 2024 07:20:40 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 46645DA7; Mon, 15 Jul 2024 00:21:00 -0700 (PDT) Received: from entos-yitian-01.shanghai.arm.com (entos-yitian-01.shanghai.arm.com [10.169.206.96]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id DF92C3F762; Mon, 15 Jul 2024 00:20:31 -0700 (PDT) From: Jia He To: Herbert Xu , "David S. Miller" , Catalin Marinas , linux-crypto@vger.kernel.org Cc: Will Deacon , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Jia He Subject: [PATCH] crypto: arm64/poly1305 - move data to rodata section Date: Mon, 15 Jul 2024 07:20:23 +0000 Message-Id: <20240715072023.61032-1-justin.he@arm.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240715_002039_097634_6C4D1FB0 X-CRM114-Status: UNSURE ( 9.51 ) 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 When objtool gains support for ARM in the future, it may encounter issues disassembling the following data in the .text section: > .Lzeros: > .long 0,0,0,0,0,0,0,0 > .asciz "Poly1305 for ARMv8, CRYPTOGAMS by \@dot-asm" > .align 2 Move it to .rodata which is a more appropriate section for read-only data. Signed-off-by: Jia He --- Inspired by commit 1253cab8a352, although currently objtool hasn't been supported on Arm, we should do some preparation(this patch) firstly. arch/arm64/crypto/poly1305-armv8.pl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm64/crypto/poly1305-armv8.pl b/arch/arm64/crypto/poly1305-armv8.pl index cbc980fb02e3..bcb70c9541e9 100644 --- a/arch/arm64/crypto/poly1305-armv8.pl +++ b/arch/arm64/crypto/poly1305-armv8.pl @@ -885,10 +885,13 @@ poly1305_blocks_neon: ret .size poly1305_blocks_neon,.-poly1305_blocks_neon +.pushsection .rodata .align 5 .Lzeros: .long 0,0,0,0,0,0,0,0 .asciz "Poly1305 for ARMv8, CRYPTOGAMS by \@dot-asm" +.popsection + .align 2 #if !defined(__KERNEL__) && !defined(_WIN64) .comm OPENSSL_armcap_P,4,4