From patchwork Tue May 11 16:12:35 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Murphy X-Patchwork-Id: 12251467 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=-17.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT 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 D6551C433ED for ; Tue, 11 May 2021 16:17:39 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 79CE26186A for ; Tue, 11 May 2021 16:17:39 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 79CE26186A Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; 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=m71M3NwcCViwJVjBmXu8wewNNz30Jt09/fXPbzMAxoM=; b=SfTgRRubnugjqyI9PaKTo6X7y /cJXcs949f0BqM87HrEtd+aPdF2neXCPAziAVmLdwBIxVzTT/s/2Ote9lZquR+JzLlRjWZZRPfvbd +rFr6TboM66vUh/tTs1MzPQ82RZyxM+bJMwINZ0V2gI421qz4VFKEG3mPt2IuWbhtZhLGihqFeiu4 sio8JJA7+FpVzrMP1E6SmliIni2Z4gXIetSwMLOBq02TWF0XrXzwZLNtxlgjf9uLAXhqPtPJMQXGh ktVQUMvQSVMZicGFjL2IMPbvUjUfCQXU4srhnHvTRCOi3vQ9P7BWWTuThHwbqKFEMf61wmWViYbCG UsxgwQR+g==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lgV2v-000hDd-4G; Tue, 11 May 2021 16:15:45 +0000 Received: from bombadil.infradead.org ([2607:7c80:54:e::133]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lgV0B-000gkI-Cd for linux-arm-kernel@desiato.infradead.org; Tue, 11 May 2021 16:12:56 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=CdtNSBsYc1JfPo6p5JhXTY6ArbidP6990K4zDUXAbso=; b=Wig3MrugIrUQmX1BZR3sd0E4on vXypQTvyaiIHvQIeXDJph2NCvdETIwl9LdL0XWD3d25naUP6Q7+mgyqqbLWl37womu2CybAB3tBYG tbhrA7Qo2pbBupsm5eDibn3wXGM5WkUDa3Yg/PdtwDEKcT2XmYLcLO0W8cCsklJlAOXhbsuY2tyDU wuhU/Uz8pIkzDfzRzvV0cMPWdzo7VgnPxLFG3zaUW/M2RSJD2tF+J9aaVDvlQNyMOrpeYMAjKXf/f dDTZum66WYq+91U25jU3eWeO9sOYhMczy7Ie7/6jYnl0MMLZ2tAm+evb0BiknVArFxnxlbFlOgcl9 AHHYrIIA==; Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lgV08-009kT2-EQ for linux-arm-kernel@lists.infradead.org; Tue, 11 May 2021 16:12:53 +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 D3CC516F2; Tue, 11 May 2021 09:12:48 -0700 (PDT) Received: from e110467-lin.cambridge.arm.com (e110467-lin.cambridge.arm.com [10.1.196.41]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 0B1813F792; Tue, 11 May 2021 09:12:47 -0700 (PDT) From: Robin Murphy To: will@kernel.org, catalin.marinas@arm.com Cc: linux-arm-kernel@lists.infradead.org, yangyingliang@huawei.com, shenkai8@huawei.com Subject: [PATCH 5/8] arm64: Add assembly annotations for weak-PI-alias madness Date: Tue, 11 May 2021 17:12:35 +0100 Message-Id: <93210932f8a83f88c69195d5c72a3c1bf4b02222.1620738177.git.robin.murphy@arm.com> X-Mailer: git-send-email 2.21.0.dirty In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210511_091252_557888_D5446157 X-CRM114-Status: UNSURE ( 7.74 ) 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 Add yet another set of assembly symbol annotations, this time for the borderline-absurd situation of a function aliasing to a weak symbol which itself also wants a position-independent alias. Signed-off-by: Robin Murphy --- arch/arm64/include/asm/linkage.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/arch/arm64/include/asm/linkage.h b/arch/arm64/include/asm/linkage.h index ba89a9af820a..9906541a6861 100644 --- a/arch/arm64/include/asm/linkage.h +++ b/arch/arm64/include/asm/linkage.h @@ -56,8 +56,16 @@ SYM_FUNC_START_ALIAS(__pi_##x); \ SYM_FUNC_START_WEAK(x) +#define SYM_FUNC_START_WEAK_ALIAS_PI(x) \ + SYM_FUNC_START_ALIAS(__pi_##x); \ + SYM_START(x, SYM_L_WEAK, SYM_A_ALIGN) + #define SYM_FUNC_END_PI(x) \ SYM_FUNC_END(x); \ SYM_FUNC_END_ALIAS(__pi_##x) +#define SYM_FUNC_END_ALIAS_PI(x) \ + SYM_FUNC_END_ALIAS(x); \ + SYM_FUNC_END_ALIAS(__pi_##x) + #endif